@florasync/leaflet-geokit 0.2.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/CHANGELOG.md +5 -0
- package/LICENSE +21 -0
- package/README.md +400 -0
- package/dist/leaflet-geokit.es.js +9233 -0
- package/dist/leaflet-geokit.es.js.map +1 -0
- package/dist/leaflet-geokit.umd.js +202 -0
- package/dist/leaflet-geokit.umd.js.map +1 -0
- package/package.json +106 -0
|
@@ -0,0 +1,202 @@
|
|
|
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 Ms=Object.defineProperty;var Es=(dt,ut,zt)=>ut in dt?Ms(dt,ut,{enumerable:!0,configurable:!0,writable:!0,value:zt}):dt[ut]=zt;var C=(dt,ut,zt)=>Es(dt,typeof ut!="symbol"?ut+"":ut,zt);function ut(g,c){for(var a=0;a<c.length;a++){const u=c[a];if(typeof u!="string"&&!Array.isArray(u)){for(const n in u)if(n!=="default"&&!(n in g)){const r=Object.getOwnPropertyDescriptor(u,n);r&&Object.defineProperty(g,n,r.get?r:{enumerable:!0,get:()=>u[n]})}}}return Object.freeze(Object.defineProperty(g,Symbol.toStringTag,{value:"Module"}))}const zt={trace:10,debug:20,info:30,warn:40,error:50};function oo(g,c){return g==="silent"?!1:zt[c]>=zt[g]}function ro(){try{return new Date().toISOString()}catch{return""}}function ve(g,c="debug",a=console){let u=c;const n=l=>(...d)=>{try{if(!oo(u,l))return;const p=`[${ro()}][${g}][${l.toUpperCase()}]`,_=a[l];typeof _=="function"?_(p,...d):a.log(p,...d)}catch{}};return{get level(){return u},setLevel(l){u=l},trace:n("trace"),debug:n("debug"),info:n("info"),warn:n("warn"),error:n("error"),child(l){return ve(`${g}:${l}`,u,a)}}}function so(g){return g&&g.__esModule&&Object.prototype.hasOwnProperty.call(g,"default")?g.default:g}var Qt={exports:{}};/* @preserve
|
|
2
|
+
* Leaflet 1.9.4, a JS library for interactive maps. https://leafletjs.com
|
|
3
|
+
* (c) 2010-2023 Vladimir Agafonkin, (c) 2010-2011 CloudMade
|
|
4
|
+
*/var ao=Qt.exports,Di;function Ii(){return Di||(Di=1,(function(g,c){(function(a,u){u(c)})(ao,(function(a){var u="1.9.4";function n(t){var e,i,o,s;for(i=1,o=arguments.length;i<o;i++){s=arguments[i];for(e in s)t[e]=s[e]}return t}var r=Object.create||(function(){function t(){}return function(e){return t.prototype=e,new t}})();function l(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 d=0;function p(t){return"_leaflet_id"in t||(t._leaflet_id=++d),t._leaflet_id}function _(t,e,i){var o,s,h,f;return f=function(){o=!1,s&&(h.apply(i,s),s=!1)},h=function(){o?s=arguments:(t.apply(i,arguments),setTimeout(f,e),o=!0)},h}function v(t,e,i){var o=e[1],s=e[0],h=o-s;return t===o&&i?t:((t-s)%h+h)%h+s}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 P(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function E(t){return P(t).split(/\s+/)}function k(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 Z(t,e,i){var o=[];for(var s in t)o.push(encodeURIComponent(i?s.toUpperCase():s)+"="+encodeURIComponent(t[s]));return(!e||e.indexOf("?")===-1?"?":"&")+o.join("&")}var F=/\{ *([\w_ -]+) *\}/g;function I(t,e){return t.replace(F,function(i,o){var s=e[o];if(s===void 0)throw new Error("No value provided for variable "+i);return typeof s=="function"&&(s=s(e)),s})}var S=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 q="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";function tt(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}var ot=0;function At(t){var e=+new Date,i=Math.max(0,16-(e-ot));return ot=e+i,window.setTimeout(t,i)}var Ct=window.requestAnimationFrame||tt("RequestAnimationFrame")||At,be=window.cancelAnimationFrame||tt("CancelAnimationFrame")||tt("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)};function rt(t,e,i){if(i&&Ct===At)t.call(e);else return Ct.call(window,l(t,e))}function at(t){t&&be.call(window,t)}var xe={__proto__:null,extend:n,create:r,bind:l,get lastId(){return d},stamp:p,throttle:_,wrapNum:v,falseFn:w,formatNum:x,trim:P,splitWords:E,setOptions:k,getParamString:Z,template:I,isArray:S,indexOf:V,emptyImageUrl:q,requestFn:Ct,cancelFn:be,requestAnimFrame:rt,cancelAnimFrame:at};function pt(){}pt.extend=function(t){var e=function(){k(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 s in this)Object.prototype.hasOwnProperty.call(this,s)&&s!=="prototype"&&s!=="__super__"&&(e[s]=this[s]);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 h=0,f=o._initHooks.length;h<f;h++)o._initHooks[h].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=S(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 s=0,h=t.length;s<h;s++)this._on(t[s],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 s=arguments.length===1,h=0,f=t.length;h<f;h++)s?this._off(t[h]):this._off(t[h],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 s={fn:e,ctx:i};o&&(s.once=!0),this._events=this._events||{},this._events[t]=this._events[t]||[],this._events[t].push(s)}},_off:function(t,e,i){var o,s,h;if(this._events&&(o=this._events[t],!!o)){if(arguments.length===1){if(this._firingCount)for(s=0,h=o.length;s<h;s++)o[s].fn=w;delete this._events[t];return}if(typeof e!="function"){console.warn("wrong listener type: "+typeof e);return}var f=this._listens(t,e,i);if(f!==!1){var m=o[f];this._firingCount&&(m.fn=w,this._events[t]=o=o.slice()),o.splice(f,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 s=this._events[t];if(s){this._firingCount=this._firingCount+1||1;for(var h=0,f=s.length;h<f;h++){var m=s[h],y=m.fn;m.once&&this.off(t,y,m.ctx),y.call(m.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 s=e;typeof e!="function"&&(o=!!e,s=void 0,i=void 0);var h=this._events&&this._events[t];if(h&&h.length&&this._listens(t,s,i)!==!1)return!0;if(o){for(var f in this._eventParents)if(this._eventParents[f].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 s=0,h=o.length;s<h;s++)if(o[s].fn===e&&o[s].ctx===i)return s;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 s=0,h=t.length;s<h;s++)this._on(t[s],e,i,!0)}return this},addEventParent:function(t){return this._eventParents=this._eventParents||{},this._eventParents[p(t)]=t,this},removeEventParent:function(t){return this._eventParents&&delete this._eventParents[p(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 B(t,e,i){this.x=i?Math.round(t):t,this.y=i?Math.round(e):e}var Yi=Math.trunc||function(t){return t>0?Math.floor(t):Math.ceil(t)};B.prototype={clone:function(){return new B(this.x,this.y)},add:function(t){return this.clone()._add(D(t))},_add:function(t){return this.x+=t.x,this.y+=t.y,this},subtract:function(t){return this.clone()._subtract(D(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 B(this.x*t.x,this.y*t.y)},unscaleBy:function(t){return new B(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=Yi(this.x),this.y=Yi(this.y),this},distanceTo:function(t){t=D(t);var e=t.x-this.x,i=t.y-this.y;return Math.sqrt(e*e+i*i)},equals:function(t){return t=D(t),t.x===this.x&&t.y===this.y},contains:function(t){return t=D(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 D(t,e,i){return t instanceof B?t:S(t)?new B(t[0],t[1]):t==null?t:typeof t=="object"&&"x"in t&&"y"in t?new B(t.x,t.y):new B(t,e,i)}function j(t,e){if(t)for(var i=e?[t,e]:t,o=0,s=i.length;o<s;o++)this.extend(i[o])}j.prototype={extend:function(t){var e,i;if(!t)return this;if(t instanceof B||typeof t[0]=="number"||"x"in t)e=i=D(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 D((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,t)},getBottomLeft:function(){return D(this.min.x,this.max.y)},getTopRight:function(){return D(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 B?t=D(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,s=t.max,h=s.x>=e.x&&o.x<=i.x,f=s.y>=e.y&&o.y<=i.y;return h&&f},overlaps:function(t){t=lt(t);var e=this.min,i=this.max,o=t.min,s=t.max,h=s.x>e.x&&o.x<i.x,f=s.y>e.y&&o.y<i.y;return h&&f},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,s=Math.abs(e.y-i.y)*t;return lt(D(e.x-o,e.y-s),D(i.x+o,i.y+s))},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,s=i.length;o<s;o++)this.extend(i[o])}ht.prototype={extend:function(t){var e=this._southWest,i=this._northEast,o,s;if(t instanceof W)o=t,s=t;else if(t instanceof ht){if(o=t._southWest,s=t._northEast,!o||!s)return this}else return t?this.extend(N(t)||X(t)):this;return!e&&!i?(this._southWest=new W(o.lat,o.lng),this._northEast=new W(s.lat,s.lng)):(e.lat=Math.min(o.lat,e.lat),e.lng=Math.min(o.lng,e.lng),i.lat=Math.max(s.lat,i.lat),i.lng=Math.max(s.lng,i.lng)),this},pad:function(t){var e=this._southWest,i=this._northEast,o=Math.abs(e.lat-i.lat)*t,s=Math.abs(e.lng-i.lng)*t;return new ht(new W(e.lat-o,e.lng-s),new W(i.lat+o,i.lng+s))},getCenter:function(){return new W((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 W(this.getNorth(),this.getWest())},getSouthEast:function(){return new W(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 W||"lat"in t?t=N(t):t=X(t);var e=this._southWest,i=this._northEast,o,s;return t instanceof ht?(o=t.getSouthWest(),s=t.getNorthEast()):o=s=t,o.lat>=e.lat&&s.lat<=i.lat&&o.lng>=e.lng&&s.lng<=i.lng},intersects:function(t){t=X(t);var e=this._southWest,i=this._northEast,o=t.getSouthWest(),s=t.getNorthEast(),h=s.lat>=e.lat&&o.lat<=i.lat,f=s.lng>=e.lng&&o.lng<=i.lng;return h&&f},overlaps:function(t){t=X(t);var e=this._southWest,i=this._northEast,o=t.getSouthWest(),s=t.getNorthEast(),h=s.lat>e.lat&&o.lat<i.lat,f=s.lng>e.lng&&o.lng<i.lng;return h&&f},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(t,e){return t?(t=X(t),this._southWest.equals(t.getSouthWest(),e)&&this._northEast.equals(t.getNorthEast(),e)):!1},isValid:function(){return!!(this._southWest&&this._northEast)}};function X(t,e){return t instanceof ht?t:new ht(t,e)}function W(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)}W.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 X([this.lat-e,this.lng-i],[this.lat+e,this.lng+i])},clone:function(){return new W(this.lat,this.lng,this.alt)}};function N(t,e,i){return t instanceof W?t:S(t)&&typeof t[0]!="object"?t.length===3?new W(t[0],t[1],t[2]):t.length===2?new W(t[0],t[1]):null:t==null?t:typeof t=="object"&&"lat"in t?new W(t.lat,"lng"in t?t.lng:t.lon,t.alt):e===void 0?null:new W(t,e,i)}var kt={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),s=this.transformation.transform(e.max,i);return new j(o,s)},infinite:!1,wrapLatLng:function(t){var e=this.wrapLng?v(t.lng,this.wrapLng,!0):t.lng,i=this.wrapLat?v(t.lat,this.wrapLat,!0):t.lat,o=t.alt;return new W(i,e,o)},wrapLatLngBounds:function(t){var e=t.getCenter(),i=this.wrapLatLng(e),o=e.lat-i.lat,s=e.lng-i.lng;if(o===0&&s===0)return t;var h=t.getSouthWest(),f=t.getNorthEast(),m=new W(h.lat-o,h.lng-s),y=new W(f.lat-o,f.lng-s);return new ht(m,y)}},St=n({},kt,{wrapLng:[-180,180],R:6371e3,distance:function(t,e){var i=Math.PI/180,o=t.lat*i,s=e.lat*i,h=Math.sin((e.lat-t.lat)*i/2),f=Math.sin((e.lng-t.lng)*i/2),m=h*h+Math.cos(o)*Math.cos(s)*f*f,y=2*Math.atan2(Math.sqrt(m),Math.sqrt(1-m));return this.R*y}}),qi=6378137,Qe={R:qi,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),s=Math.sin(o*e);return new B(this.R*t.lng*e,this.R*Math.log((1+s)/(1-s))/2)},unproject:function(t){var e=180/Math.PI;return new W((2*Math.atan(Math.exp(t.y/this.R))-Math.PI/2)*e,t.x*e/this.R)},bounds:(function(){var t=qi*Math.PI;return new j([-t,-t],[t,t])})()};function $e(t,e,i,o){if(S(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}$e.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 B((t.x/e-this._b)/this._a,(t.y/e-this._d)/this._c)}};function oe(t,e,i,o){return new $e(t,e,i,o)}var ti=n({},St,{code:"EPSG:3857",projection:Qe,transformation:(function(){var t=.5/(Math.PI*Qe.R);return oe(t,.5,-t,.5)})()}),ir=n({},ti,{code:"EPSG:900913"});function ji(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function Ki(t,e){var i="",o,s,h,f,m,y;for(o=0,h=t.length;o<h;o++){for(m=t[o],s=0,f=m.length;s<f;s++)y=m[s],i+=(s?"L":"M")+y.x+" "+y.y;i+=e?M.svg?"z":"x":""}return i||"M0 0"}var ei=document.documentElement.style,Ae="ActiveXObject"in window,nr=Ae&&!document.addEventListener,Ji="msLaunchUri"in navigator&&!("documentMode"in document),ii=wt("webkit"),Xi=wt("android"),Qi=wt("android 2")||wt("android 3"),or=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),rr=Xi&&wt("Google")&&or<537&&!("AudioNode"in window),ni=!!window.opera,$i=!Ji&&wt("chrome"),tn=wt("gecko")&&!ii&&!ni&&!Ae,sr=!$i&&wt("safari"),en=wt("phantom"),nn="OTransition"in ei,ar=navigator.platform.indexOf("Win")===0,on=Ae&&"transition"in ei,oi="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!Qi,rn="MozPerspective"in ei,lr=!window.L_DISABLE_3D&&(on||oi||rn)&&!nn&&!en,re=typeof orientation!="undefined"||wt("mobile"),hr=re&&ii,cr=re&&oi,sn=!window.PointerEvent&&window.MSPointerEvent,an=!!(window.PointerEvent||sn),ln="ontouchstart"in window||!!window.TouchEvent,dr=!window.L_NO_TOUCH&&(ln||an),ur=re&&ni,fr=re&&tn,pr=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,mr=(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})(),_r=(function(){return!!document.createElement("canvas").getContext})(),ri=!!(document.createElementNS&&ji("svg").createSVGRect),gr=!!ri&&(function(){var t=document.createElement("div");return t.innerHTML="<svg/>",(t.firstChild&&t.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"})(),vr=!ri&&(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}})(),yr=navigator.platform.indexOf("Mac")===0,wr=navigator.platform.indexOf("Linux")===0;function wt(t){return navigator.userAgent.toLowerCase().indexOf(t)>=0}var M={ie:Ae,ielt9:nr,edge:Ji,webkit:ii,android:Xi,android23:Qi,androidStock:rr,opera:ni,chrome:$i,gecko:tn,safari:sr,phantom:en,opera12:nn,win:ar,ie3d:on,webkit3d:oi,gecko3d:rn,any3d:lr,mobile:re,mobileWebkit:hr,mobileWebkit3d:cr,msPointer:sn,pointer:an,touch:dr,touchNative:ln,mobileOpera:ur,mobileGecko:fr,retina:pr,passiveEvents:mr,canvas:_r,svg:ri,vml:vr,inlineSvg:gr,mac:yr,linux:wr},hn=M.msPointer?"MSPointerDown":"pointerdown",cn=M.msPointer?"MSPointerMove":"pointermove",dn=M.msPointer?"MSPointerUp":"pointerup",un=M.msPointer?"MSPointerCancel":"pointercancel",si={touchstart:hn,touchmove:cn,touchend:dn,touchcancel:un},fn={touchstart:Mr,touchmove:ke,touchend:ke,touchcancel:ke},Gt={},pn=!1;function Lr(t,e,i){return e==="touchstart"&&kr(),fn[e]?(i=fn[e].bind(this,i),t.addEventListener(si[e],i,!1),i):(console.warn("wrong event specified:",e),w)}function br(t,e,i){if(!si[e]){console.warn("wrong event specified:",e);return}t.removeEventListener(si[e],i,!1)}function xr(t){Gt[t.pointerId]=t}function Ar(t){Gt[t.pointerId]&&(Gt[t.pointerId]=t)}function mn(t){delete Gt[t.pointerId]}function kr(){pn||(document.addEventListener(hn,xr,!0),document.addEventListener(cn,Ar,!0),document.addEventListener(dn,mn,!0),document.addEventListener(un,mn,!0),pn=!0)}function ke(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 Mr(t,e){e.MSPOINTER_TYPE_TOUCH&&e.pointerType===e.MSPOINTER_TYPE_TOUCH&&nt(e),ke(t,e)}function Er(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 Pr=200;function Tr(t,e){t.addEventListener("dblclick",e);var i=0,o;function s(h){if(h.detail!==1){o=h.detail;return}if(!(h.pointerType==="mouse"||h.sourceCapabilities&&!h.sourceCapabilities.firesTouchEvents)){var f=wn(h);if(!(f.some(function(y){return y instanceof HTMLLabelElement&&y.attributes.for})&&!f.some(function(y){return y instanceof HTMLInputElement||y instanceof HTMLSelectElement}))){var m=Date.now();m-i<=Pr?(o++,o===2&&e(Er(h))):o=1,i=m}}}return t.addEventListener("click",s),{dblclick:e,simDblclick:s}}function Cr(t,e){t.removeEventListener("dblclick",e.dblclick),t.removeEventListener("click",e.simDblclick)}var ai=Pe(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),se=Pe(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),_n=se==="webkitTransition"||se==="OTransition"?se+"End":"transitionend";function gn(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 G(t,e,i){var o=document.createElement(t);return o.className=e||"",i&&i.appendChild(o),o}function K(t){var e=t.parentNode;e&&e.removeChild(t)}function Me(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 li(t,e){if(t.classList!==void 0)return t.classList.contains(e);var i=Ee(t);return i.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(i)}function R(t,e){if(t.classList!==void 0)for(var i=E(e),o=0,s=i.length;o<s;o++)t.classList.add(i[o]);else if(!li(t,e)){var h=Ee(t);hi(t,(h?h+" ":"")+e)}}function J(t,e){t.classList!==void 0?t.classList.remove(e):hi(t,P((" "+Ee(t)+" ").replace(" "+e+" "," ")))}function hi(t,e){t.className.baseVal===void 0?t.className=e:t.className.baseVal=e}function Ee(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&&Sr(t,e)}function Sr(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 Pe(t){for(var e=document.documentElement.style,i=0;i<t.length;i++)if(t[i]in e)return t[i];return!1}function Ot(t,e,i){var o=e||new B(0,0);t.style[ai]=(M.ie3d?"translate("+o.x+"px,"+o.y+"px)":"translate3d("+o.x+"px,"+o.y+"px,0)")+(i?" scale("+i+")":"")}function Q(t,e){t._leaflet_pos=e,M.any3d?Ot(t,e):(t.style.left=e.x+"px",t.style.top=e.y+"px")}function Rt(t){return t._leaflet_pos||new B(0,0)}var le,he,ci;if("onselectstart"in document)le=function(){O(window,"selectstart",nt)},he=function(){Y(window,"selectstart",nt)};else{var ce=Pe(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);le=function(){if(ce){var t=document.documentElement.style;ci=t[ce],t[ce]="none"}},he=function(){ce&&(document.documentElement.style[ce]=ci,ci=void 0)}}function di(){O(window,"dragstart",nt)}function ui(){Y(window,"dragstart",nt)}var Te,fi;function pi(t){for(;t.tabIndex===-1;)t=t.parentNode;t.style&&(Ce(),Te=t,fi=t.style.outlineStyle,t.style.outlineStyle="none",O(window,"keydown",Ce))}function Ce(){Te&&(Te.style.outlineStyle=fi,Te=void 0,fi=void 0,Y(window,"keydown",Ce))}function vn(t){do t=t.parentNode;while((!t.offsetWidth||!t.offsetHeight)&&t!==document.body);return t}function mi(t){var e=t.getBoundingClientRect();return{x:e.width/t.offsetWidth||1,y:e.height/t.offsetHeight||1,boundingClientRect:e}}var Dr={__proto__:null,TRANSFORM:ai,TRANSITION:se,TRANSITION_END:_n,get:gn,getStyle:ae,create:G,remove:K,empty:Me,toFront:Vt,toBack:Wt,hasClass:li,addClass:R,removeClass:J,setClass:hi,getClass:Ee,setOpacity:mt,testProp:Pe,setTransform:Ot,setPosition:Q,getPosition:Rt,get disableTextSelection(){return le},get enableTextSelection(){return he},disableImageDrag:di,enableImageDrag:ui,preventOutline:pi,restoreOutline:Ce,getSizedParentNode:vn,getScale:mi};function O(t,e,i,o){if(e&&typeof e=="object")for(var s in e)gi(t,s,e[s],i);else{e=E(e);for(var h=0,f=e.length;h<f;h++)gi(t,e[h],i,o)}return this}var Lt="_leaflet_events";function Y(t,e,i,o){if(arguments.length===1)yn(t),delete t[Lt];else if(e&&typeof e=="object")for(var s in e)vi(t,s,e[s],i);else if(e=E(e),arguments.length===2)yn(t,function(m){return V(e,m)!==-1});else for(var h=0,f=e.length;h<f;h++)vi(t,e[h],i,o);return this}function yn(t,e){for(var i in t[Lt]){var o=i.split(/\d/)[0];(!e||e(o))&&vi(t,o,null,null,i)}}var _i={mouseenter:"mouseover",mouseleave:"mouseout",wheel:!("onwheel"in window)&&"mousewheel"};function gi(t,e,i,o){var s=e+p(i)+(o?"_"+p(o):"");if(t[Lt]&&t[Lt][s])return this;var h=function(m){return i.call(o||t,m||window.event)},f=h;!M.touchNative&&M.pointer&&e.indexOf("touch")===0?h=Lr(t,e,h):M.touch&&e==="dblclick"?h=Tr(t,h):"addEventListener"in t?e==="touchstart"||e==="touchmove"||e==="wheel"||e==="mousewheel"?t.addEventListener(_i[e]||e,h,M.passiveEvents?{passive:!1}:!1):e==="mouseenter"||e==="mouseleave"?(h=function(m){m=m||window.event,wi(t,m)&&f(m)},t.addEventListener(_i[e],h,!1)):t.addEventListener(e,f,!1):t.attachEvent("on"+e,h),t[Lt]=t[Lt]||{},t[Lt][s]=h}function vi(t,e,i,o,s){s=s||e+p(i)+(o?"_"+p(o):"");var h=t[Lt]&&t[Lt][s];if(!h)return this;!M.touchNative&&M.pointer&&e.indexOf("touch")===0?br(t,e,h):M.touch&&e==="dblclick"?Cr(t,h):"removeEventListener"in t?t.removeEventListener(_i[e]||e,h,!1):t.detachEvent("on"+e,h),t[Lt][s]=null}function Ut(t){return t.stopPropagation?t.stopPropagation():t.originalEvent?t.originalEvent._stopped=!0:t.cancelBubble=!0,this}function yi(t){return gi(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 Zt(t){return nt(t),Ut(t),this}function wn(t){if(t.composedPath)return t.composedPath();for(var e=[],i=t.target;i;)e.push(i),i=i.parentNode;return e}function Ln(t,e){if(!e)return new B(t.clientX,t.clientY);var i=mi(e),o=i.boundingClientRect;return new B((t.clientX-o.left)/i.x-e.clientLeft,(t.clientY-o.top)/i.y-e.clientTop)}var Ir=M.linux&&M.chrome?window.devicePixelRatio:M.mac?window.devicePixelRatio*3:window.devicePixelRatio>0?2*window.devicePixelRatio:1;function bn(t){return M.edge?t.wheelDeltaY/2:t.deltaY&&t.deltaMode===0?-t.deltaY/Ir: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 wi(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 zr={__proto__:null,on:O,off:Y,stopPropagation:Ut,disableScrollPropagation:yi,disableClickPropagation:de,preventDefault:nt,stop:Zt,getPropagationPath:wn,getMousePosition:Ln,getWheelDelta:bn,isExternalTarget:wi,addListener:O,removeListener:Y},xn=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=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(),Q(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)}}),H=ne.extend({options:{crs:ti,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=k(this,e),this._handlers=[],this._layers={},this._zoomBoundLayers={},this._sizeChanged=!0,this._initContainer(t),this._initLayout(),this._onResize=l(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&&M.any3d&&!M.mobileOpera&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),O(this._proxy,_n,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||(M.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom+t,e)},zoomOut:function(t,e){return t=t||(M.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom-t,e)},setZoomAround:function(t,e,i){var o=this.getZoomScale(e),s=this.getSize().divideBy(2),h=t instanceof B?t:this.latLngToContainerPoint(t),f=h.subtract(s).multiplyBy(1-1/o),m=this.containerPointToLatLng(s.add(f));return this.setView(m,e,{zoom:i})},_getBoundsCenterZoom:function(t,e){e=e||{},t=t.getBounds?t.getBounds():X(t);var i=D(e.paddingTopLeft||e.padding||[0,0]),o=D(e.paddingBottomRight||e.padding||[0,0]),s=this.getBoundsZoom(t,!1,i.add(o));if(s=typeof e.maxZoom=="number"?Math.min(e.maxZoom,s):s,s===1/0)return{center:t.getCenter(),zoom:s};var h=o.subtract(i).divideBy(2),f=this.project(t.getSouthWest(),s),m=this.project(t.getNorthEast(),s),y=this.unproject(f.add(m).divideBy(2).add(h),s);return{center:y,zoom:s}},fitBounds:function(t,e){if(t=X(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=D(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 xn,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),e.noMoveStart||this.fire("movestart"),e.animate!==!1){R(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||!M.any3d)return this.setView(t,e,i);this._stop();var o=this.project(this.getCenter()),s=this.project(t),h=this.getSize(),f=this._zoom;t=N(t),e=e===void 0?f:e;var m=Math.max(h.x,h.y),y=m*this.getZoomScale(f,e),b=s.distanceTo(o)||1,A=1.42,T=A*A;function U($){var Fe=$?-1:1,bs=$?y:m,xs=y*y-m*m+Fe*T*T*b*b,As=2*bs*T*b,Si=xs/As,no=Math.sqrt(Si*Si+1)-Si,ks=no<1e-9?-18:Math.log(no);return ks}function st($){return(Math.exp($)-Math.exp(-$))/2}function et($){return(Math.exp($)+Math.exp(-$))/2}function gt($){return st($)/et($)}var ct=U(0);function Xt($){return m*(et(ct)/et(ct+A*$))}function vs($){return m*(et(ct)*gt(ct+A*$)-st(ct))/T}function ys($){return 1-Math.pow(1-$,1.5)}var ws=Date.now(),eo=(U(1)-ct)/A,Ls=i.duration?1e3*i.duration:1e3*eo*.8;function io(){var $=(Date.now()-ws)/Ls,Fe=ys($)*eo;$<=1?(this._flyToFrame=rt(io,this),this._move(this.unproject(o.add(s.subtract(o).multiplyBy(vs(Fe)/b)),f),this.getScaleZoom(m/Xt(Fe),f),{flyTo:!0})):this._move(t,e)._moveEnd(!0)}return this._moveStart(!0,i.noMoveStart),io.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=X(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,X(t));return i.equals(o)||this.panTo(o,e),this._enforcingBounds=!1,this},panInside:function(t,e){e=e||{};var i=D(e.paddingTopLeft||e.padding||[0,0]),o=D(e.paddingBottomRight||e.padding||[0,0]),s=this.project(this.getCenter()),h=this.project(t),f=this.getPixelBounds(),m=lt([f.min.add(i),f.max.subtract(o)]),y=m.getSize();if(!m.contains(h)){this._enforcingBounds=!0;var b=h.subtract(m.getCenter()),A=m.extend(h).getSize().subtract(y);s.x+=b.x<0?-A.x:A.x,s.y+=b.y<0?-A.y:A.y,this.panTo(this.unproject(s),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(),s=i.divideBy(2).round(),h=o.subtract(s);return!h.x&&!h.y?this:(t.animate&&t.pan?this.panBy(h):(t.pan&&this._rawPanBy(h),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(l(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=l(this._handleGeolocationResponse,this),i=l(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 W(e,i),s=o.toBounds(t.coords.accuracy*2),h=this._locateOptions;if(h.setView){var f=this.getBoundsZoom(s);this.setView(o,h.maxZoom?Math.min(f,h.maxZoom):f)}var m={latlng:o,bounds:s,timestamp:t.timestamp};for(var y in t.coords)typeof t.coords[y]=="number"&&(m[y]=t.coords[y]);this.fire("locationfound",m)}},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(),K(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)K(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=G("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=X(t),i=D(i||[0,0]);var o=this.getZoom()||0,s=this.getMinZoom(),h=this.getMaxZoom(),f=t.getNorthWest(),m=t.getSouthEast(),y=this.getSize().subtract(i),b=lt(this.project(m,o),this.project(f,o)).getSize(),A=M.any3d?this.options.zoomSnap:1,T=y.x/b.x,U=y.y/b.y,st=e?Math.max(T,U):Math.min(T,U);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(s,Math.min(h,o))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new B(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(D(t),e)},layerPointToLatLng:function(t){var e=D(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(X(t))},distance:function(t,e){return this.options.crs.distance(N(t),N(e))},containerPointToLayerPoint:function(t){return D(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return D(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var e=this.containerPointToLayerPoint(D(t));return this.layerPointToLatLng(e)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(N(t)))},mouseEventToContainerPoint:function(t){return Ln(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=gn(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=p(e)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&M.any3d,R(t,"leaflet-container"+(M.touch?" leaflet-touch":"")+(M.retina?" leaflet-retina":"")+(M.ielt9?" leaflet-oldie":"")+(M.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),Q(this._mapPane,new B(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(R(t.markerPane,"leaflet-zoom-hide"),R(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,e,i){Q(this._mapPane,new B(0,0));var o=!this._loaded;this._loaded=!0,e=this._limitZoom(e),this.fire("viewprereset");var s=this._zoom!==e;this._moveStart(s,i)._move(t,e)._moveEnd(s),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 s=this._zoom!==e;return this._zoom=e,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),o?i&&i.pinch&&this.fire("zoom",i):((s||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){Q(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[p(this._container)]=this;var e=t?Y: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),M.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,s=e==="mouseout"||e==="mouseover",h=t.target||t.srcElement,f=!1;h;){if(o=this._targets[p(h)],o&&(e==="click"||e==="preclick")&&this._draggableMoved(o)){f=!0;break}if(o&&o.listens(e,!0)&&(s&&!wi(h,t)||(i.push(o),s))||h===this._container)break;h=h.parentNode}return!i.length&&!f&&!s&&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"&&pi(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 s=this._findEventTargets(t,e);if(i){for(var h=[],f=0;f<i.length;f++)i[f].listens(e,!0)&&h.push(i[f]);s=h.concat(s)}if(s.length){e==="contextmenu"&&nt(t);var m=s[0],y={originalEvent:t};if(t.type!=="keypress"&&t.type!=="keydown"&&t.type!=="keyup"){var b=m.getLatLng&&(!m._radius||m._radius<=10);y.containerPoint=b?this.latLngToContainerPoint(m.getLatLng()):this.mouseEventToContainerPoint(t),y.layerPoint=this.containerPointToLayerPoint(y.containerPoint),y.latlng=b?m.getLatLng():this.layerPointToLatLng(y.layerPoint)}for(f=0;f<s.length;f++)if(s[f].fire(e,y,!0),y.originalEvent._stopped||s[f].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 B(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),s=this.getSize().divideBy(2),h=new j(o.subtract(s),o.add(s)),f=this._getBoundsOffset(h,i,e);return Math.abs(f.x)<=1&&Math.abs(f.y)<=1?t:this.unproject(o.add(f),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)),s=o.min.subtract(t.min),h=o.max.subtract(t.max),f=this._rebound(s.x,-h.x),m=this._rebound(s.y,-h.y);return new B(f,m)},_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=M.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(){J(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=G("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",function(e){var i=ai,o=this._proxy.style[i];Ot(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(){K(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var t=this.getCenter(),e=this.getZoom();Ot(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),s=this._getCenterOffset(t)._divideBy(1-1/o);return i.animate!==!0&&!this.getSize().contains(s)?!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,R(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(l(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&J(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 Br(t,e){return new H(t,e)}var vt=pt.extend({options:{position:"topright"},initialize:function(t){k(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 R(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?(K(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(t){this._map&&t&&t.screenX>0&&t.screenY>0&&this._map.getContainer().focus()}}),ue=function(t){return new vt(t)};H.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=G("div",e+"control-container",this._container);function o(s,h){var f=e+s+" "+e+h;t[s+h]=G("div",f,i)}o("top","left"),o("top","right"),o("bottom","left"),o("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)K(this._controlCorners[t]);K(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var An=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){k(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(p(t));return e&&this._layers.splice(this._layers.indexOf(e),1),this._map?this._update():this},expand:function(){R(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?(R(this._section,"leaflet-control-layers-scrollbar"),this._section.style.height=t+"px"):J(this._section,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return J(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var t="leaflet-control-layers",e=this._container=G("div",t),i=this.options.collapsed;e.setAttribute("aria-haspopup",!0),de(e),yi(e);var o=this._section=G("section",t+"-list");i&&(this._map.on("click",this.collapse,this),O(e,{mouseenter:this._expandSafely,mouseleave:this.collapse},this));var s=this._layersLink=G("a",t+"-toggle",e);s.href="#",s.title="Layers",s.setAttribute("role","button"),O(s,{keydown:function(h){h.keyCode===13&&this._expandSafely()},click:function(h){nt(h),this._expandSafely()}},this),i||this.expand(),this._baseLayersList=G("div",t+"-base",o),this._separator=G("div",t+"-separator",o),this._overlaysList=G("div",t+"-overlays",o),e.appendChild(o)},_getLayer:function(t){for(var e=0;e<this._layers.length;e++)if(this._layers[e]&&p(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(l(function(o,s){return this.options.sortFunction(o.layer,s.layer,o.name,s.name)},this)),this.options.autoZIndex&&t.setZIndex&&(this._lastZIndex++,t.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;Me(this._baseLayersList),Me(this._overlaysList),this._layerControlInputs=[];var t,e,i,o,s=0;for(i=0;i<this._layers.length;i++)o=this._layers[i],this._addItem(o),e=e||o.overlay,t=t||!o.overlay,s+=o.overlay?0:1;return this.options.hideSingleBase&&(t=t&&s>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(p(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_"+p(this),i),this._layerControlInputs.push(o),o.layerId=p(t.layer),O(o,"click",this._onInputClick,this);var s=document.createElement("span");s.innerHTML=" "+t.name;var h=document.createElement("span");e.appendChild(h),h.appendChild(o),h.appendChild(s);var f=t.overlay?this._overlaysList:this._baseLayersList;return f.appendChild(e),this._checkDisabledLayers(),e},_onInputClick:function(){if(!this._preventClick){var t=this._layerControlInputs,e,i,o=[],s=[];this._handlingClick=!0;for(var h=t.length-1;h>=0;h--)e=t[h],i=this._getLayer(e.layerId).layer,e.checked?o.push(i):e.checked||s.push(i);for(h=0;h<s.length;h++)this._map.hasLayer(s[h])&&this._map.removeLayer(s[h]);for(h=0;h<o.length;h++)this._map.hasLayer(o[h])||this._map.addLayer(o[h]);this._handlingClick=!1,this._refocusOnMap()}},_checkDisabledLayers:function(){for(var t=this._layerControlInputs,e,i,o=this._map.getZoom(),s=t.length-1;s>=0;s--)e=t[s],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(){Y(t,"click",nt),e._preventClick=!1})}}),Or=function(t,e,i){return new An(t,e,i)},Li=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=G("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,s){var h=G("a",i,o);return h.innerHTML=t,h.href="#",h.title=e,h.setAttribute("role","button"),h.setAttribute("aria-label",e),de(h),O(h,"click",Zt),O(h,"click",s,this),O(h,"click",this._refocusOnMap,this),h},_updateDisabled:function(){var t=this._map,e="leaflet-disabled";J(this._zoomInButton,e),J(this._zoomOutButton,e),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||t._zoom===t.getMinZoom())&&(R(this._zoomOutButton,e),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||t._zoom===t.getMaxZoom())&&(R(this._zoomInButton,e),this._zoomInButton.setAttribute("aria-disabled","true"))}});H.mergeOptions({zoomControl:!0}),H.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new Li,this.addControl(this.zoomControl))});var Rr=function(t){return new Li(t)},kn=vt.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var e="leaflet-control-scale",i=G("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=G("div",e,i)),t.imperial&&(this._iScale=G("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,s;e>5280?(i=e/5280,o=this._getRoundNum(i),this._updateScale(this._iScale,o+" mi",o/i)):(s=this._getRoundNum(e),this._updateScale(this._iScale,s+" ft",s/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}}),Ur=function(t){return new kn(t)},Zr='<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>',bi=vt.extend({options:{position:"bottomright",prefix:'<a href="https://leafletjs.com" title="A JavaScript library for interactive maps">'+(M.inlineSvg?Zr+" ":"")+"Leaflet</a>"},initialize:function(t){k(this,t),this._attributions={}},onAdd:function(t){t.attributionControl=this,this._container=G("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> ')}}});H.mergeOptions({attributionControl:!0}),H.addInitHook(function(){this.options.attributionControl&&new bi().addTo(this)});var Nr=function(t){return new bi(t)};vt.Layers=An,vt.Zoom=Li,vt.Scale=kn,vt.Attribution=bi,ue.layers=Or,ue.zoom=Rr,ue.scale=Ur,ue.attribution=Nr;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 Hr={Events:ft},Mn=M.touch?"touchstart mousedown":"mousedown",Dt=ne.extend({options:{clickTolerance:3},initialize:function(t,e,i,o){k(this,o),this._element=t,this._dragStartTarget=e||t,this._preventOutline=i},enable:function(){this._enabled||(O(this._dragStartTarget,Mn,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(Dt._dragging===this&&this.finishDrag(!0),Y(this._dragStartTarget,Mn,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(this._enabled&&(this._moved=!1,!li(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&&pi(this._element),di(),le(),!this._moving)){this.fire("down");var e=t.touches?t.touches[0]:t,i=vn(this._element);this._startPoint=new B(e.clientX,e.clientY),this._startPos=Rt(this._element),this._parentScale=mi(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 B(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,R(document.body,"leaflet-dragging"),this._lastTarget=t.target||t.srcElement,window.SVGElementInstance&&this._lastTarget instanceof window.SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),R(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),Q(this._element,this._newPos),this.fire("drag",t)},_onUp:function(){this._enabled&&this.finishDrag()},finishDrag:function(t){J(document.body,"leaflet-dragging"),this._lastTarget&&(J(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null),Y(document,"mousemove touchmove",this._onMove,this),Y(document,"mouseup touchend touchcancel",this._onUp,this),ui(),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 En(t,e,i){var o,s=[1,4,2,8],h,f,m,y,b,A,T,U;for(h=0,A=t.length;h<A;h++)t[h]._code=Nt(t[h],e);for(m=0;m<4;m++){for(T=s[m],o=[],h=0,A=t.length,f=A-1;h<A;f=h++)y=t[h],b=t[f],y._code&T?b._code&T||(U=Se(b,y,T,e,i),U._code=Nt(U,e),o.push(U)):(b._code&T&&(U=Se(b,y,T,e,i),U._code=Nt(U,e),o.push(U)),o.push(y));t=o}return t}function Pn(t,e){var i,o,s,h,f,m,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 T=N([0,0]),U=X(t),st=U.getNorthWest().distanceTo(U.getSouthWest())*U.getNorthEast().distanceTo(U.getNorthWest());st<1700&&(T=xi(t));var et=t.length,gt=[];for(i=0;i<et;i++){var ct=N(t[i]);gt.push(e.project(N([ct.lat-T.lat,ct.lng-T.lng])))}for(m=y=b=0,i=0,o=et-1;i<et;o=i++)s=gt[i],h=gt[o],f=s.y*h.x-h.y*s.x,y+=(s.x+h.x)*f,b+=(s.y+h.y)*f,m+=f*3;m===0?A=gt[0]:A=[y/m,b/m];var Xt=e.unproject(D(A));return N([Xt.lat+T.lat,Xt.lng+T.lng])}function xi(t){for(var e=0,i=0,o=0,s=0;s<t.length;s++){var h=N(t[s]);e+=h.lat,i+=h.lng,o++}return N([e/o,i/o])}var Fr={__proto__:null,clipPolygon:En,polygonCenter:Pn,centroid:xi};function Tn(t,e){if(!e||!t.length)return t.slice();var i=e*e;return t=Wr(t,i),t=Vr(t,i),t}function Cn(t,e,i){return Math.sqrt(fe(t,e,i,!0))}function Gr(t,e,i){return fe(t,e,i)}function Vr(t,e){var i=t.length,o=typeof Uint8Array!="undefined"?Uint8Array:Array,s=new o(i);s[0]=s[i-1]=1,Ai(t,s,e,0,i-1);var h,f=[];for(h=0;h<i;h++)s[h]&&f.push(t[h]);return f}function Ai(t,e,i,o,s){var h=0,f,m,y;for(m=o+1;m<=s-1;m++)y=fe(t[m],t[o],t[s],!0),y>h&&(f=m,h=y);h>i&&(e[f]=1,Ai(t,e,i,o,f),Ai(t,e,i,f,s))}function Wr(t,e){for(var i=[t[0]],o=1,s=0,h=t.length;o<h;o++)Yr(t[o],t[s])>e&&(i.push(t[o]),s=o);return s<h-1&&i.push(t[h-1]),i}var Sn;function Dn(t,e,i,o,s){var h=o?Sn:Nt(t,i),f=Nt(e,i),m,y,b;for(Sn=f;;){if(!(h|f))return[t,e];if(h&f)return!1;m=h||f,y=Se(t,e,m,i,s),b=Nt(y,i),m===h?(t=y,h=b):(e=y,f=b)}}function Se(t,e,i,o,s){var h=e.x-t.x,f=e.y-t.y,m=o.min,y=o.max,b,A;return i&8?(b=t.x+h*(y.y-t.y)/f,A=y.y):i&4?(b=t.x+h*(m.y-t.y)/f,A=m.y):i&2?(b=y.x,A=t.y+f*(y.x-t.x)/h):i&1&&(b=m.x,A=t.y+f*(m.x-t.x)/h),new B(b,A,s)}function Nt(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 Yr(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 s=e.x,h=e.y,f=i.x-s,m=i.y-h,y=f*f+m*m,b;return y>0&&(b=((t.x-s)*f+(t.y-h)*m)/y,b>1?(s=i.x,h=i.y):b>0&&(s+=f*b,h+=m*b)),f=t.x-s,m=t.y-h,o?f*f+m*m:new B(s,h)}function _t(t){return!S(t[0])||typeof t[0][0]!="object"&&typeof t[0][0]!="undefined"}function In(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),_t(t)}function zn(t,e){var i,o,s,h,f,m,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]),T=X(t),U=T.getNorthWest().distanceTo(T.getSouthWest())*T.getNorthEast().distanceTo(T.getNorthWest());U<1700&&(A=xi(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,h=0;i<st-1;i++)if(f=et[i],m=et[i+1],s=f.distanceTo(m),h+=s,h>o){y=(h-o)/s,b=[m.x-y*(m.x-f.x),m.y-y*(m.y-f.y)];break}var ct=e.unproject(D(b));return N([ct.lat+A.lat,ct.lng+A.lng])}var qr={__proto__:null,simplify:Tn,pointToSegmentDistance:Cn,closestPointOnSegment:Gr,clipSegment:Dn,_getEdgeIntersection:Se,_getBitCode:Nt,_sqClosestPointOnSegment:fe,isFlat:_t,_flat:In,polylineCenter:zn},ki={project:function(t){return new B(t.lng,t.lat)},unproject:function(t){return new W(t.y,t.x)},bounds:new j([-180,-90],[180,90])},Mi={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,s=this.R_MINOR/i,h=Math.sqrt(1-s*s),f=h*Math.sin(o),m=Math.tan(Math.PI/4-o/2)/Math.pow((1-f)/(1+f),h/2);return o=-i*Math.log(Math.max(m,1e-10)),new B(t.lng*e*i,o)},unproject:function(t){for(var e=180/Math.PI,i=this.R,o=this.R_MINOR/i,s=Math.sqrt(1-o*o),h=Math.exp(-t.y/i),f=Math.PI/2-2*Math.atan(h),m=0,y=.1,b;m<15&&Math.abs(y)>1e-7;m++)b=s*Math.sin(f),b=Math.pow((1-b)/(1+b),s/2),y=Math.PI/2-2*Math.atan(h*b)-f,f+=y;return new W(f*e,t.x*e/i)}},jr={__proto__:null,LonLat:ki,Mercator:Mi,SphericalMercator:Qe},Kr=n({},St,{code:"EPSG:3395",projection:Mi,transformation:(function(){var t=.5/(Math.PI*Mi.R);return oe(t,.5,-t,.5)})()}),Bn=n({},St,{code:"EPSG:4326",projection:ki,transformation:oe(1/180,1,-1/180,.5)}),Jr=n({},kt,{projection:ki,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});kt.Earth=St,kt.EPSG3395=Kr,kt.EPSG3857=ti,kt.EPSG900913=ir,kt.EPSG4326=Bn,kt.Simple=Jr;var yt=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[p(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[p(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})}}});H.include({addLayer:function(t){if(!t._layerAdd)throw new Error("The provided object is not a Layer.");var e=p(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=p(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 p(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?S(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[p(t)]=t,this._updateZoomLevels())},_removeZoomLimit:function(t){var e=p(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 s=this._zoomBoundLayers[o].options;t=s.minZoom===void 0?t:Math.min(t,s.minZoom),e=s.maxZoom===void 0?e:Math.max(e,s.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){k(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 p(t)}}),Xr=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}}),Qr=function(t,e){return new Mt(t,e)},qt=pt.extend({options:{popupAnchor:[0,0],tooltipAnchor:[0,0],crossOrigin:!1},initialize:function(t){k(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 s=D(o),h=D(e==="shadow"&&i.shadowAnchor||i.iconAnchor||s&&s.divideBy(2,!0));t.className="leaflet-marker-"+e+" "+(i.className||""),h&&(t.style.marginLeft=-h.x+"px",t.style.marginTop=-h.y+"px"),s&&(t.style.width=s.x+"px",t.style.height=s.y+"px")},_createImg:function(t,e){return e=e||document.createElement("img"),e.src=t,e},_getIconUrl:function(t){return M.retina&&this.options[t+"RetinaUrl"]||this.options[t+"Url"]}});function $r(t){return new qt(t)}var pe=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 pe.imagePath!="string"&&(pe.imagePath=this._detectIconPath()),(this.options.imagePath||pe.imagePath)+qt.prototype._getIconUrl.call(this,t)},_stripUrl:function(t){var e=function(i,o,s){var h=o.exec(i);return h&&h[s]};return t=e(t,/^url\((['"])?(.+)\1\)$/,2),t&&e(t,/^(.*)marker-icon\.png$/,1)},_detectIconPath:function(){var t=G("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):""}}),On=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(),R(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&&J(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,s=this._marker.options.autoPanPadding,h=Rt(e._icon),f=i.getPixelBounds(),m=i.getPixelOrigin(),y=lt(f.min._subtract(m).add(s),f.max._subtract(m).subtract(s));if(!y.contains(h)){var b=D((Math.max(y.max.x,h.x)-y.max.x)/(f.max.x-y.max.x)-(Math.min(y.min.x,h.x)-y.min.x)/(f.min.x-y.min.x),(Math.max(y.max.y,h.y)-y.max.y)/(f.max.y-y.max.y)-(Math.min(y.min.y,h.y)-y.min.y)/(f.min.y-y.min.y)).multiplyBy(o);i.panBy(b,{animate:!1}),this._draggable._newPos._add(b),this._draggable._startPos._add(b),Q(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),s=e._map.layerPointToLatLng(o);i&&Q(i,o),e._latlng=s,t.latlng=s,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)}}),De=yt.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){k(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||"")),R(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 s=t.icon.createShadow(this._shadow),h=!1;s!==this._shadow&&(this._removeShadow(),h=!0),s&&(R(s,e),s.alt=""),this._shadow=s,t.opacity<1&&this._updateOpacity(),o&&this.getPane().appendChild(this._icon),this._initInteraction(),s&&h&&this.getPane(t.shadowPane).appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&Y(this._icon,"focus",this._panOnFocus,this),K(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&K(this._shadow),this._shadow=null},_setPos:function(t){this._icon&&Q(this._icon,t),this._shadow&&Q(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&&(R(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),On)){var t=this.options.draggable;this.dragging&&(t=this.dragging.enabled(),this.dragging.disable()),this.dragging=new On(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?D(e.iconSize):D(0,0),o=e.iconAnchor?D(e.iconAnchor):D(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 ts(t,e){return new De(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 k(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)}}),Ie=It.extend({options:{fill:!0,radius:10},initialize:function(t,e){k(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 es(t,e){return new Ie(t,e)}var Ei=Ie.extend({initialize:function(t,e,i){if(typeof e=="number"&&(e=n({},i,{radius:e})),k(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 s=Math.PI/180,h=this._mRadius/St.R/s,f=i.project([e+h,t]),m=i.project([e-h,t]),y=f.add(m).divideBy(2),b=i.unproject(y).lat,A=Math.acos((Math.cos(h*s)-Math.sin(e*s)*Math.sin(b*s))/(Math.cos(e*s)*Math.cos(b*s)))/s;(isNaN(A)||A===0)&&(A=h/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-f.y}else{var T=o.unproject(o.project(this._latlng).subtract([this._mRadius,0]));this._point=i.latLngToLayerPoint(this._latlng),this._radius=this._point.x-i.latLngToLayerPoint(T).x}this._updateBounds()}});function is(t,e,i){return new Ei(t,e,i)}var Et=It.extend({options:{smoothFactor:1,noClip:!1},initialize:function(t,e){k(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,s,h,f=0,m=this._parts.length;f<m;f++)for(var y=this._parts[f],b=1,A=y.length;b<A;b++){s=y[b-1],h=y[b];var T=o(t,s,h,!0);T<e&&(e=T,i=o(t,s,h))}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 zn(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,s=t.length;o<s;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 B(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 W,s=t.length,h,f;if(o){for(f=[],h=0;h<s;h++)f[h]=this._map.latLngToLayerPoint(t[h]),i.extend(f[h]);e.push(f)}else for(h=0;h<s;h++)this._projectLatlngs(t[h],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,s,h,f,m,y;for(i=0,s=0,h=this._rings.length;i<h;i++)for(y=this._rings[i],o=0,f=y.length;o<f-1;o++)m=Dn(y[o],y[o+1],t,o,!0),m&&(e[s]=e[s]||[],e[s].push(m[0]),(m[1]!==y[o+1]||o===f-2)&&(e[s].push(m[1]),s++))}},_simplifyPoints:function(){for(var t=this._parts,e=this.options.smoothFactor,i=0,o=t.length;i<o;i++)t[i]=Tn(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,s,h,f,m,y=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(i=0,h=this._parts.length;i<h;i++)for(m=this._parts[i],o=0,f=m.length,s=f-1;o<f;s=o++)if(!(!e&&o===0)&&Cn(t,m[s],m[o])<=y)return!0;return!1}});function ns(t,e){return new Et(t,e)}Et._flat=In;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 Pn(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 W&&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 B(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,s=this._rings.length,h;o<s;o++)h=En(this._rings[o],t,!0),h.length&&this._parts.push(h)}},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(t){var e=!1,i,o,s,h,f,m,y,b;if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(h=0,y=this._parts.length;h<y;h++)for(i=this._parts[h],f=0,b=i.length,m=b-1;f<b;m=f++)o=i[f],s=i[m],o.y>t.y!=s.y>t.y&&t.x<(s.x-o.x)*(t.y-o.y)/(s.y-o.y)+o.x&&(e=!e);return e||Et.prototype._containsPoint.call(this,t,!0)}});function os(t,e){return new jt(t,e)}var Pt=Mt.extend({initialize:function(t,e){k(this,e),this._layers={},t&&this.addData(t)},addData:function(t){var e=S(t)?t:t.features,i,o,s;if(e){for(i=0,o=e.length;i<o;i++)s=e[i],(s.geometries||s.geometry||s.features||s.coordinates)&&this.addData(s);return this}var h=this.options;if(h.filter&&!h.filter(t))return this;var f=ze(t,h);return f?(f.feature=Re(t),f.defaultOptions=f.options,this.resetStyle(f),h.onEachFeature&&h.onEachFeature(t,f),this.addLayer(f)):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 ze(t,e){var i=t.type==="Feature"?t.geometry:t,o=i?i.coordinates:null,s=[],h=e&&e.pointToLayer,f=e&&e.coordsToLatLng||Pi,m,y,b,A;if(!o&&!i)return null;switch(i.type){case"Point":return m=f(o),Rn(h,t,m,e);case"MultiPoint":for(b=0,A=o.length;b<A;b++)m=f(o[b]),s.push(Rn(h,t,m,e));return new Mt(s);case"LineString":case"MultiLineString":return y=Be(o,i.type==="LineString"?0:1,f),new Et(y,e);case"Polygon":case"MultiPolygon":return y=Be(o,i.type==="Polygon"?1:2,f),new jt(y,e);case"GeometryCollection":for(b=0,A=i.geometries.length;b<A;b++){var T=ze({geometry:i.geometries[b],type:"Feature",properties:t.properties},e);T&&s.push(T)}return new Mt(s);case"FeatureCollection":for(b=0,A=i.features.length;b<A;b++){var U=ze(i.features[b],e);U&&s.push(U)}return new Mt(s);default:throw new Error("Invalid GeoJSON object.")}}function Rn(t,e,i,o){return t?t(e,i):new De(i,o&&o.markersInheritOptions&&o)}function Pi(t){return new W(t[1],t[0],t[2])}function Be(t,e,i){for(var o=[],s=0,h=t.length,f;s<h;s++)f=e?Be(t[s],e-1,i):(i||Pi)(t[s]),o.push(f);return o}function Ti(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 Oe(t,e,i,o){for(var s=[],h=0,f=t.length;h<f;h++)s.push(e?Oe(t[h],_t(t[h])?0:e-1,i,o):Ti(t[h],o));return!e&&i&&s.length>0&&s.push(s[0].slice()),s}function Kt(t,e){return t.feature?n({},t.feature,{geometry:e}):Re(e)}function Re(t){return t.type==="Feature"||t.type==="FeatureCollection"?t:{type:"Feature",properties:{},geometry:t}}var Ci={toGeoJSON:function(t){return Kt(this,{type:"Point",coordinates:Ti(this.getLatLng(),t)})}};De.include(Ci),Ei.include(Ci),Ie.include(Ci),Et.include({toGeoJSON:function(t){var e=!_t(this._latlngs),i=Oe(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=Oe(this._latlngs,i?2:e?1:0,!0,t);return e||(o=[o]),Kt(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)}),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(s){if(s.toGeoJSON){var h=s.toGeoJSON(t);if(i)o.push(h.geometry);else{var f=Re(h);f.type==="FeatureCollection"?o.push.apply(o,f.features):o.push(f)}}}),i?Kt(this,{geometries:o,type:"GeometryCollection"}):{type:"FeatureCollection",features:o}}});function Un(t,e){return new Pt(t,e)}var rs=Un,Ue=yt.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(t,e,i){this._url=t,this._bounds=X(e),k(this,i)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(R(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){K(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(t){return this.options.opacity=t,this._image&&this._updateOpacity(),this},setStyle:function(t){return t.opacity&&this.setOpacity(t.opacity),this},bringToFront:function(){return this._map&&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=X(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:G("img");if(R(e,"leaflet-image-layer"),this._zoomAnimated&&R(e,"leaflet-zoom-animated"),this.options.className&&R(e,this.options.className),e.onselectstart=w,e.onmousemove=w,e.onload=l(this.fire,this,"load"),e.onerror=l(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;Ot(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();Q(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()}}),ss=function(t,e,i){return new Ue(t,e,i)},Zn=Ue.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:G("video");if(R(e,"leaflet-image-layer"),this._zoomAnimated&&R(e,"leaflet-zoom-animated"),this.options.className&&R(e,this.options.className),e.onselectstart=w,e.onmousemove=w,e.onloadeddata=l(this.fire,this,"load"),t){for(var i=e.getElementsByTagName("source"),o=[],s=0;s<i.length;s++)o.push(i[s].src);this._url=i.length>0?o:[e.src];return}S(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 h=0;h<this._url.length;h++){var f=G("source");f.src=this._url[h],e.appendChild(f)}}});function as(t,e,i){return new Zn(t,e,i)}var Nn=Ue.extend({_initImage:function(){var t=this._image=this._url;R(t,"leaflet-image-layer"),this._zoomAnimated&&R(t,"leaflet-zoom-animated"),this.options.className&&R(t,this.options.className),t.onselectstart=w,t.onmousemove=w}});function ls(t,e,i){return new Nn(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 W||S(t))?(this._latlng=N(t),k(this,e)):(k(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&&(R(this._container,"leaflet-interactive"),this.addInteractiveTarget(this._container))},onRemove:function(t){t._fadeAnimated?(mt(this._container,0),this._removeTimeout=setTimeout(l(K,void 0,this._container),200)):K(this._container),this.options.interactive&&(J(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=D(this.options.offset),i=this._getAnchor();this._zoomAnimated?Q(this._container,t.add(i)):e=e.add(t).add(i);var o=this._containerBottom=-e.y,s=this._containerLeft=-Math.round(this._containerWidth/2)+e.x;this._container.style.bottom=o+"px",this._container.style.left=s+"px"}},_getAnchor:function(){return[0,0]}});H.include({_initOverlay:function(t,e,i,o){var s=e;return s instanceof t||(s=new t(o).setContent(e)),i&&s.setLatLng(i),s}}),yt.include({_initOverlay:function(t,e,i,o){var s=i;return s instanceof t?(k(s,o),s._source=this):(s=e&&!o?e:new t(o,this),s.setContent(i)),s}});var Ze=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=G("div",t+" "+(this.options.className||"")+" leaflet-zoom-animated"),i=this._wrapper=G("div",t+"-content-wrapper",e);if(this._contentNode=G("div",t+"-content",i),de(e),yi(this._contentNode),O(e,"contextmenu",Ut),this._tipContainer=G("div",t+"-tip-container",e),this._tip=G("div",t+"-tip",this._tipContainer),this.options.closeButton){var o=this._closeButton=G("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(s){nt(s),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,s=this.options.maxHeight,h="leaflet-popup-scrolled";s&&o>s?(e.height=s+"px",R(t,h)):J(t,h),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),i=this._getAnchor();Q(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,s=new B(this._containerLeft,-i-this._containerBottom);s._add(Rt(this._container));var h=t.layerPointToContainerPoint(s),f=D(this.options.autoPanPadding),m=D(this.options.autoPanPaddingTopLeft||f),y=D(this.options.autoPanPaddingBottomRight||f),b=t.getSize(),A=0,T=0;h.x+o+y.x>b.x&&(A=h.x+o-b.x+y.x),h.x-A-m.x<0&&(A=h.x-m.x),h.y+i+y.y>b.y&&(T=h.y+i-b.y+y.y),h.y-T-m.y<0&&(T=h.y-m.y),(A||T)&&(this.options.keepInView&&(this._autopanning=!0),t.fire("autopanstart").panBy([A,T]))}},_getAnchor:function(){return D(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),hs=function(t,e){return new Ze(t,e)};H.mergeOptions({closePopupOnClick:!0}),H.include({openPopup:function(t,e,i){return this._initOverlay(Ze,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(Ze,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)){Zt(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 Ne=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=G("div",e),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+p(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var e,i,o=this._map,s=this._container,h=o.latLngToContainerPoint(o.getCenter()),f=o.layerPointToContainerPoint(t),m=this.options.direction,y=s.offsetWidth,b=s.offsetHeight,A=D(this.options.offset),T=this._getAnchor();m==="top"?(e=y/2,i=b):m==="bottom"?(e=y/2,i=0):m==="center"?(e=y/2,i=b/2):m==="right"?(e=0,i=b/2):m==="left"?(e=y,i=b/2):f.x<h.x?(m="right",e=0,i=b/2):(m="left",e=y+(A.x+T.x)*2,i=b/2),t=t.subtract(D(e,i,!0)).add(A).add(T),J(s,"leaflet-tooltip-right"),J(s,"leaflet-tooltip-left"),J(s,"leaflet-tooltip-top"),J(s,"leaflet-tooltip-bottom"),R(s,"leaflet-tooltip-"+m),Q(s,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 D(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),cs=function(t,e){return new Ne(t,e)};H.include({openTooltip:function(t,e,i){return this._initOverlay(Ne,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(Ne,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 Hn=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?(Me(e),e.appendChild(i.html)):e.innerHTML=i.html!==!1?i.html:"",i.bgPos){var o=D(i.bgPos);e.style.backgroundPosition=-o.x+"px "+-o.y+"px"}return this._setIconStyles(e,"icon"),e},createShadow:function(){return null}});function ds(t){return new Hn(t)}qt.Default=pe;var me=yt.extend({options:{tileSize:256,opacity:1,updateWhenIdle:M.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){k(this,t)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView()},beforeAdd:function(t){t._addZoomLimit(this)},onRemove:function(t){this._removeAllTiles(),K(this._container),t._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(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 B?t:new B(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,s=e.length,h;o<s;o++)h=e[o].style.zIndex,e[o]!==this._container&&h&&(i=t(i,+h));isFinite(i)&&(this.options.zIndex=i+t(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!M.ielt9){mt(this._container,this.options.opacity);var t=+new Date,e=!1,i=!1;for(var o in this._tiles){var s=this._tiles[o];if(!(!s.current||!s.loaded)){var h=Math.min(1,(t-s.loaded)/200);mt(s.el,h),h<1?e=!0:(s.active?i=!0:this._onOpaqueTile(s),s.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=G("div","leaflet-layer "+(this.options.className||"")),this._updateZIndex(),this.options.opacity<1&&this._updateOpacity(),this.getPane().appendChild(this._container))},_updateLevels:function(){var t=this._tileZoom,e=this.options.maxZoom;if(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)):(K(this._levels[i].el),this._removeTilesAtZoom(i),this._onRemoveLevel(i),delete this._levels[i]);var o=this._levels[t],s=this._map;return o||(o=this._levels[t]={},o.el=G("div","leaflet-tile-container leaflet-zoom-animated",this._container),o.el.style.zIndex=e,o.origin=s.project(s.unproject(s.getPixelOrigin()),t).round(),o.zoom=t,this._setZoomTransform(o,s.getCenter(),s.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)K(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 s=Math.floor(t/2),h=Math.floor(e/2),f=i-1,m=new B(+s,+h);m.z=+f;var y=this._tileCoordsToKey(m),b=this._tiles[y];return b&&b.active?(b.retain=!0,!0):(b&&b.loaded&&(b.retain=!0),f>o?this._retainParent(s,h,f,o):!1)},_retainChildren:function(t,e,i,o){for(var s=2*t;s<2*t+2;s++)for(var h=2*e;h<2*e+2;h++){var f=new B(s,h);f.z=i+1;var m=this._tileCoordsToKey(f),y=this._tiles[m];if(y&&y.active){y.retain=!0;continue}else y&&y.loaded&&(y.retain=!0);i+1<o&&this._retainChildren(s,h,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 s=Math.round(e);this.options.maxZoom!==void 0&&s>this.options.maxZoom||this.options.minZoom!==void 0&&s<this.options.minZoom?s=void 0:s=this._clampZoom(s);var h=this.options.updateWhenZooming&&s!==this._tileZoom;(!o||h)&&(this._tileZoom=s,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),s!==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),s=t.origin.multiplyBy(o).subtract(this._map._getNewPixelOrigin(e,i)).round();M.any3d?Ot(t.el,s,o):Q(t.el,s)},_resetGrid:function(){var t=this._map,e=t.options.crs,i=this._tileSize=this.getTileSize(),o=this._tileZoom,s=this._map.getPixelWorldBounds(this._tileZoom);s&&(this._globalTileRange=this._pxBoundsToTileRange(s)),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),s=e.project(t,this._tileZoom).floor(),h=e.getSize().divideBy(o*2);return new j(s.subtract(h),s.add(h))},_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),s=this._pxBoundsToTileRange(o),h=s.getCenter(),f=[],m=this.options.keepBuffer,y=new j(s.getBottomLeft().subtract([m,-m]),s.getTopRight().add([m,-m]));if(!(isFinite(s.min.x)&&isFinite(s.min.y)&&isFinite(s.max.x)&&isFinite(s.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 B(A.x,A.y)))&&(this._tiles[b].current=!1)}if(Math.abs(i-this._tileZoom)>1){this._setView(t,i);return}for(var T=s.min.y;T<=s.max.y;T++)for(var U=s.min.x;U<=s.max.x;U++){var st=new B(U,T);if(st.z=this._tileZoom,!!this._isValidTile(st)){var et=this._tiles[this._tileCoordsToKey(st)];et?et.current=!0:f.push(st)}}if(f.sort(function(ct,Xt){return ct.distanceTo(h)-Xt.distanceTo(h)}),f.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var gt=document.createDocumentFragment();for(U=0;U<f.length;U++)this._addTile(f[U],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 X(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),s=o.add(i),h=e.unproject(o,t.z),f=e.unproject(s,t.z);return[h,f]},_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 B(+e[0],+e[1]);return i.z=+e[2],i},_removeTile:function(t){var e=this._tiles[t];e&&(K(e.el),delete this._tiles[t],this.fire("tileunload",{tile:e.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){R(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,M.ielt9&&this.options.opacity<1&&mt(t,this.options.opacity)},_addTile:function(t,e){var i=this._getTilePos(t),o=this._tileCoordsToKey(t),s=this.createTile(this._wrapCoords(t),l(this._tileReady,this,t));this._initTile(s),this.createTile.length<2&&rt(l(this._tileReady,this,t,null,s)),Q(s,i),this._tiles[o]={el:s,coords:t,current:!0},e.appendChild(s),this.fire("tileloadstart",{tile:s,coords:t})},_tileReady:function(t,e,i){e&&this.fire("tileerror",{error:e,tile:i,coords:t});var o=this._tileCoordsToKey(t);i=this._tiles[o],i&&(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||(R(i.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:i.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),M.ielt9||!this._map._fadeAnimated?rt(this._pruneTiles,this):setTimeout(l(this._pruneTiles,this),250)))},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var e=new B(this._wrapX?v(t.x,this._wrapX):t.x,this._wrapY?v(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 us(t){return new me(t)}var Jt=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=k(this,e),e.detectRetina&&M.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",l(this._tileOnLoad,this,e,i)),O(i,"error",l(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:M.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 I(this._url,n(e,this.options))},_tileOnLoad:function(t,e){M.ielt9?setTimeout(l(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=q;var i=this._tiles[t].coords;K(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",q),me.prototype._removeTile.call(this,t)},_tileReady:function(t,e,i){if(!(!this._map||i&&i.getAttribute("src")===q))return me.prototype._tileReady.call(this,t,e,i)}});function Fn(t,e){return new Jt(t,e)}var Gn=Jt.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=k(this,e);var s=e.detectRetina&&M.retina?2:1,h=this.getTileSize();i.width=h.x*s,i.height=h.y*s,this.wmsParams=i},onAdd:function(t){this._crs=this.options.crs||t.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var e=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[e]=this._crs.code,Jt.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])),s=o.min,h=o.max,f=(this._wmsVersion>=1.3&&this._crs===Bn?[s.y,s.x,h.y,h.x]:[s.x,s.y,h.x,h.y]).join(","),m=Jt.prototype.getTileUrl.call(this,t);return m+Z(this.wmsParams,m,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+f},setParams:function(t,e){return n(this.wmsParams,t),e||this.redraw(),this}});function fs(t,e){return new Gn(t,e)}Jt.WMS=Gn,Fn.wms=fs;var Tt=yt.extend({options:{padding:.1},initialize:function(t){k(this,t),p(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),R(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),s=this._map.project(this._center,e),h=o.multiplyBy(-i).add(s).subtract(this._map._getNewPixelOrigin(t,e));M.any3d?Ot(this._container,h,i):Q(this._container,h)},_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()}}),Vn=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(){at(this._redrawRequest),delete this._ctx,K(this._container),Y(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=M.retina?2:1;Q(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",M.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[p(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[p(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,s;for(s=0;s<e.length;s++){if(o=Number(e[s]),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 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,s,h,f=t._parts,m=f.length,y=this._ctx;if(m){for(y.beginPath(),i=0;i<m;i++){for(o=0,s=f[i].length;o<s;o++)h=f[i][o],y[o?"lineTo":"moveTo"](h.x,h.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),s=(Math.max(Math.round(t._radiusY),1)||o)/o;s!==1&&(i.save(),i.scale(1,s)),i.beginPath(),i.arc(e.x,e.y/s,o,0,Math.PI*2,!1),s!==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,s=this._drawFirst;s;s=s.next)i=s.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&&(J(this._container,"leaflet-interactive"),this._fireEvent([e],t,"mouseout"),this._hoveredLayer=null,this._mouseHoverThrottled=!1)},_handleMouseHover:function(t,e){if(!this._mouseHoverThrottled){for(var i,o,s=this._drawFirst;s;s=s.next)i=s.layer,i.options.interactive&&i._containsPoint(e)&&(o=i);o!==this._hoveredLayer&&(this._handleMouseOut(t),o&&(R(this._container,"leaflet-interactive"),this._fireEvent([o],t,"mouseover"),this._hoveredLayer=o)),this._fireEvent(this._hoveredLayer?[this._hoveredLayer]:!1,t),this._mouseHoverThrottled=!0,setTimeout(l(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 Wn(t){return M.canvas?new Vn(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=G("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");R(e,"leaflet-vml-shape "+(this.options.className||"")),e.coordsize="1 1",t._path=_e("path"),e.appendChild(t._path),this._updateStyle(t),this._layers[p(t)]=t},_addPath:function(t){var e=t._container;this._container.appendChild(e),t.options.interactive&&t.addInteractiveTarget(e)},_removePath:function(t){var e=t._container;K(e),t.removeInteractiveTarget(e),delete this._layers[p(t)]},_updateStyle:function(t){var e=t._stroke,i=t._fill,o=t.options,s=t._container;s.stroked=!!o.stroke,s.filled=!!o.fill,o.stroke?(e||(e=t._stroke=_e("stroke")),s.appendChild(e),e.weight=o.weight+"px",e.color=o.color,e.opacity=o.opacity,o.dashArray?e.dashStyle=S(o.dashArray)?o.dashArray.join(" "):o.dashArray.replace(/( *, *)/g," "):e.dashStyle="",e.endcap=o.lineCap.replace("butt","flat"),e.joinstyle=o.lineJoin):e&&(s.removeChild(e),t._stroke=null),o.fill?(i||(i=t._fill=_e("fill")),s.appendChild(i),i.color=o.fillColor||o.color,i.opacity=o.fillOpacity):i&&(s.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)}},He=M.vml?_e:ji,ge=Tt.extend({_initContainer:function(){this._container=He("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=He("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){K(this._container),Y(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)),Q(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=He("path");t.options.className&&R(e,t.options.className),t.options.interactive&&R(e,"leaflet-interactive"),this._updateStyle(t),this._layers[p(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){K(t._path),t.removeInteractiveTarget(t._path),delete this._layers[p(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,Ki(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,s="a"+i+","+o+" 0 1,0 ",h=t._empty()?"M0 0":"M"+(e.x-i)+","+e.y+s+i*2+",0 "+s+-i*2+",0 ";this._setPath(t,h)},_setPath:function(t,e){t._path.setAttribute("d",e)},_bringToFront:function(t){Vt(t._path)},_bringToBack:function(t){Wt(t._path)}});M.vml&&ge.include(ps);function Yn(t){return M.svg||M.vml?new ge(t):null}H.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&&Wn(t)||Yn(t)}});var qn=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=X(t),[t.getSouthWest(),t.getNorthWest(),t.getNorthEast(),t.getSouthEast()]}});function ms(t,e){return new qn(t,e)}ge.create=He,ge.pointsToPath=Ki,Pt.geometryToLayer=ze,Pt.coordsToLatLng=Pi,Pt.coordsToLatLngs=Be,Pt.latLngToCoords=Ti,Pt.latLngsToCoords=Oe,Pt.getFeature=Kt,Pt.asFeature=Re,H.mergeOptions({boxZoom:!0});var jn=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(){Y(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){K(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){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(),di(),this._startPoint=this._map.mouseEventToContainerPoint(t),O(document,{contextmenu:Zt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=G("div","leaflet-zoom-box",this._container),R(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();Q(this._box,e.min),this._box.style.width=i.x+"px",this._box.style.height=i.y+"px"},_finish:function(){this._moved&&(K(this._box),J(this._container,"leaflet-crosshair")),he(),ui(),Y(document,{contextmenu:Zt,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(l(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())}});H.addInitHook("addHandler","boxZoom",jn),H.mergeOptions({doubleClickZoom:!0});var Kn=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,s=t.originalEvent.shiftKey?i-o:i+o;e.options.doubleClickZoom==="center"?e.setZoom(s):e.setZoomAround(t.containerPoint,s)}});H.addInitHook("addHandler","doubleClickZoom",Kn),H.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var Jn=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))}R(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){J(this._map._container,"leaflet-grab"),J(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=X(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,s=(o-e+i)%t+e-i,h=(o+e+i)%t-e-i,f=Math.abs(s+i)<Math.abs(h+i)?s:h;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=f},_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 s=this._lastPos.subtract(this._positions[0]),h=(this._lastTime-this._times[0])/1e3,f=i.easeLinearity,m=s.multiplyBy(f/h),y=m.distanceTo([0,0]),b=Math.min(i.inertiaMaxSpeed,y),A=m.multiplyBy(b/y),T=b/(i.inertiaDeceleration*f),U=A.multiplyBy(-T/2).round();!U.x&&!U.y?e.fire("moveend"):(U=e._limitOffset(U,e.options.maxBounds),rt(function(){e.panBy(U,{duration:T,easeLinearity:f,noMoveStart:!0,animate:!0})}))}}});H.addInitHook("addHandler","dragging",Jn),H.mergeOptions({keyboard:!0,keyboardPanDelta:80});var Xn=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(),Y(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,s;for(o=0,s=i.left.length;o<s;o++)e[i.left[o]]=[-1*t,0];for(o=0,s=i.right.length;o<s;o++)e[i.right[o]]=[t,0];for(o=0,s=i.down.length;o<s;o++)e[i.down[o]]=[0,t];for(o=0,s=i.up.length;o<s;o++)e[i.up[o]]=[0,-1*t]},_setZoomDelta:function(t){var e=this._zoomKeys={},i=this.keyCodes,o,s;for(o=0,s=i.zoomIn.length;o<s;o++)e[i.zoomIn[o]]=t;for(o=0,s=i.zoomOut.length;o<s;o++)e[i.zoomOut[o]]=-t},_addHooks:function(){O(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){Y(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=D(o).multiplyBy(3)),i.options.maxBounds&&(o=i._limitOffset(D(o),i.options.maxBounds)),i.options.worldCopyJump){var s=i.wrapLatLng(i.unproject(i.project(i.getCenter()).add(o)));i.panTo(s)}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;Zt(t)}}});H.addInitHook("addHandler","keyboard",Xn),H.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var Qn=bt.extend({addHooks:function(){O(this._map._container,"wheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){Y(this._map._container,"wheel",this._onWheelScroll,this)},_onWheelScroll:function(t){var e=bn(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(l(this._performZoom,this),o),Zt(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),s=4*Math.log(2/(1+Math.exp(-Math.abs(o))))/Math.LN2,h=i?Math.ceil(s/i)*i:s,f=t._limitZoom(e+(this._delta>0?h:-h))-e;this._delta=0,this._startTime=null,f&&(t.options.scrollWheelZoom==="center"?t.setZoom(e+f):t.setZoomAround(this._lastMousePos,e+f))}});H.addInitHook("addHandler","scrollWheelZoom",Qn);var _s=600;H.mergeOptions({tapHold:M.touchNative&&M.safari&&M.mobile,tapTolerance:15});var $n=bt.extend({addHooks:function(){O(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){Y(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 B(e.clientX,e.clientY),this._holdTimeout=setTimeout(l(function(){this._cancel(),this._isTapValid()&&(O(document,"touchend",nt),O(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",e))},this),_s),O(document,"touchend touchcancel contextmenu",this._cancel,this),O(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function t(){Y(document,"touchend",nt),Y(document,"touchend touchcancel",t)},_cancel:function(){clearTimeout(this._holdTimeout),Y(document,"touchend touchcancel contextmenu",this._cancel,this),Y(document,"touchmove",this._onMove,this)},_onMove:function(t){var e=t.touches[0];this._newPos=new B(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)}});H.addInitHook("addHandler","tapHold",$n),H.mergeOptions({touchZoom:M.touch,bounceAtZoomLimits:!0});var to=bt.extend({addHooks:function(){R(this._map._container,"leaflet-touch-zoom"),O(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){J(this._map._container,"leaflet-touch-zoom"),Y(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]),s=i.distanceTo(o)/this._startDist;if(this._zoom=e.getScaleZoom(s,this._startZoom),!e.options.bounceAtZoomLimits&&(this._zoom<e.getMinZoom()&&s<1||this._zoom>e.getMaxZoom()&&s>1)&&(this._zoom=e._limitZoom(this._zoom)),e.options.touchZoom==="center"){if(this._center=this._startLatLng,s===1)return}else{var h=i._add(o)._divideBy(2)._subtract(this._centerPoint);if(s===1&&h.x===0&&h.y===0)return;this._center=e.unproject(e.project(this._pinchStartLatLng,this._zoom).subtract(h),this._zoom)}this._moved||(e._moveStart(!0,!1),this._moved=!0),at(this._animRequest);var f=l(e._move,e,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=rt(f,this,!0),nt(t)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,at(this._animRequest),Y(document,"touchmove",this._onTouchMove,this),Y(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))}});H.addInitHook("addHandler","touchZoom",to),H.BoxZoom=jn,H.DoubleClickZoom=Kn,H.Drag=Jn,H.Keyboard=Xn,H.ScrollWheelZoom=Qn,H.TapHold=$n,H.TouchZoom=to,a.Bounds=j,a.Browser=M,a.CRS=kt,a.Canvas=Vn,a.Circle=Ei,a.CircleMarker=Ie,a.Class=pt,a.Control=vt,a.DivIcon=Hn,a.DivOverlay=xt,a.DomEvent=zr,a.DomUtil=Dr,a.Draggable=Dt,a.Evented=ne,a.FeatureGroup=Mt,a.GeoJSON=Pt,a.GridLayer=me,a.Handler=bt,a.Icon=qt,a.ImageOverlay=Ue,a.LatLng=W,a.LatLngBounds=ht,a.Layer=yt,a.LayerGroup=Yt,a.LineUtil=qr,a.Map=H,a.Marker=De,a.Mixin=Hr,a.Path=It,a.Point=B,a.PolyUtil=Fr,a.Polygon=jt,a.Polyline=Et,a.Popup=Ze,a.PosAnimation=xn,a.Projection=jr,a.Rectangle=qn,a.Renderer=Tt,a.SVG=ge,a.SVGOverlay=Nn,a.TileLayer=Jt,a.Tooltip=Ne,a.Transformation=$e,a.Util=xe,a.VideoOverlay=Zn,a.bind=l,a.bounds=lt,a.canvas=Wn,a.circle=is,a.circleMarker=es,a.control=ue,a.divIcon=ds,a.extend=n,a.featureGroup=Qr,a.geoJSON=Un,a.geoJson=rs,a.gridLayer=us,a.icon=$r,a.imageOverlay=ss,a.latLng=N,a.latLngBounds=X,a.layerGroup=Xr,a.map=Br,a.marker=ts,a.point=D,a.polygon=os,a.polyline=ns,a.popup=hs,a.rectangle=ms,a.setOptions=k,a.stamp=p,a.svg=Yn,a.svgOverlay=ls,a.tileLayer=Fn,a.tooltip=cs,a.transformation=oe,a.version=u,a.videoOverlay=as;var gs=window.L;a.noConflict=function(){return window.L=gs,this},window.L=a}))})(Qt,Qt.exports)),Qt.exports}var z=Ii();const Ge=ut({__proto__:null,default:so(z)},[z]),lo='.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}}',ho=`.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}`,co=".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}",uo="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==",fo="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=",po="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACkAAAApCAQAAAACach9AAACMUlEQVR4Ae3ShY7jQBAE0Aoz/f9/HTMzhg1zrdKUrJbdx+Kd2nD8VNudfsL/Th///dyQN2TH6f3y/BGpC379rV+S+qqetBOxImNQXL8JCAr2V4iMQXHGNJxeCfZXhSRBcQMfvkOWUdtfzlLgAENmZDcmo2TVmt8OSM2eXxBp3DjHSMFutqS7SbmemzBiR+xpKCNUIRkdkkYxhAkyGoBvyQFEJEefwSmmvBfJuJ6aKqKWnAkvGZOaZXTUgFqYULWNSHUckZuR1HIIimUExutRxwzOLROIG4vKmCKQt364mIlhSyzAf1m9lHZHJZrlAOMMztRRiKimp/rpdJDc9Awry5xTZCte7FHtuS8wJgeYGrex28xNTd086Dik7vUMscQOa8y4DoGtCCSkAKlNwpgNtphjrC6MIHUkR6YWxxs6Sc5xqn222mmCRFzIt8lEdKx+ikCtg91qS2WpwVfBelJCiQJwvzixfI9cxZQWgiSJelKnwBElKYtDOb2MFbhmUigbReQBV0Cg4+qMXSxXSyGUn4UbF8l+7qdSGnTC0XLCmahIgUHLhLOhpVCtw4CzYXvLQWQbJNmxoCsOKAxSgBJno75avolkRw8iIAFcsdc02e9iyCd8tHwmeSSoKTowIgvscSGZUOA7PuCN5b2BX9mQM7S0wYhMNU74zgsPBj3HU7wguAfnxxjFQGBE6pwN+GjME9zHY7zGp8wVxMShYX9NXvEWD3HbwJf4giO4CFIQxXScH1/TM+04kkBiAAAAAElFTkSuQmCC",mo="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",_o="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",go="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",vo="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 yo(g){const c="data-leaflet-styles";if(g.querySelector(`style[${c}]`))return;const a=document.createElement("style");a.setAttribute(c,"true"),a.textContent=`
|
|
5
|
+
/* --- Leaflet core CSS --- */
|
|
6
|
+
${lo}
|
|
7
|
+
|
|
8
|
+
/* --- Leaflet.draw CSS --- */
|
|
9
|
+
${ho}
|
|
10
|
+
|
|
11
|
+
/* --- Leaflet.ruler CSS --- */
|
|
12
|
+
${co}
|
|
13
|
+
|
|
14
|
+
/* --- Fix Leaflet.ruler icons (broken relative paths in inlined CSS) --- */
|
|
15
|
+
.leaflet-ruler {
|
|
16
|
+
width: 30px !important; /* Match Leaflet Draw default size approx */
|
|
17
|
+
height: 30px !important;
|
|
18
|
+
background-color: #fff; /* Ensure visibility */
|
|
19
|
+
background-image: url(${go}) !important;
|
|
20
|
+
background-size: 16px 16px; /* Scale icon to fit */
|
|
21
|
+
}
|
|
22
|
+
.leaflet-ruler:hover,
|
|
23
|
+
.leaflet-ruler-clicked {
|
|
24
|
+
background-image: url(${vo}) !important;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/* --- Custom overrides for marker/handle sizes --- */
|
|
28
|
+
.leaflet-draw-handle,
|
|
29
|
+
.leaflet-editing-icon,
|
|
30
|
+
.leaflet-draw-marker-icon {
|
|
31
|
+
width: 12px !important;
|
|
32
|
+
height: 12px !important;
|
|
33
|
+
margin-left: -6px !important;
|
|
34
|
+
margin-top: -6px !important;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/* --- Ruler settings control --- */
|
|
38
|
+
.leaflet-ruler-settings-control {
|
|
39
|
+
display: flex;
|
|
40
|
+
flex-direction: column;
|
|
41
|
+
}
|
|
42
|
+
.leaflet-ruler-settings-button {
|
|
43
|
+
width: 30px;
|
|
44
|
+
height: 30px;
|
|
45
|
+
border: none;
|
|
46
|
+
background-color: #fff;
|
|
47
|
+
background-repeat: no-repeat;
|
|
48
|
+
background-position: center;
|
|
49
|
+
background-size: 22px 22px;
|
|
50
|
+
cursor: pointer;
|
|
51
|
+
padding: 0;
|
|
52
|
+
border-radius: 4px;
|
|
53
|
+
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
|
|
54
|
+
background-image: url(${mo});
|
|
55
|
+
transition: background-color 0.15s ease, box-shadow 0.15s ease;
|
|
56
|
+
}
|
|
57
|
+
.leaflet-ruler-settings-button:hover {
|
|
58
|
+
background-color: #f4f4f4;
|
|
59
|
+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
|
|
60
|
+
}
|
|
61
|
+
.leaflet-ruler-settings-button:focus-visible {
|
|
62
|
+
outline: 2px solid #2c7be5;
|
|
63
|
+
outline-offset: 2px;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/* --- Measurement modal --- */
|
|
67
|
+
.leaflet-ruler-modal-overlay {
|
|
68
|
+
position: absolute;
|
|
69
|
+
inset: 0;
|
|
70
|
+
display: flex;
|
|
71
|
+
align-items: center;
|
|
72
|
+
justify-content: center;
|
|
73
|
+
background: rgba(0, 0, 0, 0.4);
|
|
74
|
+
z-index: 500;
|
|
75
|
+
opacity: 0;
|
|
76
|
+
pointer-events: none;
|
|
77
|
+
transition: opacity 0.2s ease;
|
|
78
|
+
padding: 16px;
|
|
79
|
+
}
|
|
80
|
+
.leaflet-ruler-modal-overlay.is-open {
|
|
81
|
+
opacity: 1;
|
|
82
|
+
pointer-events: auto;
|
|
83
|
+
}
|
|
84
|
+
.leaflet-ruler-modal {
|
|
85
|
+
background: #fff;
|
|
86
|
+
border-radius: 8px;
|
|
87
|
+
width: min(320px, 100%);
|
|
88
|
+
padding: 16px;
|
|
89
|
+
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
|
|
90
|
+
}
|
|
91
|
+
.leaflet-ruler-modal-title {
|
|
92
|
+
margin: 0 0 8px;
|
|
93
|
+
font-size: 16px;
|
|
94
|
+
font-weight: 600;
|
|
95
|
+
}
|
|
96
|
+
.leaflet-ruler-modal-description {
|
|
97
|
+
margin: 0 0 12px;
|
|
98
|
+
font-size: 13px;
|
|
99
|
+
color: #444;
|
|
100
|
+
}
|
|
101
|
+
.leaflet-ruler-modal-options {
|
|
102
|
+
display: flex;
|
|
103
|
+
flex-direction: column;
|
|
104
|
+
gap: 8px;
|
|
105
|
+
}
|
|
106
|
+
.leaflet-ruler-modal-option {
|
|
107
|
+
display: flex;
|
|
108
|
+
gap: 8px;
|
|
109
|
+
align-items: flex-start;
|
|
110
|
+
font-size: 14px;
|
|
111
|
+
}
|
|
112
|
+
.leaflet-ruler-modal-option input[type="radio"] {
|
|
113
|
+
margin-top: 4px;
|
|
114
|
+
}
|
|
115
|
+
.leaflet-ruler-modal-option span {
|
|
116
|
+
line-height: 1.25;
|
|
117
|
+
}
|
|
118
|
+
.leaflet-ruler-modal-actions {
|
|
119
|
+
margin-top: 16px;
|
|
120
|
+
display: flex;
|
|
121
|
+
justify-content: flex-end;
|
|
122
|
+
}
|
|
123
|
+
.leaflet-ruler-modal-close {
|
|
124
|
+
border: none;
|
|
125
|
+
background: #2c7be5;
|
|
126
|
+
color: #fff;
|
|
127
|
+
border-radius: 4px;
|
|
128
|
+
padding: 6px 12px;
|
|
129
|
+
cursor: pointer;
|
|
130
|
+
font-size: 14px;
|
|
131
|
+
}
|
|
132
|
+
.leaflet-ruler-modal-close:hover {
|
|
133
|
+
background: #1a56c2;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/* --- Layer Cake draw tool icon + manager UI --- */
|
|
137
|
+
.leaflet-draw-draw-cake {
|
|
138
|
+
background-image: url(${_o}) !important;
|
|
139
|
+
background-size: 18px 18px;
|
|
140
|
+
background-position: center;
|
|
141
|
+
background-repeat: no-repeat;
|
|
142
|
+
background-color: #fff;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.layer-cake-controls__container {
|
|
146
|
+
display: flex;
|
|
147
|
+
gap: 6px;
|
|
148
|
+
background: white;
|
|
149
|
+
padding: 5px;
|
|
150
|
+
border-radius: 4px;
|
|
151
|
+
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.layer-cake-controls button {
|
|
155
|
+
border: 1px solid #ccc;
|
|
156
|
+
background: white;
|
|
157
|
+
padding: 4px 8px;
|
|
158
|
+
border-radius: 3px;
|
|
159
|
+
font-size: 12px;
|
|
160
|
+
cursor: pointer;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.layer-cake-controls button:hover {
|
|
164
|
+
background: #f4f4f4;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/* --- Layer Cake measurement tooltips --- */
|
|
168
|
+
.cake-label {
|
|
169
|
+
background-color: rgba(255, 255, 255, 0.95) !important;
|
|
170
|
+
border: 2px solid #8A2BE2 !important;
|
|
171
|
+
border-radius: 4px !important;
|
|
172
|
+
color: #333 !important;
|
|
173
|
+
font-size: 13px !important;
|
|
174
|
+
font-weight: 600 !important;
|
|
175
|
+
padding: 4px 8px !important;
|
|
176
|
+
white-space: nowrap !important;
|
|
177
|
+
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.cake-label::before {
|
|
181
|
+
border-right-color: #8A2BE2 !important;
|
|
182
|
+
}
|
|
183
|
+
`,g.appendChild(a)}function wo(){var g,c;(c=(g=z.Icon.Default).mergeOptions)==null||c.call(g,{iconRetinaUrl:uo,iconUrl:fo,shadowUrl:po})}(function(g,c,a){function u(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 l=L.version.split(".");parseInt(l[0],10)===1&&parseInt(l[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,l=r.getLatLngs(),d=l.splice(-1,1)[0];this._poly.setLatLngs(l),this._markerGroup.removeLayer(n),r.getLatLngs().length<2&&this._map.removeLayer(r),this._vertexChanged(d,!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),l=this._map.layerPointToLatLng(r);this._currentLatLng=l,this._updateTooltip(l),this._updateGuide(r),this._mouseMarker.setLatLng(l),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,l=r.clientX,d=r.clientY;this._startPoint.call(this,l,d)}},_startPoint:function(n,r){this._mouseDownOrigin=L.point(n,r)},_onMouseUp:function(n){var r=n.originalEvent,l=r.clientX,d=r.clientY;this._endPoint.call(this,l,d,n),this._clickHandled=null},_endPoint:function(n,r,l){if(this._mouseDownOrigin){var d=L.point(n,r).distanceTo(this._mouseDownOrigin),p=this._calculateFinishDistance(l.latlng);this.options.maxPoints>1&&this.options.maxPoints==this._markers.length+1?(this.addVertex(l.latlng),this._finishShape()):p<10&&L.Browser.touch?this._finishShape():Math.abs(d)<9*(g.devicePixelRatio||1)&&this.addVertex(l.latlng),this._enableNewMarkers()}this._mouseDownOrigin=null},_onTouch:function(n){var r,l,d=n.originalEvent;!d.touches||!d.touches[0]||this._clickHandled||this._touchHandled||this._disableMarkers||(r=d.touches[0].clientX,l=d.touches[0].clientY,this._disableNewMarkers(),this._touchHandled=!0,this._startPoint.call(this,r,l),this._endPoint.call(this,r,l,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 l;if(this.type===L.Draw.Polyline.TYPE)l=this._markers[this._markers.length-1];else{if(this.type!==L.Draw.Polygon.TYPE)return 1/0;l=this._markers[0]}var d=this._map.latLngToContainerPoint(l.getLatLng()),p=new L.Marker(n,{icon:this.options.icon,zIndexOffset:2*this.options.zIndexOffset}),_=this._map.latLngToContainerPoint(p.getLatLng());r=d.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 l,d,p,_=Math.floor(Math.sqrt(Math.pow(r.x-n.x,2)+Math.pow(r.y-n.y,2))),v=this.options.guidelineDistance,w=this.options.maxGuideLineLength,x=_>w?_-w:v;for(this._guidesContainer||(this._guidesContainer=L.DomUtil.create("div","leaflet-draw-guides",this._overlayPane));x<_;x+=this.options.guidelineDistance)l=x/_,d={x:Math.floor(n.x*(1-l)+l*r.x),y:Math.floor(n.y*(1-l)+l*r.y)},p=L.DomUtil.create("div","leaflet-draw-guide-dash",this._guidesContainer),p.style.backgroundColor=this._errorShown?this.options.drawError.color:this.options.shapeOptions.color,L.DomUtil.setPosition(p,d)},_updateGuideColor:function(n){if(this._guidesContainer)for(var r=0,l=this._guidesContainer.childNodes.length;r<l;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,l=this.options.showLength;return this._markers.length===0?n={text:L.drawLocal.draw.handlers.polyline.tooltip.start}:(r=l?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 l,d,p=this._markers.length;this._markers.length===1?this._measurementRunningTotal=0:(l=p-(r?2:1),d=L.GeometryUtil.isVersion07x()?n.distanceTo(this._markers[l].getLatLng())*(this.options.factor||1):this._map.distance(n,this._markers[l].getLatLng())*(this.options.factor||1),this._measurementRunningTotal+=d*(r?1:-1))},_getMeasurementString:function(){var n,r=this._currentLatLng,l=this._markers[this._markers.length-1].getLatLng();return n=L.GeometryUtil.isVersion07x()?l&&r&&r.distanceTo?this._measurementRunningTotal+r.distanceTo(l)*(this.options.factor||1):this._measurementRunningTotal||0:l&&r?this._measurementRunningTotal+this._map.distance(r,l)*(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 l;!this.options.allowIntersection&&this.options.showArea&&(l=this._poly.getLatLngs(),this._area=L.GeometryUtil.geodesicArea(l)),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&&!u(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,l,d=L.Draw.SimpleShape.prototype._getTooltipText.call(this),p=this._shape,_=this.options.showArea;return p&&(n=this._shape._defaultShape?this._shape._defaultShape():this._shape.getLatLngs(),r=L.GeometryUtil.geodesicArea(n),l=_?L.GeometryUtil.readableArea(r,this.options.metric):""),{text:d.text,subtext:l}}}),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,l=n.latlng,d=this.options.showRadius,p=this.options.metric;if(this._tooltip.updatePosition(l),this._isDrawing){this._drawShape(l),r=this._shape.getRadius().toFixed(1);var _="";d&&(_=L.drawLocal.draw.handlers.circle.radius+": "+L.GeometryUtil.readableDistance(r,p,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 l=parseInt(n.style.marginTop,10)-r,d=parseInt(n.style.marginLeft,10)-r;n.style.marginTop=l+"px",n.style.marginLeft=d+"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,l){L.Browser.touch&&(this.options.icon=this.options.touchIcon),this._poly=n,l&&l.drawError&&(l.drawError=L.Util.extend({},this.options.drawError,l.drawError)),this._latlngs=r,L.setOptions(this,l)},_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(l){L.DomUtil.removeClass(r,l)}),n.options.editing.className.split(" ").forEach(function(l){L.DomUtil.addClass(r,l)})),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(l){L.DomUtil.removeClass(r,l)}),n.options.original.className&&n.options.original.className.split(" ").forEach(function(l){L.DomUtil.addClass(r,l)})),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,l,d,p=this._defaultShape();for(n=0,l=p.length;n<l;n++)d=this._createMarker(p[n],n),d.on("click",this._onMarkerClick,this),d.on("contextmenu",this._onContextMenu,this),this._markers.push(d);var _,v;for(n=0,r=l-1;n<l;r=n++)(n!==0||L.Polygon&&this._poly instanceof L.Polygon)&&(_=this._markers[r],v=this._markers[n],this._createMiddleMarker(_,v),this._updatePrevNext(_,v))},_createMarker:function(n,r){var l=new L.Marker.Touch(n,{draggable:!0,icon:this.options.icon});return l._origLatLng=n,l._index=r,l.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(l),l},_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,l=this._poly,d=L.LatLngUtil.cloneLatLng(r._origLatLng);if(L.extend(r._origLatLng,r._latlng),l.options.poly){var p=l._map._editTooltip;if(!l.options.poly.allowIntersection&&l.intersects()){L.extend(r._origLatLng,d),r.setLatLng(d);var _=l.options.color;l.setStyle({color:this.options.drawError.color}),p&&p.updateContent({text:L.drawLocal.draw.handlers.polyline.error}),setTimeout(function(){l.setStyle({color:_}),p&&p.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 v=this._poly.getLatLngs();this._poly._convertLatLngs(v,!0),this._poly.redraw(),this._poly.fire("editdrag")},_onMarkerClick:function(n){var r=L.Polygon&&this._poly instanceof L.Polygon?4:3,l=n.target;this._defaultShape().length<r||(this._removeMarker(l),this._updatePrevNext(l._prev,l._next),l._middleLeft&&this._markerGroup.removeLayer(l._middleLeft),l._middleRight&&this._markerGroup.removeLayer(l._middleRight),l._prev&&l._next?this._createMiddleMarker(l._prev,l._next):l._prev?l._next||(l._prev._middleRight=null):l._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]),l=this._map.layerPointToLatLng(r),d=n.target;L.extend(d._origLatLng,l),d._middleLeft&&d._middleLeft.setLatLng(this._getMiddleLatLng(d._prev,d)),d._middleRight&&d._middleRight.setLatLng(this._getMiddleLatLng(d,d._next)),this._poly.redraw(),this.updateMarkers()},_updateIndexes:function(n,r){this._markerGroup.eachLayer(function(l){l._index>n&&(l._index+=r)})},_createMiddleMarker:function(n,r){var l,d,p,_=this._getMiddleLatLng(n,r),v=this._createMarker(_);v.setOpacity(.6),n._middleRight=r._middleLeft=v,d=function(){v.off("touchmove",d,this);var w=r._index;v._index=w,v.off("click",l,this).on("click",this._onMarkerClick,this),_.lat=v.getLatLng().lat,_.lng=v.getLatLng().lng,this._spliceLatLngs(w,0,_),this._markers.splice(w,0,v),v.setOpacity(1),this._updateIndexes(w,1),r._index++,this._updatePrevNext(n,v),this._updatePrevNext(v,r),this._poly.fire("editstart")},p=function(){v.off("dragstart",d,this),v.off("dragend",p,this),v.off("touchmove",d,this),this._createMiddleMarker(n,v),this._createMiddleMarker(v,r)},l=function(){d.call(this),p.call(this),this._fireEdit()},v.on("click",l,this).on("dragstart",d,this).on("dragend",p,this).on("touchmove",d,this),this._markerGroup.addLayer(v)},_updatePrevNext:function(n,r){n&&(n._next=r),r&&(r._prev=n)},_getMiddleLatLng:function(n,r){var l=this._poly._map,d=l.project(n.getLatLng()),p=l.project(r.getLatLng());return l.unproject(d._add(p)._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,l=this._resizeMarkers.length;r<l;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 l=new L.Marker.Touch(n,{draggable:!0,icon:r,zIndexOffset:10});return this._bindMarker(l),this._markerGroup.addLayer(l),l},_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,l=r.getLatLng();r===this._moveMarker?this._move(l):this._resize(l),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(),l=n.target,d=l._cornerIndex;l.setOpacity(0),this._oppositeCorner=r[(d+2)%4],this._toggleCornerMarkers(0,d)}this._shape.fire("editstart")},_onTouchMove:function(n){var r=this._map.mouseEventToLayerPoint(n.originalEvent.touches[0]),l=this._map.layerPointToLatLng(r);return n.target===this._moveMarker?this._move(l):this._resize(l),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,l=n.length;r<l;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(),l=n.target,d=l._cornerIndex;this._oppositeCorner=r[(d+2)%4],this._toggleCornerMarkers(0,d)},_onMarkerDragEnd:function(n){var r,l,d=n.target;d===this._moveMarker&&(r=this._shape.getBounds(),l=r.getCenter(),d.setLatLng(l)),this._toggleCornerMarkers(1),this._repositionCornerMarkers(),L.Edit.SimpleShape.prototype._onMarkerDragEnd.call(this,n)},_move:function(n){for(var r,l=this._shape._defaultShape?this._shape._defaultShape():this._shape.getLatLngs(),d=this._shape.getBounds(),p=d.getCenter(),_=[],v=0,w=l.length;v<w;v++)r=[l[v].lat-p.lat,l[v].lng-p.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,l=this._resizeMarkers.length;r<l;r++)this._resizeMarkers[r].setOpacity(n)},_repositionCornerMarkers:function(){for(var n=this._getCorners(),r=0,l=this._resizeMarkers.length;r<l;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),l=this._map.project(n);return this._map.unproject([l.x+r,l.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 l={};if(n.touches!==void 0){if(!n.touches.length)return;l=n.touches[0]}else if(n.pointerType!=="touch"||(l=n,!this._filterClick(n)))return;var d=this._map.mouseEventToContainerPoint(l),p=this._map.mouseEventToLayerPoint(l),_=this._map.layerPointToLatLng(p);this._map.fire(r,{latlng:_,layerPoint:p,containerPoint:d,pageX:l.pageX,pageY:l.pageY,originalEvent:n})},_filterClick:function(n){var r=n.timeStamp||n.originalEvent.timeStamp,l=L.DomEvent._lastClick&&r-L.DomEvent._lastClick;return l&&l>100&&l<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 l=n.indexOf("rv:");return parseInt(n.substring(l+3,n.indexOf(".",l)),10)}var d=n.indexOf("Edge/");return d>0&&parseInt(n.substring(d+5,n.indexOf(".",d)),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 l=0;l<r.length;l++)L.DomEvent.on(n,r[l],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 l=n.indexOf("rv:");return parseInt(n.substring(l+3,n.indexOf(".",l)),10)}var d=n.indexOf("Edge/");return d>0&&parseInt(n.substring(d+5,n.indexOf(".",d)),10)}}),L.LatLngUtil={cloneLatLngs:function(n){for(var r=[],l=0,d=n.length;l<d;l++)Array.isArray(n[l])?r.push(L.LatLngUtil.cloneLatLngs(n[l])):r.push(this.cloneLatLng(n[l]));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 l,d,p=r.length,_=0,v=Math.PI/180;if(p>2){for(var w=0;w<p;w++)l=r[w],d=r[(w+1)%p],_+=(d.lng-l.lng)*v*(2+Math.sin(l.lat*v)+Math.sin(d.lat*v));_=6378137*_*6378137/2}return Math.abs(_)},formattedNumber:function(r,l){var d=parseFloat(r).toFixed(l),p=L.drawLocal.format&&L.drawLocal.format.numeric,_=p&&p.delimiters,v=_&&_.thousands,w=_&&_.decimal;if(v||w){var x=d.split(".");d=v?x[0].replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+v):x[0],w=w||".",x.length>1&&(d=d+w+x[1])}return d},readableArea:function(r,l,v){var p,_,v=L.Util.extend({},n,v);return l?(_=["ha","m"],type=typeof l,type==="string"?_=[l]:type!=="boolean"&&(_=l),p=r>=1e6&&_.indexOf("km")!==-1?L.GeometryUtil.formattedNumber(1e-6*r,v.km)+" km²":r>=1e4&&_.indexOf("ha")!==-1?L.GeometryUtil.formattedNumber(1e-4*r,v.ha)+" ha":L.GeometryUtil.formattedNumber(r,v.m)+" m²"):(r/=.836127,p=r>=3097600?L.GeometryUtil.formattedNumber(r/3097600,v.mi)+" mi²":r>=4840?L.GeometryUtil.formattedNumber(r/4840,v.ac)+" acres":L.GeometryUtil.formattedNumber(r,v.yd)+" yd²"),p},readableDistance:function(r,l,d,p,w){var v,w=L.Util.extend({},n,w);switch(l?typeof l=="string"?l:"metric":d?"feet":p?"nauticalMile":"yards"){case"metric":v=r>1e3?L.GeometryUtil.formattedNumber(r/1e3,w.km)+" km":L.GeometryUtil.formattedNumber(r,w.m)+" m";break;case"feet":r*=3.28083,v=L.GeometryUtil.formattedNumber(r,w.ft)+" ft";break;case"nauticalMile":r*=.53996,v=L.GeometryUtil.formattedNumber(r/1e3,w.nm)+" nm";break;case"yards":default:r*=1.09361,v=r>1760?L.GeometryUtil.formattedNumber(r/1760,w.mi)+" miles":L.GeometryUtil.formattedNumber(r,w.yd)+" yd"}return v},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,l,d){return this._checkCounterclockwise(n,l,d)!==this._checkCounterclockwise(r,l,d)&&this._checkCounterclockwise(n,r,l)!==this._checkCounterclockwise(n,r,d)},_checkCounterclockwise:function(n,r,l){return(l.y-n.y)*(r.x-n.x)>(r.y-n.y)*(l.x-n.x)}}),L.Polyline.include({intersects:function(){var n,r,l,d=this._getProjectedPoints(),p=d?d.length:0;if(this._tooFewPointsForIntersection())return!1;for(n=p-1;n>=3;n--)if(r=d[n-1],l=d[n],this._lineSegmentsIntersectsRange(r,l,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 l=this._getProjectedPoints(),d=l?l.length:0,p=l?l[d-1]:null,_=d-2;return!this._tooFewPointsForIntersection(1)&&this._lineSegmentsIntersectsRange(p,n,_,r?1:0)},_tooFewPointsForIntersection:function(n){var r=this._getProjectedPoints(),l=r?r.length:0;return l+=n||0,!r||l<=3},_lineSegmentsIntersectsRange:function(n,r,l,d){var p,_,v=this._getProjectedPoints();d=d||0;for(var w=l;w>d;w--)if(p=v[w-1],_=v[w],L.LineUtil.segmentsIntersect(n,r,p,_))return!0;return!1},_getProjectedPoints:function(){if(!this._defaultShape)return this._originalPoints;for(var n=[],r=this._defaultShape(),l=0;l<r.length;l++)n.push(this._map.latLngToLayerPoint(r[l]));return n}}),L.Polygon.include({intersects:function(){var n,r,l,d,p=this._getProjectedPoints();return!this._tooFewPointsForIntersection()&&(!!L.Polyline.prototype.intersects.call(this)||(n=p.length,r=p[0],l=p[n-1],d=n-2,this._lineSegmentsIntersectsRange(l,r,d,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,l=L.DomUtil.create("div","leaflet-draw"),d=!1;for(var p in this._toolbars)this._toolbars.hasOwnProperty(p)&&(r=this._toolbars[p].addToolbar(n))&&(d||(L.DomUtil.hasClass(r,"leaflet-draw-toolbar-top")||L.DomUtil.addClass(r.childNodes[0],"leaflet-draw-toolbar-top"),d=!0),l.appendChild(r));return l},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 l in this._toolbars)this._toolbars[l]!==r&&this._toolbars[l].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,l=L.DomUtil.create("div","leaflet-draw-section"),d=0,p=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,d++,p,_[r].title);if(d)return this._lastButtonIndex=--d,this._actionsContainer=L.DomUtil.create("ul","leaflet-draw-actions"),l.appendChild(this._toolbarContainer),l.appendChild(this._actionsContainer),l},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,l=this._actionButtons.length;r<l;r++)this._disposeButton(this._actionButtons[r].button,this._actionButtons[r].callback,this);this._actionButtons=[],this._actionsContainer=null},_initModeHandler:function(n,r,l,d,p){var _=n.type;this._modes[_]={},this._modes[_].handler=n,this._modes[_].button=this._createButton({type:_,title:p,className:d+"-"+_,container:r,callback:this._modes[_].handler.enable,context:this._modes[_].handler}),this._modes[_].buttonIndex=l,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),l=L.DomUtil.create("span","sr-only",n.container);r.href="#",r.appendChild(l),n.title&&(r.title=n.title,l.innerHTML=n.title),n.text&&(r.innerHTML=n.text,l.innerHTML=n.text);var d=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,d,n.callback,n.context),r},_disposeButton:function(n,r){var l=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,l,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,l,d,p,_=this._actionsContainer,v=this.getActions(n),w=v.length;for(l=0,d=this._actionButtons.length;l<d;l++)this._disposeButton(this._actionButtons[l].button,this._actionButtons[l].callback);for(this._actionButtons=[];_.firstChild;)_.removeChild(_.firstChild);for(var x=0;x<w;x++)"enabled"in v[x]&&!v[x].enabled||(r=L.DomUtil.create("li","",_),p=this._createButton({title:v[x].title,text:v[x].text,container:r,callback:v[x].callback,context:v[x].context}),this._actionButtons.push({button:p,callback:v[x].callback}))},_showActionsToolbar:function(){var n=this._activeMode.buttonIndex,r=this._lastButtonIndex,l=this._activeMode.button.offsetTop-1;this._createActions(this._activeMode.handler),this._actionsContainer.style.top=l+"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),l=this._container;return this._container&&(this._visible&&(l.style.visibility="inherit"),L.DomUtil.setPosition(l,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,l=r.getLayers().length!==0;this.options.edit&&(n=this._modes[L.EditToolbar.Edit.TYPE].button,l?L.DomUtil.removeClass(n,"leaflet-disabled"):L.DomUtil.addClass(n,"leaflet-disabled"),n.setAttribute("title",l?L.drawLocal.edit.toolbar.buttons.edit:L.drawLocal.edit.toolbar.buttons.editDisabled)),this.options.remove&&(n=this._modes[L.EditToolbar.Delete.TYPE].button,l?L.DomUtil.removeClass(n,"leaflet-disabled"):L.DomUtil.addClass(n,"leaflet-disabled"),n.setAttribute("title",l?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 l=L.version.split(".");parseInt(l[0],10)===1&&parseInt(l[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,l,d=n.layer||n.target||n;this._backupLayer(d),this.options.poly&&(l=L.Util.extend({},this.options.poly),d.options.poly=l),this.options.selectedPathOptions&&(r=L.Util.extend({},this.options.selectedPathOptions),r.maintainColor&&(r.color=d.options.color,r.fillColor=d.options.fillColor),d.options.original=L.extend({},d.options),d.options.editing=r),d instanceof L.Marker?(d.editing&&d.editing.enable(),d.dragging.enable(),d.on("dragend",this._onMarkerDragEnd).on("touchmove",this._onTouchMove,this).on("MSPointerMove",this._onTouchMove,this).on("touchend",this._onMarkerDragEnd,this).on("MSPointerUp",this._onMarkerDragEnd,this)):d.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],l=this._map.mouseEventToLayerPoint(r),d=this._map.layerPointToLatLng(l);n.target.setLatLng(d)},_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 l=L.version.split(".");parseInt(l[0],10)===1&&parseInt(l[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 Ve={exports:{}},zi;function Lo(){return zi||(zi=1,(function(g,c){(function(a,u){g.exports=a(Ii()),typeof u!="undefined"&&u.L&&(u.L.Ruler=a(L))})(function(a){a.Control.Ruler=a.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(u){return this._map=u,this._container=a.DomUtil.create("div","leaflet-bar"),this._container.classList.add("leaflet-ruler"),a.DomEvent.disableClickPropagation(this._container),a.DomEvent.on(this._container,"click",this._toggleMeasure,this),this._choice=!1,this._defaultCursor=this._map._container.style.cursor,this._allLayers=a.layerGroup(),this._container},onRemove:function(){a.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(),a.DomEvent.on(this._map._container,"keydown",this._escape,this),a.DomEvent.on(this._map._container,"dblclick",this._closePath,this),this._container.classList.add("leaflet-ruler-clicked"),this._clickCount=0,this._tempLine=a.featureGroup().addTo(this._allLayers),this._tempPoint=a.featureGroup().addTo(this._allLayers),this._pointLayer=a.featureGroup().addTo(this._allLayers),this._polylineLayer=a.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(),a.DomEvent.off(this._map._container,"keydown",this._escape,this),a.DomEvent.off(this._map._container,"dblclick",this._closePath,this),this._container.classList.remove("leaflet-ruler-clicked"),this._map.removeLayer(this._allLayers),this._allLayers=a.layerGroup(),this._map._container.style.cursor=this._defaultCursor,this._map.off("click",this._clicked,this),this._map.off("mousemove",this._moving,this))},_clicked:function(u){if(this._clickedLatLong=u.latlng,this._clickedPoints.push(this._clickedLatLong),a.circleMarker(this._clickedLatLong,this.options.circleMarker).addTo(this._pointLayer),this._clickCount>0&&!u.latlng.equals(this._clickedPoints[this._clickedPoints.length-2])){this._movingLatLong&&a.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,a.circleMarker(this._clickedLatLong,this.options.circleMarker).bindTooltip(n,{permanent:!0,className:"result-tooltip"}).addTo(this._pointLayer).openTooltip()}this._clickCount++},_moving:function(u){if(this._clickedLatLong){a.DomEvent.off(this._container,"click",this._toggleMeasure,this),this._movingLatLong=u.latlng,this._tempLine&&(this._map.removeLayer(this._tempLine),this._map.removeLayer(this._tempPoint));var n;this._addedLength=0,this._tempLine=a.featureGroup(),this._tempPoint=a.featureGroup(),this._tempLine.addTo(this._map),this._tempPoint.addTo(this._map),this._calculateBearingAndDistance(),this._addedLength=this._result.Distance+this._totalLength,a.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,a.circleMarker(this._movingLatLong,this.options.circleMarker).bindTooltip(n,{sticky:!0,offset:a.point(0,-40),className:"moving-tooltip"}).addTo(this._tempPoint).openTooltip()}},_escape:function(u){u.keyCode===27&&(this._clickCount>0?this._closePath():(this._choice=!0,this._toggleMeasure()))},_calculateBearingAndDistance:function(){var u=this._clickedLatLong.lat,n=this._clickedLatLong.lng,r=this._movingLatLong.lat,l=this._movingLatLong.lng,d=Math.PI/180,p=Math.sin((l-n)*d)*Math.cos(r*d),_=Math.cos(u*d)*Math.sin(r*d)-Math.sin(u*d)*Math.cos(r*d)*Math.cos((l-n)*d),v=Math.atan2(p,_)*((this.options.angleUnit.factor?this.options.angleUnit.factor/2:180)/Math.PI);v+=v<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-u)*d,P=(l-n)*d,E=Math.sin(x/2)*Math.sin(x/2)+Math.cos(u*d)*Math.cos(r*d)*Math.sin(P/2)*Math.sin(P/2),k=2*Math.atan2(Math.sqrt(E),Math.sqrt(1-E)),Z=w*k;this._result={Bearing:v,Distance:Z}},_closePath:function(){this._map.removeLayer(this._tempLine),this._map.removeLayer(this._tempPoint),this._clickCount<=1&&this._map.removeLayer(this._pointLayer),this._choice=!1,a.DomEvent.on(this._container,"click",this._toggleMeasure,this),this._toggleMeasure()}}),a.control.ruler=function(u){return new a.Control.Ruler(u)}},window)})(Ve)),Ve.exports}Lo();let ye;const bo=new Uint8Array(16);function xo(){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(bo)}const it=[];for(let g=0;g<256;++g)it.push((g+256).toString(16).slice(1));function Ao(g,c=0){return it[g[c+0]]+it[g[c+1]]+it[g[c+2]]+it[g[c+3]]+"-"+it[g[c+4]]+it[g[c+5]]+"-"+it[g[c+6]]+it[g[c+7]]+"-"+it[g[c+8]]+it[g[c+9]]+"-"+it[g[c+10]]+it[g[c+11]]+it[g[c+12]]+it[g[c+13]]+it[g[c+14]]+it[g[c+15]]}const Bi={randomUUID:typeof crypto!="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function We(g,c,a){if(Bi.randomUUID&&!g)return Bi.randomUUID();g=g||{};const u=g.random||(g.rng||xo)();return u[6]=u[6]&15|64,u[8]=u[8]&63|128,Ao(u)}function ko(g){var a,u;const c=(u=g.id)!=null?u:(a=g.properties)==null?void 0:a.id;if(c!=null)return String(c)}function Mo(g,c){const a=u=>{switch(u.type){case"Point":c(u.coordinates);break;case"MultiPoint":case"LineString":for(const n of u.coordinates)c(n);break;case"MultiLineString":case"Polygon":for(const n of u.coordinates)for(const r of n)c(r);break;case"MultiPolygon":for(const n of u.coordinates)for(const r of n)for(const l of r)c(l);break;case"GeometryCollection":for(const n of u.geometries)a(n);break}};a(g)}function Eo(g){const c=g.geometry;if(!c)return null;let a=1/0,u=1/0,n=-1/0,r=-1/0,l=!1;return Mo(c,d=>{const[p,_]=d;typeof p!="number"||typeof _!="number"||(l=!0,p<a&&(a=p),_<u&&(u=_),p>n&&(n=p),_>r&&(r=_))}),l?[a,u,n,r]:null}function Po(g){let c=1/0,a=1/0,u=-1/0,n=-1/0,r=!1;for(const l of g.features){const d=Eo(l);d&&(r=!0,c=Math.min(c,d[0]),a=Math.min(a,d[1]),u=Math.max(u,d[2]),n=Math.max(n,d[3]))}return r?[c,a,u,n]:null}function To(g){const[c,a,u,n]=g;return[[a,c],[n,u]]}function Oi(g){var a;const c=[];for(const u of g.features){if(!u||u.type!=="Feature")continue;const n=(a=u.properties)!=null?a:{},r=u.geometry;if(r)switch(r.type){case"MultiPolygon":for(const l of r.coordinates)c.push({type:"Feature",properties:{...n},geometry:{type:"Polygon",coordinates:l}});break;case"MultiLineString":for(const l of r.coordinates)c.push({type:"Feature",properties:{...n},geometry:{type:"LineString",coordinates:l}});break;case"MultiPoint":for(const l of r.coordinates)c.push({type:"Feature",properties:{...n},geometry:{type:"Point",coordinates:l}});break;case"GeometryCollection":for(const l of r.geometries)c.push({type:"Feature",properties:{...n},geometry:l});break;default:c.push(u);break}}return{type:"FeatureCollection",features:c}}function Ri(g){return(g==null?void 0:g.type)==="Polygon"}function Ui(g){return(g==null?void 0:g.type)==="MultiPolygon"}function Co(g){const c=g.geometry;return c?Ri(c)?[c.coordinates]:Ui(c)?c.coordinates:[]:[]}function So(g,c){var n,r;const a=[];for(const l of g){const d=Co(l);d.length>0&&a.push(...d)}if(a.length===0)return null;const u=(r=c!=null?c:(n=g[0])==null?void 0:n.properties)!=null?r:{};return a.length===1?{type:"Feature",properties:{...u},geometry:{type:"Polygon",coordinates:a[0]}}:{type:"Feature",properties:{...u},geometry:{type:"MultiPolygon",coordinates:a}}}class Do{constructor(c=ve("feature-store","debug")){C(this,"log");C(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,l,d,p;const a=[],u=(l=(r=performance.now)==null?void 0:r.call(performance))!=null?l:Date.now();for(const _ of c.features){const v=this.ensureId(_),w={..._,id:v};this.features.set(v,w),a.push(v)}const n=((p=(d=performance.now)==null?void 0:d.call(performance))!=null?p:Date.now())-u;return this.log.debug("add",{count:c.features.length,ids:a,elapsedMs:Math.round(n)}),a}update(c,a){if(!this.features.has(c)){this.log.warn("update:missing",{id:c});return}const u={...a,id:c};this.features.set(c,u),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 a=Po(c);return a?To(a):null}ensureId(c){const a=ko(c);if(a)return String(a);const u=We();return c.id=u,c.properties&&typeof c.properties=="object"&&(c.properties.id=u),u}}const Le=class Le extends z.Draw.Circle{constructor(c,a){super(c,a),this.type=Le.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"})}};C(Le,"TYPE","cake");let $t=Le;z.Draw.Cake=$t;let Zi=!1;function Io(){var a;if(Zi)return;const g=z.DrawToolbar;if(!((a=g==null?void 0:g.prototype)!=null&&a.getModeHandlers))return;const c=g.prototype.getModeHandlers;g.prototype.getModeHandlers=function(u){var r;const n=c.call(this,u);return(r=this.options)!=null&&r.cake&&n.push({enabled:!0,handler:new $t(u,this.options.cake),title:"Draw Layer Cake (Subtractive Zones)"}),n},Zi=!0}const zo=63710088e-1;function Ye(g){return g*Math.PI/180}function Ni(g){return g*180/Math.PI}function Bo(g,c,a){const u=c/zo,n=Ye(a),r=Ye(g.lat),l=Ye(g.lng),d=Math.sin(r),p=Math.cos(r),_=Math.sin(u),v=Math.cos(u),w=d*v+p*_*Math.cos(n),x=Math.asin(w),P=Math.sin(n)*_*p,E=v-d*w,k=l+Math.atan2(P,E);return{lat:Ni(x),lng:Ni(k)}}function Oo(g){let c=0;for(let a=0;a<g.length-1;a++){const[u,n]=g[a],[r,l]=g[a+1];c+=u*l-r*n}return c/2}function qe(g){const c=g[0],a=g.at(-1);return!c||!a||c[0]===a[0]&&c[1]===a[1]?g:[...g,c]}function je(g,c){const a=qe(g);if(Oo(a)<0===c)return a;const r=[...a].reverse();return qe(r)}function Ke(g,c,a){if(a<4)throw new Error("steps must be >= 4");const u=[];for(let n=0;n<a;n++){const r=n/a*360,l=Bo(g,c,r);u.push([l.lng,l.lat])}return qe(u)}function Ro(g){const{id:c,center:a,radiusMeters:u,layerIndex:n,steps:r}=g,l=je(Ke(a,u,r),!1);return{type:"Feature",properties:{id:c,layer_index:n,radius_outer:u,type:"core",_meta:{lat:a.lat,lng:a.lng,radius:u}},geometry:{type:"Polygon",coordinates:[l]}}}function Uo(g){const{id:c,center:a,radiusOuterMeters:u,radiusInnerMeters:n,layerIndex:r,steps:l}=g,d=je(Ke(a,u,l),!1),p=je(Ke(a,n,l),!0);return{type:"Feature",properties:{id:c,layer_index:r,radius_outer:u,type:"ring",_meta:{lat:a.lat,lng:a.lng,radius:u}},geometry:{type:"Polygon",coordinates:[d,p]}}}function Zo(g){const{circles:c,steps:a=64}=g,u=[...c].sort((r,l)=>r.getRadius()-l.getRadius()),n=[];return u.forEach((r,l)=>{const d=r.getLatLng(),p=r.getRadius(),_=We();if(l===0){n.push(Ro({id:_,center:d,radiusMeters:p,layerIndex:l,steps:a}));return}const w=u[l-1].getRadius();n.push(Uo({id:_,center:d,radiusOuterMeters:p,radiusInnerMeters:w,layerIndex:l,steps:a}))}),{type:"FeatureCollection",features:n}}function te(g){g.preventDefault(),g.stopPropagation()}function No(g){var _,v;const{root:c,addButtonId:a,saveButtonId:u,onAddRing:n,onSave:r}=g,l=(_=c.querySelector)==null?void 0:_.call(c,`#${a}`),d=(v=c.querySelector)==null?void 0:v.call(c,`#${u}`);if(!l||!d)return;const p="data-cake-controls-bound";if(!(l.hasAttribute(p)||d.hasAttribute(p))){l.setAttribute(p,"true"),d.setAttribute(p,"true");for(const w of[l,d])w.addEventListener("pointerdown",te),w.addEventListener("mousedown",te),w.addEventListener("touchstart",te);l.addEventListener("click",w=>{te(w),n()}),d.addEventListener("click",w=>{te(w),r()})}}function Ho(g){var a;const c=(a=g.options)!=null?a:{};c.original||(c.original={...c}),c.editing||(c.editing={...c})}function ee(g,c){if(c==="imperial"){const a=g*3.28084;return a>=5280?`${(a/5280).toFixed(2)} mi`:`${Math.round(a)} ft`}return g>=1e3?`${(g/1e3).toFixed(2)} km`:`${Math.round(g)} m`}class Fo{constructor(c,a,u,n="metric"){C(this,"map");C(this,"layers",[]);C(this,"controlsGroup");C(this,"onSave");C(this,"sessionId",We().slice(0,8));C(this,"baseCircleOptions");C(this,"detachMapListeners",[]);C(this,"renderScheduled",!1);C(this,"measurementSystem");this.map=c,this.onSave=u,this.measurementSystem=n,this.controlsGroup=z.layerGroup().addTo(c),this.baseCircleOptions={...a.options},delete this.baseCircleOptions.editing,delete this.baseCircleOptions.original,this.addLayer(a),this.installEditEventBridges(),this.renderControls()}installEditEventBridges(){var v,w,x,P,E,k,Z,F;const c=Ge,a=(w=(v=c==null?void 0:c.Draw)==null?void 0:v.Event)==null?void 0:w.EDITMOVE,u=(P=(x=c==null?void 0:c.Draw)==null?void 0:x.Event)==null?void 0:P.EDITRESIZE,n=(k=(E=c==null?void 0:c.Draw)==null?void 0:E.Event)==null?void 0:k.EDITSTART,r=(F=(Z=c==null?void 0:c.Draw)==null?void 0:Z.Event)==null?void 0:F.EDITSTOP;if(!a||!u)return;const l=I=>{const S=I==null?void 0:I.layer;S&&this.layers.includes(S)&&this.syncCenters(S)},d=I=>{const S=I==null?void 0:I.layer;S&&this.layers.includes(S)&&(this.updateLabels(S),this.requestRenderControls())},p=I=>{var tt;const S=I==null?void 0:I.layer;if(!S||!this.layers.includes(S))return;const V=S;((tt=V.getTooltip)==null?void 0:tt.call(V))&&this.updateLabels(V)},_=()=>{this.layers.forEach(I=>{var V;const S=(V=I.getTooltip)==null?void 0:V.call(I);S&&(I.setTooltipContent(ee(I.getRadius(),this.measurementSystem)),S.options.offset=[10,0],S.options.direction="right",I.closeTooltip(),I.openTooltip())})};this.map.on(a,l),this.map.on(u,d),n&&(this.map.on(n,p),this.detachMapListeners.push(()=>this.map.off(n,p))),r&&(this.map.on(r,_),this.detachMapListeners.push(()=>this.map.off(r,_))),this.detachMapListeners.push(()=>this.map.off(a,l)),this.detachMapListeners.push(()=>this.map.off(u,d))}requestRenderControls(){if(this.renderScheduled)return;this.renderScheduled=!0,(typeof requestAnimationFrame=="function"?requestAnimationFrame:a=>setTimeout(()=>a(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 a=c.editing;setTimeout(()=>{var u,n,r,l,d;try{if((u=c.redraw)==null||u.call(c),Ho(c),(n=a==null?void 0:a.enabled)!=null&&n.call(a)){(r=a.updateMarkers)==null||r.call(a),this.requestRenderControls();return}(l=a==null?void 0:a.enable)==null||l.call(a),(d=a==null?void 0:a.updateMarkers)==null||d.call(a),this.requestRenderControls()}catch{}},0)}addRing(){if(this.layers.length>=10)return;const c=this.getLargestCircle();if(!c)return;const a=c.getRadius()*1.5,u=z.circle(c.getLatLng(),{...this.baseCircleOptions,radius:a});this.addLayer(u),this.renderControls()}save(){const c=Zo({circles:this.layers});this.onSave(c),this.destroy()}getLargestCircle(){return this.layers.length===0?null:this.layers.reduce((c,a)=>c.getRadius()>a.getRadius()?c:a)}syncCenters(c){const a=c.getLatLng();this.layers.forEach(u=>{var n,r,l;u!==c&&(u.setLatLng(a),(n=u.redraw)==null||n.call(u),(l=(r=u.editing)==null?void 0:r.updateMarkers)==null||l.call(r))}),this.requestRenderControls()}updateLabels(c){var l;const a=c.getRadius();let u=ee(a,this.measurementSystem);const n=this.layers.filter(d=>d!==c&&d.getRadius()<a);if(n.length>0){const d=n.reduce((v,w)=>v.getRadius()>w.getRadius()?v:w),p=a-d.getRadius(),_=ee(p,this.measurementSystem);u=`${ee(a,this.measurementSystem)} (+${_})`}const r=(l=c.getTooltip)==null?void 0:l.call(c);if(r){c.setTooltipContent(u);const p=c.getBounds().getSouthWest();p.lat=c.getLatLng().lat,r.options.direction="left",r.options.offset=[-10,0],r.setLatLng(p),c.closeTooltip(),c.openTooltip()}}renderControls(){this.controlsGroup.clearLayers();const c=this.getLargestCircle();if(!c)return;const u=c.getBounds().getNorthEast(),n=`cake-add-${this.sessionId}`,r=`cake-save-${this.sessionId}`,l=z.divIcon({className:"layer-cake-controls",html:`
|
|
184
|
+
<div class="layer-cake-controls__container">
|
|
185
|
+
<button id="${n}" type="button">➕ Ring</button>
|
|
186
|
+
<button id="${r}" type="button" class="layer-cake-controls__save">💾 Save</button>
|
|
187
|
+
</div>
|
|
188
|
+
`,iconSize:[140,40],iconAnchor:[-10,20]});z.marker(u,{icon:l,interactive:!0,keyboard:!1,bubblingMouseEvents:!1}).addTo(this.controlsGroup),setTimeout(()=>{const d=this.map.getContainer();No({root:d,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 Hi=6378137,Ht=6356752314245e-6,Bt=1/298.257223563,Go=Math.PI/180,Vo=180/Math.PI,we=1e9;function Wo(g){const c=BigInt(Math.round(g*we));return Number(c)/we}function Ft(g){return Wo(g)*Go}function Fi(g){const c=g*Vo%360;return c<0?c+360:c}function Je(g){const c=BigInt(Math.round(g*we));return Number(c)/we}function Yo(g,c,a,u){const n=qo(g,c,a,u);if(n.converged)return{meters:Je(n.distanceMeters),bearingDegrees:Fi(n.bearingRad),algorithm:"vincenty",iterations:n.iterations};const r=jo(g,c,a,u);return{meters:Je(r.distanceMeters),bearingDegrees:Fi(r.bearingRad),algorithm:"karney",iterations:n.iterations}}function qo(g,c,a,u){const n=Ft(g),r=Ft(a),l=Ft(u-c),d=Math.atan((1-Bt)*Math.tan(n)),p=Math.atan((1-Bt)*Math.tan(r)),_=Math.sin(d),v=Math.cos(d),w=Math.sin(p),x=Math.cos(p);let P=l,E=0,k=0;const Z=200;let F=0,I=0,S=0,V=0,q=0,tt=0;for(;Math.abs(P-E)>1e-12&&k<Z;){const xe=Math.sin(P),pt=Math.cos(P);if(F=Math.sqrt((x*xe)**2+(v*w-_*x*pt)**2),F===0)return{distanceMeters:0,bearingRad:0,iterations:k,converged:!0};I=_*w+v*x*pt,S=Math.atan2(F,I),V=v*x*xe/F,q=1-V**2,tt=q===0?0:I-2*_*w/q;const ie=Bt/16*q*(4+Bt*(4-3*q));E=P,P=l+(1-ie)*Bt*V*(S+ie*F*(tt+ie*I*(-1+2*tt**2))),k+=1}if(k>=Z)return{distanceMeters:Number.NaN,bearingRad:0,iterations:k,converged:!1};const ot=(Hi**2-Ht**2)/Ht**2*q,At=1+ot/16384*(4096+ot*(-768+ot*(320-175*ot))),Ct=ot/1024*(256+ot*(-128+ot*(74-47*ot))),be=Ct*F*(tt+Ct/4*(I*(-1+2*tt**2)-Ct/6*tt*(-3+4*F**2)*(-3+4*tt**2))),rt=Ht*At*(S-be),at=Math.atan2(x*Math.sin(P),v*w-_*x*Math.cos(P));return{distanceMeters:rt,bearingRad:at,iterations:k,converged:!0}}function jo(g,c,a,u){const n=Ft(g),r=Ft(a),l=Ft(u-c),d=Math.atan((1-Bt)*Math.tan(n)),p=Math.atan((1-Bt)*Math.tan(r)),_=Math.sin(d),v=Math.cos(d),w=Math.sin(p),x=Math.cos(p),P=Math.sqrt((x*Math.sin(l))**2+(v*w-_*x*Math.cos(l))**2),E=_*w+v*x*Math.cos(l),k=Math.atan2(P,E);if(k===0)return{distanceMeters:0,bearingRad:0};const F=1-(v*x*Math.sin(l)/Math.sin(k))**2,I=F===0?0:E-2*_*w/F,S=(Hi**2-Ht**2)/Ht**2*F,V=1+S/16384*(4096+S*(-768+S*(320-175*S))),q=S/1024*(256+S*(-128+S*(74-47*S))),tt=q*P*(I+q/4*(E*(-1+2*I**2)-q/6*I*(-3+4*P**2)*(-3+4*I**2))),ot=Ht*V*(k-tt),At=Math.atan2(x*Math.sin(l),v*w-_*x*Math.cos(l));return{distanceMeters:ot,bearingRad:At}}const Ko={position:"topleft",circleMarker:{color:"red",radius:2},lineStyle:{color:"red",dashArray:"1,6"},angleUnit:{display:"°",decimal:2,factor:null,label:"Bearing:"}},Jo={display:"km",decimal:2,factor:null,label:"Distance (km):"},Xo={display:"mi",decimal:2,factor:.621371,label:"Distance (mi):"};function Qo(g){const c=g==="imperial"?{...Xo}:{...Jo};return{...Ko,lengthUnit:c}}const $o={metric:"Meters / Kilometers",imperial:"Feet / Miles"};let Gi=!1;class tr{constructor(c){C(this,"container");C(this,"logger");C(this,"options");C(this,"store");C(this,"map",null);C(this,"drawnItems",null);C(this,"drawControl",null);C(this,"rulerControl",null);C(this,"measurementControl",null);C(this,"measurementSystem","metric");C(this,"measurementModalOverlay",null);C(this,"measurementModalDialog",null);C(this,"measurementModalRadios",{});C(this,"measurementModalKeydownHandler",null);C(this,"detachPolygonFinishPatch",null);C(this,"vertexMenuEl",null);C(this,"vertexMenuCleanup",null);C(this,"activeCakeSession",null);var a;this.options=c,this.container=c.container,this.logger=((a=c.logger)!=null?a:ve("controller","debug")).child("map"),this.store=new Do(this.logger.child("store")),this.logger.debug("ctor",{config:c.map,controls:c.controls,readOnly:c.readOnly}),Io()}async init(){var a,u,n,r,l,d;const c=(u=(a=performance.now)==null?void 0:a.call(performance))!=null?u:Date.now();try{await this.destroy();const{latitude:p,longitude:_,zoom:v,minZoom:w,maxZoom:x,tileUrl:P,tileAttribution:E,preferCanvas:k=!0}=this.options.map,Z=[p,_];this.map=z.map(this.container,{zoomControl:!0,preferCanvas:k}).setView(Z,v),z.tileLayer(P,{attribution:E,minZoom:w,maxZoom:x}).addTo(this.map),this.drawnItems=z.featureGroup().addTo(this.map);const F=this.buildDrawOptions(this.options.controls,!!this.options.readOnly),I=z.Control.Draw;this.drawControl=new I(F),this.map.addControl(this.drawControl),this.options.controls.ruler&&(this.logger.debug("init:ruler",{available:typeof z.control.ruler=="function"}),typeof z.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 q;try{(q=this.map)==null||q.invalidateSize()}catch{}},0),this.bindDrawEvents();const S=((r=(n=performance.now)==null?void 0:n.call(performance))!=null?r:Date.now())-c;this.logger.debug("init:ready",{elapsedMs:Math.round(S)});const V=this.store.bounds();(d=(l=this.options.callbacks)==null?void 0:l.onReady)==null||d.call(l,V?{bounds:V}:{})}catch(p){this._error("Failed to initialize Leaflet map",p)}}async destroy(){var c,a,u;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{(a=this.vertexMenuCleanup)==null||a.call(this)}catch{}this.vertexMenuEl=null,this.vertexMenuCleanup=null,this.drawControl=null,this.rulerControl=null,this.measurementControl=null,this.removeMeasurementModal(),this.drawnItems=null;try{(u=this.activeCakeSession)==null||u.destroy()}catch{}this.activeCakeSession=null,this.map=null}async getGeoJSON(){return this.store.toFeatureCollection()}async loadGeoJSON(c,a=!1){if(!this.map||!this.drawnItems)return;await this.clearLayers();const u=Oi(c),n=this.store.add(u),r=z.geoJSON(u);let l=0;r.eachLayer(d=>{var p;d._fid=(p=n[l])!=null?p:n[n.length-1],this.drawnItems.addLayer(d),this.installVertexContextMenu(d),l++}),this.logger.debug("loadGeoJSON",{count:u.features.length,ids:n}),a&&await this.fitBoundsToData()}async clearLayers(){this.drawnItems&&this.drawnItems.clearLayers(),this.store.clear()}async addFeatures(c){if(!this.map||!this.drawnItems)return[];const a=Oi(c),u=this.store.add(a),n=z.geoJSON(a);let r=0;return n.eachLayer(l=>{var d;l._fid=(d=u[r])!=null?d:u[u.length-1],this.drawnItems.addLayer(l),this.installVertexContextMenu(l),r++}),u}async updateFeature(c,a){this.store.update(c,a)}async removeFeature(c){this.drawnItems&&this.drawnItems.eachLayer(a=>{a._fid===c&&this.drawnItems.removeLayer(a)}),this.store.remove(c)}async fitBoundsToData(c=.05){if(!this.map)return;const a=this.store.bounds();if(!a)return;const u=a,n=z.latLngBounds(u);if(c>0){const r=n.getSouthWest(),l=n.getNorthEast(),d=(l.lat-r.lat)*c,p=(l.lng-r.lng)*c,_=z.latLngBounds(z.latLng(r.lat-d,r.lng-p),z.latLng(l.lat+d,l.lng+p));this.map.fitBounds(_)}else this.map.fitBounds(n)}async fitBounds(c,a=.05){if(!this.map)return;const u=z.latLngBounds(c);if(a>0){const n=u.getSouthWest(),r=u.getNorthEast(),l=(r.lat-n.lat)*a,d=(r.lng-n.lng)*a,p=z.latLngBounds(z.latLng(n.lat-l,n.lng-d),z.latLng(r.lat+l,r.lng+d));this.map.fitBounds(p)}else this.map.fitBounds(u)}async setView(c,a,u){this.map&&this.map.setView([c,a],u!=null?u:this.map.getZoom())}async mergeVisiblePolygons(c){if(!this.map||!this.drawnItems)return null;const u=(await this.getGeoJSON()).features.filter(d=>{const p=d.geometry;return p&&(Ri(p)||Ui(p))});if(u.length<=1){if(u.length===1){const d=u[0].id;return d?String(d):null}return null}const n=So(u,c==null?void 0:c.properties);if(!n)return null;const r=[];for(const d of u){const p=d.id;p&&r.push(String(p))}for(const d of r)await this.removeFeature(d);const[l]=await this.addFeatures({type:"FeatureCollection",features:[n]});return l||null}setRulerUnits(c){this.measurementSystem!==c&&(this.measurementSystem=c,this.logger.debug("ruler:units",{system:c}),this.syncMeasurementModalState(),this.rebuildRulerControl())}buildDrawOptions(c,a){var r;const u={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};let n={featureGroup:this.drawnItems};return c.edit?c.delete===!1&&(n.remove=!1):n=!1,a?{draw:!1,edit:!1}:{draw:u,edit:n}}addRulerControl(){if(!this.map)return;this.installRulerPrecisionPatch();const c=Qo(this.measurementSystem);this.rulerControl=z.control.ruler(c),this.map.addControl(this.rulerControl)}installRulerPrecisionPatch(){if(Gi)return;const c=z.Control.Ruler;if(!c||typeof c!="function")return;const a=c.prototype,u=a._calculateBearingAndDistance;if(typeof u!="function")return;const n=this.logger;a._calculateBearingAndDistance=function(){var l,d,p;u.call(this);try{const _=this._clickedLatLong,v=(l=this._movingLatLong)!=null?l:this._clickedLatLong;if(!_||!v)return;const{meters:w,bearingDegrees:x}=Yo(_.lat,_.lng,v.lat,v.lng),P=w/1e3,E=typeof((p=(d=this.options)==null?void 0:d.lengthUnit)==null?void 0:p.factor)=="number"?this.options.lengthUnit.factor:1,k=Je(P*E);this._result=this._result||{},this._result.Distance=k,this._result.Bearing=x,this._result.meters=w}catch(_){n==null||n.warn("ruler:precision-patch",_)}},Gi=!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,a=z.Control.extend({options:{position:"topleft"},onAdd(){const u=z.DomUtil.create("div","leaflet-bar leaflet-ruler-settings-control"),n=z.DomUtil.create("button","leaflet-ruler-settings-button",u);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)}),z.DomEvent.disableClickPropagation(u),z.DomEvent.disableScrollPropagation(u),u}});this.measurementControl=new a,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 a=document.createElement("div");a.className="leaflet-ruler-modal",a.setAttribute("role","dialog"),a.setAttribute("aria-modal","true"),a.tabIndex=-1,c.addEventListener("click",p=>{p.target===c&&this.toggleMeasurementModal(!1)});const u=document.createElement("h2");u.className="leaflet-ruler-modal-title",u.textContent="Measurement Units",a.appendChild(u);const n=document.createElement("p");n.className="leaflet-ruler-modal-description",n.textContent="Choose how the measurement tool reports distances.",a.appendChild(n);const r=document.createElement("div");r.className="leaflet-ruler-modal-options",a.appendChild(r),["metric","imperial"].forEach(p=>{const _=document.createElement("label");_.className="leaflet-ruler-modal-option";const v=document.createElement("input");v.type="radio",v.name="leaflet-ruler-units",v.value=p,v.addEventListener("change",()=>{v.checked&&this.setRulerUnits(p)});const w=document.createElement("span");w.textContent=$o[p],_.appendChild(v),_.appendChild(w),r.appendChild(_),this.measurementModalRadios[p]=v});const l=document.createElement("div");l.className="leaflet-ruler-modal-actions";const d=document.createElement("button");return d.type="button",d.className="leaflet-ruler-modal-close",d.textContent="Close",d.addEventListener("click",()=>this.toggleMeasurementModal(!1)),l.appendChild(d),a.appendChild(l),c.appendChild(a),this.container.appendChild(c),this.measurementModalOverlay=c,this.measurementModalDialog=a,this.syncMeasurementModalState(),c}toggleMeasurementModal(c){var u;if(!c){this.measurementModalOverlay&&(this.measurementModalOverlay.classList.remove("is-open"),this.measurementModalOverlay.setAttribute("aria-hidden","true")),this.detachMeasurementModalKeydown();return}const a=this.ensureMeasurementModal();a.classList.add("is-open"),a.setAttribute("aria-hidden","false"),this.syncMeasurementModalState(),this.attachMeasurementModalKeydown(),(u=this.measurementModalDialog)==null||u.focus()}syncMeasurementModalState(){for(const[c,a]of Object.entries(this.measurementModalRadios))a&&(a.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 l,d,p,_,v;if(!this.map||!this.drawControl)return;try{(l=this.detachPolygonFinishPatch)==null||l.call(this)}catch{}this.detachPolygonFinishPatch=null;const c=this.map,a=(p=(d=this.drawControl)==null?void 0:d._toolbars)==null?void 0:p.draw;if(!a||!!!((v=(_=a._modes)==null?void 0:_.polygon)!=null&&v.handler))return;const n=10,r=w=>{var x,P,E,k,Z,F,I,S;try{const V=(P=(x=a._modes)==null?void 0:x.polygon)==null?void 0:P.handler;if(!V||!V._enabled)return;const q=V._markers;if(!Array.isArray(q)||q.length<4)return;const tt=(k=(E=q[0])==null?void 0:E.getLatLng)==null?void 0:k.call(E);if(!tt)return;const ot=c.latLngToContainerPoint(tt),At=c.latLngToContainerPoint(w.latlng);Math.hypot(ot.x-At.x,ot.y-At.y)<=n&&typeof V._finishShape=="function"&&((F=(Z=w.originalEvent)==null?void 0:Z.preventDefault)==null||F.call(Z),(S=(I=w.originalEvent)==null?void 0:I.stopPropagation)==null||S.call(I),V._finishShape())}catch(V){this._error("polygon-finish-patch",V)}};c.on("click",r),this.detachPolygonFinishPatch=()=>{try{c.off("click",r)}catch{}}}patchLeafletDrawBugs(){var c,a,u,n,r;try{const l=Ge,d=l.GeometryUtil;if(!d)return;const p={km:2,ha:2,m:0,mi:2,ac:2,yd:0,ft:0,nm:2},_=(a=(c=d.formattedNumber)==null?void 0:c.bind(d))!=null?a:((v,w)=>Number(v).toFixed(w));d.readableArea=(v,w,x)=>{var k;const P=(k=l.Util)!=null&&k.extend?l.Util.extend({},p,x||{}):{...p,...x||{}};let E;if(w){let Z=["ha","m"];const F=typeof w;F==="string"?Z=[w]:F!=="boolean"&&(Z=Array.isArray(w)?w:Z),v>=1e6&&Z.indexOf("km")!==-1?E=`${_(1e-6*v,P.km)} km²`:v>=1e4&&Z.indexOf("ha")!==-1?E=`${_(1e-4*v,P.ha)} ha`:E=`${_(v,P.m)} m²`}else v=v/.836127,v>=3097600?E=`${_(v/3097600,P.mi)} mi²`:v>=4840?E=`${_(v/4840,P.ac)} acres`:E=`${_(v,P.yd)} yd²`;return E}}catch(l){this.logger.warn("leaflet-draw-patch:readableArea",l)}try{const l=Ge,d=(u=l.Edit)==null?void 0:u.Circle,p=(n=l.Draw)==null?void 0:n.Event,_=l.GeometryUtil;if(!((r=d==null?void 0:d.prototype)!=null&&r._resize)||!p||!_)return;d.prototype._resize=function(w){var E,k,Z;const x=this._moveMarker.getLatLng(),P=_.isVersion07x()?x.distanceTo(w):this._map.distance(x,w);this._shape.setRadius(P);try{(E=this._map)!=null&&E.editTooltip&&((Z=(k=this._map)==null?void 0:k._editTooltip)!=null&&Z.updateContent)&&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+": "+_.readableDistance(P,!0,this.options.feet,this.options.nautic)})}catch{}this._map.fire(p.EDITRESIZE,{layer:this._shape})}}catch(l){this.logger.warn("leaflet-draw-patch:circle-resize",l)}}bindDrawEvents(){!this.map||!this.drawnItems||(this.map.on(z.Draw.Event.CREATED,c=>{var a,u,n;try{const{layer:r,layerType:l}=c;if(l===$t.TYPE){try{(a=this.activeCakeSession)==null||a.destroy()}catch{}this.activeCakeSession=new Fo(this.map,r,v=>{if(!this.drawnItems)return;const w=this.store.add(v),x=z.geoJSON(v);let P=0;x.eachLayer(E=>{var Z,F,I;const k=(Z=w[P])!=null?Z:w[w.length-1];E._fid=k,this.drawnItems.addLayer(E),this.installVertexContextMenu(E),(I=(F=this.options.callbacks)==null?void 0:F.onCreated)==null||I.call(F,{id:k,layerType:"polygon",geoJSON:E.toGeoJSON()}),P++}),this.activeCakeSession=null},this.measurementSystem);return}this.drawnItems.addLayer(r);const d=r.toGeoJSON(),_=this.store.add({type:"FeatureCollection",features:[d]})[0];r._fid=_,this.installVertexContextMenu(r),(n=(u=this.options.callbacks)==null?void 0:u.onCreated)==null||n.call(u,{id:_,layerType:l,geoJSON:d})}catch(r){this._error("onCreated handler failed",r)}}),this.map.on(z.Draw.Event.EDITED,c=>{var a,u;try{const n=[];c.layers.eachLayer(l=>{const d=l.toGeoJSON(),p=l._fid;if(p)this.store.update(p,d),n.push(p);else{const _=this.store.add({type:"FeatureCollection",features:[d]})[0];l._fid=_,n.push(_)}}),(u=(a=this.options.callbacks)==null?void 0:a.onEdited)==null||u.call(a,{ids:n,geoJSON:this.store.toFeatureCollection()})}catch(n){this._error("onEdited handler failed",n)}}),this.map.on(z.Draw.Event.DELETED,c=>{var a,u;try{const n=[];c.layers.eachLayer(l=>{const d=l._fid;d&&(n.push(d),this.store.remove(d))}),(u=(a=this.options.callbacks)==null?void 0:a.onDeleted)==null||u.call(a,{ids:n,geoJSON:this.store.toFeatureCollection()})}catch(n){this._error("onDeleted handler failed",n)}}))}_error(c,a){var u,n;this.logger.error("error",{message:c,cause:a}),(n=(u=this.options.callbacks)==null?void 0:u.onError)==null||n.call(u,{message:c,cause:a})}installVertexContextMenu(c){if(!c||typeof c.on!="function")return;const a=n=>{var r,l,d,p;try{(l=(r=n==null?void 0:n.originalEvent)==null?void 0:r.preventDefault)==null||l.call(r),(p=(d=n==null?void 0:n.originalEvent)==null?void 0:d.stopPropagation)==null||p.call(d)}catch{}this.openVertexMenu(c,n)},u=n=>{const r=n==null?void 0:n.originalEvent;r&&(r.ctrlKey||r.metaKey)&&this.openVertexMenu(c,n)};try{c.on("contextmenu",a),c.on("click",u)}catch{}}openVertexMenu(c,a){try{if(!this.map||!(typeof c.getLatLngs=="function"&&(c instanceof z.Polygon||c instanceof z.Polyline)))return;const n=c.editing;if(!n||typeof n.enabled!="function"||!n.enabled())return;const r=a==null?void 0:a.latlng,l=this.map.latLngToContainerPoint(r),d=this.findNearestVertex(c,r,12);if(!d)return;this.showVertexMenu(l,async()=>{await this.deleteVertex(c,d.pathIndex,d.vertexIndex)})}catch(u){this._error("openVertexMenu",u)}}showVertexMenu(c,a){var u;try{try{(u=this.vertexMenuCleanup)==null||u.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",p=>{p.stopPropagation(),p.preventDefault();try{a()}finally{l()}}),n.appendChild(r);const l=()=>{try{window.removeEventListener("pointerdown",d),this.container.removeEventListener("scroll",l,!0),n.remove()}catch{}this.vertexMenuEl=null,this.vertexMenuCleanup=null},d=p=>{n.contains(p.target)||l()};window.addEventListener("pointerdown",d,{capture:!0}),this.container.addEventListener("scroll",l,!0),this.container.appendChild(n),this.vertexMenuEl=n,this.vertexMenuCleanup=l}catch(n){this._error("showVertexMenu",n)}}findNearestVertex(c,a,u){if(!this.map)return null;const n=x=>this.map.latLngToContainerPoint(x),r=(x,P)=>Math.hypot(x.x-P.x,x.y-P.y),l=n(a);let d=1/0,p=-1,_=-1;const v=c.getLatLngs();return(Array.isArray(v[0])?v:[v]).forEach((x,P)=>{x.forEach((E,k)=>{const Z=n(E),F=r(Z,l);F<d&&(d=F,p=P,_=k)})}),p===-1||d>u?null:{pathIndex:p,vertexIndex:_}}async deleteVertex(c,a,u){var n,r,l;try{if(!(typeof c.getLatLngs=="function"&&(c instanceof z.Polygon||c instanceof z.Polyline)))return;const p=c.getLatLngs(),_=Array.isArray(p[0])?p:[p],v=_[a];if(!v)return;const x=c instanceof z.Polygon?3:2;if(v.length<=x)return;if(v.splice(u,1),_.length===1)c.setLatLngs(v);else{const E=_.map((k,Z)=>Z===a?v:k);c.setLatLngs(E)}(n=c.redraw)==null||n.call(c);const P=c._fid;if(P){const E=c.toGeoJSON();this.store.update(P,E),(l=(r=this.options.callbacks)==null?void 0:r.onEdited)==null||l.call(r,{ids:[P],geoJSON:this.store.toFeatureCollection()})}}catch(d){this._error("deleteVertex",d)}}}class Xe extends HTMLElement{constructor(){super();C(this,"_root");C(this,"_container");C(this,"_logger",ve("component:leaflet-geokit","debug"));C(this,"_latitude",0);C(this,"_longitude",0);C(this,"_zoom",2);C(this,"_minZoom");C(this,"_maxZoom");C(this,"_tileUrl","https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png");C(this,"_tileAttribution");C(this,"_readOnly",!1);C(this,"_logLevel","debug");C(this,"_devOverlay",!1);C(this,"_polygonAllowIntersection",!1);C(this,"_preferCanvas",!0);C(this,"_controller",null);this._root=this.attachShadow({mode:"open"}),this._root.innerHTML=`
|
|
189
|
+
<style>
|
|
190
|
+
:host {
|
|
191
|
+
display: block;
|
|
192
|
+
contain: content;
|
|
193
|
+
}
|
|
194
|
+
.map-container {
|
|
195
|
+
width: 100%;
|
|
196
|
+
height: 100%;
|
|
197
|
+
position: relative;
|
|
198
|
+
}
|
|
199
|
+
</style>
|
|
200
|
+
<div class="map-container" part="map"></div>
|
|
201
|
+
`;const a=this._root.querySelector(".map-container");if(!(a instanceof HTMLDivElement))throw new Error("Failed to initialize map container");this._container=a;const u=this.getAttribute("log-level");u&&(this._logLevel=u,this._logger.setLevel(u))}_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"),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}}async connectedCallback(){this._logger.debug("connectedCallback",this._currentConfig());try{yo(this._root),wo()}catch(a){this._logger.warn("leaflet-style-inject-failed",a)}this._controller=new tr({container:this._container,map:this._mapConfig(),controls:this._controlsFromAttributes(),readOnly:this._readOnly,logger:this._logger.child("controller"),callbacks:{onReady:a=>{this.dispatchEvent(new CustomEvent("leaflet-draw:ready",{detail:a}))},onCreated:a=>{this.dispatchEvent(new CustomEvent("leaflet-draw:created",{detail:a}))},onEdited:a=>{this.dispatchEvent(new CustomEvent("leaflet-draw:edited",{detail:a}))},onDeleted:a=>{this.dispatchEvent(new CustomEvent("leaflet-draw:deleted",{detail:a}))},onError:a=>{this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:a}))}}}),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","draw-polygon","draw-polyline","draw-rectangle","draw-circle","draw-layer-cake","draw-marker","draw-ruler","edit-features","delete-features","polygon-allow-intersection"]}attributeChangedCallback(a,u,n){switch(this._logger.debug("attributeChanged",{name:a,value:n}),a){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"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}this._controller&&(a==="latitude"||a==="longitude"||a==="zoom"?this._controller.setView(this._latitude,this._longitude,this._zoom):(a==="tile-url"||a==="tile-attribution"||a==="min-zoom"||a==="max-zoom"||a==="read-only"||a==="dev-overlay"||a==="log-level"||a==="prefer-canvas"||a.startsWith("draw-")||a==="edit-features"||a==="delete-features")&&this._controller.destroy().then(()=>this._controller.init()))}get latitude(){return this._latitude}set latitude(a){this._latitude=Number(a),this._reflect("latitude",String(this._latitude))}get longitude(){return this._longitude}set longitude(a){this._longitude=Number(a),this._reflect("longitude",String(this._longitude))}get zoom(){return this._zoom}set zoom(a){this._zoom=Number(a),this._reflect("zoom",String(this._zoom))}get minZoom(){return this._minZoom}set minZoom(a){this._minZoom=a,this._reflect("min-zoom",a!=null?String(a):null)}get maxZoom(){return this._maxZoom}set maxZoom(a){this._maxZoom=a,this._reflect("max-zoom",a!=null?String(a):null)}get tileUrl(){return this._tileUrl}set tileUrl(a){this._tileUrl=a,this._reflect("tile-url",a)}get tileAttribution(){return this._tileAttribution}set tileAttribution(a){this._tileAttribution=a,this._reflect("tile-attribution",a!=null?a:null)}get readOnly(){return this._readOnly}set readOnly(a){this._readOnly=!!a,this._booleanReflect("read-only",this._readOnly)}get logLevel(){return this._logLevel}set logLevel(a){this._logLevel=a,this._logger.setLevel(a),this._reflect("log-level",a)}get devOverlay(){return this._devOverlay}set devOverlay(a){this._devOverlay=!!a,this._booleanReflect("dev-overlay",this._devOverlay)}get preferCanvas(){return this._preferCanvas}set preferCanvas(a){this._preferCanvas=!!a,this._booleanReflect("prefer-canvas",this._preferCanvas)}async getGeoJSON(){return this._logger.debug("getGeoJSON"),this._controller?this._controller.getGeoJSON():{type:"FeatureCollection",features:[]}}async loadGeoJSON(a){var r,l;if(this._logger.debug("loadGeoJSON",{features:(l=(r=a==null?void 0:a.features)==null?void 0:r.length)!=null?l:0}),!this._controller)return;const u={fc:a,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:u}));const n=u.fc&&u.fc.type==="FeatureCollection"?u.fc:a;await this._controller.loadGeoJSON(n,!1)}async clearLayers(){this._logger.debug("clearLayers"),this._controller&&await this._controller.clearLayers()}async addFeatures(a){var r,l;if(this._logger.debug("addFeatures",{count:(l=(r=a==null?void 0:a.features)==null?void 0:r.length)!=null?l:0}),!this._controller)return[];const u={fc:a,mode:"add"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:u}));const n=u.fc&&u.fc.type==="FeatureCollection"?u.fc:a;return this._controller.addFeatures(n)}async updateFeature(a,u){this._logger.debug("updateFeature",{id:a}),this._controller&&await this._controller.updateFeature(a,u)}async removeFeature(a){this._logger.debug("removeFeature",{id:a}),this._controller&&await this._controller.removeFeature(a)}async fitBoundsToData(a){this._logger.debug("fitBoundsToData",{padding:a}),this._controller&&await this._controller.fitBoundsToData(typeof a=="number"?a:.05)}async fitBounds(a,u){this._logger.debug("fitBounds",{bounds:a,padding:u}),this._controller&&await this._controller.fitBounds(a,typeof u=="number"?u:.05)}async setView(a,u,n){this._logger.debug("setView",{lat:a,lng:u,zoom:n}),this.latitude=a,this.longitude=u,typeof n=="number"&&(this.zoom=n),this._controller&&await this._controller.setView(a,u,n)}async exportGeoJSON(){if(this._logger.debug("exportGeoJSON"),!this._controller)return{type:"FeatureCollection",features:[]};const a=await this._controller.getGeoJSON(),u={geoJSON:a,featureCount:a.features.length};return this.dispatchEvent(new CustomEvent("leaflet-draw:export",{detail:u})),a}async mergePolygons(a){if(this._logger.debug("mergePolygons"),!this._controller)return null;const n=(await this._controller.getGeoJSON()).features.length,r=await this._controller.mergeVisiblePolygons(a);if(r){const l=await this._controller.getGeoJSON(),d={id:r,mergedFeatureCount:n-l.features.length+1,geoJSON:l};this.dispatchEvent(new CustomEvent("leaflet-draw:merged",{detail:d}))}return r}async setMeasurementUnits(a){this._logger.debug("setMeasurementUnits",{system:a}),this._controller&&this._controller.setRulerUnits(a)}async loadGeoJSONFromUrl(a){if(this._logger.debug("loadGeoJSONFromUrl",{url:a}),!this._controller)return;const u=await fetch(a,{headers:{Accept:"application/json"}});if(!u.ok){const d=new Error(`Failed to fetch GeoJSON from ${a}: ${u.status} ${u.statusText}`);throw this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:{message:d.message,cause:d}})),d}const n=await u.json(),r={fc:n,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:r}));const l=r.fc&&r.fc.type==="FeatureCollection"?r.fc:n;await this._controller.loadGeoJSON(l,!0)}async loadGeoJSONFromText(a){var l;if(this._logger.debug("loadGeoJSONFromText",{length:(l=a==null?void 0:a.length)!=null?l:0}),!this._controller)return;let u;try{u=JSON.parse(a)}catch(d){const p=new Error("Failed to parse GeoJSON text");throw this.dispatchEvent(new CustomEvent("leaflet-draw:error",{detail:{message:p.message,cause:d}})),p}const n={fc:u,mode:"load"};this.dispatchEvent(new CustomEvent("leaflet-draw:ingest",{detail:n}));const r=n.fc&&n.fc.type==="FeatureCollection"?n.fc:u;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}}_reflect(a,u){u===null?this.removeAttribute(a):this.getAttribute(a)!==u&&this.setAttribute(a,u)}_booleanReflect(a,u){u?this.hasAttribute(a)||this.setAttribute(a,""):this.hasAttribute(a)&&this.removeAttribute(a)}_coerceNumber(a,u){if(a==null)return u!=null?u:NaN;const n=Number(a);return Number.isFinite(n)?n:u!=null?u:NaN}}const er={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"},Vi="leaflet-geokit";customElements.get(Vi)||customElements.define(Vi,Xe);const Wi="leaflet-draw-map";if(!customElements.get(Wi)){class g extends Xe{}customElements.define(Wi,g)}dt.DrawEvent=er,dt.LeafletDrawMapElement=Xe,Object.defineProperty(dt,Symbol.toStringTag,{value:"Module"})}));
|
|
202
|
+
//# sourceMappingURL=leaflet-geokit.umd.js.map
|