PageSourceSearch

https://www.brodski-stupnik.hr/wp-content/plugins/directorist/asse…/openstreetlayers.js?ver=1790978006

js brodski-stupnik.hr collected 2026-10-02 21:54:36 UTC 234,281 bytes, 5,024 lines download raw bytes

1/* @preserve
2 * Leaflet 1.5.1+build.2e3e0ff, a JS library for interactive maps. http://leafletjs.com
3 * (c) 2010-2018 Vladimir Agafonkin, (c) 2010-2011 CloudMade
4 */
5!(function (t, i) {
6    "object" == typeof exports && "undefined" != typeof module ? i(exports) : "function" == typeof define && define.amd ? define(["exports"], i) : i((t.L = {}));
7})(this, function (t) {
8    "use strict";
9    var i = Object.freeze;
10    function h(t) {
11        var i, e, n, o;
12        for (e = 1, n = arguments.length; e < n; e++) for (i in (o = arguments[e])) t[i] = o[i];
13        return t;
14    }
15    Object.freeze = function (t) {
16        return t;
17    };
18    var s =
19        Object.create ||
20        function (t) {
21            return (e.prototype = t), new e();
22        };
23    function e() {}
24    function a(t, i) {
25        var e = Array.prototype.slice;
26        if (t.bind) return t.bind.apply(t, e.call(arguments, 1));
27        var n = e.call(arguments, 2);
28        return function () {
29            return t.apply(i, n.length ? n.concat(e.call(arguments)) : arguments);
30        };
31    }
32    var n = 0;
33    function u(t) {
34        return (t._leaflet_id = t._leaflet_id || ++n), t._leaflet_id;
35    }
36    function o(t, i, e) {
37        var n, o, s, r;
38        return (
39            (r = function () {
40                (n = !1), o && (s.apply(e, o), (o = !1));
41            }),
42            (s = function () {
43                n ? (o = arguments) : (t.apply(e, arguments), setTimeout(r, i), (n = !0));
44            })
45        );
46    }
47    function r(t, i, e) {
48        var n = i[1],
49            o = i[0],
50            s = n - o;
51        return t === n && e ? t : ((((t - o) % s) + s) % s) + o;
52    }
53    function l() {
54        return !1;
55    }
56    function c(t, i) {
57        return (i = void 0 === i ? 6 : i), +(Math.round(t + "e+" + i) + "e-" + i);
58    }
59    function _(t) {
60        return t.trim ? t.trim() : t.replace(/^\s+|\s+$/g, "");
61    }
62    function d(t) {
63        return _(t).split(/\s+/);
64    }
65    function p(t, i) {
66        for (var e in (t.hasOwnProperty("options") || (t.options = t.options ? s(t.options) : {}), i)) t.options[e] = i[e];
67        return t.options;
68    }
69    function m(t, i, e) {
70        var n = [];
71        for (var o in t) n.push(encodeURIComponent(e ? o.toUpperCase() : o) + "=" + encodeURIComponent(t[o]));
72        return (i && -1 !== i.indexOf("?") ? "&" : "?") + n.join("&");
73    }
74    var f = /\{ *([\w_-]+) *\}/g;
75    function g(t, n) {
76        return t.replace(f, function (t, i) {
77            var e = n[i];
78            if (void 0 === e) throw new Error("No value provided for variable " + t);
79            return "function" == typeof e && (e = e(n)), e;
80        });
81    }
82    var v =
83        Array.isArray ||
84        function (t) {
85            return "[object Array]" === Object.prototype.toString.call(t);
86        };
87    function y(t, i) {
88        for (var e = 0; e < t.length; e++) if (t[e] === i) return e;
89        return -1;
90    }
91    var x = "data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";
92    function w(t) {
93        return window["webkit" + t] || window["moz" + t] || window["ms" + t];
94    }
95    var P = 0;
96    function b(t) {
97        var i = +new Date(),
98            e = Math.max(0, 16 - (i - P));
99        return (P = i + e), window.setTimeout(t, e);
100    }
101    var T = window.requestAnimationFrame || w("RequestAnimationFrame") || b,
102        z =
103            window.cancelAnimationFrame ||
104            w("CancelAnimationFrame") ||
105            w("CancelRequestAnimationFrame") ||
106            function (t) {
107                window.clearTimeout(t);
108            };
109    function M(t, i, e) {
110        if (!e || T !== b) return T.call(window, a(t, i));
111        t.call(i);
112    }
113    function C(t) {
114        t && z.call(window, t);
115    }
116    var S = (Object.freeze || Object)({
117        freeze: i,
118        extend: h,
119        create: s,
120        bind: a,
121        lastId: n,
122        stamp: u,
123        throttle: o,
124        wrapNum: r,
125        falseFn: l,
126        formatNum: c,
127        trim: _,
128        splitWords: d,
129        setOptions: p,
130        getParamString: m,
131        template: g,
132        isArray: v,
133        indexOf: y,
134        emptyImageUrl: x,
135        requestFn: T,
136        cancelFn: z,
137        requestAnimFrame: M,
138        cancelAnimFrame: C,
139    });
140    function Z() {}
141    (Z.extend = function (t) {
142        function i() {
143            this.initialize && this.initialize.apply(this, arguments), this.callInitHooks();
144        }
145        var e = (i.__super__ = this.prototype),
146            n = s(e);
147        for (var o in (((n.constructor = i).prototype = n), this)) this.hasOwnProperty(o) && "prototype" !== o && "__super__" !== o && (i[o] = this[o]);
148        return (
149            t.statics && (h(i, t.statics), delete t.statics),
150            t.includes &&
151                ((function (t) {
152                    if ("undefined" == typeof L || !L || !L.Mixin) return;
153                    t = v(t) ? t : [t];
154                    for (var i = 0; i < t.length; i++)
155                        t[i] === L.Mixin.Events && console.warn("Deprecated 
155include of L.Mixin.Events: this property will be removed in future releases, please inherit from L.Evented instead.", new Error().stack);
156                })(t.includes),
157                h.apply(null, [n].concat(t.includes)),
158                delete t.includes),
159            n.options && (t.options = h(s(n.options), t.options)),
160            h(n, t),
161            (n._initHooks = []),
162            (n.callInitHooks = function () {
163                if (!this._initHooksCalled) {
164                    e.callInitHooks && e.callInitHooks.call(this), (this._initHooksCalled = !0);
165                    for (var t = 0, i = n._initHooks.length; t < i; t++) n._initHooks[t].call(this);
166                }
167            }),
168            i
169        );
170    }),
171        (Z.include = function (t) {
172            return h(this.prototype, t), this;
173        }),
174        (Z.mergeOptions = function (t) {
175            return h(this.prototype.options, t), this;
176        }),
177        (Z.addInitHook = function (t) {
178            var i = Array.prototype.slice.call(arguments, 1),
179                e =
180                    "function" == typeof t
181                        ? t
182                        : function () {
183                              this[t].apply(this, i);
184                          };
185            return (this.prototype._initHooks = this.prototype._initHooks || []), this.prototype._initHooks.push(e), this;
186        });
187    var E = {
188        on: function (t, i, e) {
189            if ("object" == typeof t) for (var n in t) this._on(n, t[n], i);
190            else for (var o = 0, s = (t = d(t)).length; o < s; o++) this._on(t[o], i, e);
191            return this;
192        },
193        off: function (t, i, e) {
194            if (t)
195                if ("object" == typeof t) for (var n in t) this._off(n, t[n], i);
196                else for (var o = 0, s = (t = d(t)).length; o < s; o++) this._off(t[o], i, e);
197            else delete this._events;
198            return this;
199        },
200        _on: function (t, i, e) {
201            this._events = this._events || {};
202            var n = this._events[t];
203            n || ((n = []), (this._events[t] = n)), e === this && (e = void 0);
204            for (var o = { fn: i, ctx: e }, s = n, r = 0, a = s.length; r < a; r++) if (s[r].fn === i && s[r].ctx === e) return;
205            s.push(o);
206        },
207        _off: function (t, i, e) {
208            var n, o, s;
209            if (this._events && (n = this._events[t]))
210                if (i) {
211                    if ((e === this && (e = void 0), n))
212                        for (o = 0, s = n.length; o < s; o++) {
213                            var r = n[o];
214                            if (r.ctx === e && r.fn === i) return (r.fn = l), this._firingCount && (this._events[t] = n = n.slice()), void n.splice(o, 1);
215                        }
216                } else {
217                    for (o = 0, s = n.length; o < s; o++) n[o].fn = l;
218                    delete this._events[t];
219                }
220        },
221        fire: function (t, i, e) {
222            if (!this.listens(t, e)) return this;
223            var n = h({}, i, { type: t, target: this, sourceTarget: (i && i.sourceTarget) || this });
224            if (this._events) {
225                var o = this._events[t];
226                if (o) {
227                    this._firingCount = this._firingCount + 1 || 1;
228                    for (var s = 0, r = o.length; s < r; s++) {
229                        var a = o[s];
230                        a.fn.call(a.ctx || this, n);
231                    }
232                    this._firingCount--;
233                }
234            }
235            return e && this._propagateEvent(n), this;
236        },
237        listens: function (t, i) {
238            var e = this._events && this._events[t];
239            if (e && e.length) return !0;
240            if (i) for (var n in this._eventParents) if (this._eventParents[n].listens(t, i)) return !0;
241            return !1;
242        },
243        once: function (t, i, e) {
244            if ("object" == typeof t) {
245                for (var n in t) this.once(n, t[n], i);
246                return this;
247            }
248            var o = a(function () {
249                this.off(t, i, e).off(t, o, e);
250            }, this);
251            return this.on(t, i, e).on(t, o, e);
252        },
253        addEventParent: function (t) {
254            return (this._eventParents = this._eventParents || {}), (this._eventParents[u(t)] = t), this;
255        },
256        removeEventParent: function (t) {
257            return this._eventParents && delete this._eventParents[u(t)], this;
258        },
259        _propagateEvent: function (t) {
260            for (var i in this._eventParents) this._eventParents[i].fire(t.type, h({ layer: t.target, prop
260agatedFrom: t.target }, t), !0);
261        },
262    };
263    (E.addEventListener = E.on), (E.removeEventListener = E.clearAllEventListeners = E.off), (E.addOneTimeEventListener = E.once), (E.fireEvent = E.fire), (E.hasEventListeners = E.listens);
264    var k = Z.extend(E);
265    function B(t, i, e) {
266        (this.x = e ? Math.round(t) : t), (this.y = e ? Math.round(i) : i);
267    }
268    var A =
269        Math.trunc ||
270        function (t) {
271            return 0 < t ? Math.floor(t) : Math.ceil(t);
272        };
273    function I(t, i, e) {
274        return t instanceof B ? t : v(t) ? new B(t[0], t[1]) : null == t ? t : "object" == typeof t && "x" in t && "y" in t ? new B(t.x, t.y) : new B(t, i, e);
275    }
276    function O(t, i) {
277        if (t) for (var e = i ? [t, i] : t, n = 0, o = e.length; n < o; n++) this.extend(e[n]);
278    }
279    function R(t, i) {
280        return !t || t instanceof O ? t : new O(t, i);
281    }
282    function N(t, i) {
283        if (t) for (var e = i ? [t, i] : t, n = 0, o = e.length; n < o; n++) this.extend(e[n]);
284    }
285    function D(t, i) {
286        return t instanceof N ? t : new N(t, i);
287    }
288    function j(t, i, e) {
289        if (isNaN(t) || isNaN(i)) throw new Error("Invalid LatLng object: (" + t + ", " + i + ")");
290        (this.lat = +t), (this.lng = +i), void 0 !== e && (this.alt = +e);
291    }
292    function W(t, i, e) {
293        return t instanceof j
294            ? t
295            : v(t) && "object" != typeof t[0]
296            ? 3 === t.length
297                ? new j(t[0], t[1], t[2])
298                : 2 === t.length
299                ? new j(t[0], t[1])
300                : null
301            : null == t
302            ? t
303            : "object" == typeof t && "lat" in t
304            ? new j(t.lat, "lng" in t ? t.lng : t.lon, t.alt)
305            : void 0 === i
306            ? null
307            : new j(t, i, e);
308    }
309    (B.prototype = {
310        clone: function () {
311            return new B(this.x, this.y);
312        },
313        add: function (t) {
314            return this.clone()._add(I(t));
315        },
316        _add: function (t) {
317            return (this.x += t.x), (this.y += t.y), this;
318        },
319        subtract: function (t) {
320            return this.clone()._subtract(I(t));
321        },
322        _subtract: function (t) {
323            return (this.x -= t.x), (this.y -= t.y), this;
324        },
325        divideBy: function (t) {
326            return this.clone()._divideBy(t);
327        },
328        _divideBy: function (t) {
329            return (this.x /= t), (this.y /= t), this;
330        },
331        multiplyBy: function (t) {
332            return this.clone()._multiplyBy(t);
333        },
334        _multiplyBy: function (t) {
335            return (this.x *= t), (this.y *= t), this;
336        },
337        scaleBy: function (t) {
338            return new B(this.x * t.x, this.y * t.y);
339        },
340        unscaleBy: function (t) {
341            return new B(this.x / t.x, this.y / t.y);
342        },
343        round: function () {
344            return this.clone()._round();
345        },
346        _round: function () {
347            return (this.x = Math.round(this.x)), (this.y = Math.round(this.y)), this;
348        },
349        floor: function () {
350            return this.clone()._floor();
351        },
352        _floor: function () {
353            return (this.x = Math.floor(this.x)), (this.y = Math.floor(this.y)), this;
354        },
355        ceil: function () {
356            return this.clone()._ceil();
357        },
358        _ceil: function () {
359            return (this.x = Math.ceil(this.x)), (this.y = Math.ceil(this.y)), this;
360        },
361        trunc: function () {
362            return this.clone()._trunc();
363        },
364        _trunc: function () {
365            return (this.x = A(this.x)), (this.y = A(this.y)), this;
366        },
367        distanceTo: function (t) {
368            var i = (t = I(t)).x - this.x,
369                e = t.y - this.y;
370            return Math.sqrt(i * i + e * e);
371        },
372        equals: function (t) {
373            return (t = I(t)).x === this.x && t.y === this.y;
374        },
375        contains: function (t) {
376            return (t = I(t)), Math.abs(t.x) <= Math.abs(this.x) && Math.abs(t.y) <= Math.abs(this.y);
377        },
378        toString: function () {
379            return "Point(" + c(this.x) + ", " + c(this.y) + ")";
380        },
381    }),
382        (O.prototype = {
383            extend: function (t) {
384                return (
385                    (t = I(t)),
386                    this.min || this.max
387                        ? ((this.min.x = Math.min(t.x, this.min.x)), (this.max.x = Math.max(t.x, this.max.x)), (this.min.y = Math.min(t.y, this.min.y)), (this.max.y = Math.max(t.y, this.max.y)))
388                        : ((this.min = t.clone()), (this.max = t.clone())),
389                    this
390                );
391            },
392            getCenter: function (t) {
393                return new B((this.min.x + this.max.x) / 2, (this.min.y + this.max.y) / 2, t);
394            },
395            getBottomLeft: function () {
396                return new B(this.min.x, this.max.y);
397            },
398            getTopRight: function () {
399                return new B(this.max.x, this.min.y);
400            },
401            getTopLeft: function () {
402                return this.min;
403            },
404            getBottomRight: function () {
405                return this.max;
406            },
407            getSize: function () {
408                return this.max.subtract(this.min);
409            },
410            contains: function (t) {
411                var i, e;
412                return (t = "number" == typeof t[0] || t instanceof B ? I(t) : R(t)) instanceof O ? ((i = t.min), (e = t.max)) : (i = e = t), i.x >= this.min.x && e.x <= this.max.x && i.y >= this.min.y && e.y <= this.max.y;
413            },
414            intersects: function (t) {
415                t = R(t);
416                var i = this.min,
417                    e = this.max,
418                    n = t.min,
419                    o = t.max,
420                    s = o.x >= i.x && n.x <= e.x,
421                    r = o.y >= i.y && n.y <= e.y;
422                return s && r;
423            },
424            overlaps: function (t) {
425                t = R(t);
426                var i = this.min,
427                    e = this.max,
428                    n = t.min,
429                    o = t.max,
430                    s = o.x > i.x && n.x < e.x,
431                    r = o.y > i.y && n.y < e.y;
432                return s && r;
433            },
434            isValid: function () {
435                return !(!this.min || !this.max);
436            },
437        }),
438        (N.prototype = {
439            extend: function (t) {
440                var i,
441                    e,
442                    n = this._southWest,
443                    o = this._northEast;
444                if (t instanceof j) e = i = t;
445                else {
446                    if (!(t instanceof N)) return t ? this.extend(W(t) || D(t)) : this;
447                    if (((i = t._southWest), (e = t._northEast), !i || !e)) return this;
448                }
449                return (
450                    n || o
451                        ? ((n.lat = Math.min(i.lat, n.lat)), (n.lng = Math.min(i.lng, n.lng)), (o.lat = Math.max(e.lat, o.lat)), (o.lng = Math.max(e.lng, o.lng)))
452                        : ((this._southWest = new j(i.lat, i.lng)), (this._northEast = new j(e.lat, e.lng))),
453                    this
454                );
455            },
456            pad: function (t) {
457                var i = this._southWest,
458                    e = this._northEast,
459                    n = Math.abs(i.lat - e.lat) * t,
460                    o = Math.abs(i.lng - e.lng) * t;
461                return new N(new j(i.lat - n, i.lng - o), new j(e.lat + n, e.lng + o));
462            },
463            getCenter: function () {
464                return new j((this._southWest.lat + this._northEast.lat) / 2, (this._southWest.lng + this._northEast.lng) / 2);
465            },
466            getSouthWest: function () {
467                return this._southWest;
468            },
469            getNorthEast: function () {
470                return this._northEast;
471            },
472            getNorthWest: function () {
473                return new j(this.getNorth(), this.getWest());
474            },
475            getSouthEast: function () {
476                return new j(this.getSouth(), this.getEast());
477            },
478            getWest: function () {
479                return this._southWest.lng;
480            },
481            getSouth: function () {
482                return this._southWest.lat;
483            },
484            getEast: function () {
485                return this._northEast.lng;
486            },
487            getNorth: function () {
488                return this._northEast.lat;
489            },
490            contains: function (t) {
491                t = "number" == typeof t[0] || t instanceof j || "lat" in t ? W(t) : D(t);
492                var i,
493                    e,
494                    n = this._southWest,
495                    o = this._northEast;
496                return t instanceof N ? ((i = t.getSouthWest()), (e = t.getNorthEast())) : (i = e = t), i.lat >= n.lat && e.lat <= o.lat && i.lng >= n.lng && e.lng <= o.lng;
497            },
498            intersects: function (t) {
499                t = D(t);
500                var i = this._southWest,
501                    e = this._northEast,
502                    n = t.getSouthWest(),
503                    o = t.getNorthEast(),
504                    s = o.lat >= i.lat && n.lat <= e.lat,
505                    r = o.lng >= i.lng && n.lng <= e.lng;
506                return s && r;
507            },
508            overlaps: function (t) {
509                t = D(t);
510                var i = this._southWest,
511                    e = this._northEast,
512                    n = t.getSouthWest(),
513                    o = t.getNorthEast(),
514                    s = o.lat > i.lat && n.lat < e.lat,
515                    r = o.lng > i.lng && n.lng < e.lng;
516                return s && r;
517            },
518            toBBoxString: function () {
519                return [this.getWest(), this.getSouth(), this.getEast(), this.getNorth()].join(",");
520            },
521            equals: function (t, i) {
522                return !!t && ((t = D(t)), this._southWest.equals(t.getSouthWest
522(), i) && this._northEast.equals(t.getNorthEast(), i));
523            },
524            isValid: function () {
525                return !(!this._southWest || !this._northEast);
526            },
527        });
528    var H,
529        F = {
530            latLngToPoint: function (t, i) {
531                var e = this.projection.project(t),
532                    n = this.scale(i);
533                return this.transformation._transform(e, n);
534            },
535            pointToLatLng: function (t, i) {
536                var e = this.scale(i),
537                    n = this.transformation.untransform(t, e);
538                return this.projection.unproject(n);
539            },
540            project: function (t) {
541                return this.projection.project(t);
542            },
543            unproject: function (t) {
544                return this.projection.unproject(t);
545            },
546            scale: function (t) {
547                return 256 * Math.pow(2, t);
548            },
549            zoom: function (t) {
550                return Math.log(t / 256) / Math.LN2;
551            },
552            getProjectedBounds: function (t) {
553                if (this.infinite) return null;
554                var i = this.projection.bounds,
555                    e = this.scale(t);
556                return new O(this.transformation.transform(i.min, e), this.transformation.transform(i.max, e));
557            },
558            infinite: !(j.prototype = {
559                equals: function (t, i) {
560                    return !!t && ((t = W(t)), Math.max(Math.abs(this.lat - t.lat), Math.abs(this.lng - t.lng)) <= (void 0 === i ? 1e-9 : i));
561                },
562                toString: function (t) {
563                    return "LatLng(" + c(this.lat, t) + ", " + c(this.lng, t) + ")";
564                },
565                distanceTo: function (t) {
566                    return U.distance(this, W(t));
567                },
568                wrap: function () {
569                    return U.wrapLatLng(this);
570                },
571                toBounds: function (t) {
572                    var i = (180 * t) / 40075017,
573                        e = i / Math.cos((Math.PI / 180) * this.lat);
574                    return D([this.lat - i, this.lng - e], [this.lat + i, this.lng + e]);
575                },
576                clone: function () {
577                    return new j(this.lat, this.lng, this.alt);
578                },
579            }),
580            wrapLatLng: function (t) {
581                var i = this.wrapLng ? r(t.lng, this.wrapLng, !0) : t.lng;
582                return new j(this.wrapLat ? r(t.lat, this.wrapLat, !0) : t.lat, i, t.alt);
583            },
584            wrapLatLngBounds: function (t) {
585                var i = t.getCenter(),
586                    e = this.wrapLatLng(i),
587                    n = i.lat - e.lat,
588                    o = i.lng - e.lng;
589                if (0 == n && 0 == o) return t;
590                var s = t.getSouthWest(),
591                    r = t.getNorthEast();
592                return new N(new j(s.lat - n, s.lng - o), new j(r.lat - n, r.lng - o));
593            },
594        },
595        U = h({}, F, {
596            wrapLng: [-180, 180],
597            R: 6371e3,
598            distance: function (t, i) {
599                var e = Math.PI / 180,
600                    n = t.lat * e,
601                    o = i.lat * e,
602                    s = Math.sin(((i.lat - t.lat) * e) / 2),
603                    r = Math.sin(((i.lng - t.lng) * e) / 2),
604                    a = s * s + Math.cos(n) * Math.cos(o) * r * r,
605                    h = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
606                return this.R * h;
607            },
608        }),
609        V = 6378137,
610        q = {
611            R: V,
612            MAX_LATITUDE: 85.0511287798,
613            project: function (t) {
614                var i = Math.PI / 180,
615                    e = this.MAX_LATITUDE,
616                    n = Math.max(Math.min(e, t.lat), -e),
617                    o = Math.sin(n * i);
618                return new B(this.R * t.lng * i, (this.R * Math.log((1 + o) / (1 - o))) / 2);
619            },
620            unproject: function (t) {
621                var i = 180 / Math.PI;
622                return new j((2 * Math.atan(Math.exp(t.y / this.R)) - Math.PI / 2) * i, (t.x * i) / this.R);
623            },
624            bounds: ((H = V * Math.PI), new O([-H, -H], [H, H])),
625        };
626    function G(t, i, e, n) {
627        if (v(t)) return (this._a = t[0]), (this._b = t[1]), (this._c = t[2]), void (this._d = t[3]);
628        (this._a = t), (this._b = i), (this._c = e), (this._d = n);
629    }
630    function K(t, i, e, n) {
631        return new G(t, i, e, n);
632    }
633    G.prototype = {
634        transform: function (t, i) {
635            return this._transform(t.clone(), i);
636        },
637        _transform: function (t, i) {
638            return (i = i || 1), (t.x = i * (this._a * t.x + this._b)), (t.y = i * (this._c * t.y + this._d)), t;
639        },
640        untransform: function (t, i) {
641            return (i = i || 1), new B((t.x / i - this._b) / this._a, (t.y / i - this._d) / this._c);
642        },
643    };
644    var Y,
645        X = h({}, U, { code: "EPSG:3857", projection: q, transformation: ((Y = 0.5 / (Math.PI * q.R)), K(Y, 0.5, -Y, 0.5)) }),
646        J = h({}, X, { code: "EPSG:900913" });
647    function $(t) {
648        return document.createElementNS("https://www.w3.org/2000/svg", t);
649    }
650    function Q(t, i) {
651        var e,
652            n,
653            o,
654            s,
655            r,
656            a,
657            h = "";
658        for (e = 0, o = t.length; e < o; e++) {
659            for (n = 0, s = (r = t[e]).length; n < s; n++) h += (n ? "L" : "M") + (a = r[n]).x + " " + a.y;
660            h += i ? (Zt ? "z" : "x") : "";
661        }
662        return h || "M0 0";
663    }
664    var tt = document.documentElement.style,
665        it = "ActiveXObject" in window,
666        et = it && !document.addEventListener,
667        nt = "msLaunchUri" in navigator && !("documentMode" in document),
668        ot = kt("webkit"),
669        st = kt("android"),
670        rt = kt("android 2") || kt("android 3"),
671        at = parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1], 10),
672        ht = st && kt("Google") && at < 537 && !("AudioNode" in window),
673        ut = !!window.opera,
674        lt = kt("chrome"),
675        ct = kt("gecko") && !ot && !ut && !it,
676        _t = !lt && kt("safari"),
677        dt = kt("phantom"),
678        pt = "OTransition" in tt,
679        mt = 0 === navigator.platform.indexOf("Win"),
680        ft = it && "transition" in tt,
681        gt = "WebKitCSSMatrix" in window && "m11" in new window.WebKitCSSMatrix() && !rt,
682        vt = "MozPerspective" in tt,
683        yt = !window.L_DISABLE_3D && (ft || gt || vt) && !pt && !dt,
684        xt = "undefined" != typeof orientation || kt("mobile"),
685        wt = xt && ot,
686        Pt = xt && gt,
687        bt = !window.PointerEvent && window.MSPointerEvent,
688        Lt = !(!window.PointerEvent && !bt),
689        Tt = !window.L_NO_TOUCH && (Lt || "ontouchstart" in window || (window.DocumentTouch && document instanceof window.DocumentTouch)),
690        zt = xt && ut,
691        Mt = xt && ct,
692        Ct = 1 < (window.devicePixelRatio || window.screen.deviceXDPI / window.screen.logicalXDPI),
693        St = !!document.createElement("canvas").getContext,
694        Zt = !(!document.createElementNS || !$("svg").createSVGRect),
695        Et =
696            !Zt &&
697            (function () {
698                try {
699                    var t = document.createElement("div");
700                    t.innerHTML = '<v:shape adj="1"/>';
701                    var i = t.firstChild;
702                    return (i.style.behavior = "url(#default#VML)"), i && "object" == typeof i.adj;
703                } catch (t) {
704                    return !1;
705                }
706            })();
707    function kt(t) {
708        return 0 <= navigator.userAgent.toLowerCase().indexOf(t);
709    }
710    var Bt = (Object.freeze || Object)({
711            ie: it,
712            ielt9: et,
713            edge: nt,
714            webkit: ot,
715            android: st,
716            android23: rt,
717            androidStock: ht,
718            opera: ut,
719            chrome: lt,
720            gecko: ct,
721            safari: _t,
722            phantom: dt,
723            opera12: pt,
724            win: mt,
725            ie3d: ft,
726            webkit3d: gt,
727            gecko3d: vt,
728            any3d: yt,
729            mobile: xt,
730            mobileWebkit: wt,
731            mobileWebkit3d: Pt,
732            msPointer: bt,
733            pointer: Lt,
734            touch: Tt,
735            mobileOpera: zt,
736            mobileGecko: Mt,
737            retina: Ct,
738            canvas: St,
739            svg: Zt,
740            vml: Et,
741        }),
742        At = bt ? "MSPointerDown" : "pointerdown",
743        It = bt ? "MSPointerMove" : "pointermove",
744        Ot = bt ? "MSPointerUp" : "pointerup",
745        Rt = bt ? "MSPointerCancel" : "pointercancel",
746        Nt = ["INPUT", "SELECT", "OPTION"],
747        Dt = {},
748        jt = !1,
749        Wt = 0;
750    function Ht(t, i, e, n) {
751        return (
752            "touchstart" === i
753                ? (function (t, i, e) {
754                      var n = a(function (t) {
755                          if ("mouse" !== t.pointerType && t.MSPOINTER_TYPE_MOUSE && t.pointerType !== t.MSPOINTER_TYPE_MOUSE) {
756                              if (!(Nt.indexOf(t.target.tagName) < 0)) return;
757                              Di(t);
758                          }
759                          qt(t, i);
760                      });
761                      (t["_leaflet_touchstart" + e] = n),
762                          t.addEventListener(At, n, !1),
763                          jt ||
764                              (document.documentElement.addEventListener(At, Ft, !0),
765                              document.documentElement.addEventListener(It, Ut, !0),
766                              document.documentElement.addEventListener(Ot, Vt, !0),
767                              document.documentElement.addEventListener(Rt, Vt, !0),
768                              (jt = !0));
769                  })(t, e, n)
770                : "touchmove" === i
771                ? (function (t, i, e) {
772                      var n = function (t) {
773                          ((t.pointerType !== t.MSPOINTER_TYPE_MOUSE && "mouse" !== t.pointerType) || 0 !== t.buttons) && qt(t, i);
774                      };
775                      (t["_leaflet_touchmove" + e] = n), t.addEventListener(It, n, !1);
776                  })(t, e, n)
777                : "touchend" === i &&
778                  (function (t, i, e) {
779                      var n = function (t) {
780                          qt(t, i);
781                      };
782                      (t["_leaflet_touchend" + e] = n), t.addEventListener(Ot, n, !1), t.addEventListener(Rt, n, !1);
783                  })(t, e, n),
784            this
785        );
786    }
787    function Ft(t) {
788        (Dt[t.pointerId] = t), Wt++;
789    }
790    function Ut(t) {
791        Dt[t.pointerId] && (Dt[t.pointerId] = t);
792    }
793    function Vt(t) {
794        delete Dt[t.pointerId], Wt--;
795    }
796    function qt(t, i) {
797        for (var e in ((t.touches = []), Dt)) t.touches.push(Dt[e]);
798        (t.changedTouches = [t]), i(t);
799    }
800    var Gt = bt ? "MSPointerDown" : Lt ? "pointerdown" : "touchstart",
801        Kt = bt ? "MSPointerUp" : Lt ? "pointerup" : "touchend",
802        Yt = "_leaflet_";
803    function Xt(t, o, i) {
804        var s,
805            r,
806            a = !1;
807        function e(t) {
808            var i;
809            if (Lt) {
810                if (!nt || "mouse" === t.pointerType) return;
811                i = Wt;
812            } else i = t.touches.length;
813            if (!(1 < i)) {
814                var e = Date.now(),
815                    n = e - (s || e);
816                (r = t.touches ? t.touches[0] : t), (a = 0 < n && n <= 250), (s = e);
817            }
818        }
819        function n(t) {
820            if (a && !r.cancelBubble) {
821                if (Lt) {
822                    if (!nt || "mouse" === t.pointerType) return;
823                    var i,
824                        e,
825                        n = {};
826                    for (e in r) (i = r[e]), (n[e] = i && i.bind ? i.bind(r) : i);
827                    r = n;
828                }
829                (r.type = "dblclick"), (r.button = 0), o(r), (s = null);
830            }
831        }
832        return (t[Yt + Gt + i] = e), (t[Yt + Kt + i] = n), (t[Yt + "dblclick" + i] = o), t.addEventListener(Gt, e, !1), t.addEventListener(Kt, n, !1), t.addEventListener("dblclick", o, !1), this;
833    }
834    function Jt(t, i) {
835        var e = t[Yt + Gt + i],
836            n = t[Yt + Kt + i],
837            o = t[Yt + "dblclick" + i];
838        return t.removeEventListener(Gt, e, !1), t.removeEventListener(Kt, n, !1), nt || t.removeEventListener("dblclick", o, !1), this;
839    }
840    var $t,
841        Qt,
842        ti,
843        ii,
844        ei,
845        ni = yi(["transform", "webkitTransform", "OTransform", "MozTransform", "msTransform"]),
846        oi = yi(["webkitTransition", "transition", "OTransition", "MozTransition", "msTransition"]),
847        si = "webkitTransition" === oi || "OTransition" === oi ? oi + "End" : "transitionend";
848    function ri(t) {
849        return "string" == typeof t ? document.getElementById(t) : t;
850    }
851    function ai(t, i) {
852        var e = t.style[i] || (t.currentStyle && t.currentStyle[i]);
853        if ((!e || "auto" === e) && document.defaultView) {
854            var n = document.defaultView.getComputedStyle(t, null);
855            e = n ? n[i] : null;
856        }
857        return "auto" === e ? null : e;
858    }
859    function hi(t, i, e) {
860        var n = document.createElement(t);
861        return (n.className = i || ""), e && e.appendChild(n), n;
862    }
863    function ui(t) {
864        var i = t.parentNode;
865        i && i.removeChild(t);
866    }
867    function li(t) {
868        for (; t.firstChild; ) t.removeChild(t.firstChild);
869    }
870    function ci(t) {
871        var i = t.parentNode;
872        i && i.lastChild !== t && i.appendChild(t);
873    }
874    function _i(t) {
875        var i = t.parentNode;
876        i && i.firstChild !== t && i.insertBefore(t, i.firstChild);
877    }
878    function di(t, i) {
879        if (void 0 !== t.classList) return t.classList.contains(i);
880        var e = gi(t);
881        return 0 < e.length && new RegExp("(^|\\s)" + i + "(\\s|$)").test(e);
882    }
883    function pi(t, i) {
884        if (void 0 !== t.classList) for (var e = d(i), n = 0, o = e.length; n < o; n++) t.classList.add(e[n]);
885        else if (!di(t, i)) {
886            var s = gi(t);
887            fi(t, (s ? s + " " : "") + i);
888        }
889    }
890    function mi(t, i) {
891        void 0 !== t.classList ? t.classList.remove(i) : fi(t, _((" " + gi(t) + " ").replace(" " + i + " ", " ")));
892    }
893    function fi(t, i) {
894        void 0 === t.className.baseVal ? (t.className = i) : (t.className.baseVal = i);
895    }
896    function gi(t) {
897        return t.correspondingElement && (t = t.correspondingElement), void 0 === t.className.baseVal ? t.className : t.className.baseVal;
898    }
899    function vi(t, i) {
900        "opacity" in t.style
901            ? (t.style.opacity = i)
902            : "filter" in t.style &&
903              (function (t, i) {
904                  var e = !1,
905                      n = "DXImageTransform.Microsoft.Alpha";
906                  try {
907                      e = t.filters.item(n);
908                  } catch (t) {
909                      if (1 === i) return;
910                  }
911                  (i = Math.round(100 * i)), e ? ((e.Enabled = 100 !== i), (e.Opacity = i)) : (t.style.filter += " progid:" + n + "(opacity=" + i + ")");
912              })(t, i);
913    }
914    function yi(t) {
915        for (var i = document.documentElement.style, e = 0; e < t.length; e++) if (t[e] in i) return t[e];
916        return !1;
917    }
918    function xi(t, i, e) {
919        var n = i || new B(0, 0);
920        t.style[ni] = (ft ? "translate(" + n.x + "px," + n.y + "px)" : "translate3d(" + n.x + "px," + n.y + "px,0)") + (e ? " scale(" + e + ")" : "");
921    }
922    function wi(t, i) {
923        (t._leaflet_pos = i), yt ? xi(t, i) : ((t.style.left = i.x + "px"), (t.style.top = i.y + "px"));
924    }
925    function Pi(t) {
926        return t._leaflet_pos || new B(0, 0);
927    }
928    if ("onselectstart" in document)
929        ($t = function () {
930            Ei(window, "selectstart", Di);
931        }),
932            (Qt = function () {
933                Bi(window, "selectstart", Di);
934            });
935    else {
936        var bi = yi(["userSelect", "WebkitUserSelect", "OUserSelect", "MozUserSelect", "msUserSelect"]);
937        ($t = function () {
938            if (bi) {
939                var t = document.documentElement.style;
940                (ti = t[bi]), (t[bi] = "none");
941            }
942        }),
943            (Qt = function () {
944                bi && ((document.documentElement.style[bi] = ti), (ti = void 0));
945            });
946    }
947    function Li() {
948        Ei(window, "dragstart", Di);
949    }
950    function Ti() {
951        Bi(window, "dragstart", Di);
952    }
953    function zi(t) {
954        for (; -1 === t.tabIndex; ) t = t.parentNode;
955        t.style && (Mi(), (ei = (ii = t).style.outline), (t.style.outline = "none"), Ei(window, "keydown", Mi));
956    }
957    function Mi() {
958        ii && ((ii.style.outline = ei), (ei = ii = void 0), Bi(window, "keydown", Mi));
959    }
960    function Ci(t) {
961        for (; !(((t = t.parentNode).offsetWidth && t.offsetHeight) || t === document.body); );
962        return t;
963    }
964    function Si(t) {
965        var i = t.getBoundingClientRect();
966        return { x: i.width / t.offsetWidth || 1, y: i.height / t.offsetHeight || 1, boundingClientRect: i };
967    }
968    var Zi = (Object.freeze || Object)({
969        TRANSFORM: ni,
970        TRANSITION: oi,
971        TRANSITION_END: si,
972        get: ri,
973        getStyle: ai,
974        create: hi,
975        remove: ui,
976        empty: li,
977        toFront: ci,
978        toBack: _i,
979        hasClass: di,
980        addClass: pi,
981        removeClass: mi,
982        setClass: fi,
983        getClass: gi,
984        setOpacity: vi,
985        testProp: yi,
986        setTransform: xi,
987        setPosition: wi,
988        getPosition: Pi,
989        disableTextSelection: $t,
990        enableTextSelection: Qt,
991        disableImageDrag: Li,
992        enableImageDrag: Ti,
993        preventOutline: zi,
994        restoreOutline: Mi,
995        getSizedParentNode: Ci,
996        getScale: Si,
997    });
998    function Ei(t, i, e, n) {
999        if ("object" == typeof i) for (var o in i) Ai(t, o, i[o], e);
1000        else for (var s = 0, r = (i = d(i)).length; s < r; s++) Ai(t, i[s], e, n);
1001        return this;
1002    }
1003    var ki = "_leaflet_events";
1004    function Bi(t, i, e, n) {
1005        if ("object" == typeof i) for (var o in i) Ii(t, o, i[o], e);
1006        else if (i) for (var s = 0, r = (i = d(i)).length; s < r; s++) Ii(t, i[s], e, n);
1007        else {
1008            for (var a in t[ki]) Ii(t, a, t[ki][a]);
1009            delete t[ki];
1010        }
1011        return this;
1012    }
1013    function Ai(i, t, e, n) {
1014        var o = t + u(e) + (n ? "_" + u(n) : "");
1015        if (i[ki] && i[ki][o]) return this;
1016        var s = function (t) {
1017                return e.call(n || i, t || window.event);
1018            },
1019            r = s;
1020        Lt && 0 === t.indexOf("touch")
1021            ? Ht(i, t, s, o)
1022            : !Tt || "dblclick" !== t || (Lt && lt)
1023            ? "addEventListener" in i
1024                ? "mousewheel" === t
1025                    ? i.addEventListener("onwheel" in i ? "wheel" : "mousewheel", s, !1)
1026                    : "mouseenter" === t || "mouseleave" === t
1027                    ? ((s = function (t) {
1028                          (t = t || window.event), Ki(i, t) && r(t);
1029                      }),
1030                      i.addEventListener("mouseenter" === t ? "mouseover" : "mouseout", s, !1))
1031                    : ("click" === t &&
1032                          st &&
1033                          (s = function (t) {
1034                              !(function (t, i) {
1035                                  var e = t.timeStamp || (t.originalEvent && t.originalEvent.timeStamp),
1036                                      n = Ui && e - Ui;
1037                                  if ((n && 100 < n && n < 500) || (t.target._simulatedClick && !t._simulated)) return ji(t);
1038                                  (Ui = e), i(t);
1039                              })(t, r);
1040                          }),
1041                      i.addEventListener(t, s, !1))
1042                : "attachEvent" in i && i.attachEvent("on" + t, s)
1043            : Xt(i, s, o),
1044            (i[ki] = i[ki] || {}),
1045            (i[ki][o] = s);
1046    }
1047    function Ii(t, i, e, n) {
1048        var o = i + u(e) + (n ? "_" + u(n) : ""),
1049            s = t[ki] && t[ki][o];
1050        if (!s) return this;
1051        Lt && 0 === i.indexOf("touch")
1052            ? (function (t, i, e) {
1053                  var n = t["_leaflet_" + i + e];
1054                  "touchstart" === i ? t.removeEventListener(At, n, !1) : "touchmove" === i ? t.removeEventListener(It, n, !1) : "touchend" === i && (t.removeEventListener(Ot, n, !1), t.removeEventListener(Rt, n, !1));
1055              })(t, i, o)
1056            : !Tt || "dblclick" !== i || (Lt && lt)
1057            ? "removeEventListener" in t
1058                ? "mousewheel" === i
1059                    ? t.removeEventListener("onwheel" in t ? "wheel" : "mousewheel", s, !1)
1060                    : t.removeEventListener("mouseenter" === i ? "mouseover" : "mouseleave" === i ? "mouseout" : i, s, !1)
1061                : "detachEvent" in t && t.detachEvent("on" + i, s)
1062            : Jt(t, o),
1063            (t[ki][o] = null);
1064    }
1065    function Oi(t) {
1066        return t.stopPropagation ? t.stopPropagation() : t.originalEvent ? (t.originalEvent._stopped = !0) : (t.cancelBubble = !0), Gi(t), this;
1067    }
1068    function Ri(t) {
1069        return Ai(t, "mousewheel", Oi), this;
1070    }
1071    function Ni(t) {
1072        return Ei(t, "mousedown touchstart dblclick", Oi), Ai(t, "click", qi), this;
1073    }
1074    function Di(t) {
1075        return t.preventDefault ? t.preventDefault() : (t.returnValue = !1), this;
1076    }
1077    function ji(t) {
1078        return Di(t), Oi(t), this;
1079    }
1080    function Wi(t, i) {
1081        if (!i) return new B(t.clientX, t.clientY);
1082        var e = Si(i),
1083            n = e.boundingClientRect;
1084        return new B((t.clientX - n.left) / e.x - i.clientLeft, (t.clientY - n.top) / e.y - i.clientTop);
1085    }
1086    var Hi = mt && lt ? 2 * window.devicePixelRatio : ct ? window.devicePixelRatio : 1;
1087    function Fi(t) {
1088        return nt
1089            ? t.wheelDeltaY / 2
1090            : t.deltaY && 0 === t.deltaMode
1091            ? -t.deltaY / Hi
1092            : t.deltaY && 1 === t.deltaMode
1093            ? 20 * -t.deltaY
1094            : t.deltaY && 2 === t.deltaMode
1095            ? 60 * -t.deltaY
1096            : t.deltaX || t.deltaZ
1097            ? 0
1098            : t.wheelDelta
1099            ? (t.wheelDeltaY || t.wheelDelta) / 2
1100            : t.detail && Math.abs(t.detail) < 32765
1101            ? 20 * -t.detail
1102            : t.detail
1103            ? (t.detail / -32765) * 60
1104            : 0;
1105    }
1106    var Ui,
1107        Vi = {};
1108    function qi(t) {
1109        Vi[t.type] = !0;
1110    }
1111    function Gi(t) {
1112        var i = Vi[t.type];
1113        return (Vi[t.type] = !1), i;
1114    }
1115    function Ki(t, i) {
1116        var e = i.relatedTarget;
1117        if (!e) return !0;
1118        try {
1119            for (; e && e !== t; ) e = e.parentNode;
1120        } catch (t) {
1121            return !1;
1122        }
1123        return e !== t;
1124    }
1125    var Yi = (Object.freeze || Object)({
1126            on: Ei,
1127            off: Bi,
1128            stopPropagation: Oi,
1129            disableScrollPropagation: Ri,
1130            disableClickPropagation: Ni,
1131            preventDefault: Di,
1132            stop: ji,
1133            getMousePosition: Wi,
1134            getWheelDelta: Fi,
1135            fakeStop: qi,
1136            skipped: Gi,
1137            isExternalTarget: Ki,
1138            addListener: Ei,
1139            removeListener: Bi,
1140        }),
1141        Xi = k.extend({
1142            run: function (t, i, e, n) {
1143                this.stop(),
1144                    (this._el = t),
1145                    (this._inProgress = !0),
1146                    (this._duration = e || 0.25),
1147                    (this._easeOutPower = 1 / Math.max(n || 0.5, 0.2)),
1148                    (this._startPos = Pi(t)),
1149                    (this._offset = i.subtract(this._startPos)),
1150                    (this._startTime = +new Date()),
1151                    this.fire("start"),
1152                    this._animate();
1153            },
1154            stop: function () {
1155                this._inProgress && (this._step(!0), this._complete());
1156            },
1157            _animate: function () {
1158                (this._animId = M(this._animate, this)), this._step();
1159            },
1160            _step: function (t) {
1161                var i = +new Date() - this._startTime,
1162                    e = 1e3 * this._duration;
1163                i < e ? this._runFrame(this._easeOut(i / e), t) : (this._runFrame(1), this._complete());
1164            },
1165            _runFrame: function (t, i) {
1166                var e = this._startPos.add(this._offset.multiplyBy(t));
1167                i && e._round(), wi(this._el, e), this.fire("step");
1168            },
1169            _complete: function () {
1170                C(this._animId), (this._inProgress = !1), this.fire("end");
1171            },
1172            _easeOut: function (t) {
1173                return 1 - Math.pow(1 - t, this._easeOutPower);
1174            },
1175        }),
1176        Ji = k.extend({
1177            options: {
1178                crs: X,
1179                center: void 0,
1180                zoom: void 0,
1181                minZoom: void 0,
1182                maxZoom: void 0,
1183                layers: [],
1184                maxBounds: void 0,
1185                renderer: void 0,
1186                zoomAnimation: !0,
1187                zoomAnimationThreshold: 4,
1188                fadeAnimation: !0,
1189                markerZoomAnimation: !0,
1190                transform3DLimit: 8388608,
1191                zoomSnap: 1,
1192                zoomDelta: 1,
1193                trackResize: !0,
1194            },
1195            initialize: function (t, i) {
1196                (i = p(this, i)),
1197                    (this._handlers = []),
1198                    (this._layers = {}),
1199                    (this._zoomBoundLayers = {}),
1200                    (this._sizeChanged = !0),
1201                    this._initContainer(t),
1202                    this._initLayout(),
1203                    (this._onResize = a(this._onResize, this)),
1204                    this._initEvents(),
1205                    i.maxBounds && this.setMaxBounds(i.maxBounds),
1206                    void 0 !== i.zoom && (this._zoom = this._limitZoom(i.zoom)),
1207                    i.center && void 0 !== i.zoom && this.setView(W(i.center), i.zoom, { reset: !0 }),
1208                    this.callInitHooks(),
1209                    (this._zoomAnimated = oi && yt && !zt && this.options.zoomAnimation),
1210                    this._zoomAnimated && (this._createAnimProxy(), Ei(this._proxy, si, this._catchTransitionEnd, this)),
1211                    this._addLayers(this.options.layers);
1212            },
1213            setView: function (t, i, e) {
1214                if (
1215                    ((i = void 0 === i ? this._zoom : this._limitZoom(i)), (t = this._limitCenter(W(t), i, this.options.maxBounds)), (e = e || {}), this._stop(), this._loaded && !e.reset && !0 !== e) &&
1216                    (void 0 !== e.animate && ((e.zoom = h({ animate: e.animate }, e.zoom)), (e.pan = h({ animate: e.animate, duration: e.duration }, e.pan))),
1217                    this._zoom !== i ? this._tryAnimatedZoom && this._tryAnimatedZoom(t, i, e.zoom) : this._tryAnimatedPan(t, e.pan))
1218                )
1219                    return clearTimeout(this._sizeTimer), this;
1220                return this._resetView(t, i), this;
1221            },
1222            setZoom: function (t, i) {
1223                return this._loaded ? this.setView(this.getCenter(), t, { zoom: i }) : ((this._zoom = t), this);
1224            },
1225            zoomIn: function (t, i) {
1226                return (t = t || (yt ? this.options.zoomDelta : 1)), this.setZoom(this._zoom + t, i);
1227            },
1228            zoomOut: function (t, i) {
1229                return (t = t || (yt ? this.options.zoomDelta : 1)), this.setZoom(this._zoom - t, i);
1230            },
1231            setZoomAround: function (t, i, e) {
1232                var n = this.getZoomScale(i),
1233                    o = this.getSize().divideBy(2),
1234                    s = (t instanceof B ? t : this.latLngToContainerPoint(t)).subtract(o).multiplyBy(1 - 1 / n),
1235                    r = this.containerPointToLatLng(o.add(s));
1236                return this.setView(r, i, { zoom: e });
1237            },
1238            _getBoundsCenterZoom: function (t, i) {
1239                (i = i || {}), (t = t.getBounds ? t.getBounds() : D(t));
1240                var e = I(i.paddingTopLeft || i.padding || [0, 0]),
1241                    n = I(i.paddingBottomRight || i.padding || [0, 0]),
1242                    o = this.getBoundsZoom(t, !1, e.add(n));
1243                if ((o = "number" == typeof i.maxZoom ? Math.min(i.maxZoom, o) : o) === 1 / 0) return { center: t.getCenter(), zoom: o };
1244                var s = n.subtract(e).divideBy(2),
1245                    r = this.project(t.getSouthWest(), o),
1246                    a = this.project(t.getNorthEast(), o);
1247                return { center: this.unproject(r.add(a).divideBy(2).add(s), o), zoom: o };
1248            },
1249            fitBounds: function (t, i) {
1250                if (!(t = D(t)).isValid()) throw new Error("Bounds are not valid.");
1251                var e = this._getBoundsCenterZoom(t, i);
1252                return this.setView(e.center, e.zoom, i);
1253            },
1254            fitWorld: function (t) {
1255                return this.fitBounds(
1256                    [
1257                        [-90, -180],
1258                        [90, 180],
1259                    ],
1260                    t
1261                );
1262            },
1263            panTo: function (t, i) {
1264                return this.setView(t, this._zoom, { pan: i });
1265            },
1266            panBy: function (t, i) {
1267                if (((i = i || {}), !(t = I(t).round()).x && !t.y)) return this.fire("moveend");
1268                if (!0 !== i.animate && !this.getSize().contains(t)) return this._resetView(this.unproject(this.project(this.getCenter()).add(t)), this.getZoom()), this;
1269                if ((this._panAnim || ((this._panAnim = new Xi()), this._panAnim.on({ step: this._onPanTransitionStep, end: this._onPanTransitionEnd }, this)), i.noMoveStart || this.fire("movestart"), !1 !== i.animate)) {
1270                    pi(this._mapPane, "leaflet-pan-anim");
1271                    var e = this._getMapPanePos().subtract(t).round();
1272                    this._panAnim.run(this._mapPane, e, i.duration || 0.25, i.easeLinearity);
1273                } else this._rawPanBy(t), this.fire("move").fire("moveend");
1274                return this;
1275            },
1276            flyTo: function (n, o, t) {
1277                if (!1 === (t = t || {}).animate || !yt) return this.setView(n, o, t);
1278                this._stop();
1279                var s = this.project(this.getCenter()),
1280                    r = this.project(n),
1281                    i = this.getSize(),
1282                    a = this._zoom;
1283                (n = W(n)), (o = void 0 === o ? a : o);
1284                var h = Math.max(i.x, i.y),
1285                    u = h * this.getZoomScale(a, o),
1286                    l = r.distanceTo(s) || 1,
1287                    c = 1.42,
1288                    _ = c * c;
1289                function e(t) {
1290                    var i = (u * u - h * h + (t ? -1 : 1) * _ * _ * l * l) / (2 * (t ? u : h) * _ * l),
1291                        e = Math.sqrt(i * i + 1) - i;
1292                    return e < 1e-9 ? -18 : Math.log(e);
1293                }
1294                function d(t) {
1295                    return (Math.exp(t) - Math.exp(-t)) / 2;
1296                }
1297                function p(t) {
1298                    return (Math.exp(t) + Math.exp(-t)) / 2;
1299                }
1300                var m = e(0);
1301                function f(t) {
1302                    return (
1303                        (h *
1304                            (p(m) *
1305                                (function (t) {
1306                                    return d(t) / p(t);
1307                                })(m + c * t) -
1308                                d(m))) /
1309                        _
1310                    );
1311                }
1312                var g = Date.now(),
1313                    v = (e(1) - m) / c,
1314                    y = t.duration ? 1e3 * t.duration : 1e3 * v * 0.8;
1315                return (
1316                    this._moveStart(!0, t.noMoveStart),
1317                    function t() {
1318                        var i = (Date.now() - g) / y,
1319                            e =
1320                                (function (t) {
1321                                    return 1 - Math.pow(1 - t, 1.5);
1322                                })(i) * v;
1323                        i <= 1
1324                            ? ((this._flyToFrame = M(t, this)),
1325                              this._move(
1326                                  this.unproject(s.add(r.subtract(s).multiplyBy(f(e) / l)), a),
1327                                  this.getScaleZoom(
1328                                      h /
1329                                          (function (t) {
1330                                              return h * (p(m) / p(m + c * t));
1331                                          })(e),
1332                                      a
1333                                  ),
1334                                  { flyTo: !0 }
1335                              ))
1336                            : this._move(n, o)._moveEnd(!0);
1337                    }.call(this),
1338                    this
1339                );
1340            },
1341            flyToBounds: function (t, i) {
1342                var e = this._getBoundsCenterZoom(t, i);
1343                return this.flyTo(e.center, e.zoom, i);
1344            },
1345            setMaxBounds: function (t) {
1346                return (t = D(t)).isValid()
1347                    ? (this.options.maxBounds && this.off("moveend", this._panInsideMaxBounds), (this.options.maxBounds = t), this._loaded && this._panInsideMaxBounds(), this.on("moveend", this._panInsideMaxBounds))
1348                    : ((this.options.maxBounds = null), this.off("moveend", this._panInsideMaxBounds));
1349            },
1350            setMinZoom: function (t) {
1351                var i = this.options.minZoom;
1352                return (this.options.minZoom = t), this._loaded && i !== t && (this.fire("zoomlevelschange"), this.getZoom() < this.options.minZoom) ? this.setZoom(t) : this;
1353            },
1354            setMaxZoom: function (t) {
1355                var i = this.options.maxZoom;
1356                return (this.options.maxZoom = t), this._loaded && i !== t && (this.fire("zoomlevelschange"), this.getZoom() > this.options.maxZoom) ? this.setZoom(t) : this;
1357            },
1358            panInsideBounds: function (t, i) {
1359                this._enforcingBounds = !0;
1360                var e = this.getCenter(),
1361                    n = this._limitCenter(e, this._zoom, D(t));
1362                return e.equals(n) || this.panTo(n, i), (this._enforcingBounds = !1), this;
1363            },
1364            panInside: function (t, i) {
1365                var e = I((i = i || {}).paddingTopLeft || i.padding || [0, 0]),
1366                    n = I(i.paddingBottomRight || i.padding || [0, 0]),
1367                    o = this.getCenter(),
1368                    s = this.project(o),
1369                    r = this.project(t),
1370                    a = this.getPixelBounds(),
1371                    h = a.getSize().divideBy(2),
1372                    u = R([a.min.add(e), a.max.subtract(n)]);
1373                if (!u.contains(r)) {
1374                    this._enforcingBounds = !0;
1375                    var l = s.subtract(r),
1376                        c = I(r.x + l.x, r.y + l.y);
1377                    (r.x < u.min.x || r.x > u.max.x) && ((c.x = s.x - l.x), 0 < l.x ? (c.x += h.x - e.x) : (c.x -= h.x - n.x)),
1378                        (r.y < u.min.y || r.y > u.max.y) && ((c.y = s.y - l.y), 0 < l.y ? (c.y += h.y - e.y) : (c.y -= h.y - n.y)),
1379                        this.panTo(this.unproject(c), i),
1380                        (this._enforcingBounds = !1);
1381                }
1382                return this;
1383            },
1384            invalidateSize: function (t) {
1385                if (!this._loaded) return this;
1386                t = h({ animate: !1, pan: !0 }, !0 === t ? { animate: !0 } : t);
1387                var i = this.getSize();
1388                (this._sizeChanged = !0), (this._lastCenter = null);
1389                var e = this.getSize(),
1390                    n = i.divideBy(2).round(),
1391                    o = e.divideBy(2).round(),
1392                    s = n.subtract(o);
1393                return s.x || s.y
1394                    ? (t.animate && t.pan
1395                          ? this.panBy(s)
1396                          : (t.pan && this._rawPanBy(s), this.fire("move"), t.debounceMoveend ? (clearTimeout(this._sizeTimer), (this._sizeTimer = setTimeout(a(this.fire, this, "moveend"), 200))) : this.fire("moveend")),
1397                      this.fire("resize", { oldSize: i, newSize: e }))
1398                    : this;
1399            },
1400            stop: function () {
1401                return this.setZoom(this._limitZoom(this._zoom)), this.options.zoomSnap || this.fire("viewreset"), this._stop();
1402            },
1403            locate: function (t) {
1404                if (((t = this._locateOptions = h({ timeout: 1e4, watch: !1 }, t)), !("geolocation" in navigator))) return this._handleGeolocationError({ code: 0, message: "Geolocation not supported." }), this;
1405                var i = a(this._handleGeolocationResponse, this),
1406                    e = a(this._handleGeolocationError, this);
1407                return t.watch ? (this._locationWatchId = navigator.geolocation.watchPosition(i, e, t)) : navigator.geolocation.getCurrentPosition(i, e, t), this;
1408            },
1409            stopLocate: function () {
1410                return navigator.geolocation && navigator.geolocation.clearWatch && navigator.geolocation.clearWatch(this._locationWatchId), this._locateOptions && (this._locateOptions.setView = !1), this;
1411            },
1412            _handleGeolocationError: function (t) {
1413                var i = t.code,
1414                    e = t.message || (1 === i ? "permission denied" : 2 === i ? "position unavailable" : "timeout");
1415                this._locateOptions.setView && !this._loaded && this.fitWorld(), this.fire("locationerror", { code: i, message: "Geolocation error: " + e + "." });
1416            },
1417            _handleGeolocationResponse: function (t) {
1418                var i = new j(t.coords.latitude, t.coords.longitude),
1419                    e = i.toBounds(2 * t.coords.accuracy),
1420                    n = this._locateOptions;
1421                if (n.setView) {
1422                    var o = this.getBoundsZoom(e);
1423                    this.setView(i, n.maxZoom ? Math.min(o, n.maxZoom) : o);
1424                }
1425                var s = { latlng: i, bounds: e, timestamp: t.timestamp };
1426                for (var r in t.coords) "number" == typeof t.coords[r] && (s[r] = t.coords[r]);
1427                this.fire("locationfound", s);
1428            },
1429            addHandler: function (t, i) {
1430                if (!i) return this;
1431                var e = (this[t] = new i(this));
1432                return this._handlers.push(e), this.options[t] && e.enable(), this;
1433            },
1434            remove: function () {
1435                if ((this._initEvents(!0), this._containerId !== this._container._leaflet_id)) throw new Error("Map container is being reused by another instance");
1436                try {
1437                    delete this._container._leaflet_id, delete this._containerId;
1438                } catch (t) {
1439                    (this._container._leaflet_id = void 0), (this._containerId = void 0);
1440                }
1441                var t;
1442                for (t in (void 0 !== this._locationWatchId && this.stopLocate(),
1443                this._stop(),
1444                ui(this._mapPane),
1445                this._clearControlPos && this._clearControlPos(),
1446                this._resizeRequest && (C(this._resizeRequest), (this._resizeRequest = null)),
1447                this._clearHandlers(),
1448                this._loaded && this.fire("unload"),
1449                this._layers))
1450                    this._layers[t].remove();
1451                for (t in this._panes) ui(this._panes[t]);
1452                return (this._layers = []), (this._panes = []), delete this._mapPane, delete this._renderer, this;
1453            },
1454            createPane: function (t, i) {
1455                var e = hi("div", "leaflet-pane" + (t ? " leaflet-" + t.replace("Pane", "") + "-pane" : ""), i || this._mapPane);
1456                return t && (this._panes[t] = e), e;
1457            },
1458            getCenter: function () {
1459                return this._checkIfLoaded(), this._lastCenter && !this._moved() ? this._lastCenter : this.layerPointToLatLng(this._getCenterLayerPoint());
1460            },
1461            getZoom: function () {
1462                return this._zoom;
1463            },
1464            getBounds: function () {
1465                var t = this.getPixelBounds();
1466                return new N(this.unproject(t.getBottomLeft()), this.unproject(t.getTopRight()));
1467            },
1468            getMinZoom: function () {
1469                return void 0 === this.options.minZoom ? this._layersMinZoom || 0 : this.options.minZoom;
1470            },
1471            getMaxZoom: function () {
1472                return void 0 === this.options.maxZoom ? (void 0 === this._layersMaxZo
1472om ? 1 / 0 : this._layersMaxZoom) : this.options.maxZoom;
1473            },
1474            getBoundsZoom: function (t, i, e) {
1475                (t = D(t)), (e = I(e || [0, 0]));
1476                var n = this.getZoom() || 0,
1477                    o = this.getMinZoom(),
1478                    s = this.getMaxZoom(),
1479                    r = t.getNorthWest(),
1480                    a = t.getSouthEast(),
1481                    h = this.getSize().subtract(e),
1482                    u = R(this.project(a, n), this.project(r, n)).getSize(),
1483                    l = yt ? this.options.zoomSnap : 1,
1484                    c = h.x / u.x,
1485                    _ = h.y / u.y,
1486                    d = i ? Math.max(c, _) : Math.min(c, _);
1487                return (n = this.getScaleZoom(d, n)), l && ((n = Math.round(n / (l / 100)) * (l / 100)), (n = i ? Math.ceil(n / l) * l : Math.floor(n / l) * l)), Math.max(o, Math.min(s, n));
1488            },
1489            getSize: function () {
1490                return (this._size && !this._sizeChanged) || ((this._size = new B(this._container.clientWidth || 0, this._container.clientHeight || 0)), (this._sizeChanged = !1)), this._size.clone();
1491            },
1492            getPixelBounds: function (t, i) {
1493                var e = this._getTopLeftPoint(t, i);
1494                return new O(e, e.add(this.getSize()));
1495            },
1496            getPixelOrigin: function () {
1497                return this._checkIfLoaded(), this._pixelOrigin;
1498            },
1499            getPixelWorldBounds: function (t) {
1500                return this.options.crs.getProjectedBounds(void 0 === t ? this.getZoom() : t);
1501            },
1502            getPane: function (t) {
1503                return "string" == typeof t ? this._panes[t] : t;
1504            },
1505            getPanes: function () {
1506                return this._panes;
1507            },
1508            getContainer: function () {
1509                return this._container;
1510            },
1511            getZoomScale: function (t, i) {
1512                var e = this.options.crs;
1513                return (i = void 0 === i ? this._zoom : i), e.scale(t) / e.scale(i);
1514            },
1515            getScaleZoom: function (t, i) {
1516                var e = this.options.crs;
1517                i = void 0 === i ? this._zoom : i;
1518                var n = e.zoom(t * e.scale(i));
1519                return isNaN(n) ? 1 / 0 : n;
1520            },
1521            project: function (t, i) {
1522                return (i = void 0 === i ? this._zoom : i), this.options.crs.latLngToPoint(W(t), i);
1523            },
1524            unproject: function (t, i) {
1525                return (i = void 0 === i ? this._zoom : i), this.options.crs.pointToLatLng(I(t), i);
1526            },
1527            layerPointToLatLng: function (t) {
1528                var i = I(t).add(this.getPixelOrigin());
1529                return this.unproject(i);
1530            },
1531            latLngToLayerPoint: function (t) {
1532                return this.project(W(t))._round()._subtract(this.getPixelOrigin());
1533            },
1534            wrapLatLng: function (t) {
1535                return this.options.crs.wrapLatLng(W(t));
1536            },
1537            wrapLatLngBounds: function (t) {
1538                return this.options.crs.wrapLatLngBounds(D(t));
1539            },
1540            distance: function (t, i) {
1541                return this.options.crs.distance(W(t), W(i));
1542            },
1543            containerPointToLayerPoint: function (t) {
1544                return I(t).subtract(this._getMapPanePos());
1545            },
1546            layerPointToContainerPoint: function (t) {
1547                return I(t).add(this._getMapPanePos());
1548            },
1549            containerPointToLatLng: function (t) {
1550                var i = this.containerPointToLayerPoint(I(t));
1551                return this.layerPointToLatLng(i);
1552            },
1553            latLngToContainerPoint: function (t) {
1554                return this.layerPointToContainerPoint(this.latLngToLayerPoint(W(t)));
1555            },
1556            mouseEventToContainerPoint: function (t) {
1557                return Wi(t, this._container);
1558            },
1559            mouseEventToLayerPoint: function (t) {
1560                return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(t));
1561            },
1562            mouseEventToLatLng: function (t) {
1563                return this.layerPointToLatLng(this.mouseEventToLayerPoint(t));
1564            },
1565            _initContainer: function (t) {
1566                var i = (this._container = ri(t));
1567                if (!i) throw new Error("Map container not found.");
1568                if (i._leaflet_id) throw new Error("Map container is already initialized.");
1569                Ei(i, "scroll", this._onScroll, this), (this._containerId = u(i));
1570            },
1571            _initLayout: function () {
1572                var t = this._container;
1573                (this._fadeAnimated = this.options.fadeAnimation && yt),
1574                    pi(t, "leaflet-container" + (Tt ? " leaflet-touch" : "") + (Ct ? " leaflet-retina" : "") + (et ? " leaflet-oldie" : "") + (_t ? " leaflet-safari" : "") + (this._fadeAnimated ? " leaflet-fade-anim" : ""));
1575                var i = ai(t, "position");
1576                "absolute" !== i && "relative" !== i && "fixed" !== i && (t.style.position = "relative"), this._initPanes(), this._initControlPos && this._initControlPos();
1577            },
1578            _initPanes: function () {
1579                var t = (this._panes = {});
1580                (this._paneRenderers = {}),
1581                    (this._mapPane = this.createPane("mapPane", this._container)),
1582                    wi(this._mapPane, new B(0, 0)),
1583                    this.createPane("tilePane"),
1584                    this.createPane("shadowPane"),
1585                    this.createPane("overlayPane"),
1586                    this.createPane("markerPane"),
1587                    this.createPane("tooltipPane"),
1588                    this.createPane("popupPane"),
1589                    this.options.markerZoomAnimation || (pi(t.markerPane, "leaflet-zoom-hide"), pi(t.shadowPane, "leaflet-zoom-hide"));
1590            },
1591            _resetView: function (t, i) {
1592                wi(this._mapPane, new B(0, 0));
1593                var e = !this._loaded;
1594                (this._loaded = !0), (i = this._limitZoom(i)), this.fire("viewprereset");
1595                var n = this._zoom !== i;
1596                this._moveStart(n, !1)._move(t, i)._moveEnd(n), this.fire("viewreset"), e && this.fire("load");
1597            },
1598            _moveStart: function (t, i) {
1599                return t && this.fire("zoomstart"), i || this.fire("movestart"), this;
1600            },
1601            _move: function (t, i, e) {
1602                void 0 === i && (i = this._zoom);
1603                var n = this._zoom !== i;
1604                return (this._zoom = i), (this._lastCenter = t), (this._pixelOrigin = this._getNewPixelOrigin(t)), (n || (e && e.pinch)) && this.fire("zoom", e), this.fire("move", e);
1605            },
1606            _moveEnd: function (t) {
1607                return t && this.fire("zoomend"), this.fire("moveend");
1608            },
1609            _stop: function () {
1610                return C(this._flyToFrame), this._panAnim && this._panAnim.stop(), this;
1611            },
1612            _rawPanBy: function (t) {
1613                wi(this._mapPane, this._getMapPanePos().subtract(t));
1614            },
1615            _getZoomSpan: function () {
1616                return this.getMaxZoom() - this.getMinZoom();
1617            },
1618            _panInsideMaxBounds: function () {
1619                this._enforcingBounds || this.panInsideBounds(this.options.maxBounds);
1620            },
1621            _checkIfLoaded: function () {
1622                if (!this._loaded) throw new Error("Set map center and zoom first.");
1623            },
1624            _initEvents: function (t) {
1625                this._targets = {};
1626                var i = t ? Bi : Ei;
1627                i((this._targets[u(this._container)] = this)._container, "click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup", this._handleDOMEvent, this),
1628                    this.options.trackResize && i(window, "resize", this._onResize, this),
1629                    yt && this.options.transform3DLimit && (t ? this.off : this.on).call(this, "moveend", this._onMoveEnd);
1630            },
1631            _onResize: function () {
1632                C(this._resizeRequest),
1633                    (this._resizeRequest = M(function () {
1634                        this.invalidateSize({ debounceMoveend: !0 });
1635                    }, this));
1636            },
1637            _onScroll: function () {
1638                (this._container.scrollTop = 0), (this._container.scrollLeft = 0);
1639            },
1640            _onMoveEnd: function () {
1641                var t = this._getMapPanePos();
1642                Math.max(Math.abs(t.x), Math.abs(t.y)) >= this.options.transform3DLimit && this._resetView(this.getCenter(), this.getZoom());
1643            },
1644            _findEventTargets: function (t, i) {
1645                for (var e, n = [], o = "mouseout" === i || "mouseover" === i, s = t.target || t.srcElement, r = !1; s; ) {
1646                    if ((e = this._targets[u(s)]) && ("click" === i || "preclick" === i) && !t._simulated && this._draggableMoved(e)) {
1647                        r = !0;
1648                        break;
1649                    }
1650                    if (e && e.listens(i, !0)) {
1651                        if (o && !Ki(s, t)) break;
1652                        if ((n.push(e), o)) break;
1653                    }
1654                    if (s === this._container) break;
1655                    s = s.parentNode;
1656                }
1657                return n.length || r || o || !Ki(s, t) || (n = [this]), n;
1658            },
1659            _handleDOMEvent: function (t) {
1660                if (this._loaded && !Gi(t)) {
1661                    var i = t.type;
1662                    ("mousedown" !== i && "keypress" !== i && "keyup" !== i && "keydown" !== i) || zi(t.target || t.srcElement), this._fireDOMEvent(t, i);
1663                }
1664            },
1665            _mouseEvents: ["click", "dblclick", "mouseover", "mouseout", "contextmenu"],
1666            _fireDOMEvent: function (t, i, e) {
1667                if ("click" === t.type) {
1668                    var n = h({}, t);
1669                    (n.type = "preclick"), this._fireDOMEvent(n, n.type, e);
1670                }
1671                if (!t._stopped && (e = (e || []).concat(this._findEventTargets(t, i))).length) {
1672                    var o = e[0];
1673                    "contextmenu" === i && o.listens(i, !0) && Di(t);
1674                    var s = { originalEvent: t };
1675                    if ("keypress" !== t.type && "keydown" !== t.type && "keyup" !== t.type) {
1676                        var r = o.getLatLng && (!o._radius || o._radius <= 10);
1677                        (s.containerPoint = r ? this.latLngToContainerPoint(o.getLatLng()) : this.mouseEventToContainerPoint(t)),
1678                            (s.layerPoint = this.containerPointToLayerPoint(s.containerPoint)),
1679                            (s.latlng = r ? o.getLatLng() : this.layerPointToLatLng(s.layerPoint));
1680                    }
1681                    for (var a = 0; a < e.length; a++) if ((e[a].fire(i, s, !0), s.originalEvent._stopped || (!1 === e[a].options.bubblingMouseEvents && -1 !== y(this._mouseEvents, i)))) return;
1682                }
1683            },
1684            _draggableMoved: function (t) {
1685                return ((t = t.dragging && t.dragging.enabled() ? t : this).dragging && t.dragging.moved()) || (this.boxZoom && this.boxZoom.moved());
1686            },
1687            _clearHandlers: function () {
1688                for (var t = 0, i = this._handlers.length; t < i; t++) this._handlers[t].disable();
1689            },
1690            whenReady: function (t, i) {
1691                return this._loaded ? t.call(i || this, { target: this }) : this.on("load", t, i), this;
1692            },
1693            _getMapPanePos: function () {
1694                return Pi(this._mapPane) || new B(0, 0);
1695            },
1696            _moved: function () {
1697                var t = this._getMapPanePos();
1698                return t && !t.equals([0, 0]);
1699            },
1700            _getTopLeftPoint: function (t, i) {
1701                return (t && void 0 !== i ? this._getNewPixelOrigin(t, i) : this.getPixelOrigin()).subtract(this._getMapPanePos());
1702            },
1703            _getNewPixelOrigin: function (t, i) {
vendor: 1,779 bytes, lines 1704-1736
1704                var e = this.getSize()._divideBy(2);
1705                return this.project(t, i)._subtract(e)._add(this._getMapPanePos())._round();
1706            },
1707            _latLngToNewLayerPoint: function (t, i, e) {
1708                var n = this._getNewPixelOrigin(e, i);
1709                return this.project(t, i)._subtract(n);
1710            },
1711            _latLngBoundsToNewLayerBounds: function (t, i, e) {
1712                var n = this._getNewPixelOrigin(e, i);
1713                return R([this.project(t.getSouthWest(), i)._subtract(n), this.project(t.getNorthWest(), i)._subtract(n), this.project(t.getSouthEast(), i)._subtract(n), this.project(t.getNorthEast(), i)._subtract(n)]);
1714            },
1715            _getCenterLayerPoint: function () {
1716                return this.containerPointToLayerPoint(this.getSize()._divideBy(2));
1717            },
1718            _getCenterOffset: function (t) {
1719                return this.latLngToLayerPoint(t).subtract(this._getCenterLayerPoint());
1720            },
1721            _limitCenter: function (t, i, e) {
1722                if (!e) return t;
1723                var n = this.project(t, i),
1724                    o = this.getSize().divideBy(2),
1725                    s = new O(n.subtract(o), n.add(o)),
1726                    r = this._getBoundsOffset(s, e, i);
1727                return r.round().equals([0, 0]) ? t : this.unproject(n.add(r), i);
1728            },
1729            _limitOffset: function (t, i) {
1730                if (!i) return t;
1731                var e = this.getPixelBounds(),
1732                    n = new O(e.min.add(t), e.max.add(t));
1733                return t.add(this._getBoundsOffset(n, i));
1734            },
1735            _getBoundsOffset: function (t, i, e) {
1736                var n = R(this.project(i.getNorthEast(), e), this.project(i.getSouthWest
1736(), e)),
1737                    o = n.min.subtract(t.min),
1738                    s = n.max.subtract(t.max);
1739                return new B(this._rebound(o.x, -s.x), this._rebound(o.y, -s.y));
1740            },
1741            _rebound: function (t, i) {
1742                return 0 < t + i ? Math.round(t - i) / 2 : Math.max(0, Math.ceil(t)) - Math.max(0, Math.floor(i));
1743            },
1744            _limitZoom: function (t) {
1745                var i = this.getMinZoom(),
1746                    e = this.getMaxZoom(),
1747                    n = yt ? this.options.zoomSnap : 1;
1748                return n && (t = Math.round(t / n) * n), Math.max(i, Math.min(e, t));
1749            },
1750            _onPanTransitionStep: function () {
1751                this.fire("move");
1752            },
1753            _onPanTransitionEnd: function () {
1754                mi(this._mapPane, "leaflet-pan-anim"), this.fire("moveend");
1755            },
1756            _tryAnimatedPan: function (t, i) {
1757                var e = this._getCenterOffset(t)._trunc();
1758                return !(!0 !== (i && i.animate) && !this.getSize().contains(e)) && (this.panBy(e, i), !0);
1759            },
1760            _createAnimProxy: function () {
1761                var t = (this._proxy = hi("div", "leaflet-proxy leaflet-zoom-animated"));
1762                this._panes.mapPane.appendChild(t),
1763                    this.on(
1764                        "zoomanim",
1765                        function (t) {
1766                            var i = ni,
1767                                e = this._proxy.style[i];
1768                            xi(this._proxy, this.project(t.center, t.zoom), this.getZoomScale(t.zoom, 1)), e === this._proxy.style[i] && this._animatingZoom && this._onZoomTransitionEnd();
1769                        },
1770                        this
1771                    ),
1772                    this.on(
1773                        "load moveend",
1774                        function () {
1775                            var t = this.getCenter(),
1776                                i = this.getZoom();
1777                            xi(this._proxy, this.project(t, i), this.getZoomScale(i, 1));
1778                        },
1779                        this
1780                    ),
1781                    this._on("unload", this._destroyAnimProxy, this);
1782            },
1783            _destroyAnimProxy: function () {
1784                ui(this._proxy), delete this._proxy;
1785            },
1786            _catchTransitionEnd: function (t) {
1787                this._animatingZoom && 0 <= t.propertyName.indexOf("transform") && this._onZoomTransitionEnd();
1788            },
1789            _nothingToAnimate: function () {
1790                return !this._container.getElementsByClassName("leaflet-zoom-animated").length;
1791            },
1792            _tryAnimatedZoom: function (t, i, e) {
1793                if (this._animatingZoom) return !0;
1794                if (((e = e || {}), !this._zoomAnimated || !1 === e.animate || this._nothingToAnimate() || Math.abs(i - this._zoom) > this.options.zoomAnimationThreshold)) return !1;
1795                var n = this.getZoomScale(i),
1796                    o = this._getCenterOffset(t)._divideBy(1 - 1 / n);
1797                return (
1798                    !(!0 !== e.animate && !this.getSize().contains(o)) &&
1799                    (M(function () {
1800                        this._moveStart(!0, !1)._animateZoom(t, i, !0);
1801                    }, this),
1802                    !0)
1803                );
1804            },
1805            _animateZoom: function (t, i, e, n) {
1806                this._mapPane &&
1807                    (e && ((this._animatingZoom = !0), (this._animateToCenter = t), (this._animateToZoom = i), pi(this._mapPane, "leaflet-zoom-anim")),
1808                    this.fire("zoomanim", { center: t, zoom: i, noUpdate: n }),
1809                    setTimeout(a(this._onZoomTransitionEnd, this), 250));
1810            },
1811            _onZoomTransitionEnd: function () {
1812                this._animatingZoom &&
1813                    (this._mapPane && mi(this._mapPane, "leaflet-zoom-anim"),
1814                    (this._animatingZoom = !1),
1815                    this._move(this._animateToCenter, this._animateToZoom),
1816                    M(function () {
1817                        this._moveEnd(!0);
1818                    }, this));
1819            },
1820        });
1821    function $i(t) {
1822        return new Qi(t);
1823    }
1824    var Qi = Z.extend({
1825        options: { position: "topright" },
1826        initialize: function (t) {
1827            p(this, t);
1828        },
1829        getPosition: function () {
1830            return this.options.position;
1831        },
1832        setPosition: function (t) {
1833            var i = this._map;
1834            return i && i.removeControl(this), (this.options.position = t), i && i.addControl(this), this;
1835        },
1836        getContainer: function () {
1837            return this._container;
1838        },
1839        addTo: function (t) {
1840            this.remove(), (this._map = t);
1841            var i = (this._container = this.onAdd(t)),
1842                e = this.getPosition(),
1843                n = t._controlCorners[e];
1844            return pi(i, "leaflet-control"), -1 !== e.indexOf("bottom") ? n.insertBefore(i, n.firstChild) : n.appendChild(i), this._map.on("unload", this.remove, this), this;
1845        },
1846        remove: function () {
1847            return this._map && (ui(this._container), this.onRemove && this.onRemove(this._map), this._map.off("unload", this.remove, this), (this._map = null)), this;
1848        },
1849        _refocusOnMap: function (t) {
1850            this._map && t && 0 < t.screenX && 0 < t.screenY && this._map.getContainer().focus();
1851        },
1852    });
1853    Ji.include({
1854        addControl: function (t) {
1855            return t.addTo(this), this;
1856        },
1857        removeControl: function (t) {
1858            return t.remove(), this;
1859        },
1860        _initControlPos: function () {
1861            var n = (this._controlCorners = {}),
1862                o = "leaflet-",
1863                s = (this._controlContainer = hi("div", o + "control-container", this._container));
1864            function t(t, i) {
1865                var e = o + t + " " + o + i;
1866                n[t + i] = hi("div", e, s);
1867            }
1868            t("top", "left"), t("top", "right"), t("bottom", "left"), t("bottom", "right");
1869        },
1870        _clearControlPos: function () {
1871            for (var t in this._controlCorners) ui(this._controlCorners[t]);
1872            ui(this._controlContainer), delete this._controlCorners, delete this._controlContainer;
1873        },
1874    });
1875    var te = Qi.extend({
1876            options: {
1877                collapsed: !0,
1878                position: "topright",
1879                autoZIndex: !0,
1880                hideSingleBase: !1,
1881                sortLayers: !1,
1882                sortFunction: function (t, i, e, n) {
1883                    return e < n ? -1 : n < e ? 1 : 0;
1884                },
1885            },
1886            initialize: function (t, i, e) {
1887                for (var n in (p(this, e), (this._layerControlInputs = []), (this._layers = []), (this._lastZIndex = 0), (this._handlingClick = !1), t)) this._addLayer(t[n], n);
1888                for (n in i) this._addLayer(i[n], n, !0);
1889            },
1890            onAdd: function (t) {
1891                this._initLayout(), this._update(), (this._map = t).on("zoomend", this._checkDisabledLayers, this);
1892                for (var i = 0; i < this._layers.length; i++) this._layers[i].layer.on("add remove", this._onLayerChange, this);
1893                return this._container;
1894            },
1895            addTo: function (t) {
1896                return Qi.prototype.addTo.call(this, t), this._expandIfNotCollapsed();
1897            },
1898            onRemove: function () {
1899                this._map.off("zoomend", this._checkDisabledLayers, this);
1900                for (var t = 0; t < this._layers.length; t++) this._layers[t].layer.off("add remove", this._onLayerChange, this);
1901            },
1902            addBaseLayer: function (t, i) {
1903                return this._addLayer(t, i), this._map ? this._update() : this;
1904            },
1905            addOverlay: function (t, i) {
1906                return this._addLayer(t, i, !0), this._map ? this._update() : this;
1907            },
1908            removeLayer: function (t) {
1909                t.off("add remove", this._onLayerChange, this);
1910                var i = this._getLayer(u(t));
1911                return i && this._layers.splice(this._layers.indexOf(i), 1), this._map ? this._update() : this;
1912            },
1913            expand: function () {
1914                pi(this._container, "leaflet-control-layers-expanded"), (this._section.style.height = null);
1915                var t = this._map.getSize().y - (this._container.offsetTop + 50);
1916                return (
1917                    t < this._section.clientHeight ? (pi(this._section, "leaflet-control-layers-scrollbar"), (this._section.style.height = t + "px")) : mi(this._section, "leaflet-control-layers-scrollbar"), this._checkDisabledLayers(), this
1918                );
1919            },
1920            collapse: function () {
1921                return mi(this._container, "leaflet-control-layers-expanded"), this;
1922            },
1923            _initLayout: function () {
1924                var t = "leaflet-control-layers",
1925                    i = (this._container = hi("div", t)),
1926                    e = this.options.collapsed;
1927                i.setAttribute("aria-haspopup", !0), Ni(i), Ri(i);
1928                var n = (this._section = hi("section", t + "-list"));
1929                e && (this._map.on("click", this.collapse, this), st || Ei(i, { mouseenter: this.expand, mouseleave: this.collapse }, this));
1930                var o = (this._layersLink = hi("a", t + "-toggle", i));
1931                (o.href = "#"),
1932                    (o.title = "Layers"),
1933                    Tt ? (Ei(o, "click", ji), Ei(o, "click", this.expand, this)) : Ei(o, "focus", this.expand, this),
1934                    e || this.expand(),
1935                    (this._baseLayersList = hi("div", t + "-base", n)),
1936                    (this._separator = hi("div", t + "-separator", n)),
1937                    (this._overlaysList = hi("div", t + "-overlays", n)),
1938                    i.appendChild(n);
1939            },
1940            _getLayer: function (t) {
1941                for (var i = 0; i < this._layers.length; i++) if (this._layers[i] && u(this._layers[i].layer) === t) return this._layers[i];
1942            },
1943            _addLayer: function (t, i, e) {
1944                this._map && t.on("add remove", this._onLayerChange, this),
1945                    this._layers.push({ layer: t, name: i, overlay: e }),
1946                    this.options.sortLayers &&
1947                        this._layers.sort(
1948                            a(function (t, i) {
1949                                return this.options.sortFunction(t.layer, i.layer, t.name, i.name);
1950                            }, this)
1951                        ),
1952                    this.options.autoZIndex && t.setZIndex && (this._lastZIndex++, t.setZIndex(this._lastZIndex)),
1953                    this._expandIfNotCollapsed();
1954            },
1955            _update: function () {
1956                if (!this._container) return this;
1957                li(this._baseLayersList), li(this._overlaysList), (this._layerControlInputs = []);
1958                var t,
1959                    i,
1960                    e,
1961                    n,
1962                    o = 0;
1963                for (e = 0; e < this._layers.length; e++) (n = this._layers[e]), this._addItem(n), (i = i || n.overlay), (t = t || !n.overlay), (o += n.overlay ? 0 : 1);
1964                return this.options.hideSingleBase && ((t = t && 1 < o), (this._baseLayersList.style.display = t ? "" : "none")), (this._separator.style.display = i && t ? "" : "none"), this;
1965            },
1966            _onLayerChange: function (t) {
1967                this._handlingClick || this._update();
1968                var i = this._getLayer(u(t.target)),
1969                    e = i.overlay ? ("add" === t.type ? "overlayadd" : "overlayremove") : "add" === t.type ? "baselayerchange" : null;
1970                e && this._map.fire(e, i);
1971            },
1972            _createRadioElement: function (t, i) {
1973                var e = '<input type="radio" class="leaflet-control-layers-selector" name="' + t + '"' + (i ? ' checked="checked"' : "") + "/>",
1974                    n = document.createElement("div");
1975                return (n.innerHTML = e), n.firstChild;
1976            },
1977            _addItem: function (t) {
1978                var i,
1979                    e = document.createElement("label"),
1980                    n = this._map.hasLayer(t.layer);
1981                t.overlay ? (((i = document.createElement("input")).type = "checkbox"), (i.className = "leaflet-control-layers-selector"), (i.defaultChecked = n)) : (i = this._createRadioElement("leaflet-base-layers_" + u(this), n)),
1982                    this._layerControlInputs.push(i),
1983                    (i.layerId = u(t.layer)),
1984                    Ei(i, "click", this._onInputClick, this);
1985                var o = document.createElement("span");
1986                o.innerHTML = " " + t.name;
1987                var s = document.createElement("div");
1988                return e.appendChild(s), s.appendChild(i), s.appendChild(o), (t.overlay ? this._overlaysList : this._baseLayersList).appendChild(e), this._checkDisabledLayers(), e;
1989            },
1990            _onInputClick: function () {
1991                var t,
1992                    i,
1993                    e = this._layerControlInputs,
1994                    n = [],
1995                    o = [];
1996                this._handlingClick = !0;
1997                for (var s = e.length - 1; 0 <= s; s--) (t = e[s]), (i = this._getLayer(t.layerId).layer), t.checked ? n.push(i) : t.checked || o.push(i);
1998                for (s = 0; s < o.length; s++) this._map.hasLayer(o[s]) && this._map.removeLayer(o[s]);
1999                for (s = 0; s < n.length; s++) this._map.hasLayer(n[s]) || this._map.addLayer(n[s]);
2000                (this._handlingClick = !1), this._refocusOnMap();
2001            },
2002            _checkDisabledLayers: function () {
2003                for (var t, i, e = this._layerControlInputs, n = this._map.getZoom(), o = e.length - 1; 0 <= o; o--)
2004                    (t = e[o]), (i = this._getLayer(t.layerId).layer), (t.disabled = (void 0 !== i.options.minZoom && n < i.options.minZoom) || (void 0 !== i.options.maxZoom && n > i.options.maxZoom));
2005            },
2006            _expandIfNotCollapsed: function () {
2007                return this._map && !this.options.collapsed && this.expand(), this;
2008            },
2009            _expand: function () {
2010                return this.expand();
2011            },
2012            _collapse: function () {
2013                return this.collapse();
2014            },
2015        }),
2016        ie = Qi.extend({
2017            options: { position: "topleft", zoomInText: "+", zoomInTitle: "Zoom in", zoomOutText: "&#x2212;", zoomOutTitle: "Zoom out" },
2018            onAdd: function (t) {
2019                var i = "leaflet-control-zoom",
2020                    e = hi("div", i + " leaflet-bar"),
2021                    n = this.options;
2022                return (
2023                    (this._zoomInButton = this._createButton(n.zoomInText, n.zoomInTitle, i + "-in", e, this._zoomIn)),
2024                    (this._zoomOutButton = this._createButton(n.zoomOutText, n.zoomOutTitle, i + "-out", e, this._zoomOut)),
2025                    this._updateDisabled(),
2026                    t.on("zoomend zoomlevelschange", this._updateDisabled, this),
2027                    e
2028                );
2029            },
2030            onRemove: function (t) {
2031                t.off("zoomend zoomlevelschange", this._updateDisabled, this);
2032            },
2033            disable: function () {
2034                return (this._disabled = !0), this._updateDisabled(), this;
2035            },
2036            enable: function () {
2037                return (this._disabled = !1), this._updateDisabled(), this;
2038            },
2039            _zoomIn: function (t) {
2040                !this._disabled && this._map._zoom < this._map.getMaxZoom() && this._map.zoomIn(this._map.options.zoomDelta * (t.shiftKey ? 3 : 1));
2041            },
2042            _zoomOut: function (t) {
2043                !this._disabled && this._map._zoom > this._map.getMinZoom() && this._map.zoomOut(this._map.options.zoomDelta * (t.shiftKey ? 3 : 1));
2044            },
2045            _createButton: function (t, i, e, n, o) {
2046                var s = hi("a", e, n);
2047                return (s.innerHTML = t), (s.href = "#"), (s.title = i), s.setAttribute("role", "button"), s.setAttribute("aria-label", i), Ni(s), Ei(s, "click", ji), Ei(s, "click", o, this), Ei(s, "click", this._refocusOnMap, this), s;
2048            },
2049            _updateDisabled: function () {
2050                var t = this._map,
2051                    i = "leaflet-disabled";
2052                mi(this._zoomInButton, i), mi(this._zoomOutButton, i), (!this._disabled && t._zoom !== t.getMin
2052Zoom()) || pi(this._zoomOutButton, i), (!this._disabled && t._zoom !== t.getMaxZoom()) || pi(this._zoomInButton, i);
2053            },
2054        });
2055    Ji.mergeOptions({ zoomControl: !0 }),
2056        Ji.addInitHook(function () {
2057            this.options.zoomControl && ((this.zoomControl = new ie()), this.addControl(this.zoomControl));
2058        });
2059    var ee = Qi.extend({
2060            options: { position: "bottomleft", maxWidth: 100, metric: !0, imperial: !0 },
2061            onAdd: function (t) {
2062                var i = "leaflet-control-scale",
2063                    e = hi("div", i),
2064                    n = this.options;
2065                return this._addScales(n, i + "-line", e), t.on(n.updateWhenIdle ? "moveend" : "move", this._update, this), t.whenReady(this._update, this), e;
2066            },
2067            onRemove: function (t) {
2068                t.off(this.options.updateWhenIdle ? "moveend" : "move", this._update, this);
2069            },
2070            _addScales: function (t, i, e) {
2071                t.metric && (this._mScale = hi("div", i, e)), t.imperial && (this._iScale = hi("div", i, e));
2072            },
2073            _update: function () {
2074                var t = this._map,
2075                    i = t.getSize().y / 2,
2076                    e = t.distance(t.containerPointToLatLng([0, i]), t.containerPointToLatLng([this.options.maxWidth, i]));
2077                this._updateScales(e);
2078            },
2079            _updateScales: function (t) {
2080                this.options.metric && t && this._updateMetric(t), this.options.imperial && t && this._updateImperial(t);
2081            },
2082            _updateMetric: function (t) {
2083                var i = this._getRoundNum(t),
2084                    e = i < 1e3 ? i + " m" : i / 1e3 + " km";
2085                this._updateScale(this._mScale, e, i / t);
2086            },
2087            _updateImperial: function (t) {
2088                var i,
2089                    e,
2090                    n,
2091                    o = 3.2808399 * t;
2092                5280 < o ? ((i = o / 5280), (e = this._getRoundNum(i)), this._updateScale(this._iScale, e + " mi", e / i)) : ((n = this._getRoundNum(o)), this._updateScale(this._iScale, n + " ft", n / o));
2093            },
2094            _updateScale: function (t, i, e) {
2095                (t.style.width = Math.round(this.options.maxWidth * e) + "px"), (t.innerHTML = i);
2096            },
2097            _getRoundNum: function (t) {
2098                var i = Math.pow(10, (Math.floor(t) + "").length - 1),
2099                    e = t / i;
2100                return i * (e = 10 <= e ? 10 : 5 <= e ? 5 : 3 <= e ? 3 : 2 <= e ? 2 : 1);
2101            },
2102        }),
2103        ne = Qi.extend({
2104            options: { position: "bottomright", prefix: '<a href="https://leafletjs.com" title="A JS library for interactive maps">Leaflet</a>' },
2105            initialize: function (t) {
2106                p(this, t), (this._attributions = {});
2107            },
2108            onAdd: function (t) {
2109                for (var i in (((t.attributionControl = this)._container = hi("div", "leaflet-control-attribution")), Ni(this._container), t._layers)) t._layers[i].getAttribution && this.addAttribution(t._layers[i].getAttribution());
2110                return this._update(), this._container;
2111            },
2112            setPrefix: function (t) {
2113                return (this.options.prefix = t), this._update(), this;
2114            },
2115            addAttribution: function (t) {
2116                return t && (this._attributions[t] || (this._attributions[t] = 0), this._attributions[t]++, this._update()), this;
2117            },
2118            removeAttribution: function (t) {
2119                return t && this._attributions[t] && (this._attributions[t]--, this._update()), this;
2120            },
2121            _update: function () {
2122                if (this._map) {
2123                    var t = [];
2124                    for (var i in this._attributions) this._attributions[i] && t.push(i);
2125                    var e = [];
2126                    this.options.prefix && e.push(this.options.prefix), t.length && e.push(t.join(", ")), (this._container.innerHTML = e.join(" | "));
2127                }
2128            },
2129        });
2130    Ji.mergeOptions({ attributionControl: !0 }),
2131        Ji.addInitHook(function () {
2132            this.options.attributionControl && new ne().addTo(this);
2133        });
2134    (Qi.Layers = te),
2135        (Qi.Zoom = ie),
2136        (Qi.Scale = ee),
2137        (Qi.Attribution = ne),
2138        ($i.layers = function (t, i, e) {
2139            return new te(t, i, e);
2140        }),
2141        ($i.zoom = function (t) {
2142            return new ie(t);
2143        }),
2144        ($i.scale = function (t) {
2145            return new ee(t);
2146        }),
2147        ($i.attribution = function (t) {
2148            return new ne(t);
2149        });
2150    var oe = Z.extend({
2151        initialize: function (t) {
2152            this._map = t;
2153        },
2154        enable: function () {
2155            return this._enabled || ((this._enabled = !0), this.addHooks()), this;
2156        },
2157        disable: function () {
2158            return this._enabled && ((this._enabled = !1), this.removeHooks()), this;
2159        },
2160        enabled: function () {
2161            return !!this._enabled;
2162        },
2163    });
2164    oe.addTo = function (t, i) {
2165        return t.addHandler(i, this), this;
2166    };
2167    var se,
2168        re = { Events: E },
2169        ae = Tt ? "touchstart mousedown" : "mousedown",
2170        he = { mousedown: "mouseup", touchstart: "touchend", pointerdown: "touchend", MSPointerDown: "touchend" },
2171        ue = { mousedown: "mousemove", touchstart: "touchmove", pointerdown: "touchmove", MSPointerDown: "touchmove" },
2172        le = k.extend({
2173            options: { clickTolerance: 3 },
2174            initialize: function (t, i, e, n) {
2175                p(this, n), (this._element = t), (this._dragStartTarget = i || t), (this._preventOutline = e);
2176            },
2177            enable: function () {
2178                this._enabled || (Ei(this._dragStartTarget, ae, this._onDown, this), (this._enabled = !0));
2179            },
2180            disable: function () {
2181                this._enabled && (le._dragging === this && this.finishDrag(), Bi(this._dragStartTarget, ae, this._onDown, this), (this._enabled = !1), (this._moved = !1));
2182            },
2183            _onDown: function (t) {
2184                if (
2185                    !t._simulated &&
2186                    this._enabled &&
2187                    ((this._moved = !1),
2188                    !di(this._element, "leaflet-zoom-anim") && !(le._dragging || t.shiftKey || (1 !== t.which && 1 !== t.button && !t.touches) || ((le._dragging = this)._preventOutline && zi(this._element), Li(), $t(), this._moving)))
2189                ) {
2190                    this.fire("down");
2191                    var i = t.touches ? t.touches[0] : t,
2192                        e = Ci(this._element);
2193                    (this._startPoint = new B(i.clientX, i.clientY)), (this._parentScale = Si(e)), Ei(document, ue[t.type], this._onMove, this), Ei(document, he[t.type], this._onUp, this);
2194                }
2195            },
2196            _onMove: function (t) {
2197                if (!t._simulated && this._enabled)
2198                    if (t.touches && 1 < t.touches.length) this._moved = !0;
2199                    else {
2200                        var i = t.touches && 1 === t.touches.length ? t.touches[0] : t,
2201                            e = new B(i.clientX, i.clientY)._subtract(this._startPoint);
2202                        (e.x || e.y) &&
2203                            (Math.abs(e.x) + Math.abs(e.y) < this.options.clickTolerance ||
2204                                ((e.x /= this._parentScale.x),
2205                                (e.y /= this._parentScale.y),
2206                                Di(t),
2207                                this._moved ||
2208                                    (this.fire("dragstart"),
2209                                    (this._moved = !0),
2210                                    (this._startPos = Pi(this._element).subtract(e)),
2211                                    pi(document.body, "leaflet-dragging"),
2212                                    (this._lastTarget = t.target || t.srcElement),
2213                                    window.SVGElementInstance && this._lastTarget instanceof SVGElementInstance && (this._lastTarget = this._lastTarget.correspondingUseElement),
2214                                    pi(this._lastTarget, "leaflet-drag-target")),
2215                                (this._newPos = this._startPos.add(e)),
2216                                (this._moving = !0),
2217                                C(this._animRequest),
2218                                (this._lastEvent = t),
2219                                (this._animRequest = M(this._updatePosition, this, !0))));
2220                    }
2221            },
2222            _updatePosition: function () {
2223                var t = { originalEvent: this._lastEvent };
2224                this.fire("predrag", t), wi(this._element, this._newPos), this.fire("drag", t);
2225            },
2226            _onUp: function (t) {
2227                !t._simulated && this._enabled && this.finishDrag();
2228            },
2229            finishDrag: function () {
2230                for (var t in (mi(document.body, "leaflet-dragging"), this._lastTarget && (mi(this._lastTarget, "leaflet-drag-target"), (this._lastTarget = null)), ue))
2231                    Bi(document, ue[t], this._onMove, this), Bi(document, he[t], this._onUp, this);
2232                Ti(), Qt(), this._moved && this._moving && (C(this._animRequest), this.fire("dragend", { distance: this._newPos.distanceTo(this._startPos) })), (this._moving = !1), (le._dragging = !1);
2233            },
2234        });
2235    function ce(t, i) {
2236        if (!i || !t.length) return t.slice();
2237        var e = i * i;
2238        return (t = (function (t, i) {
2239            var e = t.length,
2240                n = new (typeof Uint8Array != void 0 + "" ? Uint8Array : Array)(e);
2241            (n[0] = n[e - 1] = 1),
2242                (function t(i, e, n, o, s) {
2243                    var r,
2244                        a,
2245                        h,
2246                        u = 0;
2247                    for (a = o + 1; a <= s - 1; a++) (h = fe(i[a], i[o], i[s], !0)), u < h && ((r = a), (u = h));
2248                    n < u && ((e[r] = 1), t(i, e, n, o, r), t(i, e, n, r, s));
2249                })(t, n, i, 0, e - 1);
2250            var o,
2251                s = [];
2252            for (o = 0; o < e; o++) n[o] && s.push(t[o]);
2253            return s;
2254        })(
2255            (t = (function (t, i) {
2256                for (var e = [t[0]], n = 1, o = 0, s = t.length; n < s; n++) (r = t[n]), (a = t[o]), void 0, (h = a.x - r.x), (u = a.y - r.y), i < h * h + u * u && (e.push(t[n]), (o = n));
2257                var r, a, h, u;
2258                o < s - 1 && e.push(t[s - 1]);
2259                return e;
2260            })(t, e)),
2261            e
2262        ));
2263    }
2264    function _e(t, i, e) {
2265        return Math.sqrt(fe(t, i, e, !0));
2266    }
2267    function de(t, i, e, n, o) {
2268        var s,
2269            r,
2270            a,
2271            h = n ? se : me(t, e),
2272            u = me(i, e);
2273        for (se = u; ; ) {
2274            if (!(h | u)) return [t, i];
2275            if (h & u) return !1;
2276            (a = me((r = pe(t, i, (s = h || u), e, o)), e)), s === h ? ((t = r), (h = a)) : ((i = r), (u = a));
2277        }
2278    }
2279    function pe(t, i, e, n, o) {
2280        var s,
2281            r,
2282            a = i.x - t.x,
2283            h = i.y - t.y,
2284            u = n.min,
2285            l = n.max;
2286        return (
2287            8 & e ? ((s = t.x + (a * (l.y - t.y)) / h), (r = l.y)) : 4 & e ? ((s = t.x + (a * (u.y - t.y)) / h), (r = u.y)) : 2 & e ? ((s = l.x), (r = t.y + (h * (l.x - t.x)) / a)) : 1 & e && ((s = u.x), (r = t.y + (h * (u.x - t.x)) / a)),
2288            new B(s, r, o)
2289        );
2290    }
2291    function me(t, i) {
2292        var e = 0;
2293        return t.x < i.min.x ? (e |= 1) : t.x > i.max.x && (e |= 2), t.y < i.min.y ? (e |= 4) : t.y > i.max.y && (e |= 8), e;
2294    }
2295    function fe(t, i, e, n) {
2296        var o,
2297            s = i.x,
2298            r = i.y,
2299            a = e.x - s,
2300            h = e.y - r,
2301            u = a * a + h * h;
2302        return 0 < u && (1 < (o = ((t.x - s) * a + (t.y - r) * h) / u) ? ((s = e.x), (r = e.y)) : 0 < o && ((s += a * o), (r += h * o))), (a = t.x - s), (h = t.y - r), n ? a * a + h * h : new B(s, r);
2303    }
2304    function ge(t) {
2305        return !v(t[0]) || ("object" != typeof t[0][0] && void 0 !== t[0][0]);
2306    }
2307    function ve(t) {
2308        return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."), ge(t);
2309    }
2310    var ye = (Object.freeze || Object)({
2311        simplify: ce,
2312        pointToSegmentDistance: _e,
2313        closestPointOnSegment: function (t, i, e) {
2314            return fe(t, i, e);
2315        },
2316        clipSegment: de,
2317        _getEdgeIntersection: pe,
2318        _getBitCode: me,
2319        _sqClosestPointOnSegment: fe,
2320        isFlat: ge,
2321        _flat: ve,
2322    });
2323    function xe(t, i, e) {
2324        var n,
2325            o,
2326            s,
2327            r,
2328            a,
2329            h,
2330            u,
2331            l,
2332            c,
2333            _ = [1, 4, 2, 8];
2334        for (o = 0, u = t.length; o < u; o++) t[o]._code = me(t[o], i);
2335        for (r = 0; r < 4; r++) {
2336            for (l = _[r], n = [], o = 0, s = (u = t.length) - 1; o < u; s = o++)
2337                (a = t[o]), (h = t[s]), a._code & l ? h._code & l || (((c = pe(h, a, l, i, e))._code = me(c, i)), n.push(c)) : (h._code & l && (((c = pe(h, a, l, i, e))._code = me(c, i)), n.push(c)), n.push(a));
2338            t = n;
2339        }
2340        return t;
2341    }
2342    var we,
2343        Pe = (Object.freeze || Object)({ clipPolygon: xe }),
2344        be = {
2345            project: function (t) {
2346                return new B(t.lng, t.lat);
2347            },
2348            unproject: function (t) {
2349                return new j(t.y, t.x);
2350            },
2351            bounds: new O([-180, -90], [180, 90]),
2352        },
2353        Le = {
2354            R: 6378137,
2355            R_MINOR: 6356752.314245179,
2356            bounds: new O([-20037508.34279, -15496570.73972], [20037508.34279, 18764656.23138]),
2357            project: function (t) {
2358                var i = Math.PI / 180,
2359                    e = this.R,
2360                    n = t.lat * i,
2361                    o = this.R_MINOR / e,
2362                    s = Math.sqrt(1 - o * o),
2363                    r = s * Math.sin(n),
2364                    a = Math.tan(Math.PI / 4 - n / 2) / Math.pow((1 - r) / (1 + r), s / 2);
2365                return (n = -e * Math.log(Math.max(a, 1e-10))), new B(t.lng * i * e, n);
2366            },
2367            unproject: function (t) {
2368                for (var i, e = 180 / Math.PI, n = this.R, o = this.R_MINOR / n, s = Math.sqrt(1 - o * o), r = Math.exp(-t.y / n), a = Math.PI / 2 - 2 * Math.atan(r), h = 0, u = 0.1; h < 15 && 1e-7 < Math.abs(u); h++)
2369                    (i = s * Math.sin(a)), (i = Math.pow((1 - i) / (1 + i), s / 2)), (a += u = Math.PI / 2 - 2 * Math.atan(r * i) - a);
2370                return new j(a * e, (t.x * e) / n);
2371            },
2372        },
2373        Te = (Object.freeze || Object)({ LonLat: be, Mercator: Le, SphericalMercator: q }),
2374        ze = h({}, U, { code: "EPSG:3395", projection: Le, transformation: ((we = 0.5 / (Math.PI * Le.R)), K(we, 0.5, -we, 0.5)) }),
2375        Me = h({}, U, { code: "EPSG:4326", projection: be, transformation: K(1 / 180, 1, -1 / 180, 0.5) }),
2376        Ce = h({}, F, {
2377            projection: be,
2378            transformation: K(1, 0, -1, 0),
2379            scale: function (t) {
2380                return Math.pow(2, t);
2381            },
2382            zoom: function (t) {
2383                return Math.log(t) / Math.LN2;
2384            },
2385            distance: function (t, i) {
2386                var e = i.lng - t.lng,
2387                    n = i.lat - t.lat;
2388                return Math.sqrt(e * e + n * n);
2389            },
2390            infinite: !0,
2391        });
2392    (F.Earth = U), (F.EPSG3395 = ze), (F.EPSG3857 = X), (F.EPSG900913 = J), (F.EPSG4326 = Me), (F.Simple = Ce);
2393    var Se = k.extend({
2394        options: { pane: "overlayPane", attribution: null, bubblingMouseEvents: !0 },
2395        addTo: function (t) {
2396            return t.addLayer(this), this;
2397        },
2398        remove: function () {
2399            return this.removeFrom(this._map || this._mapToAdd);
2400        },
2401        removeFrom: function (t) {
2402            return t && t.removeLayer(this), this;
2403        },
2404        getPane: function (t) {
2405            return this._map.getPane(t ? this.options[t] || t : this.options.pane);
2406        },
2407        addInteractiveTarget: function (t) {
2408            return (this._map._targets[u(t)] = this);
2409        },
2410        removeInteractiveTarget: function (t) {
2411            return delete this._map._targets[u(t)], this;
2412        },
2413        getAttribution: function () {
2414            return this.options.attribution;
2415        },
2416        _layerAdd: function (t) {
2417            var i = t.target;
2418            if (i.hasLayer(this)) {
2419                if (((this._map = i), (this._zoomAnimated = i._zoomAnimated), this.getEvents)) {
2420                    var e = this.getEvents();
2421                    i.on(e, this),
2422                        this.once(
2423                            "remove",
2424                            function () {
2425                                i.off(e, this);
2426                            },
2427                            this
2428                        );
2429                }
2430                this.onAdd(i), this.getAttribution && i.attributionControl && i.attributionControl.addAttribution(this.getAttribution()), this.fire("add"), i.fire("layeradd", { layer: this });
2431            }
2432        },
2433    });
2434    Ji.include({
2435        addLayer: function (t) {
2436            if (!t._layerAdd) throw new Error("The provided object is not a Layer.");
2437            var i = u(t);
2438            return this._layers[i] || (((this._layers[i] = t)._mapToAdd = this), t.beforeAdd && t.beforeAdd(this), this.whenReady(t._layerAdd, t)), this;
2439        },
2440        removeLayer: function (t) {
2441            var i = u(t);
2442            return (
2443                this._layers[i] &&
2444                    (this._loaded && t.onRemove(this),
2445                    t.getAttribution && this.attributionControl && this.attributionControl.removeAttribution(t.getAttribution()),
2446                    delete this._layers[i],
2447                    this._loaded && (this.fire("layerremove", { layer: t }), t.fire("remove")),
2448                    (t._map = t._mapToAdd = null)),
2449                this
2450            );
2451        },
2452        hasLayer: function (t) {
2453            return !!t && u(t) in this._layers;
2454        },
2455        eachLayer: function (t, i) {
2456            for (var e in this._layers) t.call(i, this._layers[e]);
2457            return this;
2458        },
2459        _addLayers: function (t) {
2460            for (var i = 0, e = (t = t ? (v(t) ? t : [t]) : []).length; i < e; i++) this.addLayer(t[i]);
2461        },
2462        _addZoomLimit: function (t) {
2463            (!isNaN(t.options.maxZoom) && isNaN(t.options.minZoom)) || ((this._zoomBoundLayers[u(t)] = t), this._updateZoomLevels());
2464        },
2465        _removeZoomLimit: function (t) {
2466            var i = u(t);
2467            this._zoomBoundLayers[i] && (delete this._zoomBoundLayers[i], this._updateZoomLevels());
2468        },
2469        _updateZoomLevels: function () {
2470            var t = 1 / 0,
2471                i = -1 / 0,
2472                e = this._getZoomSpan();
2473            for (var n in this._zoomBoundLayers) {
2474                var o = this._zoomBoundLayers[n].options;
2475                (t = void 0 === o.minZoom ? t : Math.min(t, o.minZoom)), (i = void 0 === o.maxZoom ? i : Math.max(i, o.maxZoom));
2476            }
2477            (this._layersMaxZoom = i === -1 / 0 ? void 0 : i),
2478                (this._layersMinZoom = t === 1 / 0 ? void 0 : t),
2479                e !== this._getZoomSpan() && this.fire("zoomlevelschange"),
2480                void 0 === this.options.maxZoom && this._layersMaxZoom && this.getZoom() > this._layersMaxZoom && this.setZoom(this._layersMaxZoom),
2481                void 0 === this.options.minZoom && this._layersMinZoom && this.getZoom() < this._layersMinZoom && this.setZoom(this._layersMinZoom);
2482        },
2483    });
2484    var Ze = Se.extend({
2485            initialize: function (t, i) {
2486                var e, n;
2487                if ((p(this, i), (this._layers = {}), t)) for (e = 0, n = t.length; e < n; e++) this.addLayer(t[e]);
2488            },
2489            addLayer: function (t) {
2490                var i = this.getLayerId(t);
2491                return (this._layers[i] = t), this._map && this._map.addLayer(t), this;
2492            },
2493            removeLayer: function (t) {
2494                var i = t in this._layers ? t : this.getLayerId(t);
2495                return this._map && this._layers[i] && this._map.removeLayer(this._layers[i]), delete this._layers[i], this;
2496            },
2497            hasLayer: function (t) {
2498                return !!t && (t in this._layers || this.getLayerId(t) in this._layers);
2499            },
2500            clearLayers: function () {
2501                return this.eachLayer(this.removeLayer, this);
2502            },
2503            invoke: function (t) {
2504                var i,
2505                    e,
2506                    n = Array.prototype.slice.call(arguments, 1);
2507                for (i in this._layers) (e = this._layers[i])[t] && e[t].apply(e, n);
2508                return this;
2509            },
2510            onAdd: function (t) {
2511                this.eachLayer(t.addLayer, t);
2512            },
2513            onRemove: function (t) {
2514                this.eachLayer(t.removeLayer, t);
2515            },
2516            eachLayer: function (t, i) {
2517                for (var e in this._layers) t.call(i, this._layers[e]);
2518                return this;
2519            },
2520            getLayer: function (t) {
2521                return this._layers[t];
2522            },
2523            getLayers: function () {
2524                var t = [];
2525                return this.eachLayer(t.push, t), t;
2526            },
2527            setZIndex: function (t) {
2528                return this.invoke("setZIndex", t);
2529            },
2530            getLayerId: function (t) {
2531                return u(t);
2532            },
2533        }),
2534        Ee = Ze.extend({
2535            addLayer: function (t) {
2536                return this.hasLayer(t) ? this : (t.addEventParent(this), Ze.prototype.addLayer.call(this, t), this.fire("layeradd", { layer: t }));
2537            },
2538            removeLayer: function (t) {
2539                return this.hasLayer(t) ? (t in this._layers && (t = this._layers[t]), t.removeEventParent(this), Ze.prototype.removeLayer.call(this, t), this.fire("layerremove", { layer: t })) : this;
2540            },
2541            setStyle: function (t) {
2542                return this.invoke("setStyle", t);
2543            },
2544            bringToFront: function () {
2545                return this.invoke("bringToFront");
2546            },
2547            bringToBack: function () {
2548                return this.invoke("bringToBack");
2549            },
2550            getBounds: function () {
2551                var t = new N();
2552                for (var i in this._layers) {
2553                    var e = this._layers[i];
2554                    t.extend(e.getBounds ? e.getBounds() : e.getLatLng());
2555                }
2556                return t;
2557            },
2558        }),
2559        ke = Z.extend({
2560            options: { popupAnchor: [0, 0], tooltipAnchor: [0, 0] },
2561            initialize: function (t) {
2562                p(this, t);
2563            },
2564            createIcon: function (t) {
2565                return this._createIcon("icon", t);
2566            },
2567            createShadow: function (t) {
2568                return this._createIcon("shadow", t);
2569            },
2570            _createIcon: function (t, i) {
2571                var e = this._getIconUrl(t);
2572                if (!e) {
2573                    if ("icon" === t) throw new Error("iconUrl not set in Icon options (see the docs).");
2574                    return null;
2575                }
2576                var n = this._createImg(e, i && "IMG" === i.tagName ? i : null);
2577                return this._setIconStyles(n, t), n;
2578            },
2579            _setIconStyles: function (t, i) {
2580                var e = this.options,
2581                    n = e[i + "Size"];
2582                "number" == typeof n && (n = [n, n]);
2583                var o = I(n),
2584                    s = I(("shadow" === i && e.shadowAnchor) || e.iconA
2584nchor || (o && o.divideBy(2, !0)));
2585                (t.className = "leaflet-marker-" + i + " " + (e.className || "")), s && ((t.style.marginLeft = -s.x + "px"), (t.style.marginTop = -s.y + "px")), o && ((t.style.width = o.x + "px"), (t.style.height = o.y + "px"));
2586            },
2587            _createImg: function (t, i) {
2588                return ((i = i || document.createElement("img")).src = t), i;
2589            },
2590            _getIconUrl: function (t) {
2591                return (Ct && this.options[t + "RetinaUrl"]) || this.options[t + "Url"];
2592            },
2593        });
2594    var Be = ke.extend({
2595            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] },
2596            _getIconUrl: function (t) {
2597                return Be.imagePath || (Be.imagePath = this._detectIconPath()), (this.options.imagePath || Be.imagePath) + ke.prototype._getIconUrl.call(this, t);
2598            },
2599            _detectIconPath: function () {
2600                var t = hi("div", "leaflet-default-icon-path", document.body),
2601                    i = ai(t, "background-image") || ai(t, "backgroundImage");
2602                return document.body.removeChild(t), (i = null === i || 0 !== i.indexOf("url") ? "" : i.replace(/^url\(["']?/, "").replace(/marker-icon\.png["']?\)$/, ""));
2603            },
2604        }),
2605        Ae = oe.extend({
2606            initialize: function (t) {
2607                this._marker = t;
2608            },
2609            addHooks: function () {
2610                var t = this._marker._icon;
2611                this._draggable || (this._draggable = new le(t, t, !0)),
2612                    this._draggable.on({ dragstart: this._onDragStart, predrag: this._onPreDrag, drag: this._onDrag, dragend: this._onDragEnd }, this).enable(),
2613                    pi(t, "leaflet-marker-draggable");
2614            },
2615            removeHooks: function () {
2616                this._draggable.off({ dragstart: this._onDragStart, predrag: this._onPreDrag, drag: this._onDrag, dragend: this._onDragEnd }, this).disable(), this._marker._icon && mi(this._marker._icon, "leaflet-marker-draggable");
2617            },
2618            moved: function () {
2619                return this._draggable && this._draggable._moved;
2620            },
2621            _adjustPan: function (t) {
2622                var i = this._marker,
2623                    e = i._map,
2624                    n = this._marker.options.autoPanSpeed,
2625                    o = this._marker.options.autoPanPadding,
2626                    s = Pi(i._icon),
2627                    r = e.getPixelBounds(),
2628                    a = e.getPixelOrigin(),
2629                    h = R(r.min._subtract(a).add(o), r.max._subtract(a).subtract(o));
2630                if (!h.contains(s)) {
2631                    var u = I(
2632                        (Math.max(h.max.x, s.x) - h.max.x) / (r.max.x - h.max.x) - (Math.min(h.min.x, s.x) - h.min.x) / (r.min.x - h.min.x),
2633                        (Math.max(h.max.y, s.y) - h.max.y) / (r.max.y - h.max.y) - (Math.min(h.min.y, s.y) - h.min.y) / (r.min.y - h.min.y)
2634                    ).multiplyBy(n);
2635                    e.panBy(u, { animate: !1 }), this._draggable._newPos._add(u), this._draggable._startPos._add(u), wi(i._icon, this._draggable._newPos), this._onDrag(t), (this._panRequest = M(this._adjustPan.bind(this, t)));
2636                }
2637            },
2638            _onDragStart: function () {
2639                (this._oldLatLng = this._marker.getLatLng()), this._marker.closePopup().fire("movestart").fire("dragstart");
2640            },
2641            _onPreDrag: function (t) {
2642                this._marker.options.autoPan && (C(this._panRequest), (this._panRequest = M(this._adjustPan.bind(this, t))));
2643            },
2644            _onDrag: function (t) {
2645                var i = this._marker,
2646                    e = i._shadow,
2647                    n = Pi(i._icon),
2648                    o = i._map.layerPointToLatLng(n);
2649                e && wi(e, n), (i._latlng = o), (t.latlng = o), (t.oldLatLng = this._oldLatLng), i.fire("move", t).fire("drag", t);
2650            },
2651            _onDragEnd: function (t) {
2652                C(this._panRequest), delete this._oldLatLng, this._marker.fire("moveend").fire("dragend", t);
2653            },
2654        }),
2655        Ie = Se.extend({
2656            options: {
2657                icon: new Be(),
2658                interactive: !0,
2659                keyboard: !0,
2660                title: "",
2661                alt: "",
2662                zIndexOffset: 0,
2663                opacity: 1,
2664                riseOnHover: !1,
2665                riseOffset: 250,
2666                pane: "markerPane",
2667                shadowPane: "shadowPane",
2668                bubblingMouseEvents: !1,
2669                draggable: !1,
2670                autoPan: !1,
2671                autoPanPadding: [50, 50],
2672                autoPanSpeed: 10,
2673            },
2674            initialize: function (t, i) {
2675                p(this, i), (this._latlng = W(t));
2676            },
2677            onAdd: function (t) {
2678                (this._zoomAnimated = this._zoomAnimated && t.options.markerZoomAnimation), this._zoomAnimated && t.on("zoomanim", this._animateZoom, this), this._initIcon(), this.update();
2679            },
2680            onRemove: function (t) {
2681                this.dragging && this.dragging.enabled() && ((this.options.draggable = !0), this.dragging.removeHooks()),
2682                    delete this.dragging,
2683                    this._zoomAnimated && t.off("zoomanim", this._animateZoom, this),
2684                    this._removeIcon(),
2685                    this._removeShadow();
2686            },
2687            getEvents: function () {
2688                return { zoom: this.update, viewreset: this.update };
2689            },
2690            getLatLng: function () {
2691                return this._latlng;
2692            },
2693            setLatLng: function (t) {
2694                var i = this._latlng;
2695                return (this._latlng = W(t)), this.update(), this.fire("move", { oldLatLng: i, latlng: this._latlng });
2696            },
2697            setZIndexOffset: function (t) {
2698                return (this.options.zIndexOffset = t), this.update();
2699            },
2700            getIcon: function () {
2701                return this.options.icon;
2702            },
2703            setIcon: function (t) {
2704                return (this.options.icon = t), this._map && (this._initIcon(), this.update()), this._popup && this.bindPopup(this._popup, this._popup.options), this;
2705            },
2706            getElement: function () {
2707                return this._icon;
2708            },
2709            update: function () {
2710                if (this._icon && this._map) {
2711                    var t = this._map.latLngToLayerPoint(this._latlng).round();
2712                    this._setPos(t);
2713                }
2714                return this;
2715            },
2716            _initIcon: function () {
2717                var t = this.options,
2718                    i = "leaflet-zoom-" + (this._zoomAnimated ? "animated" : "hide"),
2719                    e = t.icon.createIcon(this._icon),
2720                    n = !1;
2721                e !== this._icon && (this._icon && this._removeIcon(), (n = !0), t.title && (e.title = t.title), "IMG" === e.tagName && (e.alt = t.alt || "")),
2722                    pi(e, i),
2723                    t.keyboard && (e.tabIndex = "0"),
2724                    (this._icon = e),
2725                    t.riseOnHover && this.on({ mouseover: this._bringToFront, mouseout: this._resetZIndex });
2726                var o = t.icon.createShadow(this._shadow),
2727                    s = !1;
2728                o !== this._shadow && (this._removeShadow(), (s = !0)),
2729                    o && (pi(o, i), (o.alt = "")),
2730                    (this._shadow = o),
2731                    t.opacity < 1 && this._updateOpacity(),
2732                    n && this.getPane().appendChild(this._icon),
2733                    this._initInteraction(),
2734                    o && s && this.getPane(t.shadowPane).appendChild(this._shadow);
2735            },
2736            _removeIcon: function () {
2737                this.options.riseOnHover && this.off({ mouseover: this._bringToFront, mouseout: this._resetZIndex }), ui(this._icon), this.removeInteractiveTarget(this._icon), (this._icon = null);
2738            },
2739            _removeShadow: function () {
2740                this._shadow && ui(this._shadow), (this._shadow = null);
2741            },
2742            _setPos: function (t) {
2743                wi(this._icon, t), this._shadow && wi(this._shadow, t), (this._zIndex = t.y + this.options.zIndexOffset), this._resetZIndex();
2744            },
2745            _updateZIndex: function (t) {
2746                this._icon.style.zIndex = this._zIndex + t;
2747            },
2748            _animateZoom: function (t) {
2749                var i = this._map._latLngToNewLayerPoint(this._latlng, t.zoom, t.center).round();
2750                this._setPos(i);
2751            },
2752            _initInteraction: function () {
2753                if (this.options.interactive && (pi(this._icon, "leaflet-interactive"), this.addInteractiveTarget(this._icon), Ae)) {
2754                    var t = this.options.draggable;
2755                    this.dragging && ((t = this.dragging.enabled()), this.dragging.disable()), (this.dragging = new Ae(this)), t && this.dragging.enable();
2756                }
2757            },
2758            setOpacity: function (t) {
2759                return (this.options.opacity = t), this._map && this._updateOpacity(), this;
2760            },
2761            _updateOpacity: function () {
2762                var t = this.options.opacity;
2763                this._icon && vi(this._icon, t), this._shadow && vi(this._shadow, t);
2764            },
2765            _bringToFront: function () {
2766                this._updateZIndex(this.options.riseOffset);
2767            },
2768            _resetZIndex: function () {
2769                this._updateZIndex(0);
2770            },
2771            _getPopupAnchor: function () {
2772                return this.options.icon.options.popupAnchor;
2773            },
2774            _getTooltipAnchor: function () {
2775                return this.options.icon.options.tooltipAnchor;
2776            },
2777        });
2778    var Oe = Se.extend({
2779            options: {
2780                stroke: !0,
2781                color: "#3388ff",
2782                weight: 3,
2783                opacity: 1,
2784                lineCap: "round",
2785                lineJoin: "round",
2786                dashArray: null,
2787                dashOffset: null,
2788                fill: !1,
2789                fillColor: null,
2790                fillOpacity: 0.2,
2791                fillRule: "evenodd",
2792                interactive: !0,
2793                bubblingMouseEvents: !0,
2794            },
2795            beforeAdd: function (t) {
2796                this._renderer = t.getRenderer(this);
2797            },
2798            onAdd: function () {
2799                this._renderer._initPath(this), this._reset(), this._renderer._addPath(this);
2800            },
2801            onRemove: function () {
2802                this._renderer._removePath(this);
2803            },
2804            redraw: function () {
2805                return this._map && this._renderer._updatePath(this), this;
2806            },
2807            setStyle: function (t) {
2808                return p(this, t), this._renderer && (this._renderer._updateStyle(this), this.options.stroke && t.hasOwnProperty("weight") && this._updateBounds()), this;
2809            },
2810            bringToFront: function () {
2811                return this._renderer && this._renderer._bringToFront(this), this;
2812            },
2813            bringToBack: function () {
2814                return this._renderer && this._renderer._bringToBack(this), this;
2815            },
2816            getElement: function () {
2817                return this._path;
2818            },
2819            _reset: function () {
2820                this._project(), this._update();
2821            },
2822            _clickTolerance: function () {
2823                return (this.options.stroke ? this.options.weight / 2 : 0) + this._renderer.options.tolerance;
2824            },
2825        }),
2826        Re = Oe.extend({
2827            options: { fill: !0, radius: 10 },
2828            initialize: function (t, i) {
2829                p(this, i), (this._latlng = W(t)), (this._radius = this.options.radius);
2830            },
2831            setLatLng: function (t) {
2832                return (this._latlng = W(t)), this.redraw(), this.fire("move", { latlng: this._latlng });
2833            },
2834            getLatLng: function () {
2835                return this._latlng;
2836            },
2837            setRadius: function (t) {
2838                return (this.options.radius = this._radius = t), this.redraw();
2839            },
2840            getRadius: function () {
2841                return this._radius;
2842            },
2843            setStyle: function (t) {
2844                var i = (t && t.radius) || this._radius;
2845                return Oe.prototype.setStyle.call(this, t), this.setRadius(i), this;
2846            },
2847            _project: function () {
2848                (this._point = this._map.latLngToLayerPoint(this._latlng)), this._updateBounds();
2849            },
2850            _updateBounds: function () {
2851                var t = this._radius,
2852                    i = this._radiusY || t,
2853                    e = this._clickTolerance(),
2854                    n = [t + e, i + e];
2855                this._pxBounds = new O(this._point.subtract(n), this._point.add(n));
2856            },
2857            _update: function () {
2858                this._map && this._updatePath();
2859            },
2860            _updatePath: function () {
2861                this._renderer._updateCircle(this);
2862            },
2863            _empty: function () {
2864                return this._radius && !this._renderer._bounds.intersects(this._pxBounds);
2865            },
2866            _containsPoint: function (t) {
2867                return t.distanceTo(this._point) <= this._radius + this._clickTolerance();
2868            },
2869        });
2870    var Ne = Re.extend({
2871        initialize: function (t, i, e) {
2872            if (("number" == typeof i && (i = h({}, e, { radius: i })), p(this, i), (this._latlng = W(t)), isNaN(this.options.radius))) throw new Error("Circle radius cannot be NaN");
2873            this._mRadius = this.options.radius;
2874        },
2875        setRadius: function (t) {
2876            return (this._mRadius = t), this.redraw();
2877        },
2878        getRadius: function () {
2879            return this._mRadius;
2880        },
2881        getBounds: function () {
2882            var t = [this._radius, this._radiusY || this._radius];
2883            return new N(this._map.layerPointToLatLng(this._point.subtract(t)), this._map.layerPointToLatLng(this._point.add(t)));
2884        },
2885        setStyle: Oe.prototype.setStyle,
2886        _project: function () {
2887            var t = this._latlng.lng,
2888                i = this._latlng.lat,
2889                e = this._map,
2890                n = e.options.crs;
2891            if (n.distance === U.distance) {
2892                var o = Math.PI / 180,
2893                    s = this._mRadius / U.R / o,
2894                    r = e.project([i + s, t]),
2895                    a = e.project([i - s, t]),
2896                    h = r.add(a).divideBy(2),
2897                    u = e.unproject(h).lat,
2898                    l = Math.acos((Math.cos(s * o) - Math.sin(i * o) * Math.sin(u * o)) / (Math.cos(i * o) * Math.cos(u * o))) / o;
2899                (!isNaN(l) && 0 !== l) || (l = s / Math.cos((Math.PI / 180) * i)), (this._point = h.subtract(e.getPixelOrigin())), (this._radius = isNaN(l) ? 0 : h.x - e.project([u, t - l]).x), (this._radiusY = h.y - r.y);
2900            } else {
2901                var c = n.unproject(n.project(this._latlng).subtract([this._mRadius, 0]));
2902                (this._point = e.latLngToLayerPoint(this._latlng)), (this._radius = this._point.x - e.latLngToLayerPoint(c).x);
2903            }
2904            this._updateBounds();
2905        },
2906    });
2907    var De = Oe.extend({
2908        options: { smoothFactor: 1, noClip: !1 },
2909        initialize: function (t, i) {
2910            p(this, i), this._setLatLngs(t);
2911        },
2912        getLatLngs: function () {
2913            return this._latlngs;
2914        },
2915        setLatLngs: function (t) {
2916            return this._setLatLngs(t), this.redraw();
2917        },
2918        isEmpty: function () {
2919            return !this._latlngs.length;
2920        },
2921        closestLayerPoint: function (t) {
2922            for (var i, e, n = 1 / 0, o = null, s = fe, r = 0, a = this._parts.length; r < a; r++)
2923                for (var h = this._parts[r], u = 1, l = h.length; u < l; u++) {
2924                    var c = s(t, (i = h[u - 1]), (e = h[u]), !0);
2925                    c < n && ((n = c), (o = s(t, i, e)));
2926                }
2927            return o && (o.distance = Math.sqrt(n)), o;
2928        },
2929        getCenter: function () {
2930            if (!this._map) throw new Error("Must add layer to map before using getCenter()");
2931            var t,
2932                i,
2933                e,
2934                n,
2935                o,
2936                s,
2937                r,
2938                a = this._rings[0],
2939                h = a.length;
2940            if (!h) return null;
2941            for (i = t = 0; t < h - 1; t++) i += a[t].distanceTo(a[t + 1]) / 2;
2942            if (0 === i) return this._map.layerPointToLatLng(a[0]);
2943            for (n = t = 0; t < h - 1; t++) if (((o = a[t]), (s = a[t + 1]), i < (n += e = o.distanceTo(s)))) return (r = (n - i) / e), this._map.layerPointToLatLng([s.x - r * (s.x - o.x), s.y - r * (s.y - o.y)]);
2944        },
2945        getBounds: function () {
2946            return this._bounds;
2947        },
2948        addLatLng: function (t, i) {
2949            return (i = i || this._defaultShape()), (t = W(t)), i.push(t), this._bounds.extend(t), this.redraw();
2950        },
2951        _setLatLngs: function (t) {
2952            (this._bounds = new N()), (this._latlngs = this._convertLatLngs(t));
2953        },
2954        _defaultShape: function () {
2955            return ge(this._latlngs) ? this._latlngs : this._latlngs[0];
2956        },
2957        _convertLatLngs: function (t) {
2958            for (var i = [], e = ge(t), n = 0, o = t.length; n < o; n++) e ? ((i[n] = W(t[n])), this._bounds.extend(i[n])) : (i[n] = this._convertLatLngs(t[n]));
2959            return i;
2960        },
2961        _project: function () {
2962            var t = new O();
2963            (this._rings = []), this._projectLatlngs(this._latlngs, this._rings, t), this._bounds.isValid() && t.isValid() && ((this._rawPxBounds = t), this._updateBounds());
2964        },
2965        _updateBounds: function () {
2966            var t = this._clickTolerance(),
2967                i = new B(t, t);
2968            this._pxBounds = new O([this._rawPxBounds.min.subtract(i), this._rawPxBounds.max.add(i)]);
2969        },
2970        _projectLatlngs: function (t, i, e) {
2971            var n,
2972                o,
2973                s = t[0] instanceof j,
2974                r = t.length;
2975            if (s) {
2976                for (o = [], n = 0; n < r; n++) (o[n] = this._map.latLngToLayerPoint(t[n])), e.extend(o[n]);
2977                i.push(o);
2978            } else for (n = 0; n < r; n++) this._projectLatlngs(t[n], i, e);
2979        },
2980        _clipPoints: function () {
2981            var t = this._renderer._bounds;
2982            if (((this._parts = []), this._pxBounds && this._pxBounds.intersects(t)))
2983                if (this.options.noClip) this._parts = this._rings;
2984                else {
2985                    var i,
2986                        e,
2987                        n,
2988                        o,
2989                        s,
2990                        r,
2991                        a,
2992                        h = this._parts;
2993                    for (n = i = 0, o = this._rings.length; i < o; i++)
2994                        for (e = 0, s = (a = this._rings[i]).length; e < s - 1; e++) (r = de(a[e], a[e + 1], t, e, !0)) && ((h[n] = h[n] || []), h[n].push(r[0]), (r[1] === a[e + 1] && e !== s - 2) || (h[n].push(r[1]), n++));
2995                }
2996        },
2997        _simplifyPoints: function () {
2998            for (var t = this._parts, i = this.options.smoothFactor, e = 0, n = t.length; e < n; e++) t[e] = ce(t[e], i);
2999        },
3000        _update: function () {
3001            this._map && (this._clipPoints(), this._simplifyPoints(), this._updatePath());
3002        },
3003        _updatePath: function () {
3004            this._renderer._updatePoly(this);
3005        },
3006        _containsPoint: function (t, i) {
3007            var e,
3008                n,
3009                o,
3010                s,
3011                r,
3012                a,
3013                h = this._clickTolerance();
3014            if (!this._pxBounds || !this._pxBounds.contains(t)) return !1;
3015            for (e = 0, s = this._parts.length; e < s; e++) for (n = 0, o = (r = (a = this._parts[e]).length) - 1; n < r; o = n++) if ((i || 0 !== n) && _e(t, a[o], a[n]) <= h) return !0;
3016            return !1;
3017        },
3018    });
3019    De._flat = ve;
3020    var je = De.extend({
3021        options: { fill: !0 },
3022        isEmpty: function () {
3023            return !this._latlngs.length || !this._latlngs[0].length;
3024        },
3025        getCenter: function () {
3026            if (!this._map) throw new Error("Must add layer to map before using getCenter()");
3027            var t,
3028                i,
3029                e,
3030                n,
3031                o,
3032                s,
3033                r,
3034                a,
3035                h,
3036                u = this._rings[0],
3037                l = u.length;
3038            if (!l) return null;
3039            for (s = r = a = 0, t = 0, i = l - 1; t < l; i = t++) (e = u[t]), (n = u[i]), (o = e.y * n.x - n.y * e.x), (r += (e.x + n.x) * o), (a += (e.y + n.y) * o), (s += 3 * o);
3040            return (h = 0 === s ? u[0] : [r / s, a / s]), this._map.layerPointToLatLng(h);
3041        },
3042        _convertLatLngs: function (t) {
3043            var i = De.prototype._convertLatLngs.call(this, t),
3044                e = i.length;
3045            return 2 <= e && i[0] instanceof j && i[0].equals(i[e - 1]) && i.pop(), i;
3046        },
3047        _setLatLngs: function (t) {
3048            De.prototype._setLatLngs.call(this, t), ge(this._latlngs) && (this._latlngs = [this._latlngs]);
3049        },
3050        _defaultShape: function () {
3051            return ge(this._latlngs[0]) ? this._latlngs[0] : this._latlngs[0][0];
3052        },
3053        _clipPoints: function () {
3054            var t = this._renderer._bounds,
3055                i = this.options.weight,
3056                e = new B(i, i);
3057            if (((t = new O(t.min.subtract(e), t.max.add(e))), (this._parts = []), this._pxBounds && this._pxBounds.intersects(t)))
3058                if (this.options.noClip) this._parts = this._rings;
3059                else for (var n, o = 0, s = this._rings.length; o < s; o++) (n = xe(this._rings[o], t, !0)).length && this._parts.push(n);
3060        },
3061        _updatePath: function () {
3062            this._renderer._updatePoly(this, !0);
3063        },
3064        _containsPoint: function (t) {
3065            var i,
3066                e,
3067                n,
3068                o,
3069                s,
3070                r,
3071                a,
3072                h,
3073                u = !1;
3074            if (!this._pxBounds || !this._pxBounds.contains(t)) return !1;
3075            for (o = 0, a = this._parts.length; o < a; o++)
3076                for (s = 0, r = (h = (i = this._parts[o]).length) - 1; s < h; r = s++) (e = i[s]), (n = i[r]), e.y > t.y != n.y > t.y && t.x < ((n.x - e.x) * (t.y - e.y)) / (n.y - e.y) + e.x && (u = !u);
3077            return u || De.prototype._containsPoint.call(this, t, !0);
3078        },
3079    });
3080    var We = Ee.extend({
3081        initialize: function (t, i) {
3082            p(this, i), (this._layers = {}), t && this.addData(t);
3083        },
3084        addData: function (t) {
3085            var i,
3086                e,
3087                n,
3088                o = v(t) ? t : t.features;
3089            if (o) {
3090                for (i = 0, e = o.length; i < e; i++) ((n = o[i]).geometries || n.geometry || n.features || n.coordinates) && this.addData(n);
3091                return this;
3092            }
3093            var s = this.options;
3094            if (s.filter && !s.filter(t)) return this;
3095            var r = He(t, s);
3096            return r ? ((r.feature = Ke(t)), (r.defaultOptions = r.options), this.resetStyle(r), s.onEachFeature && s.onEachFeature(t, r), this.addLayer(r)) : this;
3097        },
3098        resetStyle: function (t) {
3099            return (t.options = h({}, t.defaultOptions)), this._setLayerStyle(t, this.options.style), this;
3100        },
3101        setStyle: function (i) {
3102            return this.eachLayer(function (t) {
3103                this._setLayerStyle(t, i);
3104            }, this);
3105        },
3106        _setLayerStyle: function (t, i) {
3107            t.setStyle && ("function" == typeof i && (i = i(t.feature)), t.setStyle(i));
3108        },
3109    });
3110    function He(t, i) {
3111        var e,
3112            n,
3113            o,
3114            s,
3115            r = "Feature" === t.type ? t.geometry : t,
3116            a = r ? r.coordinates : null,
3117            h = [],
3118            u = i && i.pointToLayer,
3119            l = (i && i.coordsToLatLng) || Fe;
3120        if (!a && !r) return null;
3121        switch (r.type) {
3122            case "Point":
3123                return (e = l(a)), u ? u(t, e) : new Ie(e);
3124            case "MultiPoint":
3125                for (o = 0, s = a.length; o < s; o++) (e = l(a[o])), h.push(u ? u(t, e) : new Ie(e));
3126                return new Ee(h);
3127            case "LineString":
3128            case "MultiLineString":
3129                return (n = Ue(a, "LineString" === r.type ? 0 : 1, l)), new De(n, i);
3130            case "Polygon":
3131            case "MultiPolygon":
3132                return (n = Ue(a, "Polygon" === r.type ? 1 : 2, l)), new je(n, i);
3133            case "GeometryCollection":
3134                for (o = 0, s = r.geometries.length; o < s; o++) {
3135                    var c = He({ geometry: r.geometries[o], type: "Feature", properties: t.properties }, i);
3136                    c && h.push(c);
3137                }
3138                return new Ee(h);
3139            default:
3140                throw new Error("Invalid GeoJSON object.");
3141        }
3142    }
3143    function Fe(t) {
3144        return new j(t[1], t[0], t[2]);
3145    }
3146    function Ue(t, i, e) {
3147        for (var n, o = [], s = 0, r = t.length; s < r; s++) (n = i ? Ue(t[s], i - 1, e) : (e || Fe)(t[s])), o.push(n);
3148        return o;
3149    }
3150    function Ve(t, i) {
3151        return (i = "number" == typeof i ? i : 6), void 0 !== t.alt ? [c(t.lng, i), c(t.lat, i), c(t.alt, i)] : [c(t.lng, i), c(t.lat, i)];
3152    }
3153    function qe(t, i, e, n) {
3154        for (var o = [], s = 0, r = t.length; s < r; s++) o.push(i ? qe(t[s], i - 1, e, n) : Ve(t[s], n));
3155        return !i && e && o.push(o[0]), o;
3156    }
3157    function Ge(t, i) {
3158        return t.feature ? h({}, t.feature, { geometry: i }) : Ke(i);
3159    }
3160    function Ke(t) {
3161        return "Feature" === t.type || "FeatureCollection" === t.type ? t : { type: "Feature", properties: {}, geometry: t };
3162    }
3163    var Ye = {
3164        toGeoJSON: function (t) {
3165            return Ge(this, { type: "Point", coordinates: Ve(this.getLatLng(), t) });
3166        },
3167    };
3168    function Xe(t, i) {
3169        return new We(t, i);
3170    }
3171    Ie.include(Ye),
3172        Ne.include(Ye),
3173        Re.include(Ye),
3174        De.include({
3175            toGeoJSON: function (t) {
3176                var i = !ge(this._latlngs);
3177                return Ge(this, { type: (i ? "Multi" : "") + "LineString", coordinates: qe(this._latlngs, i ? 1 : 0, !1, t) });
3178            },
3179        }),
3180        je.include({
3181            toGeoJSON: function (t) {
3182                var i = !ge(this._latlngs),
3183                    e = i && !ge(this._latlngs[0]),
3184                    n = qe(this._latlngs, e ? 2 : i ? 1 : 0, !0, t);
3185                return i || (n = [n]), Ge(this, { type: (e ? "Multi" : "") + "Polygon", coordinates: n });
3186            },
3187        }),
3188        Ze.include({
3189            toMultiPoint: function (i) {
3190                var e = [];
3191                return (
3192                    this.eachLayer(function (t) {
3193                        e.push(t.toGeoJSON(i).geometry.coordinates);
3194                    }),
3195                    Ge(this, { type: "MultiPoint", coordinates: e })
3196                );
3197            },
3198            toGeoJSON: function (n) {
3199                var t = this.feature && this.feature.geometry && this.feature.geometry.type;
3200                if ("MultiPoint" === t) return this.toMultiPoint(n);
3201                var o = "GeometryCollection" === t,
3202                    s = [];
3203                return (
3204                    this.eachLayer(function (t) {
3205                        if (t.toGeoJSON) {
3206                            var i = t.toGeoJSON(n);
3207                            if (o) s.push(i.geometry);
3208                            else {
3209                                var e = Ke(i);
3210                                "FeatureCollection" === e.type ? s.push.apply(s, e.features) : s.push(e);
3211                            }
3212                        }
3213                    }),
3214                    o ? Ge(this, { geometries: s, type: "GeometryCollection" }) : { type: "FeatureCollection", features: s }
3215                );
3216            },
3217        });
3218    var Je = Xe,
3219        $e = Se.extend({
3220            options: { opacity: 1, alt: "", interactive: !1, crossOrigin: !1, errorOverlayUrl: "", zIndex: 1, className: "" },
3221            initialize: function (t, i, e) {
3222                (this._url = t), (this._bounds = D(i)), p(this, e);
3223            },
3224            onAdd: function () {
3225                this._image || (this._initImage(), this.options.opacity < 1 && this._updateOpacity()),
3226                    this.options.interactive && (pi(this._image, "leaflet-interactive"), this.addInteractiveTarget(this._image)),
3227                    this.getPane().appendChild(this._image),
3228                    this._reset();
3229            },
3230            onRemove: function () {
3231                ui(this._image), this.options.interactive && this.removeInteractiveTarget(this._image);
3232            },
3233            setOpacity: function (t) {
3234                return (this.options.opacity = t), this._image && this._updateOpacity(), this;
3235            },
3236            setStyle: function (t) {
3237                return t.opacity && this.setOpacity(t.opacity), this;
3238            },
3239            bringToFront: function () {
3240                return this._map && ci(this._image), this;
3241            },
3242            bringToBack: function () {
3243                return this._map && _i(this._image), this;
3244            },
3245            setUrl: function (t) {
3246                return (this._url = t), this._image && (this._image.src = t), this;
3247            },
3248            setBounds: function (t) {
3249                return (this._bounds = D(t)), this._map && this._reset(), this;
3250            },
3251            getEvents: function () {
3252                var t = { zoom: this._reset, viewreset: this._reset };
3253                return this._zoomAnimated && (t.zoomanim = this._animateZoom), t;
3254            },
3255            setZIndex: function (t) {
3256                return (this.options.zIndex = t), this._updateZIndex(), this;
3257            },
3258            getBounds: function () {
3259                return this._bounds;
3260            },
3261            getElement: function () {
3262                return this._image;
3263            },
3264            _initImage: function () {
3265                var t = "IMG" === this._url.tagName,
3266                    i = (this._image = t ? this._url : hi("img"));
3267                pi(i, "leaflet-image-layer"),
3268                    this._zoomAnimated && pi(i, "leaflet-zoom-animated"),
3269                    this.options.className && pi(i, this.options.className),
3270                    (i.onselectstart = l),
3271                    (i.onmousemove = l),
3272                    (i.onload = a(this.fire, this, "load")),
3273                    (i.onerror = a(this._overlayOnError, this, "error")),
3274                    (!this.options.crossOrigin && "" !== this.options.crossOrigin) || (i.crossOrigin = !0 === this.options.crossOrigin ? "" : this.options.crossOrigin),
3275                    this.options.zIndex && this._updateZIndex(),
3276                    t ? (this._url = i.src) : ((i.src = this._url), (i.alt = this.options.alt));
3277            },
3278            _animateZoom: function (t) {
3279                var i = this._map.getZoomScale(t.zoom),
3280                    e = this._map._latLngBoundsToNewLayerBounds(this._bounds, t.zoom, t.center).min;
3281                xi(this._image, e, i);
3282            },
3283            _reset: function () {
3284                var t = this._image,
3285                    i = new O(this._map.latLngToLayerPoint(this._bounds.getNorthWest()), this._map.latLngToLayerPoint(this._bounds.getSouthEast())),
3286                    e = i.getSize();
3287                wi(t, i.min), (t.style.width = e.x + "px"), (t.style.height = e.y + "px");
3288            },
3289            _updateOpacity: function () {
3290                vi(this._image, this.options.opacity);
3291            },
3292            _updateZIndex: function () {
3293                this._image && void 0 !== this.options.zIndex && null !== this.options.zIndex && (this._image.style.zIndex = this.options.zIndex);
3294            },
3295            _overlayOnError: function () {
3296                this.fire("error");
3297                var t = this.options.errorOverlayUrl;
3298                t && this._url !== t && ((this._url = t), (this._image.src = t));
3299            },
3300        }),
3301        Qe = $e.extend({
3302            options: { autoplay: !0, loop: !0, keepAspectRatio: !0 },
3303            _initImage: function () {
3304                var t = "VIDEO" === this._url.tagName,
3305                    i = (this._image = t ? this._url : hi("video"));
3306                if ((pi(i, "leaflet-image-layer"), this._zoomAnimated && pi(i, "leaflet-zoom-animated"), (i.onselectstart = l), (i.onmousemove = l), (i.onloadeddata = a(this.fire, this, "load")), t)) {
3307                    for (var e = i.getElementsByTagName("source"), n = [], o = 0; o < e.length; o++) n.push(e[o].src);
3308                    this._url = 0 < e.length ? n : [i.src];
3309                } else {
3310                    v(this._url) || (this._url = [this._url]), !this.options.keepAspectRatio && i.style.hasOwnProperty("objectFit") && (i.style.objectFit = "fill"), (i.autoplay = !!this.options.autoplay), (i.loop = !!this.options.loop);
3311                    for (var s = 0; s < this._url.length; s++) {
3312                        var r = hi("source");
3313                        (r.src = this._url[s]), i.appendChild(r);
3314                    }
3315                }
3316            },
3317        });
3318    var tn = $e.extend({
3319        _initImage: function () {
3320            var t = (this._image = this._url);
3321            pi(t, "leaflet-image-layer"), this._zoomAnimated && pi(t, "leaflet-zoom-animated"), (t.onselectstart = l), (t.onmousemove = l);
3322        },
3323    });
3324    var en = Se.extend({
3325            options: { offset: [0, 7], className: "", pane: "popupPane" },
3326            initialize: function (t, i) {
3327                p(this, t), (this._source = i);
3328            },
3329            onAdd: function (t) {
3330                (this._zoomAnimated = t._zoomAnimated),
3331                    this._container || this._initLayout(),
3332                    t._fadeAnimated && vi(this._container, 0),
3333                    clearTimeout(this._removeTimeout),
3334                    this.getPane().appendChild(this._container),
3335                    this.update(),
3336                    t._fadeAnimated && vi(this._container, 1),
3337                    this.bringToFront();
3338            },
3339            onRemove: function (t) {
3340                t._fadeAnimated ? (vi(this._container, 0), (this._removeTimeout = setTimeout(a(ui, void 0, this._container), 200))) : ui(this._container);
3341            },
3342            getLatLng: function () {
3343                return this._latlng;
3344            },
3345            setLatLng: function (t) {
3346                return (this._latlng = W(t)), this._map && (this._updatePosition(), this._adjustPan()), this;
3347            },
3348            getContent: function () {
3349                return this._content;
3350            },
3351            setContent: function (t) {
3352                return (this._content = t), this.update(), this;
3353            },
3354            getElement: function () {
3355                return this._container;
3356            },
3357            update: function () {
3358                this._map && ((this._container.style.visibility = "hidden"), this._updateContent(), this._updateLayout(), this._updatePosition(), (this._container.style.visibility = ""), this._adjustPan());
3359            },
3360            getEvents: function () {
3361                var t = { zoom: this._updatePosition, viewreset: this._updatePosition };
3362                return this._zoomAnimated && (t.zoomanim = this._animateZoom), t;
3363            },
3364            isOpen: function () {
3365                return !!this._map && this._map.hasLayer(this);
3366            },
3367            bringToFront: function () {
3368                return this._map && ci(this._container), this;
3369            },
3370            bringToBack: function () {
3371                return this._map && _i(this._container), this;
3372            },
3373            _prepareOpen: function (t, i, e) {
3374                if ((i instanceof Se || ((e = i), (i = t)), i instanceof Ee))
3375                    for (var n in t._layers) {
3376                        i = t._layers[n];
3377                        break;
3378                    }
3379                if (!e)
3380                    if (i.getCenter) e = i.getCenter();
3381                    else {
3382                        if (!i.getLatLng) throw new Error("Unable to get source layer LatLng.");
3383                        e = i.getLa
3383tLng();
3384                    }
3385                return (this._source = i), this.update(), e;
3386            },
3387            _updateContent: function () {
3388                if (this._content) {
3389                    var t = this._contentNode,
3390                        i = "function" == typeof this._content ? this._content(this._source || this) : this._content;
3391                    if ("string" == typeof i) t.innerHTML = i;
3392                    else {
3393                        for (; t.hasChildNodes(); ) t.removeChild(t.firstChild);
3394                        t.appendChild(i);
3395                    }
3396                    this.fire("contentupdate");
3397                }
3398            },
3399            _updatePosition: function () {
3400                if (this._map) {
3401                    var t = this._map.latLngToLayerPoint(this._latlng),
3402                        i = I(this.options.offset),
3403                        e = this._getAnchor();
3404                    this._zoomAnimated ? wi(this._container, t.add(e)) : (i = i.add(t).add(e));
3405                    var n = (this._containerBottom = -i.y),
3406                        o = (this._containerLeft = -Math.round(this._containerWidth / 2) + i.x);
3407                    (this._container.style.bottom = n + "px"), (this._container.style.left = o + "px");
3408                }
3409            },
3410            _getAnchor: function () {
3411                return [0, 0];
3412            },
3413        }),
3414        nn = en.extend({
3415            options: {
3416                maxWidth: 300,
3417                minWidth: 50,
3418                maxHeight: null,
3419                autoPan: !0,
3420                autoPanPaddingTopLeft: null,
3421                autoPanPaddingBottomRight: null,
3422                autoPanPadding: [5, 5],
3423                keepInView: !1,
3424                closeButton: !0,
3425                autoClose: !0,
3426                closeOnEscapeKey: !0,
3427                className: "",
3428            },
3429            openOn: function (t) {
3430                return t.openPopup(this), this;
3431            },
3432            onAdd: function (t) {
3433                en.prototype.onAdd.call(this, t), t.fire("popupopen", { popup: this }), this._source && (this._source.fire("popupopen", { popup: this }, !0), this._source instanceof Oe || this._source.on("preclick", Oi));
3434            },
3435            onRemove: function (t) {
3436                en.prototype.onRemove.call(this, t), t.fire("popupclose", { popup: this }), this._source && (this._source.fire("popupclose", { popup: this }, !0), this._source instanceof Oe || this._source.off("preclick", Oi));
3437            },
3438            getEvents: function () {
3439                var t = en.prototype.getEvents.call(this);
3440                return (void 0 !== this.options.closeOnClick ? this.options.closeOnClick : this._map.options.closePopupOnClick) && (t.preclick = this._close), this.options.keepInView && (t.moveend = this._adjustPan), t;
3441            },
3442            _close: function () {
3443                this._map && this._map.closePopup(this);
3444            },
3445            _initLayout: function () {
3446                var t = "leaflet-popup",
3447                    i = (this._container = hi("div", t + " " + (this.options.className || "") + " leaflet-zoom-animated")),
3448                    e = (this._wrapper = hi("div", t + "-content-wrapper", i));
3449                if (
3450                    ((this._contentNode = hi("div", t + "-content", e)),
3451                    Ni(e),
3452                    Ri(this._contentNode),
3453                    Ei(e, "contextmenu", Oi),
3454                    (this._tipContainer = hi("div", t + "-tip-container", i)),
3455                    (this._tip = hi("div", t + "-tip", this._tipContainer)),
3456                    this.options.closeButton)
3457                ) {
3458                    var n = (this._closeButton = hi("a", t + "-close-button", i));
3459                    (n.href = "#close"), (n.innerHTML = "&#215;"), Ei(n, "click", this._onCloseButtonClick, this);
3460                }
3461            },
3462            _updateLayout: function () {
3463                var t = this._contentNode,
3464                    i = t.style;
3465                (i.width = ""), (i.whiteSpace = "nowrap");
3466                var e = t.offsetWidth;
3467                (e = Math.min(e, this.options.maxWidth)), (e = Math.max(e, this.options.minWidth)), (i.width = e + 1 + "px"), (i.whiteSpace = ""), (i.height = "");
3468                var n = t.offsetHeight,
3469                    o = this.options.maxHeight,
3470                    s = "leaflet-popup-scrolled";
3471                o && o < n ? ((i.height = o + "px"), pi(t, s)) : mi(t, s), (this._containerWidth = this._container.offsetWidth);
3472            },
3473            _animateZoom: function (t) {
3474                var i = this._map._latLngToNewLayerPoint(this._latlng, t.zoom, t.center),
3475                    e = this._getAnchor();
3476                wi(this._container, i.add(e));
3477            },
3478            _adjustPan: function () {
3479                if (this.options.autoPan) {
3480                    this._map._panAnim && this._map._panAnim.stop();
3481                    var t = this._map,
3482                        i = parseInt(ai(this._container, "marginBottom"), 10) || 0,
3483                        e = this._container.offsetHeight + i,
3484                        n = this._containerWidth,
3485                        o = new B(this._containerLeft, -e - this._containerBottom);
3486                    o._add(Pi(this._container));
3487                    var s = t.layerPointToContainerPoint(o),
3488                        r = I(this.options.autoPanPadding),
3489                        a = I(this.options.autoPanPaddingTopLeft || r),
3490                        h = I(this.options.autoPanPaddingBottomRight || r),
3491                        u = t.getSize(),
3492                        l = 0,
3493                        c = 0;
3494                    s.x + n + h.x > u.x && (l = s.x + n - u.x + h.x),
3495                        s.x - l - a.x < 0 && (l = s.x - a.x),
3496                        s.y + e + h.y > u.y && (c = s.y + e - u.y + h.y),
3497                        s.y - c - a.y < 0 && (c = s.y - a.y),
3498                        (l || c) && t.fire("autopanstart").panBy([l, c]);
3499                }
3500            },
3501            _onCloseButtonClick: function (t) {
3502                this._close(), ji(t);
3503            },
3504            _getAnchor: function () {
3505                return I(this._source && this._source._getPopupAnchor ? this._source._getPopupAnchor() : [0, 0]);
3506            },
3507        });
3508    Ji.mergeOptions({ closePopupOnClick: !0 }),
3509        Ji.include({
3510            openPopup: function (t, i, e) {
3511                return t instanceof nn || (t = new nn(e).setContent(t)), i && t.setLatLng(i), this.hasLayer(t) ? this 
3511: (this._popup && this._popup.options.autoClose && this.closePopup(), (this._popup = t), this.addLayer(t));
3512            },
3513            closePopup: function (t) {
3514                return (t && t !== this._popup) || ((t = this._popup), (this._popup = null)), t && this.removeLayer(t), this;
3515            },
3516        }),
3517        Se.include({
3518            bindPopup: function (t, i) {
3519                return (
3520                    t instanceof nn ? (p(t, i), ((this._popup = t)._source = this)) : ((this._popup && !i) || (this._popup = new nn(i, this)), this._popup.setContent(t)),
3521                    this._popupHandlersAdded || (this.on({ click: this._openPopup, keypress: this._onKeyPress, remove: this.closePopup, move: this._movePopup }), (this._popupHandlersAdded = !0)),
3522                    this
3523                );
3524            },
3525            unbindPopup: function () {
3526                return this._popup && (this.off({ click: this._openPopup, keypress: this._onKeyPress, remove: this.closePopup, move: this._movePopup }), (this._popupHandlersAdded = !1), (this._popup = null)), this;
3527            },
3528            openPopup: function (t, i) {
3529                return this._popup && this._map && ((i = this._popup._prepareOpen(this, t, i)), this._map.openPopup(this._popup, i)), this;
3530            },
3531            closePopup: function () {
3532                return this._popup && this._popup._close(), this;
3533            },
3534            togglePopup: function (t) {
3535                return this._popup && (this._popup._map ? this.closePopup() : this.openPopup(t)), this;
3536            },
3537            isPopupOpen: function () {
3538                return !!this._popup && this._popup.isOpen();
3539            },
3540            setPopupContent: function (t) {
3541                return this._popup && this._popup.setContent(t), this;
3542            },
3543            getPopup: function () {
3544                return this._popup;
3545            },
3546            _openPopup: function (t) {
3547                var i = t.layer || t.target;
3548                this._popup && this._map && (ji(t), i instanceof Oe ? this.openPopup(t.layer || t.target, t.latlng) : this._map.hasLayer(this._popup) && this._popup._source === i ? this.closePopup() : this.openPopup(i, t.latlng));
3549            },
3550            _movePopup: function (t) {
3551                this._popup.setLatLng(t.latlng);
3552            },
3553            _onKeyPress: function (t) {
3554                13 === t.originalEvent.keyCode && this._openPopup(t);
3555            },
3556        });
3557    var on = en.extend({
3558        options: { pane: "tooltipPane", offset: [0, 0], direction: "auto", permanent: !1, sticky: !1, interactive: !1, opacity: 0.9 },
3559        onAdd: function (t) {
3560            en.prototype.onAdd.call(this, t), this.setOpacity(this.options.opacity), t.fire("tooltipopen", { tooltip: this }), this._source && this._source.fire("tooltipopen", { tooltip: this }, !0);
3561        },
3562        onRemove: function (t) {
3563            en.prototype.onRemove.call(this, t), t.fire("tooltipclose", { tooltip: this }), this._source && this._source.fire("tooltipclose", { tooltip: this }, !0);
3564        },
3565        getEvents: function () {
3566            var t = en.prototype.getEvents.call(this);
3567            return Tt && !this.options.permanent && (t.preclick = this._close), t;
3568        },
3569        _close: function () {
3570            this._map && this._map.closeTooltip(this);
3571        },
3572        _initLayout: function () {
3573            var t = "leaflet-tooltip " + (this.options.className || "") + " leaflet-zoom-" + (this._zoomAnimated ? "animated" : "hide");
3574            this._contentNode = this._container = hi("div", t);
3575        },
3576        _updateLayout: function () {},
3577        _adjustPan: function () {},
3578        _setPosition: function (t) {
3579            var i = this._map,
3580                e = this._container,
3581                n = i.latLngToContainerPoint(i.getCenter()),
3582                o = i.layerPointToContainerPoint(t),
3583                s = this.options.direction,
3584                r = e.offsetWidth,
3585                a = e.offsetHeight,
3586                h = I(this.options.offset),
3587                u = this._getAnchor();
3588            (t =
3589                "top" === s
3590                    ? t.add(I(-r / 2 + h.x, -a + h.y + u.y, !0))
3591                    : "bottom" === s
3592                    ? t.subtract(I(r / 2 - h.x, -h.y, !0))
3593                    : "center" === s
3594                    ? t.subtract(I(r / 2 + h.x, a / 2 - u.y + h.y, !0))
3595                    : "right" === s || ("auto" === s && o.x < n.x)
3596                    ? ((s = "right"), t.add(I(h.x + u.x, u.y - a / 2 + h.y, !0)))
3597                    : ((s = "left"), t.subtract(I(r + u.x - h.x, a / 2 - u.y - h.y, !0)))),
3598                mi(e, "leaflet-tooltip-right"),
3599                mi(e, "leaflet-tooltip-left"),
3600                mi(e, "leaflet-tooltip-top"),
3601                mi(e, "leaflet-tooltip-bottom"),
3602                pi(e, "leaflet-tooltip-" + s),
3603                wi(e, t);
3604        },
3605        _updatePosition: function () {
3606            var t = this._map.latLngToLayerPoint(this._latlng);
3607            this._setPosition(t);
3608        },
3609        setOpacity: function (t) {
3610            (this.options.opacity = t), this._container && vi(this._container, t);
3611        },
3612        _animateZoom: function (t) {
3613            var i = this._map._latLngToNewLayerPoint(this._latlng, t.zoom, t.center);
3614            this._setPosition(i);
3615        },
3616        _getAnchor: function () {
3617            return I(this._source && this._source._getTooltipAnchor && !this.options.sticky ? this._source._getTooltipAnchor() : [0, 0]);
3618        },
3619    });
3620    Ji.include({
3621        openTooltip: function (t, i, e) {
3622            return t instanceof on || (t = new on(e).setContent(t)), i && t.setLatLng(i), this.hasLayer(t) ? this 
3622: this.addLayer(t);
3623        },
3624        closeTooltip: function (t) {
3625            return t && this.removeLayer(t), this;
3626        },
3627    }),
3628        Se.include({
3629            bindTooltip: function (t, i) {
3630                return (
3631                    t instanceof on ? (p(t, i), ((this._tooltip = t)._source = this)) : ((this._tooltip && !i) || (this._tooltip = new on(i, this)), this._tooltip.setContent(t)),
3632                    this._initTooltipInteractions(),
3633                    this._tooltip.options.permanent && this._map && this._map.hasLayer(this) && this.openTooltip(),
3634                    this
3635                );
3636            },
3637            unbindTooltip: function () {
3638                return this._tooltip && (this._initTooltipInteractions(!0), this.closeTooltip(), (this._tooltip = null)), this;
3639            },
3640            _initTooltipInteractions: function (t) {
3641                if (t || !this._tooltipHandlersAdded) {
3642                    var i = t ? "off" : "on",
3643                        e = { remove: this.closeTooltip, move: this._moveTooltip };
3644                    this._tooltip.options.permanent
3645                        ? (e.add = this._openTooltip)
3646                        : ((e.mouseover = this._openTooltip), (e.mouseout = this.closeTooltip), this._tooltip.options.sticky && (e.mousemove = this._moveTooltip), Tt && (e.click = this._openTooltip)),
3647                        this[i](e),
3648                        (this._tooltipHandlersAdded = !t);
3649                }
3650            },
3651            openTooltip: function (t, i) {
3652                return (
3653                    this._tooltip &&
3654                        this._map &&
3655                        ((i = this._tooltip._prepareOpen(this, t, i)),
3656                        this._map.openTooltip(this._tooltip, i),
3657                        this._tooltip.options.interactive && this._tooltip._container && (pi(this._tooltip._container, "leaflet-clickable"), this.addInteractiveTarget(this._tooltip._container))),
3658                    this
3659                );
3660            },
3661            closeTooltip: function () {
3662                return (
3663                    this._tooltip && (this._tooltip._close(), this._tooltip.options.interactive && this._tooltip._container && (mi(this._tooltip._container, "leaflet-clickable"), this.removeInteractiveTarget(this._tooltip._container))),
3664                    this
3665                );
3666            },
3667            toggleTooltip: function (t) {
3668                return this._tooltip && (this._tooltip._map ? this.closeTooltip() : this.openTooltip(t)), this;
3669            },
3670            isTooltipOpen: function () {
3671                return this._tooltip.isOpen();
3672            },
3673            setTooltipContent: function (t) {
3674                return this._tooltip && this._tooltip.setContent(t), this;
3675            },
3676            getTooltip: function () {
3677                return this._tooltip;
3678            },
3679            _openTooltip: function (t) {
3680                var i = t.layer || t.target;
3681                this._tooltip && this._map && this.openTooltip(i, this._tooltip.options.sticky ? t.latlng : void 0);
3682            },
3683            _moveTooltip: function (t) {
3684                var i,
3685                    e,
3686                    n = t.latlng;
3687                this._tooltip.options.sticky && t.originalEvent && ((i = this._map.mouseEventToContainerPoint(t.originalEvent)), (e = this._map.containerPointToLayerPoint(i)), (n = this._map.layerPointToLatLng(e))),
3688                    this._tooltip.setLatLng(n);
3689            },
3690        });
3691    var sn = ke.extend({
3692        options: { iconSize: [12, 12], html: !1, bgPos: null, className: "leaflet-div-icon" },
3693        createIcon: function (t) {
3694            var i = t && "DIV" === t.tagName ? t : document.createElement("div"),
3695                e = this.options;
3696            if ((e.html instanceof Element ? (li(i), i.appendChild(e.html)) : (i.innerHTML = !1 !== e.html ? e.html : ""), e.bgPos)) {
3697                var n = I(e.bgPos);
3698                i.style.backgroundPosition = -n.x + "px " + -n.y + "px";
3699            }
3700            return this._setIconStyles(i, "icon"), i;
3701        },
3702        createShadow: function () {
3703            return null;
3704        },
3705    });
3706    ke.Default = Be;
3707    var rn = Se.extend({
3708        options: {
3709            tileSize: 256,
3710            opacity: 1,
3711            updateWhenIdle: xt,
3712            updateWhenZooming: !0,
3713            updateInterval: 200,
3714            zIndex: 1,
3715            bounds: null,
3716            minZoom: 0,
3717            maxZoom: void 0,
3718            maxNativeZoom: void 0,
3719            minNativeZoom: void 0,
3720            noWrap: !1,
3721            pane: "tilePane",
3722            className: "",
3723            keepBuffer: 2,
3724        },
3725        initialize: function (t) {
3726            p(this, t);
3727        },
3728        onAdd: function () {
3729            this._initContainer(), (this._levels = {}), (this._tiles = {}), this._resetView(), this._update();
3730        },
3731        beforeAdd: function (t) {
3732            t._addZoomLimit(this);
3733        },
3734        onRemove: function (t) {
3735            this._removeAllTiles(), ui(this._container), t._removeZoomLimit(this), (this._container = null), (this._tileZoom = void 0);
3736        },
3737        bringToFront: function () {
3738            return this._map && (ci(this._container), this._setAutoZIndex(Math.max)), this;
3739        },
3740        bringToBack: function () {
3741            return this._map && (_i(this._container), this._setAutoZIndex(Math.min)), this;
3742        },
3743        getContainer: function () {
3744            return this._container;
3745        },
3746        setOpacity: function (t) {
3747            return (this.options.opacity = t), this._updateOpacity(), this;
3748        },
3749        setZIndex: function (t) {
3750            return (this.options.zIndex = t), this._updateZIndex(), this;
3751        },
3752        isLoading: function () {
3753            return this._loading;
3754        },
3755        redraw: function () {
3756            return this._map && (this._removeAllTiles(), this._update()), this;
3757        },
3758        getEvents: function () {
3759            var t = { viewprereset: this._invalidateAll, viewreset: this._resetView, zoom: this._resetView, moveend: this._onMoveEnd };
3760            return this.options.updateWhenIdle || (this._onMove || (this._onMove = o(this._onMoveEnd, this.options.updateInterval, this)), (t.move = this._onMove)), this._zoomAnimated && (t.zoomanim = this._animateZoom), t;
3761        },
3762        createTile: function () {
3763            return document.createElement("div");
3764        },
3765        getTileSize: function () {
3766            var t = this.options.tileSize;
3767            return t instanceof B ? t : new B(t, t);
3768        },
3769        _updateZIndex: function () {
3770            this._container && void 0 !== this.options.zIndex && null !== this.options.zIndex && (this._container.style.zIndex = this.options.zIndex);
3771        },
3772        _setAutoZIndex: function (t) {
3773            for (var i, e = this.getPane().children, n = -t(-1 / 0, 1 / 0), o = 0, s = e.length; o < s; o++) (i = e[o].style.zIndex), e[o] !== this._container && i && (n = t(n, +i));
3774            isFinite(n) && ((this.options.zIndex = n + t(-1, 1)), this._updateZIndex());
3775        },
3776        _updateOpacity: function () {
3777            if (this._map && !et) {
3778                vi(this._container, this.options.opacity);
3779                var t = +new Date(),
3780                    i = !1,
3781                    e = !1;
3782                for (var n in this._tiles) {
3783                    var o = this._tiles[n];
3784                    if (o.current && o.loaded) {
3785                        var s = Math.min(1, (t - o.loaded) / 200);
3786                        vi(o.el, s), s < 1 ? (i = !0) : (o.active ? (e = !0) : this._onOpaqueTile(o), (o.active = !0));
3787                    }
3788                }
3789                e && !this._noPrune && this._pruneTiles(), i && (C(this._fadeFrame), (this._fadeFrame = M(this._updateOpacity, this)));
3790            }
3791        },
3792        _onOpaqueTile: l,
3793        _initContainer: function () {
3794            this._container || ((this._container = hi("div", "leaflet-layer " + (this.options.className || ""))), this._updateZIndex(), this.options.opacity < 1 && this._updateOpacity(), this.getPane().appendChild(this._container));
3795        },
3796        _updateLevels: function () {
3797            var t = this._tileZoom,
3798                i = this.options.maxZoom;
3799            if (void 0 !== t) {
3800                for (var e in this._levels)
3801                    this._levels[e].el.children.length || e === t
3802                        ? ((this._levels[e].el.style.zIndex = i - Math.abs(t - e)), this._onUpdateLevel(e))
3803                        : (ui(this._levels[e].el), this._removeTilesAtZoom(e), this._onRemoveLevel(e), delete this._levels[e]);
3804                var n = this._levels[t],
3805                    o = this._map;
3806                return (
3807                    n ||
3808                        (((n = this._levels[t] = {}).el = hi("div", "leaflet-tile-container leaflet-zoom-animated", this._container)),
3809                        (n.el.style.zIndex = i),
3810                        (n.origin = o.project(o.unproject(o.getPixelOrigin()), t).round()),
3811                        (n.zoom = t),
3812                        this._setZoomTransform(n, o.getCenter(), o.getZoom()),
3813                        n.el.offsetWidth,
3814                        this._onCreateLevel(n)),
3815                    (this._level = n)
3816                );
3817            }
3818        },
3819        _onUpdateLevel: l,
3820        _onRemoveLevel: l,
3821        _onCreateLevel: l,
3822        _pruneTiles: function () {
3823            if (this._map) {
3824                var t,
3825                    i,
3826                    e = this._map.getZoom();
3827                if (e > this.options.maxZoom || e < this.options.minZoom) this._removeAllTiles();
3828                else {
3829                    for (t in this._tiles) (i = this._tiles[t]).retain = i.current;
3830                    for (t in this._tiles)
3831                        if ((i = this._tiles[t]).current && !i.active) {
3832                            var n = i.coords;
3833                            this._retainParent(n.x, n.y, n.z, n.z - 5) || this._retainChildren(n.x, n.y, n.z, n.z + 2);
3834                        }
3835                    for (t in this._tiles) this._tiles[t].retain || this._removeTile(t);
3836                }
3837            }
3838        },
3839        _removeTilesAtZoom: function (t) {
3840            for (var i in this._tiles) this._tiles[i].coords.z === t && this._removeTile(i);
3841        },
3842        _removeAllTiles: function () {
3843            for (var t in this._tiles) this._removeTile(t);
3844        },
3845        _invalidateAll: function () {
3846            for (var t in this._levels) ui(this._levels[t].el), this._onRemoveLevel(t), delete this._levels[t];
3847            this._removeAllTiles(), (this._tileZoom = void 0);
3848        },
3849        _retainParent: function (t, i, e, n) {
3850            var o = Math.floor(t / 2),
3851                s = Math.floor(i / 2),
3852                r = e - 1,
3853                a = new B(+o, +s);
3854            a.z = +r;
3855            var h = this._tileCoordsToKey(a),
3856                u = this._tiles[h];
3857            return u && u.active ? (u.retain = !0) : (u && u.loaded && (u.retain = !0), n < r && this._retainParent(o, s, r, n));
3858        },
3859        _retainChildren: function (t, i, e, n) {
3860            for (var o = 2 * t; o < 2 * t + 2; o++)
3861                for (var s = 2 * i; s < 2 * i + 2; s++) {
3862                    var r = new B(o, s);
3863                    r.z = e + 1;
3864                    var a = this._tileCoordsToKey(r),
3865                        h = this._tiles[a];
3866                    h && h.active ? (h.retain = !0) : (h && h.loaded && (h.retain = !0), e + 1 < n && this._retainChildren(o, s, e + 1, n));
3867                }
3868        },
3869        _resetView: function (t) {
3870            var i = t && (t.pinch || t.flyTo);
3871            this._setView(this._map.getCenter(), this._map.getZoom(), i, i);
3872        },
3873        _animateZoom: function (t) {
3874            this._setView(t.center, t.zoom, !0, t.noUpdate);
3875        },
3876        _clampZoom: function (t) {
3877            var i = this.options;
3878            return void 0 !== i.minNativeZoom && t < i.minNativeZoom ? i.minNativeZoom : void 0 !== i.maxNativeZoom && i.maxNativeZoom < t ? i.maxNativeZoom : t;
3879        },
3880        _setView: function (t, i, e, n) {
3881            var o = this._clampZoom(Math.round(i));
3882            ((void 0 !== this.options.maxZoom && o > this.options.maxZoom) || (void 0 !== this.options.minZoom && o < this.options.minZoom)) && (o = void 0);
3883            var s = this.options.updateWhenZooming && o !== this._tileZoom;
3884            (n && !s) || ((this._tileZoom = o), this._abortLoading && this._abortLoading(), this._updateLevels(), this._resetGrid(), void 0 !== o && this._update(t), e || this._pruneTiles(), (this._noPrune = !!e)),
3885                this._setZoomTransforms(t, i);
3886        },
3887        _setZoomTransforms: function (t, i) {
3888            for (var e in this._levels) this._setZoomTransform(this._levels[e], t, i);
3889        },
3890        _setZoomTransform: function (t, i, e) {
3891            var n = this._map.getZoomScale(e, t.zoom),
3892                o = t.origin.multiplyBy(n).subtract(this._map._getNewPixelOrigin(i, e)).round();
3893            yt ? xi(t.el, o, n) : wi(t.el, o);
3894        },
3895        _resetGrid: function () {
3896            var t = this._map,
3897                i = t.options.crs,
3898                e = (this._tileSize = this.getTileSize()),
3899                n = this._tileZoom,
3900                o = this._map.getPixelWorldBounds(this._tileZoom);
3901            o && (this._globalTileRange = this._pxBoundsToTileRange(o)),
3902                (this._wrapX = i.wrapLng && !this.options.noWrap && [Math.floor(t.project([0, i.wrapLng[0]], n).x / e.x), Math.ceil(t.project([0, i.wrapLng[1]], n).x / e.y)]),
3903                (this._wrapY = i.wrapLat && !this.options.noWrap && [Math.floor(t.project([i.wrapLat[0], 0], n).y / e.x), Math.ceil(t.project([i.wrapLat[1], 0], n).y / e.y)]);
3904        },
3905        _onMoveEnd: function () {
3906            this._map && !this._map._animatingZoom && this._update();
3907        },
3908        _getTiledPixelBounds: function (t) {
3909            var i = this._map,
3910                e = i._animatingZoom ? Math.max(i._animateToZoom, i.getZoom()) : i.getZoom(),
3911                n = i.getZoomScale(e, this._tileZoom),
3912                o = i.project(t, this._tileZoom).floor(),
3913                s = i.getSize().divideBy(2 * n);
3914            return new O(o.subtract(s), o.add(s));
3915        },
3916        _update: function (t) {
3917            var i = this._map;
3918            if (i) {
3919                var e = this._clampZoom(i.getZoom());
3920                if ((void 0 === t && (t = i.getCenter()), void 0 !== this._tileZoom)) {
3921                    var n = this._getTiledPixelBounds(t),
3922                        o = this._pxBoundsToTileRange(n),
3923                        s = o.getCenter(),
3924                        r = [],
3925                        a = this.options.keepBuffer,
3926                        h = new O(o.getBottomLeft().subtract([a, -a]), o.getTopRight().add([a, -a]));
3927                    if (!(isFinite(o.min.x) && isFinite(o.min.y) && isFinite(o.max.x) && isFinite(o.max.y))) throw new Error("Attempted to load an infinite number of tiles");
3928                    for (var u in this._tiles) {
3929                        var l = this._tiles[u].coords;
3930                        (l.z === this._tileZoom && h.contains(new B(l.x, l.y))) || (this._tiles[u].current = !1);
3931                    }
3932                    if (1 < Math.abs(e - this._tileZoom)) this._setVie
3932w(t, e);
3933                    else {
3934                        for (var c = o.min.y; c <= o.max.y; c++)
3935                            for (var _ = o.min.x; _ <= o.max.x; _++) {
3936                                var d = new B(_, c);
3937                                if (((d.z = this._tileZoom), this._isValidTile(d))) {
3938                                    var p = this._tiles[this._tileCoordsToKey(d)];
3939                                    p ? (p.current = !0) : r.push(d);
3940                                }
3941                            }
3942                        if (
3943                            (r.sort(function (t, i) {
3944                                return t.distanceTo(s) - i.distanceTo(s);
3945                            }),
3946                            0 !== r.length)
3947                        ) {
3948                            this._loading || ((this._loading = !0), this.fire("loading"));
3949                            var m = document.createDocumentFragment();
3950                            for (_ = 0; _ < r.length; _++) this._addTile(r[_], m);
3951                            this._level.el.appendChild(m);
3952                        }
3953                    }
3954                }
3955            }
3956        },
3957        _isValidTile: function (t) {
3958            var i = this._map.options.crs;
3959            if (!i.infinite) {
3960                var e = this._globalTileRange;
3961                if ((!i.wrapLng && (t.x < e.min.x || t.x > e.max.x)) || (!i.wrapLat && (t.y < e.min.y || t.y > e.max.y))) return !1;
3962            }
3963            if (!this.options.bounds) return !0;
3964            var n = this._tileCoordsToBounds(t);
3965            return D(this.options.bounds).overlaps(n);
3966        },
3967        _keyToBounds: function (t) {
3968            return this._tileCoordsToBounds(this._keyToTileCoords(t));
3969        },
3970        _tileCoordsToNwSe: function (t) {
3971            var i = this._map,
3972                e = this.getTileSize(),
3973                n = t.scaleBy(e),
3974                o = n.add(e);
3975            return [i.unproject(n, t.z), i.unproject(o, t.z)];
3976        },
3977        _tileCoordsToBounds: function (t) {
3978            var i = this._tileCoordsToNwSe(t),
3979                e = new N(i[0], i[1]);
3980            return this.options.noWrap || (e = this._map.wrapLatLngBounds(e)), e;
3981        },
3982        _tileCoordsToKey: function (t) {
3983            return t.x + ":" + t.y + ":" + t.z;
3984        },
3985        _keyToTileCoords: function (t) {
3986            var i = t.split(":"),
3987                e = new B(+i[0], +i[1]);
3988            return (e.z = +i[2]), e;
3989        },
3990        _removeTile: function (t) {
3991            var i = this._tiles[t];
3992            i && (ui(i.el), delete this._tiles[t], this.fire("tileunload", { tile: i.el, coords: this._keyToTileCoords(t) }));
3993        },
3994        _initTile: function (t) {
3995            pi(t, "leaflet-tile");
3996            var i = this.getTileSize();
3997            (t.style.width = i.x + "px"), (t.style.height = i.y + "px"), (t.onselectstart = l), (t.onmousemove = l), et && this.options.opacity < 1 && vi(t, this.options.opacity), st && !rt && (t.style.WebkitBackfaceVisibility = "hidden");
3998        },
3999        _addTile: function (t, i) {
4000            var e = this._getTilePos(t),
4001                n = this._tileCoordsToKey(t),
4002                o = this.createTile(this._wrapCoords(t), a(this._tileReady, this, t));
4003            this._initTile(o), this.createTile.length < 2 && M(a(this._tileReady, this, t, null, o)), wi(o, e), (this._tiles[n] = { el: o, coords: t, current: !0 }), i.appendChild(o), this.fire("tileloadstart", { tile: o, coords: t });
4004        },
4005        _tileReady: function (t, i, e) {
4006            i && this.fire("tileerror", { error: i, tile: e, coords: t });
4007            var n = this._tileCoordsToKey(t);
4008            (e = this._tiles[n]) &&
4009                ((e.loaded = +new Date()),
4010                this._map._fadeAnimated ? (vi(e.el, 0), C(this._fadeFrame), (this._fadeFrame = M(this._updateOpacity, this))) : ((e.active = !0), this._pruneTiles()),
4011                i || (pi(e.el, "leaflet-tile-loaded"), this.fire("tileload", { tile: e.el, coords: t })),
4012                this._noTilesToLoad() && ((this._loading = !1), this.fire("load"), et || !this._map._fadeAnimated ? M(this._pruneTiles, this) : setTimeout(a(this._pruneTiles, this), 250)));
4013        },
4014        _getTilePos: function (t) {
4015            return t.scaleBy(this.getTileSize()).subtract(this._level.origin);
4016        },
4017        _wrapCoords: function (t) {
4018            var i = new B(this._wrapX ? r(t.x, this._wrapX) : t.x, this._wrapY ? r(t.y, this._wrapY) : t.
4018y);
4019            return (i.z = t.z), i;
4020        },
4021        _pxBoundsToTileRange: function (t) {
4022            var i = this.getTileSize();
4023            return new O(t.min.unscaleBy(i).floor(), t.max.unscaleBy(i).ceil().subtract([1, 1]));
4024        },
4025        _noTilesToLoad: function () {
4026            for (var t in this._tiles) if (!this._tiles[t].loaded) return !1;
4027            return !0;
4028        },
4029    });
4030    var an = rn.extend({
4031        options: { minZoom: 0, maxZoom: 18, subdomains: "abc", errorTileUrl: "", zoomOffset: 0, tms: !1, zoomReverse: !1, detectRetina: !1, crossOrigin: !1 },
4032        initialize: function (t, i) {
4033            (this._url = t),
4034                (i = p(this, i)).detectRetina && Ct && 0 < i.maxZoom && ((i.tileSize = Math.floor(i.tileSize / 2)), i.zoomReverse ? (i.zoomOffset--, i.minZoom++) : (i.zoomOffset++, i.maxZoom--), (i.minZoom = Math.max(0, i.minZoom))),
4035                "string" == typeof i.subdomains && (i.subdomains = i.subdomains.split("")),
4036                st || this.on("tileunload", this._onTileRemove);
4037        },
4038        setUrl: function (t, i) {
4039            return this._url === t && void 0 === i && (i = !0), (this._url = t), i || this.redraw(), this;
4040        },
4041        createTile: function (t, i) {
4042            var e = document.createElement("img");
4043            return (
4044                Ei(e, "load", a(this._tileOnLoad, this, i, e)),
4045                Ei(e, "error", a(this._tileOnError, this, i, e)),
4046                (!this.options.crossOrigin && "" !== this.options.crossOrigin) || (e.crossOrigin = !0 === this.options.crossOrigin ? "" : this.options.crossOrigin),
4047                (e.alt = ""),
4048                e.setAttribute("role", "presentation"),
4049                (e.src = this.getTileUrl(t)),
4050                e
4051            );
4052        },
4053        getTileUrl: function (t) {
4054            var i = { r: Ct ? "@2x" : "", s: this._getSubdomain(t), x: t.x, y: t.y, z: this._getZoomForUrl() };
4055            if (this._map && !this._map.options.crs.infinite) {
4056                var e = this._globalTileRange.max.y - t.y;
4057                this.options.tms && (i.y = e), (i["-y"] = e);
4058            }
4059            return g(this._url, h(i, this.options));
4060        },
4061        _tileOnLoad: function (t, i) {
4062            et ? setTimeout(a(t, this, null, i), 0) : t(null, i);
4063        },
4064        _tileOnError: function (t, i, e) {
4065            var n = this.options.errorTileUrl;
4066            n && i.getAttribute("src") !== n && (i.src = n), t(e, i);
4067        },
4068        _onTileRemove: function (t) {
4069            t.tile.onload = null;
4070        },
4071        _getZoomForUrl: function () {
4072            var t = this._tileZoom,
4073                i = this.options.maxZoom;
4074            return this.options.zoomReverse && (t = i - t), t + this.options.zoomOffset;
4075        },
4076        _getSubdomain: function (t) {
4077            var i = Math.abs(t.x + t.y) % this.options.subdomains.length;
4078            return this.options.subdomains[i];
4079        },
4080        _abortLoading: function () {
4081            var t, i;
4082            for (t in this._tiles) this._tiles[t].coords.z !== this._tileZoom && (((i = this._tiles[t].el).onload = l), (i.onerror = l), i.complete || ((i.src = x), ui(i), delete this._tiles[t]));
4083        },
4084        _removeTile: function (t) {
4085            var i = this._tiles[t];
4086            if (i) return ht || i.el.setAttribute("src", x), rn.prototype._removeTile.call(this, t);
4087        },
4088        _tileReady: function (t, i, e) {
4089            if (this._map && (!e || e.getAttribute("src") !== x)) return rn.prototype._tileReady.call(this, t, i, e);
4090        },
4091    });
4092    function hn(t, i) {
4093        return new an(t, i);
4094    }
4095    var un = an.extend({
4096        defaultWmsParams: { service: "WMS", request: "GetMap", layers: "", styles: "", format: "image/jpeg", transparent: !1, version: "1.1.1" },
4097        options: { crs: null, uppercase: !1 },
4098        initialize: function (t, i) {
4099            this._url = t;
4100            var e = h({}, this.defaultWmsParams);
4101            for (var n in i) n in this.options || (e[n] = i[n]);
4102            var o = (i = p(this, i)).detectRetina && Ct ? 2 : 1,
4103                s = this.getTileSize();
4104            (e.width = s.x * o), (e.height = s.y * o), (this.wmsParams = e);
4105        },
4106        onAdd: function (t) {
4107            (this._crs = this.options.crs || t.options.crs), (this._wmsVersion = parseFloat(this.wmsParams.version));
4108            var i = 1.3 <= this._wmsVersion ? "crs" : "srs";
4109            (this.wmsParams[i] = this._crs.code), an.prototype.onAdd.call(this, t);
4110        },
4111        getTileUrl: function (t) {
4112            var i = this._tileCoordsToNwSe(t),
4113                e = this._crs,
4114                n = R(e.project(i[0]), e.project(i[1])),
4115                o = n.min,
4116                s = n.max,
4117                r = (1.3 <= this._wmsVersion && this._crs === Me ? [o.y, o.x, s.y, s.x] : [o.x, o.y, s.x, s.y]).join(","),
4118                a = an.prototype.getTileUrl.call(this, t);
4119            return a + m(this.wmsParams, a, this.options.uppercase) + (this.options.uppercase ? "&BBOX=" : "&bbox=") + r;
4120        },
4121        setParams: function (t, i) {
4122            return h(this.wmsParams, t), i || this.redraw(), this;
4123        },
4124    });
4125    (an.WMS = un),
4126        (hn.wms = function (t, i) {
4127            return new un(t, i);
4128        });
4129    var ln = Se.extend({
4130            options: { padding: 0.1, tolerance: 0 },
4131            initialize: function (t) {
4132                p(this, t), u(this), (this._layers = this._layers || {});
4133            },
4134            onAdd: function () {
4135                this._container || (this._initContainer(), this._zoomAnimated && pi(this._container, "leaflet-zoom-animated")), this.getPane().appendChild(this._container), this._update(), this.on("update", this._updatePaths, this);
4136            },
4137            onRemove: function () {
4138                this.off("update", this._updatePaths, this), this._destroyContainer();
4139            },
4140            getEvents: function () {
4141                var t = { viewreset: this._reset, zoom: this._onZoom, moveend: this._update, zoomend: this._onZoomEnd };
4142                return this._zoomAnimated && (t.zoomanim = this._onAnimZoom), t;
4143            },
4144            _onAnimZoom: function (t) {
4145                this._updateTransform(t.center, t.zoom);
4146            },
4147            _onZoom: function () {
4148                this._updateTransform(this._map.getCenter(), this._map.getZoom());
4149            },
4150            _updateTransform: function (t, i) {
4151                var e = this._map.getZoomScale(i, this._zoom),
4152                    n = Pi(this._container),
4153                    o = this._map.getSize().multiplyBy(0.5 + this.options.padding),
4154                    s = this._map.project(this._center, i),
4155                    r = this._map.project(t, i).subtract(s),
4156                    a = o.multiplyBy(-e).add(n).add(o).subtract(r);
4157                yt ? xi(this._container, a, e) : wi(this._container, a);
4158            },
4159            _reset: function () {
4160                for (var t in (this._update(), this._updateTransform(this._center, this._zoom), this._layers)) this._layers[t]._reset();
4161            },
4162            _onZoomEnd: function () {
4163                for (var t in this._layers) this._layers[t]._project();
4164            },
4165            _updatePaths: function () {
4166                for (var t in this._layers) this._layers[t]._update();
4167            },
4168            _update: function () {
4169                var t = this.options.padding,
4170                    i = this._map.getSize(),
4171                    e = this._map.containerPointToLayerPoint(i.multiplyBy(-t)).roun
4171d();
4172                (this._bounds = new O(e, e.add(i.multiplyBy(1 + 2 * t)).round())), (this._center = this._map.getCenter()), (this._zoom = this._map.getZoom());
4173            },
4174        }),
4175        cn = ln.extend({
4176            getEvents: function () {
4177                var t = ln.prototype.getEvents.call(this);
4178                return (t.viewprereset = this._onViewPreReset), t;
4179            },
4180            _onViewPreReset: function () {
4181                this._postponeUpdatePaths = !0;
4182            },
4183            onAdd: function () {
4184                ln.prototype.onAdd.call(this), this._draw();
4185            },
4186            _initContainer: function () {
4187                var t = (this._container = document.createElement("canvas"));
4188                Ei(t, "mousemove", o(this._onMouseMove, 32, this), this), Ei(t, "click dblclick mousedown mouseup contextmenu", this._onClick, this), Ei(t, "mouseout", this._handleMouseOut, this), (this._ctx = t.getContext("2d"));
4189            },
4190            _destroyContainer: function () {
4191                C(this._redrawRequest), delete this._ctx, ui(this._container), Bi(this._container), delete this._container;
4192            },
4193            _updatePaths: function () {
4194                if (!this._postponeUpdatePaths) {
4195                    for (var t in ((this._redrawBounds = null), this._layers)) this._layers[t]._update();
4196                    this._redraw();
4197                }
4198            },
4199            _update: function () {
4200                if (!this._map._animatingZoom || !this._bounds) {
4201                    ln.prototype._update.call(this);
4202                    var t = this._bounds,
4203                        i = this._container,
4204                        e = t.getSize(),
4205                        n = Ct ? 2 : 1;
4206                    wi(i, t.min), (i.width = n * e.x), (i.height = n * e.y), (i.style.width = e.x + "px"), (i.style.height = e.y + "px"), Ct && this._ctx.scale(2, 2), this._ctx.translate(-t.min.x, -t.min.y), this.fire("update");
4207                }
4208            },
4209            _reset: function () {
4210                ln.prototype._reset.call(this), this._postponeUpdatePaths && ((this._postponeUpdatePaths = !1), this._updatePaths());
4211            },
4212            _initPath: function (t) {
4213                this._updateDashArray(t);
4214                var i = ((this._layers[u(t)] = t)._order = { layer: t, prev: this._drawLast, next: null });
4215                this._drawLast && (this._drawLast.next = i), (this._drawLast = i), (this._drawFirst = this._drawFirst || this._drawLast);
4216            },
4217            _addPath: function (t) {
4218                this._requestRedraw(t);
4219            },
4220            _removePath: function (t) {
4221                var i = t._order,
4222                    e = i.next,
4223                    n = i.prev;
4224                e ? (e.prev = n) : (this._drawLast = n), n ? (n.next = e) : (this._drawFirst = e), delete t._order, delete this._layers[u(t)], this._requestRedraw(t);
4225            },
4226            _updatePath: function (t) {
4227                this._extendRedrawBounds(t), t._project(), t._update(), this._requestRedraw(t);
4228            },
4229            _updateStyle: function (t) {
4230                this._updateDashArray(t), this._requestRedraw(t);
4231            },
4232            _updateDashArray: function (t) {
4233                if ("string" == typeof t.options.dashArray) {
4234                    var i,
4235                        e,
4236                        n = t.options.dashArray.split(/[, ]+/),
4237                        o = [];
4238                    for (e = 0; e < n.length; e++) {
4239                        if (((i = Number(n[e])), isNaN(i))) return;
4240                        o.push(i);
4241                    }
4242                    t.options._dashArray = o;
4243                } else t.options._dashArray = t.options.dashArray;
4244            },
4245            _requestRedraw: function (t) {
4246                this._map && (this._extendRedrawBounds(t), (this._redrawRequest = this._redrawRequest || M(this._redraw, this)));
4247            },
4248            _extendRedrawBounds: function (t) {
4249                if (t._pxBounds) {
4250                    var i = (t.options.weight || 0) + 1;
4251                    (this._redrawBounds = this._redrawBounds || new O()), this._redrawBounds.extend(t._pxBounds.min.subtract([i, i])), this._redrawBounds.extend(t._pxBounds.max.add([i, i]));
4252                }
4253            },
4254            _redraw: function () {
4255                (this._redrawRequest = null), this._redrawBounds && (this._redrawBounds.min._floor(), this._redrawBounds.max._ceil()), this._clear(), this._draw(), (this._redrawBounds = null);
4256            },
4257            _clear: function () {
4258                var t = this._redrawBounds;
4259                if (t) {
4260                    var i = t.getSize();
4261                    this._ctx.clearRect(t.min.x, t.min.y, i.x, i.y);
4262                } else this._ctx.clearRect(0, 0, this._container.width, this._container.height);
4263            },
4264            _draw: function () {
4265                var t,
4266                    i = this._redrawBounds;
4267                if ((this._ctx.save(), i)) {
4268                    var e = i.getSize();
4269                    this._ctx.beginPath(), this._ctx.rect(i.min.x, i.min.y, e.x, e.y), this._ctx.clip();
4270                }
4271                this._drawing = !0;
4272                for (var n = this._drawFirst; n; n = n.next) (t = n.layer), (!i || (t._pxBounds && t._pxBounds.intersects(i))) && t._updatePath();
4273                (this._drawing = !1), this._ctx.restore();
4274            },
4275            _updatePoly: function (t, i) {
4276                if (this._drawing) {
4277                    var e,
4278                        n,
4279                        o,
4280                        s,
4281                        r = t._parts,
4282                        a = r.length,
4283                        h = this._ctx;
4284                    if (a) {
4285                        for (h.beginPath(), e = 0; e < a; e++) {
4286                            for (n = 0, o = r[e].length; n < o; n++) (s = r[e][n]), h[n ? "lineTo" : "moveTo"](s.x, s.y);
4287                            i && h.closePath();
4288                        }
4289                        this._fillStroke(h, t);
4290                    }
4291                }
4292            },
4293            _updateCircle: function (t) {
4294                if (this._drawing && !t._empty()) {
4295                    var i = t._point,
4296                        e = this._ctx,
4297                        n = Math.max(Math.round(t._radius), 1),
4298                        o = (Math.max(Math.round(t._radiusY), 1) || n) / n;
4299                    1 != o && (e.save(), e.scale(1, o)), e.beginPath(), e.arc(i.x, i.y / o, n, 0, 2 * Math.PI, !1), 1 != o && e.restore(), this._fillStroke(e, t);
4300                }
4301            },
4302            _fillStroke: function (t, i) {
4303                var e = i.options;
4304                e.fill && ((t.globalAlpha = e.fillOpacity), (t.fillStyle = e.fillColor || e.color), t.fill(e.fillRule || "evenodd")),
4305                    e.stroke &&
4306                        0 !== e.weight &&
4307                        (t.setLineDash && t.setLineDash((i.options && i.options._dashArray) || []),
4308                        (t.globalAlpha = e.opacity),
4309                        (t.lineWidth = e.weight),
4310                        (t.strokeStyle = e.color),
4311                        (t.lineCap = e.lineCap),
4312                        (t.lineJoin = e.lineJoin),
4313                        t.stroke());
4314            },
4315            _onClick: function (t) {
4316                for (var i, e, n = this._map.mouseEventToLayerPoint(t), o = this._drawFirst; o; o = o.next) (i = o.layer).options.interactive && i._containsPoint(n) && !this._map._draggableMoved(i) && (e = i);
4317                e && (qi(t), this._fireEvent([e], t));
4318            },
4319            _onMouseMove: function (t) {
4320                if (this._map && !this._map.dragging.moving() && !this._map._animatingZoom) {
4321                    var i = this._map.mouseEventToLayerPoint(t);
4322                    this._handleMouseHover(t, i);
4323                }
4324            },
4325            _handleMouseOut: function (t) {
4326                var i = this._hoveredLayer;
4327                i && (mi(this._container, "leaflet-interactive"), this._fireEvent([i], t, "mouseout"), (this._hoveredLayer = null));
4328            },
4329            _handleMouseHover: function (t, i) {
4330                for (var e, n, o = this._drawFirst; o; o = o.next) (e = o.layer).options.interactive && e._containsPoint(i) && (n = e);
4331                n !== this._hoveredLayer && (this._handleMouseOut(t), n && (pi(this._container, "leaflet-interactive"), this._fireEvent([n], t, "mouseover"), (this._hoveredLayer = n))),
4332                    this._hoveredLayer && this._fireEvent([this._hoveredLayer], t);
4333            },
4334            _fireEvent: function (t, i, e) {
4335                this._map._fireDOMEvent(i, e || i.type, t);
4336            },
4337            _bringToFront: function (t) {
4338                var i = t._order;
4339                if (i) {
4340                    var e = i.next,
4341                        n = i.prev;
4342                    e && ((e.prev = n) ? (n.next = e) : e && (this._drawFirst = e), (i.prev = this._drawLast), ((this._drawLast.next = i).next = null), (this._drawLast = i), this._requestRedraw(t));
4343                }
4344            },
4345            _bringToBack: function (t) {
4346                var i = t._order;
4347                if (i) {
4348                    var e = i.next,
4349                        n = i.prev;
4350                    n && ((n.next = e) ? (e.prev = n) : n && (this._drawLast = n), (i.prev = null), (i.next = this._drawFirst), (this._drawFirst.prev = i), (this._drawFirst = i), this._requestRedraw(t));
4351                }
4352            },
4353        });
4354    function _n(t) {
4355        return St ? new cn(t) : null;
4356    }
4357    var dn = (function () {
4358            try {
4359                return (
4360                    document.namespaces.add("lvml", "urn:schemas-microsoft-com:vml"),
4361                    function (t) {
4362                        return document.createElement("<lvml:" + t + ' class="lvml">');
4363                    }
4364                );
4365            } catch (t) {
4366                return function (t) {
4367                    return document.createElement("<" + t + ' xmlns="urn:schemas-microsoft.com:vml" class="lvml">');
4368                };
4369            }
4370        })(),
4371        pn = {
4372            _initContainer: function () {
4373                this._container = hi("div", "leaflet-vml-container");
4374            },
4375            _update: function () {
4376                this._map._animatingZoom || (ln.prototype._update.call(this), this.fire("update"));
4377            },
4378            _initPath: function (t) {
4379                var i = (t._container = dn("shape"));
4380                pi(i, "leaflet-vml-shape " + (this.options.className || "")), (i.coordsize = "1 1"), (t._path = dn("path")), i.appendChild(t._path), this._updateStyle(t), (this._layers[u(t)] = t);
4381            },
4382            _addPath: function (t) {
4383                var i = t._container;
4384                this._container.appendChild(i), t.options.interactive && t.addInteractiveTarget(i);
4385            },
4386            _removePath: function (t) {
4387                var i = t._container;
4388                ui(i), t.removeInteractiveTarget(i), delete this._layers[u(t)];
4389            },
4390            _updateStyle: function (t) {
4391                var i = t._stroke,
4392                    e = t._fill,
4393                    n = t.options,
4394                    o = t._container;
4395                (o.stroked = !!n.stroke),
4396                    (o.filled = !!n.fill),
4397                    n.stroke
4398                        ? (i || (i = t._stroke = dn("stroke")),
4399                          o.appendChild(i),
4400                          (i.weight = n.weight + "px"),
4401                          (i.color = n.color),
4402                          (i.opacity = n.opacity),
4403                          n.dashArray ? (i.dashStyle = v(n.dashArray) ? n.dashArray.join(" ") : n.dashArray.replace(/( *, *)/g, " ")) : (i.dashStyle = ""),
4404                          (i.endcap = n.lineCap.replace("butt", "flat")),
4405                          (i.joinstyle = n.lineJoin))
4406                        : i && (o.removeChild(i), (t._stroke = null)),
4407                    n.fill ? (e || (e = t._fill = dn("fill")), o.appendChild(e), (e.color = n.fillColor || n.color), (e.opacity = n.fillOpacity)) : e && (o.removeChild(e), (t._fill = null));
4408            },
4409            _updateCircle: function (t) {
4410                var i = t._point.round(),
4411                    e = Math.round(t._radius),
4412                    n = Math.round(t._radiusY || e);
4413                this._setPath(t, t._empty() ? "M0 0" : "AL " + i.x + "," + i.y + " " + e + "," + n + " 0,23592600");
4414            },
4415            _setPath: function (t, i) {
4416                t._path.v = i;
4417            },
4418            _bringToFront: function (t) {
4419                ci(t._container);
4420            },
4421            _bringToBack: function (t) {
4422                _i(t._container);
4423            },
4424        },
4425        mn = Et ? dn : $,
4426        fn = ln.extend({
4427            getEvents: function () {
4428                var t = ln.prototype.getEvents.call(this);
4429                return (t.zoomstart = this._onZoomStart), t;
4430            },
4431            _initContainer: function () {
4432                (this._container = mn("svg")), this._container.setAttribute("pointer-events", "none"), (this._rootGroup = mn("g")), this._container.appendChild(this._rootGroup);
4433            },
4434            _destroyContainer: function () {
4435                ui(this._container), Bi(this._container), delete this._container, delete this._rootGroup, delete this._svgSize;
4436            },
4437            _onZoomStart: function () {
4438                this._update();
4439            },
4440            _update: function () {
4441                if (!this._map._animatingZoom || !this._bounds) {
4442                    ln.prototype._update.call(this);
4443                    var t = this._bounds,
4444                        i = t.getSize(),
4445                        e = this._container;
4446                    (this._svgSize && this._svgSize.equals(i)) || ((this._svgSize = i), e.setAttribute("width", i.x), e.setAttribute("height", i.y)),
4447                        wi(e, t.min),
4448                        e.setAttribute("viewBox", [t.min.x, t.min.y, i.x, i.y].join(" ")),
4449                        this.fire("update");
4450                }
4451            },
4452            _initPath: function (t) {
4453                var i = (t._path = mn("path"));
4454                t.options.className && pi(i, t.options.className), t.options.interactive && pi(i, "leaflet-interactive"), this._updateStyle(t), (this._layers[u(t)] = t);
4455            },
4456            _addPath: function (t) {
4457                this._rootGroup || this._initContainer(), this._rootGroup.appendChild(t._path), t.addInteractiveTarget(t._path);
4458            },
4459            _removePath: function (t) {
4460                ui(t._path), t.removeInteractiveTarget(t._path), delete this._layers[u(t)];
4461            },
4462            _updatePath: function (t) {
4463                t._project(), t._update();
4464            },
4465            _updateStyle: function (t) {
4466                var i = t._path,
4467                    e = t.options;
4468                i &&
4469                    (e.stroke
4470                        ? (i.setAttribute("stroke", e.color),
4471                          i.setAttribute("stroke-opacity", e.opacity),
4472                          i.setAttribute("stroke-width", e.weight),
4473                          i.setAttribute("stroke-linecap", e.lineCap),
4474                          i.setAttribute("stroke-linejoin", e.lineJoin),
4475                          e.dashArray ? i.setAttribute("stroke-dasharray", e.dashArray) : i.removeAttribute("stroke-dasharray"),
4476                          e.dashOffset ? i.setAttribute("stroke-dashoffset", e.dashOffset) : i.removeAttribute("stroke-dashoffset"))
4477                        : i.setAttribute("stroke", "none"),
4478                    e.fill ? (i.setAttribute("fill", e.fillColor || e.color), i.setAttribute("fill-opacity", e.fillOpacity), i.setAttribute("fill-rule", e.fillRule || "evenodd")) : i.setAttribute("fill", "none"));
4479            },
4480            _updatePoly: function (t, i) {
4481                this._setPath(t, Q(t._parts, i));
4482            },
4483            _updateCircle: function (t) {
4484                var i = t._point,
4485                    e = Math.max(Math.round(t._radius), 1),
4486                    n = "a" + e + "," + (Math.max(Math.round(t._radiusY), 1) || e) + " 0 1,0 ",
4487                    o = t._empty() ? "M0 0" : "M" + (i.x - e) + "," + i.y + n + 2 * e + ",0 " + n + 2 * -e + ",0 ";
4488                this._setPath(t, o);
4489            },
4490            _setPath: function (t, i) {
4491                t._path.setAttribute("d", i);
4492            },
4493            _bringToFront: function (t) {
4494                ci(t._path);
4495            },
4496            _bringToBack: function (t) {
4497                _i(t._path);
4498            },
4499        });
4500    function gn(t) {
4501        return Zt || Et ? new fn(t) : null;
4502    }
4503    Et && fn.include(pn),
4504        Ji.include({
4505            getRenderer: function (t) {
4506                var i = t.options.renderer || this._getPaneRenderer(t.options.pane) || this.options.renderer || this._renderer;
4507                return i || (i = this._renderer = this._createRenderer()), this.hasLayer(i) || this.addLayer(i), i;
4508            },
4509            _getPaneRenderer: function (t) {
4510                if ("overlayPane" === t || void 0 === t) return !1;
4511                var i = this._paneRenderers[t];
4512                return void 0 === i && ((i = this._createRenderer({ pane: t })), (this._paneRenderers[t] = i)), i;
4513            },
4514            _createRenderer: function (t) {
4515                return (this.options.preferCanvas && _n(t)) || gn(t);
4516            },
4517        });
4518    var vn = je.extend({
4519        initialize: function (t, i) {
4520            je.prototype.initialize.call(this, this._boundsToLatLngs(t), i);
4521        },
4522        setBounds: function (t) {
4523            return this.setLatLngs(this._boundsToLatLngs(t));
4524        },
4525        _boundsToLatLngs: function (t) {
4526            return [(t = D(t)).getSouthWest(), t.getNorthWest(), t.getNorthEast(), t.getSouthEast()];
4527        },
4528    });
4529    (fn.create = mn),
4530        (fn.pointsToPath = Q),
4531        (We.geometryToLayer = He),
4532        (We.coordsToLatLng = Fe),
4533        (We.coordsToLatLngs = Ue),
4534        (We.latLngToCoords = Ve),
4535        (We.latLngsToCoords = qe),
4536        (We.getFeature = Ge),
4537        (We.asFeature = Ke),
4538        Ji.mergeOptions({ boxZoom: !0 });
4539    var yn = oe.extend({
4540        initialize: function (t) {
4541            (this._map = t), (this._container = t._container), (this._pane = t._panes.overlayPane), (this._resetStateTimeout = 0), t.on("unload", this._destroy, this);
4542        },
4543        addHooks: function () {
4544            Ei(this._container, "mousedown", this._onMouseDown, this);
4545        },
4546        removeHooks: function () {
4547            Bi(this._container, "mousedown", this._onMouseDown, this);
4548        },
4549        moved: function () {
4550            return this._moved;
4551        },
4552        _destroy: function () {
4553            ui(this._pane), delete this._pane;
4554        },
4555        _resetState: function () {
4556            (this._resetStateTimeout = 0), (this._moved = !1);
4557        },
4558        _clearDeferredResetState: function () {
4559            0 !== this._resetStateTimeout && (clearTimeout(this._resetStateTimeout), (this._resetStateTimeout = 0));
4560        },
4561        _onMouseDown: function (t) {
4562            if (!t.shiftKey || (1 !== t.which && 1 !== t.button)) return !1;
4563            this._clearDeferredResetState(),
4564                this._resetState(),
4565                $t(),
4566                Li(),
4567                (this._startPoint = this._map.mouseEventToContainerPoint(t)),
4568                Ei(document, { contextmenu: ji, mousemove: this._onMouseMove, mouseup: this._onMouseUp, keydown: this._onKeyDown }, this);
4569        },
4570        _onMouseMove: function (t) {
4571            this._moved || ((this._moved = !0), (this._box = hi("div", "leaflet-zoom-box", this._container)), pi(this._container, "leaflet-crosshair"), this._map.fire("boxzoomstart")),
4572                (this._point = this._map.mouseEventToContainerPoint(t));
4573            var i = new O(this._point, this._startPoint),
4574                e = i.getSize();
4575            wi(this._box, i.min), (this._box.style.width = e.x + "px"), (this._box.style.height = e.y + "px");
4576        },
4577        _finish: function () {
4578            this._moved && (ui(this._box), mi(this._container, "leaflet-crosshair")), Qt(), Ti(), Bi(document, { contextmenu: ji, mousemove: this._onMouseMove, mouseup: this._onMouseUp, keydown: this._onKeyDown }, this);
4579        },
4580        _onMouseUp: function (t) {
4581            if ((1 === t.which || 1 === t.button) && (this._finish(), this._moved)) {
4582                this._clearDeferredResetState(), (this._resetStateTimeout = setTimeout(a(this._resetState, this), 0));
4583                var i = new N(this._map.containerPointToLatLng(this._startPoint), this._map.containerPointToLatLng(this._point));
4584                this._map.fitBounds(i).fire("boxzoomend", { boxZoomBounds: i });
4585            }
4586        },
4587        _onKeyDown: function (t) {
4588            27 === t.keyCode && this._finish();
4589        },
4590    });
4591    Ji.addInitHook("addHandler", "boxZoom", yn), Ji.mergeOptions({ doubleClickZoom: !0 });
4592    var xn = oe.extend({
4593        addHooks: function () {
4594            this._map.on("dblclick", this._onDoubleClick, this);
4595        },
4596        removeHooks: function () {
4597            this._map.off("dblclick", this._onDoubleClick, this);
4598        },
4599        _onDoubleClick: function (t) {
4600            var i = this._map,
4601                e = i.getZoom(),
4602                n = i.options.zoomDelta,
4603                o = t.originalEvent.shiftKey ? e - n : e + n;
4604            "center" === i.options.doubleClickZoom ? i.setZoom(o) : i.setZoomAround(t.containerPoint, o);
4605        },
4606    });
4607    Ji.addInitHook("addHandler", "doubleClickZoom", xn), Ji.mergeOptions({ dragging: !0, inertia: !rt, inertiaDeceleration: 3400, inertiaMaxSpeed: 1 / 0, easeLinearity: 0.2, worldCopyJump: !1, maxBoundsViscosity: 0 });
4608    var wn = oe.extend({
4609        addHooks: function () {
4610            if (!this._draggable) {
4611                var t = this._map;
4612                (this._draggable = new le(t._mapPane, t._container)),
4613                    this._draggable.on({ dragstart: this._onDragStart, drag: this._onDrag, dragend: this._onDragEnd }, this),
4614                    this._draggable.on("predrag", this._onPreDragLimit, this),
4615                    t.options.worldCopyJump && (this._draggable.on("predrag", this._onPreDragWrap, this), t.on("zoomend", this._onZoomEnd, this), t.whenReady(this._onZoomEnd, this));
4616            }
4617            pi(this._map._container, "leaflet-grab leaflet-touch-drag"), this._draggable.enable(), (this._positions = []), (this._times = []);
4618        },
4619        removeHooks: function () {
4620            mi(this._map._container, "leaflet-grab"), mi(this._map._container, "leaflet-touch-drag"), this._draggable.disable();
4621        },
4622        moved: function () {
4623            return this._draggable && this._draggable._moved;
4624        },
4625        moving: function () {
4626            return this._draggable && this._draggable._moving;
4627        },
4628        _onDragStart: function () {
4629            var t = this._map;
4630            if ((t._stop(), this._map.options.maxBounds && this._map.options.maxBoundsViscosity)) {
4631                var i = D(this._map.options.maxBounds);
4632                (this._offsetLimit = R(this._map.latLngToContainerPoint(i.getNorthWest()).multiplyBy(-1), this._map.latLngToContainerPoint(i.getSouthEast()).multiplyBy(-1).add(this._map.getSize()))),
4633                    (this._viscosity = Math.min(1, Math.max(0, this._map.options.maxBoundsViscosity)));
4634            } else this._offsetLimit = null;
4635            t.fire("movestart").fire("dragstart"), t.options.inertia && ((this._positions = []), (this._times = []));
4636        },
4637        _onDrag: function (t) {
4638            if (this._map.options.inertia) {
4639                var i = (this._lastTime = +new Date()),
4640                    e = (this._lastPos = this._draggable._absPos || this._draggable._newPos);
4641                this._positions.push(e), this._times.push(i), this._prunePositions(i);
4642            }
4643            this._map.fire("move", t).fire("drag", t);
4644        },
4645        _prunePositions: function (t) {
4646            for (; 1 < this._positions.length && 50 < t - this._times[0]; ) this._positions.shift(), this._times.shift();
4647        },
4648        _onZoomEnd: function () {
4649            var t = this._map.getSize().divideBy(2),
4650                i = this._map.latLngToLayerPoint([0, 0]);
4651            (this._initialWorldOffset = i.subtract(t).x), (this._worldWidth = this._map.getPixelWorldBounds().getSize().x);
4652        },
4653        _viscousLimit: function (t, i) {
4654            return t - (t - i) * this._viscosity;
4655        },
4656        _onPreDragLimit: function () {
4657            if (this._viscosity && this._offsetLimit) {
4658                var t = this._draggable._newPos.subtract(this._draggable._startPos),
4659                    i = this._offsetLimit;
4660                t.x < i.min.x && (t.x = this._viscousLimit(t.x, i.min.x)),
4661                    t.y < i.min.y && (t.y = this._viscousLimit(t.y, i.min.y)),
4662                    t.x > i.max.x && (t.x = this._viscousLimit(t.x, i.max.x)),
4663                    t.y > i.max.y && (t.y = this._viscousLimit(t.y, i.max.y)),
4664                    (this._draggable._newPos = this._draggable._startPos.add(t));
4665            }
4666        },
4667        _onPreDragWrap: function () {
4668            var t = this._worldWidth,
4669                i = Math.round(t / 2),
4670                e = this._initialWorldOffset,
4671                n = this._draggable._newPos.x,
4672                o = ((n - i + e) % t) + i - e,
4673                s = ((n + i + e) % t) - i - e,
4674                r = Math.abs(o + e) < Math.abs(s + e) ? o : s;
4675            (this._draggable._absPos = this._draggable._newPos.clone()), (this._draggable._newPos.x = r);
4676        },
4677        _onDragEnd: function (t) {
4678            var i = this._map,
4679                e = i.options,
4680                n = !e.inertia || this._times.length < 2;
4681            if ((i.fire("dragend", t), n)) i.fire("moveend");
4682            else {
4683                this._prunePositions(+new Date());
4684                var o = this._lastPos.subtract(this._positions[0]),
4685                    s = (this._lastTime - this._times[0]) / 1e3,
4686                    r = e.easeLinearity,
4687                    a = o.multiplyBy(r / s),
4688                    h = a.distanceTo([0, 0]),
4689                    u = Math.min(e.inertiaMaxSpeed, h),
4690                    l = a.multiplyBy(u / h),
4691                    c = u / (e.inertiaDeceleration * r),
4692                    _ = l.multiplyBy(-c / 2).round();
4693                _.x || _.y
4694                    ? ((_ = i._limitOffset(_, i.options.maxBounds)),
4695                      M(function () {
4696                          i.panBy(_, { duration: c, easeLinearity: r, noMoveStart: !0, animate: !0 });
4697                      }))
4698                    : i.fire("moveend");
4699            }
4700        },
4701    });
4702    Ji.addInitHook("addHandler", "dragging", wn), Ji.mergeOptions({ keyboard: !0, keyboardPanDelta: 80 });
4703    var Pn = oe.extend({
4704        keyCodes: { left: [37], right: [39], down: [40], up: [38], zoomIn: [187, 107, 61, 171], zoomOut: [189, 109, 54, 173] },
4705        initialize: function (t) {
4706            (this._map = t), this._setPanDelta(t.options.keyboardPanDelta), this._setZoomDelta(t.options.zoomDelta);
4707        },
4708        addHooks: function () {
4709            var t = this._map._container;
4710            t.tabIndex <= 0 && (t.tabIndex = "0"), Ei(t, { focus: this._onFocus, blur: this._onBlur, mousedown: this._onMouseDown }, this), this._map.on({ focus: this._addHooks, blur: this._removeHooks }, this);
4711        },
4712        removeHooks: function () {
4713            this._removeHooks(), Bi(this._map._container, { focus: this._onFocus, blur: this._onBlur, mousedown: this._onMouseDown }, this), this._map.off({ focus: this._addHooks, blur: this._removeHooks }, this);
4714        },
4715        _onMouseDown: function () {
4716            if (!this._focused) {
4717                var t = document.body,
4718                    i = document.documentElement,
4719                    e = t.scrollTop || i.scrollTop,
4720                    n = t.scrollLeft || i.scrollLeft;
4721                this._map._container.focus(), window.scrollTo(n, e);
4722            }
4723        },
4724        _onFocus: function () {
4725            (this._focused = !0), this._map.fire("focus");
4726        },
4727        _onBlur: function () {
4728            (this._focused = !1), this._map.fire("blur");
4729        },
4730        _setPanDelta: function (t) {
4731            var i,
4732                e,
4733                n = (this._panKeys = {}),
4734                o = this.keyCodes;
4735            for (i = 0, e = o.left.length; i < e;
4735 i++) n[o.left[i]] = [-1 * t, 0];
4736            for (i = 0, e = o.right.length; i < e; i++) n[o.right[i]] = [t, 0];
4737            for (i = 0, e = o.down.length; i < e; i++) n[o.down[i]] = [0, t];
4738            for (i = 0, e = o.up.length; i < e; i++) n[o.up[i]] = [0, -1 * t];
4739        },
4740        _setZoomDelta: function (t) {
4741            var i,
4742                e,
4743                n = (this._zoomKeys = {}),
4744                o = this.keyCodes;
4745            for (i = 0, e = o.zoomIn.length; i < e; i++) n[o.zoomIn[i]] = t;
4746            for (i = 0, e = o.zoomOut.length; i < e; i++) n[o.zoomOut[i]] = -t;
4747        },
4748        _addHooks: function () {
4749            Ei(document, "keydown", this._onKeyDown, this);
4750        },
4751        _removeHooks: function () {
4752            Bi(document, "keydown", this._onKeyDown, this);
4753        },
4754        _onKeyDown: function (t) {
4755            if (!(t.altKey || t.ctrlKey || t.metaKey)) {
4756                var i,
4757                    e = t.keyCode,
4758                    n = this._map;
4759                if (e in this._panKeys) (n._panAnim && n._panAnim._inProgress) || ((i = this._panKeys[e]), t.shiftKey && (i = I(i).multiplyBy(3)), n.panBy(i), n.options.maxBounds && n.panInsideBounds(n.options.maxBounds));
4760                else if (e in this._zoomKeys) n.setZoom(n.getZoom() + (t.shiftKey ? 3 : 1) * this._zoomKeys[e]);
4761                else {
4762                    if (27 !== e || !n._popup || !n._popup.options.closeOnEscapeKey) return;
4763                    n.closePopup();
4764                }
4765                ji(t);
4766            }
4767        },
4768    });
4769    Ji.addInitHook("addHandler", "keyboard", Pn), Ji.mergeOptions({ scrollWheelZoom: !0, wheelDebounceTime: 40, wheelPxPerZoomLevel: 60 });
4770    var bn = oe.extend({
4771        addHooks: function () {
4772            Ei(this._map._container, "mousewheel", this._onWheelScroll, this), (this._delta = 0);
4773        },
4774        removeHooks: function () {
4775            Bi(this._map._container, "mousewheel", this._onWheelScroll, this);
4776        },
4777        _onWheelScroll: function (t) {
4778            var i = Fi(t),
4779                e = this._map.options.wheelDebounceTime;
4780            (this._delta += i), (this._lastMousePos = this._map.mouseEventToContainerPoint(t)), this._startTime || (this._startTime = +new Date());
4781            var n = Math.max(e - (+new Date() - this._startTime), 0);
4782            clearTimeout(this._timer), (this._timer = setTimeout(a(this._performZoom, this), n)), ji(t);
4783        },
4784        _performZoom: function () {
4785            var t = this._map,
4786                i = t.getZoom(),
4787                e = this._map.options.zoomSnap || 0;
4788            t._stop();
4789            var n = this._delta / (4 * this._map.options.wheelPxPerZoomLevel),
4790                o = (4 * Math.log(2 / (1 + Math.exp(-Math.abs(n))))) / Math.LN2,
4791                s = e ? Math.ceil(o / e) * e : o,
4792                r = t._limitZoom(i + (0 < this._delta ? s : -s)) - i;
4793            (this._delta = 0), (this._startTime = null), r && ("center" === t.options.scrollWheelZoom ? t.setZoom(i + r) : t.setZoomAround(this._lastMousePos, i + r));
4794        },
4795    });
4796    Ji.addInitHook("addHandler", "scrollWheelZoom", bn), Ji.mergeOptions({ tap: !0, tapTolerance: 15 });
4797    var Ln = oe.extend({
4798        addHooks: function () {
4799            Ei(this._map._container, "touchstart", this._onDown, this);
4800        },
4801        removeHooks: function () {
4802            Bi(this._map._container, "touchstart", this._onDown, this);
4803        },
4804        _onDown: function (t) {
4805            if (t.touches) {
4806                if ((Di(t), (this._fireClick = !0), 1 < t.touches.length)) return (this._fireClick = !1), void clearTimeout(this._holdTimeout);
4807                var i = t.touches[0],
4808                    e = i.target;
4809                (this._startPos = this._newPos = new B(i.clientX, i.clientY)),
4810                    e.tagName && "a" === e.tagName.toLowerCase() && pi(e, "leaflet-active"),
4811                    (this._holdTimeout = setTimeout(
4812                        a(function () {
4813                            this._isTapValid() && ((this._fireClick = !1), this._onUp(), this._simulateEvent("contextmenu", i));
4814                        }, this),
4815                        1e3
4816                    )),
4817                    this._simulateEvent("mousedown", i),
4818                    Ei(document, { touchmove: this._onMove, touchend: this._onUp }, this);
4819            }
4820        },
4821        _onUp: function (t) {
4822            if ((clearTimeout(this._holdTimeout), Bi(document, { touchmove: this._onMove, touchend: this._onUp }, this), this._fireClick && t && t.changedTouches)) {
4823                var i = t.changedTouches[0],
4824                    e = i.target;
4825                e && e.tagName && "a" === e.tagName.toLowerCase() && mi(e, "leaflet-active"), this._simulateEvent("mouseup", i), this._isTapValid() && this._simulateEvent("click", i);
4826            }
4827        },
4828        _isTapValid: function () {
4829            return this._newPos.distanceTo(this._startPos) <= this._map.options.tapTolerance;
4830        },
4831        _onMove: function (t) {
4832            var i = t.touches[0];
4833            (this._newPos = new B(i.clientX, i.clientY)), this._simulateEvent("mousemove", i);
4834        },
4835        _simulateEvent: function (t, i) {
4836            var e = document.createEvent("MouseEvents");
4837            (e._simulated = !0), (i.target._simulatedClick = !0), e.initMouseEvent(t, !0, !0, window, 1, i.screenX, i.screenY, i.clientX, i.clientY, !1, !1, !1, !1, 0, null), i.target.dispatchEvent(e);
4838        },
4839    });
4840    Tt && !Lt && Ji.addInitHook("addHandler", "tap", Ln), Ji.mergeOptions({ touchZoom: Tt && !rt, bounceAtZoomLimits: !0 });
4841    var Tn = oe.extend({
4842        addHooks: function () {
4843            pi(this._map._container, "leaflet-touch-zoom"), Ei(this._map._container, "touchstart", this._onTouchStart, this);
4844        },
4845        removeHooks: function () {
4846            mi(this._map._container, "leaflet-touch-zoom"), Bi(this._map._container, "touchstart", this._onTouchStart, this);
4847        },
4848        _onTouchStart: function (t) {
4849            var i = this._map;
4850            if (t.touches && 2 === t.touches.length && !i._animatingZoom && !this._zooming) {
4851                var e = i.mouseEventToContainerPoint(t.touches[0]),
4852                    n = i.mouseEventToContainerPoint(t.touches[1]);
4853                (this._centerPoint = i.getSize()._divideBy(2)),
4854                    (this._startLatLng = i.containerPointToLatLng(this._centerPoint)),
4855                    "center" !== i.options.touchZoom && (this._pinchStartLatLng = i.containerPointToLatLng(e.add(n)._divideBy(2))),
4856                    (this._startDist = e.distanceTo(n)),
4857                    (this._startZoom = i.getZoom()),
4858                    (this._moved = !1),
4859                    (this._zooming = !0),
4860                    i._stop(),
4861                    Ei(document, "touchmove", this._onTouchMove, this),
4862                    Ei(document, "touchend", this._onTouchEnd, this),
4863                    Di(t);
4864            }
4865        },
4866        _onTouchMove: function (t) {
4867            if (t.touches && 2 === t.touches.length && this._zooming) {
4868                var i = this._map,
4869                    e = i.mouseEventToContainerPoint(t.touches[0]),
4870                    n = i.mouseEventToContainerPoint(t.touches[1]),
4871                    o = e.distanceTo(n) / this._startDist;
4872                if (
4873                    ((this._zoom = i.getScaleZoom(o, this._startZoom)),
4874                    !i.options.bounceAtZoomLimits && ((this._zoom < i.getMinZoom() && o < 1) || (this._zoom > i.getMaxZoom() && 1 < o)) && (this._zoom = i._limitZoom(this._zoom)),
4875                    "center" === i.options.touchZoom)
4876                ) {
4877                    if (((this._center = this._startLatLng), 1 == o)) return;
4878                } else {
4879                    var s = e._add(n)._divideBy(2)._subtract(this._centerPoint);
4880                    if (1 == o && 0 === s.x && 0 === s.y) return;
4881                    this._center = i.unproject(i.project(this._pinchStartLatLng, this._zoom).subtract(s), this._zoom);
4882                }
4883                this._moved || (i._moveStart(!0, !1), (this._moved = !0)), C(this._animRequest);
4884                var r = a(i._move, i, this._center, this._zoom, { pinch: !0, roun
4884d: !1 });
4885                (this._animRequest = M(r, this, !0)), Di(t);
4886            }
4887        },
4888        _onTouchEnd: function () {
4889            this._moved && this._zooming
4890                ? ((this._zooming = !1),
4891                  C(this._animRequest),
4892                  Bi(document, "touchmove", this._onTouchMove),
4893                  Bi(document, "touchend", this._onTouchEnd),
4894                  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)))
4895                : (this._zooming = !1);
4896        },
4897    });
4898    Ji.addInitHook("addHandler", "touchZoom", Tn),
4899        (Ji.BoxZoom = yn),
4900        (Ji.DoubleClickZoom = xn),
4901        (Ji.Drag = wn),
4902        (Ji.Keyboard = Pn),
4903        (Ji.ScrollWheelZoom = bn),
4904        (Ji.Tap = Ln),
4905        (Ji.TouchZoom = Tn),
4906        (Object.freeze = i),
4907        (t.version = "1.5.1+build.2e3e0ffb"),
4908        (t.Control = Qi),
4909        (t.control = $i),
4910        (t.Browser = Bt),
4911        (t.Evented = k),
4912        (t.Mixin = re),
4913        (t.Util = S),
4914        (t.Class = Z),
4915        (t.Handler = oe),
4916        (t.extend = h),
4917        (t.bind = a),
4918        (t.stamp = u),
4919        (t.setOptions = p),
4920        (t.DomEvent = Yi),
4921        (t.DomUtil = Zi),
4922        (t.PosAnimation = Xi),
4923        (t.Draggable = le),
4924        (t.LineUtil = ye),
4925        (t.PolyUtil = Pe),
4926        (t.Point = B),
4927        (t.point = I),
4928        (t.Bounds = O),
4929        (t.bounds = R),
4930        (t.Transformation = G),
4931        (t.transformation = K),
4932        (t.Projection = Te),
4933        (t.LatLng = j),
4934        (t.latLng = W),
4935        (t.LatLngBounds = N),
4936        (t.latLngBounds = D),
4937        (t.CRS = F),
4938        (t.GeoJSON = We),
4939        (t.geoJSON = Xe),
4940        (t.geoJson = Je),
4941        (t.Layer = Se),
4942        (t.LayerGroup = Ze),
4943        (t.layerGroup = function (t, i) {
4944            return new Ze(t, i);
4945        }),
4946        (t.FeatureGroup = Ee),
4947        (t.featureGroup = function (t) {
4948            return new Ee(t);
4949        }),
4950        (t.ImageOverlay = $e),
4951        (t.imageOverlay = function (t, i, e) {
4952            return new $e(t, i, e);
4953        }),
4954        (t.VideoOverlay = Qe),
4955        (t.videoOverlay = function (t, i, e) {
4956            return new Qe(t, i, e);
4957        }),
4958        (t.SVGOverlay = tn),
4959        (t.svgOverlay = function (t, i, e) {
4960            return new tn(t, i, e);
4961        }),
4962        (t.DivOverlay = en),
4963        (t.Popup = nn),
4964        (t.popup = function (t, i) {
4965            return new nn(t, i);
4966        }),
4967        (t.Tooltip = on),
4968        (t.tooltip = function (t, i) {
4969            return new on(t, i);
4970        }),
4971        (t.Icon = ke),
4972        (t.icon = function (t) {
4973            return new ke(t);
4974        }),
4975        (t.DivIcon = sn),
4976        (t.divIcon = function (t) {
4977            return new sn(t);
4978        }),
4979        (t.Marker = Ie),
4980        (t.marker = function (t, i) {
4981            return new Ie(t, i);
4982        }),
4983        (t.TileLayer = an),
4984        (t.tileLayer = hn),
4985        (t.GridLayer = rn),
4986        (t.gridLayer = function (t) {
4987            return new rn(t);
4988        }),
4989        (t.SVG = fn),
4990        (t.svg = gn),
4991        (t.Renderer = ln),
4992        (t.Canvas = cn),
4993        (t.canvas = _n),
4994        (t.Path = Oe),
4995        (t.CircleMarker = Re),
4996        (t.circleMarker = function (t, i) {
4997            return new Re(t, i);
4998        }),
4999        (t.Circle = Ne),
5000        (t.circle = function (t, i, e) {
5001            return new Ne(t, i, e);
5002        }),
5003        (t.Polyline = De),
5004        (t.polyline = function (t, i) {
5005            return new De(t, i);
5006        }),
5007        (t.Polygon = je),
5008        (t.polygon = function (t, i) {
5009            return new je(t, i);
5010        }),
5011        (t.Rectangle = vn),
5012        (t.rectangle = function (t, i) {
5013            return new vn(t, i);
5014        }),
5015        (t.Map = Ji),
5016        (t.map = function (t, i) {
5017            return new Ji(t, i);
5018        });
5019    var zn = window.L;
5020    (t.noConflict = function () {
5021        return (window.L = zn), this;
5022    }),
5023        (window.L = t);
5024});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.