From f97d4c1813ed7ece8a3cba9d0e67952ffd6cdf67 Mon Sep 17 00:00:00 2001 From: Piero Toffanin Date: Fri, 23 Feb 2018 17:48:32 -0500 Subject: [PATCH] Plugin menu entry hook, posm-gcpi plugin skeleton, mount points --- app/plugins/__init__.py | 2 + app/plugins/functions.py | 8 + app/plugins/menu.py | 22 ++ app/plugins/mountpoint.py | 17 + app/plugins/plugin_base.py | 23 +- app/static/app/js/vendor/include.js | 329 ------------------ app/templates/app/logged_in_base.html | 18 +- app/templatetags/plugins.py | 5 + app/tests/test_plugins.py | 22 ++ app/tests/test_worker.py | 2 +- app/urls.py | 8 +- plugins/posm-gcpi/__init__.py | 1 + plugins/posm-gcpi/manifest.json | 13 + plugins/posm-gcpi/plugin.py | 19 + plugins/posm-gcpi/public/asset-manifest.json | 35 ++ plugins/posm-gcpi/public/favicon.ico | Bin 0 -> 1150 bytes plugins/posm-gcpi/public/index.html | 1 + .../public/static/css/main.0b2dd337.css | 4 + .../public/static/css/main.0b2dd337.css.map | 1 + .../public/static/js/main.df429876.js | 19 + .../public/static/js/main.df429876.js.map | 1 + .../public/static/media/add.5a2714f3.png | Bin 0 -> 400 bytes .../public/static/media/add@2x.b53b9f2d.png | Bin 0 -> 630 bytes .../static/media/add_point.e65f1d0c.png | Bin 0 -> 564 bytes .../static/media/add_point@2x.bf317640.png | Bin 0 -> 1003 bytes .../static/media/add_point_green.013c6b67.png | Bin 0 -> 627 bytes .../media/add_point_green@2x.1dd546dd.png | Bin 0 -> 1070 bytes .../media/add_point_yellow.a6d933c3.png | Bin 0 -> 581 bytes .../media/add_point_yellow@2x.5b290820.png | Bin 0 -> 990 bytes .../public/static/media/close.729ab67b.png | Bin 0 -> 482 bytes .../public/static/media/close@2x.c65c9577.png | Bin 0 -> 717 bytes .../static/media/fit_markers.be9754ad.png | Bin 0 -> 569 bytes .../static/media/fit_markers@2x.cf8c8fad.png | Bin 0 -> 985 bytes .../static/media/gcp-green.cfc5c722.png | Bin 0 -> 1116 bytes .../static/media/gcp-yellow.3793065e.png | Bin 0 -> 936 bytes .../public/static/media/gcp.44ed9ab1.png | Bin 0 -> 958 bytes .../static/media/layers-2x.4f0283c6.png | Bin 0 -> 1259 bytes .../public/static/media/layers.a6137456.png | Bin 0 -> 696 bytes .../public/static/media/loading.e56d6770.gif | Bin 0 -> 3965 bytes .../static/media/loading@2x.0ab4b1d1.gif | Bin 0 -> 8162 bytes .../public/static/media/logo.b38a9426.png | Bin 0 -> 3766 bytes .../static/media/marker-icon.2273e3d8.png | Bin 0 -> 1466 bytes .../static/media/point_icon.e206131a.png | Bin 0 -> 298 bytes .../static/media/point_icon@2x.dd1da9a3.png | Bin 0 -> 549 bytes .../static/media/polygon_icon.83cffeed.png | Bin 0 -> 250 bytes .../static/media/polygon_icon@2x.53277be6.png | Bin 0 -> 522 bytes .../static/media/providers.ad5af2f5.png | Bin 0 -> 378 bytes .../static/media/providers@2x.51ed570c.png | Bin 0 -> 626 bytes .../public/static/media/search.470dd7e7.png | Bin 0 -> 268 bytes .../public/static/media/search.57a8b421.png | Bin 0 -> 359 bytes .../static/media/search@2x.37035178.png | Bin 0 -> 524 bytes .../static/media/search@2x.44cf1bbe.png | Bin 0 -> 639 bytes 52 files changed, 213 insertions(+), 337 deletions(-) create mode 100644 app/plugins/menu.py create mode 100644 app/plugins/mountpoint.py delete mode 100644 app/static/app/js/vendor/include.js create mode 100644 app/tests/test_plugins.py create mode 100644 plugins/posm-gcpi/__init__.py create mode 100644 plugins/posm-gcpi/manifest.json create mode 100644 plugins/posm-gcpi/plugin.py create mode 100644 plugins/posm-gcpi/public/asset-manifest.json create mode 100644 plugins/posm-gcpi/public/favicon.ico create mode 100644 plugins/posm-gcpi/public/index.html create mode 100644 plugins/posm-gcpi/public/static/css/main.0b2dd337.css create mode 100644 plugins/posm-gcpi/public/static/css/main.0b2dd337.css.map create mode 100644 plugins/posm-gcpi/public/static/js/main.df429876.js create mode 100644 plugins/posm-gcpi/public/static/js/main.df429876.js.map create mode 100644 plugins/posm-gcpi/public/static/media/add.5a2714f3.png create mode 100644 plugins/posm-gcpi/public/static/media/add@2x.b53b9f2d.png create mode 100644 plugins/posm-gcpi/public/static/media/add_point.e65f1d0c.png create mode 100644 plugins/posm-gcpi/public/static/media/add_point@2x.bf317640.png create mode 100644 plugins/posm-gcpi/public/static/media/add_point_green.013c6b67.png create mode 100644 plugins/posm-gcpi/public/static/media/add_point_green@2x.1dd546dd.png create mode 100644 plugins/posm-gcpi/public/static/media/add_point_yellow.a6d933c3.png create mode 100644 plugins/posm-gcpi/public/static/media/add_point_yellow@2x.5b290820.png create mode 100644 plugins/posm-gcpi/public/static/media/close.729ab67b.png create mode 100644 plugins/posm-gcpi/public/static/media/close@2x.c65c9577.png create mode 100644 plugins/posm-gcpi/public/static/media/fit_markers.be9754ad.png create mode 100644 plugins/posm-gcpi/public/static/media/fit_markers@2x.cf8c8fad.png create mode 100644 plugins/posm-gcpi/public/static/media/gcp-green.cfc5c722.png create mode 100644 plugins/posm-gcpi/public/static/media/gcp-yellow.3793065e.png create mode 100644 plugins/posm-gcpi/public/static/media/gcp.44ed9ab1.png create mode 100644 plugins/posm-gcpi/public/static/media/layers-2x.4f0283c6.png create mode 100644 plugins/posm-gcpi/public/static/media/layers.a6137456.png create mode 100644 plugins/posm-gcpi/public/static/media/loading.e56d6770.gif create mode 100644 plugins/posm-gcpi/public/static/media/loading@2x.0ab4b1d1.gif create mode 100644 plugins/posm-gcpi/public/static/media/logo.b38a9426.png create mode 100644 plugins/posm-gcpi/public/static/media/marker-icon.2273e3d8.png create mode 100644 plugins/posm-gcpi/public/static/media/point_icon.e206131a.png create mode 100644 plugins/posm-gcpi/public/static/media/point_icon@2x.dd1da9a3.png create mode 100644 plugins/posm-gcpi/public/static/media/polygon_icon.83cffeed.png create mode 100644 plugins/posm-gcpi/public/static/media/polygon_icon@2x.53277be6.png create mode 100644 plugins/posm-gcpi/public/static/media/providers.ad5af2f5.png create mode 100644 plugins/posm-gcpi/public/static/media/providers@2x.51ed570c.png create mode 100644 plugins/posm-gcpi/public/static/media/search.470dd7e7.png create mode 100644 plugins/posm-gcpi/public/static/media/search.57a8b421.png create mode 100644 plugins/posm-gcpi/public/static/media/search@2x.37035178.png create mode 100644 plugins/posm-gcpi/public/static/media/search@2x.44cf1bbe.png diff --git a/app/plugins/__init__.py b/app/plugins/__init__.py index efb3d8fc..d0ccccbe 100644 --- a/app/plugins/__init__.py +++ b/app/plugins/__init__.py @@ -1,2 +1,4 @@ from .plugin_base import PluginBase +from .menu import Menu +from .mountpoint import MountPoint from .functions import * diff --git a/app/plugins/functions.py b/app/plugins/functions.py index 47097c28..f9a7027a 100644 --- a/app/plugins/functions.py +++ b/app/plugins/functions.py @@ -23,10 +23,18 @@ def get_url_patterns(): """ url_patterns = [] for plugin in get_active_plugins(): + for mount_point in plugin.mount_points(): + url_patterns.append(url('^plugins/{}/{}'.format(plugin.get_name(), mount_point.url), + mount_point.view, + *mount_point.args, + **mount_point.kwargs)) + if plugin.has_public_path(): url_patterns.append(url('^plugins/{}/(.*)'.format(plugin.get_name()), django.views.static.serve, {'document_root': plugin.get_path("public")})) + + return url_patterns plugins = None diff --git a/app/plugins/menu.py b/app/plugins/menu.py new file mode 100644 index 00000000..25d36cf9 --- /dev/null +++ b/app/plugins/menu.py @@ -0,0 +1,22 @@ +class Menu: + def __init__(self, label, link = "javascript:void(0)", css_icon = 'fa fa-caret-right fa-fw', submenu = []): + """ + Create a menu + :param label: text shown in entry + :param css_icon: class used for showing an icon (for example, "fa fa-wrench") + :param link: link of entry (use "#" or "javascript:void(0);" for no action) + :param submenu: list of Menu items + """ + super().__init__() + + self.label = label + self.css_icon = css_icon + self.link = link + self.submenu = submenu + + if (self.has_submenu()): + self.link = "#" + + + def has_submenu(self): + return len(self.submenu) > 0 diff --git a/app/plugins/mountpoint.py b/app/plugins/mountpoint.py new file mode 100644 index 00000000..71823c34 --- /dev/null +++ b/app/plugins/mountpoint.py @@ -0,0 +1,17 @@ +import re + +class MountPoint: + def __init__(self, url, view, *args, **kwargs): + """ + + :param url: path to mount this view to, relative to plugins directory + :param view: Django view + :param args: extra args to pass to url() + :param kwargs: extra kwargs to pass to url() + """ + super().__init__() + + self.url = re.sub(r'^/+', '', url) # remove leading slashes + self.view = view + self.args = args + self.kwargs = kwargs diff --git a/app/plugins/plugin_base.py b/app/plugins/plugin_base.py index de562a3e..840084c4 100644 --- a/app/plugins/plugin_base.py +++ b/app/plugins/plugin_base.py @@ -24,10 +24,13 @@ class PluginBase(ABC): return self.__class__.__module__ def get_include_js_urls(self): - return ["/plugins/{}/{}".format(self.get_name(), js_file) for js_file in self.include_js_files()] + return [self.url(js_file) for js_file in self.include_js_files()] def get_include_css_urls(self): - return ["/plugins/{}/{}".format(self.get_name(), css_file) for css_file in self.include_css_files()] + return [self.url(css_file) for css_file in self.include_css_files()] + + def url(self, path): + return "/plugins/{}/{}".format(self.get_name(), path) def has_public_path(self): return os.path.isdir(self.get_path("public")) @@ -48,5 +51,21 @@ class PluginBase(ABC): """ return [] + def main_menu(self): + """ + Should be overriden by plugins that want to add + items to the side menu. + :return: [] of Menu objects + """ + return [] + + def mount_points(self): + """ + Should be overriden by plugins that want to connect + custom Django views + :return: [] of MountPoint objects + """ + return [] + def __str__(self): return "[{}]".format(self.get_module_name()) \ No newline at end of file diff --git a/app/static/app/js/vendor/include.js b/app/static/app/js/vendor/include.js deleted file mode 100644 index 6804d2b4..00000000 --- a/app/static/app/js/vendor/include.js +++ /dev/null @@ -1,329 +0,0 @@ -const env = {}; -(function (environment) { - - /** - * List of existings modules - * @type {Object} - */ - var modules = {}; - - /** - * Array of waiting modules - * @type {Array} - */ - var waitingModules = []; - - /** - * Count created script for control - * @type {Number} - */ - var scriptCounter = 1; - - /** - * Base element check for IE 6-8 - * @type {Node} - */ - var baseElement = document.getElementsByTagName('base')[0]; - - /** - * Head element - * @type {Node} - */ - var head = document.getElementsByTagName('head')[0]; - - /** - * @param {String} name the name of the module - * @param {Array} deps dependencies of the module - * @param {Function} module module definition - * @param {String} dir relative dir path from which to load files - */ - function Include (name, deps, module, dir) { - var self = this; - - if (typeof name !== "string") { - module = deps; - deps = name; - name = null; - } - - if (deps.constructor !== [].constructor) { - module = deps; - deps = []; - } - - waitingModules.unshift([name, deps, module]); - - /** - * Uid for script differentiation - * @type {String} - */ - self.uid = Math.random().toString(36).replace(/[^a-z0-9]+/g, '').substr(0, 10); - - self.checkModuleLoaded(); - - if (deps.length) { - self.each(deps, self.parseFiles); - } - }; - - /** - * Loop trougth an array of element with the given function - * @param {Array|NodeList} array array to loop - * @param {Function} callback function to execute with each element - */ - Include.prototype.each = function (array, callback) { - var self = this, - i; - - for (i = 0; i < array.length; i++) { - if (array[i] !== undefined && callback.call(self, array[i], i, array) === false) { - break; - } - } - } - - /** - * Get element data id - * @param {String} name - * @param {Boolean} clean only clean the name - * @return {String} - */ - Include.prototype.getId = function (name, clean) { - return (clean ? '' : this.uid + '-') + name.replace(/[^a-z0-9]+/g, ''); - } - - /** - * Check if a module is loaded - */ - Include.prototype.checkModuleLoaded = function () { - var self = this; - - self.each(waitingModules, function (module, i) { - var name = module[0], - dependencies = module[1], - exec = module[2], - args = []; - - self.each(dependencies, function (dependencie, n, t) { - n = dependencie.push ? dependencie[0] : dependencie; - t = document.querySelector('[data-id*="' + self.getId(n, 1) + '"]'); - - if (t && t.nodeName == "LINK") { - args.push(null); - return; - } - - if (modules[n] !== undefined) { - args.push(modules[n]); - } - }); - - if (dependencies.length === args.length || dependencies.length === 0) { - if (name === null && i+1 === waitingModules.length) { - waitingModules = []; - scriptCounter = 1; - } - - exec = typeof exec == 'function' ? exec.apply(this, args) : exec; - modules[name] = exec; - } - }); - } - - /** - * onModuleLoaded - * @param {String} name name of the module - * @param {Number} index index of the module - */ - Include.prototype.onModuleLoaded = function (name, index) { - var self = this; - - // Is this script add a waiting module ? If not, that's a "normal" script file - if (index > waitingModules.length) { - scriptCounter--; - modules[name] = modules[name] || scriptCounter; - } else if (waitingModules[0][0] === null) { - waitingModules[0][0] = name; - } - - self.checkModuleLoaded(); - } - - /** - * On Load event - * @param {Event} event event of the load - * @param {Function} caller - */ - Include.prototype.onLoad = function (event, caller) { - var self = this, - target = (event.currentTarget || event.srcElement); - - //Check if the script is realy loaded and executed - if (event.type !== "load" && target.readyState != "complete") { - return; - } - - target.setAttribute('data-loaded', true); - self.onModuleLoaded(target.getAttribute('data-module'), target.getAttribute('data-count')); - - // Old browser need to use the detachEvent method - if (target.attachEvent) { - target.detachEvent('onreadystatechange', caller); - } else { - target.removeEventListener('load', caller); - } - } - - /** - * Watch for css load - * @param {Element} elem elem to check loading - */ - Include.prototype.watchCss = function (elem) { - var self = this, - sheets = document.styleSheets, - i = sheets.length, - href = elem.href.split('//').pop(); - - // loop on document stylesheets to check if media is loaded - while (i--) { - if (sheets[i].href.indexOf(href) != -1) { - elem.setAttribute('data-loaded', true); - self.onModuleLoaded(elem.getAttribute('data-module'), elem.getAttribute('data-count')); - return; - } - } - - setTimeout(function () { - self.watchCss.call(self, elem); - }); - } - - /** - * Attach events to an element - * @param {Element} elem elem to attach event - * @param {Boolean} isJs is elem a script - */ - Include.prototype.attachEvents = function (elem, isJs) { - var self = this, - cb = function () { - var args = Array.prototype.slice.call(arguments); - args.push(cb); - - self.onLoad.apply(self, args); - }; - - - if (isJs) { - if (elem.attachEvent) { - elem.attachEvent('onreadystatechange', cb); - } else { - elem.addEventListener('load', cb, true); - } - } else { - self.watchCss(elem); - } - } - - /** - * Check if a script already load - * @param {String} moduleName module to load - * @param {String} isJs type of file - */ - Include.prototype.checkExists = function (moduleName, isJs) { - var exists = false; - - this.each(document.getElementsByTagName(isJs ? 'script' : 'link'), function (elem) { - if (elem.getAttribute('data-module') && elem.getAttribute('data-module') === moduleName) { - exists = elem; - return false; - } - }); - - return exists; - } - - /** - * Create a script element to load asked module - * @param {String} moduleName name of the module - * @param {String} moduleFile file to include - * @param {String} isJs type of file - */ - Include.prototype.create = function (moduleName, moduleFile, isJs) { - var self = this; - - //SetTimeout prevent the element create browser rush - setTimeout(function(){ - var elem = self.checkExists.call(self, moduleName, isJs); - - if (elem) { - return; - } - - scriptCounter++; - - elem = document.createElement(isJs ? 'script' : 'link'); - - if (isJs) { - elem.async = true; - elem.type = "text/javascript"; - elem.src = moduleFile; - } else { - elem.media = "all"; - elem.href = moduleFile; - elem.rel = "stylesheet" - } - - elem.setAttribute('data-id', self.getId(moduleName)); - elem.setAttribute('data-module', moduleName); - elem.setAttribute('data-count', scriptCounter); - elem.setAttribute('data-loaded', false); - - if (baseElement) { - //prevent IE 6-8 bug (script executed before appenchild execution. - baseElement.parentNode.insertBefore(elem, baseElement); - } else { - head.appendChild(elem); - } - - self.attachEvents.call(self, elem, isJs); - }, 0); - } - - /** - * Parse a file to include - * @param {String} file file to parse - */ - Include.prototype.parseFiles = function (file) { - var moduleName = file.push ? file[0] : file, - moduleFile = file.push ? file[1] : file, - ext; - - //Don't load module already loaded - if (modules[moduleName]) { - this.checkModuleLoaded(); - return; - } - - - if (moduleFile.indexOf('//') == -1 && !/\.js/.test(moduleFile) && !/^http/.test(moduleFile)) { - moduleFile = moduleFile.replace(/\./g, '/'); - moduleFile = moduleFile + '.js'; - } - - ext = moduleFile.split('.').pop() == 'js'; - - this.create.call(this, moduleName, moduleFile, ext); - } - - /** - * @param {String} name the name of the module - * @param {Array} deps dependencies of the module - * @param {Function} module module definition - */ - environment['include'] = environment['require'] = environment['define'] = function (name, deps, module) { - return new Include(name, deps, module); - }; - -})(env); - -export default env; diff --git a/app/templates/app/logged_in_base.html b/app/templates/app/logged_in_base.html index bd1f5b21..fcfc5a6e 100644 --- a/app/templates/app/logged_in_base.html +++ b/app/templates/app/logged_in_base.html @@ -226,11 +226,27 @@ - {% load processingnode_extras %} + {% load processingnode_extras plugins %} {% can_view_processing_nodes as view_nodes %} {% can_add_processing_nodes as add_nodes %} {% get_visible_processing_nodes as nodes %} + {% get_plugins_main_menus as plugin_menus %} + {% for menu in plugin_menus %} +
  • + {{menu.label}}{% if menu.has_submenu %}{% endif %} + + {% if menu.has_submenu %} + + {% endif %} +
  • + {% endfor %} {% if view_nodes %}
  • diff --git a/app/templatetags/plugins.py b/app/templatetags/plugins.py index 23ca9b0b..804f4765 100644 --- a/app/templatetags/plugins.py +++ b/app/templatetags/plugins.py @@ -15,3 +15,8 @@ def get_plugins_css_includes(): # Flatten all urls for all plugins css_urls = list(itertools.chain(*[plugin.get_include_css_urls() for plugin in get_active_plugins()])) return "\n".join(map(lambda url: "".format(url), css_urls)) + +@register.assignment_tag() +def get_plugins_main_menus(): + # Flatten list of menus + return list(itertools.chain(*[plugin.main_menu() for plugin in get_active_plugins()])) diff --git a/app/tests/test_plugins.py b/app/tests/test_plugins.py new file mode 100644 index 00000000..378b16a0 --- /dev/null +++ b/app/tests/test_plugins.py @@ -0,0 +1,22 @@ +from django.test import Client +from rest_framework import status + +from .classes import BootTestCase + +class TestPlugins(BootTestCase): + def setUp(self): + pass + + def tearDown(self): + pass + + def test_core_plugins(self): + client = Client() + + # We can access public files core plugins (without auth) + res = client.get('/plugins/measure/leaflet-measure.css') + self.assertEqual(res.status_code, status.HTTP_200_OK) + + # TODO: + # test API endpoints + # test python hooks diff --git a/app/tests/test_worker.py b/app/tests/test_worker.py index b8340cef..bca674e9 100644 --- a/app/tests/test_worker.py +++ b/app/tests/test_worker.py @@ -6,7 +6,7 @@ from nodeodm.models import ProcessingNode from .classes import BootTestCase from .utils import start_processing_node -class TestWelcome(BootTestCase): +class TestWorker(BootTestCase): def setUp(self): super().setUp() diff --git a/app/urls.py b/app/urls.py index de02963b..4f759d9a 100644 --- a/app/urls.py +++ b/app/urls.py @@ -16,10 +16,10 @@ urlpatterns = [ url(r'^3d/project/(?P[^/.]+)/task/(?P[^/.]+)/$', app_views.model_display, name='model_display'), url(r'^public/task/(?P[^/.]+)/map/$', public_views.map, name='public_map'), - url(r'^public/task/(?P[^/.]+)/iframe/map/$', public_views.map_iframe, name='public_map'), - url(r'^public/task/(?P[^/.]+)/3d/$', public_views.model_display, name='public_map'), - url(r'^public/task/(?P[^/.]+)/iframe/3d/$', public_views.model_display_iframe, name='public_map'), - url(r'^public/task/(?P[^/.]+)/json/$', public_views.task_json, name='public_map'), + url(r'^public/task/(?P[^/.]+)/iframe/map/$', public_views.map_iframe, name='public_iframe_map'), + url(r'^public/task/(?P[^/.]+)/3d/$', public_views.model_display, name='public_3d'), + url(r'^public/task/(?P[^/.]+)/iframe/3d/$', public_views.model_display_iframe, name='public_iframe_3d'), + url(r'^public/task/(?P[^/.]+)/json/$', public_views.task_json, name='public_json'), url(r'^processingnode/([\d]+)/$', app_views.processing_node, name='processing_node'), diff --git a/plugins/posm-gcpi/__init__.py b/plugins/posm-gcpi/__init__.py new file mode 100644 index 00000000..48aad58e --- /dev/null +++ b/plugins/posm-gcpi/__init__.py @@ -0,0 +1 @@ +from .plugin import * diff --git a/plugins/posm-gcpi/manifest.json b/plugins/posm-gcpi/manifest.json new file mode 100644 index 00000000..6382d533 --- /dev/null +++ b/plugins/posm-gcpi/manifest.json @@ -0,0 +1,13 @@ +{ + "name": "POSM GCP Interface", + "webodmMinVersion": "0.5.0", + "description": "A plugin to create GCP files from images", + "version": "0.1.0", + "author": "Piero Toffanin", + "email": "pt@masseranolabs.com", + "repository": "https://github.com/OpenDroneMap/WebODM", + "tags": ["gcp", "posm"], + "homepage": "https://github.com/OpenDroneMap/WebODM", + "experimental": true, + "deprecated": false +} \ No newline at end of file diff --git a/plugins/posm-gcpi/plugin.py b/plugins/posm-gcpi/plugin.py new file mode 100644 index 00000000..2b4eb7e6 --- /dev/null +++ b/plugins/posm-gcpi/plugin.py @@ -0,0 +1,19 @@ +from app.plugins import PluginBase, Menu, MountPoint +from django.shortcuts import render + +class Plugin(PluginBase): + + def register(self): + pass + + def main_menu(self): + return [Menu("GCP Editor", self.url("index.html"), "fa fa-map-marker fa-fw")] + + def mount_points(self): + return [ + MountPoint("/test", test) + ] + + +def test(request): + return render(request, 'app/dashboard.html', {'title': 'PLUGIN!!'}) \ No newline at end of file diff --git a/plugins/posm-gcpi/public/asset-manifest.json b/plugins/posm-gcpi/public/asset-manifest.json new file mode 100644 index 00000000..1c97b4bb --- /dev/null +++ b/plugins/posm-gcpi/public/asset-manifest.json @@ -0,0 +1,35 @@ +{ + "main.css": "static/css/main.0b2dd337.css", + "main.css.map": "static/css/main.0b2dd337.css.map", + "main.js": "static/js/main.df429876.js", + "main.js.map": "static/js/main.df429876.js.map", + "static/media/add.png": "static/media/add.5a2714f3.png", + "static/media/add@2x.png": "static/media/add@2x.b53b9f2d.png", + "static/media/add_point.png": "static/media/add_point.e65f1d0c.png", + "static/media/add_point@2x.png": "static/media/add_point@2x.bf317640.png", + "static/media/add_point_green.png": "static/media/add_point_green.013c6b67.png", + "static/media/add_point_green@2x.png": "static/media/add_point_green@2x.1dd546dd.png", + "static/media/add_point_yellow.png": "static/media/add_point_yellow.a6d933c3.png", + "static/media/add_point_yellow@2x.png": "static/media/add_point_yellow@2x.5b290820.png", + "static/media/close.png": "static/media/close.729ab67b.png", + "static/media/close@2x.png": "static/media/close@2x.c65c9577.png", + "static/media/fit_markers.png": "static/media/fit_markers.be9754ad.png", + "static/media/fit_markers@2x.png": "static/media/fit_markers@2x.cf8c8fad.png", + "static/media/gcp-green.png": "static/media/gcp-green.cfc5c722.png", + "static/media/gcp-yellow.png": "static/media/gcp-yellow.3793065e.png", + "static/media/gcp.png": "static/media/gcp.44ed9ab1.png", + "static/media/layers-2x.png": "static/media/layers-2x.4f0283c6.png", + "static/media/layers.png": "static/media/layers.a6137456.png", + "static/media/loading.gif": "static/media/loading.e56d6770.gif", + "static/media/loading@2x.gif": "static/media/loading@2x.0ab4b1d1.gif", + "static/media/logo.png": "static/media/logo.b38a9426.png", + "static/media/marker-icon.png": "static/media/marker-icon.2273e3d8.png", + "static/media/point_icon.png": "static/media/point_icon.e206131a.png", + "static/media/point_icon@2x.png": "static/media/point_icon@2x.dd1da9a3.png", + "static/media/polygon_icon.png": "static/media/polygon_icon.83cffeed.png", + "static/media/polygon_icon@2x.png": "static/media/polygon_icon@2x.53277be6.png", + "static/media/providers.png": "static/media/providers.ad5af2f5.png", + "static/media/providers@2x.png": "static/media/providers@2x.51ed570c.png", + "static/media/search.png": "static/media/search.57a8b421.png", + "static/media/search@2x.png": "static/media/search@2x.44cf1bbe.png" +} \ No newline at end of file diff --git a/plugins/posm-gcpi/public/favicon.ico b/plugins/posm-gcpi/public/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..a6860cc861ec2ece79809965506f56c110dea451 GIT binary patch literal 1150 zcmbtSUr5tY6#gwW(LJP@y#$hIHHA{5jfD@1#E1o&k|2t+mu!tmNQg=ZO;R#zD zFHMqsXo5J%mrWBkADr%wYv7}avD(8Pg#G=x_pCd%{ycSl{O&#XJNG;HyXPKBlCiI( zL}KGvNuMuCrzJ^Ju%AH;N#ksiBo;d8g^dWkzdI!sT$ z!tCrDd^1n-J`0il5+9{LWAH20=t-;d`7v4 zhXLswS^@r#O%V{Gh6&iSHt%gf7HSxMh75C|X=iNNdipuGGPapm$t zn%moNBN~lna>V0t@-3Ek^xm{!!{(+7I$bxbnGMy|m5|9KR8*Y7=%@+bv-&{r&E^-B zU!gdM`udCH*VSF3bX<$u?WWrBH}!hGg!38*eqWyvyuNaIF`dQVU8TB0{VMJl3s70jnSI=8X>NvAtHtiFKZA?RG?v&oCFQ ed2P7~?c9&WVwqa-_1}!Y+y4H3&OWB|zw9Rw&?!Cu literal 0 HcmV?d00001 diff --git a/plugins/posm-gcpi/public/index.html b/plugins/posm-gcpi/public/index.html new file mode 100644 index 00000000..3e34545a --- /dev/null +++ b/plugins/posm-gcpi/public/index.html @@ -0,0 +1 @@ +GCPi
    \ No newline at end of file diff --git a/plugins/posm-gcpi/public/static/css/main.0b2dd337.css b/plugins/posm-gcpi/public/static/css/main.0b2dd337.css new file mode 100644 index 00000000..6fec173f --- /dev/null +++ b/plugins/posm-gcpi/public/static/css/main.0b2dd337.css @@ -0,0 +1,4 @@ +/*! ace.css | https://github.com/basscss/ace | MIT License */*{box-sizing:border-box}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Helvetica,sans-serif;line-height:1.5;margin:0;color:#111;background-color:#fff}img{max-width:100%;height:auto}svg{max-height:100%}a{color:#07c}h1,h2,h3,h4,h5,h6{font-weight:600;line-height:1.25;margin-top:1em;margin-bottom:.5em}h1{font-size:2rem}h2{font-size:1.5rem}h3{font-size:1.25rem}h4{font-size:1rem}h5{font-size:.875rem}h6{font-size:.75rem}blockquote,dl,ol,p,pre,ul{margin-top:1em;margin-bottom:1em}code,pre,samp{font-family:Roboto Mono,Source Code Pro,Menlo,Consolas,Liberation Mono,monospace}code,samp{padding:.125em}code,pre,samp{font-size:87.5%}pre{overflow:scroll}blockquote{font-size:1.25rem;font-style:italic;margin-left:0}hr{margin-top:1.5em;margin-bottom:1.5em;border:0;border-bottom-width:1px;border-bottom-style:solid;border-bottom-color:#ccc}.label{font-size:.875rem;font-weight:700;display:block;margin-bottom:.5rem}.input,.select{height:2.5rem}.input,.select,.textarea{font-family:inherit;font-size:inherit;display:block;width:100%;padding:.5rem;margin-bottom:1rem;border:1px solid #ccc;border-radius:3px;box-sizing:border-box}.input-range{vertical-align:middle;padding-top:.5rem;padding-bottom:.5rem;color:inherit;background-color:transparent;-webkit-appearance:none}.input-range::-webkit-slider-thumb{position:relative;width:.5rem;height:1.25rem;cursor:pointer;margin-top:-.5rem;border-radius:3px;background-color:currentcolor;-webkit-appearance:none}.input-range::-webkit-slider-thumb:before{content:"";display:block;position:absolute;top:-.5rem;left:-.875rem;width:2.25rem;height:2.25rem;opacity:0}.input-range::-moz-range-thumb{width:.5rem;height:1.25rem;cursor:pointer;border-radius:3px;border-color:transparent;border-width:0;background-color:currentcolor}.input-range::-webkit-slider-runnable-track{height:.25rem;cursor:pointer;border-radius:3px;background-color:rgba(0,0,0,.25)}.input-range::-moz-range-track{height:.25rem;cursor:pointer;border-radius:3px;background-color:rgba(0,0,0,.25)}.input-range:focus{outline:none}.progress{display:block;width:100%;height:.5625rem;margin:.5rem 0;overflow:hidden;background-color:rgba(0,0,0,.125);border:0;border-radius:10000px;-webkit-appearance:none}.progress::-webkit-progress-bar{-webkit-appearance:none;background-color:rgba(0,0,0,.125)}.progress::-webkit-progress-value{-webkit-appearance:none;background-color:currentcolor}.progress::-moz-progress-bar{background-color:currentcolor}.btn{font-family:inherit;font-size:inherit;font-weight:700;cursor:pointer;display:inline-block;line-height:1.125rem;padding:.5rem 1rem;margin:0;height:auto;border:1px solid transparent;vertical-align:middle;-webkit-appearance:none;color:inherit;background-color:transparent}.btn,.btn:hover{text-decoration:none}.btn:focus{outline:none;border-color:rgba(0,0,0,.125);box-shadow:0 0 0 3px rgba(0,0,0,.25)}::-moz-focus-inner{border:0;padding:0}.btn-small{padding:.25rem .5rem}.btn-big{padding:1rem 1.25rem}.btn-narrow{padding-left:.5rem;padding-right:.5rem}.btn-primary{color:#fff;background-color:#0074d9;border-radius:3px}.btn-primary:hover{box-shadow:inset 0 0 0 20rem rgba(0,0,0,.0625)}.btn-primary:active{box-shadow:inset 0 0 0 20rem rgba(0,0,0,.125),inset 0 3px 4px 0 rgba(0,0,0,.25),0 0 1px rgba(0,0,0,.125)}.btn-primary.is-disabled,.btn-primary:disabled{opacity:.5}.btn-outline,.btn-outline:hover{border-color:currentcolor}.btn-outline{border-radius:3px}.btn-outline:hover{box-shadow:inset 0 0 0 20rem rgba(0,0,0,.0625)}.btn-outline:active{box-shadow:inset 0 0 0 20rem rgba(0,0,0,.125),inset 0 3px 4px 0 rgba(0,0,0,.25),0 0 1px rgba(0,0,0,.125)}.btn-outline.is-disabled,.btn-outline:disabled{opacity:.5}.lg-media,.md-media,.media,.sm-media{margin-left:-.5rem;margin-right:-.5rem}.media{display:-webkit-box;display:-ms-flexbox;display:flex}.media-center{-webkit-box-align:center;-ms-flex-align:center;-ms-grid-row-align:center;align-items:center}.media-bottom{-webkit-box-align:end;-ms-flex-align:end;-ms-grid-row-align:flex-end;align-items:flex-end}.media-body,.media-img{padding-left:.5rem;padding-right:.5rem}.media-body{-webkit-box-flex:1;-ms-flex:1 1 auto;flex:1 1 auto} + +/*! Basscss | http://basscss.com | MIT License */.h1{font-size:2rem}.h2{font-size:1.5rem}.h3{font-size:1.25rem}.h4{font-size:1rem}.h5{font-size:.875rem}.h6{font-size:.75rem}.font-family-inherit{font-family:inherit}.font-size-inherit{font-size:inherit}.text-decoration-none{text-decoration:none}.bold{font-weight:700}.regular{font-weight:400}.italic{font-style:italic}.caps{text-transform:uppercase;letter-spacing:.2em}.left-align{text-align:left}.center{text-align:center}.right-align{text-align:right}.justify{text-align:justify}.nowrap{white-space:nowrap}.break-word{word-wrap:break-word}.line-height-1{line-height:1}.line-height-2{line-height:1.125}.line-height-3{line-height:1.25}.line-height-4{line-height:1.5}.list-style-none{list-style:none}.underline{text-decoration:underline}.truncate{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.list-reset{list-style:none;padding-left:0}.inline{display:inline}.block{display:block}.inline-block{display:inline-block}.table{display:table}.table-cell{display:table-cell}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.overflow-auto{overflow:auto}.clearfix:after,.clearfix:before{content:" ";display:table}.clearfix:after{clear:both}.left{float:left}.right{float:right}.fit{max-width:100%}.max-width-1{max-width:24rem}.max-width-2{max-width:32rem}.max-width-3{max-width:48rem}.max-width-4{max-width:64rem}.border-box{box-sizing:border-box}.align-baseline{vertical-align:baseline}.align-top{vertical-align:top}.align-middle{vertical-align:middle}.align-bottom{vertical-align:bottom}.m0{margin:0}.mt0{margin-top:0}.mr0{margin-right:0}.mb0{margin-bottom:0}.ml0,.mx0{margin-left:0}.mx0{margin-right:0}.my0{margin-top:0;margin-bottom:0}.m1{margin:.5rem}.mt1{margin-top:.5rem}.mr1{margin-right:.5rem}.mb1{margin-bottom:.5rem}.ml1,.mx1{margin-left:.5rem}.mx1{margin-right:.5rem}.my1{margin-top:.5rem;margin-bottom:.5rem}.m2{margin:1rem}.mt2{margin-top:1rem}.mr2{margin-right:1rem}.mb2{margin-bottom:1rem}.ml2,.mx2{margin-left:1rem}.mx2{margin-right:1rem}.my2{margin-top:1rem;margin-bottom:1rem}.m3{margin:2rem}.mt3{margin-top:2rem}.mr3{margin-right:2rem}.mb3{margin-bottom:2rem}.ml3,.mx3{margin-left:2rem}.mx3{margin-right:2rem}.my3{margin-top:2rem;margin-bottom:2rem}.m4{margin:4rem}.mt4{margin-top:4rem}.mr4{margin-right:4rem}.mb4{margin-bottom:4rem}.ml4,.mx4{margin-left:4rem}.mx4{margin-right:4rem}.my4{margin-top:4rem;margin-bottom:4rem}.mxn1{margin-left:-.5rem;margin-right:-.5rem}.mxn2{margin-left:-1rem;margin-right:-1rem}.mxn3{margin-left:-2rem;margin-right:-2rem}.mxn4{margin-left:-4rem;margin-right:-4rem}.ml-auto{margin-left:auto}.mr-auto,.mx-auto{margin-right:auto}.mx-auto{margin-left:auto}.p0{padding:0}.pt0{padding-top:0}.pr0{padding-right:0}.pb0{padding-bottom:0}.pl0,.px0{padding-left:0}.px0{padding-right:0}.py0{padding-top:0;padding-bottom:0}.p1{padding:.5rem}.pt1{padding-top:.5rem}.pr1{padding-right:.5rem}.pb1{padding-bottom:.5rem}.pl1{padding-left:.5rem}.py1{padding-top:.5rem;padding-bottom:.5rem}.px1{padding-left:.5rem;padding-right:.5rem}.p2{padding:1rem}.pt2{padding-top:1rem}.pr2{padding-right:1rem}.pb2{padding-bottom:1rem}.pl2{padding-left:1rem}.py2{padding-top:1rem;padding-bottom:1rem}.px2{padding-left:1rem;padding-right:1rem}.p3{padding:2rem}.pt3{padding-top:2rem}.pr3{padding-right:2rem}.pb3{padding-bottom:2rem}.pl3{padding-left:2rem}.py3{padding-top:2rem;padding-bottom:2rem}.px3{padding-left:2rem;padding-right:2rem}.p4{padding:4rem}.pt4{padding-top:4rem}.pr4{padding-right:4rem}.pb4{padding-bottom:4rem}.pl4{padding-left:4rem}.py4{padding-top:4rem;padding-bottom:4rem}.px4{padding-left:4rem;padding-right:4rem}.col{float:left}.col,.col-right{box-sizing:border-box}.col-right{float:right}.col-1{width:8.33333%}.col-2{width:16.66667%}.col-3{width:25%}.col-4{width:33.33333%}.col-5{width:41.66667%}.col-6{width:50%}.col-7{width:58.33333%}.col-8{width:66.66667%}.col-9{width:75%}.col-10{width:83.33333%}.col-11{width:91.66667%}.col-12{width:100%}.flex{display:-webkit-box;display:-ms-flexbox;display:flex}.flex-column{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column}.flex-wrap{-ms-flex-wrap:wrap;flex-wrap:wrap}.items-start{-webkit-box-align:start;-ms-flex-align:start;-ms-grid-row-align:flex-start;align-items:flex-start}.items-end{-webkit-box-align:end;-ms-flex-align:end;-ms-grid-row-align:flex-end;align-items:flex-end}.items-center{-webkit-box-align:center;-ms-flex-align:center;-ms-grid-row-align:center;align-items:center}.items-baseline{-webkit-box-align:baseline;-ms-flex-align:baseline;-ms-grid-row-align:baseline;align-items:baseline}.items-stretch{-webkit-box-align:stretch;-ms-flex-align:stretch;-ms-grid-row-align:stretch;align-items:stretch}.self-start{-ms-flex-item-align:start;align-self:flex-start}.self-end{-ms-flex-item-align:end;align-self:flex-end}.self-center{-ms-flex-item-align:center;-ms-grid-row-align:center;align-self:center}.self-baseline{-ms-flex-item-align:baseline;align-self:baseline}.self-stretch{-ms-flex-item-align:stretch;-ms-grid-row-align:stretch;align-self:stretch}.justify-start{-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start}.justify-end{-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end}.justify-center{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.justify-between{-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.justify-around{-ms-flex-pack:distribute;justify-content:space-around}.content-start{-ms-flex-line-pack:start;align-content:flex-start}.content-end{-ms-flex-line-pack:end;align-content:flex-end}.content-center{-ms-flex-line-pack:center;align-content:center}.content-between{-ms-flex-line-pack:justify;align-content:space-between}.content-around{-ms-flex-line-pack:distribute;align-content:space-around}.content-stretch{-ms-flex-line-pack:stretch;align-content:stretch}.flex-auto{-webkit-box-flex:1;-ms-flex:1 1 auto;flex:1 1 auto;min-width:0;min-height:0}.flex-none{-webkit-box-flex:0;-ms-flex:none;flex:none}.order-0{-webkit-box-ordinal-group:1;-ms-flex-order:0;order:0}.order-1{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1}.order-2{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2}.order-3{-webkit-box-ordinal-group:4;-ms-flex-order:3;order:3}.order-last{-webkit-box-ordinal-group:100000;-ms-flex-order:99999;order:99999}.relative{position:relative}.absolute{position:absolute}.fixed{position:fixed}.top-0{top:0}.right-0{right:0}.bottom-0{bottom:0}.left-0{left:0}.z1{z-index:1}.z2{z-index:2}.z3{z-index:3}.z4{z-index:4}.border{border-style:solid;border-width:1px}.border-top{border-top-style:solid;border-top-width:1px}.border-right{border-right-style:solid;border-right-width:1px}.border-bottom{border-bottom-style:solid;border-bottom-width:1px}.border-left{border-left-style:solid;border-left-width:1px}.border-none{border:0}.rounded{border-radius:3px}.circle{border-radius:50%}.rounded-top{border-radius:3px 3px 0 0}.rounded-right{border-radius:0 3px 3px 0}.rounded-bottom{border-radius:0 0 3px 3px}.rounded-left{border-radius:3px 0 0 3px}.not-rounded{border-radius:0}.hide{position:absolute!important;height:1px;width:1px;overflow:hidden;clip:rect(1px,1px,1px,1px)}.display-none{display:none!important}.black{color:#111}.gray{color:#aaa}.silver{color:#ddd}.white{color:#fff}.aqua{color:#7fdbff}.blue{color:#0074d9}.navy{color:#001f3f}.teal{color:#39cccc}.green{color:#2ecc40}.olive{color:#3d9970}.lime{color:#01ff70}.yellow{color:#ffdc00}.orange{color:#ff851b}.red{color:#ff4136}.fuchsia{color:#f012be}.purple{color:#b10dc9}.maroon{color:#85144b}.color-inherit{color:inherit}.muted{opacity:.5}.bg-black{background-color:#111}.bg-gray{background-color:#aaa}.bg-silver{background-color:#ddd}.bg-white{background-color:#fff}.bg-aqua{background-color:#7fdbff}.bg-blue{background-color:#0074d9}.bg-navy{background-color:#001f3f}.bg-teal{background-color:#39cccc}.bg-green{background-color:#2ecc40}.bg-olive{background-color:#3d9970}.bg-lime{background-color:#01ff70}.bg-yellow{background-color:#ffdc00}.bg-orange{background-color:#ff851b}.bg-red{background-color:#ff4136}.bg-fuchsia{background-color:#f012be}.bg-purple{background-color:#b10dc9}.bg-maroon{background-color:#85144b}.border-black{border-color:#111}.border-gray{border-color:#aaa}.border-silver{border-color:#ddd}.border-white{border-color:#fff}.border-aqua{border-color:#7fdbff}.border-blue{border-color:#0074d9}.border-navy{border-color:#001f3f}.border-teal{border-color:#39cccc}.border-green{border-color:#2ecc40}.border-olive{border-color:#3d9970}.border-lime{border-color:#01ff70}.border-yellow{border-color:#ffdc00}.border-orange{border-color:#ff851b}.border-red{border-color:#ff4136}.border-fuchsia{border-color:#f012be}.border-purple{border-color:#b10dc9}.border-maroon{border-color:#85144b}.bg-darken-1{background-color:rgba(0,0,0,.0625)}.bg-darken-2{background-color:rgba(0,0,0,.125)}.bg-darken-3{background-color:rgba(0,0,0,.25)}.bg-darken-4{background-color:rgba(0,0,0,.5)}.bg-lighten-1{background-color:hsla(0,0%,100%,.0625)}.bg-lighten-2{background-color:hsla(0,0%,100%,.125)}.bg-lighten-3{background-color:hsla(0,0%,100%,.25)}.bg-lighten-4{background-color:hsla(0,0%,100%,.5)}.bg-cover{background-size:cover}.bg-contain{background-size:contain}.bg-center{background-position:50%}.bg-top{background-position:top}.bg-right{background-position:100%}.bg-bottom{background-position:bottom}.bg-left{background-position:0}.bg-no-repeat{background-repeat:no-repeat}.bg-repeat-x{background-repeat:repeat-x}.bg-repeat-y{background-repeat:repeat-y}.all-initial{all:initial}.all-unset{all:unset}.all-inherit{all:inherit}.all-revert{all:revert}@media (min-width:40em){.sm-media{display:-webkit-box;display:-ms-flexbox;display:flex}.sm-col{float:left;box-sizing:border-box}.sm-col-right{float:right;box-sizing:border-box}.sm-col-1{width:8.33333%}.sm-col-2{width:16.66667%}.sm-col-3{width:25%}.sm-col-4{width:33.33333%}.sm-col-5{width:41.66667%}.sm-col-6{width:50%}.sm-col-7{width:58.33333%}.sm-col-8{width:66.66667%}.sm-col-9{width:75%}.sm-col-10{width:83.33333%}.sm-col-11{width:91.66667%}.sm-col-12{width:100%}.sm-flex{display:-webkit-box;display:-ms-flexbox;display:flex}.sm-m0{margin:0}.sm-mt0{margin-top:0}.sm-mr0{margin-right:0}.sm-mb0{margin-bottom:0}.sm-ml0,.sm-mx0{margin-left:0}.sm-mx0{margin-right:0}.sm-my0{margin-top:0;margin-bottom:0}.sm-m1{margin:.5rem}.sm-mt1{margin-top:.5rem}.sm-mr1{margin-right:.5rem}.sm-mb1{margin-bottom:.5rem}.sm-ml1,.sm-mx1{margin-left:.5rem}.sm-mx1{margin-right:.5rem}.sm-my1{margin-top:.5rem;margin-bottom:.5rem}.sm-m2{margin:1rem}.sm-mt2{margin-top:1rem}.sm-mr2{margin-right:1rem}.sm-mb2{margin-bottom:1rem}.sm-ml2,.sm-mx2{margin-left:1rem}.sm-mx2{margin-right:1rem}.sm-my2{margin-top:1rem;margin-bottom:1rem}.sm-m3{margin:2rem}.sm-mt3{margin-top:2rem}.sm-mr3{margin-right:2rem}.sm-mb3{margin-bottom:2rem}.sm-ml3,.sm-mx3{margin-left:2rem}.sm-mx3{margin-right:2rem}.sm-my3{margin-top:2rem;margin-bottom:2rem}.sm-m4{margin:4rem}.sm-mt4{margin-top:4rem}.sm-mr4{margin-right:4rem}.sm-mb4{margin-bottom:4rem}.sm-ml4,.sm-mx4{margin-left:4rem}.sm-mx4{margin-right:4rem}.sm-my4{margin-top:4rem;margin-bottom:4rem}.sm-mxn1{margin-left:-.5rem;margin-right:-.5rem}.sm-mxn2{margin-left:-1rem;margin-right:-1rem}.sm-mxn3{margin-left:-2rem;margin-right:-2rem}.sm-mxn4{margin-left:-4rem;margin-right:-4rem}.sm-ml-auto{margin-left:auto}.sm-mr-auto,.sm-mx-auto{margin-right:auto}.sm-mx-auto{margin-left:auto}.sm-p0{padding:0}.sm-pt0{padding-top:0}.sm-pr0{padding-right:0}.sm-pb0{padding-bottom:0}.sm-pl0,.sm-px0{padding-left:0}.sm-px0{padding-right:0}.sm-py0{padding-top:0;padding-bottom:0}.sm-p1{padding:.5rem}.sm-pt1{padding-top:.5rem}.sm-pr1{padding-right:.5rem}.sm-pb1{padding-bottom:.5rem}.sm-pl1,.sm-px1{padding-left:.5rem}.sm-px1{padding-right:.5rem}.sm-py1{padding-top:.5rem;padding-bottom:.5rem}.sm-p2{padding:1rem}.sm-pt2{padding-top:1rem}.sm-pr2{padding-right:1rem}.sm-pb2{padding-bottom:1rem}.sm-pl2,.sm-px2{padding-left:1rem}.sm-px2{padding-right:1rem}.sm-py2{padding-top:1rem;padding-bottom:1rem}.sm-p3{padding:2rem}.sm-pt3{padding-top:2rem}.sm-pr3{padding-right:2rem}.sm-pb3{padding-bottom:2rem}.sm-pl3,.sm-px3{padding-left:2rem}.sm-px3{padding-right:2rem}.sm-py3{padding-top:2rem;padding-bottom:2rem}.sm-p4{padding:4rem}.sm-pt4{padding-top:4rem}.sm-pr4{padding-right:4rem}.sm-pb4{padding-bottom:4rem}.sm-pl4,.sm-px4{padding-left:4rem}.sm-px4{padding-right:4rem}.sm-py4{padding-top:4rem;padding-bottom:4rem}.sm-inline{display:inline}.sm-block{display:block}.sm-inline-block{display:inline-block}.sm-table{display:table}.sm-table-cell{display:table-cell}.sm-overflow-hidden{overflow:hidden}.sm-overflow-scroll{overflow:scroll}.sm-overflow-auto{overflow:auto}.sm-left{float:left}.sm-right{float:right}.sm-relative{position:relative}.sm-absolute{position:absolute}.sm-fixed{position:fixed}.sm-top-0{top:0}.sm-right-0{right:0}.sm-bottom-0{bottom:0}.sm-left-0{left:0}.sm-left-align{text-align:left}.sm-center{text-align:center}.sm-right-align{text-align:right}.sm-justify{text-align:justify}.sm-h00{font-size:4rem}.sm-h0{font-size:3rem}.sm-h1{font-size:2rem}.sm-h2{font-size:1.5rem}.sm-h3{font-size:1.25rem}.sm-h4{font-size:1rem}.sm-h5{font-size:.875rem}.sm-h6{font-size:.75rem}}@media (min-width:52em){.md-media{display:-webkit-box;display:-ms-flexbox;display:flex}.md-col{float:left;box-sizing:border-box}.md-col-right{float:right;box-sizing:border-box}.md-col-1{width:8.33333%}.md-col-2{width:16.66667%}.md-col-3{width:25%}.md-col-4{width:33.33333%}.md-col-5{width:41.66667%}.md-col-6{width:50%}.md-col-7{width:58.33333%}.md-col-8{width:66.66667%}.md-col-9{width:75%}.md-col-10{width:83.33333%}.md-col-11{width:91.66667%}.md-col-12{width:100%}.md-flex{display:-webkit-box;display:-ms-flexbox;display:flex}.md-m0{margin:0}.md-mt0{margin-top:0}.md-mr0{margin-right:0}.md-mb0{margin-bottom:0}.md-ml0,.md-mx0{margin-left:0}.md-mx0{margin-right:0}.md-my0{margin-top:0;margin-bottom:0}.md-m1{margin:.5rem}.md-mt1{margin-top:.5rem}.md-mr1{margin-right:.5rem}.md-mb1{margin-bottom:.5rem}.md-ml1,.md-mx1{margin-left:.5rem}.md-mx1{margin-right:.5rem}.md-my1{margin-top:.5rem;margin-bottom:.5rem}.md-m2{margin:1rem}.md-mt2{margin-top:1rem}.md-mr2{margin-right:1rem}.md-mb2{margin-bottom:1rem}.md-ml2,.md-mx2{margin-left:1rem}.md-mx2{margin-right:1rem}.md-my2{margin-top:1rem;margin-bottom:1rem}.md-m3{margin:2rem}.md-mt3{margin-top:2rem}.md-mr3{margin-right:2rem}.md-mb3{margin-bottom:2rem}.md-ml3,.md-mx3{margin-left:2rem}.md-mx3{margin-right:2rem}.md-my3{margin-top:2rem;margin-bottom:2rem}.md-m4{margin:4rem}.md-mt4{margin-top:4rem}.md-mr4{margin-right:4rem}.md-mb4{margin-bottom:4rem}.md-ml4,.md-mx4{margin-left:4rem}.md-mx4{margin-right:4rem}.md-my4{margin-top:4rem;margin-bottom:4rem}.md-mxn1{margin-left:-.5rem;margin-right:-.5rem}.md-mxn2{margin-left:-1rem;margin-right:-1rem}.md-mxn3{margin-left:-2rem;margin-right:-2rem}.md-mxn4{margin-left:-4rem;margin-right:-4rem}.md-ml-auto{margin-left:auto}.md-mr-auto,.md-mx-auto{margin-right:auto}.md-mx-auto{margin-left:auto}.md-p0{padding:0}.md-pt0{padding-top:0}.md-pr0{padding-right:0}.md-pb0{padding-bottom:0}.md-pl0,.md-px0{padding-left:0}.md-px0{padding-right:0}.md-py0{padding-top:0;padding-bottom:0}.md-p1{padding:.5rem}.md-pt1{padding-top:.5rem}.md-pr1{padding-right:.5rem}.md-pb1{padding-bottom:.5rem}.md-pl1,.md-px1{padding-left:.5rem}.md-px1{padding-right:.5rem}.md-py1{padding-top:.5rem;padding-bottom:.5rem}.md-p2{padding:1rem}.md-pt2{padding-top:1rem}.md-pr2{padding-right:1rem}.md-pb2{padding-bottom:1rem}.md-pl2,.md-px2{padding-left:1rem}.md-px2{padding-right:1rem}.md-py2{padding-top:1rem;padding-bottom:1rem}.md-p3{padding:2rem}.md-pt3{padding-top:2rem}.md-pr3{padding-right:2rem}.md-pb3{padding-bottom:2rem}.md-pl3,.md-px3{padding-left:2rem}.md-px3{padding-right:2rem}.md-py3{padding-top:2rem;padding-bottom:2rem}.md-p4{padding:4rem}.md-pt4{padding-top:4rem}.md-pr4{padding-right:4rem}.md-pb4{padding-bottom:4rem}.md-pl4,.md-px4{padding-left:4rem}.md-px4{padding-right:4rem}.md-py4{padding-top:4rem;padding-bottom:4rem}.md-inline{display:inline}.md-block{display:block}.md-inline-block{display:inline-block}.md-table{display:table}.md-table-cell{display:table-cell}.md-overflow-hidden{overflow:hidden}.md-overflow-scroll{overflow:scroll}.md-overflow-auto{overflow:auto}.md-left{float:left}.md-right{float:right}.md-relative{position:relative}.md-absolute{position:absolute}.md-fixed{position:fixed}.md-top-0{top:0}.md-right-0{right:0}.md-bottom-0{bottom:0}.md-left-0{left:0}.md-left-align{text-align:left}.md-center{text-align:center}.md-right-align{text-align:right}.md-justify{text-align:justify}.md-h00{font-size:4rem}.md-h0{font-size:3rem}.md-h1{font-size:2rem}.md-h2{font-size:1.5rem}.md-h3{font-size:1.25rem}.md-h4{font-size:1rem}.md-h5{font-size:.875rem}.md-h6{font-size:.75rem}}@media (min-width:64em){.lg-media{display:-webkit-box;display:-ms-flexbox;display:flex}.lg-col{float:left;box-sizing:border-box}.lg-col-right{float:right;box-sizing:border-box}.lg-col-1{width:8.33333%}.lg-col-2{width:16.66667%}.lg-col-3{width:25%}.lg-col-4{width:33.33333%}.lg-col-5{width:41.66667%}.lg-col-6{width:50%}.lg-col-7{width:58.33333%}.lg-col-8{width:66.66667%}.lg-col-9{width:75%}.lg-col-10{width:83.33333%}.lg-col-11{width:91.66667%}.lg-col-12{width:100%}.lg-flex{display:-webkit-box;display:-ms-flexbox;display:flex}.lg-hide{display:none!important}.lg-m0{margin:0}.lg-mt0{margin-top:0}.lg-mr0{margin-right:0}.lg-mb0{margin-bottom:0}.lg-ml0,.lg-mx0{margin-left:0}.lg-mx0{margin-right:0}.lg-my0{margin-top:0;margin-bottom:0}.lg-m1{margin:.5rem}.lg-mt1{margin-top:.5rem}.lg-mr1{margin-right:.5rem}.lg-mb1{margin-bottom:.5rem}.lg-ml1,.lg-mx1{margin-left:.5rem}.lg-mx1{margin-right:.5rem}.lg-my1{margin-top:.5rem;margin-bottom:.5rem}.lg-m2{margin:1rem}.lg-mt2{margin-top:1rem}.lg-mr2{margin-right:1rem}.lg-mb2{margin-bottom:1rem}.lg-ml2,.lg-mx2{margin-left:1rem}.lg-mx2{margin-right:1rem}.lg-my2{margin-top:1rem;margin-bottom:1rem}.lg-m3{margin:2rem}.lg-mt3{margin-top:2rem}.lg-mr3{margin-right:2rem}.lg-mb3{margin-bottom:2rem}.lg-ml3,.lg-mx3{margin-left:2rem}.lg-mx3{margin-right:2rem}.lg-my3{margin-top:2rem;margin-bottom:2rem}.lg-m4{margin:4rem}.lg-mt4{margin-top:4rem}.lg-mr4{margin-right:4rem}.lg-mb4{margin-bottom:4rem}.lg-ml4,.lg-mx4{margin-left:4rem}.lg-mx4{margin-right:4rem}.lg-my4{margin-top:4rem;margin-bottom:4rem}.lg-mxn1{margin-left:-.5rem;margin-right:-.5rem}.lg-mxn2{margin-left:-1rem;margin-right:-1rem}.lg-mxn3{margin-left:-2rem;margin-right:-2rem}.lg-mxn4{margin-left:-4rem;margin-right:-4rem}.lg-ml-auto{margin-left:auto}.lg-mr-auto,.lg-mx-auto{margin-right:auto}.lg-mx-auto{margin-left:auto}.lg-p0{padding:0}.lg-pt0{padding-top:0}.lg-pr0{padding-right:0}.lg-pb0{padding-bottom:0}.lg-pl0,.lg-px0{padding-left:0}.lg-px0{padding-right:0}.lg-py0{padding-top:0;padding-bottom:0}.lg-p1{padding:.5rem}.lg-pt1{padding-top:.5rem}.lg-pr1{padding-right:.5rem}.lg-pb1{padding-bottom:.5rem}.lg-pl1,.lg-px1{padding-left:.5rem}.lg-px1{padding-right:.5rem}.lg-py1{padding-top:.5rem;padding-bottom:.5rem}.lg-p2{padding:1rem}.lg-pt2{padding-top:1rem}.lg-pr2{padding-right:1rem}.lg-pb2{padding-bottom:1rem}.lg-pl2,.lg-px2{padding-left:1rem}.lg-px2{padding-right:1rem}.lg-py2{padding-top:1rem;padding-bottom:1rem}.lg-p3{padding:2rem}.lg-pt3{padding-top:2rem}.lg-pr3{padding-right:2rem}.lg-pb3{padding-bottom:2rem}.lg-pl3,.lg-px3{padding-left:2rem}.lg-px3{padding-right:2rem}.lg-py3{padding-top:2rem;padding-bottom:2rem}.lg-p4{padding:4rem}.lg-pt4{padding-top:4rem}.lg-pr4{padding-right:4rem}.lg-pb4{padding-bottom:4rem}.lg-pl4,.lg-px4{padding-left:4rem}.lg-px4{padding-right:4rem}.lg-py4{padding-top:4rem;padding-bottom:4rem}.lg-inline{display:inline}.lg-block{display:block}.lg-inline-block{display:inline-block}.lg-table{display:table}.lg-table-cell{display:table-cell}.lg-overflow-hidden{overflow:hidden}.lg-overflow-scroll{overflow:scroll}.lg-overflow-auto{overflow:auto}.lg-left{float:left}.lg-right{float:right}.lg-relative{position:relative}.lg-absolute{position:absolute}.lg-fixed{position:fixed}.lg-top-0{top:0}.lg-right-0{right:0}.lg-bottom-0{bottom:0}.lg-left-0{left:0}.lg-left-align{text-align:left}.lg-center{text-align:center}.lg-right-align{text-align:right}.lg-justify{text-align:justify}.lg-h00{font-size:4rem}.lg-h0{font-size:3rem}.lg-h1{font-size:2rem}.lg-h2{font-size:1.5rem}.lg-h3{font-size:1.25rem}.lg-h4{font-size:1rem}.lg-h5{font-size:.875rem}.lg-h6{font-size:.75rem}}@media (max-width:40em){.xs-hide{display:none!important}}@media (min-width:40em) and (max-width:52em){.sm-hide{display:none!important}}@media (min-width:52em) and (max-width:64em){.md-hide{display:none!important}}.leaflet-image-layer,.leaflet-layer,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-pane,.leaflet-pane>canvas,.leaflet-pane>svg,.leaflet-tile,.leaflet-tile-container,.leaflet-zoom-box{position:absolute;left:0;top:0}.leaflet-container{overflow:hidden}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{width:1600px;height:1600px;-webkit-transform-origin:0 0}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-overlay-pane svg,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer{max-width:none!important;max-height:none!important}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:rgba(51,181,229,.4)}.leaflet-tile{-webkit-filter:inherit;filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{width:0;height:0;box-sizing:border-box;z-index:800}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{position:relative;z-index:800;pointer-events:visiblePainted;pointer-events:auto}.leaflet-bottom,.leaflet-top{position:absolute;z-index:1000;pointer-events:none}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-tile{will-change:opacity}.leaflet-fade-anim .leaflet-popup{opacity:0;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}.leaflet-zoom-anim .leaflet-zoom-animated{will-change:transform;transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1),-webkit-transform .25s cubic-bezier(0,0,.25,1)}.leaflet-pan-anim .leaflet-tile,.leaflet-zoom-anim .leaflet-tile{transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-control,.leaflet-popup-pane{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing}.leaflet-image-layer,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-image-layer.leaflet-interactive,.leaflet-marker-icon.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{background:#ddd;outline:0}.leaflet-container a{color:#0078a8}.leaflet-container a.leaflet-active{outline:2px solid orange}.leaflet-zoom-box{border:2px dotted #38f;background:hsla(0,0%,100%,.5)}.leaflet-container{font:12px/1.5 Helvetica Neue,Arial,Helvetica,sans-serif}.leaflet-bar{box-shadow:0 1px 5px rgba(0,0,0,.65);border-radius:4px}.leaflet-bar a,.leaflet-bar a:hover{background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;display:block;text-align:center;text-decoration:none;color:#000}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50% 50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:none}.leaflet-bar a.leaflet-disabled{cursor:default;background-color:#f4f4f4;color:#bbb}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-left-radius:2px;border-bottom-right-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{font:700 18px Lucida Console,Monaco,monospace;text-indent:1px}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{box-shadow:0 1px 5px rgba(0,0,0,.4);background:#fff;border-radius:5px}.leaflet-control-layers-toggle{background-image:url(/static/media/layers.a6137456.png);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(/static/media/layers-2x.4f0283c6.png);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers-expanded .leaflet-control-layers-toggle,.leaflet-control-layers .leaflet-control-layers-list{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{padding:6px 10px 6px 6px;color:#333;background:#fff}.leaflet-control-layers-scrollbar{overflow-y:scroll;overflow-x:hidden;padding-right:5px}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{display:block}.leaflet-control-layers-separator{height:0;border-top:1px solid #ddd;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(/static/media/marker-icon.2273e3d8.png)}.leaflet-container .leaflet-control-attribution{background:#fff;background:hsla(0,0%,100%,.7);margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{padding:0 5px;color:#333}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover{text-decoration:underline}.leaflet-container .leaflet-control-attribution,.leaflet-container .leaflet-control-scale{font-size:11px}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{border:2px solid #777;border-top:none;line-height:1.1;padding:2px 5px 1px;font-size:11px;white-space:nowrap;overflow:hidden;box-sizing:border-box;background:#fff;background:hsla(0,0%,100%,.5)}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-bar,.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers{box-shadow:none}.leaflet-touch .leaflet-bar,.leaflet-touch .leaflet-control-layers{border:2px solid rgba(0,0,0,.2);background-clip:padding-box}.leaflet-popup{position:absolute;text-align:center;margin-bottom:20px}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:12px}.leaflet-popup-content{margin:13px 19px;line-height:1.4}.leaflet-popup-content p{margin:18px 0}.leaflet-popup-tip-container{width:40px;height:20px;position:absolute;left:50%;margin-left:-20px;overflow:hidden;pointer-events:none}.leaflet-popup-tip{width:17px;height:17px;padding:1px;margin:-10px auto 0;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:#fff;color:#333;box-shadow:0 3px 14px rgba(0,0,0,.4)}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;padding:4px 4px 0 0;border:none;text-align:center;width:18px;height:14px;font:16px/14px Tahoma,Verdana,sans-serif;color:#c3c3c3;text-decoration:none;font-weight:700;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover{color:#999}.leaflet-popup-scrolled{overflow:auto;border-bottom:1px solid #ddd;border-top:1px solid #ddd}.leaflet-oldie .leaflet-popup-content-wrapper{zoom:1}.leaflet-oldie .leaflet-popup-tip{width:24px;margin:0 auto;-ms-filter:"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";filter:progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678,M12=0.70710678,M21=-0.70710678,M22=0.70710678)}.leaflet-oldie .leaflet-popup-tip-container{margin-top:-1px}.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{position:absolute;padding:6px;background-color:#fff;border:1px solid #fff;border-radius:3px;color:#222;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;box-shadow:0 1px 3px rgba(0,0,0,.4)}.leaflet-tooltip.leaflet-clickable{cursor:pointer;pointer-events:auto}.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before,.leaflet-tooltip-top:before{position:absolute;pointer-events:none;border:6px solid transparent;background:transparent;content:""}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{left:50%;margin-left:-6px}.leaflet-tooltip-top:before{bottom:0;margin-bottom:-12px;border-top-color:#fff}.leaflet-tooltip-bottom:before{top:0;margin-top:-12px;margin-left:-6px;border-bottom-color:#fff}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{top:50%;margin-top:-6px}.leaflet-tooltip-left:before{right:0;margin-right:-12px;border-left-color:#fff}.leaflet-tooltip-right:before{left:0;margin-left:-12px;border-right-color:#fff}.leaflet-pelias-input{box-sizing:border-box;position:absolute;left:0;top:0;height:100%;width:100%;border:none;border-radius:4px;padding-left:26px;text-indent:6px;font-size:14px;background-color:transparent;cursor:pointer}.leaflet-pelias-control{width:26px;height:26px;background-color:#fff;transition:width .1s,height .1s;z-index:810;box-sizing:content-box}.leaflet-oldie .leaflet-pelias-control{border:1px solid #999}.leaflet-touch .leaflet-pelias-control{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-pelias-control.leaflet-pelias-expanded{width:280px;height:44px;line-height:32px}.leaflet-touch .leaflet-pelias-input{background-size:30px}.leaflet-pelias-expanded{width:280px;height:44px}.leaflet-pelias-expanded .leaflet-pelias-input{padding-right:30px;padding-top:5px;padding-bottom:5px;line-height:32px}span.leaflet-pelias-layer-icon-container{display:inline-block;width:16px;height:16px;margin-right:5px;vertical-align:text-bottom}.leaflet-pelias-results span.leaflet-pelias-layer-icon-container{margin-right:9px}img.leaflet-pelias-layer-icon{width:16px}.leaflet-pelias-layer-icon{vertical-align:top}.leaflet-pelias-layer-icon-point,.leaflet-pelias-layer-icon-polygon{width:100%;height:100%;display:inline-block;background-repeat:no-repeat;background-position:50%;background-size:contain}.leaflet-pelias-layer-icon-point{background-image:url(/static/media/point_icon.e206131a.png)}.leaflet-pelias-layer-icon-polygon{background-image:url(/static/media/polygon_icon.83cffeed.png)}.leaflet-pelias-close{display:none;position:absolute;right:0;width:26px;height:100%;padding-right:2px;text-align:center;vertical-align:middle;font:normal 18px/26px Lucida Console,Monaco,monospace;background-color:transparent;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.leaflet-pelias-expanded .leaflet-pelias-close{display:table-cell;background-color:inherit;border-top-right-radius:4px;border-bottom-right-radius:4px}.leaflet-pelias-expanded .leaflet-pelias-close.leaflet-pelias-hidden{display:none}.leaflet-pelias-close:before{content:"";display:inline-block;height:100%;vertical-align:middle}.leaflet-touch .leaflet-pelias-input.leaflet-bar{border-radius:4px;border:0 none}.leaflet-touch .leaflet-pelias-results.leaflet-bar{border-radius:2px;border:0 none}.leaflet-pelias-search-icon{position:absolute;height:100%;background-image:url(/static/media/search.470dd7e7.png);background-repeat:no-repeat;background-position:50%;background-size:16px;z-index:10;cursor:pointer}.leaflet-bar a.leaflet-pelias-search-icon{border-radius:4px;border-bottom:0;height:100%}.leaflet-bar a.leaflet-pelias-search-icon:not(:hover){background-color:transparent}.leaflet-pelias-expanded a.leaflet-pelias-search-icon{border-top-right-radius:0;border-bottom-right-radius:0}.leaflet-pelias-search-icon.leaflet-pelias-loading{background-image:url(/static/media/loading.e56d6770.gif)}.leaflet-pelias-input:focus{outline:none;cursor:text}.leaflet-pelias-input::-ms-clear{display:none}.leaflet-pelias-results{width:100%;position:absolute;left:0;overflow-y:auto;overflow-x:hidden;display:none}.leaflet-touch .leaflet-pelias-results{box-shadow:0 0 0 2px rgba(0,0,0,.2)}.leaflet-oldie .leaflet-pelias-results{border:1px solid #999;left:-1px}.leaflet-top .leaflet-pelias-results{top:50px}.leaflet-bottom .leaflet-pelias-results{bottom:50px}.leaflet-pelias-list{list-style:none;margin:0;padding:0}.leaflet-pelias-results .leaflet-pelias-result{font-size:13px;padding:7px;background-color:#fff;border-top:1px solid #f1f1f1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer}.leaflet-pelias-results .leaflet-pelias-result:first-child{border:none}.leaflet-pelias-results .leaflet-pelias-result:hover{background-color:#d5f1f3;border-color:#d5f1f3}.leaflet-pelias-results .leaflet-pelias-result.leaflet-pelias-selected,.leaflet-pelias-results .leaflet-pelias-result.leaflet-pelias-selected:hover{background-color:#b2e3e7;border-color:#b2e3e7}.leaflet-pelias-message{font-size:13px;padding:7px;background-color:#fff;overflow-x:auto}.leaflet-right .leaflet-pelias-input,.leaflet-right .leaflet-pelias-results{left:auto;right:0}@media only screen and (-webkit-min-device-pixel-ratio:1.25),only screen and (min--moz-device-pixel-ratio:1.25),only screen and (min-device-pixel-ratio:1.25),only screen and (min-resolution:1.25dppx),only screen and (min-resolution:120dpi){.leaflet-pelias-layer-icon-point{background-image:url(/static/media/point_icon@2x.dd1da9a3.png)}.leaflet-pelias-layer-icon-polygon{background-image:url(/static/media/polygon_icon@2x.53277be6.png)}.leaflet-pelias-search-icon{background-image:url(/static/media/search@2x.37035178.png)}.leaflet-pelias-search-icon.leaflet-pelias-loading{background-image:url(/static/media/loading@2x.0ab4b1d1.gif)}}#root,body,html{width:100%;height:100%}body{background:#999;overflow-y:hidden}body,button{font-family:Helvetica,Arial,sans-serif}.table-row{display:table-row}.images-container{margin-top:.5rem;position:absolute;top:3rem;bottom:0;left:0;right:0;overflow:scroll}.app{display:-webkit-box;display:-ms-flexbox;display:flex;height:100%;-ms-flex-flow:column;flex-flow:column;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start}.app,.main{position:relative}.main{-webkit-box-flex:1;-ms-flex:1;flex:1}.main .inner{display:-webkit-box;display:-ms-flexbox;display:flex;padding:0;-ms-flex-flow:row nowrap;flex-flow:row nowrap;height:100%}.main .panel{position:relative;margin-top:5px;background:#fff}.main .panel.left{float:none;-webkit-box-flex:0;-ms-flex:0 0 50%;flex:0 0 50%;overflow:visible;z-index:1001}.main .panel.right{float:none;-webkit-box-flex:1;-ms-flex:auto;flex:auto}.prevent-overflow{overflow:hidden!important}.header{position:relative;padding:0 1rem;-webkit-box-flex:0;-ms-flex:0;flex:0;z-index:2000;background:#fff}.header h1{margin:1rem 0;font-size:1.5rem}.header .logo{display:inline-block;width:61px;height:67px;background:url(/static/media/logo.b38a9426.png);vertical-align:bottom}.images-getter{position:relative;font-size:1rem;color:#999}.images-getter .images-form{display:block;top:100%;right:0;width:100%;padding:1rem}.images-getter .images-form .dropzone-wrapper{display:inline-block;margin-bottom:1rem;width:50%;padding-right:5px}.images-getter .images-form .dropzone-wrapper:last-child{margin-bottom:0;padding-right:0;padding-left:5px}.images-getter .images-form .dropzone{width:100%;height:50px;border:2px dashed #ddd;border-radius:5px;line-height:1}.images-getter .images-form .dropzone>div{line-height:50px;text-align:center}.images-getter .images-form h4{margin:0;text-align:center;font-weight:400;font-size:1rem}.leaflet-map-wrapper{position:absolute;top:0;bottom:0}.leaflet-map-wrapper,.leaflet-map-wrapper .leaflet-map{width:100%;height:100%}.leaflet-map-providers{position:absolute;top:3rem;right:1rem;width:auto;height:auto;width:38px;padding:0;background:transparent;color:transparent;z-index:1001;transition:width .1s linear;overflow:hidden}.leaflet-map-providers.leaflet-bar{border:0;margin-right:0}.leaflet-map-providers.open{width:280px;color:#fff}.leaflet-map-providers h4{position:relative;margin:0;padding:0;height:38px;font-weight:400;background:#999;border-radius:38px;text-align:center;text-transform:uppercase;font-weight:200;letter-spacing:.5px;line-height:38px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer;white-space:nowrap}.leaflet-map-providers .icon.providers{position:absolute;left:6px;top:6px}.leaflet-map-providers ul{display:none;margin:0 1.2rem}.leaflet-map-providers.open ul{display:block}.leaflet-map-providers li{padding:5px 0;background:hsla(0,0%,60%,.6)}.leaflet-map-providers li:hover label{color:#fff}.leaflet-map-providers li.selected{background:hsla(0,0%,60%,.8)}.leaflet-map-providers li.selected label{color:#fff}.leaflet-map-providers label{display:block;white-space:nowrap;text-align:center;color:#fff;font-weight:200;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer}.leaflet-map-providers label span{vertical-align:middle}.leaflet-map-providers input[type=radio]{display:inline-block;visibility:hidden;height:0;width:0;margin:0;vertical-align:middle}.leaflet-map-providers input.custom-provider~div{display:none;padding:.5rem 1rem;background:transparent;cursor:default;text-align:right}.leaflet-map-providers input.custom-provider~div p{display:inline-block;padding:0;margin:0;color:#fff;white-space:pre-wrap;font-size:.75rem;line-height:1rem;text-align:left}.leaflet-map-providers input.custom-provider~div .btn{padding:.3rem 1rem;margin:0;outline:0;border:0;box-shadow:none;background:#999;font-weight:400;border-radius:1rem;font-size:.75rem}.leaflet-map-providers input.custom-provider~div input{padding:.5rem;margin:0 0 .5rem;height:auto;background:#999;font-size:.75rem;border:0;border-radius:1rem;text-align:left;color:#fff}.leaflet-map-providers input.custom-provider~div input::-webkit-input-placeholder{color:#fff}.leaflet-map-providers input.custom-provider~div input::-moz-placeholder{color:#fff}.leaflet-map-providers input.custom-provider~div input:-ms-input-placeholder{color:#fff}.leaflet-map-providers input.custom-provider~div input:-moz-placeholder{color:#fff}.leaflet-map-providers input:checked.custom-provider~div{display:block}.leaflet-zoom-controls{position:absolute;bottom:1.5rem;right:1rem;z-index:1001}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar{box-shadow:none;border-radius:0}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar a{display:block;width:36px;height:36px;line-height:36px;background-color:#999;color:#fff;font-weight:200;font-size:24px}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar a:first-child{border-top-left-radius:18px;border-top-right-radius:18px}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar a:last-child{border-bottom-left-radius:18px;border-bottom-right-radius:18px}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar .leaflet-control-zoom-out{font-size:26px}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar .leaflet-control-fit-bounds{position:relative}.leaflet-zoom-controls .leaflet-control-zoom.leaflet-bar .leaflet-control-fit-bounds .icon{margin-top:-5px;vertical-align:middle}.leaflet-pelias-control{z-index:9999;background:#999}.leaflet-pelias-control.leaflet-pelias-expanded{height:38px!important;border-radius:38px}.leaflet-pelias-control.leaflet-bar{border:0;right:1rem;margin-right:0}.leaflet-pelias-control.leaflet-bar a:hover{background:transparent}.leaflet-pelias-control.leaflet-pelias-expanded .leaflet-pelias-close{border-top-right-radius:38px;border-bottom-right-radius:38px}.leaflet-pelias-control .leaflet-pelias-results{top:100%;padding:0 1.2rem;box-shadow:none}.leaflet-pelias-control .leaflet-pelias-results .leaflet-pelias-result{padding:5px 7px;background:hsla(0,0%,60%,.8);color:#fff}.leaflet-pelias-control input{color:#fff;font-size:1rem}.leaflet-pelias-control input::-webkit-input-placeholder{color:#fff}.leaflet-pelias-control input::-moz-placeholder{color:#fff}.leaflet-pelias-control input:-ms-input-placeholder{color:#fff}.leaflet-pelias-control input:-moz-placeholder{color:#fff}.leaflet-touch .leaflet-pelias-control.leaflet-bar a.leaflet-pelias-search-icon{background-image:url(/static/media/search.57a8b421.png);background-repeat:no-repeat;background-size:16px;background-position:50%}.leaflet-pelias-control .leaflet-pelias-close{color:#fff}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:192dpi){.leaflet-touch &.leaflet-bar a.leaflet-pelias-search-icon{background-image:url(/static/media/search@2x.44cf1bbe.png)}}.images-module{position:relative;padding:0 1rem;margin:1rem 0 0;background:#fff}.images-module ul{display:block;margin:0;padding:0}.images-module li{margin-bottom:1rem}.images-module .details{position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:pointer}.images-module .details .blocker{position:absolute;display:none;top:0;left:0;right:0;bottom:0;background:hsla(0,0%,100%,.5)}.images-module .details.no-remove .blocker{display:block;left:auto;right:0;width:34px}.images-module .details span{display:inline-block;vertical-align:middle}.images-module .details .img-name{height:34px;width:calc(100% - 78px);margin:0 5px;border:1px dashed transparent;font-size:.875rem;color:#999;line-height:34px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.images-module li.empty .details{cursor:not-allowed}.images-module li.empty .blocker{display:block}.images-module li.empty .img-name{border:1px dashed #aaa}.images-module .img-container{margin:0 0 0 34px}.images-module .gcp-controls{list-style:none;margin:0 34px;padding:0}.images-module .gcp-controls button{margin:0;padding:5px;background:none;border:0;outline:0;color:#999;font-size:.875rem;vertical-align:top;text-align:left;line-height:20px}.images-module .gcp-controls .icon{width:20px;height:20px;vertical-align:top;margin-right:5px}.images-module .gcp-controls li{position:relative;line-height:1;margin-bottom:0}.images-module .gcp-controls li.disabled{opacity:.5;pointer-events:none}.images-module .gcp-controls li .icon.remove{position:absolute;right:0;top:5px}.images-module .gcp-controls li.not-selected .icon.remove{display:none}.imagepanzoom,.imgpanzoom-container{position:relative}.imagepanzoom{display:inline-block;cursor:move;width:244px;height:160px;border:none;overflow:hidden}.imagepanzoom .points-layer{position:absolute;top:0;left:0;z-index:1}.image-point{position:absolute;width:38px;height:38px;margin:-19px 0 0 -19px;padding:0;background:transparent;background-image:url(/static/media/gcp.44ed9ab1.png);background-position:50% 50%;background-repeat:no-repeat;background-size:contain;cursor:pointer}.imagepanzoom .image-point{height:20px;width:20px;margin:-10px 0 0 -10px}.image-point .actions{display:none;position:absolute;background:#fff;left:100%;top:50%;margin-left:10px;border-radius:4px;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%)}.image-point .actions ul{padding:5px;margin:0;list-style:none}.image-point .actions ul:after{content:" ";position:absolute;display:block;top:50%;right:100%;width:0;height:0;border:solid transparent;pointer-events:none;border-right-color:#fff;border-width:8px;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%)}.image-point .actions li{line-height:1}.image-point .actions li+li{margin-top:2px}.image-point .actions a{display:block;padding:1px 8px;color:#999;font-size:12px;text-decoration:none}.image-point .actions a:hover{text-decoration:underline}.image-point.draggable .actions{display:block}.image-point.active{background-image:url(/static/media/gcp-green.cfc5c722.png)}.image-point.highlighted{height:40px;width:40px;margin:-20px 0 0 -20px}.image-point.active.draggable,.image-point.active.leaflet-marker-draggable{background-image:url(/static/media/gcp-yellow.3793065e.png)}.image-point.active.draggable .actions,.image-point.active.leaflet-marker-draggable .actions{display:block}.imagepanzoom .image-point.draggable:after{width:31px;height:20px;left:9px}.image-point .image-point-label{background:hsla(0,0%,61%,.65);border-radius:5px;color:#fff;font-weight:700;margin-top:-20px;text-align:center}.images-grid{position:relative;width:100%}.images-grid .thumb{position:relative;display:inline-block;width:150px;height:150px;margin:5px;background:#ddd;border:1px solid #ddd;cursor:pointer}.images-grid .thumb.selected{border-color:#000}.images-grid .thumb.no-img:after{content:"Image needs\Aloaded";position:absolute;top:50%;left:0;width:100%;font-size:.75rem;color:#fff;text-align:center;white-space:pre;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%)}.images-grid .thumb .img{display:block;width:100%;height:100%;background-size:contain;background-repeat:no-repeat;background-position:50% 50%}.images-grid .thumb .bubble{position:absolute;width:1rem;height:1rem;background:#666;text-align:center;line-height:1rem;border-radius:50%}.images-grid .thumb .bubble>span{display:inline-block;color:#fff;font-size:.7rem;vertical-align:top}.images-grid .thumb .badge{top:-.25rem;right:-.25rem}.images-grid .thumb .delete{top:-.25rem;left:-.25rem;background:#c1272d}.images-grid .thumb .delete span{margin-top:-1px}.images-grid .thumb .img-name{position:absolute;bottom:0;width:100%;text-align:center;margin:0;color:#000;font-size:.75rem}.image-panzoom{width:auto;height:auto;max-width:none;-webkit-transform:initial;-ms-transform:initial;transform:none;-webkit-transform-origin:initial;-ms-transform-origin:initial;transform-origin:initial}.image-panzoom.orientation2{-webkit-transform:scaleX(-1);-ms-transform:scaleX(-1);transform:scaleX(-1);-webkit-transform-origin:initial;-ms-transform-origin:initial;transform-origin:initial}.image-panzoom.orientation3{-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg);-webkit-transform-origin:initial;-ms-transform-origin:initial;transform-origin:initial}.image-panzoom.orientation4{-webkit-transform:scaleY(-1);-ms-transform:scaleY(-1);transform:scaleY(-1);-webkit-transform-origin:initial;-ms-transform-origin:initial;transform-origin:initial}.image-panzoom.orientation5{-webkit-transform:scaleX(-1) rotate(90deg);-ms-transform:scaleX(-1) rotate(90deg);transform:scaleX(-1) rotate(90deg);-webkit-transform-origin:top left;-ms-transform-origin:top left;transform-origin:top left}.image-panzoom.orientation6{-webkit-transform:translateY(-100%) rotate(90deg);-ms-transform:translateY(-100%) rotate(90deg);transform:translateY(-100%) rotate(90deg);-webkit-transform-origin:left bottom;-ms-transform-origin:left bottom;transform-origin:left bottom}.image-panzoom.orientation7{-webkit-transform:scaleX(-1) translateX(100%) translateY(-100%) rotate(270deg);-ms-transform:scaleX(-1) translateX(100%) translateY(-100%) rotate(270deg);transform:scaleX(-1) translateX(100%) translateY(-100%) rotate(270deg);-webkit-transform-origin:bottom right;-ms-transform-origin:bottom right;transform-origin:bottom right}.image-panzoom.orientation8{-webkit-transform:translateX(-100%) rotate(270deg);-ms-transform:translateX(-100%) rotate(270deg);transform:translateX(-100%) rotate(270deg);-webkit-transform-origin:top right;-ms-transform-origin:top right;transform-origin:top right}.icon{display:inline-block;width:34px;height:34px;font-size:0;line-height:1;background-repeat:no-repeat;background-position:50%;background-size:20px 20px;vertical-align:middle}.icon.providers{width:25px;height:26px;background-image:url(/static/media/providers.ad5af2f5.png);background-size:25px 26px}.icon.fit-marker{width:25px;height:25px;background-image:url(/static/media/fit_markers.be9754ad.png);background-size:25px 25px}.icon.add{background-image:url(/static/media/add.5a2714f3.png)}.icon.remove{background-image:url(/static/media/close.729ab67b.png)}.icon.gcp{background-image:url(/static/media/add_point_green.013c6b67.png)}.icon.gcp.add{background-image:url(/static/media/add_point.e65f1d0c.png)}.icon.gcp.active{background-image:url(/static/media/add_point_yellow.a6d933c3.png)}.icon.disabled{opacity:.5;pointer-events:none}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:192dpi){.icon.providers{background-image:url(/static/media/providers@2x.51ed570c.png)}.icon..fit-marker{background-image:url(/static/media/fit_markers@2x.cf8c8fad.png)}.icon.add{background-image:url(/static/media/add@2x.b53b9f2d.png)}.icon.remove{background-image:url(/static/media/close@2x.c65c9577.png)}.icon.gcp{background-image:url(/static/media/add_point_green@2x.1dd546dd.png)}.icon.gcp.add{background-image:url(/static/media/add_point@2x.bf317640.png)}.icon.gcp.active{background-image:url(/static/media/add_point_yellow@2x.5b290820.png)}}.directions{color:#999;font-size:1rem;line-height:1.25;margin:0 2rem}.directions .direction-content{overflow:hidden;transition:max-height .25s;max-height:300px}.directions.hidden .direction-content{max-height:0}.directions h3{margin:0;text-transform:uppercase;font-size:1rem;line-height:3rem;cursor:pointer}.directions p{margin:0;padding:0}.directions ol{padding:0;margin:.5rem 0 0;list-style:none}.directions ol li{position:table-row;padding:0;margin:0 0 .5rem}.directions ol li span.tc{display:table-cell}.directions ol li span.tc:first-child{padding-right:.5rem}.directions ol li span.circled{display:inline-block;width:1.2rem;height:1.2rem;background:#999;color:#fff;font-size:.75rem;line-height:1.25rem;text-align:center;border-radius:50%;vertical-align:top}.directions .arrow{position:relative;display:inline-block;width:13px;height:3rem;font-size:0;line-height:0;margin-right:.5rem;vertical-align:top}.directions .arrow:before{content:" ";position:absolute;top:50%;left:0;width:0;height:0;margin-top:-1px;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%);border-style:solid;border-width:12px 6.5px 0;border-color:#999 transparent transparent}.directions.hidden .arrow:before{border-width:6px 0 6px 13px;border-color:transparent transparent transparent #999}.control-points-i{position:relative;top:50%;width:80%;margin:0 auto;background:#999;color:#fff;overflow:hidden;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%)}.control-points-i>div{margin:0;padding:5px}.control-points-i h3{margin:0 0 .5rem;text-transform:uppercase;font-size:1rem;line-height:1rem}.control-points-i ul{margin:0;padding:0;list-style:none;line-height:1}.control-points-i ul li{font-size:.85rem;color:#fff;line-height:16px;opacity:.7}.control-points-i ul li.point{display:inline-block;height:10px;width:10px;margin-right:3px;background:#fff;border-radius:50%;opacity:.4;line-height:1;opacity:1}.control-points-i ul li.point.active{background:#006837;opacity:1}.control-points-i ul li.point.active.edit{background:#fbb03b}.control-points-i ul li:last-child{margin-right:0}.export-btn{position:absolute;bottom:0;right:1rem;width:10rem;height:2.5rem;padding:0;border:0;background:transparent;color:#999;border:1px solid #999;border-bottom:0;font-size:1rem;text-transform:uppercase;outline:0;cursor:pointer}.export-btn:hover{color:#ff0}.export-btn:disabled{pointer-events:none;cursor:default;opacity:.5}.export-btn:disabled:hover{color:#999}.export-modal .output{padding:1rem 1.5rem}.export-modal .output .errors,.export-modal .output table{width:500px}.export-modal .output .errors p{font-size:.85rem;white-space:normal}.export-modal .output td:first-child{white-space:no-wrap;vertical-align:top}.export-modal .output td:last-child{width:100%}.export-modal .output p{display:inline-block;margin-right:1rem;font-size:1.1rem;color:#999;white-space:nowrap}.export-modal .output textarea{width:100%;min-height:200px}.export-modal .destination-projection{width:100%}.file-preview textarea{height:300px;width:100%}.modal-dialog{position:fixed;top:0;left:0;width:100%;height:100%;z-index:9999}.modal-dialog p{margin:0;padding:0}.modal-dialog .bk{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.1);z-index:1}.modal-dialog .inner{position:absolute;left:50%;top:50%;min-width:700px;background:#fff;-webkit-transform:translateX(-50%) translateY(-50%);-ms-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%);z-index:2}.modal-dialog .head{background:#999;color:#fff;text-align:center;text-transform:uppercase}.modal-dialog .head h3{margin:0;padding:0;line-height:2.8rem;font-size:1rem}.modal-dialog .icon{position:absolute;right:0;top:0;width:2.8rem;height:2.8rem;font-size:0;line-height:1;cursor:pointer}.modal-dialog .icon span{position:absolute;top:50%;margin-top:-.8rem;font-size:1.2rem}.modal-dialog .output{padding:1rem 1.5rem}.modal-dialog .output p{display:inline-block;margin-right:1rem;font-size:1.1rem;color:#999;white-space:nowrap}.modal-dialog .actions{text-align:right}.modal-dialog .actions p{margin-right:0;font-size:.75rem}.modal-dialog .actions button{margin-left:.5rem;border:0;background:#999;color:#fff;border-radius:11px;padding:4px 10px;outline:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.modal-dialog .actions button:hover{color:#ff0}.modal-dialog .actions button:disabled{opacity:.5;cursor:default;pointer-events:none}.modal-dialog .actions button:disabled:hover{color:#fff}.sliding-panel{position:absolute;left:-100%;top:72px;bottom:0;width:100%;background:#fff;z-index:10;transition:left .2s linear;overflow:hidden}.sliding-panel.open{left:0;overflow:auto}.image-nav{display:block;position:relative;margin:0;padding:0;width:100%;height:72px;background:#999;overflow:visible;z-index:10}.image-nav .toggle-grid{left:0}.image-nav .add-point-wrapper,.image-nav .toggle-grid{position:absolute;top:36px;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%)}.image-nav .add-point-wrapper{display:none;right:0}.image-nav.no-images .toggle-grid{opacity:.5;pointer-events:none}.image-nav.editable .add-point-wrapper{display:inline-block}.image-editor{position:relative}.toggle-grid{display:inline-block;padding:4px;margin:0;background:transparent;border:0;font-weight:700;line-height:0;outline:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.toggle-grid.to-editor:hover svg{fill:#ff0}.add-point-wrapper{line-height:1}.add-point-wrapper .add-point{display:inline-block;padding:4px;margin:0;background:transparent;border:0;font-weight:700;line-height:0;outline:0;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.add-point-wrapper .add-point:hover svg{fill:#ff0}.add-point-wrapper .helper{display:none;position:absolute;top:100%;width:150px;background:#fff;font-size:12px;line-height:1;left:-59px;padding:5px 10px;border-radius:4px;color:#999;text-align:center}.add-point-wrapper .helper:after{bottom:100%;left:50%;border:solid transparent;content:" ";height:0;width:0;position:absolute;pointer-events:none;border-color:transparent;border-bottom-color:#fff;border-width:5px;margin-left:-5px}.mode-adding .add-point-wrapper .helper{display:block} +/*# sourceMappingURL=main.0b2dd337.css.map*/ \ No newline at end of file diff --git a/plugins/posm-gcpi/public/static/css/main.0b2dd337.css.map b/plugins/posm-gcpi/public/static/css/main.0b2dd337.css.map new file mode 100644 index 00000000..61d9f2a0 --- /dev/null +++ b/plugins/posm-gcpi/public/static/css/main.0b2dd337.css.map @@ -0,0 +1 @@ +{"version":3,"sources":[],"names":[],"mappings":"","file":"static/css/main.0b2dd337.css","sourceRoot":""} \ No newline at end of file diff --git a/plugins/posm-gcpi/public/static/js/main.df429876.js b/plugins/posm-gcpi/public/static/js/main.df429876.js new file mode 100644 index 00000000..e5ac4f7b --- /dev/null +++ b/plugins/posm-gcpi/public/static/js/main.df429876.js @@ -0,0 +1,19 @@ +!function(t){function e(i){if(n[i])return n[i].exports;var o=n[i]={exports:{},id:i,loaded:!1};return t[i].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="/",e(0)}(function(t){for(var e in t)if(Object.prototype.hasOwnProperty.call(t,e))switch(typeof t[e]){case"function":break;case"object":t[e]=function(e){var n=e.slice(1),i=t[e[0]];return function(t,e,o){i.apply(this,[t,e,o].concat(n))}}(t[e]);break;default:t[e]=t[t[e]]}return t}([function(t,e,n){n(105),t.exports=n(141)},function(t,e,n){"use strict";function i(t,e,n,i,r,a,s,u){if(o(e),!t){var l;if(void 0===e)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,i,r,a,s,u],h=0;l=new Error(e.replace(/%s/g,function(){return c[h++]})),l.name="Invariant Violation"}throw l.framesToPop=1,l}}var o=function(t){};t.exports=i},function(t,e,n){"use strict";var i=n(8),o=i;t.exports=o},function(t,e){"use strict";function n(t){for(var e=arguments.length-1,n="Minified React error #"+t+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+t,i=0;i=0}function A(t,e,n,i){return"touchstart"===e?R(t,n,i):"touchmove"===e?B(t,n,i):"touchend"===e&&W(t,n,i),this}function N(t,e,n){var i=t["_leaflet_"+e+n];return"touchstart"===e?t.removeEventListener(mn,i,!1):"touchmove"===e?t.removeEventListener(_n,i,!1):"touchend"===e&&(t.removeEventListener(vn,i,!1),t.removeEventListener(gn,i,!1)),this}function R(t,e,i){var o=n(function(t){if("mouse"!==t.pointerType&&t.MSPOINTER_TYPE_MOUSE&&t.pointerType!==t.MSPOINTER_TYPE_MOUSE){if(!(yn.indexOf(t.target.tagName)<0))return;$(t)}F(t,e)});t["_leaflet_touchstart"+i]=o,t.addEventListener(mn,o,!1),Mn||(document.documentElement.addEventListener(mn,j,!0),document.documentElement.addEventListener(_n,z,!0),document.documentElement.addEventListener(vn,U,!0),document.documentElement.addEventListener(gn,U,!0),Mn=!0)}function j(t){bn[t.pointerId]=t,xn++}function z(t){bn[t.pointerId]&&(bn[t.pointerId]=t)}function U(t){delete bn[t.pointerId],xn--}function F(t,e){t.touches=[];for(var n in bn)t.touches.push(bn[n]);t.changedTouches=[t],e(t)}function B(t,e,n){var i=function(t){(t.pointerType!==t.MSPOINTER_TYPE_MOUSE&&"mouse"!==t.pointerType||0!==t.buttons)&&F(t,e)};t["_leaflet_touchmove"+n]=i,t.addEventListener(_n,i,!1)}function W(t,e,n){var i=function(t){F(t,e)};t["_leaflet_touchend"+n]=i,t.addEventListener(vn,i,!1),t.addEventListener(gn,i,!1)}function G(t,e,n){function i(t){var e;if(an){if(!ze||"mouse"===t.pointerType)return;e=xn}else e=t.touches.length;if(!(e>1)){var n=Date.now(),i=n-(r||n);a=t.touches?t.touches[0]:t,s=i>0&&i<=u,r=n}}function o(t){if(s&&!a.cancelBubble){if(an){if(!ze||"mouse"===t.pointerType)return;var n,i,o={};for(i in a)n=a[i],o[i]=n&&n.bind?n.bind(a):n;a=o}a.type="dblclick",e(a),r=null}}var r,a,s=!1,u=250;return t[En+wn+n]=i,t[En+Pn+n]=o,t[En+"dblclick"+n]=e,t.addEventListener(wn,i,!1),t.addEventListener(Pn,o,!1),t.addEventListener("dblclick",e,!1),this}function Z(t,e){var n=t[En+wn+e],i=t[En+Pn+e],o=t[En+"dblclick"+e];return t.removeEventListener(wn,n,!1),t.removeEventListener(Pn,i,!1),ze||t.removeEventListener("dblclick",o,!1),this}function H(t,e,n,i){if("object"==typeof e)for(var o in e)V(t,o,e[o],n);else{e=l(e);for(var r=0,a=e.length;r100&&i<500||t.target._simulatedClick&&!t._simulated?void J(t):(Oe=n,void e(t))}function at(t){return"string"==typeof t?document.getElementById(t):t}function st(t,e){var n=t.style[e]||t.currentStyle&&t.currentStyle[e];if((!n||"auto"===n)&&document.defaultView){var i=document.defaultView.getComputedStyle(t,null);n=i?i[e]:null}return"auto"===n?null:n}function ut(t,e,n){var i=document.createElement(t);return i.className=e||"",n&&n.appendChild(i),i}function lt(t){var e=t.parentNode;e&&e.removeChild(t)}function ct(t){for(;t.firstChild;)t.removeChild(t.firstChild)}function ht(t){var e=t.parentNode;e.lastChild!==t&&e.appendChild(t)}function pt(t){var e=t.parentNode;e.firstChild!==t&&e.insertBefore(t,e.firstChild)}function ft(t,e){if(void 0!==t.classList)return t.classList.contains(e);var n=vt(t);return n.length>0&&new RegExp("(^|\\s)"+e+"(\\s|$)").test(n)}function dt(t,e){if(void 0!==t.classList)for(var n=l(e),i=0,o=n.length;iu&&(r=a,u=s);u>n&&(e[r]=1,Dt(t,e,n,i,r),Dt(t,e,n,r,o))}function At(t,e){for(var n=[t[0]],i=1,o=0,r=t.length;ie&&(n.push(t[i]),o=i);return oe.max.x&&(n|=2),t.ye.max.y&&(n|=8),n}function zt(t,e){var n=e.x-t.x,i=e.y-t.y;return n*n+i*i}function Ut(t,e,n,i){var o,r=e.x,a=e.y,s=n.x-r,u=n.y-a,l=s*s+u*u;return l>0&&(o=((t.x-r)*s+(t.y-a)*u)/l,o>1?(r=n.x,a=n.y):o>0&&(r+=s*o,a+=u*o)),s=t.x-r,u=t.y-a,i?s*s+u*u:new b(r,a)}function Ft(t){return!ve(t[0])||"object"!=typeof t[0][0]&&"undefined"!=typeof t[0][0]}function Bt(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),Ft(t)}function Wt(t,e,n){var i,o,r,a,s,u,l,c,h,p=[1,4,2,8];for(o=0,l=t.length;o0?Math.floor(t):Math.ceil(t)};b.prototype={clone:function(){return new b(this.x,this.y)},add:function(t){return this.clone()._add(M(t))},_add:function(t){return this.x+=t.x,this.y+=t.y,this},subtract:function(t){return this.clone()._subtract(M(t))},_subtract:function(t){return this.x-=t.x,this.y-=t.y,this},divideBy:function(t){return this.clone()._divideBy(t)},_divideBy:function(t){return this.x/=t,this.y/=t,this},multiplyBy:function(t){return this.clone()._multiplyBy(t)},_multiplyBy:function(t){return this.x*=t,this.y*=t,this},scaleBy:function(t){return new b(this.x*t.x,this.y*t.y)},unscaleBy:function(t){return new b(this.x/t.x,this.y/t.y)},round:function(){return this.clone()._round()},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},floor:function(){return this.clone()._floor()},_floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.clone()._ceil()},_ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},trunc:function(){return this.clone()._trunc()},_trunc:function(){return this.x=Ee(this.x),this.y=Ee(this.y),this},distanceTo:function(t){t=M(t);var e=t.x-this.x,n=t.y-this.y;return Math.sqrt(e*e+n*n)},equals:function(t){return t=M(t),t.x===this.x&&t.y===this.y},contains:function(t){return t=M(t),Math.abs(t.x)<=Math.abs(this.x)&&Math.abs(t.y)<=Math.abs(this.y)},toString:function(){return"Point("+s(this.x)+", "+s(this.y)+")"}},x.prototype={extend:function(t){return t=M(t),this.min||this.max?(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)):(this.min=t.clone(),this.max=t.clone()),this},getCenter:function(t){return new b((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,t)},getBottomLeft:function(){return new b(this.min.x,this.max.y)},getTopRight:function(){return new b(this.max.x,this.min.y)},getTopLeft:function(){return this.min},getBottomRight:function(){return this.max},getSize:function(){return this.max.subtract(this.min)},contains:function(t){var e,n;return t="number"==typeof t[0]||t instanceof b?M(t):w(t),t instanceof x?(e=t.min,n=t.max):e=n=t,e.x>=this.min.x&&n.x<=this.max.x&&e.y>=this.min.y&&n.y<=this.max.y},intersects:function(t){t=w(t);var e=this.min,n=this.max,i=t.min,o=t.max,r=o.x>=e.x&&i.x<=n.x,a=o.y>=e.y&&i.y<=n.y;return r&&a},overlaps:function(t){t=w(t);var e=this.min,n=this.max,i=t.min,o=t.max,r=o.x>e.x&&i.xe.y&&i.y=i.lat&&n.lat<=o.lat&&e.lng>=i.lng&&n.lng<=o.lng},intersects:function(t){t=E(t);var e=this._southWest,n=this._northEast,i=t.getSouthWest(),o=t.getNorthEast(),r=o.lat>=e.lat&&i.lat<=n.lat,a=o.lng>=e.lng&&i.lng<=n.lng; +return r&&a},overlaps:function(t){t=E(t);var e=this._southWest,n=this._northEast,i=t.getSouthWest(),o=t.getNorthEast(),r=o.lat>e.lat&&i.late.lng&&i.lng1,hn=function(){return!!document.createElement("canvas").getContext}(),pn=!(!document.createElementNS||!S("svg").createSVGRect),fn=!pn&&function(){try{var t=document.createElement("div");t.innerHTML='';var e=t.firstChild;return e.style.behavior="url(#default#VML)",e&&"object"==typeof e.adj}catch(n){return!1}}(),dn=(Object.freeze||Object)({ie:Re,ielt9:je,edge:ze,webkit:Ue,android:Fe,android23:Be,androidStock:Ge,opera:Ze,chrome:He,gecko:qe,safari:Ve,phantom:Ke,opera12:Ye,win:Xe,ie3d:Qe,webkit3d:$e,gecko3d:Je,any3d:tn,mobile:en,mobileWebkit:nn,mobileWebkit3d:on,msPointer:rn,pointer:an,touch:sn,mobileOpera:un,mobileGecko:ln,retina:cn,canvas:hn,svg:pn,vml:fn}),mn=rn?"MSPointerDown":"pointerdown",_n=rn?"MSPointerMove":"pointermove",vn=rn?"MSPointerUp":"pointerup",gn=rn?"MSPointerCancel":"pointercancel",yn=["INPUT","SELECT","OPTION"],bn={},Mn=!1,xn=0,wn=rn?"MSPointerDown":an?"pointerdown":"touchstart",Pn=rn?"MSPointerUp":an?"pointerup":"touchend",En="_leaflet_",Cn="_leaflet_events",Tn=Xe&&He?2*window.devicePixelRatio:qe?window.devicePixelRatio:1,kn={},On=(Object.freeze||Object)({on:H,off:q,stopPropagation:Y,disableScrollPropagation:X,disableClickPropagation:Q,preventDefault:$,stop:J,getMousePosition:tt,getWheelDelta:et,fakeStop:nt,skipped:it,isExternalTarget:ot,addListener:H,removeListener:q}),Sn=bt(["transform","WebkitTransform","OTransform","MozTransform","msTransform"]),In=bt(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),Ln="webkitTransition"===In||"OTransition"===In?In+"End":"transitionend";if("onselectstart"in document)Se=function(){H(window,"selectstart",$)},Ie=function(){q(window,"selectstart",$)};else{var Dn=bt(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);Se=function(){if(Dn){var t=document.documentElement.style;Le=t[Dn],t[Dn]="none"}},Ie=function(){Dn&&(document.documentElement.style[Dn]=Le,Le=void 0)}}var An,Nn,Rn=(Object.freeze||Object)({TRANSFORM:Sn,TRANSITION:In,TRANSITION_END:Ln,get:at,getStyle:st,create:ut,remove:lt,empty:ct,toFront:ht,toBack:pt,hasClass:ft,addClass:dt,removeClass:mt,setClass:_t,getClass:vt,setOpacity:gt,testProp:bt,setTransform:Mt,setPosition:xt,getPosition:wt,disableTextSelection:Se,enableTextSelection:Ie,disableImageDrag:Pt,enableImageDrag:Et,preventOutline:Ct,restoreOutline:Tt}),jn=Pe.extend({run:function(t,e,n,i){this.stop(),this._el=t,this._inProgress=!0,this._duration=n||.25,this._easeOutPower=1/Math.max(i||.5,.2),this._startPos=wt(t),this._offset=e.subtract(this._startPos),this._startTime=+new Date,this.fire("start"),this._animate()},stop:function(){this._inProgress&&(this._step(!0),this._complete())},_animate:function(){this._animId=_(this._animate,this),this._step()},_step:function(t){var e=+new Date-this._startTime,n=1e3*this._duration;ethis.options.maxZoom)?this.setZoom(t):this},panInsideBounds:function(t,e){this._enforcingBounds=!0;var n=this.getCenter(),i=this._limitCenter(n,this._zoom,E(t));return n.equals(i)||this.panTo(i,e),this._enforcingBounds=!1,this},invalidateSize:function(t){if(!this._loaded)return this;t=e({animate:!1,pan:!0},t===!0?{animate:!0}:t);var i=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var o=this.getSize(),r=i.divideBy(2).round(),a=o.divideBy(2).round(),s=r.subtract(a);return s.x||s.y?(t.animate&&t.pan?this.panBy(s):(t.pan&&this._rawPanBy(s),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(n(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:i,newSize:o})):this},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(t){if(t=this._locateOptions=e({timeout:1e4,watch:!1},t),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var i=n(this._handleGeolocationResponse,this),o=n(this._handleGeolocationError,this);return t.watch?this._locationWatchId=navigator.geolocation.watchPosition(i,o,t):navigator.geolocation.getCurrentPosition(i,o,t),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(t){var e=t.code,n=t.message||(1===e?"permission denied":2===e?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:e,message:"Geolocation error: "+n+"."})},_handleGeolocationResponse:function(t){var e=t.coords.latitude,n=t.coords.longitude,i=new C(e,n),o=i.toBounds(t.coords.accuracy),r=this._locateOptions;if(r.setView){var a=this.getBoundsZoom(o);this.setView(i,r.maxZoom?Math.min(a,r.maxZoom):a)}var s={latlng:i,bounds:o,timestamp:t.timestamp};for(var u in t.coords)"number"==typeof t.coords[u]&&(s[u]=t.coords[u]);this.fire("locationfound",s)},addHandler:function(t,e){if(!e)return this;var n=this[t]=new e(this);return this._handlers.push(n),this.options[t]&&n.enable(),this},remove:function(){if(this._initEvents(!0),this._containerId!==this._container._leaflet_id)throw new Error("Map container is being reused by another instance");try{delete this._container._leaflet_id,delete this._containerId}catch(t){this._container._leaflet_id=void 0,this._containerId=void 0}void 0!==this._locationWatchId&&this.stopLocate(),this._stop(),lt(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._clearHandlers(),this._loaded&&this.fire("unload");var e;for(e in this._layers)this._layers[e].remove();for(e in this._panes)lt(this._panes[e]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(t,e){var n="leaflet-pane"+(t?" leaflet-"+t.replace("Pane","")+"-pane":""),i=ut("div",n,e||this._mapPane);return t&&(this._panes[t]=i),i},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter:this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var t=this.getPixelBounds(),e=this.unproject(t.getBottomLeft()),n=this.unproject(t.getTopRight());return new P(e,n)},getMinZoom:function(){return void 0===this.options.minZoom?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return void 0===this.options.maxZoom?void 0===this._layersMaxZoom?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(t,e,n){t=E(t),n=M(n||[0,0]);var i=this.getZoom()||0,o=this.getMinZoom(),r=this.getMaxZoom(),a=t.getNorthWest(),s=t.getSouthEast(),u=this.getSize().subtract(n),l=w(this.project(s,i),this.project(a,i)).getSize(),c=tn?this.options.zoomSnap:1,h=u.x/l.x,p=u.y/l.y,f=e?Math.max(h,p):Math.min(h,p);return i=this.getScaleZoom(f,i),c&&(i=Math.round(i/(c/100))*(c/100),i=e?Math.ceil(i/c)*c:Math.floor(i/c)*c),Math.max(o,Math.min(r,i))},getSize:function(){return this._size&&!this._sizeChanged||(this._size=new b(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(t,e){var n=this._getTopLeftPoint(t,e);return new x(n,n.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(t){return this.options.crs.getProjectedBounds(void 0===t?this.getZoom():t)},getPane:function(t){return"string"==typeof t?this._panes[t]:t},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(t,e){var n=this.options.crs;return e=void 0===e?this._zoom:e,n.scale(t)/n.scale(e)},getScaleZoom:function(t,e){var n=this.options.crs;e=void 0===e?this._zoom:e;var i=n.zoom(t*n.scale(e));return isNaN(i)?1/0:i},project:function(t,e){return e=void 0===e?this._zoom:e,this.options.crs.latLngToPoint(T(t),e)},unproject:function(t,e){return e=void 0===e?this._zoom:e,this.options.crs.pointToLatLng(M(t),e)},layerPointToLatLng:function(t){var e=M(t).add(this.getPixelOrigin());return this.unproject(e)},latLngToLayerPoint:function(t){var e=this.project(T(t))._round();return e._subtract(this.getPixelOrigin())},wrapLatLng:function(t){return this.options.crs.wrapLatLng(T(t))},wrapLatLngBounds:function(t){return this.options.crs.wrapLatLngBounds(E(t))},distance:function(t,e){return this.options.crs.distance(T(t),T(e))},containerPointToLayerPoint:function(t){return M(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return M(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var e=this.containerPointToLayerPoint(M(t));return this.layerPointToLatLng(e)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(T(t)))},mouseEventToContainerPoint:function(t){return tt(t,this._container)},mouseEventToLayerPoint:function(t){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(t))},mouseEventToLatLng:function(t){return this.layerPointToLatLng(this.mouseEventToLayerPoint(t))},_initContainer:function(t){var e=this._container=at(t);if(!e)throw new Error("Map container not found.");if(e._leaflet_id)throw new Error("Map container is already initialized.");H(e,"scroll",this._onScroll,this),this._containerId=i(e)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&tn,dt(t,"leaflet-container"+(sn?" leaflet-touch":"")+(cn?" leaflet-retina":"")+(je?" leaflet-oldie":"")+(Ve?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var e=st(t,"position");"absolute"!==e&&"relative"!==e&&"fixed"!==e&&(t.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var t=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),xt(this._mapPane,new b(0,0)),this.createPane("tilePane"),this.createPane("shadowPane"),this.createPane("overlayPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(dt(t.markerPane,"leaflet-zoom-hide"),dt(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,e){xt(this._mapPane,new b(0,0));var n=!this._loaded;this._loaded=!0,e=this._limitZoom(e),this.fire("viewprereset");var i=this._zoom!==e;this._moveStart(i,!1)._move(t,e)._moveEnd(i),this.fire("viewreset"),n&&this.fire("load")},_moveStart:function(t,e){return t&&this.fire("zoomstart"),e||this.fire("movestart"),this},_move:function(t,e,n){void 0===e&&(e=this._zoom);var i=this._zoom!==e;return this._zoom=e,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),(i||n&&n.pinch)&&this.fire("zoom",n),this.fire("move",n)},_moveEnd:function(t){return t&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return v(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(t){xt(this._mapPane,this._getMapPanePos().subtract(t))},_getZoomSpan:function(){return this.getMaxZoom()-this.getMinZoom()},_panInsideMaxBounds:function(){this._enforcingBounds||this.panInsideBounds(this.options.maxBounds)},_checkIfLoaded:function(){if(!this._loaded)throw new Error("Set map center and zoom first.")},_initEvents:function(t){this._targets={},this._targets[i(this._container)]=this;var e=t?q:H;e(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress",this._handleDOMEvent,this),this.options.trackResize&&e(window,"resize",this._onResize,this),tn&&this.options.transform3DLimit&&(t?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){v(this._resizeRequest),this._resizeRequest=_(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var t=this._getMapPanePos();Math.max(Math.abs(t.x),Math.abs(t.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(t,e){for(var n,o=[],r="mouseout"===e||"mouseover"===e,a=t.target||t.srcElement,s=!1;a;){if(n=this._targets[i(a)],n&&("click"===e||"preclick"===e)&&!t._simulated&&this._draggableMoved(n)){s=!0;break}if(n&&n.listens(e,!0)){if(r&&!ot(a,t))break;if(o.push(n),r)break}if(a===this._container)break;a=a.parentNode}return o.length||s||r||!ot(a,t)||(o=[this]),o},_handleDOMEvent:function(t){if(this._loaded&&!it(t)){var e=t.type;"mousedown"!==e&&"keypress"!==e||Ct(t.target||t.srcElement),this._fireDOMEvent(t,e)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(t,n,i){if("click"===t.type){var o=e({},t);o.type="preclick",this._fireDOMEvent(o,o.type,i)}if(!t._stopped&&(i=(i||[]).concat(this._findEventTargets(t,n)),i.length)){var r=i[0];"contextmenu"===n&&r.listens(n,!0)&&$(t);var a={originalEvent:t};if("keypress"!==t.type){var s=r.getLatLng&&(!r._radius||r._radius<=10);a.containerPoint=s?this.latLngToContainerPoint(r.getLatLng()):this.mouseEventToContainerPoint(t),a.layerPoint=this.containerPointToLayerPoint(a.containerPoint),a.latlng=s?r.getLatLng():this.layerPointToLatLng(a.layerPoint)}for(var u=0;u0?Math.round(t-e)/2:Math.max(0,Math.ceil(t))-Math.max(0,Math.floor(e))},_limitZoom:function(t){var e=this.getMinZoom(),n=this.getMaxZoom(),i=tn?this.options.zoomSnap:1;return i&&(t=Math.round(t/i)*i),Math.max(e,Math.min(n,t))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){mt(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(t,e){var n=this._getCenterOffset(t)._trunc();return!((e&&e.animate)!==!0&&!this.getSize().contains(n))&&(this.panBy(n,e),!0)},_createAnimProxy:function(){var t=this._proxy=ut("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",function(t){var e=Sn,n=this._proxy.style[e];Mt(this._proxy,this.project(t.center,t.zoom),this.getZoomScale(t.zoom,1)),n===this._proxy.style[e]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",function(){var t=this.getCenter(),e=this.getZoom();Mt(this._proxy,this.project(t,e),this.getZoomScale(e,1))},this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){lt(this._proxy),delete this._proxy},_catchTransitionEnd:function(t){this._animatingZoom&&t.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(t,e,n){if(this._animatingZoom)return!0;if(n=n||{},!this._zoomAnimated||n.animate===!1||this._nothingToAnimate()||Math.abs(e-this._zoom)>this.options.zoomAnimationThreshold)return!1;var i=this.getZoomScale(e),o=this._getCenterOffset(t)._divideBy(1-1/i);return!(n.animate!==!0&&!this.getSize().contains(o))&&(_(function(){this._moveStart(!0,!1)._animateZoom(t,e,!0)},this),!0)},_animateZoom:function(t,e,i,o){this._mapPane&&(i&&(this._animatingZoom=!0,this._animateToCenter=t,this._animateToZoom=e,dt(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:t,zoom:e,noUpdate:o}),setTimeout(n(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&mt(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom),_(function(){this._moveEnd(!0)},this))}}),Un=g.extend({options:{position:"topright"},initialize:function(t){c(this,t)},getPosition:function(){return this.options.position},setPosition:function(t){var e=this._map;return e&&e.removeControl(this),this.options.position=t,e&&e.addControl(this),this},getContainer:function(){return this._container},addTo:function(t){this.remove(),this._map=t;var e=this._container=this.onAdd(t),n=this.getPosition(),i=t._controlCorners[n];return dt(e,"leaflet-control"),n.indexOf("bottom")!==-1?i.insertBefore(e,i.firstChild):i.appendChild(e),this},remove:function(){return this._map?(lt(this._container),this.onRemove&&this.onRemove(this._map),this._map=null,this):this},_refocusOnMap:function(t){this._map&&t&&t.screenX>0&&t.screenY>0&&this._map.getContainer().focus()}}),Fn=function(t){return new Un(t)};zn.include({addControl:function(t){return t.addTo(this),this},removeControl:function(t){return t.remove(),this},_initControlPos:function(){function t(t,o){var r=n+t+" "+n+o;e[t+o]=ut("div",r,i)}var e=this._controlCorners={},n="leaflet-",i=this._controlContainer=ut("div",n+"control-container",this._container);t("top","left"),t("top","right"),t("bottom","left"),t("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)lt(this._controlCorners[t]);lt(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var Bn=Un.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(t,e,n,i){return n1,this._baseLayersList.style.display=t?"":"none"),this._separator.style.display=e&&t?"":"none",this},_onLayerChange:function(t){this._handlingClick||this._update();var e=this._getLayer(i(t.target)),n=e.overlay?"add"===t.type?"overlayadd":"overlayremove":"add"===t.type?"baselayerchange":null;n&&this._map.fire(n,e)},_createRadioElement:function(t,e){var n='",i=document.createElement("div"); +return i.innerHTML=n,i.firstChild},_addItem:function(t){var e,n=document.createElement("label"),o=this._map.hasLayer(t.layer);t.overlay?(e=document.createElement("input"),e.type="checkbox",e.className="leaflet-control-layers-selector",e.defaultChecked=o):e=this._createRadioElement("leaflet-base-layers",o),this._layerControlInputs.push(e),e.layerId=i(t.layer),H(e,"click",this._onInputClick,this);var r=document.createElement("span");r.innerHTML=" "+t.name;var a=document.createElement("div");n.appendChild(a),a.appendChild(e),a.appendChild(r);var s=t.overlay?this._overlaysList:this._baseLayersList;return s.appendChild(n),this._checkDisabledLayers(),n},_onInputClick:function(){var t,e,n=this._layerControlInputs,i=[],o=[];this._handlingClick=!0;for(var r=n.length-1;r>=0;r--)t=n[r],e=this._getLayer(t.layerId).layer,t.checked?i.push(e):t.checked||o.push(e);for(r=0;r=0;o--)t=n[o],e=this._getLayer(t.layerId).layer,t.disabled=void 0!==e.options.minZoom&&ie.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expand:function(){return this.expand()},_collapse:function(){return this.collapse()}}),Wn=function(t,e,n){return new Bn(t,e,n)},Gn=Un.extend({options:{position:"topleft",zoomInText:"+",zoomInTitle:"Zoom in",zoomOutText:"−",zoomOutTitle:"Zoom out"},onAdd:function(t){var e="leaflet-control-zoom",n=ut("div",e+" leaflet-bar"),i=this.options;return this._zoomInButton=this._createButton(i.zoomInText,i.zoomInTitle,e+"-in",n,this._zoomIn),this._zoomOutButton=this._createButton(i.zoomOutText,i.zoomOutTitle,e+"-out",n,this._zoomOut),this._updateDisabled(),t.on("zoomend zoomlevelschange",this._updateDisabled,this),n},onRemove:function(t){t.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(t){!this._disabled&&this._map._zoomthis._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(t.shiftKey?3:1))},_createButton:function(t,e,n,i,o){var r=ut("a",n,i);return r.innerHTML=t,r.href="#",r.title=e,r.setAttribute("role","button"),r.setAttribute("aria-label",e),Q(r),H(r,"click",J),H(r,"click",o,this),H(r,"click",this._refocusOnMap,this),r},_updateDisabled:function(){var t=this._map,e="leaflet-disabled";mt(this._zoomInButton,e),mt(this._zoomOutButton,e),(this._disabled||t._zoom===t.getMinZoom())&&dt(this._zoomOutButton,e),(this._disabled||t._zoom===t.getMaxZoom())&&dt(this._zoomInButton,e)}});zn.mergeOptions({zoomControl:!0}),zn.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new Gn,this.addControl(this.zoomControl))});var Zn=function(t){return new Gn(t)},Hn=Un.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var e="leaflet-control-scale",n=ut("div",e),i=this.options;return this._addScales(i,e+"-line",n),t.on(i.updateWhenIdle?"moveend":"move",this._update,this),t.whenReady(this._update,this),n},onRemove:function(t){t.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(t,e,n){t.metric&&(this._mScale=ut("div",e,n)),t.imperial&&(this._iScale=ut("div",e,n))},_update:function(){var t=this._map,e=t.getSize().y/2,n=t.distance(t.containerPointToLatLng([0,e]),t.containerPointToLatLng([this.options.maxWidth,e]));this._updateScales(n)},_updateScales:function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},_updateMetric:function(t){var e=this._getRoundNum(t),n=e<1e3?e+" m":e/1e3+" km";this._updateScale(this._mScale,n,e/t)},_updateImperial:function(t){var e,n,i,o=3.2808399*t;o>5280?(e=o/5280,n=this._getRoundNum(e),this._updateScale(this._iScale,n+" mi",n/e)):(i=this._getRoundNum(o),this._updateScale(this._iScale,i+" ft",i/o))},_updateScale:function(t,e,n){t.style.width=Math.round(this.options.maxWidth*n)+"px",t.innerHTML=e},_getRoundNum:function(t){var e=Math.pow(10,(Math.floor(t)+"").length-1),n=t/e;return n=n>=10?10:n>=5?5:n>=3?3:n>=2?2:1,e*n}}),qn=function(t){return new Hn(t)},Vn=Un.extend({options:{position:"bottomright",prefix:'Leaflet'},initialize:function(t){c(this,t),this._attributions={}},onAdd:function(t){t.attributionControl=this,this._container=ut("div","leaflet-control-attribution"),Q(this._container);for(var e in t._layers)t._layers[e].getAttribution&&this.addAttribution(t._layers[e].getAttribution());return this._update(),this._container},setPrefix:function(t){return this.options.prefix=t,this._update(),this},addAttribution:function(t){return t?(this._attributions[t]||(this._attributions[t]=0),this._attributions[t]++,this._update(),this):this},removeAttribution:function(t){return t?(this._attributions[t]&&(this._attributions[t]--,this._update()),this):this},_update:function(){if(this._map){var t=[];for(var e in this._attributions)this._attributions[e]&&t.push(e);var n=[];this.options.prefix&&n.push(this.options.prefix),t.length&&n.push(t.join(", ")),this._container.innerHTML=n.join(" | ")}}});zn.mergeOptions({attributionControl:!0}),zn.addInitHook(function(){this.options.attributionControl&&(new Vn).addTo(this)});var Kn=function(t){return new Vn(t)};Un.Layers=Bn,Un.Zoom=Gn,Un.Scale=Hn,Un.Attribution=Vn,Fn.layers=Wn,Fn.zoom=Zn,Fn.scale=qn,Fn.attribution=Kn;var Yn=g.extend({initialize:function(t){this._map=t},enable:function(){return this._enabled?this:(this._enabled=!0,this.addHooks(),this)},disable:function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},enabled:function(){return!!this._enabled}});Yn.addTo=function(t,e){return t.addHandler(e,this),this};var Xn,Qn={Events:we},$n=sn?"touchstart mousedown":"mousedown",Jn={mousedown:"mouseup",touchstart:"touchend",pointerdown:"touchend",MSPointerDown:"touchend"},ti={mousedown:"mousemove",touchstart:"touchmove",pointerdown:"touchmove",MSPointerDown:"touchmove"},ei=Pe.extend({options:{clickTolerance:3},initialize:function(t,e,n,i){c(this,i),this._element=t,this._dragStartTarget=e||t,this._preventOutline=n},enable:function(){this._enabled||(H(this._dragStartTarget,$n,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(ei._dragging===this&&this.finishDrag(),q(this._dragStartTarget,$n,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(!t._simulated&&this._enabled&&(this._moved=!1,!ft(this._element,"leaflet-zoom-anim")&&!(ei._dragging||t.shiftKey||1!==t.which&&1!==t.button&&!t.touches||(ei._dragging=this,this._preventOutline&&Ct(this._element),Pt(),Se(),this._moving)))){this.fire("down");var e=t.touches?t.touches[0]:t;this._startPoint=new b(e.clientX,e.clientY),H(document,ti[t.type],this._onMove,this),H(document,Jn[t.type],this._onUp,this)}},_onMove:function(t){if(!t._simulated&&this._enabled){if(t.touches&&t.touches.length>1)return void(this._moved=!0);var e=t.touches&&1===t.touches.length?t.touches[0]:t,n=new b(e.clientX,e.clientY),i=n.subtract(this._startPoint);(i.x||i.y)&&(Math.abs(i.x)+Math.abs(i.y)1e-7;u++)e=r*Math.sin(s),e=Math.pow((1-e)/(1+e),r/2),l=Math.PI/2-2*Math.atan(a*e)-s,s+=l;return new C(s*n,t.x*n/i)}},ai=(Object.freeze||Object)({LonLat:oi,Mercator:ri,SphericalMercator:ke}),si=e({},Te,{code:"EPSG:3395",projection:ri,transformation:function(){var t=.5/(Math.PI*ri.R);return O(t,.5,-t,.5)}()}),ui=e({},Te,{code:"EPSG:4326",projection:oi,transformation:O(1/180,1,-1/180,.5)}),li=e({},Ce,{projection:oi,transformation:O(1,0,-1,0),scale:function(t){return Math.pow(2,t)},zoom:function(t){return Math.log(t)/Math.LN2},distance:function(t,e){var n=e.lng-t.lng,i=e.lat-t.lat;return Math.sqrt(n*n+i*i)},infinite:!0});Ce.Earth=Te,Ce.EPSG3395=si,Ce.EPSG3857=De,Ce.EPSG900913=Ae,Ce.EPSG4326=ui,Ce.Simple=li;var ci=Pe.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(t){return t.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(t){return t&&t.removeLayer(this),this},getPane:function(t){return this._map.getPane(t?this.options[t]||t:this.options.pane)},addInteractiveTarget:function(t){return this._map._targets[i(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[i(t)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(t){var e=t.target;if(e.hasLayer(this)){if(this._map=e,this._zoomAnimated=e._zoomAnimated,this.getEvents){var n=this.getEvents();e.on(n,this),this.once("remove",function(){e.off(n,this)},this)}this.onAdd(e),this.getAttribution&&e.attributionControl&&e.attributionControl.addAttribution(this.getAttribution()),this.fire("add"),e.fire("layeradd",{layer:this})}}});zn.include({addLayer:function(t){if(!t._layerAdd)throw new Error("The provided object is not a Layer.");var e=i(t);return this._layers[e]?this:(this._layers[e]=t,t._mapToAdd=this,t.beforeAdd&&t.beforeAdd(this),this.whenReady(t._layerAdd,t),this)},removeLayer:function(t){var e=i(t);return this._layers[e]?(this._loaded&&t.onRemove(this),t.getAttribution&&this.attributionControl&&this.attributionControl.removeAttribution(t.getAttribution()),delete this._layers[e],this._loaded&&(this.fire("layerremove",{layer:t}),t.fire("remove")),t._map=t._mapToAdd=null,this):this},hasLayer:function(t){return!!t&&i(t)in this._layers},eachLayer:function(t,e){for(var n in this._layers)t.call(e,this._layers[n]);return this},_addLayers:function(t){t=t?ve(t)?t:[t]:[];for(var e=0,n=t.length;ethis._layersMaxZoom&&this.setZoom(this._layersMaxZoom),void 0===this.options.minZoom&&this._layersMinZoom&&this.getZoom()e)return a=(i-e)/n,this._map.layerPointToLatLng([r.x-a*(r.x-o.x),r.y-a*(r.y-o.y)])},getBounds:function(){return this._bounds},addLatLng:function(t,e){return e=e||this._defaultShape(),t=T(t),e.push(t),this._bounds.extend(t),this.redraw()},_setLatLngs:function(t){this._bounds=new P,this._latlngs=this._convertLatLngs(t)},_defaultShape:function(){return Ft(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(t){for(var e=[],n=Ft(t),i=0,o=t.length;i=2&&e[0]instanceof C&&e[0].equals(e[n-1])&&e.pop(),e},_setLatLngs:function(t){xi.prototype._setLatLngs.call(this,t),Ft(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return Ft(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var t=this._renderer._bounds,e=this.options.weight,n=new b(e,e);if(t=new x(t.min.subtract(n),t.max.add(n)),this._parts=[],this._pxBounds&&this._pxBounds.intersects(t)){if(this.options.noClip)return void(this._parts=this._rings);for(var i,o=0,r=this._rings.length;ot.y!=i.y>t.y&&t.x<(i.x-n.x)*(t.y-n.y)/(i.y-n.y)+n.x&&(l=!l);return l||xi.prototype._containsPoint.call(this,t,!0)}}),Pi=fi.extend({initialize:function(t,e){c(this,e),this._layers={},t&&this.addData(t)},addData:function(t){var e,n,i,o=ve(t)?t:t.features;if(o){for(e=0,n=o.length;e0?o:[e.src])}ve(this._url)||(this._url=[this._url]),e.autoplay=!!this.options.autoplay,e.loop=!!this.options.loop;for(var s=0;so?(e.height=o+"px",dt(t,r)):mt(t,r),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var e=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),n=this._getAnchor();xt(this._container,e.add(n))},_adjustPan:function(){if(!(!this.options.autoPan||this._map._panAnim&&this._map._panAnim._inProgress)){var t=this._map,e=parseInt(st(this._container,"marginBottom"),10)||0,n=this._container.offsetHeight+e,i=this._containerWidth,o=new b(this._containerLeft,-n-this._containerBottom);o._add(wt(this._container));var r=t.layerPointToContainerPoint(o),a=M(this.options.autoPanPadding),s=M(this.options.autoPanPaddingTopLeft||a),u=M(this.options.autoPanPaddingBottomRight||a),l=t.getSize(),c=0,h=0;r.x+i+u.x>l.x&&(c=r.x+i-l.x+u.x),r.x-c-s.x<0&&(c=r.x-s.x),r.y+n+u.y>l.y&&(h=r.y+n-l.y+u.y),r.y-h-s.y<0&&(h=r.y-s.y),(c||h)&&t.fire("autopanstart").panBy([c,h])}},_onCloseButtonClick:function(t){this._close(),J(t)},_getAnchor:function(){return M(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),Li=function(t,e){return new Ii(t,e)};zn.mergeOptions({closePopupOnClick:!0}),zn.include({openPopup:function(t,e,n){return t instanceof Ii||(t=new Ii(n).setContent(t)),e&&t.setLatLng(e),this.hasLayer(t)?this:(this._popup&&this._popup.options.autoClose&&this.closePopup(),this._popup=t,this.addLayer(t))},closePopup:function(t){return t&&t!==this._popup||(t=this._popup,this._popup=null),t&&this.removeLayer(t),this}}),ci.include({bindPopup:function(t,e){return t instanceof Ii?(c(t,e),this._popup=t,t._source=this):(this._popup&&!e||(this._popup=new Ii(e,this)),this._popup.setContent(t)),this._popupHandlersAdded||(this.on({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!0),this},unbindPopup:function(){return this._popup&&(this.off({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!1,this._popup=null),this},openPopup:function(t,e){if(t instanceof ci||(e=t,t=this),t instanceof fi)for(var n in this._layers){t=this._layers[n];break}return e||(e=t.getCenter?t.getCenter():t.getLatLng()),this._popup&&this._map&&(this._popup._source=t,this._popup.update(),this._map.openPopup(this._popup,e)),this},closePopup:function(){return this._popup&&this._popup._close(),this},togglePopup:function(t){return this._popup&&(this._popup._map?this.closePopup():this.openPopup(t)),this},isPopupOpen:function(){return!!this._popup&&this._popup.isOpen()},setPopupContent:function(t){return this._popup&&this._popup.setContent(t),this},getPopup:function(){return this._popup},_openPopup:function(t){var e=t.layer||t.target;if(this._popup&&this._map)return J(t),e instanceof yi?void this.openPopup(t.layer||t.target,t.latlng):void(this._map.hasLayer(this._popup)&&this._popup._source===e?this.closePopup():this.openPopup(e,t.latlng))},_movePopup:function(t){this._popup.setLatLng(t.latlng)},_onKeyPress:function(t){13===t.originalEvent.keyCode&&this._openPopup(t)}});var Di=Si.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,interactive:!1,opacity:.9},onAdd:function(t){Si.prototype.onAdd.call(this,t),this.setOpacity(this.options.opacity),t.fire("tooltipopen",{tooltip:this}),this._source&&this._source.fire("tooltipopen",{tooltip:this},!0)},onRemove:function(t){Si.prototype.onRemove.call(this,t),t.fire("tooltipclose",{tooltip:this}),this._source&&this._source.fire("tooltipclose",{tooltip:this},!0)},getEvents:function(){var t=Si.prototype.getEvents.call(this);return sn&&!this.options.permanent&&(t.preclick=this._close),t},_close:function(){this._map&&this._map.closeTooltip(this)},_initLayout:function(){var t="leaflet-tooltip",e=t+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=ut("div",e)},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var e=this._map,n=this._container,i=e.latLngToContainerPoint(e.getCenter()),o=e.layerPointToContainerPoint(t),r=this.options.direction,a=n.offsetWidth,s=n.offsetHeight,u=M(this.options.offset),l=this._getAnchor();"top"===r?t=t.add(M(-a/2+u.x,-s+u.y+l.y,!0)):"bottom"===r?t=t.subtract(M(a/2-u.x,-u.y,!0)):"center"===r?t=t.subtract(M(a/2+u.x,s/2-l.y+u.y,!0)):"right"===r||"auto"===r&&o.xthis.options.maxZoom||ni&&this._retainParent(o,r,a,i))},_retainChildren:function(t,e,n,i){for(var o=2*t;o<2*t+2;o++)for(var r=2*e;r<2*e+2;r++){var a=new b(o,r);a.z=n+1;var s=this._tileCoordsToKey(a),u=this._tiles[s];u&&u.active?u.retain=!0:(u&&u.loaded&&(u.retain=!0),n+1this.options.maxZoom||void 0!==this.options.minZoom&&o1)return void this._setView(t,n);for(var h=o.min.y;h<=o.max.y;h++)for(var p=o.min.x;p<=o.max.x;p++){var f=new b(p,h);if(f.z=this._tileZoom,this._isValidTile(f)){var d=this._tiles[this._tileCoordsToKey(f)];d?d.current=!0:a.push(f)}}if(a.sort(function(t,e){return t.distanceTo(r)-e.distanceTo(r)}),0!==a.length){this._loading||(this._loading=!0,this.fire("loading"));var m=document.createDocumentFragment();for(p=0;pn.max.x)||!e.wrapLat&&(t.yn.max.y))return!1}if(!this.options.bounds)return!0;var i=this._tileCoordsToBounds(t);return E(this.options.bounds).overlaps(i)},_keyToBounds:function(t){return this._tileCoordsToBounds(this._keyToTileCoords(t))},_tileCoordsToNwSe:function(t){var e=this._map,n=this.getTileSize(),i=t.scaleBy(n),o=i.add(n),r=e.unproject(i,t.z),a=e.unproject(o,t.z);return[r,a]},_tileCoordsToBounds:function(t){var e=this._tileCoordsToNwSe(t),n=new P(e[0],e[1]);return this.options.noWrap||(n=this._map.wrapLatLngBounds(n)),n},_tileCoordsToKey:function(t){return t.x+":"+t.y+":"+t.z},_keyToTileCoords:function(t){var e=t.split(":"),n=new b((+e[0]),(+e[1]));return n.z=+e[2],n},_removeTile:function(t){var e=this._tiles[t];e&&(Ge||e.el.setAttribute("src",ge),lt(e.el),delete this._tiles[t],this.fire("tileunload",{tile:e.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){dt(t,"leaflet-tile");var e=this.getTileSize();t.style.width=e.x+"px",t.style.height=e.y+"px",t.onselectstart=a,t.onmousemove=a,je&&this.options.opacity<1&>(t,this.options.opacity),Fe&&!Be&&(t.style.WebkitBackfaceVisibility="hidden")},_addTile:function(t,e){var i=this._getTilePos(t),o=this._tileCoordsToKey(t),r=this.createTile(this._wrapCoords(t),n(this._tileReady,this,t));this._initTile(r),this.createTile.length<2&&_(n(this._tileReady,this,t,null,r)),xt(r,i),this._tiles[o]={el:r,coords:t,current:!0},e.appendChild(r),this.fire("tileloadstart",{tile:r,coords:t})},_tileReady:function(t,e,i){if(this._map){e&&this.fire("tileerror",{error:e,tile:i,coords:t});var o=this._tileCoordsToKey(t);i=this._tiles[o],i&&(i.loaded=+new Date,this._map._fadeAnimated?(gt(i.el,0),v(this._fadeFrame),this._fadeFrame=_(this._updateOpacity,this)):(i.active=!0,this._pruneTiles()),e||(dt(i.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:i.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),je||!this._map._fadeAnimated?_(this._pruneTiles,this):setTimeout(n(this._pruneTiles,this),250)))}},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var e=new b(this._wrapX?r(t.x,this._wrapX):t.x,this._wrapY?r(t.y,this._wrapY):t.y);return e.z=t.z,e},_pxBoundsToTileRange:function(t){var e=this.getTileSize();return new x(t.min.unscaleBy(e).floor(),t.max.unscaleBy(e).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var t in this._tiles)if(!this._tiles[t].loaded)return!1;return!0}}),ji=Ri.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1},initialize:function(t,e){this._url=t,e=c(this,e),e.detectRetina&&cn&&e.maxZoom>0&&(e.tileSize=Math.floor(e.tileSize/2),e.zoomReverse?(e.zoomOffset--,e.minZoom++):(e.zoomOffset++,e.maxZoom--),e.minZoom=Math.max(0,e.minZoom)),"string"==typeof e.subdomains&&(e.subdomains=e.subdomains.split("")),Fe||this.on("tileunload",this._onTileRemove)},setUrl:function(t,e){return this._url=t,e||this.redraw(),this},createTile:function(t,e){var i=document.createElement("img");return H(i,"load",n(this._tileOnLoad,this,e,i)),H(i,"error",n(this._tileOnError,this,e,i)),this.options.crossOrigin&&(i.crossOrigin=""),i.alt="",i.setAttribute("role","presentation"),i.src=this.getTileUrl(t),i},getTileUrl:function(t){var n={r:cn?"@2x":"",s:this._getSubdomain(t),x:t.x,y:t.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var i=this._globalTileRange.max.y-t.y;this.options.tms&&(n.y=i),n["-y"]=i}return p(this._url,e(n,this.options))},_tileOnLoad:function(t,e){je?setTimeout(n(t,this,null,e),0):t(null,e)},_tileOnError:function(t,e,n){var i=this.options.errorTileUrl;i&&e.getAttribute("src")!==i&&(e.src=i),t(n,e)},_onTileRemove:function(t){t.tile.onload=null},_getZoomForUrl:function(){var t=this._tileZoom,e=this.options.maxZoom,n=this.options.zoomReverse,i=this.options.zoomOffset;return n&&(t=e-t),t+i},_getSubdomain:function(t){var e=Math.abs(t.x+t.y)%this.options.subdomains.length;return this.options.subdomains[e]},_abortLoading:function(){var t,e;for(t in this._tiles)this._tiles[t].coords.z!==this._tileZoom&&(e=this._tiles[t].el,e.onload=a,e.onerror=a,e.complete||(e.src=ge,lt(e),delete this._tiles[t]))}}),zi=ji.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(t,n){this._url=t;var i=e({},this.defaultWmsParams);for(var o in n)o in this.options||(i[o]=n[o]);n=c(this,n);var r=n.detectRetina&&cn?2:1,a=this.getTileSize();i.width=a.x*r,i.height=a.y*r,this.wmsParams=i},onAdd:function(t){this._crs=this.options.crs||t.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var e=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[e]=this._crs.code,ji.prototype.onAdd.call(this,t)},getTileUrl:function(t){var e=this._tileCoordsToNwSe(t),n=this._crs,i=w(n.project(e[0]),n.project(e[1])),o=i.min,r=i.max,a=(this._wmsVersion>=1.3&&this._crs===ui?[o.y,o.x,r.y,r.x]:[o.x,o.y,r.x,r.y]).join(","),s=L.TileLayer.prototype.getTileUrl.call(this,t);return s+h(this.wmsParams,s,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+a},setParams:function(t,n){return e(this.wmsParams,t),n||this.redraw(),this}});ji.WMS=zi,ae.wms=se;var Ui=ci.extend({options:{padding:.1,tolerance:0},initialize:function(t){c(this,t),i(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),this._zoomAnimated&&dt(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var t={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(t.zoomanim=this._onAnimZoom),t},_onAnimZoom:function(t){this._updateTransform(t.center,t.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(t,e){var n=this._map.getZoomScale(e,this._zoom),i=wt(this._container),o=this._map.getSize().multiplyBy(.5+this.options.padding),r=this._map.project(this._center,e),a=this._map.project(t,e),s=a.subtract(r),u=o.multiplyBy(-n).add(i).add(o).subtract(s);tn?Mt(this._container,u,n):xt(this._container,u)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var t in this._layers)this._layers[t]._reset()},_onZoomEnd:function(){for(var t in this._layers)this._layers[t]._project()},_updatePaths:function(){for(var t in this._layers)this._layers[t]._update()},_update:function(){var t=this.options.padding,e=this._map.getSize(),n=this._map.containerPointToLayerPoint(e.multiplyBy(-t)).round();this._bounds=new x(n,n.add(e.multiplyBy(1+2*t)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),Fi=Ui.extend({getEvents:function(){var t=Ui.prototype.getEvents.call(this);return t.viewprereset=this._onViewPreReset,t},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Ui.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var t=this._container=document.createElement("canvas");H(t,"mousemove",o(this._onMouseMove,32,this),this),H(t,"click dblclick mousedown mouseup contextmenu",this._onClick,this),H(t,"mouseout",this._handleMouseOut,this),this._ctx=t.getContext("2d")},_destroyContainer:function(){delete this._ctx,lt(this._container),q(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var t;this._redrawBounds=null;for(var e in this._layers)t=this._layers[e],t._update();this._redraw()}},_update:function(){if(!this._map._animatingZoom||!this._bounds){this._drawnLayers={},Ui.prototype._update.call(this);var t=this._bounds,e=this._container,n=t.getSize(),i=cn?2:1;xt(e,t.min),e.width=i*n.x,e.height=i*n.y,e.style.width=n.x+"px",e.style.height=n.y+"px",cn&&this._ctx.scale(2,2),this._ctx.translate(-t.min.x,-t.min.y),this.fire("update")}},_reset:function(){Ui.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(t){this._updateDashArray(t),this._layers[i(t)]=t;var e=t._order={layer:t,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=e),this._drawLast=e,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(t){this._requestRedraw(t)},_removePath:function(t){var e=t._order,n=e.next,i=e.prev;n?n.prev=i:this._drawLast=i,i?i.next=n:this._drawFirst=n,delete t._order,delete this._layers[L.stamp(t)],this._requestRedraw(t)},_updatePath:function(t){this._extendRedrawBounds(t),t._project(),t._update(),this._requestRedraw(t)},_updateStyle:function(t){this._updateDashArray(t),this._requestRedraw(t)},_updateDashArray:function(t){if(t.options.dashArray){var e,n=t.options.dashArray.split(","),i=[];for(e=0;e')}}catch(t){return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}}(),Wi={_initContainer:function(){this._container=ut("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Ui.prototype._update.call(this),this.fire("update"))},_initPath:function(t){var e=t._container=Bi("shape");dt(e,"leaflet-vml-shape "+(this.options.className||"")),e.coordsize="1 1",t._path=Bi("path"),e.appendChild(t._path),this._updateStyle(t),this._layers[i(t)]=t},_addPath:function(t){var e=t._container;this._container.appendChild(e),t.options.interactive&&t.addInteractiveTarget(e)},_removePath:function(t){var e=t._container;lt(e),t.removeInteractiveTarget(e),delete this._layers[i(t)]},_updateStyle:function(t){var e=t._stroke,n=t._fill,i=t.options,o=t._container;o.stroked=!!i.stroke,o.filled=!!i.fill,i.stroke?(e||(e=t._stroke=Bi("stroke")),o.appendChild(e),e.weight=i.weight+"px",e.color=i.color,e.opacity=i.opacity,i.dashArray?e.dashStyle=ve(i.dashArray)?i.dashArray.join(" "):i.dashArray.replace(/( *, *)/g," "):e.dashStyle="",e.endcap=i.lineCap.replace("butt","flat"),e.joinstyle=i.lineJoin):e&&(o.removeChild(e),t._stroke=null),i.fill?(n||(n=t._fill=Bi("fill")),o.appendChild(n),n.color=i.fillColor||i.color,n.opacity=i.fillOpacity):n&&(o.removeChild(n),t._fill=null)},_updateCircle:function(t){var e=t._point.round(),n=Math.round(t._radius),i=Math.round(t._radiusY||n);this._setPath(t,t._empty()?"M0 0":"AL "+e.x+","+e.y+" "+n+","+i+" 0,23592600")},_setPath:function(t,e){t._path.v=e},_bringToFront:function(t){ht(t._container)},_bringToBack:function(t){pt(t._container)}},Gi=fn?Bi:S,Zi=Ui.extend({getEvents:function(){var t=Ui.prototype.getEvents.call(this);return t.zoomstart=this._onZoomStart,t},_initContainer:function(){this._container=Gi("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=Gi("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){lt(this._container),q(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_onZoomStart:function(){this._update()},_update:function(){if(!this._map._animatingZoom||!this._bounds){Ui.prototype._update.call(this);var t=this._bounds,e=t.getSize(),n=this._container;this._svgSize&&this._svgSize.equals(e)||(this._svgSize=e,n.setAttribute("width",e.x),n.setAttribute("height",e.y)),xt(n,t.min),n.setAttribute("viewBox",[t.min.x,t.min.y,e.x,e.y].join(" ")),this.fire("update")}},_initPath:function(t){var e=t._path=Gi("path");t.options.className&&dt(e,t.options.className),t.options.interactive&&dt(e,"leaflet-interactive"),this._updateStyle(t),this._layers[i(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){lt(t._path),t.removeInteractiveTarget(t._path),delete this._layers[i(t)]},_updatePath:function(t){t._project(),t._update()},_updateStyle:function(t){var e=t._path,n=t.options;e&&(n.stroke?(e.setAttribute("stroke",n.color),e.setAttribute("stroke-opacity",n.opacity),e.setAttribute("stroke-width",n.weight),e.setAttribute("stroke-linecap",n.lineCap),e.setAttribute("stroke-linejoin",n.lineJoin),n.dashArray?e.setAttribute("stroke-dasharray",n.dashArray):e.removeAttribute("stroke-dasharray"),n.dashOffset?e.setAttribute("stroke-dashoffset",n.dashOffset):e.removeAttribute("stroke-dashoffset")):e.setAttribute("stroke","none"),n.fill?(e.setAttribute("fill",n.fillColor||n.color),e.setAttribute("fill-opacity",n.fillOpacity),e.setAttribute("fill-rule",n.fillRule||"evenodd")):e.setAttribute("fill","none"))},_updatePoly:function(t,e){this._setPath(t,I(t._parts,e))},_updateCircle:function(t){var e=t._point,n=Math.max(Math.round(t._radius),1),i=Math.max(Math.round(t._radiusY),1)||n,o="a"+n+","+i+" 0 1,0 ",r=t._empty()?"M0 0":"M"+(e.x-n)+","+e.y+o+2*n+",0 "+o+2*-n+",0 ";this._setPath(t,r)},_setPath:function(t,e){t._path.setAttribute("d",e)},_bringToFront:function(t){ht(t._path)},_bringToBack:function(t){pt(t._path)}});fn&&Zi.include(Wi),zn.include({getRenderer:function(t){var e=t.options.renderer||this._getPaneRenderer(t.options.pane)||this.options.renderer||this._renderer;return e||(e=this._renderer=this.options.preferCanvas&&ue()||le()),this.hasLayer(e)||this.addLayer(e),e},_getPaneRenderer:function(t){if("overlayPane"===t||void 0===t)return!1;var e=this._paneRenderers[t];return void 0===e&&(e=Zi&&le({pane:t})||Fi&&ue({pane:t}),this._paneRenderers[t]=e),e}});var Hi=wi.extend({initialize:function(t,e){wi.prototype.initialize.call(this,this._boundsToLatLngs(t),e)},setBounds:function(t){return this.setLatLngs(this._boundsToLatLngs(t))},_boundsToLatLngs:function(t){return t=E(t),[t.getSouthWest(),t.getNorthWest(),t.getNorthEast(),t.getSouthEast()]}});Zi.create=Gi,Zi.pointsToPath=I,Pi.geometryToLayer=Yt,Pi.coordsToLatLng=Xt,Pi.coordsToLatLngs=Qt,Pi.latLngToCoords=$t,Pi.latLngsToCoords=Jt,Pi.getFeature=te,Pi.asFeature=ee,zn.mergeOptions({boxZoom:!0});var qi=Yn.extend({initialize:function(t){this._map=t,this._container=t._container,this._pane=t._panes.overlayPane,this._resetStateTimeout=0,t.on("unload",this._destroy,this)},addHooks:function(){H(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){q(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){lt(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){0!==this._resetStateTimeout&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(t){return!(!t.shiftKey||1!==t.which&&1!==t.button)&&(this._clearDeferredResetState(),this._resetState(),Se(),Pt(),this._startPoint=this._map.mouseEventToContainerPoint(t),void H(document,{contextmenu:J,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this))},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=ut("div","leaflet-zoom-box",this._container),dt(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(t);var e=new x(this._point,this._startPoint),n=e.getSize();xt(this._box,e.min),this._box.style.width=n.x+"px",this._box.style.height=n.y+"px"},_finish:function(){this._moved&&(lt(this._box),mt(this._container,"leaflet-crosshair")),Ie(),Et(),q(document,{contextmenu:J,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(t){if((1===t.which||1===t.button)&&(this._finish(),this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(n(this._resetState,this),0);var e=new P(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(e).fire("boxzoomend",{boxZoomBounds:e})}},_onKeyDown:function(t){27===t.keyCode&&this._finish()}});zn.addInitHook("addHandler","boxZoom",qi),zn.mergeOptions({doubleClickZoom:!0});var Vi=Yn.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(t){var e=this._map,n=e.getZoom(),i=e.options.zoomDelta,o=t.originalEvent.shiftKey?n-i:n+i;"center"===e.options.doubleClickZoom?e.setZoom(o):e.setZoomAround(t.containerPoint,o)}});zn.addInitHook("addHandler","doubleClickZoom",Vi),zn.mergeOptions({dragging:!0,inertia:!Be,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var Ki=Yn.extend({addHooks:function(){if(!this._draggable){var t=this._map;this._draggable=new ei(t._mapPane,t._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),t.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),t.on("zoomend",this._onZoomEnd,this),t.whenReady(this._onZoomEnd,this))}dt(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){mt(this._map._container,"leaflet-grab"),mt(this._map._container,"leaflet-touch-drag"),this._draggable.disable()},moved:function(){return this._draggable&&this._draggable._moved},moving:function(){return this._draggable&&this._draggable._moving},_onDragStart:function(){var t=this._map;if(t._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var e=E(this._map.options.maxBounds);this._offsetLimit=w(this._map.latLngToContainerPoint(e.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(e.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;t.fire("movestart").fire("dragstart"),t.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(t){if(this._map.options.inertia){var e=this._lastTime=+new Date,n=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(n),this._times.push(e),this._prunePositions(e)}this._map.fire("move",t).fire("drag",t)},_prunePositions:function(t){for(;this._positions.length>1&&t-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var t=this._map.getSize().divideBy(2),e=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=e.subtract(t).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(t,e){return t-(t-e)*this._viscosity},_onPreDragLimit:function(){if(this._viscosity&&this._offsetLimit){var t=this._draggable._newPos.subtract(this._draggable._startPos),e=this._offsetLimit;t.xe.max.x&&(t.x=this._viscousLimit(t.x,e.max.x)),t.y>e.max.y&&(t.y=this._viscousLimit(t.y,e.max.y)),this._draggable._newPos=this._draggable._startPos.add(t)}},_onPreDragWrap:function(){var t=this._worldWidth,e=Math.round(t/2),n=this._initialWorldOffset,i=this._draggable._newPos.x,o=(i-e+n)%t+e-n,r=(i+e+n)%t-e-n,a=Math.abs(o+n)0?r:-r))-e;this._delta=0,this._startTime=null,a&&("center"===t.options.scrollWheelZoom?t.setZoom(e+a):t.setZoomAround(this._lastMousePos,e+a))}});zn.addInitHook("addHandler","scrollWheelZoom",Xi),zn.mergeOptions({tap:!0,tapTolerance:15});var Qi=Yn.extend({addHooks:function(){H(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){q(this._map._container,"touchstart",this._onDown,this)},_onDown:function(t){if(t.touches){if($(t),this._fireClick=!0,t.touches.length>1)return this._fireClick=!1,void clearTimeout(this._holdTimeout);var e=t.touches[0],i=e.target;this._startPos=this._newPos=new b(e.clientX,e.clientY),i.tagName&&"a"===i.tagName.toLowerCase()&&dt(i,"leaflet-active"),this._holdTimeout=setTimeout(n(function(){this._isTapValid()&&(this._fireClick=!1,this._onUp(),this._simulateEvent("contextmenu",e))},this),1e3),this._simulateEvent("mousedown",e),H(document,{touchmove:this._onMove,touchend:this._onUp},this)}},_onUp:function(t){if(clearTimeout(this._holdTimeout),q(document,{touchmove:this._onMove,touchend:this._onUp},this),this._fireClick&&t&&t.changedTouches){var e=t.changedTouches[0],n=e.target;n&&n.tagName&&"a"===n.tagName.toLowerCase()&&mt(n,"leaflet-active"),this._simulateEvent("mouseup",e),this._isTapValid()&&this._simulateEvent("click",e)}},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_onMove:function(t){var e=t.touches[0];this._newPos=new b(e.clientX,e.clientY),this._simulateEvent("mousemove",e)},_simulateEvent:function(t,e){var n=document.createEvent("MouseEvents");n._simulated=!0,e.target._simulatedClick=!0,n.initMouseEvent(t,!0,!0,window,1,e.screenX,e.screenY,e.clientX,e.clientY,!1,!1,!1,!1,0,null),e.target.dispatchEvent(n)}});sn&&!an&&zn.addInitHook("addHandler","tap",Qi),zn.mergeOptions({touchZoom:sn&&!Be,bounceAtZoomLimits:!0});var $i=Yn.extend({addHooks:function(){dt(this._map._container,"leaflet-touch-zoom"),H(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){mt(this._map._container,"leaflet-touch-zoom"),q(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(t){var e=this._map;if(t.touches&&2===t.touches.length&&!e._animatingZoom&&!this._zooming){var n=e.mouseEventToContainerPoint(t.touches[0]),i=e.mouseEventToContainerPoint(t.touches[1]);this._centerPoint=e.getSize()._divideBy(2),this._startLatLng=e.containerPointToLatLng(this._centerPoint),"center"!==e.options.touchZoom&&(this._pinchStartLatLng=e.containerPointToLatLng(n.add(i)._divideBy(2))),this._startDist=n.distanceTo(i),this._startZoom=e.getZoom(),this._moved=!1,this._zooming=!0,e._stop(),H(document,"touchmove",this._onTouchMove,this),H(document,"touchend",this._onTouchEnd,this),$(t)}},_onTouchMove:function(t){if(t.touches&&2===t.touches.length&&this._zooming){var e=this._map,i=e.mouseEventToContainerPoint(t.touches[0]),o=e.mouseEventToContainerPoint(t.touches[1]),r=i.distanceTo(o)/this._startDist;if(this._zoom=e.getScaleZoom(r,this._startZoom),!e.options.bounceAtZoomLimits&&(this._zoome.getMaxZoom()&&r>1)&&(this._zoom=e._limitZoom(this._zoom)),"center"===e.options.touchZoom){if(this._center=this._startLatLng,1===r)return}else{var a=i._add(o)._divideBy(2)._subtract(this._centerPoint);if(1===r&&0===a.x&&0===a.y)return;this._center=e.unproject(e.project(this._pinchStartLatLng,this._zoom).subtract(a),this._zoom)}this._moved||(e._moveStart(!0,!1),this._moved=!0),v(this._animRequest);var s=n(e._move,e,this._center,this._zoom,{pinch:!0,round:!1});this._animRequest=_(s,this,!0),$(t)}},_onTouchEnd:function(){return this._moved&&this._zooming?(this._zooming=!1,v(this._animRequest),q(document,"touchmove",this._onTouchMove),q(document,"touchend",this._onTouchEnd),void(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)))):void(this._zooming=!1)}});zn.addInitHook("addHandler","touchZoom",$i),zn.BoxZoom=qi,zn.DoubleClickZoom=Vi,zn.Drag=Ki,zn.Keyboard=Yi,zn.ScrollWheelZoom=Xi,zn.Tap=Qi,zn.TouchZoom=$i;var Ji=window.L;window.L=t,Object.freeze=fe,t.version=pe,t.noConflict=he,t.Control=Un,t.control=Fn,t.Browser=dn,t.Evented=Pe,t.Mixin=Qn,t.Util=xe,t.Class=g,t.Handler=Yn,t.extend=e,t.bind=n,t.stamp=i,t.setOptions=c,t.DomEvent=On,t.DomUtil=Rn,t.PosAnimation=jn,t.Draggable=ei,t.LineUtil=ni,t.PolyUtil=ii,t.Point=b,t.point=M,t.Bounds=x,t.bounds=w,t.Transformation=k,t.transformation=O,t.Projection=ai,t.LatLng=C,t.latLng=T,t.LatLngBounds=P,t.latLngBounds=E,t.CRS=Ce,t.GeoJSON=Pi,t.geoJSON=ne,t.geoJson=Ci,t.Layer=ci,t.LayerGroup=hi,t.layerGroup=pi,t.FeatureGroup=fi,t.featureGroup=di,t.ImageOverlay=Ti,t.imageOverlay=ki,t.VideoOverlay=Oi,t.videoOverlay=ie,t.DivOverlay=Si,t.Popup=Ii,t.popup=Li,t.Tooltip=Di,t.tooltip=Ai,t.Icon=mi,t.icon=Gt,t.DivIcon=Ni,t.divIcon=oe,t.Marker=gi,t.marker=Zt,t.TileLayer=ji,t.tileLayer=ae,t.GridLayer=Ri,t.gridLayer=re,t.SVG=Zi,t.svg=le,t.Renderer=Ui,t.Canvas=Fi,t.canvas=ue,t.Path=yi,t.CircleMarker=bi,t.circleMarker=Ht,t.Circle=Mi,t.circle=qt,t.Polyline=xi,t.polyline=Vt,t.Polygon=wi,t.polygon=Kt,t.Rectangle=Hi,t.rectangle=ce,t.Map=zn,t.map=kt})},function(t,e,n){"use strict";function i(t,e,n,i){this.dispatchConfig=t,this._targetInst=e,this.nativeEvent=n;var o=this.constructor.Interface;for(var r in o)if(o.hasOwnProperty(r)){var s=o[r];s?this[r]=s(n):"target"===r?this.target=i:this[r]=n[r]}var u=null!=n.defaultPrevented?n.defaultPrevented:n.returnValue===!1;return u?this.isDefaultPrevented=a.thatReturnsTrue:this.isDefaultPrevented=a.thatReturnsFalse,this.isPropagationStopped=a.thatReturnsFalse,this}var o=n(6),r=n(18),a=n(8),s=(n(2),"function"==typeof Proxy,["dispatchConfig","_targetInst","nativeEvent","isDefaultPrevented","isPropagationStopped","_dispatchListeners","_dispatchInstances"]),u={type:null,target:null,currentTarget:a.thatReturnsNull,eventPhase:null,bubbles:null,cancelable:null,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:null,isTrusted:null};o(i.prototype,{preventDefault:function(){this.defaultPrevented=!0;var t=this.nativeEvent;t&&(t.preventDefault?t.preventDefault():"unknown"!=typeof t.returnValue&&(t.returnValue=!1),this.isDefaultPrevented=a.thatReturnsTrue)},stopPropagation:function(){var t=this.nativeEvent;t&&(t.stopPropagation?t.stopPropagation():"unknown"!=typeof t.cancelBubble&&(t.cancelBubble=!0),this.isPropagationStopped=a.thatReturnsTrue)},persist:function(){this.isPersistent=a.thatReturnsTrue},isPersistent:a.thatReturnsFalse,destructor:function(){var t=this.constructor.Interface;for(var e in t)this[e]=null;for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:"";return t.join("_")+"_"+e+"_"+Date.now()},v=function(t){return Array.isArray(t)===!0&&(t.length>1&&!t.some(isNaN))},g=(e.getModeFromId=function(t,e){var n=e.find(function(e){return e.id===t});return n?n.type===d.MAP?m.MAP_EDIT:m.IMAGE_EDIT:m.DEFAULT},e.imagePoint=function(t,e){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return v(t)&&"string"==typeof e?{img_name:e,type:d.IMAGE,coord:[].concat(o(t)),id:_(t,e),hasImage:n}:null},e.mapPoint=function(t,e){return v(t)?{type:d.MAP,coord:[].concat(o(t)),id:_(t),label:e}:null},e.generateGcpOutput=function(t,e,n,i){var o=[];return Object.keys(t).forEach(function(r){var a=e.find(function(t){return t.id===r});if(void 0!==a){var u=(0,s.default)(n,i,a.coord.slice().reverse());t[r].forEach(function(t){var n=e.find(function(e){return e.id===t});void 0!==n&&o.push([u[0].toFixed(2),u[1].toFixed(2),n.coord[2]||0,n.coord[0].toFixed(2),n.coord[1].toFixed(2),n.img_name].join("\t"))})}}),o},function(t,e){return(0,f.default)((0,l.default)((0,h.default)(t).filter(function(t){var n=r(t,2),i=n[0],o=n[1];return e===i||o.indexOf(e)>=0})))});e.relatedPoints=function(t,e,n){var i=g(e,n);return i.length>0?i:t.filter(function(t){return n===t.id}).map(function(t){return t.id})},e.validate=function(t,e){var n=[];if(t.length<15&&n.push('A ground control point file must have a minimum of 15 points. There needs to be 5 control objects and each control object must have 3 image points referenced. Please see this article for more information.'),n.length)return{valid:!1,errors:n};var i=t.filter(function(t){return t.type===d.MAP}),o=t.length-i.length,r=Object.keys(e),a=r.filter(function(t){return t.length>=3});return o<9&&n.push("Need at least 10 image points."),i.length<5?n.push("Seems you have enough image points but not enough control objects. There must be at least 5."):r.length<5?n.push("There must be at least 5 control points that have image points referenced."):a.length<5&&n.push("Control objects must have at least 3 image points referenced."),{valid:!n.length,errors:n}}},function(t,e,n){var i;!function(o){"use strict";function r(t,e,n){var i,o=document.createElement("img");return o.onerror=function(i){return r.onerror(o,i,t,e,n)},o.onload=function(i){return r.onload(o,i,t,e,n)},"string"==typeof t?(r.fetchBlob(t,function(e){e?(t=e,i=r.createObjectURL(t)):(i=t,n&&n.crossOrigin&&(o.crossOrigin=n.crossOrigin)),o.src=i},n),o):r.isInstanceOf("Blob",t)||r.isInstanceOf("File",t)?(i=o._objectURL=r.createObjectURL(t),i?(o.src=i,o):r.readFile(t,function(t){var n=t.target;n&&n.result?o.src=n.result:e&&e(t)})):void 0}function a(t,e){!t._objectURL||e&&e.noRevoke||(r.revokeObjectURL(t._objectURL),delete t._objectURL)}var s=o.createObjectURL&&o||o.URL&&URL.revokeObjectURL&&URL||o.webkitURL&&webkitURL;r.fetchBlob=function(t,e,n){e()},r.isInstanceOf=function(t,e){return Object.prototype.toString.call(e)==="[object "+t+"]"},r.transform=function(t,e,n,i,o){n(t,o)},r.onerror=function(t,e,n,i,o){a(t,o),i&&i.call(t,e)},r.onload=function(t,e,n,i,o){a(t,o),i&&r.transform(t,o,i,n,{})},r.createObjectURL=function(t){return!!s&&s.createObjectURL(t)},r.revokeObjectURL=function(t){return!!s&&s.revokeObjectURL(t)},r.readFile=function(t,e,n){if(o.FileReader){var i=new FileReader;if(i.onload=i.onerror=e,n=n||"readAsDataURL",i[n])return i[n](t),i}return!1},i=function(){return r}.call(e,n,e,t),!(void 0!==i&&(t.exports=i))}("undefined"!=typeof window&&window||this)},[293,3],function(t,e,n){"use strict";function i(t){if(_){var e=t.node,n=t.children;if(n.length)for(var i=0;i1){for(var _=Array(m),v=0;v1){for(var y=Array(g),b=0;b=12&&"image/jpeg"===e.type&&t.blobSlice);!s&&t.readFile(t.blobSlice.call(e,0,a),function(e){if(e.target.error)return console.log(e.target.error),void n(o);var a,s,u,l,c=e.target.result,h=new DataView(c),p=2,f=h.byteLength-4,d=p;if(65496===h.getUint16(0)){for(;p=65504&&a<=65519||65534===a);){if(s=h.getUint16(p+2)+2,p+s>h.byteLength){console.log("Invalid meta data: Invalid segment size.");break}if(u=t.metaDataParsers.jpeg[a])for(l=0;l6&&(c.slice?o.imageHead=c.slice(0,d):o.imageHead=new Uint8Array(c).subarray(0,d))}else console.log("Invalid JPEG file: Missing JPEG marker.");n(o)},"readAsArrayBuffer")||n(o)},t.hasMetaOption=function(t){return t&&t.meta};var n=t.transform;t.transform=function(e,i,o,r,a){t.hasMetaOption(i)?t.parseMetaData(r,function(a){n.call(t,e,i,o,r,a)},i,a):n.apply(t,arguments)}})},function(t,e,n){"use strict";var i={};t.exports=i},function(t,e,n){"use strict";function i(t){return Object.prototype.hasOwnProperty.call(t,m)||(t[m]=f++,h[t[m]]={}),h[t[m]]}var o,r=n(6),a=n(44),s=n(227),u=n(83),l=n(259),c=n(55),h={},p=!1,f=0,d={topAbort:"abort",topAnimationEnd:l("animationend")||"animationend",topAnimationIteration:l("animationiteration")||"animationiteration",topAnimationStart:l("animationstart")||"animationstart",topBlur:"blur",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topChange:"change",topClick:"click",topCompositionEnd:"compositionend",topCompositionStart:"compositionstart",topCompositionUpdate:"compositionupdate",topContextMenu:"contextmenu",topCopy:"copy",topCut:"cut",topDoubleClick:"dblclick",topDrag:"drag",topDragEnd:"dragend",topDragEnter:"dragenter",topDragExit:"dragexit",topDragLeave:"dragleave",topDragOver:"dragover",topDragStart:"dragstart",topDrop:"drop",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topFocus:"focus",topInput:"input",topKeyDown:"keydown",topKeyPress:"keypress",topKeyUp:"keyup",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topMouseDown:"mousedown",topMouseMove:"mousemove",topMouseOut:"mouseout",topMouseOver:"mouseover",topMouseUp:"mouseup",topPaste:"paste",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topScroll:"scroll",topSeeked:"seeked",topSeeking:"seeking",topSelectionChange:"selectionchange",topStalled:"stalled",topSuspend:"suspend",topTextInput:"textInput",topTimeUpdate:"timeupdate",topTouchCancel:"touchcancel",topTouchEnd:"touchend",topTouchMove:"touchmove",topTouchStart:"touchstart",topTransitionEnd:l("transitionend")||"transitionend",topVolumeChange:"volumechange",topWaiting:"waiting",topWheel:"wheel"},m="_reactListenersID"+String(Math.random()).slice(2),_=r({},s,{ReactEventListener:null,injection:{injectReactEventListener:function(t){t.setHandleTopLevel(_.handleTopLevel),_.ReactEventListener=t}},setEnabled:function(t){_.ReactEventListener&&_.ReactEventListener.setEnabled(t)},isEnabled:function(){return!(!_.ReactEventListener||!_.ReactEventListener.isEnabled())},listenTo:function(t,e){for(var n=e,o=i(n),r=a.registrationNameDependencies[t],s=0;s]/;t.exports=i},function(t,e,n){"use strict";var i,o=n(7),r=n(43),a=/^[ \r\n\t\f]/,s=/<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/,u=n(51),l=u(function(t,e){if(t.namespaceURI!==r.svg||"innerHTML"in t)t.innerHTML=e;else{i=i||document.createElement("div"),i.innerHTML=""+e+"";for(var n=i.firstChild;n.firstChild;)t.appendChild(n.firstChild)}});if(o.canUseDOM){var c=document.createElement("div");c.innerHTML=" ",""===c.innerHTML&&(l=function(t,e){if(t.parentNode&&t.parentNode.replaceChild(t,t),a.test(e)||"<"===e[0]&&s.test(e)){t.innerHTML=String.fromCharCode(65279)+e;var n=t.firstChild;1===n.data.length?t.removeChild(n):n.deleteData(0,1)}else t.innerHTML=e}),c=null}t.exports=l},function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0}),e.isProjectionString=e.parseUtmDescriptor=e.getUtmDescriptor=e.getProj4Utm=e.getUtmZoneFromLatLng=void 0;var o=n(40),r=i(o);e.getUtmZoneFromLatLng=function(t,e){return t<-80||t>84?null:{zone:Math.floor((e+180)/6)%60+1,hemisphere:t>=0?"north":"south"}},e.getProj4Utm=function(t,e){return"+proj=utm +zone="+t+" "+("north"===e?"":"+south ")+"+ellps=WGS84 +datum=WGS84 +units=m +no_defs"},e.getUtmDescriptor=function(t,e){return"WGS84 UTM "+t+("north"===e?"N":"S")},e.parseUtmDescriptor=function(t){if(0!==t.indexOf("WGS84 UTM"))return null;var e=t.split(" ").slice("-1")[0].trim();return{zone:e.slice(0,-1),hemisphere:"N"===e.slice(-1)?"north":"south"}},e.isProjectionString=function(t){var e=t.toLowerCase();if(["epsg","+proj","utm"].some(function(t){return e.indexOf(t)>=0}))return!0;try{return new r.default.Proj(t),!0}catch(n){}return!1}},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n={map_options:{minZoom:2,scrollWheelZoom:!0,zoomControl:!1,initialZoom:2,initialCenter:[30,-20]},map_providers:[{id:"osm",label:"OpenStreetMap",url:"http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'Map data © OpenStreetMap contributors',maxZoom:19},{id:"satellite",label:"Satellite",url:"https://ecn.t{s}.tiles.virtualearth.net/tiles/a{q}.jpeg?g=587&mkt=en-gb&n=z",attribution:'Map data © OpenStreetMap contributors',maxZoom:19,useBing:!0}],custom_placeholder:"Enter template url...",custom_description:"Enter a tile URL template. Valid tokens are {z}, {x}, {y}, for Z/X/Y scheme and {u} for quadtile scheme.",image_slider_zoom_max:4,image_slider_step:.01,image_initial_scale:.5};e.default=n},function(t,e){"use strict";function n(t,e){return t===e?0!==t||0!==e||1/t===1/e:t!==t&&e!==e}function i(t,e){if(n(t,e))return!0;if("object"!=typeof t||null===t||"object"!=typeof e||null===e)return!1;var i=Object.keys(t),r=Object.keys(e);if(i.length!==r.length)return!1;for(var a=0;a0?90:-90),t.lat_ts=t.lat1)}function u(t){var e=this;if(2===arguments.length){var n=arguments[1];"string"==typeof n?"+"===n.charAt(0)?u[t]=Ke(arguments[1]):u[t]=un(arguments[1]):u[t]=n}else if(1===arguments.length){if(Array.isArray(t))return t.map(function(t){Array.isArray(t)?u.apply(e,t):u(t)});if("string"==typeof t){if(t in u)return u[t]}else"EPSG"in t?u["EPSG:"+t.EPSG]=t:"ESRI"in t?u["ESRI:"+t.ESRI]=t:"IAU2000"in t?u["IAU2000:"+t.IAU2000]=t:console.log(t);return}}function l(t){return"string"==typeof t}function c(t){return t in u}function h(t){return ln.some(function(e){return t.indexOf(e)>-1})}function p(t){return"+"===t[0]}function f(t){return l(t)?c(t)?u[t]:h(t)?un(t):p(t)?Ke(t):void 0:t}function d(){var t=this.b/this.a;this.es=1-t*t,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=hn(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)}function m(t){var e=t.x,n=t.y;if(n*Be>90&&n*Be<-90&&e*Be>180&&e*Be<-180)return null;var i,o;if(Math.abs(Math.abs(n)-Ne)<=Ue)return null;if(this.sphere)i=this.x0+this.a*this.k0*fn(e-this.long0),o=this.y0+this.a*this.k0*Math.log(Math.tan(We+.5*n));else{var r=Math.sin(n),a=dn(this.e,n,r);i=this.x0+this.a*this.k0*fn(e-this.long0),o=this.y0-this.a*this.k0*Math.log(a)}return t.x=i,t.y=o,t}function _(t){var e,n,i=t.x-this.x0,o=t.y-this.y0;if(this.sphere)n=Ne-2*Math.atan(Math.exp(-o/(this.a*this.k0)));else{var r=Math.exp(-o/(this.a*this.k0));if(n=mn(this.e,r),n===-9999)return null}return e=fn(this.long0+i/(this.a*this.k0)),t.x=e,t.y=n,t}function v(){}function g(t){return t}function y(t,e){var n=xn.length;return t.names?(xn[n]=t,t.names.forEach(function(t){Mn[t.toLowerCase()]=n}),this):(console.log(e),!0)}function b(t){if(!t)return!1;var e=t.toLowerCase();return"undefined"!=typeof Mn[e]&&xn[Mn[e]]?xn[Mn[e]]:void 0}function M(){bn.forEach(y)}function x(t,e,n,i){var o=t*t,r=e*e,a=(o-r)/o,s=0;i?(t*=1-a*(Re+a*(je+a*ze)),o=t*t,a=0):s=Math.sqrt(a);var u=(o-r)/r;return{es:a,e:s,ep2:u}}function w(e,n,i,o,r){if(!e){var a=t(Pn,o);a||(a=En),e=a.a,n=a.b,i=a.rf}return i&&!n&&(n=(1-1/i)*e),(0===i||Math.abs(e-n)3&&(0===a.datum_params[3]&&0===a.datum_params[4]&&0===a.datum_params[5]&&0===a.datum_params[6]||(a.datum_type=Ie,a.datum_params[3]*=Ae,a.datum_params[4]*=Ae,a.datum_params[5]*=Ae,a.datum_params[6]=a.datum_params[6]/1e6+1))),a.a=n,a.b=i,a.es=o,a.ep2=r,a}function E(e,n){if(!(this instanceof E))return new E(e);n=n||function(t){if(t)throw t};var i=f(e);if("object"!=typeof i)return void n(e);var o=E.projections.get(i.projName);if(!o)return void n(e);if(i.datumCode&&"none"!==i.datumCode){var r=t(Cn,i.datumCode);r&&(i.datum_params=r.towgs84?r.towgs84.split(","):null,i.ellps=r.ellipse,i.datumName=r.datumName?r.datumName:i.datumCode)}i.k0=i.k0||1,i.axis=i.axis||"enu",i.ellps=i.ellps||"wgs84";var a=w(i.a,i.b,i.rf,i.ellps,i.sphere),s=x(a.a,a.b,a.rf,i.R_A),u=i.datum||P(i.datumCode,i.datum_params,a.a,a.b,s.es,s.ep2);cn(this,i),cn(this,o),this.a=a.a,this.b=a.b,this.rf=a.rf,this.sphere=a.sphere,this.es=s.es,this.e=s.e,this.ep2=s.ep2,this.datum=u,this.init(),n(null,this)}function C(t,e){return t.datum_type===e.datum_type&&(!(t.a!==e.a||Math.abs(t.es-e.es)>5e-11)&&(t.datum_type===Se?t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]:t.datum_type!==Ie||t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]&&t.datum_params[3]===e.datum_params[3]&&t.datum_params[4]===e.datum_params[4]&&t.datum_params[5]===e.datum_params[5]&&t.datum_params[6]===e.datum_params[6]))}function T(t,e,n){var i,o,r,a,s=t.x,u=t.y,l=t.z?t.z:0;if(u<-Ne&&u>-1.001*Ne)u=-Ne;else if(u>Ne&&u<1.001*Ne)u=Ne;else if(u<-Ne||u>Ne)return null;return s>Math.PI&&(s-=2*Math.PI),o=Math.sin(u),a=Math.cos(u),r=o*o,i=n/Math.sqrt(1-e*r),{x:(i+l)*a*Math.cos(s),y:(i+l)*a*Math.sin(s),z:(i*(1-e)+l)*o}}function k(t,e,n,i){var o,r,a,s,u,l,c,h,p,f,d,m,_,v,g,y,b=1e-12,M=b*b,x=30,w=t.x,P=t.y,E=t.z?t.z:0;if(o=Math.sqrt(w*w+P*P),r=Math.sqrt(w*w+P*P+E*E),o/nM&&_=56&&c<64&&h>=3&&h<12&&(l=32),c>=72&&c<84&&(h>=0&&h<9?l=31:h>=9&&h<21?l=33:h>=21&&h<33?l=35:h>=33&&h<42&&(l=37)),e=6*(l-1)-180+3,u=B(e),n=f/(1-f),i=p/Math.sqrt(1-f*Math.sin(m)*Math.sin(m)),o=Math.tan(m)*Math.tan(m),r=n*Math.cos(m)*Math.cos(m),a=Math.cos(m)*(_-u),s=p*((1-f/4-3*f*f/64-5*f*f*f/256)*m-(3*f/8+3*f*f/32+45*f*f*f/1024)*Math.sin(2*m)+(15*f*f/256+45*f*f*f/1024)*Math.sin(4*m)-35*f*f*f/3072*Math.sin(6*m));var v=d*i*(a+(1-o+r)*a*a*a/6+(5-18*o+o*o+72*r-58*n)*a*a*a*a*a/120)+5e5,g=d*(s+i*Math.tan(m)*(a*a/2+(5-o+9*r+4*r*r)*a*a*a*a/24+(61-58*o+o*o+600*r-330*n)*a*a*a*a*a*a/720));return c<0&&(g+=1e7),{northing:Math.round(g),easting:Math.round(v),zoneNumber:l,zoneLetter:H(c)}}function Z(t){var e=t.northing,n=t.easting,i=t.zoneLetter,o=t.zoneNumber;if(o<0||o>60)return null;var r,a,s,u,l,c,h,p,f,d,m=.9996,_=6378137,v=.00669438,g=(1-Math.sqrt(1-v))/(1+Math.sqrt(1-v)),y=n-5e5,b=e;i<"N"&&(b-=1e7),p=6*(o-1)-180+3,r=v/(1-v),h=b/m,f=h/(_*(1-v/4-3*v*v/64-5*v*v*v/256)),d=f+(3*g/2-27*g*g*g/32)*Math.sin(2*f)+(21*g*g/16-55*g*g*g*g/32)*Math.sin(4*f)+151*g*g*g/96*Math.sin(6*f),a=_/Math.sqrt(1-v*Math.sin(d)*Math.sin(d)),s=Math.tan(d)*Math.tan(d),u=r*Math.cos(d)*Math.cos(d),l=_*(1-v)/Math.pow(1-v*Math.sin(d)*Math.sin(d),1.5),c=y/(a*m);var M=d-a*Math.tan(d)/l*(c*c/2-(5+3*s+10*u-4*u*u-9*r)*c*c*c*c/24+(61+90*s+298*u+45*s*s-252*r-3*u*u)*c*c*c*c*c*c/720);M=W(M);var x=(c-(1+2*s+u)*c*c*c/6+(5-2*u+28*s-3*u*u+8*r+24*s*s)*c*c*c*c*c/120)/Math.cos(d);x=p+W(x);var w;if(t.accuracy){var P=Z({northing:t.northing+t.accuracy,easting:t.easting+t.accuracy,zoneLetter:t.zoneLetter,zoneNumber:t.zoneNumber});w={top:P.lat,right:P.lon,bottom:M,left:x}}else w={lat:M,lon:x};return w}function H(t){var e="Z";return 84>=t&&t>=72?e="X":72>t&&t>=64?e="W":64>t&&t>=56?e="V":56>t&&t>=48?e="U":48>t&&t>=40?e="T":40>t&&t>=32?e="S":32>t&&t>=24?e="R":24>t&&t>=16?e="Q":16>t&&t>=8?e="P":8>t&&t>=0?e="N":0>t&&t>=-8?e="M":-8>t&&t>=-16?e="L":-16>t&&t>=-24?e="K":-24>t&&t>=-32?e="J":-32>t&&t>=-40?e="H":-40>t&&t>=-48?e="G":-48>t&&t>=-56?e="F":-56>t&&t>=-64?e="E":-64>t&&t>=-72?e="D":-72>t&&t>=-80&&(e="C"),e}function q(t,e){var n="00000"+t.easting,i="00000"+t.northing;return t.zoneNumber+t.zoneLetter+V(t.easting,t.northing,t.zoneNumber)+n.substr(n.length-5,e)+i.substr(i.length-5,e)}function V(t,e,n){var i=K(n),o=Math.floor(t/1e5),r=Math.floor(e/1e5)%20;return Y(o,r,i)}function K(t){var e=t%Ln;return 0===e&&(e=Ln),e}function Y(t,e,n){var i=n-1,o=Dn.charCodeAt(i),r=An.charCodeAt(i),a=o+t-1,s=r+e,u=!1;a>Un&&(a=a-Un+Nn-1,u=!0),(a===Rn||oRn||(a>Rn||ojn||(a>jn||oUn&&(a=a-Un+Nn-1),s>zn?(s=s-zn+Nn-1,u=!0):u=!1,(s===Rn||rRn||(s>Rn||rjn||(s>jn||rzn&&(s=s-zn+Nn-1);var l=String.fromCharCode(a)+String.fromCharCode(s);return l}function X(t){if(t&&0===t.length)throw"MGRSPoint coverting from nothing";for(var e,n=t.length,i=null,o="",r=0;!/[A-Z]/.test(e=t.charAt(r));){if(r>=2)throw"MGRSPoint bad conversion from: "+t;o+=e,r++}var a=parseInt(o,10);if(0===r||r+3>n)throw"MGRSPoint bad conversion from: "+t;var s=t.charAt(r++);if(s<="A"||"B"===s||"Y"===s||s>="Z"||"I"===s||"O"===s)throw"MGRSPoint zone letter "+s+" not handled: "+t;i=t.substring(r,r+=2);for(var u=K(a),l=Q(i.charAt(0),u),c=$(i.charAt(1),u);c0&&(p=1e5/Math.pow(10,v),f=t.substring(r,r+v),g=parseFloat(f)*p,d=t.substring(r+v),y=parseFloat(d)*p),m=g+l,_=y+c,{easting:m,northing:_,zoneLetter:s,zoneNumber:a,accuracy:p}}function Q(t,e){for(var n=Dn.charCodeAt(e-1),i=1e5,o=!1;n!==t.charCodeAt(0);){if(n++,n===Rn&&n++,n===jn&&n++,n>Un){if(o)throw"Bad character: "+t;n=Nn,o=!0}i+=1e5}return i}function $(t,e){if(t>"V")throw"MGRSPoint given invalid Northing "+t;for(var n=An.charCodeAt(e-1),i=0,o=!1;n!==t.charCodeAt(0);){if(n++,n===Rn&&n++,n===jn&&n++,n>zn){if(o)throw"Bad character: "+t;n=Nn,o=!0}i+=1e5}return i}function J(t){var e;switch(t){case"C":e=11e5;break;case"D":e=2e6;break;case"E":e=28e5;break;case"F":e=37e5;break;case"G":e=46e5;break;case"H":e=55e5;break;case"J":e=64e5;break;case"K":e=73e5;break;case"L":e=82e5;break;case"M":e=91e5;break;case"N":e=0;break;case"P":e=8e5;break;case"Q":e=17e5;break;case"R":e=26e5;break;case"S":e=35e5;break;case"T":e=44e5;break;case"U":e=53e5;break;case"V":e=62e5;break;case"W":e=7e6;break;case"X":e=79e5;break;default:e=-1}if(e>=0)return e;throw"Invalid zone letter: "+t}function tt(t,e,n){if(!(this instanceof tt))return new tt(t,e,n); +if(Array.isArray(t))this.x=t[0],this.y=t[1],this.z=t[2]||0;else if("object"==typeof t)this.x=t.x,this.y=t.y,this.z=t.z||0;else if("string"==typeof t&&"undefined"==typeof e){var i=t.split(",");this.x=parseFloat(i[0],10),this.y=parseFloat(i[1],10),this.z=parseFloat(i[2],10)||0}else this.x=t,this.y=e,this.z=n||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}function et(){this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.es&&(this.en=ti(this.es),this.ml0=ei(this.lat0,Math.sin(this.lat0),Math.cos(this.lat0),this.en))}function nt(t){var e,n,i,o=t.x,r=t.y,a=fn(o-this.long0),s=Math.sin(r),u=Math.cos(r);if(this.es){var l=u*a,c=Math.pow(l,2),h=this.ep2*Math.pow(u,2),p=Math.pow(h,2),f=Math.abs(u)>Ue?Math.tan(r):0,d=Math.pow(f,2),m=Math.pow(d,2);e=1-this.es*Math.pow(s,2),l/=Math.sqrt(e);var _=ei(r,s,u,this.en);n=this.a*(this.k0*l*(1+c/6*(1-d+h+c/20*(5-18*d+m+14*h-58*d*h+c/42*(61+179*m-m*d-479*d)))))+this.x0,i=this.a*(this.k0*(_-this.ml0+s*a*l/2*(1+c/12*(5-d+9*h+4*p+c/30*(61+m-58*d+270*h-330*d*h+c/56*(1385+543*m-m*d-3111*d))))))+this.y0}else{var v=u*Math.sin(a);if(Math.abs(Math.abs(v)-1)=1){if(v-1>Ue)return 93;i=0}else i=Math.acos(i);r<0&&(i=-i),i=this.a*this.k0*(i-this.lat0)+this.y0}return t.x=n,t.y=i,t}function it(t){var e,n,i,o,r=(t.x-this.x0)*(1/this.a),a=(t.y-this.y0)*(1/this.a);if(this.es)if(e=this.ml0+a/this.k0,n=ii(e,this.es,this.en),Math.abs(n)Ue?Math.tan(n):0,c=this.ep2*Math.pow(u,2),h=Math.pow(c,2),p=Math.pow(l,2),f=Math.pow(p,2);e=1-this.es*Math.pow(s,2);var d=r*Math.sqrt(e)/this.k0,m=Math.pow(d,2);e*=l,i=n-e*m/(1-this.es)*.5*(1-m/12*(5+3*p-9*c*p+c-4*h-m/30*(61+90*p-252*c*p+45*f+46*c-m/56*(1385+3633*p+4095*f+1574*f*p)))),o=fn(this.long0+d*(1-m/6*(1+2*p+c-m/20*(5+28*p+24*f+8*c*p+6*c-m/42*(61+662*p+1320*f+720*f*p))))/u)}else i=Ne*pn(a),o=0;else{var _=Math.exp(r/this.k0),v=.5*(_-1/_),g=this.lat0+a/this.k0,y=Math.cos(g);e=Math.sqrt((1-Math.pow(y,2))/(1+Math.pow(v,2))),i=Math.asin(e),a<0&&(i=-i),o=0===v&&0===y?0:fn(Math.atan2(v,y)+this.long0)}return t.x=o,t.y=i,t}function ot(){if(void 0===this.es||this.es<=0)throw new Error("incorrect elliptical usage");this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var t=this.es/(1+Math.sqrt(1-this.es)),e=t/(2-t),n=e;this.cgb[0]=e*(2+e*(-2/3+e*(-2+e*(116/45+e*(26/45+e*(-2854/675)))))),this.cbg[0]=e*(-2+e*(2/3+e*(4/3+e*(-82/45+e*(32/45+e*(4642/4725)))))),n*=e,this.cgb[1]=n*(7/3+e*(-1.6+e*(-227/45+e*(2704/315+e*(2323/945))))),this.cbg[1]=n*(5/3+e*(-16/15+e*(-13/9+e*(904/315+e*(-1522/945))))),n*=e,this.cgb[2]=n*(56/15+e*(-136/35+e*(-1262/105+e*(73814/2835)))),this.cbg[2]=n*(-26/15+e*(34/21+e*(1.6+e*(-12686/2835)))),n*=e,this.cgb[3]=n*(4279/630+e*(-332/35+e*(-399572/14175))),this.cbg[3]=n*(1237/630+e*(-2.4+e*(-24832/14175))),n*=e,this.cgb[4]=n*(4174/315+e*(-144838/6237)),this.cbg[4]=n*(-734/315+e*(109598/31185)),n*=e,this.cgb[5]=n*(601676/22275),this.cbg[5]=n*(444337/155925),n=Math.pow(e,2),this.Qn=this.k0/(1+e)*(1+n*(.25+n*(1/64+n/256))),this.utg[0]=e*(-.5+e*(2/3+e*(-37/96+e*(1/360+e*(81/512+e*(-96199/604800)))))),this.gtu[0]=e*(.5+e*(-2/3+e*(5/16+e*(41/180+e*(-127/288+e*(7891/37800)))))),this.utg[1]=n*(-1/48+e*(-1/15+e*(437/1440+e*(-46/105+e*(1118711/3870720))))),this.gtu[1]=n*(13/48+e*(-.6+e*(557/1440+e*(281/630+e*(-1983433/1935360))))),n*=e,this.utg[2]=n*(-17/480+e*(37/840+e*(209/4480+e*(-5569/90720)))),this.gtu[2]=n*(61/240+e*(-103/140+e*(15061/26880+e*(167603/181440)))),n*=e,this.utg[3]=n*(-4397/161280+e*(11/504+e*(830251/7257600))),this.gtu[3]=n*(49561/161280+e*(-179/168+e*(6601661/7257600))),n*=e,this.utg[4]=n*(-4583/161280+e*(108847/3991680)),this.gtu[4]=n*(34729/80640+e*(-3418889/1995840)),n*=e,this.utg[5]=n*-.03233083094085698,this.gtu[5]=.6650675310896665*n;var i=ci(this.cbg,this.lat0);this.Zb=-this.Qn*(i+hi(this.gtu,2*i))}function rt(t){var e=fn(t.x-this.long0),n=t.y;n=ci(this.cbg,n);var i=Math.sin(n),o=Math.cos(n),r=Math.sin(e),a=Math.cos(e);n=Math.atan2(i,a*o),e=Math.atan2(r*o,si(i,o*a)),e=li(Math.tan(e));var s=fi(this.gtu,2*n,2*e);n+=s[0],e+=s[1];var u,l;return Math.abs(e)<=2.623395162778?(u=this.a*(this.Qn*e)+this.x0,l=this.a*(this.Qn*n+this.Zb)+this.y0):(u=1/0,l=1/0),t.x=u,t.y=l,t}function at(t){var e=(t.x-this.x0)*(1/this.a),n=(t.y-this.y0)*(1/this.a);n=(n-this.Zb)/this.Qn,e/=this.Qn;var i,o;if(Math.abs(e)<=2.623395162778){var r=fi(this.utg,2*n,2*e);n+=r[0],e+=r[1],e=Math.atan(ai(e));var a=Math.sin(n),s=Math.cos(n),u=Math.sin(e),l=Math.cos(e);n=Math.atan2(a*l,si(u,l*s)),e=Math.atan2(u,l*s),i=fn(e+this.long0),o=ci(this.cgb,n)}else i=1/0,o=1/0;return t.x=i,t.y=o,t}function st(){var t=_i(this.zone,this.long0);if(void 0===t)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(t)-183)*Fe,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,mi.init.apply(this),this.forward=mi.forward,this.inverse=mi.inverse}function ut(){var t=Math.sin(this.lat0),e=Math.cos(this.lat0);e*=e,this.rc=Math.sqrt(1-this.es)/(1-this.es*t*t),this.C=Math.sqrt(1+this.es*e*e/(1-this.es)),this.phic0=Math.asin(t/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+We)/(Math.pow(Math.tan(.5*this.lat0+We),this.C)*bi(this.e*t,this.ratexp))}function lt(t){var e=t.x,n=t.y;return t.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*n+We),this.C)*bi(this.e*Math.sin(n),this.ratexp))-Ne,t.x=this.C*e,t}function ct(t){for(var e=1e-14,n=t.x/this.C,i=t.y,o=Math.pow(Math.tan(.5*i+We)/this.K,1/this.C),r=Mi;r>0&&(i=2*Math.atan(o*bi(this.e*Math.sin(t.y),-.5*this.e))-Ne,!(Math.abs(i-t.y)0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=Ue&&(this.k0=.5*this.cons*hn(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/dn(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=hn(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-Ne,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))}function _t(t){var e,n,i,o,r,a,s=t.x,u=t.y,l=Math.sin(u),c=Math.cos(u),h=fn(s-this.long0);return Math.abs(Math.abs(s-this.long0)-Math.PI)<=Ue&&Math.abs(u+this.lat0)<=Ue?(t.x=NaN,t.y=NaN,t):this.sphere?(e=2*this.k0/(1+this.sinlat0*l+this.coslat0*c*Math.cos(h)),t.x=this.a*e*c*Math.sin(h)+this.x0,t.y=this.a*e*(this.coslat0*l-this.sinlat0*c*Math.cos(h))+this.y0,t):(n=2*Math.atan(this.ssfn_(u,l,this.e))-Ne,o=Math.cos(n),i=Math.sin(n),Math.abs(this.coslat0)<=Ue?(r=dn(this.e,u*this.con,this.con*l),a=2*this.a*this.k0*r/this.cons,t.x=this.x0+a*Math.sin(s-this.long0),t.y=this.y0-this.con*a*Math.cos(s-this.long0),t):(Math.abs(this.sinlat0)0?this.long0+Math.atan2(t.x,-1*t.y):this.long0+Math.atan2(t.x,t.y):this.long0+Math.atan2(t.x*Math.sin(s),a*this.coslat0*Math.cos(s)-t.y*this.sinlat0*Math.sin(s))),t.x=e,t.y=n,t)}if(Math.abs(this.coslat0)<=Ue){if(a<=Ue)return n=this.lat0,e=this.long0,t.x=e,t.y=n,t;t.x*=this.con,t.y*=this.con,i=a*this.cons/(2*this.a*this.k0),n=this.con*mn(this.e,i),e=this.con*fn(this.con*this.long0+Math.atan2(t.x,-1*t.y))}else o=2*Math.atan(a*this.cosX0/(2*this.a*this.k0*this.ms1)),e=this.long0,a<=Ue?r=this.X0:(r=Math.asin(Math.cos(o)*this.sinX0+t.y*Math.sin(o)*this.cosX0/a),e=fn(this.long0+Math.atan2(t.x*Math.sin(o),a*this.cosX0*Math.cos(o)-t.y*this.sinX0*Math.sin(o)))),n=-1*mn(this.e,Math.tan(.5*(Ne+r)));return t.x=e,t.y=n,t}function gt(){var t=this.lat0;this.lambda0=this.long0;var e=Math.sin(t),n=this.a,i=this.rf,o=1/i,r=2*o-Math.pow(o,2),a=this.e=Math.sqrt(r);this.R=this.k0*n*Math.sqrt(1-r)/(1-r*Math.pow(e,2)),this.alpha=Math.sqrt(1+r/(1-r)*Math.pow(Math.cos(t),4)),this.b0=Math.asin(e/this.alpha);var s=Math.log(Math.tan(Math.PI/4+this.b0/2)),u=Math.log(Math.tan(Math.PI/4+t/2)),l=Math.log((1+a*e)/(1-a*e));this.K=s-this.alpha*u+this.alpha*a/2*l}function yt(t){var e=Math.log(Math.tan(Math.PI/4-t.y/2)),n=this.e/2*Math.log((1+this.e*Math.sin(t.y))/(1-this.e*Math.sin(t.y))),i=-this.alpha*(e+n)+this.K,o=2*(Math.atan(Math.exp(i))-Math.PI/4),r=this.alpha*(t.x-this.lambda0),a=Math.atan(Math.sin(r)/(Math.sin(this.b0)*Math.tan(o)+Math.cos(this.b0)*Math.cos(r))),s=Math.asin(Math.cos(this.b0)*Math.sin(o)-Math.sin(this.b0)*Math.cos(o)*Math.cos(r));return t.y=this.R/2*Math.log((1+Math.sin(s))/(1-Math.sin(s)))+this.y0,t.x=this.R*a+this.x0,t}function bt(t){for(var e=t.x-this.x0,n=t.y-this.y0,i=e/this.R,o=2*(Math.atan(Math.exp(n/this.R))-Math.PI/4),r=Math.asin(Math.cos(this.b0)*Math.sin(o)+Math.sin(this.b0)*Math.cos(o)*Math.cos(i)),a=Math.atan(Math.sin(i)/(Math.cos(this.b0)*Math.cos(i)-Math.sin(this.b0)*Math.tan(o))),s=this.lambda0+a/this.alpha,u=0,l=r,c=-1e3,h=0;Math.abs(l-c)>1e-7;){if(++h>20)return;u=1/this.alpha*(Math.log(Math.tan(Math.PI/4+r/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(l))/2)),c=l,l=2*Math.atan(Math.exp(u))-Math.PI/2}return t.x=s,t.y=l,t}function Mt(){this.no_off=this.no_off||!1,this.no_rot=this.no_rot||!1,isNaN(this.k0)&&(this.k0=1);var t=Math.sin(this.lat0),e=Math.cos(this.lat0),n=this.e*t;this.bl=Math.sqrt(1+this.es/(1-this.es)*Math.pow(e,4)),this.al=this.a*this.bl*this.k0*Math.sqrt(1-this.es)/(1-n*n);var i=dn(this.e,this.lat0,t),o=this.bl/e*Math.sqrt((1-this.es)/(1-n*n));o*o<1&&(o=1);var r,a;if(isNaN(this.longc)){var s=dn(this.e,this.lat1,Math.sin(this.lat1)),u=dn(this.e,this.lat2,Math.sin(this.lat2));this.lat0>=0?this.el=(o+Math.sqrt(o*o-1))*Math.pow(i,this.bl):this.el=(o-Math.sqrt(o*o-1))*Math.pow(i,this.bl);var l=Math.pow(s,this.bl),c=Math.pow(u,this.bl);r=this.el/l,a=.5*(r-1/r);var h=(this.el*this.el-c*l)/(this.el*this.el+c*l),p=(c-l)/(c+l),f=fn(this.long1-this.long2);this.long0=.5*(this.long1+this.long2)-Math.atan(h*Math.tan(.5*this.bl*f)/p)/this.bl,this.long0=fn(this.long0);var d=fn(this.long1-this.long0);this.gamma0=Math.atan(Math.sin(this.bl*d)/a),this.alpha=Math.asin(o*Math.sin(this.gamma0))}else r=this.lat0>=0?o+Math.sqrt(o*o-1):o-Math.sqrt(o*o-1),this.el=r*Math.pow(i,this.bl),a=.5*(r-1/r),this.gamma0=Math.asin(Math.sin(this.alpha)/o),this.long0=this.longc-Math.asin(a*Math.tan(this.gamma0))/this.bl;this.no_off?this.uc=0:this.lat0>=0?this.uc=this.al/this.bl*Math.atan2(Math.sqrt(o*o-1),Math.cos(this.alpha)):this.uc=-1*this.al/this.bl*Math.atan2(Math.sqrt(o*o-1),Math.cos(this.alpha))}function xt(t){var e,n,i,o=t.x,r=t.y,a=fn(o-this.long0);if(Math.abs(Math.abs(r)-Ne)<=Ue)i=r>0?-1:1,n=this.al/this.bl*Math.log(Math.tan(We+i*this.gamma0*.5)),e=-1*i*Ne*this.al/this.bl;else{var s=dn(this.e,r,Math.sin(r)),u=this.el/Math.pow(s,this.bl),l=.5*(u-1/u),c=.5*(u+1/u),h=Math.sin(this.bl*a),p=(l*Math.sin(this.gamma0)-h*Math.cos(this.gamma0))/c;n=Math.abs(Math.abs(p)-1)<=Ue?Number.POSITIVE_INFINITY:.5*this.al*Math.log((1-p)/(1+p))/this.bl,e=Math.abs(Math.cos(this.bl*a))<=Ue?this.al*this.bl*a:this.al*Math.atan2(l*Math.cos(this.gamma0)+h*Math.sin(this.gamma0),Math.cos(this.bl*a))/this.bl}return this.no_rot?(t.x=this.x0+e,t.y=this.y0+n):(e-=this.uc,t.x=this.x0+n*Math.cos(this.alpha)+e*Math.sin(this.alpha),t.y=this.y0+e*Math.cos(this.alpha)-n*Math.sin(this.alpha)),t}function wt(t){var e,n;this.no_rot?(n=t.y-this.y0,e=t.x-this.x0):(n=(t.x-this.x0)*Math.cos(this.alpha)-(t.y-this.y0)*Math.sin(this.alpha),e=(t.y-this.y0)*Math.cos(this.alpha)+(t.x-this.x0)*Math.sin(this.alpha),e+=this.uc);var i=Math.exp(-1*this.bl*n/this.al),o=.5*(i-1/i),r=.5*(i+1/i),a=Math.sin(this.bl*e/this.al),s=(a*Math.cos(this.gamma0)+o*Math.sin(this.gamma0))/r,u=Math.pow(this.el/Math.sqrt((1+s)/(1-s)),1/this.bl);return Math.abs(s-1)Ue?this.ns=Math.log(i/s)/Math.log(o/u):this.ns=e,isNaN(this.ns)&&(this.ns=e),this.f0=i/(this.ns*Math.pow(o,this.ns)),this.rh=this.a*this.f0*Math.pow(l,this.ns),this.title||(this.title="Lambert Conformal Conic")}}function Et(t){var e=t.x,n=t.y;Math.abs(2*Math.abs(n)-Math.PI)<=Ue&&(n=pn(n)*(Ne-2*Ue));var i,o,r=Math.abs(Math.abs(n)-Ne);if(r>Ue)i=dn(this.e,n,Math.sin(n)),o=this.a*this.f0*Math.pow(i,this.ns);else{if(r=n*this.ns,r<=0)return null;o=0}var a=this.ns*fn(e-this.long0);return t.x=this.k0*(o*Math.sin(a))+this.x0,t.y=this.k0*(this.rh-o*Math.cos(a))+this.y0,t}function Ct(t){var e,n,i,o,r,a=(t.x-this.x0)/this.k0,s=this.rh-(t.y-this.y0)/this.k0;this.ns>0?(e=Math.sqrt(a*a+s*s),n=1):(e=-Math.sqrt(a*a+s*s),n=-1);var u=0;if(0!==e&&(u=Math.atan2(n*a,n*s)),0!==e||this.ns>0){if(n=1/this.ns,i=Math.pow(e/(this.a*this.f0),n),o=mn(this.e,i),o===-9999)return null}else o=-Ne;return r=fn(u/this.ns+this.long0),t.x=r,t.y=o,t}function Tt(){this.a=6377397.155,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.4334234309119251),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq}function kt(t){var e,n,i,o,r,a,s,u=t.x,l=t.y,c=fn(u-this.long0);return e=Math.pow((1+this.e*Math.sin(l))/(1-this.e*Math.sin(l)),this.alfa*this.e/2),n=2*(Math.atan(this.k*Math.pow(Math.tan(l/2+this.s45),this.alfa)/e)-this.s45),i=-c*this.alfa,o=Math.asin(Math.cos(this.ad)*Math.sin(n)+Math.sin(this.ad)*Math.cos(n)*Math.cos(i)),r=Math.asin(Math.cos(n)*Math.sin(i)/Math.cos(o)),a=this.n*r,s=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(o/2+this.s45),this.n),t.y=s*Math.cos(a)/1,t.x=s*Math.sin(a)/1,this.czech||(t.y*=-1,t.x*=-1),t}function Ot(t){var e,n,i,o,r,a,s,u,l=t.x;t.x=t.y,t.y=l,this.czech||(t.y*=-1,t.x*=-1),a=Math.sqrt(t.x*t.x+t.y*t.y),r=Math.atan2(t.y,t.x),o=r/Math.sin(this.s0),i=2*(Math.atan(Math.pow(this.ro0/a,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),e=Math.asin(Math.cos(this.ad)*Math.sin(i)-Math.sin(this.ad)*Math.cos(i)*Math.cos(o)),n=Math.asin(Math.cos(i)*Math.sin(o)/Math.cos(e)),t.x=this.long0-n/this.alfa,s=e,u=0;var c=0;do t.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(e/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(s))/(1-this.e*Math.sin(s)),this.e/2))-this.s45),Math.abs(s-t.y)<1e-10&&(u=1),s=t.y,c+=1;while(0===u&&c<15);return c>=15?null:t}function St(){this.sphere||(this.e0=ji(this.es),this.e1=zi(this.es),this.e2=Ui(this.es),this.e3=Fi(this.es),this.ml0=this.a*Ri(this.e0,this.e1,this.e2,this.e3,this.lat0))}function It(t){var e,n,i=t.x,o=t.y;if(i=fn(i-this.long0),this.sphere)e=this.a*Math.asin(Math.cos(o)*Math.sin(i)),n=this.a*(Math.atan2(Math.tan(o),Math.cos(i))-this.lat0);else{var r=Math.sin(o),a=Math.cos(o),s=Bi(this.a,this.e,r),u=Math.tan(o)*Math.tan(o),l=i*Math.cos(o),c=l*l,h=this.es*a*a/(1-this.es),p=this.a*Ri(this.e0,this.e1,this.e2,this.e3,o);e=s*l*(1-c*u*(1/6-(8-u+8*h)*c/120)),n=p-this.ml0+s*r/a*c*(.5+(5-u+6*h)*c/24)}return t.x=e+this.x0,t.y=n+this.y0,t}function Lt(t){t.x-=this.x0,t.y-=this.y0;var e,n,i=t.x/this.a,o=t.y/this.a;if(this.sphere){var r=o+this.lat0;e=Math.asin(Math.sin(r)*Math.cos(i)),n=Math.atan2(Math.tan(i),Math.cos(r))}else{var a=this.ml0/this.a+o,s=Gi(a,this.e0,this.e1,this.e2,this.e3);if(Math.abs(Math.abs(s)-Ne)<=Ue)return t.x=this.long0,t.y=Ne,o<0&&(t.y*=-1),t;var u=Bi(this.a,this.e,Math.sin(s)),l=u*u*u/this.a/this.a*(1-this.es),c=Math.pow(Math.tan(s),2),h=i*this.a/u,p=h*h;e=s-u*Math.tan(s)/l*h*h*(.5-(1+3*c)*h*h/24),n=h*(1-p*(c/3+(1+3*c)*c*p/15))/Math.cos(s)}return t.x=fn(n+this.long0),t.y=Wi(e),t}function Dt(){var t=Math.abs(this.lat0);if(Math.abs(t-Ne)0){var e;switch(this.qp=qi(this.e,1),this.mmf=.5/(1-this.es),this.apa=Rt(this.es),this.mode){case this.N_POLE:this.dd=1;break;case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),e=Math.sin(this.lat0),this.sinb1=qi(this.e,e)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(1-this.es*e*e)*this.rq*this.cosb1),this.ymf=(this.xmf=this.rq)/this.dd,this.xmf*=this.dd}}else this.mode===this.OBLIQ&&(this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))}function At(t){var e,n,i,o,r,a,s,u,l,c,h=t.x,p=t.y;if(h=fn(h-this.long0),this.sphere){if(r=Math.sin(p),c=Math.cos(p),i=Math.cos(h),this.mode===this.OBLIQ||this.mode===this.EQUIT){if(n=this.mode===this.EQUIT?1+c*i:1+this.sinph0*r+this.cosph0*c*i,n<=Ue)return null;n=Math.sqrt(2/n),e=n*c*Math.sin(h),n*=this.mode===this.EQUIT?r:this.cosph0*r-this.sinph0*c*i}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(i=-i),Math.abs(p+this.phi0)=0?(e=(l=Math.sqrt(a))*o,n=i*(this.mode===this.S_POLE?l:-l)):e=n=0}}return t.x=this.a*e+this.x0,t.y=this.a*n+this.y0,t}function Nt(t){t.x-=this.x0,t.y-=this.y0;var e,n,i,o,r,a,s,u=t.x/this.a,l=t.y/this.a;if(this.sphere){var c,h=0,p=0;if(c=Math.sqrt(u*u+l*l),n=.5*c,n>1)return null;switch(n=2*Math.asin(n),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(p=Math.sin(n),h=Math.cos(n)),this.mode){case this.EQUIT:n=Math.abs(c)<=Ue?0:Math.asin(l*p/c),u*=p,l=h*c;break;case this.OBLIQ:n=Math.abs(c)<=Ue?this.phi0:Math.asin(h*this.sinph0+l*p*this.cosph0/c),u*=p*this.cosph0,l=(h-Math.sin(n)*this.sinph0)*c;break;case this.N_POLE:l=-l,n=Ne-n;break;case this.S_POLE:n-=Ne}e=0!==l||this.mode!==this.EQUIT&&this.mode!==this.OBLIQ?Math.atan2(u,l):0}else{if(s=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(u/=this.dd,l*=this.dd,a=Math.sqrt(u*u+l*l),aUe?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)}function Ut(t){var e=t.x,n=t.y;this.sin_phi=Math.sin(n),this.cos_phi=Math.cos(n);var i=qi(this.e3,this.sin_phi,this.cos_phi),o=this.a*Math.sqrt(this.c-this.ns0*i)/this.ns0,r=this.ns0*fn(e-this.long0),a=o*Math.sin(r)+this.x0,s=this.rh-o*Math.cos(r)+this.y0;return t.x=a,t.y=s,t}function Ft(t){var e,n,i,o,r,a;return t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns0>=0?(e=Math.sqrt(t.x*t.x+t.y*t.y),i=1):(e=-Math.sqrt(t.x*t.x+t.y*t.y),i=-1),o=0,0!==e&&(o=Math.atan2(i*t.x,i*t.y)),i=e*this.ns0/this.a,this.sphere?a=Math.asin((this.c-i*i)/(2*this.ns0)):(n=(this.c-i*i)/this.ns0,a=this.phi1z(this.e3,n)),r=fn(o/this.ns0+this.long0),t.x=r,t.y=a,t}function Bt(t,e){var n,i,o,r,a,s=ro(.5*e);if(t0||Math.abs(a)<=Ue?(s=this.x0+this.a*r*n*Math.sin(i)/a,u=this.y0+this.a*r*(this.cos_p14*e-this.sin_p14*n*o)/a):(s=this.x0+this.infinity_dist*n*Math.sin(i),u=this.y0+this.infinity_dist*(this.cos_p14*e-this.sin_p14*n*o)),t.x=s,t.y=u,t}function Zt(t){var e,n,i,o,r,a;return t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,(e=Math.sqrt(t.x*t.x+t.y*t.y))?(o=Math.atan2(e,this.rc),n=Math.sin(o),i=Math.cos(o),a=ro(i*this.sin_p14+t.y*n*this.cos_p14/e),r=Math.atan2(t.x*n,e*this.cos_p14*i-t.y*this.sin_p14*n),r=fn(this.long0+r)):(a=this.phic0,r=0),t.x=r,t.y=a,t}function Ht(){this.sphere||(this.k0=hn(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))}function qt(t){var e,n,i=t.x,o=t.y,r=fn(i-this.long0);if(this.sphere)e=this.x0+this.a*r*Math.cos(this.lat_ts),n=this.y0+this.a*Math.sin(o)/Math.cos(this.lat_ts);else{var a=qi(this.e,Math.sin(o));e=this.x0+this.a*this.k0*r,n=this.y0+this.a*a*.5/this.k0}return t.x=e,t.y=n,t}function Vt(t){t.x-=this.x0,t.y-=this.y0;var e,n;return this.sphere?(e=fn(this.long0+t.x/this.a/Math.cos(this.lat_ts)),n=Math.asin(t.y/this.a*Math.cos(this.lat_ts))):(n=co(this.e,2*t.y*this.k0/this.a),e=fn(this.long0+t.x/(this.a*this.k0))),t.x=e,t.y=n,t}function Kt(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Equidistant Cylindrical (Plate Carre)",this.rc=Math.cos(this.lat_ts)}function Yt(t){var e=t.x,n=t.y,i=fn(e-this.long0),o=Wi(n-this.lat0);return t.x=this.x0+this.a*i*this.rc,t.y=this.y0+this.a*o,t}function Xt(t){var e=t.x,n=t.y;return t.x=fn(this.long0+(e-this.x0)/(this.a*this.rc)),t.y=Wi(this.lat0+(n-this.y0)/this.a),t}function Qt(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=ji(this.es),this.e1=zi(this.es),this.e2=Ui(this.es),this.e3=Fi(this.es),this.ml0=this.a*Ri(this.e0,this.e1,this.e2,this.e3,this.lat0)}function $t(t){var e,n,i,o=t.x,r=t.y,a=fn(o-this.long0);if(i=a*Math.sin(r),this.sphere)Math.abs(r)<=Ue?(e=this.a*a,n=-1*this.a*this.lat0):(e=this.a*Math.sin(i)/Math.tan(r),n=this.a*(Wi(r-this.lat0)+(1-Math.cos(i))/Math.tan(r)));else if(Math.abs(r)<=Ue)e=this.a*a,n=-1*this.ml0;else{var s=Bi(this.a,this.e,Math.sin(r))/Math.tan(r);e=s*Math.sin(i),n=this.a*Ri(this.e0,this.e1,this.e2,this.e3,r)-this.ml0+s*(1-Math.cos(i))}return t.x=e+this.x0,t.y=n+this.y0,t}function Jt(t){var e,n,i,o,r,a,s,u,l;if(i=t.x-this.x0,o=t.y-this.y0,this.sphere)if(Math.abs(o+this.a*this.lat0)<=Ue)e=fn(i/this.a+this.long0),n=0;else{a=this.lat0+o/this.a,s=i*i/this.a/this.a+a*a,u=a;var c;for(r=_o;r;--r)if(c=Math.tan(u),l=-1*(a*(u*c+1)-u-.5*(u*u+s)*c)/((u-a)/c-1),u+=l,Math.abs(l)<=Ue){n=u;break}e=fn(this.long0+Math.asin(i*Math.tan(u)/this.a)/Math.sin(n))}else if(Math.abs(o+this.ml0)<=Ue)n=0,e=fn(this.long0+i/this.a);else{a=(this.ml0+o)/this.a,s=i*i/this.a/this.a+a*a,u=a;var h,p,f,d,m;for(r=_o;r;--r)if(m=this.e*Math.sin(u),h=Math.sqrt(1-m*m)*Math.tan(u),p=this.a*Ri(this.e0,this.e1,this.e2,this.e3,u),f=this.e0-2*this.e1*Math.cos(2*u)+4*this.e2*Math.cos(4*u)-6*this.e3*Math.cos(6*u),d=p/this.a,l=(a*(h*d+1)-d-.5*h*(d*d+s))/(this.es*Math.sin(2*u)*(d*d+s-2*a*d)/(4*h)+(a-d)*(h*f-2/Math.sin(2*u))-f),u-=l,Math.abs(l)<=Ue){n=u;break}h=Math.sqrt(1-this.es*Math.pow(Math.sin(n),2))*Math.tan(n),e=fn(this.long0+Math.asin(i*h/this.a)/Math.sin(n))}return t.x=e,t.y=n,t}function te(){this.A=[],this.A[1]=.6399175073,this.A[2]=-.1358797613,this.A[3]=.063294409,this.A[4]=-.02526853,this.A[5]=.0117879,this.A[6]=-.0055161,this.A[7]=.0026906,this.A[8]=-.001333,this.A[9]=67e-5,this.A[10]=-34e-5,this.B_re=[],this.B_im=[],this.B_re[1]=.7557853228,this.B_im[1]=0,this.B_re[2]=.249204646,this.B_im[2]=.003371507,this.B_re[3]=-.001541739,this.B_im[3]=.04105856,this.B_re[4]=-.10162907,this.B_im[4]=.01727609,this.B_re[5]=-.26623489,this.B_im[5]=-.36249218,this.B_re[6]=-.6870983,this.B_im[6]=-1.1651967,this.C_re=[],this.C_im=[],this.C_re[1]=1.3231270439,this.C_im[1]=0,this.C_re[2]=-.577245789,this.C_im[2]=-.007809598,this.C_re[3]=.508307513,this.C_im[3]=-.112208952,this.C_re[4]=-.15094762,this.C_im[4]=.18200602,this.C_re[5]=1.01418179,this.C_im[5]=1.64497696,this.C_re[6]=1.9660549,this.C_im[6]=2.5127645,this.D=[],this.D[1]=1.5627014243,this.D[2]=.5185406398,this.D[3]=-.03333098,this.D[4]=-.1052906,this.D[5]=-.0368594,this.D[6]=.007317,this.D[7]=.0122,this.D[8]=.00394,this.D[9]=-.0013}function ee(t){var e,n=t.x,i=t.y,o=i-this.lat0,r=n-this.long0,a=o/Ae*1e-5,s=r,u=1,l=0;for(e=1;e<=10;e++)u*=a,l+=this.A[e]*u;var c,h,p=l,f=s,d=1,m=0,_=0,v=0;for(e=1;e<=6;e++)c=d*p-m*f,h=m*p+d*f,d=c,m=h,_=_+this.B_re[e]*d-this.B_im[e]*m,v=v+this.B_im[e]*d+this.B_re[e]*m;return t.x=v*this.a+this.x0,t.y=_*this.a+this.y0,t}function ne(t){var e,n,i,o=t.x,r=t.y,a=o-this.x0,s=r-this.y0,u=s/this.a,l=a/this.a,c=1,h=0,p=0,f=0;for(e=1;e<=6;e++)n=c*u-h*l,i=h*u+c*l,c=n,h=i,p=p+this.C_re[e]*c-this.C_im[e]*h,f=f+this.C_im[e]*c+this.C_re[e]*h;for(var d=0;d.999999999999&&(n=.999999999999),e=Math.asin(n);var i=fn(this.long0+t.x/(.900316316158*this.a*Math.cos(e)));i<-Math.PI&&(i=-Math.PI),i>Math.PI&&(i=Math.PI),n=(2*e+Math.sin(2*e))/Math.PI,Math.abs(n)>1&&(n=1);var o=Math.asin(n);return t.x=i,t.y=o,t}function pe(){Math.abs(this.lat1+this.lat2)=0?(n=Math.sqrt(t.x*t.x+t.y*t.y),e=1):(n=-Math.sqrt(t.x*t.x+t.y*t.y),e=-1);var r=0;if(0!==n&&(r=Math.atan2(e*t.x,e*t.y)),this.sphere)return o=fn(this.long0+r/this.ns),i=Wi(this.g-n/this.a),t.x=o,t.y=i,t;var a=this.g-n/this.a;return i=Gi(a,this.e0,this.e1,this.e2,this.e3),o=fn(this.long0+r/this.ns),t.x=o,t.y=i,t}function me(){this.R=this.a}function _e(t){var e,n,i=t.x,o=t.y,r=fn(i-this.long0);Math.abs(o)<=Ue&&(e=this.x0+this.R*r,n=this.y0);var a=ro(2*Math.abs(o/Math.PI));(Math.abs(r)<=Ue||Math.abs(Math.abs(o)-Ne)<=Ue)&&(e=this.x0,n=o>=0?this.y0+Math.PI*this.R*Math.tan(.5*a):this.y0+Math.PI*this.R*-Math.tan(.5*a));var s=.5*Math.abs(Math.PI/r-r/Math.PI),u=s*s,l=Math.sin(a),c=Math.cos(a),h=c/(l+c-1),p=h*h,f=h*(2/l-1),d=f*f,m=Math.PI*this.R*(s*(h-d)+Math.sqrt(u*(h-d)*(h-d)-(d+u)*(p-d)))/(d+u);r<0&&(m=-m),e=this.x0+m;var _=u+h;return m=Math.PI*this.R*(f*_-s*Math.sqrt((d+u)*(u+1)-_*_))/(d+u),n=o>=0?this.y0+m:this.y0-m,t.x=e,t.y=n,t}function ve(t){var e,n,i,o,r,a,s,u,l,c,h,p,f;return t.x-=this.x0,t.y-=this.y0,h=Math.PI*this.R,i=t.x/h,o=t.y/h,r=i*i+o*o,a=-Math.abs(o)*(1+r),s=a-2*o*o+i*i,u=-2*a+1+2*o*o+r*r,f=o*o/u+(2*s*s*s/u/u/u-9*a*s/u/u)/27,l=(a-s*s/3/u)/u,c=2*Math.sqrt(-l/3),h=3*f/l/c,Math.abs(h)>1&&(h=h>=0?1:-1),p=Math.acos(h)/3,n=t.y>=0?(-c*Math.cos(p+Math.PI/3)-s/3/u)*Math.PI:-(-c*Math.cos(p+Math.PI/3)-s/3/u)*Math.PI,e=Math.abs(i)2*Ne*this.a)return;return n=e/this.a,i=Math.sin(n),o=Math.cos(n),r=this.long0,Math.abs(e)<=Ue?a=this.lat0:(a=ro(o*this.sin_p12+t.y*i*this.cos_p12/e),s=Math.abs(this.lat0)-Ne,r=fn(Math.abs(s)<=Ue?this.lat0>=0?this.long0+Math.atan2(t.x,-t.y):this.long0-Math.atan2(-t.x,t.y):this.long0+Math.atan2(t.x*i,e*this.cos_p12*o-t.y*this.sin_p12*i))),t.x=r,t.y=a,t}return u=ji(this.es),l=zi(this.es),c=Ui(this.es),h=Fi(this.es),Math.abs(this.sin_p12-1)<=Ue?(p=this.a*Ri(u,l,c,h,Ne),e=Math.sqrt(t.x*t.x+t.y*t.y),f=p-e,a=Gi(f/this.a,u,l,c,h),r=fn(this.long0+Math.atan2(t.x,-1*t.y)),t.x=r,t.y=a,t):Math.abs(this.sin_p12+1)<=Ue?(p=this.a*Ri(u,l,c,h,Ne),e=Math.sqrt(t.x*t.x+t.y*t.y),f=e-p,a=Gi(f/this.a,u,l,c,h),r=fn(this.long0+Math.atan2(t.x,t.y)),t.x=r,t.y=a,t):(e=Math.sqrt(t.x*t.x+t.y*t.y),_=Math.atan2(t.x,t.y),d=Bi(this.a,this.e,this.sin_p12),v=Math.cos(_),g=this.e*this.cos_p12*v,y=-g*g/(1-this.es),b=3*this.es*(1-y)*this.sin_p12*this.cos_p12*v/(1-this.es),M=e/d,x=M-y*(1+y)*Math.pow(M,3)/6-b*(1+3*y)*Math.pow(M,4)/24,w=1-y*x*x/2-M*x*x*x/6,m=Math.asin(this.sin_p12*Math.cos(x)+this.cos_p12*Math.sin(x)*v),r=fn(this.long0+Math.asin(Math.sin(_)*Math.sin(x)/Math.cos(m))),a=Math.atan((1-this.es*w*this.sin_p12/Math.sin(m))*Math.tan(m)/(1-this.es)),t.x=r,t.y=a,t)}function Me(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)}function xe(t){var e,n,i,o,r,a,s,u,l=t.x,c=t.y;return i=fn(l-this.long0),e=Math.sin(c),n=Math.cos(c),o=Math.cos(i),a=this.sin_p14*e+this.cos_p14*n*o,r=1,(a>0||Math.abs(a)<=Ue)&&(s=this.a*r*n*Math.sin(i),u=this.y0+this.a*r*(this.cos_p14*e-this.sin_p14*n*o)),t.x=s,t.y=u,t}function we(t){var e,n,i,o,r,a,s;return t.x-=this.x0,t.y-=this.y0,e=Math.sqrt(t.x*t.x+t.y*t.y),n=ro(e/this.a),i=Math.sin(n),o=Math.cos(n),a=this.long0,Math.abs(e)<=Ue?(s=this.lat0,t.x=a,t.y=s,t):(s=ro(o*this.sin_p14+t.y*i*this.cos_p14/e),r=Math.abs(this.lat0)-Ne,Math.abs(r)<=Ue?(a=fn(this.lat0>=0?this.long0+Math.atan2(t.x,-t.y):this.long0-Math.atan2(-t.x,t.y)),t.x=a,t.y=s,t):(a=fn(this.long0+Math.atan2(t.x*i,e*this.cos_p14*o-t.y*this.sin_p14*i)),t.x=a,t.y=s,t))}function Pe(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Quadrilateralized Spherical Cube",this.lat0>=Ne-We/2?this.face=Ro.TOP:this.lat0<=-(Ne-We/2)?this.face=Ro.BOTTOM:Math.abs(this.long0)<=We?this.face=Ro.FRONT:Math.abs(this.long0)<=Ne+We?this.face=this.long0>0?Ro.RIGHT:Ro.LEFT:this.face=Ro.BACK,0!==this.es&&(this.one_minus_f=1-(this.a-this.b)/this.a,this.one_minus_f_squared=this.one_minus_f*this.one_minus_f)}function Ee(t){var e,n,i,o,r,a,s={x:0,y:0},u={value:0};if(t.x-=this.long0,e=0!==this.es?Math.atan(this.one_minus_f_squared*Math.tan(t.y)):t.y,n=t.x,this.face===Ro.TOP)o=Ne-e,n>=We&&n<=Ne+We?(u.value=jo.AREA_0,i=n-Ne):n>Ne+We||n<=-(Ne+We)?(u.value=jo.AREA_1,i=n>0?n-Ze:n+Ze):n>-(Ne+We)&&n<=-We?(u.value=jo.AREA_2,i=n+Ne):(u.value=jo.AREA_3,i=n);else if(this.face===Ro.BOTTOM)o=Ne+e,n>=We&&n<=Ne+We?(u.value=jo.AREA_0,i=-n+Ne):n=-We?(u.value=jo.AREA_1,i=-n):n<-We&&n>=-(Ne+We)?(u.value=jo.AREA_2,i=-n-Ne):(u.value=jo.AREA_3,i=n>0?-n+Ze:-n-Ze);else{var l,c,h,p,f,d,m;this.face===Ro.RIGHT?n=ke(n,+Ne):this.face===Ro.BACK?n=ke(n,+Ze):this.face===Ro.LEFT&&(n=ke(n,-Ne)),p=Math.sin(e),f=Math.cos(e),d=Math.sin(n),m=Math.cos(n),l=f*m,c=f*d,h=p,this.face===Ro.FRONT?(o=Math.acos(l),i=Te(o,h,c,u)):this.face===Ro.RIGHT?(o=Math.acos(c),i=Te(o,h,-l,u)):this.face===Ro.BACK?(o=Math.acos(-l),i=Te(o,h,-c,u)):this.face===Ro.LEFT?(o=Math.acos(-c),i=Te(o,h,l,u)):(o=i=0,u.value=jo.AREA_0)}return a=Math.atan(12/Ze*(i+Math.acos(Math.sin(i)*Math.cos(We))-Ne)),r=Math.sqrt((1-Math.cos(o))/(Math.cos(a)*Math.cos(a))/(1-Math.cos(Math.atan(1/Math.cos(i))))),u.value===jo.AREA_1?a+=Ne:u.value===jo.AREA_2?a+=Ze:u.value===jo.AREA_3&&(a+=1.5*Ze),s.x=r*Math.cos(a),s.y=r*Math.sin(a),s.x=s.x*this.a+this.x0,s.y=s.y*this.a+this.y0,t.x=s.x,t.y=s.y,t}function Ce(t){var e,n,i,o,r,a,s,u,l,c={lam:0,phi:0},h={value:0};if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,n=Math.atan(Math.sqrt(t.x*t.x+t.y*t.y)),e=Math.atan2(t.y,t.x),t.x>=0&&t.x>=Math.abs(t.y)?h.value=jo.AREA_0:t.y>=0&&t.y>=Math.abs(t.x)?(h.value=jo.AREA_1,e-=Ne):t.x<0&&-t.x>=Math.abs(t.y)?(h.value=jo.AREA_2,e=e<0?e+Ze:e-Ze):(h.value=jo.AREA_3,e+=Ne),l=Ze/12*Math.tan(e),r=Math.sin(l)/(Math.cos(l)-1/Math.sqrt(2)),a=Math.atan(r),i=Math.cos(e),o=Math.tan(n),s=1-i*i*o*o*(1-Math.cos(Math.atan(1/Math.cos(a)))),s<-1?s=-1:s>1&&(s=1),this.face===Ro.TOP)u=Math.acos(s),c.phi=Ne-u,h.value===jo.AREA_0?c.lam=a+Ne:h.value===jo.AREA_1?c.lam=a<0?a+Ze:a-Ze:h.value===jo.AREA_2?c.lam=a-Ne:c.lam=a;else if(this.face===Ro.BOTTOM)u=Math.acos(s),c.phi=u-Ne,h.value===jo.AREA_0?c.lam=-a+Ne:h.value===jo.AREA_1?c.lam=-a:h.value===jo.AREA_2?c.lam=-a-Ne:c.lam=a<0?-a-Ze:-a+Ze;else{var p,f,d;p=s,l=p*p,d=l>=1?0:Math.sqrt(1-l)*Math.sin(a),l+=d*d,f=l>=1?0:Math.sqrt(1-l),h.value===jo.AREA_1?(l=f,f=-d,d=l):h.value===jo.AREA_2?(f=-f,d=-d):h.value===jo.AREA_3&&(l=f,f=d,d=-l),this.face===Ro.RIGHT?(l=p,p=-f,f=l):this.face===Ro.BACK?(p=-p,f=-f):this.face===Ro.LEFT&&(l=p,p=f,f=-l),c.phi=Math.acos(-d)-Ne,c.lam=Math.atan2(f,p),this.face===Ro.RIGHT?c.lam=ke(c.lam,-Ne):this.face===Ro.BACK?c.lam=ke(c.lam,-Ze):this.face===Ro.LEFT&&(c.lam=ke(c.lam,+Ne))}if(0!==this.es){var m,_,v;m=c.phi<0?1:0,_=Math.tan(c.phi),v=this.b/Math.sqrt(_*_+this.one_minus_f_squared),c.phi=Math.atan(Math.sqrt(this.a*this.a-v*v)/(this.one_minus_f*v)),m&&(c.phi=-c.phi)}return c.lam+=this.long0,t.x=c.lam,t.y=c.phi,t}function Te(t,e,n,i){var o;return tWe&&o<=Ne+We?(i.value=jo.AREA_1,o-=Ne):o>Ne+We||o<=-(Ne+We)?(i.value=jo.AREA_2,o=o>=0?o-Ze:o+Ze):(i.value=jo.AREA_3,o+=Ne)),o}function ke(t,e){var n=t+e;return n<-Ze?n+=Ge:n>+Ze&&(n-=Ge),n}var Oe=function(t){t("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),t("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),t("EPSG:3857","+title=WGS 84 / Pseudo-Mercator +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"),t.WGS84=t["EPSG:4326"],t["EPSG:3785"]=t["EPSG:3857"],t.GOOGLE=t["EPSG:3857"],t["EPSG:900913"]=t["EPSG:3857"],t["EPSG:102113"]=t["EPSG:3857"]},Se=1,Ie=2,Le=4,De=5,Ae=484813681109536e-20,Ne=Math.PI/2,Re=.16666666666666666,je=.04722222222222222,ze=.022156084656084655,Ue=1e-10,Fe=.017453292519943295,Be=57.29577951308232,We=Math.PI/4,Ge=2*Math.PI,Ze=3.14159265359,He={};He.greenwich=0,He.lisbon=-9.131906111111,He.paris=2.337229166667,He.bogota=-74.080916666667,He.madrid=-3.687938888889,He.rome=12.452333333333,He.bern=7.439583333333,He.jakarta=106.807719444444,He.ferro=-17.666666666667,He.brussels=4.367975,He.stockholm=18.058277777778,He.athens=23.7163375,He.oslo=10.722916666667;var qe={ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937}},Ve=/[\s_\-\/\(\)]/g,Ke=function(e){var n,i,o,r={},a=e.split("+").map(function(t){return t.trim()}).filter(function(t){return t}).reduce(function(t,e){var n=e.split("=");return n.push(!0),t[n[0].toLowerCase()]=n[1],t},{}),s={proj:"projName",datum:"datumCode",rf:function(t){r.rf=parseFloat(t)},lat_0:function(t){r.lat0=t*Fe},lat_1:function(t){r.lat1=t*Fe},lat_2:function(t){r.lat2=t*Fe},lat_ts:function(t){r.lat_ts=t*Fe},lon_0:function(t){r.long0=t*Fe},lon_1:function(t){r.long1=t*Fe},lon_2:function(t){r.long2=t*Fe},alpha:function(t){r.alpha=parseFloat(t)*Fe},lonc:function(t){r.longc=t*Fe},x_0:function(t){r.x0=parseFloat(t)},y_0:function(t){r.y0=parseFloat(t)},k_0:function(t){r.k0=parseFloat(t)},k:function(t){r.k0=parseFloat(t)},a:function(t){r.a=parseFloat(t)},b:function(t){r.b=parseFloat(t)},r_a:function(){r.R_A=!0},zone:function(t){r.zone=parseInt(t,10)},south:function(){r.utmSouth=!0},towgs84:function(t){r.datum_params=t.split(",").map(function(t){return parseFloat(t)})},to_meter:function(t){r.to_meter=parseFloat(t)},units:function(e){r.units=e;var n=t(qe,e);n&&(r.to_meter=n.to_meter)},from_greenwich:function(t){r.from_greenwich=t*Fe},pm:function(e){var n=t(He,e);r.from_greenwich=(n?n:parseFloat(e))*Fe},nadgrids:function(t){"@null"===t?r.datumCode="none":r.nadgrids=t},axis:function(t){var e="ewnsud";3===t.length&&e.indexOf(t.substr(0,1))!==-1&&e.indexOf(t.substr(1,1))!==-1&&e.indexOf(t.substr(2,1))!==-1&&(r.axis=t)}};for(n in a)i=a[n],n in s?(o=s[n],"function"==typeof o?o(i):r[o]=i):r[n]=i;return"string"==typeof r.datumCode&&"WGS84"!==r.datumCode&&(r.datumCode=r.datumCode.toLowerCase()),r},Ye=1,Xe=2,Qe=3,$e=4,Je=5,tn=-1,en=/\s/,nn=/[A-Za-z]/,on=/[A-Za-z84]/,rn=/[,\]]/,an=/[\d\.E\-\+]/;e.prototype.readCharicter=function(){var t=this.text[this.place++];if(this.state!==$e)for(;en.test(t);){if(this.place>=this.text.length)return;t=this.text[this.place++]}switch(this.state){case Ye:return this.neutral(t);case Xe:return this.keyword(t);case $e:return this.quoted(t);case Je:return this.afterquote(t);case Qe:return this.number(t);case tn:return}},e.prototype.afterquote=function(t){if('"'===t)return this.word+='"',void(this.state=$e);if(rn.test(t))return this.word=this.word.trim(),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in afterquote yet, index '+this.place)},e.prototype.afterItem=function(t){return","===t?(null!==this.word&&this.currentObject.push(this.word),this.word=null,void(this.state=Ye)):"]"===t?(this.level--,null!==this.word&&(this.currentObject.push(this.word),this.word=null),this.state=Ye,this.currentObject=this.stack.pop(),void(this.currentObject||(this.state=tn))):void 0},e.prototype.number=function(t){if(an.test(t))return void(this.word+=t);if(rn.test(t))return this.word=parseFloat(this.word),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in number yet, index '+this.place)},e.prototype.quoted=function(t){return'"'===t?void(this.state=Je):void(this.word+=t)},e.prototype.keyword=function(t){if(on.test(t))return void(this.word+=t);if("["===t){var e=[];return e.push(this.word),this.level++,null===this.root?this.root=e:this.currentObject.push(e),this.stack.push(this.currentObject),this.currentObject=e,void(this.state=Ye)}if(rn.test(t))return void this.afterItem(t);throw new Error("havn't handled \""+t+'" in keyword yet, index '+this.place)},e.prototype.neutral=function(t){if(nn.test(t))return this.word=t,void(this.state=Xe);if('"'===t)return this.word="",void(this.state=$e);if(an.test(t))return this.word=t,void(this.state=Qe);if(rn.test(t))return void this.afterItem(t);throw new Error("havn't handled \""+t+'" in neutral yet, index '+this.place)},e.prototype.output=function(){for(;this.place2&&(e.z=t[2]),t.length>3&&(e.m=t[3]),e},Sn=function(t){L(t.x),L(t.y)},In=E("WGS84"),Ln=6,Dn="AJSAJS",An="AFAFAF",Nn=65,Rn=73,jn=79,zn=86,Un=90,Fn={forward:z,inverse:U,toPoint:F};tt.fromMGRS=function(t){return new tt(F(t))},tt.prototype.toMGRS=function(t){return z([this.x,this.y],t)};var Bn="2.4.4",Wn=1,Gn=.25,Zn=.046875,Hn=.01953125,qn=.01068115234375,Vn=.75,Kn=.46875,Yn=.013020833333333334,Xn=.007120768229166667,Qn=.3645833333333333,$n=.005696614583333333,Jn=.3076171875,ti=function(t){var e=[];e[0]=Wn-t*(Gn+t*(Zn+t*(Hn+t*qn))),e[1]=t*(Vn-t*(Zn+t*(Hn+t*qn)));var n=t*t;return e[2]=n*(Kn-t*(Yn+t*Xn)),n*=t,e[3]=n*(Qn-t*$n),e[4]=n*t*Jn,e},ei=function(t,e,n,i){return n*=e,e*=e,i[0]*t-n*(i[1]+e*(i[2]+e*(i[3]+e*i[4])))},ni=20,ii=function(t,e,n){for(var i=1/(1-e),o=t,r=ni;r;--r){var a=Math.sin(o),s=1-e*a*a;if(s=(ei(o,a,Math.cos(o),n)-t)*(s*Math.sqrt(s))*i,o-=s,Math.abs(s)=0;)n=-a+i*r+t[o],a=r,r=n;return e+n*Math.sin(2*e)},hi=function(t,e){for(var n,i=2*Math.cos(e),o=t.length-1,r=t[o],a=0;--o>=0;)n=-a+i*r+t[o],a=r,r=n;return Math.sin(e)*n},pi=function(t){var e=Math.exp(t);return e=(e+1/e)/2},fi=function(t,e,n){for(var i,o,r=Math.sin(e),a=Math.cos(e),s=ai(n),u=pi(n),l=2*a*u,c=-2*r*s,h=t.length-1,p=t[h],f=0,d=0,m=0;--h>=0;)i=d,o=f,d=p,f=m,p=-i+l*d-c*f+t[h],m=-o+c*d+l*f;return l=r*u,c=a*s,[l*p-c*m,l*m+c*p]},di=["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc"],mi={init:ot,forward:rt,inverse:at,names:di},_i=function(t,e){if(void 0===t){if(t=Math.floor(30*(fn(e)+Math.PI)/Math.PI)+1,t<0)return 0;if(t>60)return 60}return t},vi="etmerc",gi=["Universal Transverse Mercator System","utm"],yi={init:st,names:gi,dependsOn:vi},bi=function(t,e){return Math.pow((1-t)/(1+t),e)},Mi=20,xi=["gauss"],wi={init:ut,forward:lt,inverse:ct,names:xi},Pi=["Stereographic_North_Pole","Oblique_Stereographic","Polar_Stereographic","sterea","Oblique Stereographic Alternative"],Ei={init:ht,forward:pt,inverse:ft,names:Pi},Ci=["stere","Stereographic_South_Pole","Polar Stereographic (variant B)"],Ti={init:mt,forward:_t,inverse:vt,names:Ci,ssfn_:dt},ki=["somerc"],Oi={init:gt,forward:yt,inverse:bt,names:ki},Si=["Hotine_Oblique_Mercator","Hotine Oblique Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin","Hotine_Oblique_Mercator_Azimuth_Center","omerc"],Ii={init:Mt,forward:xt,inverse:wt,names:Si},Li=["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_2SP","lcc"],Di={init:Pt,forward:Et,inverse:Ct,names:Li},Ai=["Krovak","krovak"],Ni={init:Tt,forward:kt,inverse:Ot,names:Ai},Ri=function(t,e,n,i,o){return t*o-e*Math.sin(2*o)+n*Math.sin(4*o)-i*Math.sin(6*o)},ji=function(t){return 1-.25*t*(1+t/16*(3+1.25*t))},zi=function(t){return.375*t*(1+.25*t*(1+.46875*t))},Ui=function(t){return.05859375*t*t*(1+.75*t)},Fi=function(t){return t*t*t*(35/3072)},Bi=function(t,e,n){var i=e*n;return t/Math.sqrt(1-i*i)},Wi=function(t){return Math.abs(t)1e-7?(n=t*e,(1-t*t)*(e/(1-n*n)-.5/t*Math.log((1-n)/(1+n)))):2*e},Vi=1,Ki=2,Yi=3,Xi=4,Qi=.3333333333333333,$i=.17222222222222222,Ji=.10257936507936508,to=.06388888888888888,eo=.0664021164021164,no=.016415012942191543,io=["Lambert Azimuthal Equal Area","Lambert_Azimuthal_Equal_Area","laea"],oo={init:Dt,forward:At,inverse:Nt,names:io,S_POLE:Vi,N_POLE:Ki,EQUIT:Yi,OBLIQ:Xi},ro=function(t){return Math.abs(t)>1&&(t=t>1?1:-1),Math.asin(t)},ao=["Albers_Conic_Equal_Area","Albers","aea"],so={init:zt,forward:Ut,inverse:Ft,names:ao,phi1z:Bt},uo=["gnom"],lo={init:Wt,forward:Gt,inverse:Zt,names:uo},co=function(t,e){var n=1-(1-t*t)/(2*t)*Math.log((1-t)/(1+t));if(Math.abs(Math.abs(e)-n)<1e-6)return e<0?-1*Ne:Ne;for(var i,o,r,a,s=Math.asin(.5*e),u=0;u<30;u++)if(o=Math.sin(s),r=Math.cos(s),a=t*o,i=Math.pow(1-a*a,2)/(2*r)*(e/(1-t*t)-o/(1-a*a)+.5/t*Math.log((1-a)/(1+a))),s+=i,Math.abs(i)<=1e-10)return s;return NaN},ho=["cea"],po={init:Ht,forward:qt,inverse:Vt,names:ho},fo=["Equirectangular","Equidistant_Cylindrical","eqc"],mo={init:Kt,forward:Yt,inverse:Xt,names:fo},_o=20,vo=["Polyconic","poly"],go={init:Qt,forward:$t,inverse:Jt,names:vo},yo=["New_Zealand_Map_Grid","nzmg"],bo={init:te,forward:ee,inverse:ne,names:yo},Mo=["Miller_Cylindrical","mill"],xo={init:ie,forward:oe,inverse:re,names:Mo},wo=20,Po=["Sinusoidal","sinu"],Eo={init:ae,forward:se,inverse:ue,names:Po},Co=["Mollweide","moll"],To={init:le,forward:ce,inverse:he,names:Co},ko=["Equidistant_Conic","eqdc"],Oo={init:pe,forward:fe,inverse:de,names:ko},So=["Van_der_Grinten_I","VanDerGrinten","vandg"],Io={init:me,forward:_e,inverse:ve,names:So},Lo=["Azimuthal_Equidistant","aeqd"],Do={init:ge,forward:ye,inverse:be,names:Lo},Ao=["ortho"],No={init:Me,forward:xe,inverse:we,names:Ao},Ro={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},jo={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4},zo=["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"],Uo={init:Pe,forward:Ee,inverse:Ce,names:zo},Fo=function(t){t.Proj.projections.add(ri),t.Proj.projections.add(mi),t.Proj.projections.add(yi),t.Proj.projections.add(Ei),t.Proj.projections.add(Ti),t.Proj.projections.add(Oi),t.Proj.projections.add(Ii),t.Proj.projections.add(Di),t.Proj.projections.add(Ni),t.Proj.projections.add(Hi),t.Proj.projections.add(oo),t.Proj.projections.add(so),t.Proj.projections.add(lo),t.Proj.projections.add(po),t.Proj.projections.add(mo),t.Proj.projections.add(go),t.Proj.projections.add(bo),t.Proj.projections.add(xo),t.Proj.projections.add(Eo),t.Proj.projections.add(To),t.Proj.projections.add(Oo),t.Proj.projections.add(Io),t.Proj.projections.add(Do),t.Proj.projections.add(No),t.Proj.projections.add(Uo)};return j.defaultDatum="WGS84",j.Proj=E,j.WGS84=new j.Proj("WGS84"),j.Point=tt,j.toPoint=On,j.defs=u,j.transform=A,j.mgrs=Fn,j.version=Bn,Fo(j),j})},function(t,e,n){t.exports=n(195)()},function(t,e,n){"use strict";function i(t,e){return Array.isArray(e)&&(e=e[1]),e?e.nextSibling:t.firstChild}function o(t,e,n){c.insertTreeBefore(t,e,n)}function r(t,e,n){Array.isArray(e)?s(t,e[0],e[1],n):m(t,e,n)}function a(t,e){if(Array.isArray(e)){var n=e[1];e=e[0],u(t,e,n),t.removeChild(n)}t.removeChild(e)}function s(t,e,n,i){for(var o=e;;){var r=o.nextSibling;if(m(t,o,i),o===n)break;o=r}}function u(t,e,n){for(;;){var i=e.nextSibling;if(i===n)break;t.removeChild(i)}}function l(t,e,n){var i=t.parentNode,o=t.nextSibling;o===e?n&&m(i,document.createTextNode(n),o):n?(d(o,n),u(i,o,e)):u(i,t,e)}var c=n(19),h=n(204),p=(n(5),n(9),n(51)),f=n(35),d=n(91),m=p(function(t,e,n){t.insertBefore(e,n)}),_=h.dangerouslyReplaceNodeWithMarkup,v={dangerouslyReplaceNodeWithMarkup:_,replaceDelimitedText:l,processUpdates:function(t,e){for(var n=0;n-1?void 0:a("96",t),!l.plugins[n]){e.extractEvents?void 0:a("97",t),l.plugins[n]=e;var i=e.eventTypes;for(var r in i)o(i[r],e,r)?void 0:a("98",r,t)}}}function o(t,e,n){l.eventNameDispatchConfigs.hasOwnProperty(n)?a("99",n):void 0,l.eventNameDispatchConfigs[n]=t;var i=t.phasedRegistrationNames;if(i){for(var o in i)if(i.hasOwnProperty(o)){var s=i[o];r(s,e,n)}return!0}return!!t.registrationName&&(r(t.registrationName,e,n),!0)}function r(t,e,n){l.registrationNameModules[t]?a("100",t):void 0,l.registrationNameModules[t]=e,l.registrationNameDependencies[t]=e.eventTypes[n].dependencies}var a=n(3),s=(n(1),null),u={},l={plugins:[],eventNameDispatchConfigs:{},registrationNameModules:{},registrationNameDependencies:{},possibleRegistrationNames:null,injectEventPluginOrder:function(t){s?a("101"):void 0,s=Array.prototype.slice.call(t),i()},injectEventPluginsByName:function(t){var e=!1;for(var n in t)if(t.hasOwnProperty(n)){var o=t[n];u.hasOwnProperty(n)&&u[n]===o||(u[n]?a("102",n):void 0,u[n]=o,e=!0)}e&&i()},getPluginModuleForEvent:function(t){var e=t.dispatchConfig;if(e.registrationName)return l.registrationNameModules[e.registrationName]||null;if(void 0!==e.phasedRegistrationNames){var n=e.phasedRegistrationNames;for(var i in n)if(n.hasOwnProperty(i)){var o=l.registrationNameModules[n[i]];if(o)return o}}return null},_resetEventPlugins:function(){s=null;for(var t in u)u.hasOwnProperty(t)&&delete u[t];l.plugins.length=0;var e=l.eventNameDispatchConfigs;for(var n in e)e.hasOwnProperty(n)&&delete e[n];var i=l.registrationNameModules;for(var o in i)i.hasOwnProperty(o)&&delete i[o]}};t.exports=l},function(t,e,n){"use strict";function i(t){return"topMouseUp"===t||"topTouchEnd"===t||"topTouchCancel"===t}function o(t){return"topMouseMove"===t||"topTouchMove"===t}function r(t){return"topMouseDown"===t||"topTouchStart"===t}function a(t,e,n,i){var o=t.type||"unknown-event";t.currentTarget=v.getNodeFromInstance(i),e?m.invokeGuardedCallbackWithCatch(o,n,t):m.invokeGuardedCallback(o,n,t),t.currentTarget=null}function s(t,e){var n=t._dispatchListeners,i=t._dispatchInstances;if(Array.isArray(n))for(var o=0;o0&&i.length<20?n+" (keys: "+i.join(", ")+")":n}function r(t,e){var n=s.get(t);if(!n){return null}return n}var a=n(3),s=(n(15),n(26)),u=(n(9),n(11)),l=(n(1),n(2),{isMounted:function(t){var e=s.get(t);return!!e&&!!e._renderedComponent},enqueueCallback:function(t,e,n){l.validateCallback(e,n);var o=r(t);return o?(o._pendingCallbacks?o._pendingCallbacks.push(e):o._pendingCallbacks=[e],void i(o)):null},enqueueCallbackInternal:function(t,e){t._pendingCallbacks?t._pendingCallbacks.push(e):t._pendingCallbacks=[e],i(t)},enqueueForceUpdate:function(t){var e=r(t,"forceUpdate");e&&(e._pendingForceUpdate=!0,i(e))},enqueueReplaceState:function(t,e,n){var o=r(t,"replaceState");o&&(o._pendingStateQueue=[e],o._pendingReplaceState=!0,void 0!==n&&null!==n&&(l.validateCallback(n,"replaceState"),o._pendingCallbacks?o._pendingCallbacks.push(n):o._pendingCallbacks=[n]),i(o))},enqueueSetState:function(t,e){var n=r(t,"setState");if(n){var o=n._pendingStateQueue||(n._pendingStateQueue=[]);o.push(e),i(n)}},enqueueElementInternal:function(t,e,n){t._pendingElement=e,t._context=n,i(t)},validateCallback:function(t,e){t&&"function"!=typeof t?a("122",e,o(t)):void 0}});t.exports=l},function(t,e){"use strict";var n=function(t){return"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,n,i,o){MSApp.execUnsafeLocalFunction(function(){return t(e,n,i,o)})}:t};t.exports=n},function(t,e){"use strict";function n(t){var e,n=t.keyCode;return"charCode"in t?(e=t.charCode,0===e&&13===n&&(e=13)):e=n,e>=32||13===e?e:0}t.exports=n},function(t,e){"use strict";function n(t){var e=this,n=e.nativeEvent;if(n.getModifierState)return n.getModifierState(t);var i=o[t];return!!i&&!!n[i]}function i(t){return n}var o={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};t.exports=i},function(t,e){"use strict";function n(t){var e=t.target||t.srcElement||window;return e.correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}t.exports=n},function(t,e,n){"use strict";function i(t,e){if(!r.canUseDOM||e&&!("addEventListener"in document))return!1;var n="on"+t,i=n in document;if(!i){var a=document.createElement("div");a.setAttribute(n,"return;"),i="function"==typeof a[n]}return!i&&o&&"wheel"===t&&(i=document.implementation.hasFeature("Events.wheel","3.0")),i}var o,r=n(7);r.canUseDOM&&(o=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),t.exports=i},function(t,e){"use strict";function n(t,e){var n=null===t||t===!1,i=null===e||e===!1;if(n||i)return n===i;var o=typeof t,r=typeof e;return"string"===o||"number"===o?"string"===r||"number"===r:"object"===r&&t.type===e.type&&t.key===e.key}t.exports=n},function(t,e,n){"use strict";var i=(n(6),n(8)),o=(n(2),i);t.exports=o},6,function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}e.__esModule=!0,e.compose=e.applyMiddleware=e.bindActionCreators=e.combineReducers=e.createStore=void 0;var o=n(102),r=i(o),a=n(286),s=i(a),u=n(285),l=i(u),c=n(284),h=i(c),p=n(101),f=i(p),d=n(103);i(d);e.createStore=r.default,e.combineReducers=s.default,e.bindActionCreators=l.default,e.applyMiddleware=h.default,e.compose=f.default},function(t,e,n){t.exports=n(17),n(62),n(29),n(148),n(61),n(147),n(149)},function(t,e,n){var i,o,r;!function(a){"use strict";o=[n(17),n(29)],i=a,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))}(function(t){"use strict";t.ExifMap=function(){return this},t.ExifMap.prototype.map={Orientation:274},t.ExifMap.prototype.get=function(t){return this[t]||this[this.map[t]]},t.getExifThumbnail=function(t,e,n){var i,o,r;if(!n||e+n>t.byteLength)return void console.log("Invalid Exif data: Invalid thumbnail data.");for(i=[],o=0;o4?n+e.getUint32(i+8,a):i+8,u+s>e.byteLength)return void console.log("Invalid Exif data: Invalid data offset.");if(1===r)return f.getValue(e,u,a);for(l=[],c=0;ct.byteLength)return void console.log("Invalid Exif data: Invalid directory offset.");if(r=t.getUint16(n,i),a=n+2+12*r,a+4>t.byteLength)return void console.log("Invalid Exif data: Invalid directory size.");for(s=0;se.byteLength)return void console.log("Invalid Exif data: Invalid segment size.");if(0!==e.getUint16(n+8))return void console.log("Invalid Exif data: Missing byte alignment offset.");switch(e.getUint16(l)){case 18761:a=!0;break;case 19789:a=!1;break;default:return void console.log("Invalid Exif data: Invalid byte alignment marker.")}if(42!==e.getUint16(l+2,a))return void console.log("Invalid Exif data: Missing TIFF marker.");s=e.getUint32(l+4,a),o.exif=new t.ExifMap,s=t.parseExifTags(e,l,l+s,a,o),s&&!r.disableExifThumbnail&&(u={exif:{}},s=t.parseExifTags(e,l,l+s,a,u),u.exif[513]&&(o.exif.Thumbnail=t.getExifThumbnail(e,l+u.exif[513],u.exif[514]))),o.exif[34665]&&!r.disableExifSub&&t.parseExifTags(e,l,l+o.exif[34665],a,o),o.exif[34853]&&!r.disableExifGps&&t.parseExifTags(e,l,l+o.exif[34853],a,o)}}},t.metaDataParsers.jpeg[65505].push(t.parseExifData)})},function(t,e,n){var i,o,r;!function(a){"use strict";o=[n(17)],i=a,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))}(function(t){"use strict";var e=t.transform;t.transform=function(n,i,o,r,a){e.call(t,t.scale(n,i,a),i,o,r,a)},t.transformCoordinates=function(){},t.getTransformedOptions=function(t,e){var n,i,o,r,a=e.aspectRatio;if(!a)return e;n={};for(i in e)e.hasOwnProperty(i)&&(n[i]=e[i]);return n.crop=!0,o=t.naturalWidth||t.width,r=t.naturalHeight||t.height,o/r>a?(n.maxWidth=r*a,n.maxHeight=r):(n.maxWidth=o,n.maxHeight=o/a),n},t.renderImageToCanvas=function(t,e,n,i,o,r,a,s,u,l){return t.getContext("2d").drawImage(e,n,i,o,r,a,s,u,l),t},t.hasCanvasOption=function(t){return t.canvas||t.crop||!!t.aspectRatio},t.scale=function(e,n,i){function o(){var t=Math.max((u||M)/M,(l||x)/x);t>1&&(M*=t,x*=t)}function r(){var t=Math.min((a||M)/M,(s||x)/x);t<1&&(M*=t,x*=t)}n=n||{};var a,s,u,l,c,h,p,f,d,m,_,v=document.createElement("canvas"),g=e.getContext||t.hasCanvasOption(n)&&v.getContext,y=e.naturalWidth||e.width,b=e.naturalHeight||e.height,M=y,x=b;if(g&&(n=t.getTransformedOptions(e,n,i),p=n.left||0,f=n.top||0,n.sourceWidth?(c=n.sourceWidth,void 0!==n.right&&void 0===n.left&&(p=y-c-n.right)):c=y-p-(n.right||0),n.sourceHeight?(h=n.sourceHeight,void 0!==n.bottom&&void 0===n.top&&(f=b-h-n.bottom)):h=b-f-(n.bottom||0),M=c,x=h),a=n.maxWidth,s=n.maxHeight,u=n.minWidth,l=n.minHeight,g&&a&&s&&n.crop?(M=a,x=s,_=c/h-a/s,_<0?(h=s*c/a,void 0===n.top&&void 0===n.bottom&&(f=(b-h)/2)):_>0&&(c=a*h/s,void 0===n.left&&void 0===n.right&&(p=(y-c)/2))):((n.contain||n.cover)&&(u=a=a||u,l=s=s||l),n.cover?(r(),o()):(o(),r())),g){if(d=n.pixelRatio,d>1&&(v.style.width=M+"px",v.style.height=x+"px",M*=d,x*=d,v.getContext("2d").scale(d,d)),m=n.downsamplingRatio,m>0&&m<1&&MM;)v.width=c*m,v.height=h*m,t.renderImageToCanvas(v,e,p,f,c,h,0,0,v.width,v.height),p=0,f=0,c=v.width,h=v.height,e=document.createElement("canvas"),e.width=c,e.height=h,t.renderImageToCanvas(e,v,0,0,c,h,0,0,c,h);return v.width=M,v.height=x,t.transformCoordinates(v,n),t.renderImageToCanvas(v,e,p,f,c,h,0,0,M,x)}return e.width=M,e.height=x,e}})},function(t,e,n){var i,o;!function(){"use strict";function n(){for(var t=[],e=0;e1)for(var n=1;n.":"function"==typeof e?" Instead of passing a class like Foo, pass React.createElement(Foo) or .":null!=e&&void 0!==e.props?" This may be caused by unintentionally loading two independent copies of React.":"");var a,s=_.createElement(z,{child:e});if(t){var u=x.get(t);a=u._processChildContext(u._context)}else a=T;var c=p(n);if(c){var h=c._currentElement,d=h.props.child;if(S(d,e)){var m=c._renderedComponent.getPublicInstance(),v=i&&function(){i.call(m)};return U._updateRootComponent(c,s,a,n,v),m}U.unmountComponentAtNode(n)}var g=o(n),y=g&&!!r(g),b=l(n),M=y&&!c&&!b,w=U._renderNewRootComponent(s,n,M,a)._renderedComponent.getPublicInstance();return i&&i.call(w),w},render:function(t,e,n){return U._renderSubtreeIntoContainer(null,t,e,n)},unmountComponentAtNode:function(t){c(t)?void 0:f("40");var e=p(t);if(!e){l(t),1===t.nodeType&&t.hasAttribute(L);return!1}return delete R[e._instance.rootID],C.batchedUpdates(u,e,t,!1),!0},_mountImageIntoNode:function(t,e,n,r,a){if(c(e)?void 0:f("41"),r){var s=o(e);if(w.canReuseMarkup(t,s))return void g.precacheNode(n,s);var u=s.getAttribute(w.CHECKSUM_ATTR_NAME);s.removeAttribute(w.CHECKSUM_ATTR_NAME);var l=s.outerHTML;s.setAttribute(w.CHECKSUM_ATTR_NAME,u);var h=t,p=i(h,l),m=" (client) "+h.substring(p-20,p+20)+"\n (server) "+l.substring(p-20,p+20);e.nodeType===A?f("42",m):void 0}if(e.nodeType===A?f("43"):void 0,a.useCreateElement){for(;e.lastChild;)e.removeChild(e.lastChild);d.insertTreeBefore(e,t,null)}else O(e,t),g.precacheNode(n,e.firstChild)}};t.exports=U},function(t,e,n){"use strict";var i=n(3),o=n(22),r=(n(1),{HOST:0,COMPOSITE:1,EMPTY:2,getType:function(t){return null===t||t===!1?r.EMPTY:o.isValidElement(t)?"function"==typeof t.type?r.COMPOSITE:r.HOST:void i("26",t)}});t.exports=r},function(t,e){"use strict";var n={currentScrollLeft:0,currentScrollTop:0,refreshScrollValues:function(t){n.currentScrollLeft=t.x,n.currentScrollTop=t.y}};t.exports=n},function(t,e,n){"use strict";function i(t,e){return null==e?o("30"):void 0,null==t?e:Array.isArray(t)?Array.isArray(e)?(t.push.apply(t,e),t):(t.push(e),t):Array.isArray(e)?[t].concat(e):[t,e]}var o=n(3);n(1);t.exports=i},function(t,e){"use strict";function n(t,e,n){Array.isArray(t)?t.forEach(e,n):t&&e.call(n,t)}t.exports=n},function(t,e,n){"use strict";function i(t){for(var e;(e=t._renderedNodeType)===o.COMPOSITE;)t=t._renderedComponent;return e===o.HOST?t._renderedComponent:e===o.EMPTY?null:void 0}var o=n(82);t.exports=i},function(t,e,n){"use strict";function i(){return!r&&o.canUseDOM&&(r="textContent"in document.documentElement?"textContent":"innerText"),r}var o=n(7),r=null;t.exports=i},function(t,e,n){"use strict";function i(t){var e=t.type,n=t.nodeName;return n&&"input"===n.toLowerCase()&&("checkbox"===e||"radio"===e)}function o(t){return t._wrapperState.valueTracker}function r(t,e){t._wrapperState.valueTracker=e}function a(t){t._wrapperState.valueTracker=null}function s(t){var e;return t&&(e=i(t)?""+t.checked:t.value),e}var u=n(5),l={_getTrackerFromNode:function(t){return o(u.getInstanceFromNode(t))},track:function(t){if(!o(t)){var e=u.getNodeFromInstance(t),n=i(e)?"checked":"value",s=Object.getOwnPropertyDescriptor(e.constructor.prototype,n),l=""+e[n];e.hasOwnProperty(n)||"function"!=typeof s.get||"function"!=typeof s.set||(Object.defineProperty(e,n,{enumerable:s.enumerable,configurable:!0,get:function(){return s.get.call(this)},set:function(t){l=""+t,s.set.call(this,t)}}),r(t,{getValue:function(){return l},setValue:function(t){l=""+t},stopTracking:function(){a(t),delete e[n]}}))}},updateValueIfChanged:function(t){if(!t)return!1;var e=o(t);if(!e)return l.track(t),!0;var n=e.getValue(),i=s(u.getNodeFromInstance(t));return i!==n&&(e.setValue(i),!0)},stopTracking:function(t){var e=o(t);e&&e.stopTracking()}};t.exports=l},function(t,e,n){"use strict";function i(t){if(t){var e=t.getName();if(e)return" Check the render method of `"+e+"`."}return""}function o(t){return"function"==typeof t&&"undefined"!=typeof t.prototype&&"function"==typeof t.prototype.mountComponent&&"function"==typeof t.prototype.receiveComponent}function r(t,e){var n;if(null===t||t===!1)n=l.create(r);else if("object"==typeof t){var s=t,u=s.type;if("function"!=typeof u&&"string"!=typeof u){var p="";p+=i(s._owner),a("130",null==u?u:typeof u,p)}"string"==typeof s.type?n=c.createInternalComponent(s):o(s.type)?(n=new s.type(s),n.getHostNode||(n.getHostNode=n.getNativeNode)):n=new h(s)}else"string"==typeof t||"number"==typeof t?n=c.createInstanceForText(t):a("131",typeof t);return n._mountIndex=0,n._mountImage=null,n}var a=n(3),s=n(6),u=n(211),l=n(77),c=n(79),h=(n(276),n(1),n(2),function(t){this.construct(t)});s(h.prototype,u,{_instantiateReactComponent:r}),t.exports=r},function(t,e){"use strict";function n(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return"input"===e?!!i[t.type]:"textarea"===e}var i={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};t.exports=n},function(t,e,n){"use strict";var i=n(7),o=n(34),r=n(35),a=function(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&3===n.nodeType)return void(n.nodeValue=e)}t.textContent=e};i.canUseDOM&&("textContent"in document.documentElement||(a=function(t,e){ +return 3===t.nodeType?void(t.nodeValue=e):void r(t,o(e))})),t.exports=a},function(t,e,n){"use strict";function i(t,e){return t&&"object"==typeof t&&null!=t.key?l.escape(t.key):e.toString(36)}function o(t,e,n,r){var p=typeof t;if("undefined"!==p&&"boolean"!==p||(t=null),null===t||"string"===p||"number"===p||"object"===p&&t.$$typeof===s)return n(r,t,""===e?c+i(t,0):e),1;var f,d,m=0,_=""===e?c:e+h;if(Array.isArray(t))for(var v=0;v=200&&t<300||304===t}function o(){void 0===s.status||i(s.status)?e.call(s,null,s):e.call(s,s,null)}var r=!1;if("undefined"==typeof window.XMLHttpRequest)return e(Error("Browser not supported"));if("undefined"==typeof n){var a=t.match(/^\s*https?:\/\/[^\/]*/);n=a&&a[0]!==location.protocol+"//"+location.hostname+(location.port?":"+location.port:"")}var s=new window.XMLHttpRequest;if(n&&!("withCredentials"in s)){s=new window.XDomainRequest;var u=e;e=function(){if(r)u.apply(this,arguments);else{var t=this,e=arguments;setTimeout(function(){u.apply(t,e)},0)}}}return"onload"in s?s.onload=o:s.onreadystatechange=function(){4===s.readyState&&o()},s.onerror=function(t){e.call(this,t||!0,null),e=function(){}},s.onprogress=function(){},s.ontimeout=function(t){e.call(this,t,null),e=function(){}},s.onabort=function(t){e.call(this,t,null),e=function(){}},s.open("GET",t,!0),s.send(null),r=!0,s}t.exports=i},function(t,e){(function(e){"use strict";function n(t){s.length||(a(),u=!0),s[s.length]=t}function i(){for(;lc){for(var e=0,n=s.length-l;e0?1:-1)*Math.log(Math.abs(u)+10)/h;var p=Math.pow(1+s,-1*u),f=p*i;f=Math.min(Math.max(f,o),a),this.onSliderChange(f)}}}},{key:"updateImageContainerSize",value:function(){if(this.el){var t=this.el.parentNode.offsetWidth,e=this.el.parentNode.offsetHeight;this.el.style.width=t+"px",this.el.style.height=e+"px"}}},{key:"getMousePosition",value:function(t){var e=this.el.getBoundingClientRect(),n="undefined"==typeof t.clientX?t.changedTouches[0].clientX:t.clientX,i="undefined"==typeof t.clientY?t.changedTouches[0].clientY:t.clientY;return[n-e.left,i-e.top]}},{key:"getCenter",value:function(){if(!this.el)return[0,0];var t=this.el.getBoundingClientRect(),e=this.el.scrollLeft+t.width/2,n=this.el.scrollTop+t.height/2;return[e,n]}},{key:"transformPosition",value:function(t,e,n){var i=this.state,o=i.imageData,r=i.imageWidth,a=i.imageHeight,s=r/o.width,u=a/o.height;return n?[t*(1/s),e*(1/u)]:[t*s,e*s]}},{key:"addPanningEvents",value:function(){window.addEventListener("mousemove",this.onDragMove),window.addEventListener("touchmove",this.onDragMove),window.addEventListener("mouseup",this.onDragStop),window.addEventListener("touchend",this.onDragStop)}},{key:"removePanningEvents",value:function(){window.removeEventListener("mousemove",this.onDragMove),window.removeEventListener("touchmove",this.onDragMove),window.removeEventListener("mouseup",this.onDragStop),window.removeEventListener("touchend",this.onDragStop)}},{key:"onDownHandler",value:function(t){var e=this.props,n=e.mode,i=e.addControlPoint,o=e.image;if(t.preventDefault(),t.target){var r=t.target.getBoundingClientRect(),a=this.getMousePosition(t),u=s(a,2),l=u[0],c=u[1];this._marker=t.target.className.indexOf("image-point")>-1?t.target:null;var h=null,p=null;if(this._marker&&(p=+t.target.dataset.selected,h=t.target.dataset.id),n===m.CP_MODES.ADDING){var f=this.getCoordinatesFromMousePosition(t),d=s(f,2),_=d[0],v=d[1];return void i([_,v],o.name,!0)}if(this._marker&&!p)return void this.props.onMarkerToggle(h);this.addPanningEvents();var g={dragging:!0,marker:!!this._marker,elHeight:this.el.clientHeight,elWidth:this.el.clientWidth,startX:l,startY:c,scrollX:this.el.scrollLeft,scrollY:this.el.scrollTop,maxX:r.width,maxY:r.height};this._dragged=!1,this.setState(g)}}},{key:"onDragMove",value:function(t){if(this.state.dragging){this._dragged=!0;var e=this.getMousePosition(t),n=s(e,2),i=n[0],o=n[1];if(this._marker){var r=this.el.scrollLeft,a=this.el.scrollTop,u=this.transformPosition(r+i,a+o,!0),l=s(u,2),c=l[0],h=l[1],p=this.transformPosition(c,h),f=s(p,2);return c=f[0],h=f[1],this._marker.style.left=c+"px",void(this._marker.style.top=h+"px")}this.el.scrollLeft=Math.min(this.state.maxX-this.state.elWidth,this.state.scrollX-(i-this.state.startX)),this.el.scrollTop=Math.min(this.state.maxY-this.state.elHeight,this.state.scrollY-(o-this.state.startY))}}},{key:"getCoordinatesFromMousePosition",value:function(t){var e=this.getMousePosition(t),n=s(e,2),i=n[0],o=n[1],r=this.el.scrollLeft,a=this.el.scrollTop,u=this.transformPosition(r+i,a+o,!0),l=s(u,2),c=l[0],h=l[1],p=this.getNativeCenter(r,a,this.state.scale);return[c,h,p]}},{key:"onDragStop",value:function(t){var e=this,n=this.props.mode;if(this.removePanningEvents(),this._dragged&&"adding"!==n){var i=this.getMousePosition(t),o=s(i,2),r=o[0],a=o[1],u=this.el.scrollLeft,l=this.el.scrollTop,c=this.transformPosition(u+r,l+a,!0),h=s(c,2),p=h[0],f=h[1],d=this.getNativeCenter(u,l,this.state.scale),m=null;this._marker&&(this._marker.style.left=p+"px",this._marker.style.top=f+"px",m=this._marker.dataset.id),this._marker=null,this.setState({dragging:!1,marker:!1,scrollLeft:u,scrollTop:l},function(){m?e.props.onMarkerDragged(m,[p,f]):e.props.onImageDragged(d)})}}},{key:"onSliderChange",value:function(t){var e=this.state.imageData;if(e.src){var n=t,i=this.scaleImage(e.width,e.height,n),o=s(i,4),r=o[0],a=o[1],u=o[2],l=o[3];this.setState({scale:n,imageWidth:r,imageHeight:a,scrollLeft:u,scrollTop:l})}}},{key:"getNativeCenter",value:function(t,e,n){var i=this.el.offsetWidth/2,o=this.el.offsetHeight/2,r=(t+i)*(1/n),a=(e+o)*(1/n);return[r,a]}},{key:"scaleImage",value:function(t,e,n,i,o){var r=this.state,a=r.scrollLeft,s=r.scrollTop,u=r.scale,l=this.el.offsetWidth/2,c=this.el.offsetHeight/2,h=e/t,p=t*n,f=p*h,d=p/t,m=f/e,_=void 0,v=void 0;if(o)return i.isPortrait?(_=f/2-l,v=p/2-c):(_=p/2-l,v=f/2-c),[p,f,_,v];var g=this.getNativeCenter(a,s,u);return _=g[0]*d-l,v=g[1]*m-c,[p,f,_,v]}},{key:"onImageLoad",value:function(t,e){var n=t.width,i=t.height,o=this.el.offsetWidth/n,r=this.el.offsetHeight/i,a=Math.round(100*Math.max(o,r))/100,u=v.default.image_initial_scale||.5;this.__scale=u;var l=this.scaleImage(n,i,u,t,!0),c=s(l,4),h=c[0],p=c[1],f=c[2],d=c[3],m=this.getNativeCenter(f,d,u);this.props.onImageDragged(m),this.setState({imageData:t,scale:u,imageWidth:h,imageHeight:p,minScale:a,scrollLeft:f,scrollTop:d})}},{key:"onActionDelete",value:function(t,e){t.preventDefault();var n=this.props.onMarkerDelete;n(e.id)}},{key:"onActionLock",value:function(t,e){t.preventDefault();var n=this.props.onMarkerToggle;n(e.id)}},{key:"renderPoints",value:function(){var t=this,e=this.props,n=e.highlightControlPoint,i=e.highlightedControlPoints,o=e.markers,r=e.selectedImage,a=e.selectedMarker;return o.map(function(e,o){if(e.type===m.CP_TYPES.IMAGE&&e.img_name===r){var u=t.transformPosition(e.coord[0],e.coord[1]),l=s(u,2),h=l[0],f=l[1],d={left:h+"px",top:f+"px"},_=a===e.id?1:0;return c.default.createElement("div",{key:"ip"+o,className:(0,p.default)("image-point","active",{draggable:_,highlighted:i.indexOf(e.id)>=0}),"data-selected":_,"data-id":e.id,style:d,onMouseOver:function(){return n(e.id)},onMouseOut:function(){return n(null)}},c.default.createElement("div",{className:"actions"},c.default.createElement("ul",null,c.default.createElement("li",null,c.default.createElement("a",{href:"#",onClick:function(n){t.onActionDelete(n,e)}},"Delete")),c.default.createElement("li",null,c.default.createElement("a",{href:"#",onClick:function(n){t.onActionLock(n,e)}},"Lock")))))}return null})}},{key:"render",value:function(){var t=this,e=this.state,n=e.imageData,i=e.imageWidth,o=e.imageHeight,r=this.props,a=r.image,s=r.height,u=n.isPortrait?o:i,l=n.isPortrait?i:o;return c.default.createElement("div",{className:"imgpanzoom-container"},c.default.createElement("div",{ref:function(e){t.el=e},className:"imagepanzoom",onMouseDown:this.onDownHandler,onTouchStart:this.onDownHandler,onWheel:this.onWheel,onDoubleClick:this.onDoubleClick,style:{height:s}},c.default.createElement("div",{className:"points-layer",style:{width:u+"px",height:l+"px"}},this.renderPoints()),c.default.createElement(d.default,{srcToLoad:a,srcToDisplay:n.src,width:i,height:o,needsRevoking:n.needsRevoking,orientation:n.orientation,onImageLoad:this.onImageLoad})))}}]),e}(l.Component);g.propTypes={image:l.PropTypes.object,markers:l.PropTypes.array,selectedMarker:l.PropTypes.any,selectedImage:l.PropTypes.string,onImageDragged:l.PropTypes.func,onMarkerToggle:l.PropTypes.func,onMarkerDelete:l.PropTypes.func,highlightedControlPoints:l.PropTypes.array,highlightControlPoint:l.PropTypes.func,addControlPoint:l.PropTypes.func,markerDraggable:l.PropTypes.bool,scrollWheelZoom:l.PropTypes.bool,doubleClickZoom:l.PropTypes.bool,mode:l.PropTypes.string},g.defaultProps={image:null,markers:[],selectedMarker:null,selectedImage:null,onImageDragged:function(){},onMarkerToggle:function(){},onMarkerDelete:function(){},highlightControlPoint:function(){},addControlPoint:function(){},markerDraggable:!1,scrollWheelZoom:!0,doubleClickZoom:!0,mode:""},e.default=g},function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var s=function(){function t(t,e){for(var n=0;ne&&t.setZoom(n-1)}},{key:"onFitMarkers",value:function(){var t=this.props.controlpoints,e=this.props.leafletMap;if(t.points.length){var n=h.default.latLngBounds();t.points.forEach(function(t){t.type===p.CP_TYPES.MAP&&n.extend(t.coord)}),n.isValid()&&e.fitBounds(n)}}},{key:"render",value:function(){var t=this,e=this.props.leafletMap;return e?l.default.createElement("div",{className:"leaflet-zoom-controls"},l.default.createElement("div",{className:"leaflet-control-zoom leaflet-bar leaflet-control"},l.default.createElement("a",{className:"leaflet-control-zoom-in",href:"#",title:"Zoom in",onClick:function(){t.onZoomIn()}},"+"),l.default.createElement("a",{className:"leaflet-control-zoom-out",href:"#",title:"Zoom out",onClick:function(){t.onZoomOut()}},"-"),l.default.createElement("a",{className:"leaflet-control-fit-bounds",href:"#",title:"Fit markers",onClick:function(){t.onFitMarkers()}},l.default.createElement("span",{className:"icon fit-marker",role:"presentation"})))):null}}]),e}(u.Component);f.propTypes={leafletMap:u.PropTypes.object,controlpoints:u.PropTypes.object},f.defaultProps={leafletMap:null},e.default=f},function(t,e,n){"use strict";!function(e){var i;i=n(13),t.exports=e(i)}(function(t){var e="leaflet-map-providers leaflet-bar leaflet-control",n="provider-item";t.TileLayer.Bing=t.TileLayer.extend({getTileUrl:function(e){return t.Util.template(this._url,{s:Math.floor(3*Math.random()),q:this._quadKey(e.x,e.y,this._getZoomForUrl())})},_quadKey:function(t,e,n){for(var i=[],o=n;o>0;o--){var r="0",a=1<=0&&e.item(n)!==this;);return n>-1});t&&t!==document;t=t.parentNode)if(t.matches(e))return t;return null},setToggleState:function(e){t.DomEvent.stopPropagation(e),this.state.open=!this.state.open,t.DomUtil.setClass(this._container,this.getContainerClass())},setProvider:function(){for(var e=this.state.selected,n=this.state.custom,i=this._container.querySelectorAll("li"),o=0;on.length?e=this.deleteMarkers(e,n):n.length>e.length&&(e=this.addMarkers(e,n)),this.setState({markers:this.updateMarkersAttributes(e,n)})}}},{key:"shouldComponentUpdate",value:function(t,e){return this._dirty}},{key:"componentDidUpdate",value:function(){var t=this,e=this.props,n=e.highlightedControlPoints,i=e.selectedMarker,o=this.state.markers;o.forEach(function(e,o){e.marker.setIcon(new v(f)),e.id===i?(e.marker.addClass("active"),e.marker.dragging.enable(),e.marker.setZIndexOffset(m.EDITABLE)):(e.marker.removeClass("active"),e.marker.dragging.disable(),t.shouldHighlightMarker(e.id)?(e.marker.addClass("active"),e.marker.setZIndexOffset(m.ACTIVE)):e.marker.setZIndexOffset(0)),(e.id===i||n.indexOf(e.id)>=0)&&(e.marker.setIcon(new v(d,e.label)),e.marker.setZIndexOffset(m.HIGHLIGHTED),(e.id===i||t.shouldHighlightMarker(e.id))&&e.marker.addClass("active"))})}},{key:"getValidPoints",value:function(t){return t.filter(function(t){return t.type===p.CP_TYPES.MAP})}},{key:"shouldHighlightMarker",value:function(t){var e=this.props,n=e.joins,i=e.selectedImage;if(!n.hasOwnProperty(t))return!1;var o=n[t].find(function(t){return t.indexOf(i)>-1});return!!o}},{key:"createLookup",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"id",n={};return t.forEach(function(t,i){n[t[e]]=i}),n}},{key:"updateMarkersAttributes",value:function(t,e){var n=this.createLookup(e);return t.forEach(function(t){var i=n.hasOwnProperty(t.id);if(i){var o=e[n[t.id]];t.hasImage=o.hasImage}}),t}},{key:"deleteMarkers",value:function(t,e){var n=this.props.leafletMap;if(n){var i=this.createLookup(e);return t.filter(function(t){var e=i.hasOwnProperty(t.id);return e||(n.removeLayer(t.marker),t.marker=null),e})}}},{key:"addMarkers",value:function(t,e){var n=this,i=this.props.leafletMap;if(i){var o=this.createLookup(t);return e.forEach(function(e){var i=o.hasOwnProperty(e.id);i||t.push(n.renderMarker(e))}),t}}},{key:"onActionsClick",value:function(t,e){h.default.DomEvent.stop(t);var n=t.target.dataset.action;if(n){var i=this.props,o=i.onMarkerDelete,r=i.onMarkerMouseOut,a=i.onMarkerToggle;"delete"===n?o(e):"lock"===n&&(a(e),r())}}},{key:"onMarkerDragEnd",value:function(t){var e=this.props.onMarkerDragged,n=t.getLatLng();e(t._pointid,[n.lat,n.lng])}},{key:"onMarkerClicked",value:function(t){if(!t.dragging.enabled()){var e=this.props.onMarkerToggle,n=this.state.markers,i=n.find(function(e){return e.id===t._pointid});i&&e(i.id,i.img,t.getLatLng())}}},{key:"renderMarker",value:function(t){var e=this,n=this.props,i=n.leafletMap,o=n.onMarkerMouseOut,r=n.onMarkerMouseOver;if(i){var a=this,s=new v(f),u=t.coord[0],l=t.coord[1],c=new _([u,l],{icon:s,draggable:!0,onActionsClick:function(n){e.onActionsClick(n,t.id)}});return c.addTo(i),c._pointid=t.id,c.on("dragend",function(t){a.onMarkerDragEnd(this)}),c.on("click",function(t){a.onMarkerClicked(this)}),c.on("mouseout",function(){t.id!==e.props.selectedMarker&&o(t.id)}),c.on("mouseover",function(){return r(t.id)}),{marker:c,id:t.id,img:t.img,hasImage:t.hasImage,label:t.label}}}},{key:"render",value:function(){var t=this.props.leafletMap;return t?l.default.createElement("div",null):null}}]),e}(u.Component);g.propTypes={highlightedControlPoints:u.PropTypes.array,leafletMap:u.PropTypes.object,points:u.PropTypes.array,selectedMarker:u.PropTypes.any,selectedImage:u.PropTypes.any,onMarkerDragged:u.PropTypes.func,onMarkerDelete:u.PropTypes.func,onMarkerMouseOut:u.PropTypes.func,onMarkerMouseOver:u.PropTypes.func,onMarkerToggle:u.PropTypes.func},g.defaultProps={highlightedControlPoints:[],leafletMap:null,points:[],selectedMarker:null,selectedImage:null,onMarkerDragged:function(){},onMarkerDelete:function(){},onMarkerMouseOut:function(){},onMarkerMouseOver:function(){},onMarkerToggle:function(){}},e.default=g},function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var s=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:v,e=arguments[1];switch(e.type){case d.ON_WINDOW_RESIZE:return h({},t,{size:e.size});default:return t}}function s(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v,e=arguments[1];switch(e.type){case d.TOGGLE_EXPORT:return{active:!t.active};default:return t}}function u(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v,e=arguments[1];switch(e.type){case d.TOGGLE_MENU:return{menu_active:!t.menu_active};default:return t}}function l(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v,e=arguments[1];switch(e.type){case d.SELECT_IMAGE:return h({},t,{selected:e.img_name});case d.DELETE_IMAGE:return Array.isArray(t.items)?h({},t,{items:t.items.filter(function(t){return t.name!==e.name})}):t;case d.RECEIVE_IMAGE_FILES:var n=t.items||[];return h({},t,{items:[].concat(r(n),r(e.items)),receivedAt:e.receivedAt,selected:t.selected||e.items[0].name});case d.PREVIEW_GCP_FILE:return h({},t,{receivedAt:e.receivedAt,gcp_list:null,gcp_list_preview:!0,gcp_list_text:e.gcp_list_text,gcp_list_name:e.file_name});case d.PREVIEW_GCP_FILE_CANCEL:return h({},t,{gcp_list_preview:!1,gcp_list_text:null,gcp_list_name:null});case d.RECEIVE_GCP_FILE:return h({},t,{sourceProjection:e.sourceProjection,projection:e.projection,gcp_list:e.rows,gcp_list_preview:!1,gcp_list_text:null,gcp_list_name:e.file_name});default:return t}}function c(){arguments.length>0&&void 0!==arguments[0]?arguments[0]:v,arguments[1];return y.apply(null,arguments)}Object.defineProperty(e,"__esModule",{value:!0});var h=Object.assign||function(t){for(var e=1;e-1&&(t[i]=t[i].filter(function(t){return t!==e}),n=!0)}),n?u({},t):t},g=function(t,e){return e.type===m.CP_TYPES.MAP?_(t,e.id):v(t,e.id)},y=function(t,e){var n=t.points.filter(function(t){return t.type===m.CP_TYPES.IMAGE&&t.img_name===e.img_name});if(!n.length)return t;var i=void 0;n.forEach(function(t){i=g(i,t)});var o=t.points.filter(function(t){return t.type===m.CP_TYPES.MAP||t.img_name!==e.img_name});return u({},t,{mode:null,selected:null,points:o,joins:i,status:(0,m.validate)(o,i)})},b=function(t,e){var n=t.points.find(function(t){return t.id===e.id});if(void 0===n)return t;var i=u({},t,{selected:null,mode:null,points:t.points.filter(function(t){return t.id!==e.id})});return i.joins=g(i.joins,n),i.status=(0,m.validate)(i.points,i.joins),i},M=function(t,e,n){var i=u({},t);t.hasOwnProperty(n)||(i[n]=[]);var o=i[n].indexOf(e)<0;return Object.keys(t).forEach(function(t){i[t].indexOf(e)>-1&&(i[t]=i[t].filter(function(t){return t!==e}))}),o&&i[n].push(e),i},x=function(t,e){var n=t.mode===m.CP_MODES.IMAGE_EDIT?t.selected:e.id,i=t.mode===m.CP_MODES.MAP_EDIT?t.selected:e.id;return null===n&&null===i?t:u({},t,{selected:null,mode:null,joins:M(t.joins,n,i)})},w=function(t,e){var n=[];return e.id&&(n=(0,m.relatedPoints)(t.points,t.joins,e.id)),u({},t,{highlighted:n})},P=function(t,e){var n=e.isImage?(0,m.imagePoint)(e.img_coord,e.img_name):(0,m.mapPoint)(e.map_coord);if(null===n)return t;var i=[].concat(a(t.points),[n]),o=t.joins||{};return u({},t,{points:i,joins:o,selected:n.id,mode:(0,m.getModeFromId)(n.id,i),status:(0,m.validate)(i,o)})},E=function(t,e){return u({},t,{points:t.points.map(function(t,n){return e.id===t.id?u({},t,{coord:e.pos}):t})})},C=function(t,e){var n=e.id===t.selected?null:e.id,i=n?(0,m.getModeFromId)(e.id,t.points):null;return u({},t,{selected:n,mode:i})},T=function(t,e){var n=e.images||[];return n.length&&t.points.length?u({},t,{points:t.points.map(function(t){var e=n.findIndex(function(e){return e.name===t.img_name});return e<0?t:u({},t,{hasImage:!0})})}):t},k=function(t){var e=void 0,n=void 0,i=void 0,o=void 0,r=void 0,a=void 0,u=void 0;if(6===t.length){var l=s(t,6);i=l[0],n=l[1],a=l[2],o=l[3],r=l[4],e=l[5]}else if(4===t.length){var c=s(t,4);u=c[0],i=c[1],n=c[2],a=c[3]}else if(3===t.length){var h=s(t,3);o=h[0],r=h[1],e=h[2]}return{img_name:e,lat:n,lng:i,x:o,y:r,z:a,mapPointLabel:u}},O=function(t,e){var n=e.images||[],i=e.rows||[];if(!i.length)return t;var o=[].concat(a(t.points)),r=u({},t.joins),l=t.selected,p=e.sourceProjection;if(p){var f=(0,h.parseUtmDescriptor)(p);f&&(p=(0,h.getProj4Utm)(f.zone,f.hemisphere))}return i.forEach(function(t,e){var i=k(t),a=i.img_name,u=i.lat,h=i.lng,f=i.x,d=i.y,_=i.mapPointLabel,v=n.findIndex(function(t){return t.name===a}),g=v>-1,y=void 0,b=void 0;if(f&&d&&a&&(y=(0,m.imagePoint)([f,d],a,g)),u&&h){if("EPSG:4326"!==p){var x=(0,c.default)(p,"EPSG:4326",[h,u]),w=s(x,2);h=w[0],u=w[1]}b=(0,m.mapPoint)([u,h],_)}y&&o.push(y),b&&o.push(b),y&&b&&(r=M(r,y.id,b.id)),!l&&y&&(l=y.id)}),u({},t,{points:o,joins:r,selected:l,mode:(0,m.getModeFromId)(l,o),status:(0,m.validate)(o,r)})},S=function(t,e){return"adding"===t.mode?t:u({},t,{selected:null,mode:m.CP_MODES.ADDING})},I=function(t){var e;return(0,p.createReducer)(t,(e={},r(e,d.DELETE_CONTROL_POINT,b),r(e,d.HIGHLIGHT_CONTROL_POINT,w),r(e,d.ADD_CONTROL_POINT,P),r(e,d.SET_CONTROL_POINT_POSITION,E),r(e,d.TOGGLE_CONTROL_POINT_MODE,C),r(e,d.AWAIT_CONTROL_POINT,S),r(e,d.JOIN_CONTROL_POINT,x),r(e,"SYNC_IMAGES_TO_POINTS",T),r(e,"SYNC_LIST_TO_IMAGES",O),r(e,"ON_DELETE_IMAGE",y),e))};e.default=I},function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t){var e=p(u.default,t);return e}Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=n(59),a=n(283),s=(i(a),n(143)),u=i(s),l=n(142),c=i(l),h=[c.default],p=r.applyMiddleware.apply(void 0,h)(r.createStore)},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});e.createReducer=function(t,e){return function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t,i=arguments[1];return e.hasOwnProperty(i.type)?e[i.type](n,i):n}}},function(t,e,n){var i,o,r;!function(a){"use strict";o=[n(17),n(61)],i=a,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))}(function(t){"use strict";t.ExifMap.prototype.tags={256:"ImageWidth",257:"ImageHeight",34665:"ExifIFDPointer",34853:"GPSInfoIFDPointer",40965:"InteroperabilityIFDPointer",258:"BitsPerSample",259:"Compression",262:"PhotometricInterpretation",274:"Orientation",277:"SamplesPerPixel",284:"PlanarConfiguration",530:"YCbCrSubSampling",531:"YCbCrPositioning",282:"XResolution",283:"YResolution",296:"ResolutionUnit",273:"StripOffsets",278:"RowsPerStrip",279:"StripByteCounts",513:"JPEGInterchangeFormat",514:"JPEGInterchangeFormatLength",301:"TransferFunction",318:"WhitePoint",319:"PrimaryChromaticities",529:"YCbCrCoefficients",532:"ReferenceBlackWhite",306:"DateTime",270:"ImageDescription",271:"Make",272:"Model",305:"Software",315:"Artist",33432:"Copyright",36864:"ExifVersion",40960:"FlashpixVersion",40961:"ColorSpace",40962:"PixelXDimension",40963:"PixelYDimension",42240:"Gamma",37121:"ComponentsConfiguration",37122:"CompressedBitsPerPixel",37500:"MakerNote",37510:"UserComment",40964:"RelatedSoundFile",36867:"DateTimeOriginal",36868:"DateTimeDigitized",37520:"SubSecTime",37521:"SubSecTimeOriginal",37522:"SubSecTimeDigitized",33434:"ExposureTime",33437:"FNumber",34850:"ExposureProgram",34852:"SpectralSensitivity",34855:"PhotographicSensitivity",34856:"OECF",34864:"SensitivityType",34865:"StandardOutputSensitivity",34866:"RecommendedExposureIndex",34867:"ISOSpeed",34868:"ISOSpeedLatitudeyyy",34869:"ISOSpeedLatitudezzz",37377:"ShutterSpeedValue",37378:"ApertureValue",37379:"BrightnessValue",37380:"ExposureBias",37381:"MaxApertureValue",37382:"SubjectDistance",37383:"MeteringMode",37384:"LightSource",37385:"Flash",37396:"SubjectArea",37386:"FocalLength",41483:"FlashEnergy",41484:"SpatialFrequencyResponse",41486:"FocalPlaneXResolution",41487:"FocalPlaneYResolution",41488:"FocalPlaneResolutionUnit",41492:"SubjectLocation",41493:"ExposureIndex",41495:"SensingMethod",41728:"FileSource",41729:"SceneType",41730:"CFAPattern",41985:"CustomRendered",41986:"ExposureMode",41987:"WhiteBalance",41988:"DigitalZoomRatio",41989:"FocalLengthIn35mmFilm",41990:"SceneCaptureType",41991:"GainControl",41992:"Contrast",41993:"Saturation",41994:"Sharpness",41995:"DeviceSettingDescription",41996:"SubjectDistanceRange",42016:"ImageUniqueID",42032:"CameraOwnerName",42033:"BodySerialNumber",42034:"LensSpecification",42035:"LensMake",42036:"LensModel",42037:"LensSerialNumber",0:"GPSVersionID",1:"GPSLatitudeRef",2:"GPSLatitude",3:"GPSLongitudeRef",4:"GPSLongitude",5:"GPSAltitudeRef",6:"GPSAltitude",7:"GPSTimeStamp",8:"GPSSatellites",9:"GPSStatus",10:"GPSMeasureMode",11:"GPSDOP",12:"GPSSpeedRef",13:"GPSSpeed",14:"GPSTrackRef",15:"GPSTrack",16:"GPSImgDirectionRef",17:"GPSImgDirection",18:"GPSMapDatum",19:"GPSDestLatitudeRef",20:"GPSDestLatitude",21:"GPSDestLongitudeRef",22:"GPSDestLongitude",23:"GPSDestBearingRef",24:"GPSDestBearing",25:"GPSDestDistanceRef",26:"GPSDestDistance",27:"GPSProcessingMethod", +28:"GPSAreaInformation",29:"GPSDateStamp",30:"GPSDifferential",31:"GPSHPositioningError"},t.ExifMap.prototype.stringValues={ExposureProgram:{0:"Undefined",1:"Manual",2:"Normal program",3:"Aperture priority",4:"Shutter priority",5:"Creative program",6:"Action program",7:"Portrait mode",8:"Landscape mode"},MeteringMode:{0:"Unknown",1:"Average",2:"CenterWeightedAverage",3:"Spot",4:"MultiSpot",5:"Pattern",6:"Partial",255:"Other"},LightSource:{0:"Unknown",1:"Daylight",2:"Fluorescent",3:"Tungsten (incandescent light)",4:"Flash",9:"Fine weather",10:"Cloudy weather",11:"Shade",12:"Daylight fluorescent (D 5700 - 7100K)",13:"Day white fluorescent (N 4600 - 5400K)",14:"Cool white fluorescent (W 3900 - 4500K)",15:"White fluorescent (WW 3200 - 3700K)",17:"Standard light A",18:"Standard light B",19:"Standard light C",20:"D55",21:"D65",22:"D75",23:"D50",24:"ISO studio tungsten",255:"Other"},Flash:{0:"Flash did not fire",1:"Flash fired",5:"Strobe return light not detected",7:"Strobe return light detected",9:"Flash fired, compulsory flash mode",13:"Flash fired, compulsory flash mode, return light not detected",15:"Flash fired, compulsory flash mode, return light detected",16:"Flash did not fire, compulsory flash mode",24:"Flash did not fire, auto mode",25:"Flash fired, auto mode",29:"Flash fired, auto mode, return light not detected",31:"Flash fired, auto mode, return light detected",32:"No flash function",65:"Flash fired, red-eye reduction mode",69:"Flash fired, red-eye reduction mode, return light not detected",71:"Flash fired, red-eye reduction mode, return light detected",73:"Flash fired, compulsory flash mode, red-eye reduction mode",77:"Flash fired, compulsory flash mode, red-eye reduction mode, return light not detected",79:"Flash fired, compulsory flash mode, red-eye reduction mode, return light detected",89:"Flash fired, auto mode, red-eye reduction mode",93:"Flash fired, auto mode, return light not detected, red-eye reduction mode",95:"Flash fired, auto mode, return light detected, red-eye reduction mode"},SensingMethod:{1:"Undefined",2:"One-chip color area sensor",3:"Two-chip color area sensor",4:"Three-chip color area sensor",5:"Color sequential area sensor",7:"Trilinear sensor",8:"Color sequential linear sensor"},SceneCaptureType:{0:"Standard",1:"Landscape",2:"Portrait",3:"Night scene"},SceneType:{1:"Directly photographed"},CustomRendered:{0:"Normal process",1:"Custom process"},WhiteBalance:{0:"Auto white balance",1:"Manual white balance"},GainControl:{0:"None",1:"Low gain up",2:"High gain up",3:"Low gain down",4:"High gain down"},Contrast:{0:"Normal",1:"Soft",2:"Hard"},Saturation:{0:"Normal",1:"Low saturation",2:"High saturation"},Sharpness:{0:"Normal",1:"Soft",2:"Hard"},SubjectDistanceRange:{0:"Unknown",1:"Macro",2:"Close view",3:"Distant view"},FileSource:{3:"DSC"},ComponentsConfiguration:{0:"",1:"Y",2:"Cb",3:"Cr",4:"R",5:"G",6:"B"},Orientation:{1:"top-left",2:"top-right",3:"bottom-right",4:"bottom-left",5:"left-top",6:"right-top",7:"right-bottom",8:"left-bottom"}},t.ExifMap.prototype.getText=function(t){var e=this.get(t);switch(t){case"LightSource":case"Flash":case"MeteringMode":case"ExposureProgram":case"SensingMethod":case"SceneCaptureType":case"SceneType":case"CustomRendered":case"WhiteBalance":case"GainControl":case"Contrast":case"Saturation":case"Sharpness":case"SubjectDistanceRange":case"FileSource":case"Orientation":return this.stringValues[t][e];case"ExifVersion":case"FlashpixVersion":if(!e)return;return String.fromCharCode(e[0],e[1],e[2],e[3]);case"ComponentsConfiguration":if(!e)return;return this.stringValues[t][e[0]]+this.stringValues[t][e[1]]+this.stringValues[t][e[2]]+this.stringValues[t][e[3]];case"GPSVersionID":if(!e)return;return e[0]+"."+e[1]+"."+e[2]+"."+e[3]}return String(e)},function(t){var e,n=t.tags,i=t.map;for(e in n)n.hasOwnProperty(e)&&(i[n[e]]=e)}(t.ExifMap.prototype),t.ExifMap.prototype.getAll=function(){var t,e,n={};for(t in this)this.hasOwnProperty(t)&&(e=this.tags[t],e&&(n[e]=this.getText(e)));return n}})},function(t,e,n){var i,o,r;!function(a){"use strict";o=[n(17),n(29)],i=a,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))}(function(t){"use strict";"undefined"!=typeof fetch&&"undefined"!=typeof Request&&(t.fetchBlob=function(e,n,i){return t.hasMetaOption(i)?fetch(new Request(e,i)).then(function(t){return t.blob()}).then(n).catch(function(t){console.log(t),n()}):void n()})})},function(t,e,n){var i,o,r;!function(a){"use strict";o=[n(17),n(62),n(29)],i=a,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))}(function(t){"use strict";var e=t.hasCanvasOption,n=t.hasMetaOption,i=t.transformCoordinates,o=t.getTransformedOptions;t.hasCanvasOption=function(n){return!!n.orientation||e.call(t,n)},t.hasMetaOption=function(e){return e&&e.orientation===!0||n.call(t,e)},t.transformCoordinates=function(e,n){i.call(t,e,n);var o=e.getContext("2d"),r=e.width,a=e.height,s=e.style.width,u=e.style.height,l=n.orientation;if(l&&!(l>8))switch(l>4&&(e.width=a,e.height=r,e.style.width=u,e.style.height=s),l){case 2:o.translate(r,0),o.scale(-1,1);break;case 3:o.translate(r,a),o.rotate(Math.PI);break;case 4:o.translate(0,a),o.scale(1,-1);break;case 5:o.rotate(.5*Math.PI),o.scale(1,-1);break;case 6:o.rotate(.5*Math.PI),o.translate(0,-a);break;case 7:o.rotate(.5*Math.PI),o.translate(r,-a),o.scale(-1,1);break;case 8:o.rotate(-.5*Math.PI),o.translate(-r,0)}},t.getTransformedOptions=function(e,n,i){var r,a,s=o.call(t,e,n),u=s.orientation;if(u===!0&&i&&i.exif&&(u=i.exif.get("Orientation")),!u||u>8||1===u)return s;r={};for(a in s)s.hasOwnProperty(a)&&(r[a]=s[a]);switch(r.orientation=u,u){case 2:r.left=s.right,r.right=s.left;break;case 3:r.left=s.right,r.top=s.bottom,r.right=s.left,r.bottom=s.top;break;case 4:r.top=s.bottom,r.bottom=s.top;break;case 5:r.left=s.top,r.top=s.left,r.right=s.bottom,r.bottom=s.right;break;case 6:r.left=s.top,r.top=s.right,r.right=s.bottom,r.bottom=s.left;break;case 7:r.left=s.bottom,r.top=s.right,r.right=s.top,r.bottom=s.left;break;case 8:r.left=s.bottom,r.top=s.left,r.right=s.top,r.bottom=s.right}return r.orientation>4&&(r.maxWidth=s.maxHeight,r.maxHeight=s.maxWidth,r.minWidth=s.minHeight,r.minHeight=s.minWidth,r.sourceWidth=s.sourceHeight,r.sourceHeight=s.sourceWidth),r}})},function(t,e){!function(t){"use strict";t.console||(t.console={});for(var e,n,i=t.console,o=function(){},r=["memory"],a="assert,clear,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,markTimeline,profile,profiles,profileEnd,show,table,time,timeEnd,timeline,timelineEnd,timeStamp,trace,warn".split(",");e=r.pop();)i[e]||(i[e]={});for(;n=a.pop();)"function"!=typeof i[n]&&(i[n]=o)}("undefined"==typeof window?this:window)},function(t,e,n){"use strict";function i(t){return t}function o(t,e,n){function o(t,e){var n=g.hasOwnProperty(e)?g[e]:null;x.hasOwnProperty(e)&&u("OVERRIDE_BASE"===n,"ReactClassInterface: You are attempting to override `%s` from your class specification. Ensure that your method names do not overlap with React methods.",e),t&&u("DEFINE_MANY"===n||"DEFINE_MANY_MERGED"===n,"ReactClassInterface: You are attempting to define `%s` on your component more than once. This conflict may be due to a mixin.",e)}function r(t,n){if(n){u("function"!=typeof n,"ReactClass: You're attempting to use a component class or function as a mixin. Instead, just use a regular object."),u(!e(n),"ReactClass: You're attempting to use a component as a mixin. Instead, just use a regular object.");var i=t.prototype,r=i.__reactAutoBindPairs;n.hasOwnProperty(l)&&y.mixins(t,n.mixins);for(var a in n)if(n.hasOwnProperty(a)&&a!==l){var s=n[a],c=i.hasOwnProperty(a);if(o(c,a),y.hasOwnProperty(a))y[a](t,s);else{var h=g.hasOwnProperty(a),d="function"==typeof s,m=d&&!h&&!c&&n.autobind!==!1;if(m)r.push(a,s),i[a]=s;else if(c){var _=g[a];u(h&&("DEFINE_MANY_MERGED"===_||"DEFINE_MANY"===_),"ReactClass: Unexpected spec policy %s for key %s when mixing in component specs.",_,a),"DEFINE_MANY_MERGED"===_?i[a]=p(i[a],s):"DEFINE_MANY"===_&&(i[a]=f(i[a],s))}else i[a]=s}}}else;}function c(t,e){if(e)for(var n in e){var i=e[n];if(e.hasOwnProperty(n)){var o=n in y;u(!o,'ReactClass: You are attempting to define a reserved property, `%s`, that shouldn\'t be on the "statics" key. Define it as an instance property instead; it will still be accessible on the constructor.',n);var r=n in t;u(!r,"ReactClass: You are attempting to define `%s` on your component more than once. This conflict may be due to a mixin.",n),t[n]=i}}}function h(t,e){u(t&&e&&"object"==typeof t&&"object"==typeof e,"mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.");for(var n in e)e.hasOwnProperty(n)&&(u(void 0===t[n],"mergeIntoWithNoDuplicateKeys(): Tried to merge two objects with the same key: `%s`. This conflict may be due to a mixin; in particular, this may be caused by two getInitialState() or getDefaultProps() methods returning objects with clashing keys.",n),t[n]=e[n]);return t}function p(t,e){return function(){var n=t.apply(this,arguments),i=e.apply(this,arguments);if(null==n)return i;if(null==i)return n;var o={};return h(o,n),h(o,i),o}}function f(t,e){return function(){t.apply(this,arguments),e.apply(this,arguments)}}function d(t,e){var n=e.bind(t);return n}function m(t){for(var e=t.__reactAutoBindPairs,n=0;n=n.length?i(new s(m,y,new a(t,e[y]))):c(e[y],n[y],i,h,m,y,d);for(;y=0?(c(e[o],n[o],i,h,m,o,d),M=u(M,a)):c(e[o],t,i,h,m,o,d)}),M.forEach(function(e){c(t,n[e],i,h,m,e,d)})}d.length=d.length-1}}else e!==n&&("number"===v&&isNaN(e)&&isNaN(n)||i(new o(m,e,n)))}function h(e,n,i,o){return o=o||[],c(e,n,function(t){t&&o.push(t)},i),o.length?o:t}function p(t,e,n){if(n.path&&n.path.length){var i,o=t[e],r=n.path.length-1;for(i=0;i":a.innerHTML="<"+t+">",s[t]=!a.firstChild),s[t]?p[t]:null}var o=n(7),r=n(1),a=o.canUseDOM?document.createElement("div"):null,s={},u=[1,'"],l=[1,"","
    "],c=[3,"","
    "],h=[1,'',""],p={"*":[1,"?
    ","
    "],area:[1,"",""],col:[2,"","
    "],legend:[1,"
    ","
    "],param:[1,"",""],tr:[2,"","
    "],optgroup:u,option:u,caption:l,colgroup:l,tbody:l,tfoot:l,thead:l,td:c,th:c},f=["circle","clipPath","defs","ellipse","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","text","tspan"];f.forEach(function(t){p[t]=h,s[t]=!0}),t.exports=i},function(t,e){"use strict";function n(t){return t.Window&&t instanceof t.Window?{x:t.pageXOffset||t.document.documentElement.scrollLeft,y:t.pageYOffset||t.document.documentElement.scrollTop}:{x:t.scrollLeft,y:t.scrollTop}}t.exports=n},function(t,e){"use strict";function n(t){return t.replace(i,"-$1").toLowerCase()}var i=/([A-Z])/g;t.exports=n},function(t,e,n){"use strict";function i(t){return o(t).replace(r,"-ms-")}var o=n(164),r=/^ms-/;t.exports=i},function(t,e){"use strict";function n(t){var e=t?t.ownerDocument||t:document,n=e.defaultView||window;return!(!t||!("function"==typeof n.Node?t instanceof n.Node:"object"==typeof t&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName))}t.exports=n},function(t,e,n){"use strict";function i(t){return o(t)&&3==t.nodeType}var o=n(166);t.exports=i},function(t,e){"use strict";function n(t){var e={};return function(n){return e.hasOwnProperty(n)||(e[n]=t.call(this,n)),e[n]}}t.exports=n},function(t,e,n){var i,o=o||function(t){"use strict";if(!("undefined"==typeof t||"undefined"!=typeof navigator&&/MSIE [1-9]\./.test(navigator.userAgent))){var e=t.document,n=function(){return t.URL||t.webkitURL||t},i=e.createElementNS("http://www.w3.org/1999/xhtml","a"),o="download"in i,r=function(t){var e=new MouseEvent("click");t.dispatchEvent(e)},a=/constructor/i.test(t.HTMLElement)||t.safari,s=/CriOS\/[\d]+/.test(navigator.userAgent),u=function(e){(t.setImmediate||t.setTimeout)(function(){throw e},0)},l="application/octet-stream",c=4e4,h=function(t){var e=function(){"string"==typeof t?n().revokeObjectURL(t):t.remove()};setTimeout(e,c)},p=function(t,e,n){e=[].concat(e);for(var i=e.length;i--;){var o=t["on"+e[i]];if("function"==typeof o)try{o.call(t,n||t)}catch(r){u(r)}}},f=function(t){return/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(t.type)?new Blob([String.fromCharCode(65279),t],{type:t.type}):t},d=function(e,u,c){c||(e=f(e));var d,m=this,_=e.type,v=_===l,g=function(){p(m,"writestart progress write writeend".split(" "))},y=function(){if((s||v&&a)&&t.FileReader){var i=new FileReader;return i.onloadend=function(){var e=s?i.result:i.result.replace(/^data:[^;]*;/,"data:attachment/file;"),n=t.open(e,"_blank");n||(t.location.href=e),e=void 0,m.readyState=m.DONE,g()},i.readAsDataURL(e),void(m.readyState=m.INIT)}if(d||(d=n().createObjectURL(e)),v)t.location.href=d;else{var o=t.open(d,"_blank");o||(t.location.href=d)}m.readyState=m.DONE,g(),h(d)};return m.readyState=m.INIT,o?(d=n().createObjectURL(e),void setTimeout(function(){i.href=d,i.download=u,r(i),g(),h(d),m.readyState=m.DONE})):void y()},m=d.prototype,_=function(t,e,n){return new d(t,e||t.name||"download",n)};return"undefined"!=typeof navigator&&navigator.msSaveOrOpenBlob?function(t,e,n){return e=e||t.name||"download",n||(t=f(t)),navigator.msSaveOrOpenBlob(t,e)}:(m.abort=function(){},m.readyState=m.INIT=0,m.WRITING=1,m.DONE=2,m.error=m.onwritestart=m.onprogress=m.onwrite=m.onabort=m.onerror=m.onwriteend=null,_)}}("undefined"!=typeof self&&self||"undefined"!=typeof window&&window||this.content);"undefined"!=typeof t&&t.exports?t.exports.saveAs=o:null!==n(290)&&null!==n(291)&&(i=function(){return o}.call(e,n,e,t),!(void 0!==i&&(t.exports=i)))},function(t,e){"use strict";var n={childContextTypes:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,arguments:!0,arity:!0},o="function"==typeof Object.getOwnPropertySymbols;t.exports=function(t,e,r){if("string"!=typeof e){var a=Object.getOwnPropertyNames(e);o&&(a=a.concat(Object.getOwnPropertySymbols(e)));for(var s=0;sMapzen',url:"https://search.mapzen.com/v1",placeholder:null,bounds:!1,focus:!0,layers:null,panToPoint:!0,pointIcon:!0,polygonIcon:!0,fullWidth:650,markers:!0,overrideBbox:!1,expanded:!1,autocomplete:!0,place:!1,textStrings:f},initialize:function(t,e){if(window.XDomainRequest&&(this.options.url="//search.mapzen.com/v1"),"object"==typeof t&&t?e=t:this.apiKey=t,e&&"undefined"!=typeof e.latlng&&("undefined"==typeof e.focus&&(e.focus=e.latlng),console.warn("[leaflet-geocoder-mapzen] DEPRECATION WARNING:","As of v1.6.0, the `latlng` option is deprecated. It has been renamed to `focus`. `latlng` will be removed in a future version.")),e&&"undefined"!=typeof e.title&&(e.textStrings=e.textStrings||{},e.textStrings.INPUT_TITLE_ATTRIBUTE=e.title,console.warn("[leaflet-geocoder-mapzen] DEPRECATION WARNING:","As of v1.8.0, the `title` option is deprecated. Please set the property `INPUT_TITLE_ATTRIBUTE` on the `textStrings` option instead. `title` will be removed in a future version.")),e&&"undefined"!=typeof e.placeholder&&(e.textStrings&&"undefined"!=typeof e.textStrings.INPUT_PLACEHOLDER||(e.textStrings=e.textStrings||{},e.textStrings.INPUT_PLACEHOLDER=e.placeholder)),e&&"object"==typeof e.textStrings)for(var n in this.options.textStrings)"undefined"==typeof e.textStrings[n]&&(e.textStrings[n]=this.options.textStrings[n]);i.Util.setOptions(this,e),this.markers=[]},reset:function(){this._input.value="",i.DomUtil.addClass(this._reset,"leaflet-pelias-hidden"),this.removeMarkers(),this.clearResults(),this.fire("reset")},getLayers:function(t){var e=this.options.layers;return e?(t.layers=e,t):t},getBoundingBoxParam:function(t){function e(t,e){return t["boundary.rect.min_lon"]=e.getWest(),t["boundary.rect.min_lat"]=e.getSouth(),t["boundary.rect.max_lon"]=e.getEast(),t["boundary.rect.max_lat"]=e.getNorth(),t}var n=this.options.bounds;if(!n)return t;if(n===!0&&this._map)n=this._map.getBounds(),t=e(t,n);else if("object"==typeof n&&n.isValid&&n.isValid())t=e(t,n);else if(i.Util.isArray(n)){var o=i.latLngBounds(n);o.isValid&&o.isValid()&&(t=e(t,o))}return t},getFocusParam:function(t){var e=this.options.focus;if(!e)return t;if(e===!0&&this._map){var n=this._map.getCenter();t["focus.point.lat"]=n.lat,t["focus.point.lon"]=n.lng}else if("object"==typeof e){var o=i.latLng(e);t["focus.point.lat"]=o.lat,t["focus.point.lon"]=o.lng}return t},getParams:function(t){t=t||{},t=this.getBoundingBoxParam(t),t=this.getFocusParam(t),t=this.getLayers(t),this.apiKey&&(t.api_key=this.apiKey);var e=this.options.params;if(!e)return t;if("object"==typeof e)for(var n in e)t[n]=e[n];return t},serialize:function(t){var e="";for(var n in t)if(t.hasOwnProperty(n)){var i,o=t[n],r=o.toString();switch(e.length&&(e+="&"),r){case"[object Array]":i="[object Object]"===o[0].toString()?JSON.stringify(o):o.join(",");break;case"[object Object]":i=JSON.stringify(o);break;case"[object Date]":i=o.valueOf();break;default:i=o}e+=encodeURIComponent(n)+"="+encodeURIComponent(i)}return e},search:function(t){if(t){var e=this.options.url+"/search",n={text:t};this.callPelias(e,n,"search")}},autocomplete:r(function(t){if(t){var e=this.options.url+"/autocomplete",n={text:t};this.callPelias(e,n,"autocomplete")}},p),place:function(t){if(t){var e=this.options.url+"/place",n={ids:t};this.callPelias(e,n,"place")}},handlePlaceResponse:function(t){},maxReqTimestampRendered:(new Date).getTime(),callPelias:function(t,e,n){function r(o,r){i.DomUtil.removeClass(l._search,"leaflet-pelias-loading");var s;try{s=JSON.parse(r.responseText)}catch(u){o={code:500,message:"Parse Error"}}if(o){var c;switch(o.code){case 403:c=l.options.textStrings.ERROR_403;break;case 404:c=l.options.textStrings.ERROR_404;break;case 408:c=l.options.textStrings.ERROR_408;break;case 429:c=l.options.textStrings.ERROR_429;break;case 500:c=l.options.textStrings.ERROR_500;break;case 502:c=l.options.textStrings.ERROR_502;break;default:c=l.options.textStrings.ERROR_DEFAULT}l.showMessage(c),l.fire("error",{results:s,endpoint:t,requestType:n,params:e,errorCode:o.code,errorMessage:c})}if(s&&s.geocoding&&s.geocoding.errors)return c=s.geocoding.errors[0],l.showMessage(c),void l.fire("error",{results:s,endpoint:t,requestType:n,params:e,errorCode:o.code,errorMessage:c});if(s&&s.features){if("autocomplete"===n||"search"===n){if(""===l._input.value||l.maxReqTimestampRendered>=a)return;l.maxReqTimestampRendered=a}"place"===n&&l.handlePlaceResponse(s),"autocomplete"!==n&&"search"!==n||l.showResults(s.features,e.text),l.fire("results",{results:s,endpoint:t,requestType:n,params:e})}}e=this.getParams(e),i.DomUtil.addClass(this._search,"leaflet-pelias-loading");var a=(new Date).getTime(),s=this.serialize(e),u=t+"?"+s,l=this;o(u,r,!0)},highlight:function(t,e){var n=RegExp("("+a(e)+")","gi");return t.replace(n,"$1")},getIconType:function(t){var e=this.options.pointIcon,n=this.options.polygonIcon,i="leaflet-pelias-layer-icon-";return t.match("venue")||t.match("address")?e===!0?{type:"class",value:i+"point"}:e!==!1&&{type:"image",value:e}:n===!0?{type:"class",value:i+"polygon"}:n!==!1&&{type:"image",value:n}},showResults:function(t,e){if(0===t.length)return void this.showMessage(this.options.textStrings.NO_RESULTS);var n=this._results;n.innerHTML="",n.style.display="block",n.style.maxHeight=this._map.getSize().y-n.offsetTop-this._container.offsetTop-h+"px";for(var o=i.DomUtil.create("ul","leaflet-pelias-list",n),r=0,a=t.length;r=window.parseInt(this.options.fullWidth,10))return void this.clearFullWidth();this._container.style.width=n.toString()+"px"}},clearFullWidth:function(){this.options.fullWidth&&(this._container.style.width="")},onAdd:function(t){var e=i.DomUtil.create("div","leaflet-pelias-control leaflet-bar leaflet-control");return this._body=document.body||document.getElementsByTagName("body")[0], +this._container=e,this._input=i.DomUtil.create("input","leaflet-pelias-input",this._container),this._input.spellcheck=!1,i.DomEvent.addListener(this._input,"focus",function(t){this.fire("focus",{originalEvent:t})},this),i.DomEvent.addListener(this._input,"blur",function(t){this.fire("blur",{originalEvent:t})},this),this.options.textStrings.INPUT_TITLE_ATTRIBUTE&&(this._input.title=this.options.textStrings.INPUT_TITLE_ATTRIBUTE),this.options.textStrings.INPUT_PLACEHOLDER&&(this._input.placeholder=this.options.textStrings.INPUT_PLACEHOLDER),this._search=i.DomUtil.create("a","leaflet-pelias-search-icon",this._container),this._reset=i.DomUtil.create("div","leaflet-pelias-close leaflet-pelias-hidden",this._container),this._reset.innerHTML="×",this._reset.title=this.options.textStrings.RESET_TITLE_ATTRIBUTE,this._results=i.DomUtil.create("div","leaflet-pelias-results leaflet-bar",this._container),this.options.expanded&&this.expand(),i.DomEvent.on(this._container,"click",function(t){this._input.focus()},this).on(this._input,"focus",function(t){this._input.value&&this._results.children.length&&(this._results.style.display="block")},this).on(this._map,"click",function(t){this.blur()},this).on(this._search,"click",function(t){i.DomEvent.stopPropagation(t),i.DomUtil.hasClass(this._container,"leaflet-pelias-expanded")?this.options.expanded===!0?this._input.focus():(i.DomUtil.addClass(this._reset,"leaflet-pelias-hidden"),this.collapse()):(this._input.value.length>0&&i.DomUtil.removeClass(this._reset,"leaflet-pelias-hidden"),this.expand(),this._input.focus())},this).on(this._reset,"click",function(t){this.reset(),this._input.focus(),i.DomEvent.stopPropagation(t)},this).on(this._input,"keydown",function(t){for(var e,n=this._results.querySelectorAll(".leaflet-pelias-result"),o=this._results.querySelectorAll(".leaflet-pelias-selected")[0],r=this,a=function(t,e){if(t&&e.panToPoint){var n=t.feature.properties.layer;"venue"!==n&&"address"!==n&&t.feature.bbox&&!e.overrideBbox?(r.removeMarkers(),r.fitBoundingBox(t.feature.bbox)):(r.removeMarkers(),r.showMarker(t.innerHTML,i.GeoJSON.coordsToLatLng(t.feature.geometry.coordinates)))}},s=function(t){var e=t.getBoundingClientRect(),n=r._results.getBoundingClientRect();e.bottom>n.bottom?r._results.scrollTop=t.offsetTop+t.offsetHeight-r._results.offsetHeight:e.top0?i.DomUtil.removeClass(this._reset,"leaflet-pelias-hidden"):i.DomUtil.addClass(this._reset,"leaflet-pelias-hidden"),13!==e&&38!==e&&40!==e)return 27===e?(0!==n.length&&"none"!==this._results.style.display||(this._input.blur(),!this.options.expanded&&i.DomUtil.hasClass(this._container,"leaflet-pelias-expanded")&&this.collapse()),this.clearResults(!0),void i.DomUtil.removeClass(this._search,"leaflet-pelias-loading")):void(n!==this._lastValue&&(this._lastValue=n,n.length>=u&&this.options.autocomplete===!0?this.autocomplete(n):this.clearResults(!0)))},this).on(this._results,"click",function(t){i.DomEvent.preventDefault(t),i.DomEvent.stopPropagation(t);var e=this._results.querySelectorAll(".leaflet-pelias-selected")[0];e&&i.DomUtil.removeClass(e,"leaflet-pelias-selected");var n=t.target||t.srcElement,o=function(){return i.DomUtil.hasClass(n,"leaflet-pelias-result")||(n=n.parentElement,n&&o()),n};o(),n&&(i.DomUtil.addClass(n,"leaflet-pelias-selected"),this.setSelectedResult(n,t))},this),this.options.fullWidth&&i.DomEvent.on(window,"resize",function(t){i.DomUtil.hasClass(this._container,"leaflet-pelias-expanded")&&this.setFullWidth()},this),i.DomEvent.on(this._results,"mouseover",this._disableMapScrollWheelZoom,this),i.DomEvent.on(this._results,"mouseout",this._enableMapScrollWheelZoom,this),i.DomEvent.on(this._map,"mousedown",this._onMapInteraction,this),i.DomEvent.on(this._map,"touchstart",this._onMapInteraction,this),i.DomEvent.disableClickPropagation(this._container),t.attributionControl&&t.attributionControl.addAttribution(this.options.attribution),e},_onMapInteraction:function(t){this.blur(),this.options.expanded||!this._input.value&&i.DomUtil.hasClass(this._container,"leaflet-pelias-expanded")&&this.collapse()},_disableMapScrollWheelZoom:function(t){this._scrollWheelZoomEnabled=this._map.scrollWheelZoom.enabled(),this._scrollWheelZoomEnabled&&this._map.scrollWheelZoom.disable()},_enableMapScrollWheelZoom:function(t){this._scrollWheelZoomEnabled&&this._map.scrollWheelZoom.enable()},onRemove:function(t){t.attributionControl&&t.attributionControl.removeAttribution(this.options.attribution)}});t.exports=d},function(t,e,n){var i,o,r;!function(a,s){o=[n(13)],i=s,r="function"==typeof i?i.apply(e,o):i,!(void 0!==r&&(t.exports=r))}(this,function(t){"use strict";var e=n(172);return t.Control.Geocoder=e,t.control.geocoder=function(e,n){return new t.Control.Geocoder(e,n)},e})},function(t,e){function n(t){return t.replace(/[-[\]\/{}()*+?.\\^$|]/g,"\\$&")}t.exports=n},function(t,e){function n(t,e,n){var i,o,r,a=null,s=0;n||(n={});var u=function(){s=n.leading===!1?0:(new Date).getTime(),a=null,r=t.apply(i,o),a||(i=o=null)};return function(){var l=(new Date).getTime();s||n.leading!==!1||(s=l);var c=e-(l-s);return i=this,o=arguments,c<=0||c>e?(a&&(clearTimeout(a),a=null),s=l,r=t.apply(i,o),a||(i=o=null)):a||n.trailing===!1||(a=setTimeout(u,c)),r}}t.exports=n},function(t,e){function n(t){return!!t&&"object"==typeof t}function i(t,e){var n=null==t?void 0:t[e];return a(n)?n:void 0}function o(t){return r(t)&&p.call(t)==s}function r(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function a(t){return null!=t&&(o(t)?f.test(c.call(t)):n(t)&&u.test(t))}var s="[object Function]",u=/^\[object .+?Constructor\]$/,l=Object.prototype,c=Function.prototype.toString,h=l.hasOwnProperty,p=l.toString,f=RegExp("^"+c.call(h).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=i},function(t,e,n){function i(t,e,n){function i(){v&&clearTimeout(v),f&&clearTimeout(f),y=0,f=v=g=void 0}function r(e,n){n&&clearTimeout(n),f=v=g=void 0,e&&(y=l(),d=t.apply(_,p),v||f||(p=_=void 0))}function u(){var t=e-(l()-m);t<=0||t>e?r(g,f):v=setTimeout(u,t)}function c(){r(M,v)}function h(){if(p=arguments,m=l(),_=this,g=M&&(v||!x),b===!1)var n=x&&!v;else{f||x||(y=m);var i=b-(m-y),o=i<=0||i>b;o?(f&&(f=clearTimeout(f)),y=m,d=t.apply(_,p)):f||(f=setTimeout(c,i))}return o&&v?v=clearTimeout(v):v||e===b||(v=setTimeout(u,e)),n&&(o=!0,d=t.apply(_,p)),!o||v||f||(p=_=void 0),d}var p,f,d,m,_,v,g,y=0,b=!1,M=!0;if("function"!=typeof t)throw new TypeError(a);if(e=e<0?0:+e||0,n===!0){var x=!0;M=!1}else o(n)&&(x=!!n.leading,b="maxWait"in n&&s(+n.maxWait||0,e),M="trailing"in n?!!n.trailing:M);return h.cancel=i,h}function o(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}var r=n(176),a="Expected a function",s=Math.max,u=r(Date,"now"),l=u||function(){return(new Date).getTime()};t.exports=i},function(t,e){(function(e){function n(t,e){for(var n=-1,i=e.length,o=t.length;++n0&&r(c)?e>1?i(c,e-1,r,a,s):n(s,c):a||(s[s.length]=c)}return s}function o(t){return T(t)||a(t)||!!(C&&t&&t[C])}function r(t){var e=t?t.length:0;return e?i(t,f):[]}function a(t){return u(t)&&x.call(t,"callee")&&(!E.call(t,"callee")||w.call(t)==m)}function s(t){return null!=t&&c(t.length)&&!l(t)}function u(t){return p(t)&&s(t)}function l(t){var e=h(t)?w.call(t):"";return e==_||e==v}function c(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=d}function h(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function p(t){return!!t&&"object"==typeof t}var f=1/0,d=9007199254740991,m="[object Arguments]",_="[object Function]",v="[object GeneratorFunction]",g="object"==typeof e&&e&&e.Object===Object&&e,y="object"==typeof self&&self&&self.Object===Object&&self,b=g||y||Function("return this")(),M=Object.prototype,x=M.hasOwnProperty,w=M.toString,P=b.Symbol,E=M.propertyIsEnumerable,C=P?P.isConcatSpreadable:void 0,T=Array.isArray;t.exports=r}).call(e,function(){return this}())},function(t,e,n){(function(t,n){function i(t,e){for(var n=-1,i=null==t?0:t.length,o=0,r=[];++n-1}function P(t,e){var n=this.__data__,i=B(n,t);return i<0?(++this.size,n.push([t,e])):n[i][1]=e,this}function E(t){var e=-1,n=null==t?0:t.length;for(this.clear();++el))return!1;var h=a.get(t);if(h&&a.get(e))return h==e;var p=-1,f=!0,d=n&xt?new I:void 0;for(a.set(t,e),a.set(e,t);++p-1&&t%1==0&&t-1&&t%1==0&&t<=wt}function dt(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function mt(t){return null!=t&&"object"==typeof t}function _t(t){return ct(t)?F(t):Y(t)}function vt(){return[]}function gt(){return!1}var yt=200,bt="__lodash_hash_undefined__",Mt=1,xt=2,wt=9007199254740991,Pt="[object Arguments]",Et="[object Array]",Ct="[object AsyncFunction]",Tt="[object Boolean]",kt="[object Date]",Ot="[object Error]",St="[object Function]",It="[object GeneratorFunction]",Lt="[object Map]",Dt="[object Number]",At="[object Null]",Nt="[object Object]",Rt="[object Promise]",jt="[object Proxy]",zt="[object RegExp]",Ut="[object Set]",Ft="[object String]",Bt="[object Symbol]",Wt="[object Undefined]",Gt="[object WeakMap]",Zt="[object ArrayBuffer]",Ht="[object DataView]",qt="[object Float32Array]",Vt="[object Float64Array]",Kt="[object Int8Array]",Yt="[object Int16Array]",Xt="[object Int32Array]",Qt="[object Uint8Array]",$t="[object Uint8ClampedArray]",Jt="[object Uint16Array]",te="[object Uint32Array]",ee=/[\\^$.*+?()[\]{}|]/g,ne=/^\[object .+?Constructor\]$/,ie=/^(?:0|[1-9]\d*)$/,oe={};oe[qt]=oe[Vt]=oe[Kt]=oe[Yt]=oe[Xt]=oe[Qt]=oe[$t]=oe[Jt]=oe[te]=!0,oe[Pt]=oe[Et]=oe[Zt]=oe[Tt]=oe[Ht]=oe[kt]=oe[Ot]=oe[St]=oe[Lt]=oe[Dt]=oe[Nt]=oe[zt]=oe[Ut]=oe[Ft]=oe[Gt]=!1;var re="object"==typeof t&&t&&t.Object===Object&&t,ae="object"==typeof self&&self&&self.Object===Object&&self,se=re||ae||Function("return this")(),ue="object"==typeof e&&e&&!e.nodeType&&e,le=ue&&"object"==typeof n&&n&&!n.nodeType&&n,ce=le&&le.exports===ue,he=ce&&re.process,pe=function(){try{return he&&he.binding&&he.binding("util")}catch(t){}}(),fe=pe&&pe.isTypedArray,de=Array.prototype,me=Function.prototype,_e=Object.prototype,ve=se["__core-js_shared__"],ge=me.toString,ye=_e.hasOwnProperty,be=function(){var t=/[^.]+$/.exec(ve&&ve.keys&&ve.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),Me=_e.toString,xe=RegExp("^"+ge.call(ye).replace(ee,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),we=ce?se.Buffer:void 0,Pe=se.Symbol,Ee=se.Uint8Array,Ce=_e.propertyIsEnumerable,Te=de.splice,ke=Pe?Pe.toStringTag:void 0,Oe=Object.getOwnPropertySymbols,Se=we?we.isBuffer:void 0,Ie=h(Object.keys,Object),Le=et(se,"DataView"),De=et(se,"Map"),Ae=et(se,"Promise"),Ne=et(se,"Set"),Re=et(se,"WeakMap"),je=et(Object,"create"),ze=ut(Le),Ue=ut(De),Fe=ut(Ae),Be=ut(Ne),We=ut(Re),Ge=Pe?Pe.prototype:void 0,Ze=Ge?Ge.valueOf:void 0;f.prototype.clear=d,f.prototype.delete=m,f.prototype.get=_,f.prototype.has=v,f.prototype.set=g,y.prototype.clear=b,y.prototype.delete=M,y.prototype.get=x,y.prototype.has=w,y.prototype.set=P,E.prototype.clear=C,E.prototype.delete=T,E.prototype.get=k,E.prototype.has=O,E.prototype.set=S,I.prototype.add=I.prototype.push=L,I.prototype.has=D,A.prototype.clear=N,A.prototype.delete=R,A.prototype.get=j,A.prototype.has=z,A.prototype.set=U;var He=Oe?function(t){return null==t?[]:(t=Object(t),i(Oe(t),function(e){return Ce.call(t,e)}))}:vt,qe=G;(Le&&qe(new Le(new ArrayBuffer(1)))!=Ht||De&&qe(new De)!=Lt||Ae&&qe(Ae.resolve())!=Rt||Ne&&qe(new Ne)!=Ut||Re&&qe(new Re)!=Gt)&&(qe=function(t){var e=G(t),n=e==Nt?t.constructor:void 0,i=n?ut(n):"";if(i)switch(i){case ze:return Ht;case Ue:return Lt;case Fe:return Rt;case Be:return Ut;case We:return Gt}return e});var Ve=Z(function(){return arguments}())?Z:function(t){return mt(t)&&ye.call(t,"callee")&&!Ce.call(t,"callee")},Ke=Array.isArray,Ye=Se||gt,Xe=fe?s(fe):K;n.exports=ht}).call(e,function(){return this}(),n(104)(t))},function(t,e){(function(e){function n(t,e){for(var n=-1,i=t?t.length:0,o=Array(i);++n-1&&t%1==0&&t-1&&t%1==0&&t<=k}function E(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function C(t){return!!t&&"object"==typeof t}function T(t){return M(t)?c(t):f(t)}var k=9007199254740991,O="[object Arguments]",S="[object Function]",I="[object GeneratorFunction]",L="[object Map]",D="[object Object]",A="[object Promise]",N="[object Set]",R="[object WeakMap]",j="[object DataView]",z=/[\\^$.*+?()[\]{}|]/g,U=/^\[object .+?Constructor\]$/,F=/^(?:0|[1-9]\d*)$/,B="object"==typeof e&&e&&e.Object===Object&&e,W="object"==typeof self&&self&&self.Object===Object&&self,G=B||W||Function("return this")(),Z=Function.prototype,H=Object.prototype,q=G["__core-js_shared__"],V=function(){var t=/[^.]+$/.exec(q&&q.keys&&q.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),K=Z.toString,Y=H.hasOwnProperty,X=H.toString,Q=RegExp("^"+K.call(Y).replace(z,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),$=H.propertyIsEnumerable,J=u(Object.keys,Object),tt=m(G,"DataView"),et=m(G,"Map"),nt=m(G,"Promise"),it=m(G,"Set"),ot=m(G,"WeakMap"),rt=y(tt),at=y(et),st=y(nt),ut=y(it),lt=y(ot),ct=h;(tt&&ct(new tt(new ArrayBuffer(1)))!=j||et&&ct(new et)!=L||nt&&ct(nt.resolve())!=A||it&&ct(new it)!=N||ot&&ct(new ot)!=R)&&(ct=function(t){var e=X.call(t),n=e==D?t.constructor:void 0,i=n?y(n):void 0;if(i)switch(i){case rt:return j;case at:return L;case st:return A;case ut:return N;case lt:return R}return e});var ht=Array.isArray,pt=d(T);t.exports=pt}).call(e,function(){return this}())},function(t,e){(function(e){function n(t,e){var n=t?t.length:0;return!!n&&r(t,e,0)>-1}function i(t,e,n){for(var i=-1,o=t?t.length:0;++i-1}function x(t,e){var n=this.__data__,i=L(n,t);return i<0?n.push([t,e]):n[i][1]=e,this}function w(t){var e=-1,n=t?t.length:0;for(this.clear();++e=H){var f=e?null:dt(t);if(f)return c(f);l=!1,a=s,p=new O}else p=e?[]:h;t:for(;++r-1}function i(t,e,n){for(var i=-1,o=t?t.length:0;++i-1}function x(t,e){var n=this.__data__,i=L(n,t);return i<0?n.push([t,e]):n[i][1]=e,this}function w(t){var e=-1,n=t?t.length:0;for(this.clear();++e=H){var f=e?null:dt(t);if(f)return c(f);l=!1,a=s,p=new O}else p=e?[]:h;t:for(;++r8&&M<=11),P=32,E=String.fromCharCode(P),C={beforeInput:{phasedRegistrationNames:{bubbled:"onBeforeInput",captured:"onBeforeInputCapture"},dependencies:["topCompositionEnd","topKeyPress","topTextInput","topPaste"]},compositionEnd:{phasedRegistrationNames:{bubbled:"onCompositionEnd",captured:"onCompositionEndCapture"},dependencies:["topBlur","topCompositionEnd","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]},compositionStart:{phasedRegistrationNames:{bubbled:"onCompositionStart",captured:"onCompositionStartCapture"},dependencies:["topBlur","topCompositionStart","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]},compositionUpdate:{phasedRegistrationNames:{bubbled:"onCompositionUpdate",captured:"onCompositionUpdateCapture"},dependencies:["topBlur","topCompositionUpdate","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]}},T=!1,k=null,O={eventTypes:C,extractEvents:function(t,e,n,i){return[l(t,e,n,i),p(t,e,n,i)]}};t.exports=O},function(t,e,n){"use strict";var i=n(72),o=n(7),r=(n(9),n(158),n(253)),a=n(165),s=n(168),u=(n(2),s(function(t){return a(t)})),l=!1,c="cssFloat";if(o.canUseDOM){var h=document.createElement("div").style;try{h.font=""}catch(p){l=!0}void 0===document.documentElement.style.cssFloat&&(c="styleFloat")}var f={createMarkupForStyles:function(t,e){var n="";for(var i in t)if(t.hasOwnProperty(i)){var o=0===i.indexOf("--"),a=t[i];null!=a&&(n+=u(i)+":",n+=r(i,a,e,o)+";")}return n||null},setValueForStyles:function(t,e,n){var o=t.style;for(var a in e)if(e.hasOwnProperty(a)){var s=0===a.indexOf("--"),u=r(a,e[a],n,s);if("float"!==a&&"cssFloat"!==a||(a=c),s)o.setProperty(a,u);else if(u)o[a]=u;else{var h=l&&i.shorthandPropertyExpansions[a];if(h)for(var p in h)o[p]="";else o[a]=""}}}};t.exports=f},function(t,e,n){"use strict";function i(t,e,n){var i=C.getPooled(I.change,t,e,n);return i.type="change",x.accumulateTwoPhaseDispatches(i),i}function o(t){var e=t.nodeName&&t.nodeName.toLowerCase();return"select"===e||"input"===e&&"file"===t.type}function r(t){var e=i(D,t,k(t));E.batchedUpdates(a,e)}function a(t){M.enqueueEvents(t),M.processEventQueue(!1)}function s(t,e){L=t,D=e,L.attachEvent("onchange",r)}function u(){L&&(L.detachEvent("onchange",r),L=null,D=null)}function l(t,e){var n=T.updateValueIfChanged(t),i=e.simulated===!0&&R._allowSimulatedPassThrough;if(n||i)return t}function c(t,e){if("topChange"===t)return e}function h(t,e,n){"topFocus"===t?(u(),s(e,n)):"topBlur"===t&&u()}function p(t,e){L=t,D=e,L.attachEvent("onpropertychange",d)}function f(){L&&(L.detachEvent("onpropertychange",d),L=null,D=null)}function d(t){"value"===t.propertyName&&l(D,t)&&r(t)}function m(t,e,n){"topFocus"===t?(f(),p(e,n)):"topBlur"===t&&f()}function _(t,e,n){if("topSelectionChange"===t||"topKeyUp"===t||"topKeyDown"===t)return l(D,n)}function v(t){var e=t.nodeName;return e&&"input"===e.toLowerCase()&&("checkbox"===t.type||"radio"===t.type)}function g(t,e,n){if("topClick"===t)return l(e,n)}function y(t,e,n){if("topInput"===t||"topChange"===t)return l(e,n)}function b(t,e){if(null!=t){var n=t._wrapperState||e._wrapperState;if(n&&n.controlled&&"number"===e.type){var i=""+e.value;e.getAttribute("value")!==i&&e.setAttribute("value",i)}}}var M=n(24),x=n(25),w=n(7),P=n(5),E=n(11),C=n(14),T=n(88),k=n(54),O=n(55),S=n(90),I={change:{phasedRegistrationNames:{bubbled:"onChange",captured:"onChangeCapture"},dependencies:["topBlur","topChange","topClick","topFocus","topInput","topKeyDown","topKeyUp","topSelectionChange"]}},L=null,D=null,A=!1;w.canUseDOM&&(A=O("change")&&(!document.documentMode||document.documentMode>8));var N=!1;w.canUseDOM&&(N=O("input")&&(!document.documentMode||document.documentMode>9));var R={eventTypes:I,_allowSimulatedPassThrough:!0,_isInputEventSupported:N,extractEvents:function(t,e,n,r){var a,s,u=e?P.getNodeFromInstance(e):window;if(o(u)?A?a=c:s=h:S(u)?N?a=y:(a=_,s=m):v(u)&&(a=g),a){var l=a(t,e,n);if(l){var p=i(l,n,r);return p}}s&&s(t,u,e),"topBlur"===t&&b(e,u)}};t.exports=R},function(t,e,n){"use strict";var i=n(3),o=n(19),r=n(7),a=n(161),s=n(8),u=(n(1),{dangerouslyReplaceNodeWithMarkup:function(t,e){if(r.canUseDOM?void 0:i("56"),e?void 0:i("57"),"HTML"===t.nodeName?i("58"):void 0,"string"==typeof e){var n=a(e,s)[0];t.parentNode.replaceChild(n,t)}else o.replaceChildWithTree(t,e)}});t.exports=u},function(t,e){"use strict";var n=["ResponderEventPlugin","SimpleEventPlugin","TapEventPlugin","EnterLeaveEventPlugin","ChangeEventPlugin","SelectEventPlugin","BeforeInputEventPlugin"];t.exports=n},function(t,e,n){"use strict";var i=n(25),o=n(5),r=n(32),a={mouseEnter:{registrationName:"onMouseEnter",dependencies:["topMouseOut","topMouseOver"]},mouseLeave:{registrationName:"onMouseLeave",dependencies:["topMouseOut","topMouseOver"]}},s={eventTypes:a,extractEvents:function(t,e,n,s){if("topMouseOver"===t&&(n.relatedTarget||n.fromElement))return null;if("topMouseOut"!==t&&"topMouseOver"!==t)return null;var u;if(s.window===s)u=s;else{var l=s.ownerDocument;u=l?l.defaultView||l.parentWindow:window}var c,h;if("topMouseOut"===t){c=e;var p=n.relatedTarget||n.toElement;h=p?o.getClosestInstanceFromNode(p):null}else c=null,h=e;if(c===h)return null;var f=null==c?u:o.getNodeFromInstance(c),d=null==h?u:o.getNodeFromInstance(h),m=r.getPooled(a.mouseLeave,c,n,s);m.type="mouseleave",m.target=f,m.relatedTarget=d;var _=r.getPooled(a.mouseEnter,h,n,s);return _.type="mouseenter",_.target=d,_.relatedTarget=f,i.accumulateEnterLeaveDispatches(m,_,c,h),[m,_]}};t.exports=s},function(t,e,n){"use strict";function i(t){this._root=t,this._startText=this.getText(),this._fallbackText=null}var o=n(6),r=n(18),a=n(87);o(i.prototype,{destructor:function(){this._root=null,this._startText=null,this._fallbackText=null},getText:function(){return"value"in this._root?this._root.value:this._root[a()]},getData:function(){if(this._fallbackText)return this._fallbackText;var t,e,n=this._startText,i=n.length,o=this.getText(),r=o.length;for(t=0;t1?1-e:void 0;return this._fallbackText=o.slice(t,s),this._fallbackText}}),r.addPoolingTo(i),t.exports=i},function(t,e,n){"use strict";var i=n(20),o=i.injection.MUST_USE_PROPERTY,r=i.injection.HAS_BOOLEAN_VALUE,a=i.injection.HAS_NUMERIC_VALUE,s=i.injection.HAS_POSITIVE_NUMERIC_VALUE,u=i.injection.HAS_OVERLOADED_BOOLEAN_VALUE,l={isCustomAttribute:RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+i.ATTRIBUTE_NAME_CHAR+"]*$")),Properties:{accept:0,acceptCharset:0,accessKey:0,action:0,allowFullScreen:r,allowTransparency:0,alt:0,as:0,async:r,autoComplete:0,autoPlay:r,capture:r,cellPadding:0,cellSpacing:0,charSet:0,challenge:0,checked:o|r,cite:0,classID:0,className:0,cols:s,colSpan:0,content:0,contentEditable:0,contextMenu:0,controls:r,controlsList:0,coords:0,crossOrigin:0,data:0,dateTime:0,default:r,defer:r,dir:0,disabled:r,download:u,draggable:0,encType:0,form:0,formAction:0,formEncType:0,formMethod:0,formNoValidate:r,formTarget:0,frameBorder:0,headers:0,height:0,hidden:r,high:0,href:0,hrefLang:0,htmlFor:0,httpEquiv:0,icon:0,id:0,inputMode:0,integrity:0,is:0,keyParams:0,keyType:0,kind:0,label:0,lang:0,list:0,loop:r,low:0,manifest:0,marginHeight:0,marginWidth:0,max:0,maxLength:0,media:0,mediaGroup:0,method:0,min:0,minLength:0,multiple:o|r,muted:o|r,name:0,nonce:0,noValidate:r,open:r,optimum:0,pattern:0,placeholder:0,playsInline:r,poster:0,preload:0,profile:0,radioGroup:0,readOnly:r,referrerPolicy:0,rel:0,required:r,reversed:r,role:0,rows:s,rowSpan:a,sandbox:0,scope:0,scoped:r,scrolling:0,seamless:r,selected:o|r,shape:0,size:s,sizes:0,span:s,spellCheck:0,src:0,srcDoc:0,srcLang:0,srcSet:0,start:a,step:0,style:0,summary:0,tabIndex:0,target:0,title:0,type:0,useMap:0,value:0,width:0,wmode:0,wrap:0,about:0,datatype:0,inlist:0,prefix:0,property:0,resource:0,typeof:0,vocab:0,autoCapitalize:0,autoCorrect:0,autoSave:0,color:0,itemProp:0,itemScope:r,itemType:0,itemID:0,itemRef:0,results:0,security:0,unselectable:0},DOMAttributeNames:{acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv"},DOMPropertyNames:{},DOMMutationMethods:{value:function(t,e){return null==e?t.removeAttribute("value"):void("number"!==t.type||t.hasAttribute("value")===!1?t.setAttribute("value",""+e):t.validity&&!t.validity.badInput&&t.ownerDocument.activeElement!==t&&t.setAttribute("value",""+e))}}};t.exports=l},function(t,e,n){(function(e){"use strict";function i(t,e,n,i){var o=void 0===t[n];null!=e&&o&&(t[n]=r(e,!0))}var o=n(21),r=n(89),a=(n(46),n(56)),s=n(92),u=(n(2),{instantiateChildren:function(t,e,n,o){if(null==t)return null;var r={};return s(t,i,r),r},updateChildren:function(t,e,n,i,s,u,l,c,h){if(e||t){var p,f;for(p in e)if(e.hasOwnProperty(p)){f=t&&t[p];var d=f&&f._currentElement,m=e[p];if(null!=f&&a(d,m))o.receiveComponent(f,m,s,c),e[p]=f;else{f&&(i[p]=o.getHostNode(f),o.unmountComponent(f,!1));var _=r(m,!0);e[p]=_;var v=o.mountComponent(_,s,u,l,c,h);n.push(v)}}for(p in t)!t.hasOwnProperty(p)||e&&e.hasOwnProperty(p)||(f=t[p],i[p]=o.getHostNode(f),o.unmountComponent(f,!1))}},unmountChildren:function(t,e){for(var n in t)if(t.hasOwnProperty(n)){var i=t[n];o.unmountComponent(i,e)}}});t.exports=u}).call(e,n(68))},function(t,e,n){"use strict";var i=n(42),o=n(217),r={processChildrenUpdates:o.dangerouslyProcessChildrenUpdates,replaceNodeWithMarkup:i.dangerouslyReplaceNodeWithMarkup};t.exports=r},function(t,e,n){"use strict";function i(t){}function o(t,e){}function r(t){return!(!t.prototype||!t.prototype.isReactComponent)}function a(t){return!(!t.prototype||!t.prototype.isPureReactComponent)}var s=n(3),u=n(6),l=n(22),c=n(48),h=n(15),p=n(49),f=n(26),d=(n(9),n(82)),m=n(21),_=n(30),v=(n(1),n(38)),g=n(56),y=(n(2),{ImpureClass:0,PureClass:1,StatelessFunctional:2});i.prototype.render=function(){var t=f.get(this)._currentElement.type,e=t(this.props,this.context,this.updater);return o(t,e),e};var b=1,M={construct:function(t){this._currentElement=t,this._rootNodeID=0,this._compositeType=null,this._instance=null,this._hostParent=null,this._hostContainerInfo=null,this._updateBatchNumber=null,this._pendingElement=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._renderedNodeType=null,this._renderedComponent=null,this._context=null,this._mountOrder=0,this._topLevelWrapper=null,this._pendingCallbacks=null,this._calledComponentWillUnmount=!1},mountComponent:function(t,e,n,u){this._context=u,this._mountOrder=b++,this._hostParent=e,this._hostContainerInfo=n;var c,h=this._currentElement.props,p=this._processContext(u),d=this._currentElement.type,m=t.getUpdateQueue(),v=r(d),g=this._constructComponent(v,h,p,m);v||null!=g&&null!=g.render?a(d)?this._compositeType=y.PureClass:this._compositeType=y.ImpureClass:(c=g,o(d,c),null===g||g===!1||l.isValidElement(g)?void 0:s("105",d.displayName||d.name||"Component"),g=new i(d),this._compositeType=y.StatelessFunctional);g.props=h,g.context=p,g.refs=_,g.updater=m,this._instance=g,f.set(g,this);var M=g.state;void 0===M&&(g.state=M=null),"object"!=typeof M||Array.isArray(M)?s("106",this.getName()||"ReactCompositeComponent"):void 0,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1;var x;return x=g.unstable_handleError?this.performInitialMountWithErrorHandling(c,e,n,t,u):this.performInitialMount(c,e,n,t,u),g.componentDidMount&&t.getReactMountReady().enqueue(g.componentDidMount,g),x},_constructComponent:function(t,e,n,i){return this._constructComponentWithoutOwner(t,e,n,i)},_constructComponentWithoutOwner:function(t,e,n,i){var o=this._currentElement.type;return t?new o(e,n,i):o(e,n,i)},performInitialMountWithErrorHandling:function(t,e,n,i,o){var r,a=i.checkpoint();try{r=this.performInitialMount(t,e,n,i,o)}catch(s){i.rollback(a),this._instance.unstable_handleError(s),this._pendingStateQueue&&(this._instance.state=this._processPendingState(this._instance.props,this._instance.context)),a=i.checkpoint(),this._renderedComponent.unmountComponent(!0),i.rollback(a),r=this.performInitialMount(t,e,n,i,o)}return r},performInitialMount:function(t,e,n,i,o){var r=this._instance,a=0;r.componentWillMount&&(r.componentWillMount(),this._pendingStateQueue&&(r.state=this._processPendingState(r.props,r.context))),void 0===t&&(t=this._renderValidatedComponent());var s=d.getType(t);this._renderedNodeType=s;var u=this._instantiateReactComponent(t,s!==d.EMPTY);this._renderedComponent=u;var l=m.mountComponent(u,i,e,n,this._processChildContext(o),a);return l},getHostNode:function(){return m.getHostNode(this._renderedComponent)},unmountComponent:function(t){if(this._renderedComponent){var e=this._instance;if(e.componentWillUnmount&&!e._calledComponentWillUnmount)if(e._calledComponentWillUnmount=!0,t){var n=this.getName()+".componentWillUnmount()";p.invokeGuardedCallback(n,e.componentWillUnmount.bind(e))}else e.componentWillUnmount();this._renderedComponent&&(m.unmountComponent(this._renderedComponent,t),this._renderedNodeType=null,this._renderedComponent=null,this._instance=null),this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._pendingCallbacks=null,this._pendingElement=null,this._context=null,this._rootNodeID=0,this._topLevelWrapper=null,f.remove(e)}},_maskContext:function(t){var e=this._currentElement.type,n=e.contextTypes;if(!n)return _;var i={};for(var o in n)i[o]=t[o];return i},_processContext:function(t){var e=this._maskContext(t);return e},_processChildContext:function(t){var e,n=this._currentElement.type,i=this._instance;if(i.getChildContext&&(e=i.getChildContext()),e){"object"!=typeof n.childContextTypes?s("107",this.getName()||"ReactCompositeComponent"):void 0;for(var o in e)o in n.childContextTypes?void 0:s("108",this.getName()||"ReactCompositeComponent",o);return u({},t,e)}return t},_checkContextTypes:function(t,e,n){},receiveComponent:function(t,e,n){var i=this._currentElement,o=this._context;this._pendingElement=null,this.updateComponent(e,i,t,o,n)},performUpdateIfNecessary:function(t){null!=this._pendingElement?m.receiveComponent(this,this._pendingElement,t,this._context):null!==this._pendingStateQueue||this._pendingForceUpdate?this.updateComponent(t,this._currentElement,this._currentElement,this._context,this._context):this._updateBatchNumber=null},updateComponent:function(t,e,n,i,o){var r=this._instance;null==r?s("136",this.getName()||"ReactCompositeComponent"):void 0;var a,u=!1;this._context===o?a=r.context:(a=this._processContext(o),u=!0);var l=e.props,c=n.props;e!==n&&(u=!0),u&&r.componentWillReceiveProps&&r.componentWillReceiveProps(c,a);var h=this._processPendingState(c,a),p=!0;this._pendingForceUpdate||(r.shouldComponentUpdate?p=r.shouldComponentUpdate(c,h,a):this._compositeType===y.PureClass&&(p=!v(l,c)||!v(r.state,h))),this._updateBatchNumber=null,p?(this._pendingForceUpdate=!1,this._performComponentUpdate(n,c,h,a,t,o)):(this._currentElement=n,this._context=o,r.props=c,r.state=h,r.context=a)},_processPendingState:function(t,e){var n=this._instance,i=this._pendingStateQueue,o=this._pendingReplaceState;if(this._pendingReplaceState=!1,this._pendingStateQueue=null,!i)return n.state;if(o&&1===i.length)return i[0];for(var r=u({},o?i[0]:n.state),a=o?1:0;a=0||null!=e.is}function m(t){var e=t.type;f(e),this._currentElement=t,this._tag=e.toLowerCase(),this._namespaceURI=null,this._renderedChildren=null,this._previousStyle=null,this._previousStyleCopy=null,this._hostNode=null,this._hostParent=null,this._rootNodeID=0,this._domID=0,this._hostContainerInfo=null,this._wrapperState=null,this._topLevelWrapper=null,this._flags=0}var _=n(3),v=n(6),g=n(200),y=n(202),b=n(19),M=n(43),x=n(20),w=n(74),P=n(24),E=n(44),C=n(31),T=n(75),k=n(5),O=n(218),S=n(219),I=n(76),L=n(222),D=(n(9),n(231)),A=n(236),N=(n(8),n(34)),R=(n(1),n(55),n(38),n(88)),j=(n(57),n(2),T),z=P.deleteListener,U=k.getNodeFromInstance,F=C.listenTo,B=E.registrationNameModules,W={string:!0,number:!0},G="style",Z="__html",H={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null},q=11,V={topAbort:"abort",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topSeeked:"seeked",topSeeking:"seeking",topStalled:"stalled",topSuspend:"suspend",topTimeUpdate:"timeupdate",topVolumeChange:"volumechange",topWaiting:"waiting"},K={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},Y={listing:!0,pre:!0,textarea:!0},X=v({menuitem:!0},K),Q=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,$={},J={}.hasOwnProperty,tt=1;m.displayName="ReactDOMComponent",m.Mixin={mountComponent:function(t,e,n,i){this._rootNodeID=tt++,this._domID=n._idCounter++,this._hostParent=e,this._hostContainerInfo=n;var r=this._currentElement.props;switch(this._tag){case"audio":case"form":case"iframe":case"img":case"link":case"object":case"source":case"video":this._wrapperState={listeners:null},t.getReactMountReady().enqueue(h,this);break;case"input":O.mountWrapper(this,r,e),r=O.getHostProps(this,r),t.getReactMountReady().enqueue(c,this),t.getReactMountReady().enqueue(h,this);break;case"option":S.mountWrapper(this,r,e),r=S.getHostProps(this,r);break;case"select":I.mountWrapper(this,r,e),r=I.getHostProps(this,r),t.getReactMountReady().enqueue(h,this);break;case"textarea":L.mountWrapper(this,r,e),r=L.getHostProps(this,r),t.getReactMountReady().enqueue(c,this),t.getReactMountReady().enqueue(h,this)}o(this,r);var a,p;null!=e?(a=e._namespaceURI,p=e._tag):n._tag&&(a=n._namespaceURI,p=n._tag),(null==a||a===M.svg&&"foreignobject"===p)&&(a=M.html),a===M.html&&("svg"===this._tag?a=M.svg:"math"===this._tag&&(a=M.mathml)),this._namespaceURI=a;var f;if(t.useCreateElement){var d,m=n._ownerDocument;if(a===M.html)if("script"===this._tag){var _=m.createElement("div"),v=this._currentElement.type;_.innerHTML="<"+v+">",d=_.removeChild(_.firstChild)}else d=r.is?m.createElement(this._currentElement.type,r.is):m.createElement(this._currentElement.type);else d=m.createElementNS(a,this._currentElement.type);k.precacheNode(this,d),this._flags|=j.hasCachedChildNodes,this._hostParent||w.setAttributeForRoot(d),this._updateDOMProperties(null,r,t);var y=b(d);this._createInitialChildren(t,r,i,y),f=y}else{var x=this._createOpenTagMarkupAndPutListeners(t,r),P=this._createContentMarkup(t,r,i);f=!P&&K[this._tag]?x+"/>":x+">"+P+""}switch(this._tag){case"input":t.getReactMountReady().enqueue(s,this),r.autoFocus&&t.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"textarea":t.getReactMountReady().enqueue(u,this),r.autoFocus&&t.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"select":r.autoFocus&&t.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"button":r.autoFocus&&t.getReactMountReady().enqueue(g.focusDOMComponent,this);break;case"option":t.getReactMountReady().enqueue(l,this)}return f},_createOpenTagMarkupAndPutListeners:function(t,e){var n="<"+this._currentElement.type;for(var i in e)if(e.hasOwnProperty(i)){var o=e[i];if(null!=o)if(B.hasOwnProperty(i))o&&r(this,i,o,t);else{i===G&&(o&&(o=this._previousStyleCopy=v({},e.style)),o=y.createMarkupForStyles(o,this));var a=null;null!=this._tag&&d(this._tag,e)?H.hasOwnProperty(i)||(a=w.createMarkupForCustomAttribute(i,o)):a=w.createMarkupForProperty(i,o),a&&(n+=" "+a)}}return t.renderToStaticMarkup?n:(this._hostParent||(n+=" "+w.createMarkupForRoot()),n+=" "+w.createMarkupForID(this._domID))},_createContentMarkup:function(t,e,n){var i="",o=e.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&(i=o.__html);else{var r=W[typeof e.children]?e.children:null,a=null!=r?null:e.children;if(null!=r)i=N(r);else if(null!=a){var s=this.mountChildren(a,t,n);i=s.join("")}}return Y[this._tag]&&"\n"===i.charAt(0)?"\n"+i:i},_createInitialChildren:function(t,e,n,i){var o=e.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&b.queueHTML(i,o.__html);else{var r=W[typeof e.children]?e.children:null,a=null!=r?null:e.children;if(null!=r)""!==r&&b.queueText(i,r);else if(null!=a)for(var s=this.mountChildren(a,t,n),u=0;u"},receiveComponent:function(){},getHostNode:function(){return r.getNodeFromInstance(this)},unmountComponent:function(){r.uncacheNode(this)}}),t.exports=a},function(t,e){"use strict";var n={useCreateElement:!0,useFiber:!1};t.exports=n},function(t,e,n){"use strict";var i=n(42),o=n(5),r={dangerouslyProcessChildrenUpdates:function(t,e){var n=o.getNodeFromInstance(t);i.processUpdates(n,e)}};t.exports=r},function(t,e,n){"use strict";function i(){this._rootNodeID&&p.updateWrapper(this)}function o(t){var e="checkbox"===t.type||"radio"===t.type;return e?null!=t.checked:null!=t.value}function r(t){var e=this._currentElement.props,n=l.executeOnChange(e,t);h.asap(i,this);var o=e.name;if("radio"===e.type&&null!=o){for(var r=c.getNodeFromInstance(this),s=r;s.parentNode;)s=s.parentNode;for(var u=s.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),p=0;pe.end?(n=e.end,i=e.start):(n=e.start,i=e.end),o.moveToElementText(t),o.moveStart("character",n),o.setEndPoint("EndToStart",o),o.moveEnd("character",i-n),o.select()}function s(t,e){if(window.getSelection){var n=window.getSelection(),i=t[c()].length,o=Math.min(e.start,i),r=void 0===e.end?o:Math.min(e.end,i);if(!n.extend&&o>r){var a=r;r=o,o=a}var s=l(t,o),u=l(t,r);if(s&&u){var h=document.createRange();h.setStart(s.node,s.offset),n.removeAllRanges(),o>r?(n.addRange(h),n.extend(u.node,u.offset)):(h.setEnd(u.node,u.offset),n.addRange(h))}}}var u=n(7),l=n(258),c=n(87),h=u.canUseDOM&&"selection"in document&&!("getSelection"in window),p={getOffsets:h?o:r,setOffsets:h?a:s};t.exports=p},function(t,e,n){"use strict";var i=n(3),o=n(6),r=n(42),a=n(19),s=n(5),u=n(34),l=(n(1),n(57),function(t){this._currentElement=t,this._stringText=""+t,this._hostNode=null,this._hostParent=null,this._domID=0,this._mountIndex=0,this._closingComment=null,this._commentNodes=null});o(l.prototype,{mountComponent:function(t,e,n,i){var o=n._idCounter++,r=" react-text: "+o+" ",l=" /react-text ";if(this._domID=o,this._hostParent=e,t.useCreateElement){var c=n._ownerDocument,h=c.createComment(r),p=c.createComment(l),f=a(c.createDocumentFragment());return a.queueChild(f,a(h)),this._stringText&&a.queueChild(f,a(c.createTextNode(this._stringText))),a.queueChild(f,a(p)),s.precacheNode(this,h),this._closingComment=p,f}var d=u(this._stringText);return t.renderToStaticMarkup?d:""+d+""},receiveComponent:function(t,e){if(t!==this._currentElement){this._currentElement=t;var n=""+t;if(n!==this._stringText){this._stringText=n;var i=this.getHostNode();r.replaceDelimitedText(i[0],i[1],n)}}},getHostNode:function(){var t=this._commentNodes;if(t)return t;if(!this._closingComment)for(var e=s.getNodeFromInstance(this),n=e.nextSibling;;){if(null==n?i("67",this._domID):void 0,8===n.nodeType&&" /react-text "===n.nodeValue){this._closingComment=n;break}n=n.nextSibling}return t=[this._hostNode,this._closingComment],this._commentNodes=t,t},unmountComponent:function(){this._closingComment=null,this._commentNodes=null,s.uncacheNode(this)}}),t.exports=l},function(t,e,n){"use strict";function i(){this._rootNodeID&&c.updateWrapper(this)}function o(t){var e=this._currentElement.props,n=s.executeOnChange(e,t);return l.asap(i,this),n}var r=n(3),a=n(6),s=n(47),u=n(5),l=n(11),c=(n(1),n(2),{getHostProps:function(t,e){null!=e.dangerouslySetInnerHTML?r("91"):void 0;var n=a({},e,{value:void 0,defaultValue:void 0,children:""+t._wrapperState.initialValue,onChange:t._wrapperState.onChange});return n},mountWrapper:function(t,e){var n=s.getValue(e),i=n;if(null==n){var a=e.defaultValue,u=e.children;null!=u&&(null!=a?r("92"):void 0,Array.isArray(u)&&(u.length<=1?void 0:r("93"),u=u[0]),a=""+u),null==a&&(a=""),i=a}t._wrapperState={initialValue:""+i,listeners:null,onChange:o.bind(t)}},updateWrapper:function(t){var e=t._currentElement.props,n=u.getNodeFromInstance(t),i=s.getValue(e);if(null!=i){var o=""+i;o!==n.value&&(n.value=o),null==e.defaultValue&&(n.defaultValue=o)}null!=e.defaultValue&&(n.defaultValue=e.defaultValue)},postMountWrapper:function(t){var e=u.getNodeFromInstance(t),n=e.textContent;n===t._wrapperState.initialValue&&(e.value=n)}});t.exports=c},function(t,e,n){"use strict";function i(t,e){"_hostNode"in t?void 0:u("33"),"_hostNode"in e?void 0:u("33");for(var n=0,i=t;i;i=i._hostParent)n++;for(var o=0,r=e;r;r=r._hostParent)o++;for(;n-o>0;)t=t._hostParent,n--;for(;o-n>0;)e=e._hostParent,o--;for(var a=n;a--;){if(t===e)return t;t=t._hostParent,e=e._hostParent}return null}function o(t,e){"_hostNode"in t?void 0:u("35"),"_hostNode"in e?void 0:u("35");for(;e;){if(e===t)return!0;e=e._hostParent}return!1}function r(t){return"_hostNode"in t?void 0:u("36"),t._hostParent}function a(t,e,n){for(var i=[];t;)i.push(t),t=t._hostParent;var o;for(o=i.length;o-- >0;)e(i[o],"captured",n);for(o=0;o0;)n(u[l],"captured",r)}var u=n(3);n(1);t.exports={isAncestor:o,getLowestCommonAncestor:i,getParentInstance:r,traverseTwoPhase:a,traverseEnterLeave:s}},function(t,e,n){"use strict";function i(){this.reinitializeTransaction()}var o=n(6),r=n(11),a=n(33),s=n(8),u={initialize:s,close:function(){p.isBatchingUpdates=!1}},l={initialize:s,close:r.flushBatchedUpdates.bind(r)},c=[l,u];o(i.prototype,a,{getTransactionWrappers:function(){return c}});var h=new i,p={isBatchingUpdates:!1,batchedUpdates:function(t,e,n,i,o,r){var a=p.isBatchingUpdates;return p.isBatchingUpdates=!0,a?t(e,n,i,o,r):h.perform(t,null,e,n,i,o,r)}};t.exports=p},function(t,e,n){"use strict";function i(){w||(w=!0,g.EventEmitter.injectReactEventListener(v),g.EventPluginHub.injectEventPluginOrder(s),g.EventPluginUtils.injectComponentTree(p),g.EventPluginUtils.injectTreeTraversal(d),g.EventPluginHub.injectEventPluginsByName({SimpleEventPlugin:x,EnterLeaveEventPlugin:u,ChangeEventPlugin:a,SelectEventPlugin:M,BeforeInputEventPlugin:r}),g.HostComponent.injectGenericComponentClass(h),g.HostComponent.injectTextComponentClass(m),g.DOMProperty.injectDOMPropertyConfig(o),g.DOMProperty.injectDOMPropertyConfig(l),g.DOMProperty.injectDOMPropertyConfig(b),g.EmptyComponent.injectEmptyComponentFactory(function(t){return new f(t)}),g.Updates.injectReconcileTransaction(y),g.Updates.injectBatchingStrategy(_),g.Component.injectEnvironment(c))}var o=n(199),r=n(201),a=n(203),s=n(205),u=n(206),l=n(208),c=n(210),h=n(213),p=n(5),f=n(215),d=n(223),m=n(221),_=n(224),v=n(228),g=n(229),y=n(234),b=n(239),M=n(240),x=n(241),w=!1;t.exports={inject:i}},97,function(t,e,n){"use strict";function i(t){o.enqueueEvents(t),o.processEventQueue(!1)}var o=n(24),r={handleTopLevel:function(t,e,n,r){var a=o.extractEvents(t,e,n,r);i(a)}};t.exports=r},function(t,e,n){"use strict";function i(t){for(;t._hostParent;)t=t._hostParent;var e=h.getNodeFromInstance(t),n=e.parentNode;return h.getClosestInstanceFromNode(n)}function o(t,e){this.topLevelType=t,this.nativeEvent=e,this.ancestors=[]}function r(t){var e=f(t.nativeEvent),n=h.getClosestInstanceFromNode(e),o=n;do t.ancestors.push(o),o=o&&i(o);while(o);for(var r=0;r/,r=/^<\!\-\-/,a={CHECKSUM_ATTR_NAME:"data-react-checksum",addChecksumToMarkup:function(t){var e=i(t);return r.test(t)?t:t.replace(o," "+a.CHECKSUM_ATTR_NAME+'="'+e+'"$&')},canReuseMarkup:function(t,e){var n=e.getAttribute(a.CHECKSUM_ATTR_NAME);n=n&&parseInt(n,10);var o=i(t);return o===n}};t.exports=a},function(t,e,n){"use strict";function i(t,e,n){return{type:"INSERT_MARKUP",content:t,fromIndex:null,fromNode:null,toIndex:n,afterNode:e}}function o(t,e,n){return{type:"MOVE_EXISTING",content:null,fromIndex:t._mountIndex,fromNode:p.getHostNode(t),toIndex:n,afterNode:e}}function r(t,e){return{type:"REMOVE_NODE",content:null,fromIndex:t._mountIndex,fromNode:e,toIndex:null,afterNode:null}}function a(t){return{type:"SET_MARKUP",content:t,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function s(t){return{type:"TEXT_CONTENT",content:t,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function u(t,e){return e&&(t=t||[],t.push(e)),t}function l(t,e){h.processChildrenUpdates(t,e)}var c=n(3),h=n(48),p=(n(26),n(9),n(15),n(21)),f=n(209),d=(n(8),n(255)),m=(n(1),{Mixin:{_reconcilerInstantiateChildren:function(t,e,n){return f.instantiateChildren(t,e,n)},_reconcilerUpdateChildren:function(t,e,n,i,o,r){var a,s=0;return a=d(e,s),f.updateChildren(t,a,n,i,o,this,this._hostContainerInfo,r,s),a},mountChildren:function(t,e,n){var i=this._reconcilerInstantiateChildren(t,e,n);this._renderedChildren=i;var o=[],r=0;for(var a in i)if(i.hasOwnProperty(a)){var s=i[a],u=0,l=p.mountComponent(s,e,this,this._hostContainerInfo,n,u);s._mountIndex=r++,o.push(l)}return o},updateTextContent:function(t){var e=this._renderedChildren;f.unmountChildren(e,!1);for(var n in e)e.hasOwnProperty(n)&&c("118");var i=[s(t)];l(this,i)},updateMarkup:function(t){var e=this._renderedChildren;f.unmountChildren(e,!1);for(var n in e)e.hasOwnProperty(n)&&c("118");var i=[a(t)];l(this,i)},updateChildren:function(t,e,n){this._updateChildren(t,e,n)},_updateChildren:function(t,e,n){var i=this._renderedChildren,o={},r=[],a=this._reconcilerUpdateChildren(i,t,r,o,e,n);if(a||i){var s,c=null,h=0,f=0,d=0,m=null;for(s in a)if(a.hasOwnProperty(s)){var _=i&&i[s],v=a[s];_===v?(c=u(c,this.moveChild(_,m,h,f)),f=Math.max(_._mountIndex,f),_._mountIndex=h):(_&&(f=Math.max(_._mountIndex,f)),c=u(c,this._mountChildAtIndex(v,r[d],m,h,e,n)),d++),h++,m=p.getHostNode(v)}for(s in o)o.hasOwnProperty(s)&&(c=u(c,this._unmountChild(i[s],o[s])));c&&l(this,c),this._renderedChildren=a}},unmountChildren:function(t){var e=this._renderedChildren;f.unmountChildren(e,t),this._renderedChildren=null},moveChild:function(t,e,n,i){if(t._mountIndex=e)return{node:o,offset:e-r};r=a}o=n(i(o))}}t.exports=o},function(t,e,n){"use strict";function i(t,e){var n={};return n[t.toLowerCase()]=e.toLowerCase(),n["Webkit"+t]="webkit"+e,n["Moz"+t]="moz"+e,n["ms"+t]="MS"+e,n["O"+t]="o"+e.toLowerCase(),n}function o(t){if(s[t])return s[t];if(!a[t])return t;var e=a[t];for(var n in e)if(e.hasOwnProperty(n)&&n in u)return s[t]=e[n];return""}var r=n(7),a={animationend:i("Animation","AnimationEnd"),animationiteration:i("Animation","AnimationIteration"),animationstart:i("Animation","AnimationStart"),transitionend:i("Transition","TransitionEnd")},s={},u={};r.canUseDOM&&(u=document.createElement("div").style,"AnimationEvent"in window||(delete a.animationend.animation,delete a.animationiteration.animation,delete a.animationstart.animation),"TransitionEvent"in window||delete a.transitionend.transition),t.exports=o},function(t,e,n){"use strict";function i(t){return'"'+o(t)+'"'}var o=n(34);t.exports=i},function(t,e,n){"use strict";var i=n(81);t.exports=i.renderSubtreeIntoContainer},function(t,e,n){!function(e,i){t.exports=i(n(4),n(41))}(this,function(t,e){return function(t){function e(i){if(n[i])return n[i].exports;var o=n[i]={exports:{},id:i,loaded:!1};return t[i].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){(function(i){"use strict";function o(t){return t&&t.__esModule?t:{default:t}}function r(t,e){var n={};for(var i in t)e.indexOf(i)>=0||Object.prototype.hasOwnProperty.call(t,i)&&(n[i]=t[i]);return n}function a(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e0||(this.setState({draggedFiles:[]}),this.props.onDragLeave&&this.props.onDragLeave.call(this,t))}},{key:"onDrop",value:function t(e){var n=this,o=this.props,t=o.onDrop,r=o.onDropAccepted,s=o.onDropRejected,u=o.multiple,l=o.disablePreview,h=o.accept,p=(0,b.default)(e),f=[],d=[];e.preventDefault(),this.dragTargets=[],this.isFileDialogActive=!1,p.forEach(function(t){if(!l)try{t.preview=window.URL.createObjectURL(t)}catch(e){"production"!==i.env.NODE_ENV&&console.error("Failed to generate preview for file",t,e)}c(t,h)&&n.fileMatchSize(t)?f.push(t):d.push(t)}),u||d.push.apply(d,a(f.splice(1))),t&&t.call(this,f,d,e),d.length>0&&s&&s.call(this,d,e),f.length>0&&r&&r.call(this,f,e),this.draggedFiles=null,this.setState({draggedFiles:[],acceptedFiles:f,rejectedFiles:d})}},{key:"onClick",value:function t(e){var n=this.props,t=n.onClick,i=n.disableClick;i||(e.stopPropagation(),t&&t.call(this,e),setTimeout(this.open.bind(this),0))}},{key:"onInputElementClick",value:function(t){t.stopPropagation(),this.props.inputProps&&this.props.inputProps.onClick&&this.props.inputProps.onClick()}},{key:"onFileDialogCancel",value:function t(){var t=this.props.onFileDialogCancel,e=this.fileInputEl,n=this.isFileDialogActive;t&&n&&setTimeout(function(){var i=e.files;i.length||(n=!1,t())},300)}},{key:"setRef",value:function(t){this.node=t}},{key:"setRefs",value:function(t){this.fileInputEl=t}},{key:"fileMatchSize",value:function(t){return t.size<=this.props.maxSize&&t.size>=this.props.minSize}},{key:"allFilesAccepted",value:function(t){var e=this;return t.every(function(t){return c(t,e.props.accept)})}},{key:"open",value:function(){this.isFileDialogActive=!0,this.fileInputEl.value=null,this.fileInputEl.click()}},{key:"render",value:function(){var t=this.props,e=t.accept,n=t.activeClassName,i=t.inputProps,o=t.multiple,a=t.name,s=t.rejectClassName,u=t.children,l=r(t,["accept","activeClassName","inputProps","multiple","name","rejectClassName","children"]),c=l.activeStyle,p=l.className,f=l.rejectStyle,m=l.style,_=r(l,["activeStyle","className","rejectStyle","style"]),v=this.state.draggedFiles,g=v.length,y=o||g<=1,b=g>0&&this.allFilesAccepted(v),x=g>0&&(!b||!y);p=p||"",b&&n&&(p+=" "+n),x&&s&&(p+=" "+s),p||m||c||f||(m={width:200,height:200,borderWidth:2,borderColor:"#666",borderStyle:"dashed",borderRadius:5},c={borderStyle:"solid",borderColor:"#6c6",backgroundColor:"#eee"},f={borderStyle:"solid",borderColor:"#c66",backgroundColor:"#eee"});var w=void 0;w=c&&b?h({},m,c):f&&x?h({},m,f):h({},m);var P={accept:e,type:"file",style:{display:"none"},multiple:M&&o,ref:this.setRefs,onChange:this.onDrop};a&&a.length&&(P.name=a);var E=["acceptedFiles","preventDropOnDocument","disablePreview","disableClick","onDropAccepted","onDropRejected","onFileDialogCancel","maxSize","minSize"],C=h({},_);return E.forEach(function(t){return delete C[t]}),d.default.createElement("div",h({className:p,style:w},C,{onClick:this.onClick,onDragStart:this.onDragStart,onDragEnter:this.onDragEnter,onDragOver:this.onDragOver,onDragLeave:this.onDragLeave,onDrop:this.onDrop,ref:this.setRef}),this.renderChildren(u,b,x),d.default.createElement("input",h({},i,P)))}}]),e}(d.default.Component);x.propTypes={accept:_.default.string,children:_.default.oneOfType([_.default.node,_.default.func]),disableClick:_.default.bool,disablePreview:_.default.bool,preventDropOnDocument:_.default.bool,inputProps:_.default.object,multiple:_.default.bool,name:_.default.string,maxSize:_.default.number,minSize:_.default.number,className:_.default.string,activeClassName:_.default.string,rejectClassName:_.default.string,style:_.default.object,activeStyle:_.default.object,rejectStyle:_.default.object,onClick:_.default.func,onDrop:_.default.func,onDropAccepted:_.default.func,onDropRejected:_.default.func,onDragStart:_.default.func,onDragEnter:_.default.func,onDragOver:_.default.func,onDragLeave:_.default.func,onFileDialogCancel:_.default.func},x.defaultProps={preventDropOnDocument:!0,disablePreview:!1,disableClick:!1,multiple:!0,maxSize:1/0,minSize:0},e.default=x,t.exports=e.default}).call(e,n(1))},function(t,e){function n(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function o(t){if(c===setTimeout)return setTimeout(t,0);if((c===n||!c)&&setTimeout)return c=setTimeout,setTimeout(t,0);try{return c(t,0)}catch(e){try{return c.call(null,t,0)}catch(e){return c.call(this,t,0)}}}function r(t){if(h===clearTimeout)return clearTimeout(t);if((h===i||!h)&&clearTimeout)return h=clearTimeout,clearTimeout(t);try{return h(t)}catch(e){try{return h.call(null,t)}catch(e){return h.call(this,t)}}}function a(){m&&f&&(m=!1,f.length?d=f.concat(d):_=-1,d.length&&s())}function s(){if(!m){var t=o(a);m=!0;for(var e=d.length;e;){for(f=d,d=[];++_1)for(var n=1;n0?i:n)(t)}},function(t,e,n){var i=n(23),o=Math.min;t.exports=function(t){return t>0?o(i(t),9007199254740991):0}},function(t,e,n){"use strict";var i=n(3),o=n(24),r=n(21),a="endsWith",s=""[a];i(i.P+i.F*n(14)(a),"String",{endsWith:function(t){var e=r(this,t,a),n=arguments,i=n.length>1?n[1]:void 0,u=o(e.length),l=void 0===i?u:Math.min(o(i),u),c=String(t);return s?s.call(e,c,l):e.slice(l-c.length,l)===c}})},function(t,e,n){var i=n(5),o=n(3),r=n(1).Array||Array,a={},s=function(t,e){i.each.call(t.split(","),function(t){void 0==e&&t in r?a[t]=r[t]:t in[]&&(a[t]=n(12)(Function.call,[][t],e))})};s("pop,reverse,shift,keys,values,entries",1),s("indexOf,every,some,forEach,map,filter,find,findIndex,includes",3),s("join,slice,concat,push,splice,unshift,sort,lastIndexOf,reduce,reduceRight,copyWithin,fill"),o(o.S,"Array",a)}])},function(t,e){"use strict";function n(t){var e=[];if(t.dataTransfer){var n=t.dataTransfer;n.files&&n.files.length?e=n.files:n.items&&n.items.length&&(e=n.items)}else t.target&&t.target.files&&(e=t.target.files);return Array.prototype.slice.call(e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=n,t.exports=e.default}])})},function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}e.__esModule=!0,e.default=void 0;var s=n(4),u=n(41),l=i(u),c=n(93),h=i(c),p=n(94),f=(i(p),function(t){function e(n,i){o(this,e);var a=r(this,t.call(this,n,i));return a.store=n.store,a}return a(e,t),e.prototype.getChildContext=function(){return{store:this.store}},e.prototype.render=function(){return s.Children.only(this.props.children)},e}(s.Component));e.default=f,f.propTypes={store:h.default.isRequired,children:l.default.element.isRequired},f.childContextTypes={store:h.default.isRequired}},function(t,e,n){"use strict";function i(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t){return t.displayName||t.name||"Component"}function u(t,e){try{return t.apply(e)}catch(n){return T.value=n,T}}function l(t,e,n){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},l=Boolean(t),p=t||P,d=void 0;d="function"==typeof e?e:e?(0,v.default)(e):E;var _=n||C,g=i.pure,y=void 0===g||g,b=i.withRef,x=void 0!==b&&b,O=y&&_!==C,S=k++;return function(t){function e(t,e,n){var i=_(t,e,n);return i}var n="Connect("+s(t)+")",i=function(i){function s(t,e){o(this,s);var a=r(this,i.call(this,t,e));a.version=S,a.store=t.store||e.store,(0,w.default)(a.store,'Could not find "store" in either the context or '+('props of "'+n+'". ')+"Either wrap the root component in a , "+('or explicitly pass "store" as a prop to "'+n+'".'));var u=a.store.getState();return a.state={storeState:u},a.clearCache(),a}return a(s,i),s.prototype.shouldComponentUpdate=function(){return!y||this.haveOwnPropsChanged||this.hasStoreStateChanged},s.prototype.computeStateProps=function(t,e){if(!this.finalMapStateToProps)return this.configureFinalMapState(t,e);var n=t.getState(),i=this.doStatePropsDependOnOwnProps?this.finalMapStateToProps(n,e):this.finalMapStateToProps(n);return i},s.prototype.configureFinalMapState=function(t,e){var n=p(t.getState(),e),i="function"==typeof n;return this.finalMapStateToProps=i?n:p,this.doStatePropsDependOnOwnProps=1!==this.finalMapStateToProps.length,i?this.computeStateProps(t,e):n},s.prototype.computeDispatchProps=function(t,e){if(!this.finalMapDispatchToProps)return this.configureFinalMapDispatch(t,e);var n=t.dispatch,i=this.doDispatchPropsDependOnOwnProps?this.finalMapDispatchToProps(n,e):this.finalMapDispatchToProps(n);return i},s.prototype.configureFinalMapDispatch=function(t,e){var n=d(t.dispatch,e),i="function"==typeof n;return this.finalMapDispatchToProps=i?n:d,this.doDispatchPropsDependOnOwnProps=1!==this.finalMapDispatchToProps.length,i?this.computeDispatchProps(t,e):n},s.prototype.updateStatePropsIfNeeded=function(){var t=this.computeStateProps(this.store,this.props);return(!this.stateProps||!(0,m.default)(t,this.stateProps))&&(this.stateProps=t,!0)},s.prototype.updateDispatchPropsIfNeeded=function(){var t=this.computeDispatchProps(this.store,this.props);return(!this.dispatchProps||!(0,m.default)(t,this.dispatchProps))&&(this.dispatchProps=t,!0)},s.prototype.updateMergedPropsIfNeeded=function(){var t=e(this.stateProps,this.dispatchProps,this.props);return!(this.mergedProps&&O&&(0,m.default)(t,this.mergedProps))&&(this.mergedProps=t,!0)},s.prototype.isSubscribed=function(){return"function"==typeof this.unsubscribe},s.prototype.trySubscribe=function(){l&&!this.unsubscribe&&(this.unsubscribe=this.store.subscribe(this.handleChange.bind(this)),this.handleChange())},s.prototype.tryUnsubscribe=function(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=null)},s.prototype.componentDidMount=function(){this.trySubscribe()},s.prototype.componentWillReceiveProps=function(t){y&&(0,m.default)(t,this.props)||(this.haveOwnPropsChanged=!0)},s.prototype.componentWillUnmount=function(){this.tryUnsubscribe(),this.clearCache()},s.prototype.clearCache=function(){this.dispatchProps=null,this.stateProps=null,this.mergedProps=null,this.haveOwnPropsChanged=!0,this.hasStoreStateChanged=!0,this.haveStatePropsBeenPrecalculated=!1,this.statePropsPrecalculationError=null,this.renderedElement=null,this.finalMapDispatchToProps=null,this.finalMapStateToProps=null},s.prototype.handleChange=function(){if(this.unsubscribe){var t=this.store.getState(),e=this.state.storeState;if(!y||e!==t){if(y&&!this.doStatePropsDependOnOwnProps){var n=u(this.updateStatePropsIfNeeded,this);if(!n)return;n===T&&(this.statePropsPrecalculationError=T.value),this.haveStatePropsBeenPrecalculated=!0}this.hasStoreStateChanged=!0,this.setState({ +storeState:t})}}},s.prototype.getWrappedInstance=function(){return(0,w.default)(x,"To access the wrapped instance, you need to specify { withRef: true } as the fourth argument of the connect() call."),this.refs.wrappedInstance},s.prototype.render=function(){var e=this.haveOwnPropsChanged,n=this.hasStoreStateChanged,i=this.haveStatePropsBeenPrecalculated,o=this.statePropsPrecalculationError,r=this.renderedElement;if(this.haveOwnPropsChanged=!1,this.hasStoreStateChanged=!1,this.haveStatePropsBeenPrecalculated=!1,this.statePropsPrecalculationError=null,o)throw o;var a=!0,s=!0;y&&r&&(a=n||e&&this.doStatePropsDependOnOwnProps,s=e&&this.doDispatchPropsDependOnOwnProps);var u=!1,l=!1;i?u=!0:a&&(u=this.updateStatePropsIfNeeded()),s&&(l=this.updateDispatchPropsIfNeeded());var p=!0;return p=!!(u||l||e)&&this.updateMergedPropsIfNeeded(),!p&&r?r:(x?this.renderedElement=(0,h.createElement)(t,c({},this.mergedProps,{ref:"wrappedInstance"})):this.renderedElement=(0,h.createElement)(t,this.mergedProps),this.renderedElement)},s}(h.Component);return i.displayName=n,i.WrappedComponent=t,i.contextTypes={store:f.default},i.propTypes={store:f.default},(0,M.default)(i,t)}}e.__esModule=!0;var c=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},e=r({},l.default,t),n=e.logger,i=e.transformer,o=e.stateTransformer,u=e.errorTransformer,c=e.predicate,h=e.logErrors,p=e.diffPredicate;if("undefined"==typeof n)return function(){return function(t){return function(e){return t(e)}}};if(i&&console.error("Option 'transformer' is deprecated, use 'stateTransformer' instead!"),t.getState&&t.dispatch)return console.error("[redux-logger] redux-logger not installed. Make sure to pass logger instance as middleware:\n\n// Logger with default options\nimport { logger } from 'redux-logger'\nconst store = createStore(\n reducer,\n applyMiddleware(logger)\n)\n\n\n// Or you can create your own logger with custom options http://bit.ly/redux-logger-options\nimport createLogger from 'redux-logger'\n\nconst logger = createLogger({\n // ...options\n});\n\nconst store = createStore(\n reducer,\n applyMiddleware(logger)\n)\n"),function(){return function(t){return function(e){return t(e)}}};var f=[];return function(t){var n=t.getState;return function(t){return function(i){if("function"==typeof c&&!c(n,i))return t(i);var l={};f.push(l),l.started=s.timer.now(),l.startedTime=new Date,l.prevState=o(n()),l.action=i;var d=void 0;if(h)try{d=t(i)}catch(m){l.error=u(m)}else d=t(i);l.took=s.timer.now()-l.started,l.nextState=o(n());var _=e.diff&&"function"==typeof p?p(n,i):e.diff;if((0,a.printBuffer)(f,r({},e,{diff:_})),f.length=0,l.error)throw l.error;return d}}}}Object.defineProperty(e,"__esModule",{value:!0}),e.logger=e.defaults=void 0;var r=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},e=arguments[1];if(u)throw u;for(var i=!1,r={},a=0;a-1?e:t}function h(t,e){e=e||{};var n=e.body;if(h.prototype.isPrototypeOf(t)){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,e.headers||(this.headers=new o(t.headers)),this.method=t.method,this.mode=t.mode,n||(n=t._bodyInit,t.bodyUsed=!0)}else this.url=t;if(this.credentials=e.credentials||this.credentials||"omit",!e.headers&&this.headers||(this.headers=new o(e.headers)),this.method=c(e.method||this.method||"GET"),this.mode=e.mode||this.mode||null,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&n)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(n)}function p(t){var e=new FormData;return t.trim().split("&").forEach(function(t){if(t){var n=t.split("="),i=n.shift().replace(/\+/g," "),o=n.join("=").replace(/\+/g," ");e.append(decodeURIComponent(i),decodeURIComponent(o))}}),e}function f(t){var e=new o,n=(t.getAllResponseHeaders()||"").trim().split("\n");return n.forEach(function(t){var n=t.trim().split(":"),i=n.shift().trim(),o=n.join(":").trim();e.append(i,o)}),e}function d(t,e){e||(e={}),this.type="default",this.status=e.status,this.ok=this.status>=200&&this.status<300,this.statusText=e.statusText,this.headers=e.headers instanceof o?e.headers:new o(e.headers),this.url=e.url||"",this._initBody(t)}if(!t.fetch){var m={searchParams:"URLSearchParams"in t,iterable:"Symbol"in t&&"iterator"in Symbol,blob:"FileReader"in t&&"Blob"in t&&function(){try{return new Blob,!0}catch(t){return!1}}(),formData:"FormData"in t,arrayBuffer:"ArrayBuffer"in t};o.prototype.append=function(t,i){t=e(t),i=n(i);var o=this.map[t];o||(o=[],this.map[t]=o),o.push(i)},o.prototype.delete=function(t){delete this.map[e(t)]},o.prototype.get=function(t){var n=this.map[e(t)];return n?n[0]:null},o.prototype.getAll=function(t){return this.map[e(t)]||[]},o.prototype.has=function(t){return this.map.hasOwnProperty(e(t))},o.prototype.set=function(t,i){this.map[e(t)]=[n(i)]},o.prototype.forEach=function(t,e){Object.getOwnPropertyNames(this.map).forEach(function(n){this.map[n].forEach(function(i){t.call(e,i,n,this)},this)},this)},o.prototype.keys=function(){var t=[];return this.forEach(function(e,n){t.push(n)}),i(t)},o.prototype.values=function(){var t=[];return this.forEach(function(e){t.push(e)}),i(t)},o.prototype.entries=function(){var t=[];return this.forEach(function(e,n){t.push([n,e])}),i(t)},m.iterable&&(o.prototype[Symbol.iterator]=o.prototype.entries);var _=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];h.prototype.clone=function(){return new h(this)},l.call(h.prototype),l.call(d.prototype),d.prototype.clone=function(){return new d(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new o(this.headers),url:this.url})},d.error=function(){var t=new d(null,{status:0,statusText:""});return t.type="error",t};var v=[301,302,303,307,308];d.redirect=function(t,e){if(v.indexOf(e)===-1)throw new RangeError("Invalid status code");return new d(null,{status:e,headers:{location:t}})},t.Headers=o,t.Request=h,t.Response=d,t.fetch=function(t,e){return new Promise(function(n,i){function o(){return"responseURL"in a?a.responseURL:/^X-Request-URL:/m.test(a.getAllResponseHeaders())?a.getResponseHeader("X-Request-URL"):void 0}var r;r=h.prototype.isPrototypeOf(t)&&!e?t:new h(t,e);var a=new XMLHttpRequest;a.onload=function(){var t={status:a.status,statusText:a.statusText,headers:f(a),url:o()},e="response"in a?a.response:a.responseText;n(new d(e,t))},a.onerror=function(){i(new TypeError("Network request failed"))},a.ontimeout=function(){i(new TypeError("Network request failed"))},a.open(r.method,r.url,!0),"include"===r.credentials&&(a.withCredentials=!0),"responseType"in a&&m.blob&&(a.responseType="blob"),r.headers.forEach(function(t,e){a.setRequestHeader(e,t)}),a.send("undefined"==typeof r._bodyInit?null:r._bodyInit)})},t.fetch.polyfill=!0}}("undefined"!=typeof self?self:this)},function(t,e,n,i){"use strict";var o=n(i),r=(n(1),function(t){var e=this;if(e.instancePool.length){var n=e.instancePool.pop();return e.call(n,t),n}return new e(t)}),a=function(t,e){var n=this;if(n.instancePool.length){var i=n.instancePool.pop();return n.call(i,t,e),i}return new n(t,e)},s=function(t,e,n){var i=this;if(i.instancePool.length){var o=i.instancePool.pop();return i.call(o,t,e,n),o}return new i(t,e,n)},u=function(t,e,n,i){var o=this;if(o.instancePool.length){var r=o.instancePool.pop();return o.call(r,t,e,n,i),r}return new o(t,e,n,i)},l=function(t){var e=this;t instanceof e?void 0:o("25"),t.destructor(),e.instancePool.length 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n\t args[_key - 1] = arguments[_key];\n\t }\n\t\n\t var argIndex = 0;\n\t var message = 'Warning: ' + format.replace(/%s/g, function () {\n\t return args[argIndex++];\n\t });\n\t if (typeof console !== 'undefined') {\n\t console.error(message);\n\t }\n\t try {\n\t // --- Welcome to debugging React ---\n\t // This error was thrown as a convenience so that you can use this stack\n\t // to find the callsite that caused this warning to fire.\n\t throw new Error(message);\n\t } catch (x) {}\n\t };\n\t\n\t warning = function warning(condition, format) {\n\t if (format === undefined) {\n\t throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument');\n\t }\n\t\n\t if (format.indexOf('Failed Composite propType: ') === 0) {\n\t return; // Ignore CompositeComponent proptype check.\n\t }\n\t\n\t if (!condition) {\n\t for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {\n\t args[_key2 - 2] = arguments[_key2];\n\t }\n\t\n\t printWarning.apply(undefined, [format].concat(args));\n\t }\n\t };\n\t}\n\t\n\tmodule.exports = warning;\n\n/***/ },\n/* 3 */\n/***/ function(module, exports) {\n\n\t/**\n\t * Copyright (c) 2013-present, Facebook, Inc.\n\t *\n\t * This source code is licensed under the MIT license found in the\n\t * LICENSE file in the root directory of this source tree.\n\t *\n\t * \n\t */\n\t'use strict';\n\t\n\t/**\n\t * WARNING: DO NOT manually require this module.\n\t * This is a replacement for `invariant(...)` used by the error code system\n\t * and will _only_ be required by the corresponding babel pass.\n\t * It always throws.\n\t */\n\t\n\tfunction reactProdInvariant(code) {\n\t var argCount = arguments.length - 1;\n\t\n\t var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code;\n\t\n\t for (var argIdx = 0; argIdx < argCount; argIdx++) {\n\t message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]);\n\t }\n\t\n\t message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.';\n\t\n\t var error = new Error(message);\n\t error.name = 'Invariant Violation';\n\t error.framesToPop = 1; // we don't care about reactProdInvariant's own frame\n\t\n\t throw error;\n\t}\n\t\n\tmodule.exports = reactProdInvariant;\n\n/***/ },\n/* 4 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tmodule.exports = __webpack_require__(22);\n\n\n/***/ },\n/* 5 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/**\n\t * Copyright (c) 2013-present, Facebook, Inc.\n\t *\n\t * This source code is licensed under the MIT license found in the\n\t * LICENSE file in the root directory of this source tree.\n\t *\n\t */\n\t\n\t'use strict';\n\t\n\tvar _prodInvariant = __webpack_require__(3);\n\t\n\tvar DOMProperty = __webpack_require__(20);\n\tvar ReactDOMComponentFlags = __webpack_require__(75);\n\t\n\tvar invariant = __webpack_require__(1);\n\t\n\tvar ATTR_NAME = DOMProperty.ID_ATTRIBUTE_NAME;\n\tvar Flags = ReactDOMComponentFlags;\n\t\n\tvar internalInstanceKey = '__reactInternalInstance$' + Math.random().toString(36).slice(2);\n\t\n\t/**\n\t * Check if a given node should be cached.\n\t */\n\tfunction shouldPrecacheNode(node, nodeID) {\n\t return node.nodeType === 1 && node.getAttribute(ATTR_NAME) === String(nodeID) || node.nodeType === 8 && node.nodeValue === ' react-text: ' + nodeID + ' ' || node.nodeType === 8 && node.nodeValue === ' react-empty: ' + nodeID + ' ';\n\t}\n\t\n\t/**\n\t * Drill down (through composites and empty components) until we get a host or\n\t * host text component.\n\t *\n\t * This is pretty polymorphic but unavoidable with the current structure we have\n\t * for `_renderedChildren`.\n\t */\n\tfunction getRenderedHostOrTextFromComponent(component) {\n\t var rendered;\n\t while (rendered = component._renderedComponent) {\n\t component = rendered;\n\t }\n\t return component;\n\t}\n\t\n\t/**\n\t * Populate `_hostNode` on the rendered host/text component with the given\n\t * DOM node. The passed `inst` can be a composite.\n\t */\n\tfunction precacheNode(inst, node) {\n\t var hostInst = getRenderedHostOrTextFromComponent(inst);\n\t hostInst._hostNode = node;\n\t node[internalInstanceKey] = hostInst;\n\t}\n\t\n\tfunction uncacheNode(inst) {\n\t var node = inst._hostNode;\n\t if (node) {\n\t delete node[internalInstanceKey];\n\t inst._hostNode = null;\n\t }\n\t}\n\t\n\t/**\n\t * Populate `_hostNode` on each child of `inst`, assuming that the children\n\t * match up with the DOM (element) children of `node`.\n\t *\n\t * We cache entire levels at once to avoid an n^2 problem where we access the\n\t * children of a node sequentially and have to walk from the start to our target\n\t * node every time.\n\t *\n\t * Since we update `_renderedChildren` and the actual DOM at (slightly)\n\t * different times, we could race here and see a newer `_renderedChildren` than\n\t * the DOM nodes we see. To avoid this, ReactMultiChild calls\n\t * `prepareToManageChildren` before we change `_renderedChildren`, at which\n\t * time the container's child nodes are always cached (until it unmounts).\n\t */\n\tfunction precacheChildNodes(inst, node) {\n\t if (inst._flags & Flags.hasCachedChildNodes) {\n\t return;\n\t }\n\t var children = inst._renderedChildren;\n\t var childNode = node.firstChild;\n\t outer: for (var name in children) {\n\t if (!children.hasOwnProperty(name)) {\n\t continue;\n\t }\n\t var childInst = children[name];\n\t var childID = getRenderedHostOrTextFromComponent(childInst)._domID;\n\t if (childID === 0) {\n\t // We're currently unmounting this child in ReactMultiChild; skip it.\n\t continue;\n\t }\n\t // We assume the child nodes are in the same order as the child instances.\n\t for (; childNode !== null; childNode = childNode.nextSibling) {\n\t if (shouldPrecacheNode(childNode, childID)) {\n\t precacheNode(childInst, childNode);\n\t continue outer;\n\t }\n\t }\n\t // We reached the end of the DOM children without finding an ID match.\n\t true ? false ? invariant(false, 'Unable to find element with ID %s.', childID) : _prodInvariant('32', childID) : void 0;\n\t }\n\t inst._flags |= Flags.hasCachedChildNodes;\n\t}\n\t\n\t/**\n\t * Given a DOM node, return the closest ReactDOMComponent or\n\t * ReactDOMTextComponent instance ancestor.\n\t */\n\tfunction getClosestInstanceFromNode(node) {\n\t if (node[internalInstanceKey]) {\n\t return node[internalInstanceKey];\n\t }\n\t\n\t // Walk up the tree until we find an ancestor whose instance we have cached.\n\t var parents = [];\n\t while (!node[internalInstanceKey]) {\n\t parents.push(node);\n\t if (node.parentNode) {\n\t node = node.parentNode;\n\t } else {\n\t // Top of the tree. This node must not be part of a React tree (or is\n\t // unmounted, potentially).\n\t return null;\n\t }\n\t }\n\t\n\t var closest;\n\t var inst;\n\t for (; node && (inst = node[internalInstanceKey]); node = parents.pop()) {\n\t closest = inst;\n\t if (parents.length) {\n\t precacheChildNodes(inst, node);\n\t }\n\t }\n\t\n\t return closest;\n\t}\n\t\n\t/**\n\t * Given a DOM node, return the ReactDOMComponent or ReactDOMTextComponent\n\t * instance, or null if the node was not rendered by this React.\n\t */\n\tfunction getInstanceFromNode(node) {\n\t var inst = getClosestInstanceFromNode(node);\n\t if (inst != null && inst._hostNode === node) {\n\t return inst;\n\t } else {\n\t return null;\n\t }\n\t}\n\t\n\t/**\n\t * Given a ReactDOMComponent or ReactDOMTextComponent, return the corresponding\n\t * DOM node.\n\t */\n\tfunction getNodeFromInstance(inst) {\n\t // Without this first invariant, passing a non-DOM-component triggers the next\n\t // invariant for a missing parent, which is super confusing.\n\t !(inst._hostNode !== undefined) ? false ? invariant(false, 'getNodeFromInstance: Invalid argument.') : _prodInvariant('33') : void 0;\n\t\n\t if (inst._hostNode) {\n\t return inst._hostNode;\n\t }\n\t\n\t // Walk up the tree until we find an ancestor whose DOM node we have cached.\n\t var parents = [];\n\t while (!inst._hostNode) {\n\t parents.push(inst);\n\t !inst._hostParent ? false ? invariant(false, 'React DOM tree root should always have a node reference.') : _prodInvariant('34') : void 0;\n\t inst = inst._hostParent;\n\t }\n\t\n\t // Now parents contains each ancestor that does *not* have a cached native\n\t // node, and `inst` is the deepest ancestor that does.\n\t for (; parents.length; inst = parents.pop()) {\n\t precacheChildNodes(inst, inst._hostNode);\n\t }\n\t\n\t return inst._hostNode;\n\t}\n\t\n\tvar ReactDOMComponentTree = {\n\t getClosestInstanceFromNode: getClosestInstanceFromNode,\n\t getInstanceFromNode: getInstanceFromNode,\n\t getNodeFromInstance: getNodeFromInstance,\n\t precacheChildNodes: precacheChildNodes,\n\t precacheNode: precacheNode,\n\t uncacheNode: uncacheNode\n\t};\n\t\n\tmodule.exports = ReactDOMComponentTree;\n\n/***/ },\n/* 6 */\n/***/ function(module, exports) {\n\n\t/*\n\tobject-assign\n\t(c) Sindre Sorhus\n\t@license MIT\n\t*/\n\t\n\t'use strict';\n\t/* eslint-disable no-unused-vars */\n\tvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\n\tvar hasOwnProperty = Object.prototype.hasOwnProperty;\n\tvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\t\n\tfunction toObject(val) {\n\t\tif (val === null || val === undefined) {\n\t\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t\t}\n\t\n\t\treturn Object(val);\n\t}\n\t\n\tfunction shouldUseNative() {\n\t\ttry {\n\t\t\tif (!Object.assign) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\n\t\t\t// Detect buggy property enumeration order in older V8 versions.\n\t\n\t\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\t\ttest1[5] = 'de';\n\t\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\t\treturn false;\n\t\t\t}\n\t\n\t\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\t\tvar test2 = {};\n\t\t\tfor (var i = 0; i < 10; i++) {\n\t\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t\t}\n\t\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\t\treturn test2[n];\n\t\t\t});\n\t\t\tif (order2.join('') !== '0123456789') {\n\t\t\t\treturn false;\n\t\t\t}\n\t\n\t\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\t\tvar test3 = {};\n\t\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\t\ttest3[letter] = letter;\n\t\t\t});\n\t\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\t\treturn false;\n\t\t\t}\n\t\n\t\t\treturn true;\n\t\t} catch (err) {\n\t\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\t\treturn false;\n\t\t}\n\t}\n\t\n\tmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\t\tvar from;\n\t\tvar to = toObject(target);\n\t\tvar symbols;\n\t\n\t\tfor (var s = 1; s < arguments.length; s++) {\n\t\t\tfrom = Object(arguments[s]);\n\t\n\t\t\tfor (var key in from) {\n\t\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\t\tto[key] = from[key];\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\tif (getOwnPropertySymbols) {\n\t\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\n\t\treturn to;\n\t};\n\n\n/***/ },\n/* 7 */\n/***/ function(module, exports) {\n\n\t/**\n\t * Copyright (c) 2013-present, Facebook, Inc.\n\t *\n\t * This source code is licensed under the MIT license found in the\n\t * LICENSE file in the root directory of this source tree.\n\t *\n\t */\n\t\n\t'use strict';\n\t\n\tvar canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);\n\t\n\t/**\n\t * Simple, lightweight module assisting with the detection and context of\n\t * Worker. Helps avoid circular dependencies and allows code to reason about\n\t * whether or not they are in a Worker, even if they never include the main\n\t * `ReactWorker` dependency.\n\t */\n\tvar ExecutionEnvironment = {\n\t\n\t canUseDOM: canUseDOM,\n\t\n\t canUseWorkers: typeof Worker !== 'undefined',\n\t\n\t canUseEventListeners: canUseDOM && !!(window.addEventListener || window.attachEvent),\n\t\n\t canUseViewport: canUseDOM && !!window.screen,\n\t\n\t isInWorker: !canUseDOM // For now, this is true - might change in the future.\n\t\n\t};\n\t\n\tmodule.exports = ExecutionEnvironment;\n\n/***/ },\n/* 8 */\n/***/ function(module, exports) {\n\n\t\"use strict\";\n\t\n\t/**\n\t * Copyright (c) 2013-present, Facebook, Inc.\n\t *\n\t * This source code is licensed under the MIT license found in the\n\t * LICENSE file in the root directory of this source tree.\n\t *\n\t * \n\t */\n\t\n\tfunction makeEmptyFunction(arg) {\n\t return function () {\n\t return arg;\n\t };\n\t}\n\t\n\t/**\n\t * This function accepts and discards inputs; it has no side effects. This is\n\t * primarily useful idiomatically for overridable function endpoints which\n\t * always need to be callable, since JS lacks a null-call idiom ala Cocoa.\n\t */\n\tvar emptyFunction = function emptyFunction() {};\n\t\n\temptyFunction.thatReturns = makeEmptyFunction;\n\temptyFunction.thatReturnsFalse = makeEmptyFunction(false);\n\temptyFunction.thatReturnsTrue = makeEmptyFunction(true);\n\temptyFunction.thatReturnsNull = makeEmptyFunction(null);\n\temptyFunction.thatReturnsThis = function () {\n\t return this;\n\t};\n\temptyFunction.thatReturnsArgument = function (arg) {\n\t return arg;\n\t};\n\t\n\tmodule.exports = emptyFunction;\n\n/***/ },\n/* 9 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/**\n\t * Copyright (c) 2016-present, Facebook, Inc.\n\t *\n\t * This source code is licensed under the MIT license found in the\n\t * LICENSE file in the root directory of this source tree.\n\t *\n\t * \n\t */\n\t\n\t'use strict';\n\t\n\t// Trust the developer to only use ReactInstrumentation with a __DEV__ check\n\t\n\tvar debugTool = null;\n\t\n\tif (false) {\n\t var ReactDebugTool = require('./ReactDebugTool');\n\t debugTool = ReactDebugTool;\n\t}\n\t\n\tmodule.exports = { debugTool: debugTool };\n\n/***/ },\n/* 10 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\tObject.defineProperty(exports, \"__esModule\", {\n\t value: true\n\t});\n\texports.RECEIVE_GCP_FILE = exports.PREVIEW_GCP_FILE_CANCEL = exports.PREVIEW_GCP_FILE = exports.RECEIVE_IMAGE_FILES = exports.SELECT_IMAGE = exports.DELETE_IMAGE = exports.SET_CONTROL_POINT_POSITION = exports.TOGGLE_CONTROL_POINT_MODE = exports.ADD_CONTROL_POINT = exports.AWAIT_CONTROL_POINT = exports.HIGHLIGHT_CONTROL_POINT = exports.DELETE_CONTROL_POINT = exports.JOIN_CONTROL_POINT = exports.TOGGLE_MENU = exports.TOGGLE_EXPORT = exports.ON_WINDOW_RESIZE = undefined;\n\texports.onWindowResize = onWindowResize;\n\texports.toggleExport = toggleExport;\n\texports.toggleMenu = toggleMenu;\n\texports.joinControlPoint = joinControlPoint;\n\texports.deleteControlPoint = deleteControlPoint;\n\texports.highlightControlPoint = highlightControlPoint;\n\texports.awaitControlPoint = awaitControlPoint;\n\texports.addControlPoint = addControlPoint;\n\texports.toggleControlPointMode = toggleControlPointMode;\n\texports.setControlPointPosition = setControlPointPosition;\n\texports.deleteImageFile = deleteImageFile;\n\texports.selectImageFile = selectImageFile;\n\texports.receiveImageFiles = receiveImageFiles;\n\texports.previewGcpFile = previewGcpFile;\n\texports.previewGcpFileCancel = previewGcpFileCancel;\n\texports.receiveGcpFile = receiveGcpFile;\n\t\n\tvar _coordinateSystems = __webpack_require__(36);\n\t\n\tfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\t\n\tvar ON_WINDOW_RESIZE = exports.ON_WINDOW_RESIZE = 'ON_WINDOW_RESIZE';\n\tfunction onWindowResize(size) {\n\t return {\n\t type: ON_WINDOW_RESIZE,\n\t size: size\n\t };\n\t}\n\t\n\tvar TOGGLE_EXPORT = exports.TOGGLE_EXPORT = 'TOGGLE_EXPORT';\n\tfunction toggleExport() {\n\t return {\n\t type: TOGGLE_EXPORT\n\t };\n\t}\n\t\n\tvar TOGGLE_MENU = exports.TOGGLE_MENU = 'TOGGLE_MENU';\n\tfunction toggleMenu() {\n\t return {\n\t type: TOGGLE_MENU\n\t };\n\t}\n\t\n\tvar JOIN_CONTROL_POINT = exports.JOIN_CONTROL_POINT = 'JOIN_CONTROL_POINT';\n\tfunction joinControlPoint(id) {\n\t return {\n\t type: JOIN_CONTROL_POINT,\n\t id: id\n\t };\n\t}\n\t\n\tvar DELETE_CONTROL_POINT = exports.DELETE_CONTROL_POINT = 'DELETE_CONTROL_POINT';\n\tfunction deleteControlPoint(id) {\n\t return {\n\t type: DELETE_CONTROL_POINT,\n\t id: id\n\t };\n\t}\n\t\n\tvar HIGHLIGHT_CONTROL_POINT = exports.HIGHLIGHT_CONTROL_POINT = 'HIGHLIGHT_CONTROL_POINT';\n\tfunction highlightControlPoint(id) {\n\t return {\n\t type: HIGHLIGHT_CONTROL_POINT,\n\t id: id\n\t };\n\t}\n\t\n\tvar AWAIT_CONTROL_POINT = exports.AWAIT_CONTROL_POINT = 'AWAIT_CONTROL_POINT';\n\tfunction awaitControlPoint(image_loc) {\n\t return {\n\t type: AWAIT_CONTROL_POINT,\n\t image_loc: image_loc\n\t };\n\t}\n\t\n\tvar ADD_CONTROL_POINT = exports.ADD_CONTROL_POINT = 'ADD_CONTROL_POINT';\n\tfunction addControlPoint(coord, img_name, isImage) {\n\t var _ref;\n\t\n\t var k = isImage ? 'img_coord' : 'map_coord';\n\t return _ref = {\n\t type: ADD_CONTROL_POINT\n\t }, _defineProperty(_ref, k, coord), _defineProperty(_ref, 'img_name', img_name), _defineProperty(_ref, 'isImage', isImage), _ref;\n\t}\n\t\n\tvar TOGGLE_CONTROL_POINT_MODE = exports.TOGGLE_CONTROL_POINT_MODE = 'TOGGLE_CONTROL_POINT_MODE';\n\tfunction toggleControlPointMode(id) {\n\t return {\n\t type: TOGGLE_CONTROL_POINT_MODE,\n\t id: id\n\t };\n\t}\n\t\n\tvar SET_CONTROL_POINT_POSITION = exports.SET_CONTROL_POINT_POSITION = 'SET_CONTROL_POINT_POSITION';\n\tfunction setControlPointPosition(loc, id, pos) {\n\t return {\n\t type: SET_CONTROL_POINT_POSITION,\n\t loc: loc,\n\t id: id,\n\t pos: pos\n\t };\n\t}\n\t\n\tvar DELETE_IMAGE = exports.DELETE_IMAGE = 'DELETE_IMAGE';\n\tfunction deleteImageFile(name) {\n\t return {\n\t type: DELETE_IMAGE,\n\t name: name\n\t };\n\t}\n\t\n\tvar SELECT_IMAGE = exports.SELECT_IMAGE = 'SELECT_IMAGE';\n\tfunction selectImageFile(img_name) {\n\t return {\n\t type: SELECT_IMAGE,\n\t img_name: img_name\n\t };\n\t}\n\t\n\tvar RECEIVE_IMAGE_FILES = exports.RECEIVE_IMAGE_FILES = 'RECEIVE_IMAGE_FILES';\n\t// Expects an array of File / Blob objects or strings\n\tfunction receiveImageFiles(files) {\n\t // var isFileObjects = Object.prototype.toString.call(files[0]) === '[object File]' || Object.prototype.toString.call(files[0]) === '[object Blob]';\n\t\n\t var now = Date.now();\n\t files.forEach(function (f, i) {\n\t f.id = now + i;\n\t });\n\t\n\t return {\n\t type: RECEIVE_IMAGE_FILES,\n\t items: files,\n\t receivedAt: now\n\t };\n\t}\n\t\n\tvar PREVIEW_GCP_FILE = exports.PREVIEW_GCP_FILE = 'PREVIEW_GCP_FILE';\n\t\n\tfunction previewGcpFile(name, content) {\n\t return {\n\t type: PREVIEW_GCP_FILE,\n\t receivedAt: Date.now(),\n\t file_name: name,\n\t gcp_list_text: content\n\t };\n\t}\n\t\n\tvar PREVIEW_GCP_FILE_CANCEL = exports.PREVIEW_GCP_FILE_CANCEL = 'PREVIEW_GCP_FILE_CANCEL';\n\t\n\tfunction previewGcpFileCancel() {\n\t return {\n\t type: PREVIEW_GCP_FILE_CANCEL\n\t };\n\t}\n\t\n\tvar RECEIVE_GCP_FILE = exports.RECEIVE_GCP_FILE = 'RECEIVE_GCP_FILE';\n\t\n\tfunction receiveGcpFile(file_name, file_content) {\n\t var newline = /\\r|\\n/g;\n\t var delimiter = /\\s|\\t|,|\\|/g;\n\t\n\t var lines = file_content.split(newline);\n\t var rows = lines;\n\t var sourceProjection = void 0;\n\t\n\t if ((0, _coordinateSystems.isProjectionString)(lines[0])) {\n\t sourceProjection = lines[0];\n\t rows = lines.slice(1);\n\t }\n\t rows = rows.map(function (r) {\n\t return r.split(delimiter);\n\t }).map(function (r) {\n\t return r.map(function (d) {\n\t return !isNaN(d) ? +d : d;\n\t });\n\t });\n\t\n\t return {\n\t type: RECEIVE_GCP_FILE,\n\t receivedAt: Date.now(),\n\t projection: 'EPSG:4326',\n\t rows: rows,\n\t sourceProjection: sourceProjection,\n\t file_name: file_name\n\t };\n\t}\n\n/***/ },\n/* 11 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/**\n\t * Copyright (c) 2013-present, Facebook, Inc.\n\t *\n\t * This source code is licensed under the MIT license found in the\n\t * LICENSE file in the root directory of this source tree.\n\t *\n\t */\n\t\n\t'use strict';\n\t\n\tvar _prodInvariant = __webpack_require__(3),\n\t _assign = __webpack_require__(6);\n\t\n\tvar CallbackQueue = __webpack_require__(73);\n\tvar PooledClass = __webpack_require__(18);\n\tvar ReactFeatureFlags = __webpack_require__(78);\n\tvar ReactReconciler = __webpack_require__(21);\n\tvar Transaction = __webpack_require__(33);\n\t\n\tvar invariant = __webpack_require__(1);\n\t\n\tvar dirtyComponents = [];\n\tvar updateBatchNumber = 0;\n\tvar asapCallbackQueue = CallbackQueue.getPooled();\n\tvar asapEnqueued = false;\n\t\n\tvar batchingStrategy = null;\n\t\n\tfunction ensureInjected() {\n\t !(ReactUpdates.ReactReconcileTransaction && batchingStrategy) ? false ? invariant(false, 'ReactUpdates: must inject a reconcile transaction class and batching strategy') : _prodInvariant('123') : void 0;\n\t}\n\t\n\tvar NESTED_UPDATES = {\n\t initialize: function () {\n\t this.dirtyComponentsLength = dirtyComponents.length;\n\t },\n\t close: function () {\n\t if (this.dirtyComponentsLength !== dirtyComponents.length) {\n\t // Additional updates were enqueued by componentDidUpdate handlers or\n\t // similar; before our own UPDATE_QUEUEING wrapper closes, we want to run\n\t // these new updates so that if A's componentDidUpdate calls setState on\n\t // B, B will update before the callback A's updater provided when calling\n\t // setState.\n\t dirtyComponents.splice(0, this.dirtyComponentsLength);\n\t flushBatchedUpdates();\n\t } else {\n\t dirtyComponents.length = 0;\n\t }\n\t }\n\t};\n\t\n\tvar UPDATE_QUEUEING = {\n\t initialize: function () {\n\t this.callbackQueue.reset();\n\t },\n\t close: function () {\n\t this.callbackQueue.notifyAll();\n\t }\n\t};\n\t\n\tvar TRANSACTION_WRAPPERS = [NESTED_UPDATES, UPDATE_QUEUEING];\n\t\n\tfunction ReactUpdatesFlushTransaction() {\n\t this.reinitializeTransaction();\n\t this.dirtyComponentsLength = null;\n\t this.callbackQueue = CallbackQueue.getPooled();\n\t this.reconcileTransaction = ReactUpdates.ReactReconcileTransaction.getPooled(\n\t /* useCreateElement */true);\n\t}\n\t\n\t_assign(ReactUpdatesFlushTransaction.prototype, Transaction, {\n\t getTransactionWrappers: function () {\n\t return TRANSACTION_WRAPPERS;\n\t },\n\t\n\t destructor: function () {\n\t this.dirtyComponentsLength = null;\n\t CallbackQueue.release(this.callbackQueue);\n\t this.callbackQueue = null;\n\t ReactUpdates.ReactReconcileTransaction.release(this.reconcileTransaction);\n\t this.reconcileTransaction = null;\n\t },\n\t\n\t perform: function (method, scope, a) {\n\t // Essentially calls `this.reconcileTransaction.perform(method, scope, a)`\n\t // with this transaction's wrappers around it.\n\t return Transaction.perform.call(this, this.reconcileTransaction.perform, this.reconcileTransaction, method, scope, a);\n\t }\n\t});\n\t\n\tPooledClass.addPoolingTo(ReactUpdatesFlushTransaction);\n\t\n\tfunction batchedUpdates(callback, a, b, c, d, e) {\n\t ensureInjected();\n\t return batchingStrategy.batchedUpdates(callback, a, b, c, d, e);\n\t}\n\t\n\t/**\n\t * Array comparator for ReactComponents by mount ordering.\n\t *\n\t * @param {ReactComponent} c1 first component you're comparing\n\t * @param {ReactComponent} c2 second component you're comparing\n\t * @return {number} Return value usable by Array.prototype.sort().\n\t */\n\tfunction mountOrderComparator(c1, c2) {\n\t return c1._mountOrder - c2._mountOrder;\n\t}\n\t\n\tfunction runBatchedUpdates(transaction) {\n\t var len = transaction.dirtyComponentsLength;\n\t !(len === dirtyComponents.length) ? false ? invariant(false, 'Expected flush transaction\\'s stored dirty-components length (%s) to match dirty-components array length (%s).', len, dirtyComponents.length) : _prodInvariant('124', len, dirtyComponents.length) : void 0;\n\t\n\t // Since reconciling a component higher in the owner hierarchy usually (not\n\t // always -- see shouldComponentUpdate()) will reconcile children, reconcile\n\t // them before their children by sorting the array.\n\t dirtyComponents.sort(mountOrderComparator);\n\t\n\t // Any updates enqueued while reconciling must be performed after this entire\n\t // batch. Otherwise, if dirtyComponents is [A, B] where A has children B and\n\t // C, B could update twice in a single batch if C's render enqueues an update\n\t // to B (since B would have already updated, we should skip it, and the only\n\t // way we can know to do so is by checking the batch counter).\n\t updateBatchNumber++;\n\t\n\t for (var i = 0; i < len; i++) {\n\t // If a component is unmounted before pending changes apply, it will still\n\t // be here, but we assume that it has cleared its _pendingCallbacks and\n\t // that performUpdateIfNecessary is a noop.\n\t var component = dirtyComponents[i];\n\t\n\t // If performUpdateIfNecessary happens to enqueue any new updates, we\n\t // shouldn't execute the callbacks until the next render happens, so\n\t // stash the callbacks first\n\t var callbacks = component._pendingCallbacks;\n\t component._pendingCallbacks = null;\n\t\n\t var markerName;\n\t if (ReactFeatureFlags.logTopLevelRenders) {\n\t var namedComponent = component;\n\t // Duck type TopLevelWrapper. This is probably always true.\n\t if (component._currentElement.type.isReactTopLevelWrapper) {\n\t namedComponent = component._renderedComponent;\n\t }\n\t markerName = 'React update: ' + namedComponent.getName();\n\t console.time(markerName);\n\t }\n\t\n\t ReactReconciler.performUpdateIfNecessary(component, transaction.reconcileTransaction, updateBatchNumber);\n\t\n\t if (markerName) {\n\t console.timeEnd(markerName);\n\t }\n\t\n\t if (callbacks) {\n\t for (var j = 0; j < callbacks.length; j++) {\n\t transaction.callbackQueue.enqueue(callbacks[j], component.getPublicInstance());\n\t }\n\t }\n\t }\n\t}\n\t\n\tvar flushBatchedUpdates = function () {\n\t // ReactUpdatesFlushTransaction's wrappers will clear the dirtyComponents\n\t // array and perform any updates enqueued by mount-ready handlers (i.e.,\n\t // componentDidUpdate) but we need to check here too in order to catch\n\t // updates enqueued by setState callbacks and asap calls.\n\t while (dirtyComponents.length || asapEnqueued) {\n\t if (dirtyComponents.length) {\n\t var transaction = ReactUpdatesFlushTransaction.getPooled();\n\t transaction.perform(runBatchedUpdates, null, transaction);\n\t ReactUpdatesFlushTransaction.release(transaction);\n\t }\n\t\n\t if (asapEnqueued) {\n\t asapEnqueued = false;\n\t var queue = asapCallbackQueue;\n\t asapCallbackQueue = CallbackQueue.getPooled();\n\t queue.notifyAll();\n\t CallbackQueue.release(queue);\n\t }\n\t }\n\t};\n\t\n\t/**\n\t * Mark a component as needing a rerender, adding an optional callback to a\n\t * list of functions which will be executed once the rerender occurs.\n\t */\n\tfunction enqueueUpdate(component) {\n\t ensureInjected();\n\t\n\t // Various parts of our code (such as ReactCompositeComponent's\n\t // _renderValidatedComponent) assume that calls to render aren't nested;\n\t // verify that that's the case. (This is called by each top-level update\n\t // function, like setState, forceUpdate, etc.; creation and\n\t // destruction of top-level components is guarded in ReactMount.)\n\t\n\t if (!batchingStrategy.isBatchingUpdates) {\n\t batchingStrategy.batchedUpdates(enqueueUpdate, component);\n\t return;\n\t }\n\t\n\t dirtyComponents.push(component);\n\t if (component._updateBatchNumber == null) {\n\t component._updateBatchNumber = updateBatchNumber + 1;\n\t }\n\t}\n\t\n\t/**\n\t * Enqueue a callback to be run at the end of the current batching cycle. Throws\n\t * if no updates are currently being performed.\n\t */\n\tfunction asap(callback, context) {\n\t invariant(batchingStrategy.isBatchingUpdates, \"ReactUpdates.asap: Can't enqueue an asap callback in a context where\" + 'updates are not being batched.');\n\t asapCallbackQueue.enqueue(callback, context);\n\t asapEnqueued = true;\n\t}\n\t\n\tvar ReactUpdatesInjection = {\n\t injectReconcileTransaction: function (ReconcileTransaction) {\n\t !ReconcileTransaction ? false ? invariant(false, 'ReactUpdates: must provide a reconcile transaction class') : _prodInvariant('126') : void 0;\n\t ReactUpdates.ReactReconcileTransaction = ReconcileTransaction;\n\t },\n\t\n\t injectBatchingStrategy: function (_batchingStrategy) {\n\t !_batchingStrategy ? false ? invariant(false, 'ReactUpdates: must provide a batching strategy') : _prodInvariant('127') : void 0;\n\t !(typeof _batchingStrategy.batchedUpdates === 'function') ? false ? invariant(false, 'ReactUpdates: must provide a batchedUpdates() function') : _prodInvariant('128') : void 0;\n\t !(typeof _batchingStrategy.isBatchingUpdates === 'boolean') ? false ? invariant(false, 'ReactUpdates: must provide an isBatchingUpdates boolean attribute') : _prodInvariant('129') : void 0;\n\t batchingStrategy = _batchingStrategy;\n\t }\n\t};\n\t\n\tvar ReactUpdates = {\n\t /**\n\t * React references `ReactReconcileTransaction` using this property in order\n\t * to allow dependency injection.\n\t *\n\t * @internal\n\t */\n\t ReactReconcileTransaction: null,\n\t\n\t batchedUpdates: batchedUpdates,\n\t enqueueUpdate: enqueueUpdate,\n\t flushBatchedUpdates: flushBatchedUpdates,\n\t injection: ReactUpdatesInjection,\n\t asap: asap\n\t};\n\t\n\tmodule.exports = ReactUpdates;\n\n/***/ },\n/* 12 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t'use strict';\n\t\n\texports.__esModule = true;\n\texports.connect = exports.Provider = undefined;\n\t\n\tvar _Provider = __webpack_require__(263);\n\t\n\tvar _Provider2 = _interopRequireDefault(_Provider);\n\t\n\tvar _connect = __webpack_require__(264);\n\t\n\tvar _connect2 = _interopRequireDefault(_connect);\n\t\n\tfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { \"default\": obj }; }\n\t\n\texports.Provider = _Provider2[\"default\"];\n\texports.connect = _connect2[\"default\"];\n\n/***/ },\n/* 13 */\n/***/ function(module, exports, __webpack_require__) {\n\n\t/* @preserve\n\t * Leaflet 1.3.1, a JS library for interactive maps. http://leafletjs.com\n\t * (c) 2010-2017 Vladimir Agafonkin, (c) 2010-2011 CloudMade\n\t */\n\t\n\t(function (global, factory) {\n\t\t true ? factory(exports) :\n\t\ttypeof define === 'function' && define.amd ? define(['exports'], factory) :\n\t\t(factory((global.L = {})));\n\t}(this, (function (exports) { 'use strict';\n\t\n\tvar version = \"1.3.1\";\n\t\n\t/*\r\n\t * @namespace Util\r\n\t *\r\n\t * Various utility functions, used by Leaflet internally.\r\n\t */\r\n\t\r\n\tvar freeze = Object.freeze;\r\n\tObject.freeze = function (obj) { return obj; };\r\n\t\r\n\t// @function extend(dest: Object, src?: Object): Object\r\n\t// Merges the properties of the `src` object (or multiple objects) into `dest` object and returns the latter. Has an `L.extend` shortcut.\r\n\tfunction extend(dest) {\r\n\t\tvar i, j, len, src;\r\n\t\r\n\t\tfor (j = 1, len = arguments.length; j < len; j++) {\r\n\t\t\tsrc = arguments[j];\r\n\t\t\tfor (i in src) {\r\n\t\t\t\tdest[i] = src[i];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn dest;\r\n\t}\r\n\t\r\n\t// @function create(proto: Object, properties?: Object): Object\r\n\t// Compatibility polyfill for [Object.create](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/create)\r\n\tvar create = Object.create || (function () {\r\n\t\tfunction F() {}\r\n\t\treturn function (proto) {\r\n\t\t\tF.prototype = proto;\r\n\t\t\treturn new F();\r\n\t\t};\r\n\t})();\r\n\t\r\n\t// @function bind(fn: Function, …): Function\r\n\t// Returns a new function bound to the arguments passed, like [Function.prototype.bind](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Function/bind).\r\n\t// Has a `L.bind()` shortcut.\r\n\tfunction bind(fn, obj) {\r\n\t\tvar slice = Array.prototype.slice;\r\n\t\r\n\t\tif (fn.bind) {\r\n\t\t\treturn fn.bind.apply(fn, slice.call(arguments, 1));\r\n\t\t}\r\n\t\r\n\t\tvar args = slice.call(arguments, 2);\r\n\t\r\n\t\treturn function () {\r\n\t\t\treturn fn.apply(obj, args.length ? args.concat(slice.call(arguments)) : arguments);\r\n\t\t};\r\n\t}\r\n\t\r\n\t// @property lastId: Number\r\n\t// Last unique ID used by [`stamp()`](#util-stamp)\r\n\tvar lastId = 0;\r\n\t\r\n\t// @function stamp(obj: Object): Number\r\n\t// Returns the unique ID of an object, assigning it one if it doesn't have it.\r\n\tfunction stamp(obj) {\r\n\t\t/*eslint-disable */\r\n\t\tobj._leaflet_id = obj._leaflet_id || ++lastId;\r\n\t\treturn obj._leaflet_id;\r\n\t\t/* eslint-enable */\r\n\t}\r\n\t\r\n\t// @function throttle(fn: Function, time: Number, context: Object): Function\r\n\t// Returns a function which executes function `fn` with the given scope `context`\r\n\t// (so that the `this` keyword refers to `context` inside `fn`'s code). The function\r\n\t// `fn` will be called no more than one time per given amount of `time`. The arguments\r\n\t// received by the bound function will be any arguments passed when binding the\r\n\t// function, followed by any arguments passed when invoking the bound function.\r\n\t// Has an `L.throttle` shortcut.\r\n\tfunction throttle(fn, time, context) {\r\n\t\tvar lock, args, wrapperFn, later;\r\n\t\r\n\t\tlater = function () {\r\n\t\t\t// reset lock and call if queued\r\n\t\t\tlock = false;\r\n\t\t\tif (args) {\r\n\t\t\t\twrapperFn.apply(context, args);\r\n\t\t\t\targs = false;\r\n\t\t\t}\r\n\t\t};\r\n\t\r\n\t\twrapperFn = function () {\r\n\t\t\tif (lock) {\r\n\t\t\t\t// called too soon, queue to call later\r\n\t\t\t\targs = arguments;\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\t// call and lock until later\r\n\t\t\t\tfn.apply(context, arguments);\r\n\t\t\t\tsetTimeout(later, time);\r\n\t\t\t\tlock = true;\r\n\t\t\t}\r\n\t\t};\r\n\t\r\n\t\treturn wrapperFn;\r\n\t}\r\n\t\r\n\t// @function wrapNum(num: Number, range: Number[], includeMax?: Boolean): Number\r\n\t// Returns the number `num` modulo `range` in such a way so it lies within\r\n\t// `range[0]` and `range[1]`. The returned value will be always smaller than\r\n\t// `range[1]` unless `includeMax` is set to `true`.\r\n\tfunction wrapNum(x, range, includeMax) {\r\n\t\tvar max = range[1],\r\n\t\t min = range[0],\r\n\t\t d = max - min;\r\n\t\treturn x === max && includeMax ? x : ((x - min) % d + d) % d + min;\r\n\t}\r\n\t\r\n\t// @function falseFn(): Function\r\n\t// Returns a function which always returns `false`.\r\n\tfunction falseFn() { return false; }\r\n\t\r\n\t// @function formatNum(num: Number, digits?: Number): Number\r\n\t// Returns the number `num` rounded to `digits` decimals, or to 6 decimals by default.\r\n\tfunction formatNum(num, digits) {\r\n\t\tvar pow = Math.pow(10, (digits === undefined ? 6 : digits));\r\n\t\treturn Math.round(num * pow) / pow;\r\n\t}\r\n\t\r\n\t// @function trim(str: String): String\r\n\t// Compatibility polyfill for [String.prototype.trim](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String/Trim)\r\n\tfunction trim(str) {\r\n\t\treturn str.trim ? str.trim() : str.replace(/^\\s+|\\s+$/g, '');\r\n\t}\r\n\t\r\n\t// @function splitWords(str: String): String[]\r\n\t// Trims and splits the string on whitespace and returns the array of parts.\r\n\tfunction splitWords(str) {\r\n\t\treturn trim(str).split(/\\s+/);\r\n\t}\r\n\t\r\n\t// @function setOptions(obj: Object, options: Object): Object\r\n\t// Merges the given properties to the `options` of the `obj` object, returning the resulting options. See `Class options`. Has an `L.setOptions` shortcut.\r\n\tfunction setOptions(obj, options) {\r\n\t\tif (!obj.hasOwnProperty('options')) {\r\n\t\t\tobj.options = obj.options ? create(obj.options) : {};\r\n\t\t}\r\n\t\tfor (var i in options) {\r\n\t\t\tobj.options[i] = options[i];\r\n\t\t}\r\n\t\treturn obj.options;\r\n\t}\r\n\t\r\n\t// @function getParamString(obj: Object, existingUrl?: String, uppercase?: Boolean): String\r\n\t// Converts an object into a parameter URL string, e.g. `{a: \"foo\", b: \"bar\"}`\r\n\t// translates to `'?a=foo&b=bar'`. If `existingUrl` is set, the parameters will\r\n\t// be appended at the end. If `uppercase` is `true`, the parameter names will\r\n\t// be uppercased (e.g. `'?A=foo&B=bar'`)\r\n\tfunction getParamString(obj, existingUrl, uppercase) {\r\n\t\tvar params = [];\r\n\t\tfor (var i in obj) {\r\n\t\t\tparams.push(encodeURIComponent(uppercase ? i.toUpperCase() : i) + '=' + encodeURIComponent(obj[i]));\r\n\t\t}\r\n\t\treturn ((!existingUrl || existingUrl.indexOf('?') === -1) ? '?' : '&') + params.join('&');\r\n\t}\r\n\t\r\n\tvar templateRe = /\\{ *([\\w_-]+) *\\}/g;\r\n\t\r\n\t// @function template(str: String, data: Object): String\r\n\t// Simple templating facility, accepts a template string of the form `'Hello {a}, {b}'`\r\n\t// and a data object like `{a: 'foo', b: 'bar'}`, returns evaluated string\r\n\t// `('Hello foo, bar')`. You can also specify functions instead of strings for\r\n\t// data values — they will be evaluated passing `data` as an argument.\r\n\tfunction template(str, data) {\r\n\t\treturn str.replace(templateRe, function (str, key) {\r\n\t\t\tvar value = data[key];\r\n\t\r\n\t\t\tif (value === undefined) {\r\n\t\t\t\tthrow new Error('No value provided for variable ' + str);\r\n\t\r\n\t\t\t} else if (typeof value === 'function') {\r\n\t\t\t\tvalue = value(data);\r\n\t\t\t}\r\n\t\t\treturn value;\r\n\t\t});\r\n\t}\r\n\t\r\n\t// @function isArray(obj): Boolean\r\n\t// Compatibility polyfill for [Array.isArray](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray)\r\n\tvar isArray = Array.isArray || function (obj) {\r\n\t\treturn (Object.prototype.toString.call(obj) === '[object Array]');\r\n\t};\r\n\t\r\n\t// @function indexOf(array: Array, el: Object): Number\r\n\t// Compatibility polyfill for [Array.prototype.indexOf](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array/indexOf)\r\n\tfunction indexOf(array, el) {\r\n\t\tfor (var i = 0; i < array.length; i++) {\r\n\t\t\tif (array[i] === el) { return i; }\r\n\t\t}\r\n\t\treturn -1;\r\n\t}\r\n\t\r\n\t// @property emptyImageUrl: String\r\n\t// Data URI string containing a base64-encoded empty GIF image.\r\n\t// Used as a hack to free memory from unused images on WebKit-powered\r\n\t// mobile devices (by setting image `src` to this string).\r\n\tvar emptyImageUrl = 'data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=';\r\n\t\r\n\t// inspired by http://paulirish.com/2011/requestanimationframe-for-smart-animating/\r\n\t\r\n\tfunction getPrefixed(name) {\r\n\t\treturn window['webkit' + name] || window['moz' + name] || window['ms' + name];\r\n\t}\r\n\t\r\n\tvar lastTime = 0;\r\n\t\r\n\t// fallback for IE 7-8\r\n\tfunction timeoutDefer(fn) {\r\n\t\tvar time = +new Date(),\r\n\t\t timeToCall = Math.max(0, 16 - (time - lastTime));\r\n\t\r\n\t\tlastTime = time + timeToCall;\r\n\t\treturn window.setTimeout(fn, timeToCall);\r\n\t}\r\n\t\r\n\tvar requestFn = window.requestAnimationFrame || getPrefixed('RequestAnimationFrame') || timeoutDefer;\r\n\tvar cancelFn = window.cancelAnimationFrame || getPrefixed('CancelAnimationFrame') ||\r\n\t\t\tgetPrefixed('CancelRequestAnimationFrame') || function (id) { window.clearTimeout(id); };\r\n\t\r\n\t// @function requestAnimFrame(fn: Function, context?: Object, immediate?: Boolean): Number\r\n\t// Schedules `fn` to be executed when the browser repaints. `fn` is bound to\r\n\t// `context` if given. When `immediate` is set, `fn` is called immediately if\r\n\t// the browser doesn't have native support for\r\n\t// [`window.requestAnimationFrame`](https://developer.mozilla.org/docs/Web/API/window/requestAnimationFrame),\r\n\t// otherwise it's delayed. Returns a request ID that can be used to cancel the request.\r\n\tfunction requestAnimFrame(fn, context, immediate) {\r\n\t\tif (immediate && requestFn === timeoutDefer) {\r\n\t\t\tfn.call(context);\r\n\t\t} else {\r\n\t\t\treturn requestFn.call(window, bind(fn, context));\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function cancelAnimFrame(id: Number): undefined\r\n\t// Cancels a previous `requestAnimFrame`. See also [window.cancelAnimationFrame](https://developer.mozilla.org/docs/Web/API/window/cancelAnimationFrame).\r\n\tfunction cancelAnimFrame(id) {\r\n\t\tif (id) {\r\n\t\t\tcancelFn.call(window, id);\r\n\t\t}\r\n\t}\r\n\t\n\t\n\tvar Util = (Object.freeze || Object)({\n\t\tfreeze: freeze,\n\t\textend: extend,\n\t\tcreate: create,\n\t\tbind: bind,\n\t\tlastId: lastId,\n\t\tstamp: stamp,\n\t\tthrottle: throttle,\n\t\twrapNum: wrapNum,\n\t\tfalseFn: falseFn,\n\t\tformatNum: formatNum,\n\t\ttrim: trim,\n\t\tsplitWords: splitWords,\n\t\tsetOptions: setOptions,\n\t\tgetParamString: getParamString,\n\t\ttemplate: template,\n\t\tisArray: isArray,\n\t\tindexOf: indexOf,\n\t\temptyImageUrl: emptyImageUrl,\n\t\trequestFn: requestFn,\n\t\tcancelFn: cancelFn,\n\t\trequestAnimFrame: requestAnimFrame,\n\t\tcancelAnimFrame: cancelAnimFrame\n\t});\n\t\n\t// @class Class\r\n\t// @aka L.Class\r\n\t\r\n\t// @section\r\n\t// @uninheritable\r\n\t\r\n\t// Thanks to John Resig and Dean Edwards for inspiration!\r\n\t\r\n\tfunction Class() {}\r\n\t\r\n\tClass.extend = function (props) {\r\n\t\r\n\t\t// @function extend(props: Object): Function\r\n\t\t// [Extends the current class](#class-inheritance) given the properties to be included.\r\n\t\t// Returns a Javascript function that is a class constructor (to be called with `new`).\r\n\t\tvar NewClass = function () {\r\n\t\r\n\t\t\t// call the constructor\r\n\t\t\tif (this.initialize) {\r\n\t\t\t\tthis.initialize.apply(this, arguments);\r\n\t\t\t}\r\n\t\r\n\t\t\t// call all constructor hooks\r\n\t\t\tthis.callInitHooks();\r\n\t\t};\r\n\t\r\n\t\tvar parentProto = NewClass.__super__ = this.prototype;\r\n\t\r\n\t\tvar proto = create(parentProto);\r\n\t\tproto.constructor = NewClass;\r\n\t\r\n\t\tNewClass.prototype = proto;\r\n\t\r\n\t\t// inherit parent's statics\r\n\t\tfor (var i in this) {\r\n\t\t\tif (this.hasOwnProperty(i) && i !== 'prototype' && i !== '__super__') {\r\n\t\t\t\tNewClass[i] = this[i];\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\t// mix static properties into the class\r\n\t\tif (props.statics) {\r\n\t\t\textend(NewClass, props.statics);\r\n\t\t\tdelete props.statics;\r\n\t\t}\r\n\t\r\n\t\t// mix includes into the prototype\r\n\t\tif (props.includes) {\r\n\t\t\tcheckDeprecatedMixinEvents(props.includes);\r\n\t\t\textend.apply(null, [proto].concat(props.includes));\r\n\t\t\tdelete props.includes;\r\n\t\t}\r\n\t\r\n\t\t// merge options\r\n\t\tif (proto.options) {\r\n\t\t\tprops.options = extend(create(proto.options), props.options);\r\n\t\t}\r\n\t\r\n\t\t// mix given properties into the prototype\r\n\t\textend(proto, props);\r\n\t\r\n\t\tproto._initHooks = [];\r\n\t\r\n\t\t// add method for calling all hooks\r\n\t\tproto.callInitHooks = function () {\r\n\t\r\n\t\t\tif (this._initHooksCalled) { return; }\r\n\t\r\n\t\t\tif (parentProto.callInitHooks) {\r\n\t\t\t\tparentProto.callInitHooks.call(this);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._initHooksCalled = true;\r\n\t\r\n\t\t\tfor (var i = 0, len = proto._initHooks.length; i < len; i++) {\r\n\t\t\t\tproto._initHooks[i].call(this);\r\n\t\t\t}\r\n\t\t};\r\n\t\r\n\t\treturn NewClass;\r\n\t};\r\n\t\r\n\t\r\n\t// @function include(properties: Object): this\r\n\t// [Includes a mixin](#class-includes) into the current class.\r\n\tClass.include = function (props) {\r\n\t\textend(this.prototype, props);\r\n\t\treturn this;\r\n\t};\r\n\t\r\n\t// @function mergeOptions(options: Object): this\r\n\t// [Merges `options`](#class-options) into the defaults of the class.\r\n\tClass.mergeOptions = function (options) {\r\n\t\textend(this.prototype.options, options);\r\n\t\treturn this;\r\n\t};\r\n\t\r\n\t// @function addInitHook(fn: Function): this\r\n\t// Adds a [constructor hook](#class-constructor-hooks) to the class.\r\n\tClass.addInitHook = function (fn) { // (Function) || (String, args...)\r\n\t\tvar args = Array.prototype.slice.call(arguments, 1);\r\n\t\r\n\t\tvar init = typeof fn === 'function' ? fn : function () {\r\n\t\t\tthis[fn].apply(this, args);\r\n\t\t};\r\n\t\r\n\t\tthis.prototype._initHooks = this.prototype._initHooks || [];\r\n\t\tthis.prototype._initHooks.push(init);\r\n\t\treturn this;\r\n\t};\r\n\t\r\n\tfunction checkDeprecatedMixinEvents(includes) {\r\n\t\tif (typeof L === 'undefined' || !L || !L.Mixin) { return; }\r\n\t\r\n\t\tincludes = isArray(includes) ? includes : [includes];\r\n\t\r\n\t\tfor (var i = 0; i < includes.length; i++) {\r\n\t\t\tif (includes[i] === L.Mixin.Events) {\r\n\t\t\t\tconsole.warn('Deprecated include of L.Mixin.Events: ' +\r\n\t\t\t\t\t'this property will be removed in future releases, ' +\r\n\t\t\t\t\t'please inherit from L.Evented instead.', new Error().stack);\r\n\t\t\t}\r\n\t\t}\r\n\t}\n\t\n\t/*\r\n\t * @class Evented\r\n\t * @aka L.Evented\r\n\t * @inherits Class\r\n\t *\r\n\t * A set of methods shared between event-powered classes (like `Map` and `Marker`). Generally, events allow you to execute some function when something happens with an object (e.g. the user clicks on the map, causing the map to fire `'click'` event).\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * map.on('click', function(e) {\r\n\t * \talert(e.latlng);\r\n\t * } );\r\n\t * ```\r\n\t *\r\n\t * Leaflet deals with event listeners by reference, so if you want to add a listener and then remove it, define it as a function:\r\n\t *\r\n\t * ```js\r\n\t * function onClick(e) { ... }\r\n\t *\r\n\t * map.on('click', onClick);\r\n\t * map.off('click', onClick);\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar Events = {\r\n\t\t/* @method on(type: String, fn: Function, context?: Object): this\r\n\t\t * Adds a listener function (`fn`) to a particular event type of the object. You can optionally specify the context of the listener (object the this keyword will point to). You can also pass several space-separated types (e.g. `'click dblclick'`).\r\n\t\t *\r\n\t\t * @alternative\r\n\t\t * @method on(eventMap: Object): this\r\n\t\t * Adds a set of type/listener pairs, e.g. `{click: onClick, mousemove: onMouseMove}`\r\n\t\t */\r\n\t\ton: function (types, fn, context) {\r\n\t\r\n\t\t\t// types can be a map of types/handlers\r\n\t\t\tif (typeof types === 'object') {\r\n\t\t\t\tfor (var type in types) {\r\n\t\t\t\t\t// we don't process space-separated events here for performance;\r\n\t\t\t\t\t// it's a hot path since Layer uses the on(obj) syntax\r\n\t\t\t\t\tthis._on(type, types[type], fn);\r\n\t\t\t\t}\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\t// types can be a string of space-separated words\r\n\t\t\t\ttypes = splitWords(types);\r\n\t\r\n\t\t\t\tfor (var i = 0, len = types.length; i < len; i++) {\r\n\t\t\t\t\tthis._on(types[i], fn, context);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t/* @method off(type: String, fn?: Function, context?: Object): this\r\n\t\t * Removes a previously added listener function. If no function is specified, it will remove all the listeners of that particular event from the object. Note that if you passed a custom context to `on`, you must pass the same context to `off` in order to remove the listener.\r\n\t\t *\r\n\t\t * @alternative\r\n\t\t * @method off(eventMap: Object): this\r\n\t\t * Removes a set of type/listener pairs.\r\n\t\t *\r\n\t\t * @alternative\r\n\t\t * @method off: this\r\n\t\t * Removes all listeners to all events on the object.\r\n\t\t */\r\n\t\toff: function (types, fn, context) {\r\n\t\r\n\t\t\tif (!types) {\r\n\t\t\t\t// clear all listeners if called without arguments\r\n\t\t\t\tdelete this._events;\r\n\t\r\n\t\t\t} else if (typeof types === 'object') {\r\n\t\t\t\tfor (var type in types) {\r\n\t\t\t\t\tthis._off(type, types[type], fn);\r\n\t\t\t\t}\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\ttypes = splitWords(types);\r\n\t\r\n\t\t\t\tfor (var i = 0, len = types.length; i < len; i++) {\r\n\t\t\t\t\tthis._off(types[i], fn, context);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// attach listener (without syntactic sugar now)\r\n\t\t_on: function (type, fn, context) {\r\n\t\t\tthis._events = this._events || {};\r\n\t\r\n\t\t\t/* get/init listeners for type */\r\n\t\t\tvar typeListeners = this._events[type];\r\n\t\t\tif (!typeListeners) {\r\n\t\t\t\ttypeListeners = [];\r\n\t\t\t\tthis._events[type] = typeListeners;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (context === this) {\r\n\t\t\t\t// Less memory footprint.\r\n\t\t\t\tcontext = undefined;\r\n\t\t\t}\r\n\t\t\tvar newListener = {fn: fn, ctx: context},\r\n\t\t\t listeners = typeListeners;\r\n\t\r\n\t\t\t// check if fn already there\r\n\t\t\tfor (var i = 0, len = listeners.length; i < len; i++) {\r\n\t\t\t\tif (listeners[i].fn === fn && listeners[i].ctx === context) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tlisteners.push(newListener);\r\n\t\t},\r\n\t\r\n\t\t_off: function (type, fn, context) {\r\n\t\t\tvar listeners,\r\n\t\t\t i,\r\n\t\t\t len;\r\n\t\r\n\t\t\tif (!this._events) { return; }\r\n\t\r\n\t\t\tlisteners = this._events[type];\r\n\t\r\n\t\t\tif (!listeners) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (!fn) {\r\n\t\t\t\t// Set all removed listeners to noop so they are not called if remove happens in fire\r\n\t\t\t\tfor (i = 0, len = listeners.length; i < len; i++) {\r\n\t\t\t\t\tlisteners[i].fn = falseFn;\r\n\t\t\t\t}\r\n\t\t\t\t// clear all listeners for a type if function isn't specified\r\n\t\t\t\tdelete this._events[type];\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (context === this) {\r\n\t\t\t\tcontext = undefined;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (listeners) {\r\n\t\r\n\t\t\t\t// find fn and remove it\r\n\t\t\t\tfor (i = 0, len = listeners.length; i < len; i++) {\r\n\t\t\t\t\tvar l = listeners[i];\r\n\t\t\t\t\tif (l.ctx !== context) { continue; }\r\n\t\t\t\t\tif (l.fn === fn) {\r\n\t\r\n\t\t\t\t\t\t// set the removed listener to noop so that's not called if remove happens in fire\r\n\t\t\t\t\t\tl.fn = falseFn;\r\n\t\r\n\t\t\t\t\t\tif (this._firingCount) {\r\n\t\t\t\t\t\t\t/* copy array in case events are being fired */\r\n\t\t\t\t\t\t\tthis._events[type] = listeners = listeners.slice();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tlisteners.splice(i, 1);\r\n\t\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @method fire(type: String, data?: Object, propagate?: Boolean): this\r\n\t\t// Fires an event of the specified type. You can optionally provide an data\r\n\t\t// object — the first argument of the listener function will contain its\r\n\t\t// properties. The event can optionally be propagated to event parents.\r\n\t\tfire: function (type, data, propagate) {\r\n\t\t\tif (!this.listens(type, propagate)) { return this; }\r\n\t\r\n\t\t\tvar event = extend({}, data, {\r\n\t\t\t\ttype: type,\r\n\t\t\t\ttarget: this,\r\n\t\t\t\tsourceTarget: data && data.sourceTarget || this\r\n\t\t\t});\r\n\t\r\n\t\t\tif (this._events) {\r\n\t\t\t\tvar listeners = this._events[type];\r\n\t\r\n\t\t\t\tif (listeners) {\r\n\t\t\t\t\tthis._firingCount = (this._firingCount + 1) || 1;\r\n\t\t\t\t\tfor (var i = 0, len = listeners.length; i < len; i++) {\r\n\t\t\t\t\t\tvar l = listeners[i];\r\n\t\t\t\t\t\tl.fn.call(l.ctx || this, event);\r\n\t\t\t\t\t}\r\n\t\r\n\t\t\t\t\tthis._firingCount--;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tif (propagate) {\r\n\t\t\t\t// propagate the event to parents (set with addEventParent)\r\n\t\t\t\tthis._propagateEvent(event);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method listens(type: String): Boolean\r\n\t\t// Returns `true` if a particular event type has any listeners attached to it.\r\n\t\tlistens: function (type, propagate) {\r\n\t\t\tvar listeners = this._events && this._events[type];\r\n\t\t\tif (listeners && listeners.length) { return true; }\r\n\t\r\n\t\t\tif (propagate) {\r\n\t\t\t\t// also check parents for listeners if event propagates\r\n\t\t\t\tfor (var id in this._eventParents) {\r\n\t\t\t\t\tif (this._eventParents[id].listens(type, propagate)) { return true; }\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn false;\r\n\t\t},\r\n\t\r\n\t\t// @method once(…): this\r\n\t\t// Behaves as [`on(…)`](#evented-on), except the listener will only get fired once and then removed.\r\n\t\tonce: function (types, fn, context) {\r\n\t\r\n\t\t\tif (typeof types === 'object') {\r\n\t\t\t\tfor (var type in types) {\r\n\t\t\t\t\tthis.once(type, types[type], fn);\r\n\t\t\t\t}\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\r\n\t\t\tvar handler = bind(function () {\r\n\t\t\t\tthis\r\n\t\t\t\t .off(types, fn, context)\r\n\t\t\t\t .off(types, handler, context);\r\n\t\t\t}, this);\r\n\t\r\n\t\t\t// add a listener that's executed once and removed after that\r\n\t\t\treturn this\r\n\t\t\t .on(types, fn, context)\r\n\t\t\t .on(types, handler, context);\r\n\t\t},\r\n\t\r\n\t\t// @method addEventParent(obj: Evented): this\r\n\t\t// Adds an event parent - an `Evented` that will receive propagated events\r\n\t\taddEventParent: function (obj) {\r\n\t\t\tthis._eventParents = this._eventParents || {};\r\n\t\t\tthis._eventParents[stamp(obj)] = obj;\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method removeEventParent(obj: Evented): this\r\n\t\t// Removes an event parent, so it will stop receiving propagated events\r\n\t\tremoveEventParent: function (obj) {\r\n\t\t\tif (this._eventParents) {\r\n\t\t\t\tdelete this._eventParents[stamp(obj)];\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_propagateEvent: function (e) {\r\n\t\t\tfor (var id in this._eventParents) {\r\n\t\t\t\tthis._eventParents[id].fire(e.type, extend({\r\n\t\t\t\t\tlayer: e.target,\r\n\t\t\t\t\tpropagatedFrom: e.target\r\n\t\t\t\t}, e), true);\r\n\t\t\t}\r\n\t\t}\r\n\t};\r\n\t\r\n\t// aliases; we should ditch those eventually\r\n\t\r\n\t// @method addEventListener(…): this\r\n\t// Alias to [`on(…)`](#evented-on)\r\n\tEvents.addEventListener = Events.on;\r\n\t\r\n\t// @method removeEventListener(…): this\r\n\t// Alias to [`off(…)`](#evented-off)\r\n\t\r\n\t// @method clearAllEventListeners(…): this\r\n\t// Alias to [`off()`](#evented-off)\r\n\tEvents.removeEventListener = Events.clearAllEventListeners = Events.off;\r\n\t\r\n\t// @method addOneTimeEventListener(…): this\r\n\t// Alias to [`once(…)`](#evented-once)\r\n\tEvents.addOneTimeEventListener = Events.once;\r\n\t\r\n\t// @method fireEvent(…): this\r\n\t// Alias to [`fire(…)`](#evented-fire)\r\n\tEvents.fireEvent = Events.fire;\r\n\t\r\n\t// @method hasEventListeners(…): Boolean\r\n\t// Alias to [`listens(…)`](#evented-listens)\r\n\tEvents.hasEventListeners = Events.listens;\r\n\t\r\n\tvar Evented = Class.extend(Events);\n\t\n\t/*\r\n\t * @class Point\r\n\t * @aka L.Point\r\n\t *\r\n\t * Represents a point with `x` and `y` coordinates in pixels.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var point = L.point(200, 300);\r\n\t * ```\r\n\t *\r\n\t * All Leaflet methods and options that accept `Point` objects also accept them in a simple Array form (unless noted otherwise), so these lines are equivalent:\r\n\t *\r\n\t * ```js\r\n\t * map.panBy([200, 300]);\r\n\t * map.panBy(L.point(200, 300));\r\n\t * ```\r\n\t *\r\n\t * Note that `Point` does not inherit from Leafet's `Class` object,\r\n\t * which means new classes can't inherit from it, and new methods\r\n\t * can't be added to it with the `include` function.\r\n\t */\r\n\t\r\n\tfunction Point(x, y, round) {\r\n\t\t// @property x: Number; The `x` coordinate of the point\r\n\t\tthis.x = (round ? Math.round(x) : x);\r\n\t\t// @property y: Number; The `y` coordinate of the point\r\n\t\tthis.y = (round ? Math.round(y) : y);\r\n\t}\r\n\t\r\n\tvar trunc = Math.trunc || function (v) {\r\n\t\treturn v > 0 ? Math.floor(v) : Math.ceil(v);\r\n\t};\r\n\t\r\n\tPoint.prototype = {\r\n\t\r\n\t\t// @method clone(): Point\r\n\t\t// Returns a copy of the current point.\r\n\t\tclone: function () {\r\n\t\t\treturn new Point(this.x, this.y);\r\n\t\t},\r\n\t\r\n\t\t// @method add(otherPoint: Point): Point\r\n\t\t// Returns the result of addition of the current and the given points.\r\n\t\tadd: function (point) {\r\n\t\t\t// non-destructive, returns a new point\r\n\t\t\treturn this.clone()._add(toPoint(point));\r\n\t\t},\r\n\t\r\n\t\t_add: function (point) {\r\n\t\t\t// destructive, used directly for performance in situations where it's safe to modify existing point\r\n\t\t\tthis.x += point.x;\r\n\t\t\tthis.y += point.y;\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method subtract(otherPoint: Point): Point\r\n\t\t// Returns the result of subtraction of the given point from the current.\r\n\t\tsubtract: function (point) {\r\n\t\t\treturn this.clone()._subtract(toPoint(point));\r\n\t\t},\r\n\t\r\n\t\t_subtract: function (point) {\r\n\t\t\tthis.x -= point.x;\r\n\t\t\tthis.y -= point.y;\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method divideBy(num: Number): Point\r\n\t\t// Returns the result of division of the current point by the given number.\r\n\t\tdivideBy: function (num) {\r\n\t\t\treturn this.clone()._divideBy(num);\r\n\t\t},\r\n\t\r\n\t\t_divideBy: function (num) {\r\n\t\t\tthis.x /= num;\r\n\t\t\tthis.y /= num;\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method multiplyBy(num: Number): Point\r\n\t\t// Returns the result of multiplication of the current point by the given number.\r\n\t\tmultiplyBy: function (num) {\r\n\t\t\treturn this.clone()._multiplyBy(num);\r\n\t\t},\r\n\t\r\n\t\t_multiplyBy: function (num) {\r\n\t\t\tthis.x *= num;\r\n\t\t\tthis.y *= num;\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method scaleBy(scale: Point): Point\r\n\t\t// Multiply each coordinate of the current point by each coordinate of\r\n\t\t// `scale`. In linear algebra terms, multiply the point by the\r\n\t\t// [scaling matrix](https://en.wikipedia.org/wiki/Scaling_%28geometry%29#Matrix_representation)\r\n\t\t// defined by `scale`.\r\n\t\tscaleBy: function (point) {\r\n\t\t\treturn new Point(this.x * point.x, this.y * point.y);\r\n\t\t},\r\n\t\r\n\t\t// @method unscaleBy(scale: Point): Point\r\n\t\t// Inverse of `scaleBy`. Divide each coordinate of the current point by\r\n\t\t// each coordinate of `scale`.\r\n\t\tunscaleBy: function (point) {\r\n\t\t\treturn new Point(this.x / point.x, this.y / point.y);\r\n\t\t},\r\n\t\r\n\t\t// @method round(): Point\r\n\t\t// Returns a copy of the current point with rounded coordinates.\r\n\t\tround: function () {\r\n\t\t\treturn this.clone()._round();\r\n\t\t},\r\n\t\r\n\t\t_round: function () {\r\n\t\t\tthis.x = Math.round(this.x);\r\n\t\t\tthis.y = Math.round(this.y);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method floor(): Point\r\n\t\t// Returns a copy of the current point with floored coordinates (rounded down).\r\n\t\tfloor: function () {\r\n\t\t\treturn this.clone()._floor();\r\n\t\t},\r\n\t\r\n\t\t_floor: function () {\r\n\t\t\tthis.x = Math.floor(this.x);\r\n\t\t\tthis.y = Math.floor(this.y);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method ceil(): Point\r\n\t\t// Returns a copy of the current point with ceiled coordinates (rounded up).\r\n\t\tceil: function () {\r\n\t\t\treturn this.clone()._ceil();\r\n\t\t},\r\n\t\r\n\t\t_ceil: function () {\r\n\t\t\tthis.x = Math.ceil(this.x);\r\n\t\t\tthis.y = Math.ceil(this.y);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method trunc(): Point\r\n\t\t// Returns a copy of the current point with truncated coordinates (rounded towards zero).\r\n\t\ttrunc: function () {\r\n\t\t\treturn this.clone()._trunc();\r\n\t\t},\r\n\t\r\n\t\t_trunc: function () {\r\n\t\t\tthis.x = trunc(this.x);\r\n\t\t\tthis.y = trunc(this.y);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method distanceTo(otherPoint: Point): Number\r\n\t\t// Returns the cartesian distance between the current and the given points.\r\n\t\tdistanceTo: function (point) {\r\n\t\t\tpoint = toPoint(point);\r\n\t\r\n\t\t\tvar x = point.x - this.x,\r\n\t\t\t y = point.y - this.y;\r\n\t\r\n\t\t\treturn Math.sqrt(x * x + y * y);\r\n\t\t},\r\n\t\r\n\t\t// @method equals(otherPoint: Point): Boolean\r\n\t\t// Returns `true` if the given point has the same coordinates.\r\n\t\tequals: function (point) {\r\n\t\t\tpoint = toPoint(point);\r\n\t\r\n\t\t\treturn point.x === this.x &&\r\n\t\t\t point.y === this.y;\r\n\t\t},\r\n\t\r\n\t\t// @method contains(otherPoint: Point): Boolean\r\n\t\t// Returns `true` if both coordinates of the given point are less than the corresponding current point coordinates (in absolute values).\r\n\t\tcontains: function (point) {\r\n\t\t\tpoint = toPoint(point);\r\n\t\r\n\t\t\treturn Math.abs(point.x) <= Math.abs(this.x) &&\r\n\t\t\t Math.abs(point.y) <= Math.abs(this.y);\r\n\t\t},\r\n\t\r\n\t\t// @method toString(): String\r\n\t\t// Returns a string representation of the point for debugging purposes.\r\n\t\ttoString: function () {\r\n\t\t\treturn 'Point(' +\r\n\t\t\t formatNum(this.x) + ', ' +\r\n\t\t\t formatNum(this.y) + ')';\r\n\t\t}\r\n\t};\r\n\t\r\n\t// @factory L.point(x: Number, y: Number, round?: Boolean)\r\n\t// Creates a Point object with the given `x` and `y` coordinates. If optional `round` is set to true, rounds the `x` and `y` values.\r\n\t\r\n\t// @alternative\r\n\t// @factory L.point(coords: Number[])\r\n\t// Expects an array of the form `[x, y]` instead.\r\n\t\r\n\t// @alternative\r\n\t// @factory L.point(coords: Object)\r\n\t// Expects a plain object of the form `{x: Number, y: Number}` instead.\r\n\tfunction toPoint(x, y, round) {\r\n\t\tif (x instanceof Point) {\r\n\t\t\treturn x;\r\n\t\t}\r\n\t\tif (isArray(x)) {\r\n\t\t\treturn new Point(x[0], x[1]);\r\n\t\t}\r\n\t\tif (x === undefined || x === null) {\r\n\t\t\treturn x;\r\n\t\t}\r\n\t\tif (typeof x === 'object' && 'x' in x && 'y' in x) {\r\n\t\t\treturn new Point(x.x, x.y);\r\n\t\t}\r\n\t\treturn new Point(x, y, round);\r\n\t}\n\t\n\t/*\r\n\t * @class Bounds\r\n\t * @aka L.Bounds\r\n\t *\r\n\t * Represents a rectangular area in pixel coordinates.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var p1 = L.point(10, 10),\r\n\t * p2 = L.point(40, 60),\r\n\t * bounds = L.bounds(p1, p2);\r\n\t * ```\r\n\t *\r\n\t * All Leaflet methods that accept `Bounds` objects also accept them in a simple Array form (unless noted otherwise), so the bounds example above can be passed like this:\r\n\t *\r\n\t * ```js\r\n\t * otherBounds.intersects([[10, 10], [40, 60]]);\r\n\t * ```\r\n\t *\r\n\t * Note that `Bounds` does not inherit from Leafet's `Class` object,\r\n\t * which means new classes can't inherit from it, and new methods\r\n\t * can't be added to it with the `include` function.\r\n\t */\r\n\t\r\n\tfunction Bounds(a, b) {\r\n\t\tif (!a) { return; }\r\n\t\r\n\t\tvar points = b ? [a, b] : a;\r\n\t\r\n\t\tfor (var i = 0, len = points.length; i < len; i++) {\r\n\t\t\tthis.extend(points[i]);\r\n\t\t}\r\n\t}\r\n\t\r\n\tBounds.prototype = {\r\n\t\t// @method extend(point: Point): this\r\n\t\t// Extends the bounds to contain the given point.\r\n\t\textend: function (point) { // (Point)\r\n\t\t\tpoint = toPoint(point);\r\n\t\r\n\t\t\t// @property min: Point\r\n\t\t\t// The top left corner of the rectangle.\r\n\t\t\t// @property max: Point\r\n\t\t\t// The bottom right corner of the rectangle.\r\n\t\t\tif (!this.min && !this.max) {\r\n\t\t\t\tthis.min = point.clone();\r\n\t\t\t\tthis.max = point.clone();\r\n\t\t\t} else {\r\n\t\t\t\tthis.min.x = Math.min(point.x, this.min.x);\r\n\t\t\t\tthis.max.x = Math.max(point.x, this.max.x);\r\n\t\t\t\tthis.min.y = Math.min(point.y, this.min.y);\r\n\t\t\t\tthis.max.y = Math.max(point.y, this.max.y);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method getCenter(round?: Boolean): Point\r\n\t\t// Returns the center point of the bounds.\r\n\t\tgetCenter: function (round) {\r\n\t\t\treturn new Point(\r\n\t\t\t (this.min.x + this.max.x) / 2,\r\n\t\t\t (this.min.y + this.max.y) / 2, round);\r\n\t\t},\r\n\t\r\n\t\t// @method getBottomLeft(): Point\r\n\t\t// Returns the bottom-left point of the bounds.\r\n\t\tgetBottomLeft: function () {\r\n\t\t\treturn new Point(this.min.x, this.max.y);\r\n\t\t},\r\n\t\r\n\t\t// @method getTopRight(): Point\r\n\t\t// Returns the top-right point of the bounds.\r\n\t\tgetTopRight: function () { // -> Point\r\n\t\t\treturn new Point(this.max.x, this.min.y);\r\n\t\t},\r\n\t\r\n\t\t// @method getTopLeft(): Point\r\n\t\t// Returns the top-left point of the bounds (i.e. [`this.min`](#bounds-min)).\r\n\t\tgetTopLeft: function () {\r\n\t\t\treturn this.min; // left, top\r\n\t\t},\r\n\t\r\n\t\t// @method getBottomRight(): Point\r\n\t\t// Returns the bottom-right point of the bounds (i.e. [`this.max`](#bounds-max)).\r\n\t\tgetBottomRight: function () {\r\n\t\t\treturn this.max; // right, bottom\r\n\t\t},\r\n\t\r\n\t\t// @method getSize(): Point\r\n\t\t// Returns the size of the given bounds\r\n\t\tgetSize: function () {\r\n\t\t\treturn this.max.subtract(this.min);\r\n\t\t},\r\n\t\r\n\t\t// @method contains(otherBounds: Bounds): Boolean\r\n\t\t// Returns `true` if the rectangle contains the given one.\r\n\t\t// @alternative\r\n\t\t// @method contains(point: Point): Boolean\r\n\t\t// Returns `true` if the rectangle contains the given point.\r\n\t\tcontains: function (obj) {\r\n\t\t\tvar min, max;\r\n\t\r\n\t\t\tif (typeof obj[0] === 'number' || obj instanceof Point) {\r\n\t\t\t\tobj = toPoint(obj);\r\n\t\t\t} else {\r\n\t\t\t\tobj = toBounds(obj);\r\n\t\t\t}\r\n\t\r\n\t\t\tif (obj instanceof Bounds) {\r\n\t\t\t\tmin = obj.min;\r\n\t\t\t\tmax = obj.max;\r\n\t\t\t} else {\r\n\t\t\t\tmin = max = obj;\r\n\t\t\t}\r\n\t\r\n\t\t\treturn (min.x >= this.min.x) &&\r\n\t\t\t (max.x <= this.max.x) &&\r\n\t\t\t (min.y >= this.min.y) &&\r\n\t\t\t (max.y <= this.max.y);\r\n\t\t},\r\n\t\r\n\t\t// @method intersects(otherBounds: Bounds): Boolean\r\n\t\t// Returns `true` if the rectangle intersects the given bounds. Two bounds\r\n\t\t// intersect if they have at least one point in common.\r\n\t\tintersects: function (bounds) { // (Bounds) -> Boolean\r\n\t\t\tbounds = toBounds(bounds);\r\n\t\r\n\t\t\tvar min = this.min,\r\n\t\t\t max = this.max,\r\n\t\t\t min2 = bounds.min,\r\n\t\t\t max2 = bounds.max,\r\n\t\t\t xIntersects = (max2.x >= min.x) && (min2.x <= max.x),\r\n\t\t\t yIntersects = (max2.y >= min.y) && (min2.y <= max.y);\r\n\t\r\n\t\t\treturn xIntersects && yIntersects;\r\n\t\t},\r\n\t\r\n\t\t// @method overlaps(otherBounds: Bounds): Boolean\r\n\t\t// Returns `true` if the rectangle overlaps the given bounds. Two bounds\r\n\t\t// overlap if their intersection is an area.\r\n\t\toverlaps: function (bounds) { // (Bounds) -> Boolean\r\n\t\t\tbounds = toBounds(bounds);\r\n\t\r\n\t\t\tvar min = this.min,\r\n\t\t\t max = this.max,\r\n\t\t\t min2 = bounds.min,\r\n\t\t\t max2 = bounds.max,\r\n\t\t\t xOverlaps = (max2.x > min.x) && (min2.x < max.x),\r\n\t\t\t yOverlaps = (max2.y > min.y) && (min2.y < max.y);\r\n\t\r\n\t\t\treturn xOverlaps && yOverlaps;\r\n\t\t},\r\n\t\r\n\t\tisValid: function () {\r\n\t\t\treturn !!(this.min && this.max);\r\n\t\t}\r\n\t};\r\n\t\r\n\t\r\n\t// @factory L.bounds(corner1: Point, corner2: Point)\r\n\t// Creates a Bounds object from two corners coordinate pairs.\r\n\t// @alternative\r\n\t// @factory L.bounds(points: Point[])\r\n\t// Creates a Bounds object from the given array of points.\r\n\tfunction toBounds(a, b) {\r\n\t\tif (!a || a instanceof Bounds) {\r\n\t\t\treturn a;\r\n\t\t}\r\n\t\treturn new Bounds(a, b);\r\n\t}\n\t\n\t/*\r\n\t * @class LatLngBounds\r\n\t * @aka L.LatLngBounds\r\n\t *\r\n\t * Represents a rectangular geographical area on a map.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var corner1 = L.latLng(40.712, -74.227),\r\n\t * corner2 = L.latLng(40.774, -74.125),\r\n\t * bounds = L.latLngBounds(corner1, corner2);\r\n\t * ```\r\n\t *\r\n\t * All Leaflet methods that accept LatLngBounds objects also accept them in a simple Array form (unless noted otherwise), so the bounds example above can be passed like this:\r\n\t *\r\n\t * ```js\r\n\t * map.fitBounds([\r\n\t * \t[40.712, -74.227],\r\n\t * \t[40.774, -74.125]\r\n\t * ]);\r\n\t * ```\r\n\t *\r\n\t * Caution: if the area crosses the antimeridian (often confused with the International Date Line), you must specify corners _outside_ the [-180, 180] degrees longitude range.\r\n\t *\r\n\t * Note that `LatLngBounds` does not inherit from Leafet's `Class` object,\r\n\t * which means new classes can't inherit from it, and new methods\r\n\t * can't be added to it with the `include` function.\r\n\t */\r\n\t\r\n\tfunction LatLngBounds(corner1, corner2) { // (LatLng, LatLng) or (LatLng[])\r\n\t\tif (!corner1) { return; }\r\n\t\r\n\t\tvar latlngs = corner2 ? [corner1, corner2] : corner1;\r\n\t\r\n\t\tfor (var i = 0, len = latlngs.length; i < len; i++) {\r\n\t\t\tthis.extend(latlngs[i]);\r\n\t\t}\r\n\t}\r\n\t\r\n\tLatLngBounds.prototype = {\r\n\t\r\n\t\t// @method extend(latlng: LatLng): this\r\n\t\t// Extend the bounds to contain the given point\r\n\t\r\n\t\t// @alternative\r\n\t\t// @method extend(otherBounds: LatLngBounds): this\r\n\t\t// Extend the bounds to contain the given bounds\r\n\t\textend: function (obj) {\r\n\t\t\tvar sw = this._southWest,\r\n\t\t\t ne = this._northEast,\r\n\t\t\t sw2, ne2;\r\n\t\r\n\t\t\tif (obj instanceof LatLng) {\r\n\t\t\t\tsw2 = obj;\r\n\t\t\t\tne2 = obj;\r\n\t\r\n\t\t\t} else if (obj instanceof LatLngBounds) {\r\n\t\t\t\tsw2 = obj._southWest;\r\n\t\t\t\tne2 = obj._northEast;\r\n\t\r\n\t\t\t\tif (!sw2 || !ne2) { return this; }\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\treturn obj ? this.extend(toLatLng(obj) || toLatLngBounds(obj)) : this;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (!sw && !ne) {\r\n\t\t\t\tthis._southWest = new LatLng(sw2.lat, sw2.lng);\r\n\t\t\t\tthis._northEast = new LatLng(ne2.lat, ne2.lng);\r\n\t\t\t} else {\r\n\t\t\t\tsw.lat = Math.min(sw2.lat, sw.lat);\r\n\t\t\t\tsw.lng = Math.min(sw2.lng, sw.lng);\r\n\t\t\t\tne.lat = Math.max(ne2.lat, ne.lat);\r\n\t\t\t\tne.lng = Math.max(ne2.lng, ne.lng);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method pad(bufferRatio: Number): LatLngBounds\r\n\t\t// Returns bounds created by extending or retracting the current bounds by a given ratio in each direction.\r\n\t\t// For example, a ratio of 0.5 extends the bounds by 50% in each direction.\r\n\t\t// Negative values will retract the bounds.\r\n\t\tpad: function (bufferRatio) {\r\n\t\t\tvar sw = this._southWest,\r\n\t\t\t ne = this._northEast,\r\n\t\t\t heightBuffer = Math.abs(sw.lat - ne.lat) * bufferRatio,\r\n\t\t\t widthBuffer = Math.abs(sw.lng - ne.lng) * bufferRatio;\r\n\t\r\n\t\t\treturn new LatLngBounds(\r\n\t\t\t new LatLng(sw.lat - heightBuffer, sw.lng - widthBuffer),\r\n\t\t\t new LatLng(ne.lat + heightBuffer, ne.lng + widthBuffer));\r\n\t\t},\r\n\t\r\n\t\t// @method getCenter(): LatLng\r\n\t\t// Returns the center point of the bounds.\r\n\t\tgetCenter: function () {\r\n\t\t\treturn new LatLng(\r\n\t\t\t (this._southWest.lat + this._northEast.lat) / 2,\r\n\t\t\t (this._southWest.lng + this._northEast.lng) / 2);\r\n\t\t},\r\n\t\r\n\t\t// @method getSouthWest(): LatLng\r\n\t\t// Returns the south-west point of the bounds.\r\n\t\tgetSouthWest: function () {\r\n\t\t\treturn this._southWest;\r\n\t\t},\r\n\t\r\n\t\t// @method getNorthEast(): LatLng\r\n\t\t// Returns the north-east point of the bounds.\r\n\t\tgetNorthEast: function () {\r\n\t\t\treturn this._northEast;\r\n\t\t},\r\n\t\r\n\t\t// @method getNorthWest(): LatLng\r\n\t\t// Returns the north-west point of the bounds.\r\n\t\tgetNorthWest: function () {\r\n\t\t\treturn new LatLng(this.getNorth(), this.getWest());\r\n\t\t},\r\n\t\r\n\t\t// @method getSouthEast(): LatLng\r\n\t\t// Returns the south-east point of the bounds.\r\n\t\tgetSouthEast: function () {\r\n\t\t\treturn new LatLng(this.getSouth(), this.getEast());\r\n\t\t},\r\n\t\r\n\t\t// @method getWest(): Number\r\n\t\t// Returns the west longitude of the bounds\r\n\t\tgetWest: function () {\r\n\t\t\treturn this._southWest.lng;\r\n\t\t},\r\n\t\r\n\t\t// @method getSouth(): Number\r\n\t\t// Returns the south latitude of the bounds\r\n\t\tgetSouth: function () {\r\n\t\t\treturn this._southWest.lat;\r\n\t\t},\r\n\t\r\n\t\t// @method getEast(): Number\r\n\t\t// Returns the east longitude of the bounds\r\n\t\tgetEast: function () {\r\n\t\t\treturn this._northEast.lng;\r\n\t\t},\r\n\t\r\n\t\t// @method getNorth(): Number\r\n\t\t// Returns the north latitude of the bounds\r\n\t\tgetNorth: function () {\r\n\t\t\treturn this._northEast.lat;\r\n\t\t},\r\n\t\r\n\t\t// @method contains(otherBounds: LatLngBounds): Boolean\r\n\t\t// Returns `true` if the rectangle contains the given one.\r\n\t\r\n\t\t// @alternative\r\n\t\t// @method contains (latlng: LatLng): Boolean\r\n\t\t// Returns `true` if the rectangle contains the given point.\r\n\t\tcontains: function (obj) { // (LatLngBounds) or (LatLng) -> Boolean\r\n\t\t\tif (typeof obj[0] === 'number' || obj instanceof LatLng || 'lat' in obj) {\r\n\t\t\t\tobj = toLatLng(obj);\r\n\t\t\t} else {\r\n\t\t\t\tobj = toLatLngBounds(obj);\r\n\t\t\t}\r\n\t\r\n\t\t\tvar sw = this._southWest,\r\n\t\t\t ne = this._northEast,\r\n\t\t\t sw2, ne2;\r\n\t\r\n\t\t\tif (obj instanceof LatLngBounds) {\r\n\t\t\t\tsw2 = obj.getSouthWest();\r\n\t\t\t\tne2 = obj.getNorthEast();\r\n\t\t\t} else {\r\n\t\t\t\tsw2 = ne2 = obj;\r\n\t\t\t}\r\n\t\r\n\t\t\treturn (sw2.lat >= sw.lat) && (ne2.lat <= ne.lat) &&\r\n\t\t\t (sw2.lng >= sw.lng) && (ne2.lng <= ne.lng);\r\n\t\t},\r\n\t\r\n\t\t// @method intersects(otherBounds: LatLngBounds): Boolean\r\n\t\t// Returns `true` if the rectangle intersects the given bounds. Two bounds intersect if they have at least one point in common.\r\n\t\tintersects: function (bounds) {\r\n\t\t\tbounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\tvar sw = this._southWest,\r\n\t\t\t ne = this._northEast,\r\n\t\t\t sw2 = bounds.getSouthWest(),\r\n\t\t\t ne2 = bounds.getNorthEast(),\r\n\t\r\n\t\t\t latIntersects = (ne2.lat >= sw.lat) && (sw2.lat <= ne.lat),\r\n\t\t\t lngIntersects = (ne2.lng >= sw.lng) && (sw2.lng <= ne.lng);\r\n\t\r\n\t\t\treturn latIntersects && lngIntersects;\r\n\t\t},\r\n\t\r\n\t\t// @method overlaps(otherBounds: Bounds): Boolean\r\n\t\t// Returns `true` if the rectangle overlaps the given bounds. Two bounds overlap if their intersection is an area.\r\n\t\toverlaps: function (bounds) {\r\n\t\t\tbounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\tvar sw = this._southWest,\r\n\t\t\t ne = this._northEast,\r\n\t\t\t sw2 = bounds.getSouthWest(),\r\n\t\t\t ne2 = bounds.getNorthEast(),\r\n\t\r\n\t\t\t latOverlaps = (ne2.lat > sw.lat) && (sw2.lat < ne.lat),\r\n\t\t\t lngOverlaps = (ne2.lng > sw.lng) && (sw2.lng < ne.lng);\r\n\t\r\n\t\t\treturn latOverlaps && lngOverlaps;\r\n\t\t},\r\n\t\r\n\t\t// @method toBBoxString(): String\r\n\t\t// Returns a string with bounding box coordinates in a 'southwest_lng,southwest_lat,northeast_lng,northeast_lat' format. Useful for sending requests to web services that return geo data.\r\n\t\ttoBBoxString: function () {\r\n\t\t\treturn [this.getWest(), this.getSouth(), this.getEast(), this.getNorth()].join(',');\r\n\t\t},\r\n\t\r\n\t\t// @method equals(otherBounds: LatLngBounds, maxMargin?: Number): Boolean\r\n\t\t// Returns `true` if the rectangle is equivalent (within a small margin of error) to the given bounds. The margin of error can be overridden by setting `maxMargin` to a small number.\r\n\t\tequals: function (bounds, maxMargin) {\r\n\t\t\tif (!bounds) { return false; }\r\n\t\r\n\t\t\tbounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\treturn this._southWest.equals(bounds.getSouthWest(), maxMargin) &&\r\n\t\t\t this._northEast.equals(bounds.getNorthEast(), maxMargin);\r\n\t\t},\r\n\t\r\n\t\t// @method isValid(): Boolean\r\n\t\t// Returns `true` if the bounds are properly initialized.\r\n\t\tisValid: function () {\r\n\t\t\treturn !!(this._southWest && this._northEast);\r\n\t\t}\r\n\t};\r\n\t\r\n\t// TODO International date line?\r\n\t\r\n\t// @factory L.latLngBounds(corner1: LatLng, corner2: LatLng)\r\n\t// Creates a `LatLngBounds` object by defining two diagonally opposite corners of the rectangle.\r\n\t\r\n\t// @alternative\r\n\t// @factory L.latLngBounds(latlngs: LatLng[])\r\n\t// Creates a `LatLngBounds` object defined by the geographical points it contains. Very useful for zooming the map to fit a particular set of locations with [`fitBounds`](#map-fitbounds).\r\n\tfunction toLatLngBounds(a, b) {\r\n\t\tif (a instanceof LatLngBounds) {\r\n\t\t\treturn a;\r\n\t\t}\r\n\t\treturn new LatLngBounds(a, b);\r\n\t}\n\t\n\t/* @class LatLng\r\n\t * @aka L.LatLng\r\n\t *\r\n\t * Represents a geographical point with a certain latitude and longitude.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```\r\n\t * var latlng = L.latLng(50.5, 30.5);\r\n\t * ```\r\n\t *\r\n\t * All Leaflet methods that accept LatLng objects also accept them in a simple Array form and simple object form (unless noted otherwise), so these lines are equivalent:\r\n\t *\r\n\t * ```\r\n\t * map.panTo([50, 30]);\r\n\t * map.panTo({lon: 30, lat: 50});\r\n\t * map.panTo({lat: 50, lng: 30});\r\n\t * map.panTo(L.latLng(50, 30));\r\n\t * ```\r\n\t *\r\n\t * Note that `LatLng` does not inherit from Leafet's `Class` object,\r\n\t * which means new classes can't inherit from it, and new methods\r\n\t * can't be added to it with the `include` function.\r\n\t */\r\n\t\r\n\tfunction LatLng(lat, lng, alt) {\r\n\t\tif (isNaN(lat) || isNaN(lng)) {\r\n\t\t\tthrow new Error('Invalid LatLng object: (' + lat + ', ' + lng + ')');\r\n\t\t}\r\n\t\r\n\t\t// @property lat: Number\r\n\t\t// Latitude in degrees\r\n\t\tthis.lat = +lat;\r\n\t\r\n\t\t// @property lng: Number\r\n\t\t// Longitude in degrees\r\n\t\tthis.lng = +lng;\r\n\t\r\n\t\t// @property alt: Number\r\n\t\t// Altitude in meters (optional)\r\n\t\tif (alt !== undefined) {\r\n\t\t\tthis.alt = +alt;\r\n\t\t}\r\n\t}\r\n\t\r\n\tLatLng.prototype = {\r\n\t\t// @method equals(otherLatLng: LatLng, maxMargin?: Number): Boolean\r\n\t\t// Returns `true` if the given `LatLng` point is at the same position (within a small margin of error). The margin of error can be overridden by setting `maxMargin` to a small number.\r\n\t\tequals: function (obj, maxMargin) {\r\n\t\t\tif (!obj) { return false; }\r\n\t\r\n\t\t\tobj = toLatLng(obj);\r\n\t\r\n\t\t\tvar margin = Math.max(\r\n\t\t\t Math.abs(this.lat - obj.lat),\r\n\t\t\t Math.abs(this.lng - obj.lng));\r\n\t\r\n\t\t\treturn margin <= (maxMargin === undefined ? 1.0E-9 : maxMargin);\r\n\t\t},\r\n\t\r\n\t\t// @method toString(): String\r\n\t\t// Returns a string representation of the point (for debugging purposes).\r\n\t\ttoString: function (precision) {\r\n\t\t\treturn 'LatLng(' +\r\n\t\t\t formatNum(this.lat, precision) + ', ' +\r\n\t\t\t formatNum(this.lng, precision) + ')';\r\n\t\t},\r\n\t\r\n\t\t// @method distanceTo(otherLatLng: LatLng): Number\r\n\t\t// Returns the distance (in meters) to the given `LatLng` calculated using the [Spherical Law of Cosines](https://en.wikipedia.org/wiki/Spherical_law_of_cosines).\r\n\t\tdistanceTo: function (other) {\r\n\t\t\treturn Earth.distance(this, toLatLng(other));\r\n\t\t},\r\n\t\r\n\t\t// @method wrap(): LatLng\r\n\t\t// Returns a new `LatLng` object with the longitude wrapped so it's always between -180 and +180 degrees.\r\n\t\twrap: function () {\r\n\t\t\treturn Earth.wrapLatLng(this);\r\n\t\t},\r\n\t\r\n\t\t// @method toBounds(sizeInMeters: Number): LatLngBounds\r\n\t\t// Returns a new `LatLngBounds` object in which each boundary is `sizeInMeters/2` meters apart from the `LatLng`.\r\n\t\ttoBounds: function (sizeInMeters) {\r\n\t\t\tvar latAccuracy = 180 * sizeInMeters / 40075017,\r\n\t\t\t lngAccuracy = latAccuracy / Math.cos((Math.PI / 180) * this.lat);\r\n\t\r\n\t\t\treturn toLatLngBounds(\r\n\t\t\t [this.lat - latAccuracy, this.lng - lngAccuracy],\r\n\t\t\t [this.lat + latAccuracy, this.lng + lngAccuracy]);\r\n\t\t},\r\n\t\r\n\t\tclone: function () {\r\n\t\t\treturn new LatLng(this.lat, this.lng, this.alt);\r\n\t\t}\r\n\t};\r\n\t\r\n\t\r\n\t\r\n\t// @factory L.latLng(latitude: Number, longitude: Number, altitude?: Number): LatLng\r\n\t// Creates an object representing a geographical point with the given latitude and longitude (and optionally altitude).\r\n\t\r\n\t// @alternative\r\n\t// @factory L.latLng(coords: Array): LatLng\r\n\t// Expects an array of the form `[Number, Number]` or `[Number, Number, Number]` instead.\r\n\t\r\n\t// @alternative\r\n\t// @factory L.latLng(coords: Object): LatLng\r\n\t// Expects an plain object of the form `{lat: Number, lng: Number}` or `{lat: Number, lng: Number, alt: Number}` instead.\r\n\t\r\n\tfunction toLatLng(a, b, c) {\r\n\t\tif (a instanceof LatLng) {\r\n\t\t\treturn a;\r\n\t\t}\r\n\t\tif (isArray(a) && typeof a[0] !== 'object') {\r\n\t\t\tif (a.length === 3) {\r\n\t\t\t\treturn new LatLng(a[0], a[1], a[2]);\r\n\t\t\t}\r\n\t\t\tif (a.length === 2) {\r\n\t\t\t\treturn new LatLng(a[0], a[1]);\r\n\t\t\t}\r\n\t\t\treturn null;\r\n\t\t}\r\n\t\tif (a === undefined || a === null) {\r\n\t\t\treturn a;\r\n\t\t}\r\n\t\tif (typeof a === 'object' && 'lat' in a) {\r\n\t\t\treturn new LatLng(a.lat, 'lng' in a ? a.lng : a.lon, a.alt);\r\n\t\t}\r\n\t\tif (b === undefined) {\r\n\t\t\treturn null;\r\n\t\t}\r\n\t\treturn new LatLng(a, b, c);\r\n\t}\n\t\n\t/*\r\n\t * @namespace CRS\r\n\t * @crs L.CRS.Base\r\n\t * Object that defines coordinate reference systems for projecting\r\n\t * geographical points into pixel (screen) coordinates and back (and to\r\n\t * coordinates in other units for [WMS](https://en.wikipedia.org/wiki/Web_Map_Service) services). See\r\n\t * [spatial reference system](http://en.wikipedia.org/wiki/Coordinate_reference_system).\r\n\t *\r\n\t * Leaflet defines the most usual CRSs by default. If you want to use a\r\n\t * CRS not defined by default, take a look at the\r\n\t * [Proj4Leaflet](https://github.com/kartena/Proj4Leaflet) plugin.\r\n\t *\r\n\t * Note that the CRS instances do not inherit from Leafet's `Class` object,\r\n\t * and can't be instantiated. Also, new classes can't inherit from them,\r\n\t * and methods can't be added to them with the `include` function.\r\n\t */\r\n\t\r\n\tvar CRS = {\r\n\t\t// @method latLngToPoint(latlng: LatLng, zoom: Number): Point\r\n\t\t// Projects geographical coordinates into pixel coordinates for a given zoom.\r\n\t\tlatLngToPoint: function (latlng, zoom) {\r\n\t\t\tvar projectedPoint = this.projection.project(latlng),\r\n\t\t\t scale = this.scale(zoom);\r\n\t\r\n\t\t\treturn this.transformation._transform(projectedPoint, scale);\r\n\t\t},\r\n\t\r\n\t\t// @method pointToLatLng(point: Point, zoom: Number): LatLng\r\n\t\t// The inverse of `latLngToPoint`. Projects pixel coordinates on a given\r\n\t\t// zoom into geographical coordinates.\r\n\t\tpointToLatLng: function (point, zoom) {\r\n\t\t\tvar scale = this.scale(zoom),\r\n\t\t\t untransformedPoint = this.transformation.untransform(point, scale);\r\n\t\r\n\t\t\treturn this.projection.unproject(untransformedPoint);\r\n\t\t},\r\n\t\r\n\t\t// @method project(latlng: LatLng): Point\r\n\t\t// Projects geographical coordinates into coordinates in units accepted for\r\n\t\t// this CRS (e.g. meters for EPSG:3857, for passing it to WMS services).\r\n\t\tproject: function (latlng) {\r\n\t\t\treturn this.projection.project(latlng);\r\n\t\t},\r\n\t\r\n\t\t// @method unproject(point: Point): LatLng\r\n\t\t// Given a projected coordinate returns the corresponding LatLng.\r\n\t\t// The inverse of `project`.\r\n\t\tunproject: function (point) {\r\n\t\t\treturn this.projection.unproject(point);\r\n\t\t},\r\n\t\r\n\t\t// @method scale(zoom: Number): Number\r\n\t\t// Returns the scale used when transforming projected coordinates into\r\n\t\t// pixel coordinates for a particular zoom. For example, it returns\r\n\t\t// `256 * 2^zoom` for Mercator-based CRS.\r\n\t\tscale: function (zoom) {\r\n\t\t\treturn 256 * Math.pow(2, zoom);\r\n\t\t},\r\n\t\r\n\t\t// @method zoom(scale: Number): Number\r\n\t\t// Inverse of `scale()`, returns the zoom level corresponding to a scale\r\n\t\t// factor of `scale`.\r\n\t\tzoom: function (scale) {\r\n\t\t\treturn Math.log(scale / 256) / Math.LN2;\r\n\t\t},\r\n\t\r\n\t\t// @method getProjectedBounds(zoom: Number): Bounds\r\n\t\t// Returns the projection's bounds scaled and transformed for the provided `zoom`.\r\n\t\tgetProjectedBounds: function (zoom) {\r\n\t\t\tif (this.infinite) { return null; }\r\n\t\r\n\t\t\tvar b = this.projection.bounds,\r\n\t\t\t s = this.scale(zoom),\r\n\t\t\t min = this.transformation.transform(b.min, s),\r\n\t\t\t max = this.transformation.transform(b.max, s);\r\n\t\r\n\t\t\treturn new Bounds(min, max);\r\n\t\t},\r\n\t\r\n\t\t// @method distance(latlng1: LatLng, latlng2: LatLng): Number\r\n\t\t// Returns the distance between two geographical coordinates.\r\n\t\r\n\t\t// @property code: String\r\n\t\t// Standard code name of the CRS passed into WMS services (e.g. `'EPSG:3857'`)\r\n\t\t//\r\n\t\t// @property wrapLng: Number[]\r\n\t\t// An array of two numbers defining whether the longitude (horizontal) coordinate\r\n\t\t// axis wraps around a given range and how. Defaults to `[-180, 180]` in most\r\n\t\t// geographical CRSs. If `undefined`, the longitude axis does not wrap around.\r\n\t\t//\r\n\t\t// @property wrapLat: Number[]\r\n\t\t// Like `wrapLng`, but for the latitude (vertical) axis.\r\n\t\r\n\t\t// wrapLng: [min, max],\r\n\t\t// wrapLat: [min, max],\r\n\t\r\n\t\t// @property infinite: Boolean\r\n\t\t// If true, the coordinate space will be unbounded (infinite in both axes)\r\n\t\tinfinite: false,\r\n\t\r\n\t\t// @method wrapLatLng(latlng: LatLng): LatLng\r\n\t\t// Returns a `LatLng` where lat and lng has been wrapped according to the\r\n\t\t// CRS's `wrapLat` and `wrapLng` properties, if they are outside the CRS's bounds.\r\n\t\twrapLatLng: function (latlng) {\r\n\t\t\tvar lng = this.wrapLng ? wrapNum(latlng.lng, this.wrapLng, true) : latlng.lng,\r\n\t\t\t lat = this.wrapLat ? wrapNum(latlng.lat, this.wrapLat, true) : latlng.lat,\r\n\t\t\t alt = latlng.alt;\r\n\t\r\n\t\t\treturn new LatLng(lat, lng, alt);\r\n\t\t},\r\n\t\r\n\t\t// @method wrapLatLngBounds(bounds: LatLngBounds): LatLngBounds\r\n\t\t// Returns a `LatLngBounds` with the same size as the given one, ensuring\r\n\t\t// that its center is within the CRS's bounds.\r\n\t\t// Only accepts actual `L.LatLngBounds` instances, not arrays.\r\n\t\twrapLatLngBounds: function (bounds) {\r\n\t\t\tvar center = bounds.getCenter(),\r\n\t\t\t newCenter = this.wrapLatLng(center),\r\n\t\t\t latShift = center.lat - newCenter.lat,\r\n\t\t\t lngShift = center.lng - newCenter.lng;\r\n\t\r\n\t\t\tif (latShift === 0 && lngShift === 0) {\r\n\t\t\t\treturn bounds;\r\n\t\t\t}\r\n\t\r\n\t\t\tvar sw = bounds.getSouthWest(),\r\n\t\t\t ne = bounds.getNorthEast(),\r\n\t\t\t newSw = new LatLng(sw.lat - latShift, sw.lng - lngShift),\r\n\t\t\t newNe = new LatLng(ne.lat - latShift, ne.lng - lngShift);\r\n\t\r\n\t\t\treturn new LatLngBounds(newSw, newNe);\r\n\t\t}\r\n\t};\n\t\n\t/*\n\t * @namespace CRS\n\t * @crs L.CRS.Earth\n\t *\n\t * Serves as the base for CRS that are global such that they cover the earth.\n\t * Can only be used as the base for other CRS and cannot be used directly,\n\t * since it does not have a `code`, `projection` or `transformation`. `distance()` returns\n\t * meters.\n\t */\n\t\n\tvar Earth = extend({}, CRS, {\n\t\twrapLng: [-180, 180],\n\t\n\t\t// Mean Earth Radius, as recommended for use by\n\t\t// the International Union of Geodesy and Geophysics,\n\t\t// see http://rosettacode.org/wiki/Haversine_formula\n\t\tR: 6371000,\n\t\n\t\t// distance between two geographical points using spherical law of cosines approximation\n\t\tdistance: function (latlng1, latlng2) {\n\t\t\tvar rad = Math.PI / 180,\n\t\t\t lat1 = latlng1.lat * rad,\n\t\t\t lat2 = latlng2.lat * rad,\n\t\t\t sinDLat = Math.sin((latlng2.lat - latlng1.lat) * rad / 2),\n\t\t\t sinDLon = Math.sin((latlng2.lng - latlng1.lng) * rad / 2),\n\t\t\t a = sinDLat * sinDLat + Math.cos(lat1) * Math.cos(lat2) * sinDLon * sinDLon,\n\t\t\t c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n\t\t\treturn this.R * c;\n\t\t}\n\t});\n\t\n\t/*\r\n\t * @namespace Projection\r\n\t * @projection L.Projection.SphericalMercator\r\n\t *\r\n\t * Spherical Mercator projection — the most common projection for online maps,\r\n\t * used by almost all free and commercial tile providers. Assumes that Earth is\r\n\t * a sphere. Used by the `EPSG:3857` CRS.\r\n\t */\r\n\t\r\n\tvar SphericalMercator = {\r\n\t\r\n\t\tR: 6378137,\r\n\t\tMAX_LATITUDE: 85.0511287798,\r\n\t\r\n\t\tproject: function (latlng) {\r\n\t\t\tvar d = Math.PI / 180,\r\n\t\t\t max = this.MAX_LATITUDE,\r\n\t\t\t lat = Math.max(Math.min(max, latlng.lat), -max),\r\n\t\t\t sin = Math.sin(lat * d);\r\n\t\r\n\t\t\treturn new Point(\r\n\t\t\t\tthis.R * latlng.lng * d,\r\n\t\t\t\tthis.R * Math.log((1 + sin) / (1 - sin)) / 2);\r\n\t\t},\r\n\t\r\n\t\tunproject: function (point) {\r\n\t\t\tvar d = 180 / Math.PI;\r\n\t\r\n\t\t\treturn new LatLng(\r\n\t\t\t\t(2 * Math.atan(Math.exp(point.y / this.R)) - (Math.PI / 2)) * d,\r\n\t\t\t\tpoint.x * d / this.R);\r\n\t\t},\r\n\t\r\n\t\tbounds: (function () {\r\n\t\t\tvar d = 6378137 * Math.PI;\r\n\t\t\treturn new Bounds([-d, -d], [d, d]);\r\n\t\t})()\r\n\t};\n\t\n\t/*\r\n\t * @class Transformation\r\n\t * @aka L.Transformation\r\n\t *\r\n\t * Represents an affine transformation: a set of coefficients `a`, `b`, `c`, `d`\r\n\t * for transforming a point of a form `(x, y)` into `(a*x + b, c*y + d)` and doing\r\n\t * the reverse. Used by Leaflet in its projections code.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var transformation = L.transformation(2, 5, -1, 10),\r\n\t * \tp = L.point(1, 2),\r\n\t * \tp2 = transformation.transform(p), // L.point(7, 8)\r\n\t * \tp3 = transformation.untransform(p2); // L.point(1, 2)\r\n\t * ```\r\n\t */\r\n\t\r\n\t\r\n\t// factory new L.Transformation(a: Number, b: Number, c: Number, d: Number)\r\n\t// Creates a `Transformation` object with the given coefficients.\r\n\tfunction Transformation(a, b, c, d) {\r\n\t\tif (isArray(a)) {\r\n\t\t\t// use array properties\r\n\t\t\tthis._a = a[0];\r\n\t\t\tthis._b = a[1];\r\n\t\t\tthis._c = a[2];\r\n\t\t\tthis._d = a[3];\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tthis._a = a;\r\n\t\tthis._b = b;\r\n\t\tthis._c = c;\r\n\t\tthis._d = d;\r\n\t}\r\n\t\r\n\tTransformation.prototype = {\r\n\t\t// @method transform(point: Point, scale?: Number): Point\r\n\t\t// Returns a transformed point, optionally multiplied by the given scale.\r\n\t\t// Only accepts actual `L.Point` instances, not arrays.\r\n\t\ttransform: function (point, scale) { // (Point, Number) -> Point\r\n\t\t\treturn this._transform(point.clone(), scale);\r\n\t\t},\r\n\t\r\n\t\t// destructive transform (faster)\r\n\t\t_transform: function (point, scale) {\r\n\t\t\tscale = scale || 1;\r\n\t\t\tpoint.x = scale * (this._a * point.x + this._b);\r\n\t\t\tpoint.y = scale * (this._c * point.y + this._d);\r\n\t\t\treturn point;\r\n\t\t},\r\n\t\r\n\t\t// @method untransform(point: Point, scale?: Number): Point\r\n\t\t// Returns the reverse transformation of the given point, optionally divided\r\n\t\t// by the given scale. Only accepts actual `L.Point` instances, not arrays.\r\n\t\tuntransform: function (point, scale) {\r\n\t\t\tscale = scale || 1;\r\n\t\t\treturn new Point(\r\n\t\t\t (point.x / scale - this._b) / this._a,\r\n\t\t\t (point.y / scale - this._d) / this._c);\r\n\t\t}\r\n\t};\r\n\t\r\n\t// factory L.transformation(a: Number, b: Number, c: Number, d: Number)\r\n\t\r\n\t// @factory L.transformation(a: Number, b: Number, c: Number, d: Number)\r\n\t// Instantiates a Transformation object with the given coefficients.\r\n\t\r\n\t// @alternative\r\n\t// @factory L.transformation(coefficients: Array): Transformation\r\n\t// Expects an coefficients array of the form\r\n\t// `[a: Number, b: Number, c: Number, d: Number]`.\r\n\t\r\n\tfunction toTransformation(a, b, c, d) {\r\n\t\treturn new Transformation(a, b, c, d);\r\n\t}\n\t\n\t/*\r\n\t * @namespace CRS\r\n\t * @crs L.CRS.EPSG3857\r\n\t *\r\n\t * The most common CRS for online maps, used by almost all free and commercial\r\n\t * tile providers. Uses Spherical Mercator projection. Set in by default in\r\n\t * Map's `crs` option.\r\n\t */\r\n\t\r\n\tvar EPSG3857 = extend({}, Earth, {\r\n\t\tcode: 'EPSG:3857',\r\n\t\tprojection: SphericalMercator,\r\n\t\r\n\t\ttransformation: (function () {\r\n\t\t\tvar scale = 0.5 / (Math.PI * SphericalMercator.R);\r\n\t\t\treturn toTransformation(scale, 0.5, -scale, 0.5);\r\n\t\t}())\r\n\t});\r\n\t\r\n\tvar EPSG900913 = extend({}, EPSG3857, {\r\n\t\tcode: 'EPSG:900913'\r\n\t});\n\t\n\t// @namespace SVG; @section\n\t// There are several static functions which can be called without instantiating L.SVG:\n\t\n\t// @function create(name: String): SVGElement\n\t// Returns a instance of [SVGElement](https://developer.mozilla.org/docs/Web/API/SVGElement),\n\t// corresponding to the class name passed. For example, using 'line' will return\n\t// an instance of [SVGLineElement](https://developer.mozilla.org/docs/Web/API/SVGLineElement).\n\tfunction svgCreate(name) {\n\t\treturn document.createElementNS('http://www.w3.org/2000/svg', name);\n\t}\n\t\n\t// @function pointsToPath(rings: Point[], closed: Boolean): String\n\t// Generates a SVG path string for multiple rings, with each ring turning\n\t// into \"M..L..L..\" instructions\n\tfunction pointsToPath(rings, closed) {\n\t\tvar str = '',\n\t\ti, j, len, len2, points, p;\n\t\n\t\tfor (i = 0, len = rings.length; i < len; i++) {\n\t\t\tpoints = rings[i];\n\t\n\t\t\tfor (j = 0, len2 = points.length; j < len2; j++) {\n\t\t\t\tp = points[j];\n\t\t\t\tstr += (j ? 'L' : 'M') + p.x + ' ' + p.y;\n\t\t\t}\n\t\n\t\t\t// closes the ring for polygons; \"x\" is VML syntax\n\t\t\tstr += closed ? (svg ? 'z' : 'x') : '';\n\t\t}\n\t\n\t\t// SVG complains about empty path strings\n\t\treturn str || 'M0 0';\n\t}\n\t\n\t/*\r\n\t * @namespace Browser\r\n\t * @aka L.Browser\r\n\t *\r\n\t * A namespace with static properties for browser/feature detection used by Leaflet internally.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * if (L.Browser.ielt9) {\r\n\t * alert('Upgrade your browser, dude!');\r\n\t * }\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar style$1 = document.documentElement.style;\r\n\t\r\n\t// @property ie: Boolean; `true` for all Internet Explorer versions (not Edge).\r\n\tvar ie = 'ActiveXObject' in window;\r\n\t\r\n\t// @property ielt9: Boolean; `true` for Internet Explorer versions less than 9.\r\n\tvar ielt9 = ie && !document.addEventListener;\r\n\t\r\n\t// @property edge: Boolean; `true` for the Edge web browser.\r\n\tvar edge = 'msLaunchUri' in navigator && !('documentMode' in document);\r\n\t\r\n\t// @property webkit: Boolean;\r\n\t// `true` for webkit-based browsers like Chrome and Safari (including mobile versions).\r\n\tvar webkit = userAgentContains('webkit');\r\n\t\r\n\t// @property android: Boolean\r\n\t// `true` for any browser running on an Android platform.\r\n\tvar android = userAgentContains('android');\r\n\t\r\n\t// @property android23: Boolean; `true` for browsers running on Android 2 or Android 3.\r\n\tvar android23 = userAgentContains('android 2') || userAgentContains('android 3');\r\n\t\r\n\t/* See https://stackoverflow.com/a/17961266 for details on detecting stock Android */\r\n\tvar webkitVer = parseInt(/WebKit\\/([0-9]+)|$/.exec(navigator.userAgent)[1], 10); // also matches AppleWebKit\r\n\t// @property androidStock: Boolean; `true` for the Android stock browser (i.e. not Chrome)\r\n\tvar androidStock = android && userAgentContains('Google') && webkitVer < 537 && !('AudioNode' in window);\r\n\t\r\n\t// @property opera: Boolean; `true` for the Opera browser\r\n\tvar opera = !!window.opera;\r\n\t\r\n\t// @property chrome: Boolean; `true` for the Chrome browser.\r\n\tvar chrome = userAgentContains('chrome');\r\n\t\r\n\t// @property gecko: Boolean; `true` for gecko-based browsers like Firefox.\r\n\tvar gecko = userAgentContains('gecko') && !webkit && !opera && !ie;\r\n\t\r\n\t// @property safari: Boolean; `true` for the Safari browser.\r\n\tvar safari = !chrome && userAgentContains('safari');\r\n\t\r\n\tvar phantom = userAgentContains('phantom');\r\n\t\r\n\t// @property opera12: Boolean\r\n\t// `true` for the Opera browser supporting CSS transforms (version 12 or later).\r\n\tvar opera12 = 'OTransition' in style$1;\r\n\t\r\n\t// @property win: Boolean; `true` when the browser is running in a Windows platform\r\n\tvar win = navigator.platform.indexOf('Win') === 0;\r\n\t\r\n\t// @property ie3d: Boolean; `true` for all Internet Explorer versions supporting CSS transforms.\r\n\tvar ie3d = ie && ('transition' in style$1);\r\n\t\r\n\t// @property webkit3d: Boolean; `true` for webkit-based browsers supporting CSS transforms.\r\n\tvar webkit3d = ('WebKitCSSMatrix' in window) && ('m11' in new window.WebKitCSSMatrix()) && !android23;\r\n\t\r\n\t// @property gecko3d: Boolean; `true` for gecko-based browsers supporting CSS transforms.\r\n\tvar gecko3d = 'MozPerspective' in style$1;\r\n\t\r\n\t// @property any3d: Boolean\r\n\t// `true` for all browsers supporting CSS transforms.\r\n\tvar any3d = !window.L_DISABLE_3D && (ie3d || webkit3d || gecko3d) && !opera12 && !phantom;\r\n\t\r\n\t// @property mobile: Boolean; `true` for all browsers running in a mobile device.\r\n\tvar mobile = typeof orientation !== 'undefined' || userAgentContains('mobile');\r\n\t\r\n\t// @property mobileWebkit: Boolean; `true` for all webkit-based browsers in a mobile device.\r\n\tvar mobileWebkit = mobile && webkit;\r\n\t\r\n\t// @property mobileWebkit3d: Boolean\r\n\t// `true` for all webkit-based browsers in a mobile device supporting CSS transforms.\r\n\tvar mobileWebkit3d = mobile && webkit3d;\r\n\t\r\n\t// @property msPointer: Boolean\r\n\t// `true` for browsers implementing the Microsoft touch events model (notably IE10).\r\n\tvar msPointer = !window.PointerEvent && window.MSPointerEvent;\r\n\t\r\n\t// @property pointer: Boolean\r\n\t// `true` for all browsers supporting [pointer events](https://msdn.microsoft.com/en-us/library/dn433244%28v=vs.85%29.aspx).\r\n\tvar pointer = !!(window.PointerEvent || msPointer);\r\n\t\r\n\t// @property touch: Boolean\r\n\t// `true` for all browsers supporting [touch events](https://developer.mozilla.org/docs/Web/API/Touch_events).\r\n\t// This does not necessarily mean that the browser is running in a computer with\r\n\t// a touchscreen, it only means that the browser is capable of understanding\r\n\t// touch events.\r\n\tvar touch = !window.L_NO_TOUCH && (pointer || 'ontouchstart' in window ||\r\n\t\t\t(window.DocumentTouch && document instanceof window.DocumentTouch));\r\n\t\r\n\t// @property mobileOpera: Boolean; `true` for the Opera browser in a mobile device.\r\n\tvar mobileOpera = mobile && opera;\r\n\t\r\n\t// @property mobileGecko: Boolean\r\n\t// `true` for gecko-based browsers running in a mobile device.\r\n\tvar mobileGecko = mobile && gecko;\r\n\t\r\n\t// @property retina: Boolean\r\n\t// `true` for browsers on a high-resolution \"retina\" screen.\r\n\tvar retina = (window.devicePixelRatio || (window.screen.deviceXDPI / window.screen.logicalXDPI)) > 1;\r\n\t\r\n\t\r\n\t// @property canvas: Boolean\r\n\t// `true` when the browser supports [``](https://developer.mozilla.org/docs/Web/API/Canvas_API).\r\n\tvar canvas = (function () {\r\n\t\treturn !!document.createElement('canvas').getContext;\r\n\t}());\r\n\t\r\n\t// @property svg: Boolean\r\n\t// `true` when the browser supports [SVG](https://developer.mozilla.org/docs/Web/SVG).\r\n\tvar svg = !!(document.createElementNS && svgCreate('svg').createSVGRect);\r\n\t\r\n\t// @property vml: Boolean\r\n\t// `true` if the browser supports [VML](https://en.wikipedia.org/wiki/Vector_Markup_Language).\r\n\tvar vml = !svg && (function () {\r\n\t\ttry {\r\n\t\t\tvar div = document.createElement('div');\r\n\t\t\tdiv.innerHTML = '';\r\n\t\r\n\t\t\tvar shape = div.firstChild;\r\n\t\t\tshape.style.behavior = 'url(#default#VML)';\r\n\t\r\n\t\t\treturn shape && (typeof shape.adj === 'object');\r\n\t\r\n\t\t} catch (e) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}());\r\n\t\r\n\t\r\n\tfunction userAgentContains(str) {\r\n\t\treturn navigator.userAgent.toLowerCase().indexOf(str) >= 0;\r\n\t}\r\n\t\n\t\n\tvar Browser = (Object.freeze || Object)({\n\t\tie: ie,\n\t\tielt9: ielt9,\n\t\tedge: edge,\n\t\twebkit: webkit,\n\t\tandroid: android,\n\t\tandroid23: android23,\n\t\tandroidStock: androidStock,\n\t\topera: opera,\n\t\tchrome: chrome,\n\t\tgecko: gecko,\n\t\tsafari: safari,\n\t\tphantom: phantom,\n\t\topera12: opera12,\n\t\twin: win,\n\t\tie3d: ie3d,\n\t\twebkit3d: webkit3d,\n\t\tgecko3d: gecko3d,\n\t\tany3d: any3d,\n\t\tmobile: mobile,\n\t\tmobileWebkit: mobileWebkit,\n\t\tmobileWebkit3d: mobileWebkit3d,\n\t\tmsPointer: msPointer,\n\t\tpointer: pointer,\n\t\ttouch: touch,\n\t\tmobileOpera: mobileOpera,\n\t\tmobileGecko: mobileGecko,\n\t\tretina: retina,\n\t\tcanvas: canvas,\n\t\tsvg: svg,\n\t\tvml: vml\n\t});\n\t\n\t/*\n\t * Extends L.DomEvent to provide touch support for Internet Explorer and Windows-based devices.\n\t */\n\t\n\t\n\tvar POINTER_DOWN = msPointer ? 'MSPointerDown' : 'pointerdown';\n\tvar POINTER_MOVE = msPointer ? 'MSPointerMove' : 'pointermove';\n\tvar POINTER_UP = msPointer ? 'MSPointerUp' : 'pointerup';\n\tvar POINTER_CANCEL = msPointer ? 'MSPointerCancel' : 'pointercancel';\n\tvar TAG_WHITE_LIST = ['INPUT', 'SELECT', 'OPTION'];\n\t\n\tvar _pointers = {};\n\tvar _pointerDocListener = false;\n\t\n\t// DomEvent.DoubleTap needs to know about this\n\tvar _pointersCount = 0;\n\t\n\t// Provides a touch events wrapper for (ms)pointer events.\n\t// ref http://www.w3.org/TR/pointerevents/ https://www.w3.org/Bugs/Public/show_bug.cgi?id=22890\n\t\n\tfunction addPointerListener(obj, type, handler, id) {\n\t\tif (type === 'touchstart') {\n\t\t\t_addPointerStart(obj, handler, id);\n\t\n\t\t} else if (type === 'touchmove') {\n\t\t\t_addPointerMove(obj, handler, id);\n\t\n\t\t} else if (type === 'touchend') {\n\t\t\t_addPointerEnd(obj, handler, id);\n\t\t}\n\t\n\t\treturn this;\n\t}\n\t\n\tfunction removePointerListener(obj, type, id) {\n\t\tvar handler = obj['_leaflet_' + type + id];\n\t\n\t\tif (type === 'touchstart') {\n\t\t\tobj.removeEventListener(POINTER_DOWN, handler, false);\n\t\n\t\t} else if (type === 'touchmove') {\n\t\t\tobj.removeEventListener(POINTER_MOVE, handler, false);\n\t\n\t\t} else if (type === 'touchend') {\n\t\t\tobj.removeEventListener(POINTER_UP, handler, false);\n\t\t\tobj.removeEventListener(POINTER_CANCEL, handler, false);\n\t\t}\n\t\n\t\treturn this;\n\t}\n\t\n\tfunction _addPointerStart(obj, handler, id) {\n\t\tvar onDown = bind(function (e) {\n\t\t\tif (e.pointerType !== 'mouse' && e.MSPOINTER_TYPE_MOUSE && e.pointerType !== e.MSPOINTER_TYPE_MOUSE) {\n\t\t\t\t// In IE11, some touch events needs to fire for form controls, or\n\t\t\t\t// the controls will stop working. We keep a whitelist of tag names that\n\t\t\t\t// need these events. For other target tags, we prevent default on the event.\n\t\t\t\tif (TAG_WHITE_LIST.indexOf(e.target.tagName) < 0) {\n\t\t\t\t\tpreventDefault(e);\n\t\t\t\t} else {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\t_handlePointer(e, handler);\n\t\t});\n\t\n\t\tobj['_leaflet_touchstart' + id] = onDown;\n\t\tobj.addEventListener(POINTER_DOWN, onDown, false);\n\t\n\t\t// need to keep track of what pointers and how many are active to provide e.touches emulation\n\t\tif (!_pointerDocListener) {\n\t\t\t// we listen documentElement as any drags that end by moving the touch off the screen get fired there\n\t\t\tdocument.documentElement.addEventListener(POINTER_DOWN, _globalPointerDown, true);\n\t\t\tdocument.documentElement.addEventListener(POINTER_MOVE, _globalPointerMove, true);\n\t\t\tdocument.documentElement.addEventListener(POINTER_UP, _globalPointerUp, true);\n\t\t\tdocument.documentElement.addEventListener(POINTER_CANCEL, _globalPointerUp, true);\n\t\n\t\t\t_pointerDocListener = true;\n\t\t}\n\t}\n\t\n\tfunction _globalPointerDown(e) {\n\t\t_pointers[e.pointerId] = e;\n\t\t_pointersCount++;\n\t}\n\t\n\tfunction _globalPointerMove(e) {\n\t\tif (_pointers[e.pointerId]) {\n\t\t\t_pointers[e.pointerId] = e;\n\t\t}\n\t}\n\t\n\tfunction _globalPointerUp(e) {\n\t\tdelete _pointers[e.pointerId];\n\t\t_pointersCount--;\n\t}\n\t\n\tfunction _handlePointer(e, handler) {\n\t\te.touches = [];\n\t\tfor (var i in _pointers) {\n\t\t\te.touches.push(_pointers[i]);\n\t\t}\n\t\te.changedTouches = [e];\n\t\n\t\thandler(e);\n\t}\n\t\n\tfunction _addPointerMove(obj, handler, id) {\n\t\tvar onMove = function (e) {\n\t\t\t// don't fire touch moves when mouse isn't down\n\t\t\tif ((e.pointerType === e.MSPOINTER_TYPE_MOUSE || e.pointerType === 'mouse') && e.buttons === 0) { return; }\n\t\n\t\t\t_handlePointer(e, handler);\n\t\t};\n\t\n\t\tobj['_leaflet_touchmove' + id] = onMove;\n\t\tobj.addEventListener(POINTER_MOVE, onMove, false);\n\t}\n\t\n\tfunction _addPointerEnd(obj, handler, id) {\n\t\tvar onUp = function (e) {\n\t\t\t_handlePointer(e, handler);\n\t\t};\n\t\n\t\tobj['_leaflet_touchend' + id] = onUp;\n\t\tobj.addEventListener(POINTER_UP, onUp, false);\n\t\tobj.addEventListener(POINTER_CANCEL, onUp, false);\n\t}\n\t\n\t/*\r\n\t * Extends the event handling code with double tap support for mobile browsers.\r\n\t */\r\n\t\r\n\tvar _touchstart = msPointer ? 'MSPointerDown' : pointer ? 'pointerdown' : 'touchstart';\r\n\tvar _touchend = msPointer ? 'MSPointerUp' : pointer ? 'pointerup' : 'touchend';\r\n\tvar _pre = '_leaflet_';\r\n\t\r\n\t// inspired by Zepto touch code by Thomas Fuchs\r\n\tfunction addDoubleTapListener(obj, handler, id) {\r\n\t\tvar last, touch$$1,\r\n\t\t doubleTap = false,\r\n\t\t delay = 250;\r\n\t\r\n\t\tfunction onTouchStart(e) {\r\n\t\t\tvar count;\r\n\t\r\n\t\t\tif (pointer) {\r\n\t\t\t\tif ((!edge) || e.pointerType === 'mouse') { return; }\r\n\t\t\t\tcount = _pointersCount;\r\n\t\t\t} else {\r\n\t\t\t\tcount = e.touches.length;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (count > 1) { return; }\r\n\t\r\n\t\t\tvar now = Date.now(),\r\n\t\t\t delta = now - (last || now);\r\n\t\r\n\t\t\ttouch$$1 = e.touches ? e.touches[0] : e;\r\n\t\t\tdoubleTap = (delta > 0 && delta <= delay);\r\n\t\t\tlast = now;\r\n\t\t}\r\n\t\r\n\t\tfunction onTouchEnd(e) {\r\n\t\t\tif (doubleTap && !touch$$1.cancelBubble) {\r\n\t\t\t\tif (pointer) {\r\n\t\t\t\t\tif ((!edge) || e.pointerType === 'mouse') { return; }\r\n\t\t\t\t\t// work around .type being readonly with MSPointer* events\r\n\t\t\t\t\tvar newTouch = {},\r\n\t\t\t\t\t prop, i;\r\n\t\r\n\t\t\t\t\tfor (i in touch$$1) {\r\n\t\t\t\t\t\tprop = touch$$1[i];\r\n\t\t\t\t\t\tnewTouch[i] = prop && prop.bind ? prop.bind(touch$$1) : prop;\r\n\t\t\t\t\t}\r\n\t\t\t\t\ttouch$$1 = newTouch;\r\n\t\t\t\t}\r\n\t\t\t\ttouch$$1.type = 'dblclick';\r\n\t\t\t\thandler(touch$$1);\r\n\t\t\t\tlast = null;\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\tobj[_pre + _touchstart + id] = onTouchStart;\r\n\t\tobj[_pre + _touchend + id] = onTouchEnd;\r\n\t\tobj[_pre + 'dblclick' + id] = handler;\r\n\t\r\n\t\tobj.addEventListener(_touchstart, onTouchStart, false);\r\n\t\tobj.addEventListener(_touchend, onTouchEnd, false);\r\n\t\r\n\t\t// On some platforms (notably, chrome<55 on win10 + touchscreen + mouse),\r\n\t\t// the browser doesn't fire touchend/pointerup events but does fire\r\n\t\t// native dblclicks. See #4127.\r\n\t\t// Edge 14 also fires native dblclicks, but only for pointerType mouse, see #5180.\r\n\t\tobj.addEventListener('dblclick', handler, false);\r\n\t\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\tfunction removeDoubleTapListener(obj, id) {\r\n\t\tvar touchstart = obj[_pre + _touchstart + id],\r\n\t\t touchend = obj[_pre + _touchend + id],\r\n\t\t dblclick = obj[_pre + 'dblclick' + id];\r\n\t\r\n\t\tobj.removeEventListener(_touchstart, touchstart, false);\r\n\t\tobj.removeEventListener(_touchend, touchend, false);\r\n\t\tif (!edge) {\r\n\t\t\tobj.removeEventListener('dblclick', dblclick, false);\r\n\t\t}\r\n\t\r\n\t\treturn this;\r\n\t}\n\t\n\t/*\r\n\t * @namespace DomEvent\r\n\t * Utility functions to work with the [DOM events](https://developer.mozilla.org/docs/Web/API/Event), used by Leaflet internally.\r\n\t */\r\n\t\r\n\t// Inspired by John Resig, Dean Edwards and YUI addEvent implementations.\r\n\t\r\n\t// @function on(el: HTMLElement, types: String, fn: Function, context?: Object): this\r\n\t// Adds a listener function (`fn`) to a particular DOM event type of the\r\n\t// element `el`. You can optionally specify the context of the listener\r\n\t// (object the `this` keyword will point to). You can also pass several\r\n\t// space-separated types (e.g. `'click dblclick'`).\r\n\t\r\n\t// @alternative\r\n\t// @function on(el: HTMLElement, eventMap: Object, context?: Object): this\r\n\t// Adds a set of type/listener pairs, e.g. `{click: onClick, mousemove: onMouseMove}`\r\n\tfunction on(obj, types, fn, context) {\r\n\t\r\n\t\tif (typeof types === 'object') {\r\n\t\t\tfor (var type in types) {\r\n\t\t\t\taddOne(obj, type, types[type], fn);\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\ttypes = splitWords(types);\r\n\t\r\n\t\t\tfor (var i = 0, len = types.length; i < len; i++) {\r\n\t\t\t\taddOne(obj, types[i], fn, context);\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\tvar eventsKey = '_leaflet_events';\r\n\t\r\n\t// @function off(el: HTMLElement, types: String, fn: Function, context?: Object): this\r\n\t// Removes a previously added listener function.\r\n\t// Note that if you passed a custom context to on, you must pass the same\r\n\t// context to `off` in order to remove the listener.\r\n\t\r\n\t// @alternative\r\n\t// @function off(el: HTMLElement, eventMap: Object, context?: Object): this\r\n\t// Removes a set of type/listener pairs, e.g. `{click: onClick, mousemove: onMouseMove}`\r\n\tfunction off(obj, types, fn, context) {\r\n\t\r\n\t\tif (typeof types === 'object') {\r\n\t\t\tfor (var type in types) {\r\n\t\t\t\tremoveOne(obj, type, types[type], fn);\r\n\t\t\t}\r\n\t\t} else if (types) {\r\n\t\t\ttypes = splitWords(types);\r\n\t\r\n\t\t\tfor (var i = 0, len = types.length; i < len; i++) {\r\n\t\t\t\tremoveOne(obj, types[i], fn, context);\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tfor (var j in obj[eventsKey]) {\r\n\t\t\t\tremoveOne(obj, j, obj[eventsKey][j]);\r\n\t\t\t}\r\n\t\t\tdelete obj[eventsKey];\r\n\t\t}\r\n\t\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\tfunction addOne(obj, type, fn, context) {\r\n\t\tvar id = type + stamp(fn) + (context ? '_' + stamp(context) : '');\r\n\t\r\n\t\tif (obj[eventsKey] && obj[eventsKey][id]) { return this; }\r\n\t\r\n\t\tvar handler = function (e) {\r\n\t\t\treturn fn.call(context || obj, e || window.event);\r\n\t\t};\r\n\t\r\n\t\tvar originalHandler = handler;\r\n\t\r\n\t\tif (pointer && type.indexOf('touch') === 0) {\r\n\t\t\t// Needs DomEvent.Pointer.js\r\n\t\t\taddPointerListener(obj, type, handler, id);\r\n\t\r\n\t\t} else if (touch && (type === 'dblclick') && addDoubleTapListener &&\r\n\t\t !(pointer && chrome)) {\r\n\t\t\t// Chrome >55 does not need the synthetic dblclicks from addDoubleTapListener\r\n\t\t\t// See #5180\r\n\t\t\taddDoubleTapListener(obj, handler, id);\r\n\t\r\n\t\t} else if ('addEventListener' in obj) {\r\n\t\r\n\t\t\tif (type === 'mousewheel') {\r\n\t\t\t\tobj.addEventListener('onwheel' in obj ? 'wheel' : 'mousewheel', handler, false);\r\n\t\r\n\t\t\t} else if ((type === 'mouseenter') || (type === 'mouseleave')) {\r\n\t\t\t\thandler = function (e) {\r\n\t\t\t\t\te = e || window.event;\r\n\t\t\t\t\tif (isExternalTarget(obj, e)) {\r\n\t\t\t\t\t\toriginalHandler(e);\r\n\t\t\t\t\t}\r\n\t\t\t\t};\r\n\t\t\t\tobj.addEventListener(type === 'mouseenter' ? 'mouseover' : 'mouseout', handler, false);\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\tif (type === 'click' && android) {\r\n\t\t\t\t\thandler = function (e) {\r\n\t\t\t\t\t\tfilterClick(e, originalHandler);\r\n\t\t\t\t\t};\r\n\t\t\t\t}\r\n\t\t\t\tobj.addEventListener(type, handler, false);\r\n\t\t\t}\r\n\t\r\n\t\t} else if ('attachEvent' in obj) {\r\n\t\t\tobj.attachEvent('on' + type, handler);\r\n\t\t}\r\n\t\r\n\t\tobj[eventsKey] = obj[eventsKey] || {};\r\n\t\tobj[eventsKey][id] = handler;\r\n\t}\r\n\t\r\n\tfunction removeOne(obj, type, fn, context) {\r\n\t\r\n\t\tvar id = type + stamp(fn) + (context ? '_' + stamp(context) : ''),\r\n\t\t handler = obj[eventsKey] && obj[eventsKey][id];\r\n\t\r\n\t\tif (!handler) { return this; }\r\n\t\r\n\t\tif (pointer && type.indexOf('touch') === 0) {\r\n\t\t\tremovePointerListener(obj, type, id);\r\n\t\r\n\t\t} else if (touch && (type === 'dblclick') && removeDoubleTapListener &&\r\n\t\t !(pointer && chrome)) {\r\n\t\t\tremoveDoubleTapListener(obj, id);\r\n\t\r\n\t\t} else if ('removeEventListener' in obj) {\r\n\t\r\n\t\t\tif (type === 'mousewheel') {\r\n\t\t\t\tobj.removeEventListener('onwheel' in obj ? 'wheel' : 'mousewheel', handler, false);\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\tobj.removeEventListener(\r\n\t\t\t\t\ttype === 'mouseenter' ? 'mouseover' :\r\n\t\t\t\t\ttype === 'mouseleave' ? 'mouseout' : type, handler, false);\r\n\t\t\t}\r\n\t\r\n\t\t} else if ('detachEvent' in obj) {\r\n\t\t\tobj.detachEvent('on' + type, handler);\r\n\t\t}\r\n\t\r\n\t\tobj[eventsKey][id] = null;\r\n\t}\r\n\t\r\n\t// @function stopPropagation(ev: DOMEvent): this\r\n\t// Stop the given event from propagation to parent elements. Used inside the listener functions:\r\n\t// ```js\r\n\t// L.DomEvent.on(div, 'click', function (ev) {\r\n\t// \tL.DomEvent.stopPropagation(ev);\r\n\t// });\r\n\t// ```\r\n\tfunction stopPropagation(e) {\r\n\t\r\n\t\tif (e.stopPropagation) {\r\n\t\t\te.stopPropagation();\r\n\t\t} else if (e.originalEvent) { // In case of Leaflet event.\r\n\t\t\te.originalEvent._stopped = true;\r\n\t\t} else {\r\n\t\t\te.cancelBubble = true;\r\n\t\t}\r\n\t\tskipped(e);\r\n\t\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\t// @function disableScrollPropagation(el: HTMLElement): this\r\n\t// Adds `stopPropagation` to the element's `'mousewheel'` events (plus browser variants).\r\n\tfunction disableScrollPropagation(el) {\r\n\t\taddOne(el, 'mousewheel', stopPropagation);\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\t// @function disableClickPropagation(el: HTMLElement): this\r\n\t// Adds `stopPropagation` to the element's `'click'`, `'doubleclick'`,\r\n\t// `'mousedown'` and `'touchstart'` events (plus browser variants).\r\n\tfunction disableClickPropagation(el) {\r\n\t\ton(el, 'mousedown touchstart dblclick', stopPropagation);\r\n\t\taddOne(el, 'click', fakeStop);\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\t// @function preventDefault(ev: DOMEvent): this\r\n\t// Prevents the default action of the DOM Event `ev` from happening (such as\r\n\t// following a link in the href of the a element, or doing a POST request\r\n\t// with page reload when a `
    ` is submitted).\r\n\t// Use it inside listener functions.\r\n\tfunction preventDefault(e) {\r\n\t\tif (e.preventDefault) {\r\n\t\t\te.preventDefault();\r\n\t\t} else {\r\n\t\t\te.returnValue = false;\r\n\t\t}\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\t// @function stop(ev: DOMEvent): this\r\n\t// Does `stopPropagation` and `preventDefault` at the same time.\r\n\tfunction stop(e) {\r\n\t\tpreventDefault(e);\r\n\t\tstopPropagation(e);\r\n\t\treturn this;\r\n\t}\r\n\t\r\n\t// @function getMousePosition(ev: DOMEvent, container?: HTMLElement): Point\r\n\t// Gets normalized mouse position from a DOM event relative to the\r\n\t// `container` or to the whole page if not specified.\r\n\tfunction getMousePosition(e, container) {\r\n\t\tif (!container) {\r\n\t\t\treturn new Point(e.clientX, e.clientY);\r\n\t\t}\r\n\t\r\n\t\tvar rect = container.getBoundingClientRect();\r\n\t\r\n\t\tvar scaleX = rect.width / container.offsetWidth || 1;\r\n\t\tvar scaleY = rect.height / container.offsetHeight || 1;\r\n\t\treturn new Point(\r\n\t\t\te.clientX / scaleX - rect.left - container.clientLeft,\r\n\t\t\te.clientY / scaleY - rect.top - container.clientTop);\r\n\t}\r\n\t\r\n\t// Chrome on Win scrolls double the pixels as in other platforms (see #4538),\r\n\t// and Firefox scrolls device pixels, not CSS pixels\r\n\tvar wheelPxFactor =\r\n\t\t(win && chrome) ? 2 * window.devicePixelRatio :\r\n\t\tgecko ? window.devicePixelRatio : 1;\r\n\t\r\n\t// @function getWheelDelta(ev: DOMEvent): Number\r\n\t// Gets normalized wheel delta from a mousewheel DOM event, in vertical\r\n\t// pixels scrolled (negative if scrolling down).\r\n\t// Events from pointing devices without precise scrolling are mapped to\r\n\t// a best guess of 60 pixels.\r\n\tfunction getWheelDelta(e) {\r\n\t\treturn (edge) ? e.wheelDeltaY / 2 : // Don't trust window-geometry-based delta\r\n\t\t (e.deltaY && e.deltaMode === 0) ? -e.deltaY / wheelPxFactor : // Pixels\r\n\t\t (e.deltaY && e.deltaMode === 1) ? -e.deltaY * 20 : // Lines\r\n\t\t (e.deltaY && e.deltaMode === 2) ? -e.deltaY * 60 : // Pages\r\n\t\t (e.deltaX || e.deltaZ) ? 0 :\t// Skip horizontal/depth wheel events\r\n\t\t e.wheelDelta ? (e.wheelDeltaY || e.wheelDelta) / 2 : // Legacy IE pixels\r\n\t\t (e.detail && Math.abs(e.detail) < 32765) ? -e.detail * 20 : // Legacy Moz lines\r\n\t\t e.detail ? e.detail / -32765 * 60 : // Legacy Moz pages\r\n\t\t 0;\r\n\t}\r\n\t\r\n\tvar skipEvents = {};\r\n\t\r\n\tfunction fakeStop(e) {\r\n\t\t// fakes stopPropagation by setting a special event flag, checked/reset with skipped(e)\r\n\t\tskipEvents[e.type] = true;\r\n\t}\r\n\t\r\n\tfunction skipped(e) {\r\n\t\tvar events = skipEvents[e.type];\r\n\t\t// reset when checking, as it's only used in map container and propagates outside of the map\r\n\t\tskipEvents[e.type] = false;\r\n\t\treturn events;\r\n\t}\r\n\t\r\n\t// check if element really left/entered the event target (for mouseenter/mouseleave)\r\n\tfunction isExternalTarget(el, e) {\r\n\t\r\n\t\tvar related = e.relatedTarget;\r\n\t\r\n\t\tif (!related) { return true; }\r\n\t\r\n\t\ttry {\r\n\t\t\twhile (related && (related !== el)) {\r\n\t\t\t\trelated = related.parentNode;\r\n\t\t\t}\r\n\t\t} catch (err) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\treturn (related !== el);\r\n\t}\r\n\t\r\n\tvar lastClick;\r\n\t\r\n\t// this is a horrible workaround for a bug in Android where a single touch triggers two click events\r\n\tfunction filterClick(e, handler) {\r\n\t\tvar timeStamp = (e.timeStamp || (e.originalEvent && e.originalEvent.timeStamp)),\r\n\t\t elapsed = lastClick && (timeStamp - lastClick);\r\n\t\r\n\t\t// are they closer together than 500ms yet more than 100ms?\r\n\t\t// Android typically triggers them ~300ms apart while multiple listeners\r\n\t\t// on the same event should be triggered far faster;\r\n\t\t// or check if click is simulated on the element, and if it is, reject any non-simulated events\r\n\t\r\n\t\tif ((elapsed && elapsed > 100 && elapsed < 500) || (e.target._simulatedClick && !e._simulated)) {\r\n\t\t\tstop(e);\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tlastClick = timeStamp;\r\n\t\r\n\t\thandler(e);\r\n\t}\r\n\t\r\n\t\r\n\t\n\t\n\tvar DomEvent = (Object.freeze || Object)({\n\t\ton: on,\n\t\toff: off,\n\t\tstopPropagation: stopPropagation,\n\t\tdisableScrollPropagation: disableScrollPropagation,\n\t\tdisableClickPropagation: disableClickPropagation,\n\t\tpreventDefault: preventDefault,\n\t\tstop: stop,\n\t\tgetMousePosition: getMousePosition,\n\t\tgetWheelDelta: getWheelDelta,\n\t\tfakeStop: fakeStop,\n\t\tskipped: skipped,\n\t\tisExternalTarget: isExternalTarget,\n\t\taddListener: on,\n\t\tremoveListener: off\n\t});\n\t\n\t/*\r\n\t * @namespace DomUtil\r\n\t *\r\n\t * Utility functions to work with the [DOM](https://developer.mozilla.org/docs/Web/API/Document_Object_Model)\r\n\t * tree, used by Leaflet internally.\r\n\t *\r\n\t * Most functions expecting or returning a `HTMLElement` also work for\r\n\t * SVG elements. The only difference is that classes refer to CSS classes\r\n\t * in HTML and SVG classes in SVG.\r\n\t */\r\n\t\r\n\t\r\n\t// @property TRANSFORM: String\r\n\t// Vendor-prefixed transform style name (e.g. `'webkitTransform'` for WebKit).\r\n\tvar TRANSFORM = testProp(\r\n\t\t['transform', 'WebkitTransform', 'OTransform', 'MozTransform', 'msTransform']);\r\n\t\r\n\t// webkitTransition comes first because some browser versions that drop vendor prefix don't do\r\n\t// the same for the transitionend event, in particular the Android 4.1 stock browser\r\n\t\r\n\t// @property TRANSITION: String\r\n\t// Vendor-prefixed transition style name.\r\n\tvar TRANSITION = testProp(\r\n\t\t['webkitTransition', 'transition', 'OTransition', 'MozTransition', 'msTransition']);\r\n\t\r\n\t// @property TRANSITION_END: String\r\n\t// Vendor-prefixed transitionend event name.\r\n\tvar TRANSITION_END =\r\n\t\tTRANSITION === 'webkitTransition' || TRANSITION === 'OTransition' ? TRANSITION + 'End' : 'transitionend';\r\n\t\r\n\t\r\n\t// @function get(id: String|HTMLElement): HTMLElement\r\n\t// Returns an element given its DOM id, or returns the element itself\r\n\t// if it was passed directly.\r\n\tfunction get(id) {\r\n\t\treturn typeof id === 'string' ? document.getElementById(id) : id;\r\n\t}\r\n\t\r\n\t// @function getStyle(el: HTMLElement, styleAttrib: String): String\r\n\t// Returns the value for a certain style attribute on an element,\r\n\t// including computed values or values set through CSS.\r\n\tfunction getStyle(el, style) {\r\n\t\tvar value = el.style[style] || (el.currentStyle && el.currentStyle[style]);\r\n\t\r\n\t\tif ((!value || value === 'auto') && document.defaultView) {\r\n\t\t\tvar css = document.defaultView.getComputedStyle(el, null);\r\n\t\t\tvalue = css ? css[style] : null;\r\n\t\t}\r\n\t\treturn value === 'auto' ? null : value;\r\n\t}\r\n\t\r\n\t// @function create(tagName: String, className?: String, container?: HTMLElement): HTMLElement\r\n\t// Creates an HTML element with `tagName`, sets its class to `className`, and optionally appends it to `container` element.\r\n\tfunction create$1(tagName, className, container) {\r\n\t\tvar el = document.createElement(tagName);\r\n\t\tel.className = className || '';\r\n\t\r\n\t\tif (container) {\r\n\t\t\tcontainer.appendChild(el);\r\n\t\t}\r\n\t\treturn el;\r\n\t}\r\n\t\r\n\t// @function remove(el: HTMLElement)\r\n\t// Removes `el` from its parent element\r\n\tfunction remove(el) {\r\n\t\tvar parent = el.parentNode;\r\n\t\tif (parent) {\r\n\t\t\tparent.removeChild(el);\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function empty(el: HTMLElement)\r\n\t// Removes all of `el`'s children elements from `el`\r\n\tfunction empty(el) {\r\n\t\twhile (el.firstChild) {\r\n\t\t\tel.removeChild(el.firstChild);\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function toFront(el: HTMLElement)\r\n\t// Makes `el` the last child of its parent, so it renders in front of the other children.\r\n\tfunction toFront(el) {\r\n\t\tvar parent = el.parentNode;\r\n\t\tif (parent.lastChild !== el) {\r\n\t\t\tparent.appendChild(el);\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function toBack(el: HTMLElement)\r\n\t// Makes `el` the first child of its parent, so it renders behind the other children.\r\n\tfunction toBack(el) {\r\n\t\tvar parent = el.parentNode;\r\n\t\tif (parent.firstChild !== el) {\r\n\t\t\tparent.insertBefore(el, parent.firstChild);\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function hasClass(el: HTMLElement, name: String): Boolean\r\n\t// Returns `true` if the element's class attribute contains `name`.\r\n\tfunction hasClass(el, name) {\r\n\t\tif (el.classList !== undefined) {\r\n\t\t\treturn el.classList.contains(name);\r\n\t\t}\r\n\t\tvar className = getClass(el);\r\n\t\treturn className.length > 0 && new RegExp('(^|\\\\s)' + name + '(\\\\s|$)').test(className);\r\n\t}\r\n\t\r\n\t// @function addClass(el: HTMLElement, name: String)\r\n\t// Adds `name` to the element's class attribute.\r\n\tfunction addClass(el, name) {\r\n\t\tif (el.classList !== undefined) {\r\n\t\t\tvar classes = splitWords(name);\r\n\t\t\tfor (var i = 0, len = classes.length; i < len; i++) {\r\n\t\t\t\tel.classList.add(classes[i]);\r\n\t\t\t}\r\n\t\t} else if (!hasClass(el, name)) {\r\n\t\t\tvar className = getClass(el);\r\n\t\t\tsetClass(el, (className ? className + ' ' : '') + name);\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function removeClass(el: HTMLElement, name: String)\r\n\t// Removes `name` from the element's class attribute.\r\n\tfunction removeClass(el, name) {\r\n\t\tif (el.classList !== undefined) {\r\n\t\t\tel.classList.remove(name);\r\n\t\t} else {\r\n\t\t\tsetClass(el, trim((' ' + getClass(el) + ' ').replace(' ' + name + ' ', ' ')));\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function setClass(el: HTMLElement, name: String)\r\n\t// Sets the element's class.\r\n\tfunction setClass(el, name) {\r\n\t\tif (el.className.baseVal === undefined) {\r\n\t\t\tel.className = name;\r\n\t\t} else {\r\n\t\t\t// in case of SVG element\r\n\t\t\tel.className.baseVal = name;\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function getClass(el: HTMLElement): String\r\n\t// Returns the element's class.\r\n\tfunction getClass(el) {\r\n\t\treturn el.className.baseVal === undefined ? el.className : el.className.baseVal;\r\n\t}\r\n\t\r\n\t// @function setOpacity(el: HTMLElement, opacity: Number)\r\n\t// Set the opacity of an element (including old IE support).\r\n\t// `opacity` must be a number from `0` to `1`.\r\n\tfunction setOpacity(el, value) {\r\n\t\tif ('opacity' in el.style) {\r\n\t\t\tel.style.opacity = value;\r\n\t\t} else if ('filter' in el.style) {\r\n\t\t\t_setOpacityIE(el, value);\r\n\t\t}\r\n\t}\r\n\t\r\n\tfunction _setOpacityIE(el, value) {\r\n\t\tvar filter = false,\r\n\t\t filterName = 'DXImageTransform.Microsoft.Alpha';\r\n\t\r\n\t\t// filters collection throws an error if we try to retrieve a filter that doesn't exist\r\n\t\ttry {\r\n\t\t\tfilter = el.filters.item(filterName);\r\n\t\t} catch (e) {\r\n\t\t\t// don't set opacity to 1 if we haven't already set an opacity,\r\n\t\t\t// it isn't needed and breaks transparent pngs.\r\n\t\t\tif (value === 1) { return; }\r\n\t\t}\r\n\t\r\n\t\tvalue = Math.round(value * 100);\r\n\t\r\n\t\tif (filter) {\r\n\t\t\tfilter.Enabled = (value !== 100);\r\n\t\t\tfilter.Opacity = value;\r\n\t\t} else {\r\n\t\t\tel.style.filter += ' progid:' + filterName + '(opacity=' + value + ')';\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function testProp(props: String[]): String|false\r\n\t// Goes through the array of style names and returns the first name\r\n\t// that is a valid style name for an element. If no such name is found,\r\n\t// it returns false. Useful for vendor-prefixed styles like `transform`.\r\n\tfunction testProp(props) {\r\n\t\tvar style = document.documentElement.style;\r\n\t\r\n\t\tfor (var i = 0; i < props.length; i++) {\r\n\t\t\tif (props[i] in style) {\r\n\t\t\t\treturn props[i];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}\r\n\t\r\n\t// @function setTransform(el: HTMLElement, offset: Point, scale?: Number)\r\n\t// Resets the 3D CSS transform of `el` so it is translated by `offset` pixels\r\n\t// and optionally scaled by `scale`. Does not have an effect if the\r\n\t// browser doesn't support 3D CSS transforms.\r\n\tfunction setTransform(el, offset, scale) {\r\n\t\tvar pos = offset || new Point(0, 0);\r\n\t\r\n\t\tel.style[TRANSFORM] =\r\n\t\t\t(ie3d ?\r\n\t\t\t\t'translate(' + pos.x + 'px,' + pos.y + 'px)' :\r\n\t\t\t\t'translate3d(' + pos.x + 'px,' + pos.y + 'px,0)') +\r\n\t\t\t(scale ? ' scale(' + scale + ')' : '');\r\n\t}\r\n\t\r\n\t// @function setPosition(el: HTMLElement, position: Point)\r\n\t// Sets the position of `el` to coordinates specified by `position`,\r\n\t// using CSS translate or top/left positioning depending on the browser\r\n\t// (used by Leaflet internally to position its layers).\r\n\tfunction setPosition(el, point) {\r\n\t\r\n\t\t/*eslint-disable */\r\n\t\tel._leaflet_pos = point;\r\n\t\t/* eslint-enable */\r\n\t\r\n\t\tif (any3d) {\r\n\t\t\tsetTransform(el, point);\r\n\t\t} else {\r\n\t\t\tel.style.left = point.x + 'px';\r\n\t\t\tel.style.top = point.y + 'px';\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function getPosition(el: HTMLElement): Point\r\n\t// Returns the coordinates of an element previously positioned with setPosition.\r\n\tfunction getPosition(el) {\r\n\t\t// this method is only used for elements previously positioned using setPosition,\r\n\t\t// so it's safe to cache the position for performance\r\n\t\r\n\t\treturn el._leaflet_pos || new Point(0, 0);\r\n\t}\r\n\t\r\n\t// @function disableTextSelection()\r\n\t// Prevents the user from generating `selectstart` DOM events, usually generated\r\n\t// when the user drags the mouse through a page with text. Used internally\r\n\t// by Leaflet to override the behaviour of any click-and-drag interaction on\r\n\t// the map. Affects drag interactions on the whole document.\r\n\t\r\n\t// @function enableTextSelection()\r\n\t// Cancels the effects of a previous [`L.DomUtil.disableTextSelection`](#domutil-disabletextselection).\r\n\tvar disableTextSelection;\r\n\tvar enableTextSelection;\r\n\tvar _userSelect;\r\n\tif ('onselectstart' in document) {\r\n\t\tdisableTextSelection = function () {\r\n\t\t\ton(window, 'selectstart', preventDefault);\r\n\t\t};\r\n\t\tenableTextSelection = function () {\r\n\t\t\toff(window, 'selectstart', preventDefault);\r\n\t\t};\r\n\t} else {\r\n\t\tvar userSelectProperty = testProp(\r\n\t\t\t['userSelect', 'WebkitUserSelect', 'OUserSelect', 'MozUserSelect', 'msUserSelect']);\r\n\t\r\n\t\tdisableTextSelection = function () {\r\n\t\t\tif (userSelectProperty) {\r\n\t\t\t\tvar style = document.documentElement.style;\r\n\t\t\t\t_userSelect = style[userSelectProperty];\r\n\t\t\t\tstyle[userSelectProperty] = 'none';\r\n\t\t\t}\r\n\t\t};\r\n\t\tenableTextSelection = function () {\r\n\t\t\tif (userSelectProperty) {\r\n\t\t\t\tdocument.documentElement.style[userSelectProperty] = _userSelect;\r\n\t\t\t\t_userSelect = undefined;\r\n\t\t\t}\r\n\t\t};\r\n\t}\r\n\t\r\n\t// @function disableImageDrag()\r\n\t// As [`L.DomUtil.disableTextSelection`](#domutil-disabletextselection), but\r\n\t// for `dragstart` DOM events, usually generated when the user drags an image.\r\n\tfunction disableImageDrag() {\r\n\t\ton(window, 'dragstart', preventDefault);\r\n\t}\r\n\t\r\n\t// @function enableImageDrag()\r\n\t// Cancels the effects of a previous [`L.DomUtil.disableImageDrag`](#domutil-disabletextselection).\r\n\tfunction enableImageDrag() {\r\n\t\toff(window, 'dragstart', preventDefault);\r\n\t}\r\n\t\r\n\tvar _outlineElement;\n\tvar _outlineStyle;\r\n\t// @function preventOutline(el: HTMLElement)\r\n\t// Makes the [outline](https://developer.mozilla.org/docs/Web/CSS/outline)\r\n\t// of the element `el` invisible. Used internally by Leaflet to prevent\r\n\t// focusable elements from displaying an outline when the user performs a\r\n\t// drag interaction on them.\r\n\tfunction preventOutline(element) {\r\n\t\twhile (element.tabIndex === -1) {\r\n\t\t\telement = element.parentNode;\r\n\t\t}\r\n\t\tif (!element.style) { return; }\r\n\t\trestoreOutline();\r\n\t\t_outlineElement = element;\r\n\t\t_outlineStyle = element.style.outline;\r\n\t\telement.style.outline = 'none';\r\n\t\ton(window, 'keydown', restoreOutline);\r\n\t}\r\n\t\r\n\t// @function restoreOutline()\r\n\t// Cancels the effects of a previous [`L.DomUtil.preventOutline`]().\r\n\tfunction restoreOutline() {\r\n\t\tif (!_outlineElement) { return; }\r\n\t\t_outlineElement.style.outline = _outlineStyle;\r\n\t\t_outlineElement = undefined;\r\n\t\t_outlineStyle = undefined;\r\n\t\toff(window, 'keydown', restoreOutline);\r\n\t}\r\n\t\n\t\n\tvar DomUtil = (Object.freeze || Object)({\n\t\tTRANSFORM: TRANSFORM,\n\t\tTRANSITION: TRANSITION,\n\t\tTRANSITION_END: TRANSITION_END,\n\t\tget: get,\n\t\tgetStyle: getStyle,\n\t\tcreate: create$1,\n\t\tremove: remove,\n\t\tempty: empty,\n\t\ttoFront: toFront,\n\t\ttoBack: toBack,\n\t\thasClass: hasClass,\n\t\taddClass: addClass,\n\t\tremoveClass: removeClass,\n\t\tsetClass: setClass,\n\t\tgetClass: getClass,\n\t\tsetOpacity: setOpacity,\n\t\ttestProp: testProp,\n\t\tsetTransform: setTransform,\n\t\tsetPosition: setPosition,\n\t\tgetPosition: getPosition,\n\t\tdisableTextSelection: disableTextSelection,\n\t\tenableTextSelection: enableTextSelection,\n\t\tdisableImageDrag: disableImageDrag,\n\t\tenableImageDrag: enableImageDrag,\n\t\tpreventOutline: preventOutline,\n\t\trestoreOutline: restoreOutline\n\t});\n\t\n\t/*\n\t * @class PosAnimation\n\t * @aka L.PosAnimation\n\t * @inherits Evented\n\t * Used internally for panning animations, utilizing CSS3 Transitions for modern browsers and a timer fallback for IE6-9.\n\t *\n\t * @example\n\t * ```js\n\t * var fx = new L.PosAnimation();\n\t * fx.run(el, [300, 500], 0.5);\n\t * ```\n\t *\n\t * @constructor L.PosAnimation()\n\t * Creates a `PosAnimation` object.\n\t *\n\t */\n\t\n\tvar PosAnimation = Evented.extend({\n\t\n\t\t// @method run(el: HTMLElement, newPos: Point, duration?: Number, easeLinearity?: Number)\n\t\t// Run an animation of a given element to a new position, optionally setting\n\t\t// duration in seconds (`0.25` by default) and easing linearity factor (3rd\n\t\t// argument of the [cubic bezier curve](http://cubic-bezier.com/#0,0,.5,1),\n\t\t// `0.5` by default).\n\t\trun: function (el, newPos, duration, easeLinearity) {\n\t\t\tthis.stop();\n\t\n\t\t\tthis._el = el;\n\t\t\tthis._inProgress = true;\n\t\t\tthis._duration = duration || 0.25;\n\t\t\tthis._easeOutPower = 1 / Math.max(easeLinearity || 0.5, 0.2);\n\t\n\t\t\tthis._startPos = getPosition(el);\n\t\t\tthis._offset = newPos.subtract(this._startPos);\n\t\t\tthis._startTime = +new Date();\n\t\n\t\t\t// @event start: Event\n\t\t\t// Fired when the animation starts\n\t\t\tthis.fire('start');\n\t\n\t\t\tthis._animate();\n\t\t},\n\t\n\t\t// @method stop()\n\t\t// Stops the animation (if currently running).\n\t\tstop: function () {\n\t\t\tif (!this._inProgress) { return; }\n\t\n\t\t\tthis._step(true);\n\t\t\tthis._complete();\n\t\t},\n\t\n\t\t_animate: function () {\n\t\t\t// animation loop\n\t\t\tthis._animId = requestAnimFrame(this._animate, this);\n\t\t\tthis._step();\n\t\t},\n\t\n\t\t_step: function (round) {\n\t\t\tvar elapsed = (+new Date()) - this._startTime,\n\t\t\t duration = this._duration * 1000;\n\t\n\t\t\tif (elapsed < duration) {\n\t\t\t\tthis._runFrame(this._easeOut(elapsed / duration), round);\n\t\t\t} else {\n\t\t\t\tthis._runFrame(1);\n\t\t\t\tthis._complete();\n\t\t\t}\n\t\t},\n\t\n\t\t_runFrame: function (progress, round) {\n\t\t\tvar pos = this._startPos.add(this._offset.multiplyBy(progress));\n\t\t\tif (round) {\n\t\t\t\tpos._round();\n\t\t\t}\n\t\t\tsetPosition(this._el, pos);\n\t\n\t\t\t// @event step: Event\n\t\t\t// Fired continuously during the animation.\n\t\t\tthis.fire('step');\n\t\t},\n\t\n\t\t_complete: function () {\n\t\t\tcancelAnimFrame(this._animId);\n\t\n\t\t\tthis._inProgress = false;\n\t\t\t// @event end: Event\n\t\t\t// Fired when the animation ends.\n\t\t\tthis.fire('end');\n\t\t},\n\t\n\t\t_easeOut: function (t) {\n\t\t\treturn 1 - Math.pow(1 - t, this._easeOutPower);\n\t\t}\n\t});\n\t\n\t/*\r\n\t * @class Map\r\n\t * @aka L.Map\r\n\t * @inherits Evented\r\n\t *\r\n\t * The central class of the API — it is used to create a map on a page and manipulate it.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * // initialize the map on the \"map\" div with a given center and zoom\r\n\t * var map = L.map('map', {\r\n\t * \tcenter: [51.505, -0.09],\r\n\t * \tzoom: 13\r\n\t * });\r\n\t * ```\r\n\t *\r\n\t */\r\n\t\r\n\tvar Map = Evented.extend({\r\n\t\r\n\t\toptions: {\r\n\t\t\t// @section Map State Options\r\n\t\t\t// @option crs: CRS = L.CRS.EPSG3857\r\n\t\t\t// The [Coordinate Reference System](#crs) to use. Don't change this if you're not\r\n\t\t\t// sure what it means.\r\n\t\t\tcrs: EPSG3857,\r\n\t\r\n\t\t\t// @option center: LatLng = undefined\r\n\t\t\t// Initial geographic center of the map\r\n\t\t\tcenter: undefined,\r\n\t\r\n\t\t\t// @option zoom: Number = undefined\r\n\t\t\t// Initial map zoom level\r\n\t\t\tzoom: undefined,\r\n\t\r\n\t\t\t// @option minZoom: Number = *\r\n\t\t\t// Minimum zoom level of the map.\r\n\t\t\t// If not specified and at least one `GridLayer` or `TileLayer` is in the map,\r\n\t\t\t// the lowest of their `minZoom` options will be used instead.\r\n\t\t\tminZoom: undefined,\r\n\t\r\n\t\t\t// @option maxZoom: Number = *\r\n\t\t\t// Maximum zoom level of the map.\r\n\t\t\t// If not specified and at least one `GridLayer` or `TileLayer` is in the map,\r\n\t\t\t// the highest of their `maxZoom` options will be used instead.\r\n\t\t\tmaxZoom: undefined,\r\n\t\r\n\t\t\t// @option layers: Layer[] = []\r\n\t\t\t// Array of layers that will be added to the map initially\r\n\t\t\tlayers: [],\r\n\t\r\n\t\t\t// @option maxBounds: LatLngBounds = null\r\n\t\t\t// When this option is set, the map restricts the view to the given\r\n\t\t\t// geographical bounds, bouncing the user back if the user tries to pan\r\n\t\t\t// outside the view. To set the restriction dynamically, use\r\n\t\t\t// [`setMaxBounds`](#map-setmaxbounds) method.\r\n\t\t\tmaxBounds: undefined,\r\n\t\r\n\t\t\t// @option renderer: Renderer = *\r\n\t\t\t// The default method for drawing vector layers on the map. `L.SVG`\r\n\t\t\t// or `L.Canvas` by default depending on browser support.\r\n\t\t\trenderer: undefined,\r\n\t\r\n\t\r\n\t\t\t// @section Animation Options\r\n\t\t\t// @option zoomAnimation: Boolean = true\r\n\t\t\t// Whether the map zoom animation is enabled. By default it's enabled\r\n\t\t\t// in all browsers that support CSS3 Transitions except Android.\r\n\t\t\tzoomAnimation: true,\r\n\t\r\n\t\t\t// @option zoomAnimationThreshold: Number = 4\r\n\t\t\t// Won't animate zoom if the zoom difference exceeds this value.\r\n\t\t\tzoomAnimationThreshold: 4,\r\n\t\r\n\t\t\t// @option fadeAnimation: Boolean = true\r\n\t\t\t// Whether the tile fade animation is enabled. By default it's enabled\r\n\t\t\t// in all browsers that support CSS3 Transitions except Android.\r\n\t\t\tfadeAnimation: true,\r\n\t\r\n\t\t\t// @option markerZoomAnimation: Boolean = true\r\n\t\t\t// Whether markers animate their zoom with the zoom animation, if disabled\r\n\t\t\t// they will disappear for the length of the animation. By default it's\r\n\t\t\t// enabled in all browsers that support CSS3 Transitions except Android.\r\n\t\t\tmarkerZoomAnimation: true,\r\n\t\r\n\t\t\t// @option transform3DLimit: Number = 2^23\r\n\t\t\t// Defines the maximum size of a CSS translation transform. The default\r\n\t\t\t// value should not be changed unless a web browser positions layers in\r\n\t\t\t// the wrong place after doing a large `panBy`.\r\n\t\t\ttransform3DLimit: 8388608, // Precision limit of a 32-bit float\r\n\t\r\n\t\t\t// @section Interaction Options\r\n\t\t\t// @option zoomSnap: Number = 1\r\n\t\t\t// Forces the map's zoom level to always be a multiple of this, particularly\r\n\t\t\t// right after a [`fitBounds()`](#map-fitbounds) or a pinch-zoom.\r\n\t\t\t// By default, the zoom level snaps to the nearest integer; lower values\r\n\t\t\t// (e.g. `0.5` or `0.1`) allow for greater granularity. A value of `0`\r\n\t\t\t// means the zoom level will not be snapped after `fitBounds` or a pinch-zoom.\r\n\t\t\tzoomSnap: 1,\r\n\t\r\n\t\t\t// @option zoomDelta: Number = 1\r\n\t\t\t// Controls how much the map's zoom level will change after a\r\n\t\t\t// [`zoomIn()`](#map-zoomin), [`zoomOut()`](#map-zoomout), pressing `+`\r\n\t\t\t// or `-` on the keyboard, or using the [zoom controls](#control-zoom).\r\n\t\t\t// Values smaller than `1` (e.g. `0.5`) allow for greater granularity.\r\n\t\t\tzoomDelta: 1,\r\n\t\r\n\t\t\t// @option trackResize: Boolean = true\r\n\t\t\t// Whether the map automatically handles browser window resize to update itself.\r\n\t\t\ttrackResize: true\r\n\t\t},\r\n\t\r\n\t\tinitialize: function (id, options) { // (HTMLElement or String, Object)\r\n\t\t\toptions = setOptions(this, options);\r\n\t\r\n\t\t\tthis._initContainer(id);\r\n\t\t\tthis._initLayout();\r\n\t\r\n\t\t\t// hack for https://github.com/Leaflet/Leaflet/issues/1980\r\n\t\t\tthis._onResize = bind(this._onResize, this);\r\n\t\r\n\t\t\tthis._initEvents();\r\n\t\r\n\t\t\tif (options.maxBounds) {\r\n\t\t\t\tthis.setMaxBounds(options.maxBounds);\r\n\t\t\t}\r\n\t\r\n\t\t\tif (options.zoom !== undefined) {\r\n\t\t\t\tthis._zoom = this._limitZoom(options.zoom);\r\n\t\t\t}\r\n\t\r\n\t\t\tif (options.center && options.zoom !== undefined) {\r\n\t\t\t\tthis.setView(toLatLng(options.center), options.zoom, {reset: true});\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._handlers = [];\r\n\t\t\tthis._layers = {};\r\n\t\t\tthis._zoomBoundLayers = {};\r\n\t\t\tthis._sizeChanged = true;\r\n\t\r\n\t\t\tthis.callInitHooks();\r\n\t\r\n\t\t\t// don't animate on browsers without hardware-accelerated transitions or old Android/Opera\r\n\t\t\tthis._zoomAnimated = TRANSITION && any3d && !mobileOpera &&\r\n\t\t\t\t\tthis.options.zoomAnimation;\r\n\t\r\n\t\t\t// zoom transitions run with the same duration for all layers, so if one of transitionend events\r\n\t\t\t// happens after starting zoom animation (propagating to the map pane), we know that it ended globally\r\n\t\t\tif (this._zoomAnimated) {\r\n\t\t\t\tthis._createAnimProxy();\r\n\t\t\t\ton(this._proxy, TRANSITION_END, this._catchTransitionEnd, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._addLayers(this.options.layers);\r\n\t\t},\r\n\t\r\n\t\r\n\t\t// @section Methods for modifying map state\r\n\t\r\n\t\t// @method setView(center: LatLng, zoom: Number, options?: Zoom/pan options): this\r\n\t\t// Sets the view of the map (geographical center and zoom) with the given\r\n\t\t// animation options.\r\n\t\tsetView: function (center, zoom, options) {\r\n\t\r\n\t\t\tzoom = zoom === undefined ? this._zoom : this._limitZoom(zoom);\r\n\t\t\tcenter = this._limitCenter(toLatLng(center), zoom, this.options.maxBounds);\r\n\t\t\toptions = options || {};\r\n\t\r\n\t\t\tthis._stop();\r\n\t\r\n\t\t\tif (this._loaded && !options.reset && options !== true) {\r\n\t\r\n\t\t\t\tif (options.animate !== undefined) {\r\n\t\t\t\t\toptions.zoom = extend({animate: options.animate}, options.zoom);\r\n\t\t\t\t\toptions.pan = extend({animate: options.animate, duration: options.duration}, options.pan);\r\n\t\t\t\t}\r\n\t\r\n\t\t\t\t// try animating pan or zoom\r\n\t\t\t\tvar moved = (this._zoom !== zoom) ?\r\n\t\t\t\t\tthis._tryAnimatedZoom && this._tryAnimatedZoom(center, zoom, options.zoom) :\r\n\t\t\t\t\tthis._tryAnimatedPan(center, options.pan);\r\n\t\r\n\t\t\t\tif (moved) {\r\n\t\t\t\t\t// prevent resize handler call, the view will refresh after animation anyway\r\n\t\t\t\t\tclearTimeout(this._sizeTimer);\r\n\t\t\t\t\treturn this;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\t// animation didn't start, just reset the map view\r\n\t\t\tthis._resetView(center, zoom);\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method setZoom(zoom: Number, options?: Zoom/pan options): this\r\n\t\t// Sets the zoom of the map.\r\n\t\tsetZoom: function (zoom, options) {\r\n\t\t\tif (!this._loaded) {\r\n\t\t\t\tthis._zoom = zoom;\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\t\treturn this.setView(this.getCenter(), zoom, {zoom: options});\r\n\t\t},\r\n\t\r\n\t\t// @method zoomIn(delta?: Number, options?: Zoom options): this\r\n\t\t// Increases the zoom of the map by `delta` ([`zoomDelta`](#map-zoomdelta) by default).\r\n\t\tzoomIn: function (delta, options) {\r\n\t\t\tdelta = delta || (any3d ? this.options.zoomDelta : 1);\r\n\t\t\treturn this.setZoom(this._zoom + delta, options);\r\n\t\t},\r\n\t\r\n\t\t// @method zoomOut(delta?: Number, options?: Zoom options): this\r\n\t\t// Decreases the zoom of the map by `delta` ([`zoomDelta`](#map-zoomdelta) by default).\r\n\t\tzoomOut: function (delta, options) {\r\n\t\t\tdelta = delta || (any3d ? this.options.zoomDelta : 1);\r\n\t\t\treturn this.setZoom(this._zoom - delta, options);\r\n\t\t},\r\n\t\r\n\t\t// @method setZoomAround(latlng: LatLng, zoom: Number, options: Zoom options): this\r\n\t\t// Zooms the map while keeping a specified geographical point on the map\r\n\t\t// stationary (e.g. used internally for scroll zoom and double-click zoom).\r\n\t\t// @alternative\r\n\t\t// @method setZoomAround(offset: Point, zoom: Number, options: Zoom options): this\r\n\t\t// Zooms the map while keeping a specified pixel on the map (relative to the top-left corner) stationary.\r\n\t\tsetZoomAround: function (latlng, zoom, options) {\r\n\t\t\tvar scale = this.getZoomScale(zoom),\r\n\t\t\t viewHalf = this.getSize().divideBy(2),\r\n\t\t\t containerPoint = latlng instanceof Point ? latlng : this.latLngToContainerPoint(latlng),\r\n\t\r\n\t\t\t centerOffset = containerPoint.subtract(viewHalf).multiplyBy(1 - 1 / scale),\r\n\t\t\t newCenter = this.containerPointToLatLng(viewHalf.add(centerOffset));\r\n\t\r\n\t\t\treturn this.setView(newCenter, zoom, {zoom: options});\r\n\t\t},\r\n\t\r\n\t\t_getBoundsCenterZoom: function (bounds, options) {\r\n\t\r\n\t\t\toptions = options || {};\r\n\t\t\tbounds = bounds.getBounds ? bounds.getBounds() : toLatLngBounds(bounds);\r\n\t\r\n\t\t\tvar paddingTL = toPoint(options.paddingTopLeft || options.padding || [0, 0]),\r\n\t\t\t paddingBR = toPoint(options.paddingBottomRight || options.padding || [0, 0]),\r\n\t\r\n\t\t\t zoom = this.getBoundsZoom(bounds, false, paddingTL.add(paddingBR));\r\n\t\r\n\t\t\tzoom = (typeof options.maxZoom === 'number') ? Math.min(options.maxZoom, zoom) : zoom;\r\n\t\r\n\t\t\tif (zoom === Infinity) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\tcenter: bounds.getCenter(),\r\n\t\t\t\t\tzoom: zoom\r\n\t\t\t\t};\r\n\t\t\t}\r\n\t\r\n\t\t\tvar paddingOffset = paddingBR.subtract(paddingTL).divideBy(2),\r\n\t\r\n\t\t\t swPoint = this.project(bounds.getSouthWest(), zoom),\r\n\t\t\t nePoint = this.project(bounds.getNorthEast(), zoom),\r\n\t\t\t center = this.unproject(swPoint.add(nePoint).divideBy(2).add(paddingOffset), zoom);\r\n\t\r\n\t\t\treturn {\r\n\t\t\t\tcenter: center,\r\n\t\t\t\tzoom: zoom\r\n\t\t\t};\r\n\t\t},\r\n\t\r\n\t\t// @method fitBounds(bounds: LatLngBounds, options?: fitBounds options): this\r\n\t\t// Sets a map view that contains the given geographical bounds with the\r\n\t\t// maximum zoom level possible.\r\n\t\tfitBounds: function (bounds, options) {\r\n\t\r\n\t\t\tbounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\tif (!bounds.isValid()) {\r\n\t\t\t\tthrow new Error('Bounds are not valid.');\r\n\t\t\t}\r\n\t\r\n\t\t\tvar target = this._getBoundsCenterZoom(bounds, options);\r\n\t\t\treturn this.setView(target.center, target.zoom, options);\r\n\t\t},\r\n\t\r\n\t\t// @method fitWorld(options?: fitBounds options): this\r\n\t\t// Sets a map view that mostly contains the whole world with the maximum\r\n\t\t// zoom level possible.\r\n\t\tfitWorld: function (options) {\r\n\t\t\treturn this.fitBounds([[-90, -180], [90, 180]], options);\r\n\t\t},\r\n\t\r\n\t\t// @method panTo(latlng: LatLng, options?: Pan options): this\r\n\t\t// Pans the map to a given center.\r\n\t\tpanTo: function (center, options) { // (LatLng)\r\n\t\t\treturn this.setView(center, this._zoom, {pan: options});\r\n\t\t},\r\n\t\r\n\t\t// @method panBy(offset: Point, options?: Pan options): this\r\n\t\t// Pans the map by a given number of pixels (animated).\r\n\t\tpanBy: function (offset, options) {\r\n\t\t\toffset = toPoint(offset).round();\r\n\t\t\toptions = options || {};\r\n\t\r\n\t\t\tif (!offset.x && !offset.y) {\r\n\t\t\t\treturn this.fire('moveend');\r\n\t\t\t}\r\n\t\t\t// If we pan too far, Chrome gets issues with tiles\r\n\t\t\t// and makes them disappear or appear in the wrong place (slightly offset) #2602\r\n\t\t\tif (options.animate !== true && !this.getSize().contains(offset)) {\r\n\t\t\t\tthis._resetView(this.unproject(this.project(this.getCenter()).add(offset)), this.getZoom());\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (!this._panAnim) {\r\n\t\t\t\tthis._panAnim = new PosAnimation();\r\n\t\r\n\t\t\t\tthis._panAnim.on({\r\n\t\t\t\t\t'step': this._onPanTransitionStep,\r\n\t\t\t\t\t'end': this._onPanTransitionEnd\r\n\t\t\t\t}, this);\r\n\t\t\t}\r\n\t\r\n\t\t\t// don't fire movestart if animating inertia\r\n\t\t\tif (!options.noMoveStart) {\r\n\t\t\t\tthis.fire('movestart');\r\n\t\t\t}\r\n\t\r\n\t\t\t// animate pan unless animate: false specified\r\n\t\t\tif (options.animate !== false) {\r\n\t\t\t\taddClass(this._mapPane, 'leaflet-pan-anim');\r\n\t\r\n\t\t\t\tvar newPos = this._getMapPanePos().subtract(offset).round();\r\n\t\t\t\tthis._panAnim.run(this._mapPane, newPos, options.duration || 0.25, options.easeLinearity);\r\n\t\t\t} else {\r\n\t\t\t\tthis._rawPanBy(offset);\r\n\t\t\t\tthis.fire('move').fire('moveend');\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method flyTo(latlng: LatLng, zoom?: Number, options?: Zoom/pan options): this\r\n\t\t// Sets the view of the map (geographical center and zoom) performing a smooth\r\n\t\t// pan-zoom animation.\r\n\t\tflyTo: function (targetCenter, targetZoom, options) {\r\n\t\r\n\t\t\toptions = options || {};\r\n\t\t\tif (options.animate === false || !any3d) {\r\n\t\t\t\treturn this.setView(targetCenter, targetZoom, options);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._stop();\r\n\t\r\n\t\t\tvar from = this.project(this.getCenter()),\r\n\t\t\t to = this.project(targetCenter),\r\n\t\t\t size = this.getSize(),\r\n\t\t\t startZoom = this._zoom;\r\n\t\r\n\t\t\ttargetCenter = toLatLng(targetCenter);\r\n\t\t\ttargetZoom = targetZoom === undefined ? startZoom : targetZoom;\r\n\t\r\n\t\t\tvar w0 = Math.max(size.x, size.y),\r\n\t\t\t w1 = w0 * this.getZoomScale(startZoom, targetZoom),\r\n\t\t\t u1 = (to.distanceTo(from)) || 1,\r\n\t\t\t rho = 1.42,\r\n\t\t\t rho2 = rho * rho;\r\n\t\r\n\t\t\tfunction r(i) {\r\n\t\t\t\tvar s1 = i ? -1 : 1,\r\n\t\t\t\t s2 = i ? w1 : w0,\r\n\t\t\t\t t1 = w1 * w1 - w0 * w0 + s1 * rho2 * rho2 * u1 * u1,\r\n\t\t\t\t b1 = 2 * s2 * rho2 * u1,\r\n\t\t\t\t b = t1 / b1,\r\n\t\t\t\t sq = Math.sqrt(b * b + 1) - b;\r\n\t\r\n\t\t\t\t // workaround for floating point precision bug when sq = 0, log = -Infinite,\r\n\t\t\t\t // thus triggering an infinite loop in flyTo\r\n\t\t\t\t var log = sq < 0.000000001 ? -18 : Math.log(sq);\r\n\t\r\n\t\t\t\treturn log;\r\n\t\t\t}\r\n\t\r\n\t\t\tfunction sinh(n) { return (Math.exp(n) - Math.exp(-n)) / 2; }\r\n\t\t\tfunction cosh(n) { return (Math.exp(n) + Math.exp(-n)) / 2; }\r\n\t\t\tfunction tanh(n) { return sinh(n) / cosh(n); }\r\n\t\r\n\t\t\tvar r0 = r(0);\r\n\t\r\n\t\t\tfunction w(s) { return w0 * (cosh(r0) / cosh(r0 + rho * s)); }\r\n\t\t\tfunction u(s) { return w0 * (cosh(r0) * tanh(r0 + rho * s) - sinh(r0)) / rho2; }\r\n\t\r\n\t\t\tfunction easeOut(t) { return 1 - Math.pow(1 - t, 1.5); }\r\n\t\r\n\t\t\tvar start = Date.now(),\r\n\t\t\t S = (r(1) - r0) / rho,\r\n\t\t\t duration = options.duration ? 1000 * options.duration : 1000 * S * 0.8;\r\n\t\r\n\t\t\tfunction frame() {\r\n\t\t\t\tvar t = (Date.now() - start) / duration,\r\n\t\t\t\t s = easeOut(t) * S;\r\n\t\r\n\t\t\t\tif (t <= 1) {\r\n\t\t\t\t\tthis._flyToFrame = requestAnimFrame(frame, this);\r\n\t\r\n\t\t\t\t\tthis._move(\r\n\t\t\t\t\t\tthis.unproject(from.add(to.subtract(from).multiplyBy(u(s) / u1)), startZoom),\r\n\t\t\t\t\t\tthis.getScaleZoom(w0 / w(s), startZoom),\r\n\t\t\t\t\t\t{flyTo: true});\r\n\t\r\n\t\t\t\t} else {\r\n\t\t\t\t\tthis\r\n\t\t\t\t\t\t._move(targetCenter, targetZoom)\r\n\t\t\t\t\t\t._moveEnd(true);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._moveStart(true, options.noMoveStart);\r\n\t\r\n\t\t\tframe.call(this);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method flyToBounds(bounds: LatLngBounds, options?: fitBounds options): this\r\n\t\t// Sets the view of the map with a smooth animation like [`flyTo`](#map-flyto),\r\n\t\t// but takes a bounds parameter like [`fitBounds`](#map-fitbounds).\r\n\t\tflyToBounds: function (bounds, options) {\r\n\t\t\tvar target = this._getBoundsCenterZoom(bounds, options);\r\n\t\t\treturn this.flyTo(target.center, target.zoom, options);\r\n\t\t},\r\n\t\r\n\t\t// @method setMaxBounds(bounds: Bounds): this\r\n\t\t// Restricts the map view to the given bounds (see the [maxBounds](#map-maxbounds) option).\r\n\t\tsetMaxBounds: function (bounds) {\r\n\t\t\tbounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\tif (!bounds.isValid()) {\r\n\t\t\t\tthis.options.maxBounds = null;\r\n\t\t\t\treturn this.off('moveend', this._panInsideMaxBounds);\r\n\t\t\t} else if (this.options.maxBounds) {\r\n\t\t\t\tthis.off('moveend', this._panInsideMaxBounds);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis.options.maxBounds = bounds;\r\n\t\r\n\t\t\tif (this._loaded) {\r\n\t\t\t\tthis._panInsideMaxBounds();\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this.on('moveend', this._panInsideMaxBounds);\r\n\t\t},\r\n\t\r\n\t\t// @method setMinZoom(zoom: Number): this\r\n\t\t// Sets the lower limit for the available zoom levels (see the [minZoom](#map-minzoom) option).\r\n\t\tsetMinZoom: function (zoom) {\r\n\t\t\tvar oldZoom = this.options.minZoom;\r\n\t\t\tthis.options.minZoom = zoom;\r\n\t\r\n\t\t\tif (this._loaded && oldZoom !== zoom) {\r\n\t\t\t\tthis.fire('zoomlevelschange');\r\n\t\r\n\t\t\t\tif (this.getZoom() < this.options.minZoom) {\r\n\t\t\t\t\treturn this.setZoom(zoom);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method setMaxZoom(zoom: Number): this\r\n\t\t// Sets the upper limit for the available zoom levels (see the [maxZoom](#map-maxzoom) option).\r\n\t\tsetMaxZoom: function (zoom) {\r\n\t\t\tvar oldZoom = this.options.maxZoom;\r\n\t\t\tthis.options.maxZoom = zoom;\r\n\t\r\n\t\t\tif (this._loaded && oldZoom !== zoom) {\r\n\t\t\t\tthis.fire('zoomlevelschange');\r\n\t\r\n\t\t\t\tif (this.getZoom() > this.options.maxZoom) {\r\n\t\t\t\t\treturn this.setZoom(zoom);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method panInsideBounds(bounds: LatLngBounds, options?: Pan options): this\r\n\t\t// Pans the map to the closest view that would lie inside the given bounds (if it's not already), controlling the animation using the options specific, if any.\r\n\t\tpanInsideBounds: function (bounds, options) {\r\n\t\t\tthis._enforcingBounds = true;\r\n\t\t\tvar center = this.getCenter(),\r\n\t\t\t newCenter = this._limitCenter(center, this._zoom, toLatLngBounds(bounds));\r\n\t\r\n\t\t\tif (!center.equals(newCenter)) {\r\n\t\t\t\tthis.panTo(newCenter, options);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._enforcingBounds = false;\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method invalidateSize(options: Zoom/pan options): this\r\n\t\t// Checks if the map container size changed and updates the map if so —\r\n\t\t// call it after you've changed the map size dynamically, also animating\r\n\t\t// pan by default. If `options.pan` is `false`, panning will not occur.\r\n\t\t// If `options.debounceMoveend` is `true`, it will delay `moveend` event so\r\n\t\t// that it doesn't happen often even if the method is called many\r\n\t\t// times in a row.\r\n\t\r\n\t\t// @alternative\r\n\t\t// @method invalidateSize(animate: Boolean): this\r\n\t\t// Checks if the map container size changed and updates the map if so —\r\n\t\t// call it after you've changed the map size dynamically, also animating\r\n\t\t// pan by default.\r\n\t\tinvalidateSize: function (options) {\r\n\t\t\tif (!this._loaded) { return this; }\r\n\t\r\n\t\t\toptions = extend({\r\n\t\t\t\tanimate: false,\r\n\t\t\t\tpan: true\r\n\t\t\t}, options === true ? {animate: true} : options);\r\n\t\r\n\t\t\tvar oldSize = this.getSize();\r\n\t\t\tthis._sizeChanged = true;\r\n\t\t\tthis._lastCenter = null;\r\n\t\r\n\t\t\tvar newSize = this.getSize(),\r\n\t\t\t oldCenter = oldSize.divideBy(2).round(),\r\n\t\t\t newCenter = newSize.divideBy(2).round(),\r\n\t\t\t offset = oldCenter.subtract(newCenter);\r\n\t\r\n\t\t\tif (!offset.x && !offset.y) { return this; }\r\n\t\r\n\t\t\tif (options.animate && options.pan) {\r\n\t\t\t\tthis.panBy(offset);\r\n\t\r\n\t\t\t} else {\r\n\t\t\t\tif (options.pan) {\r\n\t\t\t\t\tthis._rawPanBy(offset);\r\n\t\t\t\t}\r\n\t\r\n\t\t\t\tthis.fire('move');\r\n\t\r\n\t\t\t\tif (options.debounceMoveend) {\r\n\t\t\t\t\tclearTimeout(this._sizeTimer);\r\n\t\t\t\t\tthis._sizeTimer = setTimeout(bind(this.fire, this, 'moveend'), 200);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tthis.fire('moveend');\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\t// @section Map state change events\r\n\t\t\t// @event resize: ResizeEvent\r\n\t\t\t// Fired when the map is resized.\r\n\t\t\treturn this.fire('resize', {\r\n\t\t\t\toldSize: oldSize,\r\n\t\t\t\tnewSize: newSize\r\n\t\t\t});\r\n\t\t},\r\n\t\r\n\t\t// @section Methods for modifying map state\r\n\t\t// @method stop(): this\r\n\t\t// Stops the currently running `panTo` or `flyTo` animation, if any.\r\n\t\tstop: function () {\r\n\t\t\tthis.setZoom(this._limitZoom(this._zoom));\r\n\t\t\tif (!this.options.zoomSnap) {\r\n\t\t\t\tthis.fire('viewreset');\r\n\t\t\t}\r\n\t\t\treturn this._stop();\r\n\t\t},\r\n\t\r\n\t\t// @section Geolocation methods\r\n\t\t// @method locate(options?: Locate options): this\r\n\t\t// Tries to locate the user using the Geolocation API, firing a [`locationfound`](#map-locationfound)\r\n\t\t// event with location data on success or a [`locationerror`](#map-locationerror) event on failure,\r\n\t\t// and optionally sets the map view to the user's location with respect to\r\n\t\t// detection accuracy (or to the world view if geolocation failed).\r\n\t\t// Note that, if your page doesn't use HTTPS, this method will fail in\r\n\t\t// modern browsers ([Chrome 50 and newer](https://sites.google.com/a/chromium.org/dev/Home/chromium-security/deprecating-powerful-features-on-insecure-origins))\r\n\t\t// See `Locate options` for more details.\r\n\t\tlocate: function (options) {\r\n\t\r\n\t\t\toptions = this._locateOptions = extend({\r\n\t\t\t\ttimeout: 10000,\r\n\t\t\t\twatch: false\r\n\t\t\t\t// setView: false\r\n\t\t\t\t// maxZoom: \r\n\t\t\t\t// maximumAge: 0\r\n\t\t\t\t// enableHighAccuracy: false\r\n\t\t\t}, options);\r\n\t\r\n\t\t\tif (!('geolocation' in navigator)) {\r\n\t\t\t\tthis._handleGeolocationError({\r\n\t\t\t\t\tcode: 0,\r\n\t\t\t\t\tmessage: 'Geolocation not supported.'\r\n\t\t\t\t});\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\r\n\t\t\tvar onResponse = bind(this._handleGeolocationResponse, this),\r\n\t\t\t onError = bind(this._handleGeolocationError, this);\r\n\t\r\n\t\t\tif (options.watch) {\r\n\t\t\t\tthis._locationWatchId =\r\n\t\t\t\t navigator.geolocation.watchPosition(onResponse, onError, options);\r\n\t\t\t} else {\r\n\t\t\t\tnavigator.geolocation.getCurrentPosition(onResponse, onError, options);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method stopLocate(): this\r\n\t\t// Stops watching location previously initiated by `map.locate({watch: true})`\r\n\t\t// and aborts resetting the map view if map.locate was called with\r\n\t\t// `{setView: true}`.\r\n\t\tstopLocate: function () {\r\n\t\t\tif (navigator.geolocation && navigator.geolocation.clearWatch) {\r\n\t\t\t\tnavigator.geolocation.clearWatch(this._locationWatchId);\r\n\t\t\t}\r\n\t\t\tif (this._locateOptions) {\r\n\t\t\t\tthis._locateOptions.setView = false;\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_handleGeolocationError: function (error) {\r\n\t\t\tvar c = error.code,\r\n\t\t\t message = error.message ||\r\n\t\t\t (c === 1 ? 'permission denied' :\r\n\t\t\t (c === 2 ? 'position unavailable' : 'timeout'));\r\n\t\r\n\t\t\tif (this._locateOptions.setView && !this._loaded) {\r\n\t\t\t\tthis.fitWorld();\r\n\t\t\t}\r\n\t\r\n\t\t\t// @section Location events\r\n\t\t\t// @event locationerror: ErrorEvent\r\n\t\t\t// Fired when geolocation (using the [`locate`](#map-locate) method) failed.\r\n\t\t\tthis.fire('locationerror', {\r\n\t\t\t\tcode: c,\r\n\t\t\t\tmessage: 'Geolocation error: ' + message + '.'\r\n\t\t\t});\r\n\t\t},\r\n\t\r\n\t\t_handleGeolocationResponse: function (pos) {\r\n\t\t\tvar lat = pos.coords.latitude,\r\n\t\t\t lng = pos.coords.longitude,\r\n\t\t\t latlng = new LatLng(lat, lng),\r\n\t\t\t bounds = latlng.toBounds(pos.coords.accuracy),\r\n\t\t\t options = this._locateOptions;\r\n\t\r\n\t\t\tif (options.setView) {\r\n\t\t\t\tvar zoom = this.getBoundsZoom(bounds);\r\n\t\t\t\tthis.setView(latlng, options.maxZoom ? Math.min(zoom, options.maxZoom) : zoom);\r\n\t\t\t}\r\n\t\r\n\t\t\tvar data = {\r\n\t\t\t\tlatlng: latlng,\r\n\t\t\t\tbounds: bounds,\r\n\t\t\t\ttimestamp: pos.timestamp\r\n\t\t\t};\r\n\t\r\n\t\t\tfor (var i in pos.coords) {\r\n\t\t\t\tif (typeof pos.coords[i] === 'number') {\r\n\t\t\t\t\tdata[i] = pos.coords[i];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\t// @event locationfound: LocationEvent\r\n\t\t\t// Fired when geolocation (using the [`locate`](#map-locate) method)\r\n\t\t\t// went successfully.\r\n\t\t\tthis.fire('locationfound', data);\r\n\t\t},\r\n\t\r\n\t\t// TODO Appropriate docs section?\r\n\t\t// @section Other Methods\r\n\t\t// @method addHandler(name: String, HandlerClass: Function): this\r\n\t\t// Adds a new `Handler` to the map, given its name and constructor function.\r\n\t\taddHandler: function (name, HandlerClass) {\r\n\t\t\tif (!HandlerClass) { return this; }\r\n\t\r\n\t\t\tvar handler = this[name] = new HandlerClass(this);\r\n\t\r\n\t\t\tthis._handlers.push(handler);\r\n\t\r\n\t\t\tif (this.options[name]) {\r\n\t\t\t\thandler.enable();\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method remove(): this\r\n\t\t// Destroys the map and clears all related event listeners.\r\n\t\tremove: function () {\r\n\t\r\n\t\t\tthis._initEvents(true);\r\n\t\r\n\t\t\tif (this._containerId !== this._container._leaflet_id) {\r\n\t\t\t\tthrow new Error('Map container is being reused by another instance');\r\n\t\t\t}\r\n\t\r\n\t\t\ttry {\r\n\t\t\t\t// throws error in IE6-8\r\n\t\t\t\tdelete this._container._leaflet_id;\r\n\t\t\t\tdelete this._containerId;\r\n\t\t\t} catch (e) {\r\n\t\t\t\t/*eslint-disable */\r\n\t\t\t\tthis._container._leaflet_id = undefined;\r\n\t\t\t\t/* eslint-enable */\r\n\t\t\t\tthis._containerId = undefined;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (this._locationWatchId !== undefined) {\r\n\t\t\t\tthis.stopLocate();\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._stop();\r\n\t\r\n\t\t\tremove(this._mapPane);\r\n\t\r\n\t\t\tif (this._clearControlPos) {\r\n\t\t\t\tthis._clearControlPos();\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._clearHandlers();\r\n\t\r\n\t\t\tif (this._loaded) {\r\n\t\t\t\t// @section Map state change events\r\n\t\t\t\t// @event unload: Event\r\n\t\t\t\t// Fired when the map is destroyed with [remove](#map-remove) method.\r\n\t\t\t\tthis.fire('unload');\r\n\t\t\t}\r\n\t\r\n\t\t\tvar i;\r\n\t\t\tfor (i in this._layers) {\r\n\t\t\t\tthis._layers[i].remove();\r\n\t\t\t}\r\n\t\t\tfor (i in this._panes) {\r\n\t\t\t\tremove(this._panes[i]);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._layers = [];\r\n\t\t\tthis._panes = [];\r\n\t\t\tdelete this._mapPane;\r\n\t\t\tdelete this._renderer;\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @section Other Methods\r\n\t\t// @method createPane(name: String, container?: HTMLElement): HTMLElement\r\n\t\t// Creates a new [map pane](#map-pane) with the given name if it doesn't exist already,\r\n\t\t// then returns it. The pane is created as a child of `container`, or\r\n\t\t// as a child of the main map pane if not set.\r\n\t\tcreatePane: function (name, container) {\r\n\t\t\tvar className = 'leaflet-pane' + (name ? ' leaflet-' + name.replace('Pane', '') + '-pane' : ''),\r\n\t\t\t pane = create$1('div', className, container || this._mapPane);\r\n\t\r\n\t\t\tif (name) {\r\n\t\t\t\tthis._panes[name] = pane;\r\n\t\t\t}\r\n\t\t\treturn pane;\r\n\t\t},\r\n\t\r\n\t\t// @section Methods for Getting Map State\r\n\t\r\n\t\t// @method getCenter(): LatLng\r\n\t\t// Returns the geographical center of the map view\r\n\t\tgetCenter: function () {\r\n\t\t\tthis._checkIfLoaded();\r\n\t\r\n\t\t\tif (this._lastCenter && !this._moved()) {\r\n\t\t\t\treturn this._lastCenter;\r\n\t\t\t}\r\n\t\t\treturn this.layerPointToLatLng(this._getCenterLayerPoint());\r\n\t\t},\r\n\t\r\n\t\t// @method getZoom(): Number\r\n\t\t// Returns the current zoom level of the map view\r\n\t\tgetZoom: function () {\r\n\t\t\treturn this._zoom;\r\n\t\t},\r\n\t\r\n\t\t// @method getBounds(): LatLngBounds\r\n\t\t// Returns the geographical bounds visible in the current map view\r\n\t\tgetBounds: function () {\r\n\t\t\tvar bounds = this.getPixelBounds(),\r\n\t\t\t sw = this.unproject(bounds.getBottomLeft()),\r\n\t\t\t ne = this.unproject(bounds.getTopRight());\r\n\t\r\n\t\t\treturn new LatLngBounds(sw, ne);\r\n\t\t},\r\n\t\r\n\t\t// @method getMinZoom(): Number\r\n\t\t// Returns the minimum zoom level of the map (if set in the `minZoom` option of the map or of any layers), or `0` by default.\r\n\t\tgetMinZoom: function () {\r\n\t\t\treturn this.options.minZoom === undefined ? this._layersMinZoom || 0 : this.options.minZoom;\r\n\t\t},\r\n\t\r\n\t\t// @method getMaxZoom(): Number\r\n\t\t// Returns the maximum zoom level of the map (if set in the `maxZoom` option of the map or of any layers).\r\n\t\tgetMaxZoom: function () {\r\n\t\t\treturn this.options.maxZoom === undefined ?\r\n\t\t\t\t(this._layersMaxZoom === undefined ? Infinity : this._layersMaxZoom) :\r\n\t\t\t\tthis.options.maxZoom;\r\n\t\t},\r\n\t\r\n\t\t// @method getBoundsZoom(bounds: LatLngBounds, inside?: Boolean): Number\r\n\t\t// Returns the maximum zoom level on which the given bounds fit to the map\r\n\t\t// view in its entirety. If `inside` (optional) is set to `true`, the method\r\n\t\t// instead returns the minimum zoom level on which the map view fits into\r\n\t\t// the given bounds in its entirety.\r\n\t\tgetBoundsZoom: function (bounds, inside, padding) { // (LatLngBounds[, Boolean, Point]) -> Number\r\n\t\t\tbounds = toLatLngBounds(bounds);\r\n\t\t\tpadding = toPoint(padding || [0, 0]);\r\n\t\r\n\t\t\tvar zoom = this.getZoom() || 0,\r\n\t\t\t min = this.getMinZoom(),\r\n\t\t\t max = this.getMaxZoom(),\r\n\t\t\t nw = bounds.getNorthWest(),\r\n\t\t\t se = bounds.getSouthEast(),\r\n\t\t\t size = this.getSize().subtract(padding),\r\n\t\t\t boundsSize = toBounds(this.project(se, zoom), this.project(nw, zoom)).getSize(),\r\n\t\t\t snap = any3d ? this.options.zoomSnap : 1,\r\n\t\t\t scalex = size.x / boundsSize.x,\r\n\t\t\t scaley = size.y / boundsSize.y,\r\n\t\t\t scale = inside ? Math.max(scalex, scaley) : Math.min(scalex, scaley);\r\n\t\r\n\t\t\tzoom = this.getScaleZoom(scale, zoom);\r\n\t\r\n\t\t\tif (snap) {\r\n\t\t\t\tzoom = Math.round(zoom / (snap / 100)) * (snap / 100); // don't jump if within 1% of a snap level\r\n\t\t\t\tzoom = inside ? Math.ceil(zoom / snap) * snap : Math.floor(zoom / snap) * snap;\r\n\t\t\t}\r\n\t\r\n\t\t\treturn Math.max(min, Math.min(max, zoom));\r\n\t\t},\r\n\t\r\n\t\t// @method getSize(): Point\r\n\t\t// Returns the current size of the map container (in pixels).\r\n\t\tgetSize: function () {\r\n\t\t\tif (!this._size || this._sizeChanged) {\r\n\t\t\t\tthis._size = new Point(\r\n\t\t\t\t\tthis._container.clientWidth || 0,\r\n\t\t\t\t\tthis._container.clientHeight || 0);\r\n\t\r\n\t\t\t\tthis._sizeChanged = false;\r\n\t\t\t}\r\n\t\t\treturn this._size.clone();\r\n\t\t},\r\n\t\r\n\t\t// @method getPixelBounds(): Bounds\r\n\t\t// Returns the bounds of the current map view in projected pixel\r\n\t\t// coordinates (sometimes useful in layer and overlay implementations).\r\n\t\tgetPixelBounds: function (center, zoom) {\r\n\t\t\tvar topLeftPoint = this._getTopLeftPoint(center, zoom);\r\n\t\t\treturn new Bounds(topLeftPoint, topLeftPoint.add(this.getSize()));\r\n\t\t},\r\n\t\r\n\t\t// TODO: Check semantics - isn't the pixel origin the 0,0 coord relative to\r\n\t\t// the map pane? \"left point of the map layer\" can be confusing, specially\r\n\t\t// since there can be negative offsets.\r\n\t\t// @method getPixelOrigin(): Point\r\n\t\t// Returns the projected pixel coordinates of the top left point of\r\n\t\t// the map layer (useful in custom layer and overlay implementations).\r\n\t\tgetPixelOrigin: function () {\r\n\t\t\tthis._checkIfLoaded();\r\n\t\t\treturn this._pixelOrigin;\r\n\t\t},\r\n\t\r\n\t\t// @method getPixelWorldBounds(zoom?: Number): Bounds\r\n\t\t// Returns the world's bounds in pixel coordinates for zoom level `zoom`.\r\n\t\t// If `zoom` is omitted, the map's current zoom level is used.\r\n\t\tgetPixelWorldBounds: function (zoom) {\r\n\t\t\treturn this.options.crs.getProjectedBounds(zoom === undefined ? this.getZoom() : zoom);\r\n\t\t},\r\n\t\r\n\t\t// @section Other Methods\r\n\t\r\n\t\t// @method getPane(pane: String|HTMLElement): HTMLElement\r\n\t\t// Returns a [map pane](#map-pane), given its name or its HTML element (its identity).\r\n\t\tgetPane: function (pane) {\r\n\t\t\treturn typeof pane === 'string' ? this._panes[pane] : pane;\r\n\t\t},\r\n\t\r\n\t\t// @method getPanes(): Object\r\n\t\t// Returns a plain object containing the names of all [panes](#map-pane) as keys and\r\n\t\t// the panes as values.\r\n\t\tgetPanes: function () {\r\n\t\t\treturn this._panes;\r\n\t\t},\r\n\t\r\n\t\t// @method getContainer: HTMLElement\r\n\t\t// Returns the HTML element that contains the map.\r\n\t\tgetContainer: function () {\r\n\t\t\treturn this._container;\r\n\t\t},\r\n\t\r\n\t\r\n\t\t// @section Conversion Methods\r\n\t\r\n\t\t// @method getZoomScale(toZoom: Number, fromZoom: Number): Number\r\n\t\t// Returns the scale factor to be applied to a map transition from zoom level\r\n\t\t// `fromZoom` to `toZoom`. Used internally to help with zoom animations.\r\n\t\tgetZoomScale: function (toZoom, fromZoom) {\r\n\t\t\t// TODO replace with universal implementation after refactoring projections\r\n\t\t\tvar crs = this.options.crs;\r\n\t\t\tfromZoom = fromZoom === undefined ? this._zoom : fromZoom;\r\n\t\t\treturn crs.scale(toZoom) / crs.scale(fromZoom);\r\n\t\t},\r\n\t\r\n\t\t// @method getScaleZoom(scale: Number, fromZoom: Number): Number\r\n\t\t// Returns the zoom level that the map would end up at, if it is at `fromZoom`\r\n\t\t// level and everything is scaled by a factor of `scale`. Inverse of\r\n\t\t// [`getZoomScale`](#map-getZoomScale).\r\n\t\tgetScaleZoom: function (scale, fromZoom) {\r\n\t\t\tvar crs = this.options.crs;\r\n\t\t\tfromZoom = fromZoom === undefined ? this._zoom : fromZoom;\r\n\t\t\tvar zoom = crs.zoom(scale * crs.scale(fromZoom));\r\n\t\t\treturn isNaN(zoom) ? Infinity : zoom;\r\n\t\t},\r\n\t\r\n\t\t// @method project(latlng: LatLng, zoom: Number): Point\r\n\t\t// Projects a geographical coordinate `LatLng` according to the projection\r\n\t\t// of the map's CRS, then scales it according to `zoom` and the CRS's\r\n\t\t// `Transformation`. The result is pixel coordinate relative to\r\n\t\t// the CRS origin.\r\n\t\tproject: function (latlng, zoom) {\r\n\t\t\tzoom = zoom === undefined ? this._zoom : zoom;\r\n\t\t\treturn this.options.crs.latLngToPoint(toLatLng(latlng), zoom);\r\n\t\t},\r\n\t\r\n\t\t// @method unproject(point: Point, zoom: Number): LatLng\r\n\t\t// Inverse of [`project`](#map-project).\r\n\t\tunproject: function (point, zoom) {\r\n\t\t\tzoom = zoom === undefined ? this._zoom : zoom;\r\n\t\t\treturn this.options.crs.pointToLatLng(toPoint(point), zoom);\r\n\t\t},\r\n\t\r\n\t\t// @method layerPointToLatLng(point: Point): LatLng\r\n\t\t// Given a pixel coordinate relative to the [origin pixel](#map-getpixelorigin),\r\n\t\t// returns the corresponding geographical coordinate (for the current zoom level).\r\n\t\tlayerPointToLatLng: function (point) {\r\n\t\t\tvar projectedPoint = toPoint(point).add(this.getPixelOrigin());\r\n\t\t\treturn this.unproject(projectedPoint);\r\n\t\t},\r\n\t\r\n\t\t// @method latLngToLayerPoint(latlng: LatLng): Point\r\n\t\t// Given a geographical coordinate, returns the corresponding pixel coordinate\r\n\t\t// relative to the [origin pixel](#map-getpixelorigin).\r\n\t\tlatLngToLayerPoint: function (latlng) {\r\n\t\t\tvar projectedPoint = this.project(toLatLng(latlng))._round();\r\n\t\t\treturn projectedPoint._subtract(this.getPixelOrigin());\r\n\t\t},\r\n\t\r\n\t\t// @method wrapLatLng(latlng: LatLng): LatLng\r\n\t\t// Returns a `LatLng` where `lat` and `lng` has been wrapped according to the\r\n\t\t// map's CRS's `wrapLat` and `wrapLng` properties, if they are outside the\r\n\t\t// CRS's bounds.\r\n\t\t// By default this means longitude is wrapped around the dateline so its\r\n\t\t// value is between -180 and +180 degrees.\r\n\t\twrapLatLng: function (latlng) {\r\n\t\t\treturn this.options.crs.wrapLatLng(toLatLng(latlng));\r\n\t\t},\r\n\t\r\n\t\t// @method wrapLatLngBounds(bounds: LatLngBounds): LatLngBounds\r\n\t\t// Returns a `LatLngBounds` with the same size as the given one, ensuring that\r\n\t\t// its center is within the CRS's bounds.\r\n\t\t// By default this means the center longitude is wrapped around the dateline so its\r\n\t\t// value is between -180 and +180 degrees, and the majority of the bounds\r\n\t\t// overlaps the CRS's bounds.\r\n\t\twrapLatLngBounds: function (latlng) {\r\n\t\t\treturn this.options.crs.wrapLatLngBounds(toLatLngBounds(latlng));\r\n\t\t},\r\n\t\r\n\t\t// @method distance(latlng1: LatLng, latlng2: LatLng): Number\r\n\t\t// Returns the distance between two geographical coordinates according to\r\n\t\t// the map's CRS. By default this measures distance in meters.\r\n\t\tdistance: function (latlng1, latlng2) {\r\n\t\t\treturn this.options.crs.distance(toLatLng(latlng1), toLatLng(latlng2));\r\n\t\t},\r\n\t\r\n\t\t// @method containerPointToLayerPoint(point: Point): Point\r\n\t\t// Given a pixel coordinate relative to the map container, returns the corresponding\r\n\t\t// pixel coordinate relative to the [origin pixel](#map-getpixelorigin).\r\n\t\tcontainerPointToLayerPoint: function (point) { // (Point)\r\n\t\t\treturn toPoint(point).subtract(this._getMapPanePos());\r\n\t\t},\r\n\t\r\n\t\t// @method layerPointToContainerPoint(point: Point): Point\r\n\t\t// Given a pixel coordinate relative to the [origin pixel](#map-getpixelorigin),\r\n\t\t// returns the corresponding pixel coordinate relative to the map container.\r\n\t\tlayerPointToContainerPoint: function (point) { // (Point)\r\n\t\t\treturn toPoint(point).add(this._getMapPanePos());\r\n\t\t},\r\n\t\r\n\t\t// @method containerPointToLatLng(point: Point): LatLng\r\n\t\t// Given a pixel coordinate relative to the map container, returns\r\n\t\t// the corresponding geographical coordinate (for the current zoom level).\r\n\t\tcontainerPointToLatLng: function (point) {\r\n\t\t\tvar layerPoint = this.containerPointToLayerPoint(toPoint(point));\r\n\t\t\treturn this.layerPointToLatLng(layerPoint);\r\n\t\t},\r\n\t\r\n\t\t// @method latLngToContainerPoint(latlng: LatLng): Point\r\n\t\t// Given a geographical coordinate, returns the corresponding pixel coordinate\r\n\t\t// relative to the map container.\r\n\t\tlatLngToContainerPoint: function (latlng) {\r\n\t\t\treturn this.layerPointToContainerPoint(this.latLngToLayerPoint(toLatLng(latlng)));\r\n\t\t},\r\n\t\r\n\t\t// @method mouseEventToContainerPoint(ev: MouseEvent): Point\r\n\t\t// Given a MouseEvent object, returns the pixel coordinate relative to the\r\n\t\t// map container where the event took place.\r\n\t\tmouseEventToContainerPoint: function (e) {\r\n\t\t\treturn getMousePosition(e, this._container);\r\n\t\t},\r\n\t\r\n\t\t// @method mouseEventToLayerPoint(ev: MouseEvent): Point\r\n\t\t// Given a MouseEvent object, returns the pixel coordinate relative to\r\n\t\t// the [origin pixel](#map-getpixelorigin) where the event took place.\r\n\t\tmouseEventToLayerPoint: function (e) {\r\n\t\t\treturn this.containerPointToLayerPoint(this.mouseEventToContainerPoint(e));\r\n\t\t},\r\n\t\r\n\t\t// @method mouseEventToLatLng(ev: MouseEvent): LatLng\r\n\t\t// Given a MouseEvent object, returns geographical coordinate where the\r\n\t\t// event took place.\r\n\t\tmouseEventToLatLng: function (e) { // (MouseEvent)\r\n\t\t\treturn this.layerPointToLatLng(this.mouseEventToLayerPoint(e));\r\n\t\t},\r\n\t\r\n\t\r\n\t\t// map initialization methods\r\n\t\r\n\t\t_initContainer: function (id) {\r\n\t\t\tvar container = this._container = get(id);\r\n\t\r\n\t\t\tif (!container) {\r\n\t\t\t\tthrow new Error('Map container not found.');\r\n\t\t\t} else if (container._leaflet_id) {\r\n\t\t\t\tthrow new Error('Map container is already initialized.');\r\n\t\t\t}\r\n\t\r\n\t\t\ton(container, 'scroll', this._onScroll, this);\r\n\t\t\tthis._containerId = stamp(container);\r\n\t\t},\r\n\t\r\n\t\t_initLayout: function () {\r\n\t\t\tvar container = this._container;\r\n\t\r\n\t\t\tthis._fadeAnimated = this.options.fadeAnimation && any3d;\r\n\t\r\n\t\t\taddClass(container, 'leaflet-container' +\r\n\t\t\t\t(touch ? ' leaflet-touch' : '') +\r\n\t\t\t\t(retina ? ' leaflet-retina' : '') +\r\n\t\t\t\t(ielt9 ? ' leaflet-oldie' : '') +\r\n\t\t\t\t(safari ? ' leaflet-safari' : '') +\r\n\t\t\t\t(this._fadeAnimated ? ' leaflet-fade-anim' : ''));\r\n\t\r\n\t\t\tvar position = getStyle(container, 'position');\r\n\t\r\n\t\t\tif (position !== 'absolute' && position !== 'relative' && position !== 'fixed') {\r\n\t\t\t\tcontainer.style.position = 'relative';\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._initPanes();\r\n\t\r\n\t\t\tif (this._initControlPos) {\r\n\t\t\t\tthis._initControlPos();\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_initPanes: function () {\r\n\t\t\tvar panes = this._panes = {};\r\n\t\t\tthis._paneRenderers = {};\r\n\t\r\n\t\t\t// @section\r\n\t\t\t//\r\n\t\t\t// Panes are DOM elements used to control the ordering of layers on the map. You\r\n\t\t\t// can access panes with [`map.getPane`](#map-getpane) or\r\n\t\t\t// [`map.getPanes`](#map-getpanes) methods. New panes can be created with the\r\n\t\t\t// [`map.createPane`](#map-createpane) method.\r\n\t\t\t//\r\n\t\t\t// Every map has the following default panes that differ only in zIndex.\r\n\t\t\t//\r\n\t\t\t// @pane mapPane: HTMLElement = 'auto'\r\n\t\t\t// Pane that contains all other map panes\r\n\t\r\n\t\t\tthis._mapPane = this.createPane('mapPane', this._container);\r\n\t\t\tsetPosition(this._mapPane, new Point(0, 0));\r\n\t\r\n\t\t\t// @pane tilePane: HTMLElement = 200\r\n\t\t\t// Pane for `GridLayer`s and `TileLayer`s\r\n\t\t\tthis.createPane('tilePane');\r\n\t\t\t// @pane overlayPane: HTMLElement = 400\r\n\t\t\t// Pane for vectors (`Path`s, like `Polyline`s and `Polygon`s), `ImageOverlay`s and `VideoOverlay`s\r\n\t\t\tthis.createPane('shadowPane');\r\n\t\t\t// @pane shadowPane: HTMLElement = 500\r\n\t\t\t// Pane for overlay shadows (e.g. `Marker` shadows)\r\n\t\t\tthis.createPane('overlayPane');\r\n\t\t\t// @pane markerPane: HTMLElement = 600\r\n\t\t\t// Pane for `Icon`s of `Marker`s\r\n\t\t\tthis.createPane('markerPane');\r\n\t\t\t// @pane tooltipPane: HTMLElement = 650\r\n\t\t\t// Pane for `Tooltip`s.\r\n\t\t\tthis.createPane('tooltipPane');\r\n\t\t\t// @pane popupPane: HTMLElement = 700\r\n\t\t\t// Pane for `Popup`s.\r\n\t\t\tthis.createPane('popupPane');\r\n\t\r\n\t\t\tif (!this.options.markerZoomAnimation) {\r\n\t\t\t\taddClass(panes.markerPane, 'leaflet-zoom-hide');\r\n\t\t\t\taddClass(panes.shadowPane, 'leaflet-zoom-hide');\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\r\n\t\t// private methods that modify map state\r\n\t\r\n\t\t// @section Map state change events\r\n\t\t_resetView: function (center, zoom) {\r\n\t\t\tsetPosition(this._mapPane, new Point(0, 0));\r\n\t\r\n\t\t\tvar loading = !this._loaded;\r\n\t\t\tthis._loaded = true;\r\n\t\t\tzoom = this._limitZoom(zoom);\r\n\t\r\n\t\t\tthis.fire('viewprereset');\r\n\t\r\n\t\t\tvar zoomChanged = this._zoom !== zoom;\r\n\t\t\tthis\r\n\t\t\t\t._moveStart(zoomChanged, false)\r\n\t\t\t\t._move(center, zoom)\r\n\t\t\t\t._moveEnd(zoomChanged);\r\n\t\r\n\t\t\t// @event viewreset: Event\r\n\t\t\t// Fired when the map needs to redraw its content (this usually happens\r\n\t\t\t// on map zoom or load). Very useful for creating custom overlays.\r\n\t\t\tthis.fire('viewreset');\r\n\t\r\n\t\t\t// @event load: Event\r\n\t\t\t// Fired when the map is initialized (when its center and zoom are set\r\n\t\t\t// for the first time).\r\n\t\t\tif (loading) {\r\n\t\t\t\tthis.fire('load');\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_moveStart: function (zoomChanged, noMoveStart) {\r\n\t\t\t// @event zoomstart: Event\r\n\t\t\t// Fired when the map zoom is about to change (e.g. before zoom animation).\r\n\t\t\t// @event movestart: Event\r\n\t\t\t// Fired when the view of the map starts changing (e.g. user starts dragging the map).\r\n\t\t\tif (zoomChanged) {\r\n\t\t\t\tthis.fire('zoomstart');\r\n\t\t\t}\r\n\t\t\tif (!noMoveStart) {\r\n\t\t\t\tthis.fire('movestart');\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_move: function (center, zoom, data) {\r\n\t\t\tif (zoom === undefined) {\r\n\t\t\t\tzoom = this._zoom;\r\n\t\t\t}\r\n\t\t\tvar zoomChanged = this._zoom !== zoom;\r\n\t\r\n\t\t\tthis._zoom = zoom;\r\n\t\t\tthis._lastCenter = center;\r\n\t\t\tthis._pixelOrigin = this._getNewPixelOrigin(center);\r\n\t\r\n\t\t\t// @event zoom: Event\r\n\t\t\t// Fired repeatedly during any change in zoom level, including zoom\r\n\t\t\t// and fly animations.\r\n\t\t\tif (zoomChanged || (data && data.pinch)) {\t// Always fire 'zoom' if pinching because #3530\r\n\t\t\t\tthis.fire('zoom', data);\r\n\t\t\t}\r\n\t\r\n\t\t\t// @event move: Event\r\n\t\t\t// Fired repeatedly during any movement of the map, including pan and\r\n\t\t\t// fly animations.\r\n\t\t\treturn this.fire('move', data);\r\n\t\t},\r\n\t\r\n\t\t_moveEnd: function (zoomChanged) {\r\n\t\t\t// @event zoomend: Event\r\n\t\t\t// Fired when the map has changed, after any animations.\r\n\t\t\tif (zoomChanged) {\r\n\t\t\t\tthis.fire('zoomend');\r\n\t\t\t}\r\n\t\r\n\t\t\t// @event moveend: Event\r\n\t\t\t// Fired when the center of the map stops changing (e.g. user stopped\r\n\t\t\t// dragging the map).\r\n\t\t\treturn this.fire('moveend');\r\n\t\t},\r\n\t\r\n\t\t_stop: function () {\r\n\t\t\tcancelAnimFrame(this._flyToFrame);\r\n\t\t\tif (this._panAnim) {\r\n\t\t\t\tthis._panAnim.stop();\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_rawPanBy: function (offset) {\r\n\t\t\tsetPosition(this._mapPane, this._getMapPanePos().subtract(offset));\r\n\t\t},\r\n\t\r\n\t\t_getZoomSpan: function () {\r\n\t\t\treturn this.getMaxZoom() - this.getMinZoom();\r\n\t\t},\r\n\t\r\n\t\t_panInsideMaxBounds: function () {\r\n\t\t\tif (!this._enforcingBounds) {\r\n\t\t\t\tthis.panInsideBounds(this.options.maxBounds);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_checkIfLoaded: function () {\r\n\t\t\tif (!this._loaded) {\r\n\t\t\t\tthrow new Error('Set map center and zoom first.');\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// DOM event handling\r\n\t\r\n\t\t// @section Interaction events\r\n\t\t_initEvents: function (remove$$1) {\r\n\t\t\tthis._targets = {};\r\n\t\t\tthis._targets[stamp(this._container)] = this;\r\n\t\r\n\t\t\tvar onOff = remove$$1 ? off : on;\r\n\t\r\n\t\t\t// @event click: MouseEvent\r\n\t\t\t// Fired when the user clicks (or taps) the map.\r\n\t\t\t// @event dblclick: MouseEvent\r\n\t\t\t// Fired when the user double-clicks (or double-taps) the map.\r\n\t\t\t// @event mousedown: MouseEvent\r\n\t\t\t// Fired when the user pushes the mouse button on the map.\r\n\t\t\t// @event mouseup: MouseEvent\r\n\t\t\t// Fired when the user releases the mouse button on the map.\r\n\t\t\t// @event mouseover: MouseEvent\r\n\t\t\t// Fired when the mouse enters the map.\r\n\t\t\t// @event mouseout: MouseEvent\r\n\t\t\t// Fired when the mouse leaves the map.\r\n\t\t\t// @event mousemove: MouseEvent\r\n\t\t\t// Fired while the mouse moves over the map.\r\n\t\t\t// @event contextmenu: MouseEvent\r\n\t\t\t// Fired when the user pushes the right mouse button on the map, prevents\r\n\t\t\t// default browser context menu from showing if there are listeners on\r\n\t\t\t// this event. Also fired on mobile when the user holds a single touch\r\n\t\t\t// for a second (also called long press).\r\n\t\t\t// @event keypress: KeyboardEvent\r\n\t\t\t// Fired when the user presses a key from the keyboard while the map is focused.\r\n\t\t\tonOff(this._container, 'click dblclick mousedown mouseup ' +\r\n\t\t\t\t'mouseover mouseout mousemove contextmenu keypress', this._handleDOMEvent, this);\r\n\t\r\n\t\t\tif (this.options.trackResize) {\r\n\t\t\t\tonOff(window, 'resize', this._onResize, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tif (any3d && this.options.transform3DLimit) {\r\n\t\t\t\t(remove$$1 ? this.off : this.on).call(this, 'moveend', this._onMoveEnd);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_onResize: function () {\r\n\t\t\tcancelAnimFrame(this._resizeRequest);\r\n\t\t\tthis._resizeRequest = requestAnimFrame(\r\n\t\t\t function () { this.invalidateSize({debounceMoveend: true}); }, this);\r\n\t\t},\r\n\t\r\n\t\t_onScroll: function () {\r\n\t\t\tthis._container.scrollTop = 0;\r\n\t\t\tthis._container.scrollLeft = 0;\r\n\t\t},\r\n\t\r\n\t\t_onMoveEnd: function () {\r\n\t\t\tvar pos = this._getMapPanePos();\r\n\t\t\tif (Math.max(Math.abs(pos.x), Math.abs(pos.y)) >= this.options.transform3DLimit) {\r\n\t\t\t\t// https://bugzilla.mozilla.org/show_bug.cgi?id=1203873 but Webkit also have\r\n\t\t\t\t// a pixel offset on very high values, see: http://jsfiddle.net/dg6r5hhb/\r\n\t\t\t\tthis._resetView(this.getCenter(), this.getZoom());\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_findEventTargets: function (e, type) {\r\n\t\t\tvar targets = [],\r\n\t\t\t target,\r\n\t\t\t isHover = type === 'mouseout' || type === 'mouseover',\r\n\t\t\t src = e.target || e.srcElement,\r\n\t\t\t dragging = false;\r\n\t\r\n\t\t\twhile (src) {\r\n\t\t\t\ttarget = this._targets[stamp(src)];\r\n\t\t\t\tif (target && (type === 'click' || type === 'preclick') && !e._simulated && this._draggableMoved(target)) {\r\n\t\t\t\t\t// Prevent firing click after you just dragged an object.\r\n\t\t\t\t\tdragging = true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t\tif (target && target.listens(type, true)) {\r\n\t\t\t\t\tif (isHover && !isExternalTarget(src, e)) { break; }\r\n\t\t\t\t\ttargets.push(target);\r\n\t\t\t\t\tif (isHover) { break; }\r\n\t\t\t\t}\r\n\t\t\t\tif (src === this._container) { break; }\r\n\t\t\t\tsrc = src.parentNode;\r\n\t\t\t}\r\n\t\t\tif (!targets.length && !dragging && !isHover && isExternalTarget(src, e)) {\r\n\t\t\t\ttargets = [this];\r\n\t\t\t}\r\n\t\t\treturn targets;\r\n\t\t},\r\n\t\r\n\t\t_handleDOMEvent: function (e) {\r\n\t\t\tif (!this._loaded || skipped(e)) { return; }\r\n\t\r\n\t\t\tvar type = e.type;\r\n\t\r\n\t\t\tif (type === 'mousedown' || type === 'keypress') {\r\n\t\t\t\t// prevents outline when clicking on keyboard-focusable element\r\n\t\t\t\tpreventOutline(e.target || e.srcElement);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._fireDOMEvent(e, type);\r\n\t\t},\r\n\t\r\n\t\t_mouseEvents: ['click', 'dblclick', 'mouseover', 'mouseout', 'contextmenu'],\r\n\t\r\n\t\t_fireDOMEvent: function (e, type, targets) {\r\n\t\r\n\t\t\tif (e.type === 'click') {\r\n\t\t\t\t// Fire a synthetic 'preclick' event which propagates up (mainly for closing popups).\r\n\t\t\t\t// @event preclick: MouseEvent\r\n\t\t\t\t// Fired before mouse click on the map (sometimes useful when you\r\n\t\t\t\t// want something to happen on click before any existing click\r\n\t\t\t\t// handlers start running).\r\n\t\t\t\tvar synth = extend({}, e);\r\n\t\t\t\tsynth.type = 'preclick';\r\n\t\t\t\tthis._fireDOMEvent(synth, synth.type, targets);\r\n\t\t\t}\r\n\t\r\n\t\t\tif (e._stopped) { return; }\r\n\t\r\n\t\t\t// Find the layer the event is propagating from and its parents.\r\n\t\t\ttargets = (targets || []).concat(this._findEventTargets(e, type));\r\n\t\r\n\t\t\tif (!targets.length) { return; }\r\n\t\r\n\t\t\tvar target = targets[0];\r\n\t\t\tif (type === 'contextmenu' && target.listens(type, true)) {\r\n\t\t\t\tpreventDefault(e);\r\n\t\t\t}\r\n\t\r\n\t\t\tvar data = {\r\n\t\t\t\toriginalEvent: e\r\n\t\t\t};\r\n\t\r\n\t\t\tif (e.type !== 'keypress') {\r\n\t\t\t\tvar isMarker = target.getLatLng && (!target._radius || target._radius <= 10);\r\n\t\t\t\tdata.containerPoint = isMarker ?\r\n\t\t\t\t\tthis.latLngToContainerPoint(target.getLatLng()) : this.mouseEventToContainerPoint(e);\r\n\t\t\t\tdata.layerPoint = this.containerPointToLayerPoint(data.containerPoint);\r\n\t\t\t\tdata.latlng = isMarker ? target.getLatLng() : this.layerPointToLatLng(data.layerPoint);\r\n\t\t\t}\r\n\t\r\n\t\t\tfor (var i = 0; i < targets.length; i++) {\r\n\t\t\t\ttargets[i].fire(type, data, true);\r\n\t\t\t\tif (data.originalEvent._stopped ||\r\n\t\t\t\t\t(targets[i].options.bubblingMouseEvents === false && indexOf(this._mouseEvents, type) !== -1)) { return; }\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_draggableMoved: function (obj) {\r\n\t\t\tobj = obj.dragging && obj.dragging.enabled() ? obj : this;\r\n\t\t\treturn (obj.dragging && obj.dragging.moved()) || (this.boxZoom && this.boxZoom.moved());\r\n\t\t},\r\n\t\r\n\t\t_clearHandlers: function () {\r\n\t\t\tfor (var i = 0, len = this._handlers.length; i < len; i++) {\r\n\t\t\t\tthis._handlers[i].disable();\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @section Other Methods\r\n\t\r\n\t\t// @method whenReady(fn: Function, context?: Object): this\r\n\t\t// Runs the given function `fn` when the map gets initialized with\r\n\t\t// a view (center and zoom) and at least one layer, or immediately\r\n\t\t// if it's already initialized, optionally passing a function context.\r\n\t\twhenReady: function (callback, context) {\r\n\t\t\tif (this._loaded) {\r\n\t\t\t\tcallback.call(context || this, {target: this});\r\n\t\t\t} else {\r\n\t\t\t\tthis.on('load', callback, context);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\r\n\t\t// private methods for getting map state\r\n\t\r\n\t\t_getMapPanePos: function () {\r\n\t\t\treturn getPosition(this._mapPane) || new Point(0, 0);\r\n\t\t},\r\n\t\r\n\t\t_moved: function () {\r\n\t\t\tvar pos = this._getMapPanePos();\r\n\t\t\treturn pos && !pos.equals([0, 0]);\r\n\t\t},\r\n\t\r\n\t\t_getTopLeftPoint: function (center, zoom) {\r\n\t\t\tvar pixelOrigin = center && zoom !== undefined ?\r\n\t\t\t\tthis._getNewPixelOrigin(center, zoom) :\r\n\t\t\t\tthis.getPixelOrigin();\r\n\t\t\treturn pixelOrigin.subtract(this._getMapPanePos());\r\n\t\t},\r\n\t\r\n\t\t_getNewPixelOrigin: function (center, zoom) {\r\n\t\t\tvar viewHalf = this.getSize()._divideBy(2);\r\n\t\t\treturn this.project(center, zoom)._subtract(viewHalf)._add(this._getMapPanePos())._round();\r\n\t\t},\r\n\t\r\n\t\t_latLngToNewLayerPoint: function (latlng, zoom, center) {\r\n\t\t\tvar topLeft = this._getNewPixelOrigin(center, zoom);\r\n\t\t\treturn this.project(latlng, zoom)._subtract(topLeft);\r\n\t\t},\r\n\t\r\n\t\t_latLngBoundsToNewLayerBounds: function (latLngBounds, zoom, center) {\r\n\t\t\tvar topLeft = this._getNewPixelOrigin(center, zoom);\r\n\t\t\treturn toBounds([\r\n\t\t\t\tthis.project(latLngBounds.getSouthWest(), zoom)._subtract(topLeft),\r\n\t\t\t\tthis.project(latLngBounds.getNorthWest(), zoom)._subtract(topLeft),\r\n\t\t\t\tthis.project(latLngBounds.getSouthEast(), zoom)._subtract(topLeft),\r\n\t\t\t\tthis.project(latLngBounds.getNorthEast(), zoom)._subtract(topLeft)\r\n\t\t\t]);\r\n\t\t},\r\n\t\r\n\t\t// layer point of the current center\r\n\t\t_getCenterLayerPoint: function () {\r\n\t\t\treturn this.containerPointToLayerPoint(this.getSize()._divideBy(2));\r\n\t\t},\r\n\t\r\n\t\t// offset of the specified place to the current center in pixels\r\n\t\t_getCenterOffset: function (latlng) {\r\n\t\t\treturn this.latLngToLayerPoint(latlng).subtract(this._getCenterLayerPoint());\r\n\t\t},\r\n\t\r\n\t\t// adjust center for view to get inside bounds\r\n\t\t_limitCenter: function (center, zoom, bounds) {\r\n\t\r\n\t\t\tif (!bounds) { return center; }\r\n\t\r\n\t\t\tvar centerPoint = this.project(center, zoom),\r\n\t\t\t viewHalf = this.getSize().divideBy(2),\r\n\t\t\t viewBounds = new Bounds(centerPoint.subtract(viewHalf), centerPoint.add(viewHalf)),\r\n\t\t\t offset = this._getBoundsOffset(viewBounds, bounds, zoom);\r\n\t\r\n\t\t\t// If offset is less than a pixel, ignore.\r\n\t\t\t// This prevents unstable projections from getting into\r\n\t\t\t// an infinite loop of tiny offsets.\r\n\t\t\tif (offset.round().equals([0, 0])) {\r\n\t\t\t\treturn center;\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this.unproject(centerPoint.add(offset), zoom);\r\n\t\t},\r\n\t\r\n\t\t// adjust offset for view to get inside bounds\r\n\t\t_limitOffset: function (offset, bounds) {\r\n\t\t\tif (!bounds) { return offset; }\r\n\t\r\n\t\t\tvar viewBounds = this.getPixelBounds(),\r\n\t\t\t newBounds = new Bounds(viewBounds.min.add(offset), viewBounds.max.add(offset));\r\n\t\r\n\t\t\treturn offset.add(this._getBoundsOffset(newBounds, bounds));\r\n\t\t},\r\n\t\r\n\t\t// returns offset needed for pxBounds to get inside maxBounds at a specified zoom\r\n\t\t_getBoundsOffset: function (pxBounds, maxBounds, zoom) {\r\n\t\t\tvar projectedMaxBounds = toBounds(\r\n\t\t\t this.project(maxBounds.getNorthEast(), zoom),\r\n\t\t\t this.project(maxBounds.getSouthWest(), zoom)\r\n\t\t\t ),\r\n\t\t\t minOffset = projectedMaxBounds.min.subtract(pxBounds.min),\r\n\t\t\t maxOffset = projectedMaxBounds.max.subtract(pxBounds.max),\r\n\t\r\n\t\t\t dx = this._rebound(minOffset.x, -maxOffset.x),\r\n\t\t\t dy = this._rebound(minOffset.y, -maxOffset.y);\r\n\t\r\n\t\t\treturn new Point(dx, dy);\r\n\t\t},\r\n\t\r\n\t\t_rebound: function (left, right) {\r\n\t\t\treturn left + right > 0 ?\r\n\t\t\t\tMath.round(left - right) / 2 :\r\n\t\t\t\tMath.max(0, Math.ceil(left)) - Math.max(0, Math.floor(right));\r\n\t\t},\r\n\t\r\n\t\t_limitZoom: function (zoom) {\r\n\t\t\tvar min = this.getMinZoom(),\r\n\t\t\t max = this.getMaxZoom(),\r\n\t\t\t snap = any3d ? this.options.zoomSnap : 1;\r\n\t\t\tif (snap) {\r\n\t\t\t\tzoom = Math.round(zoom / snap) * snap;\r\n\t\t\t}\r\n\t\t\treturn Math.max(min, Math.min(max, zoom));\r\n\t\t},\r\n\t\r\n\t\t_onPanTransitionStep: function () {\r\n\t\t\tthis.fire('move');\r\n\t\t},\r\n\t\r\n\t\t_onPanTransitionEnd: function () {\r\n\t\t\tremoveClass(this._mapPane, 'leaflet-pan-anim');\r\n\t\t\tthis.fire('moveend');\r\n\t\t},\r\n\t\r\n\t\t_tryAnimatedPan: function (center, options) {\r\n\t\t\t// difference between the new and current centers in pixels\r\n\t\t\tvar offset = this._getCenterOffset(center)._trunc();\r\n\t\r\n\t\t\t// don't animate too far unless animate: true specified in options\r\n\t\t\tif ((options && options.animate) !== true && !this.getSize().contains(offset)) { return false; }\r\n\t\r\n\t\t\tthis.panBy(offset, options);\r\n\t\r\n\t\t\treturn true;\r\n\t\t},\r\n\t\r\n\t\t_createAnimProxy: function () {\r\n\t\r\n\t\t\tvar proxy = this._proxy = create$1('div', 'leaflet-proxy leaflet-zoom-animated');\r\n\t\t\tthis._panes.mapPane.appendChild(proxy);\r\n\t\r\n\t\t\tthis.on('zoomanim', function (e) {\r\n\t\t\t\tvar prop = TRANSFORM,\r\n\t\t\t\t transform = this._proxy.style[prop];\r\n\t\r\n\t\t\t\tsetTransform(this._proxy, this.project(e.center, e.zoom), this.getZoomScale(e.zoom, 1));\r\n\t\r\n\t\t\t\t// workaround for case when transform is the same and so transitionend event is not fired\r\n\t\t\t\tif (transform === this._proxy.style[prop] && this._animatingZoom) {\r\n\t\t\t\t\tthis._onZoomTransitionEnd();\r\n\t\t\t\t}\r\n\t\t\t}, this);\r\n\t\r\n\t\t\tthis.on('load moveend', function () {\r\n\t\t\t\tvar c = this.getCenter(),\r\n\t\t\t\t z = this.getZoom();\r\n\t\t\t\tsetTransform(this._proxy, this.project(c, z), this.getZoomScale(z, 1));\r\n\t\t\t}, this);\r\n\t\r\n\t\t\tthis._on('unload', this._destroyAnimProxy, this);\r\n\t\t},\r\n\t\r\n\t\t_destroyAnimProxy: function () {\r\n\t\t\tremove(this._proxy);\r\n\t\t\tdelete this._proxy;\r\n\t\t},\r\n\t\r\n\t\t_catchTransitionEnd: function (e) {\r\n\t\t\tif (this._animatingZoom && e.propertyName.indexOf('transform') >= 0) {\r\n\t\t\t\tthis._onZoomTransitionEnd();\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_nothingToAnimate: function () {\r\n\t\t\treturn !this._container.getElementsByClassName('leaflet-zoom-animated').length;\r\n\t\t},\r\n\t\r\n\t\t_tryAnimatedZoom: function (center, zoom, options) {\r\n\t\r\n\t\t\tif (this._animatingZoom) { return true; }\r\n\t\r\n\t\t\toptions = options || {};\r\n\t\r\n\t\t\t// don't animate if disabled, not supported or zoom difference is too large\r\n\t\t\tif (!this._zoomAnimated || options.animate === false || this._nothingToAnimate() ||\r\n\t\t\t Math.abs(zoom - this._zoom) > this.options.zoomAnimationThreshold) { return false; }\r\n\t\r\n\t\t\t// offset is the pixel coords of the zoom origin relative to the current center\r\n\t\t\tvar scale = this.getZoomScale(zoom),\r\n\t\t\t offset = this._getCenterOffset(center)._divideBy(1 - 1 / scale);\r\n\t\r\n\t\t\t// don't animate if the zoom origin isn't within one screen from the current center, unless forced\r\n\t\t\tif (options.animate !== true && !this.getSize().contains(offset)) { return false; }\r\n\t\r\n\t\t\trequestAnimFrame(function () {\r\n\t\t\t\tthis\r\n\t\t\t\t ._moveStart(true, false)\r\n\t\t\t\t ._animateZoom(center, zoom, true);\r\n\t\t\t}, this);\r\n\t\r\n\t\t\treturn true;\r\n\t\t},\r\n\t\r\n\t\t_animateZoom: function (center, zoom, startAnim, noUpdate) {\r\n\t\t\tif (!this._mapPane) { return; }\r\n\t\r\n\t\t\tif (startAnim) {\r\n\t\t\t\tthis._animatingZoom = true;\r\n\t\r\n\t\t\t\t// remember what center/zoom to set after animation\r\n\t\t\t\tthis._animateToCenter = center;\r\n\t\t\t\tthis._animateToZoom = zoom;\r\n\t\r\n\t\t\t\taddClass(this._mapPane, 'leaflet-zoom-anim');\r\n\t\t\t}\r\n\t\r\n\t\t\t// @event zoomanim: ZoomAnimEvent\r\n\t\t\t// Fired on every frame of a zoom animation\r\n\t\t\tthis.fire('zoomanim', {\r\n\t\t\t\tcenter: center,\r\n\t\t\t\tzoom: zoom,\r\n\t\t\t\tnoUpdate: noUpdate\r\n\t\t\t});\r\n\t\r\n\t\t\t// Work around webkit not firing 'transitionend', see https://github.com/Leaflet/Leaflet/issues/3689, 2693\r\n\t\t\tsetTimeout(bind(this._onZoomTransitionEnd, this), 250);\r\n\t\t},\r\n\t\r\n\t\t_onZoomTransitionEnd: function () {\r\n\t\t\tif (!this._animatingZoom) { return; }\r\n\t\r\n\t\t\tif (this._mapPane) {\r\n\t\t\t\tremoveClass(this._mapPane, 'leaflet-zoom-anim');\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._animatingZoom = false;\r\n\t\r\n\t\t\tthis._move(this._animateToCenter, this._animateToZoom);\r\n\t\r\n\t\t\t// This anim frame should prevent an obscure iOS webkit tile loading race condition.\r\n\t\t\trequestAnimFrame(function () {\r\n\t\t\t\tthis._moveEnd(true);\r\n\t\t\t}, this);\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @section\r\n\t\r\n\t// @factory L.map(id: String, options?: Map options)\r\n\t// Instantiates a map object given the DOM ID of a `
    ` element\r\n\t// and optionally an object literal with `Map options`.\r\n\t//\r\n\t// @alternative\r\n\t// @factory L.map(el: HTMLElement, options?: Map options)\r\n\t// Instantiates a map object given an instance of a `
    ` HTML element\r\n\t// and optionally an object literal with `Map options`.\r\n\tfunction createMap(id, options) {\r\n\t\treturn new Map(id, options);\r\n\t}\n\t\n\t/*\r\n\t * @class Control\r\n\t * @aka L.Control\r\n\t * @inherits Class\r\n\t *\r\n\t * L.Control is a base class for implementing map controls. Handles positioning.\r\n\t * All other controls extend from this class.\r\n\t */\r\n\t\r\n\tvar Control = Class.extend({\r\n\t\t// @section\r\n\t\t// @aka Control options\r\n\t\toptions: {\r\n\t\t\t// @option position: String = 'topright'\r\n\t\t\t// The position of the control (one of the map corners). Possible values are `'topleft'`,\r\n\t\t\t// `'topright'`, `'bottomleft'` or `'bottomright'`\r\n\t\t\tposition: 'topright'\r\n\t\t},\r\n\t\r\n\t\tinitialize: function (options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\t},\r\n\t\r\n\t\t/* @section\r\n\t\t * Classes extending L.Control will inherit the following methods:\r\n\t\t *\r\n\t\t * @method getPosition: string\r\n\t\t * Returns the position of the control.\r\n\t\t */\r\n\t\tgetPosition: function () {\r\n\t\t\treturn this.options.position;\r\n\t\t},\r\n\t\r\n\t\t// @method setPosition(position: string): this\r\n\t\t// Sets the position of the control.\r\n\t\tsetPosition: function (position) {\r\n\t\t\tvar map = this._map;\r\n\t\r\n\t\t\tif (map) {\r\n\t\t\t\tmap.removeControl(this);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis.options.position = position;\r\n\t\r\n\t\t\tif (map) {\r\n\t\t\t\tmap.addControl(this);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method getContainer: HTMLElement\r\n\t\t// Returns the HTMLElement that contains the control.\r\n\t\tgetContainer: function () {\r\n\t\t\treturn this._container;\r\n\t\t},\r\n\t\r\n\t\t// @method addTo(map: Map): this\r\n\t\t// Adds the control to the given map.\r\n\t\taddTo: function (map) {\r\n\t\t\tthis.remove();\r\n\t\t\tthis._map = map;\r\n\t\r\n\t\t\tvar container = this._container = this.onAdd(map),\r\n\t\t\t pos = this.getPosition(),\r\n\t\t\t corner = map._controlCorners[pos];\r\n\t\r\n\t\t\taddClass(container, 'leaflet-control');\r\n\t\r\n\t\t\tif (pos.indexOf('bottom') !== -1) {\r\n\t\t\t\tcorner.insertBefore(container, corner.firstChild);\r\n\t\t\t} else {\r\n\t\t\t\tcorner.appendChild(container);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method remove: this\r\n\t\t// Removes the control from the map it is currently active on.\r\n\t\tremove: function () {\r\n\t\t\tif (!this._map) {\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\r\n\t\t\tremove(this._container);\r\n\t\r\n\t\t\tif (this.onRemove) {\r\n\t\t\t\tthis.onRemove(this._map);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._map = null;\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_refocusOnMap: function (e) {\r\n\t\t\t// if map exists and event is not a keyboard event\r\n\t\t\tif (this._map && e && e.screenX > 0 && e.screenY > 0) {\r\n\t\t\t\tthis._map.getContainer().focus();\r\n\t\t\t}\r\n\t\t}\r\n\t});\r\n\t\r\n\tvar control = function (options) {\r\n\t\treturn new Control(options);\r\n\t};\r\n\t\r\n\t/* @section Extension methods\r\n\t * @uninheritable\r\n\t *\r\n\t * Every control should extend from `L.Control` and (re-)implement the following methods.\r\n\t *\r\n\t * @method onAdd(map: Map): HTMLElement\r\n\t * Should return the container DOM element for the control and add listeners on relevant map events. Called on [`control.addTo(map)`](#control-addTo).\r\n\t *\r\n\t * @method onRemove(map: Map)\r\n\t * Optional method. Should contain all clean up code that removes the listeners previously added in [`onAdd`](#control-onadd). Called on [`control.remove()`](#control-remove).\r\n\t */\r\n\t\r\n\t/* @namespace Map\r\n\t * @section Methods for Layers and Controls\r\n\t */\r\n\tMap.include({\r\n\t\t// @method addControl(control: Control): this\r\n\t\t// Adds the given control to the map\r\n\t\taddControl: function (control) {\r\n\t\t\tcontrol.addTo(this);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method removeControl(control: Control): this\r\n\t\t// Removes the given control from the map\r\n\t\tremoveControl: function (control) {\r\n\t\t\tcontrol.remove();\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_initControlPos: function () {\r\n\t\t\tvar corners = this._controlCorners = {},\r\n\t\t\t l = 'leaflet-',\r\n\t\t\t container = this._controlContainer =\r\n\t\t\t create$1('div', l + 'control-container', this._container);\r\n\t\r\n\t\t\tfunction createCorner(vSide, hSide) {\r\n\t\t\t\tvar className = l + vSide + ' ' + l + hSide;\r\n\t\r\n\t\t\t\tcorners[vSide + hSide] = create$1('div', className, container);\r\n\t\t\t}\r\n\t\r\n\t\t\tcreateCorner('top', 'left');\r\n\t\t\tcreateCorner('top', 'right');\r\n\t\t\tcreateCorner('bottom', 'left');\r\n\t\t\tcreateCorner('bottom', 'right');\r\n\t\t},\r\n\t\r\n\t\t_clearControlPos: function () {\r\n\t\t\tfor (var i in this._controlCorners) {\r\n\t\t\t\tremove(this._controlCorners[i]);\r\n\t\t\t}\r\n\t\t\tremove(this._controlContainer);\r\n\t\t\tdelete this._controlCorners;\r\n\t\t\tdelete this._controlContainer;\r\n\t\t}\r\n\t});\n\t\n\t/*\r\n\t * @class Control.Layers\r\n\t * @aka L.Control.Layers\r\n\t * @inherits Control\r\n\t *\r\n\t * The layers control gives users the ability to switch between different base layers and switch overlays on/off (check out the [detailed example](http://leafletjs.com/examples/layers-control/)). Extends `Control`.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var baseLayers = {\r\n\t * \t\"Mapbox\": mapbox,\r\n\t * \t\"OpenStreetMap\": osm\r\n\t * };\r\n\t *\r\n\t * var overlays = {\r\n\t * \t\"Marker\": marker,\r\n\t * \t\"Roads\": roadsLayer\r\n\t * };\r\n\t *\r\n\t * L.control.layers(baseLayers, overlays).addTo(map);\r\n\t * ```\r\n\t *\r\n\t * The `baseLayers` and `overlays` parameters are object literals with layer names as keys and `Layer` objects as values:\r\n\t *\r\n\t * ```js\r\n\t * {\r\n\t * \"\": layer1,\r\n\t * \"\": layer2\r\n\t * }\r\n\t * ```\r\n\t *\r\n\t * The layer names can contain HTML, which allows you to add additional styling to the items:\r\n\t *\r\n\t * ```js\r\n\t * {\" My Layer\": myLayer}\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar Layers = Control.extend({\r\n\t\t// @section\r\n\t\t// @aka Control.Layers options\r\n\t\toptions: {\r\n\t\t\t// @option collapsed: Boolean = true\r\n\t\t\t// If `true`, the control will be collapsed into an icon and expanded on mouse hover or touch.\r\n\t\t\tcollapsed: true,\r\n\t\t\tposition: 'topright',\r\n\t\r\n\t\t\t// @option autoZIndex: Boolean = true\r\n\t\t\t// If `true`, the control will assign zIndexes in increasing order to all of its layers so that the order is preserved when switching them on/off.\r\n\t\t\tautoZIndex: true,\r\n\t\r\n\t\t\t// @option hideSingleBase: Boolean = false\r\n\t\t\t// If `true`, the base layers in the control will be hidden when there is only one.\r\n\t\t\thideSingleBase: false,\r\n\t\r\n\t\t\t// @option sortLayers: Boolean = false\r\n\t\t\t// Whether to sort the layers. When `false`, layers will keep the order\r\n\t\t\t// in which they were added to the control.\r\n\t\t\tsortLayers: false,\r\n\t\r\n\t\t\t// @option sortFunction: Function = *\r\n\t\t\t// A [compare function](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array/sort)\r\n\t\t\t// that will be used for sorting the layers, when `sortLayers` is `true`.\r\n\t\t\t// The function receives both the `L.Layer` instances and their names, as in\r\n\t\t\t// `sortFunction(layerA, layerB, nameA, nameB)`.\r\n\t\t\t// By default, it sorts layers alphabetically by their name.\r\n\t\t\tsortFunction: function (layerA, layerB, nameA, nameB) {\r\n\t\t\t\treturn nameA < nameB ? -1 : (nameB < nameA ? 1 : 0);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\tinitialize: function (baseLayers, overlays, options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\r\n\t\t\tthis._layerControlInputs = [];\r\n\t\t\tthis._layers = [];\r\n\t\t\tthis._lastZIndex = 0;\r\n\t\t\tthis._handlingClick = false;\r\n\t\r\n\t\t\tfor (var i in baseLayers) {\r\n\t\t\t\tthis._addLayer(baseLayers[i], i);\r\n\t\t\t}\r\n\t\r\n\t\t\tfor (i in overlays) {\r\n\t\t\t\tthis._addLayer(overlays[i], i, true);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\tonAdd: function (map) {\r\n\t\t\tthis._initLayout();\r\n\t\t\tthis._update();\r\n\t\r\n\t\t\tthis._map = map;\r\n\t\t\tmap.on('zoomend', this._checkDisabledLayers, this);\r\n\t\r\n\t\t\tfor (var i = 0; i < this._layers.length; i++) {\r\n\t\t\t\tthis._layers[i].layer.on('add remove', this._onLayerChange, this);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this._container;\r\n\t\t},\r\n\t\r\n\t\taddTo: function (map) {\r\n\t\t\tControl.prototype.addTo.call(this, map);\r\n\t\t\t// Trigger expand after Layers Control has been inserted into DOM so that is now has an actual height.\r\n\t\t\treturn this._expandIfNotCollapsed();\r\n\t\t},\r\n\t\r\n\t\tonRemove: function () {\r\n\t\t\tthis._map.off('zoomend', this._checkDisabledLayers, this);\r\n\t\r\n\t\t\tfor (var i = 0; i < this._layers.length; i++) {\r\n\t\t\t\tthis._layers[i].layer.off('add remove', this._onLayerChange, this);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @method addBaseLayer(layer: Layer, name: String): this\r\n\t\t// Adds a base layer (radio button entry) with the given name to the control.\r\n\t\taddBaseLayer: function (layer, name) {\r\n\t\t\tthis._addLayer(layer, name);\r\n\t\t\treturn (this._map) ? this._update() : this;\r\n\t\t},\r\n\t\r\n\t\t// @method addOverlay(layer: Layer, name: String): this\r\n\t\t// Adds an overlay (checkbox entry) with the given name to the control.\r\n\t\taddOverlay: function (layer, name) {\r\n\t\t\tthis._addLayer(layer, name, true);\r\n\t\t\treturn (this._map) ? this._update() : this;\r\n\t\t},\r\n\t\r\n\t\t// @method removeLayer(layer: Layer): this\r\n\t\t// Remove the given layer from the control.\r\n\t\tremoveLayer: function (layer) {\r\n\t\t\tlayer.off('add remove', this._onLayerChange, this);\r\n\t\r\n\t\t\tvar obj = this._getLayer(stamp(layer));\r\n\t\t\tif (obj) {\r\n\t\t\t\tthis._layers.splice(this._layers.indexOf(obj), 1);\r\n\t\t\t}\r\n\t\t\treturn (this._map) ? this._update() : this;\r\n\t\t},\r\n\t\r\n\t\t// @method expand(): this\r\n\t\t// Expand the control container if collapsed.\r\n\t\texpand: function () {\r\n\t\t\taddClass(this._container, 'leaflet-control-layers-expanded');\r\n\t\t\tthis._form.style.height = null;\r\n\t\t\tvar acceptableHeight = this._map.getSize().y - (this._container.offsetTop + 50);\r\n\t\t\tif (acceptableHeight < this._form.clientHeight) {\r\n\t\t\t\taddClass(this._form, 'leaflet-control-layers-scrollbar');\r\n\t\t\t\tthis._form.style.height = acceptableHeight + 'px';\r\n\t\t\t} else {\r\n\t\t\t\tremoveClass(this._form, 'leaflet-control-layers-scrollbar');\r\n\t\t\t}\r\n\t\t\tthis._checkDisabledLayers();\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method collapse(): this\r\n\t\t// Collapse the control container if expanded.\r\n\t\tcollapse: function () {\r\n\t\t\tremoveClass(this._container, 'leaflet-control-layers-expanded');\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_initLayout: function () {\r\n\t\t\tvar className = 'leaflet-control-layers',\r\n\t\t\t container = this._container = create$1('div', className),\r\n\t\t\t collapsed = this.options.collapsed;\r\n\t\r\n\t\t\t// makes this work on IE touch devices by stopping it from firing a mouseout event when the touch is released\r\n\t\t\tcontainer.setAttribute('aria-haspopup', true);\r\n\t\r\n\t\t\tdisableClickPropagation(container);\r\n\t\t\tdisableScrollPropagation(container);\r\n\t\r\n\t\t\tvar form = this._form = create$1('form', className + '-list');\r\n\t\r\n\t\t\tif (collapsed) {\r\n\t\t\t\tthis._map.on('click', this.collapse, this);\r\n\t\r\n\t\t\t\tif (!android) {\r\n\t\t\t\t\ton(container, {\r\n\t\t\t\t\t\tmouseenter: this.expand,\r\n\t\t\t\t\t\tmouseleave: this.collapse\r\n\t\t\t\t\t}, this);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tvar link = this._layersLink = create$1('a', className + '-toggle', container);\r\n\t\t\tlink.href = '#';\r\n\t\t\tlink.title = 'Layers';\r\n\t\r\n\t\t\tif (touch) {\r\n\t\t\t\ton(link, 'click', stop);\r\n\t\t\t\ton(link, 'click', this.expand, this);\r\n\t\t\t} else {\r\n\t\t\t\ton(link, 'focus', this.expand, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tif (!collapsed) {\r\n\t\t\t\tthis.expand();\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._baseLayersList = create$1('div', className + '-base', form);\r\n\t\t\tthis._separator = create$1('div', className + '-separator', form);\r\n\t\t\tthis._overlaysList = create$1('div', className + '-overlays', form);\r\n\t\r\n\t\t\tcontainer.appendChild(form);\r\n\t\t},\r\n\t\r\n\t\t_getLayer: function (id) {\r\n\t\t\tfor (var i = 0; i < this._layers.length; i++) {\r\n\t\r\n\t\t\t\tif (this._layers[i] && stamp(this._layers[i].layer) === id) {\r\n\t\t\t\t\treturn this._layers[i];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_addLayer: function (layer, name, overlay) {\r\n\t\t\tif (this._map) {\r\n\t\t\t\tlayer.on('add remove', this._onLayerChange, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._layers.push({\r\n\t\t\t\tlayer: layer,\r\n\t\t\t\tname: name,\r\n\t\t\t\toverlay: overlay\r\n\t\t\t});\r\n\t\r\n\t\t\tif (this.options.sortLayers) {\r\n\t\t\t\tthis._layers.sort(bind(function (a, b) {\r\n\t\t\t\t\treturn this.options.sortFunction(a.layer, b.layer, a.name, b.name);\r\n\t\t\t\t}, this));\r\n\t\t\t}\r\n\t\r\n\t\t\tif (this.options.autoZIndex && layer.setZIndex) {\r\n\t\t\t\tthis._lastZIndex++;\r\n\t\t\t\tlayer.setZIndex(this._lastZIndex);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._expandIfNotCollapsed();\r\n\t\t},\r\n\t\r\n\t\t_update: function () {\r\n\t\t\tif (!this._container) { return this; }\r\n\t\r\n\t\t\tempty(this._baseLayersList);\r\n\t\t\tempty(this._overlaysList);\r\n\t\r\n\t\t\tthis._layerControlInputs = [];\r\n\t\t\tvar baseLayersPresent, overlaysPresent, i, obj, baseLayersCount = 0;\r\n\t\r\n\t\t\tfor (i = 0; i < this._layers.length; i++) {\r\n\t\t\t\tobj = this._layers[i];\r\n\t\t\t\tthis._addItem(obj);\r\n\t\t\t\toverlaysPresent = overlaysPresent || obj.overlay;\r\n\t\t\t\tbaseLayersPresent = baseLayersPresent || !obj.overlay;\r\n\t\t\t\tbaseLayersCount += !obj.overlay ? 1 : 0;\r\n\t\t\t}\r\n\t\r\n\t\t\t// Hide base layers section if there's only one layer.\r\n\t\t\tif (this.options.hideSingleBase) {\r\n\t\t\t\tbaseLayersPresent = baseLayersPresent && baseLayersCount > 1;\r\n\t\t\t\tthis._baseLayersList.style.display = baseLayersPresent ? '' : 'none';\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._separator.style.display = overlaysPresent && baseLayersPresent ? '' : 'none';\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_onLayerChange: function (e) {\r\n\t\t\tif (!this._handlingClick) {\r\n\t\t\t\tthis._update();\r\n\t\t\t}\r\n\t\r\n\t\t\tvar obj = this._getLayer(stamp(e.target));\r\n\t\r\n\t\t\t// @namespace Map\r\n\t\t\t// @section Layer events\r\n\t\t\t// @event baselayerchange: LayersControlEvent\r\n\t\t\t// Fired when the base layer is changed through the [layer control](#control-layers).\r\n\t\t\t// @event overlayadd: LayersControlEvent\r\n\t\t\t// Fired when an overlay is selected through the [layer control](#control-layers).\r\n\t\t\t// @event overlayremove: LayersControlEvent\r\n\t\t\t// Fired when an overlay is deselected through the [layer control](#control-layers).\r\n\t\t\t// @namespace Control.Layers\r\n\t\t\tvar type = obj.overlay ?\r\n\t\t\t\t(e.type === 'add' ? 'overlayadd' : 'overlayremove') :\r\n\t\t\t\t(e.type === 'add' ? 'baselayerchange' : null);\r\n\t\r\n\t\t\tif (type) {\r\n\t\t\t\tthis._map.fire(type, obj);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// IE7 bugs out if you create a radio dynamically, so you have to do it this hacky way (see http://bit.ly/PqYLBe)\r\n\t\t_createRadioElement: function (name, checked) {\r\n\t\r\n\t\t\tvar radioHtml = '';\r\n\t\r\n\t\t\tvar radioFragment = document.createElement('div');\r\n\t\t\tradioFragment.innerHTML = radioHtml;\r\n\t\r\n\t\t\treturn radioFragment.firstChild;\r\n\t\t},\r\n\t\r\n\t\t_addItem: function (obj) {\r\n\t\t\tvar label = document.createElement('label'),\r\n\t\t\t checked = this._map.hasLayer(obj.layer),\r\n\t\t\t input;\r\n\t\r\n\t\t\tif (obj.overlay) {\r\n\t\t\t\tinput = document.createElement('input');\r\n\t\t\t\tinput.type = 'checkbox';\r\n\t\t\t\tinput.className = 'leaflet-control-layers-selector';\r\n\t\t\t\tinput.defaultChecked = checked;\r\n\t\t\t} else {\r\n\t\t\t\tinput = this._createRadioElement('leaflet-base-layers', checked);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._layerControlInputs.push(input);\r\n\t\t\tinput.layerId = stamp(obj.layer);\r\n\t\r\n\t\t\ton(input, 'click', this._onInputClick, this);\r\n\t\r\n\t\t\tvar name = document.createElement('span');\r\n\t\t\tname.innerHTML = ' ' + obj.name;\r\n\t\r\n\t\t\t// Helps from preventing layer control flicker when checkboxes are disabled\r\n\t\t\t// https://github.com/Leaflet/Leaflet/issues/2771\r\n\t\t\tvar holder = document.createElement('div');\r\n\t\r\n\t\t\tlabel.appendChild(holder);\r\n\t\t\tholder.appendChild(input);\r\n\t\t\tholder.appendChild(name);\r\n\t\r\n\t\t\tvar container = obj.overlay ? this._overlaysList : this._baseLayersList;\r\n\t\t\tcontainer.appendChild(label);\r\n\t\r\n\t\t\tthis._checkDisabledLayers();\r\n\t\t\treturn label;\r\n\t\t},\r\n\t\r\n\t\t_onInputClick: function () {\r\n\t\t\tvar inputs = this._layerControlInputs,\r\n\t\t\t input, layer;\r\n\t\t\tvar addedLayers = [],\r\n\t\t\t removedLayers = [];\r\n\t\r\n\t\t\tthis._handlingClick = true;\r\n\t\r\n\t\t\tfor (var i = inputs.length - 1; i >= 0; i--) {\r\n\t\t\t\tinput = inputs[i];\r\n\t\t\t\tlayer = this._getLayer(input.layerId).layer;\r\n\t\r\n\t\t\t\tif (input.checked) {\r\n\t\t\t\t\taddedLayers.push(layer);\r\n\t\t\t\t} else if (!input.checked) {\r\n\t\t\t\t\tremovedLayers.push(layer);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\t// Bugfix issue 2318: Should remove all old layers before readding new ones\r\n\t\t\tfor (i = 0; i < removedLayers.length; i++) {\r\n\t\t\t\tif (this._map.hasLayer(removedLayers[i])) {\r\n\t\t\t\t\tthis._map.removeLayer(removedLayers[i]);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tfor (i = 0; i < addedLayers.length; i++) {\r\n\t\t\t\tif (!this._map.hasLayer(addedLayers[i])) {\r\n\t\t\t\t\tthis._map.addLayer(addedLayers[i]);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._handlingClick = false;\r\n\t\r\n\t\t\tthis._refocusOnMap();\r\n\t\t},\r\n\t\r\n\t\t_checkDisabledLayers: function () {\r\n\t\t\tvar inputs = this._layerControlInputs,\r\n\t\t\t input,\r\n\t\t\t layer,\r\n\t\t\t zoom = this._map.getZoom();\r\n\t\r\n\t\t\tfor (var i = inputs.length - 1; i >= 0; i--) {\r\n\t\t\t\tinput = inputs[i];\r\n\t\t\t\tlayer = this._getLayer(input.layerId).layer;\r\n\t\t\t\tinput.disabled = (layer.options.minZoom !== undefined && zoom < layer.options.minZoom) ||\r\n\t\t\t\t (layer.options.maxZoom !== undefined && zoom > layer.options.maxZoom);\r\n\t\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_expandIfNotCollapsed: function () {\r\n\t\t\tif (this._map && !this.options.collapsed) {\r\n\t\t\t\tthis.expand();\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_expand: function () {\r\n\t\t\t// Backward compatibility, remove me in 1.1.\r\n\t\t\treturn this.expand();\r\n\t\t},\r\n\t\r\n\t\t_collapse: function () {\r\n\t\t\t// Backward compatibility, remove me in 1.1.\r\n\t\t\treturn this.collapse();\r\n\t\t}\r\n\t\r\n\t});\r\n\t\r\n\t\r\n\t// @factory L.control.layers(baselayers?: Object, overlays?: Object, options?: Control.Layers options)\r\n\t// Creates an attribution control with the given layers. Base layers will be switched with radio buttons, while overlays will be switched with checkboxes. Note that all base layers should be passed in the base layers object, but only one should be added to the map during map instantiation.\r\n\tvar layers = function (baseLayers, overlays, options) {\r\n\t\treturn new Layers(baseLayers, overlays, options);\r\n\t};\n\t\n\t/*\r\n\t * @class Control.Zoom\r\n\t * @aka L.Control.Zoom\r\n\t * @inherits Control\r\n\t *\r\n\t * A basic zoom control with two buttons (zoom in and zoom out). It is put on the map by default unless you set its [`zoomControl` option](#map-zoomcontrol) to `false`. Extends `Control`.\r\n\t */\r\n\t\r\n\tvar Zoom = Control.extend({\r\n\t\t// @section\r\n\t\t// @aka Control.Zoom options\r\n\t\toptions: {\r\n\t\t\tposition: 'topleft',\r\n\t\r\n\t\t\t// @option zoomInText: String = '+'\r\n\t\t\t// The text set on the 'zoom in' button.\r\n\t\t\tzoomInText: '+',\r\n\t\r\n\t\t\t// @option zoomInTitle: String = 'Zoom in'\r\n\t\t\t// The title set on the 'zoom in' button.\r\n\t\t\tzoomInTitle: 'Zoom in',\r\n\t\r\n\t\t\t// @option zoomOutText: String = '−'\r\n\t\t\t// The text set on the 'zoom out' button.\r\n\t\t\tzoomOutText: '−',\r\n\t\r\n\t\t\t// @option zoomOutTitle: String = 'Zoom out'\r\n\t\t\t// The title set on the 'zoom out' button.\r\n\t\t\tzoomOutTitle: 'Zoom out'\r\n\t\t},\r\n\t\r\n\t\tonAdd: function (map) {\r\n\t\t\tvar zoomName = 'leaflet-control-zoom',\r\n\t\t\t container = create$1('div', zoomName + ' leaflet-bar'),\r\n\t\t\t options = this.options;\r\n\t\r\n\t\t\tthis._zoomInButton = this._createButton(options.zoomInText, options.zoomInTitle,\r\n\t\t\t zoomName + '-in', container, this._zoomIn);\r\n\t\t\tthis._zoomOutButton = this._createButton(options.zoomOutText, options.zoomOutTitle,\r\n\t\t\t zoomName + '-out', container, this._zoomOut);\r\n\t\r\n\t\t\tthis._updateDisabled();\r\n\t\t\tmap.on('zoomend zoomlevelschange', this._updateDisabled, this);\r\n\t\r\n\t\t\treturn container;\r\n\t\t},\r\n\t\r\n\t\tonRemove: function (map) {\r\n\t\t\tmap.off('zoomend zoomlevelschange', this._updateDisabled, this);\r\n\t\t},\r\n\t\r\n\t\tdisable: function () {\r\n\t\t\tthis._disabled = true;\r\n\t\t\tthis._updateDisabled();\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\tenable: function () {\r\n\t\t\tthis._disabled = false;\r\n\t\t\tthis._updateDisabled();\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_zoomIn: function (e) {\r\n\t\t\tif (!this._disabled && this._map._zoom < this._map.getMaxZoom()) {\r\n\t\t\t\tthis._map.zoomIn(this._map.options.zoomDelta * (e.shiftKey ? 3 : 1));\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_zoomOut: function (e) {\r\n\t\t\tif (!this._disabled && this._map._zoom > this._map.getMinZoom()) {\r\n\t\t\t\tthis._map.zoomOut(this._map.options.zoomDelta * (e.shiftKey ? 3 : 1));\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_createButton: function (html, title, className, container, fn) {\r\n\t\t\tvar link = create$1('a', className, container);\r\n\t\t\tlink.innerHTML = html;\r\n\t\t\tlink.href = '#';\r\n\t\t\tlink.title = title;\r\n\t\r\n\t\t\t/*\r\n\t\t\t * Will force screen readers like VoiceOver to read this as \"Zoom in - button\"\r\n\t\t\t */\r\n\t\t\tlink.setAttribute('role', 'button');\r\n\t\t\tlink.setAttribute('aria-label', title);\r\n\t\r\n\t\t\tdisableClickPropagation(link);\r\n\t\t\ton(link, 'click', stop);\r\n\t\t\ton(link, 'click', fn, this);\r\n\t\t\ton(link, 'click', this._refocusOnMap, this);\r\n\t\r\n\t\t\treturn link;\r\n\t\t},\r\n\t\r\n\t\t_updateDisabled: function () {\r\n\t\t\tvar map = this._map,\r\n\t\t\t className = 'leaflet-disabled';\r\n\t\r\n\t\t\tremoveClass(this._zoomInButton, className);\r\n\t\t\tremoveClass(this._zoomOutButton, className);\r\n\t\r\n\t\t\tif (this._disabled || map._zoom === map.getMinZoom()) {\r\n\t\t\t\taddClass(this._zoomOutButton, className);\r\n\t\t\t}\r\n\t\t\tif (this._disabled || map._zoom === map.getMaxZoom()) {\r\n\t\t\t\taddClass(this._zoomInButton, className);\r\n\t\t\t}\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @namespace Map\r\n\t// @section Control options\r\n\t// @option zoomControl: Boolean = true\r\n\t// Whether a [zoom control](#control-zoom) is added to the map by default.\r\n\tMap.mergeOptions({\r\n\t\tzoomControl: true\r\n\t});\r\n\t\r\n\tMap.addInitHook(function () {\r\n\t\tif (this.options.zoomControl) {\r\n\t\t\tthis.zoomControl = new Zoom();\r\n\t\t\tthis.addControl(this.zoomControl);\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @namespace Control.Zoom\r\n\t// @factory L.control.zoom(options: Control.Zoom options)\r\n\t// Creates a zoom control\r\n\tvar zoom = function (options) {\r\n\t\treturn new Zoom(options);\r\n\t};\n\t\n\t/*\n\t * @class Control.Scale\n\t * @aka L.Control.Scale\n\t * @inherits Control\n\t *\n\t * A simple scale control that shows the scale of the current center of screen in metric (m/km) and imperial (mi/ft) systems. Extends `Control`.\n\t *\n\t * @example\n\t *\n\t * ```js\n\t * L.control.scale().addTo(map);\n\t * ```\n\t */\n\t\n\tvar Scale = Control.extend({\n\t\t// @section\n\t\t// @aka Control.Scale options\n\t\toptions: {\n\t\t\tposition: 'bottomleft',\n\t\n\t\t\t// @option maxWidth: Number = 100\n\t\t\t// Maximum width of the control in pixels. The width is set dynamically to show round values (e.g. 100, 200, 500).\n\t\t\tmaxWidth: 100,\n\t\n\t\t\t// @option metric: Boolean = True\n\t\t\t// Whether to show the metric scale line (m/km).\n\t\t\tmetric: true,\n\t\n\t\t\t// @option imperial: Boolean = True\n\t\t\t// Whether to show the imperial scale line (mi/ft).\n\t\t\timperial: true\n\t\n\t\t\t// @option updateWhenIdle: Boolean = false\n\t\t\t// If `true`, the control is updated on [`moveend`](#map-moveend), otherwise it's always up-to-date (updated on [`move`](#map-move)).\n\t\t},\n\t\n\t\tonAdd: function (map) {\n\t\t\tvar className = 'leaflet-control-scale',\n\t\t\t container = create$1('div', className),\n\t\t\t options = this.options;\n\t\n\t\t\tthis._addScales(options, className + '-line', container);\n\t\n\t\t\tmap.on(options.updateWhenIdle ? 'moveend' : 'move', this._update, this);\n\t\t\tmap.whenReady(this._update, this);\n\t\n\t\t\treturn container;\n\t\t},\n\t\n\t\tonRemove: function (map) {\n\t\t\tmap.off(this.options.updateWhenIdle ? 'moveend' : 'move', this._update, this);\n\t\t},\n\t\n\t\t_addScales: function (options, className, container) {\n\t\t\tif (options.metric) {\n\t\t\t\tthis._mScale = create$1('div', className, container);\n\t\t\t}\n\t\t\tif (options.imperial) {\n\t\t\t\tthis._iScale = create$1('div', className, container);\n\t\t\t}\n\t\t},\n\t\n\t\t_update: function () {\n\t\t\tvar map = this._map,\n\t\t\t y = map.getSize().y / 2;\n\t\n\t\t\tvar maxMeters = map.distance(\n\t\t\t\tmap.containerPointToLatLng([0, y]),\n\t\t\t\tmap.containerPointToLatLng([this.options.maxWidth, y]));\n\t\n\t\t\tthis._updateScales(maxMeters);\n\t\t},\n\t\n\t\t_updateScales: function (maxMeters) {\n\t\t\tif (this.options.metric && maxMeters) {\n\t\t\t\tthis._updateMetric(maxMeters);\n\t\t\t}\n\t\t\tif (this.options.imperial && maxMeters) {\n\t\t\t\tthis._updateImperial(maxMeters);\n\t\t\t}\n\t\t},\n\t\n\t\t_updateMetric: function (maxMeters) {\n\t\t\tvar meters = this._getRoundNum(maxMeters),\n\t\t\t label = meters < 1000 ? meters + ' m' : (meters / 1000) + ' km';\n\t\n\t\t\tthis._updateScale(this._mScale, label, meters / maxMeters);\n\t\t},\n\t\n\t\t_updateImperial: function (maxMeters) {\n\t\t\tvar maxFeet = maxMeters * 3.2808399,\n\t\t\t maxMiles, miles, feet;\n\t\n\t\t\tif (maxFeet > 5280) {\n\t\t\t\tmaxMiles = maxFeet / 5280;\n\t\t\t\tmiles = this._getRoundNum(maxMiles);\n\t\t\t\tthis._updateScale(this._iScale, miles + ' mi', miles / maxMiles);\n\t\n\t\t\t} else {\n\t\t\t\tfeet = this._getRoundNum(maxFeet);\n\t\t\t\tthis._updateScale(this._iScale, feet + ' ft', feet / maxFeet);\n\t\t\t}\n\t\t},\n\t\n\t\t_updateScale: function (scale, text, ratio) {\n\t\t\tscale.style.width = Math.round(this.options.maxWidth * ratio) + 'px';\n\t\t\tscale.innerHTML = text;\n\t\t},\n\t\n\t\t_getRoundNum: function (num) {\n\t\t\tvar pow10 = Math.pow(10, (Math.floor(num) + '').length - 1),\n\t\t\t d = num / pow10;\n\t\n\t\t\td = d >= 10 ? 10 :\n\t\t\t d >= 5 ? 5 :\n\t\t\t d >= 3 ? 3 :\n\t\t\t d >= 2 ? 2 : 1;\n\t\n\t\t\treturn pow10 * d;\n\t\t}\n\t});\n\t\n\t\n\t// @factory L.control.scale(options?: Control.Scale options)\n\t// Creates an scale control with the given options.\n\tvar scale = function (options) {\n\t\treturn new Scale(options);\n\t};\n\t\n\t/*\r\n\t * @class Control.Attribution\r\n\t * @aka L.Control.Attribution\r\n\t * @inherits Control\r\n\t *\r\n\t * The attribution control allows you to display attribution data in a small text box on a map. It is put on the map by default unless you set its [`attributionControl` option](#map-attributioncontrol) to `false`, and it fetches attribution texts from layers with the [`getAttribution` method](#layer-getattribution) automatically. Extends Control.\r\n\t */\r\n\t\r\n\tvar Attribution = Control.extend({\r\n\t\t// @section\r\n\t\t// @aka Control.Attribution options\r\n\t\toptions: {\r\n\t\t\tposition: 'bottomright',\r\n\t\r\n\t\t\t// @option prefix: String = 'Leaflet'\r\n\t\t\t// The HTML text shown before the attributions. Pass `false` to disable.\r\n\t\t\tprefix: 'Leaflet'\r\n\t\t},\r\n\t\r\n\t\tinitialize: function (options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\r\n\t\t\tthis._attributions = {};\r\n\t\t},\r\n\t\r\n\t\tonAdd: function (map) {\r\n\t\t\tmap.attributionControl = this;\r\n\t\t\tthis._container = create$1('div', 'leaflet-control-attribution');\r\n\t\t\tdisableClickPropagation(this._container);\r\n\t\r\n\t\t\t// TODO ugly, refactor\r\n\t\t\tfor (var i in map._layers) {\r\n\t\t\t\tif (map._layers[i].getAttribution) {\r\n\t\t\t\t\tthis.addAttribution(map._layers[i].getAttribution());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._update();\r\n\t\r\n\t\t\treturn this._container;\r\n\t\t},\r\n\t\r\n\t\t// @method setPrefix(prefix: String): this\r\n\t\t// Sets the text before the attributions.\r\n\t\tsetPrefix: function (prefix) {\r\n\t\t\tthis.options.prefix = prefix;\r\n\t\t\tthis._update();\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method addAttribution(text: String): this\r\n\t\t// Adds an attribution text (e.g. `'Vector data © Mapbox'`).\r\n\t\taddAttribution: function (text) {\r\n\t\t\tif (!text) { return this; }\r\n\t\r\n\t\t\tif (!this._attributions[text]) {\r\n\t\t\t\tthis._attributions[text] = 0;\r\n\t\t\t}\r\n\t\t\tthis._attributions[text]++;\r\n\t\r\n\t\t\tthis._update();\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method removeAttribution(text: String): this\r\n\t\t// Removes an attribution text.\r\n\t\tremoveAttribution: function (text) {\r\n\t\t\tif (!text) { return this; }\r\n\t\r\n\t\t\tif (this._attributions[text]) {\r\n\t\t\t\tthis._attributions[text]--;\r\n\t\t\t\tthis._update();\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_update: function () {\r\n\t\t\tif (!this._map) { return; }\r\n\t\r\n\t\t\tvar attribs = [];\r\n\t\r\n\t\t\tfor (var i in this._attributions) {\r\n\t\t\t\tif (this._attributions[i]) {\r\n\t\t\t\t\tattribs.push(i);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tvar prefixAndAttribs = [];\r\n\t\r\n\t\t\tif (this.options.prefix) {\r\n\t\t\t\tprefixAndAttribs.push(this.options.prefix);\r\n\t\t\t}\r\n\t\t\tif (attribs.length) {\r\n\t\t\t\tprefixAndAttribs.push(attribs.join(', '));\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._container.innerHTML = prefixAndAttribs.join(' | ');\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @namespace Map\r\n\t// @section Control options\r\n\t// @option attributionControl: Boolean = true\r\n\t// Whether a [attribution control](#control-attribution) is added to the map by default.\r\n\tMap.mergeOptions({\r\n\t\tattributionControl: true\r\n\t});\r\n\t\r\n\tMap.addInitHook(function () {\r\n\t\tif (this.options.attributionControl) {\r\n\t\t\tnew Attribution().addTo(this);\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @namespace Control.Attribution\r\n\t// @factory L.control.attribution(options: Control.Attribution options)\r\n\t// Creates an attribution control.\r\n\tvar attribution = function (options) {\r\n\t\treturn new Attribution(options);\r\n\t};\n\t\n\tControl.Layers = Layers;\n\tControl.Zoom = Zoom;\n\tControl.Scale = Scale;\n\tControl.Attribution = Attribution;\n\t\n\tcontrol.layers = layers;\n\tcontrol.zoom = zoom;\n\tcontrol.scale = scale;\n\tcontrol.attribution = attribution;\n\t\n\t/*\n\t\tL.Handler is a base class for handler classes that are used internally to inject\n\t\tinteraction features like dragging to classes like Map and Marker.\n\t*/\n\t\n\t// @class Handler\n\t// @aka L.Handler\n\t// Abstract class for map interaction handlers\n\t\n\tvar Handler = Class.extend({\n\t\tinitialize: function (map) {\n\t\t\tthis._map = map;\n\t\t},\n\t\n\t\t// @method enable(): this\n\t\t// Enables the handler\n\t\tenable: function () {\n\t\t\tif (this._enabled) { return this; }\n\t\n\t\t\tthis._enabled = true;\n\t\t\tthis.addHooks();\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method disable(): this\n\t\t// Disables the handler\n\t\tdisable: function () {\n\t\t\tif (!this._enabled) { return this; }\n\t\n\t\t\tthis._enabled = false;\n\t\t\tthis.removeHooks();\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method enabled(): Boolean\n\t\t// Returns `true` if the handler is enabled\n\t\tenabled: function () {\n\t\t\treturn !!this._enabled;\n\t\t}\n\t\n\t\t// @section Extension methods\n\t\t// Classes inheriting from `Handler` must implement the two following methods:\n\t\t// @method addHooks()\n\t\t// Called when the handler is enabled, should add event hooks.\n\t\t// @method removeHooks()\n\t\t// Called when the handler is disabled, should remove the event hooks added previously.\n\t});\n\t\n\t// @section There is static function which can be called without instantiating L.Handler:\n\t// @function addTo(map: Map, name: String): this\n\t// Adds a new Handler to the given map with the given name.\n\tHandler.addTo = function (map, name) {\n\t\tmap.addHandler(name, this);\n\t\treturn this;\n\t};\n\t\n\tvar Mixin = {Events: Events};\n\t\n\t/*\r\n\t * @class Draggable\r\n\t * @aka L.Draggable\r\n\t * @inherits Evented\r\n\t *\r\n\t * A class for making DOM elements draggable (including touch support).\r\n\t * Used internally for map and marker dragging. Only works for elements\r\n\t * that were positioned with [`L.DomUtil.setPosition`](#domutil-setposition).\r\n\t *\r\n\t * @example\r\n\t * ```js\r\n\t * var draggable = new L.Draggable(elementToDrag);\r\n\t * draggable.enable();\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar START = touch ? 'touchstart mousedown' : 'mousedown';\r\n\tvar END = {\r\n\t\tmousedown: 'mouseup',\r\n\t\ttouchstart: 'touchend',\r\n\t\tpointerdown: 'touchend',\r\n\t\tMSPointerDown: 'touchend'\r\n\t};\r\n\tvar MOVE = {\r\n\t\tmousedown: 'mousemove',\r\n\t\ttouchstart: 'touchmove',\r\n\t\tpointerdown: 'touchmove',\r\n\t\tMSPointerDown: 'touchmove'\r\n\t};\r\n\t\r\n\t\r\n\tvar Draggable = Evented.extend({\r\n\t\r\n\t\toptions: {\r\n\t\t\t// @section\r\n\t\t\t// @aka Draggable options\r\n\t\t\t// @option clickTolerance: Number = 3\r\n\t\t\t// The max number of pixels a user can shift the mouse pointer during a click\r\n\t\t\t// for it to be considered a valid click (as opposed to a mouse drag).\r\n\t\t\tclickTolerance: 3\r\n\t\t},\r\n\t\r\n\t\t// @constructor L.Draggable(el: HTMLElement, dragHandle?: HTMLElement, preventOutline?: Boolean, options?: Draggable options)\r\n\t\t// Creates a `Draggable` object for moving `el` when you start dragging the `dragHandle` element (equals `el` itself by default).\r\n\t\tinitialize: function (element, dragStartTarget, preventOutline$$1, options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\r\n\t\t\tthis._element = element;\r\n\t\t\tthis._dragStartTarget = dragStartTarget || element;\r\n\t\t\tthis._preventOutline = preventOutline$$1;\r\n\t\t},\r\n\t\r\n\t\t// @method enable()\r\n\t\t// Enables the dragging ability\r\n\t\tenable: function () {\r\n\t\t\tif (this._enabled) { return; }\r\n\t\r\n\t\t\ton(this._dragStartTarget, START, this._onDown, this);\r\n\t\r\n\t\t\tthis._enabled = true;\r\n\t\t},\r\n\t\r\n\t\t// @method disable()\r\n\t\t// Disables the dragging ability\r\n\t\tdisable: function () {\r\n\t\t\tif (!this._enabled) { return; }\r\n\t\r\n\t\t\t// If we're currently dragging this draggable,\r\n\t\t\t// disabling it counts as first ending the drag.\r\n\t\t\tif (Draggable._dragging === this) {\r\n\t\t\t\tthis.finishDrag();\r\n\t\t\t}\r\n\t\r\n\t\t\toff(this._dragStartTarget, START, this._onDown, this);\r\n\t\r\n\t\t\tthis._enabled = false;\r\n\t\t\tthis._moved = false;\r\n\t\t},\r\n\t\r\n\t\t_onDown: function (e) {\r\n\t\t\t// Ignore simulated events, since we handle both touch and\r\n\t\t\t// mouse explicitly; otherwise we risk getting duplicates of\r\n\t\t\t// touch events, see #4315.\r\n\t\t\t// Also ignore the event if disabled; this happens in IE11\r\n\t\t\t// under some circumstances, see #3666.\r\n\t\t\tif (e._simulated || !this._enabled) { return; }\r\n\t\r\n\t\t\tthis._moved = false;\r\n\t\r\n\t\t\tif (hasClass(this._element, 'leaflet-zoom-anim')) { return; }\r\n\t\r\n\t\t\tif (Draggable._dragging || e.shiftKey || ((e.which !== 1) && (e.button !== 1) && !e.touches)) { return; }\r\n\t\t\tDraggable._dragging = this; // Prevent dragging multiple objects at once.\r\n\t\r\n\t\t\tif (this._preventOutline) {\r\n\t\t\t\tpreventOutline(this._element);\r\n\t\t\t}\r\n\t\r\n\t\t\tdisableImageDrag();\r\n\t\t\tdisableTextSelection();\r\n\t\r\n\t\t\tif (this._moving) { return; }\r\n\t\r\n\t\t\t// @event down: Event\r\n\t\t\t// Fired when a drag is about to start.\r\n\t\t\tthis.fire('down');\r\n\t\r\n\t\t\tvar first = e.touches ? e.touches[0] : e;\r\n\t\r\n\t\t\tthis._startPoint = new Point(first.clientX, first.clientY);\r\n\t\r\n\t\t\ton(document, MOVE[e.type], this._onMove, this);\r\n\t\t\ton(document, END[e.type], this._onUp, this);\r\n\t\t},\r\n\t\r\n\t\t_onMove: function (e) {\r\n\t\t\t// Ignore simulated events, since we handle both touch and\r\n\t\t\t// mouse explicitly; otherwise we risk getting duplicates of\r\n\t\t\t// touch events, see #4315.\r\n\t\t\t// Also ignore the event if disabled; this happens in IE11\r\n\t\t\t// under some circumstances, see #3666.\r\n\t\t\tif (e._simulated || !this._enabled) { return; }\r\n\t\r\n\t\t\tif (e.touches && e.touches.length > 1) {\r\n\t\t\t\tthis._moved = true;\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\r\n\t\t\tvar first = (e.touches && e.touches.length === 1 ? e.touches[0] : e),\r\n\t\t\t newPoint = new Point(first.clientX, first.clientY),\r\n\t\t\t offset = newPoint.subtract(this._startPoint);\r\n\t\r\n\t\t\tif (!offset.x && !offset.y) { return; }\r\n\t\t\tif (Math.abs(offset.x) + Math.abs(offset.y) < this.options.clickTolerance) { return; }\r\n\t\r\n\t\t\tpreventDefault(e);\r\n\t\r\n\t\t\tif (!this._moved) {\r\n\t\t\t\t// @event dragstart: Event\r\n\t\t\t\t// Fired when a drag starts\r\n\t\t\t\tthis.fire('dragstart');\r\n\t\r\n\t\t\t\tthis._moved = true;\r\n\t\t\t\tthis._startPos = getPosition(this._element).subtract(offset);\r\n\t\r\n\t\t\t\taddClass(document.body, 'leaflet-dragging');\r\n\t\r\n\t\t\t\tthis._lastTarget = e.target || e.srcElement;\r\n\t\t\t\t// IE and Edge do not give the element, so fetch it\r\n\t\t\t\t// if necessary\r\n\t\t\t\tif ((window.SVGElementInstance) && (this._lastTarget instanceof SVGElementInstance)) {\r\n\t\t\t\t\tthis._lastTarget = this._lastTarget.correspondingUseElement;\r\n\t\t\t\t}\r\n\t\t\t\taddClass(this._lastTarget, 'leaflet-drag-target');\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._newPos = this._startPos.add(offset);\r\n\t\t\tthis._moving = true;\r\n\t\r\n\t\t\tcancelAnimFrame(this._animRequest);\r\n\t\t\tthis._lastEvent = e;\r\n\t\t\tthis._animRequest = requestAnimFrame(this._updatePosition, this, true);\r\n\t\t},\r\n\t\r\n\t\t_updatePosition: function () {\r\n\t\t\tvar e = {originalEvent: this._lastEvent};\r\n\t\r\n\t\t\t// @event predrag: Event\r\n\t\t\t// Fired continuously during dragging *before* each corresponding\r\n\t\t\t// update of the element's position.\r\n\t\t\tthis.fire('predrag', e);\r\n\t\t\tsetPosition(this._element, this._newPos);\r\n\t\r\n\t\t\t// @event drag: Event\r\n\t\t\t// Fired continuously during dragging.\r\n\t\t\tthis.fire('drag', e);\r\n\t\t},\r\n\t\r\n\t\t_onUp: function (e) {\r\n\t\t\t// Ignore simulated events, since we handle both touch and\r\n\t\t\t// mouse explicitly; otherwise we risk getting duplicates of\r\n\t\t\t// touch events, see #4315.\r\n\t\t\t// Also ignore the event if disabled; this happens in IE11\r\n\t\t\t// under some circumstances, see #3666.\r\n\t\t\tif (e._simulated || !this._enabled) { return; }\r\n\t\t\tthis.finishDrag();\r\n\t\t},\r\n\t\r\n\t\tfinishDrag: function () {\r\n\t\t\tremoveClass(document.body, 'leaflet-dragging');\r\n\t\r\n\t\t\tif (this._lastTarget) {\r\n\t\t\t\tremoveClass(this._lastTarget, 'leaflet-drag-target');\r\n\t\t\t\tthis._lastTarget = null;\r\n\t\t\t}\r\n\t\r\n\t\t\tfor (var i in MOVE) {\r\n\t\t\t\toff(document, MOVE[i], this._onMove, this);\r\n\t\t\t\toff(document, END[i], this._onUp, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tenableImageDrag();\r\n\t\t\tenableTextSelection();\r\n\t\r\n\t\t\tif (this._moved && this._moving) {\r\n\t\t\t\t// ensure drag is not fired after dragend\r\n\t\t\t\tcancelAnimFrame(this._animRequest);\r\n\t\r\n\t\t\t\t// @event dragend: DragEndEvent\r\n\t\t\t\t// Fired when the drag ends.\r\n\t\t\t\tthis.fire('dragend', {\r\n\t\t\t\t\tdistance: this._newPos.distanceTo(this._startPos)\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._moving = false;\r\n\t\t\tDraggable._dragging = false;\r\n\t\t}\r\n\t\r\n\t});\n\t\n\t/*\r\n\t * @namespace LineUtil\r\n\t *\r\n\t * Various utility functions for polyline points processing, used by Leaflet internally to make polylines lightning-fast.\r\n\t */\r\n\t\r\n\t// Simplify polyline with vertex reduction and Douglas-Peucker simplification.\r\n\t// Improves rendering performance dramatically by lessening the number of points to draw.\r\n\t\r\n\t// @function simplify(points: Point[], tolerance: Number): Point[]\r\n\t// Dramatically reduces the number of points in a polyline while retaining\r\n\t// its shape and returns a new array of simplified points, using the\r\n\t// [Douglas-Peucker algorithm](http://en.wikipedia.org/wiki/Douglas-Peucker_algorithm).\r\n\t// Used for a huge performance boost when processing/displaying Leaflet polylines for\r\n\t// each zoom level and also reducing visual noise. tolerance affects the amount of\r\n\t// simplification (lesser value means higher quality but slower and with more points).\r\n\t// Also released as a separated micro-library [Simplify.js](http://mourner.github.com/simplify-js/).\r\n\tfunction simplify(points, tolerance) {\r\n\t\tif (!tolerance || !points.length) {\r\n\t\t\treturn points.slice();\r\n\t\t}\r\n\t\r\n\t\tvar sqTolerance = tolerance * tolerance;\r\n\t\r\n\t\t // stage 1: vertex reduction\r\n\t\t points = _reducePoints(points, sqTolerance);\r\n\t\r\n\t\t // stage 2: Douglas-Peucker simplification\r\n\t\t points = _simplifyDP(points, sqTolerance);\r\n\t\r\n\t\treturn points;\r\n\t}\r\n\t\r\n\t// @function pointToSegmentDistance(p: Point, p1: Point, p2: Point): Number\r\n\t// Returns the distance between point `p` and segment `p1` to `p2`.\r\n\tfunction pointToSegmentDistance(p, p1, p2) {\r\n\t\treturn Math.sqrt(_sqClosestPointOnSegment(p, p1, p2, true));\r\n\t}\r\n\t\r\n\t// @function closestPointOnSegment(p: Point, p1: Point, p2: Point): Number\r\n\t// Returns the closest point from a point `p` on a segment `p1` to `p2`.\r\n\tfunction closestPointOnSegment(p, p1, p2) {\r\n\t\treturn _sqClosestPointOnSegment(p, p1, p2);\r\n\t}\r\n\t\r\n\t// Douglas-Peucker simplification, see http://en.wikipedia.org/wiki/Douglas-Peucker_algorithm\r\n\tfunction _simplifyDP(points, sqTolerance) {\r\n\t\r\n\t\tvar len = points.length,\r\n\t\t ArrayConstructor = typeof Uint8Array !== undefined + '' ? Uint8Array : Array,\r\n\t\t markers = new ArrayConstructor(len);\r\n\t\r\n\t\t markers[0] = markers[len - 1] = 1;\r\n\t\r\n\t\t_simplifyDPStep(points, markers, sqTolerance, 0, len - 1);\r\n\t\r\n\t\tvar i,\r\n\t\t newPoints = [];\r\n\t\r\n\t\tfor (i = 0; i < len; i++) {\r\n\t\t\tif (markers[i]) {\r\n\t\t\t\tnewPoints.push(points[i]);\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\treturn newPoints;\r\n\t}\r\n\t\r\n\tfunction _simplifyDPStep(points, markers, sqTolerance, first, last) {\r\n\t\r\n\t\tvar maxSqDist = 0,\r\n\t\tindex, i, sqDist;\r\n\t\r\n\t\tfor (i = first + 1; i <= last - 1; i++) {\r\n\t\t\tsqDist = _sqClosestPointOnSegment(points[i], points[first], points[last], true);\r\n\t\r\n\t\t\tif (sqDist > maxSqDist) {\r\n\t\t\t\tindex = i;\r\n\t\t\t\tmaxSqDist = sqDist;\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\tif (maxSqDist > sqTolerance) {\r\n\t\t\tmarkers[index] = 1;\r\n\t\r\n\t\t\t_simplifyDPStep(points, markers, sqTolerance, first, index);\r\n\t\t\t_simplifyDPStep(points, markers, sqTolerance, index, last);\r\n\t\t}\r\n\t}\r\n\t\r\n\t// reduce points that are too close to each other to a single point\r\n\tfunction _reducePoints(points, sqTolerance) {\r\n\t\tvar reducedPoints = [points[0]];\r\n\t\r\n\t\tfor (var i = 1, prev = 0, len = points.length; i < len; i++) {\r\n\t\t\tif (_sqDist(points[i], points[prev]) > sqTolerance) {\r\n\t\t\t\treducedPoints.push(points[i]);\r\n\t\t\t\tprev = i;\r\n\t\t\t}\r\n\t\t}\r\n\t\tif (prev < len - 1) {\r\n\t\t\treducedPoints.push(points[len - 1]);\r\n\t\t}\r\n\t\treturn reducedPoints;\r\n\t}\r\n\t\r\n\tvar _lastCode;\r\n\t\r\n\t// @function clipSegment(a: Point, b: Point, bounds: Bounds, useLastCode?: Boolean, round?: Boolean): Point[]|Boolean\r\n\t// Clips the segment a to b by rectangular bounds with the\r\n\t// [Cohen-Sutherland algorithm](https://en.wikipedia.org/wiki/Cohen%E2%80%93Sutherland_algorithm)\r\n\t// (modifying the segment points directly!). Used by Leaflet to only show polyline\r\n\t// points that are on the screen or near, increasing performance.\r\n\tfunction clipSegment(a, b, bounds, useLastCode, round) {\r\n\t\tvar codeA = useLastCode ? _lastCode : _getBitCode(a, bounds),\r\n\t\t codeB = _getBitCode(b, bounds),\r\n\t\r\n\t\t codeOut, p, newCode;\r\n\t\r\n\t\t // save 2nd code to avoid calculating it on the next segment\r\n\t\t _lastCode = codeB;\r\n\t\r\n\t\twhile (true) {\r\n\t\t\t// if a,b is inside the clip window (trivial accept)\r\n\t\t\tif (!(codeA | codeB)) {\r\n\t\t\t\treturn [a, b];\r\n\t\t\t}\r\n\t\r\n\t\t\t// if a,b is outside the clip window (trivial reject)\r\n\t\t\tif (codeA & codeB) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\r\n\t\t\t// other cases\r\n\t\t\tcodeOut = codeA || codeB;\r\n\t\t\tp = _getEdgeIntersection(a, b, codeOut, bounds, round);\r\n\t\t\tnewCode = _getBitCode(p, bounds);\r\n\t\r\n\t\t\tif (codeOut === codeA) {\r\n\t\t\t\ta = p;\r\n\t\t\t\tcodeA = newCode;\r\n\t\t\t} else {\r\n\t\t\t\tb = p;\r\n\t\t\t\tcodeB = newCode;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\t\r\n\tfunction _getEdgeIntersection(a, b, code, bounds, round) {\r\n\t\tvar dx = b.x - a.x,\r\n\t\t dy = b.y - a.y,\r\n\t\t min = bounds.min,\r\n\t\t max = bounds.max,\r\n\t\t x, y;\r\n\t\r\n\t\tif (code & 8) { // top\r\n\t\t\tx = a.x + dx * (max.y - a.y) / dy;\r\n\t\t\ty = max.y;\r\n\t\r\n\t\t} else if (code & 4) { // bottom\r\n\t\t\tx = a.x + dx * (min.y - a.y) / dy;\r\n\t\t\ty = min.y;\r\n\t\r\n\t\t} else if (code & 2) { // right\r\n\t\t\tx = max.x;\r\n\t\t\ty = a.y + dy * (max.x - a.x) / dx;\r\n\t\r\n\t\t} else if (code & 1) { // left\r\n\t\t\tx = min.x;\r\n\t\t\ty = a.y + dy * (min.x - a.x) / dx;\r\n\t\t}\r\n\t\r\n\t\treturn new Point(x, y, round);\r\n\t}\r\n\t\r\n\tfunction _getBitCode(p, bounds) {\r\n\t\tvar code = 0;\r\n\t\r\n\t\tif (p.x < bounds.min.x) { // left\r\n\t\t\tcode |= 1;\r\n\t\t} else if (p.x > bounds.max.x) { // right\r\n\t\t\tcode |= 2;\r\n\t\t}\r\n\t\r\n\t\tif (p.y < bounds.min.y) { // bottom\r\n\t\t\tcode |= 4;\r\n\t\t} else if (p.y > bounds.max.y) { // top\r\n\t\t\tcode |= 8;\r\n\t\t}\r\n\t\r\n\t\treturn code;\r\n\t}\r\n\t\r\n\t// square distance (to avoid unnecessary Math.sqrt calls)\r\n\tfunction _sqDist(p1, p2) {\r\n\t\tvar dx = p2.x - p1.x,\r\n\t\t dy = p2.y - p1.y;\r\n\t\treturn dx * dx + dy * dy;\r\n\t}\r\n\t\r\n\t// return closest point on segment or distance to that point\r\n\tfunction _sqClosestPointOnSegment(p, p1, p2, sqDist) {\r\n\t\tvar x = p1.x,\r\n\t\t y = p1.y,\r\n\t\t dx = p2.x - x,\r\n\t\t dy = p2.y - y,\r\n\t\t dot = dx * dx + dy * dy,\r\n\t\t t;\r\n\t\r\n\t\tif (dot > 0) {\r\n\t\t\tt = ((p.x - x) * dx + (p.y - y) * dy) / dot;\r\n\t\r\n\t\t\tif (t > 1) {\r\n\t\t\t\tx = p2.x;\r\n\t\t\t\ty = p2.y;\r\n\t\t\t} else if (t > 0) {\r\n\t\t\t\tx += dx * t;\r\n\t\t\t\ty += dy * t;\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\tdx = p.x - x;\r\n\t\tdy = p.y - y;\r\n\t\r\n\t\treturn sqDist ? dx * dx + dy * dy : new Point(x, y);\r\n\t}\r\n\t\r\n\t\r\n\t// @function isFlat(latlngs: LatLng[]): Boolean\r\n\t// Returns true if `latlngs` is a flat array, false is nested.\r\n\tfunction isFlat(latlngs) {\r\n\t\treturn !isArray(latlngs[0]) || (typeof latlngs[0][0] !== 'object' && typeof latlngs[0][0] !== 'undefined');\r\n\t}\r\n\t\r\n\tfunction _flat(latlngs) {\r\n\t\tconsole.warn('Deprecated use of _flat, please use L.LineUtil.isFlat instead.');\r\n\t\treturn isFlat(latlngs);\r\n\t}\r\n\t\n\t\n\tvar LineUtil = (Object.freeze || Object)({\n\t\tsimplify: simplify,\n\t\tpointToSegmentDistance: pointToSegmentDistance,\n\t\tclosestPointOnSegment: closestPointOnSegment,\n\t\tclipSegment: clipSegment,\n\t\t_getEdgeIntersection: _getEdgeIntersection,\n\t\t_getBitCode: _getBitCode,\n\t\t_sqClosestPointOnSegment: _sqClosestPointOnSegment,\n\t\tisFlat: isFlat,\n\t\t_flat: _flat\n\t});\n\t\n\t/*\r\n\t * @namespace PolyUtil\r\n\t * Various utility functions for polygon geometries.\r\n\t */\r\n\t\r\n\t/* @function clipPolygon(points: Point[], bounds: Bounds, round?: Boolean): Point[]\r\n\t * Clips the polygon geometry defined by the given `points` by the given bounds (using the [Sutherland-Hodgman algorithm](https://en.wikipedia.org/wiki/Sutherland%E2%80%93Hodgman_algorithm)).\r\n\t * Used by Leaflet to only show polygon points that are on the screen or near, increasing\r\n\t * performance. Note that polygon points needs different algorithm for clipping\r\n\t * than polyline, so there's a separate method for it.\r\n\t */\r\n\tfunction clipPolygon(points, bounds, round) {\r\n\t\tvar clippedPoints,\r\n\t\t edges = [1, 4, 2, 8],\r\n\t\t i, j, k,\r\n\t\t a, b,\r\n\t\t len, edge, p;\r\n\t\r\n\t\tfor (i = 0, len = points.length; i < len; i++) {\r\n\t\t\tpoints[i]._code = _getBitCode(points[i], bounds);\r\n\t\t}\r\n\t\r\n\t\t// for each edge (left, bottom, right, top)\r\n\t\tfor (k = 0; k < 4; k++) {\r\n\t\t\tedge = edges[k];\r\n\t\t\tclippedPoints = [];\r\n\t\r\n\t\t\tfor (i = 0, len = points.length, j = len - 1; i < len; j = i++) {\r\n\t\t\t\ta = points[i];\r\n\t\t\t\tb = points[j];\r\n\t\r\n\t\t\t\t// if a is inside the clip window\r\n\t\t\t\tif (!(a._code & edge)) {\r\n\t\t\t\t\t// if b is outside the clip window (a->b goes out of screen)\r\n\t\t\t\t\tif (b._code & edge) {\r\n\t\t\t\t\t\tp = _getEdgeIntersection(b, a, edge, bounds, round);\r\n\t\t\t\t\t\tp._code = _getBitCode(p, bounds);\r\n\t\t\t\t\t\tclippedPoints.push(p);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tclippedPoints.push(a);\r\n\t\r\n\t\t\t\t// else if b is inside the clip window (a->b enters the screen)\r\n\t\t\t\t} else if (!(b._code & edge)) {\r\n\t\t\t\t\tp = _getEdgeIntersection(b, a, edge, bounds, round);\r\n\t\t\t\t\tp._code = _getBitCode(p, bounds);\r\n\t\t\t\t\tclippedPoints.push(p);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tpoints = clippedPoints;\r\n\t\t}\r\n\t\r\n\t\treturn points;\r\n\t}\r\n\t\n\t\n\tvar PolyUtil = (Object.freeze || Object)({\n\t\tclipPolygon: clipPolygon\n\t});\n\t\n\t/*\r\n\t * @namespace Projection\r\n\t * @section\r\n\t * Leaflet comes with a set of already defined Projections out of the box:\r\n\t *\r\n\t * @projection L.Projection.LonLat\r\n\t *\r\n\t * Equirectangular, or Plate Carree projection — the most simple projection,\r\n\t * mostly used by GIS enthusiasts. Directly maps `x` as longitude, and `y` as\r\n\t * latitude. Also suitable for flat worlds, e.g. game maps. Used by the\r\n\t * `EPSG:4326` and `Simple` CRS.\r\n\t */\r\n\t\r\n\tvar LonLat = {\r\n\t\tproject: function (latlng) {\r\n\t\t\treturn new Point(latlng.lng, latlng.lat);\r\n\t\t},\r\n\t\r\n\t\tunproject: function (point) {\r\n\t\t\treturn new LatLng(point.y, point.x);\r\n\t\t},\r\n\t\r\n\t\tbounds: new Bounds([-180, -90], [180, 90])\r\n\t};\n\t\n\t/*\r\n\t * @namespace Projection\r\n\t * @projection L.Projection.Mercator\r\n\t *\r\n\t * Elliptical Mercator projection — more complex than Spherical Mercator. Takes into account that Earth is a geoid, not a perfect sphere. Used by the EPSG:3395 CRS.\r\n\t */\r\n\t\r\n\tvar Mercator = {\r\n\t\tR: 6378137,\r\n\t\tR_MINOR: 6356752.314245179,\r\n\t\r\n\t\tbounds: new Bounds([-20037508.34279, -15496570.73972], [20037508.34279, 18764656.23138]),\r\n\t\r\n\t\tproject: function (latlng) {\r\n\t\t\tvar d = Math.PI / 180,\r\n\t\t\t r = this.R,\r\n\t\t\t y = latlng.lat * d,\r\n\t\t\t tmp = this.R_MINOR / r,\r\n\t\t\t e = Math.sqrt(1 - tmp * tmp),\r\n\t\t\t con = e * Math.sin(y);\r\n\t\r\n\t\t\tvar ts = Math.tan(Math.PI / 4 - y / 2) / Math.pow((1 - con) / (1 + con), e / 2);\r\n\t\t\ty = -r * Math.log(Math.max(ts, 1E-10));\r\n\t\r\n\t\t\treturn new Point(latlng.lng * d * r, y);\r\n\t\t},\r\n\t\r\n\t\tunproject: function (point) {\r\n\t\t\tvar d = 180 / Math.PI,\r\n\t\t\t r = this.R,\r\n\t\t\t tmp = this.R_MINOR / r,\r\n\t\t\t e = Math.sqrt(1 - tmp * tmp),\r\n\t\t\t ts = Math.exp(-point.y / r),\r\n\t\t\t phi = Math.PI / 2 - 2 * Math.atan(ts);\r\n\t\r\n\t\t\tfor (var i = 0, dphi = 0.1, con; i < 15 && Math.abs(dphi) > 1e-7; i++) {\r\n\t\t\t\tcon = e * Math.sin(phi);\r\n\t\t\t\tcon = Math.pow((1 - con) / (1 + con), e / 2);\r\n\t\t\t\tdphi = Math.PI / 2 - 2 * Math.atan(ts * con) - phi;\r\n\t\t\t\tphi += dphi;\r\n\t\t\t}\r\n\t\r\n\t\t\treturn new LatLng(phi * d, point.x * d / r);\r\n\t\t}\r\n\t};\n\t\n\t/*\n\t * @class Projection\n\t\n\t * An object with methods for projecting geographical coordinates of the world onto\n\t * a flat surface (and back). See [Map projection](http://en.wikipedia.org/wiki/Map_projection).\n\t\n\t * @property bounds: Bounds\n\t * The bounds (specified in CRS units) where the projection is valid\n\t\n\t * @method project(latlng: LatLng): Point\n\t * Projects geographical coordinates into a 2D point.\n\t * Only accepts actual `L.LatLng` instances, not arrays.\n\t\n\t * @method unproject(point: Point): LatLng\n\t * The inverse of `project`. Projects a 2D point into a geographical location.\n\t * Only accepts actual `L.Point` instances, not arrays.\n\t\n\t * Note that the projection instances do not inherit from Leafet's `Class` object,\n\t * and can't be instantiated. Also, new classes can't inherit from them,\n\t * and methods can't be added to them with the `include` function.\n\t\n\t */\n\t\n\t\n\t\n\t\n\tvar index = (Object.freeze || Object)({\n\t\tLonLat: LonLat,\n\t\tMercator: Mercator,\n\t\tSphericalMercator: SphericalMercator\n\t});\n\t\n\t/*\r\n\t * @namespace CRS\r\n\t * @crs L.CRS.EPSG3395\r\n\t *\r\n\t * Rarely used by some commercial tile providers. Uses Elliptical Mercator projection.\r\n\t */\r\n\tvar EPSG3395 = extend({}, Earth, {\r\n\t\tcode: 'EPSG:3395',\r\n\t\tprojection: Mercator,\r\n\t\r\n\t\ttransformation: (function () {\r\n\t\t\tvar scale = 0.5 / (Math.PI * Mercator.R);\r\n\t\t\treturn toTransformation(scale, 0.5, -scale, 0.5);\r\n\t\t}())\r\n\t});\n\t\n\t/*\r\n\t * @namespace CRS\r\n\t * @crs L.CRS.EPSG4326\r\n\t *\r\n\t * A common CRS among GIS enthusiasts. Uses simple Equirectangular projection.\r\n\t *\r\n\t * Leaflet 1.0.x complies with the [TMS coordinate scheme for EPSG:4326](https://wiki.osgeo.org/wiki/Tile_Map_Service_Specification#global-geodetic),\r\n\t * which is a breaking change from 0.7.x behaviour. If you are using a `TileLayer`\r\n\t * with this CRS, ensure that there are two 256x256 pixel tiles covering the\r\n\t * whole earth at zoom level zero, and that the tile coordinate origin is (-180,+90),\r\n\t * or (-180,-90) for `TileLayer`s with [the `tms` option](#tilelayer-tms) set.\r\n\t */\r\n\t\r\n\tvar EPSG4326 = extend({}, Earth, {\r\n\t\tcode: 'EPSG:4326',\r\n\t\tprojection: LonLat,\r\n\t\ttransformation: toTransformation(1 / 180, 1, -1 / 180, 0.5)\r\n\t});\n\t\n\t/*\n\t * @namespace CRS\n\t * @crs L.CRS.Simple\n\t *\n\t * A simple CRS that maps longitude and latitude into `x` and `y` directly.\n\t * May be used for maps of flat surfaces (e.g. game maps). Note that the `y`\n\t * axis should still be inverted (going from bottom to top). `distance()` returns\n\t * simple euclidean distance.\n\t */\n\t\n\tvar Simple = extend({}, CRS, {\n\t\tprojection: LonLat,\n\t\ttransformation: toTransformation(1, 0, -1, 0),\n\t\n\t\tscale: function (zoom) {\n\t\t\treturn Math.pow(2, zoom);\n\t\t},\n\t\n\t\tzoom: function (scale) {\n\t\t\treturn Math.log(scale) / Math.LN2;\n\t\t},\n\t\n\t\tdistance: function (latlng1, latlng2) {\n\t\t\tvar dx = latlng2.lng - latlng1.lng,\n\t\t\t dy = latlng2.lat - latlng1.lat;\n\t\n\t\t\treturn Math.sqrt(dx * dx + dy * dy);\n\t\t},\n\t\n\t\tinfinite: true\n\t});\n\t\n\tCRS.Earth = Earth;\n\tCRS.EPSG3395 = EPSG3395;\n\tCRS.EPSG3857 = EPSG3857;\n\tCRS.EPSG900913 = EPSG900913;\n\tCRS.EPSG4326 = EPSG4326;\n\tCRS.Simple = Simple;\n\t\n\t/*\n\t * @class Layer\n\t * @inherits Evented\n\t * @aka L.Layer\n\t * @aka ILayer\n\t *\n\t * A set of methods from the Layer base class that all Leaflet layers use.\n\t * Inherits all methods, options and events from `L.Evented`.\n\t *\n\t * @example\n\t *\n\t * ```js\n\t * var layer = L.Marker(latlng).addTo(map);\n\t * layer.addTo(map);\n\t * layer.remove();\n\t * ```\n\t *\n\t * @event add: Event\n\t * Fired after the layer is added to a map\n\t *\n\t * @event remove: Event\n\t * Fired after the layer is removed from a map\n\t */\n\t\n\t\n\tvar Layer = Evented.extend({\n\t\n\t\t// Classes extending `L.Layer` will inherit the following options:\n\t\toptions: {\n\t\t\t// @option pane: String = 'overlayPane'\n\t\t\t// By default the layer will be added to the map's [overlay pane](#map-overlaypane). Overriding this option will cause the layer to be placed on another pane by default.\n\t\t\tpane: 'overlayPane',\n\t\n\t\t\t// @option attribution: String = null\n\t\t\t// String to be shown in the attribution control, describes the layer data, e.g. \"© Mapbox\".\n\t\t\tattribution: null,\n\t\n\t\t\tbubblingMouseEvents: true\n\t\t},\n\t\n\t\t/* @section\n\t\t * Classes extending `L.Layer` will inherit the following methods:\n\t\t *\n\t\t * @method addTo(map: Map|LayerGroup): this\n\t\t * Adds the layer to the given map or layer group.\n\t\t */\n\t\taddTo: function (map) {\n\t\t\tmap.addLayer(this);\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method remove: this\n\t\t// Removes the layer from the map it is currently active on.\n\t\tremove: function () {\n\t\t\treturn this.removeFrom(this._map || this._mapToAdd);\n\t\t},\n\t\n\t\t// @method removeFrom(map: Map): this\n\t\t// Removes the layer from the given map\n\t\tremoveFrom: function (obj) {\n\t\t\tif (obj) {\n\t\t\t\tobj.removeLayer(this);\n\t\t\t}\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method getPane(name? : String): HTMLElement\n\t\t// Returns the `HTMLElement` representing the named pane on the map. If `name` is omitted, returns the pane for this layer.\n\t\tgetPane: function (name) {\n\t\t\treturn this._map.getPane(name ? (this.options[name] || name) : this.options.pane);\n\t\t},\n\t\n\t\taddInteractiveTarget: function (targetEl) {\n\t\t\tthis._map._targets[stamp(targetEl)] = this;\n\t\t\treturn this;\n\t\t},\n\t\n\t\tremoveInteractiveTarget: function (targetEl) {\n\t\t\tdelete this._map._targets[stamp(targetEl)];\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method getAttribution: String\n\t\t// Used by the `attribution control`, returns the [attribution option](#gridlayer-attribution).\n\t\tgetAttribution: function () {\n\t\t\treturn this.options.attribution;\n\t\t},\n\t\n\t\t_layerAdd: function (e) {\n\t\t\tvar map = e.target;\n\t\n\t\t\t// check in case layer gets added and then removed before the map is ready\n\t\t\tif (!map.hasLayer(this)) { return; }\n\t\n\t\t\tthis._map = map;\n\t\t\tthis._zoomAnimated = map._zoomAnimated;\n\t\n\t\t\tif (this.getEvents) {\n\t\t\t\tvar events = this.getEvents();\n\t\t\t\tmap.on(events, this);\n\t\t\t\tthis.once('remove', function () {\n\t\t\t\t\tmap.off(events, this);\n\t\t\t\t}, this);\n\t\t\t}\n\t\n\t\t\tthis.onAdd(map);\n\t\n\t\t\tif (this.getAttribution && map.attributionControl) {\n\t\t\t\tmap.attributionControl.addAttribution(this.getAttribution());\n\t\t\t}\n\t\n\t\t\tthis.fire('add');\n\t\t\tmap.fire('layeradd', {layer: this});\n\t\t}\n\t});\n\t\n\t/* @section Extension methods\n\t * @uninheritable\n\t *\n\t * Every layer should extend from `L.Layer` and (re-)implement the following methods.\n\t *\n\t * @method onAdd(map: Map): this\n\t * Should contain code that creates DOM elements for the layer, adds them to `map panes` where they should belong and puts listeners on relevant map events. Called on [`map.addLayer(layer)`](#map-addlayer).\n\t *\n\t * @method onRemove(map: Map): this\n\t * Should contain all clean up code that removes the layer's elements from the DOM and removes listeners previously added in [`onAdd`](#layer-onadd). Called on [`map.removeLayer(layer)`](#map-removelayer).\n\t *\n\t * @method getEvents(): Object\n\t * This optional method should return an object like `{ viewreset: this._reset }` for [`addEventListener`](#evented-addeventlistener). The event handlers in this object will be automatically added and removed from the map with your layer.\n\t *\n\t * @method getAttribution(): String\n\t * This optional method should return a string containing HTML to be shown on the `Attribution control` whenever the layer is visible.\n\t *\n\t * @method beforeAdd(map: Map): this\n\t * Optional method. Called on [`map.addLayer(layer)`](#map-addlayer), before the layer is added to the map, before events are initialized, without waiting until the map is in a usable state. Use for early initialization only.\n\t */\n\t\n\t\n\t/* @namespace Map\n\t * @section Layer events\n\t *\n\t * @event layeradd: LayerEvent\n\t * Fired when a new layer is added to the map.\n\t *\n\t * @event layerremove: LayerEvent\n\t * Fired when some layer is removed from the map\n\t *\n\t * @section Methods for Layers and Controls\n\t */\n\tMap.include({\n\t\t// @method addLayer(layer: Layer): this\n\t\t// Adds the given layer to the map\n\t\taddLayer: function (layer) {\n\t\t\tif (!layer._layerAdd) {\n\t\t\t\tthrow new Error('The provided object is not a Layer.');\n\t\t\t}\n\t\n\t\t\tvar id = stamp(layer);\n\t\t\tif (this._layers[id]) { return this; }\n\t\t\tthis._layers[id] = layer;\n\t\n\t\t\tlayer._mapToAdd = this;\n\t\n\t\t\tif (layer.beforeAdd) {\n\t\t\t\tlayer.beforeAdd(this);\n\t\t\t}\n\t\n\t\t\tthis.whenReady(layer._layerAdd, layer);\n\t\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method removeLayer(layer: Layer): this\n\t\t// Removes the given layer from the map.\n\t\tremoveLayer: function (layer) {\n\t\t\tvar id = stamp(layer);\n\t\n\t\t\tif (!this._layers[id]) { return this; }\n\t\n\t\t\tif (this._loaded) {\n\t\t\t\tlayer.onRemove(this);\n\t\t\t}\n\t\n\t\t\tif (layer.getAttribution && this.attributionControl) {\n\t\t\t\tthis.attributionControl.removeAttribution(layer.getAttribution());\n\t\t\t}\n\t\n\t\t\tdelete this._layers[id];\n\t\n\t\t\tif (this._loaded) {\n\t\t\t\tthis.fire('layerremove', {layer: layer});\n\t\t\t\tlayer.fire('remove');\n\t\t\t}\n\t\n\t\t\tlayer._map = layer._mapToAdd = null;\n\t\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method hasLayer(layer: Layer): Boolean\n\t\t// Returns `true` if the given layer is currently added to the map\n\t\thasLayer: function (layer) {\n\t\t\treturn !!layer && (stamp(layer) in this._layers);\n\t\t},\n\t\n\t\t/* @method eachLayer(fn: Function, context?: Object): this\n\t\t * Iterates over the layers of the map, optionally specifying context of the iterator function.\n\t\t * ```\n\t\t * map.eachLayer(function(layer){\n\t\t * layer.bindPopup('Hello');\n\t\t * });\n\t\t * ```\n\t\t */\n\t\teachLayer: function (method, context) {\n\t\t\tfor (var i in this._layers) {\n\t\t\t\tmethod.call(context, this._layers[i]);\n\t\t\t}\n\t\t\treturn this;\n\t\t},\n\t\n\t\t_addLayers: function (layers) {\n\t\t\tlayers = layers ? (isArray(layers) ? layers : [layers]) : [];\n\t\n\t\t\tfor (var i = 0, len = layers.length; i < len; i++) {\n\t\t\t\tthis.addLayer(layers[i]);\n\t\t\t}\n\t\t},\n\t\n\t\t_addZoomLimit: function (layer) {\n\t\t\tif (isNaN(layer.options.maxZoom) || !isNaN(layer.options.minZoom)) {\n\t\t\t\tthis._zoomBoundLayers[stamp(layer)] = layer;\n\t\t\t\tthis._updateZoomLevels();\n\t\t\t}\n\t\t},\n\t\n\t\t_removeZoomLimit: function (layer) {\n\t\t\tvar id = stamp(layer);\n\t\n\t\t\tif (this._zoomBoundLayers[id]) {\n\t\t\t\tdelete this._zoomBoundLayers[id];\n\t\t\t\tthis._updateZoomLevels();\n\t\t\t}\n\t\t},\n\t\n\t\t_updateZoomLevels: function () {\n\t\t\tvar minZoom = Infinity,\n\t\t\t maxZoom = -Infinity,\n\t\t\t oldZoomSpan = this._getZoomSpan();\n\t\n\t\t\tfor (var i in this._zoomBoundLayers) {\n\t\t\t\tvar options = this._zoomBoundLayers[i].options;\n\t\n\t\t\t\tminZoom = options.minZoom === undefined ? minZoom : Math.min(minZoom, options.minZoom);\n\t\t\t\tmaxZoom = options.maxZoom === undefined ? maxZoom : Math.max(maxZoom, options.maxZoom);\n\t\t\t}\n\t\n\t\t\tthis._layersMaxZoom = maxZoom === -Infinity ? undefined : maxZoom;\n\t\t\tthis._layersMinZoom = minZoom === Infinity ? undefined : minZoom;\n\t\n\t\t\t// @section Map state change events\n\t\t\t// @event zoomlevelschange: Event\n\t\t\t// Fired when the number of zoomlevels on the map is changed due\n\t\t\t// to adding or removing a layer.\n\t\t\tif (oldZoomSpan !== this._getZoomSpan()) {\n\t\t\t\tthis.fire('zoomlevelschange');\n\t\t\t}\n\t\n\t\t\tif (this.options.maxZoom === undefined && this._layersMaxZoom && this.getZoom() > this._layersMaxZoom) {\n\t\t\t\tthis.setZoom(this._layersMaxZoom);\n\t\t\t}\n\t\t\tif (this.options.minZoom === undefined && this._layersMinZoom && this.getZoom() < this._layersMinZoom) {\n\t\t\t\tthis.setZoom(this._layersMinZoom);\n\t\t\t}\n\t\t}\n\t});\n\t\n\t/*\r\n\t * @class LayerGroup\r\n\t * @aka L.LayerGroup\r\n\t * @inherits Layer\r\n\t *\r\n\t * Used to group several layers and handle them as one. If you add it to the map,\r\n\t * any layers added or removed from the group will be added/removed on the map as\r\n\t * well. Extends `Layer`.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * L.layerGroup([marker1, marker2])\r\n\t * \t.addLayer(polyline)\r\n\t * \t.addTo(map);\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar LayerGroup = Layer.extend({\r\n\t\r\n\t\tinitialize: function (layers, options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\r\n\t\t\tthis._layers = {};\r\n\t\r\n\t\t\tvar i, len;\r\n\t\r\n\t\t\tif (layers) {\r\n\t\t\t\tfor (i = 0, len = layers.length; i < len; i++) {\r\n\t\t\t\t\tthis.addLayer(layers[i]);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @method addLayer(layer: Layer): this\r\n\t\t// Adds the given layer to the group.\r\n\t\taddLayer: function (layer) {\r\n\t\t\tvar id = this.getLayerId(layer);\r\n\t\r\n\t\t\tthis._layers[id] = layer;\r\n\t\r\n\t\t\tif (this._map) {\r\n\t\t\t\tthis._map.addLayer(layer);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method removeLayer(layer: Layer): this\r\n\t\t// Removes the given layer from the group.\r\n\t\t// @alternative\r\n\t\t// @method removeLayer(id: Number): this\r\n\t\t// Removes the layer with the given internal ID from the group.\r\n\t\tremoveLayer: function (layer) {\r\n\t\t\tvar id = layer in this._layers ? layer : this.getLayerId(layer);\r\n\t\r\n\t\t\tif (this._map && this._layers[id]) {\r\n\t\t\t\tthis._map.removeLayer(this._layers[id]);\r\n\t\t\t}\r\n\t\r\n\t\t\tdelete this._layers[id];\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method hasLayer(layer: Layer): Boolean\r\n\t\t// Returns `true` if the given layer is currently added to the group.\r\n\t\t// @alternative\r\n\t\t// @method hasLayer(id: Number): Boolean\r\n\t\t// Returns `true` if the given internal ID is currently added to the group.\r\n\t\thasLayer: function (layer) {\r\n\t\t\treturn !!layer && (layer in this._layers || this.getLayerId(layer) in this._layers);\r\n\t\t},\r\n\t\r\n\t\t// @method clearLayers(): this\r\n\t\t// Removes all the layers from the group.\r\n\t\tclearLayers: function () {\r\n\t\t\treturn this.eachLayer(this.removeLayer, this);\r\n\t\t},\r\n\t\r\n\t\t// @method invoke(methodName: String, …): this\r\n\t\t// Calls `methodName` on every layer contained in this group, passing any\r\n\t\t// additional parameters. Has no effect if the layers contained do not\r\n\t\t// implement `methodName`.\r\n\t\tinvoke: function (methodName) {\r\n\t\t\tvar args = Array.prototype.slice.call(arguments, 1),\r\n\t\t\t i, layer;\r\n\t\r\n\t\t\tfor (i in this._layers) {\r\n\t\t\t\tlayer = this._layers[i];\r\n\t\r\n\t\t\t\tif (layer[methodName]) {\r\n\t\t\t\t\tlayer[methodName].apply(layer, args);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\tonAdd: function (map) {\r\n\t\t\tthis.eachLayer(map.addLayer, map);\r\n\t\t},\r\n\t\r\n\t\tonRemove: function (map) {\r\n\t\t\tthis.eachLayer(map.removeLayer, map);\r\n\t\t},\r\n\t\r\n\t\t// @method eachLayer(fn: Function, context?: Object): this\r\n\t\t// Iterates over the layers of the group, optionally specifying context of the iterator function.\r\n\t\t// ```js\r\n\t\t// group.eachLayer(function (layer) {\r\n\t\t// \tlayer.bindPopup('Hello');\r\n\t\t// });\r\n\t\t// ```\r\n\t\teachLayer: function (method, context) {\r\n\t\t\tfor (var i in this._layers) {\r\n\t\t\t\tmethod.call(context, this._layers[i]);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method getLayer(id: Number): Layer\r\n\t\t// Returns the layer with the given internal ID.\r\n\t\tgetLayer: function (id) {\r\n\t\t\treturn this._layers[id];\r\n\t\t},\r\n\t\r\n\t\t// @method getLayers(): Layer[]\r\n\t\t// Returns an array of all the layers added to the group.\r\n\t\tgetLayers: function () {\r\n\t\t\tvar layers = [];\r\n\t\t\tthis.eachLayer(layers.push, layers);\r\n\t\t\treturn layers;\r\n\t\t},\r\n\t\r\n\t\t// @method setZIndex(zIndex: Number): this\r\n\t\t// Calls `setZIndex` on every layer contained in this group, passing the z-index.\r\n\t\tsetZIndex: function (zIndex) {\r\n\t\t\treturn this.invoke('setZIndex', zIndex);\r\n\t\t},\r\n\t\r\n\t\t// @method getLayerId(layer: Layer): Number\r\n\t\t// Returns the internal ID for a layer\r\n\t\tgetLayerId: function (layer) {\r\n\t\t\treturn stamp(layer);\r\n\t\t}\r\n\t});\r\n\t\r\n\t\r\n\t// @factory L.layerGroup(layers?: Layer[], options?: Object)\r\n\t// Create a layer group, optionally given an initial set of layers and an `options` object.\r\n\tvar layerGroup = function (layers, options) {\r\n\t\treturn new LayerGroup(layers, options);\r\n\t};\n\t\n\t/*\r\n\t * @class FeatureGroup\r\n\t * @aka L.FeatureGroup\r\n\t * @inherits LayerGroup\r\n\t *\r\n\t * Extended `LayerGroup` that makes it easier to do the same thing to all its member layers:\r\n\t * * [`bindPopup`](#layer-bindpopup) binds a popup to all of the layers at once (likewise with [`bindTooltip`](#layer-bindtooltip))\r\n\t * * Events are propagated to the `FeatureGroup`, so if the group has an event\r\n\t * handler, it will handle events from any of the layers. This includes mouse events\r\n\t * and custom events.\r\n\t * * Has `layeradd` and `layerremove` events\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * L.featureGroup([marker1, marker2, polyline])\r\n\t * \t.bindPopup('Hello world!')\r\n\t * \t.on('click', function() { alert('Clicked on a member of the group!'); })\r\n\t * \t.addTo(map);\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar FeatureGroup = LayerGroup.extend({\r\n\t\r\n\t\taddLayer: function (layer) {\r\n\t\t\tif (this.hasLayer(layer)) {\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\r\n\t\t\tlayer.addEventParent(this);\r\n\t\r\n\t\t\tLayerGroup.prototype.addLayer.call(this, layer);\r\n\t\r\n\t\t\t// @event layeradd: LayerEvent\r\n\t\t\t// Fired when a layer is added to this `FeatureGroup`\r\n\t\t\treturn this.fire('layeradd', {layer: layer});\r\n\t\t},\r\n\t\r\n\t\tremoveLayer: function (layer) {\r\n\t\t\tif (!this.hasLayer(layer)) {\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\t\tif (layer in this._layers) {\r\n\t\t\t\tlayer = this._layers[layer];\r\n\t\t\t}\r\n\t\r\n\t\t\tlayer.removeEventParent(this);\r\n\t\r\n\t\t\tLayerGroup.prototype.removeLayer.call(this, layer);\r\n\t\r\n\t\t\t// @event layerremove: LayerEvent\r\n\t\t\t// Fired when a layer is removed from this `FeatureGroup`\r\n\t\t\treturn this.fire('layerremove', {layer: layer});\r\n\t\t},\r\n\t\r\n\t\t// @method setStyle(style: Path options): this\r\n\t\t// Sets the given path options to each layer of the group that has a `setStyle` method.\r\n\t\tsetStyle: function (style) {\r\n\t\t\treturn this.invoke('setStyle', style);\r\n\t\t},\r\n\t\r\n\t\t// @method bringToFront(): this\r\n\t\t// Brings the layer group to the top of all other layers\r\n\t\tbringToFront: function () {\r\n\t\t\treturn this.invoke('bringToFront');\r\n\t\t},\r\n\t\r\n\t\t// @method bringToBack(): this\r\n\t\t// Brings the layer group to the back of all other layers\r\n\t\tbringToBack: function () {\r\n\t\t\treturn this.invoke('bringToBack');\r\n\t\t},\r\n\t\r\n\t\t// @method getBounds(): LatLngBounds\r\n\t\t// Returns the LatLngBounds of the Feature Group (created from bounds and coordinates of its children).\r\n\t\tgetBounds: function () {\r\n\t\t\tvar bounds = new LatLngBounds();\r\n\t\r\n\t\t\tfor (var id in this._layers) {\r\n\t\t\t\tvar layer = this._layers[id];\r\n\t\t\t\tbounds.extend(layer.getBounds ? layer.getBounds() : layer.getLatLng());\r\n\t\t\t}\r\n\t\t\treturn bounds;\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @factory L.featureGroup(layers: Layer[])\r\n\t// Create a feature group, optionally given an initial set of layers.\r\n\tvar featureGroup = function (layers) {\r\n\t\treturn new FeatureGroup(layers);\r\n\t};\n\t\n\t/*\r\n\t * @class Icon\r\n\t * @aka L.Icon\r\n\t *\r\n\t * Represents an icon to provide when creating a marker.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var myIcon = L.icon({\r\n\t * iconUrl: 'my-icon.png',\r\n\t * iconRetinaUrl: 'my-icon@2x.png',\r\n\t * iconSize: [38, 95],\r\n\t * iconAnchor: [22, 94],\r\n\t * popupAnchor: [-3, -76],\r\n\t * shadowUrl: 'my-icon-shadow.png',\r\n\t * shadowRetinaUrl: 'my-icon-shadow@2x.png',\r\n\t * shadowSize: [68, 95],\r\n\t * shadowAnchor: [22, 94]\r\n\t * });\r\n\t *\r\n\t * L.marker([50.505, 30.57], {icon: myIcon}).addTo(map);\r\n\t * ```\r\n\t *\r\n\t * `L.Icon.Default` extends `L.Icon` and is the blue icon Leaflet uses for markers by default.\r\n\t *\r\n\t */\r\n\t\r\n\tvar Icon = Class.extend({\r\n\t\r\n\t\t/* @section\r\n\t\t * @aka Icon options\r\n\t\t *\r\n\t\t * @option iconUrl: String = null\r\n\t\t * **(required)** The URL to the icon image (absolute or relative to your script path).\r\n\t\t *\r\n\t\t * @option iconRetinaUrl: String = null\r\n\t\t * The URL to a retina sized version of the icon image (absolute or relative to your\r\n\t\t * script path). Used for Retina screen devices.\r\n\t\t *\r\n\t\t * @option iconSize: Point = null\r\n\t\t * Size of the icon image in pixels.\r\n\t\t *\r\n\t\t * @option iconAnchor: Point = null\r\n\t\t * The coordinates of the \"tip\" of the icon (relative to its top left corner). The icon\r\n\t\t * will be aligned so that this point is at the marker's geographical location. Centered\r\n\t\t * by default if size is specified, also can be set in CSS with negative margins.\r\n\t\t *\r\n\t\t * @option popupAnchor: Point = [0, 0]\r\n\t\t * The coordinates of the point from which popups will \"open\", relative to the icon anchor.\r\n\t\t *\r\n\t\t * @option tooltipAnchor: Point = [0, 0]\r\n\t\t * The coordinates of the point from which tooltips will \"open\", relative to the icon anchor.\r\n\t\t *\r\n\t\t * @option shadowUrl: String = null\r\n\t\t * The URL to the icon shadow image. If not specified, no shadow image will be created.\r\n\t\t *\r\n\t\t * @option shadowRetinaUrl: String = null\r\n\t\t *\r\n\t\t * @option shadowSize: Point = null\r\n\t\t * Size of the shadow image in pixels.\r\n\t\t *\r\n\t\t * @option shadowAnchor: Point = null\r\n\t\t * The coordinates of the \"tip\" of the shadow (relative to its top left corner) (the same\r\n\t\t * as iconAnchor if not specified).\r\n\t\t *\r\n\t\t * @option className: String = ''\r\n\t\t * A custom class name to assign to both icon and shadow images. Empty by default.\r\n\t\t */\r\n\t\r\n\t\toptions: {\r\n\t\t\tpopupAnchor: [0, 0],\r\n\t\t\ttooltipAnchor: [0, 0],\r\n\t\t},\r\n\t\r\n\t\tinitialize: function (options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\t},\r\n\t\r\n\t\t// @method createIcon(oldIcon?: HTMLElement): HTMLElement\r\n\t\t// Called internally when the icon has to be shown, returns a `` HTML element\r\n\t\t// styled according to the options.\r\n\t\tcreateIcon: function (oldIcon) {\r\n\t\t\treturn this._createIcon('icon', oldIcon);\r\n\t\t},\r\n\t\r\n\t\t// @method createShadow(oldIcon?: HTMLElement): HTMLElement\r\n\t\t// As `createIcon`, but for the shadow beneath it.\r\n\t\tcreateShadow: function (oldIcon) {\r\n\t\t\treturn this._createIcon('shadow', oldIcon);\r\n\t\t},\r\n\t\r\n\t\t_createIcon: function (name, oldIcon) {\r\n\t\t\tvar src = this._getIconUrl(name);\r\n\t\r\n\t\t\tif (!src) {\r\n\t\t\t\tif (name === 'icon') {\r\n\t\t\t\t\tthrow new Error('iconUrl not set in Icon options (see the docs).');\r\n\t\t\t\t}\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\t\r\n\t\t\tvar img = this._createImg(src, oldIcon && oldIcon.tagName === 'IMG' ? oldIcon : null);\r\n\t\t\tthis._setIconStyles(img, name);\r\n\t\r\n\t\t\treturn img;\r\n\t\t},\r\n\t\r\n\t\t_setIconStyles: function (img, name) {\r\n\t\t\tvar options = this.options;\r\n\t\t\tvar sizeOption = options[name + 'Size'];\r\n\t\r\n\t\t\tif (typeof sizeOption === 'number') {\r\n\t\t\t\tsizeOption = [sizeOption, sizeOption];\r\n\t\t\t}\r\n\t\r\n\t\t\tvar size = toPoint(sizeOption),\r\n\t\t\t anchor = toPoint(name === 'shadow' && options.shadowAnchor || options.iconAnchor ||\r\n\t\t\t size && size.divideBy(2, true));\r\n\t\r\n\t\t\timg.className = 'leaflet-marker-' + name + ' ' + (options.className || '');\r\n\t\r\n\t\t\tif (anchor) {\r\n\t\t\t\timg.style.marginLeft = (-anchor.x) + 'px';\r\n\t\t\t\timg.style.marginTop = (-anchor.y) + 'px';\r\n\t\t\t}\r\n\t\r\n\t\t\tif (size) {\r\n\t\t\t\timg.style.width = size.x + 'px';\r\n\t\t\t\timg.style.height = size.y + 'px';\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_createImg: function (src, el) {\r\n\t\t\tel = el || document.createElement('img');\r\n\t\t\tel.src = src;\r\n\t\t\treturn el;\r\n\t\t},\r\n\t\r\n\t\t_getIconUrl: function (name) {\r\n\t\t\treturn retina && this.options[name + 'RetinaUrl'] || this.options[name + 'Url'];\r\n\t\t}\r\n\t});\r\n\t\r\n\t\r\n\t// @factory L.icon(options: Icon options)\r\n\t// Creates an icon instance with the given options.\r\n\tfunction icon(options) {\r\n\t\treturn new Icon(options);\r\n\t}\n\t\n\t/*\n\t * @miniclass Icon.Default (Icon)\n\t * @aka L.Icon.Default\n\t * @section\n\t *\n\t * A trivial subclass of `Icon`, represents the icon to use in `Marker`s when\n\t * no icon is specified. Points to the blue marker image distributed with Leaflet\n\t * releases.\n\t *\n\t * In order to customize the default icon, just change the properties of `L.Icon.Default.prototype.options`\n\t * (which is a set of `Icon options`).\n\t *\n\t * If you want to _completely_ replace the default icon, override the\n\t * `L.Marker.prototype.options.icon` with your own icon instead.\n\t */\n\t\n\tvar IconDefault = Icon.extend({\n\t\n\t\toptions: {\n\t\t\ticonUrl: 'marker-icon.png',\n\t\t\ticonRetinaUrl: 'marker-icon-2x.png',\n\t\t\tshadowUrl: 'marker-shadow.png',\n\t\t\ticonSize: [25, 41],\n\t\t\ticonAnchor: [12, 41],\n\t\t\tpopupAnchor: [1, -34],\n\t\t\ttooltipAnchor: [16, -28],\n\t\t\tshadowSize: [41, 41]\n\t\t},\n\t\n\t\t_getIconUrl: function (name) {\n\t\t\tif (!IconDefault.imagePath) {\t// Deprecated, backwards-compatibility only\n\t\t\t\tIconDefault.imagePath = this._detectIconPath();\n\t\t\t}\n\t\n\t\t\t// @option imagePath: String\n\t\t\t// `Icon.Default` will try to auto-detect the location of the\n\t\t\t// blue icon images. If you are placing these images in a non-standard\n\t\t\t// way, set this option to point to the right path.\n\t\t\treturn (this.options.imagePath || IconDefault.imagePath) + Icon.prototype._getIconUrl.call(this, name);\n\t\t},\n\t\n\t\t_detectIconPath: function () {\n\t\t\tvar el = create$1('div', 'leaflet-default-icon-path', document.body);\n\t\t\tvar path = getStyle(el, 'background-image') ||\n\t\t\t getStyle(el, 'backgroundImage');\t// IE8\n\t\n\t\t\tdocument.body.removeChild(el);\n\t\n\t\t\tif (path === null || path.indexOf('url') !== 0) {\n\t\t\t\tpath = '';\n\t\t\t} else {\n\t\t\t\tpath = path.replace(/^url\\([\"']?/, '').replace(/marker-icon\\.png[\"']?\\)$/, '');\n\t\t\t}\n\t\n\t\t\treturn path;\n\t\t}\n\t});\n\t\n\t/*\n\t * L.Handler.MarkerDrag is used internally by L.Marker to make the markers draggable.\n\t */\n\t\n\t\n\t/* @namespace Marker\n\t * @section Interaction handlers\n\t *\n\t * Interaction handlers are properties of a marker instance that allow you to control interaction behavior in runtime, enabling or disabling certain features such as dragging (see `Handler` methods). Example:\n\t *\n\t * ```js\n\t * marker.dragging.disable();\n\t * ```\n\t *\n\t * @property dragging: Handler\n\t * Marker dragging handler (by both mouse and touch). Only valid when the marker is on the map (Otherwise set [`marker.options.draggable`](#marker-draggable)).\n\t */\n\t\n\tvar MarkerDrag = Handler.extend({\n\t\tinitialize: function (marker) {\n\t\t\tthis._marker = marker;\n\t\t},\n\t\n\t\taddHooks: function () {\n\t\t\tvar icon = this._marker._icon;\n\t\n\t\t\tif (!this._draggable) {\n\t\t\t\tthis._draggable = new Draggable(icon, icon, true);\n\t\t\t}\n\t\n\t\t\tthis._draggable.on({\n\t\t\t\tdragstart: this._onDragStart,\n\t\t\t\tpredrag: this._onPreDrag,\n\t\t\t\tdrag: this._onDrag,\n\t\t\t\tdragend: this._onDragEnd\n\t\t\t}, this).enable();\n\t\n\t\t\taddClass(icon, 'leaflet-marker-draggable');\n\t\t},\n\t\n\t\tremoveHooks: function () {\n\t\t\tthis._draggable.off({\n\t\t\t\tdragstart: this._onDragStart,\n\t\t\t\tpredrag: this._onPreDrag,\n\t\t\t\tdrag: this._onDrag,\n\t\t\t\tdragend: this._onDragEnd\n\t\t\t}, this).disable();\n\t\n\t\t\tif (this._marker._icon) {\n\t\t\t\tremoveClass(this._marker._icon, 'leaflet-marker-draggable');\n\t\t\t}\n\t\t},\n\t\n\t\tmoved: function () {\n\t\t\treturn this._draggable && this._draggable._moved;\n\t\t},\n\t\n\t\t_adjustPan: function (e) {\n\t\t\tvar marker = this._marker,\n\t\t\t map = marker._map,\n\t\t\t speed = this._marker.options.autoPanSpeed,\n\t\t\t padding = this._marker.options.autoPanPadding,\n\t\t\t iconPos = L.DomUtil.getPosition(marker._icon),\n\t\t\t bounds = map.getPixelBounds(),\n\t\t\t origin = map.getPixelOrigin();\n\t\n\t\t\tvar panBounds = toBounds(\n\t\t\t\tbounds.min._subtract(origin).add(padding),\n\t\t\t\tbounds.max._subtract(origin).subtract(padding)\n\t\t\t);\n\t\n\t\t\tif (!panBounds.contains(iconPos)) {\n\t\t\t\t// Compute incremental movement\n\t\t\t\tvar movement = toPoint(\n\t\t\t\t\t(Math.max(panBounds.max.x, iconPos.x) - panBounds.max.x) / (bounds.max.x - panBounds.max.x) -\n\t\t\t\t\t(Math.min(panBounds.min.x, iconPos.x) - panBounds.min.x) / (bounds.min.x - panBounds.min.x),\n\t\n\t\t\t\t\t(Math.max(panBounds.max.y, iconPos.y) - panBounds.max.y) / (bounds.max.y - panBounds.max.y) -\n\t\t\t\t\t(Math.min(panBounds.min.y, iconPos.y) - panBounds.min.y) / (bounds.min.y - panBounds.min.y)\n\t\t\t\t).multiplyBy(speed);\n\t\n\t\t\t\tmap.panBy(movement, {animate: false});\n\t\n\t\t\t\tthis._draggable._newPos._add(movement);\n\t\t\t\tthis._draggable._startPos._add(movement);\n\t\n\t\t\t\tL.DomUtil.setPosition(marker._icon, this._draggable._newPos);\n\t\t\t\tthis._onDrag(e);\n\t\n\t\t\t\tthis._panRequest = requestAnimFrame(this._adjustPan.bind(this, e));\n\t\t\t}\n\t\t},\n\t\n\t\t_onDragStart: function () {\n\t\t\t// @section Dragging events\n\t\t\t// @event dragstart: Event\n\t\t\t// Fired when the user starts dragging the marker.\n\t\n\t\t\t// @event movestart: Event\n\t\t\t// Fired when the marker starts moving (because of dragging).\n\t\n\t\t\tthis._oldLatLng = this._marker.getLatLng();\n\t\t\tthis._marker\n\t\t\t .closePopup()\n\t\t\t .fire('movestart')\n\t\t\t .fire('dragstart');\n\t\t},\n\t\n\t\t_onPreDrag: function (e) {\n\t\t\tif (this._marker.options.autoPan) {\n\t\t\t\tcancelAnimFrame(this._panRequest);\n\t\t\t\tthis._panRequest = requestAnimFrame(this._adjustPan.bind(this, e));\n\t\t\t}\n\t\t},\n\t\n\t\t_onDrag: function (e) {\n\t\t\tvar marker = this._marker,\n\t\t\t shadow = marker._shadow,\n\t\t\ticonPos = getPosition(marker._icon),\n\t\t\t latlng = marker._map.layerPointToLatLng(iconPos);\n\t\n\t\t\t// update shadow position\n\t\t\tif (shadow) {\n\t\t\t\tsetPosition(shadow, iconPos);\n\t\t\t}\n\t\n\t\t\tmarker._latlng = latlng;\n\t\t\te.latlng = latlng;\n\t\t\te.oldLatLng = this._oldLatLng;\n\t\n\t\t\t// @event drag: Event\n\t\t\t// Fired repeatedly while the user drags the marker.\n\t\t\tmarker\n\t\t\t .fire('move', e)\n\t\t\t .fire('drag', e);\n\t\t},\n\t\n\t\t_onDragEnd: function (e) {\n\t\t\t// @event dragend: DragEndEvent\n\t\t\t// Fired when the user stops dragging the marker.\n\t\n\t\t\t cancelAnimFrame(this._panRequest);\n\t\n\t\t\t// @event moveend: Event\n\t\t\t// Fired when the marker stops moving (because of dragging).\n\t\t\tdelete this._oldLatLng;\n\t\t\tthis._marker\n\t\t\t .fire('moveend')\n\t\t\t .fire('dragend', e);\n\t\t}\n\t});\n\t\n\t/*\r\n\t * @class Marker\r\n\t * @inherits Interactive layer\r\n\t * @aka L.Marker\r\n\t * L.Marker is used to display clickable/draggable icons on the map. Extends `Layer`.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * L.marker([50.5, 30.5]).addTo(map);\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar Marker = Layer.extend({\r\n\t\r\n\t\t// @section\r\n\t\t// @aka Marker options\r\n\t\toptions: {\r\n\t\t\t// @option icon: Icon = *\r\n\t\t\t// Icon instance to use for rendering the marker.\r\n\t\t\t// See [Icon documentation](#L.Icon) for details on how to customize the marker icon.\r\n\t\t\t// If not specified, a common instance of `L.Icon.Default` is used.\r\n\t\t\ticon: new IconDefault(),\r\n\t\r\n\t\t\t// Option inherited from \"Interactive layer\" abstract class\r\n\t\t\tinteractive: true,\r\n\t\r\n\t\t\t// @option draggable: Boolean = false\r\n\t\t\t// Whether the marker is draggable with mouse/touch or not.\r\n\t\t\tdraggable: false,\r\n\t\r\n\t\t\t// @option autoPan: Boolean = false\r\n\t\t\t// Set it to `true` if you want the map to do panning animation when marker hits the edges.\r\n\t\t\tautoPan: false,\r\n\t\r\n\t\t\t// @option autoPanPadding: Point = Point(50, 50)\r\n\t\t\t// Equivalent of setting both top left and bottom right autopan padding to the same value.\r\n\t\t\tautoPanPadding: [50, 50],\r\n\t\r\n\t\t\t// @option autoPanSpeed: Number = 10\r\n\t\t\t// Number of pixels the map should move by.\r\n\t\t\tautoPanSpeed: 10,\r\n\t\r\n\t\t\t// @option keyboard: Boolean = true\r\n\t\t\t// Whether the marker can be tabbed to with a keyboard and clicked by pressing enter.\r\n\t\t\tkeyboard: true,\r\n\t\r\n\t\t\t// @option title: String = ''\r\n\t\t\t// Text for the browser tooltip that appear on marker hover (no tooltip by default).\r\n\t\t\ttitle: '',\r\n\t\r\n\t\t\t// @option alt: String = ''\r\n\t\t\t// Text for the `alt` attribute of the icon image (useful for accessibility).\r\n\t\t\talt: '',\r\n\t\r\n\t\t\t// @option zIndexOffset: Number = 0\r\n\t\t\t// By default, marker images zIndex is set automatically based on its latitude. Use this option if you want to put the marker on top of all others (or below), specifying a high value like `1000` (or high negative value, respectively).\r\n\t\t\tzIndexOffset: 0,\r\n\t\r\n\t\t\t// @option opacity: Number = 1.0\r\n\t\t\t// The opacity of the marker.\r\n\t\t\topacity: 1,\r\n\t\r\n\t\t\t// @option riseOnHover: Boolean = false\r\n\t\t\t// If `true`, the marker will get on top of others when you hover the mouse over it.\r\n\t\t\triseOnHover: false,\r\n\t\r\n\t\t\t// @option riseOffset: Number = 250\r\n\t\t\t// The z-index offset used for the `riseOnHover` feature.\r\n\t\t\triseOffset: 250,\r\n\t\r\n\t\t\t// @option pane: String = 'markerPane'\r\n\t\t\t// `Map pane` where the markers icon will be added.\r\n\t\t\tpane: 'markerPane',\r\n\t\r\n\t\t\t// @option bubblingMouseEvents: Boolean = false\r\n\t\t\t// When `true`, a mouse event on this marker will trigger the same event on the map\r\n\t\t\t// (unless [`L.DomEvent.stopPropagation`](#domevent-stoppropagation) is used).\r\n\t\t\tbubblingMouseEvents: false\r\n\t\t},\r\n\t\r\n\t\t/* @section\r\n\t\t *\r\n\t\t * In addition to [shared layer methods](#Layer) like `addTo()` and `remove()` and [popup methods](#Popup) like bindPopup() you can also use the following methods:\r\n\t\t */\r\n\t\r\n\t\tinitialize: function (latlng, options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\t\tthis._latlng = toLatLng(latlng);\r\n\t\t},\r\n\t\r\n\t\tonAdd: function (map) {\r\n\t\t\tthis._zoomAnimated = this._zoomAnimated && map.options.markerZoomAnimation;\r\n\t\r\n\t\t\tif (this._zoomAnimated) {\r\n\t\t\t\tmap.on('zoomanim', this._animateZoom, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._initIcon();\r\n\t\t\tthis.update();\r\n\t\t},\r\n\t\r\n\t\tonRemove: function (map) {\r\n\t\t\tif (this.dragging && this.dragging.enabled()) {\r\n\t\t\t\tthis.options.draggable = true;\r\n\t\t\t\tthis.dragging.removeHooks();\r\n\t\t\t}\r\n\t\t\tdelete this.dragging;\r\n\t\r\n\t\t\tif (this._zoomAnimated) {\r\n\t\t\t\tmap.off('zoomanim', this._animateZoom, this);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._removeIcon();\r\n\t\t\tthis._removeShadow();\r\n\t\t},\r\n\t\r\n\t\tgetEvents: function () {\r\n\t\t\treturn {\r\n\t\t\t\tzoom: this.update,\r\n\t\t\t\tviewreset: this.update\r\n\t\t\t};\r\n\t\t},\r\n\t\r\n\t\t// @method getLatLng: LatLng\r\n\t\t// Returns the current geographical position of the marker.\r\n\t\tgetLatLng: function () {\r\n\t\t\treturn this._latlng;\r\n\t\t},\r\n\t\r\n\t\t// @method setLatLng(latlng: LatLng): this\r\n\t\t// Changes the marker position to the given point.\r\n\t\tsetLatLng: function (latlng) {\r\n\t\t\tvar oldLatLng = this._latlng;\r\n\t\t\tthis._latlng = toLatLng(latlng);\r\n\t\t\tthis.update();\r\n\t\r\n\t\t\t// @event move: Event\r\n\t\t\t// Fired when the marker is moved via [`setLatLng`](#marker-setlatlng) or by [dragging](#marker-dragging). Old and new coordinates are included in event arguments as `oldLatLng`, `latlng`.\r\n\t\t\treturn this.fire('move', {oldLatLng: oldLatLng, latlng: this._latlng});\r\n\t\t},\r\n\t\r\n\t\t// @method setZIndexOffset(offset: Number): this\r\n\t\t// Changes the [zIndex offset](#marker-zindexoffset) of the marker.\r\n\t\tsetZIndexOffset: function (offset) {\r\n\t\t\tthis.options.zIndexOffset = offset;\r\n\t\t\treturn this.update();\r\n\t\t},\r\n\t\r\n\t\t// @method setIcon(icon: Icon): this\r\n\t\t// Changes the marker icon.\r\n\t\tsetIcon: function (icon) {\r\n\t\r\n\t\t\tthis.options.icon = icon;\r\n\t\r\n\t\t\tif (this._map) {\r\n\t\t\t\tthis._initIcon();\r\n\t\t\t\tthis.update();\r\n\t\t\t}\r\n\t\r\n\t\t\tif (this._popup) {\r\n\t\t\t\tthis.bindPopup(this._popup, this._popup.options);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\tgetElement: function () {\r\n\t\t\treturn this._icon;\r\n\t\t},\r\n\t\r\n\t\tupdate: function () {\r\n\t\r\n\t\t\tif (this._icon && this._map) {\r\n\t\t\t\tvar pos = this._map.latLngToLayerPoint(this._latlng).round();\r\n\t\t\t\tthis._setPos(pos);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_initIcon: function () {\r\n\t\t\tvar options = this.options,\r\n\t\t\t classToAdd = 'leaflet-zoom-' + (this._zoomAnimated ? 'animated' : 'hide');\r\n\t\r\n\t\t\tvar icon = options.icon.createIcon(this._icon),\r\n\t\t\t addIcon = false;\r\n\t\r\n\t\t\t// if we're not reusing the icon, remove the old one and init new one\r\n\t\t\tif (icon !== this._icon) {\r\n\t\t\t\tif (this._icon) {\r\n\t\t\t\t\tthis._removeIcon();\r\n\t\t\t\t}\r\n\t\t\t\taddIcon = true;\r\n\t\r\n\t\t\t\tif (options.title) {\r\n\t\t\t\t\ticon.title = options.title;\r\n\t\t\t\t}\r\n\t\r\n\t\t\t\tif (icon.tagName === 'IMG') {\r\n\t\t\t\t\ticon.alt = options.alt || '';\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\taddClass(icon, classToAdd);\r\n\t\r\n\t\t\tif (options.keyboard) {\r\n\t\t\t\ticon.tabIndex = '0';\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._icon = icon;\r\n\t\r\n\t\t\tif (options.riseOnHover) {\r\n\t\t\t\tthis.on({\r\n\t\t\t\t\tmouseover: this._bringToFront,\r\n\t\t\t\t\tmouseout: this._resetZIndex\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\r\n\t\t\tvar newShadow = options.icon.createShadow(this._shadow),\r\n\t\t\t addShadow = false;\r\n\t\r\n\t\t\tif (newShadow !== this._shadow) {\r\n\t\t\t\tthis._removeShadow();\r\n\t\t\t\taddShadow = true;\r\n\t\t\t}\r\n\t\r\n\t\t\tif (newShadow) {\r\n\t\t\t\taddClass(newShadow, classToAdd);\r\n\t\t\t\tnewShadow.alt = '';\r\n\t\t\t}\r\n\t\t\tthis._shadow = newShadow;\r\n\t\r\n\t\r\n\t\t\tif (options.opacity < 1) {\r\n\t\t\t\tthis._updateOpacity();\r\n\t\t\t}\r\n\t\r\n\t\r\n\t\t\tif (addIcon) {\r\n\t\t\t\tthis.getPane().appendChild(this._icon);\r\n\t\t\t}\r\n\t\t\tthis._initInteraction();\r\n\t\t\tif (newShadow && addShadow) {\r\n\t\t\t\tthis.getPane('shadowPane').appendChild(this._shadow);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_removeIcon: function () {\r\n\t\t\tif (this.options.riseOnHover) {\r\n\t\t\t\tthis.off({\r\n\t\t\t\t\tmouseover: this._bringToFront,\r\n\t\t\t\t\tmouseout: this._resetZIndex\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\r\n\t\t\tremove(this._icon);\r\n\t\t\tthis.removeInteractiveTarget(this._icon);\r\n\t\r\n\t\t\tthis._icon = null;\r\n\t\t},\r\n\t\r\n\t\t_removeShadow: function () {\r\n\t\t\tif (this._shadow) {\r\n\t\t\t\tremove(this._shadow);\r\n\t\t\t}\r\n\t\t\tthis._shadow = null;\r\n\t\t},\r\n\t\r\n\t\t_setPos: function (pos) {\r\n\t\t\tsetPosition(this._icon, pos);\r\n\t\r\n\t\t\tif (this._shadow) {\r\n\t\t\t\tsetPosition(this._shadow, pos);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis._zIndex = pos.y + this.options.zIndexOffset;\r\n\t\r\n\t\t\tthis._resetZIndex();\r\n\t\t},\r\n\t\r\n\t\t_updateZIndex: function (offset) {\r\n\t\t\tthis._icon.style.zIndex = this._zIndex + offset;\r\n\t\t},\r\n\t\r\n\t\t_animateZoom: function (opt) {\r\n\t\t\tvar pos = this._map._latLngToNewLayerPoint(this._latlng, opt.zoom, opt.center).round();\r\n\t\r\n\t\t\tthis._setPos(pos);\r\n\t\t},\r\n\t\r\n\t\t_initInteraction: function () {\r\n\t\r\n\t\t\tif (!this.options.interactive) { return; }\r\n\t\r\n\t\t\taddClass(this._icon, 'leaflet-interactive');\r\n\t\r\n\t\t\tthis.addInteractiveTarget(this._icon);\r\n\t\r\n\t\t\tif (MarkerDrag) {\r\n\t\t\t\tvar draggable = this.options.draggable;\r\n\t\t\t\tif (this.dragging) {\r\n\t\t\t\t\tdraggable = this.dragging.enabled();\r\n\t\t\t\t\tthis.dragging.disable();\r\n\t\t\t\t}\r\n\t\r\n\t\t\t\tthis.dragging = new MarkerDrag(this);\r\n\t\r\n\t\t\t\tif (draggable) {\r\n\t\t\t\t\tthis.dragging.enable();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @method setOpacity(opacity: Number): this\r\n\t\t// Changes the opacity of the marker.\r\n\t\tsetOpacity: function (opacity) {\r\n\t\t\tthis.options.opacity = opacity;\r\n\t\t\tif (this._map) {\r\n\t\t\t\tthis._updateOpacity();\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t_updateOpacity: function () {\r\n\t\t\tvar opacity = this.options.opacity;\r\n\t\r\n\t\t\tsetOpacity(this._icon, opacity);\r\n\t\r\n\t\t\tif (this._shadow) {\r\n\t\t\t\tsetOpacity(this._shadow, opacity);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_bringToFront: function () {\r\n\t\t\tthis._updateZIndex(this.options.riseOffset);\r\n\t\t},\r\n\t\r\n\t\t_resetZIndex: function () {\r\n\t\t\tthis._updateZIndex(0);\r\n\t\t},\r\n\t\r\n\t\t_getPopupAnchor: function () {\r\n\t\t\treturn this.options.icon.options.popupAnchor;\r\n\t\t},\r\n\t\r\n\t\t_getTooltipAnchor: function () {\r\n\t\t\treturn this.options.icon.options.tooltipAnchor;\r\n\t\t}\r\n\t});\r\n\t\r\n\t\r\n\t// factory L.marker(latlng: LatLng, options? : Marker options)\r\n\t\r\n\t// @factory L.marker(latlng: LatLng, options? : Marker options)\r\n\t// Instantiates a Marker object given a geographical point and optionally an options object.\r\n\tfunction marker(latlng, options) {\r\n\t\treturn new Marker(latlng, options);\r\n\t}\n\t\n\t/*\n\t * @class Path\n\t * @aka L.Path\n\t * @inherits Interactive layer\n\t *\n\t * An abstract class that contains options and constants shared between vector\n\t * overlays (Polygon, Polyline, Circle). Do not use it directly. Extends `Layer`.\n\t */\n\t\n\tvar Path = Layer.extend({\n\t\n\t\t// @section\n\t\t// @aka Path options\n\t\toptions: {\n\t\t\t// @option stroke: Boolean = true\n\t\t\t// Whether to draw stroke along the path. Set it to `false` to disable borders on polygons or circles.\n\t\t\tstroke: true,\n\t\n\t\t\t// @option color: String = '#3388ff'\n\t\t\t// Stroke color\n\t\t\tcolor: '#3388ff',\n\t\n\t\t\t// @option weight: Number = 3\n\t\t\t// Stroke width in pixels\n\t\t\tweight: 3,\n\t\n\t\t\t// @option opacity: Number = 1.0\n\t\t\t// Stroke opacity\n\t\t\topacity: 1,\n\t\n\t\t\t// @option lineCap: String= 'round'\n\t\t\t// A string that defines [shape to be used at the end](https://developer.mozilla.org/docs/Web/SVG/Attribute/stroke-linecap) of the stroke.\n\t\t\tlineCap: 'round',\n\t\n\t\t\t// @option lineJoin: String = 'round'\n\t\t\t// A string that defines [shape to be used at the corners](https://developer.mozilla.org/docs/Web/SVG/Attribute/stroke-linejoin) of the stroke.\n\t\t\tlineJoin: 'round',\n\t\n\t\t\t// @option dashArray: String = null\n\t\t\t// A string that defines the stroke [dash pattern](https://developer.mozilla.org/docs/Web/SVG/Attribute/stroke-dasharray). Doesn't work on `Canvas`-powered layers in [some old browsers](https://developer.mozilla.org/docs/Web/API/CanvasRenderingContext2D/setLineDash#Browser_compatibility).\n\t\t\tdashArray: null,\n\t\n\t\t\t// @option dashOffset: String = null\n\t\t\t// A string that defines the [distance into the dash pattern to start the dash](https://developer.mozilla.org/docs/Web/SVG/Attribute/stroke-dashoffset). Doesn't work on `Canvas`-powered layers in [some old browsers](https://developer.mozilla.org/docs/Web/API/CanvasRenderingContext2D/setLineDash#Browser_compatibility).\n\t\t\tdashOffset: null,\n\t\n\t\t\t// @option fill: Boolean = depends\n\t\t\t// Whether to fill the path with color. Set it to `false` to disable filling on polygons or circles.\n\t\t\tfill: false,\n\t\n\t\t\t// @option fillColor: String = *\n\t\t\t// Fill color. Defaults to the value of the [`color`](#path-color) option\n\t\t\tfillColor: null,\n\t\n\t\t\t// @option fillOpacity: Number = 0.2\n\t\t\t// Fill opacity.\n\t\t\tfillOpacity: 0.2,\n\t\n\t\t\t// @option fillRule: String = 'evenodd'\n\t\t\t// A string that defines [how the inside of a shape](https://developer.mozilla.org/docs/Web/SVG/Attribute/fill-rule) is determined.\n\t\t\tfillRule: 'evenodd',\n\t\n\t\t\t// className: '',\n\t\n\t\t\t// Option inherited from \"Interactive layer\" abstract class\n\t\t\tinteractive: true,\n\t\n\t\t\t// @option bubblingMouseEvents: Boolean = true\n\t\t\t// When `true`, a mouse event on this path will trigger the same event on the map\n\t\t\t// (unless [`L.DomEvent.stopPropagation`](#domevent-stoppropagation) is used).\n\t\t\tbubblingMouseEvents: true\n\t\t},\n\t\n\t\tbeforeAdd: function (map) {\n\t\t\t// Renderer is set here because we need to call renderer.getEvents\n\t\t\t// before this.getEvents.\n\t\t\tthis._renderer = map.getRenderer(this);\n\t\t},\n\t\n\t\tonAdd: function () {\n\t\t\tthis._renderer._initPath(this);\n\t\t\tthis._reset();\n\t\t\tthis._renderer._addPath(this);\n\t\t},\n\t\n\t\tonRemove: function () {\n\t\t\tthis._renderer._removePath(this);\n\t\t},\n\t\n\t\t// @method redraw(): this\n\t\t// Redraws the layer. Sometimes useful after you changed the coordinates that the path uses.\n\t\tredraw: function () {\n\t\t\tif (this._map) {\n\t\t\t\tthis._renderer._updatePath(this);\n\t\t\t}\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method setStyle(style: Path options): this\n\t\t// Changes the appearance of a Path based on the options in the `Path options` object.\n\t\tsetStyle: function (style) {\n\t\t\tsetOptions(this, style);\n\t\t\tif (this._renderer) {\n\t\t\t\tthis._renderer._updateStyle(this);\n\t\t\t}\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method bringToFront(): this\n\t\t// Brings the layer to the top of all path layers.\n\t\tbringToFront: function () {\n\t\t\tif (this._renderer) {\n\t\t\t\tthis._renderer._bringToFront(this);\n\t\t\t}\n\t\t\treturn this;\n\t\t},\n\t\n\t\t// @method bringToBack(): this\n\t\t// Brings the layer to the bottom of all path layers.\n\t\tbringToBack: function () {\n\t\t\tif (this._renderer) {\n\t\t\t\tthis._renderer._bringToBack(this);\n\t\t\t}\n\t\t\treturn this;\n\t\t},\n\t\n\t\tgetElement: function () {\n\t\t\treturn this._path;\n\t\t},\n\t\n\t\t_reset: function () {\n\t\t\t// defined in child classes\n\t\t\tthis._project();\n\t\t\tthis._update();\n\t\t},\n\t\n\t\t_clickTolerance: function () {\n\t\t\t// used when doing hit detection for Canvas layers\n\t\t\treturn (this.options.stroke ? this.options.weight / 2 : 0) + this._renderer.options.tolerance;\n\t\t}\n\t});\n\t\n\t/*\n\t * @class CircleMarker\n\t * @aka L.CircleMarker\n\t * @inherits Path\n\t *\n\t * A circle of a fixed size with radius specified in pixels. Extends `Path`.\n\t */\n\t\n\tvar CircleMarker = Path.extend({\n\t\n\t\t// @section\n\t\t// @aka CircleMarker options\n\t\toptions: {\n\t\t\tfill: true,\n\t\n\t\t\t// @option radius: Number = 10\n\t\t\t// Radius of the circle marker, in pixels\n\t\t\tradius: 10\n\t\t},\n\t\n\t\tinitialize: function (latlng, options) {\n\t\t\tsetOptions(this, options);\n\t\t\tthis._latlng = toLatLng(latlng);\n\t\t\tthis._radius = this.options.radius;\n\t\t},\n\t\n\t\t// @method setLatLng(latLng: LatLng): this\n\t\t// Sets the position of a circle marker to a new location.\n\t\tsetLatLng: function (latlng) {\n\t\t\tthis._latlng = toLatLng(latlng);\n\t\t\tthis.redraw();\n\t\t\treturn this.fire('move', {latlng: this._latlng});\n\t\t},\n\t\n\t\t// @method getLatLng(): LatLng\n\t\t// Returns the current geographical position of the circle marker\n\t\tgetLatLng: function () {\n\t\t\treturn this._latlng;\n\t\t},\n\t\n\t\t// @method setRadius(radius: Number): this\n\t\t// Sets the radius of a circle marker. Units are in pixels.\n\t\tsetRadius: function (radius) {\n\t\t\tthis.options.radius = this._radius = radius;\n\t\t\treturn this.redraw();\n\t\t},\n\t\n\t\t// @method getRadius(): Number\n\t\t// Returns the current radius of the circle\n\t\tgetRadius: function () {\n\t\t\treturn this._radius;\n\t\t},\n\t\n\t\tsetStyle : function (options) {\n\t\t\tvar radius = options && options.radius || this._radius;\n\t\t\tPath.prototype.setStyle.call(this, options);\n\t\t\tthis.setRadius(radius);\n\t\t\treturn this;\n\t\t},\n\t\n\t\t_project: function () {\n\t\t\tthis._point = this._map.latLngToLayerPoint(this._latlng);\n\t\t\tthis._updateBounds();\n\t\t},\n\t\n\t\t_updateBounds: function () {\n\t\t\tvar r = this._radius,\n\t\t\t r2 = this._radiusY || r,\n\t\t\t w = this._clickTolerance(),\n\t\t\t p = [r + w, r2 + w];\n\t\t\tthis._pxBounds = new Bounds(this._point.subtract(p), this._point.add(p));\n\t\t},\n\t\n\t\t_update: function () {\n\t\t\tif (this._map) {\n\t\t\t\tthis._updatePath();\n\t\t\t}\n\t\t},\n\t\n\t\t_updatePath: function () {\n\t\t\tthis._renderer._updateCircle(this);\n\t\t},\n\t\n\t\t_empty: function () {\n\t\t\treturn this._radius && !this._renderer._bounds.intersects(this._pxBounds);\n\t\t},\n\t\n\t\t// Needed by the `Canvas` renderer for interactivity\n\t\t_containsPoint: function (p) {\n\t\t\treturn p.distanceTo(this._point) <= this._radius + this._clickTolerance();\n\t\t}\n\t});\n\t\n\t\n\t// @factory L.circleMarker(latlng: LatLng, options?: CircleMarker options)\n\t// Instantiates a circle marker object given a geographical point, and an optional options object.\n\tfunction circleMarker(latlng, options) {\n\t\treturn new CircleMarker(latlng, options);\n\t}\n\t\n\t/*\n\t * @class Circle\n\t * @aka L.Circle\n\t * @inherits CircleMarker\n\t *\n\t * A class for drawing circle overlays on a map. Extends `CircleMarker`.\n\t *\n\t * It's an approximation and starts to diverge from a real circle closer to poles (due to projection distortion).\n\t *\n\t * @example\n\t *\n\t * ```js\n\t * L.circle([50.5, 30.5], {radius: 200}).addTo(map);\n\t * ```\n\t */\n\t\n\tvar Circle = CircleMarker.extend({\n\t\n\t\tinitialize: function (latlng, options, legacyOptions) {\n\t\t\tif (typeof options === 'number') {\n\t\t\t\t// Backwards compatibility with 0.7.x factory (latlng, radius, options?)\n\t\t\t\toptions = extend({}, legacyOptions, {radius: options});\n\t\t\t}\n\t\t\tsetOptions(this, options);\n\t\t\tthis._latlng = toLatLng(latlng);\n\t\n\t\t\tif (isNaN(this.options.radius)) { throw new Error('Circle radius cannot be NaN'); }\n\t\n\t\t\t// @section\n\t\t\t// @aka Circle options\n\t\t\t// @option radius: Number; Radius of the circle, in meters.\n\t\t\tthis._mRadius = this.options.radius;\n\t\t},\n\t\n\t\t// @method setRadius(radius: Number): this\n\t\t// Sets the radius of a circle. Units are in meters.\n\t\tsetRadius: function (radius) {\n\t\t\tthis._mRadius = radius;\n\t\t\treturn this.redraw();\n\t\t},\n\t\n\t\t// @method getRadius(): Number\n\t\t// Returns the current radius of a circle. Units are in meters.\n\t\tgetRadius: function () {\n\t\t\treturn this._mRadius;\n\t\t},\n\t\n\t\t// @method getBounds(): LatLngBounds\n\t\t// Returns the `LatLngBounds` of the path.\n\t\tgetBounds: function () {\n\t\t\tvar half = [this._radius, this._radiusY || this._radius];\n\t\n\t\t\treturn new LatLngBounds(\n\t\t\t\tthis._map.layerPointToLatLng(this._point.subtract(half)),\n\t\t\t\tthis._map.layerPointToLatLng(this._point.add(half)));\n\t\t},\n\t\n\t\tsetStyle: Path.prototype.setStyle,\n\t\n\t\t_project: function () {\n\t\n\t\t\tvar lng = this._latlng.lng,\n\t\t\t lat = this._latlng.lat,\n\t\t\t map = this._map,\n\t\t\t crs = map.options.crs;\n\t\n\t\t\tif (crs.distance === Earth.distance) {\n\t\t\t\tvar d = Math.PI / 180,\n\t\t\t\t latR = (this._mRadius / Earth.R) / d,\n\t\t\t\t top = map.project([lat + latR, lng]),\n\t\t\t\t bottom = map.project([lat - latR, lng]),\n\t\t\t\t p = top.add(bottom).divideBy(2),\n\t\t\t\t lat2 = map.unproject(p).lat,\n\t\t\t\t lngR = Math.acos((Math.cos(latR * d) - Math.sin(lat * d) * Math.sin(lat2 * d)) /\n\t\t\t\t (Math.cos(lat * d) * Math.cos(lat2 * d))) / d;\n\t\n\t\t\t\tif (isNaN(lngR) || lngR === 0) {\n\t\t\t\t\tlngR = latR / Math.cos(Math.PI / 180 * lat); // Fallback for edge case, #2425\n\t\t\t\t}\n\t\n\t\t\t\tthis._point = p.subtract(map.getPixelOrigin());\n\t\t\t\tthis._radius = isNaN(lngR) ? 0 : p.x - map.project([lat2, lng - lngR]).x;\n\t\t\t\tthis._radiusY = p.y - top.y;\n\t\n\t\t\t} else {\n\t\t\t\tvar latlng2 = crs.unproject(crs.project(this._latlng).subtract([this._mRadius, 0]));\n\t\n\t\t\t\tthis._point = map.latLngToLayerPoint(this._latlng);\n\t\t\t\tthis._radius = this._point.x - map.latLngToLayerPoint(latlng2).x;\n\t\t\t}\n\t\n\t\t\tthis._updateBounds();\n\t\t}\n\t});\n\t\n\t// @factory L.circle(latlng: LatLng, options?: Circle options)\n\t// Instantiates a circle object given a geographical point, and an options object\n\t// which contains the circle radius.\n\t// @alternative\n\t// @factory L.circle(latlng: LatLng, radius: Number, options?: Circle options)\n\t// Obsolete way of instantiating a circle, for compatibility with 0.7.x code.\n\t// Do not use in new applications or plugins.\n\tfunction circle(latlng, options, legacyOptions) {\n\t\treturn new Circle(latlng, options, legacyOptions);\n\t}\n\t\n\t/*\n\t * @class Polyline\n\t * @aka L.Polyline\n\t * @inherits Path\n\t *\n\t * A class for drawing polyline overlays on a map. Extends `Path`.\n\t *\n\t * @example\n\t *\n\t * ```js\n\t * // create a red polyline from an array of LatLng points\n\t * var latlngs = [\n\t * \t[45.51, -122.68],\n\t * \t[37.77, -122.43],\n\t * \t[34.04, -118.2]\n\t * ];\n\t *\n\t * var polyline = L.polyline(latlngs, {color: 'red'}).addTo(map);\n\t *\n\t * // zoom the map to the polyline\n\t * map.fitBounds(polyline.getBounds());\n\t * ```\n\t *\n\t * You can also pass a multi-dimensional array to represent a `MultiPolyline` shape:\n\t *\n\t * ```js\n\t * // create a red polyline from an array of arrays of LatLng points\n\t * var latlngs = [\n\t * \t[[45.51, -122.68],\n\t * \t [37.77, -122.43],\n\t * \t [34.04, -118.2]],\n\t * \t[[40.78, -73.91],\n\t * \t [41.83, -87.62],\n\t * \t [32.76, -96.72]]\n\t * ];\n\t * ```\n\t */\n\t\n\t\n\tvar Polyline = Path.extend({\n\t\n\t\t// @section\n\t\t// @aka Polyline options\n\t\toptions: {\n\t\t\t// @option smoothFactor: Number = 1.0\n\t\t\t// How much to simplify the polyline on each zoom level. More means\n\t\t\t// better performance and smoother look, and less means more accurate representation.\n\t\t\tsmoothFactor: 1.0,\n\t\n\t\t\t// @option noClip: Boolean = false\n\t\t\t// Disable polyline clipping.\n\t\t\tnoClip: false\n\t\t},\n\t\n\t\tinitialize: function (latlngs, options) {\n\t\t\tsetOptions(this, options);\n\t\t\tthis._setLatLngs(latlngs);\n\t\t},\n\t\n\t\t// @method getLatLngs(): LatLng[]\n\t\t// Returns an array of the points in the path, or nested arrays of points in case of multi-polyline.\n\t\tgetLatLngs: function () {\n\t\t\treturn this._latlngs;\n\t\t},\n\t\n\t\t// @method setLatLngs(latlngs: LatLng[]): this\n\t\t// Replaces all the points in the polyline with the given array of geographical points.\n\t\tsetLatLngs: function (latlngs) {\n\t\t\tthis._setLatLngs(latlngs);\n\t\t\treturn this.redraw();\n\t\t},\n\t\n\t\t// @method isEmpty(): Boolean\n\t\t// Returns `true` if the Polyline has no LatLngs.\n\t\tisEmpty: function () {\n\t\t\treturn !this._latlngs.length;\n\t\t},\n\t\n\t\t// @method closestLayerPoint: Point\n\t\t// Returns the point closest to `p` on the Polyline.\n\t\tclosestLayerPoint: function (p) {\n\t\t\tvar minDistance = Infinity,\n\t\t\t minPoint = null,\n\t\t\t closest = _sqClosestPointOnSegment,\n\t\t\t p1, p2;\n\t\n\t\t\tfor (var j = 0, jLen = this._parts.length; j < jLen; j++) {\n\t\t\t\tvar points = this._parts[j];\n\t\n\t\t\t\tfor (var i = 1, len = points.length; i < len; i++) {\n\t\t\t\t\tp1 = points[i - 1];\n\t\t\t\t\tp2 = points[i];\n\t\n\t\t\t\t\tvar sqDist = closest(p, p1, p2, true);\n\t\n\t\t\t\t\tif (sqDist < minDistance) {\n\t\t\t\t\t\tminDistance = sqDist;\n\t\t\t\t\t\tminPoint = closest(p, p1, p2);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (minPoint) {\n\t\t\t\tminPoint.distance = Math.sqrt(minDistance);\n\t\t\t}\n\t\t\treturn minPoint;\n\t\t},\n\t\n\t\t// @method getCenter(): LatLng\n\t\t// Returns the center ([centroid](http://en.wikipedia.org/wiki/Centroid)) of the polyline.\n\t\tgetCenter: function () {\n\t\t\t// throws error when not yet added to map as this center calculation requires projected coordinates\n\t\t\tif (!this._map) {\n\t\t\t\tthrow new Error('Must add layer to map before using getCenter()');\n\t\t\t}\n\t\n\t\t\tvar i, halfDist, segDist, dist, p1, p2, ratio,\n\t\t\t points = this._rings[0],\n\t\t\t len = points.length;\n\t\n\t\t\tif (!len) { return null; }\n\t\n\t\t\t// polyline centroid algorithm; only uses the first ring if there are multiple\n\t\n\t\t\tfor (i = 0, halfDist = 0; i < len - 1; i++) {\n\t\t\t\thalfDist += points[i].distanceTo(points[i + 1]) / 2;\n\t\t\t}\n\t\n\t\t\t// The line is so small in the current view that all points are on the same pixel.\n\t\t\tif (halfDist === 0) {\n\t\t\t\treturn this._map.layerPointToLatLng(points[0]);\n\t\t\t}\n\t\n\t\t\tfor (i = 0, dist = 0; i < len - 1; i++) {\n\t\t\t\tp1 = points[i];\n\t\t\t\tp2 = points[i + 1];\n\t\t\t\tsegDist = p1.distanceTo(p2);\n\t\t\t\tdist += segDist;\n\t\n\t\t\t\tif (dist > halfDist) {\n\t\t\t\t\tratio = (dist - halfDist) / segDist;\n\t\t\t\t\treturn this._map.layerPointToLatLng([\n\t\t\t\t\t\tp2.x - ratio * (p2.x - p1.x),\n\t\t\t\t\t\tp2.y - ratio * (p2.y - p1.y)\n\t\t\t\t\t]);\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\n\t\t// @method getBounds(): LatLngBounds\n\t\t// Returns the `LatLngBounds` of the path.\n\t\tgetBounds: function () {\n\t\t\treturn this._bounds;\n\t\t},\n\t\n\t\t// @method addLatLng(latlng: LatLng, latlngs? LatLng[]): this\n\t\t// Adds a given point to the polyline. By default, adds to the first ring of\n\t\t// the polyline in case of a multi-polyline, but can be overridden by passing\n\t\t// a specific ring as a LatLng array (that you can earlier access with [`getLatLngs`](#polyline-getlatlngs)).\n\t\taddLatLng: function (latlng, latlngs) {\n\t\t\tlatlngs = latlngs || this._defaultShape();\n\t\t\tlatlng = toLatLng(latlng);\n\t\t\tlatlngs.push(latlng);\n\t\t\tthis._bounds.extend(latlng);\n\t\t\treturn this.redraw();\n\t\t},\n\t\n\t\t_setLatLngs: function (latlngs) {\n\t\t\tthis._bounds = new LatLngBounds();\n\t\t\tthis._latlngs = this._convertLatLngs(latlngs);\n\t\t},\n\t\n\t\t_defaultShape: function () {\n\t\t\treturn isFlat(this._latlngs) ? this._latlngs : this._latlngs[0];\n\t\t},\n\t\n\t\t// recursively convert latlngs input into actual LatLng instances; calculate bounds along the way\n\t\t_convertLatLngs: function (latlngs) {\n\t\t\tvar result = [],\n\t\t\t flat = isFlat(latlngs);\n\t\n\t\t\tfor (var i = 0, len = latlngs.length; i < len; i++) {\n\t\t\t\tif (flat) {\n\t\t\t\t\tresult[i] = toLatLng(latlngs[i]);\n\t\t\t\t\tthis._bounds.extend(result[i]);\n\t\t\t\t} else {\n\t\t\t\t\tresult[i] = this._convertLatLngs(latlngs[i]);\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\treturn result;\n\t\t},\n\t\n\t\t_project: function () {\n\t\t\tvar pxBounds = new Bounds();\n\t\t\tthis._rings = [];\n\t\t\tthis._projectLatlngs(this._latlngs, this._rings, pxBounds);\n\t\n\t\t\tvar w = this._clickTolerance(),\n\t\t\t p = new Point(w, w);\n\t\n\t\t\tif (this._bounds.isValid() && pxBounds.isValid()) {\n\t\t\t\tpxBounds.min._subtract(p);\n\t\t\t\tpxBounds.max._add(p);\n\t\t\t\tthis._pxBounds = pxBounds;\n\t\t\t}\n\t\t},\n\t\n\t\t// recursively turns latlngs into a set of rings with projected coordinates\n\t\t_projectLatlngs: function (latlngs, result, projectedBounds) {\n\t\t\tvar flat = latlngs[0] instanceof LatLng,\n\t\t\t len = latlngs.length,\n\t\t\t i, ring;\n\t\n\t\t\tif (flat) {\n\t\t\t\tring = [];\n\t\t\t\tfor (i = 0; i < len; i++) {\n\t\t\t\t\tring[i] = this._map.latLngToLayerPoint(latlngs[i]);\n\t\t\t\t\tprojectedBounds.extend(ring[i]);\n\t\t\t\t}\n\t\t\t\tresult.push(ring);\n\t\t\t} else {\n\t\t\t\tfor (i = 0; i < len; i++) {\n\t\t\t\t\tthis._projectLatlngs(latlngs[i], result, projectedBounds);\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\n\t\t// clip polyline by renderer bounds so that we have less to render for performance\n\t\t_clipPoints: function () {\n\t\t\tvar bounds = this._renderer._bounds;\n\t\n\t\t\tthis._parts = [];\n\t\t\tif (!this._pxBounds || !this._pxBounds.intersects(bounds)) {\n\t\t\t\treturn;\n\t\t\t}\n\t\n\t\t\tif (this.options.noClip) {\n\t\t\t\tthis._parts = this._rings;\n\t\t\t\treturn;\n\t\t\t}\n\t\n\t\t\tvar parts = this._parts,\n\t\t\t i, j, k, len, len2, segment, points;\n\t\n\t\t\tfor (i = 0, k = 0, len = this._rings.length; i < len; i++) {\n\t\t\t\tpoints = this._rings[i];\n\t\n\t\t\t\tfor (j = 0, len2 = points.length; j < len2 - 1; j++) {\n\t\t\t\t\tsegment = clipSegment(points[j], points[j + 1], bounds, j, true);\n\t\n\t\t\t\t\tif (!segment) { continue; }\n\t\n\t\t\t\t\tparts[k] = parts[k] || [];\n\t\t\t\t\tparts[k].push(segment[0]);\n\t\n\t\t\t\t\t// if segment goes out of screen, or it's the last one, it's the end of the line part\n\t\t\t\t\tif ((segment[1] !== points[j + 1]) || (j === len2 - 2)) {\n\t\t\t\t\t\tparts[k].push(segment[1]);\n\t\t\t\t\t\tk++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\n\t\t// simplify each clipped part of the polyline for performance\n\t\t_simplifyPoints: function () {\n\t\t\tvar parts = this._parts,\n\t\t\t tolerance = this.options.smoothFactor;\n\t\n\t\t\tfor (var i = 0, len = parts.length; i < len; i++) {\n\t\t\t\tparts[i] = simplify(parts[i], tolerance);\n\t\t\t}\n\t\t},\n\t\n\t\t_update: function () {\n\t\t\tif (!this._map) { return; }\n\t\n\t\t\tthis._clipPoints();\n\t\t\tthis._simplifyPoints();\n\t\t\tthis._updatePath();\n\t\t},\n\t\n\t\t_updatePath: function () {\n\t\t\tthis._renderer._updatePoly(this);\n\t\t},\n\t\n\t\t// Needed by the `Canvas` renderer for interactivity\n\t\t_containsPoint: function (p, closed) {\n\t\t\tvar i, j, k, len, len2, part,\n\t\t\t w = this._clickTolerance();\n\t\n\t\t\tif (!this._pxBounds || !this._pxBounds.contains(p)) { return false; }\n\t\n\t\t\t// hit detection for polylines\n\t\t\tfor (i = 0, len = this._parts.length; i < len; i++) {\n\t\t\t\tpart = this._parts[i];\n\t\n\t\t\t\tfor (j = 0, len2 = part.length, k = len2 - 1; j < len2; k = j++) {\n\t\t\t\t\tif (!closed && (j === 0)) { continue; }\n\t\n\t\t\t\t\tif (pointToSegmentDistance(p, part[k], part[j]) <= w) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t});\n\t\n\t// @factory L.polyline(latlngs: LatLng[], options?: Polyline options)\n\t// Instantiates a polyline object given an array of geographical points and\n\t// optionally an options object. You can create a `Polyline` object with\n\t// multiple separate lines (`MultiPolyline`) by passing an array of arrays\n\t// of geographic points.\n\tfunction polyline(latlngs, options) {\n\t\treturn new Polyline(latlngs, options);\n\t}\n\t\n\t// Retrocompat. Allow plugins to support Leaflet versions before and after 1.1.\n\tPolyline._flat = _flat;\n\t\n\t/*\n\t * @class Polygon\n\t * @aka L.Polygon\n\t * @inherits Polyline\n\t *\n\t * A class for drawing polygon overlays on a map. Extends `Polyline`.\n\t *\n\t * Note that points you pass when creating a polygon shouldn't have an additional last point equal to the first one — it's better to filter out such points.\n\t *\n\t *\n\t * @example\n\t *\n\t * ```js\n\t * // create a red polygon from an array of LatLng points\n\t * var latlngs = [[37, -109.05],[41, -109.03],[41, -102.05],[37, -102.04]];\n\t *\n\t * var polygon = L.polygon(latlngs, {color: 'red'}).addTo(map);\n\t *\n\t * // zoom the map to the polygon\n\t * map.fitBounds(polygon.getBounds());\n\t * ```\n\t *\n\t * You can also pass an array of arrays of latlngs, with the first array representing the outer shape and the other arrays representing holes in the outer shape:\n\t *\n\t * ```js\n\t * var latlngs = [\n\t * [[37, -109.05],[41, -109.03],[41, -102.05],[37, -102.04]], // outer ring\n\t * [[37.29, -108.58],[40.71, -108.58],[40.71, -102.50],[37.29, -102.50]] // hole\n\t * ];\n\t * ```\n\t *\n\t * Additionally, you can pass a multi-dimensional array to represent a MultiPolygon shape.\n\t *\n\t * ```js\n\t * var latlngs = [\n\t * [ // first polygon\n\t * [[37, -109.05],[41, -109.03],[41, -102.05],[37, -102.04]], // outer ring\n\t * [[37.29, -108.58],[40.71, -108.58],[40.71, -102.50],[37.29, -102.50]] // hole\n\t * ],\n\t * [ // second polygon\n\t * [[41, -111.03],[45, -111.04],[45, -104.05],[41, -104.05]]\n\t * ]\n\t * ];\n\t * ```\n\t */\n\t\n\tvar Polygon = Polyline.extend({\n\t\n\t\toptions: {\n\t\t\tfill: true\n\t\t},\n\t\n\t\tisEmpty: function () {\n\t\t\treturn !this._latlngs.length || !this._latlngs[0].length;\n\t\t},\n\t\n\t\tgetCenter: function () {\n\t\t\t// throws error when not yet added to map as this center calculation requires projected coordinates\n\t\t\tif (!this._map) {\n\t\t\t\tthrow new Error('Must add layer to map before using getCenter()');\n\t\t\t}\n\t\n\t\t\tvar i, j, p1, p2, f, area, x, y, center,\n\t\t\t points = this._rings[0],\n\t\t\t len = points.length;\n\t\n\t\t\tif (!len) { return null; }\n\t\n\t\t\t// polygon centroid algorithm; only uses the first ring if there are multiple\n\t\n\t\t\tarea = x = y = 0;\n\t\n\t\t\tfor (i = 0, j = len - 1; i < len; j = i++) {\n\t\t\t\tp1 = points[i];\n\t\t\t\tp2 = points[j];\n\t\n\t\t\t\tf = p1.y * p2.x - p2.y * p1.x;\n\t\t\t\tx += (p1.x + p2.x) * f;\n\t\t\t\ty += (p1.y + p2.y) * f;\n\t\t\t\tarea += f * 3;\n\t\t\t}\n\t\n\t\t\tif (area === 0) {\n\t\t\t\t// Polygon is so small that all points are on same pixel.\n\t\t\t\tcenter = points[0];\n\t\t\t} else {\n\t\t\t\tcenter = [x / area, y / area];\n\t\t\t}\n\t\t\treturn this._map.layerPointToLatLng(center);\n\t\t},\n\t\n\t\t_convertLatLngs: function (latlngs) {\n\t\t\tvar result = Polyline.prototype._convertLatLngs.call(this, latlngs),\n\t\t\t len = result.length;\n\t\n\t\t\t// remove last point if it equals first one\n\t\t\tif (len >= 2 && result[0] instanceof LatLng && result[0].equals(result[len - 1])) {\n\t\t\t\tresult.pop();\n\t\t\t}\n\t\t\treturn result;\n\t\t},\n\t\n\t\t_setLatLngs: function (latlngs) {\n\t\t\tPolyline.prototype._setLatLngs.call(this, latlngs);\n\t\t\tif (isFlat(this._latlngs)) {\n\t\t\t\tthis._latlngs = [this._latlngs];\n\t\t\t}\n\t\t},\n\t\n\t\t_defaultShape: function () {\n\t\t\treturn isFlat(this._latlngs[0]) ? this._latlngs[0] : this._latlngs[0][0];\n\t\t},\n\t\n\t\t_clipPoints: function () {\n\t\t\t// polygons need a different clipping algorithm so we redefine that\n\t\n\t\t\tvar bounds = this._renderer._bounds,\n\t\t\t w = this.options.weight,\n\t\t\t p = new Point(w, w);\n\t\n\t\t\t// increase clip padding by stroke width to avoid stroke on clip edges\n\t\t\tbounds = new Bounds(bounds.min.subtract(p), bounds.max.add(p));\n\t\n\t\t\tthis._parts = [];\n\t\t\tif (!this._pxBounds || !this._pxBounds.intersects(bounds)) {\n\t\t\t\treturn;\n\t\t\t}\n\t\n\t\t\tif (this.options.noClip) {\n\t\t\t\tthis._parts = this._rings;\n\t\t\t\treturn;\n\t\t\t}\n\t\n\t\t\tfor (var i = 0, len = this._rings.length, clipped; i < len; i++) {\n\t\t\t\tclipped = clipPolygon(this._rings[i], bounds, true);\n\t\t\t\tif (clipped.length) {\n\t\t\t\t\tthis._parts.push(clipped);\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\n\t\t_updatePath: function () {\n\t\t\tthis._renderer._updatePoly(this, true);\n\t\t},\n\t\n\t\t// Needed by the `Canvas` renderer for interactivity\n\t\t_containsPoint: function (p) {\n\t\t\tvar inside = false,\n\t\t\t part, p1, p2, i, j, k, len, len2;\n\t\n\t\t\tif (!this._pxBounds.contains(p)) { return false; }\n\t\n\t\t\t// ray casting algorithm for detecting if point is in polygon\n\t\t\tfor (i = 0, len = this._parts.length; i < len; i++) {\n\t\t\t\tpart = this._parts[i];\n\t\n\t\t\t\tfor (j = 0, len2 = part.length, k = len2 - 1; j < len2; k = j++) {\n\t\t\t\t\tp1 = part[j];\n\t\t\t\t\tp2 = part[k];\n\t\n\t\t\t\t\tif (((p1.y > p.y) !== (p2.y > p.y)) && (p.x < (p2.x - p1.x) * (p.y - p1.y) / (p2.y - p1.y) + p1.x)) {\n\t\t\t\t\t\tinside = !inside;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\t// also check if it's on polygon stroke\n\t\t\treturn inside || Polyline.prototype._containsPoint.call(this, p, true);\n\t\t}\n\t\n\t});\n\t\n\t\n\t// @factory L.polygon(latlngs: LatLng[], options?: Polyline options)\n\tfunction polygon(latlngs, options) {\n\t\treturn new Polygon(latlngs, options);\n\t}\n\t\n\t/*\r\n\t * @class GeoJSON\r\n\t * @aka L.GeoJSON\r\n\t * @inherits FeatureGroup\r\n\t *\r\n\t * Represents a GeoJSON object or an array of GeoJSON objects. Allows you to parse\r\n\t * GeoJSON data and display it on the map. Extends `FeatureGroup`.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * L.geoJSON(data, {\r\n\t * \tstyle: function (feature) {\r\n\t * \t\treturn {color: feature.properties.color};\r\n\t * \t}\r\n\t * }).bindPopup(function (layer) {\r\n\t * \treturn layer.feature.properties.description;\r\n\t * }).addTo(map);\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar GeoJSON = FeatureGroup.extend({\r\n\t\r\n\t\t/* @section\r\n\t\t * @aka GeoJSON options\r\n\t\t *\r\n\t\t * @option pointToLayer: Function = *\r\n\t\t * A `Function` defining how GeoJSON points spawn Leaflet layers. It is internally\r\n\t\t * called when data is added, passing the GeoJSON point feature and its `LatLng`.\r\n\t\t * The default is to spawn a default `Marker`:\r\n\t\t * ```js\r\n\t\t * function(geoJsonPoint, latlng) {\r\n\t\t * \treturn L.marker(latlng);\r\n\t\t * }\r\n\t\t * ```\r\n\t\t *\r\n\t\t * @option style: Function = *\r\n\t\t * A `Function` defining the `Path options` for styling GeoJSON lines and polygons,\r\n\t\t * called internally when data is added.\r\n\t\t * The default value is to not override any defaults:\r\n\t\t * ```js\r\n\t\t * function (geoJsonFeature) {\r\n\t\t * \treturn {}\r\n\t\t * }\r\n\t\t * ```\r\n\t\t *\r\n\t\t * @option onEachFeature: Function = *\r\n\t\t * A `Function` that will be called once for each created `Feature`, after it has\r\n\t\t * been created and styled. Useful for attaching events and popups to features.\r\n\t\t * The default is to do nothing with the newly created layers:\r\n\t\t * ```js\r\n\t\t * function (feature, layer) {}\r\n\t\t * ```\r\n\t\t *\r\n\t\t * @option filter: Function = *\r\n\t\t * A `Function` that will be used to decide whether to include a feature or not.\r\n\t\t * The default is to include all features:\r\n\t\t * ```js\r\n\t\t * function (geoJsonFeature) {\r\n\t\t * \treturn true;\r\n\t\t * }\r\n\t\t * ```\r\n\t\t * Note: dynamically changing the `filter` option will have effect only on newly\r\n\t\t * added data. It will _not_ re-evaluate already included features.\r\n\t\t *\r\n\t\t * @option coordsToLatLng: Function = *\r\n\t\t * A `Function` that will be used for converting GeoJSON coordinates to `LatLng`s.\r\n\t\t * The default is the `coordsToLatLng` static method.\r\n\t\t */\r\n\t\r\n\t\tinitialize: function (geojson, options) {\r\n\t\t\tsetOptions(this, options);\r\n\t\r\n\t\t\tthis._layers = {};\r\n\t\r\n\t\t\tif (geojson) {\r\n\t\t\t\tthis.addData(geojson);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @method addData( data ): this\r\n\t\t// Adds a GeoJSON object to the layer.\r\n\t\taddData: function (geojson) {\r\n\t\t\tvar features = isArray(geojson) ? geojson : geojson.features,\r\n\t\t\t i, len, feature;\r\n\t\r\n\t\t\tif (features) {\r\n\t\t\t\tfor (i = 0, len = features.length; i < len; i++) {\r\n\t\t\t\t\t// only add this if geometry or geometries are set and not null\r\n\t\t\t\t\tfeature = features[i];\r\n\t\t\t\t\tif (feature.geometries || feature.geometry || feature.features || feature.coordinates) {\r\n\t\t\t\t\t\tthis.addData(feature);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\r\n\t\t\tvar options = this.options;\r\n\t\r\n\t\t\tif (options.filter && !options.filter(geojson)) { return this; }\r\n\t\r\n\t\t\tvar layer = geometryToLayer(geojson, options);\r\n\t\t\tif (!layer) {\r\n\t\t\t\treturn this;\r\n\t\t\t}\r\n\t\t\tlayer.feature = asFeature(geojson);\r\n\t\r\n\t\t\tlayer.defaultOptions = layer.options;\r\n\t\t\tthis.resetStyle(layer);\r\n\t\r\n\t\t\tif (options.onEachFeature) {\r\n\t\t\t\toptions.onEachFeature(geojson, layer);\r\n\t\t\t}\r\n\t\r\n\t\t\treturn this.addLayer(layer);\r\n\t\t},\r\n\t\r\n\t\t// @method resetStyle( layer ): this\r\n\t\t// Resets the given vector layer's style to the original GeoJSON style, useful for resetting style after hover events.\r\n\t\tresetStyle: function (layer) {\r\n\t\t\t// reset any custom styles\r\n\t\t\tlayer.options = extend({}, layer.defaultOptions);\r\n\t\t\tthis._setLayerStyle(layer, this.options.style);\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method setStyle( style ): this\r\n\t\t// Changes styles of GeoJSON vector layers with the given style function.\r\n\t\tsetStyle: function (style) {\r\n\t\t\treturn this.eachLayer(function (layer) {\r\n\t\t\t\tthis._setLayerStyle(layer, style);\r\n\t\t\t}, this);\r\n\t\t},\r\n\t\r\n\t\t_setLayerStyle: function (layer, style) {\r\n\t\t\tif (typeof style === 'function') {\r\n\t\t\t\tstyle = style(layer.feature);\r\n\t\t\t}\r\n\t\t\tif (layer.setStyle) {\r\n\t\t\t\tlayer.setStyle(style);\r\n\t\t\t}\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @section\r\n\t// There are several static functions which can be called without instantiating L.GeoJSON:\r\n\t\r\n\t// @function geometryToLayer(featureData: Object, options?: GeoJSON options): Layer\r\n\t// Creates a `Layer` from a given GeoJSON feature. Can use a custom\r\n\t// [`pointToLayer`](#geojson-pointtolayer) and/or [`coordsToLatLng`](#geojson-coordstolatlng)\r\n\t// functions if provided as options.\r\n\tfunction geometryToLayer(geojson, options) {\r\n\t\r\n\t\tvar geometry = geojson.type === 'Feature' ? geojson.geometry : geojson,\r\n\t\t coords = geometry ? geometry.coordinates : null,\r\n\t\t layers = [],\r\n\t\t pointToLayer = options && options.pointToLayer,\r\n\t\t _coordsToLatLng = options && options.coordsToLatLng || coordsToLatLng,\r\n\t\t latlng, latlngs, i, len;\r\n\t\r\n\t\tif (!coords && !geometry) {\r\n\t\t\treturn null;\r\n\t\t}\r\n\t\r\n\t\tswitch (geometry.type) {\r\n\t\tcase 'Point':\r\n\t\t\tlatlng = _coordsToLatLng(coords);\r\n\t\t\treturn pointToLayer ? pointToLayer(geojson, latlng) : new Marker(latlng);\r\n\t\r\n\t\tcase 'MultiPoint':\r\n\t\t\tfor (i = 0, len = coords.length; i < len; i++) {\r\n\t\t\t\tlatlng = _coordsToLatLng(coords[i]);\r\n\t\t\t\tlayers.push(pointToLayer ? pointToLayer(geojson, latlng) : new Marker(latlng));\r\n\t\t\t}\r\n\t\t\treturn new FeatureGroup(layers);\r\n\t\r\n\t\tcase 'LineString':\r\n\t\tcase 'MultiLineString':\r\n\t\t\tlatlngs = coordsToLatLngs(coords, geometry.type === 'LineString' ? 0 : 1, _coordsToLatLng);\r\n\t\t\treturn new Polyline(latlngs, options);\r\n\t\r\n\t\tcase 'Polygon':\r\n\t\tcase 'MultiPolygon':\r\n\t\t\tlatlngs = coordsToLatLngs(coords, geometry.type === 'Polygon' ? 1 : 2, _coordsToLatLng);\r\n\t\t\treturn new Polygon(latlngs, options);\r\n\t\r\n\t\tcase 'GeometryCollection':\r\n\t\t\tfor (i = 0, len = geometry.geometries.length; i < len; i++) {\r\n\t\t\t\tvar layer = geometryToLayer({\r\n\t\t\t\t\tgeometry: geometry.geometries[i],\r\n\t\t\t\t\ttype: 'Feature',\r\n\t\t\t\t\tproperties: geojson.properties\r\n\t\t\t\t}, options);\r\n\t\r\n\t\t\t\tif (layer) {\r\n\t\t\t\t\tlayers.push(layer);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn new FeatureGroup(layers);\r\n\t\r\n\t\tdefault:\r\n\t\t\tthrow new Error('Invalid GeoJSON object.');\r\n\t\t}\r\n\t}\r\n\t\r\n\t// @function coordsToLatLng(coords: Array): LatLng\r\n\t// Creates a `LatLng` object from an array of 2 numbers (longitude, latitude)\r\n\t// or 3 numbers (longitude, latitude, altitude) used in GeoJSON for points.\r\n\tfunction coordsToLatLng(coords) {\r\n\t\treturn new LatLng(coords[1], coords[0], coords[2]);\r\n\t}\r\n\t\r\n\t// @function coordsToLatLngs(coords: Array, levelsDeep?: Number, coordsToLatLng?: Function): Array\r\n\t// Creates a multidimensional array of `LatLng`s from a GeoJSON coordinates array.\r\n\t// `levelsDeep` specifies the nesting level (0 is for an array of points, 1 for an array of arrays of points, etc., 0 by default).\r\n\t// Can use a custom [`coordsToLatLng`](#geojson-coordstolatlng) function.\r\n\tfunction coordsToLatLngs(coords, levelsDeep, _coordsToLatLng) {\r\n\t\tvar latlngs = [];\r\n\t\r\n\t\tfor (var i = 0, len = coords.length, latlng; i < len; i++) {\r\n\t\t\tlatlng = levelsDeep ?\r\n\t\t\t\tcoordsToLatLngs(coords[i], levelsDeep - 1, _coordsToLatLng) :\r\n\t\t\t\t(_coordsToLatLng || coordsToLatLng)(coords[i]);\r\n\t\r\n\t\t\tlatlngs.push(latlng);\r\n\t\t}\r\n\t\r\n\t\treturn latlngs;\r\n\t}\r\n\t\r\n\t// @function latLngToCoords(latlng: LatLng, precision?: Number): Array\r\n\t// Reverse of [`coordsToLatLng`](#geojson-coordstolatlng)\r\n\tfunction latLngToCoords(latlng, precision) {\r\n\t\tprecision = typeof precision === 'number' ? precision : 6;\r\n\t\treturn latlng.alt !== undefined ?\r\n\t\t\t[formatNum(latlng.lng, precision), formatNum(latlng.lat, precision), formatNum(latlng.alt, precision)] :\r\n\t\t\t[formatNum(latlng.lng, precision), formatNum(latlng.lat, precision)];\r\n\t}\r\n\t\r\n\t// @function latLngsToCoords(latlngs: Array, levelsDeep?: Number, closed?: Boolean): Array\r\n\t// Reverse of [`coordsToLatLngs`](#geojson-coordstolatlngs)\r\n\t// `closed` determines whether the first point should be appended to the end of the array to close the feature, only used when `levelsDeep` is 0. False by default.\r\n\tfunction latLngsToCoords(latlngs, levelsDeep, closed, precision) {\r\n\t\tvar coords = [];\r\n\t\r\n\t\tfor (var i = 0, len = latlngs.length; i < len; i++) {\r\n\t\t\tcoords.push(levelsDeep ?\r\n\t\t\t\tlatLngsToCoords(latlngs[i], levelsDeep - 1, closed, precision) :\r\n\t\t\t\tlatLngToCoords(latlngs[i], precision));\r\n\t\t}\r\n\t\r\n\t\tif (!levelsDeep && closed) {\r\n\t\t\tcoords.push(coords[0]);\r\n\t\t}\r\n\t\r\n\t\treturn coords;\r\n\t}\r\n\t\r\n\tfunction getFeature(layer, newGeometry) {\r\n\t\treturn layer.feature ?\r\n\t\t\textend({}, layer.feature, {geometry: newGeometry}) :\r\n\t\t\tasFeature(newGeometry);\r\n\t}\r\n\t\r\n\t// @function asFeature(geojson: Object): Object\r\n\t// Normalize GeoJSON geometries/features into GeoJSON features.\r\n\tfunction asFeature(geojson) {\r\n\t\tif (geojson.type === 'Feature' || geojson.type === 'FeatureCollection') {\r\n\t\t\treturn geojson;\r\n\t\t}\r\n\t\r\n\t\treturn {\r\n\t\t\ttype: 'Feature',\r\n\t\t\tproperties: {},\r\n\t\t\tgeometry: geojson\r\n\t\t};\r\n\t}\r\n\t\r\n\tvar PointToGeoJSON = {\r\n\t\ttoGeoJSON: function (precision) {\r\n\t\t\treturn getFeature(this, {\r\n\t\t\t\ttype: 'Point',\r\n\t\t\t\tcoordinates: latLngToCoords(this.getLatLng(), precision)\r\n\t\t\t});\r\n\t\t}\r\n\t};\r\n\t\r\n\t// @namespace Marker\r\n\t// @method toGeoJSON(): Object\r\n\t// Returns a [`GeoJSON`](http://en.wikipedia.org/wiki/GeoJSON) representation of the marker (as a GeoJSON `Point` Feature).\r\n\tMarker.include(PointToGeoJSON);\r\n\t\r\n\t// @namespace CircleMarker\r\n\t// @method toGeoJSON(): Object\r\n\t// Returns a [`GeoJSON`](http://en.wikipedia.org/wiki/GeoJSON) representation of the circle marker (as a GeoJSON `Point` Feature).\r\n\tCircle.include(PointToGeoJSON);\r\n\tCircleMarker.include(PointToGeoJSON);\r\n\t\r\n\t\r\n\t// @namespace Polyline\r\n\t// @method toGeoJSON(): Object\r\n\t// Returns a [`GeoJSON`](http://en.wikipedia.org/wiki/GeoJSON) representation of the polyline (as a GeoJSON `LineString` or `MultiLineString` Feature).\r\n\tPolyline.include({\r\n\t\ttoGeoJSON: function (precision) {\r\n\t\t\tvar multi = !isFlat(this._latlngs);\r\n\t\r\n\t\t\tvar coords = latLngsToCoords(this._latlngs, multi ? 1 : 0, false, precision);\r\n\t\r\n\t\t\treturn getFeature(this, {\r\n\t\t\t\ttype: (multi ? 'Multi' : '') + 'LineString',\r\n\t\t\t\tcoordinates: coords\r\n\t\t\t});\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @namespace Polygon\r\n\t// @method toGeoJSON(): Object\r\n\t// Returns a [`GeoJSON`](http://en.wikipedia.org/wiki/GeoJSON) representation of the polygon (as a GeoJSON `Polygon` or `MultiPolygon` Feature).\r\n\tPolygon.include({\r\n\t\ttoGeoJSON: function (precision) {\r\n\t\t\tvar holes = !isFlat(this._latlngs),\r\n\t\t\t multi = holes && !isFlat(this._latlngs[0]);\r\n\t\r\n\t\t\tvar coords = latLngsToCoords(this._latlngs, multi ? 2 : holes ? 1 : 0, true, precision);\r\n\t\r\n\t\t\tif (!holes) {\r\n\t\t\t\tcoords = [coords];\r\n\t\t\t}\r\n\t\r\n\t\t\treturn getFeature(this, {\r\n\t\t\t\ttype: (multi ? 'Multi' : '') + 'Polygon',\r\n\t\t\t\tcoordinates: coords\r\n\t\t\t});\r\n\t\t}\r\n\t});\r\n\t\r\n\t\r\n\t// @namespace LayerGroup\r\n\tLayerGroup.include({\r\n\t\ttoMultiPoint: function (precision) {\r\n\t\t\tvar coords = [];\r\n\t\r\n\t\t\tthis.eachLayer(function (layer) {\r\n\t\t\t\tcoords.push(layer.toGeoJSON(precision).geometry.coordinates);\r\n\t\t\t});\r\n\t\r\n\t\t\treturn getFeature(this, {\r\n\t\t\t\ttype: 'MultiPoint',\r\n\t\t\t\tcoordinates: coords\r\n\t\t\t});\r\n\t\t},\r\n\t\r\n\t\t// @method toGeoJSON(): Object\r\n\t\t// Returns a [`GeoJSON`](http://en.wikipedia.org/wiki/GeoJSON) representation of the layer group (as a GeoJSON `FeatureCollection`, `GeometryCollection`, or `MultiPoint`).\r\n\t\ttoGeoJSON: function (precision) {\r\n\t\r\n\t\t\tvar type = this.feature && this.feature.geometry && this.feature.geometry.type;\r\n\t\r\n\t\t\tif (type === 'MultiPoint') {\r\n\t\t\t\treturn this.toMultiPoint(precision);\r\n\t\t\t}\r\n\t\r\n\t\t\tvar isGeometryCollection = type === 'GeometryCollection',\r\n\t\t\t jsons = [];\r\n\t\r\n\t\t\tthis.eachLayer(function (layer) {\r\n\t\t\t\tif (layer.toGeoJSON) {\r\n\t\t\t\t\tvar json = layer.toGeoJSON(precision);\r\n\t\t\t\t\tif (isGeometryCollection) {\r\n\t\t\t\t\t\tjsons.push(json.geometry);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tvar feature = asFeature(json);\r\n\t\t\t\t\t\t// Squash nested feature collections\r\n\t\t\t\t\t\tif (feature.type === 'FeatureCollection') {\r\n\t\t\t\t\t\t\tjsons.push.apply(jsons, feature.features);\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tjsons.push(feature);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\r\n\t\t\tif (isGeometryCollection) {\r\n\t\t\t\treturn getFeature(this, {\r\n\t\t\t\t\tgeometries: jsons,\r\n\t\t\t\t\ttype: 'GeometryCollection'\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\r\n\t\t\treturn {\r\n\t\t\t\ttype: 'FeatureCollection',\r\n\t\t\t\tfeatures: jsons\r\n\t\t\t};\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @namespace GeoJSON\r\n\t// @factory L.geoJSON(geojson?: Object, options?: GeoJSON options)\r\n\t// Creates a GeoJSON layer. Optionally accepts an object in\r\n\t// [GeoJSON format](http://geojson.org/geojson-spec.html) to display on the map\r\n\t// (you can alternatively add it later with `addData` method) and an `options` object.\r\n\tfunction geoJSON(geojson, options) {\r\n\t\treturn new GeoJSON(geojson, options);\r\n\t}\r\n\t\r\n\t// Backward compatibility.\r\n\tvar geoJson = geoJSON;\n\t\n\t/*\r\n\t * @class ImageOverlay\r\n\t * @aka L.ImageOverlay\r\n\t * @inherits Interactive layer\r\n\t *\r\n\t * Used to load and display a single image over specific bounds of the map. Extends `Layer`.\r\n\t *\r\n\t * @example\r\n\t *\r\n\t * ```js\r\n\t * var imageUrl = 'http://www.lib.utexas.edu/maps/historical/newark_nj_1922.jpg',\r\n\t * \timageBounds = [[40.712216, -74.22655], [40.773941, -74.12544]];\r\n\t * L.imageOverlay(imageUrl, imageBounds).addTo(map);\r\n\t * ```\r\n\t */\r\n\t\r\n\tvar ImageOverlay = Layer.extend({\r\n\t\r\n\t\t// @section\r\n\t\t// @aka ImageOverlay options\r\n\t\toptions: {\r\n\t\t\t// @option opacity: Number = 1.0\r\n\t\t\t// The opacity of the image overlay.\r\n\t\t\topacity: 1,\r\n\t\r\n\t\t\t// @option alt: String = ''\r\n\t\t\t// Text for the `alt` attribute of the image (useful for accessibility).\r\n\t\t\talt: '',\r\n\t\r\n\t\t\t// @option interactive: Boolean = false\r\n\t\t\t// If `true`, the image overlay will emit [mouse events](#interactive-layer) when clicked or hovered.\r\n\t\t\tinteractive: false,\r\n\t\r\n\t\t\t// @option crossOrigin: Boolean = false\r\n\t\t\t// If true, the image will have its crossOrigin attribute set to ''. This is needed if you want to access image pixel data.\r\n\t\t\tcrossOrigin: false,\r\n\t\r\n\t\t\t// @option errorOverlayUrl: String = ''\r\n\t\t\t// URL to the overlay image to show in place of the overlay that failed to load.\r\n\t\t\terrorOverlayUrl: '',\r\n\t\r\n\t\t\t// @option zIndex: Number = 1\r\n\t\t\t// The explicit [zIndex](https://developer.mozilla.org/docs/Web/CSS/CSS_Positioning/Understanding_z_index) of the tile layer.\r\n\t\t\tzIndex: 1,\r\n\t\r\n\t\t\t// @option className: String = ''\r\n\t\t\t// A custom class name to assign to the image. Empty by default.\r\n\t\t\tclassName: '',\r\n\t\t},\r\n\t\r\n\t\tinitialize: function (url, bounds, options) { // (String, LatLngBounds, Object)\r\n\t\t\tthis._url = url;\r\n\t\t\tthis._bounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\tsetOptions(this, options);\r\n\t\t},\r\n\t\r\n\t\tonAdd: function () {\r\n\t\t\tif (!this._image) {\r\n\t\t\t\tthis._initImage();\r\n\t\r\n\t\t\t\tif (this.options.opacity < 1) {\r\n\t\t\t\t\tthis._updateOpacity();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\tif (this.options.interactive) {\r\n\t\t\t\taddClass(this._image, 'leaflet-interactive');\r\n\t\t\t\tthis.addInteractiveTarget(this._image);\r\n\t\t\t}\r\n\t\r\n\t\t\tthis.getPane().appendChild(this._image);\r\n\t\t\tthis._reset();\r\n\t\t},\r\n\t\r\n\t\tonRemove: function () {\r\n\t\t\tremove(this._image);\r\n\t\t\tif (this.options.interactive) {\r\n\t\t\t\tthis.removeInteractiveTarget(this._image);\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t// @method setOpacity(opacity: Number): this\r\n\t\t// Sets the opacity of the overlay.\r\n\t\tsetOpacity: function (opacity) {\r\n\t\t\tthis.options.opacity = opacity;\r\n\t\r\n\t\t\tif (this._image) {\r\n\t\t\t\tthis._updateOpacity();\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\tsetStyle: function (styleOpts) {\r\n\t\t\tif (styleOpts.opacity) {\r\n\t\t\t\tthis.setOpacity(styleOpts.opacity);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method bringToFront(): this\r\n\t\t// Brings the layer to the top of all overlays.\r\n\t\tbringToFront: function () {\r\n\t\t\tif (this._map) {\r\n\t\t\t\ttoFront(this._image);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method bringToBack(): this\r\n\t\t// Brings the layer to the bottom of all overlays.\r\n\t\tbringToBack: function () {\r\n\t\t\tif (this._map) {\r\n\t\t\t\ttoBack(this._image);\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method setUrl(url: String): this\r\n\t\t// Changes the URL of the image.\r\n\t\tsetUrl: function (url) {\r\n\t\t\tthis._url = url;\r\n\t\r\n\t\t\tif (this._image) {\r\n\t\t\t\tthis._image.src = url;\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method setBounds(bounds: LatLngBounds): this\r\n\t\t// Update the bounds that this ImageOverlay covers\r\n\t\tsetBounds: function (bounds) {\r\n\t\t\tthis._bounds = toLatLngBounds(bounds);\r\n\t\r\n\t\t\tif (this._map) {\r\n\t\t\t\tthis._reset();\r\n\t\t\t}\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\tgetEvents: function () {\r\n\t\t\tvar events = {\r\n\t\t\t\tzoom: this._reset,\r\n\t\t\t\tviewreset: this._reset\r\n\t\t\t};\r\n\t\r\n\t\t\tif (this._zoomAnimated) {\r\n\t\t\t\tevents.zoomanim = this._animateZoom;\r\n\t\t\t}\r\n\t\r\n\t\t\treturn events;\r\n\t\t},\r\n\t\r\n\t\t// @method: setZIndex(value: Number) : this\r\n\t\t// Changes the [zIndex](#imageoverlay-zindex) of the image overlay.\r\n\t\tsetZIndex: function (value) {\r\n\t\t\tthis.options.zIndex = value;\r\n\t\t\tthis._updateZIndex();\r\n\t\t\treturn this;\r\n\t\t},\r\n\t\r\n\t\t// @method getBounds(): LatLngBounds\r\n\t\t// Get the bounds that this ImageOverlay covers\r\n\t\tgetBounds: function () {\r\n\t\t\treturn this._bounds;\r\n\t\t},\r\n\t\r\n\t\t// @method getElement(): HTMLElement\r\n\t\t// Returns the instance of [`HTMLImageElement`](https://developer.mozilla.org/docs/Web/API/HTMLImageElement)\r\n\t\t// used by this overlay.\r\n\t\tgetElement: function () {\r\n\t\t\treturn this._image;\r\n\t\t},\r\n\t\r\n\t\t_initImage: function () {\r\n\t\t\tvar wasElementSupplied = this._url.tagName === 'IMG';\r\n\t\t\tvar img = this._image = wasElementSupplied ? this._url : create$1('img');\r\n\t\r\n\t\t\taddClass(img, 'leaflet-image-layer');\r\n\t\t\tif (this._zoomAnimated) { addClass(img, 'leaflet-zoom-animated'); }\r\n\t\t\tif (this.options.className) { addClass(img, this.options.className); }\r\n\t\r\n\t\t\timg.onselectstart = falseFn;\r\n\t\t\timg.onmousemove = falseFn;\r\n\t\r\n\t\t\t// @event load: Event\r\n\t\t\t// Fired when the ImageOverlay layer has loaded its image\r\n\t\t\timg.onload = bind(this.fire, this, 'load');\r\n\t\t\timg.onerror = bind(this._overlayOnError, this, 'error');\r\n\t\r\n\t\t\tif (this.options.crossOrigin) {\r\n\t\t\t\timg.crossOrigin = '';\r\n\t\t\t}\r\n\t\r\n\t\t\tif (this.options.zIndex) {\r\n\t\t\t\tthis._updateZIndex();\r\n\t\t\t}\r\n\t\r\n\t\t\tif (wasElementSupplied) {\r\n\t\t\t\tthis._url = img.src;\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\r\n\t\t\timg.src = this._url;\r\n\t\t\timg.alt = this.options.alt;\r\n\t\t},\r\n\t\r\n\t\t_animateZoom: function (e) {\r\n\t\t\tvar scale = this._map.getZoomScale(e.zoom),\r\n\t\t\t offset = this._map._latLngBoundsToNewLayerBounds(this._bounds, e.zoom, e.center).min;\r\n\t\r\n\t\t\tsetTransform(this._image, offset, scale);\r\n\t\t},\r\n\t\r\n\t\t_reset: function () {\r\n\t\t\tvar image = this._image,\r\n\t\t\t bounds = new Bounds(\r\n\t\t\t this._map.latLngToLayerPoint(this._bounds.getNorthWest()),\r\n\t\t\t this._map.latLngToLayerPoint(this._bounds.getSouthEast())),\r\n\t\t\t size = bounds.getSize();\r\n\t\r\n\t\t\tsetPosition(image, bounds.min);\r\n\t\r\n\t\t\timage.style.width = size.x + 'px';\r\n\t\t\timage.style.height = size.y + 'px';\r\n\t\t},\r\n\t\r\n\t\t_updateOpacity: function () {\r\n\t\t\tsetOpacity(this._image, this.options.opacity);\r\n\t\t},\r\n\t\r\n\t\t_updateZIndex: function () {\r\n\t\t\tif (this._image && this.options.zIndex !== undefined && this.options.zIndex !== null) {\r\n\t\t\t\tthis._image.style.zIndex = this.options.zIndex;\r\n\t\t\t}\r\n\t\t},\r\n\t\r\n\t\t_overlayOnError: function () {\r\n\t\t\t// @event error: Event\r\n\t\t\t// Fired when the ImageOverlay layer has loaded its image\r\n\t\t\tthis.fire('error');\r\n\t\r\n\t\t\tvar errorUrl = this.options.errorOverlayUrl;\r\n\t\t\tif (errorUrl && this._url !== errorUrl) {\r\n\t\t\t\tthis._url = errorUrl;\r\n\t\t\t\tthis._image.src = errorUrl;\r\n\t\t\t}\r\n\t\t}\r\n\t});\r\n\t\r\n\t// @factory L.imageOverlay(imageUrl: String, bounds: LatLngBounds, options?: ImageOverlay options)\r\n\t// Instantiates an image overlay object given the URL of the image and the\r\n\t// geographical bounds it is tied to.\r\n\tvar imageOverlay = function (url, bounds, options) {\r\n\t\treturn new ImageOverlay(url, bounds, options);\r\n\t};\n\t\n\t/*\r\n\t * @class VideoOverlay\r\n\t * @aka L.VideoOverlay\r\n\t * @inherits ImageOverlay\r\n\t *\r\n\t * Used to load and display a video player over specific bounds of the map. Extends `ImageOverlay`.\r\n\t *\r\n\t * A video overlay uses the [`