@kepler.gl/styles 3.0.0-alpha.0 → 3.0.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,26 +1,4 @@
1
- // Copyright (c) 2022 Uber Technologies, Inc.
2
- //
3
- // Permission is hereby granted, free of charge, to any person obtaining a copy
4
- // of this software and associated documentation files (the "Software"), to deal
5
- // in the Software without restriction, including without limitation the rights
6
- // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
- // copies of the Software, and to permit persons to whom the Software is
8
- // furnished to do so, subject to the following conditions:
9
- //
10
- // The above copyright notice and this permission notice shall be included in
11
- // all copies or substantial portions of the Software.
12
- //
13
- // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
- // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
- // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
- // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
- // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
- // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
- // THE SOFTWARE.
1
+ // SPDX-License-Identifier: MIT
2
+ // Copyright contributors to the kepler.gl project
20
3
 
21
- !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("react"),require("styled-components")):"function"==typeof define&&define.amd?define(["react","styled-components"],e):"object"==typeof exports?exports.KeplerGl=e(require("react"),require("styled-components")):t.KeplerGl=e(t.React,t.styled)}(this,(function(t,e){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var i=e[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)r.d(n,i,function(e){return t[e]}.bind(null,i));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=37)}([function(t,e,r){t.exports=r(54)()},function(e,r){e.exports=t},function(t,e,r){"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}r.d(e,"a",(function(){return n}))},function(t,e,r){"use strict";r.d(e,"a",(function(){return i}));var n=r(16);function i(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t)){var r=[],n=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(n=(a=s.next()).done)&&(r.push(a.value),!e||r.length!==e);n=!0);}catch(t){i=!0,o=t}finally{try{n||null==s.return||s.return()}finally{if(i)throw o}}return r}}(t,e)||Object(n.a)(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}r.d(e,"a",(function(){return n}))},function(t,e,r){"use strict";function n(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function i(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),t}r.d(e,"a",(function(){return i}))},function(t,e,r){"use strict";(function(t){r.d(e,"a",(function(){return n}));"undefined"!=typeof window&&window,void 0!==t||window;var n="undefined"!=typeof document?document:{}}).call(this,r(14))},,function(t,e){t.exports=function(t){return t&&t.__esModule?t:{default:t}},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){"use strict";(function(t){r.d(e,"b",(function(){return n})),r.d(e,"c",(function(){return i})),r.d(e,"a",(function(){return o}));var n="undefined"!=typeof navigator&&navigator.userAgent?navigator.userAgent.toLowerCase():"",i="undefined"!=typeof window?window:t,o=(void 0!==t||window,"undefined"!=typeof document&&document,!1);try{var a={get passive(){return o=!0,!0}};i.addEventListener("test",a,a),i.removeEventListener("test",a,a)}catch(t){}}).call(this,r(14))},function(t,e,r){"use strict";function n(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}r.d(e,"a",(function(){return n}))},function(t,e,r){"use strict";function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}r.d(e,"a",(function(){return n}))},function(t,e,r){var n;
22
- /*! Hammer.JS - v2.0.7 - 2016-04-22
23
- * http://hammerjs.github.io/
24
- *
25
- * Copyright (c) 2016 Jorik Tangelder;
26
- * Licensed under the MIT license */!function(i,o,a,s){"use strict";var l,u=["","webkit","Moz","MS","ms","o"],c=o.createElement("div"),p=Math.round,h=Math.abs,f=Date.now;function d(t,e,r){return setTimeout(x(t,r),e)}function m(t,e,r){return!!Array.isArray(t)&&(g(t,r[e],r),!0)}function g(t,e,r){var n;if(t)if(t.forEach)t.forEach(e,r);else if(void 0!==t.length)for(n=0;n<t.length;)e.call(r,t[n],n,t),n++;else for(n in t)t.hasOwnProperty(n)&&e.call(r,t[n],n,t)}function y(t,e,r){var n="DEPRECATED METHOD: "+e+"\n"+r+" AT \n";return function(){var e=new Error("get-stack-trace"),r=e&&e.stack?e.stack.replace(/^[^\(]+?[\n$]/gm,"").replace(/^\s+at\s+/gm,"").replace(/^Object.<anonymous>\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",o=i.console&&(i.console.warn||i.console.log);return o&&o.call(i.console,n,r),t.apply(this,arguments)}}l="function"!=typeof Object.assign?function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),r=1;r<arguments.length;r++){var n=arguments[r];if(null!=n)for(var i in n)n.hasOwnProperty(i)&&(e[i]=n[i])}return e}:Object.assign;var v=y((function(t,e,r){for(var n=Object.keys(e),i=0;i<n.length;)(!r||r&&void 0===t[n[i]])&&(t[n[i]]=e[n[i]]),i++;return t}),"extend","Use `assign`."),_=y((function(t,e){return v(t,e,!0)}),"merge","Use `assign`.");function b(t,e,r){var n,i=e.prototype;(n=t.prototype=Object.create(i)).constructor=t,n._super=i,r&&l(n,r)}function x(t,e){return function(){return t.apply(e,arguments)}}function w(t,e){return"function"==typeof t?t.apply(e&&e[0]||void 0,e):t}function E(t,e){return void 0===t?e:t}function T(t,e,r){g(P(e),(function(e){t.addEventListener(e,r,!1)}))}function A(t,e,r){g(P(e),(function(e){t.removeEventListener(e,r,!1)}))}function C(t,e){for(;t;){if(t==e)return!0;t=t.parentNode}return!1}function S(t,e){return t.indexOf(e)>-1}function P(t){return t.trim().split(/\s+/g)}function I(t,e,r){if(t.indexOf&&!r)return t.indexOf(e);for(var n=0;n<t.length;){if(r&&t[n][r]==e||!r&&t[n]===e)return n;n++}return-1}function D(t){return Array.prototype.slice.call(t,0)}function O(t,e,r){for(var n=[],i=[],o=0;o<t.length;){var a=e?t[o][e]:t[o];I(i,a)<0&&n.push(t[o]),i[o]=a,o++}return r&&(n=e?n.sort((function(t,r){return t[e]>r[e]})):n.sort()),n}function M(t,e){for(var r,n,i=e[0].toUpperCase()+e.slice(1),o=0;o<u.length;){if((n=(r=u[o])?r+i:e)in t)return n;o++}}var B=1;function k(t){var e=t.ownerDocument||t;return e.defaultView||e.parentWindow||i}var F="ontouchstart"in i,L=void 0!==M(i,"PointerEvent"),R=F&&/mobile|tablet|ip(ad|hone|od)|android/i.test(navigator.userAgent),z=["x","y"],N=["clientX","clientY"];function j(t,e){var r=this;this.manager=t,this.callback=e,this.element=t.element,this.target=t.options.inputTarget,this.domHandler=function(e){w(t.options.enable,[t])&&r.handler(e)},this.init()}function U(t,e,r){var n=r.pointers.length,i=r.changedPointers.length,o=1&e&&n-i==0,a=12&e&&n-i==0;r.isFirst=!!o,r.isFinal=!!a,o&&(t.session={}),r.eventType=e,function(t,e){var r=t.session,n=e.pointers,i=n.length;r.firstInput||(r.firstInput=V(e));i>1&&!r.firstMultiple?r.firstMultiple=V(e):1===i&&(r.firstMultiple=!1);var o=r.firstInput,a=r.firstMultiple,s=a?a.center:o.center,l=e.center=q(n);e.timeStamp=f(),e.deltaTime=e.timeStamp-o.timeStamp,e.angle=W(s,l),e.distance=Z(s,l),function(t,e){var r=e.center,n=t.offsetDelta||{},i=t.prevDelta||{},o=t.prevInput||{};1!==e.eventType&&4!==o.eventType||(i=t.prevDelta={x:o.deltaX||0,y:o.deltaY||0},n=t.offsetDelta={x:r.x,y:r.y});e.deltaX=i.x+(r.x-n.x),e.deltaY=i.y+(r.y-n.y)}(r,e),e.offsetDirection=G(e.deltaX,e.deltaY);var u=H(e.deltaTime,e.deltaX,e.deltaY);e.overallVelocityX=u.x,e.overallVelocityY=u.y,e.overallVelocity=h(u.x)>h(u.y)?u.x:u.y,e.scale=a?(c=a.pointers,p=n,Z(p[0],p[1],N)/Z(c[0],c[1],N)):1,e.rotation=a?function(t,e){return W(e[1],e[0],N)+W(t[1],t[0],N)}(a.pointers,n):0,e.maxPointers=r.prevInput?e.pointers.length>r.prevInput.maxPointers?e.pointers.length:r.prevInput.maxPointers:e.pointers.length,function(t,e){var r,n,i,o,a=t.lastInterval||e,s=e.timeStamp-a.timeStamp;if(8!=e.eventType&&(s>25||void 0===a.velocity)){var l=e.deltaX-a.deltaX,u=e.deltaY-a.deltaY,c=H(s,l,u);n=c.x,i=c.y,r=h(c.x)>h(c.y)?c.x:c.y,o=G(l,u),t.lastInterval=e}else r=a.velocity,n=a.velocityX,i=a.velocityY,o=a.direction;e.velocity=r,e.velocityX=n,e.velocityY=i,e.direction=o}(r,e);var c,p;var d=t.element;C(e.srcEvent.target,d)&&(d=e.srcEvent.target);e.target=d}(t,r),t.emit("hammer.input",r),t.recognize(r),t.session.prevInput=r}function V(t){for(var e=[],r=0;r<t.pointers.length;)e[r]={clientX:p(t.pointers[r].clientX),clientY:p(t.pointers[r].clientY)},r++;return{timeStamp:f(),pointers:e,center:q(e),deltaX:t.deltaX,deltaY:t.deltaY}}function q(t){var e=t.length;if(1===e)return{x:p(t[0].clientX),y:p(t[0].clientY)};for(var r=0,n=0,i=0;i<e;)r+=t[i].clientX,n+=t[i].clientY,i++;return{x:p(r/e),y:p(n/e)}}function H(t,e,r){return{x:e/t||0,y:r/t||0}}function G(t,e){return t===e?1:h(t)>=h(e)?t<0?2:4:e<0?8:16}function Z(t,e,r){r||(r=z);var n=e[r[0]]-t[r[0]],i=e[r[1]]-t[r[1]];return Math.sqrt(n*n+i*i)}function W(t,e,r){r||(r=z);var n=e[r[0]]-t[r[0]],i=e[r[1]]-t[r[1]];return 180*Math.atan2(i,n)/Math.PI}j.prototype={handler:function(){},init:function(){this.evEl&&T(this.element,this.evEl,this.domHandler),this.evTarget&&T(this.target,this.evTarget,this.domHandler),this.evWin&&T(k(this.element),this.evWin,this.domHandler)},destroy:function(){this.evEl&&A(this.element,this.evEl,this.domHandler),this.evTarget&&A(this.target,this.evTarget,this.domHandler),this.evWin&&A(k(this.element),this.evWin,this.domHandler)}};var Y={mousedown:1,mousemove:2,mouseup:4};function X(){this.evEl="mousedown",this.evWin="mousemove mouseup",this.pressed=!1,j.apply(this,arguments)}b(X,j,{handler:function(t){var e=Y[t.type];1&e&&0===t.button&&(this.pressed=!0),2&e&&1!==t.which&&(e=4),this.pressed&&(4&e&&(this.pressed=!1),this.callback(this.manager,e,{pointers:[t],changedPointers:[t],pointerType:"mouse",srcEvent:t}))}});var K={pointerdown:1,pointermove:2,pointerup:4,pointercancel:8,pointerout:8},J={2:"touch",3:"pen",4:"mouse",5:"kinect"},Q="pointerdown",$="pointermove pointerup pointercancel";function tt(){this.evEl=Q,this.evWin=$,j.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}i.MSPointerEvent&&!i.PointerEvent&&(Q="MSPointerDown",$="MSPointerMove MSPointerUp MSPointerCancel"),b(tt,j,{handler:function(t){var e=this.store,r=!1,n=t.type.toLowerCase().replace("ms",""),i=K[n],o=J[t.pointerType]||t.pointerType,a="touch"==o,s=I(e,t.pointerId,"pointerId");1&i&&(0===t.button||a)?s<0&&(e.push(t),s=e.length-1):12&i&&(r=!0),s<0||(e[s]=t,this.callback(this.manager,i,{pointers:e,changedPointers:[t],pointerType:o,srcEvent:t}),r&&e.splice(s,1))}});var et={touchstart:1,touchmove:2,touchend:4,touchcancel:8};function rt(){this.evTarget="touchstart",this.evWin="touchstart touchmove touchend touchcancel",this.started=!1,j.apply(this,arguments)}function nt(t,e){var r=D(t.touches),n=D(t.changedTouches);return 12&e&&(r=O(r.concat(n),"identifier",!0)),[r,n]}b(rt,j,{handler:function(t){var e=et[t.type];if(1===e&&(this.started=!0),this.started){var r=nt.call(this,t,e);12&e&&r[0].length-r[1].length==0&&(this.started=!1),this.callback(this.manager,e,{pointers:r[0],changedPointers:r[1],pointerType:"touch",srcEvent:t})}}});var it={touchstart:1,touchmove:2,touchend:4,touchcancel:8};function ot(){this.evTarget="touchstart touchmove touchend touchcancel",this.targetIds={},j.apply(this,arguments)}function at(t,e){var r=D(t.touches),n=this.targetIds;if(3&e&&1===r.length)return n[r[0].identifier]=!0,[r,r];var i,o,a=D(t.changedTouches),s=[],l=this.target;if(o=r.filter((function(t){return C(t.target,l)})),1===e)for(i=0;i<o.length;)n[o[i].identifier]=!0,i++;for(i=0;i<a.length;)n[a[i].identifier]&&s.push(a[i]),12&e&&delete n[a[i].identifier],i++;return s.length?[O(o.concat(s),"identifier",!0),s]:void 0}b(ot,j,{handler:function(t){var e=it[t.type],r=at.call(this,t,e);r&&this.callback(this.manager,e,{pointers:r[0],changedPointers:r[1],pointerType:"touch",srcEvent:t})}});function st(){j.apply(this,arguments);var t=x(this.handler,this);this.touch=new ot(this.manager,t),this.mouse=new X(this.manager,t),this.primaryTouch=null,this.lastTouches=[]}function lt(t,e){1&t?(this.primaryTouch=e.changedPointers[0].identifier,ut.call(this,e)):12&t&&ut.call(this,e)}function ut(t){var e=t.changedPointers[0];if(e.identifier===this.primaryTouch){var r={x:e.clientX,y:e.clientY};this.lastTouches.push(r);var n=this.lastTouches;setTimeout((function(){var t=n.indexOf(r);t>-1&&n.splice(t,1)}),2500)}}function ct(t){for(var e=t.srcEvent.clientX,r=t.srcEvent.clientY,n=0;n<this.lastTouches.length;n++){var i=this.lastTouches[n],o=Math.abs(e-i.x),a=Math.abs(r-i.y);if(o<=25&&a<=25)return!0}return!1}b(st,j,{handler:function(t,e,r){var n="touch"==r.pointerType,i="mouse"==r.pointerType;if(!(i&&r.sourceCapabilities&&r.sourceCapabilities.firesTouchEvents)){if(n)lt.call(this,e,r);else if(i&&ct.call(this,r))return;this.callback(t,e,r)}},destroy:function(){this.touch.destroy(),this.mouse.destroy()}});var pt=M(c.style,"touchAction"),ht=void 0!==pt,ft=function(){if(!ht)return!1;var t={},e=i.CSS&&i.CSS.supports;return["auto","manipulation","pan-y","pan-x","pan-x pan-y","none"].forEach((function(r){t[r]=!e||i.CSS.supports("touch-action",r)})),t}();function dt(t,e){this.manager=t,this.set(e)}dt.prototype={set:function(t){"compute"==t&&(t=this.compute()),ht&&this.manager.element.style&&ft[t]&&(this.manager.element.style[pt]=t),this.actions=t.toLowerCase().trim()},update:function(){this.set(this.manager.options.touchAction)},compute:function(){var t=[];return g(this.manager.recognizers,(function(e){w(e.options.enable,[e])&&(t=t.concat(e.getTouchAction()))})),function(t){if(S(t,"none"))return"none";var e=S(t,"pan-x"),r=S(t,"pan-y");if(e&&r)return"none";if(e||r)return e?"pan-x":"pan-y";if(S(t,"manipulation"))return"manipulation";return"auto"}(t.join(" "))},preventDefaults:function(t){var e=t.srcEvent,r=t.offsetDirection;if(this.manager.session.prevented)e.preventDefault();else{var n=this.actions,i=S(n,"none")&&!ft.none,o=S(n,"pan-y")&&!ft["pan-y"],a=S(n,"pan-x")&&!ft["pan-x"];if(i){var s=1===t.pointers.length,l=t.distance<2,u=t.deltaTime<250;if(s&&l&&u)return}if(!a||!o)return i||o&&6&r||a&&24&r?this.preventSrc(e):void 0}},preventSrc:function(t){this.manager.session.prevented=!0,t.preventDefault()}};function mt(t){this.options=l({},this.defaults,t||{}),this.id=B++,this.manager=null,this.options.enable=E(this.options.enable,!0),this.state=1,this.simultaneous={},this.requireFail=[]}function gt(t){return 16&t?"cancel":8&t?"end":4&t?"move":2&t?"start":""}function yt(t){return 16==t?"down":8==t?"up":2==t?"left":4==t?"right":""}function vt(t,e){var r=e.manager;return r?r.get(t):t}function _t(){mt.apply(this,arguments)}function bt(){_t.apply(this,arguments),this.pX=null,this.pY=null}function xt(){_t.apply(this,arguments)}function wt(){mt.apply(this,arguments),this._timer=null,this._input=null}function Et(){_t.apply(this,arguments)}function Tt(){_t.apply(this,arguments)}function At(){mt.apply(this,arguments),this.pTime=!1,this.pCenter=!1,this._timer=null,this._input=null,this.count=0}function Ct(t,e){return(e=e||{}).recognizers=E(e.recognizers,Ct.defaults.preset),new St(t,e)}mt.prototype={defaults:{},set:function(t){return l(this.options,t),this.manager&&this.manager.touchAction.update(),this},recognizeWith:function(t){if(m(t,"recognizeWith",this))return this;var e=this.simultaneous;return e[(t=vt(t,this)).id]||(e[t.id]=t,t.recognizeWith(this)),this},dropRecognizeWith:function(t){return m(t,"dropRecognizeWith",this)||(t=vt(t,this),delete this.simultaneous[t.id]),this},requireFailure:function(t){if(m(t,"requireFailure",this))return this;var e=this.requireFail;return-1===I(e,t=vt(t,this))&&(e.push(t),t.requireFailure(this)),this},dropRequireFailure:function(t){if(m(t,"dropRequireFailure",this))return this;t=vt(t,this);var e=I(this.requireFail,t);return e>-1&&this.requireFail.splice(e,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(t){return!!this.simultaneous[t.id]},emit:function(t){var e=this,r=this.state;function n(r){e.manager.emit(r,t)}r<8&&n(e.options.event+gt(r)),n(e.options.event),t.additionalEvent&&n(t.additionalEvent),r>=8&&n(e.options.event+gt(r))},tryEmit:function(t){if(this.canEmit())return this.emit(t);this.state=32},canEmit:function(){for(var t=0;t<this.requireFail.length;){if(!(33&this.requireFail[t].state))return!1;t++}return!0},recognize:function(t){var e=l({},t);if(!w(this.options.enable,[this,e]))return this.reset(),void(this.state=32);56&this.state&&(this.state=1),this.state=this.process(e),30&this.state&&this.tryEmit(e)},process:function(t){},getTouchAction:function(){},reset:function(){}},b(_t,mt,{defaults:{pointers:1},attrTest:function(t){var e=this.options.pointers;return 0===e||t.pointers.length===e},process:function(t){var e=this.state,r=t.eventType,n=6&e,i=this.attrTest(t);return n&&(8&r||!i)?16|e:n||i?4&r?8|e:2&e?4|e:2:32}}),b(bt,_t,{defaults:{event:"pan",threshold:10,pointers:1,direction:30},getTouchAction:function(){var t=this.options.direction,e=[];return 6&t&&e.push("pan-y"),24&t&&e.push("pan-x"),e},directionTest:function(t){var e=this.options,r=!0,n=t.distance,i=t.direction,o=t.deltaX,a=t.deltaY;return i&e.direction||(6&e.direction?(i=0===o?1:o<0?2:4,r=o!=this.pX,n=Math.abs(t.deltaX)):(i=0===a?1:a<0?8:16,r=a!=this.pY,n=Math.abs(t.deltaY))),t.direction=i,r&&n>e.threshold&&i&e.direction},attrTest:function(t){return _t.prototype.attrTest.call(this,t)&&(2&this.state||!(2&this.state)&&this.directionTest(t))},emit:function(t){this.pX=t.deltaX,this.pY=t.deltaY;var e=yt(t.direction);e&&(t.additionalEvent=this.options.event+e),this._super.emit.call(this,t)}}),b(xt,_t,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return["none"]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.scale-1)>this.options.threshold||2&this.state)},emit:function(t){if(1!==t.scale){var e=t.scale<1?"in":"out";t.additionalEvent=this.options.event+e}this._super.emit.call(this,t)}}),b(wt,mt,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return["auto"]},process:function(t){var e=this.options,r=t.pointers.length===e.pointers,n=t.distance<e.threshold,i=t.deltaTime>e.time;if(this._input=t,!n||!r||12&t.eventType&&!i)this.reset();else if(1&t.eventType)this.reset(),this._timer=d((function(){this.state=8,this.tryEmit()}),e.time,this);else if(4&t.eventType)return 8;return 32},reset:function(){clearTimeout(this._timer)},emit:function(t){8===this.state&&(t&&4&t.eventType?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=f(),this.manager.emit(this.options.event,this._input)))}}),b(Et,_t,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return["none"]},attrTest:function(t){return this._super.attrTest.call(this,t)&&(Math.abs(t.rotation)>this.options.threshold||2&this.state)}}),b(Tt,_t,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:30,pointers:1},getTouchAction:function(){return bt.prototype.getTouchAction.call(this)},attrTest:function(t){var e,r=this.options.direction;return 30&r?e=t.overallVelocity:6&r?e=t.overallVelocityX:24&r&&(e=t.overallVelocityY),this._super.attrTest.call(this,t)&&r&t.offsetDirection&&t.distance>this.options.threshold&&t.maxPointers==this.options.pointers&&h(e)>this.options.velocity&&4&t.eventType},emit:function(t){var e=yt(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)}}),b(At,mt,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return["manipulation"]},process:function(t){var e=this.options,r=t.pointers.length===e.pointers,n=t.distance<e.threshold,i=t.deltaTime<e.time;if(this.reset(),1&t.eventType&&0===this.count)return this.failTimeout();if(n&&i&&r){if(4!=t.eventType)return this.failTimeout();var o=!this.pTime||t.timeStamp-this.pTime<e.interval,a=!this.pCenter||Z(this.pCenter,t.center)<e.posThreshold;if(this.pTime=t.timeStamp,this.pCenter=t.center,a&&o?this.count+=1:this.count=1,this._input=t,0===this.count%e.taps)return this.hasRequireFailures()?(this._timer=d((function(){this.state=8,this.tryEmit()}),e.interval,this),2):8}return 32},failTimeout:function(){return this._timer=d((function(){this.state=32}),this.options.interval,this),32},reset:function(){clearTimeout(this._timer)},emit:function(){8==this.state&&(this._input.tapCount=this.count,this.manager.emit(this.options.event,this._input))}}),Ct.VERSION="2.0.7",Ct.defaults={domEvents:!1,touchAction:"compute",enable:!0,inputTarget:null,inputClass:null,preset:[[Et,{enable:!1}],[xt,{enable:!1},["rotate"]],[Tt,{direction:6}],[bt,{direction:6},["swipe"]],[At],[At,{event:"doubletap",taps:2},["tap"]],[wt]],cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}};function St(t,e){var r;this.options=l({},Ct.defaults,e||{}),this.options.inputTarget=this.options.inputTarget||t,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=t,this.input=new((r=this).options.inputClass||(L?tt:R?ot:F?st:X))(r,U),this.touchAction=new dt(this,this.options.touchAction),Pt(this,!0),g(this.options.recognizers,(function(t){var e=this.add(new t[0](t[1]));t[2]&&e.recognizeWith(t[2]),t[3]&&e.requireFailure(t[3])}),this)}function Pt(t,e){var r,n=t.element;n.style&&(g(t.options.cssProps,(function(i,o){r=M(n.style,o),e?(t.oldCssProps[r]=n.style[r],n.style[r]=i):n.style[r]=t.oldCssProps[r]||""})),e||(t.oldCssProps={}))}St.prototype={set:function(t){return l(this.options,t),t.touchAction&&this.touchAction.update(),t.inputTarget&&(this.input.destroy(),this.input.target=t.inputTarget,this.input.init()),this},stop:function(t){this.session.stopped=t?2:1},recognize:function(t){var e=this.session;if(!e.stopped){var r;this.touchAction.preventDefaults(t);var n=this.recognizers,i=e.curRecognizer;(!i||i&&8&i.state)&&(i=e.curRecognizer=null);for(var o=0;o<n.length;)r=n[o],2===e.stopped||i&&r!=i&&!r.canRecognizeWith(i)?r.reset():r.recognize(t),!i&&14&r.state&&(i=e.curRecognizer=r),o++}},get:function(t){if(t instanceof mt)return t;for(var e=this.recognizers,r=0;r<e.length;r++)if(e[r].options.event==t)return e[r];return null},add:function(t){if(m(t,"add",this))return this;var e=this.get(t.options.event);return e&&this.remove(e),this.recognizers.push(t),t.manager=this,this.touchAction.update(),t},remove:function(t){if(m(t,"remove",this))return this;if(t=this.get(t)){var e=this.recognizers,r=I(e,t);-1!==r&&(e.splice(r,1),this.touchAction.update())}return this},on:function(t,e){if(void 0!==t&&void 0!==e){var r=this.handlers;return g(P(t),(function(t){r[t]=r[t]||[],r[t].push(e)})),this}},off:function(t,e){if(void 0!==t){var r=this.handlers;return g(P(t),(function(t){e?r[t]&&r[t].splice(I(r[t],e),1):delete r[t]})),this}},emit:function(t,e){this.options.domEvents&&function(t,e){var r=o.createEvent("Event");r.initEvent(t,!0,!0),r.gesture=e,e.target.dispatchEvent(r)}(t,e);var r=this.handlers[t]&&this.handlers[t].slice();if(r&&r.length){e.type=t,e.preventDefault=function(){e.srcEvent.preventDefault()};for(var n=0;n<r.length;)r[n](e),n++}},destroy:function(){this.element&&Pt(this,!1),this.handlers={},this.session={},this.input.destroy(),this.element=null}},l(Ct,{INPUT_START:1,INPUT_MOVE:2,INPUT_END:4,INPUT_CANCEL:8,STATE_POSSIBLE:1,STATE_BEGAN:2,STATE_CHANGED:4,STATE_ENDED:8,STATE_RECOGNIZED:8,STATE_CANCELLED:16,STATE_FAILED:32,DIRECTION_NONE:1,DIRECTION_LEFT:2,DIRECTION_RIGHT:4,DIRECTION_UP:8,DIRECTION_DOWN:16,DIRECTION_HORIZONTAL:6,DIRECTION_VERTICAL:24,DIRECTION_ALL:30,Manager:St,Input:j,TouchAction:dt,TouchInput:ot,MouseInput:X,PointerEventInput:tt,TouchMouseInput:st,SingleTouchInput:rt,Recognizer:mt,AttrRecognizer:_t,Tap:At,Pan:bt,Swipe:Tt,Pinch:xt,Rotate:Et,Press:wt,on:T,off:A,each:g,merge:_,extend:v,assign:l,inherit:b,bindFn:x,prefixed:M}),(void 0!==i?i:"undefined"!=typeof self?self:{}).Hammer=Ct,void 0===(n=function(){return Ct}.call(e,r,e,t))||(t.exports=n)}(window,document)},function(t,e){t.exports=function(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(t){"object"==typeof window&&(r=window)}t.exports=r},function(t,e,r){"use strict";var n,i;function o(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}Object.defineProperty(e,"__esModule",{value:!0}),e.ELEMENT_TYPE=e.STATIC_STYLE=e.OPERATIONS=e.RENDER_STATE=e.MODE_TO_RENDER_TYPE=e.RENDER_TYPE=e.MODE_TO_GEOJSON_TYPE=e.GEOJSON_TYPE=e.DRAWING_MODES=e.MODES=void 0;var a={READ_ONLY:"READ_ONLY",SELECT_FEATURE:"SELECT_FEATURE",EDIT_VERTEX:"EDIT_VERTEX",DRAW_POINT:"DRAW_POINT",DRAW_PATH:"DRAW_PATH",DRAW_POLYGON:"DRAW_POLYGON",DRAW_RECTANGLE:"DRAW_RECTANGLE"};e.MODES=a;var s=[a.DRAW_POINT,a.DRAW_PATH,a.DRAW_POLYGON,a.DRAW_RECTANGLE];e.DRAWING_MODES=s;var l={POINT:"Point",LINE_STRING:"LineString",POLYGON:"Polygon"};e.GEOJSON_TYPE=l;var u=(o(n={},a.DRAW_POINT,l.POINT),o(n,a.DRAW_PATH,l.LINE_STRING),o(n,a.DRAW_POLYGON,l.POLYGON),o(n,a.DRAW_RECTANGLE,l.POLYGON),n);e.MODE_TO_GEOJSON_TYPE=u;var c={POINT:"Point",LINE_STRING:"LineString",POLYGON:"Polygon",RECTANGLE:"Rectangle"};e.RENDER_TYPE=c;var p=(o(i={},a.DRAW_POINT,c.POINT),o(i,a.DRAW_PATH,c.LINE_STRING),o(i,a.DRAW_POLYGON,c.POLYGON),o(i,a.DRAW_RECTANGLE,c.RECTANGLE),i);e.MODE_TO_RENDER_TYPE=p;e.RENDER_STATE={INACTIVE:"INACTIVE",UNCOMMITTED:"UNCOMMITTED",SELECTED:"SELECTED",HOVERED:"HOVERED",CLOSING:"CLOSING"};e.OPERATIONS={NONE:"NONE",SET:"SET",INTERSECT:"INTERSECT",INSERT:"INSERT"};e.STATIC_STYLE={cursor:"default",pointerEvents:"none"};e.ELEMENT_TYPE={FEATURE:"feature",SEGMENT:"segment",VERTEX:"vertex"}},function(t,e,r){"use strict";r.d(e,"a",(function(){return i}));var n=r(10);function i(t,e){if(t){if("string"==typeof t)return Object(n.a)(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Object(n.a)(t,e):void 0}}},function(t,e,r){"use strict";(function(t){r.d(e,"a",(function(){return h}));var n=r(4),i=r(5),o=r(2),a=r(0),s=r(6),l=r(18);var u={container:a.object,gl:a.object,mapboxApiAccessToken:a.string,mapboxApiUrl:a.string,attributionControl:a.bool,preserveDrawingBuffer:a.bool,reuseMaps:a.bool,transformRequest:a.func,mapOptions:a.object,mapStyle:a.oneOfType([a.string,a.object]),preventStyleDiffing:a.bool,visible:a.bool,asyncRender:a.bool,onLoad:a.func,onError:a.func,width:a.number,height:a.number,viewState:a.object,longitude:a.number,latitude:a.number,zoom:a.number,bearing:a.number,pitch:a.number,altitude:a.number},c={container:s.a.body,mapboxApiAccessToken:function(){var e=null;if("undefined"!=typeof window&&window.location){var r=window.location.search.match(/access_token=([^&\/]*)/);e=r&&r[1]}e||void 0===t||(e=e||t.env.MapboxAccessToken||t.env.REACT_APP_MAPBOX_ACCESS_TOKEN);return e||"no-token"}(),mapboxApiUrl:"https://api.mapbox.com",preserveDrawingBuffer:!1,attributionControl:!0,reuseMaps:!1,mapOptions:{},mapStyle:"mapbox://styles/mapbox/light-v8",preventStyleDiffing:!1,visible:!0,asyncRender:!1,onLoad:function(){},onError:function(t){t&&console.error(t.error)},width:0,height:0,longitude:0,latitude:0,zoom:0,bearing:0,pitch:0,altitude:1.5};function p(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"component";t.debug&&a.checkPropTypes(u,t,"prop",e)}var h=function(){function t(e){var r=this;if(Object(n.a)(this,t),Object(o.a)(this,"props",c),Object(o.a)(this,"width",0),Object(o.a)(this,"height",0),Object(o.a)(this,"_fireLoadEvent",(function(){r.props.onLoad({type:"load",target:r._map})})),!e.mapboxgl)throw new Error("Mapbox not available");this.mapboxgl=e.mapboxgl,t.initialized||(t.initialized=!0,this._checkStyleSheet(this.mapboxgl.version)),this._initialize(e)}return Object(i.a)(t,[{key:"finalize",value:function(){return this._destroy(),this}},{key:"setProps",value:function(t){return this._update(this.props,t),this}},{key:"redraw",value:function(){var t=this._map;t.style&&(t._frame&&(t._frame.cancel(),t._frame=null),t._render())}},{key:"getMap",value:function(){return this._map}},{key:"_reuse",value:function(e){this._map=t.savedMap;var r=this._map.getContainer(),n=e.container;for(n.classList.add("mapboxgl-map");r.childNodes.length>0;)n.appendChild(r.childNodes[0]);this._map._container=n,t.savedMap=null,e.mapStyle&&this._map.setStyle(Object(l.a)(e.mapStyle),{diff:!1}),this._map.isStyleLoaded()?this._fireLoadEvent():this._map.once("styledata",this._fireLoadEvent)}},{key:"_create",value:function(e){if(e.reuseMaps&&t.savedMap)this._reuse(e);else{if(e.gl){var r=HTMLCanvasElement.prototype.getContext;HTMLCanvasElement.prototype.getContext=function(){return HTMLCanvasElement.prototype.getContext=r,e.gl}}var n={container:e.container,center:[0,0],zoom:8,pitch:0,bearing:0,maxZoom:24,style:Object(l.a)(e.mapStyle),interactive:!1,trackResize:!1,attributionControl:e.attributionControl,preserveDrawingBuffer:e.preserveDrawingBuffer};e.transformRequest&&(n.transformRequest=e.transformRequest),this._map=new this.mapboxgl.Map(Object.assign({},n,e.mapOptions)),this._map.once("load",e.onLoad),this._map.on("error",e.onError)}return this}},{key:"_destroy",value:function(){this._map&&(t.savedMap?this._map.remove():(t.savedMap=this._map,this._map.off("load",this.props.onLoad),this._map.off("error",this.props.onError),this._map.off("styledata",this._fireLoadEvent)),this._map=null)}},{key:"_initialize",value:function(t){var e=this;p(t=Object.assign({},c,t),"Mapbox"),this.mapboxgl.accessToken=t.mapboxApiAccessToken||c.mapboxApiAccessToken,this.mapboxgl.baseApiUrl=t.mapboxApiUrl,this._create(t);var r=t.container;Object.defineProperty(r,"offsetWidth",{get:function(){return e.width}}),Object.defineProperty(r,"clientWidth",{get:function(){return e.width}}),Object.defineProperty(r,"offsetHeight",{get:function(){return e.height}}),Object.defineProperty(r,"clientHeight",{get:function(){return e.height}});var n=this._map.getCanvas();n&&(n.style.outline="none"),this._updateMapViewport({},t),this._updateMapSize({},t),this.props=t}},{key:"_update",value:function(t,e){if(this._map){p(e=Object.assign({},this.props,e),"Mapbox");var r=this._updateMapViewport(t,e),n=this._updateMapSize(t,e);this._updateMapStyle(t,e),e.asyncRender||!r&&!n||this.redraw(),this.props=e}}},{key:"_updateMapStyle",value:function(t,e){t.mapStyle!==e.mapStyle&&this._map.setStyle(Object(l.a)(e.mapStyle),{diff:!e.preventStyleDiffing})}},{key:"_updateMapSize",value:function(t,e){var r=t.width!==e.width||t.height!==e.height;return r&&(this.width=e.width,this.height=e.height,this._map.resize()),r}},{key:"_updateMapViewport",value:function(t,e){var r=this._getViewState(t),n=this._getViewState(e),i=n.latitude!==r.latitude||n.longitude!==r.longitude||n.zoom!==r.zoom||n.pitch!==r.pitch||n.bearing!==r.bearing||n.altitude!==r.altitude;return i&&(this._map.jumpTo(this._viewStateToMapboxProps(n)),n.altitude!==r.altitude&&(this._map.transform.altitude=n.altitude)),i}},{key:"_getViewState",value:function(t){var e=t.viewState||t,r=e.longitude,n=e.latitude,i=e.zoom,o=e.pitch,a=void 0===o?0:o,s=e.bearing,l=void 0===s?0:s,u=e.altitude;return{longitude:r,latitude:n,zoom:i,pitch:a,bearing:l,altitude:void 0===u?1.5:u}}},{key:"_checkStyleSheet",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"0.47.0";if(void 0!==s.a)try{var e=s.a.createElement("div");e.className="mapboxgl-map",e.style.display="none",s.a.body.appendChild(e);var r="static"!==window.getComputedStyle(e).position;if(!r){var n=s.a.createElement("link");n.setAttribute("rel","stylesheet"),n.setAttribute("type","text/css"),n.setAttribute("href","https://api.tiles.mapbox.com/mapbox-gl-js/v".concat(t,"/mapbox-gl.css")),s.a.head.appendChild(n)}}catch(t){}}},{key:"_viewStateToMapboxProps",value:function(t){return{center:[t.longitude,t.latitude],zoom:t.zoom,bearing:t.bearing,pitch:t.pitch}}}]),t}();Object(o.a)(h,"initialized",!1),Object(o.a)(h,"propTypes",u),Object(o.a)(h,"defaultProps",c),Object(o.a)(h,"savedMap",null)}).call(this,r(56))},function(t,e,r){"use strict";r.d(e,"a",(function(){return u}));var n=r(2);function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function o(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(Object(r),!0).forEach((function(e){Object(n.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function a(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return s(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return s(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,l=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return a=t.done,t},e:function(t){l=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(l)throw o}}}}function s(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var l=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function u(t){if(!t)return null;if("string"==typeof t)return t;t.toJS&&(t=t.toJS());var e,r={},n=a(t.layers);try{for(n.s();!(e=n.n()).done;){var i=e.value;r[i.id]=i}}catch(t){n.e(t)}finally{n.f()}var s=t.layers.map((function(t){var e=r[t.ref],n=null;if("interactive"in t&&delete(n=o({},t)).interactive,e){delete(n=n||o({},t)).ref;var i,s=a(l);try{for(s.s();!(i=s.n()).done;){var u=i.value;u in e&&(n[u]=e[u])}}catch(t){s.e(t)}finally{s.f()}}return n||t}));return o(o({},t),{},{layers:s})}},function(t,e,r){"use strict";r.r(e),r.d(e,"EventManager",(function(){return z}));var n,i,o=r(3),a=r(4),s=r(5),l=r(12),u=r.n(l),c={mousedown:1,mousemove:2,mouseup:4};n=u.a.PointerEventInput,i=n.prototype.handler,n.prototype.handler=function(t){var e=this.store;t.button>0&&(function(t,e){for(var r=0;r<t.length;r++)if(e(t[r]))return!0;return!1}(e,(function(e){return e.pointerId===t.pointerId}))||e.push(t)),i.call(this,t)},u.a.MouseInput.prototype.handler=function(t){var e=c[t.type];1&e&&t.button>=0&&(this.pressed=!0),2&e&&0===t.which&&(e=4),this.pressed&&(4&e&&(this.pressed=!1),this.callback(this.manager,e,{pointers:[t],changedPointers:[t],pointerType:"mouse",srcEvent:t}))};var p=u.a.Manager,h=u.a,f=h?[[h.Pan,{event:"tripan",pointers:3,threshold:0,enable:!1}],[h.Rotate,{enable:!1}],[h.Pinch,{enable:!1}],[h.Swipe,{enable:!1}],[h.Pan,{threshold:0,enable:!1}],[h.Press,{enable:!1}],[h.Tap,{event:"doubletap",taps:2,enable:!1}],[h.Tap,{event:"anytap",enable:!1}],[h.Tap,{enable:!1}]]:null,d={tripan:["rotate","pinch","pan"],rotate:["pinch"],pinch:["pan"],pan:["press","doubletap","anytap","tap"],doubletap:["anytap"],anytap:["tap"]},m={doubletap:["tap"]},g={pointerdown:"pointerdown",pointermove:"pointermove",pointerup:"pointerup",touchstart:"pointerdown",touchmove:"pointermove",touchend:"pointerup",mousedown:"pointerdown",mousemove:"pointermove",mouseup:"pointerup"},y=["keydown","keyup"],v=["mousedown","mousemove","mouseup","mouseover","mouseout","mouseleave"],_=["wheel","mousewheel","DOMMouseScroll"],b={tap:"tap",anytap:"anytap",doubletap:"doubletap",press:"press",pinch:"pinch",pinchin:"pinch",pinchout:"pinch",pinchstart:"pinch",pinchmove:"pinch",pinchend:"pinch",pinchcancel:"pinch",rotate:"rotate",rotatestart:"rotate",rotatemove:"rotate",rotateend:"rotate",rotatecancel:"rotate",tripan:"tripan",tripanstart:"tripan",tripanmove:"tripan",tripanup:"tripan",tripandown:"tripan",tripanleft:"tripan",tripanright:"tripan",tripanend:"tripan",tripancancel:"tripan",pan:"pan",panstart:"pan",panmove:"pan",panup:"pan",pandown:"pan",panleft:"pan",panright:"pan",panend:"pan",pancancel:"pan",swipe:"swipe",swipeleft:"swipe",swiperight:"swipe",swipeup:"swipe",swipedown:"swipe"},x={click:"tap",anyclick:"anytap",dblclick:"doubletap",mousedown:"pointerdown",mousemove:"pointermove",mouseup:"pointerup",mouseover:"pointerover",mouseout:"pointerout",mouseleave:"pointerleave"},w=r(9),E=-1!==w.b.indexOf("firefox"),T=_,A=function(){function t(e,r){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Object(a.a)(this,t),this.element=e,this.callback=r,this.options=Object.assign({enable:!0},i),this.events=T.concat(i.events||[]),this.handleEvent=this.handleEvent.bind(this),this.events.forEach((function(t){return e.addEventListener(t,n.handleEvent,!!w.a&&{passive:!1})}))}return Object(s.a)(t,[{key:"destroy",value:function(){var t=this;this.events.forEach((function(e){return t.element.removeEventListener(e,t.handleEvent)}))}},{key:"enableEventType",value:function(t,e){"wheel"===t&&(this.options.enable=e)}},{key:"handleEvent",value:function(t){if(this.options.enable){var e=t.deltaY;w.c.WheelEvent&&(E&&t.deltaMode===w.c.WheelEvent.DOM_DELTA_PIXEL&&(e/=w.c.devicePixelRatio),t.deltaMode===w.c.WheelEvent.DOM_DELTA_LINE&&(e*=40));var r={x:t.clientX,y:t.clientY};0!==e&&e%4.000244140625==0&&(e=Math.floor(e/4.000244140625)),t.shiftKey&&e&&(e*=.25),this._onWheel(t,-e,r)}}},{key:"_onWheel",value:function(t,e,r){this.callback({type:"wheel",center:r,delta:e,srcEvent:t,pointerType:"mouse",target:t.target})}}]),t}(),C=v,S=function(){function t(e,r){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Object(a.a)(this,t),this.element=e,this.callback=r,this.pressed=!1,this.options=Object.assign({enable:!0},i),this.enableMoveEvent=this.options.enable,this.enableLeaveEvent=this.options.enable,this.enableOutEvent=this.options.enable,this.enableOverEvent=this.options.enable,this.events=C.concat(i.events||[]),this.handleEvent=this.handleEvent.bind(this),this.events.forEach((function(t){return e.addEventListener(t,n.handleEvent)}))}return Object(s.a)(t,[{key:"destroy",value:function(){var t=this;this.events.forEach((function(e){return t.element.removeEventListener(e,t.handleEvent)}))}},{key:"enableEventType",value:function(t,e){"pointermove"===t&&(this.enableMoveEvent=e),"pointerover"===t&&(this.enableOverEvent=e),"pointerout"===t&&(this.enableOutEvent=e),"pointerleave"===t&&(this.enableLeaveEvent=e)}},{key:"handleEvent",value:function(t){this.handleOverEvent(t),this.handleOutEvent(t),this.handleLeaveEvent(t),this.handleMoveEvent(t)}},{key:"handleOverEvent",value:function(t){this.enableOverEvent&&"mouseover"===t.type&&this.callback({type:"pointerover",srcEvent:t,pointerType:"mouse",target:t.target})}},{key:"handleOutEvent",value:function(t){this.enableOutEvent&&"mouseout"===t.type&&this.callback({type:"pointerout",srcEvent:t,pointerType:"mouse",target:t.target})}},{key:"handleLeaveEvent",value:function(t){this.enableLeaveEvent&&"mouseleave"===t.type&&this.callback({type:"pointerleave",srcEvent:t,pointerType:"mouse",target:t.target})}},{key:"handleMoveEvent",value:function(t){if(this.enableMoveEvent)switch(t.type){case"mousedown":t.button>=0&&(this.pressed=!0);break;case"mousemove":0===t.which&&(this.pressed=!1),this.pressed||this.callback({type:"pointermove",srcEvent:t,pointerType:"mouse",target:t.target});break;case"mouseup":this.pressed=!1}}}]),t}(),P=y,I=function(){function t(e,r){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Object(a.a)(this,t),this.element=e,this.callback=r,this.options=Object.assign({enable:!0},i),this.enableDownEvent=this.options.enable,this.enableUpEvent=this.options.enable,this.events=P.concat(i.events||[]),this.handleEvent=this.handleEvent.bind(this),e.tabIndex=i.tabIndex||0,e.style.outline="none",this.events.forEach((function(t){return e.addEventListener(t,n.handleEvent)}))}return Object(s.a)(t,[{key:"destroy",value:function(){var t=this;this.events.forEach((function(e){return t.element.removeEventListener(e,t.handleEvent)}))}},{key:"enableEventType",value:function(t,e){"keydown"===t&&(this.enableDownEvent=e),"keyup"===t&&(this.enableUpEvent=e)}},{key:"handleEvent",value:function(t){var e=t.target||t.srcElement;"INPUT"===e.tagName&&"text"===e.type||"TEXTAREA"===e.tagName||(this.enableDownEvent&&"keydown"===t.type&&this.callback({type:"keydown",srcEvent:t,key:t.key,target:t.target}),this.enableUpEvent&&"keyup"===t.type&&this.callback({type:"keyup",srcEvent:t,key:t.key,target:t.target}))}}]),t}(),D=function(){function t(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Object(a.a)(this,t),this.element=e,this.callback=r,this.options=Object.assign({enable:!0},n),this.handleEvent=this.handleEvent.bind(this),e.addEventListener("contextmenu",this.handleEvent)}return Object(s.a)(t,[{key:"destroy",value:function(){this.element.removeEventListener("contextmenu",this.handleEvent)}},{key:"enableEventType",value:function(t,e){"contextmenu"===t&&(this.options.enable=e)}},{key:"handleEvent",value:function(t){this.options.enable&&this.callback({type:"contextmenu",center:{x:t.clientX,y:t.clientY},srcEvent:t,pointerType:"mouse",target:t.target})}}]),t}(),O=r(11),M={pointerdown:1,pointermove:2,pointerup:4,mousedown:1,mousemove:2,mouseup:4};var B={srcElement:"root",priority:0},k=function(){function t(e){Object(a.a)(this,t),this.eventManager=e,this.handlers=[],this.handlersByElement=new Map,this.handleEvent=this.handleEvent.bind(this),this._active=!1}return Object(s.a)(t,[{key:"isEmpty",value:function(){return!this._active}},{key:"add",value:function(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4&&void 0!==arguments[4]&&arguments[4],o=this.handlers,a=this.handlersByElement;r&&("object"!==Object(O.a)(r)||r.addEventListener)&&(r={srcElement:r}),r=r?Object.assign({},B,r):B;var s=a.get(r.srcElement);s||(s=[],a.set(r.srcElement,s));var l={type:t,handler:e,srcElement:r.srcElement,priority:r.priority};n&&(l.once=!0),i&&(l.passive=!0),o.push(l),this._active=this._active||!l.passive;for(var u=s.length-1;u>=0&&!(s[u].priority>=l.priority);)u--;s.splice(u+1,0,l)}},{key:"remove",value:function(t,e){for(var r=this.handlers,n=this.handlersByElement,i=r.length-1;i>=0;i--){var o=r[i];if(o.type===t&&o.handler===e){r.splice(i,1);var a=n.get(o.srcElement);a.splice(a.indexOf(o),1),0===a.length&&n.delete(o.srcElement)}}this._active=r.some((function(t){return!t.passive}))}},{key:"handleEvent",value:function(t){if(!this.isEmpty()){for(var e=this._normalizeEvent(t),r=t.srcEvent.target;r&&r!==e.rootElement;){if(this._emit(e,r),e.handled)return;r=r.parentNode}this._emit(e,"root")}}},{key:"_emit",value:function(t,e){var r=this.handlersByElement.get(e);if(r){for(var n=!1,i=function(){t.handled=!0},o=function(){t.handled=!0,n=!0},a=[],s=0;s<r.length;s++){var l=r[s],u=l.type,c=l.handler,p=l.once;if(c(Object.assign({},t,{type:u,stopPropagation:i,stopImmediatePropagation:o})),p&&a.push(r[s]),n)break}for(var h=0;h<a.length;h++){var f=a[h],d=f.type,m=f.handler;this.remove(d,m)}}}},{key:"_normalizeEvent",value:function(t){var e=this.eventManager.element;return Object.assign({},t,function(t){var e=M[t.srcEvent.type];if(!e)return null;var r=t.srcEvent,n=r.buttons,i=r.button,o=r.which,a=!1,s=!1,l=!1;return 4===e||2===e&&!Number.isFinite(n)?(a=1===o,s=2===o,l=3===o):2===e?(a=Boolean(1&n),s=Boolean(4&n),l=Boolean(2&n)):1===e&&(a=0===i,s=1===i,l=2===i),{leftButton:a,middleButton:s,rightButton:l}}(t),function(t,e){var r=t.srcEvent;if(!t.center&&!Number.isFinite(r.clientX))return null;var n=t.center||{x:r.clientX,y:r.clientY},i=e.getBoundingClientRect(),o=i.width/e.offsetWidth,a=i.height/e.offsetHeight;return{center:n,offsetCenter:{x:(n.x-i.left-e.clientLeft)/o,y:(n.y-i.top-e.clientTop)/a}}}(t,e),{handled:!1,rootElement:e})}}]),t}();function F(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return L(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return L(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}function L(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var R={events:null,recognizers:null,recognizerOptions:{},Manager:p,touchAction:"none",tabIndex:0},z=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(a.a)(this,t),this.options=Object.assign({},R,r),this.events=new Map,this._onBasicInput=this._onBasicInput.bind(this),this._onOtherEvent=this._onOtherEvent.bind(this),this.setElement(e);var n=r.events;n&&this.on(n)}return Object(s.a)(t,[{key:"setElement",value:function(t){var e=this;if(this.element&&this.destroy(),this.element=t,t){var r=this.options,n=r.Manager;for(var i in this.manager=new n(t,{touchAction:r.touchAction,recognizers:r.recognizers||f}).on("hammer.input",this._onBasicInput),r.recognizers||Object.keys(d).forEach((function(t){var r=e.manager.get(t);r&&d[t].forEach((function(t){r.recognizeWith(t)}))})),r.recognizerOptions){var a=this.manager.get(i);if(a){var s=r.recognizerOptions[i];delete s.enable,a.set(s)}}this.wheelInput=new A(t,this._onOtherEvent,{enable:!1}),this.moveInput=new S(t,this._onOtherEvent,{enable:!1}),this.keyInput=new I(t,this._onOtherEvent,{enable:!1,tabIndex:r.tabIndex}),this.contextmenuInput=new D(t,this._onOtherEvent,{enable:!1});var l,u=F(this.events);try{for(u.s();!(l=u.n()).done;){var c=Object(o.a)(l.value,2),p=c[0],h=c[1];h.isEmpty()||(this._toggleRecognizer(h.recognizerName,!0),this.manager.on(p,h.handleEvent))}}catch(t){u.e(t)}finally{u.f()}}}},{key:"destroy",value:function(){this.element&&(this.wheelInput.destroy(),this.moveInput.destroy(),this.keyInput.destroy(),this.contextmenuInput.destroy(),this.manager.destroy(),this.wheelInput=null,this.moveInput=null,this.keyInput=null,this.contextmenuInput=null,this.manager=null,this.element=null)}},{key:"on",value:function(t,e,r){this._addEventHandler(t,e,r,!1)}},{key:"once",value:function(t,e,r){this._addEventHandler(t,e,r,!0)}},{key:"watch",value:function(t,e,r){this._addEventHandler(t,e,r,!1,!0)}},{key:"off",value:function(t,e){this._removeEventHandler(t,e)}},{key:"_toggleRecognizer",value:function(t,e){var r=this.manager;if(r){var n=r.get(t);if(n&&n.options.enable!==e){n.set({enable:e});var i=m[t];i&&!this.options.recognizers&&i.forEach((function(i){var o=r.get(i);e?(o.requireFailure(t),n.dropRequireFailure(i)):o.dropRequireFailure(t)}))}this.wheelInput.enableEventType(t,e),this.moveInput.enableEventType(t,e),this.keyInput.enableEventType(t,e),this.contextmenuInput.enableEventType(t,e)}}},{key:"_addEventHandler",value:function(t,e,r,n,i){if("string"==typeof t){var o=this.manager,a=this.events,s=x[t]||t,l=a.get(s);l||(l=new k(this),a.set(s,l),l.recognizerName=b[s]||s,o&&o.on(s,l.handleEvent)),l.add(t,e,r,n,i),l.isEmpty()||this._toggleRecognizer(l.recognizerName,!0)}else for(var u in r=e,t)this._addEventHandler(u,t[u],r,n,i)}},{key:"_removeEventHandler",value:function(t,e){if("string"==typeof t){var r=this.events,n=x[t]||t,i=r.get(n);if(i&&(i.remove(t,e),i.isEmpty())){var o,a=i.recognizerName,s=!1,l=F(r.values());try{for(l.s();!(o=l.n()).done;){var u=o.value;if(u.recognizerName===a&&!u.isEmpty()){s=!0;break}}}catch(t){l.e(t)}finally{l.f()}s||this._toggleRecognizer(a,!1)}}else for(var c in t)this._removeEventHandler(c,t[c])}},{key:"_onBasicInput",value:function(t){var e=t.srcEvent,r=g[e.type];r&&this.manager.emit(r,t)}},{key:"_onOtherEvent",value:function(t){this.manager.emit(t.type,t)}}]),t}()},,,function(t,e){t.exports=function(t,e){return e||(e=t.slice(0)),Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(e)}}))},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,r){t.exports=e},function(t,e,r){var n=r(44),i=r(45),o=r(25),a=r(46);t.exports=function(t,e){return n(t)||i(t,e)||o(t,e)||a()},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){var n=r(26);t.exports=function(t,e){if(t){if("string"==typeof t)return n(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(t,e):void 0}},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e){t.exports=function(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_COLOR_RANGE=e.COLOR_RANGES=void 0;var i=n(r(47)),o=n(r(13)),a=n(r(24)),s=n(r(51)),l=r(28);function u(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function c(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?u(Object(r),!0).forEach((function(e){(0,o.default)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):u(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}for(var p=Object.entries(s.default.schemeGroups).reduce((function(t,e){var r=(0,a.default)(e,2),n=r[0],i=r[1];return c(c({},t),i.reduce((function(t,e){return c(c({},t),{},(0,o.default)({},e,n))}),{}))}),{}),h=(0,i.default)(l.VizColorPalette),f=0,d=Object.entries(s.default);f<d.length;f++){var m=(0,a.default)(d[f],2),g=m[0],y=m[1];if("schemeGroups"!==g)for(var v=0,_=Object.entries(y);v<_.length;v++){var b=(0,a.default)(_[v],2),x=b[0],w=b[1];h.push({name:"ColorBrewer ".concat(g,"-").concat(x),type:p[g],category:"ColorBrewer",colors:w})}}var E=h;e.COLOR_RANGES=E;var T=h.find((function(t){return"Global Warming"===t.name}))||{name:"Global Warming",type:"SEQ",category:"Uber",colors:["#5A1846","#900C3F","#C70039","#E3611C","#F1920E","#FFC300"]};e.DEFAULT_COLOR_RANGE=T},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VizColorPalette=e.DataVizColors=e.DIV=e.QUA=e.SIN=e.SEQ=void 0;var n="sequential";e.SEQ=n;e.SIN="singlehue";var i="qualitative";e.QUA=i;var o="diverging";e.DIV=o;var a={aqua:"#12939A",tumbleweed:"#DDB27C",mule_fawn:"#88572C",tree_poppy:"#FF991F",flame:"#F15C17",sapphire:"#223F9A",orchid:"#DA70BF",chathams_blue:"#125C77",med_aquamarine:"#4DC19C",crocodile:"#776E57",java:"#17B8BE",chalky:"#F6D18A",light_taupe:"#B7885E",peach_orange:"#FFCB99",apricot:"#F89570",portage:"#829AE3",light_orchid:"#E79FD5",blue_green:"#1E96BE",bermuda:"#89DAC1",cloudy:"#B3AD9E"};e.DataVizColors=a;var s=Object.values(a),l=[{name:"Uber Viz Qualitative 0",type:i,category:"Uber",colors:s.slice(0,3)},{name:"Uber Viz Qualitative 0.5",type:i,category:"Uber",colors:s.slice(0,4)},{name:"Uber Viz Qualitative 1",type:i,category:"Uber",colors:s.slice(0,5)},{name:"Uber Viz Qualitative 1.2",type:i,category:"Uber",colors:s.slice(0,6)},{name:"Uber Viz Qualitative 1.4",type:i,category:"Uber",colors:s.slice(0,7)},{name:"Uber Viz Qualitative 1.6",type:i,category:"Uber",colors:s.slice(0,8)},{name:"Uber Viz Qualitative 1.8",type:i,category:"Uber",colors:s.slice(0,9)},{name:"Uber Viz Qualitative 2",type:i,category:"Uber",colors:s.slice(0,10)},{name:"Uber Viz Qualitative 3",type:i,category:"Uber",colors:s.slice(0,15)},{name:"Uber Viz Qualitative 4",type:i,category:"Uber",colors:s.slice(0,20)}],u=[{name:"Uber Viz Sequential 1",type:n,category:"Uber",colors:["#E6FAFA","#89C6CA","#00939C"]},{name:"Uber Viz Sequential 2",type:n,category:"Uber",colors:["#E6FAFA","#AAD7DA","#68B4BB","#00939C"]},{name:"Uber Viz Sequential 3",type:n,category:"Uber",colors:["#E6FAFA","#B8E0E1","#89C6CA","#56ACB3","#00939C"]},{name:"Uber Viz Sequential 4",type:n,category:"Uber",colors:["#E6FAFA","#C1E5E6","#9DD0D4","#75BBC1","#4BA7AF","#00939C"]},{name:"Uber Viz Sequential 5",type:n,category:"Uber",colors:["#E6FAFA","#C1E5E6","#9DD0D4","#75BBC1","#4BA7AF","#00939C","#108188"]},{name:"Uber Viz Sequential 6",type:n,category:"Uber",colors:["#E6FAFA","#C1E5E6","#9DD0D4","#75BBC1","#4BA7AF","#00939C","#108188","#0E7077"]}],c=[{name:"Uber Viz Diverging 0",type:o,category:"Uber",colors:["#C22E00","#FEEEE8","#00939C"].reverse()},{name:"Uber Viz Diverging 0.5",type:o,category:"Uber",colors:["#C22E00","#EFBEAE","#A2D4D7","#00939C"].reverse()},{name:"Uber Viz Diverging 1",type:o,category:"Uber",colors:["#C22E00","#EC9370","#FEEEE8","#85C4C8","#00939C"].reverse()},{name:"Uber Viz Diverging 1.5",type:o,category:"Uber",colors:["#C22E00","#DD7755","#F8C0AA","#BAE1E2","#5DBABF","#00939C"].reverse()},{name:"Uber Viz Diverging 2",type:o,category:"Uber",colors:["#C22E00","#E17449","#F5B097","#FEEEE8","#A2D4D7","#65B3BA","#00939C"].reverse()},{name:"Uber Viz Diverging 2.5",type:o,category:"Uber",colors:["#C22E00","#D45F39","#E68F71","#F8C0AA","#BAE1E2","#7CC7CB","#3EADB3","#00939C"].reverse()},{name:"Uber Viz Diverging 3",type:o,category:"Uber",colors:["#C22E00","#DA6436","#EC9370","#F8C0AA","#FEEEE8","#B2DCDF","#65B3BA","#49A6AE","#00939C"].reverse()},{name:"Uber Viz Diverging 3.5",type:o,category:"Uber",colors:["#C22E00","#D0532B","#DD7755","#EB9C80","#F8C0AA","#BAE1E2","#8CCED1","#5DBABF","#2FA7AE","#00939C"].reverse()},{name:"Uber Viz Diverging 4",type:o,category:"Uber",colors:["#C22E00","#D55A2B","#E68059","#F2A587","#F8C0AA","#FEEEE8","#BAE1E2","#97CED1","#71BABF","#49A6AE","#00939C"].reverse()}],p=[].concat(c,u,l,[{name:"UberPool",type:o,category:"Uber",colors:["#223F9A","#2C51BE","#482BBD","#7A0DA6","#AE0E7F","#CF1750","#E31A1A","#FD7900","#FAC200","#FAE300"]},{name:"UberPool 9",type:o,category:"Uber",colors:["#2C51BE","#482BBD","#7A0DA6","#AE0E7F","#CF1750","#E31A1A","#FD7900","#FAC200","#FAE300"]},{name:"UberPool 8",type:o,category:"Uber",colors:["#213E9A","#3C1FA7","#811CB5","#C318B0","#D01367","#DE0F0E","#EC7007","#F9E200"]},{name:"UberPool 7",type:o,category:"Uber",colors:["#213E9A","#461FA9","#9B1BBA","#CA168E","#DA102C","#E95E08","#F9E200"]},{name:"UberPool 6",type:o,category:"Uber",colors:["#213E9A","#551EAD","#C019BD","#D31256","#E6470A","#F9E200"]},{name:"UberPool 5",type:o,category:"Uber",colors:["#213E9A","#6E1DB2","#CA168E","#E2260C","#F9E200"]},{name:"UberPool 4",type:o,category:"Uber",colors:["#213E9A","#9B1BBA","#DA102C","#F9E200"]},{name:"UberPool 3",type:o,category:"Uber",colors:["#213E9A","#CA168E","#F9E200"]},{name:"Ice And Fire 3",type:o,category:"Uber",colors:["#0198BD","#FAFEB3","#D50255"]},{name:"Ice And Fire 4",type:o,category:"Uber",colors:["#0198BD","#E8FEB5","#FEAD54","#D50255"]},{name:"Ice And Fire 5",type:o,category:"Uber",colors:["#0198BD","#49E3CE","#FAFEB3","#FEAD54","#D50255"]},{name:"Ice And Fire",type:o,category:"Uber",colors:["#0198BD","#49E3CE","#E8FEB5","#FEEDB1","#FEAD54","#D50255"]},{name:"Ice And Fire 7",type:o,category:"Uber",colors:["#0198BD","#54BAB9","#A7DCB6","#FAFEB3","#FCD583","#FEAD54","#D50255"]},{name:"Ice And Fire 8",type:o,category:"Uber",colors:["#007A99","#0198BD","#49E3CE","#E8FEB5","#FEEDB1","#FEAD54","#D50255","#7F1941"]},{name:"Global Warming 3",type:n,category:"Uber",colors:["#5A1846","#C70039","#FFC300"]},{name:"Global Warming 4",type:n,category:"Uber",colors:["#5A1846","#831A3D","#E3611C","#FFC300"]},{name:"Global Warming 5",type:n,category:"Uber",colors:["#5A1846","#831A3D","#AC1C17","#D55D0E","#FFC300"]},{name:"Global Warming",type:n,category:"Uber",colors:["#5A1846","#900C3F","#C70039","#E3611C","#F1920E","#FFC300"]},{name:"Global Warming 7",type:n,category:"Uber",colors:["#5A1846","#751A43","#911932","#AC1C17","#C84411","#E37B0A","#FFC300"]},{name:"Global Warming 8",type:n,category:"Uber",colors:["#4C0035","#650031","#7F0023","#98000A","#B21800","#CB4600","#E57F00","#FFC300"]},{name:"Sunrise 3",type:n,category:"Uber",colors:["#355C7D","#C06C84","#F8B195"]},{name:"Sunrise 4",type:n,category:"Uber",colors:["#355C7D","#9A627C","#C86A7E","#F8B195"]},{name:"Sunrise",type:n,category:"Uber",colors:["#355C7D","#6C5B7B","#C06C84","#F67280","#F8B195"]},{name:"Sunrise 6",type:n,category:"Uber",colors:["#355C7D","#63617F","#916681","#D88185","#E8998D","#F8B195"]},{name:"Sunrise 7",type:n,category:"Uber",colors:["#355C7D","#63617F","#916681","#C06C84","#D28389","#E59A8F","#F8B195"]},{name:"Sunrise 8",type:n,category:"Uber",colors:["#194266","#355C7D","#63617F","#916681","#C06C84","#D28389","#E59A8F","#F8B195"]},{name:"Ocean Green 3",type:n,category:"Uber",colors:["#3A748A","#3EACA8","#E5EEc1"]},{name:"Ocean Green 4",type:n,category:"Uber",colors:["#547A82","#3EACA8","#A2D4AB","#E5EEc1"]},{name:"Ocean Green 5",type:n,category:"Uber",colors:["#3A748A","#54A38F","#73BC84","#A9D597","#E5EEc1"]},{name:"Ocean Green 6",type:n,category:"Uber",colors:["#37535E","#3A748A","#4095B5","#52AEC9","#72BFC4","#93CFBF"]},{name:"Ocean Green 7",type:n,category:"Uber",colors:["#3A748A","#4B9A95","#5EAB8B","#73BC84","#92CC8B","#BEDDA5","#E5EEc1"]},{name:"Ocean Green 8",type:n,category:"Uber",colors:["#37535E","#3A748A","#4B9A95","#5EAB8B","#73BC84","#92CC8B","#BEDDA5","#E5EEc1"]},{name:"Pink Wine 3",type:n,category:"Uber",colors:["#50315E","#956485","#EDD1CA"]},{name:"Pink Wine 4",type:n,category:"Uber",colors:["#50315E","#774976","#B28294","#EDD1CA"]},{name:"Pink Wine 5",type:n,category:"Uber",colors:["#50315E","#643D68","#956485","#C1939D","#EDD1CA"]},{name:"Pink Wine 6",type:n,category:"Uber",colors:["#2C1E3D","#573660","#83537C","#A6758E","#C99DA4","#EDD1CA"]},{name:"Pink Wine 7",type:n,category:"Uber",colors:["#2C1E3D","#4F315A","#774976","#956485","#B28294","#CFA4A8","#EDD1CA"]},{name:"Pink Wine",type:n,category:"Uber",colors:["#2C1E3D","#50315E","#764476","#9A5B88","#B77495","#CF91A3","#E0B1B3","#EDD1CA"]},{name:"Purple Blue Yellow 3",type:n,category:"Uber",colors:["#2B1E3E","#5EA28D","#D6DEBF"]},{name:"Purple Blue Yellow 4",type:n,category:"Uber",colors:["#2B1E3E","#466373","#7BA889","#D6DEBF"]},{name:"Purple Blue Yellow 5",type:n,category:"Uber",colors:["#2B1E3E","#3A4B66","#5F8E86","#8BB68D","#D6DEBF"]},{name:"Purple Blue Yellow 6",type:n,category:"Uber",colors:["#2B1E3E","#343D5E","#4F777E","#709E87","#99BE95","#D6DEBF"]},{name:"Purple Blue Yellow 7",type:n,category:"Uber",colors:["#2B1E3E","#303558","#466373","#5F8E86","#7BA889","#A4C39B","#D6DEBF"]},{name:"Purple Blue Yellow",type:n,category:"Uber",colors:["#2B1E3E","#383C65","#3E5F7E","#49838A","#5EA28D","#82BB92","#AECEA1","#D6DEBF"]}]);e.VizColorPalette=p},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),e.getHTMLMapModeTileUrl=pt,e.PROJECTED_PIXEL_SIZE_MULTIPLIER=e.MAP_CONTROLS=e.DATASET_FORMATS=e.DEFAULT_FEATURE_FLAGS=e.LOADING_METHODS=e.MAP_INFO_CHARACTER=e.MAP_THUMBNAIL_DIMENSION=e.MAX_GPU_FILTERS=e.PLOT_TYPES=e.EDITOR_MODES=e.GEOCODER_ICON_SIZE=e.GEOCODER_ICON_COLOR=e.GEOCODER_GEO_OFFSET=e.GEOCODER_LAYER_ID=e.GEOCODER_DATASET_NAME=e.SPEED_CONTROL_STEP=e.SPEED_CONTROL_RANGE=e.DEFAULT_TIME_FORMAT=e.ANIMATION_WINDOW=e.FPS=e.BASE_SPEED=e.THROTTLE_NOTIFICATION_TIME=e.DEFAULT_NOTIFICATION_TOPICS=e.DEFAULT_NOTIFICATION_TYPES=e.DEFAULT_NOTIFICATION_MESSAGE=e.DEFAULT_UUID_COUNT=e.EXPORT_HTML_MAP_MODE_OPTIONS=e.EXPORT_MAP_FORMAT_OPTIONS=e.EXPORT_HTML_MAP_MODES=e.EXPORT_MAP_FORMATS=e.EXPORT_DATA_TYPE_OPTIONS=e.EXPORT_DATA_TYPE=e.EXPORT_IMG_RESOLUTION_OPTIONS=e.TwoXResolutionOption=e.OneXResolutionOption=e.EXPORT_IMG_RATIO_OPTIONS=e.SixteenByNineRatioOption=e.FourByThreeRatioOption=e.CustomRatioOption=e.ScreenRatioOption=e.EXPORT_IMG_RATIOS=e.RESOLUTIONS=e.MAX_DEFAULT_TOOLTIPS=e.LAYER_BLENDINGS=e.NO_VALUE_COLOR=e.DEFAULT_TOOLTIP_FIELDS=e.DEFAULT_LAYER_COLOR=e.CHANNEL_SCALE_SUPPORTED_FIELDS=e.FIELD_OPTS=e.DEFAULT_AGGREGATION=e.notSupportAggrOpts=e.notSupportedScaleOpts=e.ordinalFieldAggrScaleFunctions=e.ordinalFieldScaleFunctions=e.linearFieldAggrScaleFunctions=e.linearFieldScaleFunctions=e.AGGREGATION_TYPES=e.CHANNEL_SCALES=e.HIGHLIGH_COLOR_3D=e.FIELD_COLORS=e.FIELD_TYPE_DISPLAY=e.TABLE_OPTION_LIST=e.TABLE_OPTION=e.SORT_ORDER=e.ALL_FIELD_TYPES=e.SCALE_FUNC=e.SCALE_TYPES=e.FILTER_TYPES=e.TRIP_ARC_FIELDS=e.ALTITUDE_FIELDS=e.TRIP_POINT_FIELDS=e.ICON_FIELDS=e.GEOJSON_FIELDS=e.DEFAULT_MAP_STYLES=e.DEFAULT_LAYER_GROUPS=e.PANELS=e.SIDEBAR_PANELS=e.THEME=e.DIMENSIONS=e.KEPLER_GL_WEBSITE=e.KEPLER_GL_VERSION=e.KEPLER_GL_NAME=e.SHARE_MAP_ID=e.OVERWRITE_MAP_ID=e.SAVE_MAP_ID=e.EXPORT_MAP_ID=e.ADD_MAP_STYLE_ID=e.EXPORT_DATA_ID=e.EXPORT_IMAGE_ID=e.ADD_DATA_ID=e.DELETE_DATA_ID=e.DATA_TABLE_ID=e.TRANSITION_DURATION=e.DEFAULT_MAPBOX_API_URL=e.ICON_PREFIX=e.CLOUDFRONT=e.ACTION_PREFIX=void 0;var i,o,a,s,l,u,c,p,h,f,d,m,g=n(r(13)),y=n(r(30)),v=r(52),_=r(69),b=r(34);function x(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function w(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?x(Object(r),!0).forEach((function(e){(0,g.default)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):x(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}e.ACTION_PREFIX="@@kepler.gl/";var E="https://d1a3f4spazzrp4.cloudfront.net/kepler.gl";e.CLOUDFRONT=E;var T="".concat(E,"/geodude");e.ICON_PREFIX=T;e.DEFAULT_MAPBOX_API_URL="https://api.mapbox.com";e.TRANSITION_DURATION=0;e.DATA_TABLE_ID="dataTable";e.DELETE_DATA_ID="deleteData";e.ADD_DATA_ID="addData";e.EXPORT_IMAGE_ID="exportImage";e.EXPORT_DATA_ID="exportData";e.ADD_MAP_STYLE_ID="addMapStyle";e.EXPORT_MAP_ID="exportMap";e.SAVE_MAP_ID="saveMap";e.OVERWRITE_MAP_ID="overwriteMap";e.SHARE_MAP_ID="shareMap";e.KEPLER_GL_NAME="kepler.gl";e.KEPLER_GL_VERSION="3.0.0-alpha.0";e.KEPLER_GL_WEBSITE="http://kepler.gl/";e.DIMENSIONS={sidePanel:{width:300,margin:{top:20,left:20,bottom:30,right:20},headerHeight:96},mapControl:{width:184,padding:12,mapLegend:{pinned:{bottom:22,right:12}}}};var A=(0,y.default)({light:null,dark:null,base:null});e.THEME=A;var C=[{id:"layer",label:"sidebar.panels.layer",onClick:null},{id:"filter",label:"sidebar.panels.filter",onClick:null},{id:"interaction",label:"sidebar.panels.interaction",onClick:null},{id:"map",label:"sidebar.panels.basemap",onClick:null}];e.SIDEBAR_PANELS=C;var S=C;e.PANELS=S;var P=[{slug:"label",filter:function(t){return t.id.match(/(?=(label|place-|poi-))/)},defaultVisibility:!0},{slug:"road",filter:function(t){return t.id.match(/(?=(road|railway|tunnel|street|bridge))(?!.*label)/)},defaultVisibility:!0},{slug:"border",filter:function(t){return t.id.match(/border|boundaries|boundary/)},defaultVisibility:!1},{slug:"building",filter:function(t){return t.id.match(/building/)},defaultVisibility:!0},{slug:"water",filter:function(t){return t.id.match(/(?=(water|stream|ferry))/)},defaultVisibility:!0},{slug:"land",filter:function(t){return t.id.match(/(?=(parks|landcover|industrial|sand|hillshade))/)},defaultVisibility:!0},{slug:"3d building",filter:function(){return!1},defaultVisibility:!1}];e.DEFAULT_LAYER_GROUPS=P;var I=[{id:"dark",label:"Dark",url:"mapbox://styles/uberdata/cjoqbbf6l9k302sl96tyvka09",icon:"".concat(T,"/UBER_DARK_V2.png"),layerGroups:P},{id:"light",label:"Light",url:"mapbox://styles/uberdata/cjoqb9j339k1f2sl9t5ic5bn4",icon:"".concat(T,"/UBER_LIGHT_V2.png"),layerGroups:P},{id:"muted",label:"Muted Light",url:"mapbox://styles/uberdata/cjfyl03kp1tul2smf5v2tbdd4",icon:"".concat(T,"/UBER_MUTED_LIGHT.png"),layerGroups:P},{id:"muted_night",label:"Muted Night",url:"mapbox://styles/uberdata/cjfxhlikmaj1b2soyzevnywgs",icon:"".concat(T,"/UBER_MUTED_NIGHT.png"),layerGroups:P},{id:"satellite",label:"Satellite",url:"mapbox://styles/mapbox/satellite-v9",icon:"".concat(T,"/UBER_SATELLITE.png")}];e.DEFAULT_MAP_STYLES=I;e.GEOJSON_FIELDS={geojson:["_geojson","all_points","geojson"]};e.ICON_FIELDS={icon:["icon"]};e.TRIP_POINT_FIELDS=[["lat","lng"],["lat","lon"],["lat","long"],["latitude","longitude"]];e.ALTITUDE_FIELDS=["alt","altitude"];e.TRIP_ARC_FIELDS={lat0:"begintrip",lng0:"begintrip",lat1:"dropoff",lng1:"dropoff"};var D=(0,y.default)({range:null,select:null,input:null,timeRange:null,multiSelect:null,polygon:null});e.FILTER_TYPES=D;var O=(0,y.default)({ordinal:null,quantile:null,quantize:null,linear:null,sqrt:null,log:null,point:null});e.SCALE_TYPES=O;var M=(i={},(0,g.default)(i,O.linear,_.scaleLinear),(0,g.default)(i,O.quantize,_.scaleQuantize),(0,g.default)(i,O.quantile,_.scaleQuantile),(0,g.default)(i,O.ordinal,_.scaleOrdinal),(0,g.default)(i,O.sqrt,_.scaleSqrt),(0,g.default)(i,O.log,_.scaleLog),(0,g.default)(i,O.point,_.scalePoint),i);e.SCALE_FUNC=M;var B=(0,y.default)({boolean:null,date:null,geojson:null,integer:null,real:null,string:null,timestamp:null,point:null});e.ALL_FIELD_TYPES=B;var k=(0,y.default)({ASCENDING:null,DESCENDING:null,UNSORT:null});e.SORT_ORDER=k;var F=(0,y.default)({SORT_ASC:null,SORT_DES:null,UNSORT:null,PIN:null,UNPIN:null,COPY:null});e.TABLE_OPTION=F;var L=[{value:F.SORT_ASC,display:"Sort Ascending",icon:"ArrowUp",condition:function(t){return t.sortMode!==k.ASCENDING}},{value:F.SORT_DES,display:"Sort Descending",icon:"ArrowDown",condition:function(t){return t.sortMode!==k.DESCENDING}},{value:F.UNSORT,display:"Unsort Column",icon:"Cancel",condition:function(t){return t.isSorted}},{value:F.PIN,display:"Pin Column",icon:"Pin",condition:function(t){return!t.isPinned}},{value:F.UNPIN,display:"Unpin Column",icon:"Cancel",condition:function(t){return t.isPinned}},{value:F.COPY,display:"Copy Column",icon:"Clipboard"}];e.TABLE_OPTION_LIST=L;var R=(o={},(0,g.default)(o,B.boolean,{label:"bool",color:"231, 189, 194"}),(0,g.default)(o,B.date,{label:"date",color:"160, 106, 206"}),(0,g.default)(o,B.geojson,{label:"geo",color:"106, 160, 206"}),(0,g.default)(o,B.integer,{label:"int",color:"248, 194, 28"}),(0,g.default)(o,B.real,{label:"float",color:"248, 194, 28"}),(0,g.default)(o,B.string,{label:"string",color:"140, 210, 205"}),(0,g.default)(o,B.timestamp,{label:"time",color:"106, 160, 56"}),(0,g.default)(o,B.point,{label:"point",color:"0, 172, 237"}),o);e.FIELD_TYPE_DISPLAY=R;var z={default:"237, 88, 106"};e.FIELD_COLORS=z;e.HIGHLIGH_COLOR_3D=[255,255,255,60];var N=(0,y.default)({color:null,radius:null,size:null,colorAggr:null,sizeAggr:null});e.CHANNEL_SCALES=N;var j={count:"count",average:"average",maximum:"maximum",minimum:"minimum",median:"median",stdev:"stdev",sum:"sum",variance:"variance",mode:"mode",countUnique:"count unique"};e.AGGREGATION_TYPES=j;var U=(a={},(0,g.default)(a,N.color,[O.quantize,O.quantile]),(0,g.default)(a,N.radius,[O.sqrt]),(0,g.default)(a,N.size,[O.linear,O.sqrt,O.log]),a);e.linearFieldScaleFunctions=U;var V=(u={},(0,g.default)(u,N.colorAggr,(s={},(0,g.default)(s,j.average,[O.quantize,O.quantile]),(0,g.default)(s,j.maximum,[O.quantize,O.quantile]),(0,g.default)(s,j.minimum,[O.quantize,O.quantile]),(0,g.default)(s,j.median,[O.quantize,O.quantile]),(0,g.default)(s,j.stdev,[O.quantize,O.quantile]),(0,g.default)(s,j.sum,[O.quantize,O.quantile]),(0,g.default)(s,j.variance,[O.quantize,O.quantile]),s)),(0,g.default)(u,N.sizeAggr,(l={},(0,g.default)(l,j.average,[O.linear,O.sqrt,O.log]),(0,g.default)(l,j.maximum,[O.linear,O.sqrt,O.log]),(0,g.default)(l,j.minimum,[O.linear,O.sqrt,O.log]),(0,g.default)(l,j.median,[O.linear,O.sqrt,O.log]),(0,g.default)(l,j.stdev,[O.linear,O.sqrt,O.log]),(0,g.default)(l,j.sum,[O.linear,O.sqrt,O.log]),(0,g.default)(l,j.variance,[O.linear,O.sqrt,O.log]),l)),u);e.linearFieldAggrScaleFunctions=V;var q=(c={},(0,g.default)(c,N.color,[O.ordinal]),(0,g.default)(c,N.radius,[O.point]),(0,g.default)(c,N.size,[O.point]),c);e.ordinalFieldScaleFunctions=q;var H=(h={},(0,g.default)(h,N.colorAggr,(p={},(0,g.default)(p,j.mode,[O.ordinal]),(0,g.default)(p,j.countUnique,[O.quantize,O.quantile]),p)),(0,g.default)(h,N.sizeAggr,{}),h);e.ordinalFieldAggrScaleFunctions=H;var G=(f={},(0,g.default)(f,N.color,[]),(0,g.default)(f,N.radius,[]),(0,g.default)(f,N.size,[]),f);e.notSupportedScaleOpts=G;var Z=(d={},(0,g.default)(d,N.colorAggr,{}),(0,g.default)(d,N.sizeAggr,{}),d);e.notSupportAggrOpts=Z;var W=(m={},(0,g.default)(m,N.colorAggr,(0,g.default)({},j.count,[O.quantize,O.quantile])),(0,g.default)(m,N.sizeAggr,(0,g.default)({},j.count,[O.linear,O.sqrt,O.log])),m);e.DEFAULT_AGGREGATION=W;var Y={string:{type:"categorical",scale:w(w({},q),H),format:{legend:function(t){return t},tooltip:[]}},real:{type:"numerical",scale:w(w({},U),V),format:{legend:function(t){return t},tooltip:[b.TOOLTIP_FORMAT_TYPES.NONE,b.TOOLTIP_FORMAT_TYPES.DECIMAL,b.TOOLTIP_FORMAT_TYPES.PERCENTAGE]}},timestamp:{type:"time",scale:w(w({},U),Z),format:{legend:function(t){return t},tooltip:[b.TOOLTIP_FORMAT_TYPES.NONE,b.TOOLTIP_FORMAT_TYPES.DATE,b.TOOLTIP_FORMAT_TYPES.DATE_TIME]}},integer:{type:"numerical",scale:w(w({},U),V),format:{legend:function(t){return t},tooltip:[b.TOOLTIP_FORMAT_TYPES.NONE,b.TOOLTIP_FORMAT_TYPES.DECIMAL,b.TOOLTIP_FORMAT_TYPES.PERCENTAGE]}},boolean:{type:"boolean",scale:w(w({},q),H),format:{legend:function(t){return t},tooltip:[b.TOOLTIP_FORMAT_TYPES.NONE,b.TOOLTIP_FORMAT_TYPES.BOOLEAN]}},date:{scale:w(w({},q),H),format:{legend:function(t){return t},tooltip:[b.TOOLTIP_FORMAT_TYPES.NONE,b.TOOLTIP_FORMAT_TYPES.DATE]}},geojson:{type:"geometry",scale:w(w({},G),Z),format:{legend:function(t){return"..."},tooltip:[]}}};e.FIELD_OPTS=Y;var X=Object.keys(N).reduce((function(t,e){return w(w({},t),{},(0,g.default)({},e,Object.keys(Y).filter((function(t){return Object.keys(Y[t].scale[e]).length}))))}),{});e.CHANNEL_SCALE_SUPPORTED_FIELDS=X;e.DEFAULT_LAYER_COLOR={tripArc:"#9226C6",begintrip_lat:"#1E96BE",dropoff_lat:"#FF991F",request_lat:"#52A353"};e.DEFAULT_TOOLTIP_FIELDS=[];e.NO_VALUE_COLOR=[0,0,0,0];e.LAYER_BLENDINGS={additive:{label:"layerBlending.additive",blendFunc:["SRC_ALPHA","DST_ALPHA"],blendEquation:"FUNC_ADD"},normal:{label:"layerBlending.normal",blendFunc:["SRC_ALPHA","ONE_MINUS_SRC_ALPHA","ONE","ONE_MINUS_SRC_ALPHA"],blendEquation:["FUNC_ADD","FUNC_ADD"]},subtractive:{label:"layerBlending.subtractive",blendFunc:["ONE","ONE_MINUS_DST_COLOR","SRC_ALPHA","DST_ALPHA"],blendEquation:["FUNC_SUBTRACT","FUNC_ADD"]}};e.MAX_DEFAULT_TOOLTIPS=5;var K=(0,y.default)({ONE_X:null,TWO_X:null});e.RESOLUTIONS=K;var J=(0,y.default)({SCREEN:null,FOUR_BY_THREE:null,SIXTEEN_BY_NINE:null,CUSTOM:null});e.EXPORT_IMG_RATIOS=J;var Q={id:J.SCREEN,label:"modal.exportImage.ratioOriginalScreen",getSize:function(t,e){return{width:t,height:e}}};e.ScreenRatioOption=Q;var $={id:J.CUSTOM,hidden:!0,label:"modal.exportImage.ratioCustom",getSize:function(t,e){return{width:t,height:e}}};e.CustomRatioOption=$;var tt={id:J.FOUR_BY_THREE,label:"modal.exportImage.ratio4_3",getSize:function(t,e){return{width:t,height:Math.round(.75*t)}}};e.FourByThreeRatioOption=tt;var et={id:J.SIXTEEN_BY_NINE,label:"modal.exportImage.ratio16_9",getSize:function(t,e){return{width:t,height:Math.round(.5625*t)}}};e.SixteenByNineRatioOption=et;var rt=[Q,$,tt,et];e.EXPORT_IMG_RATIO_OPTIONS=rt;var nt={id:K.ONE_X,label:"1x",available:!0,scale:1,getSize:function(t,e){return{width:t,height:e}}};e.OneXResolutionOption=nt;var it={id:K.TWO_X,label:"2x",available:!0,scale:2,getSize:function(t,e){return{width:2*t,height:2*e}}};e.TwoXResolutionOption=it;var ot=[nt,it];e.EXPORT_IMG_RESOLUTION_OPTIONS=ot;var at=(0,y.default)({CSV:null});e.EXPORT_DATA_TYPE=at;var st=[{id:at.CSV,label:at.CSV.toLowerCase(),available:!0}];e.EXPORT_DATA_TYPE_OPTIONS=st;var lt=(0,y.default)({HTML:null,JSON:null});e.EXPORT_MAP_FORMATS=lt;var ut=(0,y.default)({READ:null,EDIT:null});e.EXPORT_HTML_MAP_MODES=ut;var ct=Object.entries(lt).map((function(t){return{id:t[0],label:t[1].toLowerCase(),available:!0}}));function pt(t){return"https://d1a3f4spazzrp4.cloudfront.net/kepler.gl/documentation/map-".concat(t.toLowerCase(),"-mode.png")}e.EXPORT_MAP_FORMAT_OPTIONS=ct;var ht=Object.entries(ut).map((function(t){return{id:t[0],label:"modal.exportMap.html.".concat(t[1].toLowerCase()),available:!0,url:pt(t[1])}}));e.EXPORT_HTML_MAP_MODE_OPTIONS=ht;e.DEFAULT_UUID_COUNT=6;e.DEFAULT_NOTIFICATION_MESSAGE="MESSAGE_NOT_PROVIDED";var ft=(0,y.default)({info:null,error:null,warning:null,success:null});e.DEFAULT_NOTIFICATION_TYPES=ft;var dt=(0,y.default)({global:null,file:null});e.DEFAULT_NOTIFICATION_TOPICS=dt;e.THROTTLE_NOTIFICATION_TIME=2500;e.BASE_SPEED=600;e.FPS=60;var mt=(0,y.default)({free:null,incremental:null,point:null,interval:null});e.ANIMATION_WINDOW=mt;e.DEFAULT_TIME_FORMAT="MM/DD/YY HH:mm:ssa";e.SPEED_CONTROL_RANGE=[0,10];e.SPEED_CONTROL_STEP=.001;e.GEOCODER_DATASET_NAME="geocoder_dataset";e.GEOCODER_LAYER_ID="geocoder_layer";e.GEOCODER_GEO_OFFSET=.05;e.GEOCODER_ICON_COLOR=[255,0,0];e.GEOCODER_ICON_SIZE=80;var gt={READ_ONLY:v.EditorModes.READ_ONLY,DRAW_POLYGON:v.EditorModes.DRAW_POLYGON,DRAW_RECTANGLE:v.EditorModes.DRAW_RECTANGLE,EDIT:v.EditorModes.EDIT_VERTEX};e.EDITOR_MODES=gt;var yt=(0,y.default)({histogram:null,lineChart:null});e.PLOT_TYPES=yt;e.MAX_GPU_FILTERS=4;e.MAP_THUMBNAIL_DIMENSION={width:300,height:200};e.MAP_INFO_CHARACTER={title:100,description:100};var vt=(0,y.default)({upload:null,storage:null});e.LOADING_METHODS=vt;e.DEFAULT_FEATURE_FLAGS={};var _t=(0,y.default)({row:null,geojson:null,csv:null,keplergl:null});e.DATASET_FORMATS=_t;var bt=(0,y.default)({visibleLayers:null,mapLegend:null,toggle3d:null,splitMap:null,mapDraw:null,mapLocale:null});e.MAP_CONTROLS=bt;e.PROJECTED_PIXEL_SIZE_MULTIPLIER=2/3},function(t,e,r){"use strict";t.exports=function(t){var e,r={};if(!(t instanceof Object)||Array.isArray(t))throw new Error("keyMirror(...): Argument must be an object.");for(e in t)t.hasOwnProperty(e)&&(r[e]=e);return r}},function(t,e,r){t.exports=function(){"use strict";var t,e,r;function n(n,i){if(t)if(e){var o="var sharedChunk = {}; ("+t+")(sharedChunk); ("+e+")(sharedChunk);",a={};t(a),r=i(a),"undefined"!=typeof window&&(r.workerUrl=window.URL.createObjectURL(new Blob([o],{type:"text/javascript"})))}else e=i;else t=i}return n(0,(function(t){function e(t,e){return t(e={exports:{}},e.exports),e.exports}var r=n;function n(t,e,r,n){this.cx=3*t,this.bx=3*(r-t)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*e,this.by=3*(n-e)-this.cy,this.ay=1-this.cy-this.by,this.p1x=t,this.p1y=n,this.p2x=r,this.p2y=n}n.prototype.sampleCurveX=function(t){return((this.ax*t+this.bx)*t+this.cx)*t},n.prototype.sampleCurveY=function(t){return((this.ay*t+this.by)*t+this.cy)*t},n.prototype.sampleCurveDerivativeX=function(t){return(3*this.ax*t+2*this.bx)*t+this.cx},n.prototype.solveCurveX=function(t,e){var r,n,i,o,a;for(void 0===e&&(e=1e-6),i=t,a=0;a<8;a++){if(o=this.sampleCurveX(i)-t,Math.abs(o)<e)return i;var s=this.sampleCurveDerivativeX(i);if(Math.abs(s)<1e-6)break;i-=o/s}if((i=t)<(r=0))return r;if(i>(n=1))return n;for(;r<n;){if(o=this.sampleCurveX(i),Math.abs(o-t)<e)return i;t>o?r=i:n=i,i=.5*(n-r)+r}return i},n.prototype.solve=function(t,e){return this.sampleCurveY(this.solveCurveX(t,e))};var i=o;function o(t,e){this.x=t,this.y=e}o.prototype={clone:function(){return new o(this.x,this.y)},add:function(t){return this.clone()._add(t)},sub:function(t){return this.clone()._sub(t)},multByPoint:function(t){return this.clone()._multByPoint(t)},divByPoint:function(t){return this.clone()._divByPoint(t)},mult:function(t){return this.clone()._mult(t)},div:function(t){return this.clone()._div(t)},rotate:function(t){return this.clone()._rotate(t)},rotateAround:function(t,e){return this.clone()._rotateAround(t,e)},matMult:function(t){return this.clone()._matMult(t)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(t){return this.x===t.x&&this.y===t.y},dist:function(t){return Math.sqrt(this.distSqr(t))},distSqr:function(t){var e=t.x-this.x,r=t.y-this.y;return e*e+r*r},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(t){return Math.atan2(this.y-t.y,this.x-t.x)},angleWith:function(t){return this.angleWithSep(t.x,t.y)},angleWithSep:function(t,e){return Math.atan2(this.x*e-this.y*t,this.x*t+this.y*e)},_matMult:function(t){var e=t[2]*this.x+t[3]*this.y;return this.x=t[0]*this.x+t[1]*this.y,this.y=e,this},_add:function(t){return this.x+=t.x,this.y+=t.y,this},_sub:function(t){return this.x-=t.x,this.y-=t.y,this},_mult:function(t){return this.x*=t,this.y*=t,this},_div:function(t){return this.x/=t,this.y/=t,this},_multByPoint:function(t){return this.x*=t.x,this.y*=t.y,this},_divByPoint:function(t){return this.x/=t.x,this.y/=t.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var t=this.y;return this.y=this.x,this.x=-t,this},_rotate:function(t){var e=Math.cos(t),r=Math.sin(t),n=r*this.x+e*this.y;return this.x=e*this.x-r*this.y,this.y=n,this},_rotateAround:function(t,e){var r=Math.cos(t),n=Math.sin(t),i=e.y+n*(this.x-e.x)+r*(this.y-e.y);return this.x=e.x+r*(this.x-e.x)-n*(this.y-e.y),this.y=i,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},o.convert=function(t){return t instanceof o?t:Array.isArray(t)?new o(t[0],t[1]):t};var a="undefined"!=typeof self?self:{},s=Math.pow(2,53)-1;function l(t,e,n,i){var o=new r(t,e,n,i);return function(t){return o.solve(t)}}var u=l(.25,.1,.25,1);function c(t,e,r){return Math.min(r,Math.max(e,t))}function p(t,e,r){var n=r-e,i=((t-e)%n+n)%n+e;return i===e?r:i}function h(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];for(var n=0,i=e;n<i.length;n+=1){var o=i[n];for(var a in o)t[a]=o[a]}return t}var f=1;function d(){return f++}function m(){return function t(e){return e?(e^16*Math.random()>>e/4).toString(16):([1e7]+-[1e3]+-4e3+-8e3+-1e11).replace(/[018]/g,t)}()}function g(t){return!!t&&/^[0-9a-f]{8}-[0-9a-f]{4}-[4][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(t)}function y(t,e){t.forEach((function(t){e[t]&&(e[t]=e[t].bind(e))}))}function v(t,e){return-1!==t.indexOf(e,t.length-e.length)}function _(t,e,r){var n={};for(var i in t)n[i]=e.call(r||this,t[i],i,t);return n}function b(t,e,r){var n={};for(var i in t)e.call(r||this,t[i],i,t)&&(n[i]=t[i]);return n}function x(t){return Array.isArray(t)?t.map(x):"object"==typeof t&&t?_(t,x):t}var w={};function E(t){w[t]||("undefined"!=typeof console&&console.warn(t),w[t]=!0)}function T(t,e,r){return(r.y-t.y)*(e.x-t.x)>(e.y-t.y)*(r.x-t.x)}function A(t){for(var e=0,r=0,n=t.length,i=n-1,o=void 0,a=void 0;r<n;i=r++)e+=((a=t[i]).x-(o=t[r]).x)*(o.y+a.y);return e}function C(){return"undefined"!=typeof WorkerGlobalScope&&"undefined"!=typeof self&&self instanceof WorkerGlobalScope}function S(t){var e={};if(t.replace(/(?:^|(?:\s*\,\s*))([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,(function(t,r,n,i){var o=n||i;return e[r]=!o||o.toLowerCase(),""})),e["max-age"]){var r=parseInt(e["max-age"],10);isNaN(r)?delete e["max-age"]:e["max-age"]=r}return e}var P=null;function I(t){if(null==P){var e=t.navigator?t.navigator.userAgent:null;P=!!t.safari||!(!e||!(/\b(iPad|iPhone|iPod)\b/.test(e)||e.match("Safari")&&!e.match("Chrome")))}return P}function D(t){try{var e=a[t];return e.setItem("_mapbox_test_",1),e.removeItem("_mapbox_test_"),!0}catch(t){return!1}}var O,M,B,k,F=a.performance&&a.performance.now?a.performance.now.bind(a.performance):Date.now.bind(Date),L=a.requestAnimationFrame||a.mozRequestAnimationFrame||a.webkitRequestAnimationFrame||a.msRequestAnimationFrame,R=a.cancelAnimationFrame||a.mozCancelAnimationFrame||a.webkitCancelAnimationFrame||a.msCancelAnimationFrame,z={now:F,frame:function(t){var e=L(t);return{cancel:function(){return R(e)}}},getImageData:function(t,e){void 0===e&&(e=0);var r=a.document.createElement("canvas"),n=r.getContext("2d");if(!n)throw new Error("failed to create canvas 2d context");return r.width=t.width,r.height=t.height,n.drawImage(t,0,0,t.width,t.height),n.getImageData(-e,-e,t.width+2*e,t.height+2*e)},resolveURL:function(t){return O||(O=a.document.createElement("a")),O.href=t,O.href},hardwareConcurrency:a.navigator&&a.navigator.hardwareConcurrency||4,get devicePixelRatio(){return a.devicePixelRatio},get prefersReducedMotion(){return!!a.matchMedia&&(null==M&&(M=a.matchMedia("(prefers-reduced-motion: reduce)")),M.matches)}},N={API_URL:"https://api.mapbox.com",get EVENTS_URL(){return this.API_URL?0===this.API_URL.indexOf("https://api.mapbox.cn")?"https://events.mapbox.cn/events/v2":0===this.API_URL.indexOf("https://api.mapbox.com")?"https://events.mapbox.com/events/v2":null:null},FEEDBACK_URL:"https://apps.mapbox.com/feedback",REQUIRE_ACCESS_TOKEN:!0,ACCESS_TOKEN:null,MAX_PARALLEL_IMAGE_REQUESTS:16},j={supported:!1,testSupport:function(t){!U&&k&&(V?q(t):B=t)}},U=!1,V=!1;function q(t){var e=t.createTexture();t.bindTexture(t.TEXTURE_2D,e);try{if(t.texImage2D(t.TEXTURE_2D,0,t.RGBA,t.RGBA,t.UNSIGNED_BYTE,k),t.isContextLost())return;j.supported=!0}catch(t){}t.deleteTexture(e),U=!0}a.document&&((k=a.document.createElement("img")).onload=function(){B&&q(B),B=null,V=!0},k.onerror=function(){U=!0,B=null},k.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA=");var H="01",G=function(t,e){this._transformRequestFn=t,this._customAccessToken=e,this._createSkuToken()};function Z(t){return 0===t.indexOf("mapbox:")}G.prototype._createSkuToken=function(){var t=function(){for(var t="",e=0;e<10;e++)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return{token:["1",H,t].join(""),tokenExpiresAt:Date.now()+432e5}}();this._skuToken=t.token,this._skuTokenExpiresAt=t.tokenExpiresAt},G.prototype._isSkuTokenExpired=function(){return Date.now()>this._skuTokenExpiresAt},G.prototype.transformRequest=function(t,e){return this._transformRequestFn&&this._transformRequestFn(t,e)||{url:t}},G.prototype.normalizeStyleURL=function(t,e){if(!Z(t))return t;var r=K(t);return r.path="/styles/v1"+r.path,this._makeAPIURL(r,this._customAccessToken||e)},G.prototype.normalizeGlyphsURL=function(t,e){if(!Z(t))return t;var r=K(t);return r.path="/fonts/v1"+r.path,this._makeAPIURL(r,this._customAccessToken||e)},G.prototype.normalizeSourceURL=function(t,e){if(!Z(t))return t;var r=K(t);return r.path="/v4/"+r.authority+".json",r.params.push("secure"),this._makeAPIURL(r,this._customAccessToken||e)},G.prototype.normalizeSpriteURL=function(t,e,r,n){var i=K(t);return Z(t)?(i.path="/styles/v1"+i.path+"/sprite"+e+r,this._makeAPIURL(i,this._customAccessToken||n)):(i.path+=""+e+r,J(i))},G.prototype.normalizeTileURL=function(t,e){if(this._isSkuTokenExpired()&&this._createSkuToken(),t&&!Z(t))return t;var r=K(t);r.path=r.path.replace(/(\.(png|jpg)\d*)(?=$)/,(z.devicePixelRatio>=2||512===e?"@2x":"")+(j.supported?".webp":"$1")),r.path=r.path.replace(/^.+\/v4\//,"/"),r.path="/v4"+r.path;var n=this._customAccessToken||function(t){for(var e=0,r=t;e<r.length;e+=1){var n=r[e].match(/^access_token=(.*)$/);if(n)return n[1]}return null}(r.params)||N.ACCESS_TOKEN;return N.REQUIRE_ACCESS_TOKEN&&n&&this._skuToken&&r.params.push("sku="+this._skuToken),this._makeAPIURL(r,n)},G.prototype.canonicalizeTileURL=function(t,e){var r=K(t);if(!r.path.match(/(^\/v4\/)/)||!r.path.match(/\.[\w]+$/))return t;var n="mapbox://tiles/";n+=r.path.replace("/v4/","");var i=r.params;return e&&(i=i.filter((function(t){return!t.match(/^access_token=/)}))),i.length&&(n+="?"+i.join("&")),n},G.prototype.canonicalizeTileset=function(t,e){for(var r=!!e&&Z(e),n=[],i=0,o=t.tiles||[];i<o.length;i+=1){var a=o[i];Y(a)?n.push(this.canonicalizeTileURL(a,r)):n.push(a)}return n},G.prototype._makeAPIURL=function(t,e){var r="See https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes",n=K(N.API_URL);if(t.protocol=n.protocol,t.authority=n.authority,"http"===t.protocol){var i=t.params.indexOf("secure");i>=0&&t.params.splice(i,1)}if("/"!==n.path&&(t.path=""+n.path+t.path),!N.REQUIRE_ACCESS_TOKEN)return J(t);if(!(e=e||N.ACCESS_TOKEN))throw new Error("An API access token is required to use Mapbox GL. "+r);if("s"===e[0])throw new Error("Use a public access token (pk.*) with Mapbox GL, not a secret access token (sk.*). "+r);return t.params=t.params.filter((function(t){return-1===t.indexOf("access_token")})),t.params.push("access_token="+e),J(t)};var W=/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/|\?|$)/i;function Y(t){return W.test(t)}var X=/^(\w+):\/\/([^/?]*)(\/[^?]+)?\??(.+)?/;function K(t){var e=t.match(X);if(!e)throw new Error("Unable to parse URL object");return{protocol:e[1],authority:e[2],path:e[3]||"/",params:e[4]?e[4].split("&"):[]}}function J(t){var e=t.params.length?"?"+t.params.join("&"):"";return t.protocol+"://"+t.authority+t.path+e}function Q(t){if(!t)return null;var e=t.split(".");if(!e||3!==e.length)return null;try{return JSON.parse(decodeURIComponent(a.atob(e[1]).split("").map((function(t){return"%"+("00"+t.charCodeAt(0).toString(16)).slice(-2)})).join("")))}catch(t){return null}}var $=function(t){this.type=t,this.anonId=null,this.eventData={},this.queue=[],this.pendingRequest=null};$.prototype.getStorageKey=function(t){var e,r=Q(N.ACCESS_TOKEN);return e=r&&r.u?a.btoa(encodeURIComponent(r.u).replace(/%([0-9A-F]{2})/g,(function(t,e){return String.fromCharCode(Number("0x"+e))}))):N.ACCESS_TOKEN||"",t?"mapbox.eventData."+t+":"+e:"mapbox.eventData:"+e},$.prototype.fetchEventData=function(){var t=D("localStorage"),e=this.getStorageKey(),r=this.getStorageKey("uuid");if(t)try{var n=a.localStorage.getItem(e);n&&(this.eventData=JSON.parse(n));var i=a.localStorage.getItem(r);i&&(this.anonId=i)}catch(t){E("Unable to read from LocalStorage")}},$.prototype.saveEventData=function(){var t=D("localStorage"),e=this.getStorageKey(),r=this.getStorageKey("uuid");if(t)try{a.localStorage.setItem(r,this.anonId),Object.keys(this.eventData).length>=1&&a.localStorage.setItem(e,JSON.stringify(this.eventData))}catch(t){E("Unable to write to LocalStorage")}},$.prototype.processRequests=function(t){},$.prototype.postEvent=function(t,e,r,n){var i=this;if(N.EVENTS_URL){var o=K(N.EVENTS_URL);o.params.push("access_token="+(n||N.ACCESS_TOKEN||""));var a={event:this.type,created:new Date(t).toISOString(),sdkIdentifier:"mapbox-gl-js",sdkVersion:"1.13.1",skuId:H,userId:this.anonId},s=e?h(a,e):a,l={url:J(o),headers:{"Content-Type":"text/plain"},body:JSON.stringify([s])};this.pendingRequest=xt(l,(function(t){i.pendingRequest=null,r(t),i.saveEventData(),i.processRequests(n)}))}},$.prototype.queueRequest=function(t,e){this.queue.push(t),this.processRequests(e)};var tt,et,rt=function(t){function e(){t.call(this,"map.load"),this.success={},this.skuToken=""}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.postMapLoadEvent=function(t,e,r,n){this.skuToken=r,(N.EVENTS_URL&&n||N.ACCESS_TOKEN&&Array.isArray(t)&&t.some((function(t){return Z(t)||Y(t)})))&&this.queueRequest({id:e,timestamp:Date.now()},n)},e.prototype.processRequests=function(t){var e=this;if(!this.pendingRequest&&0!==this.queue.length){var r=this.queue.shift(),n=r.id,i=r.timestamp;n&&this.success[n]||(this.anonId||this.fetchEventData(),g(this.anonId)||(this.anonId=m()),this.postEvent(i,{skuToken:this.skuToken},(function(t){t||n&&(e.success[n]=!0)}),t))}},e}($),nt=new(function(t){function e(e){t.call(this,"appUserTurnstile"),this._customAccessToken=e}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.postTurnstileEvent=function(t,e){N.EVENTS_URL&&N.ACCESS_TOKEN&&Array.isArray(t)&&t.some((function(t){return Z(t)||Y(t)}))&&this.queueRequest(Date.now(),e)},e.prototype.processRequests=function(t){var e=this;if(!this.pendingRequest&&0!==this.queue.length){this.anonId&&this.eventData.lastSuccess&&this.eventData.tokenU||this.fetchEventData();var r=Q(N.ACCESS_TOKEN),n=r?r.u:N.ACCESS_TOKEN,i=n!==this.eventData.tokenU;g(this.anonId)||(this.anonId=m(),i=!0);var o=this.queue.shift();if(this.eventData.lastSuccess){var a=new Date(this.eventData.lastSuccess),s=new Date(o),l=(o-this.eventData.lastSuccess)/864e5;i=i||l>=1||l<-1||a.getDate()!==s.getDate()}else i=!0;if(!i)return this.processRequests();this.postEvent(o,{"enabled.telemetry":!1},(function(t){t||(e.eventData.lastSuccess=o,e.eventData.tokenU=n)}),t)}},e}($)),it=nt.postTurnstileEvent.bind(nt),ot=new rt,at=ot.postMapLoadEvent.bind(ot),st=500,lt=50;function ut(){a.caches&&!tt&&(tt=a.caches.open("mapbox-tiles"))}function ct(t){var e=t.indexOf("?");return e<0?t:t.slice(0,e)}var pt,ht=1/0;function ft(){return null==pt&&(pt=a.OffscreenCanvas&&new a.OffscreenCanvas(1,1).getContext("2d")&&"function"==typeof a.createImageBitmap),pt}var dt={Unknown:"Unknown",Style:"Style",Source:"Source",Tile:"Tile",Glyphs:"Glyphs",SpriteImage:"SpriteImage",SpriteJSON:"SpriteJSON",Image:"Image"};"function"==typeof Object.freeze&&Object.freeze(dt);var mt,gt,yt=function(t){function e(e,r,n){401===r&&Y(n)&&(e+=": you may have provided an invalid Mapbox access token. See https://www.mapbox.com/api-documentation/#access-tokens-and-token-scopes"),t.call(this,e),this.status=r,this.url=n,this.name=this.constructor.name,this.message=e}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.toString=function(){return this.name+": "+this.message+" ("+this.status+"): "+this.url},e}(Error),vt=C()?function(){return self.worker&&self.worker.referrer}:function(){return("blob:"===a.location.protocol?a.parent:a).location.href},_t=function(t,e){if(!(/^file:/.test(r=t.url)||/^file:/.test(vt())&&!/^\w+:/.test(r))){if(a.fetch&&a.Request&&a.AbortController&&a.Request.prototype.hasOwnProperty("signal"))return function(t,e){var r,n=new a.AbortController,i=new a.Request(t.url,{method:t.method||"GET",body:t.body,credentials:t.credentials,headers:t.headers,referrer:vt(),signal:n.signal}),o=!1,s=!1,l=(r=i.url).indexOf("sku=")>0&&Y(r);"json"===t.type&&i.headers.set("Accept","application/json");var u=function(r,n,o){if(!s){if(r&&"SecurityError"!==r.message&&E(r),n&&o)return c(n);var u=Date.now();a.fetch(i).then((function(r){if(r.ok){var n=l?r.clone():null;return c(r,n,u)}return e(new yt(r.statusText,r.status,t.url))})).catch((function(t){20!==t.code&&e(new Error(t.message))}))}},c=function(r,n,l){("arrayBuffer"===t.type?r.arrayBuffer():"json"===t.type?r.json():r.text()).then((function(t){s||(n&&l&&function(t,e,r){if(ut(),tt){var n={status:e.status,statusText:e.statusText,headers:new a.Headers};e.headers.forEach((function(t,e){return n.headers.set(e,t)}));var i=S(e.headers.get("Cache-Control")||"");i["no-store"]||(i["max-age"]&&n.headers.set("Expires",new Date(r+1e3*i["max-age"]).toUTCString()),new Date(n.headers.get("Expires")).getTime()-r<42e4||function(t,e){if(void 0===et)try{new Response(new ReadableStream),et=!0}catch(t){et=!1}et?e(t.body):t.blob().then(e)}(e,(function(e){var r=new a.Response(e,n);ut(),tt&&tt.then((function(e){return e.put(ct(t.url),r)})).catch((function(t){return E(t.message)}))})))}}(i,n,l),o=!0,e(null,t,r.headers.get("Cache-Control"),r.headers.get("Expires")))})).catch((function(t){s||e(new Error(t.message))}))};return l?function(t,e){if(ut(),!tt)return e(null);var r=ct(t.url);tt.then((function(t){t.match(r).then((function(n){var i=function(t){if(!t)return!1;var e=new Date(t.headers.get("Expires")||0),r=S(t.headers.get("Cache-Control")||"");return e>Date.now()&&!r["no-cache"]}(n);t.delete(r),i&&t.put(r,n.clone()),e(null,n,i)})).catch(e)})).catch(e)}(i,u):u(null,null),{cancel:function(){s=!0,o||n.abort()}}}(t,e);if(C()&&self.worker&&self.worker.actor)return self.worker.actor.send("getResource",t,e,void 0,!0)}var r;return function(t,e){var r=new a.XMLHttpRequest;for(var n in r.open(t.method||"GET",t.url,!0),"arrayBuffer"===t.type&&(r.responseType="arraybuffer"),t.headers)r.setRequestHeader(n,t.headers[n]);return"json"===t.type&&(r.responseType="text",r.setRequestHeader("Accept","application/json")),r.withCredentials="include"===t.credentials,r.onerror=function(){e(new Error(r.statusText))},r.onload=function(){if((r.status>=200&&r.status<300||0===r.status)&&null!==r.response){var n=r.response;if("json"===t.type)try{n=JSON.parse(r.response)}catch(t){return e(t)}e(null,n,r.getResponseHeader("Cache-Control"),r.getResponseHeader("Expires"))}else e(new yt(r.statusText,r.status,t.url))},r.send(t.body),{cancel:function(){return r.abort()}}}(t,e)},bt=function(t,e){return _t(h(t,{type:"arrayBuffer"}),e)},xt=function(t,e){return _t(h(t,{method:"POST"}),e)},wt="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";mt=[],gt=0;var Et=function(t,e){if(j.supported&&(t.headers||(t.headers={}),t.headers.accept="image/webp,*/*"),gt>=N.MAX_PARALLEL_IMAGE_REQUESTS){var r={requestParameters:t,callback:e,cancelled:!1,cancel:function(){this.cancelled=!0}};return mt.push(r),r}gt++;var n=!1,i=function(){if(!n)for(n=!0,gt--;mt.length&&gt<N.MAX_PARALLEL_IMAGE_REQUESTS;){var t=mt.shift();t.cancelled||(t.cancel=Et(t.requestParameters,t.callback).cancel)}},o=bt(t,(function(t,r,n,o){i(),t?e(t):r&&(ft()?function(t,e){var r=new a.Blob([new Uint8Array(t)],{type:"image/png"});a.createImageBitmap(r).then((function(t){e(null,t)})).catch((function(t){e(new Error("Could not load image because of "+t.message+". Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."))}))}(r,e):function(t,e,r,n){var i=new a.Image,o=a.URL;i.onload=function(){e(null,i),o.revokeObjectURL(i.src),i.onload=null,a.requestAnimationFrame((function(){i.src=wt}))},i.onerror=function(){return e(new Error("Could not load image. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."))};var s=new a.Blob([new Uint8Array(t)],{type:"image/png"});i.cacheControl=r,i.expires=n,i.src=t.byteLength?o.createObjectURL(s):wt}(r,e,n,o))}));return{cancel:function(){o.cancel(),i()}}};function Tt(t,e,r){r[t]&&-1!==r[t].indexOf(e)||(r[t]=r[t]||[],r[t].push(e))}function At(t,e,r){if(r&&r[t]){var n=r[t].indexOf(e);-1!==n&&r[t].splice(n,1)}}var Ct=function(t,e){void 0===e&&(e={}),h(this,e),this.type=t},St=function(t){function e(e,r){void 0===r&&(r={}),t.call(this,"error",h({error:e},r))}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e}(Ct),Pt=function(){};Pt.prototype.on=function(t,e){return this._listeners=this._listeners||{},Tt(t,e,this._listeners),this},Pt.prototype.off=function(t,e){return At(t,e,this._listeners),At(t,e,this._oneTimeListeners),this},Pt.prototype.once=function(t,e){return this._oneTimeListeners=this._oneTimeListeners||{},Tt(t,e,this._oneTimeListeners),this},Pt.prototype.fire=function(t,e){"string"==typeof t&&(t=new Ct(t,e||{}));var r=t.type;if(this.listens(r)){t.target=this;for(var n=0,i=this._listeners&&this._listeners[r]?this._listeners[r].slice():[];n<i.length;n+=1)i[n].call(this,t);for(var o=0,a=this._oneTimeListeners&&this._oneTimeListeners[r]?this._oneTimeListeners[r].slice():[];o<a.length;o+=1){var s=a[o];At(r,s,this._oneTimeListeners),s.call(this,t)}var l=this._eventedParent;l&&(h(t,"function"==typeof this._eventedParentData?this._eventedParentData():this._eventedParentData),l.fire(t))}else t instanceof St&&console.error(t.error);return this},Pt.prototype.listens=function(t){return this._listeners&&this._listeners[t]&&this._listeners[t].length>0||this._oneTimeListeners&&this._oneTimeListeners[t]&&this._oneTimeListeners[t].length>0||this._eventedParent&&this._eventedParent.listens(t)},Pt.prototype.setEventedParent=function(t,e){return this._eventedParent=t,this._eventedParentData=e,this};var It={$version:8,$root:{version:{required:!0,type:"enum",values:[8]},name:{type:"string"},metadata:{type:"*"},center:{type:"array",value:"number"},zoom:{type:"number"},bearing:{type:"number",default:0,period:360,units:"degrees"},pitch:{type:"number",default:0,units:"degrees"},light:{type:"light"},sources:{required:!0,type:"sources"},sprite:{type:"string"},glyphs:{type:"string"},transition:{type:"transition"},layers:{required:!0,type:"array",value:"layer"}},sources:{"*":{type:"source"}},source:["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],source_vector:{type:{required:!0,type:"enum",values:{vector:{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},scheme:{type:"enum",values:{xyz:{},tms:{}},default:"xyz"},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},attribution:{type:"string"},promoteId:{type:"promoteId"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_raster:{type:{required:!0,type:"enum",values:{raster:{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},tileSize:{type:"number",default:512,units:"pixels"},scheme:{type:"enum",values:{xyz:{},tms:{}},default:"xyz"},attribution:{type:"string"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_raster_dem:{type:{required:!0,type:"enum",values:{"raster-dem":{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},tileSize:{type:"number",default:512,units:"pixels"},attribution:{type:"string"},encoding:{type:"enum",values:{terrarium:{},mapbox:{}},default:"mapbox"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_geojson:{type:{required:!0,type:"enum",values:{geojson:{}}},data:{type:"*"},maxzoom:{type:"number",default:18},attribution:{type:"string"},buffer:{type:"number",default:128,maximum:512,minimum:0},filter:{type:"*"},tolerance:{type:"number",default:.375},cluster:{type:"boolean",default:!1},clusterRadius:{type:"number",default:50,minimum:0},clusterMaxZoom:{type:"number"},clusterMinPoints:{type:"number"},clusterProperties:{type:"*"},lineMetrics:{type:"boolean",default:!1},generateId:{type:"boolean",default:!1},promoteId:{type:"promoteId"}},source_video:{type:{required:!0,type:"enum",values:{video:{}}},urls:{required:!0,type:"array",value:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},source_image:{type:{required:!0,type:"enum",values:{image:{}}},url:{required:!0,type:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},layer:{id:{type:"string",required:!0},type:{type:"enum",values:{fill:{},line:{},symbol:{},circle:{},heatmap:{},"fill-extrusion":{},raster:{},hillshade:{},background:{}},required:!0},metadata:{type:"*"},source:{type:"string"},"source-layer":{type:"string"},minzoom:{type:"number",minimum:0,maximum:24},maxzoom:{type:"number",minimum:0,maximum:24},filter:{type:"filter"},layout:{type:"layout"},paint:{type:"paint"}},layout:["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background"],layout_background:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_fill:{"fill-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_circle:{"circle-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_heatmap:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_line:{"line-cap":{type:"enum",values:{butt:{},round:{},square:{}},default:"butt",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-join":{type:"enum",values:{bevel:{},round:{},miter:{}},default:"miter",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{type:"number",default:2,requires:[{"line-join":"miter"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-round-limit":{type:"number",default:1.05,requires:[{"line-join":"round"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_symbol:{"symbol-placement":{type:"enum",values:{point:{},line:{},"line-center":{}},default:"point",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-spacing":{type:"number",default:250,minimum:1,units:"pixels",requires:[{"symbol-placement":"line"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{type:"boolean",default:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{type:"enum",values:{auto:{},"viewport-y":{},source:{}},default:"auto",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{type:"boolean",default:!1,requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{type:"boolean",default:!1,requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-optional":{type:"boolean",default:!1,requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-size":{type:"number",default:1,minimum:0,units:"factor of the original icon size",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{type:"enum",values:{none:{},width:{},height:{},both:{}},default:"none",requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",requires:["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-image":{type:"resolvedImage",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{type:"number",default:2,minimum:0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-keep-upright":{type:"boolean",default:!1,requires:["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{type:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},default:"center",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-field":{type:"formatted",default:"",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-font":{type:"array",value:"string",default:["Open Sans Regular","Arial Unicode MS Regular"],requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-size":{type:"number",default:16,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{type:"number",default:1.2,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-letter-spacing":{type:"number",default:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-justify":{type:"enum",values:{auto:{},left:{},center:{},right:{}},default:"center",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{type:"number",units:"ems",default:0,requires:["text-field"],"property-type":"data-driven",expression:{interpolated:!0,parameters:["zoom","feature"]}},"text-variable-anchor":{type:"array",value:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-anchor":{type:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},default:"center",requires:["text-field",{"!":"text-variable-anchor"}],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{type:"number",default:45,units:"degrees",requires:["text-field",{"symbol-placement":["line","line-center"]}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-writing-mode":{type:"array",value:"enum",values:{horizontal:{},vertical:{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-keep-upright":{type:"boolean",default:!0,requires:["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-transform":{type:"enum",values:{none:{},uppercase:{},lowercase:{}},default:"none",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-offset":{type:"array",value:"number",units:"ems",length:2,default:[0,0],requires:["text-field",{"!":"text-radial-offset"}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{type:"boolean",default:!1,requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{type:"boolean",default:!1,requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-optional":{type:"boolean",default:!1,requires:["text-field","icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_raster:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_hillshade:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},filter:{type:"array",value:"*"},filter_operator:{type:"enum",values:{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},in:{},"!in":{},all:{},any:{},none:{},has:{},"!has":{},within:{}}},geometry_type:{type:"enum",values:{Point:{},LineString:{},Polygon:{}}},function:{expression:{type:"expression"},stops:{type:"array",value:"function_stop"},base:{type:"number",default:1,minimum:0},property:{type:"string",default:"$zoom"},type:{type:"enum",values:{identity:{},exponential:{},interval:{},categorical:{}},default:"exponential"},colorSpace:{type:"enum",values:{rgb:{},lab:{},hcl:{}},default:"rgb"},default:{type:"*",required:!1}},function_stop:{type:"array",minimum:0,maximum:24,value:["number","color"],length:2},expression:{type:"array",value:"*",minimum:1},light:{anchor:{type:"enum",default:"viewport",values:{map:{},viewport:{}},"property-type":"data-constant",transition:!1,expression:{interpolated:!1,parameters:["zoom"]}},position:{type:"array",default:[1.15,210,30],length:3,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},intensity:{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},paint:["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background"],paint_fill:{"fill-antialias":{type:"boolean",default:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{type:"color",transition:!0,requires:[{"!":"fill-pattern"},{"fill-antialias":!0}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"}},"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-extrusion-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-extrusion-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"fill-extrusion-height":{type:"number",default:0,minimum:0,units:"meters",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{type:"number",default:0,minimum:0,units:"meters",transition:!0,requires:["fill-extrusion-height"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{type:"boolean",default:!0,transition:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_line:{"line-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"line-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["line-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-width":{type:"number",default:1,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{type:"number",default:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{type:"array",value:"number",minimum:0,transition:!0,units:"line widths",requires:[{"!":"line-pattern"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"line-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-gradient":{type:"color",transition:!1,requires:[{"!":"line-dasharray"},{"!":"line-pattern"},{source:"geojson",has:{lineMetrics:!0}}],expression:{interpolated:!0,parameters:["line-progress"]},"property-type":"color-ramp"}},paint_circle:{"circle-radius":{type:"number",default:5,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{type:"number",default:0,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["circle-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{type:"enum",values:{map:{},viewport:{}},default:"map",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"}},paint_heatmap:{"heatmap-radius":{type:"number",default:30,minimum:1,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{type:"number",default:1,minimum:0,transition:!1,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{type:"number",default:1,minimum:0,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"heatmap-color":{type:"color",default:["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],transition:!1,expression:{interpolated:!0,parameters:["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_symbol:{"icon-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{type:"color",default:"#000000",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["icon-image","icon-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{type:"color",default:"#000000",transition:!0,overridable:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["text-field","text-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_raster:{"raster-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{type:"number",default:0,period:360,transition:!0,units:"degrees",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{type:"number",default:0,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-saturation":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-contrast":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-resampling":{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{type:"number",default:300,minimum:0,transition:!1,units:"milliseconds",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_hillshade:{"hillshade-illumination-direction":{type:"number",default:335,minimum:0,maximum:359,transition:!1,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{type:"number",default:.5,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_background:{"background-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"background-pattern"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"background-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},transition:{duration:{type:"number",default:300,minimum:0,units:"milliseconds"},delay:{type:"number",default:0,minimum:0,units:"milliseconds"}},"property-type":{"data-driven":{type:"property-type"},"cross-faded":{type:"property-type"},"cross-faded-data-driven":{type:"property-type"},"color-ramp":{type:"property-type"},"data-constant":{type:"property-type"},constant:{type:"property-type"}},promoteId:{"*":{type:"string"}}},Dt=function(t,e,r,n){this.message=(t?t+": ":"")+r,n&&(this.identifier=n),null!=e&&e.__line__&&(this.line=e.__line__)};function Ot(t){var e=t.value;return e?[new Dt(t.key,e,"constants have been deprecated as of v8")]:[]}function Mt(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];for(var n=0,i=e;n<i.length;n+=1){var o=i[n];for(var a in o)t[a]=o[a]}return t}function Bt(t){return t instanceof Number||t instanceof String||t instanceof Boolean?t.valueOf():t}function kt(t){if(Array.isArray(t))return t.map(kt);if(t instanceof Object&&!(t instanceof Number||t instanceof String||t instanceof Boolean)){var e={};for(var r in t)e[r]=kt(t[r]);return e}return Bt(t)}var Ft=function(t){function e(e,r){t.call(this,r),this.message=r,this.key=e}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e}(Error),Lt=function(t,e){void 0===e&&(e=[]),this.parent=t,this.bindings={};for(var r=0,n=e;r<n.length;r+=1){var i=n[r];this.bindings[i[0]]=i[1]}};Lt.prototype.concat=function(t){return new Lt(this,t)},Lt.prototype.get=function(t){if(this.bindings[t])return this.bindings[t];if(this.parent)return this.parent.get(t);throw new Error(t+" not found in scope.")},Lt.prototype.has=function(t){return!!this.bindings[t]||!!this.parent&&this.parent.has(t)};var Rt={kind:"null"},zt={kind:"number"},Nt={kind:"string"},jt={kind:"boolean"},Ut={kind:"color"},Vt={kind:"object"},qt={kind:"value"},Ht={kind:"collator"},Gt={kind:"formatted"},Zt={kind:"resolvedImage"};function Wt(t,e){return{kind:"array",itemType:t,N:e}}function Yt(t){if("array"===t.kind){var e=Yt(t.itemType);return"number"==typeof t.N?"array<"+e+", "+t.N+">":"value"===t.itemType.kind?"array":"array<"+e+">"}return t.kind}var Xt=[Rt,zt,Nt,jt,Ut,Gt,Vt,Wt(qt),Zt];function Kt(t,e){if("error"===e.kind)return null;if("array"===t.kind){if("array"===e.kind&&(0===e.N&&"value"===e.itemType.kind||!Kt(t.itemType,e.itemType))&&("number"!=typeof t.N||t.N===e.N))return null}else{if(t.kind===e.kind)return null;if("value"===t.kind)for(var r=0,n=Xt;r<n.length;r+=1)if(!Kt(n[r],e))return null}return"Expected "+Yt(t)+" but found "+Yt(e)+" instead."}function Jt(t,e){return e.some((function(e){return e.kind===t.kind}))}function Qt(t,e){return e.some((function(e){return"null"===e?null===t:"array"===e?Array.isArray(t):"object"===e?t&&!Array.isArray(t)&&"object"==typeof t:e===typeof t}))}var $t=e((function(t,e){var r={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],rebeccapurple:[102,51,153,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function n(t){return(t=Math.round(t))<0?0:t>255?255:t}function i(t){return n("%"===t[t.length-1]?parseFloat(t)/100*255:parseInt(t))}function o(t){return(e="%"===t[t.length-1]?parseFloat(t)/100:parseFloat(t))<0?0:e>1?1:e;var e}function a(t,e,r){return r<0?r+=1:r>1&&(r-=1),6*r<1?t+(e-t)*r*6:2*r<1?e:3*r<2?t+(e-t)*(2/3-r)*6:t}try{e.parseCSSColor=function(t){var e,s=t.replace(/ /g,"").toLowerCase();if(s in r)return r[s].slice();if("#"===s[0])return 4===s.length?(e=parseInt(s.substr(1),16))>=0&&e<=4095?[(3840&e)>>4|(3840&e)>>8,240&e|(240&e)>>4,15&e|(15&e)<<4,1]:null:7===s.length&&(e=parseInt(s.substr(1),16))>=0&&e<=16777215?[(16711680&e)>>16,(65280&e)>>8,255&e,1]:null;var l=s.indexOf("("),u=s.indexOf(")");if(-1!==l&&u+1===s.length){var c=s.substr(0,l),p=s.substr(l+1,u-(l+1)).split(","),h=1;switch(c){case"rgba":if(4!==p.length)return null;h=o(p.pop());case"rgb":return 3!==p.length?null:[i(p[0]),i(p[1]),i(p[2]),h];case"hsla":if(4!==p.length)return null;h=o(p.pop());case"hsl":if(3!==p.length)return null;var f=(parseFloat(p[0])%360+360)%360/360,d=o(p[1]),m=o(p[2]),g=m<=.5?m*(d+1):m+d-m*d,y=2*m-g;return[n(255*a(y,g,f+1/3)),n(255*a(y,g,f)),n(255*a(y,g,f-1/3)),h];default:return null}}return null}}catch(t){}})).parseCSSColor,te=function(t,e,r,n){void 0===n&&(n=1),this.r=t,this.g=e,this.b=r,this.a=n};te.parse=function(t){if(t){if(t instanceof te)return t;if("string"==typeof t){var e=$t(t);if(e)return new te(e[0]/255*e[3],e[1]/255*e[3],e[2]/255*e[3],e[3])}}},te.prototype.toString=function(){var t=this.toArray(),e=t[1],r=t[2],n=t[3];return"rgba("+Math.round(t[0])+","+Math.round(e)+","+Math.round(r)+","+n+")"},te.prototype.toArray=function(){var t=this.a;return 0===t?[0,0,0,0]:[255*this.r/t,255*this.g/t,255*this.b/t,t]},te.black=new te(0,0,0,1),te.white=new te(1,1,1,1),te.transparent=new te(0,0,0,0),te.red=new te(1,0,0,1);var ee=function(t,e,r){this.sensitivity=t?e?"variant":"case":e?"accent":"base",this.locale=r,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})};ee.prototype.compare=function(t,e){return this.collator.compare(t,e)},ee.prototype.resolvedLocale=function(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale};var re=function(t,e,r,n,i){this.text=t,this.image=e,this.scale=r,this.fontStack=n,this.textColor=i},ne=function(t){this.sections=t};ne.fromString=function(t){return new ne([new re(t,null,null,null,null)])},ne.prototype.isEmpty=function(){return 0===this.sections.length||!this.sections.some((function(t){return 0!==t.text.length||t.image&&0!==t.image.name.length}))},ne.factory=function(t){return t instanceof ne?t:ne.fromString(t)},ne.prototype.toString=function(){return 0===this.sections.length?"":this.sections.map((function(t){return t.text})).join("")},ne.prototype.serialize=function(){for(var t=["format"],e=0,r=this.sections;e<r.length;e+=1){var n=r[e];if(n.image)t.push(["image",n.image.name]);else{t.push(n.text);var i={};n.fontStack&&(i["text-font"]=["literal",n.fontStack.split(",")]),n.scale&&(i["font-scale"]=n.scale),n.textColor&&(i["text-color"]=["rgba"].concat(n.textColor.toArray())),t.push(i)}}return t};var ie=function(t){this.name=t.name,this.available=t.available};function oe(t,e,r,n){return"number"==typeof t&&t>=0&&t<=255&&"number"==typeof e&&e>=0&&e<=255&&"number"==typeof r&&r>=0&&r<=255?void 0===n||"number"==typeof n&&n>=0&&n<=1?null:"Invalid rgba value ["+[t,e,r,n].join(", ")+"]: 'a' must be between 0 and 1.":"Invalid rgba value ["+("number"==typeof n?[t,e,r,n]:[t,e,r]).join(", ")+"]: 'r', 'g', and 'b' must be between 0 and 255."}function ae(t){if(null===t)return!0;if("string"==typeof t)return!0;if("boolean"==typeof t)return!0;if("number"==typeof t)return!0;if(t instanceof te)return!0;if(t instanceof ee)return!0;if(t instanceof ne)return!0;if(t instanceof ie)return!0;if(Array.isArray(t)){for(var e=0,r=t;e<r.length;e+=1)if(!ae(r[e]))return!1;return!0}if("object"==typeof t){for(var n in t)if(!ae(t[n]))return!1;return!0}return!1}function se(t){if(null===t)return Rt;if("string"==typeof t)return Nt;if("boolean"==typeof t)return jt;if("number"==typeof t)return zt;if(t instanceof te)return Ut;if(t instanceof ee)return Ht;if(t instanceof ne)return Gt;if(t instanceof ie)return Zt;if(Array.isArray(t)){for(var e,r=t.length,n=0,i=t;n<i.length;n+=1){var o=se(i[n]);if(e){if(e===o)continue;e=qt;break}e=o}return Wt(e||qt,r)}return Vt}function le(t){var e=typeof t;return null===t?"":"string"===e||"number"===e||"boolean"===e?String(t):t instanceof te||t instanceof ne||t instanceof ie?t.toString():JSON.stringify(t)}ie.prototype.toString=function(){return this.name},ie.fromString=function(t){return t?new ie({name:t,available:!1}):null},ie.prototype.serialize=function(){return["image",this.name]};var ue=function(t,e){this.type=t,this.value=e};ue.parse=function(t,e){if(2!==t.length)return e.error("'literal' expression requires exactly one argument, but found "+(t.length-1)+" instead.");if(!ae(t[1]))return e.error("invalid value");var r=t[1],n=se(r),i=e.expectedType;return"array"!==n.kind||0!==n.N||!i||"array"!==i.kind||"number"==typeof i.N&&0!==i.N||(n=i),new ue(n,r)},ue.prototype.evaluate=function(){return this.value},ue.prototype.eachChild=function(){},ue.prototype.outputDefined=function(){return!0},ue.prototype.serialize=function(){return"array"===this.type.kind||"object"===this.type.kind?["literal",this.value]:this.value instanceof te?["rgba"].concat(this.value.toArray()):this.value instanceof ne?this.value.serialize():this.value};var ce=function(t){this.name="ExpressionEvaluationError",this.message=t};ce.prototype.toJSON=function(){return this.message};var pe={string:Nt,number:zt,boolean:jt,object:Vt},he=function(t,e){this.type=t,this.args=e};he.parse=function(t,e){if(t.length<2)return e.error("Expected at least one argument.");var r,n=1,i=t[0];if("array"===i){var o,a;if(t.length>2){var s=t[1];if("string"!=typeof s||!(s in pe)||"object"===s)return e.error('The item type argument of "array" must be one of string, number, boolean',1);o=pe[s],n++}else o=qt;if(t.length>3){if(null!==t[2]&&("number"!=typeof t[2]||t[2]<0||t[2]!==Math.floor(t[2])))return e.error('The length argument to "array" must be a positive integer literal',2);a=t[2],n++}r=Wt(o,a)}else r=pe[i];for(var l=[];n<t.length;n++){var u=e.parse(t[n],n,qt);if(!u)return null;l.push(u)}return new he(r,l)},he.prototype.evaluate=function(t){for(var e=0;e<this.args.length;e++){var r=this.args[e].evaluate(t);if(!Kt(this.type,se(r)))return r;if(e===this.args.length-1)throw new ce("Expected value to be of type "+Yt(this.type)+", but found "+Yt(se(r))+" instead.")}return null},he.prototype.eachChild=function(t){this.args.forEach(t)},he.prototype.outputDefined=function(){return this.args.every((function(t){return t.outputDefined()}))},he.prototype.serialize=function(){var t=this.type,e=[t.kind];if("array"===t.kind){var r=t.itemType;if("string"===r.kind||"number"===r.kind||"boolean"===r.kind){e.push(r.kind);var n=t.N;("number"==typeof n||this.args.length>1)&&e.push(n)}}return e.concat(this.args.map((function(t){return t.serialize()})))};var fe=function(t){this.type=Gt,this.sections=t};fe.parse=function(t,e){if(t.length<2)return e.error("Expected at least one argument.");var r=t[1];if(!Array.isArray(r)&&"object"==typeof r)return e.error("First argument must be an image or text section.");for(var n=[],i=!1,o=1;o<=t.length-1;++o){var a=t[o];if(i&&"object"==typeof a&&!Array.isArray(a)){i=!1;var s=null;if(a["font-scale"]&&!(s=e.parse(a["font-scale"],1,zt)))return null;var l=null;if(a["text-font"]&&!(l=e.parse(a["text-font"],1,Wt(Nt))))return null;var u=null;if(a["text-color"]&&!(u=e.parse(a["text-color"],1,Ut)))return null;var c=n[n.length-1];c.scale=s,c.font=l,c.textColor=u}else{var p=e.parse(t[o],1,qt);if(!p)return null;var h=p.type.kind;if("string"!==h&&"value"!==h&&"null"!==h&&"resolvedImage"!==h)return e.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");i=!0,n.push({content:p,scale:null,font:null,textColor:null})}}return new fe(n)},fe.prototype.evaluate=function(t){return new ne(this.sections.map((function(e){var r=e.content.evaluate(t);return se(r)===Zt?new re("",r,null,null,null):new re(le(r),null,e.scale?e.scale.evaluate(t):null,e.font?e.font.evaluate(t).join(","):null,e.textColor?e.textColor.evaluate(t):null)})))},fe.prototype.eachChild=function(t){for(var e=0,r=this.sections;e<r.length;e+=1){var n=r[e];t(n.content),n.scale&&t(n.scale),n.font&&t(n.font),n.textColor&&t(n.textColor)}},fe.prototype.outputDefined=function(){return!1},fe.prototype.serialize=function(){for(var t=["format"],e=0,r=this.sections;e<r.length;e+=1){var n=r[e];t.push(n.content.serialize());var i={};n.scale&&(i["font-scale"]=n.scale.serialize()),n.font&&(i["text-font"]=n.font.serialize()),n.textColor&&(i["text-color"]=n.textColor.serialize()),t.push(i)}return t};var de=function(t){this.type=Zt,this.input=t};de.parse=function(t,e){if(2!==t.length)return e.error("Expected two arguments.");var r=e.parse(t[1],1,Nt);return r?new de(r):e.error("No image name provided.")},de.prototype.evaluate=function(t){var e=this.input.evaluate(t),r=ie.fromString(e);return r&&t.availableImages&&(r.available=t.availableImages.indexOf(e)>-1),r},de.prototype.eachChild=function(t){t(this.input)},de.prototype.outputDefined=function(){return!1},de.prototype.serialize=function(){return["image",this.input.serialize()]};var me={"to-boolean":jt,"to-color":Ut,"to-number":zt,"to-string":Nt},ge=function(t,e){this.type=t,this.args=e};ge.parse=function(t,e){if(t.length<2)return e.error("Expected at least one argument.");var r=t[0];if(("to-boolean"===r||"to-string"===r)&&2!==t.length)return e.error("Expected one argument.");for(var n=me[r],i=[],o=1;o<t.length;o++){var a=e.parse(t[o],o,qt);if(!a)return null;i.push(a)}return new ge(n,i)},ge.prototype.evaluate=function(t){if("boolean"===this.type.kind)return Boolean(this.args[0].evaluate(t));if("color"===this.type.kind){for(var e,r,n=0,i=this.args;n<i.length;n+=1){if(r=null,(e=i[n].evaluate(t))instanceof te)return e;if("string"==typeof e){var o=t.parseColor(e);if(o)return o}else if(Array.isArray(e)&&!(r=e.length<3||e.length>4?"Invalid rbga value "+JSON.stringify(e)+": expected an array containing either three or four numeric values.":oe(e[0],e[1],e[2],e[3])))return new te(e[0]/255,e[1]/255,e[2]/255,e[3])}throw new ce(r||"Could not parse color from value '"+("string"==typeof e?e:String(JSON.stringify(e)))+"'")}if("number"===this.type.kind){for(var a=null,s=0,l=this.args;s<l.length;s+=1){if(null===(a=l[s].evaluate(t)))return 0;var u=Number(a);if(!isNaN(u))return u}throw new ce("Could not convert "+JSON.stringify(a)+" to number.")}return"formatted"===this.type.kind?ne.fromString(le(this.args[0].evaluate(t))):"resolvedImage"===this.type.kind?ie.fromString(le(this.args[0].evaluate(t))):le(this.args[0].evaluate(t))},ge.prototype.eachChild=function(t){this.args.forEach(t)},ge.prototype.outputDefined=function(){return this.args.every((function(t){return t.outputDefined()}))},ge.prototype.serialize=function(){if("formatted"===this.type.kind)return new fe([{content:this.args[0],scale:null,font:null,textColor:null}]).serialize();if("resolvedImage"===this.type.kind)return new de(this.args[0]).serialize();var t=["to-"+this.type.kind];return this.eachChild((function(e){t.push(e.serialize())})),t};var ye=["Unknown","Point","LineString","Polygon"],ve=function(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache={},this.availableImages=null,this.canonical=null};ve.prototype.id=function(){return this.feature&&"id"in this.feature?this.feature.id:null},ve.prototype.geometryType=function(){return this.feature?"number"==typeof this.feature.type?ye[this.feature.type]:this.feature.type:null},ve.prototype.geometry=function(){return this.feature&&"geometry"in this.feature?this.feature.geometry:null},ve.prototype.canonicalID=function(){return this.canonical},ve.prototype.properties=function(){return this.feature&&this.feature.properties||{}},ve.prototype.parseColor=function(t){var e=this._parseColorCache[t];return e||(e=this._parseColorCache[t]=te.parse(t)),e};var _e=function(t,e,r,n){this.name=t,this.type=e,this._evaluate=r,this.args=n};_e.prototype.evaluate=function(t){return this._evaluate(t,this.args)},_e.prototype.eachChild=function(t){this.args.forEach(t)},_e.prototype.outputDefined=function(){return!1},_e.prototype.serialize=function(){return[this.name].concat(this.args.map((function(t){return t.serialize()})))},_e.parse=function(t,e){var r,n=t[0],i=_e.definitions[n];if(!i)return e.error('Unknown expression "'+n+'". If you wanted a literal array, use ["literal", [...]].',0);for(var o=Array.isArray(i)?i[0]:i.type,a=Array.isArray(i)?[[i[1],i[2]]]:i.overloads,s=a.filter((function(e){var r=e[0];return!Array.isArray(r)||r.length===t.length-1})),l=null,u=0,c=s;u<c.length;u+=1){var p=c[u],h=p[0],f=p[1];l=new Ue(e.registry,e.path,null,e.scope);for(var d=[],m=!1,g=1;g<t.length;g++){var y=t[g],v=Array.isArray(h)?h[g-1]:h.type,_=l.parse(y,1+d.length,v);if(!_){m=!0;break}d.push(_)}if(!m)if(Array.isArray(h)&&h.length!==d.length)l.error("Expected "+h.length+" arguments, but found "+d.length+" instead.");else{for(var b=0;b<d.length;b++){var x=Array.isArray(h)?h[b]:h.type,w=d[b];l.concat(b+1).checkSubtype(x,w.type)}if(0===l.errors.length)return new _e(n,o,f,d)}}if(1===s.length)(r=e.errors).push.apply(r,l.errors);else{for(var E=(s.length?s:a).map((function(t){var e;return e=t[0],Array.isArray(e)?"("+e.map(Yt).join(", ")+")":"("+Yt(e.type)+"...)"})).join(" | "),T=[],A=1;A<t.length;A++){var C=e.parse(t[A],1+T.length);if(!C)return null;T.push(Yt(C.type))}e.error("Expected arguments of type "+E+", but found ("+T.join(", ")+") instead.")}return null},_e.register=function(t,e){for(var r in _e.definitions=e,e)t[r]=_e};var be=function(t,e,r){this.type=Ht,this.locale=r,this.caseSensitive=t,this.diacriticSensitive=e};function xe(t,e){t[0]=Math.min(t[0],e[0]),t[1]=Math.min(t[1],e[1]),t[2]=Math.max(t[2],e[0]),t[3]=Math.max(t[3],e[1])}function we(t,e){return!(t[0]<=e[0]||t[2]>=e[2]||t[1]<=e[1]||t[3]>=e[3])}function Ee(t,e){var r=(180+t[0])/360,n=(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+t[1]*Math.PI/360)))/360,i=Math.pow(2,e.z);return[Math.round(r*i*8192),Math.round(n*i*8192)]}function Te(t,e,r){return e[1]>t[1]!=r[1]>t[1]&&t[0]<(r[0]-e[0])*(t[1]-e[1])/(r[1]-e[1])+e[0]}function Ae(t,e){for(var r,n,i,o,a,s,l,u=!1,c=0,p=e.length;c<p;c++)for(var h=e[c],f=0,d=h.length;f<d-1;f++){if((o=(r=t)[0]-(n=h[f])[0])*(l=r[1]-(i=h[f+1])[1])-(s=r[0]-i[0])*(a=r[1]-n[1])==0&&o*s<=0&&a*l<=0)return!1;Te(t,h[f],h[f+1])&&(u=!u)}return u}function Ce(t,e){for(var r=0;r<e.length;r++)if(Ae(t,e[r]))return!0;return!1}function Se(t,e,r,n){var i=n[0]-r[0],o=n[1]-r[1],a=(t[0]-r[0])*o-i*(t[1]-r[1]),s=(e[0]-r[0])*o-i*(e[1]-r[1]);return a>0&&s<0||a<0&&s>0}function Pe(t,e,r){for(var n=0,i=r;n<i.length;n+=1)for(var o=i[n],a=0;a<o.length-1;++a)if(0!=(p=[(c=o[a+1])[0]-(u=o[a])[0],c[1]-u[1]])[0]*(h=[(l=e)[0]-(s=t)[0],l[1]-s[1]])[1]-p[1]*h[0]&&Se(s,l,u,c)&&Se(u,c,s,l))return!0;var s,l,u,c,p,h;return!1}function Ie(t,e){for(var r=0;r<t.length;++r)if(!Ae(t[r],e))return!1;for(var n=0;n<t.length-1;++n)if(Pe(t[n],t[n+1],e))return!1;return!0}function De(t,e){for(var r=0;r<e.length;r++)if(Ie(t,e[r]))return!0;return!1}function Oe(t,e,r){for(var n=[],i=0;i<t.length;i++){for(var o=[],a=0;a<t[i].length;a++){var s=Ee(t[i][a],r);xe(e,s),o.push(s)}n.push(o)}return n}function Me(t,e,r){for(var n=[],i=0;i<t.length;i++){var o=Oe(t[i],e,r);n.push(o)}return n}function Be(t,e,r,n){if(t[0]<r[0]||t[0]>r[2]){var i=.5*n,o=t[0]-r[0]>i?-n:r[0]-t[0]>i?n:0;0===o&&(o=t[0]-r[2]>i?-n:r[2]-t[0]>i?n:0),t[0]+=o}xe(e,t)}function ke(t,e,r,n){for(var i=8192*Math.pow(2,n.z),o=[8192*n.x,8192*n.y],a=[],s=0,l=t;s<l.length;s+=1)for(var u=0,c=l[s];u<c.length;u+=1){var p=c[u],h=[p.x+o[0],p.y+o[1]];Be(h,e,r,i),a.push(h)}return a}function Fe(t,e,r,n){for(var i,o=8192*Math.pow(2,n.z),a=[8192*n.x,8192*n.y],s=[],l=0,u=t;l<u.length;l+=1){for(var c=[],p=0,h=u[l];p<h.length;p+=1){var f=h[p],d=[f.x+a[0],f.y+a[1]];xe(e,d),c.push(d)}s.push(c)}if(e[2]-e[0]<=o/2){(i=e)[0]=i[1]=1/0,i[2]=i[3]=-1/0;for(var m=0,g=s;m<g.length;m+=1)for(var y=0,v=g[m];y<v.length;y+=1)Be(v[y],e,r,o)}return s}be.parse=function(t,e){if(2!==t.length)return e.error("Expected one argument.");var r=t[1];if("object"!=typeof r||Array.isArray(r))return e.error("Collator options argument must be an object.");var n=e.parse(void 0!==r["case-sensitive"]&&r["case-sensitive"],1,jt);if(!n)return null;var i=e.parse(void 0!==r["diacritic-sensitive"]&&r["diacritic-sensitive"],1,jt);if(!i)return null;var o=null;return r.locale&&!(o=e.parse(r.locale,1,Nt))?null:new be(n,i,o)},be.prototype.evaluate=function(t){return new ee(this.caseSensitive.evaluate(t),this.diacriticSensitive.evaluate(t),this.locale?this.locale.evaluate(t):null)},be.prototype.eachChild=function(t){t(this.caseSensitive),t(this.diacriticSensitive),this.locale&&t(this.locale)},be.prototype.outputDefined=function(){return!1},be.prototype.serialize=function(){var t={};return t["case-sensitive"]=this.caseSensitive.serialize(),t["diacritic-sensitive"]=this.diacriticSensitive.serialize(),this.locale&&(t.locale=this.locale.serialize()),["collator",t]};var Le=function(t,e){this.type=jt,this.geojson=t,this.geometries=e};function Re(t){if(t instanceof _e){if("get"===t.name&&1===t.args.length)return!1;if("feature-state"===t.name)return!1;if("has"===t.name&&1===t.args.length)return!1;if("properties"===t.name||"geometry-type"===t.name||"id"===t.name)return!1;if(/^filter-/.test(t.name))return!1}if(t instanceof Le)return!1;var e=!0;return t.eachChild((function(t){e&&!Re(t)&&(e=!1)})),e}function ze(t){if(t instanceof _e&&"feature-state"===t.name)return!1;var e=!0;return t.eachChild((function(t){e&&!ze(t)&&(e=!1)})),e}function Ne(t,e){if(t instanceof _e&&e.indexOf(t.name)>=0)return!1;var r=!0;return t.eachChild((function(t){r&&!Ne(t,e)&&(r=!1)})),r}Le.parse=function(t,e){if(2!==t.length)return e.error("'within' expression requires exactly one argument, but found "+(t.length-1)+" instead.");if(ae(t[1])){var r=t[1];if("FeatureCollection"===r.type)for(var n=0;n<r.features.length;++n){var i=r.features[n].geometry.type;if("Polygon"===i||"MultiPolygon"===i)return new Le(r,r.features[n].geometry)}else if("Feature"===r.type){var o=r.geometry.type;if("Polygon"===o||"MultiPolygon"===o)return new Le(r,r.geometry)}else if("Polygon"===r.type||"MultiPolygon"===r.type)return new Le(r,r)}return e.error("'within' expression requires valid geojson object that contains polygon geometry type.")},Le.prototype.evaluate=function(t){if(null!=t.geometry()&&null!=t.canonicalID()){if("Point"===t.geometryType())return function(t,e){var r=[1/0,1/0,-1/0,-1/0],n=[1/0,1/0,-1/0,-1/0],i=t.canonicalID();if("Polygon"===e.type){var o=Oe(e.coordinates,n,i),a=ke(t.geometry(),r,n,i);if(!we(r,n))return!1;for(var s=0,l=a;s<l.length;s+=1)if(!Ae(l[s],o))return!1}if("MultiPolygon"===e.type){var u=Me(e.coordinates,n,i),c=ke(t.geometry(),r,n,i);if(!we(r,n))return!1;for(var p=0,h=c;p<h.length;p+=1)if(!Ce(h[p],u))return!1}return!0}(t,this.geometries);if("LineString"===t.geometryType())return function(t,e){var r=[1/0,1/0,-1/0,-1/0],n=[1/0,1/0,-1/0,-1/0],i=t.canonicalID();if("Polygon"===e.type){var o=Oe(e.coordinates,n,i),a=Fe(t.geometry(),r,n,i);if(!we(r,n))return!1;for(var s=0,l=a;s<l.length;s+=1)if(!Ie(l[s],o))return!1}if("MultiPolygon"===e.type){var u=Me(e.coordinates,n,i),c=Fe(t.geometry(),r,n,i);if(!we(r,n))return!1;for(var p=0,h=c;p<h.length;p+=1)if(!De(h[p],u))return!1}return!0}(t,this.geometries)}return!1},Le.prototype.eachChild=function(){},Le.prototype.outputDefined=function(){return!0},Le.prototype.serialize=function(){return["within",this.geojson]};var je=function(t,e){this.type=e.type,this.name=t,this.boundExpression=e};je.parse=function(t,e){if(2!==t.length||"string"!=typeof t[1])return e.error("'var' expression requires exactly one string literal argument.");var r=t[1];return e.scope.has(r)?new je(r,e.scope.get(r)):e.error('Unknown variable "'+r+'". Make sure "'+r+'" has been bound in an enclosing "let" expression before using it.',1)},je.prototype.evaluate=function(t){return this.boundExpression.evaluate(t)},je.prototype.eachChild=function(){},je.prototype.outputDefined=function(){return!1},je.prototype.serialize=function(){return["var",this.name]};var Ue=function(t,e,r,n,i){void 0===e&&(e=[]),void 0===n&&(n=new Lt),void 0===i&&(i=[]),this.registry=t,this.path=e,this.key=e.map((function(t){return"["+t+"]"})).join(""),this.scope=n,this.errors=i,this.expectedType=r};function Ve(t,e){for(var r,n=t.length-1,i=0,o=n,a=0;i<=o;)if((r=t[a=Math.floor((i+o)/2)])<=e){if(a===n||e<t[a+1])return a;i=a+1}else{if(!(r>e))throw new ce("Input is not a number.");o=a-1}return 0}Ue.prototype.parse=function(t,e,r,n,i){return void 0===i&&(i={}),e?this.concat(e,r,n)._parse(t,i):this._parse(t,i)},Ue.prototype._parse=function(t,e){function r(t,e,r){return"assert"===r?new he(e,[t]):"coerce"===r?new ge(e,[t]):t}if(null!==t&&"string"!=typeof t&&"boolean"!=typeof t&&"number"!=typeof t||(t=["literal",t]),Array.isArray(t)){if(0===t.length)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');var n=t[0];if("string"!=typeof n)return this.error("Expression name must be a string, but found "+typeof n+' instead. If you wanted a literal array, use ["literal", [...]].',0),null;var i=this.registry[n];if(i){var o=i.parse(t,this);if(!o)return null;if(this.expectedType){var a=this.expectedType,s=o.type;if("string"!==a.kind&&"number"!==a.kind&&"boolean"!==a.kind&&"object"!==a.kind&&"array"!==a.kind||"value"!==s.kind)if("color"!==a.kind&&"formatted"!==a.kind&&"resolvedImage"!==a.kind||"value"!==s.kind&&"string"!==s.kind){if(this.checkSubtype(a,s))return null}else o=r(o,a,e.typeAnnotation||"coerce");else o=r(o,a,e.typeAnnotation||"assert")}if(!(o instanceof ue)&&"resolvedImage"!==o.type.kind&&function t(e){if(e instanceof je)return t(e.boundExpression);if(e instanceof _e&&"error"===e.name)return!1;if(e instanceof be)return!1;if(e instanceof Le)return!1;var r=e instanceof ge||e instanceof he,n=!0;return e.eachChild((function(e){n=r?n&&t(e):n&&e instanceof ue})),!!n&&Re(e)&&Ne(e,["zoom","heatmap-density","line-progress","accumulated","is-supported-script"])}(o)){var l=new ve;try{o=new ue(o.type,o.evaluate(l))}catch(t){return this.error(t.message),null}}return o}return this.error('Unknown expression "'+n+'". If you wanted a literal array, use ["literal", [...]].',0)}return this.error(void 0===t?"'undefined' value invalid. Use null instead.":"object"==typeof t?'Bare objects invalid. Use ["literal", {...}] instead.':"Expected an array, but found "+typeof t+" instead.")},Ue.prototype.concat=function(t,e,r){var n="number"==typeof t?this.path.concat(t):this.path,i=r?this.scope.concat(r):this.scope;return new Ue(this.registry,n,e||null,i,this.errors)},Ue.prototype.error=function(t){for(var e=[],r=arguments.length-1;r-- >0;)e[r]=arguments[r+1];var n=""+this.key+e.map((function(t){return"["+t+"]"})).join("");this.errors.push(new Ft(n,t))},Ue.prototype.checkSubtype=function(t,e){var r=Kt(t,e);return r&&this.error(r),r};var qe=function(t,e,r){this.type=t,this.input=e,this.labels=[],this.outputs=[];for(var n=0,i=r;n<i.length;n+=1){var o=i[n],a=o[1];this.labels.push(o[0]),this.outputs.push(a)}};function He(t,e,r){return t*(1-r)+e*r}qe.parse=function(t,e){if(t.length-1<4)return e.error("Expected at least 4 arguments, but found only "+(t.length-1)+".");if((t.length-1)%2!=0)return e.error("Expected an even number of arguments.");var r=e.parse(t[1],1,zt);if(!r)return null;var n=[],i=null;e.expectedType&&"value"!==e.expectedType.kind&&(i=e.expectedType);for(var o=1;o<t.length;o+=2){var a=1===o?-1/0:t[o],s=t[o+1],l=o,u=o+1;if("number"!=typeof a)return e.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',l);if(n.length&&n[n.length-1][0]>=a)return e.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',l);var c=e.parse(s,u,i);if(!c)return null;i=i||c.type,n.push([a,c])}return new qe(i,r,n)},qe.prototype.evaluate=function(t){var e=this.labels,r=this.outputs;if(1===e.length)return r[0].evaluate(t);var n=this.input.evaluate(t);if(n<=e[0])return r[0].evaluate(t);var i=e.length;return n>=e[i-1]?r[i-1].evaluate(t):r[Ve(e,n)].evaluate(t)},qe.prototype.eachChild=function(t){t(this.input);for(var e=0,r=this.outputs;e<r.length;e+=1)t(r[e])},qe.prototype.outputDefined=function(){return this.outputs.every((function(t){return t.outputDefined()}))},qe.prototype.serialize=function(){for(var t=["step",this.input.serialize()],e=0;e<this.labels.length;e++)e>0&&t.push(this.labels[e]),t.push(this.outputs[e].serialize());return t};var Ge=Object.freeze({__proto__:null,number:He,color:function(t,e,r){return new te(He(t.r,e.r,r),He(t.g,e.g,r),He(t.b,e.b,r),He(t.a,e.a,r))},array:function(t,e,r){return t.map((function(t,n){return He(t,e[n],r)}))}}),Ze=6/29*3*(6/29),We=Math.PI/180,Ye=180/Math.PI;function Xe(t){return t>.008856451679035631?Math.pow(t,1/3):t/Ze+4/29}function Ke(t){return t>6/29?t*t*t:Ze*(t-4/29)}function Je(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Qe(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function $e(t){var e=Qe(t.r),r=Qe(t.g),n=Qe(t.b),i=Xe((.4124564*e+.3575761*r+.1804375*n)/.95047),o=Xe((.2126729*e+.7151522*r+.072175*n)/1);return{l:116*o-16,a:500*(i-o),b:200*(o-Xe((.0193339*e+.119192*r+.9503041*n)/1.08883)),alpha:t.a}}function tr(t){var e=(t.l+16)/116,r=isNaN(t.a)?e:e+t.a/500,n=isNaN(t.b)?e:e-t.b/200;return e=1*Ke(e),r=.95047*Ke(r),n=1.08883*Ke(n),new te(Je(3.2404542*r-1.5371385*e-.4985314*n),Je(-.969266*r+1.8760108*e+.041556*n),Je(.0556434*r-.2040259*e+1.0572252*n),t.alpha)}function er(t,e,r){var n=e-t;return t+r*(n>180||n<-180?n-360*Math.round(n/360):n)}var rr={forward:$e,reverse:tr,interpolate:function(t,e,r){return{l:He(t.l,e.l,r),a:He(t.a,e.a,r),b:He(t.b,e.b,r),alpha:He(t.alpha,e.alpha,r)}}},nr={forward:function(t){var e=$e(t),r=e.l,n=e.a,i=e.b,o=Math.atan2(i,n)*Ye;return{h:o<0?o+360:o,c:Math.sqrt(n*n+i*i),l:r,alpha:t.a}},reverse:function(t){var e=t.h*We,r=t.c;return tr({l:t.l,a:Math.cos(e)*r,b:Math.sin(e)*r,alpha:t.alpha})},interpolate:function(t,e,r){return{h:er(t.h,e.h,r),c:He(t.c,e.c,r),l:He(t.l,e.l,r),alpha:He(t.alpha,e.alpha,r)}}},ir=Object.freeze({__proto__:null,lab:rr,hcl:nr}),or=function(t,e,r,n,i){this.type=t,this.operator=e,this.interpolation=r,this.input=n,this.labels=[],this.outputs=[];for(var o=0,a=i;o<a.length;o+=1){var s=a[o],l=s[1];this.labels.push(s[0]),this.outputs.push(l)}};function ar(t,e,r,n){var i=n-r,o=t-r;return 0===i?0:1===e?o/i:(Math.pow(e,o)-1)/(Math.pow(e,i)-1)}or.interpolationFactor=function(t,e,n,i){var o=0;if("exponential"===t.name)o=ar(e,t.base,n,i);else if("linear"===t.name)o=ar(e,1,n,i);else if("cubic-bezier"===t.name){var a=t.controlPoints;o=new r(a[0],a[1],a[2],a[3]).solve(ar(e,1,n,i))}return o},or.parse=function(t,e){var r=t[0],n=t[1],i=t[2],o=t.slice(3);if(!Array.isArray(n)||0===n.length)return e.error("Expected an interpolation type expression.",1);if("linear"===n[0])n={name:"linear"};else if("exponential"===n[0]){var a=n[1];if("number"!=typeof a)return e.error("Exponential interpolation requires a numeric base.",1,1);n={name:"exponential",base:a}}else{if("cubic-bezier"!==n[0])return e.error("Unknown interpolation type "+String(n[0]),1,0);var s=n.slice(1);if(4!==s.length||s.some((function(t){return"number"!=typeof t||t<0||t>1})))return e.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);n={name:"cubic-bezier",controlPoints:s}}if(t.length-1<4)return e.error("Expected at least 4 arguments, but found only "+(t.length-1)+".");if((t.length-1)%2!=0)return e.error("Expected an even number of arguments.");if(!(i=e.parse(i,2,zt)))return null;var l=[],u=null;"interpolate-hcl"===r||"interpolate-lab"===r?u=Ut:e.expectedType&&"value"!==e.expectedType.kind&&(u=e.expectedType);for(var c=0;c<o.length;c+=2){var p=o[c],h=o[c+1],f=c+3,d=c+4;if("number"!=typeof p)return e.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',f);if(l.length&&l[l.length-1][0]>=p)return e.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',f);var m=e.parse(h,d,u);if(!m)return null;u=u||m.type,l.push([p,m])}return"number"===u.kind||"color"===u.kind||"array"===u.kind&&"number"===u.itemType.kind&&"number"==typeof u.N?new or(u,r,n,i,l):e.error("Type "+Yt(u)+" is not interpolatable.")},or.prototype.evaluate=function(t){var e=this.labels,r=this.outputs;if(1===e.length)return r[0].evaluate(t);var n=this.input.evaluate(t);if(n<=e[0])return r[0].evaluate(t);var i=e.length;if(n>=e[i-1])return r[i-1].evaluate(t);var o=Ve(e,n),a=or.interpolationFactor(this.interpolation,n,e[o],e[o+1]),s=r[o].evaluate(t),l=r[o+1].evaluate(t);return"interpolate"===this.operator?Ge[this.type.kind.toLowerCase()](s,l,a):"interpolate-hcl"===this.operator?nr.reverse(nr.interpolate(nr.forward(s),nr.forward(l),a)):rr.reverse(rr.interpolate(rr.forward(s),rr.forward(l),a))},or.prototype.eachChild=function(t){t(this.input);for(var e=0,r=this.outputs;e<r.length;e+=1)t(r[e])},or.prototype.outputDefined=function(){return this.outputs.every((function(t){return t.outputDefined()}))},or.prototype.serialize=function(){var t;t="linear"===this.interpolation.name?["linear"]:"exponential"===this.interpolation.name?1===this.interpolation.base?["linear"]:["exponential",this.interpolation.base]:["cubic-bezier"].concat(this.interpolation.controlPoints);for(var e=[this.operator,t,this.input.serialize()],r=0;r<this.labels.length;r++)e.push(this.labels[r],this.outputs[r].serialize());return e};var sr=function(t,e){this.type=t,this.args=e};sr.parse=function(t,e){if(t.length<2)return e.error("Expectected at least one argument.");var r=null,n=e.expectedType;n&&"value"!==n.kind&&(r=n);for(var i=[],o=0,a=t.slice(1);o<a.length;o+=1){var s=e.parse(a[o],1+i.length,r,void 0,{typeAnnotation:"omit"});if(!s)return null;r=r||s.type,i.push(s)}var l=n&&i.some((function(t){return Kt(n,t.type)}));return new sr(l?qt:r,i)},sr.prototype.evaluate=function(t){for(var e,r=null,n=0,i=0,o=this.args;i<o.length&&(n++,(r=o[i].evaluate(t))&&r instanceof ie&&!r.available&&(e||(e=r.name),r=null,n===this.args.length&&(r=e)),null===r);i+=1);return r},sr.prototype.eachChild=function(t){this.args.forEach(t)},sr.prototype.outputDefined=function(){return this.args.every((function(t){return t.outputDefined()}))},sr.prototype.serialize=function(){var t=["coalesce"];return this.eachChild((function(e){t.push(e.serialize())})),t};var lr=function(t,e){this.type=e.type,this.bindings=[].concat(t),this.result=e};lr.prototype.evaluate=function(t){return this.result.evaluate(t)},lr.prototype.eachChild=function(t){for(var e=0,r=this.bindings;e<r.length;e+=1)t(r[e][1]);t(this.result)},lr.parse=function(t,e){if(t.length<4)return e.error("Expected at least 3 arguments, but found "+(t.length-1)+" instead.");for(var r=[],n=1;n<t.length-1;n+=2){var i=t[n];if("string"!=typeof i)return e.error("Expected string, but found "+typeof i+" instead.",n);if(/[^a-zA-Z0-9_]/.test(i))return e.error("Variable names must contain only alphanumeric characters or '_'.",n);var o=e.parse(t[n+1],n+1);if(!o)return null;r.push([i,o])}var a=e.parse(t[t.length-1],t.length-1,e.expectedType,r);return a?new lr(r,a):null},lr.prototype.outputDefined=function(){return this.result.outputDefined()},lr.prototype.serialize=function(){for(var t=["let"],e=0,r=this.bindings;e<r.length;e+=1){var n=r[e];t.push(n[0],n[1].serialize())}return t.push(this.result.serialize()),t};var ur=function(t,e,r){this.type=t,this.index=e,this.input=r};ur.parse=function(t,e){if(3!==t.length)return e.error("Expected 2 arguments, but found "+(t.length-1)+" instead.");var r=e.parse(t[1],1,zt),n=e.parse(t[2],2,Wt(e.expectedType||qt));return r&&n?new ur(n.type.itemType,r,n):null},ur.prototype.evaluate=function(t){var e=this.index.evaluate(t),r=this.input.evaluate(t);if(e<0)throw new ce("Array index out of bounds: "+e+" < 0.");if(e>=r.length)throw new ce("Array index out of bounds: "+e+" > "+(r.length-1)+".");if(e!==Math.floor(e))throw new ce("Array index must be an integer, but found "+e+" instead.");return r[e]},ur.prototype.eachChild=function(t){t(this.index),t(this.input)},ur.prototype.outputDefined=function(){return!1},ur.prototype.serialize=function(){return["at",this.index.serialize(),this.input.serialize()]};var cr=function(t,e){this.type=jt,this.needle=t,this.haystack=e};cr.parse=function(t,e){if(3!==t.length)return e.error("Expected 2 arguments, but found "+(t.length-1)+" instead.");var r=e.parse(t[1],1,qt),n=e.parse(t[2],2,qt);return r&&n?Jt(r.type,[jt,Nt,zt,Rt,qt])?new cr(r,n):e.error("Expected first argument to be of type boolean, string, number or null, but found "+Yt(r.type)+" instead"):null},cr.prototype.evaluate=function(t){var e=this.needle.evaluate(t),r=this.haystack.evaluate(t);if(!r)return!1;if(!Qt(e,["boolean","string","number","null"]))throw new ce("Expected first argument to be of type boolean, string, number or null, but found "+Yt(se(e))+" instead.");if(!Qt(r,["string","array"]))throw new ce("Expected second argument to be of type array or string, but found "+Yt(se(r))+" instead.");return r.indexOf(e)>=0},cr.prototype.eachChild=function(t){t(this.needle),t(this.haystack)},cr.prototype.outputDefined=function(){return!0},cr.prototype.serialize=function(){return["in",this.needle.serialize(),this.haystack.serialize()]};var pr=function(t,e,r){this.type=zt,this.needle=t,this.haystack=e,this.fromIndex=r};pr.parse=function(t,e){if(t.length<=2||t.length>=5)return e.error("Expected 3 or 4 arguments, but found "+(t.length-1)+" instead.");var r=e.parse(t[1],1,qt),n=e.parse(t[2],2,qt);if(!r||!n)return null;if(!Jt(r.type,[jt,Nt,zt,Rt,qt]))return e.error("Expected first argument to be of type boolean, string, number or null, but found "+Yt(r.type)+" instead");if(4===t.length){var i=e.parse(t[3],3,zt);return i?new pr(r,n,i):null}return new pr(r,n)},pr.prototype.evaluate=function(t){var e=this.needle.evaluate(t),r=this.haystack.evaluate(t);if(!Qt(e,["boolean","string","number","null"]))throw new ce("Expected first argument to be of type boolean, string, number or null, but found "+Yt(se(e))+" instead.");if(!Qt(r,["string","array"]))throw new ce("Expected second argument to be of type array or string, but found "+Yt(se(r))+" instead.");if(this.fromIndex){var n=this.fromIndex.evaluate(t);return r.indexOf(e,n)}return r.indexOf(e)},pr.prototype.eachChild=function(t){t(this.needle),t(this.haystack),this.fromIndex&&t(this.fromIndex)},pr.prototype.outputDefined=function(){return!1},pr.prototype.serialize=function(){if(null!=this.fromIndex&&void 0!==this.fromIndex){var t=this.fromIndex.serialize();return["index-of",this.needle.serialize(),this.haystack.serialize(),t]}return["index-of",this.needle.serialize(),this.haystack.serialize()]};var hr=function(t,e,r,n,i,o){this.inputType=t,this.type=e,this.input=r,this.cases=n,this.outputs=i,this.otherwise=o};hr.parse=function(t,e){if(t.length<5)return e.error("Expected at least 4 arguments, but found only "+(t.length-1)+".");if(t.length%2!=1)return e.error("Expected an even number of arguments.");var r,n;e.expectedType&&"value"!==e.expectedType.kind&&(n=e.expectedType);for(var i={},o=[],a=2;a<t.length-1;a+=2){var s=t[a],l=t[a+1];Array.isArray(s)||(s=[s]);var u=e.concat(a);if(0===s.length)return u.error("Expected at least one branch label.");for(var c=0,p=s;c<p.length;c+=1){var h=p[c];if("number"!=typeof h&&"string"!=typeof h)return u.error("Branch labels must be numbers or strings.");if("number"==typeof h&&Math.abs(h)>Number.MAX_SAFE_INTEGER)return u.error("Branch labels must be integers no larger than "+Number.MAX_SAFE_INTEGER+".");if("number"==typeof h&&Math.floor(h)!==h)return u.error("Numeric branch labels must be integer values.");if(r){if(u.checkSubtype(r,se(h)))return null}else r=se(h);if(void 0!==i[String(h)])return u.error("Branch labels must be unique.");i[String(h)]=o.length}var f=e.parse(l,a,n);if(!f)return null;n=n||f.type,o.push(f)}var d=e.parse(t[1],1,qt);if(!d)return null;var m=e.parse(t[t.length-1],t.length-1,n);return m?"value"!==d.type.kind&&e.concat(1).checkSubtype(r,d.type)?null:new hr(r,n,d,i,o,m):null},hr.prototype.evaluate=function(t){var e=this.input.evaluate(t);return(se(e)===this.inputType&&this.outputs[this.cases[e]]||this.otherwise).evaluate(t)},hr.prototype.eachChild=function(t){t(this.input),this.outputs.forEach(t),t(this.otherwise)},hr.prototype.outputDefined=function(){return this.outputs.every((function(t){return t.outputDefined()}))&&this.otherwise.outputDefined()},hr.prototype.serialize=function(){for(var t=this,e=["match",this.input.serialize()],r=[],n={},i=0,o=Object.keys(this.cases).sort();i<o.length;i+=1){var a=o[i];void 0===(p=n[this.cases[a]])?(n[this.cases[a]]=r.length,r.push([this.cases[a],[a]])):r[p][1].push(a)}for(var s=function(e){return"number"===t.inputType.kind?Number(e):e},l=0,u=r;l<u.length;l+=1){var c=u[l],p=c[0],h=c[1];e.push(1===h.length?s(h[0]):h.map(s)),e.push(this.outputs[outputIndex$1].serialize())}return e.push(this.otherwise.serialize()),e};var fr=function(t,e,r){this.type=t,this.branches=e,this.otherwise=r};fr.parse=function(t,e){if(t.length<4)return e.error("Expected at least 3 arguments, but found only "+(t.length-1)+".");if(t.length%2!=0)return e.error("Expected an odd number of arguments.");var r;e.expectedType&&"value"!==e.expectedType.kind&&(r=e.expectedType);for(var n=[],i=1;i<t.length-1;i+=2){var o=e.parse(t[i],i,jt);if(!o)return null;var a=e.parse(t[i+1],i+1,r);if(!a)return null;n.push([o,a]),r=r||a.type}var s=e.parse(t[t.length-1],t.length-1,r);return s?new fr(r,n,s):null},fr.prototype.evaluate=function(t){for(var e=0,r=this.branches;e<r.length;e+=1){var n=r[e],i=n[1];if(n[0].evaluate(t))return i.evaluate(t)}return this.otherwise.evaluate(t)},fr.prototype.eachChild=function(t){for(var e=0,r=this.branches;e<r.length;e+=1){var n=r[e],i=n[1];t(n[0]),t(i)}t(this.otherwise)},fr.prototype.outputDefined=function(){return this.branches.every((function(t){return t[1].outputDefined()}))&&this.otherwise.outputDefined()},fr.prototype.serialize=function(){var t=["case"];return this.eachChild((function(e){t.push(e.serialize())})),t};var dr=function(t,e,r,n){this.type=t,this.input=e,this.beginIndex=r,this.endIndex=n};function mr(t,e){return"=="===t||"!="===t?"boolean"===e.kind||"string"===e.kind||"number"===e.kind||"null"===e.kind||"value"===e.kind:"string"===e.kind||"number"===e.kind||"value"===e.kind}function gr(t,e,r,n){return 0===n.compare(e,r)}function yr(t,e,r){var n="=="!==t&&"!="!==t;return function(){function i(t,e,r){this.type=jt,this.lhs=t,this.rhs=e,this.collator=r,this.hasUntypedArgument="value"===t.type.kind||"value"===e.type.kind}return i.parse=function(t,e){if(3!==t.length&&4!==t.length)return e.error("Expected two or three arguments.");var r=t[0],o=e.parse(t[1],1,qt);if(!o)return null;if(!mr(r,o.type))return e.concat(1).error('"'+r+"\" comparisons are not supported for type '"+Yt(o.type)+"'.");var a=e.parse(t[2],2,qt);if(!a)return null;if(!mr(r,a.type))return e.concat(2).error('"'+r+"\" comparisons are not supported for type '"+Yt(a.type)+"'.");if(o.type.kind!==a.type.kind&&"value"!==o.type.kind&&"value"!==a.type.kind)return e.error("Cannot compare types '"+Yt(o.type)+"' and '"+Yt(a.type)+"'.");n&&("value"===o.type.kind&&"value"!==a.type.kind?o=new he(a.type,[o]):"value"!==o.type.kind&&"value"===a.type.kind&&(a=new he(o.type,[a])));var s=null;if(4===t.length){if("string"!==o.type.kind&&"string"!==a.type.kind&&"value"!==o.type.kind&&"value"!==a.type.kind)return e.error("Cannot use collator to compare non-string types.");if(!(s=e.parse(t[3],3,Ht)))return null}return new i(o,a,s)},i.prototype.evaluate=function(i){var o=this.lhs.evaluate(i),a=this.rhs.evaluate(i);if(n&&this.hasUntypedArgument){var s=se(o),l=se(a);if(s.kind!==l.kind||"string"!==s.kind&&"number"!==s.kind)throw new ce('Expected arguments for "'+t+'" to be (string, string) or (number, number), but found ('+s.kind+", "+l.kind+") instead.")}if(this.collator&&!n&&this.hasUntypedArgument){var u=se(o),c=se(a);if("string"!==u.kind||"string"!==c.kind)return e(i,o,a)}return this.collator?r(i,o,a,this.collator.evaluate(i)):e(i,o,a)},i.prototype.eachChild=function(t){t(this.lhs),t(this.rhs),this.collator&&t(this.collator)},i.prototype.outputDefined=function(){return!0},i.prototype.serialize=function(){var e=[t];return this.eachChild((function(t){e.push(t.serialize())})),e},i}()}dr.parse=function(t,e){if(t.length<=2||t.length>=5)return e.error("Expected 3 or 4 arguments, but found "+(t.length-1)+" instead.");var r=e.parse(t[1],1,qt),n=e.parse(t[2],2,zt);if(!r||!n)return null;if(!Jt(r.type,[Wt(qt),Nt,qt]))return e.error("Expected first argument to be of type array or string, but found "+Yt(r.type)+" instead");if(4===t.length){var i=e.parse(t[3],3,zt);return i?new dr(r.type,r,n,i):null}return new dr(r.type,r,n)},dr.prototype.evaluate=function(t){var e=this.input.evaluate(t),r=this.beginIndex.evaluate(t);if(!Qt(e,["string","array"]))throw new ce("Expected first argument to be of type array or string, but found "+Yt(se(e))+" instead.");if(this.endIndex){var n=this.endIndex.evaluate(t);return e.slice(r,n)}return e.slice(r)},dr.prototype.eachChild=function(t){t(this.input),t(this.beginIndex),this.endIndex&&t(this.endIndex)},dr.prototype.outputDefined=function(){return!1},dr.prototype.serialize=function(){if(null!=this.endIndex&&void 0!==this.endIndex){var t=this.endIndex.serialize();return["slice",this.input.serialize(),this.beginIndex.serialize(),t]}return["slice",this.input.serialize(),this.beginIndex.serialize()]};var vr=yr("==",(function(t,e,r){return e===r}),gr),_r=yr("!=",(function(t,e,r){return e!==r}),(function(t,e,r,n){return!gr(0,e,r,n)})),br=yr("<",(function(t,e,r){return e<r}),(function(t,e,r,n){return n.compare(e,r)<0})),xr=yr(">",(function(t,e,r){return e>r}),(function(t,e,r,n){return n.compare(e,r)>0})),wr=yr("<=",(function(t,e,r){return e<=r}),(function(t,e,r,n){return n.compare(e,r)<=0})),Er=yr(">=",(function(t,e,r){return e>=r}),(function(t,e,r,n){return n.compare(e,r)>=0})),Tr=function(t,e,r,n,i){this.type=Nt,this.number=t,this.locale=e,this.currency=r,this.minFractionDigits=n,this.maxFractionDigits=i};Tr.parse=function(t,e){if(3!==t.length)return e.error("Expected two arguments.");var r=e.parse(t[1],1,zt);if(!r)return null;var n=t[2];if("object"!=typeof n||Array.isArray(n))return e.error("NumberFormat options argument must be an object.");var i=null;if(n.locale&&!(i=e.parse(n.locale,1,Nt)))return null;var o=null;if(n.currency&&!(o=e.parse(n.currency,1,Nt)))return null;var a=null;if(n["min-fraction-digits"]&&!(a=e.parse(n["min-fraction-digits"],1,zt)))return null;var s=null;return n["max-fraction-digits"]&&!(s=e.parse(n["max-fraction-digits"],1,zt))?null:new Tr(r,i,o,a,s)},Tr.prototype.evaluate=function(t){return new Intl.NumberFormat(this.locale?this.locale.evaluate(t):[],{style:this.currency?"currency":"decimal",currency:this.currency?this.currency.evaluate(t):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(t):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(t):void 0}).format(this.number.evaluate(t))},Tr.prototype.eachChild=function(t){t(this.number),this.locale&&t(this.locale),this.currency&&t(this.currency),this.minFractionDigits&&t(this.minFractionDigits),this.maxFractionDigits&&t(this.maxFractionDigits)},Tr.prototype.outputDefined=function(){return!1},Tr.prototype.serialize=function(){var t={};return this.locale&&(t.locale=this.locale.serialize()),this.currency&&(t.currency=this.currency.serialize()),this.minFractionDigits&&(t["min-fraction-digits"]=this.minFractionDigits.serialize()),this.maxFractionDigits&&(t["max-fraction-digits"]=this.maxFractionDigits.serialize()),["number-format",this.number.serialize(),t]};var Ar=function(t){this.type=zt,this.input=t};Ar.parse=function(t,e){if(2!==t.length)return e.error("Expected 1 argument, but found "+(t.length-1)+" instead.");var r=e.parse(t[1],1);return r?"array"!==r.type.kind&&"string"!==r.type.kind&&"value"!==r.type.kind?e.error("Expected argument of type string or array, but found "+Yt(r.type)+" instead."):new Ar(r):null},Ar.prototype.evaluate=function(t){var e=this.input.evaluate(t);if("string"==typeof e)return e.length;if(Array.isArray(e))return e.length;throw new ce("Expected value to be of type string or array, but found "+Yt(se(e))+" instead.")},Ar.prototype.eachChild=function(t){t(this.input)},Ar.prototype.outputDefined=function(){return!1},Ar.prototype.serialize=function(){var t=["length"];return this.eachChild((function(e){t.push(e.serialize())})),t};var Cr={"==":vr,"!=":_r,">":xr,"<":br,">=":Er,"<=":wr,array:he,at:ur,boolean:he,case:fr,coalesce:sr,collator:be,format:fe,image:de,in:cr,"index-of":pr,interpolate:or,"interpolate-hcl":or,"interpolate-lab":or,length:Ar,let:lr,literal:ue,match:hr,number:he,"number-format":Tr,object:he,slice:dr,step:qe,string:he,"to-boolean":ge,"to-color":ge,"to-number":ge,"to-string":ge,var:je,within:Le};function Sr(t,e){var r=e[0],n=e[1],i=e[2],o=e[3];r=r.evaluate(t),n=n.evaluate(t),i=i.evaluate(t);var a=o?o.evaluate(t):1,s=oe(r,n,i,a);if(s)throw new ce(s);return new te(r/255*a,n/255*a,i/255*a,a)}function Pr(t,e){return t in e}function Ir(t,e){var r=e[t];return void 0===r?null:r}function Dr(t){return{type:t}}function Or(t){return{result:"success",value:t}}function Mr(t){return{result:"error",value:t}}function Br(t){return"data-driven"===t["property-type"]||"cross-faded-data-driven"===t["property-type"]}function kr(t){return!!t.expression&&t.expression.parameters.indexOf("zoom")>-1}function Fr(t){return!!t.expression&&t.expression.interpolated}function Lr(t){return t instanceof Number?"number":t instanceof String?"string":t instanceof Boolean?"boolean":Array.isArray(t)?"array":null===t?"null":typeof t}function Rr(t){return"object"==typeof t&&null!==t&&!Array.isArray(t)}function zr(t){return t}function Nr(t,e,r){return void 0!==t?t:void 0!==e?e:void 0!==r?r:void 0}function jr(t,e,r,n,i){return Nr(typeof r===i?n[r]:void 0,t.default,e.default)}function Ur(t,e,r){if("number"!==Lr(r))return Nr(t.default,e.default);var n=t.stops.length;if(1===n)return t.stops[0][1];if(r<=t.stops[0][0])return t.stops[0][1];if(r>=t.stops[n-1][0])return t.stops[n-1][1];var i=Ve(t.stops.map((function(t){return t[0]})),r);return t.stops[i][1]}function Vr(t,e,r){var n=void 0!==t.base?t.base:1;if("number"!==Lr(r))return Nr(t.default,e.default);var i=t.stops.length;if(1===i)return t.stops[0][1];if(r<=t.stops[0][0])return t.stops[0][1];if(r>=t.stops[i-1][0])return t.stops[i-1][1];var o=Ve(t.stops.map((function(t){return t[0]})),r),a=function(t,e,r,n){var i=n-r,o=t-r;return 0===i?0:1===e?o/i:(Math.pow(e,o)-1)/(Math.pow(e,i)-1)}(r,n,t.stops[o][0],t.stops[o+1][0]),s=t.stops[o][1],l=t.stops[o+1][1],u=Ge[e.type]||zr;if(t.colorSpace&&"rgb"!==t.colorSpace){var c=ir[t.colorSpace];u=function(t,e){return c.reverse(c.interpolate(c.forward(t),c.forward(e),a))}}return"function"==typeof s.evaluate?{evaluate:function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];var r=s.evaluate.apply(void 0,t),n=l.evaluate.apply(void 0,t);if(void 0!==r&&void 0!==n)return u(r,n,a)}}:u(s,l,a)}function qr(t,e,r){return"color"===e.type?r=te.parse(r):"formatted"===e.type?r=ne.fromString(r.toString()):"resolvedImage"===e.type?r=ie.fromString(r.toString()):Lr(r)===e.type||"enum"===e.type&&e.values[r]||(r=void 0),Nr(r,t.default,e.default)}_e.register(Cr,{error:[{kind:"error"},[Nt],function(t,e){throw new ce(e[0].evaluate(t))}],typeof:[Nt,[qt],function(t,e){return Yt(se(e[0].evaluate(t)))}],"to-rgba":[Wt(zt,4),[Ut],function(t,e){return e[0].evaluate(t).toArray()}],rgb:[Ut,[zt,zt,zt],Sr],rgba:[Ut,[zt,zt,zt,zt],Sr],has:{type:jt,overloads:[[[Nt],function(t,e){return Pr(e[0].evaluate(t),t.properties())}],[[Nt,Vt],function(t,e){var r=e[1];return Pr(e[0].evaluate(t),r.evaluate(t))}]]},get:{type:qt,overloads:[[[Nt],function(t,e){return Ir(e[0].evaluate(t),t.properties())}],[[Nt,Vt],function(t,e){var r=e[1];return Ir(e[0].evaluate(t),r.evaluate(t))}]]},"feature-state":[qt,[Nt],function(t,e){return Ir(e[0].evaluate(t),t.featureState||{})}],properties:[Vt,[],function(t){return t.properties()}],"geometry-type":[Nt,[],function(t){return t.geometryType()}],id:[qt,[],function(t){return t.id()}],zoom:[zt,[],function(t){return t.globals.zoom}],"heatmap-density":[zt,[],function(t){return t.globals.heatmapDensity||0}],"line-progress":[zt,[],function(t){return t.globals.lineProgress||0}],accumulated:[qt,[],function(t){return void 0===t.globals.accumulated?null:t.globals.accumulated}],"+":[zt,Dr(zt),function(t,e){for(var r=0,n=0,i=e;n<i.length;n+=1)r+=i[n].evaluate(t);return r}],"*":[zt,Dr(zt),function(t,e){for(var r=1,n=0,i=e;n<i.length;n+=1)r*=i[n].evaluate(t);return r}],"-":{type:zt,overloads:[[[zt,zt],function(t,e){var r=e[1];return e[0].evaluate(t)-r.evaluate(t)}],[[zt],function(t,e){return-e[0].evaluate(t)}]]},"/":[zt,[zt,zt],function(t,e){var r=e[1];return e[0].evaluate(t)/r.evaluate(t)}],"%":[zt,[zt,zt],function(t,e){var r=e[1];return e[0].evaluate(t)%r.evaluate(t)}],ln2:[zt,[],function(){return Math.LN2}],pi:[zt,[],function(){return Math.PI}],e:[zt,[],function(){return Math.E}],"^":[zt,[zt,zt],function(t,e){var r=e[1];return Math.pow(e[0].evaluate(t),r.evaluate(t))}],sqrt:[zt,[zt],function(t,e){return Math.sqrt(e[0].evaluate(t))}],log10:[zt,[zt],function(t,e){return Math.log(e[0].evaluate(t))/Math.LN10}],ln:[zt,[zt],function(t,e){return Math.log(e[0].evaluate(t))}],log2:[zt,[zt],function(t,e){return Math.log(e[0].evaluate(t))/Math.LN2}],sin:[zt,[zt],function(t,e){return Math.sin(e[0].evaluate(t))}],cos:[zt,[zt],function(t,e){return Math.cos(e[0].evaluate(t))}],tan:[zt,[zt],function(t,e){return Math.tan(e[0].evaluate(t))}],asin:[zt,[zt],function(t,e){return Math.asin(e[0].evaluate(t))}],acos:[zt,[zt],function(t,e){return Math.acos(e[0].evaluate(t))}],atan:[zt,[zt],function(t,e){return Math.atan(e[0].evaluate(t))}],min:[zt,Dr(zt),function(t,e){return Math.min.apply(Math,e.map((function(e){return e.evaluate(t)})))}],max:[zt,Dr(zt),function(t,e){return Math.max.apply(Math,e.map((function(e){return e.evaluate(t)})))}],abs:[zt,[zt],function(t,e){return Math.abs(e[0].evaluate(t))}],round:[zt,[zt],function(t,e){var r=e[0].evaluate(t);return r<0?-Math.round(-r):Math.round(r)}],floor:[zt,[zt],function(t,e){return Math.floor(e[0].evaluate(t))}],ceil:[zt,[zt],function(t,e){return Math.ceil(e[0].evaluate(t))}],"filter-==":[jt,[Nt,qt],function(t,e){var r=e[0],n=e[1];return t.properties()[r.value]===n.value}],"filter-id-==":[jt,[qt],function(t,e){var r=e[0];return t.id()===r.value}],"filter-type-==":[jt,[Nt],function(t,e){var r=e[0];return t.geometryType()===r.value}],"filter-<":[jt,[Nt,qt],function(t,e){var r=e[0],n=e[1],i=t.properties()[r.value],o=n.value;return typeof i==typeof o&&i<o}],"filter-id-<":[jt,[qt],function(t,e){var r=e[0],n=t.id(),i=r.value;return typeof n==typeof i&&n<i}],"filter->":[jt,[Nt,qt],function(t,e){var r=e[0],n=e[1],i=t.properties()[r.value],o=n.value;return typeof i==typeof o&&i>o}],"filter-id->":[jt,[qt],function(t,e){var r=e[0],n=t.id(),i=r.value;return typeof n==typeof i&&n>i}],"filter-<=":[jt,[Nt,qt],function(t,e){var r=e[0],n=e[1],i=t.properties()[r.value],o=n.value;return typeof i==typeof o&&i<=o}],"filter-id-<=":[jt,[qt],function(t,e){var r=e[0],n=t.id(),i=r.value;return typeof n==typeof i&&n<=i}],"filter->=":[jt,[Nt,qt],function(t,e){var r=e[0],n=e[1],i=t.properties()[r.value],o=n.value;return typeof i==typeof o&&i>=o}],"filter-id->=":[jt,[qt],function(t,e){var r=e[0],n=t.id(),i=r.value;return typeof n==typeof i&&n>=i}],"filter-has":[jt,[qt],function(t,e){return e[0].value in t.properties()}],"filter-has-id":[jt,[],function(t){return null!==t.id()&&void 0!==t.id()}],"filter-type-in":[jt,[Wt(Nt)],function(t,e){return e[0].value.indexOf(t.geometryType())>=0}],"filter-id-in":[jt,[Wt(qt)],function(t,e){return e[0].value.indexOf(t.id())>=0}],"filter-in-small":[jt,[Nt,Wt(qt)],function(t,e){var r=e[0];return e[1].value.indexOf(t.properties()[r.value])>=0}],"filter-in-large":[jt,[Nt,Wt(qt)],function(t,e){var r=e[0],n=e[1];return function(t,e,r,n){for(;r<=n;){var i=r+n>>1;if(e[i]===t)return!0;e[i]>t?n=i-1:r=i+1}return!1}(t.properties()[r.value],n.value,0,n.value.length-1)}],all:{type:jt,overloads:[[[jt,jt],function(t,e){var r=e[1];return e[0].evaluate(t)&&r.evaluate(t)}],[Dr(jt),function(t,e){for(var r=0,n=e;r<n.length;r+=1)if(!n[r].evaluate(t))return!1;return!0}]]},any:{type:jt,overloads:[[[jt,jt],function(t,e){var r=e[1];return e[0].evaluate(t)||r.evaluate(t)}],[Dr(jt),function(t,e){for(var r=0,n=e;r<n.length;r+=1)if(n[r].evaluate(t))return!0;return!1}]]},"!":[jt,[jt],function(t,e){return!e[0].evaluate(t)}],"is-supported-script":[jt,[Nt],function(t,e){var r=t.globals&&t.globals.isSupportedScript;return!r||r(e[0].evaluate(t))}],upcase:[Nt,[Nt],function(t,e){return e[0].evaluate(t).toUpperCase()}],downcase:[Nt,[Nt],function(t,e){return e[0].evaluate(t).toLowerCase()}],concat:[Nt,Dr(qt),function(t,e){return e.map((function(e){return le(e.evaluate(t))})).join("")}],"resolved-locale":[Nt,[Ht],function(t,e){return e[0].evaluate(t).resolvedLocale()}]});var Hr=function(t,e){this.expression=t,this._warningHistory={},this._evaluator=new ve,this._defaultValue=e?function(t){return"color"===t.type&&Rr(t.default)?new te(0,0,0,0):"color"===t.type?te.parse(t.default)||null:void 0===t.default?null:t.default}(e):null,this._enumValues=e&&"enum"===e.type?e.values:null};function Gr(t){return Array.isArray(t)&&t.length>0&&"string"==typeof t[0]&&t[0]in Cr}function Zr(t,e){var r=new Ue(Cr,[],e?function(t){var e={color:Ut,string:Nt,number:zt,enum:Nt,boolean:jt,formatted:Gt,resolvedImage:Zt};return"array"===t.type?Wt(e[t.value]||qt,t.length):e[t.type]}(e):void 0),n=r.parse(t,void 0,void 0,void 0,e&&"string"===e.type?{typeAnnotation:"coerce"}:void 0);return n?Or(new Hr(n,e)):Mr(r.errors)}Hr.prototype.evaluateWithoutErrorHandling=function(t,e,r,n,i,o){return this._evaluator.globals=t,this._evaluator.feature=e,this._evaluator.featureState=r,this._evaluator.canonical=n,this._evaluator.availableImages=i||null,this._evaluator.formattedSection=o,this.expression.evaluate(this._evaluator)},Hr.prototype.evaluate=function(t,e,r,n,i,o){this._evaluator.globals=t,this._evaluator.feature=e||null,this._evaluator.featureState=r||null,this._evaluator.canonical=n,this._evaluator.availableImages=i||null,this._evaluator.formattedSection=o||null;try{var a=this.expression.evaluate(this._evaluator);if(null==a||"number"==typeof a&&a!=a)return this._defaultValue;if(this._enumValues&&!(a in this._enumValues))throw new ce("Expected value to be one of "+Object.keys(this._enumValues).map((function(t){return JSON.stringify(t)})).join(", ")+", but found "+JSON.stringify(a)+" instead.");return a}catch(t){return this._warningHistory[t.message]||(this._warningHistory[t.message]=!0,"undefined"!=typeof console&&console.warn(t.message)),this._defaultValue}};var Wr=function(t,e){this.kind=t,this._styleExpression=e,this.isStateDependent="constant"!==t&&!ze(e.expression)};Wr.prototype.evaluateWithoutErrorHandling=function(t,e,r,n,i,o){return this._styleExpression.evaluateWithoutErrorHandling(t,e,r,n,i,o)},Wr.prototype.evaluate=function(t,e,r,n,i,o){return this._styleExpression.evaluate(t,e,r,n,i,o)};var Yr=function(t,e,r,n){this.kind=t,this.zoomStops=r,this._styleExpression=e,this.isStateDependent="camera"!==t&&!ze(e.expression),this.interpolationType=n};function Xr(t,e){if("error"===(t=Zr(t,e)).result)return t;var r=t.value.expression,n=Re(r);if(!n&&!Br(e))return Mr([new Ft("","data expressions not supported")]);var i=Ne(r,["zoom"]);if(!i&&!kr(e))return Mr([new Ft("","zoom expressions not supported")]);var o=function t(e){var r=null;if(e instanceof lr)r=t(e.result);else if(e instanceof sr)for(var n=0,i=e.args;n<i.length&&!(r=t(i[n]));n+=1);else(e instanceof qe||e instanceof or)&&e.input instanceof _e&&"zoom"===e.input.name&&(r=e);return r instanceof Ft||e.eachChild((function(e){var n=t(e);n instanceof Ft?r=n:!r&&n?r=new Ft("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):r&&n&&r!==n&&(r=new Ft("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))})),r}(r);return o||i?o instanceof Ft?Mr([o]):o instanceof or&&!Fr(e)?Mr([new Ft("",'"interpolate" expressions cannot be used with this property')]):Or(o?new Yr(n?"camera":"composite",t.value,o.labels,o instanceof or?o.interpolation:void 0):new Wr(n?"constant":"source",t.value)):Mr([new Ft("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')])}Yr.prototype.evaluateWithoutErrorHandling=function(t,e,r,n,i,o){return this._styleExpression.evaluateWithoutErrorHandling(t,e,r,n,i,o)},Yr.prototype.evaluate=function(t,e,r,n,i,o){return this._styleExpression.evaluate(t,e,r,n,i,o)},Yr.prototype.interpolationFactor=function(t,e,r){return this.interpolationType?or.interpolationFactor(this.interpolationType,t,e,r):0};var Kr=function(t,e){this._parameters=t,this._specification=e,Mt(this,function t(e,r){var n,i,o,a="color"===r.type,s=e.stops&&"object"==typeof e.stops[0][0],l=s||!(s||void 0!==e.property),u=e.type||(Fr(r)?"exponential":"interval");if(a&&((e=Mt({},e)).stops&&(e.stops=e.stops.map((function(t){return[t[0],te.parse(t[1])]}))),e.default=te.parse(e.default?e.default:r.default)),e.colorSpace&&"rgb"!==e.colorSpace&&!ir[e.colorSpace])throw new Error("Unknown color space: "+e.colorSpace);if("exponential"===u)n=Vr;else if("interval"===u)n=Ur;else if("categorical"===u){n=jr,i=Object.create(null);for(var c=0,p=e.stops;c<p.length;c+=1){var h=p[c];i[h[0]]=h[1]}o=typeof e.stops[0][0]}else{if("identity"!==u)throw new Error('Unknown function type "'+u+'"');n=qr}if(s){for(var f={},d=[],m=0;m<e.stops.length;m++){var g=e.stops[m],y=g[0].zoom;void 0===f[y]&&(f[y]={zoom:y,type:e.type,property:e.property,default:e.default,stops:[]},d.push(y)),f[y].stops.push([g[0].value,g[1]])}for(var v=[],_=0,b=d;_<b.length;_+=1){var x=b[_];v.push([f[x].zoom,t(f[x],r)])}var w={name:"linear"};return{kind:"composite",interpolationType:w,interpolationFactor:or.interpolationFactor.bind(void 0,w),zoomStops:v.map((function(t){return t[0]})),evaluate:function(t,n){var i=t.zoom;return Vr({stops:v,base:e.base},r,i).evaluate(i,n)}}}if(l){var E="exponential"===u?{name:"exponential",base:void 0!==e.base?e.base:1}:null;return{kind:"camera",interpolationType:E,interpolationFactor:or.interpolationFactor.bind(void 0,E),zoomStops:e.stops.map((function(t){return t[0]})),evaluate:function(t){return n(e,r,t.zoom,i,o)}}}return{kind:"source",evaluate:function(t,a){var s=a&&a.properties?a.properties[e.property]:void 0;return void 0===s?Nr(e.default,r.default):n(e,r,s,i,o)}}}(this._parameters,this._specification))};function Jr(t){var e=t.key,r=t.value,n=t.valueSpec||{},i=t.objectElementValidators||{},o=t.style,a=t.styleSpec,s=[],l=Lr(r);if("object"!==l)return[new Dt(e,r,"object expected, "+l+" found")];for(var u in r){var c=u.split(".")[0],p=n[c]||n["*"],h=void 0;if(i[c])h=i[c];else if(n[c])h=En;else if(i["*"])h=i["*"];else{if(!n["*"]){s.push(new Dt(e,r[u],'unknown property "'+u+'"'));continue}h=En}s=s.concat(h({key:(e?e+".":e)+u,value:r[u],valueSpec:p,style:o,styleSpec:a,object:r,objectKey:u},r))}for(var f in n)i[f]||n[f].required&&void 0===n[f].default&&void 0===r[f]&&s.push(new Dt(e,r,'missing required property "'+f+'"'));return s}function Qr(t){var e=t.value,r=t.valueSpec,n=t.style,i=t.styleSpec,o=t.key,a=t.arrayElementValidator||En;if("array"!==Lr(e))return[new Dt(o,e,"array expected, "+Lr(e)+" found")];if(r.length&&e.length!==r.length)return[new Dt(o,e,"array length "+r.length+" expected, length "+e.length+" found")];if(r["min-length"]&&e.length<r["min-length"])return[new Dt(o,e,"array length at least "+r["min-length"]+" expected, length "+e.length+" found")];var s={type:r.value,values:r.values};i.$version<7&&(s.function=r.function),"object"===Lr(r.value)&&(s=r.value);for(var l=[],u=0;u<e.length;u++)l=l.concat(a({array:e,arrayIndex:u,value:e[u],valueSpec:s,style:n,styleSpec:i,key:o+"["+u+"]"}));return l}function $r(t){var e=t.key,r=t.value,n=t.valueSpec,i=Lr(r);return"number"===i&&r!=r&&(i="NaN"),"number"!==i?[new Dt(e,r,"number expected, "+i+" found")]:"minimum"in n&&r<n.minimum?[new Dt(e,r,r+" is less than the minimum value "+n.minimum)]:"maximum"in n&&r>n.maximum?[new Dt(e,r,r+" is greater than the maximum value "+n.maximum)]:[]}function tn(t){var e,r,n,i=t.valueSpec,o=Bt(t.value.type),a={},s="categorical"!==o&&void 0===t.value.property,l=!s,u="array"===Lr(t.value.stops)&&"array"===Lr(t.value.stops[0])&&"object"===Lr(t.value.stops[0][0]),c=Jr({key:t.key,value:t.value,valueSpec:t.styleSpec.function,style:t.style,styleSpec:t.styleSpec,objectElementValidators:{stops:function(t){if("identity"===o)return[new Dt(t.key,t.value,'identity function may not have a "stops" property')];var e=[],r=t.value;return e=e.concat(Qr({key:t.key,value:r,valueSpec:t.valueSpec,style:t.style,styleSpec:t.styleSpec,arrayElementValidator:p})),"array"===Lr(r)&&0===r.length&&e.push(new Dt(t.key,r,"array must have at least one stop")),e},default:function(t){return En({key:t.key,value:t.value,valueSpec:i,style:t.style,styleSpec:t.styleSpec})}}});return"identity"===o&&s&&c.push(new Dt(t.key,t.value,'missing required property "property"')),"identity"===o||t.value.stops||c.push(new Dt(t.key,t.value,'missing required property "stops"')),"exponential"===o&&t.valueSpec.expression&&!Fr(t.valueSpec)&&c.push(new Dt(t.key,t.value,"exponential functions not supported")),t.styleSpec.$version>=8&&(l&&!Br(t.valueSpec)?c.push(new Dt(t.key,t.value,"property functions not supported")):s&&!kr(t.valueSpec)&&c.push(new Dt(t.key,t.value,"zoom functions not supported"))),"categorical"!==o&&!u||void 0!==t.value.property||c.push(new Dt(t.key,t.value,'"property" property is required')),c;function p(t){var e=[],o=t.value,s=t.key;if("array"!==Lr(o))return[new Dt(s,o,"array expected, "+Lr(o)+" found")];if(2!==o.length)return[new Dt(s,o,"array length 2 expected, length "+o.length+" found")];if(u){if("object"!==Lr(o[0]))return[new Dt(s,o,"object expected, "+Lr(o[0])+" found")];if(void 0===o[0].zoom)return[new Dt(s,o,"object stop key must have zoom")];if(void 0===o[0].value)return[new Dt(s,o,"object stop key must have value")];if(n&&n>Bt(o[0].zoom))return[new Dt(s,o[0].zoom,"stop zoom values must appear in ascending order")];Bt(o[0].zoom)!==n&&(n=Bt(o[0].zoom),r=void 0,a={}),e=e.concat(Jr({key:s+"[0]",value:o[0],valueSpec:{zoom:{}},style:t.style,styleSpec:t.styleSpec,objectElementValidators:{zoom:$r,value:h}}))}else e=e.concat(h({key:s+"[0]",value:o[0],valueSpec:{},style:t.style,styleSpec:t.styleSpec},o));return Gr(kt(o[1]))?e.concat([new Dt(s+"[1]",o[1],"expressions are not allowed in function stops.")]):e.concat(En({key:s+"[1]",value:o[1],valueSpec:i,style:t.style,styleSpec:t.styleSpec}))}function h(t,n){var s=Lr(t.value),l=Bt(t.value),u=null!==t.value?t.value:n;if(e){if(s!==e)return[new Dt(t.key,u,s+" stop domain type must match previous stop domain type "+e)]}else e=s;if("number"!==s&&"string"!==s&&"boolean"!==s)return[new Dt(t.key,u,"stop domain value must be a number, string, or boolean")];if("number"!==s&&"categorical"!==o){var c="number expected, "+s+" found";return Br(i)&&void 0===o&&(c+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new Dt(t.key,u,c)]}return"categorical"!==o||"number"!==s||isFinite(l)&&Math.floor(l)===l?"categorical"!==o&&"number"===s&&void 0!==r&&l<r?[new Dt(t.key,u,"stop domain values must appear in ascending order")]:(r=l,"categorical"===o&&l in a?[new Dt(t.key,u,"stop domain values must be unique")]:(a[l]=!0,[])):[new Dt(t.key,u,"integer expected, found "+l)]}}function en(t){var e=("property"===t.expressionContext?Xr:Zr)(kt(t.value),t.valueSpec);if("error"===e.result)return e.value.map((function(e){return new Dt(""+t.key+e.key,t.value,e.message)}));var r=e.value.expression||e.value._styleExpression.expression;if("property"===t.expressionContext&&"text-font"===t.propertyKey&&!r.outputDefined())return[new Dt(t.key,t.value,'Invalid data expression for "'+t.propertyKey+'". Output values must be contained as literals within the expression.')];if("property"===t.expressionContext&&"layout"===t.propertyType&&!ze(r))return[new Dt(t.key,t.value,'"feature-state" data expressions are not supported with layout properties.')];if("filter"===t.expressionContext&&!ze(r))return[new Dt(t.key,t.value,'"feature-state" data expressions are not supported with filters.')];if(t.expressionContext&&0===t.expressionContext.indexOf("cluster")){if(!Ne(r,["zoom","feature-state"]))return[new Dt(t.key,t.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if("cluster-initial"===t.expressionContext&&!Re(r))return[new Dt(t.key,t.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function rn(t){var e=t.key,r=t.value,n=t.valueSpec,i=[];return Array.isArray(n.values)?-1===n.values.indexOf(Bt(r))&&i.push(new Dt(e,r,"expected one of ["+n.values.join(", ")+"], "+JSON.stringify(r)+" found")):-1===Object.keys(n.values).indexOf(Bt(r))&&i.push(new Dt(e,r,"expected one of ["+Object.keys(n.values).join(", ")+"], "+JSON.stringify(r)+" found")),i}function nn(t){if(!0===t||!1===t)return!0;if(!Array.isArray(t)||0===t.length)return!1;switch(t[0]){case"has":return t.length>=2&&"$id"!==t[1]&&"$type"!==t[1];case"in":return t.length>=3&&("string"!=typeof t[1]||Array.isArray(t[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return 3!==t.length||Array.isArray(t[1])||Array.isArray(t[2]);case"any":case"all":for(var e=0,r=t.slice(1);e<r.length;e+=1){var n=r[e];if(!nn(n)&&"boolean"!=typeof n)return!1}return!0;default:return!0}}Kr.deserialize=function(t){return new Kr(t._parameters,t._specification)},Kr.serialize=function(t){return{_parameters:t._parameters,_specification:t._specification}};var on={type:"boolean",default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}};function an(t){if(null==t)return{filter:function(){return!0},needGeometry:!1};nn(t)||(t=ln(t));var e=Zr(t,on);if("error"===e.result)throw new Error(e.value.map((function(t){return t.key+": "+t.message})).join(", "));return{filter:function(t,r,n){return e.value.evaluate(t,r,{},n)},needGeometry:function t(e){if(!Array.isArray(e))return!1;if("within"===e[0])return!0;for(var r=1;r<e.length;r++)if(t(e[r]))return!0;return!1}(t)}}function sn(t,e){return t<e?-1:t>e?1:0}function ln(t){if(!t)return!0;var e,r=t[0];return t.length<=1?"any"!==r:"=="===r?un(t[1],t[2],"=="):"!="===r?hn(un(t[1],t[2],"==")):"<"===r||">"===r||"<="===r||">="===r?un(t[1],t[2],r):"any"===r?(e=t.slice(1),["any"].concat(e.map(ln))):"all"===r?["all"].concat(t.slice(1).map(ln)):"none"===r?["all"].concat(t.slice(1).map(ln).map(hn)):"in"===r?cn(t[1],t.slice(2)):"!in"===r?hn(cn(t[1],t.slice(2))):"has"===r?pn(t[1]):"!has"===r?hn(pn(t[1])):"within"!==r||t}function un(t,e,r){switch(t){case"$type":return["filter-type-"+r,e];case"$id":return["filter-id-"+r,e];default:return["filter-"+r,t,e]}}function cn(t,e){if(0===e.length)return!1;switch(t){case"$type":return["filter-type-in",["literal",e]];case"$id":return["filter-id-in",["literal",e]];default:return e.length>200&&!e.some((function(t){return typeof t!=typeof e[0]}))?["filter-in-large",t,["literal",e.sort(sn)]]:["filter-in-small",t,["literal",e]]}}function pn(t){switch(t){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",t]}}function hn(t){return["!",t]}function fn(t){return nn(kt(t.value))?en(Mt({},t,{expressionContext:"filter",valueSpec:{value:"boolean"}})):function t(e){var r=e.value,n=e.key;if("array"!==Lr(r))return[new Dt(n,r,"array expected, "+Lr(r)+" found")];var i,o=e.styleSpec,a=[];if(r.length<1)return[new Dt(n,r,"filter array must have at least 1 element")];switch(a=a.concat(rn({key:n+"[0]",value:r[0],valueSpec:o.filter_operator,style:e.style,styleSpec:e.styleSpec})),Bt(r[0])){case"<":case"<=":case">":case">=":r.length>=2&&"$type"===Bt(r[1])&&a.push(new Dt(n,r,'"$type" cannot be use with operator "'+r[0]+'"'));case"==":case"!=":3!==r.length&&a.push(new Dt(n,r,'filter array for operator "'+r[0]+'" must have 3 elements'));case"in":case"!in":r.length>=2&&"string"!==(i=Lr(r[1]))&&a.push(new Dt(n+"[1]",r[1],"string expected, "+i+" found"));for(var s=2;s<r.length;s++)i=Lr(r[s]),"$type"===Bt(r[1])?a=a.concat(rn({key:n+"["+s+"]",value:r[s],valueSpec:o.geometry_type,style:e.style,styleSpec:e.styleSpec})):"string"!==i&&"number"!==i&&"boolean"!==i&&a.push(new Dt(n+"["+s+"]",r[s],"string, number, or boolean expected, "+i+" found"));break;case"any":case"all":case"none":for(var l=1;l<r.length;l++)a=a.concat(t({key:n+"["+l+"]",value:r[l],style:e.style,styleSpec:e.styleSpec}));break;case"has":case"!has":i=Lr(r[1]),2!==r.length?a.push(new Dt(n,r,'filter array for "'+r[0]+'" operator must have 2 elements')):"string"!==i&&a.push(new Dt(n+"[1]",r[1],"string expected, "+i+" found"));break;case"within":i=Lr(r[1]),2!==r.length?a.push(new Dt(n,r,'filter array for "'+r[0]+'" operator must have 2 elements')):"object"!==i&&a.push(new Dt(n+"[1]",r[1],"object expected, "+i+" found"))}return a}(t)}function dn(t,e){var r=t.key,n=t.style,i=t.styleSpec,o=t.value,a=t.objectKey,s=i[e+"_"+t.layerType];if(!s)return[];var l=a.match(/^(.*)-transition$/);if("paint"===e&&l&&s[l[1]]&&s[l[1]].transition)return En({key:r,value:o,valueSpec:i.transition,style:n,styleSpec:i});var u,c=t.valueSpec||s[a];if(!c)return[new Dt(r,o,'unknown property "'+a+'"')];if("string"===Lr(o)&&Br(c)&&!c.tokens&&(u=/^{([^}]+)}$/.exec(o)))return[new Dt(r,o,'"'+a+'" does not support interpolation syntax\nUse an identity property function instead: `{ "type": "identity", "property": '+JSON.stringify(u[1])+" }`.")];var p=[];return"symbol"===t.layerType&&("text-field"===a&&n&&!n.glyphs&&p.push(new Dt(r,o,'use of "text-field" requires a style "glyphs" property')),"text-font"===a&&Rr(kt(o))&&"identity"===Bt(o.type)&&p.push(new Dt(r,o,'"text-font" does not support identity functions'))),p.concat(En({key:t.key,value:o,valueSpec:c,style:n,styleSpec:i,expressionContext:"property",propertyType:e,propertyKey:a}))}function mn(t){return dn(t,"paint")}function gn(t){return dn(t,"layout")}function yn(t){var e=[],r=t.value,n=t.key,i=t.style,o=t.styleSpec;r.type||r.ref||e.push(new Dt(n,r,'either "type" or "ref" is required'));var a,s=Bt(r.type),l=Bt(r.ref);if(r.id)for(var u=Bt(r.id),c=0;c<t.arrayIndex;c++){var p=i.layers[c];Bt(p.id)===u&&e.push(new Dt(n,r.id,'duplicate layer id "'+r.id+'", previously used at line '+p.id.__line__))}if("ref"in r)["type","source","source-layer","filter","layout"].forEach((function(t){t in r&&e.push(new Dt(n,r[t],'"'+t+'" is prohibited for ref layers'))})),i.layers.forEach((function(t){Bt(t.id)===l&&(a=t)})),a?a.ref?e.push(new Dt(n,r.ref,"ref cannot reference another ref layer")):s=Bt(a.type):e.push(new Dt(n,r.ref,'ref layer "'+l+'" not found'));else if("background"!==s)if(r.source){var h=i.sources&&i.sources[r.source],f=h&&Bt(h.type);h?"vector"===f&&"raster"===s?e.push(new Dt(n,r.source,'layer "'+r.id+'" requires a raster source')):"raster"===f&&"raster"!==s?e.push(new Dt(n,r.source,'layer "'+r.id+'" requires a vector source')):"vector"!==f||r["source-layer"]?"raster-dem"===f&&"hillshade"!==s?e.push(new Dt(n,r.source,"raster-dem source can only be used with layer type 'hillshade'.")):"line"!==s||!r.paint||!r.paint["line-gradient"]||"geojson"===f&&h.lineMetrics||e.push(new Dt(n,r,'layer "'+r.id+'" specifies a line-gradient, which requires a GeoJSON source with `lineMetrics` enabled.')):e.push(new Dt(n,r,'layer "'+r.id+'" must specify a "source-layer"')):e.push(new Dt(n,r.source,'source "'+r.source+'" not found'))}else e.push(new Dt(n,r,'missing required property "source"'));return e=e.concat(Jr({key:n,value:r,valueSpec:o.layer,style:t.style,styleSpec:t.styleSpec,objectElementValidators:{"*":function(){return[]},type:function(){return En({key:n+".type",value:r.type,valueSpec:o.layer.type,style:t.style,styleSpec:t.styleSpec,object:r,objectKey:"type"})},filter:fn,layout:function(t){return Jr({layer:r,key:t.key,value:t.value,style:t.style,styleSpec:t.styleSpec,objectElementValidators:{"*":function(t){return gn(Mt({layerType:s},t))}}})},paint:function(t){return Jr({layer:r,key:t.key,value:t.value,style:t.style,styleSpec:t.styleSpec,objectElementValidators:{"*":function(t){return mn(Mt({layerType:s},t))}}})}}}))}function vn(t){var e=t.value,r=t.key,n=Lr(e);return"string"!==n?[new Dt(r,e,"string expected, "+n+" found")]:[]}var _n={promoteId:function(t){var e=t.key,r=t.value;if("string"===Lr(r))return vn({key:e,value:r});var n=[];for(var i in r)n.push.apply(n,vn({key:e+"."+i,value:r[i]}));return n}};function bn(t){var e=t.value,r=t.key,n=t.styleSpec,i=t.style;if(!e.type)return[new Dt(r,e,'"type" is required')];var o,a=Bt(e.type);switch(a){case"vector":case"raster":case"raster-dem":return Jr({key:r,value:e,valueSpec:n["source_"+a.replace("-","_")],style:t.style,styleSpec:n,objectElementValidators:_n});case"geojson":if(o=Jr({key:r,value:e,valueSpec:n.source_geojson,style:i,styleSpec:n,objectElementValidators:_n}),e.cluster)for(var s in e.clusterProperties){var l=e.clusterProperties[s],u=l[0],c="string"==typeof u?[u,["accumulated"],["get",s]]:u;o.push.apply(o,en({key:r+"."+s+".map",value:l[1],expressionContext:"cluster-map"})),o.push.apply(o,en({key:r+"."+s+".reduce",value:c,expressionContext:"cluster-reduce"}))}return o;case"video":return Jr({key:r,value:e,valueSpec:n.source_video,style:i,styleSpec:n});case"image":return Jr({key:r,value:e,valueSpec:n.source_image,style:i,styleSpec:n});case"canvas":return[new Dt(r,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return rn({key:r+".type",value:e.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]},style:i,styleSpec:n})}}function xn(t){var e=t.value,r=t.styleSpec,n=r.light,i=t.style,o=[],a=Lr(e);if(void 0===e)return o;if("object"!==a)return o.concat([new Dt("light",e,"object expected, "+a+" found")]);for(var s in e){var l=s.match(/^(.*)-transition$/);o=o.concat(l&&n[l[1]]&&n[l[1]].transition?En({key:s,value:e[s],valueSpec:r.transition,style:i,styleSpec:r}):n[s]?En({key:s,value:e[s],valueSpec:n[s],style:i,styleSpec:r}):[new Dt(s,e[s],'unknown property "'+s+'"')])}return o}var wn={"*":function(){return[]},array:Qr,boolean:function(t){var e=t.value,r=t.key,n=Lr(e);return"boolean"!==n?[new Dt(r,e,"boolean expected, "+n+" found")]:[]},number:$r,color:function(t){var e=t.key,r=t.value,n=Lr(r);return"string"!==n?[new Dt(e,r,"color expected, "+n+" found")]:null===$t(r)?[new Dt(e,r,'color expected, "'+r+'" found')]:[]},constants:Ot,enum:rn,filter:fn,function:tn,layer:yn,object:Jr,source:bn,light:xn,string:vn,formatted:function(t){return 0===vn(t).length?[]:en(t)},resolvedImage:function(t){return 0===vn(t).length?[]:en(t)}};function En(t){var e=t.value,r=t.valueSpec,n=t.styleSpec;return r.expression&&Rr(Bt(e))?tn(t):r.expression&&Gr(kt(e))?en(t):r.type&&wn[r.type]?wn[r.type](t):Jr(Mt({},t,{valueSpec:r.type?n[r.type]:r}))}function Tn(t){var e=t.value,r=t.key,n=vn(t);return n.length||(-1===e.indexOf("{fontstack}")&&n.push(new Dt(r,e,'"glyphs" url must include a "{fontstack}" token')),-1===e.indexOf("{range}")&&n.push(new Dt(r,e,'"glyphs" url must include a "{range}" token'))),n}function An(t,e){void 0===e&&(e=It);var r=[];return r=r.concat(En({key:"",value:t,valueSpec:e.$root,styleSpec:e,style:t,objectElementValidators:{glyphs:Tn,"*":function(){return[]}}})),t.constants&&(r=r.concat(Ot({key:"constants",value:t.constants,style:t,styleSpec:e}))),Cn(r)}function Cn(t){return[].concat(t).sort((function(t,e){return t.line-e.line}))}function Sn(t){return function(){for(var e=[],r=arguments.length;r--;)e[r]=arguments[r];return Cn(t.apply(this,e))}}An.source=Sn(bn),An.light=Sn(xn),An.layer=Sn(yn),An.filter=Sn(fn),An.paintProperty=Sn(mn),An.layoutProperty=Sn(gn);var Pn=An,In=Pn.light,Dn=Pn.paintProperty,On=Pn.layoutProperty;function Mn(t,e){var r=!1;if(e&&e.length)for(var n=0,i=e;n<i.length;n+=1)t.fire(new St(new Error(i[n].message))),r=!0;return r}var Bn=kn;function kn(t,e,r){var n=this.cells=[];if(t instanceof ArrayBuffer){this.arrayBuffer=t;var i=new Int32Array(this.arrayBuffer);t=i[0],this.d=(e=i[1])+2*(r=i[2]);for(var o=0;o<this.d*this.d;o++){var a=i[3+o],s=i[3+o+1];n.push(a===s?null:i.subarray(a,s))}var l=i[3+n.length+1];this.keys=i.subarray(i[3+n.length],l),this.bboxes=i.subarray(l),this.insert=this._insertReadonly}else{this.d=e+2*r;for(var u=0;u<this.d*this.d;u++)n.push([]);this.keys=[],this.bboxes=[]}this.n=e,this.extent=t,this.padding=r,this.scale=e/t,this.uid=0;var c=r/e*t;this.min=-c,this.max=t+c}kn.prototype.insert=function(t,e,r,n,i){this._forEachCell(e,r,n,i,this._insertCell,this.uid++),this.keys.push(t),this.bboxes.push(e),this.bboxes.push(r),this.bboxes.push(n),this.bboxes.push(i)},kn.prototype._insertReadonly=function(){throw"Cannot insert into a GridIndex created from an ArrayBuffer."},kn.prototype._insertCell=function(t,e,r,n,i,o){this.cells[i].push(o)},kn.prototype.query=function(t,e,r,n,i){var o=this.min,a=this.max;if(t<=o&&e<=o&&a<=r&&a<=n&&!i)return Array.prototype.slice.call(this.keys);var s=[];return this._forEachCell(t,e,r,n,this._queryCell,s,{},i),s},kn.prototype._queryCell=function(t,e,r,n,i,o,a,s){var l=this.cells[i];if(null!==l)for(var u=this.keys,c=this.bboxes,p=0;p<l.length;p++){var h=l[p];if(void 0===a[h]){var f=4*h;(s?s(c[f+0],c[f+1],c[f+2],c[f+3]):t<=c[f+2]&&e<=c[f+3]&&r>=c[f+0]&&n>=c[f+1])?(a[h]=!0,o.push(u[h])):a[h]=!1}}},kn.prototype._forEachCell=function(t,e,r,n,i,o,a,s){for(var l=this._convertToCellCoord(t),u=this._convertToCellCoord(e),c=this._convertToCellCoord(r),p=this._convertToCellCoord(n),h=l;h<=c;h++)for(var f=u;f<=p;f++){var d=this.d*f+h;if((!s||s(this._convertFromCellCoord(h),this._convertFromCellCoord(f),this._convertFromCellCoord(h+1),this._convertFromCellCoord(f+1)))&&i.call(this,t,e,r,n,d,o,a,s))return}},kn.prototype._convertFromCellCoord=function(t){return(t-this.padding)/this.scale},kn.prototype._convertToCellCoord=function(t){return Math.max(0,Math.min(this.d-1,Math.floor(t*this.scale)+this.padding))},kn.prototype.toArrayBuffer=function(){if(this.arrayBuffer)return this.arrayBuffer;for(var t=this.cells,e=3+this.cells.length+1+1,r=0,n=0;n<this.cells.length;n++)r+=this.cells[n].length;var i=new Int32Array(e+r+this.keys.length+this.bboxes.length);i[0]=this.extent,i[1]=this.n,i[2]=this.padding;for(var o=e,a=0;a<t.length;a++){var s=t[a];i[3+a]=o,i.set(s,o),o+=s.length}return i[3+t.length]=o,i.set(this.keys,o),i[3+t.length+1]=o+=this.keys.length,i.set(this.bboxes,o),o+=this.bboxes.length,i.buffer};var Fn=a.ImageData,Ln=a.ImageBitmap,Rn={};function zn(t,e,r){void 0===r&&(r={}),Object.defineProperty(e,"_classRegistryKey",{value:t,writeable:!1}),Rn[t]={klass:e,omit:r.omit||[],shallow:r.shallow||[]}}for(var Nn in zn("Object",Object),Bn.serialize=function(t,e){var r=t.toArrayBuffer();return e&&e.push(r),{buffer:r}},Bn.deserialize=function(t){return new Bn(t.buffer)},zn("Grid",Bn),zn("Color",te),zn("Error",Error),zn("ResolvedImage",ie),zn("StylePropertyFunction",Kr),zn("StyleExpression",Hr,{omit:["_evaluator"]}),zn("ZoomDependentExpression",Yr),zn("ZoomConstantExpression",Wr),zn("CompoundExpression",_e,{omit:["_evaluate"]}),Cr)Cr[Nn]._classRegistryKey||zn("Expression_"+Nn,Cr[Nn]);function jn(t){return t&&"undefined"!=typeof ArrayBuffer&&(t instanceof ArrayBuffer||t.constructor&&"ArrayBuffer"===t.constructor.name)}function Un(t){return Ln&&t instanceof Ln}function Vn(t,e){if(null==t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||t instanceof Boolean||t instanceof Number||t instanceof String||t instanceof Date||t instanceof RegExp)return t;if(jn(t)||Un(t))return e&&e.push(t),t;if(ArrayBuffer.isView(t)){var r=t;return e&&e.push(r.buffer),r}if(t instanceof Fn)return e&&e.push(t.data.buffer),t;if(Array.isArray(t)){for(var n=[],i=0,o=t;i<o.length;i+=1)n.push(Vn(o[i],e));return n}if("object"==typeof t){var a=t.constructor,s=a._classRegistryKey;if(!s)throw new Error("can't serialize object of unregistered class");var l=a.serialize?a.serialize(t,e):{};if(!a.serialize){for(var u in t)if(t.hasOwnProperty(u)&&!(Rn[s].omit.indexOf(u)>=0)){var c=t[u];l[u]=Rn[s].shallow.indexOf(u)>=0?c:Vn(c,e)}t instanceof Error&&(l.message=t.message)}if(l.$name)throw new Error("$name property is reserved for worker serialization logic.");return"Object"!==s&&(l.$name=s),l}throw new Error("can't serialize object of type "+typeof t)}function qn(t){if(null==t||"boolean"==typeof t||"number"==typeof t||"string"==typeof t||t instanceof Boolean||t instanceof Number||t instanceof String||t instanceof Date||t instanceof RegExp||jn(t)||Un(t)||ArrayBuffer.isView(t)||t instanceof Fn)return t;if(Array.isArray(t))return t.map(qn);if("object"==typeof t){var e=t.$name||"Object",r=Rn[e].klass;if(!r)throw new Error("can't deserialize unregistered class "+e);if(r.deserialize)return r.deserialize(t);for(var n=Object.create(r.prototype),i=0,o=Object.keys(t);i<o.length;i+=1){var a=o[i];if("$name"!==a){var s=t[a];n[a]=Rn[e].shallow.indexOf(a)>=0?s:qn(s)}}return n}throw new Error("can't deserialize object of type "+typeof t)}var Hn=function(){this.first=!0};Hn.prototype.update=function(t,e){var r=Math.floor(t);return this.first?(this.first=!1,this.lastIntegerZoom=r,this.lastIntegerZoomTime=0,this.lastZoom=t,this.lastFloorZoom=r,!0):(this.lastFloorZoom>r?(this.lastIntegerZoom=r+1,this.lastIntegerZoomTime=e):this.lastFloorZoom<r&&(this.lastIntegerZoom=r,this.lastIntegerZoomTime=e),t!==this.lastZoom&&(this.lastZoom=t,this.lastFloorZoom=r,!0))};var Gn={"Latin-1 Supplement":function(t){return t>=128&&t<=255},Arabic:function(t){return t>=1536&&t<=1791},"Arabic Supplement":function(t){return t>=1872&&t<=1919},"Arabic Extended-A":function(t){return t>=2208&&t<=2303},"Hangul Jamo":function(t){return t>=4352&&t<=4607},"Unified Canadian Aboriginal Syllabics":function(t){return t>=5120&&t<=5759},Khmer:function(t){return t>=6016&&t<=6143},"Unified Canadian Aboriginal Syllabics Extended":function(t){return t>=6320&&t<=6399},"General Punctuation":function(t){return t>=8192&&t<=8303},"Letterlike Symbols":function(t){return t>=8448&&t<=8527},"Number Forms":function(t){return t>=8528&&t<=8591},"Miscellaneous Technical":function(t){return t>=8960&&t<=9215},"Control Pictures":function(t){return t>=9216&&t<=9279},"Optical Character Recognition":function(t){return t>=9280&&t<=9311},"Enclosed Alphanumerics":function(t){return t>=9312&&t<=9471},"Geometric Shapes":function(t){return t>=9632&&t<=9727},"Miscellaneous Symbols":function(t){return t>=9728&&t<=9983},"Miscellaneous Symbols and Arrows":function(t){return t>=11008&&t<=11263},"CJK Radicals Supplement":function(t){return t>=11904&&t<=12031},"Kangxi Radicals":function(t){return t>=12032&&t<=12255},"Ideographic Description Characters":function(t){return t>=12272&&t<=12287},"CJK Symbols and Punctuation":function(t){return t>=12288&&t<=12351},Hiragana:function(t){return t>=12352&&t<=12447},Katakana:function(t){return t>=12448&&t<=12543},Bopomofo:function(t){return t>=12544&&t<=12591},"Hangul Compatibility Jamo":function(t){return t>=12592&&t<=12687},Kanbun:function(t){return t>=12688&&t<=12703},"Bopomofo Extended":function(t){return t>=12704&&t<=12735},"CJK Strokes":function(t){return t>=12736&&t<=12783},"Katakana Phonetic Extensions":function(t){return t>=12784&&t<=12799},"Enclosed CJK Letters and Months":function(t){return t>=12800&&t<=13055},"CJK Compatibility":function(t){return t>=13056&&t<=13311},"CJK Unified Ideographs Extension A":function(t){return t>=13312&&t<=19903},"Yijing Hexagram Symbols":function(t){return t>=19904&&t<=19967},"CJK Unified Ideographs":function(t){return t>=19968&&t<=40959},"Yi Syllables":function(t){return t>=40960&&t<=42127},"Yi Radicals":function(t){return t>=42128&&t<=42191},"Hangul Jamo Extended-A":function(t){return t>=43360&&t<=43391},"Hangul Syllables":function(t){return t>=44032&&t<=55215},"Hangul Jamo Extended-B":function(t){return t>=55216&&t<=55295},"Private Use Area":function(t){return t>=57344&&t<=63743},"CJK Compatibility Ideographs":function(t){return t>=63744&&t<=64255},"Arabic Presentation Forms-A":function(t){return t>=64336&&t<=65023},"Vertical Forms":function(t){return t>=65040&&t<=65055},"CJK Compatibility Forms":function(t){return t>=65072&&t<=65103},"Small Form Variants":function(t){return t>=65104&&t<=65135},"Arabic Presentation Forms-B":function(t){return t>=65136&&t<=65279},"Halfwidth and Fullwidth Forms":function(t){return t>=65280&&t<=65519}};function Zn(t){for(var e=0,r=t;e<r.length;e+=1)if(Wn(r[e].charCodeAt(0)))return!0;return!1}function Wn(t){return!(746!==t&&747!==t&&(t<4352||!(Gn["Bopomofo Extended"](t)||Gn.Bopomofo(t)||Gn["CJK Compatibility Forms"](t)&&!(t>=65097&&t<=65103)||Gn["CJK Compatibility Ideographs"](t)||Gn["CJK Compatibility"](t)||Gn["CJK Radicals Supplement"](t)||Gn["CJK Strokes"](t)||!(!Gn["CJK Symbols and Punctuation"](t)||t>=12296&&t<=12305||t>=12308&&t<=12319||12336===t)||Gn["CJK Unified Ideographs Extension A"](t)||Gn["CJK Unified Ideographs"](t)||Gn["Enclosed CJK Letters and Months"](t)||Gn["Hangul Compatibility Jamo"](t)||Gn["Hangul Jamo Extended-A"](t)||Gn["Hangul Jamo Extended-B"](t)||Gn["Hangul Jamo"](t)||Gn["Hangul Syllables"](t)||Gn.Hiragana(t)||Gn["Ideographic Description Characters"](t)||Gn.Kanbun(t)||Gn["Kangxi Radicals"](t)||Gn["Katakana Phonetic Extensions"](t)||Gn.Katakana(t)&&12540!==t||!(!Gn["Halfwidth and Fullwidth Forms"](t)||65288===t||65289===t||65293===t||t>=65306&&t<=65310||65339===t||65341===t||65343===t||t>=65371&&t<=65503||65507===t||t>=65512&&t<=65519)||!(!Gn["Small Form Variants"](t)||t>=65112&&t<=65118||t>=65123&&t<=65126)||Gn["Unified Canadian Aboriginal Syllabics"](t)||Gn["Unified Canadian Aboriginal Syllabics Extended"](t)||Gn["Vertical Forms"](t)||Gn["Yijing Hexagram Symbols"](t)||Gn["Yi Syllables"](t)||Gn["Yi Radicals"](t))))}function Yn(t){return!(Wn(t)||function(t){return!!(Gn["Latin-1 Supplement"](t)&&(167===t||169===t||174===t||177===t||188===t||189===t||190===t||215===t||247===t)||Gn["General Punctuation"](t)&&(8214===t||8224===t||8225===t||8240===t||8241===t||8251===t||8252===t||8258===t||8263===t||8264===t||8265===t||8273===t)||Gn["Letterlike Symbols"](t)||Gn["Number Forms"](t)||Gn["Miscellaneous Technical"](t)&&(t>=8960&&t<=8967||t>=8972&&t<=8991||t>=8996&&t<=9e3||9003===t||t>=9085&&t<=9114||t>=9150&&t<=9165||9167===t||t>=9169&&t<=9179||t>=9186&&t<=9215)||Gn["Control Pictures"](t)&&9251!==t||Gn["Optical Character Recognition"](t)||Gn["Enclosed Alphanumerics"](t)||Gn["Geometric Shapes"](t)||Gn["Miscellaneous Symbols"](t)&&!(t>=9754&&t<=9759)||Gn["Miscellaneous Symbols and Arrows"](t)&&(t>=11026&&t<=11055||t>=11088&&t<=11097||t>=11192&&t<=11243)||Gn["CJK Symbols and Punctuation"](t)||Gn.Katakana(t)||Gn["Private Use Area"](t)||Gn["CJK Compatibility Forms"](t)||Gn["Small Form Variants"](t)||Gn["Halfwidth and Fullwidth Forms"](t)||8734===t||8756===t||8757===t||t>=9984&&t<=10087||t>=10102&&t<=10131||65532===t||65533===t)}(t))}function Xn(t){return t>=1424&&t<=2303||Gn["Arabic Presentation Forms-A"](t)||Gn["Arabic Presentation Forms-B"](t)}function Kn(t,e){return!(!e&&Xn(t)||t>=2304&&t<=3583||t>=3840&&t<=4255||Gn.Khmer(t))}function Jn(t){for(var e=0,r=t;e<r.length;e+=1)if(Xn(r[e].charCodeAt(0)))return!0;return!1}var Qn=null,$n="unavailable",ti=null,ei=function(t){t&&"string"==typeof t&&t.indexOf("NetworkError")>-1&&($n="error"),Qn&&Qn(t)};function ri(){ni.fire(new Ct("pluginStateChange",{pluginStatus:$n,pluginURL:ti}))}var ni=new Pt,ii=function(){return $n},oi=function(){if("deferred"!==$n||!ti)throw new Error("rtl-text-plugin cannot be downloaded unless a pluginURL is specified");$n="loading",ri(),ti&&bt({url:ti},(function(t){t?ei(t):($n="loaded",ri())}))},ai={applyArabicShaping:null,processBidirectionalText:null,processStyledBidirectionalText:null,isLoaded:function(){return"loaded"===$n||null!=ai.applyArabicShaping},isLoading:function(){return"loading"===$n},setState:function(t){$n=t.pluginStatus,ti=t.pluginURL},isParsed:function(){return null!=ai.applyArabicShaping&&null!=ai.processBidirectionalText&&null!=ai.processStyledBidirectionalText},getPluginURL:function(){return ti}},si=function(t,e){this.zoom=t,e?(this.now=e.now,this.fadeDuration=e.fadeDuration,this.zoomHistory=e.zoomHistory,this.transition=e.transition):(this.now=0,this.fadeDuration=0,this.zoomHistory=new Hn,this.transition={})};si.prototype.isSupportedScript=function(t){return function(t,e){for(var r=0,n=t;r<n.length;r+=1)if(!Kn(n[r].charCodeAt(0),e))return!1;return!0}(t,ai.isLoaded())},si.prototype.crossFadingFactor=function(){return 0===this.fadeDuration?1:Math.min((this.now-this.zoomHistory.lastIntegerZoomTime)/this.fadeDuration,1)},si.prototype.getCrossfadeParameters=function(){var t=this.zoom,e=t-Math.floor(t),r=this.crossFadingFactor();return t>this.zoomHistory.lastIntegerZoom?{fromScale:2,toScale:1,t:e+(1-e)*r}:{fromScale:.5,toScale:1,t:1-(1-r)*e}};var li=function(t,e){this.property=t,this.value=e,this.expression=function(t,e){if(Rr(t))return new Kr(t,e);if(Gr(t)){var r=Xr(t,e);if("error"===r.result)throw new Error(r.value.map((function(t){return t.key+": "+t.message})).join(", "));return r.value}var n=t;return"string"==typeof t&&"color"===e.type&&(n=te.parse(t)),{kind:"constant",evaluate:function(){return n}}}(void 0===e?t.specification.default:e,t.specification)};li.prototype.isDataDriven=function(){return"source"===this.expression.kind||"composite"===this.expression.kind},li.prototype.possiblyEvaluate=function(t,e,r){return this.property.possiblyEvaluate(this,t,e,r)};var ui=function(t){this.property=t,this.value=new li(t,void 0)};ui.prototype.transitioned=function(t,e){return new pi(this.property,this.value,e,h({},t.transition,this.transition),t.now)},ui.prototype.untransitioned=function(){return new pi(this.property,this.value,null,{},0)};var ci=function(t){this._properties=t,this._values=Object.create(t.defaultTransitionablePropertyValues)};ci.prototype.getValue=function(t){return x(this._values[t].value.value)},ci.prototype.setValue=function(t,e){this._values.hasOwnProperty(t)||(this._values[t]=new ui(this._values[t].property)),this._values[t].value=new li(this._values[t].property,null===e?void 0:x(e))},ci.prototype.getTransition=function(t){return x(this._values[t].transition)},ci.prototype.setTransition=function(t,e){this._values.hasOwnProperty(t)||(this._values[t]=new ui(this._values[t].property)),this._values[t].transition=x(e)||void 0},ci.prototype.serialize=function(){for(var t={},e=0,r=Object.keys(this._values);e<r.length;e+=1){var n=r[e],i=this.getValue(n);void 0!==i&&(t[n]=i);var o=this.getTransition(n);void 0!==o&&(t[n+"-transition"]=o)}return t},ci.prototype.transitioned=function(t,e){for(var r=new hi(this._properties),n=0,i=Object.keys(this._values);n<i.length;n+=1){var o=i[n];r._values[o]=this._values[o].transitioned(t,e._values[o])}return r},ci.prototype.untransitioned=function(){for(var t=new hi(this._properties),e=0,r=Object.keys(this._values);e<r.length;e+=1){var n=r[e];t._values[n]=this._values[n].untransitioned()}return t};var pi=function(t,e,r,n,i){this.property=t,this.value=e,this.begin=i+n.delay||0,this.end=this.begin+n.duration||0,t.specification.transition&&(n.delay||n.duration)&&(this.prior=r)};pi.prototype.possiblyEvaluate=function(t,e,r){var n=t.now||0,i=this.value.possiblyEvaluate(t,e,r),o=this.prior;if(o){if(n>this.end)return this.prior=null,i;if(this.value.isDataDriven())return this.prior=null,i;if(n<this.begin)return o.possiblyEvaluate(t,e,r);var a=(n-this.begin)/(this.end-this.begin);return this.property.interpolate(o.possiblyEvaluate(t,e,r),i,function(t){if(t<=0)return 0;if(t>=1)return 1;var e=t*t,r=e*t;return 4*(t<.5?r:3*(t-e)+r-.75)}(a))}return i};var hi=function(t){this._properties=t,this._values=Object.create(t.defaultTransitioningPropertyValues)};hi.prototype.possiblyEvaluate=function(t,e,r){for(var n=new mi(this._properties),i=0,o=Object.keys(this._values);i<o.length;i+=1){var a=o[i];n._values[a]=this._values[a].possiblyEvaluate(t,e,r)}return n},hi.prototype.hasTransition=function(){for(var t=0,e=Object.keys(this._values);t<e.length;t+=1)if(this._values[e[t]].prior)return!0;return!1};var fi=function(t){this._properties=t,this._values=Object.create(t.defaultPropertyValues)};fi.prototype.getValue=function(t){return x(this._values[t].value)},fi.prototype.setValue=function(t,e){this._values[t]=new li(this._values[t].property,null===e?void 0:x(e))},fi.prototype.serialize=function(){for(var t={},e=0,r=Object.keys(this._values);e<r.length;e+=1){var n=r[e],i=this.getValue(n);void 0!==i&&(t[n]=i)}return t},fi.prototype.possiblyEvaluate=function(t,e,r){for(var n=new mi(this._properties),i=0,o=Object.keys(this._values);i<o.length;i+=1){var a=o[i];n._values[a]=this._values[a].possiblyEvaluate(t,e,r)}return n};var di=function(t,e,r){this.property=t,this.value=e,this.parameters=r};di.prototype.isConstant=function(){return"constant"===this.value.kind},di.prototype.constantOr=function(t){return"constant"===this.value.kind?this.value.value:t},di.prototype.evaluate=function(t,e,r,n){return this.property.evaluate(this.value,this.parameters,t,e,r,n)};var mi=function(t){this._properties=t,this._values=Object.create(t.defaultPossiblyEvaluatedValues)};mi.prototype.get=function(t){return this._values[t]};var gi=function(t){this.specification=t};gi.prototype.possiblyEvaluate=function(t,e){return t.expression.evaluate(e)},gi.prototype.interpolate=function(t,e,r){var n=Ge[this.specification.type];return n?n(t,e,r):t};var yi=function(t,e){this.specification=t,this.overrides=e};yi.prototype.possiblyEvaluate=function(t,e,r,n){return new di(this,"constant"===t.expression.kind||"camera"===t.expression.kind?{kind:"constant",value:t.expression.evaluate(e,null,{},r,n)}:t.expression,e)},yi.prototype.interpolate=function(t,e,r){if("constant"!==t.value.kind||"constant"!==e.value.kind)return t;if(void 0===t.value.value||void 0===e.value.value)return new di(this,{kind:"constant",value:void 0},t.parameters);var n=Ge[this.specification.type];return n?new di(this,{kind:"constant",value:n(t.value.value,e.value.value,r)},t.parameters):t},yi.prototype.evaluate=function(t,e,r,n,i,o){return"constant"===t.kind?t.value:t.evaluate(e,r,n,i,o)};var vi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.possiblyEvaluate=function(t,e,r,n){if(void 0===t.value)return new di(this,{kind:"constant",value:void 0},e);if("constant"===t.expression.kind){var i=t.expression.evaluate(e,null,{},r,n),o="resolvedImage"===t.property.specification.type&&"string"!=typeof i?i.name:i,a=this._calculate(o,o,o,e);return new di(this,{kind:"constant",value:a},e)}if("camera"===t.expression.kind){var s=this._calculate(t.expression.evaluate({zoom:e.zoom-1}),t.expression.evaluate({zoom:e.zoom}),t.expression.evaluate({zoom:e.zoom+1}),e);return new di(this,{kind:"constant",value:s},e)}return new di(this,t.expression,e)},e.prototype.evaluate=function(t,e,r,n,i,o){if("source"===t.kind){var a=t.evaluate(e,r,n,i,o);return this._calculate(a,a,a,e)}return"composite"===t.kind?this._calculate(t.evaluate({zoom:Math.floor(e.zoom)-1},r,n),t.evaluate({zoom:Math.floor(e.zoom)},r,n),t.evaluate({zoom:Math.floor(e.zoom)+1},r,n),e):t.value},e.prototype._calculate=function(t,e,r,n){return n.zoom>n.zoomHistory.lastIntegerZoom?{from:t,to:e}:{from:r,to:e}},e.prototype.interpolate=function(t){return t},e}(yi),_i=function(t){this.specification=t};_i.prototype.possiblyEvaluate=function(t,e,r,n){if(void 0!==t.value){if("constant"===t.expression.kind){var i=t.expression.evaluate(e,null,{},r,n);return this._calculate(i,i,i,e)}return this._calculate(t.expression.evaluate(new si(Math.floor(e.zoom-1),e)),t.expression.evaluate(new si(Math.floor(e.zoom),e)),t.expression.evaluate(new si(Math.floor(e.zoom+1),e)),e)}},_i.prototype._calculate=function(t,e,r,n){return n.zoom>n.zoomHistory.lastIntegerZoom?{from:t,to:e}:{from:r,to:e}},_i.prototype.interpolate=function(t){return t};var bi=function(t){this.specification=t};bi.prototype.possiblyEvaluate=function(t,e,r,n){return!!t.expression.evaluate(e,null,{},r,n)},bi.prototype.interpolate=function(){return!1};var xi=function(t){for(var e in this.properties=t,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},this.overridableProperties=[],t){var r=t[e];r.specification.overridable&&this.overridableProperties.push(e);var n=this.defaultPropertyValues[e]=new li(r,void 0),i=this.defaultTransitionablePropertyValues[e]=new ui(r);this.defaultTransitioningPropertyValues[e]=i.untransitioned(),this.defaultPossiblyEvaluatedValues[e]=n.possiblyEvaluate({})}};zn("DataDrivenProperty",yi),zn("DataConstantProperty",gi),zn("CrossFadedDataDrivenProperty",vi),zn("CrossFadedProperty",_i),zn("ColorRampProperty",bi);var wi=function(t){function e(e,r){if(t.call(this),this.id=e.id,this.type=e.type,this._featureFilter={filter:function(){return!0},needGeometry:!1},"custom"!==e.type&&(this.metadata=(e=e).metadata,this.minzoom=e.minzoom,this.maxzoom=e.maxzoom,"background"!==e.type&&(this.source=e.source,this.sourceLayer=e["source-layer"],this.filter=e.filter),r.layout&&(this._unevaluatedLayout=new fi(r.layout)),r.paint)){for(var n in this._transitionablePaint=new ci(r.paint),e.paint)this.setPaintProperty(n,e.paint[n],{validate:!1});for(var i in e.layout)this.setLayoutProperty(i,e.layout[i],{validate:!1});this._transitioningPaint=this._transitionablePaint.untransitioned(),this.paint=new mi(r.paint)}}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getCrossfadeParameters=function(){return this._crossfadeParameters},e.prototype.getLayoutProperty=function(t){return"visibility"===t?this.visibility:this._unevaluatedLayout.getValue(t)},e.prototype.setLayoutProperty=function(t,e,r){void 0===r&&(r={}),null!=e&&this._validate(On,"layers."+this.id+".layout."+t,t,e,r)||("visibility"!==t?this._unevaluatedLayout.setValue(t,e):this.visibility=e)},e.prototype.getPaintProperty=function(t){return v(t,"-transition")?this._transitionablePaint.getTransition(t.slice(0,-"-transition".length)):this._transitionablePaint.getValue(t)},e.prototype.setPaintProperty=function(t,e,r){if(void 0===r&&(r={}),null!=e&&this._validate(Dn,"layers."+this.id+".paint."+t,t,e,r))return!1;if(v(t,"-transition"))return this._transitionablePaint.setTransition(t.slice(0,-"-transition".length),e||void 0),!1;var n=this._transitionablePaint._values[t],i="cross-faded-data-driven"===n.property.specification["property-type"],o=n.value.isDataDriven(),a=n.value;this._transitionablePaint.setValue(t,e),this._handleSpecialPaintPropertyUpdate(t);var s=this._transitionablePaint._values[t].value;return s.isDataDriven()||o||i||this._handleOverridablePaintPropertyUpdate(t,a,s)},e.prototype._handleSpecialPaintPropertyUpdate=function(t){},e.prototype._handleOverridablePaintPropertyUpdate=function(t,e,r){return!1},e.prototype.isHidden=function(t){return!!(this.minzoom&&t<this.minzoom)||!!(this.maxzoom&&t>=this.maxzoom)||"none"===this.visibility},e.prototype.updateTransitions=function(t){this._transitioningPaint=this._transitionablePaint.transitioned(t,this._transitioningPaint)},e.prototype.hasTransition=function(){return this._transitioningPaint.hasTransition()},e.prototype.recalculate=function(t,e){t.getCrossfadeParameters&&(this._crossfadeParameters=t.getCrossfadeParameters()),this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(t,void 0,e)),this.paint=this._transitioningPaint.possiblyEvaluate(t,void 0,e)},e.prototype.serialize=function(){var t={id:this.id,type:this.type,source:this.source,"source-layer":this.sourceLayer,metadata:this.metadata,minzoom:this.minzoom,maxzoom:this.maxzoom,filter:this.filter,layout:this._unevaluatedLayout&&this._unevaluatedLayout.serialize(),paint:this._transitionablePaint&&this._transitionablePaint.serialize()};return this.visibility&&(t.layout=t.layout||{},t.layout.visibility=this.visibility),b(t,(function(t,e){return!(void 0===t||"layout"===e&&!Object.keys(t).length||"paint"===e&&!Object.keys(t).length)}))},e.prototype._validate=function(t,e,r,n,i){return void 0===i&&(i={}),(!i||!1!==i.validate)&&Mn(this,t.call(Pn,{key:e,layerType:this.type,objectKey:r,value:n,styleSpec:It,style:{glyphs:!0,sprite:!0}}))},e.prototype.is3D=function(){return!1},e.prototype.isTileClipped=function(){return!1},e.prototype.hasOffscreenPass=function(){return!1},e.prototype.resize=function(){},e.prototype.isStateDependent=function(){for(var t in this.paint._values){var e=this.paint.get(t);if(e instanceof di&&Br(e.property.specification)&&("source"===e.value.kind||"composite"===e.value.kind)&&e.value.isStateDependent)return!0}return!1},e}(Pt),Ei={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array},Ti=function(t,e){this._structArray=t,this._pos1=e*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8},Ai=function(){this.isTransferred=!1,this.capacity=-1,this.resize(0)};function Ci(t,e){void 0===e&&(e=1);var r=0,n=0;return{members:t.map((function(t){var i=Ei[t.type].BYTES_PER_ELEMENT,o=r=Si(r,Math.max(e,i)),a=t.components||1;return n=Math.max(n,i),r+=i*a,{name:t.name,type:t.type,components:a,offset:o}})),size:Si(r,Math.max(n,e)),alignment:e}}function Si(t,e){return Math.ceil(t/e)*e}Ai.serialize=function(t,e){return t._trim(),e&&(t.isTransferred=!0,e.push(t.arrayBuffer)),{length:t.length,arrayBuffer:t.arrayBuffer}},Ai.deserialize=function(t){var e=Object.create(this.prototype);return e.arrayBuffer=t.arrayBuffer,e.length=t.length,e.capacity=t.arrayBuffer.byteLength/e.bytesPerElement,e._refreshViews(),e},Ai.prototype._trim=function(){this.length!==this.capacity&&(this.capacity=this.length,this.arrayBuffer=this.arrayBuffer.slice(0,this.length*this.bytesPerElement),this._refreshViews())},Ai.prototype.clear=function(){this.length=0},Ai.prototype.resize=function(t){this.reserve(t),this.length=t},Ai.prototype.reserve=function(t){if(t>this.capacity){this.capacity=Math.max(t,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);var e=this.uint8;this._refreshViews(),e&&this.uint8.set(e)}},Ai.prototype._refreshViews=function(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")};var Pi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e){var r=this.length;return this.resize(r+1),this.emplace(r,t,e)},e.prototype.emplace=function(t,e,r){var n=2*t;return this.int16[n+0]=e,this.int16[n+1]=r,t},e}(Ai);Pi.prototype.bytesPerElement=4,zn("StructArrayLayout2i4",Pi);var Ii=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n){var i=this.length;return this.resize(i+1),this.emplace(i,t,e,r,n)},e.prototype.emplace=function(t,e,r,n,i){var o=4*t;return this.int16[o+0]=e,this.int16[o+1]=r,this.int16[o+2]=n,this.int16[o+3]=i,t},e}(Ai);Ii.prototype.bytesPerElement=8,zn("StructArrayLayout4i8",Ii);var Di=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o){var a=this.length;return this.resize(a+1),this.emplace(a,t,e,r,n,i,o)},e.prototype.emplace=function(t,e,r,n,i,o,a){var s=6*t;return this.int16[s+0]=e,this.int16[s+1]=r,this.int16[s+2]=n,this.int16[s+3]=i,this.int16[s+4]=o,this.int16[s+5]=a,t},e}(Ai);Di.prototype.bytesPerElement=12,zn("StructArrayLayout2i4i12",Di);var Oi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o){var a=this.length;return this.resize(a+1),this.emplace(a,t,e,r,n,i,o)},e.prototype.emplace=function(t,e,r,n,i,o,a){var s=4*t,l=8*t;return this.int16[s+0]=e,this.int16[s+1]=r,this.uint8[l+4]=n,this.uint8[l+5]=i,this.uint8[l+6]=o,this.uint8[l+7]=a,t},e}(Ai);Oi.prototype.bytesPerElement=8,zn("StructArrayLayout2i4ub8",Oi);var Mi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e){var r=this.length;return this.resize(r+1),this.emplace(r,t,e)},e.prototype.emplace=function(t,e,r){var n=2*t;return this.float32[n+0]=e,this.float32[n+1]=r,t},e}(Ai);Mi.prototype.bytesPerElement=8,zn("StructArrayLayout2f8",Mi);var Bi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o,a,s,l,u){var c=this.length;return this.resize(c+1),this.emplace(c,t,e,r,n,i,o,a,s,l,u)},e.prototype.emplace=function(t,e,r,n,i,o,a,s,l,u,c){var p=10*t;return this.uint16[p+0]=e,this.uint16[p+1]=r,this.uint16[p+2]=n,this.uint16[p+3]=i,this.uint16[p+4]=o,this.uint16[p+5]=a,this.uint16[p+6]=s,this.uint16[p+7]=l,this.uint16[p+8]=u,this.uint16[p+9]=c,t},e}(Ai);Bi.prototype.bytesPerElement=20,zn("StructArrayLayout10ui20",Bi);var ki=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o,a,s,l,u,c,p){var h=this.length;return this.resize(h+1),this.emplace(h,t,e,r,n,i,o,a,s,l,u,c,p)},e.prototype.emplace=function(t,e,r,n,i,o,a,s,l,u,c,p,h){var f=12*t;return this.int16[f+0]=e,this.int16[f+1]=r,this.int16[f+2]=n,this.int16[f+3]=i,this.uint16[f+4]=o,this.uint16[f+5]=a,this.uint16[f+6]=s,this.uint16[f+7]=l,this.int16[f+8]=u,this.int16[f+9]=c,this.int16[f+10]=p,this.int16[f+11]=h,t},e}(Ai);ki.prototype.bytesPerElement=24,zn("StructArrayLayout4i4ui4i24",ki);var Fi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r){var n=this.length;return this.resize(n+1),this.emplace(n,t,e,r)},e.prototype.emplace=function(t,e,r,n){var i=3*t;return this.float32[i+0]=e,this.float32[i+1]=r,this.float32[i+2]=n,t},e}(Ai);Fi.prototype.bytesPerElement=12,zn("StructArrayLayout3f12",Fi);var Li=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t){var e=this.length;return this.resize(e+1),this.emplace(e,t)},e.prototype.emplace=function(t,e){return this.uint32[1*t+0]=e,t},e}(Ai);Li.prototype.bytesPerElement=4,zn("StructArrayLayout1ul4",Li);var Ri=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o,a,s,l){var u=this.length;return this.resize(u+1),this.emplace(u,t,e,r,n,i,o,a,s,l)},e.prototype.emplace=function(t,e,r,n,i,o,a,s,l,u){var c=10*t,p=5*t;return this.int16[c+0]=e,this.int16[c+1]=r,this.int16[c+2]=n,this.int16[c+3]=i,this.int16[c+4]=o,this.int16[c+5]=a,this.uint32[p+3]=s,this.uint16[c+8]=l,this.uint16[c+9]=u,t},e}(Ai);Ri.prototype.bytesPerElement=20,zn("StructArrayLayout6i1ul2ui20",Ri);var zi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o){var a=this.length;return this.resize(a+1),this.emplace(a,t,e,r,n,i,o)},e.prototype.emplace=function(t,e,r,n,i,o,a){var s=6*t;return this.int16[s+0]=e,this.int16[s+1]=r,this.int16[s+2]=n,this.int16[s+3]=i,this.int16[s+4]=o,this.int16[s+5]=a,t},e}(Ai);zi.prototype.bytesPerElement=12,zn("StructArrayLayout2i2i2i12",zi);var Ni=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i){var o=this.length;return this.resize(o+1),this.emplace(o,t,e,r,n,i)},e.prototype.emplace=function(t,e,r,n,i,o){var a=4*t,s=8*t;return this.float32[a+0]=e,this.float32[a+1]=r,this.float32[a+2]=n,this.int16[s+6]=i,this.int16[s+7]=o,t},e}(Ai);Ni.prototype.bytesPerElement=16,zn("StructArrayLayout2f1f2i16",Ni);var ji=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n){var i=this.length;return this.resize(i+1),this.emplace(i,t,e,r,n)},e.prototype.emplace=function(t,e,r,n,i){var o=12*t,a=3*t;return this.uint8[o+0]=e,this.uint8[o+1]=r,this.float32[a+1]=n,this.float32[a+2]=i,t},e}(Ai);ji.prototype.bytesPerElement=12,zn("StructArrayLayout2ub2f12",ji);var Ui=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r){var n=this.length;return this.resize(n+1),this.emplace(n,t,e,r)},e.prototype.emplace=function(t,e,r,n){var i=3*t;return this.uint16[i+0]=e,this.uint16[i+1]=r,this.uint16[i+2]=n,t},e}(Ai);Ui.prototype.bytesPerElement=6,zn("StructArrayLayout3ui6",Ui);var Vi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g){var y=this.length;return this.resize(y+1),this.emplace(y,t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g)},e.prototype.emplace=function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g,y){var v=24*t,_=12*t,b=48*t;return this.int16[v+0]=e,this.int16[v+1]=r,this.uint16[v+2]=n,this.uint16[v+3]=i,this.uint32[_+2]=o,this.uint32[_+3]=a,this.uint32[_+4]=s,this.uint16[v+10]=l,this.uint16[v+11]=u,this.uint16[v+12]=c,this.float32[_+7]=p,this.float32[_+8]=h,this.uint8[b+36]=f,this.uint8[b+37]=d,this.uint8[b+38]=m,this.uint32[_+10]=g,this.int16[v+22]=y,t},e}(Ai);Vi.prototype.bytesPerElement=48,zn("StructArrayLayout2i2ui3ul3ui2f3ub1ul1i48",Vi);var qi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g,y,v,_,b,x,w,E,T,A,C,S){var P=this.length;return this.resize(P+1),this.emplace(P,t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g,y,v,_,b,x,w,E,T,A,C,S)},e.prototype.emplace=function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g,y,v,_,b,x,w,E,T,A,C,S,P){var I=34*t,D=17*t;return this.int16[I+0]=e,this.int16[I+1]=r,this.int16[I+2]=n,this.int16[I+3]=i,this.int16[I+4]=o,this.int16[I+5]=a,this.int16[I+6]=s,this.int16[I+7]=l,this.uint16[I+8]=u,this.uint16[I+9]=c,this.uint16[I+10]=p,this.uint16[I+11]=h,this.uint16[I+12]=f,this.uint16[I+13]=d,this.uint16[I+14]=m,this.uint16[I+15]=g,this.uint16[I+16]=y,this.uint16[I+17]=v,this.uint16[I+18]=_,this.uint16[I+19]=b,this.uint16[I+20]=x,this.uint16[I+21]=w,this.uint16[I+22]=E,this.uint32[D+12]=T,this.float32[D+13]=A,this.float32[D+14]=C,this.float32[D+15]=S,this.float32[D+16]=P,t},e}(Ai);qi.prototype.bytesPerElement=68,zn("StructArrayLayout8i15ui1ul4f68",qi);var Hi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t){var e=this.length;return this.resize(e+1),this.emplace(e,t)},e.prototype.emplace=function(t,e){return this.float32[1*t+0]=e,t},e}(Ai);Hi.prototype.bytesPerElement=4,zn("StructArrayLayout1f4",Hi);var Gi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r){var n=this.length;return this.resize(n+1),this.emplace(n,t,e,r)},e.prototype.emplace=function(t,e,r,n){var i=3*t;return this.int16[i+0]=e,this.int16[i+1]=r,this.int16[i+2]=n,t},e}(Ai);Gi.prototype.bytesPerElement=6,zn("StructArrayLayout3i6",Gi);var Zi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r){var n=this.length;return this.resize(n+1),this.emplace(n,t,e,r)},e.prototype.emplace=function(t,e,r,n){var i=4*t;return this.uint32[2*t+0]=e,this.uint16[i+2]=r,this.uint16[i+3]=n,t},e}(Ai);Zi.prototype.bytesPerElement=8,zn("StructArrayLayout1ul2ui8",Zi);var Wi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e){var r=this.length;return this.resize(r+1),this.emplace(r,t,e)},e.prototype.emplace=function(t,e,r){var n=2*t;return this.uint16[n+0]=e,this.uint16[n+1]=r,t},e}(Ai);Wi.prototype.bytesPerElement=4,zn("StructArrayLayout2ui4",Wi);var Yi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t){var e=this.length;return this.resize(e+1),this.emplace(e,t)},e.prototype.emplace=function(t,e){return this.uint16[1*t+0]=e,t},e}(Ai);Yi.prototype.bytesPerElement=2,zn("StructArrayLayout1ui2",Yi);var Xi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._refreshViews=function(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)},e.prototype.emplaceBack=function(t,e,r,n){var i=this.length;return this.resize(i+1),this.emplace(i,t,e,r,n)},e.prototype.emplace=function(t,e,r,n,i){var o=4*t;return this.float32[o+0]=e,this.float32[o+1]=r,this.float32[o+2]=n,this.float32[o+3]=i,t},e}(Ai);Xi.prototype.bytesPerElement=16,zn("StructArrayLayout4f16",Xi);var Ki=function(t){function e(){t.apply(this,arguments)}t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e;var r={anchorPointX:{configurable:!0},anchorPointY:{configurable:!0},x1:{configurable:!0},y1:{configurable:!0},x2:{configurable:!0},y2:{configurable:!0},featureIndex:{configurable:!0},sourceLayerIndex:{configurable:!0},bucketIndex:{configurable:!0},anchorPoint:{configurable:!0}};return r.anchorPointX.get=function(){return this._structArray.int16[this._pos2+0]},r.anchorPointY.get=function(){return this._structArray.int16[this._pos2+1]},r.x1.get=function(){return this._structArray.int16[this._pos2+2]},r.y1.get=function(){return this._structArray.int16[this._pos2+3]},r.x2.get=function(){return this._structArray.int16[this._pos2+4]},r.y2.get=function(){return this._structArray.int16[this._pos2+5]},r.featureIndex.get=function(){return this._structArray.uint32[this._pos4+3]},r.sourceLayerIndex.get=function(){return this._structArray.uint16[this._pos2+8]},r.bucketIndex.get=function(){return this._structArray.uint16[this._pos2+9]},r.anchorPoint.get=function(){return new i(this.anchorPointX,this.anchorPointY)},Object.defineProperties(e.prototype,r),e}(Ti);Ki.prototype.size=20;var Ji=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.get=function(t){return new Ki(this,t)},e}(Ri);zn("CollisionBoxArray",Ji);var Qi=function(t){function e(){t.apply(this,arguments)}t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e;var r={anchorX:{configurable:!0},anchorY:{configurable:!0},glyphStartIndex:{configurable:!0},numGlyphs:{configurable:!0},vertexStartIndex:{configurable:!0},lineStartIndex:{configurable:!0},lineLength:{configurable:!0},segment:{configurable:!0},lowerSize:{configurable:!0},upperSize:{configurable:!0},lineOffsetX:{configurable:!0},lineOffsetY:{configurable:!0},writingMode:{configurable:!0},placedOrientation:{configurable:!0},hidden:{configurable:!0},crossTileID:{configurable:!0},associatedIconIndex:{configurable:!0}};return r.anchorX.get=function(){return this._structArray.int16[this._pos2+0]},r.anchorY.get=function(){return this._structArray.int16[this._pos2+1]},r.glyphStartIndex.get=function(){return this._structArray.uint16[this._pos2+2]},r.numGlyphs.get=function(){return this._structArray.uint16[this._pos2+3]},r.vertexStartIndex.get=function(){return this._structArray.uint32[this._pos4+2]},r.lineStartIndex.get=function(){return this._structArray.uint32[this._pos4+3]},r.lineLength.get=function(){return this._structArray.uint32[this._pos4+4]},r.segment.get=function(){return this._structArray.uint16[this._pos2+10]},r.lowerSize.get=function(){return this._structArray.uint16[this._pos2+11]},r.upperSize.get=function(){return this._structArray.uint16[this._pos2+12]},r.lineOffsetX.get=function(){return this._structArray.float32[this._pos4+7]},r.lineOffsetY.get=function(){return this._structArray.float32[this._pos4+8]},r.writingMode.get=function(){return this._structArray.uint8[this._pos1+36]},r.placedOrientation.get=function(){return this._structArray.uint8[this._pos1+37]},r.placedOrientation.set=function(t){this._structArray.uint8[this._pos1+37]=t},r.hidden.get=function(){return this._structArray.uint8[this._pos1+38]},r.hidden.set=function(t){this._structArray.uint8[this._pos1+38]=t},r.crossTileID.get=function(){return this._structArray.uint32[this._pos4+10]},r.crossTileID.set=function(t){this._structArray.uint32[this._pos4+10]=t},r.associatedIconIndex.get=function(){return this._structArray.int16[this._pos2+22]},Object.defineProperties(e.prototype,r),e}(Ti);Qi.prototype.size=48;var $i=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.get=function(t){return new Qi(this,t)},e}(Vi);zn("PlacedSymbolArray",$i);var to=function(t){function e(){t.apply(this,arguments)}t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e;var r={anchorX:{configurable:!0},anchorY:{configurable:!0},rightJustifiedTextSymbolIndex:{configurable:!0},centerJustifiedTextSymbolIndex:{configurable:!0},leftJustifiedTextSymbolIndex:{configurable:!0},verticalPlacedTextSymbolIndex:{configurable:!0},placedIconSymbolIndex:{configurable:!0},verticalPlacedIconSymbolIndex:{configurable:!0},key:{configurable:!0},textBoxStartIndex:{configurable:!0},textBoxEndIndex:{configurable:!0},verticalTextBoxStartIndex:{configurable:!0},verticalTextBoxEndIndex:{configurable:!0},iconBoxStartIndex:{configurable:!0},iconBoxEndIndex:{configurable:!0},verticalIconBoxStartIndex:{configurable:!0},verticalIconBoxEndIndex:{configurable:!0},featureIndex:{configurable:!0},numHorizontalGlyphVertices:{configurable:!0},numVerticalGlyphVertices:{configurable:!0},numIconVertices:{configurable:!0},numVerticalIconVertices:{configurable:!0},useRuntimeCollisionCircles:{configurable:!0},crossTileID:{configurable:!0},textBoxScale:{configurable:!0},textOffset0:{configurable:!0},textOffset1:{configurable:!0},collisionCircleDiameter:{configurable:!0}};return r.anchorX.get=function(){return this._structArray.int16[this._pos2+0]},r.anchorY.get=function(){return this._structArray.int16[this._pos2+1]},r.rightJustifiedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+2]},r.centerJustifiedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+3]},r.leftJustifiedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+4]},r.verticalPlacedTextSymbolIndex.get=function(){return this._structArray.int16[this._pos2+5]},r.placedIconSymbolIndex.get=function(){return this._structArray.int16[this._pos2+6]},r.verticalPlacedIconSymbolIndex.get=function(){return this._structArray.int16[this._pos2+7]},r.key.get=function(){return this._structArray.uint16[this._pos2+8]},r.textBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+9]},r.textBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+10]},r.verticalTextBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+11]},r.verticalTextBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+12]},r.iconBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+13]},r.iconBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+14]},r.verticalIconBoxStartIndex.get=function(){return this._structArray.uint16[this._pos2+15]},r.verticalIconBoxEndIndex.get=function(){return this._structArray.uint16[this._pos2+16]},r.featureIndex.get=function(){return this._structArray.uint16[this._pos2+17]},r.numHorizontalGlyphVertices.get=function(){return this._structArray.uint16[this._pos2+18]},r.numVerticalGlyphVertices.get=function(){return this._structArray.uint16[this._pos2+19]},r.numIconVertices.get=function(){return this._structArray.uint16[this._pos2+20]},r.numVerticalIconVertices.get=function(){return this._structArray.uint16[this._pos2+21]},r.useRuntimeCollisionCircles.get=function(){return this._structArray.uint16[this._pos2+22]},r.crossTileID.get=function(){return this._structArray.uint32[this._pos4+12]},r.crossTileID.set=function(t){this._structArray.uint32[this._pos4+12]=t},r.textBoxScale.get=function(){return this._structArray.float32[this._pos4+13]},r.textOffset0.get=function(){return this._structArray.float32[this._pos4+14]},r.textOffset1.get=function(){return this._structArray.float32[this._pos4+15]},r.collisionCircleDiameter.get=function(){return this._structArray.float32[this._pos4+16]},Object.defineProperties(e.prototype,r),e}(Ti);to.prototype.size=68;var eo=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.get=function(t){return new to(this,t)},e}(qi);zn("SymbolInstanceArray",eo);var ro=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getoffsetX=function(t){return this.float32[1*t+0]},e}(Hi);zn("GlyphOffsetArray",ro);var no=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getx=function(t){return this.int16[3*t+0]},e.prototype.gety=function(t){return this.int16[3*t+1]},e.prototype.gettileUnitDistanceFromAnchor=function(t){return this.int16[3*t+2]},e}(Gi);zn("SymbolLineVertexArray",no);var io=function(t){function e(){t.apply(this,arguments)}t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e;var r={featureIndex:{configurable:!0},sourceLayerIndex:{configurable:!0},bucketIndex:{configurable:!0}};return r.featureIndex.get=function(){return this._structArray.uint32[this._pos4+0]},r.sourceLayerIndex.get=function(){return this._structArray.uint16[this._pos2+2]},r.bucketIndex.get=function(){return this._structArray.uint16[this._pos2+3]},Object.defineProperties(e.prototype,r),e}(Ti);io.prototype.size=8;var oo=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.get=function(t){return new io(this,t)},e}(Zi);zn("FeatureIndexArray",oo);var ao=Ci([{name:"a_pos",components:2,type:"Int16"}],4).members,so=function(t){void 0===t&&(t=[]),this.segments=t};function lo(t,e){return 256*(t=c(Math.floor(t),0,255))+c(Math.floor(e),0,255)}so.prototype.prepareSegment=function(t,e,r,n){var i=this.segments[this.segments.length-1];return t>so.MAX_VERTEX_ARRAY_LENGTH&&E("Max vertices per segment is "+so.MAX_VERTEX_ARRAY_LENGTH+": bucket requested "+t),(!i||i.vertexLength+t>so.MAX_VERTEX_ARRAY_LENGTH||i.sortKey!==n)&&(i={vertexOffset:e.length,primitiveOffset:r.length,vertexLength:0,primitiveLength:0},void 0!==n&&(i.sortKey=n),this.segments.push(i)),i},so.prototype.get=function(){return this.segments},so.prototype.destroy=function(){for(var t=0,e=this.segments;t<e.length;t+=1){var r=e[t];for(var n in r.vaos)r.vaos[n].destroy()}},so.simpleSegment=function(t,e,r,n){return new so([{vertexOffset:t,primitiveOffset:e,vertexLength:r,primitiveLength:n,vaos:{},sortKey:0}])},so.MAX_VERTEX_ARRAY_LENGTH=Math.pow(2,16)-1,zn("SegmentVector",so);var uo=Ci([{name:"a_pattern_from",components:4,type:"Uint16"},{name:"a_pattern_to",components:4,type:"Uint16"},{name:"a_pixel_ratio_from",components:1,type:"Uint16"},{name:"a_pixel_ratio_to",components:1,type:"Uint16"}]),co=e((function(t){t.exports=function(t,e){var r,n,i,o,a,s,l,u;for(n=t.length-(r=3&t.length),i=e,a=3432918353,s=461845907,u=0;u<n;)l=255&t.charCodeAt(u)|(255&t.charCodeAt(++u))<<8|(255&t.charCodeAt(++u))<<16|(255&t.charCodeAt(++u))<<24,++u,i=27492+(65535&(o=5*(65535&(i=(i^=l=(65535&(l=(l=(65535&l)*a+(((l>>>16)*a&65535)<<16)&4294967295)<<15|l>>>17))*s+(((l>>>16)*s&65535)<<16)&4294967295)<<13|i>>>19))+((5*(i>>>16)&65535)<<16)&4294967295))+((58964+(o>>>16)&65535)<<16);switch(l=0,r){case 3:l^=(255&t.charCodeAt(u+2))<<16;case 2:l^=(255&t.charCodeAt(u+1))<<8;case 1:i^=l=(65535&(l=(l=(65535&(l^=255&t.charCodeAt(u)))*a+(((l>>>16)*a&65535)<<16)&4294967295)<<15|l>>>17))*s+(((l>>>16)*s&65535)<<16)&4294967295}return i^=t.length,i=2246822507*(65535&(i^=i>>>16))+((2246822507*(i>>>16)&65535)<<16)&4294967295,i=3266489909*(65535&(i^=i>>>13))+((3266489909*(i>>>16)&65535)<<16)&4294967295,(i^=i>>>16)>>>0}})),po=e((function(t){t.exports=function(t,e){for(var r,n=t.length,i=e^n,o=0;n>=4;)r=1540483477*(65535&(r=255&t.charCodeAt(o)|(255&t.charCodeAt(++o))<<8|(255&t.charCodeAt(++o))<<16|(255&t.charCodeAt(++o))<<24))+((1540483477*(r>>>16)&65535)<<16),i=1540483477*(65535&i)+((1540483477*(i>>>16)&65535)<<16)^(r=1540483477*(65535&(r^=r>>>24))+((1540483477*(r>>>16)&65535)<<16)),n-=4,++o;switch(n){case 3:i^=(255&t.charCodeAt(o+2))<<16;case 2:i^=(255&t.charCodeAt(o+1))<<8;case 1:i=1540483477*(65535&(i^=255&t.charCodeAt(o)))+((1540483477*(i>>>16)&65535)<<16)}return i=1540483477*(65535&(i^=i>>>13))+((1540483477*(i>>>16)&65535)<<16),(i^=i>>>15)>>>0}})),ho=co,fo=po;ho.murmur3=co,ho.murmur2=fo;var mo=function(){this.ids=[],this.positions=[],this.indexed=!1};mo.prototype.add=function(t,e,r,n){this.ids.push(yo(t)),this.positions.push(e,r,n)},mo.prototype.getPositions=function(t){for(var e=yo(t),r=0,n=this.ids.length-1;r<n;){var i=r+n>>1;this.ids[i]>=e?n=i:r=i+1}for(var o=[];this.ids[r]===e;)o.push({index:this.positions[3*r],start:this.positions[3*r+1],end:this.positions[3*r+2]}),r++;return o},mo.serialize=function(t,e){var r=new Float64Array(t.ids),n=new Uint32Array(t.positions);return function t(e,r,n,i){for(;n<i;){for(var o=e[n+i>>1],a=n-1,s=i+1;;){do{a++}while(e[a]<o);do{s--}while(e[s]>o);if(a>=s)break;vo(e,a,s),vo(r,3*a,3*s),vo(r,3*a+1,3*s+1),vo(r,3*a+2,3*s+2)}s-n<i-s?(t(e,r,n,s),n=s+1):(t(e,r,s+1,i),i=s)}}(r,n,0,r.length-1),e&&e.push(r.buffer,n.buffer),{ids:r,positions:n}},mo.deserialize=function(t){var e=new mo;return e.ids=t.ids,e.positions=t.positions,e.indexed=!0,e};var go=Math.pow(2,53)-1;function yo(t){var e=+t;return!isNaN(e)&&e<=go?e:ho(String(t))}function vo(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}zn("FeaturePositionMap",mo);var _o=function(t,e){this.gl=t.gl,this.location=e},bo=function(t){function e(e,r){t.call(this,e,r),this.current=0}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){this.current!==t&&(this.current=t,this.gl.uniform1i(this.location,t))},e}(_o),xo=function(t){function e(e,r){t.call(this,e,r),this.current=0}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){this.current!==t&&(this.current=t,this.gl.uniform1f(this.location,t))},e}(_o),wo=function(t){function e(e,r){t.call(this,e,r),this.current=[0,0]}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){t[0]===this.current[0]&&t[1]===this.current[1]||(this.current=t,this.gl.uniform2f(this.location,t[0],t[1]))},e}(_o),Eo=function(t){function e(e,r){t.call(this,e,r),this.current=[0,0,0]}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){t[0]===this.current[0]&&t[1]===this.current[1]&&t[2]===this.current[2]||(this.current=t,this.gl.uniform3f(this.location,t[0],t[1],t[2]))},e}(_o),To=function(t){function e(e,r){t.call(this,e,r),this.current=[0,0,0,0]}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){t[0]===this.current[0]&&t[1]===this.current[1]&&t[2]===this.current[2]&&t[3]===this.current[3]||(this.current=t,this.gl.uniform4f(this.location,t[0],t[1],t[2],t[3]))},e}(_o),Ao=function(t){function e(e,r){t.call(this,e,r),this.current=te.transparent}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){t.r===this.current.r&&t.g===this.current.g&&t.b===this.current.b&&t.a===this.current.a||(this.current=t,this.gl.uniform4f(this.location,t.r,t.g,t.b,t.a))},e}(_o),Co=new Float32Array(16),So=function(t){function e(e,r){t.call(this,e,r),this.current=Co}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){if(t[12]!==this.current[12]||t[0]!==this.current[0])return this.current=t,void this.gl.uniformMatrix4fv(this.location,!1,t);for(var e=1;e<16;e++)if(t[e]!==this.current[e]){this.current=t,this.gl.uniformMatrix4fv(this.location,!1,t);break}},e}(_o);function Po(t){return[lo(255*t.r,255*t.g),lo(255*t.b,255*t.a)]}var Io=function(t,e,r){this.value=t,this.uniformNames=e.map((function(t){return"u_"+t})),this.type=r};Io.prototype.setUniform=function(t,e,r){t.set(r.constantOr(this.value))},Io.prototype.getBinding=function(t,e,r){return"color"===this.type?new Ao(t,e):new xo(t,e)};var Do=function(t,e){this.uniformNames=e.map((function(t){return"u_"+t})),this.patternFrom=null,this.patternTo=null,this.pixelRatioFrom=1,this.pixelRatioTo=1};Do.prototype.setConstantPatternPositions=function(t,e){this.pixelRatioFrom=e.pixelRatio,this.pixelRatioTo=t.pixelRatio,this.patternFrom=e.tlbr,this.patternTo=t.tlbr},Do.prototype.setUniform=function(t,e,r,n){var i="u_pattern_to"===n?this.patternTo:"u_pattern_from"===n?this.patternFrom:"u_pixel_ratio_to"===n?this.pixelRatioTo:"u_pixel_ratio_from"===n?this.pixelRatioFrom:null;i&&t.set(i)},Do.prototype.getBinding=function(t,e,r){return"u_pattern"===r.substr(0,9)?new To(t,e):new xo(t,e)};var Oo=function(t,e,r,n){this.expression=t,this.type=r,this.maxValue=0,this.paintVertexAttributes=e.map((function(t){return{name:"a_"+t,type:"Float32",components:"color"===r?2:1,offset:0}})),this.paintVertexArray=new n};Oo.prototype.populatePaintArray=function(t,e,r,n,i){var o=this.paintVertexArray.length,a=this.expression.evaluate(new si(0),e,{},n,[],i);this.paintVertexArray.resize(t),this._setPaintValue(o,t,a)},Oo.prototype.updatePaintArray=function(t,e,r,n){var i=this.expression.evaluate({zoom:0},r,n);this._setPaintValue(t,e,i)},Oo.prototype._setPaintValue=function(t,e,r){if("color"===this.type)for(var n=Po(r),i=t;i<e;i++)this.paintVertexArray.emplace(i,n[0],n[1]);else{for(var o=t;o<e;o++)this.paintVertexArray.emplace(o,r);this.maxValue=Math.max(this.maxValue,Math.abs(r))}},Oo.prototype.upload=function(t){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=t.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))},Oo.prototype.destroy=function(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()};var Mo=function(t,e,r,n,i,o){this.expression=t,this.uniformNames=e.map((function(t){return"u_"+t+"_t"})),this.type=r,this.useIntegerZoom=n,this.zoom=i,this.maxValue=0,this.paintVertexAttributes=e.map((function(t){return{name:"a_"+t,type:"Float32",components:"color"===r?4:2,offset:0}})),this.paintVertexArray=new o};Mo.prototype.populatePaintArray=function(t,e,r,n,i){var o=this.expression.evaluate(new si(this.zoom),e,{},n,[],i),a=this.expression.evaluate(new si(this.zoom+1),e,{},n,[],i),s=this.paintVertexArray.length;this.paintVertexArray.resize(t),this._setPaintValue(s,t,o,a)},Mo.prototype.updatePaintArray=function(t,e,r,n){var i=this.expression.evaluate({zoom:this.zoom},r,n),o=this.expression.evaluate({zoom:this.zoom+1},r,n);this._setPaintValue(t,e,i,o)},Mo.prototype._setPaintValue=function(t,e,r,n){if("color"===this.type)for(var i=Po(r),o=Po(n),a=t;a<e;a++)this.paintVertexArray.emplace(a,i[0],i[1],o[0],o[1]);else{for(var s=t;s<e;s++)this.paintVertexArray.emplace(s,r,n);this.maxValue=Math.max(this.maxValue,Math.abs(r),Math.abs(n))}},Mo.prototype.upload=function(t){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=t.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))},Mo.prototype.destroy=function(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()},Mo.prototype.setUniform=function(t,e){var r=this.useIntegerZoom?Math.floor(e.zoom):e.zoom,n=c(this.expression.interpolationFactor(r,this.zoom,this.zoom+1),0,1);t.set(n)},Mo.prototype.getBinding=function(t,e,r){return new xo(t,e)};var Bo=function(t,e,r,n,i,o){this.expression=t,this.type=e,this.useIntegerZoom=r,this.zoom=n,this.layerId=o,this.zoomInPaintVertexArray=new i,this.zoomOutPaintVertexArray=new i};Bo.prototype.populatePaintArray=function(t,e,r){var n=this.zoomInPaintVertexArray.length;this.zoomInPaintVertexArray.resize(t),this.zoomOutPaintVertexArray.resize(t),this._setPaintValues(n,t,e.patterns&&e.patterns[this.layerId],r)},Bo.prototype.updatePaintArray=function(t,e,r,n,i){this._setPaintValues(t,e,r.patterns&&r.patterns[this.layerId],i)},Bo.prototype._setPaintValues=function(t,e,r,n){if(n&&r){var i=n[r.min],o=n[r.mid],a=n[r.max];if(i&&o&&a)for(var s=t;s<e;s++)this.zoomInPaintVertexArray.emplace(s,o.tl[0],o.tl[1],o.br[0],o.br[1],i.tl[0],i.tl[1],i.br[0],i.br[1],o.pixelRatio,i.pixelRatio),this.zoomOutPaintVertexArray.emplace(s,o.tl[0],o.tl[1],o.br[0],o.br[1],a.tl[0],a.tl[1],a.br[0],a.br[1],o.pixelRatio,a.pixelRatio)}},Bo.prototype.upload=function(t){this.zoomInPaintVertexArray&&this.zoomInPaintVertexArray.arrayBuffer&&this.zoomOutPaintVertexArray&&this.zoomOutPaintVertexArray.arrayBuffer&&(this.zoomInPaintVertexBuffer=t.createVertexBuffer(this.zoomInPaintVertexArray,uo.members,this.expression.isStateDependent),this.zoomOutPaintVertexBuffer=t.createVertexBuffer(this.zoomOutPaintVertexArray,uo.members,this.expression.isStateDependent))},Bo.prototype.destroy=function(){this.zoomOutPaintVertexBuffer&&this.zoomOutPaintVertexBuffer.destroy(),this.zoomInPaintVertexBuffer&&this.zoomInPaintVertexBuffer.destroy()};var ko=function(t,e,r){this.binders={},this._buffers=[];var n=[];for(var i in t.paint._values)if(r(i)){var o=t.paint.get(i);if(o instanceof di&&Br(o.property.specification)){var a=Lo(i,t.type),s=o.value,l=o.property.specification.type,u=o.property.useIntegerZoom,c=o.property.specification["property-type"],p="cross-faded"===c||"cross-faded-data-driven"===c;if("constant"===s.kind)this.binders[i]=p?new Do(s.value,a):new Io(s.value,a,l),n.push("/u_"+i);else if("source"===s.kind||p){var h=Ro(i,l,"source");this.binders[i]=p?new Bo(s,l,u,e,h,t.id):new Oo(s,a,l,h),n.push("/a_"+i)}else{var f=Ro(i,l,"composite");this.binders[i]=new Mo(s,a,l,u,e,f),n.push("/z_"+i)}}}this.cacheKey=n.sort().join("")};ko.prototype.getMaxValue=function(t){var e=this.binders[t];return e instanceof Oo||e instanceof Mo?e.maxValue:0},ko.prototype.populatePaintArrays=function(t,e,r,n,i){for(var o in this.binders){var a=this.binders[o];(a instanceof Oo||a instanceof Mo||a instanceof Bo)&&a.populatePaintArray(t,e,r,n,i)}},ko.prototype.setConstantPatternPositions=function(t,e){for(var r in this.binders){var n=this.binders[r];n instanceof Do&&n.setConstantPatternPositions(t,e)}},ko.prototype.updatePaintArrays=function(t,e,r,n,i){var o=!1;for(var a in t)for(var s=0,l=e.getPositions(a);s<l.length;s+=1){var u=l[s],c=r.feature(u.index);for(var p in this.binders){var h=this.binders[p];if((h instanceof Oo||h instanceof Mo||h instanceof Bo)&&!0===h.expression.isStateDependent){var f=n.paint.get(p);h.expression=f.value,h.updatePaintArray(u.start,u.end,c,t[a],i),o=!0}}}return o},ko.prototype.defines=function(){var t=[];for(var e in this.binders){var r=this.binders[e];(r instanceof Io||r instanceof Do)&&t.push.apply(t,r.uniformNames.map((function(t){return"#define HAS_UNIFORM_"+t})))}return t},ko.prototype.getBinderAttributes=function(){var t=[];for(var e in this.binders){var r=this.binders[e];if(r instanceof Oo||r instanceof Mo)for(var n=0;n<r.paintVertexAttributes.length;n++)t.push(r.paintVertexAttributes[n].name);else if(r instanceof Bo)for(var i=0;i<uo.members.length;i++)t.push(uo.members[i].name)}return t},ko.prototype.getBinderUniforms=function(){var t=[];for(var e in this.binders){var r=this.binders[e];if(r instanceof Io||r instanceof Do||r instanceof Mo)for(var n=0,i=r.uniformNames;n<i.length;n+=1)t.push(i[n])}return t},ko.prototype.getPaintVertexBuffers=function(){return this._buffers},ko.prototype.getUniforms=function(t,e){var r=[];for(var n in this.binders){var i=this.binders[n];if(i instanceof Io||i instanceof Do||i instanceof Mo)for(var o=0,a=i.uniformNames;o<a.length;o+=1){var s=a[o];if(e[s]){var l=i.getBinding(t,e[s],s);r.push({name:s,property:n,binding:l})}}}return r},ko.prototype.setUniforms=function(t,e,r,n){for(var i=0,o=e;i<o.length;i+=1){var a=o[i],s=a.name,l=a.property;this.binders[l].setUniform(a.binding,n,r.get(l),s)}},ko.prototype.updatePaintBuffers=function(t){for(var e in this._buffers=[],this.binders){var r=this.binders[e];if(t&&r instanceof Bo){var n=2===t.fromScale?r.zoomInPaintVertexBuffer:r.zoomOutPaintVertexBuffer;n&&this._buffers.push(n)}else(r instanceof Oo||r instanceof Mo)&&r.paintVertexBuffer&&this._buffers.push(r.paintVertexBuffer)}},ko.prototype.upload=function(t){for(var e in this.binders){var r=this.binders[e];(r instanceof Oo||r instanceof Mo||r instanceof Bo)&&r.upload(t)}this.updatePaintBuffers()},ko.prototype.destroy=function(){for(var t in this.binders){var e=this.binders[t];(e instanceof Oo||e instanceof Mo||e instanceof Bo)&&e.destroy()}};var Fo=function(t,e,r){void 0===r&&(r=function(){return!0}),this.programConfigurations={};for(var n=0,i=t;n<i.length;n+=1){var o=i[n];this.programConfigurations[o.id]=new ko(o,e,r)}this.needsUpload=!1,this._featureMap=new mo,this._bufferOffset=0};function Lo(t,e){return{"text-opacity":["opacity"],"icon-opacity":["opacity"],"text-color":["fill_color"],"icon-color":["fill_color"],"text-halo-color":["halo_color"],"icon-halo-color":["halo_color"],"text-halo-blur":["halo_blur"],"icon-halo-blur":["halo_blur"],"text-halo-width":["halo_width"],"icon-halo-width":["halo_width"],"line-gap-width":["gapwidth"],"line-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-extrusion-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"]}[t]||[t.replace(e+"-","").replace(/-/g,"_")]}function Ro(t,e,r){var n={color:{source:Mi,composite:Xi},number:{source:Hi,composite:Mi}},i=function(t){return{"line-pattern":{source:Bi,composite:Bi},"fill-pattern":{source:Bi,composite:Bi},"fill-extrusion-pattern":{source:Bi,composite:Bi}}[t]}(t);return i&&i[r]||n[e][r]}Fo.prototype.populatePaintArrays=function(t,e,r,n,i,o){for(var a in this.programConfigurations)this.programConfigurations[a].populatePaintArrays(t,e,n,i,o);void 0!==e.id&&this._featureMap.add(e.id,r,this._bufferOffset,t),this._bufferOffset=t,this.needsUpload=!0},Fo.prototype.updatePaintArrays=function(t,e,r,n){for(var i=0,o=r;i<o.length;i+=1){var a=o[i];this.needsUpload=this.programConfigurations[a.id].updatePaintArrays(t,this._featureMap,e,a,n)||this.needsUpload}},Fo.prototype.get=function(t){return this.programConfigurations[t]},Fo.prototype.upload=function(t){if(this.needsUpload){for(var e in this.programConfigurations)this.programConfigurations[e].upload(t);this.needsUpload=!1}},Fo.prototype.destroy=function(){for(var t in this.programConfigurations)this.programConfigurations[t].destroy()},zn("ConstantBinder",Io),zn("CrossFadedConstantBinder",Do),zn("SourceExpressionBinder",Oo),zn("CrossFadedCompositeBinder",Bo),zn("CompositeExpressionBinder",Mo),zn("ProgramConfiguration",ko,{omit:["_buffers"]}),zn("ProgramConfigurationSet",Fo);var zo=Math.pow(2,14)-1,No=-zo-1;function jo(t){for(var e=8192/t.extent,r=t.loadGeometry(),n=0;n<r.length;n++)for(var i=r[n],o=0;o<i.length;o++){var a=i[o],s=Math.round(a.x*e),l=Math.round(a.y*e);a.x=c(s,No,zo),a.y=c(l,No,zo),(s<a.x||s>a.x+1||l<a.y||l>a.y+1)&&E("Geometry exceeds allowed extent, reduce your vector tile buffer size")}return r}function Uo(t,e){return{type:t.type,id:t.id,properties:t.properties,geometry:e?jo(t):[]}}function Vo(t,e,r,n,i){t.emplaceBack(2*e+(n+1)/2,2*r+(i+1)/2)}var qo=function(t){this.zoom=t.zoom,this.overscaling=t.overscaling,this.layers=t.layers,this.layerIds=this.layers.map((function(t){return t.id})),this.index=t.index,this.hasPattern=!1,this.layoutVertexArray=new Pi,this.indexArray=new Ui,this.segments=new so,this.programConfigurations=new Fo(t.layers,t.zoom),this.stateDependentLayerIds=this.layers.filter((function(t){return t.isStateDependent()})).map((function(t){return t.id}))};function Ho(t,e){for(var r=0;r<t.length;r++)if($o(e,t[r]))return!0;for(var n=0;n<e.length;n++)if($o(t,e[n]))return!0;return!!Yo(t,e)}function Go(t,e,r){return!!$o(t,e)||!!Ko(e,t,r)}function Zo(t,e){if(1===t.length)return Qo(e,t[0]);for(var r=0;r<e.length;r++)for(var n=e[r],i=0;i<n.length;i++)if($o(t,n[i]))return!0;for(var o=0;o<t.length;o++)if(Qo(e,t[o]))return!0;for(var a=0;a<e.length;a++)if(Yo(t,e[a]))return!0;return!1}function Wo(t,e,r){if(t.length>1){if(Yo(t,e))return!0;for(var n=0;n<e.length;n++)if(Ko(e[n],t,r))return!0}for(var i=0;i<t.length;i++)if(Ko(t[i],e,r))return!0;return!1}function Yo(t,e){if(0===t.length||0===e.length)return!1;for(var r=0;r<t.length-1;r++)for(var n=t[r],i=t[r+1],o=0;o<e.length-1;o++)if(Xo(n,i,e[o],e[o+1]))return!0;return!1}function Xo(t,e,r,n){return T(t,r,n)!==T(e,r,n)&&T(t,e,r)!==T(t,e,n)}function Ko(t,e,r){var n=r*r;if(1===e.length)return t.distSqr(e[0])<n;for(var i=1;i<e.length;i++)if(Jo(t,e[i-1],e[i])<n)return!0;return!1}function Jo(t,e,r){var n=e.distSqr(r);if(0===n)return t.distSqr(e);var i=((t.x-e.x)*(r.x-e.x)+(t.y-e.y)*(r.y-e.y))/n;return t.distSqr(i<0?e:i>1?r:r.sub(e)._mult(i)._add(e))}function Qo(t,e){for(var r,n,i,o=!1,a=0;a<t.length;a++)for(var s=0,l=(r=t[a]).length-1;s<r.length;l=s++)(n=r[s]).y>e.y!=(i=r[l]).y>e.y&&e.x<(i.x-n.x)*(e.y-n.y)/(i.y-n.y)+n.x&&(o=!o);return o}function $o(t,e){for(var r=!1,n=0,i=t.length-1;n<t.length;i=n++){var o=t[n],a=t[i];o.y>e.y!=a.y>e.y&&e.x<(a.x-o.x)*(e.y-o.y)/(a.y-o.y)+o.x&&(r=!r)}return r}function ta(t,e,r){var n=r[0],i=r[2];if(t.x<n.x&&e.x<n.x||t.x>i.x&&e.x>i.x||t.y<n.y&&e.y<n.y||t.y>i.y&&e.y>i.y)return!1;var o=T(t,e,r[0]);return o!==T(t,e,r[1])||o!==T(t,e,r[2])||o!==T(t,e,r[3])}function ea(t,e,r){var n=e.paint.get(t).value;return"constant"===n.kind?n.value:r.programConfigurations.get(e.id).getMaxValue(t)}function ra(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function na(t,e,r,n,o){if(!e[0]&&!e[1])return t;var a=i.convert(e)._mult(o);"viewport"===r&&a._rotate(-n);for(var s=[],l=0;l<t.length;l++)s.push(t[l].sub(a));return s}qo.prototype.populate=function(t,e,r){var n=this.layers[0],i=[],o=null;"circle"===n.type&&(o=n.layout.get("circle-sort-key"));for(var a=0,s=t;a<s.length;a+=1){var l=s[a],u=l.feature,c=l.id,p=l.index,h=l.sourceLayerIndex,f=this.layers[0]._featureFilter.needGeometry,d=Uo(u,f);if(this.layers[0]._featureFilter.filter(new si(this.zoom),d,r)){var m=o?o.evaluate(d,{},r):void 0,g={id:c,properties:u.properties,type:u.type,sourceLayerIndex:h,index:p,geometry:f?d.geometry:jo(u),patterns:{},sortKey:m};i.push(g)}}o&&i.sort((function(t,e){return t.sortKey-e.sortKey}));for(var y=0,v=i;y<v.length;y+=1){var _=v[y],b=_.geometry,x=_.index,w=_.sourceLayerIndex,E=t[x].feature;this.addFeature(_,b,x,r),e.featureIndex.insert(E,b,x,w,this.index)}},qo.prototype.update=function(t,e,r){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(t,e,this.stateDependentLayers,r)},qo.prototype.isEmpty=function(){return 0===this.layoutVertexArray.length},qo.prototype.uploadPending=function(){return!this.uploaded||this.programConfigurations.needsUpload},qo.prototype.upload=function(t){this.uploaded||(this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,ao),this.indexBuffer=t.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(t),this.uploaded=!0},qo.prototype.destroy=function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())},qo.prototype.addFeature=function(t,e,r,n){for(var i=0,o=e;i<o.length;i+=1)for(var a=0,s=o[i];a<s.length;a+=1){var l=s[a],u=l.x,c=l.y;if(!(u<0||u>=8192||c<0||c>=8192)){var p=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray,t.sortKey),h=p.vertexLength;Vo(this.layoutVertexArray,u,c,-1,-1),Vo(this.layoutVertexArray,u,c,1,-1),Vo(this.layoutVertexArray,u,c,1,1),Vo(this.layoutVertexArray,u,c,-1,1),this.indexArray.emplaceBack(h,h+1,h+2),this.indexArray.emplaceBack(h,h+3,h+2),p.vertexLength+=4,p.primitiveLength+=2}}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,t,r,{},n)},zn("CircleBucket",qo,{omit:["layers"]});var ia=new xi({"circle-sort-key":new yi(It.layout_circle["circle-sort-key"])}),oa={paint:new xi({"circle-radius":new yi(It.paint_circle["circle-radius"]),"circle-color":new yi(It.paint_circle["circle-color"]),"circle-blur":new yi(It.paint_circle["circle-blur"]),"circle-opacity":new yi(It.paint_circle["circle-opacity"]),"circle-translate":new gi(It.paint_circle["circle-translate"]),"circle-translate-anchor":new gi(It.paint_circle["circle-translate-anchor"]),"circle-pitch-scale":new gi(It.paint_circle["circle-pitch-scale"]),"circle-pitch-alignment":new gi(It.paint_circle["circle-pitch-alignment"]),"circle-stroke-width":new yi(It.paint_circle["circle-stroke-width"]),"circle-stroke-color":new yi(It.paint_circle["circle-stroke-color"]),"circle-stroke-opacity":new yi(It.paint_circle["circle-stroke-opacity"])}),layout:ia},aa="undefined"!=typeof Float32Array?Float32Array:Array;function sa(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function la(t,e,r){var n=e[0],i=e[1],o=e[2],a=e[3],s=e[4],l=e[5],u=e[6],c=e[7],p=e[8],h=e[9],f=e[10],d=e[11],m=e[12],g=e[13],y=e[14],v=e[15],_=r[0],b=r[1],x=r[2],w=r[3];return t[0]=_*n+b*s+x*p+w*m,t[1]=_*i+b*l+x*h+w*g,t[2]=_*o+b*u+x*f+w*y,t[3]=_*a+b*c+x*d+w*v,t[4]=(_=r[4])*n+(b=r[5])*s+(x=r[6])*p+(w=r[7])*m,t[5]=_*i+b*l+x*h+w*g,t[6]=_*o+b*u+x*f+w*y,t[7]=_*a+b*c+x*d+w*v,t[8]=(_=r[8])*n+(b=r[9])*s+(x=r[10])*p+(w=r[11])*m,t[9]=_*i+b*l+x*h+w*g,t[10]=_*o+b*u+x*f+w*y,t[11]=_*a+b*c+x*d+w*v,t[12]=(_=r[12])*n+(b=r[13])*s+(x=r[14])*p+(w=r[15])*m,t[13]=_*i+b*l+x*h+w*g,t[14]=_*o+b*u+x*f+w*y,t[15]=_*a+b*c+x*d+w*v,t}Math.hypot||(Math.hypot=function(){for(var t=arguments,e=0,r=arguments.length;r--;)e+=t[r]*t[r];return Math.sqrt(e)});var ua,ca=la;function pa(t,e,r){var n=e[0],i=e[1],o=e[2],a=e[3];return t[0]=r[0]*n+r[4]*i+r[8]*o+r[12]*a,t[1]=r[1]*n+r[5]*i+r[9]*o+r[13]*a,t[2]=r[2]*n+r[6]*i+r[10]*o+r[14]*a,t[3]=r[3]*n+r[7]*i+r[11]*o+r[15]*a,t}ua=new aa(3),aa!=Float32Array&&(ua[0]=0,ua[1]=0,ua[2]=0),function(){var t=new aa(4);aa!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0,t[3]=0)}();var ha=(function(){var t=new aa(2);aa!=Float32Array&&(t[0]=0,t[1]=0)}(),function(t){function e(e){t.call(this,e,oa)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.createBucket=function(t){return new qo(t)},e.prototype.queryRadius=function(t){var e=t;return ea("circle-radius",this,e)+ea("circle-stroke-width",this,e)+ra(this.paint.get("circle-translate"))},e.prototype.queryIntersectsFeature=function(t,e,r,n,i,o,a,s){for(var l=na(t,this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),o.angle,a),u=this.paint.get("circle-radius").evaluate(e,r)+this.paint.get("circle-stroke-width").evaluate(e,r),c="map"===this.paint.get("circle-pitch-alignment"),p=c?l:function(t,e){return t.map((function(t){return fa(t,e)}))}(l,s),h=c?u*a:u,f=0,d=n;f<d.length;f+=1)for(var m=0,g=d[f];m<g.length;m+=1){var y=g[m],v=c?y:fa(y,s),_=h,b=pa([],[y.x,y.y,0,1],s);if("viewport"===this.paint.get("circle-pitch-scale")&&"map"===this.paint.get("circle-pitch-alignment")?_*=b[3]/o.cameraToCenterDistance:"map"===this.paint.get("circle-pitch-scale")&&"viewport"===this.paint.get("circle-pitch-alignment")&&(_*=o.cameraToCenterDistance/b[3]),Go(p,v,_))return!0}return!1},e}(wi));function fa(t,e){var r=pa([],[t.x,t.y,0,1],e);return new i(r[0]/r[3],r[1]/r[3])}var da=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e}(qo);function ma(t,e,r,n){var i=e.width,o=e.height;if(n){if(n instanceof Uint8ClampedArray)n=new Uint8Array(n.buffer);else if(n.length!==i*o*r)throw new RangeError("mismatched image size")}else n=new Uint8Array(i*o*r);return t.width=i,t.height=o,t.data=n,t}function ga(t,e,r){var n=e.width,i=e.height;if(n!==t.width||i!==t.height){var o=ma({},{width:n,height:i},r);ya(t,o,{x:0,y:0},{x:0,y:0},{width:Math.min(t.width,n),height:Math.min(t.height,i)},r),t.width=n,t.height=i,t.data=o.data}}function ya(t,e,r,n,i,o){if(0===i.width||0===i.height)return e;if(i.width>t.width||i.height>t.height||r.x>t.width-i.width||r.y>t.height-i.height)throw new RangeError("out of range source coordinates for image copy");if(i.width>e.width||i.height>e.height||n.x>e.width-i.width||n.y>e.height-i.height)throw new RangeError("out of range destination coordinates for image copy");for(var a=t.data,s=e.data,l=0;l<i.height;l++)for(var u=((r.y+l)*t.width+r.x)*o,c=((n.y+l)*e.width+n.x)*o,p=0;p<i.width*o;p++)s[c+p]=a[u+p];return e}zn("HeatmapBucket",da,{omit:["layers"]});var va=function(t,e){ma(this,t,1,e)};va.prototype.resize=function(t){ga(this,t,1)},va.prototype.clone=function(){return new va({width:this.width,height:this.height},new Uint8Array(this.data))},va.copy=function(t,e,r,n,i){ya(t,e,r,n,i,1)};var _a=function(t,e){ma(this,t,4,e)};_a.prototype.resize=function(t){ga(this,t,4)},_a.prototype.replace=function(t,e){e?this.data.set(t):this.data=t instanceof Uint8ClampedArray?new Uint8Array(t.buffer):t},_a.prototype.clone=function(){return new _a({width:this.width,height:this.height},new Uint8Array(this.data))},_a.copy=function(t,e,r,n,i){ya(t,e,r,n,i,4)},zn("AlphaImage",va),zn("RGBAImage",_a);var ba={paint:new xi({"heatmap-radius":new yi(It.paint_heatmap["heatmap-radius"]),"heatmap-weight":new yi(It.paint_heatmap["heatmap-weight"]),"heatmap-intensity":new gi(It.paint_heatmap["heatmap-intensity"]),"heatmap-color":new bi(It.paint_heatmap["heatmap-color"]),"heatmap-opacity":new gi(It.paint_heatmap["heatmap-opacity"])})};function xa(t){var e={},r=t.resolution||256,n=t.clips?t.clips.length:1,i=t.image||new _a({width:r,height:n}),o=function(r,n,o){e[t.evaluationKey]=o;var a=t.expression.evaluate(e);i.data[r+n+0]=Math.floor(255*a.r/a.a),i.data[r+n+1]=Math.floor(255*a.g/a.a),i.data[r+n+2]=Math.floor(255*a.b/a.a),i.data[r+n+3]=Math.floor(255*a.a)};if(t.clips)for(var a=0,s=0;a<n;++a,s+=4*r)for(var l=0,u=0;l<r;l++,u+=4){var c=l/(r-1),p=t.clips[a];o(s,u,p.start*(1-c)+p.end*c)}else for(var h=0,f=0;h<r;h++,f+=4)o(0,f,h/(r-1));return i}var wa=function(t){function e(e){t.call(this,e,ba),this._updateColorRamp()}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.createBucket=function(t){return new da(t)},e.prototype._handleSpecialPaintPropertyUpdate=function(t){"heatmap-color"===t&&this._updateColorRamp()},e.prototype._updateColorRamp=function(){this.colorRamp=xa({expression:this._transitionablePaint._values["heatmap-color"].value.expression,evaluationKey:"heatmapDensity",image:this.colorRamp}),this.colorRampTexture=null},e.prototype.resize=function(){this.heatmapFbo&&(this.heatmapFbo.destroy(),this.heatmapFbo=null)},e.prototype.queryRadius=function(){return 0},e.prototype.queryIntersectsFeature=function(){return!1},e.prototype.hasOffscreenPass=function(){return 0!==this.paint.get("heatmap-opacity")&&"none"!==this.visibility},e}(wi),Ea={paint:new xi({"hillshade-illumination-direction":new gi(It.paint_hillshade["hillshade-illumination-direction"]),"hillshade-illumination-anchor":new gi(It.paint_hillshade["hillshade-illumination-anchor"]),"hillshade-exaggeration":new gi(It.paint_hillshade["hillshade-exaggeration"]),"hillshade-shadow-color":new gi(It.paint_hillshade["hillshade-shadow-color"]),"hillshade-highlight-color":new gi(It.paint_hillshade["hillshade-highlight-color"]),"hillshade-accent-color":new gi(It.paint_hillshade["hillshade-accent-color"])})},Ta=function(t){function e(e){t.call(this,e,Ea)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.hasOffscreenPass=function(){return 0!==this.paint.get("hillshade-exaggeration")&&"none"!==this.visibility},e}(wi),Aa=Ci([{name:"a_pos",components:2,type:"Int16"}],4).members,Ca=Pa,Sa=Pa;function Pa(t,e,r){r=r||2;var n,i,o,a,s,l,u,c=e&&e.length,p=c?e[0]*r:t.length,h=Ia(t,0,p,r,!0),f=[];if(!h||h.next===h.prev)return f;if(c&&(h=function(t,e,r,n){var i,o,a,s=[];for(i=0,o=e.length;i<o;i++)(a=Ia(t,e[i]*n,i<o-1?e[i+1]*n:t.length,n,!1))===a.next&&(a.steiner=!0),s.push(ja(a));for(s.sort(La),i=0;i<s.length;i++)Ra(s[i],r),r=Da(r,r.next);return r}(t,e,h,r)),t.length>80*r){n=o=t[0],i=a=t[1];for(var d=r;d<p;d+=r)(s=t[d])<n&&(n=s),(l=t[d+1])<i&&(i=l),s>o&&(o=s),l>a&&(a=l);u=0!==(u=Math.max(o-n,a-i))?1/u:0}return Oa(h,f,r,n,i,u),f}function Ia(t,e,r,n,i){var o,a;if(i===$a(t,e,r,n)>0)for(o=e;o<r;o+=n)a=Ka(o,t[o],t[o+1],a);else for(o=r-n;o>=e;o-=n)a=Ka(o,t[o],t[o+1],a);return a&&Ha(a,a.next)&&(Ja(a),a=a.next),a}function Da(t,e){if(!t)return t;e||(e=t);var r,n=t;do{if(r=!1,n.steiner||!Ha(n,n.next)&&0!==qa(n.prev,n,n.next))n=n.next;else{if(Ja(n),(n=e=n.prev)===n.next)break;r=!0}}while(r||n!==e);return e}function Oa(t,e,r,n,i,o,a){if(t){!a&&o&&function(t,e,r,n){var i=t;do{null===i.z&&(i.z=Na(i.x,i.y,e,r,n)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,r,n,i,o,a,s,l,u=1;do{for(r=t,t=null,o=null,a=0;r;){for(a++,n=r,s=0,e=0;e<u&&(s++,n=n.nextZ);e++);for(l=u;s>0||l>0&&n;)0!==s&&(0===l||!n||r.z<=n.z)?(i=r,r=r.nextZ,s--):(i=n,n=n.nextZ,l--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;r=n}o.nextZ=null,u*=2}while(a>1)}(i)}(t,n,i,o);for(var s,l,u=t;t.prev!==t.next;)if(s=t.prev,l=t.next,o?Ba(t,n,i,o):Ma(t))e.push(s.i/r),e.push(t.i/r),e.push(l.i/r),Ja(t),t=l.next,u=l.next;else if((t=l)===u){a?1===a?Oa(t=ka(Da(t),e,r),e,r,n,i,o,2):2===a&&Fa(t,e,r,n,i,o):Oa(Da(t),e,r,n,i,o,1);break}}}function Ma(t){var e=t.prev,r=t,n=t.next;if(qa(e,r,n)>=0)return!1;for(var i=t.next.next;i!==t.prev;){if(Ua(e.x,e.y,r.x,r.y,n.x,n.y,i.x,i.y)&&qa(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function Ba(t,e,r,n){var i=t.prev,o=t,a=t.next;if(qa(i,o,a)>=0)return!1;for(var s=i.x>o.x?i.x>a.x?i.x:a.x:o.x>a.x?o.x:a.x,l=i.y>o.y?i.y>a.y?i.y:a.y:o.y>a.y?o.y:a.y,u=Na(i.x<o.x?i.x<a.x?i.x:a.x:o.x<a.x?o.x:a.x,i.y<o.y?i.y<a.y?i.y:a.y:o.y<a.y?o.y:a.y,e,r,n),c=Na(s,l,e,r,n),p=t.prevZ,h=t.nextZ;p&&p.z>=u&&h&&h.z<=c;){if(p!==t.prev&&p!==t.next&&Ua(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&qa(p.prev,p,p.next)>=0)return!1;if(p=p.prevZ,h!==t.prev&&h!==t.next&&Ua(i.x,i.y,o.x,o.y,a.x,a.y,h.x,h.y)&&qa(h.prev,h,h.next)>=0)return!1;h=h.nextZ}for(;p&&p.z>=u;){if(p!==t.prev&&p!==t.next&&Ua(i.x,i.y,o.x,o.y,a.x,a.y,p.x,p.y)&&qa(p.prev,p,p.next)>=0)return!1;p=p.prevZ}for(;h&&h.z<=c;){if(h!==t.prev&&h!==t.next&&Ua(i.x,i.y,o.x,o.y,a.x,a.y,h.x,h.y)&&qa(h.prev,h,h.next)>=0)return!1;h=h.nextZ}return!0}function ka(t,e,r){var n=t;do{var i=n.prev,o=n.next.next;!Ha(i,o)&&Ga(i,n,n.next,o)&&Ya(i,o)&&Ya(o,i)&&(e.push(i.i/r),e.push(n.i/r),e.push(o.i/r),Ja(n),Ja(n.next),n=t=o),n=n.next}while(n!==t);return Da(n)}function Fa(t,e,r,n,i,o){var a=t;do{for(var s=a.next.next;s!==a.prev;){if(a.i!==s.i&&Va(a,s)){var l=Xa(a,s);return a=Da(a,a.next),l=Da(l,l.next),Oa(a,e,r,n,i,o),void Oa(l,e,r,n,i,o)}s=s.next}a=a.next}while(a!==t)}function La(t,e){return t.x-e.x}function Ra(t,e){if(e=function(t,e){var r,n=e,i=t.x,o=t.y,a=-1/0;do{if(o<=n.y&&o>=n.next.y&&n.next.y!==n.y){var s=n.x+(o-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(s<=i&&s>a){if(a=s,s===i){if(o===n.y)return n;if(o===n.next.y)return n.next}r=n.x<n.next.x?n:n.next}}n=n.next}while(n!==e);if(!r)return null;if(i===a)return r;var l,u=r,c=r.x,p=r.y,h=1/0;n=r;do{i>=n.x&&n.x>=c&&i!==n.x&&Ua(o<p?i:a,o,c,p,o<p?a:i,o,n.x,n.y)&&(l=Math.abs(o-n.y)/(i-n.x),Ya(n,t)&&(l<h||l===h&&(n.x>r.x||n.x===r.x&&za(r,n)))&&(r=n,h=l)),n=n.next}while(n!==u);return r}(t,e)){var r=Xa(e,t);Da(e,e.next),Da(r,r.next)}}function za(t,e){return qa(t.prev,t,e.prev)<0&&qa(e.next,t,t.next)<0}function Na(t,e,r,n,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)*i)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-n)*i)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function ja(t){var e=t,r=t;do{(e.x<r.x||e.x===r.x&&e.y<r.y)&&(r=e),e=e.next}while(e!==t);return r}function Ua(t,e,r,n,i,o,a,s){return(i-a)*(e-s)-(t-a)*(o-s)>=0&&(t-a)*(n-s)-(r-a)*(e-s)>=0&&(r-a)*(o-s)-(i-a)*(n-s)>=0}function Va(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var r=t;do{if(r.i!==t.i&&r.next.i!==t.i&&r.i!==e.i&&r.next.i!==e.i&&Ga(r,r.next,t,e))return!0;r=r.next}while(r!==t);return!1}(t,e)&&(Ya(t,e)&&Ya(e,t)&&function(t,e){var r=t,n=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{r.y>o!=r.next.y>o&&r.next.y!==r.y&&i<(r.next.x-r.x)*(o-r.y)/(r.next.y-r.y)+r.x&&(n=!n),r=r.next}while(r!==t);return n}(t,e)&&(qa(t.prev,t,e.prev)||qa(t,e.prev,e))||Ha(t,e)&&qa(t.prev,t,t.next)>0&&qa(e.prev,e,e.next)>0)}function qa(t,e,r){return(e.y-t.y)*(r.x-e.x)-(e.x-t.x)*(r.y-e.y)}function Ha(t,e){return t.x===e.x&&t.y===e.y}function Ga(t,e,r,n){var i=Wa(qa(t,e,r)),o=Wa(qa(t,e,n)),a=Wa(qa(r,n,t)),s=Wa(qa(r,n,e));return i!==o&&a!==s||!(0!==i||!Za(t,r,e))||!(0!==o||!Za(t,n,e))||!(0!==a||!Za(r,t,n))||!(0!==s||!Za(r,e,n))}function Za(t,e,r){return e.x<=Math.max(t.x,r.x)&&e.x>=Math.min(t.x,r.x)&&e.y<=Math.max(t.y,r.y)&&e.y>=Math.min(t.y,r.y)}function Wa(t){return t>0?1:t<0?-1:0}function Ya(t,e){return qa(t.prev,t,t.next)<0?qa(t,e,t.next)>=0&&qa(t,t.prev,e)>=0:qa(t,e,t.prev)<0||qa(t,t.next,e)<0}function Xa(t,e){var r=new Qa(t.i,t.x,t.y),n=new Qa(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,r.next=i,i.prev=r,n.next=r,r.prev=n,o.next=n,n.prev=o,n}function Ka(t,e,r,n){var i=new Qa(t,e,r);return n?(i.next=n.next,i.prev=n,n.next.prev=i,n.next=i):(i.prev=i,i.next=i),i}function Ja(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function Qa(t,e,r){this.i=t,this.x=e,this.y=r,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function $a(t,e,r,n){for(var i=0,o=e,a=r-n;o<r;o+=n)i+=(t[a]-t[o])*(t[o+1]+t[a+1]),a=o;return i}function ts(t,e,r,n,i){!function t(e,r,n,i,o){for(;i>n;){if(i-n>600){var a=i-n+1,s=r-n+1,l=Math.log(a),u=.5*Math.exp(2*l/3),c=.5*Math.sqrt(l*u*(a-u)/a)*(s-a/2<0?-1:1);t(e,r,Math.max(n,Math.floor(r-s*u/a+c)),Math.min(i,Math.floor(r+(a-s)*u/a+c)),o)}var p=e[r],h=n,f=i;for(es(e,n,r),o(e[i],p)>0&&es(e,n,i);h<f;){for(es(e,h,f),h++,f--;o(e[h],p)<0;)h++;for(;o(e[f],p)>0;)f--}0===o(e[n],p)?es(e,n,f):es(e,++f,i),f<=r&&(n=f+1),r<=f&&(i=f-1)}}(t,e,r||0,n||t.length-1,i||rs)}function es(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function rs(t,e){return t<e?-1:t>e?1:0}function ns(t,e){var r=t.length;if(r<=1)return[t];for(var n,i,o=[],a=0;a<r;a++){var s=A(t[a]);0!==s&&(t[a].area=Math.abs(s),void 0===i&&(i=s<0),i===s<0?(n&&o.push(n),n=[t[a]]):n.push(t[a]))}if(n&&o.push(n),e>1)for(var l=0;l<o.length;l++)o[l].length<=e||(ts(o[l],e,1,o[l].length-1,is),o[l]=o[l].slice(0,e));return o}function is(t,e){return e.area-t.area}function os(t,e,r){for(var n=r.patternDependencies,i=!1,o=0,a=e;o<a.length;o+=1){var s=a[o].paint.get(t+"-pattern");s.isConstant()||(i=!0);var l=s.constantOr(null);l&&(i=!0,n[l.to]=!0,n[l.from]=!0)}return i}function as(t,e,r,n,i){for(var o=i.patternDependencies,a=0,s=e;a<s.length;a+=1){var l=s[a],u=l.paint.get(t+"-pattern").value;if("constant"!==u.kind){var c=u.evaluate({zoom:n-1},r,{},i.availableImages),p=u.evaluate({zoom:n},r,{},i.availableImages),h=u.evaluate({zoom:n+1},r,{},i.availableImages);p=p&&p.name?p.name:p,h=h&&h.name?h.name:h,o[c=c&&c.name?c.name:c]=!0,o[p]=!0,o[h]=!0,r.patterns[l.id]={min:c,mid:p,max:h}}}return r}Pa.deviation=function(t,e,r,n){var i=e&&e.length,o=Math.abs($a(t,0,i?e[0]*r:t.length,r));if(i)for(var a=0,s=e.length;a<s;a++)o-=Math.abs($a(t,e[a]*r,a<s-1?e[a+1]*r:t.length,r));var l=0;for(a=0;a<n.length;a+=3){var u=n[a]*r,c=n[a+1]*r,p=n[a+2]*r;l+=Math.abs((t[u]-t[p])*(t[c+1]-t[u+1])-(t[u]-t[c])*(t[p+1]-t[u+1]))}return 0===o&&0===l?0:Math.abs((l-o)/o)},Pa.flatten=function(t){for(var e=t[0][0].length,r={vertices:[],holes:[],dimensions:e},n=0,i=0;i<t.length;i++){for(var o=0;o<t[i].length;o++)for(var a=0;a<e;a++)r.vertices.push(t[i][o][a]);i>0&&r.holes.push(n+=t[i-1].length)}return r},Ca.default=Sa;var ss=function(t){this.zoom=t.zoom,this.overscaling=t.overscaling,this.layers=t.layers,this.layerIds=this.layers.map((function(t){return t.id})),this.index=t.index,this.hasPattern=!1,this.patternFeatures=[],this.layoutVertexArray=new Pi,this.indexArray=new Ui,this.indexArray2=new Wi,this.programConfigurations=new Fo(t.layers,t.zoom),this.segments=new so,this.segments2=new so,this.stateDependentLayerIds=this.layers.filter((function(t){return t.isStateDependent()})).map((function(t){return t.id}))};ss.prototype.populate=function(t,e,r){this.hasPattern=os("fill",this.layers,e);for(var n=this.layers[0].layout.get("fill-sort-key"),i=[],o=0,a=t;o<a.length;o+=1){var s=a[o],l=s.feature,u=s.id,c=s.index,p=s.sourceLayerIndex,h=this.layers[0]._featureFilter.needGeometry,f=Uo(l,h);if(this.layers[0]._featureFilter.filter(new si(this.zoom),f,r)){var d=n?n.evaluate(f,{},r,e.availableImages):void 0,m={id:u,properties:l.properties,type:l.type,sourceLayerIndex:p,index:c,geometry:h?f.geometry:jo(l),patterns:{},sortKey:d};i.push(m)}}n&&i.sort((function(t,e){return t.sortKey-e.sortKey}));for(var g=0,y=i;g<y.length;g+=1){var v=y[g],_=v.geometry,b=v.index,x=v.sourceLayerIndex;if(this.hasPattern){var w=as("fill",this.layers,v,this.zoom,e);this.patternFeatures.push(w)}else this.addFeature(v,_,b,r,{});e.featureIndex.insert(t[b].feature,_,b,x,this.index)}},ss.prototype.update=function(t,e,r){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(t,e,this.stateDependentLayers,r)},ss.prototype.addFeatures=function(t,e,r){for(var n=0,i=this.patternFeatures;n<i.length;n+=1){var o=i[n];this.addFeature(o,o.geometry,o.index,e,r)}},ss.prototype.isEmpty=function(){return 0===this.layoutVertexArray.length},ss.prototype.uploadPending=function(){return!this.uploaded||this.programConfigurations.needsUpload},ss.prototype.upload=function(t){this.uploaded||(this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,Aa),this.indexBuffer=t.createIndexBuffer(this.indexArray),this.indexBuffer2=t.createIndexBuffer(this.indexArray2)),this.programConfigurations.upload(t),this.uploaded=!0},ss.prototype.destroy=function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.indexBuffer2.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.segments2.destroy())},ss.prototype.addFeature=function(t,e,r,n,i){for(var o=0,a=ns(e,500);o<a.length;o+=1){for(var s=a[o],l=0,u=0,c=s;u<c.length;u+=1)l+=c[u].length;for(var p=this.segments.prepareSegment(l,this.layoutVertexArray,this.indexArray),h=p.vertexLength,f=[],d=[],m=0,g=s;m<g.length;m+=1){var y=g[m];if(0!==y.length){y!==s[0]&&d.push(f.length/2);var v=this.segments2.prepareSegment(y.length,this.layoutVertexArray,this.indexArray2),_=v.vertexLength;this.layoutVertexArray.emplaceBack(y[0].x,y[0].y),this.indexArray2.emplaceBack(_+y.length-1,_),f.push(y[0].x),f.push(y[0].y);for(var b=1;b<y.length;b++)this.layoutVertexArray.emplaceBack(y[b].x,y[b].y),this.indexArray2.emplaceBack(_+b-1,_+b),f.push(y[b].x),f.push(y[b].y);v.vertexLength+=y.length,v.primitiveLength+=y.length}}for(var x=Ca(f,d),w=0;w<x.length;w+=3)this.indexArray.emplaceBack(h+x[w],h+x[w+1],h+x[w+2]);p.vertexLength+=l,p.primitiveLength+=x.length/3}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,t,r,i,n)},zn("FillBucket",ss,{omit:["layers","patternFeatures"]});var ls=new xi({"fill-sort-key":new yi(It.layout_fill["fill-sort-key"])}),us={paint:new xi({"fill-antialias":new gi(It.paint_fill["fill-antialias"]),"fill-opacity":new yi(It.paint_fill["fill-opacity"]),"fill-color":new yi(It.paint_fill["fill-color"]),"fill-outline-color":new yi(It.paint_fill["fill-outline-color"]),"fill-translate":new gi(It.paint_fill["fill-translate"]),"fill-translate-anchor":new gi(It.paint_fill["fill-translate-anchor"]),"fill-pattern":new vi(It.paint_fill["fill-pattern"])}),layout:ls},cs=function(t){function e(e){t.call(this,e,us)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.recalculate=function(e,r){t.prototype.recalculate.call(this,e,r);var n=this.paint._values["fill-outline-color"];"constant"===n.value.kind&&void 0===n.value.value&&(this.paint._values["fill-outline-color"]=this.paint._values["fill-color"])},e.prototype.createBucket=function(t){return new ss(t)},e.prototype.queryRadius=function(){return ra(this.paint.get("fill-translate"))},e.prototype.queryIntersectsFeature=function(t,e,r,n,i,o,a){return Zo(na(t,this.paint.get("fill-translate"),this.paint.get("fill-translate-anchor"),o.angle,a),n)},e.prototype.isTileClipped=function(){return!0},e}(wi),ps=Ci([{name:"a_pos",components:2,type:"Int16"},{name:"a_normal_ed",components:4,type:"Int16"}],4).members,hs=fs;function fs(t,e,r,n,i){this.properties={},this.extent=r,this.type=0,this._pbf=t,this._geometry=-1,this._keys=n,this._values=i,t.readFields(ds,this,e)}function ds(t,e,r){1==t?e.id=r.readVarint():2==t?function(t,e){for(var r=t.readVarint()+t.pos;t.pos<r;){var n=e._keys[t.readVarint()],i=e._values[t.readVarint()];e.properties[n]=i}}(r,e):3==t?e.type=r.readVarint():4==t&&(e._geometry=r.pos)}function ms(t){for(var e,r,n=0,i=0,o=t.length,a=o-1;i<o;a=i++)n+=((r=t[a]).x-(e=t[i]).x)*(e.y+r.y);return n}fs.types=["Unknown","Point","LineString","Polygon"],fs.prototype.loadGeometry=function(){var t=this._pbf;t.pos=this._geometry;for(var e,r=t.readVarint()+t.pos,n=1,o=0,a=0,s=0,l=[];t.pos<r;){if(o<=0){var u=t.readVarint();n=7&u,o=u>>3}if(o--,1===n||2===n)a+=t.readSVarint(),s+=t.readSVarint(),1===n&&(e&&l.push(e),e=[]),e.push(new i(a,s));else{if(7!==n)throw new Error("unknown command "+n);e&&e.push(e[0].clone())}}return e&&l.push(e),l},fs.prototype.bbox=function(){var t=this._pbf;t.pos=this._geometry;for(var e=t.readVarint()+t.pos,r=1,n=0,i=0,o=0,a=1/0,s=-1/0,l=1/0,u=-1/0;t.pos<e;){if(n<=0){var c=t.readVarint();r=7&c,n=c>>3}if(n--,1===r||2===r)(i+=t.readSVarint())<a&&(a=i),i>s&&(s=i),(o+=t.readSVarint())<l&&(l=o),o>u&&(u=o);else if(7!==r)throw new Error("unknown command "+r)}return[a,l,s,u]},fs.prototype.toGeoJSON=function(t,e,r){var n,i,o=this.extent*Math.pow(2,r),a=this.extent*t,s=this.extent*e,l=this.loadGeometry(),u=fs.types[this.type];function c(t){for(var e=0;e<t.length;e++){var r=t[e];t[e]=[360*(r.x+a)/o-180,360/Math.PI*Math.atan(Math.exp((180-360*(r.y+s)/o)*Math.PI/180))-90]}}switch(this.type){case 1:var p=[];for(n=0;n<l.length;n++)p[n]=l[n][0];c(l=p);break;case 2:for(n=0;n<l.length;n++)c(l[n]);break;case 3:for(l=function(t){var e=t.length;if(e<=1)return[t];for(var r,n,i=[],o=0;o<e;o++){var a=ms(t[o]);0!==a&&(void 0===n&&(n=a<0),n===a<0?(r&&i.push(r),r=[t[o]]):r.push(t[o]))}return r&&i.push(r),i}(l),n=0;n<l.length;n++)for(i=0;i<l[n].length;i++)c(l[n][i])}1===l.length?l=l[0]:u="Multi"+u;var h={type:"Feature",geometry:{type:u,coordinates:l},properties:this.properties};return"id"in this&&(h.id=this.id),h};var gs=ys;function ys(t,e){this.version=1,this.name=null,this.extent=4096,this.length=0,this._pbf=t,this._keys=[],this._values=[],this._features=[],t.readFields(vs,this,e),this.length=this._features.length}function vs(t,e,r){15===t?e.version=r.readVarint():1===t?e.name=r.readString():5===t?e.extent=r.readVarint():2===t?e._features.push(r.pos):3===t?e._keys.push(r.readString()):4===t&&e._values.push(function(t){for(var e=null,r=t.readVarint()+t.pos;t.pos<r;){var n=t.readVarint()>>3;e=1===n?t.readString():2===n?t.readFloat():3===n?t.readDouble():4===n?t.readVarint64():5===n?t.readVarint():6===n?t.readSVarint():7===n?t.readBoolean():null}return e}(r))}function _s(t,e,r){if(3===t){var n=new gs(r,r.readVarint()+r.pos);n.length&&(e[n.name]=n)}}ys.prototype.feature=function(t){if(t<0||t>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[t];var e=this._pbf.readVarint()+this._pbf.pos;return new hs(this._pbf,e,this.extent,this._keys,this._values)};var bs={VectorTile:function(t,e){this.layers=t.readFields(_s,{},e)},VectorTileFeature:hs,VectorTileLayer:gs},xs=bs.VectorTileFeature.types,ws=Math.pow(2,13);function Es(t,e,r,n,i,o,a,s){t.emplaceBack(e,r,2*Math.floor(n*ws)+a,i*ws*2,o*ws*2,Math.round(s))}var Ts=function(t){this.zoom=t.zoom,this.overscaling=t.overscaling,this.layers=t.layers,this.layerIds=this.layers.map((function(t){return t.id})),this.index=t.index,this.hasPattern=!1,this.layoutVertexArray=new Di,this.indexArray=new Ui,this.programConfigurations=new Fo(t.layers,t.zoom),this.segments=new so,this.stateDependentLayerIds=this.layers.filter((function(t){return t.isStateDependent()})).map((function(t){return t.id}))};function As(t,e){return t.x===e.x&&(t.x<0||t.x>8192)||t.y===e.y&&(t.y<0||t.y>8192)}Ts.prototype.populate=function(t,e,r){this.features=[],this.hasPattern=os("fill-extrusion",this.layers,e);for(var n=0,i=t;n<i.length;n+=1){var o=i[n],a=o.feature,s=o.id,l=o.index,u=o.sourceLayerIndex,c=this.layers[0]._featureFilter.needGeometry,p=Uo(a,c);if(this.layers[0]._featureFilter.filter(new si(this.zoom),p,r)){var h={id:s,sourceLayerIndex:u,index:l,geometry:c?p.geometry:jo(a),properties:a.properties,type:a.type,patterns:{}};this.hasPattern?this.features.push(as("fill-extrusion",this.layers,h,this.zoom,e)):this.addFeature(h,h.geometry,l,r,{}),e.featureIndex.insert(a,h.geometry,l,u,this.index,!0)}}},Ts.prototype.addFeatures=function(t,e,r){for(var n=0,i=this.features;n<i.length;n+=1){var o=i[n];this.addFeature(o,o.geometry,o.index,e,r)}},Ts.prototype.update=function(t,e,r){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(t,e,this.stateDependentLayers,r)},Ts.prototype.isEmpty=function(){return 0===this.layoutVertexArray.length},Ts.prototype.uploadPending=function(){return!this.uploaded||this.programConfigurations.needsUpload},Ts.prototype.upload=function(t){this.uploaded||(this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,ps),this.indexBuffer=t.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(t),this.uploaded=!0},Ts.prototype.destroy=function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())},Ts.prototype.addFeature=function(t,e,r,n,i){for(var o=0,a=ns(e,500);o<a.length;o+=1){for(var s=a[o],l=0,u=0,c=s;u<c.length;u+=1)l+=c[u].length;for(var p=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray),h=0,f=s;h<f.length;h+=1){var d=f[h];if(0!==d.length&&!((M=d).every((function(t){return t.x<0}))||M.every((function(t){return t.x>8192}))||M.every((function(t){return t.y<0}))||M.every((function(t){return t.y>8192}))))for(var m=0,g=0;g<d.length;g++){var y=d[g];if(g>=1){var v=d[g-1];if(!As(y,v)){p.vertexLength+4>so.MAX_VERTEX_ARRAY_LENGTH&&(p=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));var _=y.sub(v)._perp()._unit(),b=v.dist(y);m+b>32768&&(m=0),Es(this.layoutVertexArray,y.x,y.y,_.x,_.y,0,0,m),Es(this.layoutVertexArray,y.x,y.y,_.x,_.y,0,1,m),Es(this.layoutVertexArray,v.x,v.y,_.x,_.y,0,0,m+=b),Es(this.layoutVertexArray,v.x,v.y,_.x,_.y,0,1,m);var x=p.vertexLength;this.indexArray.emplaceBack(x,x+2,x+1),this.indexArray.emplaceBack(x+1,x+2,x+3),p.vertexLength+=4,p.primitiveLength+=2}}}}if(p.vertexLength+l>so.MAX_VERTEX_ARRAY_LENGTH&&(p=this.segments.prepareSegment(l,this.layoutVertexArray,this.indexArray)),"Polygon"===xs[t.type]){for(var w=[],E=[],T=p.vertexLength,A=0,C=s;A<C.length;A+=1){var S=C[A];if(0!==S.length){S!==s[0]&&E.push(w.length/2);for(var P=0;P<S.length;P++){var I=S[P];Es(this.layoutVertexArray,I.x,I.y,0,0,1,1,0),w.push(I.x),w.push(I.y)}}}for(var D=Ca(w,E),O=0;O<D.length;O+=3)this.indexArray.emplaceBack(T+D[O],T+D[O+2],T+D[O+1]);p.primitiveLength+=D.length/3,p.vertexLength+=l}}var M;this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,t,r,i,n)},zn("FillExtrusionBucket",Ts,{omit:["layers","features"]});var Cs={paint:new xi({"fill-extrusion-opacity":new gi(It["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new yi(It["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new gi(It["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new gi(It["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new vi(It["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new yi(It["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new yi(It["paint_fill-extrusion"]["fill-extrusion-base"]),"fill-extrusion-vertical-gradient":new gi(It["paint_fill-extrusion"]["fill-extrusion-vertical-gradient"])})},Ss=function(t){function e(e){t.call(this,e,Cs)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.createBucket=function(t){return new Ts(t)},e.prototype.queryRadius=function(){return ra(this.paint.get("fill-extrusion-translate"))},e.prototype.is3D=function(){return!0},e.prototype.queryIntersectsFeature=function(t,e,r,n,o,a,s,l){var u=na(t,this.paint.get("fill-extrusion-translate"),this.paint.get("fill-extrusion-translate-anchor"),a.angle,s),c=this.paint.get("fill-extrusion-height").evaluate(e,r),p=this.paint.get("fill-extrusion-base").evaluate(e,r),h=function(t,e,r,n){for(var o=[],a=0,s=t;a<s.length;a+=1){var l=s[a],u=[l.x,l.y,0,1];pa(u,u,e),o.push(new i(u[0]/u[3],u[1]/u[3]))}return o}(u,l),f=function(t,e,r,n){for(var o=[],a=[],s=n[8]*e,l=n[9]*e,u=n[10]*e,c=n[11]*e,p=n[8]*r,h=n[9]*r,f=n[10]*r,d=n[11]*r,m=0,g=t;m<g.length;m+=1){for(var y=[],v=[],_=0,b=g[m];_<b.length;_+=1){var x=b[_],w=x.x,E=x.y,T=n[0]*w+n[4]*E+n[12],A=n[1]*w+n[5]*E+n[13],C=n[2]*w+n[6]*E+n[14],S=n[3]*w+n[7]*E+n[15],P=C+u,I=S+c,D=T+p,O=A+h,M=C+f,B=S+d,k=new i((T+s)/I,(A+l)/I);k.z=P/I,y.push(k);var F=new i(D/B,O/B);F.z=M/B,v.push(F)}o.push(y),a.push(v)}return[o,a]}(n,p,c,l);return function(t,e,r){var n=1/0;Zo(r,e)&&(n=Is(r,e[0]));for(var i=0;i<e.length;i++)for(var o=e[i],a=t[i],s=0;s<o.length-1;s++){var l=o[s],u=[l,o[s+1],a[s+1],a[s],l];Ho(r,u)&&(n=Math.min(n,Is(r,u)))}return n!==1/0&&n}(f[0],f[1],h)},e}(wi);function Ps(t,e){return t.x*e.x+t.y*e.y}function Is(t,e){if(1===t.length){for(var r,n=0,i=e[n++];!r||i.equals(r);)if(!(r=e[n++]))return 1/0;for(;n<e.length;n++){var o=e[n],a=t[0],s=r.sub(i),l=o.sub(i),u=a.sub(i),c=Ps(s,s),p=Ps(s,l),h=Ps(l,l),f=Ps(u,s),d=Ps(u,l),m=c*h-p*p,g=(h*f-p*d)/m,y=(c*d-p*f)/m,v=i.z*(1-g-y)+r.z*g+o.z*y;if(isFinite(v))return v}return 1/0}for(var _=1/0,b=0,x=e;b<x.length;b+=1)_=Math.min(_,x[b].z);return _}var Ds=Ci([{name:"a_pos_normal",components:2,type:"Int16"},{name:"a_data",components:4,type:"Uint8"}],4).members,Os=Ci([{name:"a_uv_x",components:1,type:"Float32"},{name:"a_split_index",components:1,type:"Float32"}]).members,Ms=bs.VectorTileFeature.types,Bs=Math.cos(Math.PI/180*37.5),ks=Math.pow(2,14)/.5,Fs=function(t){var e=this;this.zoom=t.zoom,this.overscaling=t.overscaling,this.layers=t.layers,this.layerIds=this.layers.map((function(t){return t.id})),this.index=t.index,this.hasPattern=!1,this.patternFeatures=[],this.lineClipsArray=[],this.gradients={},this.layers.forEach((function(t){e.gradients[t.id]={}})),this.layoutVertexArray=new Oi,this.layoutVertexArray2=new Mi,this.indexArray=new Ui,this.programConfigurations=new Fo(t.layers,t.zoom),this.segments=new so,this.maxLineLength=0,this.stateDependentLayerIds=this.layers.filter((function(t){return t.isStateDependent()})).map((function(t){return t.id}))};Fs.prototype.populate=function(t,e,r){this.hasPattern=os("line",this.layers,e);for(var n=this.layers[0].layout.get("line-sort-key"),i=[],o=0,a=t;o<a.length;o+=1){var s=a[o],l=s.feature,u=s.id,c=s.index,p=s.sourceLayerIndex,h=this.layers[0]._featureFilter.needGeometry,f=Uo(l,h);if(this.layers[0]._featureFilter.filter(new si(this.zoom),f,r)){var d=n?n.evaluate(f,{},r):void 0,m={id:u,properties:l.properties,type:l.type,sourceLayerIndex:p,index:c,geometry:h?f.geometry:jo(l),patterns:{},sortKey:d};i.push(m)}}n&&i.sort((function(t,e){return t.sortKey-e.sortKey}));for(var g=0,y=i;g<y.length;g+=1){var v=y[g],_=v.geometry,b=v.index,x=v.sourceLayerIndex;if(this.hasPattern){var w=as("line",this.layers,v,this.zoom,e);this.patternFeatures.push(w)}else this.addFeature(v,_,b,r,{});e.featureIndex.insert(t[b].feature,_,b,x,this.index)}},Fs.prototype.update=function(t,e,r){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(t,e,this.stateDependentLayers,r)},Fs.prototype.addFeatures=function(t,e,r){for(var n=0,i=this.patternFeatures;n<i.length;n+=1){var o=i[n];this.addFeature(o,o.geometry,o.index,e,r)}},Fs.prototype.isEmpty=function(){return 0===this.layoutVertexArray.length},Fs.prototype.uploadPending=function(){return!this.uploaded||this.programConfigurations.needsUpload},Fs.prototype.upload=function(t){this.uploaded||(0!==this.layoutVertexArray2.length&&(this.layoutVertexBuffer2=t.createVertexBuffer(this.layoutVertexArray2,Os)),this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,Ds),this.indexBuffer=t.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(t),this.uploaded=!0},Fs.prototype.destroy=function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())},Fs.prototype.lineFeatureClips=function(t){if(t.properties&&t.properties.hasOwnProperty("mapbox_clip_start")&&t.properties.hasOwnProperty("mapbox_clip_end"))return{start:+t.properties.mapbox_clip_start,end:+t.properties.mapbox_clip_end}},Fs.prototype.addFeature=function(t,e,r,n,i){var o=this.layers[0].layout,a=o.get("line-join").evaluate(t,{}),s=o.get("line-cap"),l=o.get("line-miter-limit"),u=o.get("line-round-limit");this.lineClips=this.lineFeatureClips(t);for(var c=0,p=e;c<p.length;c+=1)this.addLine(p[c],t,a,s,l,u);this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,t,r,i,n)},Fs.prototype.addLine=function(t,e,r,n,i,o){if(this.distance=0,this.scaledDistance=0,this.totalDistance=0,this.lineClips){this.lineClipsArray.push(this.lineClips);for(var a=0;a<t.length-1;a++)this.totalDistance+=t[a].dist(t[a+1]);this.updateScaledDistance(),this.maxLineLength=Math.max(this.maxLineLength,this.totalDistance)}for(var s="Polygon"===Ms[e.type],l=t.length;l>=2&&t[l-1].equals(t[l-2]);)l--;for(var u=0;u<l-1&&t[u].equals(t[u+1]);)u++;if(!(l<(s?3:2))){"bevel"===r&&(i=1.05);var c,p=this.overscaling<=16?122880/(512*this.overscaling):0,h=this.segments.prepareSegment(10*l,this.layoutVertexArray,this.indexArray),f=void 0,d=void 0,m=void 0,g=void 0;this.e1=this.e2=-1,s&&(g=t[u].sub(c=t[l-2])._unit()._perp());for(var y=u;y<l;y++)if(!(d=y===l-1?s?t[u+1]:void 0:t[y+1])||!t[y].equals(d)){g&&(m=g),c&&(f=c),c=t[y],g=d?d.sub(c)._unit()._perp():m;var v=(m=m||g).add(g);0===v.x&&0===v.y||v._unit();var _=m.x*g.x+m.y*g.y,b=v.x*g.x+v.y*g.y,x=0!==b?1/b:1/0,w=2*Math.sqrt(2-2*b),E=b<Bs&&f&&d,T=m.x*g.y-m.y*g.x>0;if(E&&y>u){var A=c.dist(f);if(A>2*p){var C=c.sub(c.sub(f)._mult(p/A)._round());this.updateDistance(f,C),this.addCurrentVertex(C,m,0,0,h),f=C}}var S=f&&d,P=S?r:s?"butt":n;if(S&&"round"===P&&(x<o?P="miter":x<=2&&(P="fakeround")),"miter"===P&&x>i&&(P="bevel"),"bevel"===P&&(x>2&&(P="flipbevel"),x<i&&(P="miter")),f&&this.updateDistance(f,c),"miter"===P)v._mult(x),this.addCurrentVertex(c,v,0,0,h);else if("flipbevel"===P){if(x>100)v=g.mult(-1);else{var I=x*m.add(g).mag()/m.sub(g).mag();v._perp()._mult(I*(T?-1:1))}this.addCurrentVertex(c,v,0,0,h),this.addCurrentVertex(c,v.mult(-1),0,0,h)}else if("bevel"===P||"fakeround"===P){var D=-Math.sqrt(x*x-1),O=T?D:0,M=T?0:D;if(f&&this.addCurrentVertex(c,m,O,M,h),"fakeround"===P)for(var B=Math.round(180*w/Math.PI/20),k=1;k<B;k++){var F=k/B;if(.5!==F){var L=F-.5;F+=F*L*(F-1)*((1.0904+_*(_*(3.55645-1.43519*_)-3.2452))*L*L+(.848013+_*(.215638*_-1.06021)))}var R=g.sub(m)._mult(F)._add(m)._unit()._mult(T?-1:1);this.addHalfVertex(c,R.x,R.y,!1,T,0,h)}d&&this.addCurrentVertex(c,g,-O,-M,h)}else if("butt"===P)this.addCurrentVertex(c,v,0,0,h);else if("square"===P){var z=f?1:-1;this.addCurrentVertex(c,v,z,z,h)}else"round"===P&&(f&&(this.addCurrentVertex(c,m,0,0,h),this.addCurrentVertex(c,m,1,1,h,!0)),d&&(this.addCurrentVertex(c,g,-1,-1,h,!0),this.addCurrentVertex(c,g,0,0,h)));if(E&&y<l-1){var N=c.dist(d);if(N>2*p){var j=c.add(d.sub(c)._mult(p/N)._round());this.updateDistance(c,j),this.addCurrentVertex(j,g,0,0,h),c=j}}}}},Fs.prototype.addCurrentVertex=function(t,e,r,n,i,o){void 0===o&&(o=!1);var a=e.y*n-e.x,s=-e.y-e.x*n;this.addHalfVertex(t,e.x+e.y*r,e.y-e.x*r,o,!1,r,i),this.addHalfVertex(t,a,s,o,!0,-n,i),this.distance>ks/2&&0===this.totalDistance&&(this.distance=0,this.addCurrentVertex(t,e,r,n,i,o))},Fs.prototype.addHalfVertex=function(t,e,r,n,i,o,a){var s=.5*(this.lineClips?this.scaledDistance*(ks-1):this.scaledDistance);this.layoutVertexArray.emplaceBack((t.x<<1)+(n?1:0),(t.y<<1)+(i?1:0),Math.round(63*e)+128,Math.round(63*r)+128,1+(0===o?0:o<0?-1:1)|(63&s)<<2,s>>6),this.lineClips&&this.layoutVertexArray2.emplaceBack((this.scaledDistance-this.lineClips.start)/(this.lineClips.end-this.lineClips.start),this.lineClipsArray.length);var l=a.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,this.e2,l),a.primitiveLength++),i?this.e2=l:this.e1=l},Fs.prototype.updateScaledDistance=function(){this.scaledDistance=this.lineClips?this.lineClips.start+(this.lineClips.end-this.lineClips.start)*this.distance/this.totalDistance:this.distance},Fs.prototype.updateDistance=function(t,e){this.distance+=t.dist(e),this.updateScaledDistance()},zn("LineBucket",Fs,{omit:["layers","patternFeatures"]});var Ls=new xi({"line-cap":new gi(It.layout_line["line-cap"]),"line-join":new yi(It.layout_line["line-join"]),"line-miter-limit":new gi(It.layout_line["line-miter-limit"]),"line-round-limit":new gi(It.layout_line["line-round-limit"]),"line-sort-key":new yi(It.layout_line["line-sort-key"])}),Rs={paint:new xi({"line-opacity":new yi(It.paint_line["line-opacity"]),"line-color":new yi(It.paint_line["line-color"]),"line-translate":new gi(It.paint_line["line-translate"]),"line-translate-anchor":new gi(It.paint_line["line-translate-anchor"]),"line-width":new yi(It.paint_line["line-width"]),"line-gap-width":new yi(It.paint_line["line-gap-width"]),"line-offset":new yi(It.paint_line["line-offset"]),"line-blur":new yi(It.paint_line["line-blur"]),"line-dasharray":new _i(It.paint_line["line-dasharray"]),"line-pattern":new vi(It.paint_line["line-pattern"]),"line-gradient":new bi(It.paint_line["line-gradient"])}),layout:Ls},zs=new(function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.possiblyEvaluate=function(e,r){return r=new si(Math.floor(r.zoom),{now:r.now,fadeDuration:r.fadeDuration,zoomHistory:r.zoomHistory,transition:r.transition}),t.prototype.possiblyEvaluate.call(this,e,r)},e.prototype.evaluate=function(e,r,n,i){return r=h({},r,{zoom:Math.floor(r.zoom)}),t.prototype.evaluate.call(this,e,r,n,i)},e}(yi))(Rs.paint.properties["line-width"].specification);zs.useIntegerZoom=!0;var Ns=function(t){function e(e){t.call(this,e,Rs),this.gradientVersion=0}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._handleSpecialPaintPropertyUpdate=function(t){"line-gradient"===t&&(this.stepInterpolant=this._transitionablePaint._values["line-gradient"].value.expression._styleExpression.expression instanceof qe,this.gradientVersion=(this.gradientVersion+1)%s)},e.prototype.gradientExpression=function(){return this._transitionablePaint._values["line-gradient"].value.expression},e.prototype.recalculate=function(e,r){t.prototype.recalculate.call(this,e,r),this.paint._values["line-floorwidth"]=zs.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,e)},e.prototype.createBucket=function(t){return new Fs(t)},e.prototype.queryRadius=function(t){var e=t,r=js(ea("line-width",this,e),ea("line-gap-width",this,e)),n=ea("line-offset",this,e);return r/2+Math.abs(n)+ra(this.paint.get("line-translate"))},e.prototype.queryIntersectsFeature=function(t,e,r,n,o,a,s){var l=na(t,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),a.angle,s),u=s/2*js(this.paint.get("line-width").evaluate(e,r),this.paint.get("line-gap-width").evaluate(e,r)),c=this.paint.get("line-offset").evaluate(e,r);return c&&(n=function(t,e){for(var r=[],n=new i(0,0),o=0;o<t.length;o++){for(var a=t[o],s=[],l=0;l<a.length;l++){var u=a[l],c=a[l+1],p=0===l?n:u.sub(a[l-1])._unit()._perp(),h=l===a.length-1?n:c.sub(u)._unit()._perp(),f=p._add(h)._unit();f._mult(1/(f.x*h.x+f.y*h.y)),s.push(f._mult(e)._add(u))}r.push(s)}return r}(n,c*s)),function(t,e,r){for(var n=0;n<e.length;n++){var i=e[n];if(t.length>=3)for(var o=0;o<i.length;o++)if($o(t,i[o]))return!0;if(Wo(t,i,r))return!0}return!1}(l,n,u)},e.prototype.isTileClipped=function(){return!0},e}(wi);function js(t,e){return e>0?e+2*t:t}var Us=Ci([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"}],4),Vs=Ci([{name:"a_projected_pos",components:3,type:"Float32"}],4),qs=(Ci([{name:"a_fade_opacity",components:1,type:"Uint32"}],4),Ci([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"}])),Hs=(Ci([{type:"Int16",name:"anchorPointX"},{type:"Int16",name:"anchorPointY"},{type:"Int16",name:"x1"},{type:"Int16",name:"y1"},{type:"Int16",name:"x2"},{type:"Int16",name:"y2"},{type:"Uint32",name:"featureIndex"},{type:"Uint16",name:"sourceLayerIndex"},{type:"Uint16",name:"bucketIndex"}]),Ci([{name:"a_pos",components:2,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4)),Gs=Ci([{name:"a_pos",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);function Zs(t,e,r){return t.sections.forEach((function(t){t.text=function(t,e,r){var n=e.layout.get("text-transform").evaluate(r,{});return"uppercase"===n?t=t.toLocaleUpperCase():"lowercase"===n&&(t=t.toLocaleLowerCase()),ai.applyArabicShaping&&(t=ai.applyArabicShaping(t)),t}(t.text,e,r)})),t}Ci([{name:"triangle",components:3,type:"Uint16"}]),Ci([{type:"Int16",name:"anchorX"},{type:"Int16",name:"anchorY"},{type:"Uint16",name:"glyphStartIndex"},{type:"Uint16",name:"numGlyphs"},{type:"Uint32",name:"vertexStartIndex"},{type:"Uint32",name:"lineStartIndex"},{type:"Uint32",name:"lineLength"},{type:"Uint16",name:"segment"},{type:"Uint16",name:"lowerSize"},{type:"Uint16",name:"upperSize"},{type:"Float32",name:"lineOffsetX"},{type:"Float32",name:"lineOffsetY"},{type:"Uint8",name:"writingMode"},{type:"Uint8",name:"placedOrientation"},{type:"Uint8",name:"hidden"},{type:"Uint32",name:"crossTileID"},{type:"Int16",name:"associatedIconIndex"}]),Ci([{type:"Int16",name:"anchorX"},{type:"Int16",name:"anchorY"},{type:"Int16",name:"rightJustifiedTextSymbolIndex"},{type:"Int16",name:"centerJustifiedTextSymbolIndex"},{type:"Int16",name:"leftJustifiedTextSymbolIndex"},{type:"Int16",name:"verticalPlacedTextSymbolIndex"},{type:"Int16",name:"placedIconSymbolIndex"},{type:"Int16",name:"verticalPlacedIconSymbolIndex"},{type:"Uint16",name:"key"},{type:"Uint16",name:"textBoxStartIndex"},{type:"Uint16",name:"textBoxEndIndex"},{type:"Uint16",name:"verticalTextBoxStartIndex"},{type:"Uint16",name:"verticalTextBoxEndIndex"},{type:"Uint16",name:"iconBoxStartIndex"},{type:"Uint16",name:"iconBoxEndIndex"},{type:"Uint16",name:"verticalIconBoxStartIndex"},{type:"Uint16",name:"verticalIconBoxEndIndex"},{type:"Uint16",name:"featureIndex"},{type:"Uint16",name:"numHorizontalGlyphVertices"},{type:"Uint16",name:"numVerticalGlyphVertices"},{type:"Uint16",name:"numIconVertices"},{type:"Uint16",name:"numVerticalIconVertices"},{type:"Uint16",name:"useRuntimeCollisionCircles"},{type:"Uint32",name:"crossTileID"},{type:"Float32",name:"textBoxScale"},{type:"Float32",components:2,name:"textOffset"},{type:"Float32",name:"collisionCircleDiameter"}]),Ci([{type:"Float32",name:"offsetX"}]),Ci([{type:"Int16",name:"x"},{type:"Int16",name:"y"},{type:"Int16",name:"tileUnitDistanceFromAnchor"}]);var Ws={"!":"︕","#":"#",$:"$","%":"%","&":"&","(":"︵",")":"︶","*":"*","+":"+",",":"︐","-":"︲",".":"・","/":"/",":":"︓",";":"︔","<":"︿","=":"=",">":"﹀","?":"︖","@":"@","[":"﹇","\\":"\","]":"﹈","^":"^",_:"︳","`":"`","{":"︷","|":"―","}":"︸","~":"~","¢":"¢","£":"£","¥":"¥","¦":"¦","¬":"¬","¯":" ̄","–":"︲","—":"︱","‘":"﹃","’":"﹄","“":"﹁","”":"﹂","…":"︙","‧":"・","₩":"₩","、":"︑","。":"︒","〈":"︿","〉":"﹀","《":"︽","》":"︾","「":"﹁","」":"﹂","『":"﹃","』":"﹄","【":"︻","】":"︼","〔":"︹","〕":"︺","〖":"︗","〗":"︘","!":"︕","(":"︵",")":"︶",",":"︐","-":"︲",".":"・",":":"︓",";":"︔","<":"︿",">":"﹀","?":"︖","[":"﹇","]":"﹈","_":"︳","{":"︷","|":"―","}":"︸","⦅":"︵","⦆":"︶","。":"︒","「":"﹁","」":"﹂"},Ys=function(t,e,r,n,i){var o,a,s=8*i-n-1,l=(1<<s)-1,u=l>>1,c=-7,p=r?i-1:0,h=r?-1:1,f=t[e+p];for(p+=h,o=f&(1<<-c)-1,f>>=-c,c+=s;c>0;o=256*o+t[e+p],p+=h,c-=8);for(a=o&(1<<-c)-1,o>>=-c,c+=n;c>0;a=256*a+t[e+p],p+=h,c-=8);if(0===o)o=1-u;else{if(o===l)return a?NaN:1/0*(f?-1:1);a+=Math.pow(2,n),o-=u}return(f?-1:1)*a*Math.pow(2,o-n)},Xs=function(t,e,r,n,i,o){var a,s,l,u=8*o-i-1,c=(1<<u)-1,p=c>>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,f=n?0:o-1,d=n?1:-1,m=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=c):(a=Math.floor(Math.log(e)/Math.LN2),e*(l=Math.pow(2,-a))<1&&(a--,l*=2),(e+=a+p>=1?h/l:h*Math.pow(2,1-p))*l>=2&&(a++,l/=2),a+p>=c?(s=0,a=c):a+p>=1?(s=(e*l-1)*Math.pow(2,i),a+=p):(s=e*Math.pow(2,p-1)*Math.pow(2,i),a=0));i>=8;t[r+f]=255&s,f+=d,s/=256,i-=8);for(a=a<<i|s,u+=i;u>0;t[r+f]=255&a,f+=d,a/=256,u-=8);t[r+f-d]|=128*m},Ks=Js;function Js(t){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(t)?t:new Uint8Array(t||0),this.pos=0,this.type=0,this.length=this.buf.length}Js.Varint=0,Js.Fixed64=1,Js.Bytes=2,Js.Fixed32=5;var Qs="undefined"==typeof TextDecoder?null:new TextDecoder("utf8");function $s(t){return t.type===Js.Bytes?t.readVarint()+t.pos:t.pos+1}function tl(t,e,r){return r?4294967296*e+(t>>>0):4294967296*(e>>>0)+(t>>>0)}function el(t,e,r){var n=e<=16383?1:e<=2097151?2:e<=268435455?3:Math.floor(Math.log(e)/(7*Math.LN2));r.realloc(n);for(var i=r.pos-1;i>=t;i--)r.buf[i+n]=r.buf[i]}function rl(t,e){for(var r=0;r<t.length;r++)e.writeVarint(t[r])}function nl(t,e){for(var r=0;r<t.length;r++)e.writeSVarint(t[r])}function il(t,e){for(var r=0;r<t.length;r++)e.writeFloat(t[r])}function ol(t,e){for(var r=0;r<t.length;r++)e.writeDouble(t[r])}function al(t,e){for(var r=0;r<t.length;r++)e.writeBoolean(t[r])}function sl(t,e){for(var r=0;r<t.length;r++)e.writeFixed32(t[r])}function ll(t,e){for(var r=0;r<t.length;r++)e.writeSFixed32(t[r])}function ul(t,e){for(var r=0;r<t.length;r++)e.writeFixed64(t[r])}function cl(t,e){for(var r=0;r<t.length;r++)e.writeSFixed64(t[r])}function pl(t,e){return(t[e]|t[e+1]<<8|t[e+2]<<16)+16777216*t[e+3]}function hl(t,e,r){t[r]=e,t[r+1]=e>>>8,t[r+2]=e>>>16,t[r+3]=e>>>24}function fl(t,e){return(t[e]|t[e+1]<<8|t[e+2]<<16)+(t[e+3]<<24)}function dl(t,e,r){1===t&&r.readMessage(ml,e)}function ml(t,e,r){if(3===t){var n=r.readMessage(gl,{}),i=n.width,o=n.height,a=n.left,s=n.top,l=n.advance;e.push({id:n.id,bitmap:new va({width:i+6,height:o+6},n.bitmap),metrics:{width:i,height:o,left:a,top:s,advance:l}})}}function gl(t,e,r){1===t?e.id=r.readVarint():2===t?e.bitmap=r.readBytes():3===t?e.width=r.readVarint():4===t?e.height=r.readVarint():5===t?e.left=r.readSVarint():6===t?e.top=r.readSVarint():7===t&&(e.advance=r.readVarint())}function yl(t){for(var e=0,r=0,n=0,i=t;n<i.length;n+=1){var o=i[n];e+=o.w*o.h,r=Math.max(r,o.w)}t.sort((function(t,e){return e.h-t.h}));for(var a=[{x:0,y:0,w:Math.max(Math.ceil(Math.sqrt(e/.95)),r),h:1/0}],s=0,l=0,u=0,c=t;u<c.length;u+=1)for(var p=c[u],h=a.length-1;h>=0;h--){var f=a[h];if(!(p.w>f.w||p.h>f.h)){if(p.x=f.x,p.y=f.y,l=Math.max(l,p.y+p.h),s=Math.max(s,p.x+p.w),p.w===f.w&&p.h===f.h){var d=a.pop();h<a.length&&(a[h]=d)}else p.h===f.h?(f.x+=p.w,f.w-=p.w):p.w===f.w?(f.y+=p.h,f.h-=p.h):(a.push({x:f.x+p.w,y:f.y,w:f.w-p.w,h:p.h}),f.y+=p.h,f.h-=p.h);break}}return{w:s,h:l,fill:e/(s*l)||0}}Js.prototype={destroy:function(){this.buf=null},readFields:function(t,e,r){for(r=r||this.length;this.pos<r;){var n=this.readVarint(),i=n>>3,o=this.pos;this.type=7&n,t(i,e,this),this.pos===o&&this.skip(n)}return e},readMessage:function(t,e){return this.readFields(t,e,this.readVarint()+this.pos)},readFixed32:function(){var t=pl(this.buf,this.pos);return this.pos+=4,t},readSFixed32:function(){var t=fl(this.buf,this.pos);return this.pos+=4,t},readFixed64:function(){var t=pl(this.buf,this.pos)+4294967296*pl(this.buf,this.pos+4);return this.pos+=8,t},readSFixed64:function(){var t=pl(this.buf,this.pos)+4294967296*fl(this.buf,this.pos+4);return this.pos+=8,t},readFloat:function(){var t=Ys(this.buf,this.pos,!0,23,4);return this.pos+=4,t},readDouble:function(){var t=Ys(this.buf,this.pos,!0,52,8);return this.pos+=8,t},readVarint:function(t){var e,r,n=this.buf;return e=127&(r=n[this.pos++]),r<128?e:(e|=(127&(r=n[this.pos++]))<<7,r<128?e:(e|=(127&(r=n[this.pos++]))<<14,r<128?e:(e|=(127&(r=n[this.pos++]))<<21,r<128?e:function(t,e,r){var n,i,o=r.buf;if(n=(112&(i=o[r.pos++]))>>4,i<128)return tl(t,n,e);if(n|=(127&(i=o[r.pos++]))<<3,i<128)return tl(t,n,e);if(n|=(127&(i=o[r.pos++]))<<10,i<128)return tl(t,n,e);if(n|=(127&(i=o[r.pos++]))<<17,i<128)return tl(t,n,e);if(n|=(127&(i=o[r.pos++]))<<24,i<128)return tl(t,n,e);if(n|=(1&(i=o[r.pos++]))<<31,i<128)return tl(t,n,e);throw new Error("Expected varint not more than 10 bytes")}(e|=(15&(r=n[this.pos]))<<28,t,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var t=this.readVarint();return t%2==1?(t+1)/-2:t/2},readBoolean:function(){return Boolean(this.readVarint())},readString:function(){var t=this.readVarint()+this.pos,e=this.pos;return this.pos=t,t-e>=12&&Qs?function(t,e,r){return Qs.decode(t.subarray(e,r))}(this.buf,e,t):function(t,e,r){for(var n="",i=e;i<r;){var o,a,s,l=t[i],u=null,c=l>239?4:l>223?3:l>191?2:1;if(i+c>r)break;1===c?l<128&&(u=l):2===c?128==(192&(o=t[i+1]))&&(u=(31&l)<<6|63&o)<=127&&(u=null):3===c?(a=t[i+2],128==(192&(o=t[i+1]))&&128==(192&a)&&((u=(15&l)<<12|(63&o)<<6|63&a)<=2047||u>=55296&&u<=57343)&&(u=null)):4===c&&(a=t[i+2],s=t[i+3],128==(192&(o=t[i+1]))&&128==(192&a)&&128==(192&s)&&((u=(15&l)<<18|(63&o)<<12|(63&a)<<6|63&s)<=65535||u>=1114112)&&(u=null)),null===u?(u=65533,c=1):u>65535&&(u-=65536,n+=String.fromCharCode(u>>>10&1023|55296),u=56320|1023&u),n+=String.fromCharCode(u),i+=c}return n}(this.buf,e,t)},readBytes:function(){var t=this.readVarint()+this.pos,e=this.buf.subarray(this.pos,t);return this.pos=t,e},readPackedVarint:function(t,e){if(this.type!==Js.Bytes)return t.push(this.readVarint(e));var r=$s(this);for(t=t||[];this.pos<r;)t.push(this.readVarint(e));return t},readPackedSVarint:function(t){if(this.type!==Js.Bytes)return t.push(this.readSVarint());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readSVarint());return t},readPackedBoolean:function(t){if(this.type!==Js.Bytes)return t.push(this.readBoolean());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readBoolean());return t},readPackedFloat:function(t){if(this.type!==Js.Bytes)return t.push(this.readFloat());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readFloat());return t},readPackedDouble:function(t){if(this.type!==Js.Bytes)return t.push(this.readDouble());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readDouble());return t},readPackedFixed32:function(t){if(this.type!==Js.Bytes)return t.push(this.readFixed32());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readFixed32());return t},readPackedSFixed32:function(t){if(this.type!==Js.Bytes)return t.push(this.readSFixed32());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readSFixed32());return t},readPackedFixed64:function(t){if(this.type!==Js.Bytes)return t.push(this.readFixed64());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readFixed64());return t},readPackedSFixed64:function(t){if(this.type!==Js.Bytes)return t.push(this.readSFixed64());var e=$s(this);for(t=t||[];this.pos<e;)t.push(this.readSFixed64());return t},skip:function(t){var e=7&t;if(e===Js.Varint)for(;this.buf[this.pos++]>127;);else if(e===Js.Bytes)this.pos=this.readVarint()+this.pos;else if(e===Js.Fixed32)this.pos+=4;else{if(e!==Js.Fixed64)throw new Error("Unimplemented type: "+e);this.pos+=8}},writeTag:function(t,e){this.writeVarint(t<<3|e)},realloc:function(t){for(var e=this.length||16;e<this.pos+t;)e*=2;if(e!==this.length){var r=new Uint8Array(e);r.set(this.buf),this.buf=r,this.length=e}},finish:function(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)},writeFixed32:function(t){this.realloc(4),hl(this.buf,t,this.pos),this.pos+=4},writeSFixed32:function(t){this.realloc(4),hl(this.buf,t,this.pos),this.pos+=4},writeFixed64:function(t){this.realloc(8),hl(this.buf,-1&t,this.pos),hl(this.buf,Math.floor(t*(1/4294967296)),this.pos+4),this.pos+=8},writeSFixed64:function(t){this.realloc(8),hl(this.buf,-1&t,this.pos),hl(this.buf,Math.floor(t*(1/4294967296)),this.pos+4),this.pos+=8},writeVarint:function(t){(t=+t||0)>268435455||t<0?function(t,e){var r,n;if(t>=0?(r=t%4294967296|0,n=t/4294967296|0):(n=~(-t/4294967296),4294967295^(r=~(-t%4294967296))?r=r+1|0:(r=0,n=n+1|0)),t>=0x10000000000000000||t<-0x10000000000000000)throw new Error("Given varint doesn't fit into 10 bytes");e.realloc(10),function(t,e,r){r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos++]=127&t|128,r.buf[r.pos]=127&(t>>>=7)}(r,0,e),function(t,e){var r=(7&t)<<4;e.buf[e.pos++]|=r|((t>>>=3)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t)))))}(n,e)}(t,this):(this.realloc(4),this.buf[this.pos++]=127&t|(t>127?128:0),t<=127||(this.buf[this.pos++]=127&(t>>>=7)|(t>127?128:0),t<=127||(this.buf[this.pos++]=127&(t>>>=7)|(t>127?128:0),t<=127||(this.buf[this.pos++]=t>>>7&127))))},writeSVarint:function(t){this.writeVarint(t<0?2*-t-1:2*t)},writeBoolean:function(t){this.writeVarint(Boolean(t))},writeString:function(t){t=String(t),this.realloc(4*t.length),this.pos++;var e=this.pos;this.pos=function(t,e,r){for(var n,i,o=0;o<e.length;o++){if((n=e.charCodeAt(o))>55295&&n<57344){if(!i){n>56319||o+1===e.length?(t[r++]=239,t[r++]=191,t[r++]=189):i=n;continue}if(n<56320){t[r++]=239,t[r++]=191,t[r++]=189,i=n;continue}n=i-55296<<10|n-56320|65536,i=null}else i&&(t[r++]=239,t[r++]=191,t[r++]=189,i=null);n<128?t[r++]=n:(n<2048?t[r++]=n>>6|192:(n<65536?t[r++]=n>>12|224:(t[r++]=n>>18|240,t[r++]=n>>12&63|128),t[r++]=n>>6&63|128),t[r++]=63&n|128)}return r}(this.buf,t,this.pos);var r=this.pos-e;r>=128&&el(e,r,this),this.pos=e-1,this.writeVarint(r),this.pos+=r},writeFloat:function(t){this.realloc(4),Xs(this.buf,t,this.pos,!0,23,4),this.pos+=4},writeDouble:function(t){this.realloc(8),Xs(this.buf,t,this.pos,!0,52,8),this.pos+=8},writeBytes:function(t){var e=t.length;this.writeVarint(e),this.realloc(e);for(var r=0;r<e;r++)this.buf[this.pos++]=t[r]},writeRawMessage:function(t,e){this.pos++;var r=this.pos;t(e,this);var n=this.pos-r;n>=128&&el(r,n,this),this.pos=r-1,this.writeVarint(n),this.pos+=n},writeMessage:function(t,e,r){this.writeTag(t,Js.Bytes),this.writeRawMessage(e,r)},writePackedVarint:function(t,e){e.length&&this.writeMessage(t,rl,e)},writePackedSVarint:function(t,e){e.length&&this.writeMessage(t,nl,e)},writePackedBoolean:function(t,e){e.length&&this.writeMessage(t,al,e)},writePackedFloat:function(t,e){e.length&&this.writeMessage(t,il,e)},writePackedDouble:function(t,e){e.length&&this.writeMessage(t,ol,e)},writePackedFixed32:function(t,e){e.length&&this.writeMessage(t,sl,e)},writePackedSFixed32:function(t,e){e.length&&this.writeMessage(t,ll,e)},writePackedFixed64:function(t,e){e.length&&this.writeMessage(t,ul,e)},writePackedSFixed64:function(t,e){e.length&&this.writeMessage(t,cl,e)},writeBytesField:function(t,e){this.writeTag(t,Js.Bytes),this.writeBytes(e)},writeFixed32Field:function(t,e){this.writeTag(t,Js.Fixed32),this.writeFixed32(e)},writeSFixed32Field:function(t,e){this.writeTag(t,Js.Fixed32),this.writeSFixed32(e)},writeFixed64Field:function(t,e){this.writeTag(t,Js.Fixed64),this.writeFixed64(e)},writeSFixed64Field:function(t,e){this.writeTag(t,Js.Fixed64),this.writeSFixed64(e)},writeVarintField:function(t,e){this.writeTag(t,Js.Varint),this.writeVarint(e)},writeSVarintField:function(t,e){this.writeTag(t,Js.Varint),this.writeSVarint(e)},writeStringField:function(t,e){this.writeTag(t,Js.Bytes),this.writeString(e)},writeFloatField:function(t,e){this.writeTag(t,Js.Fixed32),this.writeFloat(e)},writeDoubleField:function(t,e){this.writeTag(t,Js.Fixed64),this.writeDouble(e)},writeBooleanField:function(t,e){this.writeVarintField(t,Boolean(e))}};var vl=function(t,e){var r=e.pixelRatio,n=e.version,i=e.stretchX,o=e.stretchY,a=e.content;this.paddedRect=t,this.pixelRatio=r,this.stretchX=i,this.stretchY=o,this.content=a,this.version=n},_l={tl:{configurable:!0},br:{configurable:!0},tlbr:{configurable:!0},displaySize:{configurable:!0}};_l.tl.get=function(){return[this.paddedRect.x+1,this.paddedRect.y+1]},_l.br.get=function(){return[this.paddedRect.x+this.paddedRect.w-1,this.paddedRect.y+this.paddedRect.h-1]},_l.tlbr.get=function(){return this.tl.concat(this.br)},_l.displaySize.get=function(){return[(this.paddedRect.w-2)/this.pixelRatio,(this.paddedRect.h-2)/this.pixelRatio]},Object.defineProperties(vl.prototype,_l);var bl=function(t,e){var r={},n={};this.haveRenderCallbacks=[];var i=[];this.addImages(t,r,i),this.addImages(e,n,i);var o=yl(i),a=new _a({width:o.w||1,height:o.h||1});for(var s in t){var l=t[s],u=r[s].paddedRect;_a.copy(l.data,a,{x:0,y:0},{x:u.x+1,y:u.y+1},l.data)}for(var c in e){var p=e[c],h=n[c].paddedRect,f=h.x+1,d=h.y+1,m=p.data.width,g=p.data.height;_a.copy(p.data,a,{x:0,y:0},{x:f,y:d},p.data),_a.copy(p.data,a,{x:0,y:g-1},{x:f,y:d-1},{width:m,height:1}),_a.copy(p.data,a,{x:0,y:0},{x:f,y:d+g},{width:m,height:1}),_a.copy(p.data,a,{x:m-1,y:0},{x:f-1,y:d},{width:1,height:g}),_a.copy(p.data,a,{x:0,y:0},{x:f+m,y:d},{width:1,height:g})}this.image=a,this.iconPositions=r,this.patternPositions=n};bl.prototype.addImages=function(t,e,r){for(var n in t){var i=t[n],o={x:0,y:0,w:i.data.width+2,h:i.data.height+2};r.push(o),e[n]=new vl(o,i),i.hasRenderCallback&&this.haveRenderCallbacks.push(n)}},bl.prototype.patchUpdatedImages=function(t,e){for(var r in t.dispatchRenderCallbacks(this.haveRenderCallbacks),t.updatedImages)this.patchUpdatedImage(this.iconPositions[r],t.getImage(r),e),this.patchUpdatedImage(this.patternPositions[r],t.getImage(r),e)},bl.prototype.patchUpdatedImage=function(t,e,r){if(t&&e&&t.version!==e.version){t.version=e.version;var n=t.tl;r.update(e.data,void 0,{x:n[0],y:n[1]})}},zn("ImagePosition",vl),zn("ImageAtlas",bl);var xl={horizontal:1,vertical:2,horizontalOnly:3},wl=function(){this.scale=1,this.fontStack="",this.imageName=null};wl.forText=function(t,e){var r=new wl;return r.scale=t||1,r.fontStack=e,r},wl.forImage=function(t){var e=new wl;return e.imageName=t,e};var El=function(){this.text="",this.sectionIndex=[],this.sections=[],this.imageSectionID=null};function Tl(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m){var g,y=El.fromFeature(t,i);p===xl.vertical&&y.verticalizePunctuation();var v=ai.processBidirectionalText,_=ai.processStyledBidirectionalText;if(v&&1===y.sections.length){g=[];for(var b=0,x=v(y.toString(),Ol(y,u,o,e,n,f,d));b<x.length;b+=1){var w=x[b],E=new El;E.text=w,E.sections=y.sections;for(var T=0;T<w.length;T++)E.sectionIndex.push(0);g.push(E)}}else if(_){g=[];for(var A=0,C=_(y.text,y.sectionIndex,Ol(y,u,o,e,n,f,d));A<C.length;A+=1){var S=C[A],P=new El;P.text=S[0],P.sectionIndex=S[1],P.sections=y.sections,g.push(P)}}else g=function(t,e){for(var r=[],n=t.text,i=0,o=0,a=e;o<a.length;o+=1){var s=a[o];r.push(t.substring(i,s)),i=s}return i<n.length&&r.push(t.substring(i,n.length)),r}(y,Ol(y,u,o,e,n,f,d));var I=[],D={positionedLines:I,text:y.toString(),top:c[1],bottom:c[1],left:c[0],right:c[0],writingMode:p,iconsInText:!1,verticalizable:!1};return function(t,e,r,n,i,o,a,s,l,u,c,p){for(var h=0,f=-17,d=0,m=0,g="right"===s?1:"left"===s?0:.5,y=0,v=0,_=i;v<_.length;v+=1){var b=_[v];b.trim();var x=b.getMaxScale(),w=24*(x-1),E={positionedGlyphs:[],lineOffset:0};t.positionedLines[y]=E;var T=E.positionedGlyphs,A=0;if(b.length()){for(var C=0;C<b.length();C++){var S=b.getSection(C),P=b.getSectionIndex(C),I=b.getCharCode(C),D=0,O=null,M=null,B=null,k=24,F=!(l===xl.horizontal||!c&&!Wn(I)||c&&(Al[I]||(H=I,Gn.Arabic(H)||Gn["Arabic Supplement"](H)||Gn["Arabic Extended-A"](H)||Gn["Arabic Presentation Forms-A"](H)||Gn["Arabic Presentation Forms-B"](H))));if(S.imageName){var L=n[S.imageName];if(!L)continue;B=S.imageName,t.iconsInText=t.iconsInText||!0,M=L.paddedRect;var R=L.displaySize;S.scale=24*S.scale/p,D=w+(24-R[1]*S.scale),k=(O={width:R[0],height:R[1],left:1,top:-3,advance:F?R[1]:R[0]}).advance;var z=F?R[0]*S.scale-24*x:R[1]*S.scale-24*x;z>0&&z>A&&(A=z)}else{var N=r[S.fontStack],j=N&&N[I];if(j&&j.rect)M=j.rect,O=j.metrics;else{var U=e[S.fontStack],V=U&&U[I];if(!V)continue;O=V.metrics}D=24*(x-S.scale)}F?(t.verticalizable=!0,T.push({glyph:I,imageName:B,x:h,y:f+D,vertical:F,scale:S.scale,fontStack:S.fontStack,sectionIndex:P,metrics:O,rect:M}),h+=k*S.scale+u):(T.push({glyph:I,imageName:B,x:h,y:f+D,vertical:F,scale:S.scale,fontStack:S.fontStack,sectionIndex:P,metrics:O,rect:M}),h+=O.advance*S.scale+u)}0!==T.length&&(d=Math.max(h-u,d),Bl(T,0,T.length-1,g,A)),h=0;var q=o*x+A;E.lineOffset=Math.max(A,w),f+=q,m=Math.max(q,m),++y}else f+=o,++y}var H,G=f- -17,Z=Ml(a),W=Z.horizontalAlign,Y=Z.verticalAlign;(function(t,e,r,n,i,o,a,s,l){var u,c=(e-r)*i;u=o!==a?-s*n- -17:(-n*l+.5)*a;for(var p=0,h=t;p<h.length;p+=1)for(var f=0,d=h[p].positionedGlyphs;f<d.length;f+=1){var m=d[f];m.x+=c,m.y+=u}})(t.positionedLines,g,W,Y,d,m,o,G,i.length),t.top+=-Y*G,t.bottom=t.top+G,t.left+=-W*d,t.right=t.left+d}(D,e,r,n,g,a,s,l,p,u,h,m),!function(t){for(var e=0,r=t;e<r.length;e+=1)if(0!==r[e].positionedGlyphs.length)return!1;return!0}(I)&&D}El.fromFeature=function(t,e){for(var r=new El,n=0;n<t.sections.length;n++){var i=t.sections[n];i.image?r.addImageSection(i):r.addTextSection(i,e)}return r},El.prototype.length=function(){return this.text.length},El.prototype.getSection=function(t){return this.sections[this.sectionIndex[t]]},El.prototype.getSectionIndex=function(t){return this.sectionIndex[t]},El.prototype.getCharCode=function(t){return this.text.charCodeAt(t)},El.prototype.verticalizePunctuation=function(){this.text=function(t){for(var e="",r=0;r<t.length;r++){var n=t.charCodeAt(r+1)||null,i=t.charCodeAt(r-1)||null;e+=n&&Yn(n)&&!Ws[t[r+1]]||i&&Yn(i)&&!Ws[t[r-1]]||!Ws[t[r]]?t[r]:Ws[t[r]]}return e}(this.text)},El.prototype.trim=function(){for(var t=0,e=0;e<this.text.length&&Al[this.text.charCodeAt(e)];e++)t++;for(var r=this.text.length,n=this.text.length-1;n>=0&&n>=t&&Al[this.text.charCodeAt(n)];n--)r--;this.text=this.text.substring(t,r),this.sectionIndex=this.sectionIndex.slice(t,r)},El.prototype.substring=function(t,e){var r=new El;return r.text=this.text.substring(t,e),r.sectionIndex=this.sectionIndex.slice(t,e),r.sections=this.sections,r},El.prototype.toString=function(){return this.text},El.prototype.getMaxScale=function(){var t=this;return this.sectionIndex.reduce((function(e,r){return Math.max(e,t.sections[r].scale)}),0)},El.prototype.addTextSection=function(t,e){this.text+=t.text,this.sections.push(wl.forText(t.scale,t.fontStack||e));for(var r=this.sections.length-1,n=0;n<t.text.length;++n)this.sectionIndex.push(r)},El.prototype.addImageSection=function(t){var e=t.image?t.image.name:"";if(0!==e.length){var r=this.getNextImageSectionCharCode();r?(this.text+=String.fromCharCode(r),this.sections.push(wl.forImage(e)),this.sectionIndex.push(this.sections.length-1)):E("Reached maximum number of images 6401")}else E("Can't add FormattedSection with an empty image.")},El.prototype.getNextImageSectionCharCode=function(){return this.imageSectionID?this.imageSectionID>=63743?null:++this.imageSectionID:(this.imageSectionID=57344,this.imageSectionID)};var Al={9:!0,10:!0,11:!0,12:!0,13:!0,32:!0},Cl={};function Sl(t,e,r,n,i,o){if(e.imageName){var a=n[e.imageName];return a?a.displaySize[0]*e.scale*24/o+i:0}var s=r[e.fontStack],l=s&&s[t];return l?l.metrics.advance*e.scale+i:0}function Pl(t,e,r,n){var i=Math.pow(t-e,2);return n?t<e?i/2:2*i:i+Math.abs(r)*r}function Il(t,e,r){var n=0;return 10===t&&(n-=1e4),r&&(n+=150),40!==t&&65288!==t||(n+=50),41!==e&&65289!==e||(n+=50),n}function Dl(t,e,r,n,i,o){for(var a=null,s=Pl(e,r,i,o),l=0,u=n;l<u.length;l+=1){var c=u[l],p=Pl(e-c.x,r,i,o)+c.badness;p<=s&&(a=c,s=p)}return{index:t,x:e,priorBreak:a,badness:s}}function Ol(t,e,r,n,i,o,a){if("point"!==o)return[];if(!t)return[];for(var s,l=[],u=function(t,e,r,n,i,o){for(var a=0,s=0;s<t.length();s++){var l=t.getSection(s);a+=Sl(t.getCharCode(s),l,n,i,e,o)}return a/Math.max(1,Math.ceil(a/r))}(t,e,r,n,i,a),c=t.text.indexOf("​")>=0,p=0,h=0;h<t.length();h++){var f=t.getSection(h),d=t.getCharCode(h);if(Al[d]||(p+=Sl(d,f,n,i,e,a)),h<t.length()-1){var m=!((s=d)<11904||!(Gn["Bopomofo Extended"](s)||Gn.Bopomofo(s)||Gn["CJK Compatibility Forms"](s)||Gn["CJK Compatibility Ideographs"](s)||Gn["CJK Compatibility"](s)||Gn["CJK Radicals Supplement"](s)||Gn["CJK Strokes"](s)||Gn["CJK Symbols and Punctuation"](s)||Gn["CJK Unified Ideographs Extension A"](s)||Gn["CJK Unified Ideographs"](s)||Gn["Enclosed CJK Letters and Months"](s)||Gn["Halfwidth and Fullwidth Forms"](s)||Gn.Hiragana(s)||Gn["Ideographic Description Characters"](s)||Gn["Kangxi Radicals"](s)||Gn["Katakana Phonetic Extensions"](s)||Gn.Katakana(s)||Gn["Vertical Forms"](s)||Gn["Yi Radicals"](s)||Gn["Yi Syllables"](s)));(Cl[d]||m||f.imageName)&&l.push(Dl(h+1,p,u,l,Il(d,t.getCharCode(h+1),m&&c),!1))}}return function t(e){return e?t(e.priorBreak).concat(e.index):[]}(Dl(t.length(),p,u,l,0,!0))}function Ml(t){var e=.5,r=.5;switch(t){case"right":case"top-right":case"bottom-right":e=1;break;case"left":case"top-left":case"bottom-left":e=0}switch(t){case"bottom":case"bottom-right":case"bottom-left":r=1;break;case"top":case"top-right":case"top-left":r=0}return{horizontalAlign:e,verticalAlign:r}}function Bl(t,e,r,n,i){if(n||i)for(var o=t[r],a=(t[r].x+o.metrics.advance*o.scale)*n,s=e;s<=r;s++)t[s].x-=a,t[s].y+=i}function kl(t,e,r,n,i,o){var a,s=t.image;if(s.content){var l=s.content,u=s.pixelRatio||1;a=[l[0]/u,l[1]/u,s.displaySize[0]-l[2]/u,s.displaySize[1]-l[3]/u]}var c,p,h,f,d=e.left*o,m=e.right*o;"width"===r||"both"===r?(f=i[0]+d-n[3],p=i[0]+m+n[1]):p=(f=i[0]+(d+m-s.displaySize[0])/2)+s.displaySize[0];var g=e.top*o,y=e.bottom*o;return"height"===r||"both"===r?(c=i[1]+g-n[0],h=i[1]+y+n[2]):h=(c=i[1]+(g+y-s.displaySize[1])/2)+s.displaySize[1],{image:s,top:c,right:p,bottom:h,left:f,collisionPadding:a}}Cl[10]=!0,Cl[32]=!0,Cl[38]=!0,Cl[40]=!0,Cl[41]=!0,Cl[43]=!0,Cl[45]=!0,Cl[47]=!0,Cl[173]=!0,Cl[183]=!0,Cl[8203]=!0,Cl[8208]=!0,Cl[8211]=!0,Cl[8231]=!0;var Fl=function(t){function e(e,r,n,i){t.call(this,e,r),this.angle=n,void 0!==i&&(this.segment=i)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.clone=function(){return new e(this.x,this.y,this.angle,this.segment)},e}(i);function Ll(t,e){var r=e.expression;if("constant"===r.kind)return{kind:"constant",layoutSize:r.evaluate(new si(t+1))};if("source"===r.kind)return{kind:"source"};for(var n=r.zoomStops,i=r.interpolationType,o=0;o<n.length&&n[o]<=t;)o++;for(var a=o=Math.max(0,o-1);a<n.length&&n[a]<t+1;)a++;a=Math.min(n.length-1,a);var s=n[o],l=n[a];return"composite"===r.kind?{kind:"composite",minZoom:s,maxZoom:l,interpolationType:i}:{kind:"camera",minZoom:s,maxZoom:l,minSize:r.evaluate(new si(s)),maxSize:r.evaluate(new si(l)),interpolationType:i}}function Rl(t,e,r){var n=e.uSize,i=r.lowerSize;return"source"===t.kind?i/128:"composite"===t.kind?He(i/128,r.upperSize/128,e.uSizeT):n}function zl(t,e){var r=0,n=0;if("constant"===t.kind)n=t.layoutSize;else if("source"!==t.kind){var i=t.interpolationType,o=i?c(or.interpolationFactor(i,e,t.minZoom,t.maxZoom),0,1):0;"camera"===t.kind?n=He(t.minSize,t.maxSize,o):r=o}return{uSizeT:r,uSize:n}}zn("Anchor",Fl);var Nl=Object.freeze({__proto__:null,getSizeData:Ll,evaluateSizeForFeature:Rl,evaluateSizeForZoom:zl,SIZE_PACK_FACTOR:128});function jl(t,e,r,n,i){if(void 0===e.segment)return!0;for(var o=e,a=e.segment+1,s=0;s>-r/2;){if(--a<0)return!1;s-=t[a].dist(o),o=t[a]}s+=t[a].dist(t[a+1]),a++;for(var l=[],u=0;s<r/2;){var c=t[a],p=t[a+1];if(!p)return!1;var h=t[a-1].angleTo(c)-c.angleTo(p);for(h=Math.abs((h+3*Math.PI)%(2*Math.PI)-Math.PI),l.push({distance:s,angleDelta:h}),u+=h;s-l[0].distance>n;)u-=l.shift().angleDelta;if(u>i)return!1;a++,s+=c.dist(p)}return!0}function Ul(t){for(var e=0,r=0;r<t.length-1;r++)e+=t[r].dist(t[r+1]);return e}function Vl(t,e,r){return t?.6*e*r:0}function ql(t,e){return Math.max(t?t.right-t.left:0,e?e.right-e.left:0)}function Hl(t,e,r,n,i,o){for(var a=Vl(r,i,o),s=ql(r,n)*o,l=0,u=Ul(t)/2,c=0;c<t.length-1;c++){var p=t[c],h=t[c+1],f=p.dist(h);if(l+f>u){var d=(u-l)/f,m=He(p.x,h.x,d),g=He(p.y,h.y,d),y=new Fl(m,g,h.angleTo(p),c);return y._round(),!a||jl(t,y,s,a,e)?y:void 0}l+=f}}function Gl(t,e,r,n,i,o,a,s,l){var u=Vl(n,o,a),c=ql(n,i),p=c*a,h=0===t[0].x||t[0].x===l||0===t[0].y||t[0].y===l;return e-p<e/4&&(e=p+e/4),function t(e,r,n,i,o,a,s,l,u){for(var c=a/2,p=Ul(e),h=0,f=r-n,d=[],m=0;m<e.length-1;m++){for(var g=e[m],y=e[m+1],v=g.dist(y),_=y.angleTo(g);f+n<h+v;){var b=((f+=n)-h)/v,x=He(g.x,y.x,b),w=He(g.y,y.y,b);if(x>=0&&x<u&&w>=0&&w<u&&f-c>=0&&f+c<=p){var E=new Fl(x,w,_,m);E._round(),i&&!jl(e,E,a,i,o)||d.push(E)}}h+=v}return l||d.length||s||(d=t(e,h/2,n,i,o,a,s,!0,u)),d}(t,h?e/2*s%e:(c/2+2*o)*a*s%e,e,u,r,p,h,!1,l)}function Zl(t,e,r,n,o){for(var a=[],s=0;s<t.length;s++)for(var l=t[s],u=void 0,c=0;c<l.length-1;c++){var p=l[c],h=l[c+1];p.x<e&&h.x<e||(p.x<e?p=new i(e,p.y+(e-p.x)/(h.x-p.x)*(h.y-p.y))._round():h.x<e&&(h=new i(e,p.y+(e-p.x)/(h.x-p.x)*(h.y-p.y))._round()),p.y<r&&h.y<r||(p.y<r?p=new i(p.x+(r-p.y)/(h.y-p.y)*(h.x-p.x),r)._round():h.y<r&&(h=new i(p.x+(r-p.y)/(h.y-p.y)*(h.x-p.x),r)._round()),p.x>=n&&h.x>=n||(p.x>=n?p=new i(n,p.y+(n-p.x)/(h.x-p.x)*(h.y-p.y))._round():h.x>=n&&(h=new i(n,p.y+(n-p.x)/(h.x-p.x)*(h.y-p.y))._round()),p.y>=o&&h.y>=o||(p.y>=o?p=new i(p.x+(o-p.y)/(h.y-p.y)*(h.x-p.x),o)._round():h.y>=o&&(h=new i(p.x+(o-p.y)/(h.y-p.y)*(h.x-p.x),o)._round()),u&&p.equals(u[u.length-1])||a.push(u=[p]),u.push(h)))))}return a}function Wl(t,e,r,n){var o=[],a=t.image,s=a.pixelRatio,l=a.paddedRect.w-2,u=a.paddedRect.h-2,c=t.right-t.left,p=t.bottom-t.top,h=a.stretchX||[[0,l]],f=a.stretchY||[[0,u]],d=function(t,e){return t+e[1]-e[0]},m=h.reduce(d,0),g=f.reduce(d,0),y=l-m,v=u-g,_=0,b=m,x=0,w=g,E=0,T=y,A=0,C=v;if(a.content&&n){var S=a.content;_=Yl(h,0,S[0]),x=Yl(f,0,S[1]),b=Yl(h,S[0],S[2]),w=Yl(f,S[1],S[3]),E=S[0]-_,A=S[1]-x,T=S[2]-S[0]-b,C=S[3]-S[1]-w}var P=function(n,o,l,u){var h=Kl(n.stretch-_,b,c,t.left),f=Jl(n.fixed-E,T,n.stretch,m),d=Kl(o.stretch-x,w,p,t.top),y=Jl(o.fixed-A,C,o.stretch,g),v=Kl(l.stretch-_,b,c,t.left),S=Jl(l.fixed-E,T,l.stretch,m),P=Kl(u.stretch-x,w,p,t.top),I=Jl(u.fixed-A,C,u.stretch,g),D=new i(h,d),O=new i(v,d),M=new i(v,P),B=new i(h,P),k=new i(f/s,y/s),F=new i(S/s,I/s),L=e*Math.PI/180;if(L){var R=Math.sin(L),z=Math.cos(L),N=[z,-R,R,z];D._matMult(N),O._matMult(N),B._matMult(N),M._matMult(N)}var j=n.stretch+n.fixed,U=o.stretch+o.fixed;return{tl:D,tr:O,bl:B,br:M,tex:{x:a.paddedRect.x+1+j,y:a.paddedRect.y+1+U,w:l.stretch+l.fixed-j,h:u.stretch+u.fixed-U},writingMode:void 0,glyphOffset:[0,0],sectionIndex:0,pixelOffsetTL:k,pixelOffsetBR:F,minFontScaleX:T/s/c,minFontScaleY:C/s/p,isSDF:r}};if(n&&(a.stretchX||a.stretchY))for(var I=Xl(h,y,m),D=Xl(f,v,g),O=0;O<I.length-1;O++)for(var M=I[O],B=I[O+1],k=0;k<D.length-1;k++)o.push(P(M,D[k],B,D[k+1]));else o.push(P({fixed:0,stretch:-1},{fixed:0,stretch:-1},{fixed:0,stretch:l+1},{fixed:0,stretch:u+1}));return o}function Yl(t,e,r){for(var n=0,i=0,o=t;i<o.length;i+=1){var a=o[i];n+=Math.max(e,Math.min(r,a[1]))-Math.max(e,Math.min(r,a[0]))}return n}function Xl(t,e,r){for(var n=[{fixed:-1,stretch:0}],i=0,o=t;i<o.length;i+=1){var a=o[i],s=a[0],l=a[1],u=n[n.length-1];n.push({fixed:s-u.stretch,stretch:u.stretch}),n.push({fixed:s-u.stretch,stretch:u.stretch+(l-s)})}return n.push({fixed:e+1,stretch:r}),n}function Kl(t,e,r,n){return t/e*r+n}function Jl(t,e,r,n){return t-e*r/n}var Ql=function(t,e,r,n,o,a,s,l,u,c){if(this.boxStartIndex=t.length,u){var p=a.top,h=a.bottom,f=a.collisionPadding;f&&(p-=f[1],h+=f[3]);var d=h-p;d>0&&(d=Math.max(10,d),this.circleDiameter=d)}else{var m=a.top*s-l,g=a.bottom*s+l,y=a.left*s-l,v=a.right*s+l,_=a.collisionPadding;if(_&&(y-=_[0]*s,m-=_[1]*s,v+=_[2]*s,g+=_[3]*s),c){var b=new i(y,m),x=new i(v,m),w=new i(y,g),E=new i(v,g),T=c*Math.PI/180;b._rotate(T),x._rotate(T),w._rotate(T),E._rotate(T),y=Math.min(b.x,x.x,w.x,E.x),v=Math.max(b.x,x.x,w.x,E.x),m=Math.min(b.y,x.y,w.y,E.y),g=Math.max(b.y,x.y,w.y,E.y)}t.emplaceBack(e.x,e.y,y,m,v,g,r,n,o)}this.boxEndIndex=t.length},$l=function(t,e){if(void 0===t&&(t=[]),void 0===e&&(e=tu),this.data=t,this.length=this.data.length,this.compare=e,this.length>0)for(var r=(this.length>>1)-1;r>=0;r--)this._down(r)};function tu(t,e){return t<e?-1:t>e?1:0}function eu(t,e,r){void 0===e&&(e=1),void 0===r&&(r=!1);for(var n=1/0,o=1/0,a=-1/0,s=-1/0,l=t[0],u=0;u<l.length;u++){var c=l[u];(!u||c.x<n)&&(n=c.x),(!u||c.y<o)&&(o=c.y),(!u||c.x>a)&&(a=c.x),(!u||c.y>s)&&(s=c.y)}var p=Math.min(a-n,s-o),h=p/2,f=new $l([],ru);if(0===p)return new i(n,o);for(var d=n;d<a;d+=p)for(var m=o;m<s;m+=p)f.push(new nu(d+h,m+h,h,t));for(var g=function(t){for(var e=0,r=0,n=0,i=t[0],o=0,a=i.length,s=a-1;o<a;s=o++){var l=i[o],u=i[s],c=l.x*u.y-u.x*l.y;r+=(l.x+u.x)*c,n+=(l.y+u.y)*c,e+=3*c}return new nu(r/e,n/e,0,t)}(t),y=f.length;f.length;){var v=f.pop();(v.d>g.d||!g.d)&&(g=v,r&&console.log("found best %d after %d probes",Math.round(1e4*v.d)/1e4,y)),v.max-g.d<=e||(f.push(new nu(v.p.x-(h=v.h/2),v.p.y-h,h,t)),f.push(new nu(v.p.x+h,v.p.y-h,h,t)),f.push(new nu(v.p.x-h,v.p.y+h,h,t)),f.push(new nu(v.p.x+h,v.p.y+h,h,t)),y+=4)}return r&&(console.log("num probes: "+y),console.log("best distance: "+g.d)),g.p}function ru(t,e){return e.max-t.max}function nu(t,e,r,n){this.p=new i(t,e),this.h=r,this.d=function(t,e){for(var r=!1,n=1/0,i=0;i<e.length;i++)for(var o=e[i],a=0,s=o.length,l=s-1;a<s;l=a++){var u=o[a],c=o[l];u.y>t.y!=c.y>t.y&&t.x<(c.x-u.x)*(t.y-u.y)/(c.y-u.y)+u.x&&(r=!r),n=Math.min(n,Jo(t,u,c))}return(r?1:-1)*Math.sqrt(n)}(this.p,n),this.max=this.d+this.h*Math.SQRT2}$l.prototype.push=function(t){this.data.push(t),this.length++,this._up(this.length-1)},$l.prototype.pop=function(){if(0!==this.length){var t=this.data[0],e=this.data.pop();return this.length--,this.length>0&&(this.data[0]=e,this._down(0)),t}},$l.prototype.peek=function(){return this.data[0]},$l.prototype._up=function(t){for(var e=this.data,r=this.compare,n=e[t];t>0;){var i=t-1>>1,o=e[i];if(r(n,o)>=0)break;e[t]=o,t=i}e[t]=n},$l.prototype._down=function(t){for(var e=this.data,r=this.compare,n=this.length>>1,i=e[t];t<n;){var o=1+(t<<1),a=e[o],s=o+1;if(s<this.length&&r(e[s],a)<0&&(o=s,a=e[s]),r(a,i)>=0)break;e[t]=a,t=o}e[t]=i};var iu=Number.POSITIVE_INFINITY;function ou(t,e){return e[1]!==iu?function(t,e,r){var n=0,i=0;switch(e=Math.abs(e),r=Math.abs(r),t){case"top-right":case"top-left":case"top":i=r-7;break;case"bottom-right":case"bottom-left":case"bottom":i=7-r}switch(t){case"top-right":case"bottom-right":case"right":n=-e;break;case"top-left":case"bottom-left":case"left":n=e}return[n,i]}(t,e[0],e[1]):function(t,e){var r=0,n=0;e<0&&(e=0);var i=e/Math.sqrt(2);switch(t){case"top-right":case"top-left":n=i-7;break;case"bottom-right":case"bottom-left":n=7-i;break;case"bottom":n=7-e;break;case"top":n=e-7}switch(t){case"top-right":case"bottom-right":r=-i;break;case"top-left":case"bottom-left":r=i;break;case"left":r=e;break;case"right":r=-e}return[r,n]}(t,e[0])}function au(t){switch(t){case"right":case"top-right":case"bottom-right":return"right";case"left":case"top-left":case"bottom-left":return"left"}return"center"}function su(t,e,r,n,o,a,s,l,u,c,p,h,f,d,m){var g=function(t,e,r,n,o,a,s,l){for(var u=n.layout.get("text-rotate").evaluate(a,{})*Math.PI/180,c=[],p=0,h=e.positionedLines;p<h.length;p+=1)for(var f=h[p],d=0,m=f.positionedGlyphs;d<m.length;d+=1){var g=m[d];if(g.rect){var y=g.rect||{},v=4,_=!0,b=1,x=0,w=(o||l)&&g.vertical,E=g.metrics.advance*g.scale/2;if(l&&e.verticalizable&&(x=f.lineOffset/2-(g.imageName?-(24-g.metrics.width*g.scale)/2:24*(g.scale-1))),g.imageName){var T=s[g.imageName];_=T.sdf,v=1/(b=T.pixelRatio)}var A=o?[g.x+E,g.y]:[0,0],C=o?[0,0]:[g.x+E+r[0],g.y+r[1]-x],S=[0,0];w&&(S=C,C=[0,0]);var P=(g.metrics.left-v)*g.scale-E+C[0],I=(-g.metrics.top-v)*g.scale+C[1],D=P+y.w*g.scale/b,O=I+y.h*g.scale/b,M=new i(P,I),B=new i(D,I),k=new i(P,O),F=new i(D,O);if(w){var L=new i(-E,E- -17),R=-Math.PI/2,z=12-E,N=new i(22-z,-(g.imageName?z:0)),j=new(Function.prototype.bind.apply(i,[null].concat(S)));M._rotateAround(R,L)._add(N)._add(j),B._rotateAround(R,L)._add(N)._add(j),k._rotateAround(R,L)._add(N)._add(j),F._rotateAround(R,L)._add(N)._add(j)}if(u){var U=Math.sin(u),V=Math.cos(u),q=[V,-U,U,V];M._matMult(q),B._matMult(q),k._matMult(q),F._matMult(q)}var H=new i(0,0),G=new i(0,0);c.push({tl:M,tr:B,bl:k,br:F,tex:y,writingMode:e.writingMode,glyphOffset:A,sectionIndex:g.sectionIndex,isSDF:_,pixelOffsetTL:H,pixelOffsetBR:G,minFontScaleX:0,minFontScaleY:0})}}return c}(0,r,l,o,a,s,n,t.allowVerticalPlacement),y=t.textSizeData,v=null;"source"===y.kind?(v=[128*o.layout.get("text-size").evaluate(s,{})])[0]>32640&&E(t.layerIds[0]+': Value for "text-size" is >= 255. Reduce your "text-size".'):"composite"===y.kind&&((v=[128*d.compositeTextSizes[0].evaluate(s,{},m),128*d.compositeTextSizes[1].evaluate(s,{},m)])[0]>32640||v[1]>32640)&&E(t.layerIds[0]+': Value for "text-size" is >= 255. Reduce your "text-size".'),t.addSymbols(t.text,g,v,l,a,s,c,e,u.lineStartIndex,u.lineLength,f,m);for(var _=0,b=p;_<b.length;_+=1)h[b[_]]=t.text.placedSymbolArray.length-1;return 4*g.length}function lu(t){for(var e in t)return t[e];return null}function uu(t,e,r,n){var i=t.compareText;if(e in i){for(var o=i[e],a=o.length-1;a>=0;a--)if(n.dist(o[a])<r)return!0}else i[e]=[];return i[e].push(n),!1}var cu=bs.VectorTileFeature.types,pu=[{name:"a_fade_opacity",components:1,type:"Uint8",offset:0}];function hu(t,e,r,n,i,o,a,s,l,u,c,p,h){var f=s?Math.min(32640,Math.round(s[0])):0,d=s?Math.min(32640,Math.round(s[1])):0;t.emplaceBack(e,r,Math.round(32*n),Math.round(32*i),o,a,(f<<1)+(l?1:0),d,16*u,16*c,256*p,256*h)}function fu(t,e,r){t.emplaceBack(e.x,e.y,r),t.emplaceBack(e.x,e.y,r),t.emplaceBack(e.x,e.y,r),t.emplaceBack(e.x,e.y,r)}function du(t){for(var e=0,r=t.sections;e<r.length;e+=1)if(Jn(r[e].text))return!0;return!1}var mu=function(t){this.layoutVertexArray=new ki,this.indexArray=new Ui,this.programConfigurations=t,this.segments=new so,this.dynamicLayoutVertexArray=new Fi,this.opacityVertexArray=new Li,this.placedSymbolArray=new $i};mu.prototype.isEmpty=function(){return 0===this.layoutVertexArray.length&&0===this.indexArray.length&&0===this.dynamicLayoutVertexArray.length&&0===this.opacityVertexArray.length},mu.prototype.upload=function(t,e,r,n){this.isEmpty()||(r&&(this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,Us.members),this.indexBuffer=t.createIndexBuffer(this.indexArray,e),this.dynamicLayoutVertexBuffer=t.createVertexBuffer(this.dynamicLayoutVertexArray,Vs.members,!0),this.opacityVertexBuffer=t.createVertexBuffer(this.opacityVertexArray,pu,!0),this.opacityVertexBuffer.itemSize=1),(r||n)&&this.programConfigurations.upload(t))},mu.prototype.destroy=function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.dynamicLayoutVertexBuffer.destroy(),this.opacityVertexBuffer.destroy())},zn("SymbolBuffers",mu);var gu=function(t,e,r){this.layoutVertexArray=new t,this.layoutAttributes=e,this.indexArray=new r,this.segments=new so,this.collisionVertexArray=new ji};gu.prototype.upload=function(t){this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,this.layoutAttributes),this.indexBuffer=t.createIndexBuffer(this.indexArray),this.collisionVertexBuffer=t.createVertexBuffer(this.collisionVertexArray,qs.members,!0)},gu.prototype.destroy=function(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.collisionVertexBuffer.destroy())},zn("CollisionBuffers",gu);var yu=function(t){this.collisionBoxArray=t.collisionBoxArray,this.zoom=t.zoom,this.overscaling=t.overscaling,this.layers=t.layers,this.layerIds=this.layers.map((function(t){return t.id})),this.index=t.index,this.pixelRatio=t.pixelRatio,this.sourceLayerIndex=t.sourceLayerIndex,this.hasPattern=!1,this.hasRTLText=!1,this.sortKeyRanges=[],this.collisionCircleArray=[],this.placementInvProjMatrix=sa([]),this.placementViewportMatrix=sa([]);var e=this.layers[0]._unevaluatedLayout._values;this.textSizeData=Ll(this.zoom,e["text-size"]),this.iconSizeData=Ll(this.zoom,e["icon-size"]);var r=this.layers[0].layout,n=r.get("symbol-sort-key"),i=r.get("symbol-z-order");this.canOverlap=r.get("text-allow-overlap")||r.get("icon-allow-overlap")||r.get("text-ignore-placement")||r.get("icon-ignore-placement"),this.sortFeaturesByKey="viewport-y"!==i&&void 0!==n.constantOr(1),this.sortFeaturesByY=("viewport-y"===i||"auto"===i&&!this.sortFeaturesByKey)&&this.canOverlap,"point"===r.get("symbol-placement")&&(this.writingModes=r.get("text-writing-mode").map((function(t){return xl[t]}))),this.stateDependentLayerIds=this.layers.filter((function(t){return t.isStateDependent()})).map((function(t){return t.id})),this.sourceID=t.sourceID};yu.prototype.createArrays=function(){this.text=new mu(new Fo(this.layers,this.zoom,(function(t){return/^text/.test(t)}))),this.icon=new mu(new Fo(this.layers,this.zoom,(function(t){return/^icon/.test(t)}))),this.glyphOffsetArray=new ro,this.lineVertexArray=new no,this.symbolInstances=new eo},yu.prototype.calculateGlyphDependencies=function(t,e,r,n,i){for(var o=0;o<t.length;o++)if(e[t.charCodeAt(o)]=!0,(r||n)&&i){var a=Ws[t.charAt(o)];a&&(e[a.charCodeAt(0)]=!0)}},yu.prototype.populate=function(t,e,r){var n=this.layers[0],i=n.layout,o=i.get("text-font"),a=i.get("text-field"),s=i.get("icon-image"),l=("constant"!==a.value.kind||a.value.value instanceof ne&&!a.value.value.isEmpty()||a.value.value.toString().length>0)&&("constant"!==o.value.kind||o.value.value.length>0),u="constant"!==s.value.kind||!!s.value.value||Object.keys(s.parameters).length>0,c=i.get("symbol-sort-key");if(this.features=[],l||u){for(var p=e.iconDependencies,h=e.glyphDependencies,f=e.availableImages,d=new si(this.zoom),m=0,g=t;m<g.length;m+=1){var y=g[m],v=y.feature,_=y.id,b=y.index,x=y.sourceLayerIndex,w=n._featureFilter.needGeometry,E=Uo(v,w);if(n._featureFilter.filter(d,E,r)){w||(E.geometry=jo(v));var T=void 0;if(l){var A=n.getValueAndResolveTokens("text-field",E,r,f),C=ne.factory(A);du(C)&&(this.hasRTLText=!0),(!this.hasRTLText||"unavailable"===ii()||this.hasRTLText&&ai.isParsed())&&(T=Zs(C,n,E))}var S=void 0;if(u){var P=n.getValueAndResolveTokens("icon-image",E,r,f);S=P instanceof ie?P:ie.fromString(P)}if(T||S){var I=this.sortFeaturesByKey?c.evaluate(E,{},r):void 0;if(this.features.push({id:_,text:T,icon:S,index:b,sourceLayerIndex:x,geometry:E.geometry,properties:v.properties,type:cu[v.type],sortKey:I}),S&&(p[S.name]=!0),T){var D=o.evaluate(E,{},r).join(","),O="map"===i.get("text-rotation-alignment")&&"point"!==i.get("symbol-placement");this.allowVerticalPlacement=this.writingModes&&this.writingModes.indexOf(xl.vertical)>=0;for(var M=0,B=T.sections;M<B.length;M+=1){var k=B[M];if(k.image)p[k.image.name]=!0;else{var F=Zn(T.toString()),L=k.fontStack||D,R=h[L]=h[L]||{};this.calculateGlyphDependencies(k.text,R,O,this.allowVerticalPlacement,F)}}}}}}"line"===i.get("symbol-placement")&&(this.features=function(t){var e={},r={},n=[],i=0;function o(e){n.push(t[e]),i++}function a(t,e,i){var o=r[t];return delete r[t],r[e]=o,n[o].geometry[0].pop(),n[o].geometry[0]=n[o].geometry[0].concat(i[0]),o}function s(t,r,i){var o=e[r];return delete e[r],e[t]=o,n[o].geometry[0].shift(),n[o].geometry[0]=i[0].concat(n[o].geometry[0]),o}function l(t,e,r){var n=r?e[0][e[0].length-1]:e[0][0];return t+":"+n.x+":"+n.y}for(var u=0;u<t.length;u++){var c=t[u],p=c.geometry,h=c.text?c.text.toString():null;if(h){var f=l(h,p),d=l(h,p,!0);if(f in r&&d in e&&r[f]!==e[d]){var m=s(f,d,p),g=a(f,d,n[m].geometry);delete e[f],delete r[d],r[l(h,n[g].geometry,!0)]=g,n[m].geometry=null}else f in r?a(f,d,p):d in e?s(f,d,p):(o(u),e[f]=i-1,r[d]=i-1)}else o(u)}return n.filter((function(t){return t.geometry}))}(this.features)),this.sortFeaturesByKey&&this.features.sort((function(t,e){return t.sortKey-e.sortKey}))}},yu.prototype.update=function(t,e,r){this.stateDependentLayers.length&&(this.text.programConfigurations.updatePaintArrays(t,e,this.layers,r),this.icon.programConfigurations.updatePaintArrays(t,e,this.layers,r))},yu.prototype.isEmpty=function(){return 0===this.symbolInstances.length&&!this.hasRTLText},yu.prototype.uploadPending=function(){return!this.uploaded||this.text.programConfigurations.needsUpload||this.icon.programConfigurations.needsUpload},yu.prototype.upload=function(t){!this.uploaded&&this.hasDebugData()&&(this.textCollisionBox.upload(t),this.iconCollisionBox.upload(t)),this.text.upload(t,this.sortFeaturesByY,!this.uploaded,this.text.programConfigurations.needsUpload),this.icon.upload(t,this.sortFeaturesByY,!this.uploaded,this.icon.programConfigurations.needsUpload),this.uploaded=!0},yu.prototype.destroyDebugData=function(){this.textCollisionBox.destroy(),this.iconCollisionBox.destroy()},yu.prototype.destroy=function(){this.text.destroy(),this.icon.destroy(),this.hasDebugData()&&this.destroyDebugData()},yu.prototype.addToLineVertexArray=function(t,e){var r=this.lineVertexArray.length;if(void 0!==t.segment){for(var n=t.dist(e[t.segment+1]),i=t.dist(e[t.segment]),o={},a=t.segment+1;a<e.length;a++)o[a]={x:e[a].x,y:e[a].y,tileUnitDistanceFromAnchor:n},a<e.length-1&&(n+=e[a+1].dist(e[a]));for(var s=t.segment||0;s>=0;s--)o[s]={x:e[s].x,y:e[s].y,tileUnitDistanceFromAnchor:i},s>0&&(i+=e[s-1].dist(e[s]));for(var l=0;l<e.length;l++){var u=o[l];this.lineVertexArray.emplaceBack(u.x,u.y,u.tileUnitDistanceFromAnchor)}}return{lineStartIndex:r,lineLength:this.lineVertexArray.length-r}},yu.prototype.addSymbols=function(t,e,r,n,i,o,a,s,l,u,c,p){for(var h=t.indexArray,f=t.layoutVertexArray,d=t.segments.prepareSegment(4*e.length,f,h,this.canOverlap?o.sortKey:void 0),m=this.glyphOffsetArray.length,g=d.vertexLength,y=this.allowVerticalPlacement&&a===xl.vertical?Math.PI/2:0,v=o.text&&o.text.sections,_=0;_<e.length;_++){var b=e[_],x=b.tl,w=b.tr,E=b.bl,T=b.br,A=b.tex,C=b.pixelOffsetTL,S=b.pixelOffsetBR,P=b.minFontScaleX,I=b.minFontScaleY,D=b.glyphOffset,O=b.isSDF,M=b.sectionIndex,B=d.vertexLength,k=D[1];hu(f,s.x,s.y,x.x,k+x.y,A.x,A.y,r,O,C.x,C.y,P,I),hu(f,s.x,s.y,w.x,k+w.y,A.x+A.w,A.y,r,O,S.x,C.y,P,I),hu(f,s.x,s.y,E.x,k+E.y,A.x,A.y+A.h,r,O,C.x,S.y,P,I),hu(f,s.x,s.y,T.x,k+T.y,A.x+A.w,A.y+A.h,r,O,S.x,S.y,P,I),fu(t.dynamicLayoutVertexArray,s,y),h.emplaceBack(B,B+1,B+2),h.emplaceBack(B+1,B+2,B+3),d.vertexLength+=4,d.primitiveLength+=2,this.glyphOffsetArray.emplaceBack(D[0]),_!==e.length-1&&M===e[_+1].sectionIndex||t.programConfigurations.populatePaintArrays(f.length,o,o.index,{},p,v&&v[M])}t.placedSymbolArray.emplaceBack(s.x,s.y,m,this.glyphOffsetArray.length-m,g,l,u,s.segment,r?r[0]:0,r?r[1]:0,n[0],n[1],a,0,!1,0,c)},yu.prototype._addCollisionDebugVertex=function(t,e,r,n,i,o){return e.emplaceBack(0,0),t.emplaceBack(r.x,r.y,n,i,Math.round(o.x),Math.round(o.y))},yu.prototype.addCollisionDebugVertices=function(t,e,r,n,o,a,s){var l=o.segments.prepareSegment(4,o.layoutVertexArray,o.indexArray),u=l.vertexLength,c=o.layoutVertexArray,p=o.collisionVertexArray,h=s.anchorX,f=s.anchorY;this._addCollisionDebugVertex(c,p,a,h,f,new i(t,e)),this._addCollisionDebugVertex(c,p,a,h,f,new i(r,e)),this._addCollisionDebugVertex(c,p,a,h,f,new i(r,n)),this._addCollisionDebugVertex(c,p,a,h,f,new i(t,n)),l.vertexLength+=4;var d=o.indexArray;d.emplaceBack(u,u+1),d.emplaceBack(u+1,u+2),d.emplaceBack(u+2,u+3),d.emplaceBack(u+3,u),l.primitiveLength+=4},yu.prototype.addDebugCollisionBoxes=function(t,e,r,n){for(var i=t;i<e;i++){var o=this.collisionBoxArray.get(i);this.addCollisionDebugVertices(o.x1,o.y1,o.x2,o.y2,n?this.textCollisionBox:this.iconCollisionBox,o.anchorPoint,r)}},yu.prototype.generateCollisionDebugBuffers=function(){this.hasDebugData()&&this.destroyDebugData(),this.textCollisionBox=new gu(zi,Hs.members,Wi),this.iconCollisionBox=new gu(zi,Hs.members,Wi);for(var t=0;t<this.symbolInstances.length;t++){var e=this.symbolInstances.get(t);this.addDebugCollisionBoxes(e.textBoxStartIndex,e.textBoxEndIndex,e,!0),this.addDebugCollisionBoxes(e.verticalTextBoxStartIndex,e.verticalTextBoxEndIndex,e,!0),this.addDebugCollisionBoxes(e.iconBoxStartIndex,e.iconBoxEndIndex,e,!1),this.addDebugCollisionBoxes(e.verticalIconBoxStartIndex,e.verticalIconBoxEndIndex,e,!1)}},yu.prototype._deserializeCollisionBoxesForSymbol=function(t,e,r,n,i,o,a,s,l){for(var u={},c=e;c<r;c++){var p=t.get(c);u.textBox={x1:p.x1,y1:p.y1,x2:p.x2,y2:p.y2,anchorPointX:p.anchorPointX,anchorPointY:p.anchorPointY},u.textFeatureIndex=p.featureIndex;break}for(var h=n;h<i;h++){var f=t.get(h);u.verticalTextBox={x1:f.x1,y1:f.y1,x2:f.x2,y2:f.y2,anchorPointX:f.anchorPointX,anchorPointY:f.anchorPointY},u.verticalTextFeatureIndex=f.featureIndex;break}for(var d=o;d<a;d++){var m=t.get(d);u.iconBox={x1:m.x1,y1:m.y1,x2:m.x2,y2:m.y2,anchorPointX:m.anchorPointX,anchorPointY:m.anchorPointY},u.iconFeatureIndex=m.featureIndex;break}for(var g=s;g<l;g++){var y=t.get(g);u.verticalIconBox={x1:y.x1,y1:y.y1,x2:y.x2,y2:y.y2,anchorPointX:y.anchorPointX,anchorPointY:y.anchorPointY},u.verticalIconFeatureIndex=y.featureIndex;break}return u},yu.prototype.deserializeCollisionBoxes=function(t){this.collisionArrays=[];for(var e=0;e<this.symbolInstances.length;e++){var r=this.symbolInstances.get(e);this.collisionArrays.push(this._deserializeCollisionBoxesForSymbol(t,r.textBoxStartIndex,r.textBoxEndIndex,r.verticalTextBoxStartIndex,r.verticalTextBoxEndIndex,r.iconBoxStartIndex,r.iconBoxEndIndex,r.verticalIconBoxStartIndex,r.verticalIconBoxEndIndex))}},yu.prototype.hasTextData=function(){return this.text.segments.get().length>0},yu.prototype.hasIconData=function(){return this.icon.segments.get().length>0},yu.prototype.hasDebugData=function(){return this.textCollisionBox&&this.iconCollisionBox},yu.prototype.hasTextCollisionBoxData=function(){return this.hasDebugData()&&this.textCollisionBox.segments.get().length>0},yu.prototype.hasIconCollisionBoxData=function(){return this.hasDebugData()&&this.iconCollisionBox.segments.get().length>0},yu.prototype.addIndicesForPlacedSymbol=function(t,e){for(var r=t.placedSymbolArray.get(e),n=r.vertexStartIndex+4*r.numGlyphs,i=r.vertexStartIndex;i<n;i+=4)t.indexArray.emplaceBack(i,i+1,i+2),t.indexArray.emplaceBack(i+1,i+2,i+3)},yu.prototype.getSortedSymbolIndexes=function(t){if(this.sortedAngle===t&&void 0!==this.symbolInstanceIndexes)return this.symbolInstanceIndexes;for(var e=Math.sin(t),r=Math.cos(t),n=[],i=[],o=[],a=0;a<this.symbolInstances.length;++a){o.push(a);var s=this.symbolInstances.get(a);n.push(0|Math.round(e*s.anchorX+r*s.anchorY)),i.push(s.featureIndex)}return o.sort((function(t,e){return n[t]-n[e]||i[e]-i[t]})),o},yu.prototype.addToSortKeyRanges=function(t,e){var r=this.sortKeyRanges[this.sortKeyRanges.length-1];r&&r.sortKey===e?r.symbolInstanceEnd=t+1:this.sortKeyRanges.push({sortKey:e,symbolInstanceStart:t,symbolInstanceEnd:t+1})},yu.prototype.sortFeatures=function(t){var e=this;if(this.sortFeaturesByY&&this.sortedAngle!==t&&!(this.text.segments.get().length>1||this.icon.segments.get().length>1)){this.symbolInstanceIndexes=this.getSortedSymbolIndexes(t),this.sortedAngle=t,this.text.indexArray.clear(),this.icon.indexArray.clear(),this.featureSortOrder=[];for(var r=0,n=this.symbolInstanceIndexes;r<n.length;r+=1){var i=this.symbolInstances.get(n[r]);this.featureSortOrder.push(i.featureIndex),[i.rightJustifiedTextSymbolIndex,i.centerJustifiedTextSymbolIndex,i.leftJustifiedTextSymbolIndex].forEach((function(t,r,n){t>=0&&n.indexOf(t)===r&&e.addIndicesForPlacedSymbol(e.text,t)})),i.verticalPlacedTextSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.text,i.verticalPlacedTextSymbolIndex),i.placedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,i.placedIconSymbolIndex),i.verticalPlacedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,i.verticalPlacedIconSymbolIndex)}this.text.indexBuffer&&this.text.indexBuffer.updateData(this.text.indexArray),this.icon.indexBuffer&&this.icon.indexBuffer.updateData(this.icon.indexArray)}},zn("SymbolBucket",yu,{omit:["layers","collisionBoxArray","features","compareText"]}),yu.MAX_GLYPHS=65535,yu.addDynamicAttributes=fu;var vu=new xi({"symbol-placement":new gi(It.layout_symbol["symbol-placement"]),"symbol-spacing":new gi(It.layout_symbol["symbol-spacing"]),"symbol-avoid-edges":new gi(It.layout_symbol["symbol-avoid-edges"]),"symbol-sort-key":new yi(It.layout_symbol["symbol-sort-key"]),"symbol-z-order":new gi(It.layout_symbol["symbol-z-order"]),"icon-allow-overlap":new gi(It.layout_symbol["icon-allow-overlap"]),"icon-ignore-placement":new gi(It.layout_symbol["icon-ignore-placement"]),"icon-optional":new gi(It.layout_symbol["icon-optional"]),"icon-rotation-alignment":new gi(It.layout_symbol["icon-rotation-alignment"]),"icon-size":new yi(It.layout_symbol["icon-size"]),"icon-text-fit":new gi(It.layout_symbol["icon-text-fit"]),"icon-text-fit-padding":new gi(It.layout_symbol["icon-text-fit-padding"]),"icon-image":new yi(It.layout_symbol["icon-image"]),"icon-rotate":new yi(It.layout_symbol["icon-rotate"]),"icon-padding":new gi(It.layout_symbol["icon-padding"]),"icon-keep-upright":new gi(It.layout_symbol["icon-keep-upright"]),"icon-offset":new yi(It.layout_symbol["icon-offset"]),"icon-anchor":new yi(It.layout_symbol["icon-anchor"]),"icon-pitch-alignment":new gi(It.layout_symbol["icon-pitch-alignment"]),"text-pitch-alignment":new gi(It.layout_symbol["text-pitch-alignment"]),"text-rotation-alignment":new gi(It.layout_symbol["text-rotation-alignment"]),"text-field":new yi(It.layout_symbol["text-field"]),"text-font":new yi(It.layout_symbol["text-font"]),"text-size":new yi(It.layout_symbol["text-size"]),"text-max-width":new yi(It.layout_symbol["text-max-width"]),"text-line-height":new gi(It.layout_symbol["text-line-height"]),"text-letter-spacing":new yi(It.layout_symbol["text-letter-spacing"]),"text-justify":new yi(It.layout_symbol["text-justify"]),"text-radial-offset":new yi(It.layout_symbol["text-radial-offset"]),"text-variable-anchor":new gi(It.layout_symbol["text-variable-anchor"]),"text-anchor":new yi(It.layout_symbol["text-anchor"]),"text-max-angle":new gi(It.layout_symbol["text-max-angle"]),"text-writing-mode":new gi(It.layout_symbol["text-writing-mode"]),"text-rotate":new yi(It.layout_symbol["text-rotate"]),"text-padding":new gi(It.layout_symbol["text-padding"]),"text-keep-upright":new gi(It.layout_symbol["text-keep-upright"]),"text-transform":new yi(It.layout_symbol["text-transform"]),"text-offset":new yi(It.layout_symbol["text-offset"]),"text-allow-overlap":new gi(It.layout_symbol["text-allow-overlap"]),"text-ignore-placement":new gi(It.layout_symbol["text-ignore-placement"]),"text-optional":new gi(It.layout_symbol["text-optional"])}),_u={paint:new xi({"icon-opacity":new yi(It.paint_symbol["icon-opacity"]),"icon-color":new yi(It.paint_symbol["icon-color"]),"icon-halo-color":new yi(It.paint_symbol["icon-halo-color"]),"icon-halo-width":new yi(It.paint_symbol["icon-halo-width"]),"icon-halo-blur":new yi(It.paint_symbol["icon-halo-blur"]),"icon-translate":new gi(It.paint_symbol["icon-translate"]),"icon-translate-anchor":new gi(It.paint_symbol["icon-translate-anchor"]),"text-opacity":new yi(It.paint_symbol["text-opacity"]),"text-color":new yi(It.paint_symbol["text-color"],{runtimeType:Ut,getOverride:function(t){return t.textColor},hasOverride:function(t){return!!t.textColor}}),"text-halo-color":new yi(It.paint_symbol["text-halo-color"]),"text-halo-width":new yi(It.paint_symbol["text-halo-width"]),"text-halo-blur":new yi(It.paint_symbol["text-halo-blur"]),"text-translate":new gi(It.paint_symbol["text-translate"]),"text-translate-anchor":new gi(It.paint_symbol["text-translate-anchor"])}),layout:vu},bu=function(t){this.type=t.property.overrides?t.property.overrides.runtimeType:Rt,this.defaultValue=t};bu.prototype.evaluate=function(t){if(t.formattedSection){var e=this.defaultValue.property.overrides;if(e&&e.hasOverride(t.formattedSection))return e.getOverride(t.formattedSection)}return t.feature&&t.featureState?this.defaultValue.evaluate(t.feature,t.featureState):this.defaultValue.property.specification.default},bu.prototype.eachChild=function(t){this.defaultValue.isConstant()||t(this.defaultValue.value._styleExpression.expression)},bu.prototype.outputDefined=function(){return!1},bu.prototype.serialize=function(){return null},zn("FormatSectionOverride",bu,{omit:["defaultValue"]});var xu=function(t){function e(e){t.call(this,e,_u)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.recalculate=function(e,r){if(t.prototype.recalculate.call(this,e,r),"auto"===this.layout.get("icon-rotation-alignment")&&(this.layout._values["icon-rotation-alignment"]="point"!==this.layout.get("symbol-placement")?"map":"viewport"),"auto"===this.layout.get("text-rotation-alignment")&&(this.layout._values["text-rotation-alignment"]="point"!==this.layout.get("symbol-placement")?"map":"viewport"),"auto"===this.layout.get("text-pitch-alignment")&&(this.layout._values["text-pitch-alignment"]=this.layout.get("text-rotation-alignment")),"auto"===this.layout.get("icon-pitch-alignment")&&(this.layout._values["icon-pitch-alignment"]=this.layout.get("icon-rotation-alignment")),"point"===this.layout.get("symbol-placement")){var n=this.layout.get("text-writing-mode");if(n){for(var i=[],o=0,a=n;o<a.length;o+=1){var s=a[o];i.indexOf(s)<0&&i.push(s)}this.layout._values["text-writing-mode"]=i}else this.layout._values["text-writing-mode"]=["horizontal"]}this._setPaintOverrides()},e.prototype.getValueAndResolveTokens=function(t,e,r,n){var i=this.layout.get(t).evaluate(e,{},r,n),o=this._unevaluatedLayout._values[t];return o.isDataDriven()||Gr(o.value)||!i?i:function(t,e){return e.replace(/{([^{}]+)}/g,(function(e,r){return r in t?String(t[r]):""}))}(e.properties,i)},e.prototype.createBucket=function(t){return new yu(t)},e.prototype.queryRadius=function(){return 0},e.prototype.queryIntersectsFeature=function(){return!1},e.prototype._setPaintOverrides=function(){for(var t=0,r=_u.paint.overridableProperties;t<r.length;t+=1){var n=r[t];if(e.hasPaintOverride(this.layout,n)){var i,o=this.paint.get(n),a=new bu(o),s=new Hr(a,o.property.specification);i="constant"===o.value.kind||"source"===o.value.kind?new Wr("source",s):new Yr("composite",s,o.value.zoomStops,o.value._interpolationType),this.paint._values[n]=new di(o.property,i,o.parameters)}}},e.prototype._handleOverridablePaintPropertyUpdate=function(t,r,n){return!(!this.layout||r.isDataDriven()||n.isDataDriven())&&e.hasPaintOverride(this.layout,t)},e.hasPaintOverride=function(t,e){var r=t.get("text-field"),n=_u.paint.properties[e],i=!1,o=function(t){for(var e=0,r=t;e<r.length;e+=1)if(n.overrides&&n.overrides.hasOverride(r[e]))return void(i=!0)};if("constant"===r.value.kind&&r.value.value instanceof ne)o(r.value.value.sections);else if("source"===r.value.kind){var a=function(t){i||(t instanceof ue&&se(t.value)===Gt?o(t.value.sections):t instanceof fe?o(t.sections):t.eachChild(a))},s=r.value;s._styleExpression&&a(s._styleExpression.expression)}return i},e}(wi),wu={paint:new xi({"background-color":new gi(It.paint_background["background-color"]),"background-pattern":new _i(It.paint_background["background-pattern"]),"background-opacity":new gi(It.paint_background["background-opacity"])})},Eu=function(t){function e(e){t.call(this,e,wu)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e}(wi),Tu={paint:new xi({"raster-opacity":new gi(It.paint_raster["raster-opacity"]),"raster-hue-rotate":new gi(It.paint_raster["raster-hue-rotate"]),"raster-brightness-min":new gi(It.paint_raster["raster-brightness-min"]),"raster-brightness-max":new gi(It.paint_raster["raster-brightness-max"]),"raster-saturation":new gi(It.paint_raster["raster-saturation"]),"raster-contrast":new gi(It.paint_raster["raster-contrast"]),"raster-resampling":new gi(It.paint_raster["raster-resampling"]),"raster-fade-duration":new gi(It.paint_raster["raster-fade-duration"])})},Au=function(t){function e(e){t.call(this,e,Tu)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e}(wi),Cu=function(t){function e(e){t.call(this,e,{}),this.implementation=e}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.is3D=function(){return"3d"===this.implementation.renderingMode},e.prototype.hasOffscreenPass=function(){return void 0!==this.implementation.prerender},e.prototype.recalculate=function(){},e.prototype.updateTransitions=function(){},e.prototype.hasTransition=function(){},e.prototype.serialize=function(){},e.prototype.onAdd=function(t){this.implementation.onAdd&&this.implementation.onAdd(t,t.painter.context.gl)},e.prototype.onRemove=function(t){this.implementation.onRemove&&this.implementation.onRemove(t,t.painter.context.gl)},e}(wi),Su={circle:ha,heatmap:wa,hillshade:Ta,fill:cs,"fill-extrusion":Ss,line:Ns,symbol:xu,background:Eu,raster:Au},Pu=a.HTMLImageElement,Iu=a.HTMLCanvasElement,Du=a.HTMLVideoElement,Ou=a.ImageData,Mu=a.ImageBitmap,Bu=function(t,e,r,n){this.context=t,this.format=r,this.texture=t.gl.createTexture(),this.update(e,n)};Bu.prototype.update=function(t,e,r){var n=t.width,i=t.height,o=!(this.size&&this.size[0]===n&&this.size[1]===i||r),a=this.context,s=a.gl;if(this.useMipmap=Boolean(e&&e.useMipmap),s.bindTexture(s.TEXTURE_2D,this.texture),a.pixelStoreUnpackFlipY.set(!1),a.pixelStoreUnpack.set(1),a.pixelStoreUnpackPremultiplyAlpha.set(this.format===s.RGBA&&(!e||!1!==e.premultiply)),o)this.size=[n,i],t instanceof Pu||t instanceof Iu||t instanceof Du||t instanceof Ou||Mu&&t instanceof Mu?s.texImage2D(s.TEXTURE_2D,0,this.format,this.format,s.UNSIGNED_BYTE,t):s.texImage2D(s.TEXTURE_2D,0,this.format,n,i,0,this.format,s.UNSIGNED_BYTE,t.data);else{var l=r||{x:0,y:0},u=l.x,c=l.y;t instanceof Pu||t instanceof Iu||t instanceof Du||t instanceof Ou||Mu&&t instanceof Mu?s.texSubImage2D(s.TEXTURE_2D,0,u,c,s.RGBA,s.UNSIGNED_BYTE,t):s.texSubImage2D(s.TEXTURE_2D,0,u,c,n,i,s.RGBA,s.UNSIGNED_BYTE,t.data)}this.useMipmap&&this.isSizePowerOfTwo()&&s.generateMipmap(s.TEXTURE_2D)},Bu.prototype.bind=function(t,e,r){var n=this.context.gl;n.bindTexture(n.TEXTURE_2D,this.texture),r!==n.LINEAR_MIPMAP_NEAREST||this.isSizePowerOfTwo()||(r=n.LINEAR),t!==this.filter&&(n.texParameteri(n.TEXTURE_2D,n.TEXTURE_MAG_FILTER,t),n.texParameteri(n.TEXTURE_2D,n.TEXTURE_MIN_FILTER,r||t),this.filter=t),e!==this.wrap&&(n.texParameteri(n.TEXTURE_2D,n.TEXTURE_WRAP_S,e),n.texParameteri(n.TEXTURE_2D,n.TEXTURE_WRAP_T,e),this.wrap=e)},Bu.prototype.isSizePowerOfTwo=function(){return this.size[0]===this.size[1]&&Math.log(this.size[0])/Math.LN2%1==0},Bu.prototype.destroy=function(){this.context.gl.deleteTexture(this.texture),this.texture=null};var ku=function(t){var e=this;this._callback=t,this._triggered=!1,"undefined"!=typeof MessageChannel&&(this._channel=new MessageChannel,this._channel.port2.onmessage=function(){e._triggered=!1,e._callback()})};ku.prototype.trigger=function(){var t=this;this._triggered||(this._triggered=!0,this._channel?this._channel.port1.postMessage(!0):setTimeout((function(){t._triggered=!1,t._callback()}),0))},ku.prototype.remove=function(){delete this._channel,this._callback=function(){}};var Fu=function(t,e,r){this.target=t,this.parent=e,this.mapId=r,this.callbacks={},this.tasks={},this.taskQueue=[],this.cancelCallbacks={},y(["receive","process"],this),this.invoker=new ku(this.process),this.target.addEventListener("message",this.receive,!1),this.globalScope=C()?t:a};function Lu(t,e,r){var n=2*Math.PI*6378137/256/Math.pow(2,r);return[t*n-2*Math.PI*6378137/2,e*n-2*Math.PI*6378137/2]}Fu.prototype.send=function(t,e,r,n,i){var o=this;void 0===i&&(i=!1);var a=Math.round(1e18*Math.random()).toString(36).substring(0,10);r&&(this.callbacks[a]=r);var s=I(this.globalScope)?void 0:[];return this.target.postMessage({id:a,type:t,hasCallback:!!r,targetMapId:n,mustQueue:i,sourceMapId:this.mapId,data:Vn(e,s)},s),{cancel:function(){r&&delete o.callbacks[a],o.target.postMessage({id:a,type:"<cancel>",targetMapId:n,sourceMapId:o.mapId})}}},Fu.prototype.receive=function(t){var e=t.data,r=e.id;if(r&&(!e.targetMapId||this.mapId===e.targetMapId))if("<cancel>"===e.type){delete this.tasks[r];var n=this.cancelCallbacks[r];delete this.cancelCallbacks[r],n&&n()}else C()||e.mustQueue?(this.tasks[r]=e,this.taskQueue.push(r),this.invoker.trigger()):this.processTask(r,e)},Fu.prototype.process=function(){if(this.taskQueue.length){var t=this.taskQueue.shift(),e=this.tasks[t];delete this.tasks[t],this.taskQueue.length&&this.invoker.trigger(),e&&this.processTask(t,e)}},Fu.prototype.processTask=function(t,e){var r=this;if("<response>"===e.type){var n=this.callbacks[t];delete this.callbacks[t],n&&(e.error?n(qn(e.error)):n(null,qn(e.data)))}else{var i=!1,o=I(this.globalScope)?void 0:[],a=e.hasCallback?function(e,n){i=!0,delete r.cancelCallbacks[t],r.target.postMessage({id:t,type:"<response>",sourceMapId:r.mapId,error:e?Vn(e):null,data:Vn(n,o)},o)}:function(t){i=!0},s=null,l=qn(e.data);if(this.parent[e.type])s=this.parent[e.type](e.sourceMapId,l,a);else if(this.parent.getWorkerSource){var u=e.type.split(".");s=this.parent.getWorkerSource(e.sourceMapId,u[0],l.source)[u[1]](l,a)}else a(new Error("Could not find function "+e.type));!i&&s&&s.cancel&&(this.cancelCallbacks[t]=s.cancel)}},Fu.prototype.remove=function(){this.invoker.remove(),this.target.removeEventListener("message",this.receive,!1)};var Ru=function(t,e){t&&(e?this.setSouthWest(t).setNorthEast(e):4===t.length?this.setSouthWest([t[0],t[1]]).setNorthEast([t[2],t[3]]):this.setSouthWest(t[0]).setNorthEast(t[1]))};Ru.prototype.setNorthEast=function(t){return this._ne=t instanceof zu?new zu(t.lng,t.lat):zu.convert(t),this},Ru.prototype.setSouthWest=function(t){return this._sw=t instanceof zu?new zu(t.lng,t.lat):zu.convert(t),this},Ru.prototype.extend=function(t){var e,r,n=this._sw,i=this._ne;if(t instanceof zu)e=t,r=t;else{if(!(t instanceof Ru))return Array.isArray(t)?4===t.length||t.every(Array.isArray)?this.extend(Ru.convert(t)):this.extend(zu.convert(t)):this;if(r=t._ne,!(e=t._sw)||!r)return this}return n||i?(n.lng=Math.min(e.lng,n.lng),n.lat=Math.min(e.lat,n.lat),i.lng=Math.max(r.lng,i.lng),i.lat=Math.max(r.lat,i.lat)):(this._sw=new zu(e.lng,e.lat),this._ne=new zu(r.lng,r.lat)),this},Ru.prototype.getCenter=function(){return new zu((this._sw.lng+this._ne.lng)/2,(this._sw.lat+this._ne.lat)/2)},Ru.prototype.getSouthWest=function(){return this._sw},Ru.prototype.getNorthEast=function(){return this._ne},Ru.prototype.getNorthWest=function(){return new zu(this.getWest(),this.getNorth())},Ru.prototype.getSouthEast=function(){return new zu(this.getEast(),this.getSouth())},Ru.prototype.getWest=function(){return this._sw.lng},Ru.prototype.getSouth=function(){return this._sw.lat},Ru.prototype.getEast=function(){return this._ne.lng},Ru.prototype.getNorth=function(){return this._ne.lat},Ru.prototype.toArray=function(){return[this._sw.toArray(),this._ne.toArray()]},Ru.prototype.toString=function(){return"LngLatBounds("+this._sw.toString()+", "+this._ne.toString()+")"},Ru.prototype.isEmpty=function(){return!(this._sw&&this._ne)},Ru.prototype.contains=function(t){var e=zu.convert(t),r=e.lng,n=e.lat,i=this._sw.lng<=r&&r<=this._ne.lng;return this._sw.lng>this._ne.lng&&(i=this._sw.lng>=r&&r>=this._ne.lng),this._sw.lat<=n&&n<=this._ne.lat&&i},Ru.convert=function(t){return!t||t instanceof Ru?t:new Ru(t)};var zu=function(t,e){if(isNaN(t)||isNaN(e))throw new Error("Invalid LngLat object: ("+t+", "+e+")");if(this.lng=+t,this.lat=+e,this.lat>90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")};zu.prototype.wrap=function(){return new zu(p(this.lng,-180,180),this.lat)},zu.prototype.toArray=function(){return[this.lng,this.lat]},zu.prototype.toString=function(){return"LngLat("+this.lng+", "+this.lat+")"},zu.prototype.distanceTo=function(t){var e=Math.PI/180,r=this.lat*e,n=t.lat*e,i=Math.sin(r)*Math.sin(n)+Math.cos(r)*Math.cos(n)*Math.cos((t.lng-this.lng)*e);return 6371008.8*Math.acos(Math.min(i,1))},zu.prototype.toBounds=function(t){void 0===t&&(t=0);var e=360*t/40075017,r=e/Math.cos(Math.PI/180*this.lat);return new Ru(new zu(this.lng-r,this.lat-e),new zu(this.lng+r,this.lat+e))},zu.convert=function(t){if(t instanceof zu)return t;if(Array.isArray(t)&&(2===t.length||3===t.length))return new zu(Number(t[0]),Number(t[1]));if(!Array.isArray(t)&&"object"==typeof t&&null!==t)return new zu(Number("lng"in t?t.lng:t.lon),Number(t.lat));throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: <lng>, lat: <lat>}, an object {lon: <lng>, lat: <lat>}, or an array of [<lng>, <lat>]")};var Nu=2*Math.PI*6371008.8;function ju(t){return Nu*Math.cos(t*Math.PI/180)}function Uu(t){return(180+t)/360}function Vu(t){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+t*Math.PI/360)))/360}function qu(t,e){return t/ju(e)}function Hu(t){return 360/Math.PI*Math.atan(Math.exp((180-360*t)*Math.PI/180))-90}var Gu=function(t,e,r){void 0===r&&(r=0),this.x=+t,this.y=+e,this.z=+r};Gu.fromLngLat=function(t,e){void 0===e&&(e=0);var r=zu.convert(t);return new Gu(Uu(r.lng),Vu(r.lat),qu(e,r.lat))},Gu.prototype.toLngLat=function(){return new zu(360*this.x-180,Hu(this.y))},Gu.prototype.toAltitude=function(){return this.z*ju(Hu(this.y))},Gu.prototype.meterInMercatorCoordinateUnits=function(){return 1/Nu*(t=Hu(this.y),1/Math.cos(t*Math.PI/180));var t};var Zu=function(t,e,r){this.z=t,this.x=e,this.y=r,this.key=Xu(0,t,t,e,r)};Zu.prototype.equals=function(t){return this.z===t.z&&this.x===t.x&&this.y===t.y},Zu.prototype.url=function(t,e){var r,n,i,o,a,s=(n=this.y,i=this.z,o=Lu(256*(r=this.x),256*(n=Math.pow(2,i)-n-1),i),a=Lu(256*(r+1),256*(n+1),i),o[0]+","+o[1]+","+a[0]+","+a[1]),l=function(t,e,r){for(var n,i="",o=t;o>0;o--)i+=(e&(n=1<<o-1)?1:0)+(r&n?2:0);return i}(this.z,this.x,this.y);return t[(this.x+this.y)%t.length].replace("{prefix}",(this.x%16).toString(16)+(this.y%16).toString(16)).replace("{z}",String(this.z)).replace("{x}",String(this.x)).replace("{y}",String("tms"===e?Math.pow(2,this.z)-this.y-1:this.y)).replace("{quadkey}",l).replace("{bbox-epsg-3857}",s)},Zu.prototype.getTilePoint=function(t){var e=Math.pow(2,this.z);return new i(8192*(t.x*e-this.x),8192*(t.y*e-this.y))},Zu.prototype.toString=function(){return this.z+"/"+this.x+"/"+this.y};var Wu=function(t,e){this.wrap=t,this.canonical=e,this.key=Xu(t,e.z,e.z,e.x,e.y)},Yu=function(t,e,r,n,i){this.overscaledZ=t,this.wrap=e,this.canonical=new Zu(r,+n,+i),this.key=Xu(e,t,r,n,i)};function Xu(t,e,r,n,i){(t*=2)<0&&(t=-1*t-1);var o=1<<r;return(o*o*t+o*i+n).toString(36)+r.toString(36)+e.toString(36)}Yu.prototype.equals=function(t){return this.overscaledZ===t.overscaledZ&&this.wrap===t.wrap&&this.canonical.equals(t.canonical)},Yu.prototype.scaledTo=function(t){var e=this.canonical.z-t;return t>this.canonical.z?new Yu(t,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new Yu(t,this.wrap,t,this.canonical.x>>e,this.canonical.y>>e)},Yu.prototype.calculateScaledKey=function(t,e){var r=this.canonical.z-t;return t>this.canonical.z?Xu(this.wrap*+e,t,this.canonical.z,this.canonical.x,this.canonical.y):Xu(this.wrap*+e,t,t,this.canonical.x>>r,this.canonical.y>>r)},Yu.prototype.isChildOf=function(t){if(t.wrap!==this.wrap)return!1;var e=this.canonical.z-t.canonical.z;return 0===t.overscaledZ||t.overscaledZ<this.overscaledZ&&t.canonical.x===this.canonical.x>>e&&t.canonical.y===this.canonical.y>>e},Yu.prototype.children=function(t){if(this.overscaledZ>=t)return[new Yu(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];var e=this.canonical.z+1,r=2*this.canonical.x,n=2*this.canonical.y;return[new Yu(e,this.wrap,e,r,n),new Yu(e,this.wrap,e,r+1,n),new Yu(e,this.wrap,e,r,n+1),new Yu(e,this.wrap,e,r+1,n+1)]},Yu.prototype.isLessThan=function(t){return this.wrap<t.wrap||!(this.wrap>t.wrap)&&(this.overscaledZ<t.overscaledZ||!(this.overscaledZ>t.overscaledZ)&&(this.canonical.x<t.canonical.x||!(this.canonical.x>t.canonical.x)&&this.canonical.y<t.canonical.y))},Yu.prototype.wrapped=function(){return new Yu(this.overscaledZ,0,this.canonical.z,this.canonical.x,this.canonical.y)},Yu.prototype.unwrapTo=function(t){return new Yu(this.overscaledZ,t,this.canonical.z,this.canonical.x,this.canonical.y)},Yu.prototype.overscaleFactor=function(){return Math.pow(2,this.overscaledZ-this.canonical.z)},Yu.prototype.toUnwrapped=function(){return new Wu(this.wrap,this.canonical)},Yu.prototype.toString=function(){return this.overscaledZ+"/"+this.canonical.x+"/"+this.canonical.y},Yu.prototype.getTilePoint=function(t){return this.canonical.getTilePoint(new Gu(t.x-this.wrap,t.y))},zn("CanonicalTileID",Zu),zn("OverscaledTileID",Yu,{omit:["posMatrix"]});var Ku=function(t,e,r){if(this.uid=t,e.height!==e.width)throw new RangeError("DEM tiles must be square");if(r&&"mapbox"!==r&&"terrarium"!==r)return E('"'+r+'" is not a valid encoding type. Valid types include "mapbox" and "terrarium".');this.stride=e.height;var n=this.dim=e.height-2;this.data=new Uint32Array(e.data.buffer),this.encoding=r||"mapbox";for(var i=0;i<n;i++)this.data[this._idx(-1,i)]=this.data[this._idx(0,i)],this.data[this._idx(n,i)]=this.data[this._idx(n-1,i)],this.data[this._idx(i,-1)]=this.data[this._idx(i,0)],this.data[this._idx(i,n)]=this.data[this._idx(i,n-1)];this.data[this._idx(-1,-1)]=this.data[this._idx(0,0)],this.data[this._idx(n,-1)]=this.data[this._idx(n-1,0)],this.data[this._idx(-1,n)]=this.data[this._idx(0,n-1)],this.data[this._idx(n,n)]=this.data[this._idx(n-1,n-1)]};Ku.prototype.get=function(t,e){var r=new Uint8Array(this.data.buffer),n=4*this._idx(t,e);return("terrarium"===this.encoding?this._unpackTerrarium:this._unpackMapbox)(r[n],r[n+1],r[n+2])},Ku.prototype.getUnpackVector=function(){return"terrarium"===this.encoding?[256,1,1/256,32768]:[6553.6,25.6,.1,1e4]},Ku.prototype._idx=function(t,e){if(t<-1||t>=this.dim+1||e<-1||e>=this.dim+1)throw new RangeError("out of range source coordinates for DEM data");return(e+1)*this.stride+(t+1)},Ku.prototype._unpackMapbox=function(t,e,r){return(256*t*256+256*e+r)/10-1e4},Ku.prototype._unpackTerrarium=function(t,e,r){return 256*t+e+r/256-32768},Ku.prototype.getPixels=function(){return new _a({width:this.stride,height:this.stride},new Uint8Array(this.data.buffer))},Ku.prototype.backfillBorder=function(t,e,r){if(this.dim!==t.dim)throw new Error("dem dimension mismatch");var n=e*this.dim,i=e*this.dim+this.dim,o=r*this.dim,a=r*this.dim+this.dim;switch(e){case-1:n=i-1;break;case 1:i=n+1}switch(r){case-1:o=a-1;break;case 1:a=o+1}for(var s=-e*this.dim,l=-r*this.dim,u=o;u<a;u++)for(var c=n;c<i;c++)this.data[this._idx(c,u)]=t.data[this._idx(c+s,u+l)]},zn("DEMData",Ku);var Ju=function(t){this._stringToNumber={},this._numberToString=[];for(var e=0;e<t.length;e++){var r=t[e];this._stringToNumber[r]=e,this._numberToString[e]=r}};Ju.prototype.encode=function(t){return this._stringToNumber[t]},Ju.prototype.decode=function(t){return this._numberToString[t]};var Qu=function(t,e,r,n,i){this.type="Feature",this._vectorTileFeature=t,t._z=e,t._x=r,t._y=n,this.properties=t.properties,this.id=i},$u={geometry:{configurable:!0}};$u.geometry.get=function(){return void 0===this._geometry&&(this._geometry=this._vectorTileFeature.toGeoJSON(this._vectorTileFeature._x,this._vectorTileFeature._y,this._vectorTileFeature._z).geometry),this._geometry},$u.geometry.set=function(t){this._geometry=t},Qu.prototype.toJSON=function(){var t={geometry:this.geometry};for(var e in this)"_geometry"!==e&&"_vectorTileFeature"!==e&&(t[e]=this[e]);return t},Object.defineProperties(Qu.prototype,$u);var tc=function(){this.state={},this.stateChanges={},this.deletedStates={}};tc.prototype.updateState=function(t,e,r){var n=String(e);if(this.stateChanges[t]=this.stateChanges[t]||{},this.stateChanges[t][n]=this.stateChanges[t][n]||{},h(this.stateChanges[t][n],r),null===this.deletedStates[t])for(var i in this.deletedStates[t]={},this.state[t])i!==n&&(this.deletedStates[t][i]=null);else if(this.deletedStates[t]&&null===this.deletedStates[t][n])for(var o in this.deletedStates[t][n]={},this.state[t][n])r[o]||(this.deletedStates[t][n][o]=null);else for(var a in r)this.deletedStates[t]&&this.deletedStates[t][n]&&null===this.deletedStates[t][n][a]&&delete this.deletedStates[t][n][a]},tc.prototype.removeFeatureState=function(t,e,r){if(null!==this.deletedStates[t]){var n=String(e);if(this.deletedStates[t]=this.deletedStates[t]||{},r&&void 0!==e)null!==this.deletedStates[t][n]&&(this.deletedStates[t][n]=this.deletedStates[t][n]||{},this.deletedStates[t][n][r]=null);else if(void 0!==e)if(this.stateChanges[t]&&this.stateChanges[t][n])for(r in this.deletedStates[t][n]={},this.stateChanges[t][n])this.deletedStates[t][n][r]=null;else this.deletedStates[t][n]=null;else this.deletedStates[t]=null}},tc.prototype.getState=function(t,e){var r=String(e),n=h({},(this.state[t]||{})[r],(this.stateChanges[t]||{})[r]);if(null===this.deletedStates[t])return{};if(this.deletedStates[t]){var i=this.deletedStates[t][e];if(null===i)return{};for(var o in i)delete n[o]}return n},tc.prototype.initializeTileState=function(t,e){t.setFeatureState(this.state,e)},tc.prototype.coalesceChanges=function(t,e){var r={};for(var n in this.stateChanges){this.state[n]=this.state[n]||{};var i={};for(var o in this.stateChanges[n])this.state[n][o]||(this.state[n][o]={}),h(this.state[n][o],this.stateChanges[n][o]),i[o]=this.state[n][o];r[n]=i}for(var a in this.deletedStates){this.state[a]=this.state[a]||{};var s={};if(null===this.deletedStates[a])for(var l in this.state[a])s[l]={},this.state[a][l]={};else for(var u in this.deletedStates[a]){if(null===this.deletedStates[a][u])this.state[a][u]={};else for(var c=0,p=Object.keys(this.deletedStates[a][u]);c<p.length;c+=1)delete this.state[a][u][p[c]];s[u]=this.state[a][u]}r[a]=r[a]||{},h(r[a],s)}if(this.stateChanges={},this.deletedStates={},0!==Object.keys(r).length)for(var f in t)t[f].setFeatureState(r,e)};var ec=function(t,e){this.tileID=t,this.x=t.canonical.x,this.y=t.canonical.y,this.z=t.canonical.z,this.grid=new Bn(8192,16,0),this.grid3D=new Bn(8192,16,0),this.featureIndexArray=new oo,this.promoteId=e};function rc(t,e,r,n,i){return _(t,(function(t,o){var a=e instanceof mi?e.get(o):null;return a&&a.evaluate?a.evaluate(r,n,i):a}))}function nc(t){for(var e=1/0,r=1/0,n=-1/0,i=-1/0,o=0,a=t;o<a.length;o+=1){var s=a[o];e=Math.min(e,s.x),r=Math.min(r,s.y),n=Math.max(n,s.x),i=Math.max(i,s.y)}return{minX:e,minY:r,maxX:n,maxY:i}}function ic(t,e){return e-t}ec.prototype.insert=function(t,e,r,n,i,o){var a=this.featureIndexArray.length;this.featureIndexArray.emplaceBack(r,n,i);for(var s=o?this.grid3D:this.grid,l=0;l<e.length;l++){for(var u=e[l],c=[1/0,1/0,-1/0,-1/0],p=0;p<u.length;p++){var h=u[p];c[0]=Math.min(c[0],h.x),c[1]=Math.min(c[1],h.y),c[2]=Math.max(c[2],h.x),c[3]=Math.max(c[3],h.y)}c[0]<8192&&c[1]<8192&&c[2]>=0&&c[3]>=0&&s.insert(a,c[0],c[1],c[2],c[3])}},ec.prototype.loadVTLayers=function(){return this.vtLayers||(this.vtLayers=new bs.VectorTile(new Ks(this.rawTileData)).layers,this.sourceLayerCoder=new Ju(this.vtLayers?Object.keys(this.vtLayers).sort():["_geojsonTileLayer"])),this.vtLayers},ec.prototype.query=function(t,e,r,n){var o=this;this.loadVTLayers();for(var a=t.params||{},s=8192/t.tileSize/t.scale,l=an(a.filter),u=t.queryGeometry,c=t.queryPadding*s,p=nc(u),h=this.grid.query(p.minX-c,p.minY-c,p.maxX+c,p.maxY+c),f=nc(t.cameraQueryGeometry),d=0,m=this.grid3D.query(f.minX-c,f.minY-c,f.maxX+c,f.maxY+c,(function(e,r,n,o){return function(t,e,r,n,o){for(var a=0,s=t;a<s.length;a+=1){var l=s[a];if(e<=l.x&&r<=l.y&&n>=l.x&&o>=l.y)return!0}var u=[new i(e,r),new i(e,o),new i(n,o),new i(n,r)];if(t.length>2)for(var c=0,p=u;c<p.length;c+=1)if($o(t,p[c]))return!0;for(var h=0;h<t.length-1;h++)if(ta(t[h],t[h+1],u))return!0;return!1}(t.cameraQueryGeometry,e-c,r-c,n+c,o+c)}));d<m.length;d+=1)h.push(m[d]);h.sort(ic);for(var g,y={},v=function(i){var c=h[i];if(c!==g){g=c;var p=o.featureIndexArray.get(c),f=null;o.loadMatchingFeature(y,p.bucketIndex,p.sourceLayerIndex,p.featureIndex,l,a.layers,a.availableImages,e,r,n,(function(e,r,n){return f||(f=jo(e)),r.queryIntersectsFeature(u,e,n,f,o.z,t.transform,s,t.pixelPosMatrix)}))}},_=0;_<h.length;_++)v(_);return y},ec.prototype.loadMatchingFeature=function(t,e,r,n,i,o,a,s,l,u,c){var p=this.bucketLayerIDs[e];if(!o||function(t,e){for(var r=0;r<t.length;r++)if(e.indexOf(t[r])>=0)return!0;return!1}(o,p)){var f=this.sourceLayerCoder.decode(r),d=this.vtLayers[f].feature(n);if(i.needGeometry){var m=Uo(d,!0);if(!i.filter(new si(this.tileID.overscaledZ),m,this.tileID.canonical))return}else if(!i.filter(new si(this.tileID.overscaledZ),d))return;for(var g=this.getId(d,f),y=0;y<p.length;y++){var v=p[y];if(!(o&&o.indexOf(v)<0)){var _=s[v];if(_){var b={};void 0!==g&&u&&(b=u.getState(_.sourceLayer||"_geojsonTileLayer",g));var x=h({},l[v]);x.paint=rc(x.paint,_.paint,d,b,a),x.layout=rc(x.layout,_.layout,d,b,a);var w=!c||c(d,_,b);if(w){var E=new Qu(d,this.z,this.x,this.y,g);E.layer=x;var T=t[v];void 0===T&&(T=t[v]=[]),T.push({featureIndex:n,feature:E,intersectionZ:w})}}}}}},ec.prototype.lookupSymbolFeatures=function(t,e,r,n,i,o,a,s){var l={};this.loadVTLayers();for(var u=an(i),c=0,p=t;c<p.length;c+=1)this.loadMatchingFeature(l,r,n,p[c],u,o,a,s,e);return l},ec.prototype.hasLayer=function(t){for(var e=0,r=this.bucketLayerIDs;e<r.length;e+=1)for(var n=0,i=r[e];n<i.length;n+=1)if(t===i[n])return!0;return!1},ec.prototype.getId=function(t,e){var r=t.id;return this.promoteId&&"boolean"==typeof(r=t.properties["string"==typeof this.promoteId?this.promoteId:this.promoteId[e]])&&(r=Number(r)),r},zn("FeatureIndex",ec,{omit:["rawTileData","sourceLayerCoder"]});var oc=function(t,e){this.tileID=t,this.uid=d(),this.uses=0,this.tileSize=e,this.buckets={},this.expirationTime=null,this.queryPadding=0,this.hasSymbolBuckets=!1,this.hasRTLText=!1,this.dependencies={},this.expiredRequestCount=0,this.state="loading"};oc.prototype.registerFadeDuration=function(t){var e=t+this.timeAdded;e<z.now()||this.fadeEndTime&&e<this.fadeEndTime||(this.fadeEndTime=e)},oc.prototype.wasRequested=function(){return"errored"===this.state||"loaded"===this.state||"reloading"===this.state},oc.prototype.loadVectorData=function(t,e,r){if(this.hasData()&&this.unloadVectorData(),this.state="loaded",t){for(var n in t.featureIndex&&(this.latestFeatureIndex=t.featureIndex,t.rawTileData?(this.latestRawTileData=t.rawTileData,this.latestFeatureIndex.rawTileData=t.rawTileData):this.latestRawTileData&&(this.latestFeatureIndex.rawTileData=this.latestRawTileData)),this.collisionBoxArray=t.collisionBoxArray,this.buckets=function(t,e){var r={};if(!e)return r;for(var n=function(){var t=o[i],n=t.layerIds.map((function(t){return e.getLayer(t)})).filter(Boolean);if(0!==n.length){t.layers=n,t.stateDependentLayerIds&&(t.stateDependentLayers=t.stateDependentLayerIds.map((function(t){return n.filter((function(e){return e.id===t}))[0]})));for(var a=0,s=n;a<s.length;a+=1)r[s[a].id]=t}},i=0,o=t;i<o.length;i+=1)n();return r}(t.buckets,e.style),this.hasSymbolBuckets=!1,this.buckets){var i=this.buckets[n];if(i instanceof yu){if(this.hasSymbolBuckets=!0,!r)break;i.justReloaded=!0}}if(this.hasRTLText=!1,this.hasSymbolBuckets)for(var o in this.buckets){var a=this.buckets[o];if(a instanceof yu&&a.hasRTLText){this.hasRTLText=!0,ai.isLoading()||ai.isLoaded()||"deferred"!==ii()||oi();break}}for(var s in this.queryPadding=0,this.buckets){var l=this.buckets[s];this.queryPadding=Math.max(this.queryPadding,e.style.getLayer(s).queryRadius(l))}t.imageAtlas&&(this.imageAtlas=t.imageAtlas),t.glyphAtlasImage&&(this.glyphAtlasImage=t.glyphAtlasImage)}else this.collisionBoxArray=new Ji},oc.prototype.unloadVectorData=function(){for(var t in this.buckets)this.buckets[t].destroy();this.buckets={},this.imageAtlasTexture&&this.imageAtlasTexture.destroy(),this.imageAtlas&&(this.imageAtlas=null),this.glyphAtlasTexture&&this.glyphAtlasTexture.destroy(),this.latestFeatureIndex=null,this.state="unloaded"},oc.prototype.getBucket=function(t){return this.buckets[t.id]},oc.prototype.upload=function(t){for(var e in this.buckets){var r=this.buckets[e];r.uploadPending()&&r.upload(t)}var n=t.gl;this.imageAtlas&&!this.imageAtlas.uploaded&&(this.imageAtlasTexture=new Bu(t,this.imageAtlas.image,n.RGBA),this.imageAtlas.uploaded=!0),this.glyphAtlasImage&&(this.glyphAtlasTexture=new Bu(t,this.glyphAtlasImage,n.ALPHA),this.glyphAtlasImage=null)},oc.prototype.prepare=function(t){this.imageAtlas&&this.imageAtlas.patchUpdatedImages(t,this.imageAtlasTexture)},oc.prototype.queryRenderedFeatures=function(t,e,r,n,i,o,a,s,l,u){return this.latestFeatureIndex&&this.latestFeatureIndex.rawTileData?this.latestFeatureIndex.query({queryGeometry:n,cameraQueryGeometry:i,scale:o,tileSize:this.tileSize,pixelPosMatrix:u,transform:s,params:a,queryPadding:this.queryPadding*l},t,e,r):{}},oc.prototype.querySourceFeatures=function(t,e){var r=this.latestFeatureIndex;if(r&&r.rawTileData){var n=r.loadVTLayers(),i=e?e.sourceLayer:"",o=n._geojsonTileLayer||n[i];if(o)for(var a=an(e&&e.filter),s=this.tileID.canonical,l=s.z,u=s.x,c=s.y,p={z:l,x:u,y:c},h=0;h<o.length;h++){var f=o.feature(h);if(a.needGeometry){var d=Uo(f,!0);if(!a.filter(new si(this.tileID.overscaledZ),d,this.tileID.canonical))continue}else if(!a.filter(new si(this.tileID.overscaledZ),f))continue;var m=r.getId(f,i),g=new Qu(f,l,u,c,m);g.tile=p,t.push(g)}}},oc.prototype.hasData=function(){return"loaded"===this.state||"reloading"===this.state||"expired"===this.state},oc.prototype.patternsLoaded=function(){return this.imageAtlas&&!!Object.keys(this.imageAtlas.patternPositions).length},oc.prototype.setExpiryData=function(t){var e=this.expirationTime;if(t.cacheControl){var r=S(t.cacheControl);r["max-age"]&&(this.expirationTime=Date.now()+1e3*r["max-age"])}else t.expires&&(this.expirationTime=new Date(t.expires).getTime());if(this.expirationTime){var n=Date.now(),i=!1;if(this.expirationTime>n)i=!1;else if(e)if(this.expirationTime<e)i=!0;else{var o=this.expirationTime-e;o?this.expirationTime=n+Math.max(o,3e4):i=!0}else i=!0;i?(this.expiredRequestCount++,this.state="expired"):this.expiredRequestCount=0}},oc.prototype.getExpiryTimeout=function(){if(this.expirationTime)return this.expiredRequestCount?1e3*(1<<Math.min(this.expiredRequestCount-1,31)):Math.min(this.expirationTime-(new Date).getTime(),Math.pow(2,31)-1)},oc.prototype.setFeatureState=function(t,e){if(this.latestFeatureIndex&&this.latestFeatureIndex.rawTileData&&0!==Object.keys(t).length){var r=this.latestFeatureIndex.loadVTLayers();for(var n in this.buckets)if(e.style.hasLayer(n)){var i=this.buckets[n],o=i.layers[0].sourceLayer||"_geojsonTileLayer",a=r[o],s=t[o];if(a&&s&&0!==Object.keys(s).length){i.update(s,a,this.imageAtlas&&this.imageAtlas.patternPositions||{});var l=e&&e.style&&e.style.getLayer(n);l&&(this.queryPadding=Math.max(this.queryPadding,l.queryRadius(i)))}}}},oc.prototype.holdingForFade=function(){return void 0!==this.symbolFadeHoldUntil},oc.prototype.symbolFadeFinished=function(){return!this.symbolFadeHoldUntil||this.symbolFadeHoldUntil<z.now()},oc.prototype.clearFadeHold=function(){this.symbolFadeHoldUntil=void 0},oc.prototype.setHoldDuration=function(t){this.symbolFadeHoldUntil=z.now()+t},oc.prototype.setDependencies=function(t,e){for(var r={},n=0,i=e;n<i.length;n+=1)r[i[n]]=!0;this.dependencies[t]=r},oc.prototype.hasDependency=function(t,e){for(var r=0,n=t;r<n.length;r+=1){var i=this.dependencies[n[r]];if(i)for(var o=0,a=e;o<a.length;o+=1)if(i[a[o]])return!0}return!1};var ac=a.performance,sc=function(t){this._marks={start:[t.url,"start"].join("#"),end:[t.url,"end"].join("#"),measure:t.url.toString()},ac.mark(this._marks.start)};sc.prototype.finish=function(){ac.mark(this._marks.end);var t=ac.getEntriesByName(this._marks.measure);return 0===t.length&&(ac.measure(this._marks.measure,this._marks.start,this._marks.end),t=ac.getEntriesByName(this._marks.measure),ac.clearMarks(this._marks.start),ac.clearMarks(this._marks.end),ac.clearMeasures(this._marks.measure)),t},t.Actor=Fu,t.AlphaImage=va,t.CanonicalTileID=Zu,t.CollisionBoxArray=Ji,t.Color=te,t.DEMData=Ku,t.DataConstantProperty=gi,t.DictionaryCoder=Ju,t.EXTENT=8192,t.ErrorEvent=St,t.EvaluationParameters=si,t.Event=Ct,t.Evented=Pt,t.FeatureIndex=ec,t.FillBucket=ss,t.FillExtrusionBucket=Ts,t.ImageAtlas=bl,t.ImagePosition=vl,t.LineBucket=Fs,t.LngLat=zu,t.LngLatBounds=Ru,t.MercatorCoordinate=Gu,t.ONE_EM=24,t.OverscaledTileID=Yu,t.Point=i,t.Point$1=i,t.Properties=xi,t.Protobuf=Ks,t.RGBAImage=_a,t.RequestManager=G,t.RequestPerformance=sc,t.ResourceType=dt,t.SegmentVector=so,t.SourceFeatureState=tc,t.StructArrayLayout1ui2=Yi,t.StructArrayLayout2f1f2i16=Ni,t.StructArrayLayout2i4=Pi,t.StructArrayLayout3ui6=Ui,t.StructArrayLayout4i8=Ii,t.SymbolBucket=yu,t.Texture=Bu,t.Tile=oc,t.Transitionable=ci,t.Uniform1f=xo,t.Uniform1i=bo,t.Uniform2f=wo,t.Uniform3f=Eo,t.Uniform4f=To,t.UniformColor=Ao,t.UniformMatrix4f=So,t.UnwrappedTileID=Wu,t.ValidationError=Dt,t.WritingMode=xl,t.ZoomHistory=Hn,t.add=function(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t[2]=e[2]+r[2],t},t.addDynamicAttributes=fu,t.asyncAll=function(t,e,r){if(!t.length)return r(null,[]);var n=t.length,i=new Array(t.length),o=null;t.forEach((function(t,a){e(t,(function(t,e){t&&(o=t),i[a]=e,0==--n&&r(o,i)}))}))},t.bezier=l,t.bindAll=y,t.browser=z,t.cacheEntryPossiblyAdded=function(t){++ht>lt&&(t.getActor().send("enforceCacheSizeLimit",st),ht=0)},t.clamp=c,t.clearTileCache=function(t){var e=a.caches.delete("mapbox-tiles");t&&e.catch(t).then((function(){return t()}))},t.clipLine=Zl,t.clone=function(t){var e=new aa(16);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e},t.clone$1=x,t.clone$2=function(t){var e=new aa(3);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e},t.collisionCircleLayout=Gs,t.config=N,t.create=function(){var t=new aa(16);return aa!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0),t[0]=1,t[5]=1,t[10]=1,t[15]=1,t},t.create$1=function(){var t=new aa(9);return aa!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[5]=0,t[6]=0,t[7]=0),t[0]=1,t[4]=1,t[8]=1,t},t.create$2=function(){var t=new aa(4);return aa!=Float32Array&&(t[1]=0,t[2]=0),t[0]=1,t[3]=1,t},t.createCommonjsModule=e,t.createExpression=Zr,t.createLayout=Ci,t.createStyleLayer=function(t){return"custom"===t.type?new Cu(t):new Su[t.type](t)},t.cross=function(t,e,r){var n=e[0],i=e[1],o=e[2],a=r[0],s=r[1],l=r[2];return t[0]=i*l-o*s,t[1]=o*a-n*l,t[2]=n*s-i*a,t},t.deepEqual=function t(e,r){if(Array.isArray(e)){if(!Array.isArray(r)||e.length!==r.length)return!1;for(var n=0;n<e.length;n++)if(!t(e[n],r[n]))return!1;return!0}if("object"==typeof e&&null!==e&&null!==r){if("object"!=typeof r)return!1;if(Object.keys(e).length!==Object.keys(r).length)return!1;for(var i in e)if(!t(e[i],r[i]))return!1;return!0}return e===r},t.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]},t.dot$1=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]},t.ease=u,t.emitValidationErrors=Mn,t.endsWith=v,t.enforceCacheSizeLimit=function(t){ut(),tt&&tt.then((function(e){e.keys().then((function(r){for(var n=0;n<r.length-t;n++)e.delete(r[n])}))}))},t.evaluateSizeForFeature=Rl,t.evaluateSizeForZoom=zl,t.evaluateVariableOffset=ou,t.evented=ni,t.extend=h,t.featureFilter=an,t.filterObject=b,t.fromRotation=function(t,e){var r=Math.sin(e),n=Math.cos(e);return t[0]=n,t[1]=r,t[2]=0,t[3]=-r,t[4]=n,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},t.getAnchorAlignment=Ml,t.getAnchorJustification=au,t.getArrayBuffer=bt,t.getImage=Et,t.getJSON=function(t,e){return _t(h(t,{type:"json"}),e)},t.getRTLTextPluginStatus=ii,t.getReferrer=vt,t.getVideo=function(t,e){var r,n,i=a.document.createElement("video");i.muted=!0,i.onloadstart=function(){e(null,i)};for(var o=0;o<t.length;o++){var s=a.document.createElement("source");r=t[o],n=void 0,(n=a.document.createElement("a")).href=r,(n.protocol!==a.document.location.protocol||n.host!==a.document.location.host)&&(i.crossOrigin="Anonymous"),s.src=t[o],i.appendChild(s)}return{cancel:function(){}}},t.identity=sa,t.invert=function(t,e){var r=e[0],n=e[1],i=e[2],o=e[3],a=e[4],s=e[5],l=e[6],u=e[7],c=e[8],p=e[9],h=e[10],f=e[11],d=e[12],m=e[13],g=e[14],y=e[15],v=r*s-n*a,_=r*l-i*a,b=r*u-o*a,x=n*l-i*s,w=n*u-o*s,E=i*u-o*l,T=c*m-p*d,A=c*g-h*d,C=c*y-f*d,S=p*g-h*m,P=p*y-f*m,I=h*y-f*g,D=v*I-_*P+b*S+x*C-w*A+E*T;return D?(t[0]=(s*I-l*P+u*S)*(D=1/D),t[1]=(i*P-n*I-o*S)*D,t[2]=(m*E-g*w+y*x)*D,t[3]=(h*w-p*E-f*x)*D,t[4]=(l*C-a*I-u*A)*D,t[5]=(r*I-i*C+o*A)*D,t[6]=(g*b-d*E-y*_)*D,t[7]=(c*E-h*b+f*_)*D,t[8]=(a*P-s*C+u*T)*D,t[9]=(n*C-r*P-o*T)*D,t[10]=(d*w-m*b+y*v)*D,t[11]=(p*b-c*w-f*v)*D,t[12]=(s*A-a*S-l*T)*D,t[13]=(r*S-n*A+i*T)*D,t[14]=(m*_-d*x-g*v)*D,t[15]=(c*x-p*_+h*v)*D,t):null},t.isChar=Gn,t.isMapboxURL=Z,t.keysDifference=function(t,e){var r=[];for(var n in t)n in e||r.push(n);return r},t.makeRequest=_t,t.mapObject=_,t.mercatorXfromLng=Uu,t.mercatorYfromLat=Vu,t.mercatorZfromAltitude=qu,t.mul=ca,t.multiply=la,t.mvt=bs,t.nextPowerOfTwo=function(t){return t<=1?1:Math.pow(2,Math.ceil(Math.log(t)/Math.LN2))},t.normalize=function(t,e){var r=e[0],n=e[1],i=e[2],o=r*r+n*n+i*i;return o>0&&(o=1/Math.sqrt(o)),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o,t},t.number=He,t.offscreenCanvasSupported=ft,t.ortho=function(t,e,r,n,i,o,a){var s=1/(e-r),l=1/(n-i),u=1/(o-a);return t[0]=-2*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*l,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*u,t[11]=0,t[12]=(e+r)*s,t[13]=(i+n)*l,t[14]=(a+o)*u,t[15]=1,t},t.parseGlyphPBF=function(t){return new Ks(t).readFields(dl,[])},t.pbf=Ks,t.performSymbolLayout=function(t,e,r,n,i,o,a){t.createArrays(),t.tilePixelRatio=8192/(512*t.overscaling),t.compareText={},t.iconsNeedLinear=!1;var s=t.layers[0].layout,l=t.layers[0]._unevaluatedLayout._values,u={};if("composite"===t.textSizeData.kind){var c=t.textSizeData,p=c.maxZoom;u.compositeTextSizes=[l["text-size"].possiblyEvaluate(new si(c.minZoom),a),l["text-size"].possiblyEvaluate(new si(p),a)]}if("composite"===t.iconSizeData.kind){var h=t.iconSizeData,f=h.maxZoom;u.compositeIconSizes=[l["icon-size"].possiblyEvaluate(new si(h.minZoom),a),l["icon-size"].possiblyEvaluate(new si(f),a)]}u.layoutTextSize=l["text-size"].possiblyEvaluate(new si(t.zoom+1),a),u.layoutIconSize=l["icon-size"].possiblyEvaluate(new si(t.zoom+1),a),u.textMaxSize=l["text-size"].possiblyEvaluate(new si(18));for(var d=24*s.get("text-line-height"),m="map"===s.get("text-rotation-alignment")&&"point"!==s.get("symbol-placement"),g=s.get("text-keep-upright"),y=s.get("text-size"),v=function(){var o=b[_],l=s.get("text-font").evaluate(o,{},a).join(","),c=y.evaluate(o,{},a),p=u.layoutTextSize.evaluate(o,{},a),h=u.layoutIconSize.evaluate(o,{},a),f={horizontal:{},vertical:void 0},v=o.text,x=[0,0];if(v){var w=v.toString(),T=24*s.get("text-letter-spacing").evaluate(o,{},a),A=function(t){for(var e=0,r=t;e<r.length;e+=1)if(n=r[e].charCodeAt(0),Gn.Arabic(n)||Gn["Arabic Supplement"](n)||Gn["Arabic Extended-A"](n)||Gn["Arabic Presentation Forms-A"](n)||Gn["Arabic Presentation Forms-B"](n))return!1;var n;return!0}(w)?T:0,C=s.get("text-anchor").evaluate(o,{},a),S=s.get("text-variable-anchor");if(!S){var P=s.get("text-radial-offset").evaluate(o,{},a);x=P?ou(C,[24*P,iu]):s.get("text-offset").evaluate(o,{},a).map((function(t){return 24*t}))}var I=m?"center":s.get("text-justify").evaluate(o,{},a),D=s.get("symbol-placement"),O="point"===D?24*s.get("text-max-width").evaluate(o,{},a):0,M=function(){t.allowVerticalPlacement&&Zn(w)&&(f.vertical=Tl(v,e,r,i,l,O,d,C,"left",A,x,xl.vertical,!0,D,p,c))};if(!m&&S){for(var B="auto"===I?S.map((function(t){return au(t)})):[I],k=!1,F=0;F<B.length;F++){var L=B[F];if(!f.horizontal[L])if(k)f.horizontal[L]=f.horizontal[0];else{var R=Tl(v,e,r,i,l,O,d,"center",L,A,x,xl.horizontal,!1,D,p,c);R&&(f.horizontal[L]=R,k=1===R.positionedLines.length)}}M()}else{"auto"===I&&(I=au(C));var z=Tl(v,e,r,i,l,O,d,C,I,A,x,xl.horizontal,!1,D,p,c);z&&(f.horizontal[I]=z),M(),Zn(w)&&m&&g&&(f.vertical=Tl(v,e,r,i,l,O,d,C,I,A,x,xl.vertical,!1,D,p,c))}}var N=void 0,j=!1;if(o.icon&&o.icon.name){var U=n[o.icon.name];U&&(N=function(t,e,r){var n=Ml(r),i=e[0]-t.displaySize[0]*n.horizontalAlign,o=e[1]-t.displaySize[1]*n.verticalAlign;return{image:t,top:o,bottom:o+t.displaySize[1],left:i,right:i+t.displaySize[0]}}(i[o.icon.name],s.get("icon-offset").evaluate(o,{},a),s.get("icon-anchor").evaluate(o,{},a)),j=U.sdf,void 0===t.sdfIcons?t.sdfIcons=U.sdf:t.sdfIcons!==U.sdf&&E("Style sheet warning: Cannot mix SDF and non-SDF icons in one buffer"),(U.pixelRatio!==t.pixelRatio||0!==s.get("icon-rotate").constantOr(1))&&(t.iconsNeedLinear=!0))}var V=lu(f.horizontal)||f.vertical;t.iconsInText=!!V&&V.iconsInText,(V||N)&&function(t,e,r,n,i,o,a,s,l,u,c){var p=o.textMaxSize.evaluate(e,{});void 0===p&&(p=a);var h,f=t.layers[0].layout,d=f.get("icon-offset").evaluate(e,{},c),m=lu(r.horizontal),g=a/24,y=t.tilePixelRatio*g,v=t.tilePixelRatio*p/24,_=t.tilePixelRatio*s,b=t.tilePixelRatio*f.get("symbol-spacing"),x=f.get("text-padding")*t.tilePixelRatio,w=f.get("icon-padding")*t.tilePixelRatio,T=f.get("text-max-angle")/180*Math.PI,A="map"===f.get("text-rotation-alignment")&&"point"!==f.get("symbol-placement"),C="map"===f.get("icon-rotation-alignment")&&"point"!==f.get("symbol-placement"),S=f.get("symbol-placement"),P=b/2,I=f.get("icon-text-fit");n&&"none"!==I&&(t.allowVerticalPlacement&&r.vertical&&(h=kl(n,r.vertical,I,f.get("icon-text-fit-padding"),d,g)),m&&(n=kl(n,m,I,f.get("icon-text-fit-padding"),d,g)));var D=function(s,p){p.x<0||p.x>=8192||p.y<0||p.y>=8192||function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m,g,y,v,_,b,x,w,T,A){var C,S,P,I,D,O=t.addToLineVertexArray(e,r),M=0,B=0,k=0,F=0,L=-1,R=-1,z={},N=ho(""),j=0,U=0;if(void 0===s._unevaluatedLayout.getValue("text-radial-offset")?(j=(C=s.layout.get("text-offset").evaluate(b,{},T).map((function(t){return 24*t})))[0],U=C[1]):(j=24*s.layout.get("text-radial-offset").evaluate(b,{},T),U=iu),t.allowVerticalPlacement&&n.vertical){var V=s.layout.get("text-rotate").evaluate(b,{},T)+90;I=new Ql(l,e,u,c,p,n.vertical,h,f,d,V),a&&(D=new Ql(l,e,u,c,p,a,g,y,d,V))}if(i){var q=s.layout.get("icon-rotate").evaluate(b,{}),H="none"!==s.layout.get("icon-text-fit"),G=Wl(i,q,w,H),Z=a?Wl(a,q,w,H):void 0;P=new Ql(l,e,u,c,p,i,g,y,!1,q),M=4*G.length;var W=t.iconSizeData,Y=null;"source"===W.kind?(Y=[128*s.layout.get("icon-size").evaluate(b,{})])[0]>32640&&E(t.layerIds[0]+': Value for "icon-size" is >= 255. Reduce your "icon-size".'):"composite"===W.kind&&((Y=[128*x.compositeIconSizes[0].evaluate(b,{},T),128*x.compositeIconSizes[1].evaluate(b,{},T)])[0]>32640||Y[1]>32640)&&E(t.layerIds[0]+': Value for "icon-size" is >= 255. Reduce your "icon-size".'),t.addSymbols(t.icon,G,Y,_,v,b,!1,e,O.lineStartIndex,O.lineLength,-1,T),L=t.icon.placedSymbolArray.length-1,Z&&(B=4*Z.length,t.addSymbols(t.icon,Z,Y,_,v,b,xl.vertical,e,O.lineStartIndex,O.lineLength,-1,T),R=t.icon.placedSymbolArray.length-1)}for(var X in n.horizontal){var K=n.horizontal[X];if(!S){N=ho(K.text);var J=s.layout.get("text-rotate").evaluate(b,{},T);S=new Ql(l,e,u,c,p,K,h,f,d,J)}var Q=1===K.positionedLines.length;if(k+=su(t,e,K,o,s,d,b,m,O,n.vertical?xl.horizontal:xl.horizontalOnly,Q?Object.keys(n.horizontal):[X],z,L,x,T),Q)break}n.vertical&&(F+=su(t,e,n.vertical,o,s,d,b,m,O,xl.vertical,["vertical"],z,R,x,T));var $=S?S.boxStartIndex:t.collisionBoxArray.length,tt=S?S.boxEndIndex:t.collisionBoxArray.length,et=I?I.boxStartIndex:t.collisionBoxArray.length,rt=I?I.boxEndIndex:t.collisionBoxArray.length,nt=P?P.boxStartIndex:t.collisionBoxArray.length,it=P?P.boxEndIndex:t.collisionBoxArray.length,ot=D?D.boxStartIndex:t.collisionBoxArray.length,at=D?D.boxEndIndex:t.collisionBoxArray.length,st=-1,lt=function(t,e){return t&&t.circleDiameter?Math.max(t.circleDiameter,e):e};st=lt(S,st),st=lt(I,st),st=lt(P,st);var ut=(st=lt(D,st))>-1?1:0;ut&&(st*=A/24),t.glyphOffsetArray.length>=yu.MAX_GLYPHS&&E("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907"),void 0!==b.sortKey&&t.addToSortKeyRanges(t.symbolInstances.length,b.sortKey),t.symbolInstances.emplaceBack(e.x,e.y,z.right>=0?z.right:-1,z.center>=0?z.center:-1,z.left>=0?z.left:-1,z.vertical||-1,L,R,N,$,tt,et,rt,nt,it,ot,at,u,k,F,M,B,ut,0,h,j,U,st)}(t,p,s,r,n,i,h,t.layers[0],t.collisionBoxArray,e.index,e.sourceLayerIndex,t.index,y,x,A,l,_,w,C,d,e,o,u,c,a)};if("line"===S)for(var O=0,M=Zl(e.geometry,0,0,8192,8192);O<M.length;O+=1)for(var B=M[O],k=0,F=Gl(B,b,T,r.vertical||m,n,24,v,t.overscaling,8192);k<F.length;k+=1){var L=F[k];m&&uu(t,m.text,P,L)||D(B,L)}else if("line-center"===S)for(var R=0,z=e.geometry;R<z.length;R+=1){var N=z[R];if(N.length>1){var j=Hl(N,T,r.vertical||m,n,24,v);j&&D(N,j)}}else if("Polygon"===e.type)for(var U=0,V=ns(e.geometry,0);U<V.length;U+=1){var q=V[U],H=eu(q,16);D(q[0],new Fl(H.x,H.y,0))}else if("LineString"===e.type)for(var G=0,Z=e.geometry;G<Z.length;G+=1){var W=Z[G];D(W,new Fl(W[0].x,W[0].y,0))}else if("Point"===e.type)for(var Y=0,X=e.geometry;Y<X.length;Y+=1)for(var K=0,J=X[Y];K<J.length;K+=1){var Q=J[K];D([Q],new Fl(Q.x,Q.y,0))}}(t,o,f,N,n,u,p,h,x,j,a)},_=0,b=t.features;_<b.length;_+=1)v();o&&t.generateCollisionDebugBuffers()},t.perspective=function(t,e,r,n,i){var o,a=1/Math.tan(e/2);return t[0]=a/r,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=a,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=i&&i!==1/0?(t[10]=(i+n)*(o=1/(n-i)),t[14]=2*i*n*o):(t[10]=-1,t[14]=-2*n),t},t.pick=function(t,e){for(var r={},n=0;n<e.length;n++){var i=e[n];i in t&&(r[i]=t[i])}return r},t.plugin=ai,t.polygonIntersectsPolygon=Ho,t.postMapLoadEvent=at,t.postTurnstileEvent=it,t.potpack=yl,t.refProperties=["type","source","source-layer","minzoom","maxzoom","filter","layout"],t.register=zn,t.registerForPluginStateChange=function(t){return t({pluginStatus:$n,pluginURL:ti}),ni.on("pluginStateChange",t),t},t.renderColorRamp=xa,t.rotate=function(t,e,r){var n=e[0],i=e[1],o=e[2],a=e[3],s=Math.sin(r),l=Math.cos(r);return t[0]=n*l+o*s,t[1]=i*l+a*s,t[2]=n*-s+o*l,t[3]=i*-s+a*l,t},t.rotateX=function(t,e,r){var n=Math.sin(r),i=Math.cos(r),o=e[4],a=e[5],s=e[6],l=e[7],u=e[8],c=e[9],p=e[10],h=e[11];return e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=o*i+u*n,t[5]=a*i+c*n,t[6]=s*i+p*n,t[7]=l*i+h*n,t[8]=u*i-o*n,t[9]=c*i-a*n,t[10]=p*i-s*n,t[11]=h*i-l*n,t},t.rotateZ=function(t,e,r){var n=Math.sin(r),i=Math.cos(r),o=e[0],a=e[1],s=e[2],l=e[3],u=e[4],c=e[5],p=e[6],h=e[7];return e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i+u*n,t[1]=a*i+c*n,t[2]=s*i+p*n,t[3]=l*i+h*n,t[4]=u*i-o*n,t[5]=c*i-a*n,t[6]=p*i-s*n,t[7]=h*i-l*n,t},t.scale=function(t,e,r){var n=r[0],i=r[1],o=r[2];return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},t.scale$1=function(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t},t.scale$2=function(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t},t.setCacheLimits=function(t,e){st=t,lt=e},t.setRTLTextPlugin=function(t,e,r){if(void 0===r&&(r=!1),"deferred"===$n||"loading"===$n||"loaded"===$n)throw new Error("setRTLTextPlugin cannot be called multiple times.");ti=z.resolveURL(t),$n="deferred",Qn=e,ri(),r||oi()},t.sphericalToCartesian=function(t){var e=t[0],r=t[1],n=t[2];return r+=90,r*=Math.PI/180,n*=Math.PI/180,{x:e*Math.cos(r)*Math.sin(n),y:e*Math.sin(r)*Math.sin(n),z:e*Math.cos(n)}},t.sqrLen=function(t){var e=t[0],r=t[1];return e*e+r*r},t.styleSpec=It,t.sub=function(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t[2]=e[2]-r[2],t},t.symbolSize=Nl,t.transformMat3=function(t,e,r){var n=e[0],i=e[1],o=e[2];return t[0]=n*r[0]+i*r[3]+o*r[6],t[1]=n*r[1]+i*r[4]+o*r[7],t[2]=n*r[2]+i*r[5]+o*r[8],t},t.transformMat4=pa,t.translate=function(t,e,r){var n,i,o,a,s,l,u,c,p,h,f,d,m=r[0],g=r[1],y=r[2];return e===t?(t[12]=e[0]*m+e[4]*g+e[8]*y+e[12],t[13]=e[1]*m+e[5]*g+e[9]*y+e[13],t[14]=e[2]*m+e[6]*g+e[10]*y+e[14],t[15]=e[3]*m+e[7]*g+e[11]*y+e[15]):(i=e[1],o=e[2],a=e[3],s=e[4],l=e[5],u=e[6],c=e[7],p=e[8],h=e[9],f=e[10],d=e[11],t[0]=n=e[0],t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=l,t[6]=u,t[7]=c,t[8]=p,t[9]=h,t[10]=f,t[11]=d,t[12]=n*m+s*g+p*y+e[12],t[13]=i*m+l*g+h*y+e[13],t[14]=o*m+u*g+f*y+e[14],t[15]=a*m+c*g+d*y+e[15]),t},t.triggerPluginCompletionEvent=ei,t.uniqueId=d,t.validateCustomStyleLayer=function(t){var e=[],r=t.id;return void 0===r&&e.push({message:"layers."+r+': missing required property "id"'}),void 0===t.render&&e.push({message:"layers."+r+': missing required method "render"'}),t.renderingMode&&"2d"!==t.renderingMode&&"3d"!==t.renderingMode&&e.push({message:"layers."+r+': property "renderingMode" must be either "2d" or "3d"'}),e},t.validateLight=In,t.validateStyle=Pn,t.values=function(t){var e=[];for(var r in t)e.push(t[r]);return e},t.vectorTile=bs,t.version="1.13.1",t.warnOnce=E,t.webpSupported=j,t.window=a,t.wrap=p})),n(0,(function(t){function e(t){var r=typeof t;if("number"===r||"boolean"===r||"string"===r||null==t)return JSON.stringify(t);if(Array.isArray(t)){for(var n="[",i=0,o=t;i<o.length;i+=1)n+=e(o[i])+",";return n+"]"}for(var a=Object.keys(t).sort(),s="{",l=0;l<a.length;l++)s+=JSON.stringify(a[l])+":"+e(t[a[l]])+",";return s+"}"}function r(r){for(var n="",i=0,o=t.refProperties;i<o.length;i+=1)n+="/"+e(r[o[i]]);return n}var n=function(t){this.keyCache={},t&&this.replace(t)};n.prototype.replace=function(t){this._layerConfigs={},this._layers={},this.update(t,[])},n.prototype.update=function(e,n){for(var i=this,o=0,a=e;o<a.length;o+=1){var s=a[o];this._layerConfigs[s.id]=s;var l=this._layers[s.id]=t.createStyleLayer(s);l._featureFilter=t.featureFilter(l.filter),this.keyCache[s.id]&&delete this.keyCache[s.id]}for(var u=0,c=n;u<c.length;u+=1){var p=c[u];delete this.keyCache[p],delete this._layerConfigs[p],delete this._layers[p]}this.familiesBySource={};for(var h=0,f=function(t,e){for(var n={},i=0;i<t.length;i++){var o=e&&e[t[i].id]||r(t[i]);e&&(e[t[i].id]=o);var a=n[o];a||(a=n[o]=[]),a.push(t[i])}var s=[];for(var l in n)s.push(n[l]);return s}(t.values(this._layerConfigs),this.keyCache);h<f.length;h+=1){var d=f[h].map((function(t){return i._layers[t.id]})),m=d[0];if("none"!==m.visibility){var g=m.source||"",y=this.familiesBySource[g];y||(y=this.familiesBySource[g]={});var v=m.sourceLayer||"_geojsonTileLayer",_=y[v];_||(_=y[v]=[]),_.push(d)}}};var i=function(e){var r={},n=[];for(var i in e){var o=e[i],a=r[i]={};for(var s in o){var l=o[+s];if(l&&0!==l.bitmap.width&&0!==l.bitmap.height){var u={x:0,y:0,w:l.bitmap.width+2,h:l.bitmap.height+2};n.push(u),a[s]={rect:u,metrics:l.metrics}}}}var c=t.potpack(n),p=new t.AlphaImage({width:c.w||1,height:c.h||1});for(var h in e){var f=e[h];for(var d in f){var m=f[+d];if(m&&0!==m.bitmap.width&&0!==m.bitmap.height){var g=r[h][d].rect;t.AlphaImage.copy(m.bitmap,p,{x:0,y:0},{x:g.x+1,y:g.y+1},m.bitmap)}}}this.image=p,this.positions=r};t.register("GlyphAtlas",i);var o=function(e){this.tileID=new t.OverscaledTileID(e.tileID.overscaledZ,e.tileID.wrap,e.tileID.canonical.z,e.tileID.canonical.x,e.tileID.canonical.y),this.uid=e.uid,this.zoom=e.zoom,this.pixelRatio=e.pixelRatio,this.tileSize=e.tileSize,this.source=e.source,this.overscaling=this.tileID.overscaleFactor(),this.showCollisionBoxes=e.showCollisionBoxes,this.collectResourceTiming=!!e.collectResourceTiming,this.returnDependencies=!!e.returnDependencies,this.promoteId=e.promoteId};function a(e,r,n){for(var i=new t.EvaluationParameters(r),o=0,a=e;o<a.length;o+=1)a[o].recalculate(i,n)}function s(e,r){var n=t.getArrayBuffer(e.request,(function(e,n,i,o){e?r(e):n&&r(null,{vectorTile:new t.vectorTile.VectorTile(new t.pbf(n)),rawData:n,cacheControl:i,expires:o})}));return function(){n.cancel(),r()}}o.prototype.parse=function(e,r,n,o,s){var l=this;this.status="parsing",this.data=e,this.collisionBoxArray=new t.CollisionBoxArray;var u=new t.DictionaryCoder(Object.keys(e.layers).sort()),c=new t.FeatureIndex(this.tileID,this.promoteId);c.bucketLayerIDs=[];var p,h,f,d,m={},g={featureIndex:c,iconDependencies:{},patternDependencies:{},glyphDependencies:{},availableImages:n},y=r.familiesBySource[this.source];for(var v in y){var _=e.layers[v];if(_){1===_.version&&t.warnOnce('Vector tile source "'+this.source+'" layer "'+v+'" does not use vector tile spec v2 and therefore may have some rendering errors.');for(var b=u.encode(v),x=[],w=0;w<_.length;w++){var E=_.feature(w),T=c.getId(E,v);x.push({feature:E,id:T,index:w,sourceLayerIndex:b})}for(var A=0,C=y[v];A<C.length;A+=1){var S=C[A],P=S[0];P.minzoom&&this.zoom<Math.floor(P.minzoom)||P.maxzoom&&this.zoom>=P.maxzoom||"none"!==P.visibility&&(a(S,this.zoom,n),(m[P.id]=P.createBucket({index:c.bucketLayerIDs.length,layers:S,zoom:this.zoom,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray,sourceLayerIndex:b,sourceID:this.source})).populate(x,g,this.tileID.canonical),c.bucketLayerIDs.push(S.map((function(t){return t.id}))))}}}var I=t.mapObject(g.glyphDependencies,(function(t){return Object.keys(t).map(Number)}));Object.keys(I).length?o.send("getGlyphs",{uid:this.uid,stacks:I},(function(t,e){p||(p=t,h=e,M.call(l))})):h={};var D=Object.keys(g.iconDependencies);D.length?o.send("getImages",{icons:D,source:this.source,tileID:this.tileID,type:"icons"},(function(t,e){p||(p=t,f=e,M.call(l))})):f={};var O=Object.keys(g.patternDependencies);function M(){if(p)return s(p);if(h&&f&&d){var e=new i(h),r=new t.ImageAtlas(f,d);for(var o in m){var l=m[o];l instanceof t.SymbolBucket?(a(l.layers,this.zoom,n),t.performSymbolLayout(l,h,e.positions,f,r.iconPositions,this.showCollisionBoxes,this.tileID.canonical)):l.hasPattern&&(l instanceof t.LineBucket||l instanceof t.FillBucket||l instanceof t.FillExtrusionBucket)&&(a(l.layers,this.zoom,n),l.addFeatures(g,this.tileID.canonical,r.patternPositions))}this.status="done",s(null,{buckets:t.values(m).filter((function(t){return!t.isEmpty()})),featureIndex:c,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:e.image,imageAtlas:r,glyphMap:this.returnDependencies?h:null,iconMap:this.returnDependencies?f:null,glyphPositions:this.returnDependencies?e.positions:null})}}O.length?o.send("getImages",{icons:O,source:this.source,tileID:this.tileID,type:"patterns"},(function(t,e){p||(p=t,d=e,M.call(l))})):d={},M.call(this)};var l=function(t,e,r,n){this.actor=t,this.layerIndex=e,this.availableImages=r,this.loadVectorData=n||s,this.loading={},this.loaded={}};l.prototype.loadTile=function(e,r){var n=this,i=e.uid;this.loading||(this.loading={});var a=!!(e&&e.request&&e.request.collectResourceTiming)&&new t.RequestPerformance(e.request),s=this.loading[i]=new o(e);s.abort=this.loadVectorData(e,(function(e,o){if(delete n.loading[i],e||!o)return s.status="done",n.loaded[i]=s,r(e);var l=o.rawData,u={};o.expires&&(u.expires=o.expires),o.cacheControl&&(u.cacheControl=o.cacheControl);var c={};if(a){var p=a.finish();p&&(c.resourceTiming=JSON.parse(JSON.stringify(p)))}s.vectorTile=o.vectorTile,s.parse(o.vectorTile,n.layerIndex,n.availableImages,n.actor,(function(e,n){if(e||!n)return r(e);r(null,t.extend({rawTileData:l.slice(0)},n,u,c))})),n.loaded=n.loaded||{},n.loaded[i]=s}))},l.prototype.reloadTile=function(t,e){var r=this,n=this.loaded,i=t.uid,o=this;if(n&&n[i]){var a=n[i];a.showCollisionBoxes=t.showCollisionBoxes;var s=function(t,n){var i=a.reloadCallback;i&&(delete a.reloadCallback,a.parse(a.vectorTile,o.layerIndex,r.availableImages,o.actor,i)),e(t,n)};"parsing"===a.status?a.reloadCallback=s:"done"===a.status&&(a.vectorTile?a.parse(a.vectorTile,this.layerIndex,this.availableImages,this.actor,s):s())}},l.prototype.abortTile=function(t,e){var r=this.loading,n=t.uid;r&&r[n]&&r[n].abort&&(r[n].abort(),delete r[n]),e()},l.prototype.removeTile=function(t,e){var r=this.loaded,n=t.uid;r&&r[n]&&delete r[n],e()};var u=t.window.ImageBitmap,c=function(){this.loaded={}};function p(t,e){if(0!==t.length){h(t[0],e);for(var r=1;r<t.length;r++)h(t[r],!e)}}function h(t,e){for(var r=0,n=0,i=t.length,o=i-1;n<i;o=n++)r+=(t[n][0]-t[o][0])*(t[o][1]+t[n][1]);r>=0!=!!e&&t.reverse()}c.prototype.loadTile=function(e,r){var n=e.uid,i=e.encoding,o=e.rawImageData,a=u&&o instanceof u?this.getImageData(o):o,s=new t.DEMData(n,a,i);this.loaded=this.loaded||{},this.loaded[n]=s,r(null,s)},c.prototype.getImageData=function(e){this.offscreenCanvas&&this.offscreenCanvasContext||(this.offscreenCanvas=new OffscreenCanvas(e.width,e.height),this.offscreenCanvasContext=this.offscreenCanvas.getContext("2d")),this.offscreenCanvas.width=e.width,this.offscreenCanvas.height=e.height,this.offscreenCanvasContext.drawImage(e,0,0,e.width,e.height);var r=this.offscreenCanvasContext.getImageData(-1,-1,e.width+2,e.height+2);return this.offscreenCanvasContext.clearRect(0,0,this.offscreenCanvas.width,this.offscreenCanvas.height),new t.RGBAImage({width:r.width,height:r.height},r.data)},c.prototype.removeTile=function(t){var e=this.loaded,r=t.uid;e&&e[r]&&delete e[r]};var f=t.vectorTile.VectorTileFeature.prototype.toGeoJSON,d=function(e){this._feature=e,this.extent=t.EXTENT,this.type=e.type,this.properties=e.tags,"id"in e&&!isNaN(e.id)&&(this.id=parseInt(e.id,10))};d.prototype.loadGeometry=function(){if(1===this._feature.type){for(var e=[],r=0,n=this._feature.geometry;r<n.length;r+=1){var i=n[r];e.push([new t.Point$1(i[0],i[1])])}return e}for(var o=[],a=0,s=this._feature.geometry;a<s.length;a+=1){for(var l=[],u=0,c=s[a];u<c.length;u+=1){var p=c[u];l.push(new t.Point$1(p[0],p[1]))}o.push(l)}return o},d.prototype.toGeoJSON=function(t,e,r){return f.call(this,t,e,r)};var m=function(e){this.layers={_geojsonTileLayer:this},this.name="_geojsonTileLayer",this.extent=t.EXTENT,this.length=e.length,this._features=e};m.prototype.feature=function(t){return new d(this._features[t])};var g=t.vectorTile.VectorTileFeature,y=v;function v(t,e){this.options=e||{},this.features=t,this.length=t.length}function _(t,e){this.id="number"==typeof t.id?t.id:void 0,this.type=t.type,this.rawGeometry=1===t.type?[t.geometry]:t.geometry,this.properties=t.tags,this.extent=e||4096}v.prototype.feature=function(t){return new _(this.features[t],this.options.extent)},_.prototype.loadGeometry=function(){var e=this.rawGeometry;this.geometry=[];for(var r=0;r<e.length;r++){for(var n=e[r],i=[],o=0;o<n.length;o++)i.push(new t.Point$1(n[o][0],n[o][1]));this.geometry.push(i)}return this.geometry},_.prototype.bbox=function(){this.geometry||this.loadGeometry();for(var t=this.geometry,e=1/0,r=-1/0,n=1/0,i=-1/0,o=0;o<t.length;o++)for(var a=t[o],s=0;s<a.length;s++){var l=a[s];e=Math.min(e,l.x),r=Math.max(r,l.x),n=Math.min(n,l.y),i=Math.max(i,l.y)}return[e,n,r,i]},_.prototype.toGeoJSON=g.prototype.toGeoJSON;var b=w,x=y;function w(e){var r=new t.pbf;return function(t,e){for(var r in t.layers)e.writeMessage(3,E,t.layers[r])}(e,r),r.finish()}function E(t,e){var r;e.writeVarintField(15,t.version||1),e.writeStringField(1,t.name||""),e.writeVarintField(5,t.extent||4096);var n={keys:[],values:[],keycache:{},valuecache:{}};for(r=0;r<t.length;r++)n.feature=t.feature(r),e.writeMessage(2,T,n);var i=n.keys;for(r=0;r<i.length;r++)e.writeStringField(3,i[r]);var o=n.values;for(r=0;r<o.length;r++)e.writeMessage(4,I,o[r])}function T(t,e){var r=t.feature;void 0!==r.id&&e.writeVarintField(1,r.id),e.writeMessage(2,A,t),e.writeVarintField(3,r.type),e.writeMessage(4,P,r)}function A(t,e){var r=t.feature,n=t.keys,i=t.values,o=t.keycache,a=t.valuecache;for(var s in r.properties){var l=o[s];void 0===l&&(n.push(s),o[s]=l=n.length-1),e.writeVarint(l);var u=r.properties[s],c=typeof u;"string"!==c&&"boolean"!==c&&"number"!==c&&(u=JSON.stringify(u));var p=c+":"+u,h=a[p];void 0===h&&(i.push(u),a[p]=h=i.length-1),e.writeVarint(h)}}function C(t,e){return(e<<3)+(7&t)}function S(t){return t<<1^t>>31}function P(t,e){for(var r=t.loadGeometry(),n=t.type,i=0,o=0,a=r.length,s=0;s<a;s++){var l=r[s],u=1;1===n&&(u=l.length),e.writeVarint(C(1,u));for(var c=3===n?l.length-1:l.length,p=0;p<c;p++){1===p&&1!==n&&e.writeVarint(C(2,c-1));var h=l[p].x-i,f=l[p].y-o;e.writeVarint(S(h)),e.writeVarint(S(f)),i+=h,o+=f}3===n&&e.writeVarint(C(7,1))}}function I(t,e){var r=typeof t;"string"===r?e.writeStringField(1,t):"boolean"===r?e.writeBooleanField(7,t):"number"===r&&(t%1!=0?e.writeDoubleField(3,t):t<0?e.writeSVarintField(6,t):e.writeVarintField(5,t))}function D(t,e,r,n){O(t,r,n),O(e,2*r,2*n),O(e,2*r+1,2*n+1)}function O(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function M(t,e,r,n){var i=t-r,o=e-n;return i*i+o*o}b.fromVectorTileJs=w,b.fromGeojsonVt=function(t,e){e=e||{};var r={};for(var n in t)r[n]=new y(t[n].features,e),r[n].name=n,r[n].version=e.version,r[n].extent=e.extent;return w({layers:r})},b.GeoJSONWrapper=x;var B=function(t){return t[0]},k=function(t){return t[1]},F=function(t,e,r,n,i){void 0===e&&(e=B),void 0===r&&(r=k),void 0===n&&(n=64),void 0===i&&(i=Float64Array),this.nodeSize=n,this.points=t;for(var o=t.length<65536?Uint16Array:Uint32Array,a=this.ids=new o(t.length),s=this.coords=new i(2*t.length),l=0;l<t.length;l++)a[l]=l,s[2*l]=e(t[l]),s[2*l+1]=r(t[l]);!function t(e,r,n,i,o,a){if(!(o-i<=n)){var s=i+o>>1;!function t(e,r,n,i,o,a){for(;o>i;){if(o-i>600){var s=o-i+1,l=n-i+1,u=Math.log(s),c=.5*Math.exp(2*u/3),p=.5*Math.sqrt(u*c*(s-c)/s)*(l-s/2<0?-1:1);t(e,r,n,Math.max(i,Math.floor(n-l*c/s+p)),Math.min(o,Math.floor(n+(s-l)*c/s+p)),a)}var h=r[2*n+a],f=i,d=o;for(D(e,r,i,n),r[2*o+a]>h&&D(e,r,i,o);f<d;){for(D(e,r,f,d),f++,d--;r[2*f+a]<h;)f++;for(;r[2*d+a]>h;)d--}r[2*i+a]===h?D(e,r,i,d):D(e,r,++d,o),d<=n&&(i=d+1),n<=d&&(o=d-1)}}(e,r,s,i,o,a%2),t(e,r,n,i,s-1,a+1),t(e,r,n,s+1,o,a+1)}}(a,s,n,0,a.length-1,0)};F.prototype.range=function(t,e,r,n){return function(t,e,r,n,i,o,a){for(var s,l,u=[0,t.length-1,0],c=[];u.length;){var p=u.pop(),h=u.pop(),f=u.pop();if(h-f<=a)for(var d=f;d<=h;d++)l=e[2*d+1],(s=e[2*d])>=r&&s<=i&&l>=n&&l<=o&&c.push(t[d]);else{var m=Math.floor((f+h)/2);l=e[2*m+1],(s=e[2*m])>=r&&s<=i&&l>=n&&l<=o&&c.push(t[m]);var g=(p+1)%2;(0===p?r<=s:n<=l)&&(u.push(f),u.push(m-1),u.push(g)),(0===p?i>=s:o>=l)&&(u.push(m+1),u.push(h),u.push(g))}}return c}(this.ids,this.coords,t,e,r,n,this.nodeSize)},F.prototype.within=function(t,e,r){return function(t,e,r,n,i,o){for(var a=[0,t.length-1,0],s=[],l=i*i;a.length;){var u=a.pop(),c=a.pop(),p=a.pop();if(c-p<=o)for(var h=p;h<=c;h++)M(e[2*h],e[2*h+1],r,n)<=l&&s.push(t[h]);else{var f=Math.floor((p+c)/2),d=e[2*f],m=e[2*f+1];M(d,m,r,n)<=l&&s.push(t[f]);var g=(u+1)%2;(0===u?r-i<=d:n-i<=m)&&(a.push(p),a.push(f-1),a.push(g)),(0===u?r+i>=d:n+i>=m)&&(a.push(f+1),a.push(c),a.push(g))}}return s}(this.ids,this.coords,t,e,r,this.nodeSize)};var L={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:function(t){return t}},R=function(t){this.options=H(Object.create(L),t),this.trees=new Array(this.options.maxZoom+1)};function z(t,e,r,n,i){return{x:t,y:e,zoom:1/0,id:r,parentId:-1,numPoints:n,properties:i}}function N(t,e){var r=t.geometry.coordinates,n=r[1];return{x:V(r[0]),y:q(n),zoom:1/0,index:e,parentId:-1}}function j(t){return{type:"Feature",id:t.id,properties:U(t),geometry:{type:"Point",coordinates:[(n=t.x,360*(n-.5)),(e=t.y,r=(180-360*e)*Math.PI/180,360*Math.atan(Math.exp(r))/Math.PI-90)]}};var e,r,n}function U(t){var e=t.numPoints,r=e>=1e4?Math.round(e/1e3)+"k":e>=1e3?Math.round(e/100)/10+"k":e;return H(H({},t.properties),{cluster:!0,cluster_id:t.id,point_count:e,point_count_abbreviated:r})}function V(t){return t/360+.5}function q(t){var e=Math.sin(t*Math.PI/180),r=.5-.25*Math.log((1+e)/(1-e))/Math.PI;return r<0?0:r>1?1:r}function H(t,e){for(var r in e)t[r]=e[r];return t}function G(t){return t.x}function Z(t){return t.y}function W(t,e,r,n,i,o){var a=i-r,s=o-n;if(0!==a||0!==s){var l=((t-r)*a+(e-n)*s)/(a*a+s*s);l>1?(r=i,n=o):l>0&&(r+=a*l,n+=s*l)}return(a=t-r)*a+(s=e-n)*s}function Y(t,e,r,n){var i={id:void 0===t?null:t,type:e,geometry:r,tags:n,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(t){var e=t.geometry,r=t.type;if("Point"===r||"MultiPoint"===r||"LineString"===r)X(t,e);else if("Polygon"===r||"MultiLineString"===r)for(var n=0;n<e.length;n++)X(t,e[n]);else if("MultiPolygon"===r)for(n=0;n<e.length;n++)for(var i=0;i<e[n].length;i++)X(t,e[n][i])}(i),i}function X(t,e){for(var r=0;r<e.length;r+=3)t.minX=Math.min(t.minX,e[r]),t.minY=Math.min(t.minY,e[r+1]),t.maxX=Math.max(t.maxX,e[r]),t.maxY=Math.max(t.maxY,e[r+1])}function K(t,e,r,n){if(e.geometry){var i=e.geometry.coordinates,o=e.geometry.type,a=Math.pow(r.tolerance/((1<<r.maxZoom)*r.extent),2),s=[],l=e.id;if(r.promoteId?l=e.properties[r.promoteId]:r.generateId&&(l=n||0),"Point"===o)J(i,s);else if("MultiPoint"===o)for(var u=0;u<i.length;u++)J(i[u],s);else if("LineString"===o)Q(i,s,a,!1);else if("MultiLineString"===o){if(r.lineMetrics){for(u=0;u<i.length;u++)Q(i[u],s=[],a,!1),t.push(Y(l,"LineString",s,e.properties));return}$(i,s,a,!1)}else if("Polygon"===o)$(i,s,a,!0);else{if("MultiPolygon"!==o){if("GeometryCollection"===o){for(u=0;u<e.geometry.geometries.length;u++)K(t,{id:l,geometry:e.geometry.geometries[u],properties:e.properties},r,n);return}throw new Error("Input data is not a valid GeoJSON object.")}for(u=0;u<i.length;u++){var c=[];$(i[u],c,a,!0),s.push(c)}}t.push(Y(l,o,s,e.properties))}}function J(t,e){e.push(tt(t[0])),e.push(et(t[1])),e.push(0)}function Q(t,e,r,n){for(var i,o,a=0,s=0;s<t.length;s++){var l=tt(t[s][0]),u=et(t[s][1]);e.push(l),e.push(u),e.push(0),s>0&&(a+=n?(i*u-l*o)/2:Math.sqrt(Math.pow(l-i,2)+Math.pow(u-o,2))),i=l,o=u}var c=e.length-3;e[2]=1,function t(e,r,n,i){for(var o,a=i,s=n-r>>1,l=n-r,u=e[r],c=e[r+1],p=e[n],h=e[n+1],f=r+3;f<n;f+=3){var d=W(e[f],e[f+1],u,c,p,h);if(d>a)o=f,a=d;else if(d===a){var m=Math.abs(f-s);m<l&&(o=f,l=m)}}a>i&&(o-r>3&&t(e,r,o,i),e[o+2]=a,n-o>3&&t(e,o,n,i))}(e,0,c,r),e[c+2]=1,e.size=Math.abs(a),e.start=0,e.end=e.size}function $(t,e,r,n){for(var i=0;i<t.length;i++){var o=[];Q(t[i],o,r,n),e.push(o)}}function tt(t){return t/360+.5}function et(t){var e=Math.sin(t*Math.PI/180),r=.5-.25*Math.log((1+e)/(1-e))/Math.PI;return r<0?0:r>1?1:r}function rt(t,e,r,n,i,o,a,s){if(n/=e,o>=(r/=e)&&a<n)return t;if(a<r||o>=n)return null;for(var l=[],u=0;u<t.length;u++){var c=t[u],p=c.geometry,h=c.type,f=0===i?c.minX:c.minY,d=0===i?c.maxX:c.maxY;if(f>=r&&d<n)l.push(c);else if(!(d<r||f>=n)){var m=[];if("Point"===h||"MultiPoint"===h)nt(p,m,r,n,i);else if("LineString"===h)it(p,m,r,n,i,!1,s.lineMetrics);else if("MultiLineString"===h)at(p,m,r,n,i,!1);else if("Polygon"===h)at(p,m,r,n,i,!0);else if("MultiPolygon"===h)for(var g=0;g<p.length;g++){var y=[];at(p[g],y,r,n,i,!0),y.length&&m.push(y)}if(m.length){if(s.lineMetrics&&"LineString"===h){for(g=0;g<m.length;g++)l.push(Y(c.id,h,m[g],c.tags));continue}"LineString"!==h&&"MultiLineString"!==h||(1===m.length?(h="LineString",m=m[0]):h="MultiLineString"),"Point"!==h&&"MultiPoint"!==h||(h=3===m.length?"Point":"MultiPoint"),l.push(Y(c.id,h,m,c.tags))}}}return l.length?l:null}function nt(t,e,r,n,i){for(var o=0;o<t.length;o+=3){var a=t[o+i];a>=r&&a<=n&&(e.push(t[o]),e.push(t[o+1]),e.push(t[o+2]))}}function it(t,e,r,n,i,o,a){for(var s,l,u=ot(t),c=0===i?lt:ut,p=t.start,h=0;h<t.length-3;h+=3){var f=t[h],d=t[h+1],m=t[h+2],g=t[h+3],y=t[h+4],v=0===i?f:d,_=0===i?g:y,b=!1;a&&(s=Math.sqrt(Math.pow(f-g,2)+Math.pow(d-y,2))),v<r?_>r&&(l=c(u,f,d,g,y,r),a&&(u.start=p+s*l)):v>n?_<n&&(l=c(u,f,d,g,y,n),a&&(u.start=p+s*l)):st(u,f,d,m),_<r&&v>=r&&(l=c(u,f,d,g,y,r),b=!0),_>n&&v<=n&&(l=c(u,f,d,g,y,n),b=!0),!o&&b&&(a&&(u.end=p+s*l),e.push(u),u=ot(t)),a&&(p+=s)}var x=t.length-3;f=t[x],d=t[x+1],m=t[x+2],(v=0===i?f:d)>=r&&v<=n&&st(u,f,d,m),x=u.length-3,o&&x>=3&&(u[x]!==u[0]||u[x+1]!==u[1])&&st(u,u[0],u[1],u[2]),u.length&&e.push(u)}function ot(t){var e=[];return e.size=t.size,e.start=t.start,e.end=t.end,e}function at(t,e,r,n,i,o){for(var a=0;a<t.length;a++)it(t[a],e,r,n,i,o,!1)}function st(t,e,r,n){t.push(e),t.push(r),t.push(n)}function lt(t,e,r,n,i,o){var a=(o-e)/(n-e);return t.push(o),t.push(r+(i-r)*a),t.push(1),a}function ut(t,e,r,n,i,o){var a=(o-r)/(i-r);return t.push(e+(n-e)*a),t.push(o),t.push(1),a}function ct(t,e){for(var r=[],n=0;n<t.length;n++){var i,o=t[n],a=o.type;if("Point"===a||"MultiPoint"===a||"LineString"===a)i=pt(o.geometry,e);else if("MultiLineString"===a||"Polygon"===a){i=[];for(var s=0;s<o.geometry.length;s++)i.push(pt(o.geometry[s],e))}else if("MultiPolygon"===a)for(i=[],s=0;s<o.geometry.length;s++){for(var l=[],u=0;u<o.geometry[s].length;u++)l.push(pt(o.geometry[s][u],e));i.push(l)}r.push(Y(o.id,a,i,o.tags))}return r}function pt(t,e){var r=[];r.size=t.size,void 0!==t.start&&(r.start=t.start,r.end=t.end);for(var n=0;n<t.length;n+=3)r.push(t[n]+e,t[n+1],t[n+2]);return r}function ht(t,e){if(t.transformed)return t;var r,n,i,o=1<<t.z,a=t.x,s=t.y;for(r=0;r<t.features.length;r++){var l=t.features[r],u=l.geometry,c=l.type;if(l.geometry=[],1===c)for(n=0;n<u.length;n+=2)l.geometry.push(ft(u[n],u[n+1],e,o,a,s));else for(n=0;n<u.length;n++){var p=[];for(i=0;i<u[n].length;i+=2)p.push(ft(u[n][i],u[n][i+1],e,o,a,s));l.geometry.push(p)}}return t.transformed=!0,t}function ft(t,e,r,n,i,o){return[Math.round(r*(t*n-i)),Math.round(r*(e*n-o))]}function dt(t,e,r,n,i){for(var o=e===i.maxZoom?0:i.tolerance/((1<<e)*i.extent),a={features:[],numPoints:0,numSimplified:0,numFeatures:0,source:null,x:r,y:n,z:e,transformed:!1,minX:2,minY:1,maxX:-1,maxY:0},s=0;s<t.length;s++){a.numFeatures++,mt(a,t[s],o,i);var l=t[s].minX,u=t[s].minY,c=t[s].maxX,p=t[s].maxY;l<a.minX&&(a.minX=l),u<a.minY&&(a.minY=u),c>a.maxX&&(a.maxX=c),p>a.maxY&&(a.maxY=p)}return a}function mt(t,e,r,n){var i=e.geometry,o=e.type,a=[];if("Point"===o||"MultiPoint"===o)for(var s=0;s<i.length;s+=3)a.push(i[s]),a.push(i[s+1]),t.numPoints++,t.numSimplified++;else if("LineString"===o)gt(a,i,t,r,!1,!1);else if("MultiLineString"===o||"Polygon"===o)for(s=0;s<i.length;s++)gt(a,i[s],t,r,"Polygon"===o,0===s);else if("MultiPolygon"===o)for(var l=0;l<i.length;l++){var u=i[l];for(s=0;s<u.length;s++)gt(a,u[s],t,r,!0,0===s)}if(a.length){var c=e.tags||null;if("LineString"===o&&n.lineMetrics){for(var p in c={},e.tags)c[p]=e.tags[p];c.mapbox_clip_start=i.start/i.size,c.mapbox_clip_end=i.end/i.size}var h={geometry:a,type:"Polygon"===o||"MultiPolygon"===o?3:"LineString"===o||"MultiLineString"===o?2:1,tags:c};null!==e.id&&(h.id=e.id),t.features.push(h)}}function gt(t,e,r,n,i,o){var a=n*n;if(n>0&&e.size<(i?a:n))r.numPoints+=e.length/3;else{for(var s=[],l=0;l<e.length;l+=3)(0===n||e[l+2]>a)&&(r.numSimplified++,s.push(e[l]),s.push(e[l+1])),r.numPoints++;i&&function(t,e){for(var r=0,n=0,i=t.length,o=i-2;n<i;o=n,n+=2)r+=(t[n]-t[o])*(t[n+1]+t[o+1]);if(r>0===e)for(n=0,i=t.length;n<i/2;n+=2){var a=t[n],s=t[n+1];t[n]=t[i-2-n],t[n+1]=t[i-1-n],t[i-2-n]=a,t[i-1-n]=s}}(s,o),t.push(s)}}function yt(t,e){var r=(e=this.options=function(t,e){for(var r in e)t[r]=e[r];return t}(Object.create(this.options),e)).debug;if(r&&console.time("preprocess data"),e.maxZoom<0||e.maxZoom>24)throw new Error("maxZoom should be in the 0-24 range");if(e.promoteId&&e.generateId)throw new Error("promoteId and generateId cannot be used together.");var n=function(t,e){var r=[];if("FeatureCollection"===t.type)for(var n=0;n<t.features.length;n++)K(r,t.features[n],e,n);else K(r,"Feature"===t.type?t:{geometry:t},e);return r}(t,e);this.tiles={},this.tileCoords=[],r&&(console.timeEnd("preprocess data"),console.log("index: maxZoom: %d, maxPoints: %d",e.indexMaxZoom,e.indexMaxPoints),console.time("generate tiles"),this.stats={},this.total=0),(n=function(t,e){var r=e.buffer/e.extent,n=t,i=rt(t,1,-1-r,r,0,-1,2,e),o=rt(t,1,1-r,2+r,0,-1,2,e);return(i||o)&&(n=rt(t,1,-r,1+r,0,-1,2,e)||[],i&&(n=ct(i,1).concat(n)),o&&(n=n.concat(ct(o,-1)))),n}(n,e)).length&&this.splitTile(n,0,0,0),r&&(n.length&&console.log("features: %d, points: %d",this.tiles[0].numFeatures,this.tiles[0].numPoints),console.timeEnd("generate tiles"),console.log("tiles generated:",this.total,JSON.stringify(this.stats)))}function vt(t,e,r){return 32*((1<<t)*r+e)+t}function _t(t,e){var r=t.tileID.canonical;if(!this._geoJSONIndex)return e(null,null);var n=this._geoJSONIndex.getTile(r.z,r.x,r.y);if(!n)return e(null,null);var i=new m(n.features),o=b(i);0===o.byteOffset&&o.byteLength===o.buffer.byteLength||(o=new Uint8Array(o)),e(null,{vectorTile:i,rawData:o.buffer})}R.prototype.load=function(t){var e=this.options,r=e.log,n=e.minZoom,i=e.maxZoom,o=e.nodeSize;r&&console.time("total time");var a="prepare "+t.length+" points";r&&console.time(a),this.points=t;for(var s=[],l=0;l<t.length;l++)t[l].geometry&&s.push(N(t[l],l));this.trees[i+1]=new F(s,G,Z,o,Float32Array),r&&console.timeEnd(a);for(var u=i;u>=n;u--){var c=+Date.now();s=this._cluster(s,u),this.trees[u]=new F(s,G,Z,o,Float32Array),r&&console.log("z%d: %d clusters in %dms",u,s.length,+Date.now()-c)}return r&&console.timeEnd("total time"),this},R.prototype.getClusters=function(t,e){var r=((t[0]+180)%360+360)%360-180,n=Math.max(-90,Math.min(90,t[1])),i=180===t[2]?180:((t[2]+180)%360+360)%360-180,o=Math.max(-90,Math.min(90,t[3]));if(t[2]-t[0]>=360)r=-180,i=180;else if(r>i){var a=this.getClusters([r,n,180,o],e),s=this.getClusters([-180,n,i,o],e);return a.concat(s)}for(var l=this.trees[this._limitZoom(e)],u=[],c=0,p=l.range(V(r),q(o),V(i),q(n));c<p.length;c+=1){var h=l.points[p[c]];u.push(h.numPoints?j(h):this.points[h.index])}return u},R.prototype.getChildren=function(t){var e=this._getOriginId(t),r=this._getOriginZoom(t),n="No cluster with the specified id.",i=this.trees[r];if(!i)throw new Error(n);var o=i.points[e];if(!o)throw new Error(n);for(var a=this.options.radius/(this.options.extent*Math.pow(2,r-1)),s=[],l=0,u=i.within(o.x,o.y,a);l<u.length;l+=1){var c=i.points[u[l]];c.parentId===t&&s.push(c.numPoints?j(c):this.points[c.index])}if(0===s.length)throw new Error(n);return s},R.prototype.getLeaves=function(t,e,r){var n=[];return this._appendLeaves(n,t,e=e||10,r=r||0,0),n},R.prototype.getTile=function(t,e,r){var n=this.trees[this._limitZoom(t)],i=Math.pow(2,t),o=this.options,a=o.radius/o.extent,s=(r-a)/i,l=(r+1+a)/i,u={features:[]};return this._addTileFeatures(n.range((e-a)/i,s,(e+1+a)/i,l),n.points,e,r,i,u),0===e&&this._addTileFeatures(n.range(1-a/i,s,1,l),n.points,i,r,i,u),e===i-1&&this._addTileFeatures(n.range(0,s,a/i,l),n.points,-1,r,i,u),u.features.length?u:null},R.prototype.getClusterExpansionZoom=function(t){for(var e=this._getOriginZoom(t)-1;e<=this.options.maxZoom;){var r=this.getChildren(t);if(e++,1!==r.length)break;t=r[0].properties.cluster_id}return e},R.prototype._appendLeaves=function(t,e,r,n,i){for(var o=0,a=this.getChildren(e);o<a.length;o+=1){var s=a[o],l=s.properties;if(l&&l.cluster?i+l.point_count<=n?i+=l.point_count:i=this._appendLeaves(t,l.cluster_id,r,n,i):i<n?i++:t.push(s),t.length===r)break}return i},R.prototype._addTileFeatures=function(t,e,r,n,i,o){for(var a=0,s=t;a<s.length;a+=1){var l=e[s[a]],u=l.numPoints,c={type:1,geometry:[[Math.round(this.options.extent*(l.x*i-r)),Math.round(this.options.extent*(l.y*i-n))]],tags:u?U(l):this.points[l.index].properties},p=void 0;u?p=l.id:this.options.generateId?p=l.index:this.points[l.index].id&&(p=this.points[l.index].id),void 0!==p&&(c.id=p),o.features.push(c)}},R.prototype._limitZoom=function(t){return Math.max(this.options.minZoom,Math.min(+t,this.options.maxZoom+1))},R.prototype._cluster=function(t,e){for(var r=[],n=this.options,i=n.reduce,o=n.minPoints,a=n.radius/(n.extent*Math.pow(2,e)),s=0;s<t.length;s++){var l=t[s];if(!(l.zoom<=e)){l.zoom=e;for(var u=this.trees[e+1],c=u.within(l.x,l.y,a),p=l.numPoints||1,h=p,f=0,d=c;f<d.length;f+=1){var m=u.points[d[f]];m.zoom>e&&(h+=m.numPoints||1)}if(h>=o){for(var g=l.x*p,y=l.y*p,v=i&&p>1?this._map(l,!0):null,_=(s<<5)+(e+1)+this.points.length,b=0,x=c;b<x.length;b+=1){var w=u.points[x[b]];if(!(w.zoom<=e)){w.zoom=e;var E=w.numPoints||1;g+=w.x*E,y+=w.y*E,w.parentId=_,i&&(v||(v=this._map(l,!0)),i(v,this._map(w)))}}l.parentId=_,r.push(z(g/h,y/h,_,h,v))}else if(r.push(l),h>1)for(var T=0,A=c;T<A.length;T+=1){var C=u.points[A[T]];C.zoom<=e||(C.zoom=e,r.push(C))}}}return r},R.prototype._getOriginId=function(t){return t-this.points.length>>5},R.prototype._getOriginZoom=function(t){return(t-this.points.length)%32},R.prototype._map=function(t,e){if(t.numPoints)return e?H({},t.properties):t.properties;var r=this.points[t.index].properties,n=this.options.map(r);return e&&n===r?H({},n):n},yt.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},yt.prototype.splitTile=function(t,e,r,n,i,o,a){for(var s=[t,e,r,n],l=this.options,u=l.debug;s.length;){n=s.pop(),r=s.pop(),e=s.pop(),t=s.pop();var c=1<<e,p=vt(e,r,n),h=this.tiles[p];if(!h&&(u>1&&console.time("creation"),h=this.tiles[p]=dt(t,e,r,n,l),this.tileCoords.push({z:e,x:r,y:n}),u)){u>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",e,r,n,h.numFeatures,h.numPoints,h.numSimplified),console.timeEnd("creation"));var f="z"+e;this.stats[f]=(this.stats[f]||0)+1,this.total++}if(h.source=t,i){if(e===l.maxZoom||e===i)continue;var d=1<<i-e;if(r!==Math.floor(o/d)||n!==Math.floor(a/d))continue}else if(e===l.indexMaxZoom||h.numPoints<=l.indexMaxPoints)continue;if(h.source=null,0!==t.length){u>1&&console.time("clipping");var m,g,y,v,_,b,x=.5*l.buffer/l.extent,w=.5-x,E=.5+x,T=1+x;m=g=y=v=null,_=rt(t,c,r-x,r+E,0,h.minX,h.maxX,l),b=rt(t,c,r+w,r+T,0,h.minX,h.maxX,l),t=null,_&&(m=rt(_,c,n-x,n+E,1,h.minY,h.maxY,l),g=rt(_,c,n+w,n+T,1,h.minY,h.maxY,l),_=null),b&&(y=rt(b,c,n-x,n+E,1,h.minY,h.maxY,l),v=rt(b,c,n+w,n+T,1,h.minY,h.maxY,l),b=null),u>1&&console.timeEnd("clipping"),s.push(m||[],e+1,2*r,2*n),s.push(g||[],e+1,2*r,2*n+1),s.push(y||[],e+1,2*r+1,2*n),s.push(v||[],e+1,2*r+1,2*n+1)}}},yt.prototype.getTile=function(t,e,r){var n=this.options,i=n.extent,o=n.debug;if(t<0||t>24)return null;var a=1<<t,s=vt(t,e=(e%a+a)%a,r);if(this.tiles[s])return ht(this.tiles[s],i);o>1&&console.log("drilling down to z%d-%d-%d",t,e,r);for(var l,u=t,c=e,p=r;!l&&u>0;)u--,c=Math.floor(c/2),p=Math.floor(p/2),l=this.tiles[vt(u,c,p)];return l&&l.source?(o>1&&console.log("found parent tile z%d-%d-%d",u,c,p),o>1&&console.time("drilling down"),this.splitTile(l.source,u,c,p,t,e,r),o>1&&console.timeEnd("drilling down"),this.tiles[s]?ht(this.tiles[s],i):null):null};var bt=function(e){function r(t,r,n,i){e.call(this,t,r,n,_t),i&&(this.loadGeoJSON=i)}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.loadData=function(t,e){this._pendingCallback&&this._pendingCallback(null,{abandoned:!0}),this._pendingCallback=e,this._pendingLoadDataParams=t,this._state&&"Idle"!==this._state?this._state="NeedsLoadData":(this._state="Coalescing",this._loadData())},r.prototype._loadData=function(){var e=this;if(this._pendingCallback&&this._pendingLoadDataParams){var r=this._pendingCallback,n=this._pendingLoadDataParams;delete this._pendingCallback,delete this._pendingLoadDataParams;var i=!!(n&&n.request&&n.request.collectResourceTiming)&&new t.RequestPerformance(n.request);this.loadGeoJSON(n,(function(o,a){if(o||!a)return r(o);if("object"!=typeof a)return r(new Error("Input data given to '"+n.source+"' is not a valid GeoJSON object."));!function t(e,r){var n,i=e&&e.type;if("FeatureCollection"===i)for(n=0;n<e.features.length;n++)t(e.features[n],r);else if("GeometryCollection"===i)for(n=0;n<e.geometries.length;n++)t(e.geometries[n],r);else if("Feature"===i)t(e.geometry,r);else if("Polygon"===i)p(e.coordinates,r);else if("MultiPolygon"===i)for(n=0;n<e.coordinates.length;n++)p(e.coordinates[n],r);return e}(a,!0);try{if(n.filter){var s=t.createExpression(n.filter,{type:"boolean","property-type":"data-driven",overridable:!1,transition:!1});if("error"===s.result)throw new Error(s.value.map((function(t){return t.key+": "+t.message})).join(", "));var l=a.features.filter((function(t){return s.value.evaluate({zoom:0},t)}));a={type:"FeatureCollection",features:l}}e._geoJSONIndex=n.cluster?new R(function(e){var r=e.superclusterOptions,n=e.clusterProperties;if(!n||!r)return r;for(var i={},o={},a={accumulated:null,zoom:0},s={properties:null},l=Object.keys(n),u=0,c=l;u<c.length;u+=1){var p=c[u],h=n[p],f=h[0],d=t.createExpression(h[1]),m=t.createExpression("string"==typeof f?[f,["accumulated"],["get",p]]:f);i[p]=d.value,o[p]=m.value}return r.map=function(t){s.properties=t;for(var e={},r=0,n=l;r<n.length;r+=1){var o=n[r];e[o]=i[o].evaluate(a,s)}return e},r.reduce=function(t,e){s.properties=e;for(var r=0,n=l;r<n.length;r+=1){var i=n[r];a.accumulated=t[i],t[i]=o[i].evaluate(a,s)}},r}(n)).load(a.features):function(t,e){return new yt(t,e)}(a,n.geojsonVtOptions)}catch(o){return r(o)}e.loaded={};var u={};if(i){var c=i.finish();c&&(u.resourceTiming={},u.resourceTiming[n.source]=JSON.parse(JSON.stringify(c)))}r(null,u)}))}},r.prototype.coalesce=function(){"Coalescing"===this._state?this._state="Idle":"NeedsLoadData"===this._state&&(this._state="Coalescing",this._loadData())},r.prototype.reloadTile=function(t,r){var n=this.loaded;return n&&n[t.uid]?e.prototype.reloadTile.call(this,t,r):this.loadTile(t,r)},r.prototype.loadGeoJSON=function(e,r){if(e.request)t.getJSON(e.request,r);else{if("string"!=typeof e.data)return r(new Error("Input data given to '"+e.source+"' is not a valid GeoJSON object."));try{return r(null,JSON.parse(e.data))}catch(t){return r(new Error("Input data given to '"+e.source+"' is not a valid GeoJSON object."))}}},r.prototype.removeSource=function(t,e){this._pendingCallback&&this._pendingCallback(null,{abandoned:!0}),e()},r.prototype.getClusterExpansionZoom=function(t,e){try{e(null,this._geoJSONIndex.getClusterExpansionZoom(t.clusterId))}catch(t){e(t)}},r.prototype.getClusterChildren=function(t,e){try{e(null,this._geoJSONIndex.getChildren(t.clusterId))}catch(t){e(t)}},r.prototype.getClusterLeaves=function(t,e){try{e(null,this._geoJSONIndex.getLeaves(t.clusterId,t.limit,t.offset))}catch(t){e(t)}},r}(l),xt=function(e){var r=this;this.self=e,this.actor=new t.Actor(e,this),this.layerIndexes={},this.availableImages={},this.workerSourceTypes={vector:l,geojson:bt},this.workerSources={},this.demWorkerSources={},this.self.registerWorkerSource=function(t,e){if(r.workerSourceTypes[t])throw new Error('Worker source with name "'+t+'" already registered.');r.workerSourceTypes[t]=e},this.self.registerRTLTextPlugin=function(e){if(t.plugin.isParsed())throw new Error("RTL text plugin already registered.");t.plugin.applyArabicShaping=e.applyArabicShaping,t.plugin.processBidirectionalText=e.processBidirectionalText,t.plugin.processStyledBidirectionalText=e.processStyledBidirectionalText}};return xt.prototype.setReferrer=function(t,e){this.referrer=e},xt.prototype.setImages=function(t,e,r){for(var n in this.availableImages[t]=e,this.workerSources[t]){var i=this.workerSources[t][n];for(var o in i)i[o].availableImages=e}r()},xt.prototype.setLayers=function(t,e,r){this.getLayerIndex(t).replace(e),r()},xt.prototype.updateLayers=function(t,e,r){this.getLayerIndex(t).update(e.layers,e.removedIds),r()},xt.prototype.loadTile=function(t,e,r){this.getWorkerSource(t,e.type,e.source).loadTile(e,r)},xt.prototype.loadDEMTile=function(t,e,r){this.getDEMWorkerSource(t,e.source).loadTile(e,r)},xt.prototype.reloadTile=function(t,e,r){this.getWorkerSource(t,e.type,e.source).reloadTile(e,r)},xt.prototype.abortTile=function(t,e,r){this.getWorkerSource(t,e.type,e.source).abortTile(e,r)},xt.prototype.removeTile=function(t,e,r){this.getWorkerSource(t,e.type,e.source).removeTile(e,r)},xt.prototype.removeDEMTile=function(t,e){this.getDEMWorkerSource(t,e.source).removeTile(e)},xt.prototype.removeSource=function(t,e,r){if(this.workerSources[t]&&this.workerSources[t][e.type]&&this.workerSources[t][e.type][e.source]){var n=this.workerSources[t][e.type][e.source];delete this.workerSources[t][e.type][e.source],void 0!==n.removeSource?n.removeSource(e,r):r()}},xt.prototype.loadWorkerSource=function(t,e,r){try{this.self.importScripts(e.url),r()}catch(t){r(t.toString())}},xt.prototype.syncRTLPluginState=function(e,r,n){try{t.plugin.setState(r);var i=t.plugin.getPluginURL();if(t.plugin.isLoaded()&&!t.plugin.isParsed()&&null!=i){this.self.importScripts(i);var o=t.plugin.isParsed();n(o?void 0:new Error("RTL Text Plugin failed to import scripts from "+i),o)}}catch(t){n(t.toString())}},xt.prototype.getAvailableImages=function(t){var e=this.availableImages[t];return e||(e=[]),e},xt.prototype.getLayerIndex=function(t){var e=this.layerIndexes[t];return e||(e=this.layerIndexes[t]=new n),e},xt.prototype.getWorkerSource=function(t,e,r){var n=this;return this.workerSources[t]||(this.workerSources[t]={}),this.workerSources[t][e]||(this.workerSources[t][e]={}),this.workerSources[t][e][r]||(this.workerSources[t][e][r]=new this.workerSourceTypes[e]({send:function(e,r,i){n.actor.send(e,r,i,t)}},this.getLayerIndex(t),this.getAvailableImages(t))),this.workerSources[t][e][r]},xt.prototype.getDEMWorkerSource=function(t,e){return this.demWorkerSources[t]||(this.demWorkerSources[t]={}),this.demWorkerSources[t][e]||(this.demWorkerSources[t][e]=new c),this.demWorkerSources[t][e]},xt.prototype.enforceCacheSizeLimit=function(e,r){t.enforceCacheSizeLimit(r)},"undefined"!=typeof WorkerGlobalScope&&"undefined"!=typeof self&&self instanceof WorkerGlobalScope&&(self.worker=new xt(self)),xt})),n(0,(function(t){var e=t.createCommonjsModule((function(t){function e(t){return!r(t)}function r(t){return"undefined"==typeof window||"undefined"==typeof document?"not a browser":Array.prototype&&Array.prototype.every&&Array.prototype.filter&&Array.prototype.forEach&&Array.prototype.indexOf&&Array.prototype.lastIndexOf&&Array.prototype.map&&Array.prototype.some&&Array.prototype.reduce&&Array.prototype.reduceRight&&Array.isArray?Function.prototype&&Function.prototype.bind?Object.keys&&Object.create&&Object.getPrototypeOf&&Object.getOwnPropertyNames&&Object.isSealed&&Object.isFrozen&&Object.isExtensible&&Object.getOwnPropertyDescriptor&&Object.defineProperty&&Object.defineProperties&&Object.seal&&Object.freeze&&Object.preventExtensions?"JSON"in window&&"parse"in JSON&&"stringify"in JSON?function(){if(!("Worker"in window&&"Blob"in window&&"URL"in window))return!1;var t,e,r=new Blob([""],{type:"text/javascript"}),n=URL.createObjectURL(r);try{e=new Worker(n),t=!0}catch(e){t=!1}return e&&e.terminate(),URL.revokeObjectURL(n),t}()?"Uint8ClampedArray"in window?ArrayBuffer.isView?function(){var t=document.createElement("canvas");t.width=t.height=1;var e=t.getContext("2d");if(!e)return!1;var r=e.getImageData(0,0,1,1);return r&&r.width===t.width}()?(void 0===n[r=t&&t.failIfMajorPerformanceCaveat]&&(n[r]=function(t){var r=function(t){var r=document.createElement("canvas"),n=Object.create(e.webGLContextAttributes);return n.failIfMajorPerformanceCaveat=t,r.probablySupportsContext?r.probablySupportsContext("webgl",n)||r.probablySupportsContext("experimental-webgl",n):r.supportsContext?r.supportsContext("webgl",n)||r.supportsContext("experimental-webgl",n):r.getContext("webgl",n)||r.getContext("experimental-webgl",n)}(t);if(!r)return!1;var n=r.createShader(r.VERTEX_SHADER);return!(!n||r.isContextLost())&&(r.shaderSource(n,"void main() {}"),r.compileShader(n),!0===r.getShaderParameter(n,r.COMPILE_STATUS))}(r)),n[r]?void 0:"insufficient WebGL support"):"insufficient Canvas/getImageData support":"insufficient ArrayBuffer support":"insufficient Uint8ClampedArray support":"insufficient worker support":"insufficient JSON support":"insufficient Object support":"insufficient Function support":"insufficent Array support";var r}t.exports?t.exports=e:window&&(window.mapboxgl=window.mapboxgl||{},window.mapboxgl.supported=e,window.mapboxgl.notSupportedReason=r);var n={};e.webGLContextAttributes={antialias:!1,alpha:!0,stencil:!0,depth:!0}})),r={create:function(e,r,n){var i=t.window.document.createElement(e);return void 0!==r&&(i.className=r),n&&n.appendChild(i),i},createNS:function(e,r){return t.window.document.createElementNS(e,r)}},n=t.window.document&&t.window.document.documentElement.style;function i(t){if(!n)return t[0];for(var e=0;e<t.length;e++)if(t[e]in n)return t[e];return t[0]}var o,a=i(["userSelect","MozUserSelect","WebkitUserSelect","msUserSelect"]);r.disableDrag=function(){n&&a&&(o=n[a],n[a]="none")},r.enableDrag=function(){n&&a&&(n[a]=o)};var s=i(["transform","WebkitTransform"]);r.setTransform=function(t,e){t.style[s]=e};var l=!1;try{var u=Object.defineProperty({},"passive",{get:function(){l=!0}});t.window.addEventListener("test",u,u),t.window.removeEventListener("test",u,u)}catch(t){l=!1}r.addEventListener=function(t,e,r,n){void 0===n&&(n={}),t.addEventListener(e,r,"passive"in n&&l?n:n.capture)},r.removeEventListener=function(t,e,r,n){void 0===n&&(n={}),t.removeEventListener(e,r,"passive"in n&&l?n:n.capture)};var c=function(e){e.preventDefault(),e.stopPropagation(),t.window.removeEventListener("click",c,!0)};function p(t){var e=t.userImage;return!!(e&&e.render&&e.render())&&(t.data.replace(new Uint8Array(e.data.buffer)),!0)}r.suppressClick=function(){t.window.addEventListener("click",c,!0),t.window.setTimeout((function(){t.window.removeEventListener("click",c,!0)}),0)},r.mousePos=function(e,r){var n=e.getBoundingClientRect();return new t.Point(r.clientX-n.left-e.clientLeft,r.clientY-n.top-e.clientTop)},r.touchPos=function(e,r){for(var n=e.getBoundingClientRect(),i=[],o=0;o<r.length;o++)i.push(new t.Point(r[o].clientX-n.left-e.clientLeft,r[o].clientY-n.top-e.clientTop));return i},r.mouseButton=function(e){return void 0!==t.window.InstallTrigger&&2===e.button&&e.ctrlKey&&t.window.navigator.platform.toUpperCase().indexOf("MAC")>=0?0:e.button},r.remove=function(t){t.parentNode&&t.parentNode.removeChild(t)};var h=function(e){function r(){e.call(this),this.images={},this.updatedImages={},this.callbackDispatchedThisFrame={},this.loaded=!1,this.requestors=[],this.patterns={},this.atlasImage=new t.RGBAImage({width:1,height:1}),this.dirty=!0}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.isLoaded=function(){return this.loaded},r.prototype.setLoaded=function(t){if(this.loaded!==t&&(this.loaded=t,t)){for(var e=0,r=this.requestors;e<r.length;e+=1){var n=r[e];this._notify(n.ids,n.callback)}this.requestors=[]}},r.prototype.getImage=function(t){return this.images[t]},r.prototype.addImage=function(t,e){this._validate(t,e)&&(this.images[t]=e)},r.prototype._validate=function(e,r){var n=!0;return this._validateStretch(r.stretchX,r.data&&r.data.width)||(this.fire(new t.ErrorEvent(new Error('Image "'+e+'" has invalid "stretchX" value'))),n=!1),this._validateStretch(r.stretchY,r.data&&r.data.height)||(this.fire(new t.ErrorEvent(new Error('Image "'+e+'" has invalid "stretchY" value'))),n=!1),this._validateContent(r.content,r)||(this.fire(new t.ErrorEvent(new Error('Image "'+e+'" has invalid "content" value'))),n=!1),n},r.prototype._validateStretch=function(t,e){if(!t)return!0;for(var r=0,n=0,i=t;n<i.length;n+=1){var o=i[n];if(o[0]<r||o[1]<o[0]||e<o[1])return!1;r=o[1]}return!0},r.prototype._validateContent=function(t,e){return!(t&&(4!==t.length||t[0]<0||e.data.width<t[0]||t[1]<0||e.data.height<t[1]||t[2]<0||e.data.width<t[2]||t[3]<0||e.data.height<t[3]||t[2]<t[0]||t[3]<t[1]))},r.prototype.updateImage=function(t,e){e.version=this.images[t].version+1,this.images[t]=e,this.updatedImages[t]=!0},r.prototype.removeImage=function(t){var e=this.images[t];delete this.images[t],delete this.patterns[t],e.userImage&&e.userImage.onRemove&&e.userImage.onRemove()},r.prototype.listImages=function(){return Object.keys(this.images)},r.prototype.getImages=function(t,e){var r=!0;if(!this.isLoaded())for(var n=0,i=t;n<i.length;n+=1)this.images[i[n]]||(r=!1);this.isLoaded()||r?this._notify(t,e):this.requestors.push({ids:t,callback:e})},r.prototype._notify=function(e,r){for(var n={},i=0,o=e;i<o.length;i+=1){var a=o[i];this.images[a]||this.fire(new t.Event("styleimagemissing",{id:a}));var s=this.images[a];s?n[a]={data:s.data.clone(),pixelRatio:s.pixelRatio,sdf:s.sdf,version:s.version,stretchX:s.stretchX,stretchY:s.stretchY,content:s.content,hasRenderCallback:Boolean(s.userImage&&s.userImage.render)}:t.warnOnce('Image "'+a+'" could not be loaded. Please make sure you have added the image with map.addImage() or a "sprite" property in your style. You can provide missing images by listening for the "styleimagemissing" map event.')}r(null,n)},r.prototype.getPixelSize=function(){var t=this.atlasImage;return{width:t.width,height:t.height}},r.prototype.getPattern=function(e){var r=this.patterns[e],n=this.getImage(e);if(!n)return null;if(r&&r.position.version===n.version)return r.position;if(r)r.position.version=n.version;else{var i={w:n.data.width+2,h:n.data.height+2,x:0,y:0},o=new t.ImagePosition(i,n);this.patterns[e]={bin:i,position:o}}return this._updatePatternAtlas(),this.patterns[e].position},r.prototype.bind=function(e){var r=e.gl;this.atlasTexture?this.dirty&&(this.atlasTexture.update(this.atlasImage),this.dirty=!1):this.atlasTexture=new t.Texture(e,this.atlasImage,r.RGBA),this.atlasTexture.bind(r.LINEAR,r.CLAMP_TO_EDGE)},r.prototype._updatePatternAtlas=function(){var e=[];for(var r in this.patterns)e.push(this.patterns[r].bin);var n=t.potpack(e),i=n.w,o=n.h,a=this.atlasImage;for(var s in a.resize({width:i||1,height:o||1}),this.patterns){var l=this.patterns[s].bin,u=l.x+1,c=l.y+1,p=this.images[s].data,h=p.width,f=p.height;t.RGBAImage.copy(p,a,{x:0,y:0},{x:u,y:c},{width:h,height:f}),t.RGBAImage.copy(p,a,{x:0,y:f-1},{x:u,y:c-1},{width:h,height:1}),t.RGBAImage.copy(p,a,{x:0,y:0},{x:u,y:c+f},{width:h,height:1}),t.RGBAImage.copy(p,a,{x:h-1,y:0},{x:u-1,y:c},{width:1,height:f}),t.RGBAImage.copy(p,a,{x:0,y:0},{x:u+h,y:c},{width:1,height:f})}this.dirty=!0},r.prototype.beginFrame=function(){this.callbackDispatchedThisFrame={}},r.prototype.dispatchRenderCallbacks=function(t){for(var e=0,r=t;e<r.length;e+=1){var n=r[e];if(!this.callbackDispatchedThisFrame[n]){this.callbackDispatchedThisFrame[n]=!0;var i=this.images[n];p(i)&&this.updateImage(n,i)}}},r}(t.Evented),f=g,d=g,m=1e20;function g(t,e,r,n,i,o){this.fontSize=t||24,this.buffer=void 0===e?3:e,this.cutoff=n||.25,this.fontFamily=i||"sans-serif",this.fontWeight=o||"normal",this.radius=r||8;var a=this.size=this.fontSize+2*this.buffer;this.canvas=document.createElement("canvas"),this.canvas.width=this.canvas.height=a,this.ctx=this.canvas.getContext("2d"),this.ctx.font=this.fontWeight+" "+this.fontSize+"px "+this.fontFamily,this.ctx.textBaseline="middle",this.ctx.fillStyle="black",this.gridOuter=new Float64Array(a*a),this.gridInner=new Float64Array(a*a),this.f=new Float64Array(a),this.d=new Float64Array(a),this.z=new Float64Array(a+1),this.v=new Int16Array(a),this.middle=Math.round(a/2*(navigator.userAgent.indexOf("Gecko/")>=0?1.2:1))}function y(t,e,r,n,i,o,a){for(var s=0;s<e;s++){for(var l=0;l<r;l++)n[l]=t[l*e+s];for(v(n,i,o,a,r),l=0;l<r;l++)t[l*e+s]=i[l]}for(l=0;l<r;l++){for(s=0;s<e;s++)n[s]=t[l*e+s];for(v(n,i,o,a,e),s=0;s<e;s++)t[l*e+s]=Math.sqrt(i[s])}}function v(t,e,r,n,i){r[0]=0,n[0]=-m,n[1]=+m;for(var o=1,a=0;o<i;o++){for(var s=(t[o]+o*o-(t[r[a]]+r[a]*r[a]))/(2*o-2*r[a]);s<=n[a];)a--,s=(t[o]+o*o-(t[r[a]]+r[a]*r[a]))/(2*o-2*r[a]);r[++a]=o,n[a]=s,n[a+1]=+m}for(o=0,a=0;o<i;o++){for(;n[a+1]<o;)a++;e[o]=(o-r[a])*(o-r[a])+t[r[a]]}}g.prototype.draw=function(t){this.ctx.clearRect(0,0,this.size,this.size),this.ctx.fillText(t,this.buffer,this.middle);for(var e=this.ctx.getImageData(0,0,this.size,this.size),r=new Uint8ClampedArray(this.size*this.size),n=0;n<this.size*this.size;n++){var i=e.data[4*n+3]/255;this.gridOuter[n]=1===i?0:0===i?m:Math.pow(Math.max(0,.5-i),2),this.gridInner[n]=1===i?m:0===i?0:Math.pow(Math.max(0,i-.5),2)}for(y(this.gridOuter,this.size,this.size,this.f,this.d,this.v,this.z),y(this.gridInner,this.size,this.size,this.f,this.d,this.v,this.z),n=0;n<this.size*this.size;n++)r[n]=Math.max(0,Math.min(255,Math.round(255-255*((this.gridOuter[n]-this.gridInner[n])/this.radius+this.cutoff))));return r},f.default=d;var _=function(t,e){this.requestManager=t,this.localIdeographFontFamily=e,this.entries={}};_.prototype.setURL=function(t){this.url=t},_.prototype.getGlyphs=function(e,r){var n=this,i=[];for(var o in e)for(var a=0,s=e[o];a<s.length;a+=1)i.push({stack:o,id:s[a]});t.asyncAll(i,(function(t,e){var r=t.stack,i=t.id,o=n.entries[r];o||(o=n.entries[r]={glyphs:{},requests:{},ranges:{}});var a=o.glyphs[i];if(void 0===a){if(a=n._tinySDF(o,r,i))return o.glyphs[i]=a,void e(null,{stack:r,id:i,glyph:a});var s=Math.floor(i/256);if(256*s>65535)e(new Error("glyphs > 65535 not supported"));else if(o.ranges[s])e(null,{stack:r,id:i,glyph:a});else{var l=o.requests[s];l||(l=o.requests[s]=[],_.loadGlyphRange(r,s,n.url,n.requestManager,(function(t,e){if(e){for(var r in e)n._doesCharSupportLocalGlyph(+r)||(o.glyphs[+r]=e[+r]);o.ranges[s]=!0}for(var i=0,a=l;i<a.length;i+=1)(0,a[i])(t,e);delete o.requests[s]}))),l.push((function(t,n){t?e(t):n&&e(null,{stack:r,id:i,glyph:n[i]||null})}))}}else e(null,{stack:r,id:i,glyph:a})}),(function(t,e){if(t)r(t);else if(e){for(var n={},i=0,o=e;i<o.length;i+=1){var a=o[i],s=a.stack,l=a.id,u=a.glyph;(n[s]||(n[s]={}))[l]=u&&{id:u.id,bitmap:u.bitmap.clone(),metrics:u.metrics}}r(null,n)}}))},_.prototype._doesCharSupportLocalGlyph=function(e){return!!this.localIdeographFontFamily&&(t.isChar["CJK Unified Ideographs"](e)||t.isChar["Hangul Syllables"](e)||t.isChar.Hiragana(e)||t.isChar.Katakana(e))},_.prototype._tinySDF=function(e,r,n){var i=this.localIdeographFontFamily;if(i&&this._doesCharSupportLocalGlyph(n)){var o=e.tinySDF;if(!o){var a="400";/bold/i.test(r)?a="900":/medium/i.test(r)?a="500":/light/i.test(r)&&(a="200"),o=e.tinySDF=new _.TinySDF(24,3,8,.25,i,a)}return{id:n,bitmap:new t.AlphaImage({width:30,height:30},o.draw(String.fromCharCode(n))),metrics:{width:24,height:24,left:0,top:-8,advance:24}}}},_.loadGlyphRange=function(e,r,n,i,o){var a=256*r,s=a+255,l=i.transformRequest(i.normalizeGlyphsURL(n).replace("{fontstack}",e).replace("{range}",a+"-"+s),t.ResourceType.Glyphs);t.getArrayBuffer(l,(function(e,r){if(e)o(e);else if(r){for(var n={},i=0,a=t.parseGlyphPBF(r);i<a.length;i+=1){var s=a[i];n[s.id]=s}o(null,n)}}))},_.TinySDF=f;var b=function(){this.specification=t.styleSpec.light.position};b.prototype.possiblyEvaluate=function(e,r){return t.sphericalToCartesian(e.expression.evaluate(r))},b.prototype.interpolate=function(e,r,n){return{x:t.number(e.x,r.x,n),y:t.number(e.y,r.y,n),z:t.number(e.z,r.z,n)}};var x=new t.Properties({anchor:new t.DataConstantProperty(t.styleSpec.light.anchor),position:new b,color:new t.DataConstantProperty(t.styleSpec.light.color),intensity:new t.DataConstantProperty(t.styleSpec.light.intensity)}),w=function(e){function r(r){e.call(this),this._transitionable=new t.Transitionable(x),this.setLight(r),this._transitioning=this._transitionable.untransitioned()}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.getLight=function(){return this._transitionable.serialize()},r.prototype.setLight=function(e,r){if(void 0===r&&(r={}),!this._validate(t.validateLight,e,r))for(var n in e){var i=e[n];t.endsWith(n,"-transition")?this._transitionable.setTransition(n.slice(0,-"-transition".length),i):this._transitionable.setValue(n,i)}},r.prototype.updateTransitions=function(t){this._transitioning=this._transitionable.transitioned(t,this._transitioning)},r.prototype.hasTransition=function(){return this._transitioning.hasTransition()},r.prototype.recalculate=function(t){this.properties=this._transitioning.possiblyEvaluate(t)},r.prototype._validate=function(e,r,n){return(!n||!1!==n.validate)&&t.emitValidationErrors(this,e.call(t.validateStyle,t.extend({value:r,style:{glyphs:!0,sprite:!0},styleSpec:t.styleSpec})))},r}(t.Evented),E=function(t,e){this.width=t,this.height=e,this.nextRow=0,this.data=new Uint8Array(this.width*this.height),this.dashEntry={}};E.prototype.getDash=function(t,e){var r=t.join(",")+String(e);return this.dashEntry[r]||(this.dashEntry[r]=this.addDash(t,e)),this.dashEntry[r]},E.prototype.getDashRanges=function(t,e,r){var n=[],i=t.length%2==1?-t[t.length-1]*r:0,o=t[0]*r,a=!0;n.push({left:i,right:o,isDash:a,zeroLength:0===t[0]});for(var s=t[0],l=1;l<t.length;l++){var u=t[l];n.push({left:i=s*r,right:o=(s+=u)*r,isDash:a=!a,zeroLength:0===u})}return n},E.prototype.addRoundDash=function(t,e,r){for(var n=e/2,i=-r;i<=r;i++)for(var o=this.width*(this.nextRow+r+i),a=0,s=t[a],l=0;l<this.width;l++){l/s.right>1&&(s=t[++a]);var u=Math.abs(l-s.left),c=Math.abs(l-s.right),p=Math.min(u,c),h=void 0,f=i/r*(n+1);if(s.isDash){var d=n-Math.abs(f);h=Math.sqrt(p*p+d*d)}else h=n-Math.sqrt(p*p+f*f);this.data[o+l]=Math.max(0,Math.min(255,h+128))}},E.prototype.addRegularDash=function(t){for(var e=t.length-1;e>=0;--e){var r=t[e],n=t[e+1];r.zeroLength?t.splice(e,1):n&&n.isDash===r.isDash&&(n.left=r.left,t.splice(e,1))}var i=t[0],o=t[t.length-1];i.isDash===o.isDash&&(i.left=o.left-this.width,o.right=i.right+this.width);for(var a=this.width*this.nextRow,s=0,l=t[s],u=0;u<this.width;u++){u/l.right>1&&(l=t[++s]);var c=Math.abs(u-l.left),p=Math.abs(u-l.right),h=Math.min(c,p);this.data[a+u]=Math.max(0,Math.min(255,(l.isDash?h:-h)+128))}},E.prototype.addDash=function(e,r){var n=r?7:0,i=2*n+1;if(this.nextRow+i>this.height)return t.warnOnce("LineAtlas out of space"),null;for(var o=0,a=0;a<e.length;a++)o+=e[a];if(0!==o){var s=this.width/o,l=this.getDashRanges(e,this.width,s);r?this.addRoundDash(l,s,n):this.addRegularDash(l)}var u={y:(this.nextRow+n+.5)/this.height,height:2*n/this.height,width:o};return this.nextRow+=i,this.dirty=!0,u},E.prototype.bind=function(t){var e=t.gl;this.texture?(e.bindTexture(e.TEXTURE_2D,this.texture),this.dirty&&(this.dirty=!1,e.texSubImage2D(e.TEXTURE_2D,0,0,0,this.width,this.height,e.ALPHA,e.UNSIGNED_BYTE,this.data))):(this.texture=e.createTexture(),e.bindTexture(e.TEXTURE_2D,this.texture),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.REPEAT),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.REPEAT),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.LINEAR),e.texImage2D(e.TEXTURE_2D,0,e.ALPHA,this.width,this.height,0,e.ALPHA,e.UNSIGNED_BYTE,this.data))};var T=function e(r,n){this.workerPool=r,this.actors=[],this.currentActor=0,this.id=t.uniqueId();for(var i=this.workerPool.acquire(this.id),o=0;o<i.length;o++){var a=new e.Actor(i[o],n,this.id);a.name="Worker "+o,this.actors.push(a)}};function A(e,r,n){var i=function(i,o){if(i)return n(i);if(o){var a=t.pick(t.extend(o,e),["tiles","minzoom","maxzoom","attribution","mapbox_logo","bounds","scheme","tileSize","encoding"]);o.vector_layers&&(a.vectorLayers=o.vector_layers,a.vectorLayerIds=a.vectorLayers.map((function(t){return t.id}))),a.tiles=r.canonicalizeTileset(a,e.url),n(null,a)}};return e.url?t.getJSON(r.transformRequest(r.normalizeSourceURL(e.url),t.ResourceType.Source),i):t.browser.frame((function(){return i(null,e)}))}T.prototype.broadcast=function(e,r,n){t.asyncAll(this.actors,(function(t,n){t.send(e,r,n)}),n=n||function(){})},T.prototype.getActor=function(){return this.currentActor=(this.currentActor+1)%this.actors.length,this.actors[this.currentActor]},T.prototype.remove=function(){this.actors.forEach((function(t){t.remove()})),this.actors=[],this.workerPool.release(this.id)},T.Actor=t.Actor;var C=function(e,r,n){this.bounds=t.LngLatBounds.convert(this.validateBounds(e)),this.minzoom=r||0,this.maxzoom=n||24};C.prototype.validateBounds=function(t){return Array.isArray(t)&&4===t.length?[Math.max(-180,t[0]),Math.max(-90,t[1]),Math.min(180,t[2]),Math.min(90,t[3])]:[-180,-90,180,90]},C.prototype.contains=function(e){var r=Math.pow(2,e.z),n=Math.floor(t.mercatorXfromLng(this.bounds.getWest())*r),i=Math.floor(t.mercatorYfromLat(this.bounds.getNorth())*r),o=Math.ceil(t.mercatorXfromLng(this.bounds.getEast())*r),a=Math.ceil(t.mercatorYfromLat(this.bounds.getSouth())*r);return e.x>=n&&e.x<o&&e.y>=i&&e.y<a};var S=function(e){function r(r,n,i,o){if(e.call(this),this.id=r,this.dispatcher=i,this.type="vector",this.minzoom=0,this.maxzoom=22,this.scheme="xyz",this.tileSize=512,this.reparseOverscaled=!0,this.isTileClipped=!0,this._loaded=!1,t.extend(this,t.pick(n,["url","scheme","tileSize","promoteId"])),this._options=t.extend({type:"vector"},n),this._collectResourceTiming=n.collectResourceTiming,512!==this.tileSize)throw new Error("vector tile sources must have a tileSize of 512");this.setEventedParent(o)}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.load=function(){var e=this;this._loaded=!1,this.fire(new t.Event("dataloading",{dataType:"source"})),this._tileJSONRequest=A(this._options,this.map._requestManager,(function(r,n){e._tileJSONRequest=null,e._loaded=!0,r?e.fire(new t.ErrorEvent(r)):n&&(t.extend(e,n),n.bounds&&(e.tileBounds=new C(n.bounds,e.minzoom,e.maxzoom)),t.postTurnstileEvent(n.tiles,e.map._requestManager._customAccessToken),t.postMapLoadEvent(n.tiles,e.map._getMapId(),e.map._requestManager._skuToken,e.map._requestManager._customAccessToken),e.fire(new t.Event("data",{dataType:"source",sourceDataType:"metadata"})),e.fire(new t.Event("data",{dataType:"source",sourceDataType:"content"})))}))},r.prototype.loaded=function(){return this._loaded},r.prototype.hasTile=function(t){return!this.tileBounds||this.tileBounds.contains(t.canonical)},r.prototype.onAdd=function(t){this.map=t,this.load()},r.prototype.setSourceProperty=function(t){this._tileJSONRequest&&this._tileJSONRequest.cancel(),t(),this.map.style.sourceCaches[this.id].clearTiles(),this.load()},r.prototype.setTiles=function(t){var e=this;return this.setSourceProperty((function(){e._options.tiles=t})),this},r.prototype.setUrl=function(t){var e=this;return this.setSourceProperty((function(){e.url=t,e._options.url=t})),this},r.prototype.onRemove=function(){this._tileJSONRequest&&(this._tileJSONRequest.cancel(),this._tileJSONRequest=null)},r.prototype.serialize=function(){return t.extend({},this._options)},r.prototype.loadTile=function(e,r){var n=this.map._requestManager.normalizeTileURL(e.tileID.canonical.url(this.tiles,this.scheme)),i={request:this.map._requestManager.transformRequest(n,t.ResourceType.Tile),uid:e.uid,tileID:e.tileID,zoom:e.tileID.overscaledZ,tileSize:this.tileSize*e.tileID.overscaleFactor(),type:this.type,source:this.id,pixelRatio:t.browser.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId};function o(n,i){return delete e.request,e.aborted?r(null):n&&404!==n.status?r(n):(i&&i.resourceTiming&&(e.resourceTiming=i.resourceTiming),this.map._refreshExpiredTiles&&i&&e.setExpiryData(i),e.loadVectorData(i,this.map.painter),t.cacheEntryPossiblyAdded(this.dispatcher),r(null),void(e.reloadCallback&&(this.loadTile(e,e.reloadCallback),e.reloadCallback=null)))}i.request.collectResourceTiming=this._collectResourceTiming,e.actor&&"expired"!==e.state?"loading"===e.state?e.reloadCallback=r:e.request=e.actor.send("reloadTile",i,o.bind(this)):(e.actor=this.dispatcher.getActor(),e.request=e.actor.send("loadTile",i,o.bind(this)))},r.prototype.abortTile=function(t){t.request&&(t.request.cancel(),delete t.request),t.actor&&t.actor.send("abortTile",{uid:t.uid,type:this.type,source:this.id},void 0)},r.prototype.unloadTile=function(t){t.unloadVectorData(),t.actor&&t.actor.send("removeTile",{uid:t.uid,type:this.type,source:this.id},void 0)},r.prototype.hasTransition=function(){return!1},r}(t.Evented),P=function(e){function r(r,n,i,o){e.call(this),this.id=r,this.dispatcher=i,this.setEventedParent(o),this.type="raster",this.minzoom=0,this.maxzoom=22,this.roundZoom=!0,this.scheme="xyz",this.tileSize=512,this._loaded=!1,this._options=t.extend({type:"raster"},n),t.extend(this,t.pick(n,["url","scheme","tileSize"]))}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.load=function(){var e=this;this._loaded=!1,this.fire(new t.Event("dataloading",{dataType:"source"})),this._tileJSONRequest=A(this._options,this.map._requestManager,(function(r,n){e._tileJSONRequest=null,e._loaded=!0,r?e.fire(new t.ErrorEvent(r)):n&&(t.extend(e,n),n.bounds&&(e.tileBounds=new C(n.bounds,e.minzoom,e.maxzoom)),t.postTurnstileEvent(n.tiles),t.postMapLoadEvent(n.tiles,e.map._getMapId(),e.map._requestManager._skuToken),e.fire(new t.Event("data",{dataType:"source",sourceDataType:"metadata"})),e.fire(new t.Event("data",{dataType:"source",sourceDataType:"content"})))}))},r.prototype.loaded=function(){return this._loaded},r.prototype.onAdd=function(t){this.map=t,this.load()},r.prototype.onRemove=function(){this._tileJSONRequest&&(this._tileJSONRequest.cancel(),this._tileJSONRequest=null)},r.prototype.serialize=function(){return t.extend({},this._options)},r.prototype.hasTile=function(t){return!this.tileBounds||this.tileBounds.contains(t.canonical)},r.prototype.loadTile=function(e,r){var n=this,i=this.map._requestManager.normalizeTileURL(e.tileID.canonical.url(this.tiles,this.scheme),this.tileSize);e.request=t.getImage(this.map._requestManager.transformRequest(i,t.ResourceType.Tile),(function(i,o){if(delete e.request,e.aborted)e.state="unloaded",r(null);else if(i)e.state="errored",r(i);else if(o){n.map._refreshExpiredTiles&&e.setExpiryData(o),delete o.cacheControl,delete o.expires;var a=n.map.painter.context,s=a.gl;e.texture=n.map.painter.getTileTexture(o.width),e.texture?e.texture.update(o,{useMipmap:!0}):(e.texture=new t.Texture(a,o,s.RGBA,{useMipmap:!0}),e.texture.bind(s.LINEAR,s.CLAMP_TO_EDGE,s.LINEAR_MIPMAP_NEAREST),a.extTextureFilterAnisotropic&&s.texParameterf(s.TEXTURE_2D,a.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,a.extTextureFilterAnisotropicMax)),e.state="loaded",t.cacheEntryPossiblyAdded(n.dispatcher),r(null)}}))},r.prototype.abortTile=function(t,e){t.request&&(t.request.cancel(),delete t.request),e()},r.prototype.unloadTile=function(t,e){t.texture&&this.map.painter.saveTileTexture(t.texture),e()},r.prototype.hasTransition=function(){return!1},r}(t.Evented),I=function(e){function r(r,n,i,o){e.call(this,r,n,i,o),this.type="raster-dem",this.maxzoom=22,this._options=t.extend({type:"raster-dem"},n),this.encoding=n.encoding||"mapbox"}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.serialize=function(){return{type:"raster-dem",url:this.url,tileSize:this.tileSize,tiles:this.tiles,bounds:this.bounds,encoding:this.encoding}},r.prototype.loadTile=function(e,r){var n=this.map._requestManager.normalizeTileURL(e.tileID.canonical.url(this.tiles,this.scheme),this.tileSize);function i(t,n){t&&(e.state="errored",r(t)),n&&(e.dem=n,e.needsHillshadePrepare=!0,e.state="loaded",r(null))}e.request=t.getImage(this.map._requestManager.transformRequest(n,t.ResourceType.Tile),function(n,o){if(delete e.request,e.aborted)e.state="unloaded",r(null);else if(n)e.state="errored",r(n);else if(o){this.map._refreshExpiredTiles&&e.setExpiryData(o),delete o.cacheControl,delete o.expires;var a=t.window.ImageBitmap&&o instanceof t.window.ImageBitmap&&t.offscreenCanvasSupported()?o:t.browser.getImageData(o,1),s={uid:e.uid,coord:e.tileID,source:this.id,rawImageData:a,encoding:this.encoding};e.actor&&"expired"!==e.state||(e.actor=this.dispatcher.getActor(),e.actor.send("loadDEMTile",s,i.bind(this)))}}.bind(this)),e.neighboringTiles=this._getNeighboringTiles(e.tileID)},r.prototype._getNeighboringTiles=function(e){var r=e.canonical,n=Math.pow(2,r.z),i=(r.x-1+n)%n,o=0===r.x?e.wrap-1:e.wrap,a=(r.x+1+n)%n,s=r.x+1===n?e.wrap+1:e.wrap,l={};return l[new t.OverscaledTileID(e.overscaledZ,o,r.z,i,r.y).key]={backfilled:!1},l[new t.OverscaledTileID(e.overscaledZ,s,r.z,a,r.y).key]={backfilled:!1},r.y>0&&(l[new t.OverscaledTileID(e.overscaledZ,o,r.z,i,r.y-1).key]={backfilled:!1},l[new t.OverscaledTileID(e.overscaledZ,e.wrap,r.z,r.x,r.y-1).key]={backfilled:!1},l[new t.OverscaledTileID(e.overscaledZ,s,r.z,a,r.y-1).key]={backfilled:!1}),r.y+1<n&&(l[new t.OverscaledTileID(e.overscaledZ,o,r.z,i,r.y+1).key]={backfilled:!1},l[new t.OverscaledTileID(e.overscaledZ,e.wrap,r.z,r.x,r.y+1).key]={backfilled:!1},l[new t.OverscaledTileID(e.overscaledZ,s,r.z,a,r.y+1).key]={backfilled:!1}),l},r.prototype.unloadTile=function(t){t.demTexture&&this.map.painter.saveTileTexture(t.demTexture),t.fbo&&(t.fbo.destroy(),delete t.fbo),t.dem&&delete t.dem,delete t.neighboringTiles,t.state="unloaded",t.actor&&t.actor.send("removeDEMTile",{uid:t.uid,source:this.id})},r}(P),D=function(e){function r(r,n,i,o){e.call(this),this.id=r,this.type="geojson",this.minzoom=0,this.maxzoom=18,this.tileSize=512,this.isTileClipped=!0,this.reparseOverscaled=!0,this._removed=!1,this._loaded=!1,this.actor=i.getActor(),this.setEventedParent(o),this._data=n.data,this._options=t.extend({},n),this._collectResourceTiming=n.collectResourceTiming,this._resourceTiming=[],void 0!==n.maxzoom&&(this.maxzoom=n.maxzoom),n.type&&(this.type=n.type),n.attribution&&(this.attribution=n.attribution),this.promoteId=n.promoteId;var a=t.EXTENT/this.tileSize;this.workerOptions=t.extend({source:this.id,cluster:n.cluster||!1,geojsonVtOptions:{buffer:(void 0!==n.buffer?n.buffer:128)*a,tolerance:(void 0!==n.tolerance?n.tolerance:.375)*a,extent:t.EXTENT,maxZoom:this.maxzoom,lineMetrics:n.lineMetrics||!1,generateId:n.generateId||!1},superclusterOptions:{maxZoom:void 0!==n.clusterMaxZoom?Math.min(n.clusterMaxZoom,this.maxzoom-1):this.maxzoom-1,minPoints:Math.max(2,n.clusterMinPoints||2),extent:t.EXTENT,radius:(n.clusterRadius||50)*a,log:!1,generateId:n.generateId||!1},clusterProperties:n.clusterProperties,filter:n.filter},n.workerOptions)}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.load=function(){var e=this;this.fire(new t.Event("dataloading",{dataType:"source"})),this._updateWorkerData((function(r){if(r)e.fire(new t.ErrorEvent(r));else{var n={dataType:"source",sourceDataType:"metadata"};e._collectResourceTiming&&e._resourceTiming&&e._resourceTiming.length>0&&(n.resourceTiming=e._resourceTiming,e._resourceTiming=[]),e.fire(new t.Event("data",n))}}))},r.prototype.onAdd=function(t){this.map=t,this.load()},r.prototype.setData=function(e){var r=this;return this._data=e,this.fire(new t.Event("dataloading",{dataType:"source"})),this._updateWorkerData((function(e){if(e)r.fire(new t.ErrorEvent(e));else{var n={dataType:"source",sourceDataType:"content"};r._collectResourceTiming&&r._resourceTiming&&r._resourceTiming.length>0&&(n.resourceTiming=r._resourceTiming,r._resourceTiming=[]),r.fire(new t.Event("data",n))}})),this},r.prototype.getClusterExpansionZoom=function(t,e){return this.actor.send("geojson.getClusterExpansionZoom",{clusterId:t,source:this.id},e),this},r.prototype.getClusterChildren=function(t,e){return this.actor.send("geojson.getClusterChildren",{clusterId:t,source:this.id},e),this},r.prototype.getClusterLeaves=function(t,e,r,n){return this.actor.send("geojson.getClusterLeaves",{source:this.id,clusterId:t,limit:e,offset:r},n),this},r.prototype._updateWorkerData=function(e){var r=this;this._loaded=!1;var n=t.extend({},this.workerOptions),i=this._data;"string"==typeof i?(n.request=this.map._requestManager.transformRequest(t.browser.resolveURL(i),t.ResourceType.Source),n.request.collectResourceTiming=this._collectResourceTiming):n.data=JSON.stringify(i),this.actor.send(this.type+".loadData",n,(function(t,i){r._removed||i&&i.abandoned||(r._loaded=!0,i&&i.resourceTiming&&i.resourceTiming[r.id]&&(r._resourceTiming=i.resourceTiming[r.id].slice(0)),r.actor.send(r.type+".coalesce",{source:n.source},null),e(t))}))},r.prototype.loaded=function(){return this._loaded},r.prototype.loadTile=function(e,r){var n=this,i=e.actor?"reloadTile":"loadTile";e.actor=this.actor,e.request=this.actor.send(i,{type:this.type,uid:e.uid,tileID:e.tileID,zoom:e.tileID.overscaledZ,maxZoom:this.maxzoom,tileSize:this.tileSize,source:this.id,pixelRatio:t.browser.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId},(function(t,o){return delete e.request,e.unloadVectorData(),e.aborted?r(null):t?r(t):(e.loadVectorData(o,n.map.painter,"reloadTile"===i),r(null))}))},r.prototype.abortTile=function(t){t.request&&(t.request.cancel(),delete t.request),t.aborted=!0},r.prototype.unloadTile=function(t){t.unloadVectorData(),this.actor.send("removeTile",{uid:t.uid,type:this.type,source:this.id})},r.prototype.onRemove=function(){this._removed=!0,this.actor.send("removeSource",{type:this.type,source:this.id})},r.prototype.serialize=function(){return t.extend({},this._options,{type:this.type,data:this._data})},r.prototype.hasTransition=function(){return!1},r}(t.Evented),O=t.createLayout([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]),M=function(e){function r(t,r,n,i){e.call(this),this.id=t,this.dispatcher=n,this.coordinates=r.coordinates,this.type="image",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.tiles={},this._loaded=!1,this.setEventedParent(i),this.options=r}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.load=function(e,r){var n=this;this._loaded=!1,this.fire(new t.Event("dataloading",{dataType:"source"})),this.url=this.options.url,t.getImage(this.map._requestManager.transformRequest(this.url,t.ResourceType.Image),(function(i,o){n._loaded=!0,i?n.fire(new t.ErrorEvent(i)):o&&(n.image=o,e&&(n.coordinates=e),r&&r(),n._finishLoading())}))},r.prototype.loaded=function(){return this._loaded},r.prototype.updateImage=function(t){var e=this;return this.image&&t.url?(this.options.url=t.url,this.load(t.coordinates,(function(){e.texture=null})),this):this},r.prototype._finishLoading=function(){this.map&&(this.setCoordinates(this.coordinates),this.fire(new t.Event("data",{dataType:"source",sourceDataType:"metadata"})))},r.prototype.onAdd=function(t){this.map=t,this.load()},r.prototype.setCoordinates=function(e){var r=this;this.coordinates=e;var n=e.map(t.MercatorCoordinate.fromLngLat);this.tileID=function(e){for(var r=1/0,n=1/0,i=-1/0,o=-1/0,a=0,s=e;a<s.length;a+=1){var l=s[a];r=Math.min(r,l.x),n=Math.min(n,l.y),i=Math.max(i,l.x),o=Math.max(o,l.y)}var u=Math.max(i-r,o-n),c=Math.max(0,Math.floor(-Math.log(u)/Math.LN2)),p=Math.pow(2,c);return new t.CanonicalTileID(c,Math.floor((r+i)/2*p),Math.floor((n+o)/2*p))}(n),this.minzoom=this.maxzoom=this.tileID.z;var i=n.map((function(t){return r.tileID.getTilePoint(t)._round()}));return this._boundsArray=new t.StructArrayLayout4i8,this._boundsArray.emplaceBack(i[0].x,i[0].y,0,0),this._boundsArray.emplaceBack(i[1].x,i[1].y,t.EXTENT,0),this._boundsArray.emplaceBack(i[3].x,i[3].y,0,t.EXTENT),this._boundsArray.emplaceBack(i[2].x,i[2].y,t.EXTENT,t.EXTENT),this.boundsBuffer&&(this.boundsBuffer.destroy(),delete this.boundsBuffer),this.fire(new t.Event("data",{dataType:"source",sourceDataType:"content"})),this},r.prototype.prepare=function(){if(0!==Object.keys(this.tiles).length&&this.image){var e=this.map.painter.context,r=e.gl;for(var n in this.boundsBuffer||(this.boundsBuffer=e.createVertexBuffer(this._boundsArray,O.members)),this.boundsSegments||(this.boundsSegments=t.SegmentVector.simpleSegment(0,0,4,2)),this.texture||(this.texture=new t.Texture(e,this.image,r.RGBA),this.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE)),this.tiles){var i=this.tiles[n];"loaded"!==i.state&&(i.state="loaded",i.texture=this.texture)}}},r.prototype.loadTile=function(t,e){this.tileID&&this.tileID.equals(t.tileID.canonical)?(this.tiles[String(t.tileID.wrap)]=t,t.buckets={},e(null)):(t.state="errored",e(null))},r.prototype.serialize=function(){return{type:"image",url:this.options.url,coordinates:this.coordinates}},r.prototype.hasTransition=function(){return!1},r}(t.Evented),B=function(e){function r(t,r,n,i){e.call(this,t,r,n,i),this.roundZoom=!0,this.type="video",this.options=r}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.load=function(){var e=this;this._loaded=!1;var r=this.options;this.urls=[];for(var n=0,i=r.urls;n<i.length;n+=1)this.urls.push(this.map._requestManager.transformRequest(i[n],t.ResourceType.Source).url);t.getVideo(this.urls,(function(r,n){e._loaded=!0,r?e.fire(new t.ErrorEvent(r)):n&&(e.video=n,e.video.loop=!0,e.video.addEventListener("playing",(function(){e.map.triggerRepaint()})),e.map&&e.video.play(),e._finishLoading())}))},r.prototype.pause=function(){this.video&&this.video.pause()},r.prototype.play=function(){this.video&&this.video.play()},r.prototype.seek=function(e){if(this.video){var r=this.video.seekable;e<r.start(0)||e>r.end(0)?this.fire(new t.ErrorEvent(new t.ValidationError("sources."+this.id,null,"Playback for this video can be set only between the "+r.start(0)+" and "+r.end(0)+"-second mark."))):this.video.currentTime=e}},r.prototype.getVideo=function(){return this.video},r.prototype.onAdd=function(t){this.map||(this.map=t,this.load(),this.video&&(this.video.play(),this.setCoordinates(this.coordinates)))},r.prototype.prepare=function(){if(!(0===Object.keys(this.tiles).length||this.video.readyState<2)){var e=this.map.painter.context,r=e.gl;for(var n in this.boundsBuffer||(this.boundsBuffer=e.createVertexBuffer(this._boundsArray,O.members)),this.boundsSegments||(this.boundsSegments=t.SegmentVector.simpleSegment(0,0,4,2)),this.texture?this.video.paused||(this.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE),r.texSubImage2D(r.TEXTURE_2D,0,0,0,r.RGBA,r.UNSIGNED_BYTE,this.video)):(this.texture=new t.Texture(e,this.video,r.RGBA),this.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE)),this.tiles){var i=this.tiles[n];"loaded"!==i.state&&(i.state="loaded",i.texture=this.texture)}}},r.prototype.serialize=function(){return{type:"video",urls:this.urls,coordinates:this.coordinates}},r.prototype.hasTransition=function(){return this.video&&!this.video.paused},r}(M),k=function(e){function r(r,n,i,o){e.call(this,r,n,i,o),n.coordinates?Array.isArray(n.coordinates)&&4===n.coordinates.length&&!n.coordinates.some((function(t){return!Array.isArray(t)||2!==t.length||t.some((function(t){return"number"!=typeof t}))}))||this.fire(new t.ErrorEvent(new t.ValidationError("sources."+r,null,'"coordinates" property must be an array of 4 longitude/latitude array pairs'))):this.fire(new t.ErrorEvent(new t.ValidationError("sources."+r,null,'missing required property "coordinates"'))),n.animate&&"boolean"!=typeof n.animate&&this.fire(new t.ErrorEvent(new t.ValidationError("sources."+r,null,'optional "animate" property must be a boolean value'))),n.canvas?"string"==typeof n.canvas||n.canvas instanceof t.window.HTMLCanvasElement||this.fire(new t.ErrorEvent(new t.ValidationError("sources."+r,null,'"canvas" must be either a string representing the ID of the canvas element from which to read, or an HTMLCanvasElement instance'))):this.fire(new t.ErrorEvent(new t.ValidationError("sources."+r,null,'missing required property "canvas"'))),this.options=n,this.animate=void 0===n.animate||n.animate}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.load=function(){this._loaded=!0,this.canvas||(this.canvas=this.options.canvas instanceof t.window.HTMLCanvasElement?this.options.canvas:t.window.document.getElementById(this.options.canvas)),this.width=this.canvas.width,this.height=this.canvas.height,this._hasInvalidDimensions()?this.fire(new t.ErrorEvent(new Error("Canvas dimensions cannot be less than or equal to zero."))):(this.play=function(){this._playing=!0,this.map.triggerRepaint()},this.pause=function(){this._playing&&(this.prepare(),this._playing=!1)},this._finishLoading())},r.prototype.getCanvas=function(){return this.canvas},r.prototype.onAdd=function(t){this.map=t,this.load(),this.canvas&&this.animate&&this.play()},r.prototype.onRemove=function(){this.pause()},r.prototype.prepare=function(){var e=!1;if(this.canvas.width!==this.width&&(this.width=this.canvas.width,e=!0),this.canvas.height!==this.height&&(this.height=this.canvas.height,e=!0),!this._hasInvalidDimensions()&&0!==Object.keys(this.tiles).length){var r=this.map.painter.context,n=r.gl;for(var i in this.boundsBuffer||(this.boundsBuffer=r.createVertexBuffer(this._boundsArray,O.members)),this.boundsSegments||(this.boundsSegments=t.SegmentVector.simpleSegment(0,0,4,2)),this.texture?(e||this._playing)&&this.texture.update(this.canvas,{premultiply:!0}):this.texture=new t.Texture(r,this.canvas,n.RGBA,{premultiply:!0}),this.tiles){var o=this.tiles[i];"loaded"!==o.state&&(o.state="loaded",o.texture=this.texture)}}},r.prototype.serialize=function(){return{type:"canvas",coordinates:this.coordinates}},r.prototype.hasTransition=function(){return this._playing},r.prototype._hasInvalidDimensions=function(){for(var t=0,e=[this.canvas.width,this.canvas.height];t<e.length;t+=1){var r=e[t];if(isNaN(r)||r<=0)return!0}return!1},r}(M),F={vector:S,raster:P,"raster-dem":I,geojson:D,video:B,image:M,canvas:k};function L(e,r){var n=t.identity([]);return t.translate(n,n,[1,1,0]),t.scale(n,n,[.5*e.width,.5*e.height,1]),t.multiply(n,n,e.calculatePosMatrix(r.toUnwrapped()))}function R(t,e,r,n,i,o){var a=function(t,e,r){if(t)for(var n=0,i=t;n<i.length;n+=1){var o=e[i[n]];if(o&&o.source===r&&"fill-extrusion"===o.type)return!0}else for(var a in e){var s=e[a];if(s.source===r&&"fill-extrusion"===s.type)return!0}return!1}(i&&i.layers,e,t.id),s=o.maxPitchScaleFactor(),l=t.tilesIn(n,s,a);l.sort(z);for(var u=[],c=0,p=l;c<p.length;c+=1){var h=p[c];u.push({wrappedTileID:h.tileID.wrapped().key,queryResults:h.tile.queryRenderedFeatures(e,r,t._state,h.queryGeometry,h.cameraQueryGeometry,h.scale,i,o,s,L(t.transform,h.tileID))})}var f=function(t){for(var e={},r={},n=0,i=t;n<i.length;n+=1){var o=i[n],a=o.queryResults,s=o.wrappedTileID,l=r[s]=r[s]||{};for(var u in a)for(var c=a[u],p=l[u]=l[u]||{},h=e[u]=e[u]||[],f=0,d=c;f<d.length;f+=1){var m=d[f];p[m.featureIndex]||(p[m.featureIndex]=!0,h.push(m))}}return e}(u);for(var d in f)f[d].forEach((function(e){var r=e.feature,n=t.getFeatureState(r.layer["source-layer"],r.id);r.source=r.layer.source,r.layer["source-layer"]&&(r.sourceLayer=r.layer["source-layer"]),r.state=n}));return f}function z(t,e){var r=t.tileID,n=e.tileID;return r.overscaledZ-n.overscaledZ||r.canonical.y-n.canonical.y||r.wrap-n.wrap||r.canonical.x-n.canonical.x}var N=function(t,e){this.max=t,this.onRemove=e,this.reset()};N.prototype.reset=function(){for(var t in this.data)for(var e=0,r=this.data[t];e<r.length;e+=1){var n=r[e];n.timeout&&clearTimeout(n.timeout),this.onRemove(n.value)}return this.data={},this.order=[],this},N.prototype.add=function(t,e,r){var n=this,i=t.wrapped().key;void 0===this.data[i]&&(this.data[i]=[]);var o={value:e,timeout:void 0};if(void 0!==r&&(o.timeout=setTimeout((function(){n.remove(t,o)}),r)),this.data[i].push(o),this.order.push(i),this.order.length>this.max){var a=this._getAndRemoveByKey(this.order[0]);a&&this.onRemove(a)}return this},N.prototype.has=function(t){return t.wrapped().key in this.data},N.prototype.getAndRemove=function(t){return this.has(t)?this._getAndRemoveByKey(t.wrapped().key):null},N.prototype._getAndRemoveByKey=function(t){var e=this.data[t].shift();return e.timeout&&clearTimeout(e.timeout),0===this.data[t].length&&delete this.data[t],this.order.splice(this.order.indexOf(t),1),e.value},N.prototype.getByKey=function(t){var e=this.data[t];return e?e[0].value:null},N.prototype.get=function(t){return this.has(t)?this.data[t.wrapped().key][0].value:null},N.prototype.remove=function(t,e){if(!this.has(t))return this;var r=t.wrapped().key,n=void 0===e?0:this.data[r].indexOf(e),i=this.data[r][n];return this.data[r].splice(n,1),i.timeout&&clearTimeout(i.timeout),0===this.data[r].length&&delete this.data[r],this.onRemove(i.value),this.order.splice(this.order.indexOf(r),1),this},N.prototype.setMaxSize=function(t){for(this.max=t;this.order.length>this.max;){var e=this._getAndRemoveByKey(this.order[0]);e&&this.onRemove(e)}return this},N.prototype.filter=function(t){var e=[];for(var r in this.data)for(var n=0,i=this.data[r];n<i.length;n+=1){var o=i[n];t(o.value)||e.push(o)}for(var a=0,s=e;a<s.length;a+=1){var l=s[a];this.remove(l.value.tileID,l)}};var j=function(t,e,r){this.context=t;var n=t.gl;this.buffer=n.createBuffer(),this.dynamicDraw=Boolean(r),this.context.unbindVAO(),t.bindElementBuffer.set(this.buffer),n.bufferData(n.ELEMENT_ARRAY_BUFFER,e.arrayBuffer,this.dynamicDraw?n.DYNAMIC_DRAW:n.STATIC_DRAW),this.dynamicDraw||delete e.arrayBuffer};j.prototype.bind=function(){this.context.bindElementBuffer.set(this.buffer)},j.prototype.updateData=function(t){var e=this.context.gl;this.context.unbindVAO(),this.bind(),e.bufferSubData(e.ELEMENT_ARRAY_BUFFER,0,t.arrayBuffer)},j.prototype.destroy=function(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)};var U={Int8:"BYTE",Uint8:"UNSIGNED_BYTE",Int16:"SHORT",Uint16:"UNSIGNED_SHORT",Int32:"INT",Uint32:"UNSIGNED_INT",Float32:"FLOAT"},V=function(t,e,r,n){this.length=e.length,this.attributes=r,this.itemSize=e.bytesPerElement,this.dynamicDraw=n,this.context=t;var i=t.gl;this.buffer=i.createBuffer(),t.bindVertexBuffer.set(this.buffer),i.bufferData(i.ARRAY_BUFFER,e.arrayBuffer,this.dynamicDraw?i.DYNAMIC_DRAW:i.STATIC_DRAW),this.dynamicDraw||delete e.arrayBuffer};V.prototype.bind=function(){this.context.bindVertexBuffer.set(this.buffer)},V.prototype.updateData=function(t){var e=this.context.gl;this.bind(),e.bufferSubData(e.ARRAY_BUFFER,0,t.arrayBuffer)},V.prototype.enableAttributes=function(t,e){for(var r=0;r<this.attributes.length;r++){var n=e.attributes[this.attributes[r].name];void 0!==n&&t.enableVertexAttribArray(n)}},V.prototype.setVertexAttribPointers=function(t,e,r){for(var n=0;n<this.attributes.length;n++){var i=this.attributes[n],o=e.attributes[i.name];void 0!==o&&t.vertexAttribPointer(o,i.components,t[U[i.type]],!1,this.itemSize,i.offset+this.itemSize*(r||0))}},V.prototype.destroy=function(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)};var q=function(t){this.gl=t.gl,this.default=this.getDefault(),this.current=this.default,this.dirty=!1};q.prototype.get=function(){return this.current},q.prototype.set=function(t){},q.prototype.getDefault=function(){return this.default},q.prototype.setDefault=function(){this.set(this.default)};var H=function(e){function r(){e.apply(this,arguments)}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.getDefault=function(){return t.Color.transparent},r.prototype.set=function(t){var e=this.current;(t.r!==e.r||t.g!==e.g||t.b!==e.b||t.a!==e.a||this.dirty)&&(this.gl.clearColor(t.r,t.g,t.b,t.a),this.current=t,this.dirty=!1)},r}(q),G=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return 1},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.clearDepth(t),this.current=t,this.dirty=!1)},e}(q),Z=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return 0},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.clearStencil(t),this.current=t,this.dirty=!1)},e}(q),W=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return[!0,!0,!0,!0]},e.prototype.set=function(t){var e=this.current;(t[0]!==e[0]||t[1]!==e[1]||t[2]!==e[2]||t[3]!==e[3]||this.dirty)&&(this.gl.colorMask(t[0],t[1],t[2],t[3]),this.current=t,this.dirty=!1)},e}(q),Y=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!0},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.depthMask(t),this.current=t,this.dirty=!1)},e}(q),X=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return 255},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.stencilMask(t),this.current=t,this.dirty=!1)},e}(q),K=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return{func:this.gl.ALWAYS,ref:0,mask:255}},e.prototype.set=function(t){var e=this.current;(t.func!==e.func||t.ref!==e.ref||t.mask!==e.mask||this.dirty)&&(this.gl.stencilFunc(t.func,t.ref,t.mask),this.current=t,this.dirty=!1)},e}(q),J=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){var t=this.gl;return[t.KEEP,t.KEEP,t.KEEP]},e.prototype.set=function(t){var e=this.current;(t[0]!==e[0]||t[1]!==e[1]||t[2]!==e[2]||this.dirty)&&(this.gl.stencilOp(t[0],t[1],t[2]),this.current=t,this.dirty=!1)},e}(q),Q=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!1},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;t?e.enable(e.STENCIL_TEST):e.disable(e.STENCIL_TEST),this.current=t,this.dirty=!1}},e}(q),$=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return[0,1]},e.prototype.set=function(t){var e=this.current;(t[0]!==e[0]||t[1]!==e[1]||this.dirty)&&(this.gl.depthRange(t[0],t[1]),this.current=t,this.dirty=!1)},e}(q),tt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!1},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;t?e.enable(e.DEPTH_TEST):e.disable(e.DEPTH_TEST),this.current=t,this.dirty=!1}},e}(q),et=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return this.gl.LESS},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.depthFunc(t),this.current=t,this.dirty=!1)},e}(q),rt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!1},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;t?e.enable(e.BLEND):e.disable(e.BLEND),this.current=t,this.dirty=!1}},e}(q),nt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){var t=this.gl;return[t.ONE,t.ZERO]},e.prototype.set=function(t){var e=this.current;(t[0]!==e[0]||t[1]!==e[1]||this.dirty)&&(this.gl.blendFunc(t[0],t[1]),this.current=t,this.dirty=!1)},e}(q),it=function(e){function r(){e.apply(this,arguments)}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.getDefault=function(){return t.Color.transparent},r.prototype.set=function(t){var e=this.current;(t.r!==e.r||t.g!==e.g||t.b!==e.b||t.a!==e.a||this.dirty)&&(this.gl.blendColor(t.r,t.g,t.b,t.a),this.current=t,this.dirty=!1)},r}(q),ot=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return this.gl.FUNC_ADD},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.blendEquation(t),this.current=t,this.dirty=!1)},e}(q),at=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!1},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;t?e.enable(e.CULL_FACE):e.disable(e.CULL_FACE),this.current=t,this.dirty=!1}},e}(q),st=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return this.gl.BACK},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.cullFace(t),this.current=t,this.dirty=!1)},e}(q),lt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return this.gl.CCW},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.frontFace(t),this.current=t,this.dirty=!1)},e}(q),ut=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.useProgram(t),this.current=t,this.dirty=!1)},e}(q),ct=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return this.gl.TEXTURE0},e.prototype.set=function(t){(t!==this.current||this.dirty)&&(this.gl.activeTexture(t),this.current=t,this.dirty=!1)},e}(q),pt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){var t=this.gl;return[0,0,t.drawingBufferWidth,t.drawingBufferHeight]},e.prototype.set=function(t){var e=this.current;(t[0]!==e[0]||t[1]!==e[1]||t[2]!==e[2]||t[3]!==e[3]||this.dirty)&&(this.gl.viewport(t[0],t[1],t[2],t[3]),this.current=t,this.dirty=!1)},e}(q),ht=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.bindFramebuffer(e.FRAMEBUFFER,t),this.current=t,this.dirty=!1}},e}(q),ft=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.bindRenderbuffer(e.RENDERBUFFER,t),this.current=t,this.dirty=!1}},e}(q),dt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.bindTexture(e.TEXTURE_2D,t),this.current=t,this.dirty=!1}},e}(q),mt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.bindBuffer(e.ARRAY_BUFFER,t),this.current=t,this.dirty=!1}},e}(q),gt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){var e=this.gl;e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,t),this.current=t,this.dirty=!1},e}(q),yt=function(t){function e(e){t.call(this,e),this.vao=e.extVertexArrayObject}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e.prototype.set=function(t){this.vao&&(t!==this.current||this.dirty)&&(this.vao.bindVertexArrayOES(t),this.current=t,this.dirty=!1)},e}(q),vt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return 4},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.pixelStorei(e.UNPACK_ALIGNMENT,t),this.current=t,this.dirty=!1}},e}(q),_t=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!1},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,t),this.current=t,this.dirty=!1}},e}(q),bt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return!1},e.prototype.set=function(t){if(t!==this.current||this.dirty){var e=this.gl;e.pixelStorei(e.UNPACK_FLIP_Y_WEBGL,t),this.current=t,this.dirty=!1}},e}(q),xt=function(t){function e(e,r){t.call(this,e),this.context=e,this.parent=r}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.getDefault=function(){return null},e}(q),wt=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.setDirty=function(){this.dirty=!0},e.prototype.set=function(t){if(t!==this.current||this.dirty){this.context.bindFramebuffer.set(this.parent);var e=this.gl;e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,t,0),this.current=t,this.dirty=!1}},e}(xt),Et=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.set=function(t){if(t!==this.current||this.dirty){this.context.bindFramebuffer.set(this.parent);var e=this.gl;e.framebufferRenderbuffer(e.FRAMEBUFFER,e.DEPTH_ATTACHMENT,e.RENDERBUFFER,t),this.current=t,this.dirty=!1}},e}(xt),Tt=function(t,e,r,n){this.context=t,this.width=e,this.height=r;var i=this.framebuffer=t.gl.createFramebuffer();this.colorAttachment=new wt(t,i),n&&(this.depthAttachment=new Et(t,i))};Tt.prototype.destroy=function(){var t=this.context.gl,e=this.colorAttachment.get();if(e&&t.deleteTexture(e),this.depthAttachment){var r=this.depthAttachment.get();r&&t.deleteRenderbuffer(r)}t.deleteFramebuffer(this.framebuffer)};var At=function(t,e,r){this.func=t,this.mask=e,this.range=r};At.ReadOnly=!1,At.ReadWrite=!0,At.disabled=new At(519,At.ReadOnly,[0,1]);var Ct=function(t,e,r,n,i,o){this.test=t,this.ref=e,this.mask=r,this.fail=n,this.depthFail=i,this.pass=o};Ct.disabled=new Ct({func:519,mask:0},0,0,7680,7680,7680);var St=function(t,e,r){this.blendFunction=t,this.blendColor=e,this.mask=r};St.disabled=new St(St.Replace=[1,0],t.Color.transparent,[!1,!1,!1,!1]),St.unblended=new St(St.Replace,t.Color.transparent,[!0,!0,!0,!0]),St.alphaBlended=new St([1,771],t.Color.transparent,[!0,!0,!0,!0]);var Pt=function(t,e,r){this.enable=t,this.mode=e,this.frontFace=r};Pt.disabled=new Pt(!1,1029,2305),Pt.backCCW=new Pt(!0,1029,2305);var It=function(t){this.gl=t,this.extVertexArrayObject=this.gl.getExtension("OES_vertex_array_object"),this.clearColor=new H(this),this.clearDepth=new G(this),this.clearStencil=new Z(this),this.colorMask=new W(this),this.depthMask=new Y(this),this.stencilMask=new X(this),this.stencilFunc=new K(this),this.stencilOp=new J(this),this.stencilTest=new Q(this),this.depthRange=new $(this),this.depthTest=new tt(this),this.depthFunc=new et(this),this.blend=new rt(this),this.blendFunc=new nt(this),this.blendColor=new it(this),this.blendEquation=new ot(this),this.cullFace=new at(this),this.cullFaceSide=new st(this),this.frontFace=new lt(this),this.program=new ut(this),this.activeTexture=new ct(this),this.viewport=new pt(this),this.bindFramebuffer=new ht(this),this.bindRenderbuffer=new ft(this),this.bindTexture=new dt(this),this.bindVertexBuffer=new mt(this),this.bindElementBuffer=new gt(this),this.bindVertexArrayOES=this.extVertexArrayObject&&new yt(this),this.pixelStoreUnpack=new vt(this),this.pixelStoreUnpackPremultiplyAlpha=new _t(this),this.pixelStoreUnpackFlipY=new bt(this),this.extTextureFilterAnisotropic=t.getExtension("EXT_texture_filter_anisotropic")||t.getExtension("MOZ_EXT_texture_filter_anisotropic")||t.getExtension("WEBKIT_EXT_texture_filter_anisotropic"),this.extTextureFilterAnisotropic&&(this.extTextureFilterAnisotropicMax=t.getParameter(this.extTextureFilterAnisotropic.MAX_TEXTURE_MAX_ANISOTROPY_EXT)),this.extTextureHalfFloat=t.getExtension("OES_texture_half_float"),this.extTextureHalfFloat&&(t.getExtension("OES_texture_half_float_linear"),this.extRenderToTextureHalfFloat=t.getExtension("EXT_color_buffer_half_float")),this.extTimerQuery=t.getExtension("EXT_disjoint_timer_query"),this.maxTextureSize=t.getParameter(t.MAX_TEXTURE_SIZE)};It.prototype.setDefault=function(){this.unbindVAO(),this.clearColor.setDefault(),this.clearDepth.setDefault(),this.clearStencil.setDefault(),this.colorMask.setDefault(),this.depthMask.setDefault(),this.stencilMask.setDefault(),this.stencilFunc.setDefault(),this.stencilOp.setDefault(),this.stencilTest.setDefault(),this.depthRange.setDefault(),this.depthTest.setDefault(),this.depthFunc.setDefault(),this.blend.setDefault(),this.blendFunc.setDefault(),this.blendColor.setDefault(),this.blendEquation.setDefault(),this.cullFace.setDefault(),this.cullFaceSide.setDefault(),this.frontFace.setDefault(),this.program.setDefault(),this.activeTexture.setDefault(),this.bindFramebuffer.setDefault(),this.pixelStoreUnpack.setDefault(),this.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.pixelStoreUnpackFlipY.setDefault()},It.prototype.setDirty=function(){this.clearColor.dirty=!0,this.clearDepth.dirty=!0,this.clearStencil.dirty=!0,this.colorMask.dirty=!0,this.depthMask.dirty=!0,this.stencilMask.dirty=!0,this.stencilFunc.dirty=!0,this.stencilOp.dirty=!0,this.stencilTest.dirty=!0,this.depthRange.dirty=!0,this.depthTest.dirty=!0,this.depthFunc.dirty=!0,this.blend.dirty=!0,this.blendFunc.dirty=!0,this.blendColor.dirty=!0,this.blendEquation.dirty=!0,this.cullFace.dirty=!0,this.cullFaceSide.dirty=!0,this.frontFace.dirty=!0,this.program.dirty=!0,this.activeTexture.dirty=!0,this.viewport.dirty=!0,this.bindFramebuffer.dirty=!0,this.bindRenderbuffer.dirty=!0,this.bindTexture.dirty=!0,this.bindVertexBuffer.dirty=!0,this.bindElementBuffer.dirty=!0,this.extVertexArrayObject&&(this.bindVertexArrayOES.dirty=!0),this.pixelStoreUnpack.dirty=!0,this.pixelStoreUnpackPremultiplyAlpha.dirty=!0,this.pixelStoreUnpackFlipY.dirty=!0},It.prototype.createIndexBuffer=function(t,e){return new j(this,t,e)},It.prototype.createVertexBuffer=function(t,e,r){return new V(this,t,e,r)},It.prototype.createRenderbuffer=function(t,e,r){var n=this.gl,i=n.createRenderbuffer();return this.bindRenderbuffer.set(i),n.renderbufferStorage(n.RENDERBUFFER,t,e,r),this.bindRenderbuffer.set(null),i},It.prototype.createFramebuffer=function(t,e,r){return new Tt(this,t,e,r)},It.prototype.clear=function(t){var e=t.color,r=t.depth,n=this.gl,i=0;e&&(i|=n.COLOR_BUFFER_BIT,this.clearColor.set(e),this.colorMask.set([!0,!0,!0,!0])),void 0!==r&&(i|=n.DEPTH_BUFFER_BIT,this.depthRange.set([0,1]),this.clearDepth.set(r),this.depthMask.set(!0)),n.clear(i)},It.prototype.setCullFace=function(t){!1===t.enable?this.cullFace.set(!1):(this.cullFace.set(!0),this.cullFaceSide.set(t.mode),this.frontFace.set(t.frontFace))},It.prototype.setDepthMode=function(t){t.func!==this.gl.ALWAYS||t.mask?(this.depthTest.set(!0),this.depthFunc.set(t.func),this.depthMask.set(t.mask),this.depthRange.set(t.range)):this.depthTest.set(!1)},It.prototype.setStencilMode=function(t){t.test.func!==this.gl.ALWAYS||t.mask?(this.stencilTest.set(!0),this.stencilMask.set(t.mask),this.stencilOp.set([t.fail,t.depthFail,t.pass]),this.stencilFunc.set({func:t.test.func,ref:t.ref,mask:t.test.mask})):this.stencilTest.set(!1)},It.prototype.setColorMode=function(e){t.deepEqual(e.blendFunction,St.Replace)?this.blend.set(!1):(this.blend.set(!0),this.blendFunc.set(e.blendFunction),this.blendColor.set(e.blendColor)),this.colorMask.set(e.mask)},It.prototype.unbindVAO=function(){this.extVertexArrayObject&&this.bindVertexArrayOES.set(null)};var Dt=function(e){function r(r,n,i){var o=this;e.call(this),this.id=r,this.dispatcher=i,this.on("data",(function(t){"source"===t.dataType&&"metadata"===t.sourceDataType&&(o._sourceLoaded=!0),o._sourceLoaded&&!o._paused&&"source"===t.dataType&&"content"===t.sourceDataType&&(o.reload(),o.transform&&o.update(o.transform))})),this.on("error",(function(){o._sourceErrored=!0})),this._source=function(e,r,n,i){var o=new F[r.type](e,r,n,i);if(o.id!==e)throw new Error("Expected Source id to be "+e+" instead of "+o.id);return t.bindAll(["load","abort","unload","serialize","prepare"],o),o}(r,n,i,this),this._tiles={},this._cache=new N(0,this._unloadTile.bind(this)),this._timers={},this._cacheTimers={},this._maxTileCacheSize=null,this._loadedParentTiles={},this._coveredTiles={},this._state=new t.SourceFeatureState}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.onAdd=function(t){this.map=t,this._maxTileCacheSize=t?t._maxTileCacheSize:null,this._source&&this._source.onAdd&&this._source.onAdd(t)},r.prototype.onRemove=function(t){this._source&&this._source.onRemove&&this._source.onRemove(t)},r.prototype.loaded=function(){if(this._sourceErrored)return!0;if(!this._sourceLoaded)return!1;if(!this._source.loaded())return!1;for(var t in this._tiles){var e=this._tiles[t];if("loaded"!==e.state&&"errored"!==e.state)return!1}return!0},r.prototype.getSource=function(){return this._source},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){if(this._paused){var t=this._shouldReloadOnResume;this._paused=!1,this._shouldReloadOnResume=!1,t&&this.reload(),this.transform&&this.update(this.transform)}},r.prototype._loadTile=function(t,e){return this._source.loadTile(t,e)},r.prototype._unloadTile=function(t){if(this._source.unloadTile)return this._source.unloadTile(t,(function(){}))},r.prototype._abortTile=function(t){if(this._source.abortTile)return this._source.abortTile(t,(function(){}))},r.prototype.serialize=function(){return this._source.serialize()},r.prototype.prepare=function(t){for(var e in this._source.prepare&&this._source.prepare(),this._state.coalesceChanges(this._tiles,this.map?this.map.painter:null),this._tiles){var r=this._tiles[e];r.upload(t),r.prepare(this.map.style.imageManager)}},r.prototype.getIds=function(){return t.values(this._tiles).map((function(t){return t.tileID})).sort(Ot).map((function(t){return t.key}))},r.prototype.getRenderableIds=function(e){var r=this,n=[];for(var i in this._tiles)this._isIdRenderable(i,e)&&n.push(this._tiles[i]);return e?n.sort((function(e,n){var i=e.tileID,o=n.tileID,a=new t.Point(i.canonical.x,i.canonical.y)._rotate(r.transform.angle),s=new t.Point(o.canonical.x,o.canonical.y)._rotate(r.transform.angle);return i.overscaledZ-o.overscaledZ||s.y-a.y||s.x-a.x})).map((function(t){return t.tileID.key})):n.map((function(t){return t.tileID})).sort(Ot).map((function(t){return t.key}))},r.prototype.hasRenderableParent=function(t){var e=this.findLoadedParent(t,0);return!!e&&this._isIdRenderable(e.tileID.key)},r.prototype._isIdRenderable=function(t,e){return this._tiles[t]&&this._tiles[t].hasData()&&!this._coveredTiles[t]&&(e||!this._tiles[t].holdingForFade())},r.prototype.reload=function(){if(this._paused)this._shouldReloadOnResume=!0;else for(var t in this._cache.reset(),this._tiles)"errored"!==this._tiles[t].state&&this._reloadTile(t,"reloading")},r.prototype._reloadTile=function(t,e){var r=this._tiles[t];r&&("loading"!==r.state&&(r.state=e),this._loadTile(r,this._tileLoaded.bind(this,r,t,e)))},r.prototype._tileLoaded=function(e,r,n,i){if(i)return e.state="errored",void(404!==i.status?this._source.fire(new t.ErrorEvent(i,{tile:e})):this.update(this.transform));e.timeAdded=t.browser.now(),"expired"===n&&(e.refreshedUponExpiration=!0),this._setTileReloadTimer(r,e),"raster-dem"===this.getSource().type&&e.dem&&this._backfillDEM(e),this._state.initializeTileState(e,this.map?this.map.painter:null),this._source.fire(new t.Event("data",{dataType:"source",tile:e,coord:e.tileID}))},r.prototype._backfillDEM=function(t){for(var e=this.getRenderableIds(),r=0;r<e.length;r++){var n=e[r];if(t.neighboringTiles&&t.neighboringTiles[n]){var i=this.getTileByID(n);o(t,i),o(i,t)}}function o(t,e){t.needsHillshadePrepare=!0;var r=e.tileID.canonical.x-t.tileID.canonical.x,n=e.tileID.canonical.y-t.tileID.canonical.y,i=Math.pow(2,t.tileID.canonical.z),o=e.tileID.key;0===r&&0===n||Math.abs(n)>1||(Math.abs(r)>1&&(1===Math.abs(r+i)?r+=i:1===Math.abs(r-i)&&(r-=i)),e.dem&&t.dem&&(t.dem.backfillBorder(e.dem,r,n),t.neighboringTiles&&t.neighboringTiles[o]&&(t.neighboringTiles[o].backfilled=!0)))}},r.prototype.getTile=function(t){return this.getTileByID(t.key)},r.prototype.getTileByID=function(t){return this._tiles[t]},r.prototype._retainLoadedChildren=function(t,e,r,n){for(var i in this._tiles){var o=this._tiles[i];if(!(n[i]||!o.hasData()||o.tileID.overscaledZ<=e||o.tileID.overscaledZ>r)){for(var a=o.tileID;o&&o.tileID.overscaledZ>e+1;){var s=o.tileID.scaledTo(o.tileID.overscaledZ-1);(o=this._tiles[s.key])&&o.hasData()&&(a=s)}for(var l=a;l.overscaledZ>e;)if(t[(l=l.scaledTo(l.overscaledZ-1)).key]){n[a.key]=a;break}}}},r.prototype.findLoadedParent=function(t,e){if(t.key in this._loadedParentTiles){var r=this._loadedParentTiles[t.key];return r&&r.tileID.overscaledZ>=e?r:null}for(var n=t.overscaledZ-1;n>=e;n--){var i=t.scaledTo(n),o=this._getLoadedTile(i);if(o)return o}},r.prototype._getLoadedTile=function(t){var e=this._tiles[t.key];return e&&e.hasData()?e:this._cache.getByKey(t.wrapped().key)},r.prototype.updateCacheSize=function(t){var e=Math.ceil(t.width/this._source.tileSize)+1,r=Math.ceil(t.height/this._source.tileSize)+1,n=Math.floor(e*r*5),i="number"==typeof this._maxTileCacheSize?Math.min(this._maxTileCacheSize,n):n;this._cache.setMaxSize(i)},r.prototype.handleWrapJump=function(t){var e=Math.round((t-(void 0===this._prevLng?t:this._prevLng))/360);if(this._prevLng=t,e){var r={};for(var n in this._tiles){var i=this._tiles[n];i.tileID=i.tileID.unwrapTo(i.tileID.wrap+e),r[i.tileID.key]=i}for(var o in this._tiles=r,this._timers)clearTimeout(this._timers[o]),delete this._timers[o];for(var a in this._tiles)this._setTileReloadTimer(a,this._tiles[a])}},r.prototype.update=function(e){var n=this;if(this.transform=e,this._sourceLoaded&&!this._paused){var i;this.updateCacheSize(e),this.handleWrapJump(this.transform.center.lng),this._coveredTiles={},this.used?this._source.tileID?i=e.getVisibleUnwrappedCoordinates(this._source.tileID).map((function(e){return new t.OverscaledTileID(e.canonical.z,e.wrap,e.canonical.z,e.canonical.x,e.canonical.y)})):(i=e.coveringTiles({tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled}),this._source.hasTile&&(i=i.filter((function(t){return n._source.hasTile(t)})))):i=[];var o=e.coveringZoomLevel(this._source),a=Math.max(o-r.maxOverzooming,this._source.minzoom),s=Math.max(o+r.maxUnderzooming,this._source.minzoom),l=this._updateRetainedTiles(i,o);if(Mt(this._source.type)){for(var u={},c={},p=0,h=Object.keys(l);p<h.length;p+=1){var f=h[p],d=l[f],m=this._tiles[f];if(m&&!(m.fadeEndTime&&m.fadeEndTime<=t.browser.now())){var g=this.findLoadedParent(d,a);g&&(this._addTile(g.tileID),u[g.tileID.key]=g.tileID),c[f]=d}}for(var y in this._retainLoadedChildren(c,o,s,l),u)l[y]||(this._coveredTiles[y]=!0,l[y]=u[y])}for(var v in l)this._tiles[v].clearFadeHold();for(var _=0,b=t.keysDifference(this._tiles,l);_<b.length;_+=1){var x=b[_],w=this._tiles[x];w.hasSymbolBuckets&&!w.holdingForFade()?w.setHoldDuration(this.map._fadeDuration):w.hasSymbolBuckets&&!w.symbolFadeFinished()||this._removeTile(x)}this._updateLoadedParentTileCache()}},r.prototype.releaseSymbolFadeTiles=function(){for(var t in this._tiles)this._tiles[t].holdingForFade()&&this._removeTile(t)},r.prototype._updateRetainedTiles=function(t,e){for(var n={},i={},o=Math.max(e-r.maxOverzooming,this._source.minzoom),a=Math.max(e+r.maxUnderzooming,this._source.minzoom),s={},l=0,u=t;l<u.length;l+=1){var c=u[l],p=this._addTile(c);n[c.key]=c,p.hasData()||e<this._source.maxzoom&&(s[c.key]=c)}this._retainLoadedChildren(s,e,a,n);for(var h=0,f=t;h<f.length;h+=1){var d=f[h],m=this._tiles[d.key];if(!m.hasData()){if(e+1>this._source.maxzoom){var g=d.children(this._source.maxzoom)[0],y=this.getTile(g);if(y&&y.hasData()){n[g.key]=g;continue}}else{var v=d.children(this._source.maxzoom);if(n[v[0].key]&&n[v[1].key]&&n[v[2].key]&&n[v[3].key])continue}for(var _=m.wasRequested(),b=d.overscaledZ-1;b>=o;--b){var x=d.scaledTo(b);if(i[x.key])break;if(i[x.key]=!0,!(m=this.getTile(x))&&_&&(m=this._addTile(x)),m&&(n[x.key]=x,_=m.wasRequested(),m.hasData()))break}}}return n},r.prototype._updateLoadedParentTileCache=function(){for(var t in this._loadedParentTiles={},this._tiles){for(var e=[],r=void 0,n=this._tiles[t].tileID;n.overscaledZ>0;){if(n.key in this._loadedParentTiles){r=this._loadedParentTiles[n.key];break}e.push(n.key);var i=n.scaledTo(n.overscaledZ-1);if(r=this._getLoadedTile(i))break;n=i}for(var o=0,a=e;o<a.length;o+=1)this._loadedParentTiles[a[o]]=r}},r.prototype._addTile=function(e){var r=this._tiles[e.key];if(r)return r;(r=this._cache.getAndRemove(e))&&(this._setTileReloadTimer(e.key,r),r.tileID=e,this._state.initializeTileState(r,this.map?this.map.painter:null),this._cacheTimers[e.key]&&(clearTimeout(this._cacheTimers[e.key]),delete this._cacheTimers[e.key],this._setTileReloadTimer(e.key,r)));var n=Boolean(r);return n||(r=new t.Tile(e,this._source.tileSize*e.overscaleFactor()),this._loadTile(r,this._tileLoaded.bind(this,r,e.key,r.state))),r?(r.uses++,this._tiles[e.key]=r,n||this._source.fire(new t.Event("dataloading",{tile:r,coord:r.tileID,dataType:"source"})),r):null},r.prototype._setTileReloadTimer=function(t,e){var r=this;t in this._timers&&(clearTimeout(this._timers[t]),delete this._timers[t]);var n=e.getExpiryTimeout();n&&(this._timers[t]=setTimeout((function(){r._reloadTile(t,"expired"),delete r._timers[t]}),n))},r.prototype._removeTile=function(t){var e=this._tiles[t];e&&(e.uses--,delete this._tiles[t],this._timers[t]&&(clearTimeout(this._timers[t]),delete this._timers[t]),e.uses>0||(e.hasData()&&"reloading"!==e.state?this._cache.add(e.tileID,e,e.getExpiryTimeout()):(e.aborted=!0,this._abortTile(e),this._unloadTile(e))))},r.prototype.clearTiles=function(){for(var t in this._shouldReloadOnResume=!1,this._paused=!1,this._tiles)this._removeTile(t);this._cache.reset()},r.prototype.tilesIn=function(e,r,n){var i=this,o=[],a=this.transform;if(!a)return o;for(var s=n?a.getCameraQueryGeometry(e):e,l=e.map((function(t){return a.pointCoordinate(t)})),u=s.map((function(t){return a.pointCoordinate(t)})),c=this.getIds(),p=1/0,h=1/0,f=-1/0,d=-1/0,m=0,g=u;m<g.length;m+=1){var y=g[m];p=Math.min(p,y.x),h=Math.min(h,y.y),f=Math.max(f,y.x),d=Math.max(d,y.y)}for(var v=function(e){var n=i._tiles[c[e]];if(!n.holdingForFade()){var s=n.tileID,m=Math.pow(2,a.zoom-n.tileID.overscaledZ),g=r*n.queryPadding*t.EXTENT/n.tileSize/m,y=[s.getTilePoint(new t.MercatorCoordinate(p,h)),s.getTilePoint(new t.MercatorCoordinate(f,d))];if(y[0].x-g<t.EXTENT&&y[0].y-g<t.EXTENT&&y[1].x+g>=0&&y[1].y+g>=0){var v=l.map((function(t){return s.getTilePoint(t)})),_=u.map((function(t){return s.getTilePoint(t)}));o.push({tile:n,tileID:s,queryGeometry:v,cameraQueryGeometry:_,scale:m})}}},_=0;_<c.length;_++)v(_);return o},r.prototype.getVisibleCoordinates=function(t){for(var e=this,r=this.getRenderableIds(t).map((function(t){return e._tiles[t].tileID})),n=0,i=r;n<i.length;n+=1){var o=i[n];o.posMatrix=this.transform.calculatePosMatrix(o.toUnwrapped())}return r},r.prototype.hasTransition=function(){if(this._source.hasTransition())return!0;if(Mt(this._source.type))for(var e in this._tiles){var r=this._tiles[e];if(void 0!==r.fadeEndTime&&r.fadeEndTime>=t.browser.now())return!0}return!1},r.prototype.setFeatureState=function(t,e,r){this._state.updateState(t=t||"_geojsonTileLayer",e,r)},r.prototype.removeFeatureState=function(t,e,r){this._state.removeFeatureState(t=t||"_geojsonTileLayer",e,r)},r.prototype.getFeatureState=function(t,e){return this._state.getState(t=t||"_geojsonTileLayer",e)},r.prototype.setDependencies=function(t,e,r){var n=this._tiles[t];n&&n.setDependencies(e,r)},r.prototype.reloadTilesForDependencies=function(t,e){for(var r in this._tiles)this._tiles[r].hasDependency(t,e)&&this._reloadTile(r,"reloading");this._cache.filter((function(r){return!r.hasDependency(t,e)}))},r}(t.Evented);function Ot(t,e){var r=Math.abs(2*t.wrap)-+(t.wrap<0),n=Math.abs(2*e.wrap)-+(e.wrap<0);return t.overscaledZ-e.overscaledZ||n-r||e.canonical.y-t.canonical.y||e.canonical.x-t.canonical.x}function Mt(t){return"raster"===t||"image"===t||"video"===t}function Bt(){return new t.window.Worker(Xi.workerUrl)}Dt.maxOverzooming=10,Dt.maxUnderzooming=3;var kt="mapboxgl_preloaded_worker_pool",Ft=function(){this.active={}};Ft.prototype.acquire=function(t){if(!this.workers)for(this.workers=[];this.workers.length<Ft.workerCount;)this.workers.push(new Bt);return this.active[t]=!0,this.workers.slice()},Ft.prototype.release=function(t){delete this.active[t],0===this.numActive()&&(this.workers.forEach((function(t){t.terminate()})),this.workers=null)},Ft.prototype.isPreloaded=function(){return!!this.active[kt]},Ft.prototype.numActive=function(){return Object.keys(this.active).length};var Lt,Rt=Math.floor(t.browser.hardwareConcurrency/2);function zt(){return Lt||(Lt=new Ft),Lt}function Nt(e,r){var n={};for(var i in e)"ref"!==i&&(n[i]=e[i]);return t.refProperties.forEach((function(t){t in r&&(n[t]=r[t])})),n}function jt(t){t=t.slice();for(var e=Object.create(null),r=0;r<t.length;r++)e[t[r].id]=t[r];for(var n=0;n<t.length;n++)"ref"in t[n]&&(t[n]=Nt(t[n],e[t[n].ref]));return t}Ft.workerCount=Math.max(Math.min(Rt,6),1);var Ut={setStyle:"setStyle",addLayer:"addLayer",removeLayer:"removeLayer",setPaintProperty:"setPaintProperty",setLayoutProperty:"setLayoutProperty",setFilter:"setFilter",addSource:"addSource",removeSource:"removeSource",setGeoJSONSourceData:"setGeoJSONSourceData",setLayerZoomRange:"setLayerZoomRange",setLayerProperty:"setLayerProperty",setCenter:"setCenter",setZoom:"setZoom",setBearing:"setBearing",setPitch:"setPitch",setSprite:"setSprite",setGlyphs:"setGlyphs",setTransition:"setTransition",setLight:"setLight"};function Vt(t,e,r){r.push({command:Ut.addSource,args:[t,e[t]]})}function qt(t,e,r){e.push({command:Ut.removeSource,args:[t]}),r[t]=!0}function Ht(t,e,r,n){qt(t,r,n),Vt(t,e,r)}function Gt(e,r,n){var i;for(i in e[n])if(e[n].hasOwnProperty(i)&&"data"!==i&&!t.deepEqual(e[n][i],r[n][i]))return!1;for(i in r[n])if(r[n].hasOwnProperty(i)&&"data"!==i&&!t.deepEqual(e[n][i],r[n][i]))return!1;return!0}function Zt(e,r,n,i,o,a){var s;for(s in r=r||{},e=e||{})e.hasOwnProperty(s)&&(t.deepEqual(e[s],r[s])||n.push({command:a,args:[i,s,r[s],o]}));for(s in r)r.hasOwnProperty(s)&&!e.hasOwnProperty(s)&&(t.deepEqual(e[s],r[s])||n.push({command:a,args:[i,s,r[s],o]}))}function Wt(t){return t.id}function Yt(t,e){return t[e.id]=e,t}var Xt=function(t,e){this.reset(t,e)};Xt.prototype.reset=function(t,e){this.points=t||[],this._distances=[0];for(var r=1;r<this.points.length;r++)this._distances[r]=this._distances[r-1]+this.points[r].dist(this.points[r-1]);this.length=this._distances[this._distances.length-1],this.padding=Math.min(e||0,.5*this.length),this.paddedLength=this.length-2*this.padding},Xt.prototype.lerp=function(e){if(1===this.points.length)return this.points[0];e=t.clamp(e,0,1);for(var r=1,n=this._distances[r],i=e*this.paddedLength+this.padding;n<i&&r<this._distances.length;)n=this._distances[++r];var o=r-1,a=this._distances[o],s=n-a,l=s>0?(i-a)/s:0;return this.points[o].mult(1-l).add(this.points[r].mult(l))};var Kt=function(t,e,r){var n=this.boxCells=[],i=this.circleCells=[];this.xCellCount=Math.ceil(t/r),this.yCellCount=Math.ceil(e/r);for(var o=0;o<this.xCellCount*this.yCellCount;o++)n.push([]),i.push([]);this.circleKeys=[],this.boxKeys=[],this.bboxes=[],this.circles=[],this.width=t,this.height=e,this.xScale=this.xCellCount/t,this.yScale=this.yCellCount/e,this.boxUid=0,this.circleUid=0};function Jt(e,r,n,i,o){var a=t.create();return r?(t.scale(a,a,[1/o,1/o,1]),n||t.rotateZ(a,a,i.angle)):t.multiply(a,i.labelPlaneMatrix,e),a}function Qt(e,r,n,i,o){if(r){var a=t.clone(e);return t.scale(a,a,[o,o,1]),n||t.rotateZ(a,a,-i.angle),a}return i.glCoordMatrix}function $t(e,r){var n=[e.x,e.y,0,1];ce(n,n,r);var i=n[3];return{point:new t.Point(n[0]/i,n[1]/i),signedDistanceFromCamera:i}}function te(t,e){return.5+t/e*.5}function ee(t,e){var r=t[0]/t[3],n=t[1]/t[3];return r>=-e[0]&&r<=e[0]&&n>=-e[1]&&n<=e[1]}function re(e,r,n,i,o,a,s,l){var u=i?e.textSizeData:e.iconSizeData,c=t.evaluateSizeForZoom(u,n.transform.zoom),p=[256/n.width*2+1,256/n.height*2+1],h=i?e.text.dynamicLayoutVertexArray:e.icon.dynamicLayoutVertexArray;h.clear();for(var f=e.lineVertexArray,d=i?e.text.placedSymbolArray:e.icon.placedSymbolArray,m=n.transform.width/n.transform.height,g=!1,y=0;y<d.length;y++){var v=d.get(y);if(v.hidden||v.writingMode===t.WritingMode.vertical&&!g)ue(v.numGlyphs,h);else{g=!1;var _=[v.anchorX,v.anchorY,0,1];if(t.transformMat4(_,_,r),ee(_,p)){var b=te(n.transform.cameraToCenterDistance,_[3]),x=t.evaluateSizeForFeature(u,c,v),w=s?x/b:x*b,E=new t.Point(v.anchorX,v.anchorY),T=$t(E,o).point,A={},C=oe(v,w,!1,l,r,o,a,e.glyphOffsetArray,f,h,T,E,A,m);g=C.useVertical,(C.notEnoughRoom||g||C.needsFlipping&&oe(v,w,!0,l,r,o,a,e.glyphOffsetArray,f,h,T,E,A,m).notEnoughRoom)&&ue(v.numGlyphs,h)}else ue(v.numGlyphs,h)}}i?e.text.dynamicLayoutVertexBuffer.updateData(h):e.icon.dynamicLayoutVertexBuffer.updateData(h)}function ne(t,e,r,n,i,o,a,s,l,u,c){var p=s.glyphStartIndex+s.numGlyphs,h=s.lineStartIndex,f=s.lineStartIndex+s.lineLength,d=e.getoffsetX(s.glyphStartIndex),m=e.getoffsetX(p-1),g=se(t*d,r,n,i,o,a,s.segment,h,f,l,u,c);if(!g)return null;var y=se(t*m,r,n,i,o,a,s.segment,h,f,l,u,c);return y?{first:g,last:y}:null}function ie(e,r,n,i){return e===t.WritingMode.horizontal&&Math.abs(n.y-r.y)>Math.abs(n.x-r.x)*i?{useVertical:!0}:(e===t.WritingMode.vertical?r.y<n.y:r.x>n.x)?{needsFlipping:!0}:null}function oe(e,r,n,i,o,a,s,l,u,c,p,h,f,d){var m,g=r/24,y=e.lineOffsetX*g,v=e.lineOffsetY*g;if(e.numGlyphs>1){var _=e.glyphStartIndex+e.numGlyphs,b=e.lineStartIndex,x=e.lineStartIndex+e.lineLength,w=ne(g,l,y,v,n,p,h,e,u,a,f);if(!w)return{notEnoughRoom:!0};var E=$t(w.first.point,s).point,T=$t(w.last.point,s).point;if(i&&!n){var A=ie(e.writingMode,E,T,d);if(A)return A}m=[w.first];for(var C=e.glyphStartIndex+1;C<_-1;C++)m.push(se(g*l.getoffsetX(C),y,v,n,p,h,e.segment,b,x,u,a,f));m.push(w.last)}else{if(i&&!n){var S=$t(h,o).point,P=e.lineStartIndex+e.segment+1,I=new t.Point(u.getx(P),u.gety(P)),D=$t(I,o),O=D.signedDistanceFromCamera>0?D.point:ae(h,I,S,1,o),M=ie(e.writingMode,S,O,d);if(M)return M}var B=se(g*l.getoffsetX(e.glyphStartIndex),y,v,n,p,h,e.segment,e.lineStartIndex,e.lineStartIndex+e.lineLength,u,a,f);if(!B)return{notEnoughRoom:!0};m=[B]}for(var k=0,F=m;k<F.length;k+=1){var L=F[k];t.addDynamicAttributes(c,L.point,L.angle)}return{}}function ae(t,e,r,n,i){var o=$t(t.add(t.sub(e)._unit()),i).point,a=r.sub(o);return r.add(a._mult(n/a.mag()))}function se(e,r,n,i,o,a,s,l,u,c,p,h){var f=i?e-r:e+r,d=f>0?1:-1,m=0;i&&(d*=-1,m=Math.PI),d<0&&(m+=Math.PI);for(var g=d>0?l+s:l+s+1,y=o,v=o,_=0,b=0,x=Math.abs(f),w=[];_+b<=x;){if((g+=d)<l||g>=u)return null;if(v=y,w.push(y),void 0===(y=h[g])){var E=new t.Point(c.getx(g),c.gety(g)),T=$t(E,p);if(T.signedDistanceFromCamera>0)y=h[g]=T.point;else{var A=g-d;y=ae(0===_?a:new t.Point(c.getx(A),c.gety(A)),E,v,x-_+1,p)}}_+=b,b=v.dist(y)}var C=(x-_)/b,S=y.sub(v),P=S.mult(C)._add(v);P._add(S._unit()._perp()._mult(n*d));var I=m+Math.atan2(y.y-v.y,y.x-v.x);return w.push(P),{point:P,angle:I,path:w}}Kt.prototype.keysLength=function(){return this.boxKeys.length+this.circleKeys.length},Kt.prototype.insert=function(t,e,r,n,i){this._forEachCell(e,r,n,i,this._insertBoxCell,this.boxUid++),this.boxKeys.push(t),this.bboxes.push(e),this.bboxes.push(r),this.bboxes.push(n),this.bboxes.push(i)},Kt.prototype.insertCircle=function(t,e,r,n){this._forEachCell(e-n,r-n,e+n,r+n,this._insertCircleCell,this.circleUid++),this.circleKeys.push(t),this.circles.push(e),this.circles.push(r),this.circles.push(n)},Kt.prototype._insertBoxCell=function(t,e,r,n,i,o){this.boxCells[i].push(o)},Kt.prototype._insertCircleCell=function(t,e,r,n,i,o){this.circleCells[i].push(o)},Kt.prototype._query=function(t,e,r,n,i,o){if(r<0||t>this.width||n<0||e>this.height)return!i&&[];var a=[];if(t<=0&&e<=0&&this.width<=r&&this.height<=n){if(i)return!0;for(var s=0;s<this.boxKeys.length;s++)a.push({key:this.boxKeys[s],x1:this.bboxes[4*s],y1:this.bboxes[4*s+1],x2:this.bboxes[4*s+2],y2:this.bboxes[4*s+3]});for(var l=0;l<this.circleKeys.length;l++){var u=this.circles[3*l],c=this.circles[3*l+1],p=this.circles[3*l+2];a.push({key:this.circleKeys[l],x1:u-p,y1:c-p,x2:u+p,y2:c+p})}return o?a.filter(o):a}return this._forEachCell(t,e,r,n,this._queryCell,a,{hitTest:i,seenUids:{box:{},circle:{}}},o),i?a.length>0:a},Kt.prototype._queryCircle=function(t,e,r,n,i){var o=t-r,a=t+r,s=e-r,l=e+r;if(a<0||o>this.width||l<0||s>this.height)return!n&&[];var u=[];return this._forEachCell(o,s,a,l,this._queryCellCircle,u,{hitTest:n,circle:{x:t,y:e,radius:r},seenUids:{box:{},circle:{}}},i),n?u.length>0:u},Kt.prototype.query=function(t,e,r,n,i){return this._query(t,e,r,n,!1,i)},Kt.prototype.hitTest=function(t,e,r,n,i){return this._query(t,e,r,n,!0,i)},Kt.prototype.hitTestCircle=function(t,e,r,n){return this._queryCircle(t,e,r,!0,n)},Kt.prototype._queryCell=function(t,e,r,n,i,o,a,s){var l=a.seenUids,u=this.boxCells[i];if(null!==u)for(var c=this.bboxes,p=0,h=u;p<h.length;p+=1){var f=h[p];if(!l.box[f]){l.box[f]=!0;var d=4*f;if(t<=c[d+2]&&e<=c[d+3]&&r>=c[d+0]&&n>=c[d+1]&&(!s||s(this.boxKeys[f]))){if(a.hitTest)return o.push(!0),!0;o.push({key:this.boxKeys[f],x1:c[d],y1:c[d+1],x2:c[d+2],y2:c[d+3]})}}}var m=this.circleCells[i];if(null!==m)for(var g=this.circles,y=0,v=m;y<v.length;y+=1){var _=v[y];if(!l.circle[_]){l.circle[_]=!0;var b=3*_;if(this._circleAndRectCollide(g[b],g[b+1],g[b+2],t,e,r,n)&&(!s||s(this.circleKeys[_]))){if(a.hitTest)return o.push(!0),!0;var x=g[b],w=g[b+1],E=g[b+2];o.push({key:this.circleKeys[_],x1:x-E,y1:w-E,x2:x+E,y2:w+E})}}}},Kt.prototype._queryCellCircle=function(t,e,r,n,i,o,a,s){var l=a.circle,u=a.seenUids,c=this.boxCells[i];if(null!==c)for(var p=this.bboxes,h=0,f=c;h<f.length;h+=1){var d=f[h];if(!u.box[d]){u.box[d]=!0;var m=4*d;if(this._circleAndRectCollide(l.x,l.y,l.radius,p[m+0],p[m+1],p[m+2],p[m+3])&&(!s||s(this.boxKeys[d])))return o.push(!0),!0}}var g=this.circleCells[i];if(null!==g)for(var y=this.circles,v=0,_=g;v<_.length;v+=1){var b=_[v];if(!u.circle[b]){u.circle[b]=!0;var x=3*b;if(this._circlesCollide(y[x],y[x+1],y[x+2],l.x,l.y,l.radius)&&(!s||s(this.circleKeys[b])))return o.push(!0),!0}}},Kt.prototype._forEachCell=function(t,e,r,n,i,o,a,s){for(var l=this._convertToXCellCoord(t),u=this._convertToYCellCoord(e),c=this._convertToXCellCoord(r),p=this._convertToYCellCoord(n),h=l;h<=c;h++)for(var f=u;f<=p;f++)if(i.call(this,t,e,r,n,this.xCellCount*f+h,o,a,s))return},Kt.prototype._convertToXCellCoord=function(t){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(t*this.xScale)))},Kt.prototype._convertToYCellCoord=function(t){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(t*this.yScale)))},Kt.prototype._circlesCollide=function(t,e,r,n,i,o){var a=n-t,s=i-e,l=r+o;return l*l>a*a+s*s},Kt.prototype._circleAndRectCollide=function(t,e,r,n,i,o,a){var s=(o-n)/2,l=Math.abs(t-(n+s));if(l>s+r)return!1;var u=(a-i)/2,c=Math.abs(e-(i+u));if(c>u+r)return!1;if(l<=s||c<=u)return!0;var p=l-s,h=c-u;return p*p+h*h<=r*r};var le=new Float32Array([-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0]);function ue(t,e){for(var r=0;r<t;r++){var n=e.length;e.resize(n+4),e.float32.set(le,3*n)}}function ce(t,e,r){var n=e[0],i=e[1];return t[0]=r[0]*n+r[4]*i+r[12],t[1]=r[1]*n+r[5]*i+r[13],t[3]=r[3]*n+r[7]*i+r[15],t}var pe=function(t,e,r){void 0===e&&(e=new Kt(t.width+200,t.height+200,25)),void 0===r&&(r=new Kt(t.width+200,t.height+200,25)),this.transform=t,this.grid=e,this.ignoredGrid=r,this.pitchfactor=Math.cos(t._pitch)*t.cameraToCenterDistance,this.screenRightBoundary=t.width+100,this.screenBottomBoundary=t.height+100,this.gridRightBoundary=t.width+200,this.gridBottomBoundary=t.height+200};function he(e,r,n){return r*(t.EXTENT/(e.tileSize*Math.pow(2,n-e.tileID.overscaledZ)))}pe.prototype.placeCollisionBox=function(t,e,r,n,i){var o=this.projectAndGetPerspectiveRatio(n,t.anchorPointX,t.anchorPointY),a=r*o.perspectiveRatio,s=t.x1*a+o.point.x,l=t.y1*a+o.point.y,u=t.x2*a+o.point.x,c=t.y2*a+o.point.y;return!this.isInsideGrid(s,l,u,c)||!e&&this.grid.hitTest(s,l,u,c,i)?{box:[],offscreen:!1}:{box:[s,l,u,c],offscreen:this.isOffscreen(s,l,u,c)}},pe.prototype.placeCollisionCircles=function(e,r,n,i,o,a,s,l,u,c,p,h,f){var d=[],m=new t.Point(r.anchorX,r.anchorY),g=$t(m,a),y=te(this.transform.cameraToCenterDistance,g.signedDistanceFromCamera),v=(c?o/y:o*y)/t.ONE_EM,_=$t(m,s).point,b=ne(v,i,r.lineOffsetX*v,r.lineOffsetY*v,!1,_,m,r,n,s,{}),x=!1,w=!1,E=!0;if(b){for(var T=.5*h*y+f,A=new t.Point(-100,-100),C=new t.Point(this.screenRightBoundary,this.screenBottomBoundary),S=new Xt,P=b.first,I=b.last,D=[],O=P.path.length-1;O>=1;O--)D.push(P.path[O]);for(var M=1;M<I.path.length;M++)D.push(I.path[M]);var B=2.5*T;if(l){var k=D.map((function(t){return $t(t,l)}));D=k.some((function(t){return t.signedDistanceFromCamera<=0}))?[]:k.map((function(t){return t.point}))}var F=[];if(D.length>0){for(var L=D[0].clone(),R=D[0].clone(),z=1;z<D.length;z++)L.x=Math.min(L.x,D[z].x),L.y=Math.min(L.y,D[z].y),R.x=Math.max(R.x,D[z].x),R.y=Math.max(R.y,D[z].y);F=L.x>=A.x&&R.x<=C.x&&L.y>=A.y&&R.y<=C.y?[D]:R.x<A.x||L.x>C.x||R.y<A.y||L.y>C.y?[]:t.clipLine([D],A.x,A.y,C.x,C.y)}for(var N=0,j=F;N<j.length;N+=1){var U;S.reset(j[N],.25*T),U=S.length<=.5*T?1:Math.ceil(S.paddedLength/B)+1;for(var V=0;V<U;V++){var q=V/Math.max(U-1,1),H=S.lerp(q),G=H.x+100,Z=H.y+100;d.push(G,Z,T,0);var W=G-T,Y=Z-T,X=G+T,K=Z+T;if(E=E&&this.isOffscreen(W,Y,X,K),w=w||this.isInsideGrid(W,Y,X,K),!e&&this.grid.hitTestCircle(G,Z,T,p)&&(x=!0,!u))return{circles:[],offscreen:!1,collisionDetected:x}}}}return{circles:!u&&x||!w?[]:d,offscreen:E,collisionDetected:x}},pe.prototype.queryRenderedSymbols=function(e){if(0===e.length||0===this.grid.keysLength()&&0===this.ignoredGrid.keysLength())return{};for(var r=[],n=1/0,i=1/0,o=-1/0,a=-1/0,s=0,l=e;s<l.length;s+=1){var u=l[s],c=new t.Point(u.x+100,u.y+100);n=Math.min(n,c.x),i=Math.min(i,c.y),o=Math.max(o,c.x),a=Math.max(a,c.y),r.push(c)}for(var p={},h={},f=0,d=this.grid.query(n,i,o,a).concat(this.ignoredGrid.query(n,i,o,a));f<d.length;f+=1){var m=d[f],g=m.key;if(void 0===p[g.bucketInstanceId]&&(p[g.bucketInstanceId]={}),!p[g.bucketInstanceId][g.featureIndex]){var y=[new t.Point(m.x1,m.y1),new t.Point(m.x2,m.y1),new t.Point(m.x2,m.y2),new t.Point(m.x1,m.y2)];t.polygonIntersectsPolygon(r,y)&&(p[g.bucketInstanceId][g.featureIndex]=!0,void 0===h[g.bucketInstanceId]&&(h[g.bucketInstanceId]=[]),h[g.bucketInstanceId].push(g.featureIndex))}}return h},pe.prototype.insertCollisionBox=function(t,e,r,n,i){(e?this.ignoredGrid:this.grid).insert({bucketInstanceId:r,featureIndex:n,collisionGroupID:i},t[0],t[1],t[2],t[3])},pe.prototype.insertCollisionCircles=function(t,e,r,n,i){for(var o=e?this.ignoredGrid:this.grid,a={bucketInstanceId:r,featureIndex:n,collisionGroupID:i},s=0;s<t.length;s+=4)o.insertCircle(a,t[s],t[s+1],t[s+2])},pe.prototype.projectAndGetPerspectiveRatio=function(e,r,n){var i=[r,n,0,1];return ce(i,i,e),{point:new t.Point((i[0]/i[3]+1)/2*this.transform.width+100,(-i[1]/i[3]+1)/2*this.transform.height+100),perspectiveRatio:.5+this.transform.cameraToCenterDistance/i[3]*.5}},pe.prototype.isOffscreen=function(t,e,r,n){return r<100||t>=this.screenRightBoundary||n<100||e>this.screenBottomBoundary},pe.prototype.isInsideGrid=function(t,e,r,n){return r>=0&&t<this.gridRightBoundary&&n>=0&&e<this.gridBottomBoundary},pe.prototype.getViewportMatrix=function(){var e=t.identity([]);return t.translate(e,e,[-100,-100,0]),e};var fe=function(t,e,r,n){this.opacity=t?Math.max(0,Math.min(1,t.opacity+(t.placed?e:-e))):n&&r?1:0,this.placed=r};fe.prototype.isHidden=function(){return 0===this.opacity&&!this.placed};var de=function(t,e,r,n,i){this.text=new fe(t?t.text:null,e,r,i),this.icon=new fe(t?t.icon:null,e,n,i)};de.prototype.isHidden=function(){return this.text.isHidden()&&this.icon.isHidden()};var me=function(t,e,r){this.text=t,this.icon=e,this.skipFade=r},ge=function(){this.invProjMatrix=t.create(),this.viewportMatrix=t.create(),this.circles=[]},ye=function(t,e,r,n,i){this.bucketInstanceId=t,this.featureIndex=e,this.sourceLayerIndex=r,this.bucketIndex=n,this.tileID=i},ve=function(t){this.crossSourceCollisions=t,this.maxGroupID=0,this.collisionGroups={}};function _e(e,r,n,i,o){var a=t.getAnchorAlignment(e),s=-(a.horizontalAlign-.5)*r,l=-(a.verticalAlign-.5)*n,u=t.evaluateVariableOffset(e,i);return new t.Point(s+u[0]*o,l+u[1]*o)}function be(e,r,n,i,o,a){var s=e.x1,l=e.x2,u=e.y1,c=e.y2,p=e.anchorPointX,h=e.anchorPointY,f=new t.Point(r,n);return i&&f._rotate(o?a:-a),{x1:s+f.x,y1:u+f.y,x2:l+f.x,y2:c+f.y,anchorPointX:p,anchorPointY:h}}ve.prototype.get=function(t){if(this.crossSourceCollisions)return{ID:0,predicate:null};if(!this.collisionGroups[t]){var e=++this.maxGroupID;this.collisionGroups[t]={ID:e,predicate:function(t){return t.collisionGroupID===e}}}return this.collisionGroups[t]};var xe=function(t,e,r,n){this.transform=t.clone(),this.collisionIndex=new pe(this.transform),this.placements={},this.opacities={},this.variableOffsets={},this.stale=!1,this.commitTime=0,this.fadeDuration=e,this.retainedQueryData={},this.collisionGroups=new ve(r),this.collisionCircleArrays={},this.prevPlacement=n,n&&(n.prevPlacement=void 0),this.placedOrientations={}};function we(t,e,r,n,i){t.emplaceBack(e?1:0,r?1:0,n||0,i||0),t.emplaceBack(e?1:0,r?1:0,n||0,i||0),t.emplaceBack(e?1:0,r?1:0,n||0,i||0),t.emplaceBack(e?1:0,r?1:0,n||0,i||0)}xe.prototype.getBucketParts=function(e,r,n,i){var o=n.getBucket(r),a=n.latestFeatureIndex;if(o&&a&&r.id===o.layerIds[0]){var s=n.collisionBoxArray,l=o.layers[0].layout,u=Math.pow(2,this.transform.zoom-n.tileID.overscaledZ),c=n.tileSize/t.EXTENT,p=this.transform.calculatePosMatrix(n.tileID.toUnwrapped()),h="map"===l.get("text-pitch-alignment"),f="map"===l.get("text-rotation-alignment"),d=he(n,1,this.transform.zoom),m=Jt(p,h,f,this.transform,d),g=null;if(h){var y=Qt(p,h,f,this.transform,d);g=t.multiply([],this.transform.labelPlaneMatrix,y)}this.retainedQueryData[o.bucketInstanceId]=new ye(o.bucketInstanceId,a,o.sourceLayerIndex,o.index,n.tileID);var v={bucket:o,layout:l,posMatrix:p,textLabelPlaneMatrix:m,labelToScreenMatrix:g,scale:u,textPixelRatio:c,holdingForFade:n.holdingForFade(),collisionBoxArray:s,partiallyEvaluatedTextSize:t.evaluateSizeForZoom(o.textSizeData,this.transform.zoom),collisionGroup:this.collisionGroups.get(o.sourceID)};if(i)for(var _=0,b=o.sortKeyRanges;_<b.length;_+=1){var x=b[_];e.push({sortKey:x.sortKey,symbolInstanceStart:x.symbolInstanceStart,symbolInstanceEnd:x.symbolInstanceEnd,parameters:v})}else e.push({symbolInstanceStart:0,symbolInstanceEnd:o.symbolInstances.length,parameters:v})}},xe.prototype.attemptAnchorPlacement=function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d){var m,g=[p.textOffset0,p.textOffset1],y=_e(t,r,n,g,i),v=this.collisionIndex.placeCollisionBox(be(e,y.x,y.y,o,a,this.transform.angle),c,s,l,u.predicate);if(!d||0!==this.collisionIndex.placeCollisionBox(be(d,y.x,y.y,o,a,this.transform.angle),c,s,l,u.predicate).box.length)return v.box.length>0?(this.prevPlacement&&this.prevPlacement.variableOffsets[p.crossTileID]&&this.prevPlacement.placements[p.crossTileID]&&this.prevPlacement.placements[p.crossTileID].text&&(m=this.prevPlacement.variableOffsets[p.crossTileID].anchor),this.variableOffsets[p.crossTileID]={textOffset:g,width:r,height:n,anchor:t,textBoxScale:i,prevAnchor:m},this.markUsedJustification(h,t,p,f),h.allowVerticalPlacement&&(this.markUsedOrientation(h,f,p),this.placedOrientations[p.crossTileID]=f),{shift:y,placedGlyphBoxes:v}):void 0},xe.prototype.placeLayerBucketPart=function(e,r,n){var i=this,o=e.parameters,a=o.bucket,s=o.layout,l=o.posMatrix,u=o.textLabelPlaneMatrix,c=o.labelToScreenMatrix,p=o.textPixelRatio,h=o.holdingForFade,f=o.collisionBoxArray,d=o.partiallyEvaluatedTextSize,m=o.collisionGroup,g=s.get("text-optional"),y=s.get("icon-optional"),v=s.get("text-allow-overlap"),_=s.get("icon-allow-overlap"),b="map"===s.get("text-rotation-alignment"),x="map"===s.get("text-pitch-alignment"),w="none"!==s.get("icon-text-fit"),E="viewport-y"===s.get("symbol-z-order"),T=v&&(_||!a.hasIconData()||y),A=_&&(v||!a.hasTextData()||g);!a.collisionArrays&&f&&a.deserializeCollisionBoxes(f);var C=function(e,o){if(!r[e.crossTileID])if(h)i.placements[e.crossTileID]=new me(!1,!1,!1);else{var f,E=!1,C=!1,S=!0,P=null,I={box:null,offscreen:null},D={box:null,offscreen:null},O=null,M=null,B=0,k=0,F=0;o.textFeatureIndex?B=o.textFeatureIndex:e.useRuntimeCollisionCircles&&(B=e.featureIndex),o.verticalTextFeatureIndex&&(k=o.verticalTextFeatureIndex);var L=o.textBox;if(L){var R=function(r){var n=t.WritingMode.horizontal;if(a.allowVerticalPlacement&&!r&&i.prevPlacement){var o=i.prevPlacement.placedOrientations[e.crossTileID];o&&(i.placedOrientations[e.crossTileID]=o,i.markUsedOrientation(a,n=o,e))}return n},z=function(r,n){if(a.allowVerticalPlacement&&e.numVerticalGlyphVertices>0&&o.verticalTextBox)for(var i=0,s=a.writingModes;i<s.length&&(s[i]===t.WritingMode.vertical?(I=n(),D=I):I=r(),!(I&&I.box&&I.box.length));i+=1);else I=r()};if(s.get("text-variable-anchor")){var N=s.get("text-variable-anchor");if(i.prevPlacement&&i.prevPlacement.variableOffsets[e.crossTileID]){var j=i.prevPlacement.variableOffsets[e.crossTileID];N.indexOf(j.anchor)>0&&(N=N.filter((function(t){return t!==j.anchor}))).unshift(j.anchor)}var U=function(t,r,n){for(var o=t.x2-t.x1,s=t.y2-t.y1,u=e.textBoxScale,c=w&&!_?r:null,h={box:[],offscreen:!1},f=v?2*N.length:N.length,d=0;d<f;++d){var g=i.attemptAnchorPlacement(N[d%N.length],t,o,s,u,b,x,p,l,m,d>=N.length,e,a,n,c);if(g&&(h=g.placedGlyphBoxes)&&h.box&&h.box.length){E=!0,P=g.shift;break}}return h};z((function(){return U(L,o.iconBox,t.WritingMode.horizontal)}),(function(){var r=o.verticalTextBox;return a.allowVerticalPlacement&&!(I&&I.box&&I.box.length)&&e.numVerticalGlyphVertices>0&&r?U(r,o.verticalIconBox,t.WritingMode.vertical):{box:null,offscreen:null}})),I&&(E=I.box,S=I.offscreen);var V=R(I&&I.box);if(!E&&i.prevPlacement){var q=i.prevPlacement.variableOffsets[e.crossTileID];q&&(i.variableOffsets[e.crossTileID]=q,i.markUsedJustification(a,q.anchor,e,V))}}else{var H=function(t,r){var n=i.collisionIndex.placeCollisionBox(t,v,p,l,m.predicate);return n&&n.box&&n.box.length&&(i.markUsedOrientation(a,r,e),i.placedOrientations[e.crossTileID]=r),n};z((function(){return H(L,t.WritingMode.horizontal)}),(function(){var r=o.verticalTextBox;return a.allowVerticalPlacement&&e.numVerticalGlyphVertices>0&&r?H(r,t.WritingMode.vertical):{box:null,offscreen:null}})),R(I&&I.box&&I.box.length)}}if(E=(f=I)&&f.box&&f.box.length>0,S=f&&f.offscreen,e.useRuntimeCollisionCircles){var G=a.text.placedSymbolArray.get(e.centerJustifiedTextSymbolIndex),Z=t.evaluateSizeForFeature(a.textSizeData,d,G),W=s.get("text-padding");O=i.collisionIndex.placeCollisionCircles(v,G,a.lineVertexArray,a.glyphOffsetArray,Z,l,u,c,n,x,m.predicate,e.collisionCircleDiameter,W),E=v||O.circles.length>0&&!O.collisionDetected,S=S&&O.offscreen}if(o.iconFeatureIndex&&(F=o.iconFeatureIndex),o.iconBox){var Y=function(t){var e=w&&P?be(t,P.x,P.y,b,x,i.transform.angle):t;return i.collisionIndex.placeCollisionBox(e,_,p,l,m.predicate)};C=D&&D.box&&D.box.length&&o.verticalIconBox?(M=Y(o.verticalIconBox)).box.length>0:(M=Y(o.iconBox)).box.length>0,S=S&&M.offscreen}var X=g||0===e.numHorizontalGlyphVertices&&0===e.numVerticalGlyphVertices,K=y||0===e.numIconVertices;if(X||K?K?X||(C=C&&E):E=C&&E:C=E=C&&E,E&&f&&f.box&&i.collisionIndex.insertCollisionBox(f.box,s.get("text-ignore-placement"),a.bucketInstanceId,D&&D.box&&k?k:B,m.ID),C&&M&&i.collisionIndex.insertCollisionBox(M.box,s.get("icon-ignore-placement"),a.bucketInstanceId,F,m.ID),O&&(E&&i.collisionIndex.insertCollisionCircles(O.circles,s.get("text-ignore-placement"),a.bucketInstanceId,B,m.ID),n)){var J=a.bucketInstanceId,Q=i.collisionCircleArrays[J];void 0===Q&&(Q=i.collisionCircleArrays[J]=new ge);for(var $=0;$<O.circles.length;$+=4)Q.circles.push(O.circles[$+0]),Q.circles.push(O.circles[$+1]),Q.circles.push(O.circles[$+2]),Q.circles.push(O.collisionDetected?1:0)}i.placements[e.crossTileID]=new me(E||T,C||A,S||a.justReloaded),r[e.crossTileID]=!0}};if(E)for(var S=a.getSortedSymbolIndexes(this.transform.angle),P=S.length-1;P>=0;--P){var I=S[P];C(a.symbolInstances.get(I),a.collisionArrays[I])}else for(var D=e.symbolInstanceStart;D<e.symbolInstanceEnd;D++)C(a.symbolInstances.get(D),a.collisionArrays[D]);if(n&&a.bucketInstanceId in this.collisionCircleArrays){var O=this.collisionCircleArrays[a.bucketInstanceId];t.invert(O.invProjMatrix,l),O.viewportMatrix=this.collisionIndex.getViewportMatrix()}a.justReloaded=!1},xe.prototype.markUsedJustification=function(e,r,n,i){var o;o=i===t.WritingMode.vertical?n.verticalPlacedTextSymbolIndex:{left:n.leftJustifiedTextSymbolIndex,center:n.centerJustifiedTextSymbolIndex,right:n.rightJustifiedTextSymbolIndex}[t.getAnchorJustification(r)];for(var a=0,s=[n.leftJustifiedTextSymbolIndex,n.centerJustifiedTextSymbolIndex,n.rightJustifiedTextSymbolIndex,n.verticalPlacedTextSymbolIndex];a<s.length;a+=1){var l=s[a];l>=0&&(e.text.placedSymbolArray.get(l).crossTileID=o>=0&&l!==o?0:n.crossTileID)}},xe.prototype.markUsedOrientation=function(e,r,n){for(var i=r===t.WritingMode.horizontal||r===t.WritingMode.horizontalOnly?r:0,o=r===t.WritingMode.vertical?r:0,a=0,s=[n.leftJustifiedTextSymbolIndex,n.centerJustifiedTextSymbolIndex,n.rightJustifiedTextSymbolIndex];a<s.length;a+=1)e.text.placedSymbolArray.get(s[a]).placedOrientation=i;n.verticalPlacedTextSymbolIndex&&(e.text.placedSymbolArray.get(n.verticalPlacedTextSymbolIndex).placedOrientation=o)},xe.prototype.commit=function(t){this.commitTime=t,this.zoomAtLastRecencyCheck=this.transform.zoom;var e=this.prevPlacement,r=!1;this.prevZoomAdjustment=e?e.zoomAdjustment(this.transform.zoom):0;var n=e?e.symbolFadeChange(t):1,i=e?e.opacities:{},o=e?e.variableOffsets:{},a=e?e.placedOrientations:{};for(var s in this.placements){var l=this.placements[s],u=i[s];u?(this.opacities[s]=new de(u,n,l.text,l.icon),r=r||l.text!==u.text.placed||l.icon!==u.icon.placed):(this.opacities[s]=new de(null,n,l.text,l.icon,l.skipFade),r=r||l.text||l.icon)}for(var c in i){var p=i[c];if(!this.opacities[c]){var h=new de(p,n,!1,!1);h.isHidden()||(this.opacities[c]=h,r=r||p.text.placed||p.icon.placed)}}for(var f in o)this.variableOffsets[f]||!this.opacities[f]||this.opacities[f].isHidden()||(this.variableOffsets[f]=o[f]);for(var d in a)this.placedOrientations[d]||!this.opacities[d]||this.opacities[d].isHidden()||(this.placedOrientations[d]=a[d]);r?this.lastPlacementChangeTime=t:"number"!=typeof this.lastPlacementChangeTime&&(this.lastPlacementChangeTime=e?e.lastPlacementChangeTime:t)},xe.prototype.updateLayerOpacities=function(t,e){for(var r={},n=0,i=e;n<i.length;n+=1){var o=i[n],a=o.getBucket(t);a&&o.latestFeatureIndex&&t.id===a.layerIds[0]&&this.updateBucketOpacities(a,r,o.collisionBoxArray)}},xe.prototype.updateBucketOpacities=function(e,r,n){var i=this;e.hasTextData()&&e.text.opacityVertexArray.clear(),e.hasIconData()&&e.icon.opacityVertexArray.clear(),e.hasIconCollisionBoxData()&&e.iconCollisionBox.collisionVertexArray.clear(),e.hasTextCollisionBoxData()&&e.textCollisionBox.collisionVertexArray.clear();var o=e.layers[0].layout,a=new de(null,0,!1,!1,!0),s=o.get("text-allow-overlap"),l=o.get("icon-allow-overlap"),u=o.get("text-variable-anchor"),c="map"===o.get("text-rotation-alignment"),p="map"===o.get("text-pitch-alignment"),h="none"!==o.get("icon-text-fit"),f=new de(null,0,s&&(l||!e.hasIconData()||o.get("icon-optional")),l&&(s||!e.hasTextData()||o.get("text-optional")),!0);!e.collisionArrays&&n&&(e.hasIconCollisionBoxData()||e.hasTextCollisionBoxData())&&e.deserializeCollisionBoxes(n);for(var d=function(t,e,r){for(var n=0;n<e/4;n++)t.opacityVertexArray.emplaceBack(r)},m=function(n){var o=e.symbolInstances.get(n),s=o.numHorizontalGlyphVertices,l=o.numVerticalGlyphVertices,m=o.crossTileID,g=i.opacities[m];r[m]?g=a:g||(i.opacities[m]=g=f),r[m]=!0;var y=o.numIconVertices>0,v=i.placedOrientations[o.crossTileID],_=v===t.WritingMode.vertical,b=v===t.WritingMode.horizontal||v===t.WritingMode.horizontalOnly;if(s>0||l>0){var x=De(g.text);d(e.text,s,_?Oe:x),d(e.text,l,b?Oe:x);var w=g.text.isHidden();[o.rightJustifiedTextSymbolIndex,o.centerJustifiedTextSymbolIndex,o.leftJustifiedTextSymbolIndex].forEach((function(t){t>=0&&(e.text.placedSymbolArray.get(t).hidden=w||_?1:0)})),o.verticalPlacedTextSymbolIndex>=0&&(e.text.placedSymbolArray.get(o.verticalPlacedTextSymbolIndex).hidden=w||b?1:0);var E=i.variableOffsets[o.crossTileID];E&&i.markUsedJustification(e,E.anchor,o,v);var T=i.placedOrientations[o.crossTileID];T&&(i.markUsedJustification(e,"left",o,T),i.markUsedOrientation(e,T,o))}if(y){var A=De(g.icon),C=!(h&&o.verticalPlacedIconSymbolIndex&&_);o.placedIconSymbolIndex>=0&&(d(e.icon,o.numIconVertices,C?A:Oe),e.icon.placedSymbolArray.get(o.placedIconSymbolIndex).hidden=g.icon.isHidden()),o.verticalPlacedIconSymbolIndex>=0&&(d(e.icon,o.numVerticalIconVertices,C?Oe:A),e.icon.placedSymbolArray.get(o.verticalPlacedIconSymbolIndex).hidden=g.icon.isHidden())}if(e.hasIconCollisionBoxData()||e.hasTextCollisionBoxData()){var S=e.collisionArrays[n];if(S){var P=new t.Point(0,0);if(S.textBox||S.verticalTextBox){var I=!0;if(u){var D=i.variableOffsets[m];D?(P=_e(D.anchor,D.width,D.height,D.textOffset,D.textBoxScale),c&&P._rotate(p?i.transform.angle:-i.transform.angle)):I=!1}S.textBox&&we(e.textCollisionBox.collisionVertexArray,g.text.placed,!I||_,P.x,P.y),S.verticalTextBox&&we(e.textCollisionBox.collisionVertexArray,g.text.placed,!I||b,P.x,P.y)}var O=Boolean(!b&&S.verticalIconBox);S.iconBox&&we(e.iconCollisionBox.collisionVertexArray,g.icon.placed,O,h?P.x:0,h?P.y:0),S.verticalIconBox&&we(e.iconCollisionBox.collisionVertexArray,g.icon.placed,!O,h?P.x:0,h?P.y:0)}}},g=0;g<e.symbolInstances.length;g++)m(g);if(e.sortFeatures(this.transform.angle),this.retainedQueryData[e.bucketInstanceId]&&(this.retainedQueryData[e.bucketInstanceId].featureSortOrder=e.featureSortOrder),e.hasTextData()&&e.text.opacityVertexBuffer&&e.text.opacityVertexBuffer.updateData(e.text.opacityVertexArray),e.hasIconData()&&e.icon.opacityVertexBuffer&&e.icon.opacityVertexBuffer.updateData(e.icon.opacityVertexArray),e.hasIconCollisionBoxData()&&e.iconCollisionBox.collisionVertexBuffer&&e.iconCollisionBox.collisionVertexBuffer.updateData(e.iconCollisionBox.collisionVertexArray),e.hasTextCollisionBoxData()&&e.textCollisionBox.collisionVertexBuffer&&e.textCollisionBox.collisionVertexBuffer.updateData(e.textCollisionBox.collisionVertexArray),e.bucketInstanceId in this.collisionCircleArrays){var y=this.collisionCircleArrays[e.bucketInstanceId];e.placementInvProjMatrix=y.invProjMatrix,e.placementViewportMatrix=y.viewportMatrix,e.collisionCircleArray=y.circles,delete this.collisionCircleArrays[e.bucketInstanceId]}},xe.prototype.symbolFadeChange=function(t){return 0===this.fadeDuration?1:(t-this.commitTime)/this.fadeDuration+this.prevZoomAdjustment},xe.prototype.zoomAdjustment=function(t){return Math.max(0,(this.transform.zoom-t)/1.5)},xe.prototype.hasTransitions=function(t){return this.stale||t-this.lastPlacementChangeTime<this.fadeDuration},xe.prototype.stillRecent=function(t,e){var r=this.zoomAtLastRecencyCheck===e?1-this.zoomAdjustment(e):1;return this.zoomAtLastRecencyCheck=e,this.commitTime+this.fadeDuration*r>t},xe.prototype.setStale=function(){this.stale=!0};var Ee=Math.pow(2,25),Te=Math.pow(2,24),Ae=Math.pow(2,17),Ce=Math.pow(2,16),Se=Math.pow(2,9),Pe=Math.pow(2,8),Ie=Math.pow(2,1);function De(t){if(0===t.opacity&&!t.placed)return 0;if(1===t.opacity&&t.placed)return 4294967295;var e=t.placed?1:0,r=Math.floor(127*t.opacity);return r*Ee+e*Te+r*Ae+e*Ce+r*Se+e*Pe+r*Ie+e}var Oe=0,Me=function(t){this._sortAcrossTiles="viewport-y"!==t.layout.get("symbol-z-order")&&void 0!==t.layout.get("symbol-sort-key").constantOr(1),this._currentTileIndex=0,this._currentPartIndex=0,this._seenCrossTileIDs={},this._bucketParts=[]};Me.prototype.continuePlacement=function(t,e,r,n,i){for(var o=this._bucketParts;this._currentTileIndex<t.length;)if(e.getBucketParts(o,n,t[this._currentTileIndex],this._sortAcrossTiles),this._currentTileIndex++,i())return!0;for(this._sortAcrossTiles&&(this._sortAcrossTiles=!1,o.sort((function(t,e){return t.sortKey-e.sortKey})));this._currentPartIndex<o.length;)if(e.placeLayerBucketPart(o[this._currentPartIndex],this._seenCrossTileIDs,r),this._currentPartIndex++,i())return!0;return!1};var Be=function(t,e,r,n,i,o,a){this.placement=new xe(t,i,o,a),this._currentPlacementIndex=e.length-1,this._forceFullPlacement=r,this._showCollisionBoxes=n,this._done=!1};Be.prototype.isDone=function(){return this._done},Be.prototype.continuePlacement=function(e,r,n){for(var i=this,o=t.browser.now(),a=function(){var e=t.browser.now()-o;return!i._forceFullPlacement&&e>2};this._currentPlacementIndex>=0;){var s=r[e[this._currentPlacementIndex]],l=this.placement.collisionIndex.transform.zoom;if("symbol"===s.type&&(!s.minzoom||s.minzoom<=l)&&(!s.maxzoom||s.maxzoom>l)){if(this._inProgressLayer||(this._inProgressLayer=new Me(s)),this._inProgressLayer.continuePlacement(n[s.source],this.placement,this._showCollisionBoxes,s,a))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0},Be.prototype.commit=function(t){return this.placement.commit(t),this.placement};var ke=512/t.EXTENT/2,Fe=function(t,e,r){this.tileID=t,this.indexedSymbolInstances={},this.bucketInstanceId=r;for(var n=0;n<e.length;n++){var i=e.get(n),o=i.key;this.indexedSymbolInstances[o]||(this.indexedSymbolInstances[o]=[]),this.indexedSymbolInstances[o].push({crossTileID:i.crossTileID,coord:this.getScaledCoordinates(i,t)})}};Fe.prototype.getScaledCoordinates=function(e,r){var n=ke/Math.pow(2,r.canonical.z-this.tileID.canonical.z);return{x:Math.floor((r.canonical.x*t.EXTENT+e.anchorX)*n),y:Math.floor((r.canonical.y*t.EXTENT+e.anchorY)*n)}},Fe.prototype.findMatches=function(t,e,r){for(var n=this.tileID.canonical.z<e.canonical.z?1:Math.pow(2,this.tileID.canonical.z-e.canonical.z),i=0;i<t.length;i++){var o=t.get(i);if(!o.crossTileID){var a=this.indexedSymbolInstances[o.key];if(a)for(var s=this.getScaledCoordinates(o,e),l=0,u=a;l<u.length;l+=1){var c=u[l];if(Math.abs(c.coord.x-s.x)<=n&&Math.abs(c.coord.y-s.y)<=n&&!r[c.crossTileID]){r[c.crossTileID]=!0,o.crossTileID=c.crossTileID;break}}}}};var Le=function(){this.maxCrossTileID=0};Le.prototype.generate=function(){return++this.maxCrossTileID};var Re=function(){this.indexes={},this.usedCrossTileIDs={},this.lng=0};Re.prototype.handleWrapJump=function(t){var e=Math.round((t-this.lng)/360);if(0!==e)for(var r in this.indexes){var n=this.indexes[r],i={};for(var o in n){var a=n[o];a.tileID=a.tileID.unwrapTo(a.tileID.wrap+e),i[a.tileID.key]=a}this.indexes[r]=i}this.lng=t},Re.prototype.addBucket=function(t,e,r){if(this.indexes[t.overscaledZ]&&this.indexes[t.overscaledZ][t.key]){if(this.indexes[t.overscaledZ][t.key].bucketInstanceId===e.bucketInstanceId)return!1;this.removeBucketCrossTileIDs(t.overscaledZ,this.indexes[t.overscaledZ][t.key])}for(var n=0;n<e.symbolInstances.length;n++)e.symbolInstances.get(n).crossTileID=0;this.usedCrossTileIDs[t.overscaledZ]||(this.usedCrossTileIDs[t.overscaledZ]={});var i=this.usedCrossTileIDs[t.overscaledZ];for(var o in this.indexes){var a=this.indexes[o];if(Number(o)>t.overscaledZ)for(var s in a){var l=a[s];l.tileID.isChildOf(t)&&l.findMatches(e.symbolInstances,t,i)}else{var u=a[t.scaledTo(Number(o)).key];u&&u.findMatches(e.symbolInstances,t,i)}}for(var c=0;c<e.symbolInstances.length;c++){var p=e.symbolInstances.get(c);p.crossTileID||(p.crossTileID=r.generate(),i[p.crossTileID]=!0)}return void 0===this.indexes[t.overscaledZ]&&(this.indexes[t.overscaledZ]={}),this.indexes[t.overscaledZ][t.key]=new Fe(t,e.symbolInstances,e.bucketInstanceId),!0},Re.prototype.removeBucketCrossTileIDs=function(t,e){for(var r in e.indexedSymbolInstances)for(var n=0,i=e.indexedSymbolInstances[r];n<i.length;n+=1)delete this.usedCrossTileIDs[t][i[n].crossTileID]},Re.prototype.removeStaleBuckets=function(t){var e=!1;for(var r in this.indexes){var n=this.indexes[r];for(var i in n)t[n[i].bucketInstanceId]||(this.removeBucketCrossTileIDs(r,n[i]),delete n[i],e=!0)}return e};var ze=function(){this.layerIndexes={},this.crossTileIDs=new Le,this.maxBucketInstanceId=0,this.bucketsInCurrentPlacement={}};ze.prototype.addLayer=function(t,e,r){var n=this.layerIndexes[t.id];void 0===n&&(n=this.layerIndexes[t.id]=new Re);var i=!1,o={};n.handleWrapJump(r);for(var a=0,s=e;a<s.length;a+=1){var l=s[a],u=l.getBucket(t);u&&t.id===u.layerIds[0]&&(u.bucketInstanceId||(u.bucketInstanceId=++this.maxBucketInstanceId),n.addBucket(l.tileID,u,this.crossTileIDs)&&(i=!0),o[u.bucketInstanceId]=!0)}return n.removeStaleBuckets(o)&&(i=!0),i},ze.prototype.pruneUnusedLayers=function(t){var e={};for(var r in t.forEach((function(t){e[t]=!0})),this.layerIndexes)e[r]||delete this.layerIndexes[r]};var Ne=function(e,r){return t.emitValidationErrors(e,r&&r.filter((function(t){return"source.canvas"!==t.identifier})))},je=t.pick(Ut,["addLayer","removeLayer","setPaintProperty","setLayoutProperty","setFilter","addSource","removeSource","setLayerZoomRange","setLight","setTransition","setGeoJSONSourceData"]),Ue=t.pick(Ut,["setCenter","setZoom","setBearing","setPitch"]),Ve=function(){var e={},r=t.styleSpec.$version;for(var n in t.styleSpec.$root){var i,o=t.styleSpec.$root[n];o.required&&null!=(i="version"===n?r:"array"===o.type?[]:{})&&(e[n]=i)}return e}(),qe=function(e){function r(n,i){var o=this;void 0===i&&(i={}),e.call(this),this.map=n,this.dispatcher=new T(zt(),this),this.imageManager=new h,this.imageManager.setEventedParent(this),this.glyphManager=new _(n._requestManager,i.localIdeographFontFamily),this.lineAtlas=new E(256,512),this.crossTileSymbolIndex=new ze,this._layers={},this._serializedLayers={},this._order=[],this.sourceCaches={},this.zoomHistory=new t.ZoomHistory,this._loaded=!1,this._availableImages=[],this._resetUpdates(),this.dispatcher.broadcast("setReferrer",t.getReferrer());var a=this;this._rtlTextPluginCallback=r.registerForPluginStateChange((function(e){a.dispatcher.broadcast("syncRTLPluginState",{pluginStatus:e.pluginStatus,pluginURL:e.pluginURL},(function(e,r){if(t.triggerPluginCompletionEvent(e),r&&r.every((function(t){return t})))for(var n in a.sourceCaches)a.sourceCaches[n].reload()}))})),this.on("data",(function(t){if("source"===t.dataType&&"metadata"===t.sourceDataType){var e=o.sourceCaches[t.sourceId];if(e){var r=e.getSource();if(r&&r.vectorLayerIds)for(var n in o._layers){var i=o._layers[n];i.source===r.id&&o._validateLayer(i)}}}}))}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.loadURL=function(e,r){var n=this;void 0===r&&(r={}),this.fire(new t.Event("dataloading",{dataType:"style"}));var i="boolean"==typeof r.validate?r.validate:!t.isMapboxURL(e);e=this.map._requestManager.normalizeStyleURL(e,r.accessToken);var o=this.map._requestManager.transformRequest(e,t.ResourceType.Style);this._request=t.getJSON(o,(function(e,r){n._request=null,e?n.fire(new t.ErrorEvent(e)):r&&n._load(r,i)}))},r.prototype.loadJSON=function(e,r){var n=this;void 0===r&&(r={}),this.fire(new t.Event("dataloading",{dataType:"style"})),this._request=t.browser.frame((function(){n._request=null,n._load(e,!1!==r.validate)}))},r.prototype.loadEmpty=function(){this.fire(new t.Event("dataloading",{dataType:"style"})),this._load(Ve,!1)},r.prototype._load=function(e,r){if(!r||!Ne(this,t.validateStyle(e))){for(var n in this._loaded=!0,this.stylesheet=e,e.sources)this.addSource(n,e.sources[n],{validate:!1});e.sprite?this._loadSprite(e.sprite):this.imageManager.setLoaded(!0),this.glyphManager.setURL(e.glyphs);var i=jt(this.stylesheet.layers);this._order=i.map((function(t){return t.id})),this._layers={},this._serializedLayers={};for(var o=0,a=i;o<a.length;o+=1){var s=a[o];(s=t.createStyleLayer(s)).setEventedParent(this,{layer:{id:s.id}}),this._layers[s.id]=s,this._serializedLayers[s.id]=s.serialize()}this.dispatcher.broadcast("setLayers",this._serializeLayers(this._order)),this.light=new w(this.stylesheet.light),this.fire(new t.Event("data",{dataType:"style"})),this.fire(new t.Event("style.load"))}},r.prototype._loadSprite=function(e){var r=this;this._spriteRequest=function(e,r,n){var i,o,a,s=t.browser.devicePixelRatio>1?"@2x":"",l=t.getJSON(r.transformRequest(r.normalizeSpriteURL(e,s,".json"),t.ResourceType.SpriteJSON),(function(t,e){l=null,a||(a=t,i=e,c())})),u=t.getImage(r.transformRequest(r.normalizeSpriteURL(e,s,".png"),t.ResourceType.SpriteImage),(function(t,e){u=null,a||(a=t,o=e,c())}));function c(){if(a)n(a);else if(i&&o){var e=t.browser.getImageData(o),r={};for(var s in i){var l=i[s],u=l.width,c=l.height,p=l.x,h=l.y,f=l.sdf,d=l.pixelRatio,m=l.stretchX,g=l.stretchY,y=l.content,v=new t.RGBAImage({width:u,height:c});t.RGBAImage.copy(e,v,{x:p,y:h},{x:0,y:0},{width:u,height:c}),r[s]={data:v,pixelRatio:d,sdf:f,stretchX:m,stretchY:g,content:y}}n(null,r)}}return{cancel:function(){l&&(l.cancel(),l=null),u&&(u.cancel(),u=null)}}}(e,this.map._requestManager,(function(e,n){if(r._spriteRequest=null,e)r.fire(new t.ErrorEvent(e));else if(n)for(var i in n)r.imageManager.addImage(i,n[i]);r.imageManager.setLoaded(!0),r._availableImages=r.imageManager.listImages(),r.dispatcher.broadcast("setImages",r._availableImages),r.fire(new t.Event("data",{dataType:"style"}))}))},r.prototype._validateLayer=function(e){var r=this.sourceCaches[e.source];if(r){var n=e.sourceLayer;if(n){var i=r.getSource();("geojson"===i.type||i.vectorLayerIds&&-1===i.vectorLayerIds.indexOf(n))&&this.fire(new t.ErrorEvent(new Error('Source layer "'+n+'" does not exist on source "'+i.id+'" as specified by style layer "'+e.id+'"')))}}},r.prototype.loaded=function(){if(!this._loaded)return!1;if(Object.keys(this._updatedSources).length)return!1;for(var t in this.sourceCaches)if(!this.sourceCaches[t].loaded())return!1;return!!this.imageManager.isLoaded()},r.prototype._serializeLayers=function(t){for(var e=[],r=0,n=t;r<n.length;r+=1){var i=this._layers[n[r]];"custom"!==i.type&&e.push(i.serialize())}return e},r.prototype.hasTransitions=function(){if(this.light&&this.light.hasTransition())return!0;for(var t in this.sourceCaches)if(this.sourceCaches[t].hasTransition())return!0;for(var e in this._layers)if(this._layers[e].hasTransition())return!0;return!1},r.prototype._checkLoaded=function(){if(!this._loaded)throw new Error("Style is not done loading")},r.prototype.update=function(e){if(this._loaded){var r=this._changed;if(this._changed){var n=Object.keys(this._updatedLayers),i=Object.keys(this._removedLayers);for(var o in(n.length||i.length)&&this._updateWorkerLayers(n,i),this._updatedSources){var a=this._updatedSources[o];"reload"===a?this._reloadSource(o):"clear"===a&&this._clearSource(o)}for(var s in this._updateTilesForChangedImages(),this._updatedPaintProps)this._layers[s].updateTransitions(e);this.light.updateTransitions(e),this._resetUpdates()}var l={};for(var u in this.sourceCaches){var c=this.sourceCaches[u];l[u]=c.used,c.used=!1}for(var p=0,h=this._order;p<h.length;p+=1){var f=this._layers[h[p]];f.recalculate(e,this._availableImages),!f.isHidden(e.zoom)&&f.source&&(this.sourceCaches[f.source].used=!0)}for(var d in l){var m=this.sourceCaches[d];l[d]!==m.used&&m.fire(new t.Event("data",{sourceDataType:"visibility",dataType:"source",sourceId:d}))}this.light.recalculate(e),this.z=e.zoom,r&&this.fire(new t.Event("data",{dataType:"style"}))}},r.prototype._updateTilesForChangedImages=function(){var t=Object.keys(this._changedImages);if(t.length){for(var e in this.sourceCaches)this.sourceCaches[e].reloadTilesForDependencies(["icons","patterns"],t);this._changedImages={}}},r.prototype._updateWorkerLayers=function(t,e){this.dispatcher.broadcast("updateLayers",{layers:this._serializeLayers(t),removedIds:e})},r.prototype._resetUpdates=function(){this._changed=!1,this._updatedLayers={},this._removedLayers={},this._updatedSources={},this._updatedPaintProps={},this._changedImages={}},r.prototype.setState=function(e){var r=this;if(this._checkLoaded(),Ne(this,t.validateStyle(e)))return!1;(e=t.clone$1(e)).layers=jt(e.layers);var n=function(e,r){if(!e)return[{command:Ut.setStyle,args:[r]}];var n=[];try{if(!t.deepEqual(e.version,r.version))return[{command:Ut.setStyle,args:[r]}];t.deepEqual(e.center,r.center)||n.push({command:Ut.setCenter,args:[r.center]}),t.deepEqual(e.zoom,r.zoom)||n.push({command:Ut.setZoom,args:[r.zoom]}),t.deepEqual(e.bearing,r.bearing)||n.push({command:Ut.setBearing,args:[r.bearing]}),t.deepEqual(e.pitch,r.pitch)||n.push({command:Ut.setPitch,args:[r.pitch]}),t.deepEqual(e.sprite,r.sprite)||n.push({command:Ut.setSprite,args:[r.sprite]}),t.deepEqual(e.glyphs,r.glyphs)||n.push({command:Ut.setGlyphs,args:[r.glyphs]}),t.deepEqual(e.transition,r.transition)||n.push({command:Ut.setTransition,args:[r.transition]}),t.deepEqual(e.light,r.light)||n.push({command:Ut.setLight,args:[r.light]});var i={},o=[];!function(e,r,n,i){var o;for(o in r=r||{},e=e||{})e.hasOwnProperty(o)&&(r.hasOwnProperty(o)||qt(o,n,i));for(o in r)r.hasOwnProperty(o)&&(e.hasOwnProperty(o)?t.deepEqual(e[o],r[o])||("geojson"===e[o].type&&"geojson"===r[o].type&&Gt(e,r,o)?n.push({command:Ut.setGeoJSONSourceData,args:[o,r[o].data]}):Ht(o,r,n,i)):Vt(o,r,n))}(e.sources,r.sources,o,i);var a=[];e.layers&&e.layers.forEach((function(t){i[t.source]?n.push({command:Ut.removeLayer,args:[t.id]}):a.push(t)})),n=n.concat(o),function(e,r,n){r=r||[];var i,o,a,s,l,u,c,p=(e=e||[]).map(Wt),h=r.map(Wt),f=e.reduce(Yt,{}),d=r.reduce(Yt,{}),m=p.slice(),g=Object.create(null);for(i=0,o=0;i<p.length;i++)d.hasOwnProperty(a=p[i])?o++:(n.push({command:Ut.removeLayer,args:[a]}),m.splice(m.indexOf(a,o),1));for(i=0,o=0;i<h.length;i++)m[m.length-1-i]!==(a=h[h.length-1-i])&&(f.hasOwnProperty(a)?(n.push({command:Ut.removeLayer,args:[a]}),m.splice(m.lastIndexOf(a,m.length-o),1)):o++,n.push({command:Ut.addLayer,args:[d[a],u=m[m.length-i]]}),m.splice(m.length-i,0,a),g[a]=!0);for(i=0;i<h.length;i++)if(s=f[a=h[i]],l=d[a],!g[a]&&!t.deepEqual(s,l))if(t.deepEqual(s.source,l.source)&&t.deepEqual(s["source-layer"],l["source-layer"])&&t.deepEqual(s.type,l.type)){for(c in Zt(s.layout,l.layout,n,a,null,Ut.setLayoutProperty),Zt(s.paint,l.paint,n,a,null,Ut.setPaintProperty),t.deepEqual(s.filter,l.filter)||n.push({command:Ut.setFilter,args:[a,l.filter]}),t.deepEqual(s.minzoom,l.minzoom)&&t.deepEqual(s.maxzoom,l.maxzoom)||n.push({command:Ut.setLayerZoomRange,args:[a,l.minzoom,l.maxzoom]}),s)s.hasOwnProperty(c)&&"layout"!==c&&"paint"!==c&&"filter"!==c&&"metadata"!==c&&"minzoom"!==c&&"maxzoom"!==c&&(0===c.indexOf("paint.")?Zt(s[c],l[c],n,a,c.slice(6),Ut.setPaintProperty):t.deepEqual(s[c],l[c])||n.push({command:Ut.setLayerProperty,args:[a,c,l[c]]}));for(c in l)l.hasOwnProperty(c)&&!s.hasOwnProperty(c)&&"layout"!==c&&"paint"!==c&&"filter"!==c&&"metadata"!==c&&"minzoom"!==c&&"maxzoom"!==c&&(0===c.indexOf("paint.")?Zt(s[c],l[c],n,a,c.slice(6),Ut.setPaintProperty):t.deepEqual(s[c],l[c])||n.push({command:Ut.setLayerProperty,args:[a,c,l[c]]}))}else n.push({command:Ut.removeLayer,args:[a]}),u=m[m.lastIndexOf(a)+1],n.push({command:Ut.addLayer,args:[l,u]})}(a,r.layers,n)}catch(t){console.warn("Unable to compute style diff:",t),n=[{command:Ut.setStyle,args:[r]}]}return n}(this.serialize(),e).filter((function(t){return!(t.command in Ue)}));if(0===n.length)return!1;var i=n.filter((function(t){return!(t.command in je)}));if(i.length>0)throw new Error("Unimplemented: "+i.map((function(t){return t.command})).join(", ")+".");return n.forEach((function(t){"setTransition"!==t.command&&r[t.command].apply(r,t.args)})),this.stylesheet=e,!0},r.prototype.addImage=function(e,r){if(this.getImage(e))return this.fire(new t.ErrorEvent(new Error("An image with this name already exists.")));this.imageManager.addImage(e,r),this._afterImageUpdated(e)},r.prototype.updateImage=function(t,e){this.imageManager.updateImage(t,e)},r.prototype.getImage=function(t){return this.imageManager.getImage(t)},r.prototype.removeImage=function(e){if(!this.getImage(e))return this.fire(new t.ErrorEvent(new Error("No image with this name exists.")));this.imageManager.removeImage(e),this._afterImageUpdated(e)},r.prototype._afterImageUpdated=function(e){this._availableImages=this.imageManager.listImages(),this._changedImages[e]=!0,this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new t.Event("data",{dataType:"style"}))},r.prototype.listImages=function(){return this._checkLoaded(),this.imageManager.listImages()},r.prototype.addSource=function(e,r,n){var i=this;if(void 0===n&&(n={}),this._checkLoaded(),void 0!==this.sourceCaches[e])throw new Error("There is already a source with this ID");if(!r.type)throw new Error("The type property must be defined, but only the following properties were given: "+Object.keys(r).join(", ")+".");if(!(["vector","raster","geojson","video","image"].indexOf(r.type)>=0&&this._validate(t.validateStyle.source,"sources."+e,r,null,n))){this.map&&this.map._collectResourceTiming&&(r.collectResourceTiming=!0);var o=this.sourceCaches[e]=new Dt(e,r,this.dispatcher);o.style=this,o.setEventedParent(this,(function(){return{isSourceLoaded:i.loaded(),source:o.serialize(),sourceId:e}})),o.onAdd(this.map),this._changed=!0}},r.prototype.removeSource=function(e){if(this._checkLoaded(),void 0===this.sourceCaches[e])throw new Error("There is no source with this ID");for(var r in this._layers)if(this._layers[r].source===e)return this.fire(new t.ErrorEvent(new Error('Source "'+e+'" cannot be removed while layer "'+r+'" is using it.')));var n=this.sourceCaches[e];delete this.sourceCaches[e],delete this._updatedSources[e],n.fire(new t.Event("data",{sourceDataType:"metadata",dataType:"source",sourceId:e})),n.setEventedParent(null),n.clearTiles(),n.onRemove&&n.onRemove(this.map),this._changed=!0},r.prototype.setGeoJSONSourceData=function(t,e){this._checkLoaded(),this.sourceCaches[t].getSource().setData(e),this._changed=!0},r.prototype.getSource=function(t){return this.sourceCaches[t]&&this.sourceCaches[t].getSource()},r.prototype.addLayer=function(e,r,n){void 0===n&&(n={}),this._checkLoaded();var i=e.id;if(this.getLayer(i))this.fire(new t.ErrorEvent(new Error('Layer with id "'+i+'" already exists on this map')));else{var o;if("custom"===e.type){if(Ne(this,t.validateCustomStyleLayer(e)))return;o=t.createStyleLayer(e)}else{if("object"==typeof e.source&&(this.addSource(i,e.source),e=t.clone$1(e),e=t.extend(e,{source:i})),this._validate(t.validateStyle.layer,"layers."+i,e,{arrayIndex:-1},n))return;o=t.createStyleLayer(e),this._validateLayer(o),o.setEventedParent(this,{layer:{id:i}}),this._serializedLayers[o.id]=o.serialize()}var a=r?this._order.indexOf(r):this._order.length;if(r&&-1===a)this.fire(new t.ErrorEvent(new Error('Layer with id "'+r+'" does not exist on this map.')));else{if(this._order.splice(a,0,i),this._layerOrderChanged=!0,this._layers[i]=o,this._removedLayers[i]&&o.source&&"custom"!==o.type){var s=this._removedLayers[i];delete this._removedLayers[i],s.type!==o.type?this._updatedSources[o.source]="clear":(this._updatedSources[o.source]="reload",this.sourceCaches[o.source].pause())}this._updateLayer(o),o.onAdd&&o.onAdd(this.map)}}},r.prototype.moveLayer=function(e,r){if(this._checkLoaded(),this._changed=!0,this._layers[e]){if(e!==r){var n=this._order.indexOf(e);this._order.splice(n,1);var i=r?this._order.indexOf(r):this._order.length;r&&-1===i?this.fire(new t.ErrorEvent(new Error('Layer with id "'+r+'" does not exist on this map.'))):(this._order.splice(i,0,e),this._layerOrderChanged=!0)}}else this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style and cannot be moved.")))},r.prototype.removeLayer=function(e){this._checkLoaded();var r=this._layers[e];if(r){r.setEventedParent(null);var n=this._order.indexOf(e);this._order.splice(n,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[e]=r,delete this._layers[e],delete this._serializedLayers[e],delete this._updatedLayers[e],delete this._updatedPaintProps[e],r.onRemove&&r.onRemove(this.map)}else this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style and cannot be removed.")))},r.prototype.getLayer=function(t){return this._layers[t]},r.prototype.hasLayer=function(t){return t in this._layers},r.prototype.setLayerZoomRange=function(e,r,n){this._checkLoaded();var i=this.getLayer(e);i?i.minzoom===r&&i.maxzoom===n||(null!=r&&(i.minzoom=r),null!=n&&(i.maxzoom=n),this._updateLayer(i)):this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style and cannot have zoom extent.")))},r.prototype.setFilter=function(e,r,n){void 0===n&&(n={}),this._checkLoaded();var i=this.getLayer(e);if(i){if(!t.deepEqual(i.filter,r))return null==r?(i.filter=void 0,void this._updateLayer(i)):void(this._validate(t.validateStyle.filter,"layers."+i.id+".filter",r,null,n)||(i.filter=t.clone$1(r),this._updateLayer(i)))}else this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style and cannot be filtered.")))},r.prototype.getFilter=function(e){return t.clone$1(this.getLayer(e).filter)},r.prototype.setLayoutProperty=function(e,r,n,i){void 0===i&&(i={}),this._checkLoaded();var o=this.getLayer(e);o?t.deepEqual(o.getLayoutProperty(r),n)||(o.setLayoutProperty(r,n,i),this._updateLayer(o)):this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style and cannot be styled.")))},r.prototype.getLayoutProperty=function(e,r){var n=this.getLayer(e);if(n)return n.getLayoutProperty(r);this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style.")))},r.prototype.setPaintProperty=function(e,r,n,i){void 0===i&&(i={}),this._checkLoaded();var o=this.getLayer(e);o?t.deepEqual(o.getPaintProperty(r),n)||(o.setPaintProperty(r,n,i)&&this._updateLayer(o),this._changed=!0,this._updatedPaintProps[e]=!0):this.fire(new t.ErrorEvent(new Error("The layer '"+e+"' does not exist in the map's style and cannot be styled.")))},r.prototype.getPaintProperty=function(t,e){return this.getLayer(t).getPaintProperty(e)},r.prototype.setFeatureState=function(e,r){this._checkLoaded();var n=e.source,i=e.sourceLayer,o=this.sourceCaches[n];if(void 0!==o){var a=o.getSource().type;"geojson"===a&&i?this.fire(new t.ErrorEvent(new Error("GeoJSON sources cannot have a sourceLayer parameter."))):"vector"!==a||i?(void 0===e.id&&this.fire(new t.ErrorEvent(new Error("The feature id parameter must be provided."))),o.setFeatureState(i,e.id,r)):this.fire(new t.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new t.ErrorEvent(new Error("The source '"+n+"' does not exist in the map's style.")))},r.prototype.removeFeatureState=function(e,r){this._checkLoaded();var n=e.source,i=this.sourceCaches[n];if(void 0!==i){var o=i.getSource().type,a="vector"===o?e.sourceLayer:void 0;"vector"!==o||a?r&&"string"!=typeof e.id&&"number"!=typeof e.id?this.fire(new t.ErrorEvent(new Error("A feature id is required to remove its specific state property."))):i.removeFeatureState(a,e.id,r):this.fire(new t.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new t.ErrorEvent(new Error("The source '"+n+"' does not exist in the map's style.")))},r.prototype.getFeatureState=function(e){this._checkLoaded();var r=e.source,n=e.sourceLayer,i=this.sourceCaches[r];if(void 0!==i){if("vector"!==i.getSource().type||n)return void 0===e.id&&this.fire(new t.ErrorEvent(new Error("The feature id parameter must be provided."))),i.getFeatureState(n,e.id);this.fire(new t.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new t.ErrorEvent(new Error("The source '"+r+"' does not exist in the map's style.")))},r.prototype.getTransition=function(){return t.extend({duration:300,delay:0},this.stylesheet&&this.stylesheet.transition)},r.prototype.serialize=function(){return t.filterObject({version:this.stylesheet.version,name:this.stylesheet.name,metadata:this.stylesheet.metadata,light:this.stylesheet.light,center:this.stylesheet.center,zoom:this.stylesheet.zoom,bearing:this.stylesheet.bearing,pitch:this.stylesheet.pitch,sprite:this.stylesheet.sprite,glyphs:this.stylesheet.glyphs,transition:this.stylesheet.transition,sources:t.mapObject(this.sourceCaches,(function(t){return t.serialize()})),layers:this._serializeLayers(this._order)},(function(t){return void 0!==t}))},r.prototype._updateLayer=function(t){this._updatedLayers[t.id]=!0,t.source&&!this._updatedSources[t.source]&&"raster"!==this.sourceCaches[t.source].getSource().type&&(this._updatedSources[t.source]="reload",this.sourceCaches[t.source].pause()),this._changed=!0},r.prototype._flattenAndSortRenderedFeatures=function(t){for(var e=this,r=function(t){return"fill-extrusion"===e._layers[t].type},n={},i=[],o=this._order.length-1;o>=0;o--){var a=this._order[o];if(r(a)){n[a]=o;for(var s=0,l=t;s<l.length;s+=1){var u=l[s][a];if(u)for(var c=0,p=u;c<p.length;c+=1)i.push(p[c])}}}i.sort((function(t,e){return e.intersectionZ-t.intersectionZ}));for(var h=[],f=this._order.length-1;f>=0;f--){var d=this._order[f];if(r(d))for(var m=i.length-1;m>=0;m--){var g=i[m].feature;if(n[g.layer.id]<f)break;h.push(g),i.pop()}else for(var y=0,v=t;y<v.length;y+=1){var _=v[y][d];if(_)for(var b=0,x=_;b<x.length;b+=1)h.push(x[b].feature)}}return h},r.prototype.queryRenderedFeatures=function(e,r,n){r&&r.filter&&this._validate(t.validateStyle.filter,"queryRenderedFeatures.filter",r.filter,null,r);var i={};if(r&&r.layers){if(!Array.isArray(r.layers))return this.fire(new t.ErrorEvent(new Error("parameters.layers must be an Array."))),[];for(var o=0,a=r.layers;o<a.length;o+=1){var s=a[o],l=this._layers[s];if(!l)return this.fire(new t.ErrorEvent(new Error("The layer '"+s+"' does not exist in the map's style and cannot be queried for features."))),[];i[l.source]=!0}}var u=[];for(var c in r.availableImages=this._availableImages,this.sourceCaches)r.layers&&!i[c]||u.push(R(this.sourceCaches[c],this._layers,this._serializedLayers,e,r,n));return this.placement&&u.push(function(t,e,r,n,i,o,a){for(var s={},l=o.queryRenderedSymbols(n),u=[],c=0,p=Object.keys(l).map(Number);c<p.length;c+=1)u.push(a[p[c]]);u.sort(z);for(var h=function(){var r=d[f],n=r.featureIndex.lookupSymbolFeatures(l[r.bucketInstanceId],e,r.bucketIndex,r.sourceLayerIndex,i.filter,i.layers,i.availableImages,t);for(var o in n){var a=s[o]=s[o]||[],u=n[o];u.sort((function(t,e){var n=r.featureSortOrder;if(n){var i=n.indexOf(t.featureIndex);return n.indexOf(e.featureIndex)-i}return e.featureIndex-t.featureIndex}));for(var c=0,p=u;c<p.length;c+=1)a.push(p[c])}},f=0,d=u;f<d.length;f+=1)h();var m=function(e){s[e].forEach((function(n){var i=n.feature,o=r[t[e].source].getFeatureState(i.layer["source-layer"],i.id);i.source=i.layer.source,i.layer["source-layer"]&&(i.sourceLayer=i.layer["source-layer"]),i.state=o}))};for(var g in s)m(g);return s}(this._layers,this._serializedLayers,this.sourceCaches,e,r,this.placement.collisionIndex,this.placement.retainedQueryData)),this._flattenAndSortRenderedFeatures(u)},r.prototype.querySourceFeatures=function(e,r){r&&r.filter&&this._validate(t.validateStyle.filter,"querySourceFeatures.filter",r.filter,null,r);var n=this.sourceCaches[e];return n?function(t,e){for(var r=t.getRenderableIds().map((function(e){return t.getTileByID(e)})),n=[],i={},o=0;o<r.length;o++){var a=r[o],s=a.tileID.canonical.key;i[s]||(i[s]=!0,a.querySourceFeatures(n,e))}return n}(n,r):[]},r.prototype.addSourceType=function(t,e,n){return r.getSourceType(t)?n(new Error('A source type called "'+t+'" already exists.')):(r.setSourceType(t,e),e.workerSourceURL?void this.dispatcher.broadcast("loadWorkerSource",{name:t,url:e.workerSourceURL},n):n(null,null))},r.prototype.getLight=function(){return this.light.getLight()},r.prototype.setLight=function(e,r){void 0===r&&(r={}),this._checkLoaded();var n=this.light.getLight(),i=!1;for(var o in e)if(!t.deepEqual(e[o],n[o])){i=!0;break}if(i){var a={now:t.browser.now(),transition:t.extend({duration:300,delay:0},this.stylesheet.transition)};this.light.setLight(e,r),this.light.updateTransitions(a)}},r.prototype._validate=function(e,r,n,i,o){return void 0===o&&(o={}),(!o||!1!==o.validate)&&Ne(this,e.call(t.validateStyle,t.extend({key:r,style:this.serialize(),value:n,styleSpec:t.styleSpec},i)))},r.prototype._remove=function(){for(var e in this._request&&(this._request.cancel(),this._request=null),this._spriteRequest&&(this._spriteRequest.cancel(),this._spriteRequest=null),t.evented.off("pluginStateChange",this._rtlTextPluginCallback),this._layers)this._layers[e].setEventedParent(null);for(var r in this.sourceCaches)this.sourceCaches[r].clearTiles(),this.sourceCaches[r].setEventedParent(null);this.imageManager.setEventedParent(null),this.setEventedParent(null),this.dispatcher.remove()},r.prototype._clearSource=function(t){this.sourceCaches[t].clearTiles()},r.prototype._reloadSource=function(t){this.sourceCaches[t].resume(),this.sourceCaches[t].reload()},r.prototype._updateSources=function(t){for(var e in this.sourceCaches)this.sourceCaches[e].update(t)},r.prototype._generateCollisionBoxes=function(){for(var t in this.sourceCaches)this._reloadSource(t)},r.prototype._updatePlacement=function(e,r,n,i,o){void 0===o&&(o=!1);for(var a=!1,s=!1,l={},u=0,c=this._order;u<c.length;u+=1){var p=this._layers[c[u]];if("symbol"===p.type){if(!l[p.source]){var h=this.sourceCaches[p.source];l[p.source]=h.getRenderableIds(!0).map((function(t){return h.getTileByID(t)})).sort((function(t,e){return e.tileID.overscaledZ-t.tileID.overscaledZ||(t.tileID.isLessThan(e.tileID)?-1:1)}))}var f=this.crossTileSymbolIndex.addLayer(p,l[p.source],e.center.lng);a=a||f}}if(this.crossTileSymbolIndex.pruneUnusedLayers(this._order),((o=o||this._layerOrderChanged||0===n)||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(t.browser.now(),e.zoom))&&(this.pauseablePlacement=new Be(e,this._order,o,r,n,i,this.placement),this._layerOrderChanged=!1),this.pauseablePlacement.isDone()?this.placement.setStale():(this.pauseablePlacement.continuePlacement(this._order,this._layers,l),this.pauseablePlacement.isDone()&&(this.placement=this.pauseablePlacement.commit(t.browser.now()),s=!0),a&&this.pauseablePlacement.placement.setStale()),s||a)for(var d=0,m=this._order;d<m.length;d+=1){var g=this._layers[m[d]];"symbol"===g.type&&this.placement.updateLayerOpacities(g,l[g.source])}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(t.browser.now())},r.prototype._releaseSymbolFadeTiles=function(){for(var t in this.sourceCaches)this.sourceCaches[t].releaseSymbolFadeTiles()},r.prototype.getImages=function(t,e,r){this.imageManager.getImages(e.icons,r),this._updateTilesForChangedImages();var n=this.sourceCaches[e.source];n&&n.setDependencies(e.tileID.key,e.type,e.icons)},r.prototype.getGlyphs=function(t,e,r){this.glyphManager.getGlyphs(e.stacks,r)},r.prototype.getResource=function(e,r,n){return t.makeRequest(r,n)},r}(t.Evented);qe.getSourceType=function(t){return F[t]},qe.setSourceType=function(t,e){F[t]=e},qe.registerForPluginStateChange=t.registerForPluginStateChange;var He=t.createLayout([{name:"a_pos",type:"Int16",components:2}]),Ge=yr("#ifdef GL_ES\nprecision mediump float;\n#else\n#if !defined(lowp)\n#define lowp\n#endif\n#if !defined(mediump)\n#define mediump\n#endif\n#if !defined(highp)\n#define highp\n#endif\n#endif","#ifdef GL_ES\nprecision highp float;\n#else\n#if !defined(lowp)\n#define lowp\n#endif\n#if !defined(mediump)\n#define mediump\n#endif\n#if !defined(highp)\n#define highp\n#endif\n#endif\nvec2 unpack_float(const float packedValue) {int packedIntValue=int(packedValue);int v0=packedIntValue/256;return vec2(v0,packedIntValue-v0*256);}vec2 unpack_opacity(const float packedOpacity) {int intOpacity=int(packedOpacity)/2;return vec2(float(intOpacity)/127.0,mod(packedOpacity,2.0));}vec4 decode_color(const vec2 encodedColor) {return vec4(unpack_float(encodedColor[0])/255.0,unpack_float(encodedColor[1])/255.0\n);}float unpack_mix_vec2(const vec2 packedValue,const float t) {return mix(packedValue[0],packedValue[1],t);}vec4 unpack_mix_color(const vec4 packedColors,const float t) {vec4 minColor=decode_color(vec2(packedColors[0],packedColors[1]));vec4 maxColor=decode_color(vec2(packedColors[2],packedColors[3]));return mix(minColor,maxColor,t);}vec2 get_pattern_pos(const vec2 pixel_coord_upper,const vec2 pixel_coord_lower,const vec2 pattern_size,const float tile_units_to_pixels,const vec2 pos) {vec2 offset=mod(mod(mod(pixel_coord_upper,pattern_size)*256.0,pattern_size)*256.0+pixel_coord_lower,pattern_size);return (tile_units_to_pixels*pos+offset)/pattern_size;}"),Ze=yr("uniform vec4 u_color;uniform float u_opacity;void main() {gl_FragColor=u_color*u_opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);}"),We=yr("uniform vec2 u_pattern_tl_a;uniform vec2 u_pattern_br_a;uniform vec2 u_pattern_tl_b;uniform vec2 u_pattern_br_b;uniform vec2 u_texsize;uniform float u_mix;uniform float u_opacity;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;void main() {vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(u_pattern_tl_a/u_texsize,u_pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(u_pattern_tl_b/u_texsize,u_pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);gl_FragColor=mix(color1,color2,u_mix)*u_opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_pattern_size_a;uniform vec2 u_pattern_size_b;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_scale_a;uniform float u_scale_b;uniform float u_tile_units_to_pixels;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_a*u_pattern_size_a,u_tile_units_to_pixels,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_b*u_pattern_size_b,u_tile_units_to_pixels,a_pos);}"),Ye=yr("varying vec3 v_data;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define mediump float radius\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define highp vec4 stroke_color\n#pragma mapbox: define mediump float stroke_width\n#pragma mapbox: define lowp float stroke_opacity\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize mediump float radius\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize highp vec4 stroke_color\n#pragma mapbox: initialize mediump float stroke_width\n#pragma mapbox: initialize lowp float stroke_opacity\nvec2 extrude=v_data.xy;float extrude_length=length(extrude);lowp float antialiasblur=v_data.z;float antialiased_blur=-max(blur,antialiasblur);float opacity_t=smoothstep(0.0,antialiased_blur,extrude_length-1.0);float color_t=stroke_width < 0.01 ? 0.0 : smoothstep(antialiased_blur,0.0,extrude_length-radius/(radius+stroke_width));gl_FragColor=opacity_t*mix(color*opacity,stroke_color*stroke_opacity,color_t);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform bool u_scale_with_map;uniform bool u_pitch_with_map;uniform vec2 u_extrude_scale;uniform lowp float u_device_pixel_ratio;uniform highp float u_camera_to_center_distance;attribute vec2 a_pos;varying vec3 v_data;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define mediump float radius\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define highp vec4 stroke_color\n#pragma mapbox: define mediump float stroke_width\n#pragma mapbox: define lowp float stroke_opacity\nvoid main(void) {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize mediump float radius\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize highp vec4 stroke_color\n#pragma mapbox: initialize mediump float stroke_width\n#pragma mapbox: initialize lowp float stroke_opacity\nvec2 extrude=vec2(mod(a_pos,2.0)*2.0-1.0);vec2 circle_center=floor(a_pos*0.5);if (u_pitch_with_map) {vec2 corner_position=circle_center;if (u_scale_with_map) {corner_position+=extrude*(radius+stroke_width)*u_extrude_scale;} else {vec4 projected_center=u_matrix*vec4(circle_center,0,1);corner_position+=extrude*(radius+stroke_width)*u_extrude_scale*(projected_center.w/u_camera_to_center_distance);}gl_Position=u_matrix*vec4(corner_position,0,1);} else {gl_Position=u_matrix*vec4(circle_center,0,1);if (u_scale_with_map) {gl_Position.xy+=extrude*(radius+stroke_width)*u_extrude_scale*u_camera_to_center_distance;} else {gl_Position.xy+=extrude*(radius+stroke_width)*u_extrude_scale*gl_Position.w;}}lowp float antialiasblur=1.0/u_device_pixel_ratio/(radius+stroke_width);v_data=vec3(extrude.x,extrude.y,antialiasblur);}"),Xe=yr("void main() {gl_FragColor=vec4(1.0);}","attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);}"),Ke=yr("uniform highp float u_intensity;varying vec2 v_extrude;\n#pragma mapbox: define highp float weight\n#define GAUSS_COEF 0.3989422804014327\nvoid main() {\n#pragma mapbox: initialize highp float weight\nfloat d=-0.5*3.0*3.0*dot(v_extrude,v_extrude);float val=weight*u_intensity*GAUSS_COEF*exp(d);gl_FragColor=vec4(val,1.0,1.0,1.0);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform float u_extrude_scale;uniform float u_opacity;uniform float u_intensity;attribute vec2 a_pos;varying vec2 v_extrude;\n#pragma mapbox: define highp float weight\n#pragma mapbox: define mediump float radius\nconst highp float ZERO=1.0/255.0/16.0;\n#define GAUSS_COEF 0.3989422804014327\nvoid main(void) {\n#pragma mapbox: initialize highp float weight\n#pragma mapbox: initialize mediump float radius\nvec2 unscaled_extrude=vec2(mod(a_pos,2.0)*2.0-1.0);float S=sqrt(-2.0*log(ZERO/weight/u_intensity/GAUSS_COEF))/3.0;v_extrude=S*unscaled_extrude;vec2 extrude=v_extrude*radius*u_extrude_scale;vec4 pos=vec4(floor(a_pos*0.5)+extrude,0,1);gl_Position=u_matrix*pos;}"),Je=yr("uniform sampler2D u_image;uniform sampler2D u_color_ramp;uniform float u_opacity;varying vec2 v_pos;void main() {float t=texture2D(u_image,v_pos).r;vec4 color=texture2D(u_color_ramp,vec2(t,0.5));gl_FragColor=color*u_opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(0.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_world;attribute vec2 a_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos*u_world,0,1);v_pos.x=a_pos.x;v_pos.y=1.0-a_pos.y;}"),Qe=yr("varying float v_placed;varying float v_notUsed;void main() {float alpha=0.5;gl_FragColor=vec4(1.0,0.0,0.0,1.0)*alpha;if (v_placed > 0.5) {gl_FragColor=vec4(0.0,0.0,1.0,0.5)*alpha;}if (v_notUsed > 0.5) {gl_FragColor*=.1;}}","attribute vec2 a_pos;attribute vec2 a_anchor_pos;attribute vec2 a_extrude;attribute vec2 a_placed;attribute vec2 a_shift;uniform mat4 u_matrix;uniform vec2 u_extrude_scale;uniform float u_camera_to_center_distance;varying float v_placed;varying float v_notUsed;void main() {vec4 projectedPoint=u_matrix*vec4(a_anchor_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float collision_perspective_ratio=clamp(0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);gl_Position=u_matrix*vec4(a_pos,0.0,1.0);gl_Position.xy+=(a_extrude+a_shift)*u_extrude_scale*gl_Position.w*collision_perspective_ratio;v_placed=a_placed.x;v_notUsed=a_placed.y;}"),$e=yr("varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;void main() {float alpha=0.5*min(v_perspective_ratio,1.0);float stroke_radius=0.9*max(v_perspective_ratio,1.0);float distance_to_center=length(v_extrude);float distance_to_edge=abs(distance_to_center-v_radius);float opacity_t=smoothstep(-stroke_radius,0.0,-distance_to_edge);vec4 color=mix(vec4(0.0,0.0,1.0,0.5),vec4(1.0,0.0,0.0,1.0),v_collision);gl_FragColor=color*alpha*opacity_t;}","attribute vec2 a_pos;attribute float a_radius;attribute vec2 a_flags;uniform mat4 u_matrix;uniform mat4 u_inv_matrix;uniform vec2 u_viewport_size;uniform float u_camera_to_center_distance;varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;vec3 toTilePosition(vec2 screenPos) {vec4 rayStart=u_inv_matrix*vec4(screenPos,-1.0,1.0);vec4 rayEnd =u_inv_matrix*vec4(screenPos, 1.0,1.0);rayStart.xyz/=rayStart.w;rayEnd.xyz /=rayEnd.w;highp float t=(0.0-rayStart.z)/(rayEnd.z-rayStart.z);return mix(rayStart.xyz,rayEnd.xyz,t);}void main() {vec2 quadCenterPos=a_pos;float radius=a_radius;float collision=a_flags.x;float vertexIdx=a_flags.y;vec2 quadVertexOffset=vec2(mix(-1.0,1.0,float(vertexIdx >=2.0)),mix(-1.0,1.0,float(vertexIdx >=1.0 && vertexIdx <=2.0)));vec2 quadVertexExtent=quadVertexOffset*radius;vec3 tilePos=toTilePosition(quadCenterPos);vec4 clipPos=u_matrix*vec4(tilePos,1.0);highp float camera_to_anchor_distance=clipPos.w;highp float collision_perspective_ratio=clamp(0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);float padding_factor=1.2;v_radius=radius;v_extrude=quadVertexExtent*padding_factor;v_perspective_ratio=collision_perspective_ratio;v_collision=collision;gl_Position=vec4(clipPos.xyz/clipPos.w,1.0)+vec4(quadVertexExtent*padding_factor/u_viewport_size*2.0,0.0,0.0);}"),tr=yr("uniform highp vec4 u_color;uniform sampler2D u_overlay;varying vec2 v_uv;void main() {vec4 overlay_color=texture2D(u_overlay,v_uv);gl_FragColor=mix(u_color,overlay_color,overlay_color.a);}","attribute vec2 a_pos;varying vec2 v_uv;uniform mat4 u_matrix;uniform float u_overlay_scale;void main() {v_uv=a_pos/8192.0;gl_Position=u_matrix*vec4(a_pos*u_overlay_scale,0,1);}"),er=yr("#pragma mapbox: define highp vec4 color\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize lowp float opacity\ngl_FragColor=color*opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","attribute vec2 a_pos;uniform mat4 u_matrix;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize lowp float opacity\ngl_Position=u_matrix*vec4(a_pos,0,1);}"),rr=yr("varying vec2 v_pos;\n#pragma mapbox: define highp vec4 outline_color\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize highp vec4 outline_color\n#pragma mapbox: initialize lowp float opacity\nfloat dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);gl_FragColor=outline_color*(alpha*opacity);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","attribute vec2 a_pos;uniform mat4 u_matrix;uniform vec2 u_world;varying vec2 v_pos;\n#pragma mapbox: define highp vec4 outline_color\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize highp vec4 outline_color\n#pragma mapbox: initialize lowp float opacity\ngl_Position=u_matrix*vec4(a_pos,0,1);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;}"),nr=yr("uniform vec2 u_texsize;uniform sampler2D u_image;uniform float u_fade;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos;\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\nvoid main() {\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);gl_FragColor=mix(color1,color2,u_fade)*alpha*opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_world;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos;\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\n#pragma mapbox: define lowp float pixel_ratio_from\n#pragma mapbox: define lowp float pixel_ratio_to\nvoid main() {\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\n#pragma mapbox: initialize lowp float pixel_ratio_from\n#pragma mapbox: initialize lowp float pixel_ratio_to\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;gl_Position=u_matrix*vec4(a_pos,0,1);vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,a_pos);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;}"),ir=yr("uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\nvoid main() {\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);gl_FragColor=mix(color1,color2,u_fade)*opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\n#pragma mapbox: define lowp float pixel_ratio_from\n#pragma mapbox: define lowp float pixel_ratio_to\nvoid main() {\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\n#pragma mapbox: initialize lowp float pixel_ratio_from\n#pragma mapbox: initialize lowp float pixel_ratio_to\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;gl_Position=u_matrix*vec4(a_pos,0,1);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileZoomRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileZoomRatio,a_pos);}"),or=yr("varying vec4 v_color;void main() {gl_FragColor=v_color;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;uniform float u_vertical_gradient;uniform lowp float u_opacity;attribute vec2 a_pos;attribute vec4 a_normal_ed;varying vec4 v_color;\n#pragma mapbox: define highp float base\n#pragma mapbox: define highp float height\n#pragma mapbox: define highp vec4 color\nvoid main() {\n#pragma mapbox: initialize highp float base\n#pragma mapbox: initialize highp float height\n#pragma mapbox: initialize highp vec4 color\nvec3 normal=a_normal_ed.xyz;base=max(0.0,base);height=max(0.0,height);float t=mod(normal.x,2.0);gl_Position=u_matrix*vec4(a_pos,t > 0.0 ? height : base,1);float colorvalue=color.r*0.2126+color.g*0.7152+color.b*0.0722;v_color=vec4(0.0,0.0,0.0,1.0);vec4 ambientlight=vec4(0.03,0.03,0.03,1.0);color+=ambientlight;float directional=clamp(dot(normal/16384.0,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((1.0-colorvalue+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=((1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_color.r+=clamp(color.r*directional*u_lightcolor.r,mix(0.0,0.3,1.0-u_lightcolor.r),1.0);v_color.g+=clamp(color.g*directional*u_lightcolor.g,mix(0.0,0.3,1.0-u_lightcolor.g),1.0);v_color.b+=clamp(color.b*directional*u_lightcolor.b,mix(0.0,0.3,1.0-u_lightcolor.b),1.0);v_color*=u_opacity;}"),ar=yr("uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting;\n#pragma mapbox: define lowp float base\n#pragma mapbox: define lowp float height\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\n#pragma mapbox: define lowp float pixel_ratio_from\n#pragma mapbox: define lowp float pixel_ratio_to\nvoid main() {\n#pragma mapbox: initialize lowp float base\n#pragma mapbox: initialize lowp float height\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\n#pragma mapbox: initialize lowp float pixel_ratio_from\n#pragma mapbox: initialize lowp float pixel_ratio_to\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);vec4 mixedColor=mix(color1,color2,u_fade);gl_FragColor=mixedColor*v_lighting;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_height_factor;uniform vec3 u_scale;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;attribute vec2 a_pos;attribute vec4 a_normal_ed;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting;\n#pragma mapbox: define lowp float base\n#pragma mapbox: define lowp float height\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\n#pragma mapbox: define lowp float pixel_ratio_from\n#pragma mapbox: define lowp float pixel_ratio_to\nvoid main() {\n#pragma mapbox: initialize lowp float base\n#pragma mapbox: initialize lowp float height\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\n#pragma mapbox: initialize lowp float pixel_ratio_from\n#pragma mapbox: initialize lowp float pixel_ratio_to\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec3 normal=a_normal_ed.xyz;float edgedistance=a_normal_ed.w;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;base=max(0.0,base);height=max(0.0,height);float t=mod(normal.x,2.0);float z=t > 0.0 ? height : base;gl_Position=u_matrix*vec4(a_pos,z,1);vec2 pos=normal.x==1.0 && normal.y==0.0 && normal.z==16384.0\n? a_pos\n: vec2(edgedistance,z*u_height_factor);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,pos);v_lighting=vec4(0.0,0.0,0.0,1.0);float directional=clamp(dot(normal/16383.0,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((0.5+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=((1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_lighting.rgb+=clamp(directional*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));v_lighting*=u_opacity;}"),sr=yr("#ifdef GL_ES\nprecision highp float;\n#endif\nuniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_dimension;uniform float u_zoom;uniform vec4 u_unpack;float getElevation(vec2 coord,float bias) {vec4 data=texture2D(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack)/4.0;}void main() {vec2 epsilon=1.0/u_dimension;float a=getElevation(v_pos+vec2(-epsilon.x,-epsilon.y),0.0);float b=getElevation(v_pos+vec2(0,-epsilon.y),0.0);float c=getElevation(v_pos+vec2(epsilon.x,-epsilon.y),0.0);float d=getElevation(v_pos+vec2(-epsilon.x,0),0.0);float e=getElevation(v_pos,0.0);float f=getElevation(v_pos+vec2(epsilon.x,0),0.0);float g=getElevation(v_pos+vec2(-epsilon.x,epsilon.y),0.0);float h=getElevation(v_pos+vec2(0,epsilon.y),0.0);float i=getElevation(v_pos+vec2(epsilon.x,epsilon.y),0.0);float exaggerationFactor=u_zoom < 2.0 ? 0.4 : u_zoom < 4.5 ? 0.35 : 0.3;float exaggeration=u_zoom < 15.0 ? (u_zoom-15.0)*exaggerationFactor : 0.0;vec2 deriv=vec2((c+f+f+i)-(a+d+d+g),(g+h+h+i)-(a+b+b+c))/pow(2.0,exaggeration+(19.2562-u_zoom));gl_FragColor=clamp(vec4(deriv.x/2.0+0.5,deriv.y/2.0+0.5,1.0,1.0),0.0,1.0);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_dimension;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);highp vec2 epsilon=1.0/u_dimension;float scale=(u_dimension.x-2.0)/u_dimension.x;v_pos=(a_texture_pos/8192.0)*scale+epsilon;}"),lr=yr("uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_latrange;uniform vec2 u_light;uniform vec4 u_shadow;uniform vec4 u_highlight;uniform vec4 u_accent;\n#define PI 3.141592653589793\nvoid main() {vec4 pixel=texture2D(u_image,v_pos);vec2 deriv=((pixel.rg*2.0)-1.0);float scaleFactor=cos(radians((u_latrange[0]-u_latrange[1])*(1.0-v_pos.y)+u_latrange[1]));float slope=atan(1.25*length(deriv)/scaleFactor);float aspect=deriv.x !=0.0 ? atan(deriv.y,-deriv.x) : PI/2.0*(deriv.y > 0.0 ? 1.0 :-1.0);float intensity=u_light.x;float azimuth=u_light.y+PI;float base=1.875-intensity*1.75;float maxValue=0.5*PI;float scaledSlope=intensity !=0.5 ? ((pow(base,slope)-1.0)/(pow(base,maxValue)-1.0))*maxValue : slope;float accent=cos(scaledSlope);vec4 accent_color=(1.0-accent)*u_accent*clamp(intensity*2.0,0.0,1.0);float shade=abs(mod((aspect+azimuth)/PI+0.5,2.0)-1.0);vec4 shade_color=mix(u_shadow,u_highlight,shade)*sin(scaledSlope)*clamp(intensity*2.0,0.0,1.0);gl_FragColor=accent_color*(1.0-shade_color.a)+shade_color;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=a_texture_pos/8192.0;}"),ur=yr("uniform lowp float u_device_pixel_ratio;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\nfloat dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);gl_FragColor=color*(alpha*opacity);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","\n#define scale 0.015873016\nattribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform vec2 u_units_to_pixels;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp float v_linesofar;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define mediump float gapwidth\n#pragma mapbox: define lowp float offset\n#pragma mapbox: define mediump float width\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump float gapwidth\n#pragma mapbox: initialize lowp float offset\n#pragma mapbox: initialize mediump float width\nfloat ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;v_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*2.0;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_width2=vec2(outset,inset);}"),cr=yr("uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;varying highp vec2 v_uv;\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\nfloat dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);vec4 color=texture2D(u_image,v_uv);gl_FragColor=color*(alpha*opacity);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","\n#define scale 0.015873016\nattribute vec2 a_pos_normal;attribute vec4 a_data;attribute float a_uv_x;attribute float a_split_index;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_units_to_pixels;uniform float u_image_height;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp vec2 v_uv;\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define mediump float gapwidth\n#pragma mapbox: define lowp float offset\n#pragma mapbox: define mediump float width\nvoid main() {\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump float gapwidth\n#pragma mapbox: initialize lowp float offset\n#pragma mapbox: initialize mediump float width\nfloat ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;highp float texel_height=1.0/u_image_height;highp float half_texel_height=0.5*texel_height;v_uv=vec2(a_uv_x,a_split_index*texel_height-half_texel_height);vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_width2=vec2(outset,inset);}"),pr=yr("uniform lowp float u_device_pixel_ratio;uniform vec2 u_texsize;uniform float u_fade;uniform mediump vec3 u_scale;uniform sampler2D u_image;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\n#pragma mapbox: define lowp float pixel_ratio_from\n#pragma mapbox: define lowp float pixel_ratio_to\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\n#pragma mapbox: initialize lowp float pixel_ratio_from\n#pragma mapbox: initialize lowp float pixel_ratio_to\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\nvec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;vec2 pattern_size_a=vec2(display_size_a.x*fromScale/tileZoomRatio,display_size_a.y);vec2 pattern_size_b=vec2(display_size_b.x*toScale/tileZoomRatio,display_size_b.y);float aspect_a=display_size_a.y/v_width;float aspect_b=display_size_b.y/v_width;float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);float x_a=mod(v_linesofar/pattern_size_a.x*aspect_a,1.0);float x_b=mod(v_linesofar/pattern_size_b.x*aspect_b,1.0);float y=0.5*v_normal.y+0.5;vec2 texel_size=1.0/u_texsize;vec2 pos_a=mix(pattern_tl_a*texel_size-texel_size,pattern_br_a*texel_size+texel_size,vec2(x_a,y));vec2 pos_b=mix(pattern_tl_b*texel_size-texel_size,pattern_br_b*texel_size+texel_size,vec2(x_b,y));vec4 color=mix(texture2D(u_image,pos_a),texture2D(u_image,pos_b),u_fade);gl_FragColor=color*alpha*opacity;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","\n#define scale 0.015873016\n#define LINE_DISTANCE_SCALE 2.0\nattribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform vec2 u_units_to_pixels;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp float offset\n#pragma mapbox: define mediump float gapwidth\n#pragma mapbox: define mediump float width\n#pragma mapbox: define lowp float floorwidth\n#pragma mapbox: define lowp vec4 pattern_from\n#pragma mapbox: define lowp vec4 pattern_to\n#pragma mapbox: define lowp float pixel_ratio_from\n#pragma mapbox: define lowp float pixel_ratio_to\nvoid main() {\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize lowp float offset\n#pragma mapbox: initialize mediump float gapwidth\n#pragma mapbox: initialize mediump float width\n#pragma mapbox: initialize lowp float floorwidth\n#pragma mapbox: initialize mediump vec4 pattern_from\n#pragma mapbox: initialize mediump vec4 pattern_to\n#pragma mapbox: initialize lowp float pixel_ratio_from\n#pragma mapbox: initialize lowp float pixel_ratio_to\nfloat ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_linesofar=a_linesofar;v_width2=vec2(outset,inset);v_width=floorwidth;}"),hr=yr("uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;uniform float u_sdfgamma;uniform float u_mix;varying vec2 v_normal;varying vec2 v_width2;varying vec2 v_tex_a;varying vec2 v_tex_b;varying float v_gamma_scale;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define mediump float width\n#pragma mapbox: define lowp float floorwidth\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump float width\n#pragma mapbox: initialize lowp float floorwidth\nfloat dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);float sdfdist_a=texture2D(u_image,v_tex_a).a;float sdfdist_b=texture2D(u_image,v_tex_b).a;float sdfdist=mix(sdfdist_a,sdfdist_b,u_mix);alpha*=smoothstep(0.5-u_sdfgamma/floorwidth,0.5+u_sdfgamma/floorwidth,sdfdist);gl_FragColor=color*(alpha*opacity);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","\n#define scale 0.015873016\n#define LINE_DISTANCE_SCALE 2.0\nattribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_patternscale_a;uniform float u_tex_y_a;uniform vec2 u_patternscale_b;uniform float u_tex_y_b;uniform vec2 u_units_to_pixels;varying vec2 v_normal;varying vec2 v_width2;varying vec2 v_tex_a;varying vec2 v_tex_b;varying float v_gamma_scale;\n#pragma mapbox: define highp vec4 color\n#pragma mapbox: define lowp float blur\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define mediump float gapwidth\n#pragma mapbox: define lowp float offset\n#pragma mapbox: define mediump float width\n#pragma mapbox: define lowp float floorwidth\nvoid main() {\n#pragma mapbox: initialize highp vec4 color\n#pragma mapbox: initialize lowp float blur\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize mediump float gapwidth\n#pragma mapbox: initialize lowp float offset\n#pragma mapbox: initialize mediump float width\n#pragma mapbox: initialize lowp float floorwidth\nfloat ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;v_tex_a=vec2(a_linesofar*u_patternscale_a.x/floorwidth,normal.y*u_patternscale_a.y+u_tex_y_a);v_tex_b=vec2(a_linesofar*u_patternscale_b.x/floorwidth,normal.y*u_patternscale_b.y+u_tex_y_b);v_width2=vec2(outset,inset);}"),fr=yr("uniform float u_fade_t;uniform float u_opacity;uniform sampler2D u_image0;uniform sampler2D u_image1;varying vec2 v_pos0;varying vec2 v_pos1;uniform float u_brightness_low;uniform float u_brightness_high;uniform float u_saturation_factor;uniform float u_contrast_factor;uniform vec3 u_spin_weights;void main() {vec4 color0=texture2D(u_image0,v_pos0);vec4 color1=texture2D(u_image1,v_pos1);if (color0.a > 0.0) {color0.rgb=color0.rgb/color0.a;}if (color1.a > 0.0) {color1.rgb=color1.rgb/color1.a;}vec4 color=mix(color0,color1,u_fade_t);color.a*=u_opacity;vec3 rgb=color.rgb;rgb=vec3(dot(rgb,u_spin_weights.xyz),dot(rgb,u_spin_weights.zxy),dot(rgb,u_spin_weights.yzx));float average=(color.r+color.g+color.b)/3.0;rgb+=(average-rgb)*u_saturation_factor;rgb=(rgb-0.5)*u_contrast_factor+0.5;vec3 u_high_vec=vec3(u_brightness_low,u_brightness_low,u_brightness_low);vec3 u_low_vec=vec3(u_brightness_high,u_brightness_high,u_brightness_high);gl_FragColor=vec4(mix(u_high_vec,u_low_vec,rgb)*color.a,color.a);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","uniform mat4 u_matrix;uniform vec2 u_tl_parent;uniform float u_scale_parent;uniform float u_buffer_scale;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos0;varying vec2 v_pos1;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos0=(((a_texture_pos/8192.0)-0.5)/u_buffer_scale )+0.5;v_pos1=(v_pos0*u_scale_parent)+u_tl_parent;}"),dr=yr("uniform sampler2D u_texture;varying vec2 v_tex;varying float v_fade_opacity;\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize lowp float opacity\nlowp float alpha=opacity*v_fade_opacity;gl_FragColor=texture2D(u_texture,v_tex)*alpha;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec4 a_pixeloffset;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform highp float u_camera_to_center_distance;uniform highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform float u_fade_change;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform vec2 u_texsize;varying vec2 v_tex;varying float v_fade_opacity;\n#pragma mapbox: define lowp float opacity\nvoid main() {\n#pragma mapbox: initialize lowp float opacity\nvec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;vec2 a_minFontScale=a_pixeloffset.zw/256.0;highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec4 projectedPoint=u_matrix*vec4(a_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ?\ncamera_to_anchor_distance/u_camera_to_center_distance :\nu_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),0,1);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);vec4 projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,0.0,1.0);gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*max(a_minFontScale,fontScale)+a_pxoffset/16.0),0.0,1.0);v_tex=a_tex/u_texsize;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;v_fade_opacity=max(0.0,min(1.0,fade_opacity[0]+fade_change));}"),mr=yr("#define SDF_PX 8.0\nuniform bool u_is_halo;uniform sampler2D u_texture;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;uniform bool u_is_text;varying vec2 v_data0;varying vec3 v_data1;\n#pragma mapbox: define highp vec4 fill_color\n#pragma mapbox: define highp vec4 halo_color\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp float halo_width\n#pragma mapbox: define lowp float halo_blur\nvoid main() {\n#pragma mapbox: initialize highp vec4 fill_color\n#pragma mapbox: initialize highp vec4 halo_color\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize lowp float halo_width\n#pragma mapbox: initialize lowp float halo_blur\nfloat EDGE_GAMMA=0.105/u_device_pixel_ratio;vec2 tex=v_data0.xy;float gamma_scale=v_data1.x;float size=v_data1.y;float fade_opacity=v_data1[2];float fontScale=u_is_text ? size/24.0 : size;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec4 a_pixeloffset;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;varying vec2 v_data0;varying vec3 v_data1;\n#pragma mapbox: define highp vec4 fill_color\n#pragma mapbox: define highp vec4 halo_color\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp float halo_width\n#pragma mapbox: define lowp float halo_blur\nvoid main() {\n#pragma mapbox: initialize highp vec4 fill_color\n#pragma mapbox: initialize highp vec4 halo_color\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize lowp float halo_width\n#pragma mapbox: initialize lowp float halo_blur\nvec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec4 projectedPoint=u_matrix*vec4(a_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ?\ncamera_to_anchor_distance/u_camera_to_center_distance :\nu_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),0,1);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);vec4 projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,0.0,1.0);gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale+a_pxoffset),0.0,1.0);float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(1.0,fade_opacity[0]+fade_change));v_data0=a_tex/u_texsize;v_data1=vec3(gamma_scale,size,interpolated_fade_opacity);}"),gr=yr("#define SDF_PX 8.0\n#define SDF 1.0\n#define ICON 0.0\nuniform bool u_is_halo;uniform sampler2D u_texture;uniform sampler2D u_texture_icon;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;varying vec4 v_data0;varying vec4 v_data1;\n#pragma mapbox: define highp vec4 fill_color\n#pragma mapbox: define highp vec4 halo_color\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp float halo_width\n#pragma mapbox: define lowp float halo_blur\nvoid main() {\n#pragma mapbox: initialize highp vec4 fill_color\n#pragma mapbox: initialize highp vec4 halo_color\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize lowp float halo_width\n#pragma mapbox: initialize lowp float halo_blur\nfloat fade_opacity=v_data1[2];if (v_data1.w==ICON) {vec2 tex_icon=v_data0.zw;lowp float alpha=opacity*fade_opacity;gl_FragColor=texture2D(u_texture_icon,tex_icon)*alpha;\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\nreturn;}vec2 tex=v_data0.xy;float EDGE_GAMMA=0.105/u_device_pixel_ratio;float gamma_scale=v_data1.x;float size=v_data1.y;float fontScale=size/24.0;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);\n#ifdef OVERDRAW_INSPECTOR\ngl_FragColor=vec4(1.0);\n#endif\n}","const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;uniform vec2 u_texsize_icon;varying vec4 v_data0;varying vec4 v_data1;\n#pragma mapbox: define highp vec4 fill_color\n#pragma mapbox: define highp vec4 halo_color\n#pragma mapbox: define lowp float opacity\n#pragma mapbox: define lowp float halo_width\n#pragma mapbox: define lowp float halo_blur\nvoid main() {\n#pragma mapbox: initialize highp vec4 fill_color\n#pragma mapbox: initialize highp vec4 halo_color\n#pragma mapbox: initialize lowp float opacity\n#pragma mapbox: initialize lowp float halo_width\n#pragma mapbox: initialize lowp float halo_blur\nvec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);float is_sdf=a_size[0]-2.0*a_size_min;highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec4 projectedPoint=u_matrix*vec4(a_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ?\ncamera_to_anchor_distance/u_camera_to_center_distance :\nu_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=size/24.0;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),0,1);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);vec4 projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,0.0,1.0);gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale),0.0,1.0);float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(1.0,fade_opacity[0]+fade_change));v_data0.xy=a_tex/u_texsize;v_data0.zw=a_tex/u_texsize_icon;v_data1=vec4(gamma_scale,size,interpolated_fade_opacity,is_sdf);}");function yr(t,e){var r=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,n=e.match(/attribute ([\w]+) ([\w]+)/g),i=t.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),o=e.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),a=o?o.concat(i):i,s={};return{fragmentSource:t=t.replace(r,(function(t,e,r,n,i){return s[i]=!0,"define"===e?"\n#ifndef HAS_UNIFORM_u_"+i+"\nvarying "+r+" "+n+" "+i+";\n#else\nuniform "+r+" "+n+" u_"+i+";\n#endif\n":"\n#ifdef HAS_UNIFORM_u_"+i+"\n "+r+" "+n+" "+i+" = u_"+i+";\n#endif\n"})),vertexSource:e=e.replace(r,(function(t,e,r,n,i){var o="float"===n?"vec2":"vec4",a=i.match(/color/)?"color":o;return s[i]?"define"===e?"\n#ifndef HAS_UNIFORM_u_"+i+"\nuniform lowp float u_"+i+"_t;\nattribute "+r+" "+o+" a_"+i+";\nvarying "+r+" "+n+" "+i+";\n#else\nuniform "+r+" "+n+" u_"+i+";\n#endif\n":"vec4"===a?"\n#ifndef HAS_UNIFORM_u_"+i+"\n "+i+" = a_"+i+";\n#else\n "+r+" "+n+" "+i+" = u_"+i+";\n#endif\n":"\n#ifndef HAS_UNIFORM_u_"+i+"\n "+i+" = unpack_mix_"+a+"(a_"+i+", u_"+i+"_t);\n#else\n "+r+" "+n+" "+i+" = u_"+i+";\n#endif\n":"define"===e?"\n#ifndef HAS_UNIFORM_u_"+i+"\nuniform lowp float u_"+i+"_t;\nattribute "+r+" "+o+" a_"+i+";\n#else\nuniform "+r+" "+n+" u_"+i+";\n#endif\n":"vec4"===a?"\n#ifndef HAS_UNIFORM_u_"+i+"\n "+r+" "+n+" "+i+" = a_"+i+";\n#else\n "+r+" "+n+" "+i+" = u_"+i+";\n#endif\n":"\n#ifndef HAS_UNIFORM_u_"+i+"\n "+r+" "+n+" "+i+" = unpack_mix_"+a+"(a_"+i+", u_"+i+"_t);\n#else\n "+r+" "+n+" "+i+" = u_"+i+";\n#endif\n"})),staticAttributes:n,staticUniforms:a}}var vr=Object.freeze({__proto__:null,prelude:Ge,background:Ze,backgroundPattern:We,circle:Ye,clippingMask:Xe,heatmap:Ke,heatmapTexture:Je,collisionBox:Qe,collisionCircle:$e,debug:tr,fill:er,fillOutline:rr,fillOutlinePattern:nr,fillPattern:ir,fillExtrusion:or,fillExtrusionPattern:ar,hillshadePrepare:sr,hillshade:lr,line:ur,lineGradient:cr,linePattern:pr,lineSDF:hr,raster:fr,symbolIcon:dr,symbolSDF:mr,symbolTextAndIcon:gr}),_r=function(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffer=null,this.vao=null};function br(t){for(var e=[],r=0;r<t.length;r++)if(null!==t[r]){var n=t[r].split(" ");e.push(n.pop())}return e}_r.prototype.bind=function(t,e,r,n,i,o,a,s){this.context=t;for(var l=this.boundPaintVertexBuffers.length!==n.length,u=0;!l&&u<n.length;u++)this.boundPaintVertexBuffers[u]!==n[u]&&(l=!0);t.extVertexArrayObject&&this.vao&&this.boundProgram===e&&this.boundLayoutVertexBuffer===r&&!l&&this.boundIndexBuffer===i&&this.boundVertexOffset===o&&this.boundDynamicVertexBuffer===a&&this.boundDynamicVertexBuffer2===s?(t.bindVertexArrayOES.set(this.vao),a&&a.bind(),i&&i.dynamicDraw&&i.bind(),s&&s.bind()):this.freshBind(e,r,n,i,o,a,s)},_r.prototype.freshBind=function(t,e,r,n,i,o,a){var s,l=t.numAttributes,u=this.context,c=u.gl;if(u.extVertexArrayObject)this.vao&&this.destroy(),this.vao=u.extVertexArrayObject.createVertexArrayOES(),u.bindVertexArrayOES.set(this.vao),s=0,this.boundProgram=t,this.boundLayoutVertexBuffer=e,this.boundPaintVertexBuffers=r,this.boundIndexBuffer=n,this.boundVertexOffset=i,this.boundDynamicVertexBuffer=o,this.boundDynamicVertexBuffer2=a;else{s=u.currentNumAttributes||0;for(var p=l;p<s;p++)c.disableVertexAttribArray(p)}e.enableAttributes(c,t);for(var h=0,f=r;h<f.length;h+=1)f[h].enableAttributes(c,t);o&&o.enableAttributes(c,t),a&&a.enableAttributes(c,t),e.bind(),e.setVertexAttribPointers(c,t,i);for(var d=0,m=r;d<m.length;d+=1){var g=m[d];g.bind(),g.setVertexAttribPointers(c,t,i)}o&&(o.bind(),o.setVertexAttribPointers(c,t,i)),n&&n.bind(),a&&(a.bind(),a.setVertexAttribPointers(c,t,i)),u.currentNumAttributes=l},_r.prototype.destroy=function(){this.vao&&(this.context.extVertexArrayObject.deleteVertexArrayOES(this.vao),this.vao=null)};var xr=function(t,e,r,n,i,o){var a=t.gl;this.program=a.createProgram();for(var s=br(r.staticAttributes),l=n?n.getBinderAttributes():[],u=s.concat(l),c=r.staticUniforms?br(r.staticUniforms):[],p=n?n.getBinderUniforms():[],h=[],f=0,d=c.concat(p);f<d.length;f+=1){var m=d[f];h.indexOf(m)<0&&h.push(m)}var g=n?n.defines():[];o&&g.push("#define OVERDRAW_INSPECTOR;");var y=g.concat(Ge.fragmentSource,r.fragmentSource).join("\n"),v=g.concat(Ge.vertexSource,r.vertexSource).join("\n"),_=a.createShader(a.FRAGMENT_SHADER);if(a.isContextLost())this.failedToCreate=!0;else{a.shaderSource(_,y),a.compileShader(_),a.attachShader(this.program,_);var b=a.createShader(a.VERTEX_SHADER);if(a.isContextLost())this.failedToCreate=!0;else{a.shaderSource(b,v),a.compileShader(b),a.attachShader(this.program,b),this.attributes={};var x={};this.numAttributes=u.length;for(var w=0;w<this.numAttributes;w++)u[w]&&(a.bindAttribLocation(this.program,w,u[w]),this.attributes[u[w]]=w);a.linkProgram(this.program),a.deleteShader(b),a.deleteShader(_);for(var E=0;E<h.length;E++){var T=h[E];if(T&&!x[T]){var A=a.getUniformLocation(this.program,T);A&&(x[T]=A)}}this.fixedUniforms=i(t,x),this.binderUniforms=n?n.getUniforms(t,x):[]}}};function wr(t,e,r){var n=1/he(r,1,e.transform.tileZoom),i=Math.pow(2,r.tileID.overscaledZ),o=r.tileSize*Math.pow(2,e.transform.tileZoom)/i,a=o*(r.tileID.canonical.x+r.tileID.wrap*i),s=o*r.tileID.canonical.y;return{u_image:0,u_texsize:r.imageAtlasTexture.size,u_scale:[n,t.fromScale,t.toScale],u_fade:t.t,u_pixel_coord_upper:[a>>16,s>>16],u_pixel_coord_lower:[65535&a,65535&s]}}xr.prototype.draw=function(t,e,r,n,i,o,a,s,l,u,c,p,h,f,d,m){var g,y=t.gl;if(!this.failedToCreate){for(var v in t.program.set(this.program),t.setDepthMode(r),t.setStencilMode(n),t.setColorMode(i),t.setCullFace(o),this.fixedUniforms)this.fixedUniforms[v].set(a[v]);f&&f.setUniforms(t,this.binderUniforms,p,{zoom:h});for(var _=(g={},g[y.LINES]=2,g[y.TRIANGLES]=3,g[y.LINE_STRIP]=1,g)[e],b=0,x=c.get();b<x.length;b+=1){var w=x[b],E=w.vaos||(w.vaos={});(E[s]||(E[s]=new _r)).bind(t,this,l,f?f.getPaintVertexBuffers():[],u,w.vertexOffset,d,m),y.drawElements(e,w.primitiveLength*_,y.UNSIGNED_SHORT,w.primitiveOffset*_*2)}}};var Er=function(e,r,n,i){var o=r.style.light,a=o.properties.get("position"),s=[a.x,a.y,a.z],l=t.create$1();"viewport"===o.properties.get("anchor")&&t.fromRotation(l,-r.transform.angle),t.transformMat3(s,s,l);var u=o.properties.get("color");return{u_matrix:e,u_lightpos:s,u_lightintensity:o.properties.get("intensity"),u_lightcolor:[u.r,u.g,u.b],u_vertical_gradient:+n,u_opacity:i}},Tr=function(e,r,n,i,o,a,s){return t.extend(Er(e,r,n,i),wr(a,r,s),{u_height_factor:-Math.pow(2,o.overscaledZ)/s.tileSize/8})},Ar=function(t){return{u_matrix:t}},Cr=function(e,r,n,i){return t.extend(Ar(e),wr(n,r,i))},Sr=function(t,e){return{u_matrix:t,u_world:e}},Pr=function(e,r,n,i,o){return t.extend(Cr(e,r,n,i),{u_world:o})},Ir=function(e,r,n,i){var o,a,s=e.transform;if("map"===i.paint.get("circle-pitch-alignment")){var l=he(n,1,s.zoom);o=!0,a=[l,l]}else o=!1,a=s.pixelsToGLUnits;return{u_camera_to_center_distance:s.cameraToCenterDistance,u_scale_with_map:+("map"===i.paint.get("circle-pitch-scale")),u_matrix:e.translatePosMatrix(r.posMatrix,n,i.paint.get("circle-translate"),i.paint.get("circle-translate-anchor")),u_pitch_with_map:+o,u_device_pixel_ratio:t.browser.devicePixelRatio,u_extrude_scale:a}},Dr=function(t,e,r){var n=he(r,1,e.zoom),i=Math.pow(2,e.zoom-r.tileID.overscaledZ),o=r.tileID.overscaleFactor();return{u_matrix:t,u_camera_to_center_distance:e.cameraToCenterDistance,u_pixels_to_tile_units:n,u_extrude_scale:[e.pixelsToGLUnits[0]/(n*i),e.pixelsToGLUnits[1]/(n*i)],u_overscale_factor:o}},Or=function(t,e,r){return{u_matrix:t,u_inv_matrix:e,u_camera_to_center_distance:r.cameraToCenterDistance,u_viewport_size:[r.width,r.height]}},Mr=function(t,e,r){return void 0===r&&(r=1),{u_matrix:t,u_color:e,u_overlay:0,u_overlay_scale:r}},Br=function(t){return{u_matrix:t}},kr=function(t,e,r,n){return{u_matrix:t,u_extrude_scale:he(e,1,r),u_intensity:n}},Fr=function(e,r,n){var i=e.transform;return{u_matrix:jr(e,r,n),u_ratio:1/he(r,1,i.zoom),u_device_pixel_ratio:t.browser.devicePixelRatio,u_units_to_pixels:[1/i.pixelsToGLUnits[0],1/i.pixelsToGLUnits[1]]}},Lr=function(e,r,n,i){return t.extend(Fr(e,r,n),{u_image:0,u_image_height:i})},Rr=function(e,r,n,i){var o=e.transform,a=Nr(r,o);return{u_matrix:jr(e,r,n),u_texsize:r.imageAtlasTexture.size,u_ratio:1/he(r,1,o.zoom),u_device_pixel_ratio:t.browser.devicePixelRatio,u_image:0,u_scale:[a,i.fromScale,i.toScale],u_fade:i.t,u_units_to_pixels:[1/o.pixelsToGLUnits[0],1/o.pixelsToGLUnits[1]]}},zr=function(e,r,n,i,o){var a=e.lineAtlas,s=Nr(r,e.transform),l="round"===n.layout.get("line-cap"),u=a.getDash(i.from,l),c=a.getDash(i.to,l),p=u.width*o.fromScale,h=c.width*o.toScale;return t.extend(Fr(e,r,n),{u_patternscale_a:[s/p,-u.height/2],u_patternscale_b:[s/h,-c.height/2],u_sdfgamma:a.width/(256*Math.min(p,h)*t.browser.devicePixelRatio)/2,u_image:0,u_tex_y_a:u.y,u_tex_y_b:c.y,u_mix:o.t})};function Nr(t,e){return 1/he(t,1,e.tileZoom)}function jr(t,e,r){return t.translatePosMatrix(e.tileID.posMatrix,e,r.paint.get("line-translate"),r.paint.get("line-translate-anchor"))}var Ur=function(t,e,r,n,i){return{u_matrix:t,u_tl_parent:e,u_scale_parent:r,u_buffer_scale:1,u_fade_t:n.mix,u_opacity:n.opacity*i.paint.get("raster-opacity"),u_image0:0,u_image1:1,u_brightness_low:i.paint.get("raster-brightness-min"),u_brightness_high:i.paint.get("raster-brightness-max"),u_saturation_factor:(a=i.paint.get("raster-saturation"),a>0?1-1/(1.001-a):-a),u_contrast_factor:(o=i.paint.get("raster-contrast"),o>0?1/(1-o):1+o),u_spin_weights:Vr(i.paint.get("raster-hue-rotate"))};var o,a};function Vr(t){t*=Math.PI/180;var e=Math.sin(t),r=Math.cos(t);return[(2*r+1)/3,(-Math.sqrt(3)*e-r+1)/3,(Math.sqrt(3)*e-r+1)/3]}var qr,Hr=function(t,e,r,n,i,o,a,s,l,u){var c=i.transform;return{u_is_size_zoom_constant:+("constant"===t||"source"===t),u_is_size_feature_constant:+("constant"===t||"camera"===t),u_size_t:e?e.uSizeT:0,u_size:e?e.uSize:0,u_camera_to_center_distance:c.cameraToCenterDistance,u_pitch:c.pitch/360*2*Math.PI,u_rotate_symbol:+r,u_aspect_ratio:c.width/c.height,u_fade_change:i.options.fadeDuration?i.symbolFadeChange:1,u_matrix:o,u_label_plane_matrix:a,u_coord_matrix:s,u_is_text:+l,u_pitch_with_map:+n,u_texsize:u,u_texture:0}},Gr=function(e,r,n,i,o,a,s,l,u,c,p){var h=o.transform;return t.extend(Hr(e,r,n,i,o,a,s,l,u,c),{u_gamma_scale:i?Math.cos(h._pitch)*h.cameraToCenterDistance:1,u_device_pixel_ratio:t.browser.devicePixelRatio,u_is_halo:+p})},Zr=function(e,r,n,i,o,a,s,l,u,c){return t.extend(Gr(e,r,n,i,o,a,s,l,!0,u,!0),{u_texsize_icon:c,u_texture_icon:1})},Wr=function(t,e,r){return{u_matrix:t,u_opacity:e,u_color:r}},Yr=function(e,r,n,i,o,a){return t.extend(function(t,e,r,n){var i=r.imageManager.getPattern(t.from.toString()),o=r.imageManager.getPattern(t.to.toString()),a=r.imageManager.getPixelSize(),s=a.width,l=a.height,u=Math.pow(2,n.tileID.overscaledZ),c=n.tileSize*Math.pow(2,r.transform.tileZoom)/u,p=c*(n.tileID.canonical.x+n.tileID.wrap*u),h=c*n.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:i.tl,u_pattern_br_a:i.br,u_pattern_tl_b:o.tl,u_pattern_br_b:o.br,u_texsize:[s,l],u_mix:e.t,u_pattern_size_a:i.displaySize,u_pattern_size_b:o.displaySize,u_scale_a:e.fromScale,u_scale_b:e.toScale,u_tile_units_to_pixels:1/he(n,1,r.transform.tileZoom),u_pixel_coord_upper:[p>>16,h>>16],u_pixel_coord_lower:[65535&p,65535&h]}}(i,a,n,o),{u_matrix:e,u_opacity:r})},Xr={fillExtrusion:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_lightpos:new t.Uniform3f(e,r.u_lightpos),u_lightintensity:new t.Uniform1f(e,r.u_lightintensity),u_lightcolor:new t.Uniform3f(e,r.u_lightcolor),u_vertical_gradient:new t.Uniform1f(e,r.u_vertical_gradient),u_opacity:new t.Uniform1f(e,r.u_opacity)}},fillExtrusionPattern:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_lightpos:new t.Uniform3f(e,r.u_lightpos),u_lightintensity:new t.Uniform1f(e,r.u_lightintensity),u_lightcolor:new t.Uniform3f(e,r.u_lightcolor),u_vertical_gradient:new t.Uniform1f(e,r.u_vertical_gradient),u_height_factor:new t.Uniform1f(e,r.u_height_factor),u_image:new t.Uniform1i(e,r.u_image),u_texsize:new t.Uniform2f(e,r.u_texsize),u_pixel_coord_upper:new t.Uniform2f(e,r.u_pixel_coord_upper),u_pixel_coord_lower:new t.Uniform2f(e,r.u_pixel_coord_lower),u_scale:new t.Uniform3f(e,r.u_scale),u_fade:new t.Uniform1f(e,r.u_fade),u_opacity:new t.Uniform1f(e,r.u_opacity)}},fill:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix)}},fillPattern:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_image:new t.Uniform1i(e,r.u_image),u_texsize:new t.Uniform2f(e,r.u_texsize),u_pixel_coord_upper:new t.Uniform2f(e,r.u_pixel_coord_upper),u_pixel_coord_lower:new t.Uniform2f(e,r.u_pixel_coord_lower),u_scale:new t.Uniform3f(e,r.u_scale),u_fade:new t.Uniform1f(e,r.u_fade)}},fillOutline:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_world:new t.Uniform2f(e,r.u_world)}},fillOutlinePattern:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_world:new t.Uniform2f(e,r.u_world),u_image:new t.Uniform1i(e,r.u_image),u_texsize:new t.Uniform2f(e,r.u_texsize),u_pixel_coord_upper:new t.Uniform2f(e,r.u_pixel_coord_upper),u_pixel_coord_lower:new t.Uniform2f(e,r.u_pixel_coord_lower),u_scale:new t.Uniform3f(e,r.u_scale),u_fade:new t.Uniform1f(e,r.u_fade)}},circle:function(e,r){return{u_camera_to_center_distance:new t.Uniform1f(e,r.u_camera_to_center_distance),u_scale_with_map:new t.Uniform1i(e,r.u_scale_with_map),u_pitch_with_map:new t.Uniform1i(e,r.u_pitch_with_map),u_extrude_scale:new t.Uniform2f(e,r.u_extrude_scale),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_matrix:new t.UniformMatrix4f(e,r.u_matrix)}},collisionBox:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_camera_to_center_distance:new t.Uniform1f(e,r.u_camera_to_center_distance),u_pixels_to_tile_units:new t.Uniform1f(e,r.u_pixels_to_tile_units),u_extrude_scale:new t.Uniform2f(e,r.u_extrude_scale),u_overscale_factor:new t.Uniform1f(e,r.u_overscale_factor)}},collisionCircle:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_inv_matrix:new t.UniformMatrix4f(e,r.u_inv_matrix),u_camera_to_center_distance:new t.Uniform1f(e,r.u_camera_to_center_distance),u_viewport_size:new t.Uniform2f(e,r.u_viewport_size)}},debug:function(e,r){return{u_color:new t.UniformColor(e,r.u_color),u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_overlay:new t.Uniform1i(e,r.u_overlay),u_overlay_scale:new t.Uniform1f(e,r.u_overlay_scale)}},clippingMask:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix)}},heatmap:function(e,r){return{u_extrude_scale:new t.Uniform1f(e,r.u_extrude_scale),u_intensity:new t.Uniform1f(e,r.u_intensity),u_matrix:new t.UniformMatrix4f(e,r.u_matrix)}},heatmapTexture:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_world:new t.Uniform2f(e,r.u_world),u_image:new t.Uniform1i(e,r.u_image),u_color_ramp:new t.Uniform1i(e,r.u_color_ramp),u_opacity:new t.Uniform1f(e,r.u_opacity)}},hillshade:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_image:new t.Uniform1i(e,r.u_image),u_latrange:new t.Uniform2f(e,r.u_latrange),u_light:new t.Uniform2f(e,r.u_light),u_shadow:new t.UniformColor(e,r.u_shadow),u_highlight:new t.UniformColor(e,r.u_highlight),u_accent:new t.UniformColor(e,r.u_accent)}},hillshadePrepare:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_image:new t.Uniform1i(e,r.u_image),u_dimension:new t.Uniform2f(e,r.u_dimension),u_zoom:new t.Uniform1f(e,r.u_zoom),u_unpack:new t.Uniform4f(e,r.u_unpack)}},line:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_ratio:new t.Uniform1f(e,r.u_ratio),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_units_to_pixels:new t.Uniform2f(e,r.u_units_to_pixels)}},lineGradient:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_ratio:new t.Uniform1f(e,r.u_ratio),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_units_to_pixels:new t.Uniform2f(e,r.u_units_to_pixels),u_image:new t.Uniform1i(e,r.u_image),u_image_height:new t.Uniform1f(e,r.u_image_height)}},linePattern:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_texsize:new t.Uniform2f(e,r.u_texsize),u_ratio:new t.Uniform1f(e,r.u_ratio),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_image:new t.Uniform1i(e,r.u_image),u_units_to_pixels:new t.Uniform2f(e,r.u_units_to_pixels),u_scale:new t.Uniform3f(e,r.u_scale),u_fade:new t.Uniform1f(e,r.u_fade)}},lineSDF:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_ratio:new t.Uniform1f(e,r.u_ratio),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_units_to_pixels:new t.Uniform2f(e,r.u_units_to_pixels),u_patternscale_a:new t.Uniform2f(e,r.u_patternscale_a),u_patternscale_b:new t.Uniform2f(e,r.u_patternscale_b),u_sdfgamma:new t.Uniform1f(e,r.u_sdfgamma),u_image:new t.Uniform1i(e,r.u_image),u_tex_y_a:new t.Uniform1f(e,r.u_tex_y_a),u_tex_y_b:new t.Uniform1f(e,r.u_tex_y_b),u_mix:new t.Uniform1f(e,r.u_mix)}},raster:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_tl_parent:new t.Uniform2f(e,r.u_tl_parent),u_scale_parent:new t.Uniform1f(e,r.u_scale_parent),u_buffer_scale:new t.Uniform1f(e,r.u_buffer_scale),u_fade_t:new t.Uniform1f(e,r.u_fade_t),u_opacity:new t.Uniform1f(e,r.u_opacity),u_image0:new t.Uniform1i(e,r.u_image0),u_image1:new t.Uniform1i(e,r.u_image1),u_brightness_low:new t.Uniform1f(e,r.u_brightness_low),u_brightness_high:new t.Uniform1f(e,r.u_brightness_high),u_saturation_factor:new t.Uniform1f(e,r.u_saturation_factor),u_contrast_factor:new t.Uniform1f(e,r.u_contrast_factor),u_spin_weights:new t.Uniform3f(e,r.u_spin_weights)}},symbolIcon:function(e,r){return{u_is_size_zoom_constant:new t.Uniform1i(e,r.u_is_size_zoom_constant),u_is_size_feature_constant:new t.Uniform1i(e,r.u_is_size_feature_constant),u_size_t:new t.Uniform1f(e,r.u_size_t),u_size:new t.Uniform1f(e,r.u_size),u_camera_to_center_distance:new t.Uniform1f(e,r.u_camera_to_center_distance),u_pitch:new t.Uniform1f(e,r.u_pitch),u_rotate_symbol:new t.Uniform1i(e,r.u_rotate_symbol),u_aspect_ratio:new t.Uniform1f(e,r.u_aspect_ratio),u_fade_change:new t.Uniform1f(e,r.u_fade_change),u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_label_plane_matrix:new t.UniformMatrix4f(e,r.u_label_plane_matrix),u_coord_matrix:new t.UniformMatrix4f(e,r.u_coord_matrix),u_is_text:new t.Uniform1i(e,r.u_is_text),u_pitch_with_map:new t.Uniform1i(e,r.u_pitch_with_map),u_texsize:new t.Uniform2f(e,r.u_texsize),u_texture:new t.Uniform1i(e,r.u_texture)}},symbolSDF:function(e,r){return{u_is_size_zoom_constant:new t.Uniform1i(e,r.u_is_size_zoom_constant),u_is_size_feature_constant:new t.Uniform1i(e,r.u_is_size_feature_constant),u_size_t:new t.Uniform1f(e,r.u_size_t),u_size:new t.Uniform1f(e,r.u_size),u_camera_to_center_distance:new t.Uniform1f(e,r.u_camera_to_center_distance),u_pitch:new t.Uniform1f(e,r.u_pitch),u_rotate_symbol:new t.Uniform1i(e,r.u_rotate_symbol),u_aspect_ratio:new t.Uniform1f(e,r.u_aspect_ratio),u_fade_change:new t.Uniform1f(e,r.u_fade_change),u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_label_plane_matrix:new t.UniformMatrix4f(e,r.u_label_plane_matrix),u_coord_matrix:new t.UniformMatrix4f(e,r.u_coord_matrix),u_is_text:new t.Uniform1i(e,r.u_is_text),u_pitch_with_map:new t.Uniform1i(e,r.u_pitch_with_map),u_texsize:new t.Uniform2f(e,r.u_texsize),u_texture:new t.Uniform1i(e,r.u_texture),u_gamma_scale:new t.Uniform1f(e,r.u_gamma_scale),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_is_halo:new t.Uniform1i(e,r.u_is_halo)}},symbolTextAndIcon:function(e,r){return{u_is_size_zoom_constant:new t.Uniform1i(e,r.u_is_size_zoom_constant),u_is_size_feature_constant:new t.Uniform1i(e,r.u_is_size_feature_constant),u_size_t:new t.Uniform1f(e,r.u_size_t),u_size:new t.Uniform1f(e,r.u_size),u_camera_to_center_distance:new t.Uniform1f(e,r.u_camera_to_center_distance),u_pitch:new t.Uniform1f(e,r.u_pitch),u_rotate_symbol:new t.Uniform1i(e,r.u_rotate_symbol),u_aspect_ratio:new t.Uniform1f(e,r.u_aspect_ratio),u_fade_change:new t.Uniform1f(e,r.u_fade_change),u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_label_plane_matrix:new t.UniformMatrix4f(e,r.u_label_plane_matrix),u_coord_matrix:new t.UniformMatrix4f(e,r.u_coord_matrix),u_is_text:new t.Uniform1i(e,r.u_is_text),u_pitch_with_map:new t.Uniform1i(e,r.u_pitch_with_map),u_texsize:new t.Uniform2f(e,r.u_texsize),u_texsize_icon:new t.Uniform2f(e,r.u_texsize_icon),u_texture:new t.Uniform1i(e,r.u_texture),u_texture_icon:new t.Uniform1i(e,r.u_texture_icon),u_gamma_scale:new t.Uniform1f(e,r.u_gamma_scale),u_device_pixel_ratio:new t.Uniform1f(e,r.u_device_pixel_ratio),u_is_halo:new t.Uniform1i(e,r.u_is_halo)}},background:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_opacity:new t.Uniform1f(e,r.u_opacity),u_color:new t.UniformColor(e,r.u_color)}},backgroundPattern:function(e,r){return{u_matrix:new t.UniformMatrix4f(e,r.u_matrix),u_opacity:new t.Uniform1f(e,r.u_opacity),u_image:new t.Uniform1i(e,r.u_image),u_pattern_tl_a:new t.Uniform2f(e,r.u_pattern_tl_a),u_pattern_br_a:new t.Uniform2f(e,r.u_pattern_br_a),u_pattern_tl_b:new t.Uniform2f(e,r.u_pattern_tl_b),u_pattern_br_b:new t.Uniform2f(e,r.u_pattern_br_b),u_texsize:new t.Uniform2f(e,r.u_texsize),u_mix:new t.Uniform1f(e,r.u_mix),u_pattern_size_a:new t.Uniform2f(e,r.u_pattern_size_a),u_pattern_size_b:new t.Uniform2f(e,r.u_pattern_size_b),u_scale_a:new t.Uniform1f(e,r.u_scale_a),u_scale_b:new t.Uniform1f(e,r.u_scale_b),u_pixel_coord_upper:new t.Uniform2f(e,r.u_pixel_coord_upper),u_pixel_coord_lower:new t.Uniform2f(e,r.u_pixel_coord_lower),u_tile_units_to_pixels:new t.Uniform1f(e,r.u_tile_units_to_pixels)}}};function Kr(e,r,n,i,o,a,s){for(var l=e.context,u=l.gl,c=e.useProgram("collisionBox"),p=[],h=0,f=0,d=0;d<i.length;d++){var m=i[d],g=r.getTile(m),y=g.getBucket(n);if(y){var v=m.posMatrix;0===o[0]&&0===o[1]||(v=e.translatePosMatrix(m.posMatrix,g,o,a));var _=s?y.textCollisionBox:y.iconCollisionBox,b=y.collisionCircleArray;if(b.length>0){var x=t.create(),w=v;t.mul(x,y.placementInvProjMatrix,e.transform.glCoordMatrix),t.mul(x,x,y.placementViewportMatrix),p.push({circleArray:b,circleOffset:f,transform:w,invTransform:x}),f=h+=b.length/4}_&&c.draw(l,u.LINES,At.disabled,Ct.disabled,e.colorModeForRenderPass(),Pt.disabled,Dr(v,e.transform,g),n.id,_.layoutVertexBuffer,_.indexBuffer,_.segments,null,e.transform.zoom,null,null,_.collisionVertexBuffer)}}if(s&&p.length){var E=e.useProgram("collisionCircle"),T=new t.StructArrayLayout2f1f2i16;T.resize(4*h),T._trim();for(var A=0,C=0,S=p;C<S.length;C+=1)for(var P=S[C],I=0;I<P.circleArray.length/4;I++){var D=4*I,O=P.circleArray[D+0],M=P.circleArray[D+1],B=P.circleArray[D+2],k=P.circleArray[D+3];T.emplace(A++,O,M,B,k,0),T.emplace(A++,O,M,B,k,1),T.emplace(A++,O,M,B,k,2),T.emplace(A++,O,M,B,k,3)}(!qr||qr.length<2*h)&&(qr=function(e){var r=2*e,n=new t.StructArrayLayout3ui6;n.resize(r),n._trim();for(var i=0;i<r;i++){var o=6*i;n.uint16[o+0]=4*i+0,n.uint16[o+1]=4*i+1,n.uint16[o+2]=4*i+2,n.uint16[o+3]=4*i+2,n.uint16[o+4]=4*i+3,n.uint16[o+5]=4*i+0}return n}(h));for(var F=l.createIndexBuffer(qr,!0),L=l.createVertexBuffer(T,t.collisionCircleLayout.members,!0),R=0,z=p;R<z.length;R+=1){var N=z[R],j=Or(N.transform,N.invTransform,e.transform);E.draw(l,u.TRIANGLES,At.disabled,Ct.disabled,e.colorModeForRenderPass(),Pt.disabled,j,n.id,L,F,t.SegmentVector.simpleSegment(0,2*N.circleOffset,N.circleArray.length,N.circleArray.length/2),null,e.transform.zoom,null,null,null)}L.destroy(),F.destroy()}}var Jr=t.identity(new Float32Array(16));function Qr(e,r,n,i,o,a){var s=t.getAnchorAlignment(e),l=-(s.horizontalAlign-.5)*r,u=-(s.verticalAlign-.5)*n,c=t.evaluateVariableOffset(e,i);return new t.Point((l/o+c[0])*a,(u/o+c[1])*a)}function $r(e,r,n,i,o,a,s,l,u,c,p){var h=e.text.placedSymbolArray,f=e.text.dynamicLayoutVertexArray,d=e.icon.dynamicLayoutVertexArray,m={};f.clear();for(var g=0;g<h.length;g++){var y=h.get(g),v=y.hidden||!y.crossTileID||e.allowVerticalPlacement&&!y.placedOrientation?null:i[y.crossTileID];if(v){var _=new t.Point(y.anchorX,y.anchorY),b=$t(_,n?l:s),x=te(a.cameraToCenterDistance,b.signedDistanceFromCamera),w=o.evaluateSizeForFeature(e.textSizeData,c,y)*x/t.ONE_EM;n&&(w*=e.tilePixelRatio/u);for(var E=Qr(v.anchor,v.width,v.height,v.textOffset,v.textBoxScale,w),T=n?$t(_.add(E),s).point:b.point.add(r?E.rotate(-a.angle):E),A=e.allowVerticalPlacement&&y.placedOrientation===t.WritingMode.vertical?Math.PI/2:0,C=0;C<y.numGlyphs;C++)t.addDynamicAttributes(f,T,A);p&&y.associatedIconIndex>=0&&(m[y.associatedIconIndex]={shiftedAnchor:T,angle:A})}else ue(y.numGlyphs,f)}if(p){d.clear();for(var S=e.icon.placedSymbolArray,P=0;P<S.length;P++){var I=S.get(P);if(I.hidden)ue(I.numGlyphs,d);else{var D=m[P];if(D)for(var O=0;O<I.numGlyphs;O++)t.addDynamicAttributes(d,D.shiftedAnchor,D.angle);else ue(I.numGlyphs,d)}}e.icon.dynamicLayoutVertexBuffer.updateData(d)}e.text.dynamicLayoutVertexBuffer.updateData(f)}function tn(t,e,r){return r.iconsInText&&e?"symbolTextAndIcon":t?"symbolSDF":"symbolIcon"}function en(e,r,n,i,o,a,s,l,u,c,p,h){for(var f=e.context,d=f.gl,m=e.transform,g="map"===l,y="map"===u,v=g&&"point"!==n.layout.get("symbol-placement"),_=g&&!y&&!v,b=void 0!==n.layout.get("symbol-sort-key").constantOr(1),x=!1,w=e.depthModeForSublayer(0,At.ReadOnly),E=n.layout.get("text-variable-anchor"),T=[],A=0,C=i;A<C.length;A+=1){var S=C[A],P=r.getTile(S),I=P.getBucket(n);if(I){var D=o?I.text:I.icon;if(D&&D.segments.get().length){var O=D.programConfigurations.get(n.id),M=o||I.sdfIcons,B=o?I.textSizeData:I.iconSizeData,k=y||0!==m.pitch,F=e.useProgram(tn(M,o,I),O),L=t.evaluateSizeForZoom(B,m.zoom),R=void 0,z=[0,0],N=void 0,j=void 0,U=null,V=void 0;if(o)N=P.glyphAtlasTexture,j=d.LINEAR,R=P.glyphAtlasTexture.size,I.iconsInText&&(z=P.imageAtlasTexture.size,U=P.imageAtlasTexture,V=k||e.options.rotating||e.options.zooming||"composite"===B.kind||"camera"===B.kind?d.LINEAR:d.NEAREST);else{var q=1!==n.layout.get("icon-size").constantOr(0)||I.iconsNeedLinear;N=P.imageAtlasTexture,j=M||e.options.rotating||e.options.zooming||q||k?d.LINEAR:d.NEAREST,R=P.imageAtlasTexture.size}var H=he(P,1,e.transform.zoom),G=Jt(S.posMatrix,y,g,e.transform,H),Z=Qt(S.posMatrix,y,g,e.transform,H),W=E&&I.hasTextData(),Y="none"!==n.layout.get("icon-text-fit")&&W&&I.hasIconData();v&&re(I,S.posMatrix,e,o,G,Z,y,c);var X=e.translatePosMatrix(S.posMatrix,P,a,s),K=v||o&&E||Y?Jr:G,J=e.translatePosMatrix(Z,P,a,s,!0),Q=M&&0!==n.paint.get(o?"text-halo-width":"icon-halo-width").constantOr(1),$={program:F,buffers:D,uniformValues:M?I.iconsInText?Zr(B.kind,L,_,y,e,X,K,J,R,z):Gr(B.kind,L,_,y,e,X,K,J,o,R,!0):Hr(B.kind,L,_,y,e,X,K,J,o,R),atlasTexture:N,atlasTextureIcon:U,atlasInterpolation:j,atlasInterpolationIcon:V,isSDF:M,hasHalo:Q};if(b&&I.canOverlap){x=!0;for(var tt=0,et=D.segments.get();tt<et.length;tt+=1){var rt=et[tt];T.push({segments:new t.SegmentVector([rt]),sortKey:rt.sortKey,state:$})}}else T.push({segments:D.segments,sortKey:0,state:$})}}}x&&T.sort((function(t,e){return t.sortKey-e.sortKey}));for(var nt=0,it=T;nt<it.length;nt+=1){var ot=it[nt],at=ot.state;if(f.activeTexture.set(d.TEXTURE0),at.atlasTexture.bind(at.atlasInterpolation,d.CLAMP_TO_EDGE),at.atlasTextureIcon&&(f.activeTexture.set(d.TEXTURE1),at.atlasTextureIcon&&at.atlasTextureIcon.bind(at.atlasInterpolationIcon,d.CLAMP_TO_EDGE)),at.isSDF){var st=at.uniformValues;at.hasHalo&&(st.u_is_halo=1,rn(at.buffers,ot.segments,n,e,at.program,w,p,h,st)),st.u_is_halo=0}rn(at.buffers,ot.segments,n,e,at.program,w,p,h,at.uniformValues)}}function rn(t,e,r,n,i,o,a,s,l){var u=n.context;i.draw(u,u.gl.TRIANGLES,o,a,s,Pt.disabled,l,r.id,t.layoutVertexBuffer,t.indexBuffer,e,r.paint,n.transform.zoom,t.programConfigurations.get(r.id),t.dynamicLayoutVertexBuffer,t.opacityVertexBuffer)}function nn(t,e,r,n,i,o,a){var s,l,u,c,p,h=t.context.gl,f=r.paint.get("fill-pattern"),d=f&&f.constantOr(1),m=r.getCrossfadeParameters();a?(l=d&&!r.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",s=h.LINES):(l=d?"fillPattern":"fill",s=h.TRIANGLES);for(var g=0,y=n;g<y.length;g+=1){var v=y[g],_=e.getTile(v);if(!d||_.patternsLoaded()){var b=_.getBucket(r);if(b){var x=b.programConfigurations.get(r.id),w=t.useProgram(l,x);d&&(t.context.activeTexture.set(h.TEXTURE0),_.imageAtlasTexture.bind(h.LINEAR,h.CLAMP_TO_EDGE),x.updatePaintBuffers(m));var E=f.constantOr(null);if(E&&_.imageAtlas){var T=_.imageAtlas,A=T.patternPositions[E.to.toString()],C=T.patternPositions[E.from.toString()];A&&C&&x.setConstantPatternPositions(A,C)}var S=t.translatePosMatrix(v.posMatrix,_,r.paint.get("fill-translate"),r.paint.get("fill-translate-anchor"));if(a){c=b.indexBuffer2,p=b.segments2;var P=[h.drawingBufferWidth,h.drawingBufferHeight];u="fillOutlinePattern"===l&&d?Pr(S,t,m,_,P):Sr(S,P)}else c=b.indexBuffer,p=b.segments,u=d?Cr(S,t,m,_):Ar(S);w.draw(t.context,s,i,t.stencilModeForClipping(v),o,Pt.disabled,u,r.id,b.layoutVertexBuffer,c,p,r.paint,t.transform.zoom,x)}}}}function on(t,e,r,n,i,o,a){for(var s=t.context,l=s.gl,u=r.paint.get("fill-extrusion-pattern"),c=u.constantOr(1),p=r.getCrossfadeParameters(),h=r.paint.get("fill-extrusion-opacity"),f=0,d=n;f<d.length;f+=1){var m=d[f],g=e.getTile(m),y=g.getBucket(r);if(y){var v=y.programConfigurations.get(r.id),_=t.useProgram(c?"fillExtrusionPattern":"fillExtrusion",v);c&&(t.context.activeTexture.set(l.TEXTURE0),g.imageAtlasTexture.bind(l.LINEAR,l.CLAMP_TO_EDGE),v.updatePaintBuffers(p));var b=u.constantOr(null);if(b&&g.imageAtlas){var x=g.imageAtlas,w=x.patternPositions[b.to.toString()],E=x.patternPositions[b.from.toString()];w&&E&&v.setConstantPatternPositions(w,E)}var T=t.translatePosMatrix(m.posMatrix,g,r.paint.get("fill-extrusion-translate"),r.paint.get("fill-extrusion-translate-anchor")),A=r.paint.get("fill-extrusion-vertical-gradient"),C=c?Tr(T,t,A,h,m,p,g):Er(T,t,A,h);_.draw(s,s.gl.TRIANGLES,i,o,a,Pt.backCCW,C,r.id,y.layoutVertexBuffer,y.indexBuffer,y.segments,r.paint,t.transform.zoom,v)}}}function an(e,r,n,i,o,a){var s=e.context,l=s.gl,u=r.fbo;if(u){var c=e.useProgram("hillshade");s.activeTexture.set(l.TEXTURE0),l.bindTexture(l.TEXTURE_2D,u.colorAttachment.get());var p=function(e,r,n){var i=n.paint.get("hillshade-shadow-color"),o=n.paint.get("hillshade-highlight-color"),a=n.paint.get("hillshade-accent-color"),s=n.paint.get("hillshade-illumination-direction")*(Math.PI/180);"viewport"===n.paint.get("hillshade-illumination-anchor")&&(s-=e.transform.angle);var l,u,c,p=!e.options.moving;return{u_matrix:e.transform.calculatePosMatrix(r.tileID.toUnwrapped(),p),u_image:0,u_latrange:(l=r.tileID,u=Math.pow(2,l.canonical.z),c=l.canonical.y,[new t.MercatorCoordinate(0,c/u).toLngLat().lat,new t.MercatorCoordinate(0,(c+1)/u).toLngLat().lat]),u_light:[n.paint.get("hillshade-exaggeration"),s],u_shadow:i,u_highlight:o,u_accent:a}}(e,r,n);c.draw(s,l.TRIANGLES,i,o,a,Pt.disabled,p,n.id,e.rasterBoundsBuffer,e.quadTriangleIndexBuffer,e.rasterBoundsSegments)}}function sn(e,r,n,i,o,a){var s=e.context,l=s.gl,u=r.dem;if(u&&u.data){var c=u.dim,p=u.stride,h=u.getPixels();if(s.activeTexture.set(l.TEXTURE1),s.pixelStoreUnpackPremultiplyAlpha.set(!1),r.demTexture=r.demTexture||e.getTileTexture(p),r.demTexture){var f=r.demTexture;f.update(h,{premultiply:!1}),f.bind(l.NEAREST,l.CLAMP_TO_EDGE)}else r.demTexture=new t.Texture(s,h,l.RGBA,{premultiply:!1}),r.demTexture.bind(l.NEAREST,l.CLAMP_TO_EDGE);s.activeTexture.set(l.TEXTURE0);var d=r.fbo;if(!d){var m=new t.Texture(s,{width:c,height:c,data:null},l.RGBA);m.bind(l.LINEAR,l.CLAMP_TO_EDGE),(d=r.fbo=s.createFramebuffer(c,c,!0)).colorAttachment.set(m.texture)}s.bindFramebuffer.set(d.framebuffer),s.viewport.set([0,0,c,c]),e.useProgram("hillshadePrepare").draw(s,l.TRIANGLES,i,o,a,Pt.disabled,function(e,r){var n=r.stride,i=t.create();return t.ortho(i,0,t.EXTENT,-t.EXTENT,0,0,1),t.translate(i,i,[0,-t.EXTENT,0]),{u_matrix:i,u_image:1,u_dimension:[n,n],u_zoom:e.overscaledZ,u_unpack:r.getUnpackVector()}}(r.tileID,u),n.id,e.rasterBoundsBuffer,e.quadTriangleIndexBuffer,e.rasterBoundsSegments),r.needsHillshadePrepare=!1}}function ln(e,r,n,i,o){var a=i.paint.get("raster-fade-duration");if(a>0){var s=t.browser.now(),l=(s-e.timeAdded)/a,u=r?(s-r.timeAdded)/a:-1,c=n.getSource(),p=o.coveringZoomLevel({tileSize:c.tileSize,roundZoom:c.roundZoom}),h=!r||Math.abs(r.tileID.overscaledZ-p)>Math.abs(e.tileID.overscaledZ-p),f=h&&e.refreshedUponExpiration?1:t.clamp(h?l:1-u,0,1);return e.refreshedUponExpiration&&l>=1&&(e.refreshedUponExpiration=!1),r?{opacity:1,mix:1-f}:{opacity:f,mix:0}}return{opacity:1,mix:0}}var un=new t.Color(1,0,0,1),cn=new t.Color(0,1,0,1),pn=new t.Color(0,0,1,1),hn=new t.Color(1,0,1,1),fn=new t.Color(0,1,1,1);function dn(t,e,r,n){gn(t,0,e+r/2,t.transform.width,r,n)}function mn(t,e,r,n){gn(t,e-r/2,0,r,t.transform.height,n)}function gn(e,r,n,i,o,a){var s=e.context,l=s.gl;l.enable(l.SCISSOR_TEST),l.scissor(r*t.browser.devicePixelRatio,n*t.browser.devicePixelRatio,i*t.browser.devicePixelRatio,o*t.browser.devicePixelRatio),s.clear({color:a}),l.disable(l.SCISSOR_TEST)}function yn(e,r,n){var i=e.context,o=i.gl,a=n.posMatrix,s=e.useProgram("debug"),l=At.disabled,u=Ct.disabled,c=e.colorModeForRenderPass();i.activeTexture.set(o.TEXTURE0),e.emptyTexture.bind(o.LINEAR,o.CLAMP_TO_EDGE),s.draw(i,o.LINE_STRIP,l,u,c,Pt.disabled,Mr(a,t.Color.red),"$debug",e.debugBuffer,e.tileBorderIndexBuffer,e.debugSegments);var p=r.getTileByID(n.key).latestRawTileData,h=Math.floor((p&&p.byteLength||0)/1024),f=r.getTile(n).tileSize,d=512/Math.min(f,512)*(n.overscaledZ/e.transform.zoom)*.5,m=n.canonical.toString();n.overscaledZ!==n.canonical.z&&(m+=" => "+n.overscaledZ),function(t,e){t.initDebugOverlayCanvas();var r=t.debugOverlayCanvas,n=t.context.gl,i=t.debugOverlayCanvas.getContext("2d");i.clearRect(0,0,r.width,r.height),i.shadowColor="white",i.shadowBlur=2,i.lineWidth=1.5,i.strokeStyle="white",i.textBaseline="top",i.font="bold 36px Open Sans, sans-serif",i.fillText(e,5,5),i.strokeText(e,5,5),t.debugOverlayTexture.update(r),t.debugOverlayTexture.bind(n.LINEAR,n.CLAMP_TO_EDGE)}(e,m+" "+h+"kb"),s.draw(i,o.TRIANGLES,l,u,St.alphaBlended,Pt.disabled,Mr(a,t.Color.transparent,d),"$debug",e.debugBuffer,e.quadTriangleIndexBuffer,e.debugSegments)}var vn={symbol:function(e,r,n,i,o){if("translucent"===e.renderPass){var a=Ct.disabled,s=e.colorModeForRenderPass();n.layout.get("text-variable-anchor")&&function(e,r,n,i,o,a,s){for(var l=r.transform,u="map"===o,c="map"===a,p=0,h=e;p<h.length;p+=1){var f=h[p],d=i.getTile(f),m=d.getBucket(n);if(m&&m.text&&m.text.segments.get().length){var g=t.evaluateSizeForZoom(m.textSizeData,l.zoom),y=he(d,1,r.transform.zoom),v=Jt(f.posMatrix,c,u,r.transform,y),_="none"!==n.layout.get("icon-text-fit")&&m.hasIconData();if(g){var b=Math.pow(2,l.zoom-d.tileID.overscaledZ);$r(m,u,c,s,t.symbolSize,l,v,f.posMatrix,b,g,_)}}}}(i,e,n,r,n.layout.get("text-rotation-alignment"),n.layout.get("text-pitch-alignment"),o),0!==n.paint.get("icon-opacity").constantOr(1)&&en(e,r,n,i,!1,n.paint.get("icon-translate"),n.paint.get("icon-translate-anchor"),n.layout.get("icon-rotation-alignment"),n.layout.get("icon-pitch-alignment"),n.layout.get("icon-keep-upright"),a,s),0!==n.paint.get("text-opacity").constantOr(1)&&en(e,r,n,i,!0,n.paint.get("text-translate"),n.paint.get("text-translate-anchor"),n.layout.get("text-rotation-alignment"),n.layout.get("text-pitch-alignment"),n.layout.get("text-keep-upright"),a,s),r.map.showCollisionBoxes&&(Kr(e,r,n,i,n.paint.get("text-translate"),n.paint.get("text-translate-anchor"),!0),Kr(e,r,n,i,n.paint.get("icon-translate"),n.paint.get("icon-translate-anchor"),!1))}},circle:function(e,r,n,i){if("translucent"===e.renderPass){var o=n.paint.get("circle-opacity"),a=n.paint.get("circle-stroke-width"),s=n.paint.get("circle-stroke-opacity"),l=void 0!==n.layout.get("circle-sort-key").constantOr(1);if(0!==o.constantOr(1)||0!==a.constantOr(1)&&0!==s.constantOr(1)){for(var u=e.context,c=u.gl,p=e.depthModeForSublayer(0,At.ReadOnly),h=Ct.disabled,f=e.colorModeForRenderPass(),d=[],m=0;m<i.length;m++){var g=i[m],y=r.getTile(g),v=y.getBucket(n);if(v){var _=v.programConfigurations.get(n.id),b={programConfiguration:_,program:e.useProgram("circle",_),layoutVertexBuffer:v.layoutVertexBuffer,indexBuffer:v.indexBuffer,uniformValues:Ir(e,g,y,n)};if(l)for(var x=0,w=v.segments.get();x<w.length;x+=1){var E=w[x];d.push({segments:new t.SegmentVector([E]),sortKey:E.sortKey,state:b})}else d.push({segments:v.segments,sortKey:0,state:b})}}l&&d.sort((function(t,e){return t.sortKey-e.sortKey}));for(var T=0,A=d;T<A.length;T+=1){var C=A[T],S=C.state;S.program.draw(u,c.TRIANGLES,p,h,f,Pt.disabled,S.uniformValues,n.id,S.layoutVertexBuffer,S.indexBuffer,C.segments,n.paint,e.transform.zoom,S.programConfiguration)}}}},heatmap:function(e,r,n,i){if(0!==n.paint.get("heatmap-opacity"))if("offscreen"===e.renderPass){var o=e.context,a=o.gl,s=Ct.disabled,l=new St([a.ONE,a.ONE],t.Color.transparent,[!0,!0,!0,!0]);!function(t,e,r){var n=t.gl;t.activeTexture.set(n.TEXTURE1),t.viewport.set([0,0,e.width/4,e.height/4]);var i=r.heatmapFbo;if(i)n.bindTexture(n.TEXTURE_2D,i.colorAttachment.get()),t.bindFramebuffer.set(i.framebuffer);else{var o=n.createTexture();n.bindTexture(n.TEXTURE_2D,o),n.texParameteri(n.TEXTURE_2D,n.TEXTURE_WRAP_S,n.CLAMP_TO_EDGE),n.texParameteri(n.TEXTURE_2D,n.TEXTURE_WRAP_T,n.CLAMP_TO_EDGE),n.texParameteri(n.TEXTURE_2D,n.TEXTURE_MIN_FILTER,n.LINEAR),n.texParameteri(n.TEXTURE_2D,n.TEXTURE_MAG_FILTER,n.LINEAR),i=r.heatmapFbo=t.createFramebuffer(e.width/4,e.height/4,!1),function(t,e,r,n){var i=t.gl;i.texImage2D(i.TEXTURE_2D,0,i.RGBA,e.width/4,e.height/4,0,i.RGBA,t.extRenderToTextureHalfFloat?t.extTextureHalfFloat.HALF_FLOAT_OES:i.UNSIGNED_BYTE,null),n.colorAttachment.set(r)}(t,e,o,i)}}(o,e,n),o.clear({color:t.Color.transparent});for(var u=0;u<i.length;u++){var c=i[u];if(!r.hasRenderableParent(c)){var p=r.getTile(c),h=p.getBucket(n);if(h){var f=h.programConfigurations.get(n.id);e.useProgram("heatmap",f).draw(o,a.TRIANGLES,At.disabled,s,l,Pt.disabled,kr(c.posMatrix,p,e.transform.zoom,n.paint.get("heatmap-intensity")),n.id,h.layoutVertexBuffer,h.indexBuffer,h.segments,n.paint,e.transform.zoom,f)}}}o.viewport.set([0,0,e.width,e.height])}else"translucent"===e.renderPass&&(e.context.setColorMode(e.colorModeForRenderPass()),function(e,r){var n=e.context,i=n.gl,o=r.heatmapFbo;if(o){n.activeTexture.set(i.TEXTURE0),i.bindTexture(i.TEXTURE_2D,o.colorAttachment.get()),n.activeTexture.set(i.TEXTURE1);var a=r.colorRampTexture;a||(a=r.colorRampTexture=new t.Texture(n,r.colorRamp,i.RGBA)),a.bind(i.LINEAR,i.CLAMP_TO_EDGE),e.useProgram("heatmapTexture").draw(n,i.TRIANGLES,At.disabled,Ct.disabled,e.colorModeForRenderPass(),Pt.disabled,function(e,r,n,i){var o=t.create();t.ortho(o,0,e.width,e.height,0,0,1);var a=e.context.gl;return{u_matrix:o,u_world:[a.drawingBufferWidth,a.drawingBufferHeight],u_image:0,u_color_ramp:1,u_opacity:r.paint.get("heatmap-opacity")}}(e,r),r.id,e.viewportBuffer,e.quadTriangleIndexBuffer,e.viewportSegments,r.paint,e.transform.zoom)}}(e,n))},line:function(e,r,n,i){if("translucent"===e.renderPass){var o=n.paint.get("line-opacity"),a=n.paint.get("line-width");if(0!==o.constantOr(1)&&0!==a.constantOr(1))for(var s=e.depthModeForSublayer(0,At.ReadOnly),l=e.colorModeForRenderPass(),u=n.paint.get("line-dasharray"),c=n.paint.get("line-pattern"),p=c.constantOr(1),h=n.paint.get("line-gradient"),f=n.getCrossfadeParameters(),d=p?"linePattern":u?"lineSDF":h?"lineGradient":"line",m=e.context,g=m.gl,y=!0,v=0,_=i;v<_.length;v+=1){var b=_[v],x=r.getTile(b);if(!p||x.patternsLoaded()){var w=x.getBucket(n);if(w){var E=w.programConfigurations.get(n.id),T=e.context.program.get(),A=e.useProgram(d,E),C=y||A.program!==T,S=c.constantOr(null);if(S&&x.imageAtlas){var P=x.imageAtlas,I=P.patternPositions[S.to.toString()],D=P.patternPositions[S.from.toString()];I&&D&&E.setConstantPatternPositions(I,D)}var O=p?Rr(e,x,n,f):u?zr(e,x,n,u,f):h?Lr(e,x,n,w.lineClipsArray.length):Fr(e,x,n);if(p)m.activeTexture.set(g.TEXTURE0),x.imageAtlasTexture.bind(g.LINEAR,g.CLAMP_TO_EDGE),E.updatePaintBuffers(f);else if(u&&(C||e.lineAtlas.dirty))m.activeTexture.set(g.TEXTURE0),e.lineAtlas.bind(m);else if(h){var M=w.gradients[n.id],B=M.texture;if(n.gradientVersion!==M.version){var k=256;if(n.stepInterpolant){var F=r.getSource().maxzoom,L=b.canonical.z===F?Math.ceil(1<<e.transform.maxZoom-b.canonical.z):1;k=t.clamp(t.nextPowerOfTwo(w.maxLineLength/t.EXTENT*1024*L),256,m.maxTextureSize)}M.gradient=t.renderColorRamp({expression:n.gradientExpression(),evaluationKey:"lineProgress",resolution:k,image:M.gradient||void 0,clips:w.lineClipsArray}),M.texture?M.texture.update(M.gradient):M.texture=new t.Texture(m,M.gradient,g.RGBA),M.version=n.gradientVersion,B=M.texture}m.activeTexture.set(g.TEXTURE0),B.bind(n.stepInterpolant?g.NEAREST:g.LINEAR,g.CLAMP_TO_EDGE)}A.draw(m,g.TRIANGLES,s,e.stencilModeForClipping(b),l,Pt.disabled,O,n.id,w.layoutVertexBuffer,w.indexBuffer,w.segments,n.paint,e.transform.zoom,E,w.layoutVertexBuffer2),y=!1}}}}},fill:function(e,r,n,i){var o=n.paint.get("fill-color"),a=n.paint.get("fill-opacity");if(0!==a.constantOr(1)){var s=e.colorModeForRenderPass(),l=n.paint.get("fill-pattern"),u=e.opaquePassEnabledForLayer()&&!l.constantOr(1)&&1===o.constantOr(t.Color.transparent).a&&1===a.constantOr(0)?"opaque":"translucent";if(e.renderPass===u){var c=e.depthModeForSublayer(1,"opaque"===e.renderPass?At.ReadWrite:At.ReadOnly);nn(e,r,n,i,c,s,!1)}if("translucent"===e.renderPass&&n.paint.get("fill-antialias")){var p=e.depthModeForSublayer(n.getPaintProperty("fill-outline-color")?2:0,At.ReadOnly);nn(e,r,n,i,p,s,!0)}}},"fill-extrusion":function(t,e,r,n){var i=r.paint.get("fill-extrusion-opacity");if(0!==i&&"translucent"===t.renderPass){var o=new At(t.context.gl.LEQUAL,At.ReadWrite,t.depthRangeFor3D);if(1!==i||r.paint.get("fill-extrusion-pattern").constantOr(1))on(t,e,r,n,o,Ct.disabled,St.disabled),on(t,e,r,n,o,t.stencilModeFor3D(),t.colorModeForRenderPass());else{var a=t.colorModeForRenderPass();on(t,e,r,n,o,Ct.disabled,a)}}},hillshade:function(t,e,r,n){if("offscreen"===t.renderPass||"translucent"===t.renderPass){for(var i=t.context,o=t.depthModeForSublayer(0,At.ReadOnly),a=t.colorModeForRenderPass(),s="translucent"===t.renderPass?t.stencilConfigForOverlap(n):[{},n],l=s[0],u=0,c=s[1];u<c.length;u+=1){var p=c[u],h=e.getTile(p);h.needsHillshadePrepare&&"offscreen"===t.renderPass?sn(t,h,r,o,Ct.disabled,a):"translucent"===t.renderPass&&an(t,h,r,o,l[p.overscaledZ],a)}i.viewport.set([0,0,t.width,t.height])}},raster:function(t,e,r,n){if("translucent"===t.renderPass&&0!==r.paint.get("raster-opacity")&&n.length)for(var i=t.context,o=i.gl,a=e.getSource(),s=t.useProgram("raster"),l=t.colorModeForRenderPass(),u=a instanceof M?[{},n]:t.stencilConfigForOverlap(n),c=u[0],p=u[1],h=p[p.length-1].overscaledZ,f=!t.options.moving,d=0,m=p;d<m.length;d+=1){var g=m[d],y=t.depthModeForSublayer(g.overscaledZ-h,1===r.paint.get("raster-opacity")?At.ReadWrite:At.ReadOnly,o.LESS),v=e.getTile(g),_=t.transform.calculatePosMatrix(g.toUnwrapped(),f);v.registerFadeDuration(r.paint.get("raster-fade-duration"));var b=e.findLoadedParent(g,0),x=ln(v,b,e,r,t.transform),w=void 0,E=void 0,T="nearest"===r.paint.get("raster-resampling")?o.NEAREST:o.LINEAR;i.activeTexture.set(o.TEXTURE0),v.texture.bind(T,o.CLAMP_TO_EDGE,o.LINEAR_MIPMAP_NEAREST),i.activeTexture.set(o.TEXTURE1),b?(b.texture.bind(T,o.CLAMP_TO_EDGE,o.LINEAR_MIPMAP_NEAREST),w=Math.pow(2,b.tileID.overscaledZ-v.tileID.overscaledZ),E=[v.tileID.canonical.x*w%1,v.tileID.canonical.y*w%1]):v.texture.bind(T,o.CLAMP_TO_EDGE,o.LINEAR_MIPMAP_NEAREST);var A=Ur(_,E||[0,0],w||1,x,r);a instanceof M?s.draw(i,o.TRIANGLES,y,Ct.disabled,l,Pt.disabled,A,r.id,a.boundsBuffer,t.quadTriangleIndexBuffer,a.boundsSegments):s.draw(i,o.TRIANGLES,y,c[g.overscaledZ],l,Pt.disabled,A,r.id,t.rasterBoundsBuffer,t.quadTriangleIndexBuffer,t.rasterBoundsSegments)}},background:function(t,e,r){var n=r.paint.get("background-color"),i=r.paint.get("background-opacity");if(0!==i){var o=t.context,a=o.gl,s=t.transform,l=s.tileSize,u=r.paint.get("background-pattern");if(!t.isPatternMissing(u)){var c=!u&&1===n.a&&1===i&&t.opaquePassEnabledForLayer()?"opaque":"translucent";if(t.renderPass===c){var p=Ct.disabled,h=t.depthModeForSublayer(0,"opaque"===c?At.ReadWrite:At.ReadOnly),f=t.colorModeForRenderPass(),d=t.useProgram(u?"backgroundPattern":"background"),m=s.coveringTiles({tileSize:l});u&&(o.activeTexture.set(a.TEXTURE0),t.imageManager.bind(t.context));for(var g=r.getCrossfadeParameters(),y=0,v=m;y<v.length;y+=1){var _=v[y],b=t.transform.calculatePosMatrix(_.toUnwrapped()),x=u?Yr(b,i,t,u,{tileID:_,tileSize:l},g):Wr(b,i,n);d.draw(o,a.TRIANGLES,h,p,f,Pt.disabled,x,r.id,t.tileExtentBuffer,t.quadTriangleIndexBuffer,t.tileExtentSegments)}}}}},debug:function(t,e,r){for(var n=0;n<r.length;n++)yn(t,e,r[n])},custom:function(t,e,r){var n=t.context,i=r.implementation;if("offscreen"===t.renderPass){var o=i.prerender;o&&(t.setCustomLayerDefaults(),n.setColorMode(t.colorModeForRenderPass()),o.call(i,n.gl,t.transform.customLayerMatrix()),n.setDirty(),t.setBaseState())}else if("translucent"===t.renderPass){t.setCustomLayerDefaults(),n.setColorMode(t.colorModeForRenderPass()),n.setStencilMode(Ct.disabled);var a="3d"===i.renderingMode?new At(t.context.gl.LEQUAL,At.ReadWrite,t.depthRangeFor3D):t.depthModeForSublayer(0,At.ReadOnly);n.setDepthMode(a),i.render(n.gl,t.transform.customLayerMatrix()),n.setDirty(),t.setBaseState(),n.bindFramebuffer.set(null)}}},_n=function(t,e){this.context=new It(t),this.transform=e,this._tileTextures={},this.setup(),this.numSublayers=Dt.maxUnderzooming+Dt.maxOverzooming+1,this.depthEpsilon=1/Math.pow(2,16),this.crossTileSymbolIndex=new ze,this.gpuTimers={}};_n.prototype.resize=function(e,r){if(this.width=e*t.browser.devicePixelRatio,this.height=r*t.browser.devicePixelRatio,this.context.viewport.set([0,0,this.width,this.height]),this.style)for(var n=0,i=this.style._order;n<i.length;n+=1)this.style._layers[i[n]].resize()},_n.prototype.setup=function(){var e=this.context,r=new t.StructArrayLayout2i4;r.emplaceBack(0,0),r.emplaceBack(t.EXTENT,0),r.emplaceBack(0,t.EXTENT),r.emplaceBack(t.EXTENT,t.EXTENT),this.tileExtentBuffer=e.createVertexBuffer(r,He.members),this.tileExtentSegments=t.SegmentVector.simpleSegment(0,0,4,2);var n=new t.StructArrayLayout2i4;n.emplaceBack(0,0),n.emplaceBack(t.EXTENT,0),n.emplaceBack(0,t.EXTENT),n.emplaceBack(t.EXTENT,t.EXTENT),this.debugBuffer=e.createVertexBuffer(n,He.members),this.debugSegments=t.SegmentVector.simpleSegment(0,0,4,5);var i=new t.StructArrayLayout4i8;i.emplaceBack(0,0,0,0),i.emplaceBack(t.EXTENT,0,t.EXTENT,0),i.emplaceBack(0,t.EXTENT,0,t.EXTENT),i.emplaceBack(t.EXTENT,t.EXTENT,t.EXTENT,t.EXTENT),this.rasterBoundsBuffer=e.createVertexBuffer(i,O.members),this.rasterBoundsSegments=t.SegmentVector.simpleSegment(0,0,4,2);var o=new t.StructArrayLayout2i4;o.emplaceBack(0,0),o.emplaceBack(1,0),o.emplaceBack(0,1),o.emplaceBack(1,1),this.viewportBuffer=e.createVertexBuffer(o,He.members),this.viewportSegments=t.SegmentVector.simpleSegment(0,0,4,2);var a=new t.StructArrayLayout1ui2;a.emplaceBack(0),a.emplaceBack(1),a.emplaceBack(3),a.emplaceBack(2),a.emplaceBack(0),this.tileBorderIndexBuffer=e.createIndexBuffer(a);var s=new t.StructArrayLayout3ui6;s.emplaceBack(0,1,2),s.emplaceBack(2,1,3),this.quadTriangleIndexBuffer=e.createIndexBuffer(s),this.emptyTexture=new t.Texture(e,{width:1,height:1,data:new Uint8Array([0,0,0,0])},e.gl.RGBA);var l=this.context.gl;this.stencilClearMode=new Ct({func:l.ALWAYS,mask:0},0,255,l.ZERO,l.ZERO,l.ZERO)},_n.prototype.clearStencil=function(){var e=this.context,r=e.gl;this.nextStencilID=1,this.currentStencilSource=void 0;var n=t.create();t.ortho(n,0,this.width,this.height,0,0,1),t.scale(n,n,[r.drawingBufferWidth,r.drawingBufferHeight,0]),this.useProgram("clippingMask").draw(e,r.TRIANGLES,At.disabled,this.stencilClearMode,St.disabled,Pt.disabled,Br(n),"$clipping",this.viewportBuffer,this.quadTriangleIndexBuffer,this.viewportSegments)},_n.prototype._renderTileClippingMasks=function(t,e){if(this.currentStencilSource!==t.source&&t.isTileClipped()&&e&&e.length){this.currentStencilSource=t.source;var r=this.context,n=r.gl;this.nextStencilID+e.length>256&&this.clearStencil(),r.setColorMode(St.disabled),r.setDepthMode(At.disabled);var i=this.useProgram("clippingMask");this._tileClippingMaskIDs={};for(var o=0,a=e;o<a.length;o+=1){var s=a[o],l=this._tileClippingMaskIDs[s.key]=this.nextStencilID++;i.draw(r,n.TRIANGLES,At.disabled,new Ct({func:n.ALWAYS,mask:0},l,255,n.KEEP,n.KEEP,n.REPLACE),St.disabled,Pt.disabled,Br(s.posMatrix),"$clipping",this.tileExtentBuffer,this.quadTriangleIndexBuffer,this.tileExtentSegments)}}},_n.prototype.stencilModeFor3D=function(){this.currentStencilSource=void 0,this.nextStencilID+1>256&&this.clearStencil();var t=this.nextStencilID++,e=this.context.gl;return new Ct({func:e.NOTEQUAL,mask:255},t,255,e.KEEP,e.KEEP,e.REPLACE)},_n.prototype.stencilModeForClipping=function(t){var e=this.context.gl;return new Ct({func:e.EQUAL,mask:255},this._tileClippingMaskIDs[t.key],0,e.KEEP,e.KEEP,e.REPLACE)},_n.prototype.stencilConfigForOverlap=function(t){var e,r=this.context.gl,n=t.sort((function(t,e){return e.overscaledZ-t.overscaledZ})),i=n[n.length-1].overscaledZ,o=n[0].overscaledZ-i+1;if(o>1){this.currentStencilSource=void 0,this.nextStencilID+o>256&&this.clearStencil();for(var a={},s=0;s<o;s++)a[s+i]=new Ct({func:r.GEQUAL,mask:255},s+this.nextStencilID,255,r.KEEP,r.KEEP,r.REPLACE);return this.nextStencilID+=o,[a,n]}return[(e={},e[i]=Ct.disabled,e),n]},_n.prototype.colorModeForRenderPass=function(){var e=this.context.gl;return this._showOverdrawInspector?new St([e.CONSTANT_COLOR,e.ONE],new t.Color(1/8,1/8,1/8,0),[!0,!0,!0,!0]):"opaque"===this.renderPass?St.unblended:St.alphaBlended},_n.prototype.depthModeForSublayer=function(t,e,r){if(!this.opaquePassEnabledForLayer())return At.disabled;var n=1-((1+this.currentLayer)*this.numSublayers+t)*this.depthEpsilon;return new At(r||this.context.gl.LEQUAL,e,[n,n])},_n.prototype.opaquePassEnabledForLayer=function(){return this.currentLayer<this.opaquePassCutoff},_n.prototype.render=function(e,r){var n=this;this.style=e,this.options=r,this.lineAtlas=e.lineAtlas,this.imageManager=e.imageManager,this.glyphManager=e.glyphManager,this.symbolFadeChange=e.placement.symbolFadeChange(t.browser.now()),this.imageManager.beginFrame();var i=this.style._order,o=this.style.sourceCaches;for(var a in o){var s=o[a];s.used&&s.prepare(this.context)}var l,u,c={},p={},h={};for(var f in o){var d=o[f];c[f]=d.getVisibleCoordinates(),p[f]=c[f].slice().reverse(),h[f]=d.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(var m=0;m<i.length;m++)if(this.style._layers[i[m]].is3D()){this.opaquePassCutoff=m;break}this.renderPass="offscreen";for(var g=0,y=i;g<y.length;g+=1){var v=this.style._layers[y[g]];if(v.hasOffscreenPass()&&!v.isHidden(this.transform.zoom)){var _=p[v.source];("custom"===v.type||_.length)&&this.renderLayer(this,o[v.source],v,_)}}for(this.context.bindFramebuffer.set(null),this.context.clear({color:r.showOverdrawInspector?t.Color.black:t.Color.transparent,depth:1}),this.clearStencil(),this._showOverdrawInspector=r.showOverdrawInspector,this.depthRangeFor3D=[0,1-(e._order.length+2)*this.numSublayers*this.depthEpsilon],this.renderPass="opaque",this.currentLayer=i.length-1;this.currentLayer>=0;this.currentLayer--){var b=this.style._layers[i[this.currentLayer]],x=o[b.source],w=c[b.source];this._renderTileClippingMasks(b,w),this.renderLayer(this,x,b,w)}for(this.renderPass="translucent",this.currentLayer=0;this.currentLayer<i.length;this.currentLayer++){var E=this.style._layers[i[this.currentLayer]],T=o[E.source],A=("symbol"===E.type?h:p)[E.source];this._renderTileClippingMasks(E,c[E.source]),this.renderLayer(this,T,E,A)}this.options.showTileBoundaries&&(t.values(this.style._layers).forEach((function(t){t.source&&!t.isHidden(n.transform.zoom)&&(t.source!==(u&&u.id)&&(u=n.style.sourceCaches[t.source]),(!l||l.getSource().maxzoom<u.getSource().maxzoom)&&(l=u))})),l&&vn.debug(this,l,l.getVisibleCoordinates())),this.options.showPadding&&function(t){var e=t.transform.padding;dn(t,t.transform.height-(e.top||0),3,un),dn(t,e.bottom||0,3,cn),mn(t,e.left||0,3,pn),mn(t,t.transform.width-(e.right||0),3,hn);var r=t.transform.centerPoint;!function(t,e,r,n){gn(t,e-1,r-10,2,20,n),gn(t,e-10,r-1,20,2,n)}(t,r.x,t.transform.height-r.y,fn)}(this),this.context.setDefault()},_n.prototype.renderLayer=function(t,e,r,n){r.isHidden(this.transform.zoom)||("background"===r.type||"custom"===r.type||n.length)&&(this.id=r.id,this.gpuTimingStart(r),vn[r.type](t,e,r,n,this.style.placement.variableOffsets),this.gpuTimingEnd())},_n.prototype.gpuTimingStart=function(t){if(this.options.gpuTiming){var e=this.context.extTimerQuery,r=this.gpuTimers[t.id];r||(r=this.gpuTimers[t.id]={calls:0,cpuTime:0,query:e.createQueryEXT()}),r.calls++,e.beginQueryEXT(e.TIME_ELAPSED_EXT,r.query)}},_n.prototype.gpuTimingEnd=function(){if(this.options.gpuTiming){var t=this.context.extTimerQuery;t.endQueryEXT(t.TIME_ELAPSED_EXT)}},_n.prototype.collectGpuTimers=function(){var t=this.gpuTimers;return this.gpuTimers={},t},_n.prototype.queryGpuTimers=function(t){var e={};for(var r in t){var n=t[r],i=this.context.extTimerQuery,o=i.getQueryObjectEXT(n.query,i.QUERY_RESULT_EXT)/1e6;i.deleteQueryEXT(n.query),e[r]=o}return e},_n.prototype.translatePosMatrix=function(e,r,n,i,o){if(!n[0]&&!n[1])return e;var a=o?"map"===i?this.transform.angle:0:"viewport"===i?-this.transform.angle:0;if(a){var s=Math.sin(a),l=Math.cos(a);n=[n[0]*l-n[1]*s,n[0]*s+n[1]*l]}var u=[o?n[0]:he(r,n[0],this.transform.zoom),o?n[1]:he(r,n[1],this.transform.zoom),0],c=new Float32Array(16);return t.translate(c,e,u),c},_n.prototype.saveTileTexture=function(t){var e=this._tileTextures[t.size[0]];e?e.push(t):this._tileTextures[t.size[0]]=[t]},_n.prototype.getTileTexture=function(t){var e=this._tileTextures[t];return e&&e.length>0?e.pop():null},_n.prototype.isPatternMissing=function(t){if(!t)return!1;if(!t.from||!t.to)return!0;var e=this.imageManager.getPattern(t.from.toString()),r=this.imageManager.getPattern(t.to.toString());return!e||!r},_n.prototype.useProgram=function(t,e){this.cache=this.cache||{};var r=""+t+(e?e.cacheKey:"")+(this._showOverdrawInspector?"/overdraw":"");return this.cache[r]||(this.cache[r]=new xr(this.context,t,vr[t],e,Xr[t],this._showOverdrawInspector)),this.cache[r]},_n.prototype.setCustomLayerDefaults=function(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()},_n.prototype.setBaseState=function(){var t=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(t.FUNC_ADD)},_n.prototype.initDebugOverlayCanvas=function(){null==this.debugOverlayCanvas&&(this.debugOverlayCanvas=t.window.document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512,this.debugOverlayTexture=new t.Texture(this.context,this.debugOverlayCanvas,this.context.gl.RGBA))},_n.prototype.destroy=function(){this.emptyTexture.destroy(),this.debugOverlayTexture&&this.debugOverlayTexture.destroy()};var bn=function(t,e){this.points=t,this.planes=e};bn.fromInvProjectionMatrix=function(e,r,n){var i=Math.pow(2,n),o=[[-1,1,-1,1],[1,1,-1,1],[1,-1,-1,1],[-1,-1,-1,1],[-1,1,1,1],[1,1,1,1],[1,-1,1,1],[-1,-1,1,1]].map((function(r){return t.transformMat4([],r,e)})).map((function(e){return t.scale$1([],e,1/e[3]/r*i)})),a=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map((function(e){var r=t.sub([],o[e[0]],o[e[1]]),n=t.sub([],o[e[2]],o[e[1]]),i=t.normalize([],t.cross([],r,n)),a=-t.dot(i,o[e[1]]);return i.concat(a)}));return new bn(o,a)};var xn=function(e,r){this.min=e,this.max=r,this.center=t.scale$2([],t.add([],this.min,this.max),.5)};xn.prototype.quadrant=function(e){for(var r=[e%2==0,e<2],n=t.clone$2(this.min),i=t.clone$2(this.max),o=0;o<r.length;o++)n[o]=r[o]?this.min[o]:this.center[o],i[o]=r[o]?this.center[o]:this.max[o];return i[2]=this.max[2],new xn(n,i)},xn.prototype.distanceX=function(t){return Math.max(Math.min(this.max[0],t[0]),this.min[0])-t[0]},xn.prototype.distanceY=function(t){return Math.max(Math.min(this.max[1],t[1]),this.min[1])-t[1]},xn.prototype.intersects=function(e){for(var r=[[this.min[0],this.min[1],0,1],[this.max[0],this.min[1],0,1],[this.max[0],this.max[1],0,1],[this.min[0],this.max[1],0,1]],n=!0,i=0;i<e.planes.length;i++){for(var o=e.planes[i],a=0,s=0;s<r.length;s++)a+=t.dot$1(o,r[s])>=0;if(0===a)return 0;a!==r.length&&(n=!1)}if(n)return 2;for(var l=0;l<3;l++){for(var u=Number.MAX_VALUE,c=-Number.MAX_VALUE,p=0;p<e.points.length;p++){var h=e.points[p][l]-this.min[l];u=Math.min(u,h),c=Math.max(c,h)}if(c<0||u>this.max[l]-this.min[l])return 0}return 1};var wn=function(t,e,r,n){if(void 0===t&&(t=0),void 0===e&&(e=0),void 0===r&&(r=0),void 0===n&&(n=0),isNaN(t)||t<0||isNaN(e)||e<0||isNaN(r)||r<0||isNaN(n)||n<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=t,this.bottom=e,this.left=r,this.right=n};wn.prototype.interpolate=function(e,r,n){return null!=r.top&&null!=e.top&&(this.top=t.number(e.top,r.top,n)),null!=r.bottom&&null!=e.bottom&&(this.bottom=t.number(e.bottom,r.bottom,n)),null!=r.left&&null!=e.left&&(this.left=t.number(e.left,r.left,n)),null!=r.right&&null!=e.right&&(this.right=t.number(e.right,r.right,n)),this},wn.prototype.getCenter=function(e,r){var n=t.clamp((this.left+e-this.right)/2,0,e),i=t.clamp((this.top+r-this.bottom)/2,0,r);return new t.Point(n,i)},wn.prototype.equals=function(t){return this.top===t.top&&this.bottom===t.bottom&&this.left===t.left&&this.right===t.right},wn.prototype.clone=function(){return new wn(this.top,this.bottom,this.left,this.right)},wn.prototype.toJSON=function(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}};var En=function(e,r,n,i,o){this.tileSize=512,this.maxValidLatitude=85.051129,this._renderWorldCopies=void 0===o||o,this._minZoom=e||0,this._maxZoom=r||22,this._minPitch=null==n?0:n,this._maxPitch=null==i?60:i,this.setMaxBounds(),this.width=0,this.height=0,this._center=new t.LngLat(0,0),this.zoom=0,this.angle=0,this._fov=.6435011087932844,this._pitch=0,this._unmodified=!0,this._edgeInsets=new wn,this._posMatrixCache={},this._alignedPosMatrixCache={}},Tn={minZoom:{configurable:!0},maxZoom:{configurable:!0},minPitch:{configurable:!0},maxPitch:{configurable:!0},renderWorldCopies:{configurable:!0},worldSize:{configurable:!0},centerOffset:{configurable:!0},size:{configurable:!0},bearing:{configurable:!0},pitch:{configurable:!0},fov:{configurable:!0},zoom:{configurable:!0},center:{configurable:!0},padding:{configurable:!0},centerPoint:{configurable:!0},unmodified:{configurable:!0},point:{configurable:!0}};En.prototype.clone=function(){var t=new En(this._minZoom,this._maxZoom,this._minPitch,this.maxPitch,this._renderWorldCopies);return t.tileSize=this.tileSize,t.latRange=this.latRange,t.width=this.width,t.height=this.height,t._center=this._center,t.zoom=this.zoom,t.angle=this.angle,t._fov=this._fov,t._pitch=this._pitch,t._unmodified=this._unmodified,t._edgeInsets=this._edgeInsets.clone(),t._calcMatrices(),t},Tn.minZoom.get=function(){return this._minZoom},Tn.minZoom.set=function(t){this._minZoom!==t&&(this._minZoom=t,this.zoom=Math.max(this.zoom,t))},Tn.maxZoom.get=function(){return this._maxZoom},Tn.maxZoom.set=function(t){this._maxZoom!==t&&(this._maxZoom=t,this.zoom=Math.min(this.zoom,t))},Tn.minPitch.get=function(){return this._minPitch},Tn.minPitch.set=function(t){this._minPitch!==t&&(this._minPitch=t,this.pitch=Math.max(this.pitch,t))},Tn.maxPitch.get=function(){return this._maxPitch},Tn.maxPitch.set=function(t){this._maxPitch!==t&&(this._maxPitch=t,this.pitch=Math.min(this.pitch,t))},Tn.renderWorldCopies.get=function(){return this._renderWorldCopies},Tn.renderWorldCopies.set=function(t){void 0===t?t=!0:null===t&&(t=!1),this._renderWorldCopies=t},Tn.worldSize.get=function(){return this.tileSize*this.scale},Tn.centerOffset.get=function(){return this.centerPoint._sub(this.size._div(2))},Tn.size.get=function(){return new t.Point(this.width,this.height)},Tn.bearing.get=function(){return-this.angle/Math.PI*180},Tn.bearing.set=function(e){var r=-t.wrap(e,-180,180)*Math.PI/180;this.angle!==r&&(this._unmodified=!1,this.angle=r,this._calcMatrices(),this.rotationMatrix=t.create$2(),t.rotate(this.rotationMatrix,this.rotationMatrix,this.angle))},Tn.pitch.get=function(){return this._pitch/Math.PI*180},Tn.pitch.set=function(e){var r=t.clamp(e,this.minPitch,this.maxPitch)/180*Math.PI;this._pitch!==r&&(this._unmodified=!1,this._pitch=r,this._calcMatrices())},Tn.fov.get=function(){return this._fov/Math.PI*180},Tn.fov.set=function(t){t=Math.max(.01,Math.min(60,t)),this._fov!==t&&(this._unmodified=!1,this._fov=t/180*Math.PI,this._calcMatrices())},Tn.zoom.get=function(){return this._zoom},Tn.zoom.set=function(t){var e=Math.min(Math.max(t,this.minZoom),this.maxZoom);this._zoom!==e&&(this._unmodified=!1,this._zoom=e,this.scale=this.zoomScale(e),this.tileZoom=Math.floor(e),this.zoomFraction=e-this.tileZoom,this._constrain(),this._calcMatrices())},Tn.center.get=function(){return this._center},Tn.center.set=function(t){t.lat===this._center.lat&&t.lng===this._center.lng||(this._unmodified=!1,this._center=t,this._constrain(),this._calcMatrices())},Tn.padding.get=function(){return this._edgeInsets.toJSON()},Tn.padding.set=function(t){this._edgeInsets.equals(t)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,t,1),this._calcMatrices())},Tn.centerPoint.get=function(){return this._edgeInsets.getCenter(this.width,this.height)},En.prototype.isPaddingEqual=function(t){return this._edgeInsets.equals(t)},En.prototype.interpolatePadding=function(t,e,r){this._unmodified=!1,this._edgeInsets.interpolate(t,e,r),this._constrain(),this._calcMatrices()},En.prototype.coveringZoomLevel=function(t){var e=(t.roundZoom?Math.round:Math.floor)(this.zoom+this.scaleZoom(this.tileSize/t.tileSize));return Math.max(0,e)},En.prototype.getVisibleUnwrappedCoordinates=function(e){var r=[new t.UnwrappedTileID(0,e)];if(this._renderWorldCopies)for(var n=this.pointCoordinate(new t.Point(0,0)),i=this.pointCoordinate(new t.Point(this.width,0)),o=this.pointCoordinate(new t.Point(this.width,this.height)),a=this.pointCoordinate(new t.Point(0,this.height)),s=Math.floor(Math.min(n.x,i.x,o.x,a.x)),l=Math.floor(Math.max(n.x,i.x,o.x,a.x)),u=s-1;u<=l+1;u++)0!==u&&r.push(new t.UnwrappedTileID(u,e));return r},En.prototype.coveringTiles=function(e){var r=this.coveringZoomLevel(e),n=r;if(void 0!==e.minzoom&&r<e.minzoom)return[];void 0!==e.maxzoom&&r>e.maxzoom&&(r=e.maxzoom);var i=t.MercatorCoordinate.fromLngLat(this.center),o=Math.pow(2,r),a=[o*i.x,o*i.y,0],s=bn.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,r),l=e.minzoom||0;this.pitch<=60&&this._edgeInsets.top<.1&&(l=r);var u=function(t){return{aabb:new xn([t*o,0,0],[(t+1)*o,o,0]),zoom:0,x:0,y:0,wrap:t,fullyVisible:!1}},c=[],p=[],h=r,f=e.reparseOverscaled?n:r;if(this._renderWorldCopies)for(var d=1;d<=3;d++)c.push(u(-d)),c.push(u(d));for(c.push(u(0));c.length>0;){var m=c.pop(),g=m.x,y=m.y,v=m.fullyVisible;if(!v){var _=m.aabb.intersects(s);if(0===_)continue;v=2===_}var b=m.aabb.distanceX(a),x=m.aabb.distanceY(a),w=Math.max(Math.abs(b),Math.abs(x));if(m.zoom===h||w>3+(1<<h-m.zoom)-2&&m.zoom>=l)p.push({tileID:new t.OverscaledTileID(m.zoom===h?f:m.zoom,m.wrap,m.zoom,g,y),distanceSq:t.sqrLen([a[0]-.5-g,a[1]-.5-y])});else for(var E=0;E<4;E++){var T=(g<<1)+E%2,A=(y<<1)+(E>>1);c.push({aabb:m.aabb.quadrant(E),zoom:m.zoom+1,x:T,y:A,wrap:m.wrap,fullyVisible:v})}}return p.sort((function(t,e){return t.distanceSq-e.distanceSq})).map((function(t){return t.tileID}))},En.prototype.resize=function(t,e){this.width=t,this.height=e,this.pixelsToGLUnits=[2/t,-2/e],this._constrain(),this._calcMatrices()},Tn.unmodified.get=function(){return this._unmodified},En.prototype.zoomScale=function(t){return Math.pow(2,t)},En.prototype.scaleZoom=function(t){return Math.log(t)/Math.LN2},En.prototype.project=function(e){var r=t.clamp(e.lat,-this.maxValidLatitude,this.maxValidLatitude);return new t.Point(t.mercatorXfromLng(e.lng)*this.worldSize,t.mercatorYfromLat(r)*this.worldSize)},En.prototype.unproject=function(e){return new t.MercatorCoordinate(e.x/this.worldSize,e.y/this.worldSize).toLngLat()},Tn.point.get=function(){return this.project(this.center)},En.prototype.setLocationAtPoint=function(e,r){var n=this.pointCoordinate(r),i=this.pointCoordinate(this.centerPoint),o=this.locationCoordinate(e),a=new t.MercatorCoordinate(o.x-(n.x-i.x),o.y-(n.y-i.y));this.center=this.coordinateLocation(a),this._renderWorldCopies&&(this.center=this.center.wrap())},En.prototype.locationPoint=function(t){return this.coordinatePoint(this.locationCoordinate(t))},En.prototype.pointLocation=function(t){return this.coordinateLocation(this.pointCoordinate(t))},En.prototype.locationCoordinate=function(e){return t.MercatorCoordinate.fromLngLat(e)},En.prototype.coordinateLocation=function(t){return t.toLngLat()},En.prototype.pointCoordinate=function(e){var r=[e.x,e.y,0,1],n=[e.x,e.y,1,1];t.transformMat4(r,r,this.pixelMatrixInverse),t.transformMat4(n,n,this.pixelMatrixInverse);var i=r[3],o=n[3],a=r[1]/i,s=n[1]/o,l=r[2]/i,u=n[2]/o,c=l===u?0:(0-l)/(u-l);return new t.MercatorCoordinate(t.number(r[0]/i,n[0]/o,c)/this.worldSize,t.number(a,s,c)/this.worldSize)},En.prototype.coordinatePoint=function(e){var r=[e.x*this.worldSize,e.y*this.worldSize,0,1];return t.transformMat4(r,r,this.pixelMatrix),new t.Point(r[0]/r[3],r[1]/r[3])},En.prototype.getBounds=function(){return(new t.LngLatBounds).extend(this.pointLocation(new t.Point(0,0))).extend(this.pointLocation(new t.Point(this.width,0))).extend(this.pointLocation(new t.Point(this.width,this.height))).extend(this.pointLocation(new t.Point(0,this.height)))},En.prototype.getMaxBounds=function(){return this.latRange&&2===this.latRange.length&&this.lngRange&&2===this.lngRange.length?new t.LngLatBounds([this.lngRange[0],this.latRange[0]],[this.lngRange[1],this.latRange[1]]):null},En.prototype.setMaxBounds=function(t){t?(this.lngRange=[t.getWest(),t.getEast()],this.latRange=[t.getSouth(),t.getNorth()],this._constrain()):(this.lngRange=null,this.latRange=[-this.maxValidLatitude,this.maxValidLatitude])},En.prototype.calculatePosMatrix=function(e,r){void 0===r&&(r=!1);var n=e.key,i=r?this._alignedPosMatrixCache:this._posMatrixCache;if(i[n])return i[n];var o=e.canonical,a=this.worldSize/this.zoomScale(o.z),s=o.x+Math.pow(2,o.z)*e.wrap,l=t.identity(new Float64Array(16));return t.translate(l,l,[s*a,o.y*a,0]),t.scale(l,l,[a/t.EXTENT,a/t.EXTENT,1]),t.multiply(l,r?this.alignedProjMatrix:this.projMatrix,l),i[n]=new Float32Array(l),i[n]},En.prototype.customLayerMatrix=function(){return this.mercatorMatrix.slice()},En.prototype._constrain=function(){if(this.center&&this.width&&this.height&&!this._constraining){this._constraining=!0;var e,r,n,i,o=-90,a=90,s=-180,l=180,u=this.size,c=this._unmodified;if(this.latRange){var p=this.latRange;o=t.mercatorYfromLat(p[1])*this.worldSize,e=(a=t.mercatorYfromLat(p[0])*this.worldSize)-o<u.y?u.y/(a-o):0}if(this.lngRange){var h=this.lngRange;s=t.mercatorXfromLng(h[0])*this.worldSize,r=(l=t.mercatorXfromLng(h[1])*this.worldSize)-s<u.x?u.x/(l-s):0}var f=this.point,d=Math.max(r||0,e||0);if(d)return this.center=this.unproject(new t.Point(r?(l+s)/2:f.x,e?(a+o)/2:f.y)),this.zoom+=this.scaleZoom(d),this._unmodified=c,void(this._constraining=!1);if(this.latRange){var m=f.y,g=u.y/2;m-g<o&&(i=o+g),m+g>a&&(i=a-g)}if(this.lngRange){var y=f.x,v=u.x/2;y-v<s&&(n=s+v),y+v>l&&(n=l-v)}void 0===n&&void 0===i||(this.center=this.unproject(new t.Point(void 0!==n?n:f.x,void 0!==i?i:f.y))),this._unmodified=c,this._constraining=!1}},En.prototype._calcMatrices=function(){if(this.height){var e=this.centerOffset;this.cameraToCenterDistance=.5/Math.tan(this._fov/2)*this.height;var r=Math.PI/2+this._pitch,n=this._fov*(.5+e.y/this.height),i=Math.sin(n)*this.cameraToCenterDistance/Math.sin(t.clamp(Math.PI-r-n,.01,Math.PI-.01)),o=this.point,a=o.x,s=o.y,l=1.01*(Math.cos(Math.PI/2-this._pitch)*i+this.cameraToCenterDistance),u=this.height/50,c=new Float64Array(16);t.perspective(c,this._fov,this.width/this.height,u,l),c[8]=2*-e.x/this.width,c[9]=2*e.y/this.height,t.scale(c,c,[1,-1,1]),t.translate(c,c,[0,0,-this.cameraToCenterDistance]),t.rotateX(c,c,this._pitch),t.rotateZ(c,c,this.angle),t.translate(c,c,[-a,-s,0]),this.mercatorMatrix=t.scale([],c,[this.worldSize,this.worldSize,this.worldSize]),t.scale(c,c,[1,1,t.mercatorZfromAltitude(1,this.center.lat)*this.worldSize,1]),this.projMatrix=c,this.invProjMatrix=t.invert([],this.projMatrix);var p=this.width%2/2,h=this.height%2/2,f=Math.cos(this.angle),d=Math.sin(this.angle),m=a-Math.round(a)+f*p+d*h,g=s-Math.round(s)+f*h+d*p,y=new Float64Array(c);if(t.translate(y,y,[m>.5?m-1:m,g>.5?g-1:g,0]),this.alignedProjMatrix=y,c=t.create(),t.scale(c,c,[this.width/2,-this.height/2,1]),t.translate(c,c,[1,-1,0]),this.labelPlaneMatrix=c,c=t.create(),t.scale(c,c,[1,-1,1]),t.translate(c,c,[-1,-1,0]),t.scale(c,c,[2/this.width,2/this.height,1]),this.glCoordMatrix=c,this.pixelMatrix=t.multiply(new Float64Array(16),this.labelPlaneMatrix,this.projMatrix),!(c=t.invert(new Float64Array(16),this.pixelMatrix)))throw new Error("failed to invert matrix");this.pixelMatrixInverse=c,this._posMatrixCache={},this._alignedPosMatrixCache={}}},En.prototype.maxPitchScaleFactor=function(){if(!this.pixelMatrixInverse)return 1;var e=this.pointCoordinate(new t.Point(0,0)),r=[e.x*this.worldSize,e.y*this.worldSize,0,1];return t.transformMat4(r,r,this.pixelMatrix)[3]/this.cameraToCenterDistance},En.prototype.getCameraPoint=function(){var e=Math.tan(this._pitch)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new t.Point(0,e))},En.prototype.getCameraQueryGeometry=function(e){var r=this.getCameraPoint();if(1===e.length)return[e[0],r];for(var n=r.x,i=r.y,o=r.x,a=r.y,s=0,l=e;s<l.length;s+=1){var u=l[s];n=Math.min(n,u.x),i=Math.min(i,u.y),o=Math.max(o,u.x),a=Math.max(a,u.y)}return[new t.Point(n,i),new t.Point(o,i),new t.Point(o,a),new t.Point(n,a),new t.Point(n,i)]},Object.defineProperties(En.prototype,Tn);var An=function(e){var r,n,i,o;this._hashName=e&&encodeURIComponent(e),t.bindAll(["_getCurrentHash","_onHashChange","_updateHash"],this),this._updateHash=(r=this._updateHashUnthrottled.bind(this),n=!1,i=null,o=function(){i=null,n&&(r(),i=setTimeout(o,300),n=!1)},function(){return n=!0,i||o(),i})};An.prototype.addTo=function(e){return this._map=e,t.window.addEventListener("hashchange",this._onHashChange,!1),this._map.on("moveend",this._updateHash),this},An.prototype.remove=function(){return t.window.removeEventListener("hashchange",this._onHashChange,!1),this._map.off("moveend",this._updateHash),clearTimeout(this._updateHash()),delete this._map,this},An.prototype.getHashString=function(e){var r=this._map.getCenter(),n=Math.round(100*this._map.getZoom())/100,i=Math.ceil((n*Math.LN2+Math.log(512/360/.5))/Math.LN10),o=Math.pow(10,i),a=Math.round(r.lng*o)/o,s=Math.round(r.lat*o)/o,l=this._map.getBearing(),u=this._map.getPitch(),c="";if(c+=e?"/"+a+"/"+s+"/"+n:n+"/"+s+"/"+a,(l||u)&&(c+="/"+Math.round(10*l)/10),u&&(c+="/"+Math.round(u)),this._hashName){var p=this._hashName,h=!1,f=t.window.location.hash.slice(1).split("&").map((function(t){var e=t.split("=")[0];return e===p?(h=!0,e+"="+c):t})).filter((function(t){return t}));return h||f.push(p+"="+c),"#"+f.join("&")}return"#"+c},An.prototype._getCurrentHash=function(){var e,r=this,n=t.window.location.hash.replace("#","");return this._hashName?(n.split("&").map((function(t){return t.split("=")})).forEach((function(t){t[0]===r._hashName&&(e=t)})),(e&&e[1]||"").split("/")):n.split("/")},An.prototype._onHashChange=function(){var t=this._getCurrentHash();if(t.length>=3&&!t.some((function(t){return isNaN(t)}))){var e=this._map.dragRotate.isEnabled()&&this._map.touchZoomRotate.isEnabled()?+(t[3]||0):this._map.getBearing();return this._map.jumpTo({center:[+t[2],+t[1]],zoom:+t[0],bearing:e,pitch:+(t[4]||0)}),!0}return!1},An.prototype._updateHashUnthrottled=function(){var e=t.window.location.href.replace(/(#.+)?$/,this.getHashString());try{t.window.history.replaceState(t.window.history.state,null,e)}catch(t){}};var Cn={linearity:.3,easing:t.bezier(0,0,.3,1)},Sn=t.extend({deceleration:2500,maxSpeed:1400},Cn),Pn=t.extend({deceleration:20,maxSpeed:1400},Cn),In=t.extend({deceleration:1e3,maxSpeed:360},Cn),Dn=t.extend({deceleration:1e3,maxSpeed:90},Cn),On=function(t){this._map=t,this.clear()};function Mn(t,e){(!t.duration||t.duration<e.duration)&&(t.duration=e.duration,t.easing=e.easing)}function Bn(e,r,n){var i=n.maxSpeed,o=n.linearity,a=n.deceleration,s=t.clamp(e*o/(r/1e3),-i,i),l=Math.abs(s)/(a*o);return{easing:n.easing,duration:1e3*l,amount:s*(l/2)}}On.prototype.clear=function(){this._inertiaBuffer=[]},On.prototype.record=function(e){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:t.browser.now(),settings:e})},On.prototype._drainInertiaBuffer=function(){for(var e=this._inertiaBuffer,r=t.browser.now();e.length>0&&r-e[0].time>160;)e.shift()},On.prototype._onMoveEnd=function(e){if(this._drainInertiaBuffer(),!(this._inertiaBuffer.length<2)){for(var r={zoom:0,bearing:0,pitch:0,pan:new t.Point(0,0),pinchAround:void 0,around:void 0},n=0,i=this._inertiaBuffer;n<i.length;n+=1){var o=i[n].settings;r.zoom+=o.zoomDelta||0,r.bearing+=o.bearingDelta||0,r.pitch+=o.pitchDelta||0,o.panDelta&&r.pan._add(o.panDelta),o.around&&(r.around=o.around),o.pinchAround&&(r.pinchAround=o.pinchAround)}var a=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,s={};if(r.pan.mag()){var l=Bn(r.pan.mag(),a,t.extend({},Sn,e||{}));s.offset=r.pan.mult(l.amount/r.pan.mag()),s.center=this._map.transform.center,Mn(s,l)}if(r.zoom){var u=Bn(r.zoom,a,Pn);s.zoom=this._map.transform.zoom+u.amount,Mn(s,u)}if(r.bearing){var c=Bn(r.bearing,a,In);s.bearing=this._map.transform.bearing+t.clamp(c.amount,-179,179),Mn(s,c)}if(r.pitch){var p=Bn(r.pitch,a,Dn);s.pitch=this._map.transform.pitch+p.amount,Mn(s,p)}if(s.zoom||s.bearing){var h=void 0===r.pinchAround?r.around:r.pinchAround;s.around=h?this._map.unproject(h):this._map.getCenter()}return this.clear(),t.extend(s,{noMoveStart:!0})}};var kn=function(e){function n(n,i,o,a){void 0===a&&(a={});var s=r.mousePos(i.getCanvasContainer(),o),l=i.unproject(s);e.call(this,n,t.extend({point:s,lngLat:l,originalEvent:o},a)),this._defaultPrevented=!1,this.target=i}e&&(n.__proto__=e),(n.prototype=Object.create(e&&e.prototype)).constructor=n;var i={defaultPrevented:{configurable:!0}};return n.prototype.preventDefault=function(){this._defaultPrevented=!0},i.defaultPrevented.get=function(){return this._defaultPrevented},Object.defineProperties(n.prototype,i),n}(t.Event),Fn=function(e){function n(n,i,o){var a="touchend"===n?o.changedTouches:o.touches,s=r.touchPos(i.getCanvasContainer(),a),l=s.map((function(t){return i.unproject(t)})),u=s.reduce((function(t,e,r,n){return t.add(e.div(n.length))}),new t.Point(0,0)),c=i.unproject(u);e.call(this,n,{points:s,point:u,lngLats:l,lngLat:c,originalEvent:o}),this._defaultPrevented=!1}e&&(n.__proto__=e),(n.prototype=Object.create(e&&e.prototype)).constructor=n;var i={defaultPrevented:{configurable:!0}};return n.prototype.preventDefault=function(){this._defaultPrevented=!0},i.defaultPrevented.get=function(){return this._defaultPrevented},Object.defineProperties(n.prototype,i),n}(t.Event),Ln=function(t){function e(e,r,n){t.call(this,e,{originalEvent:n}),this._defaultPrevented=!1}t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e;var r={defaultPrevented:{configurable:!0}};return e.prototype.preventDefault=function(){this._defaultPrevented=!0},r.defaultPrevented.get=function(){return this._defaultPrevented},Object.defineProperties(e.prototype,r),e}(t.Event),Rn=function(t,e){this._map=t,this._clickTolerance=e.clickTolerance};Rn.prototype.reset=function(){delete this._mousedownPos},Rn.prototype.wheel=function(t){return this._firePreventable(new Ln(t.type,this._map,t))},Rn.prototype.mousedown=function(t,e){return this._mousedownPos=e,this._firePreventable(new kn(t.type,this._map,t))},Rn.prototype.mouseup=function(t){this._map.fire(new kn(t.type,this._map,t))},Rn.prototype.click=function(t,e){this._mousedownPos&&this._mousedownPos.dist(e)>=this._clickTolerance||this._map.fire(new kn(t.type,this._map,t))},Rn.prototype.dblclick=function(t){return this._firePreventable(new kn(t.type,this._map,t))},Rn.prototype.mouseover=function(t){this._map.fire(new kn(t.type,this._map,t))},Rn.prototype.mouseout=function(t){this._map.fire(new kn(t.type,this._map,t))},Rn.prototype.touchstart=function(t){return this._firePreventable(new Fn(t.type,this._map,t))},Rn.prototype.touchmove=function(t){this._map.fire(new Fn(t.type,this._map,t))},Rn.prototype.touchend=function(t){this._map.fire(new Fn(t.type,this._map,t))},Rn.prototype.touchcancel=function(t){this._map.fire(new Fn(t.type,this._map,t))},Rn.prototype._firePreventable=function(t){if(this._map.fire(t),t.defaultPrevented)return{}},Rn.prototype.isEnabled=function(){return!0},Rn.prototype.isActive=function(){return!1},Rn.prototype.enable=function(){},Rn.prototype.disable=function(){};var zn=function(t){this._map=t};zn.prototype.reset=function(){this._delayContextMenu=!1,delete this._contextMenuEvent},zn.prototype.mousemove=function(t){this._map.fire(new kn(t.type,this._map,t))},zn.prototype.mousedown=function(){this._delayContextMenu=!0},zn.prototype.mouseup=function(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new kn("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)},zn.prototype.contextmenu=function(t){this._delayContextMenu?this._contextMenuEvent=t:this._map.fire(new kn(t.type,this._map,t)),this._map.listens("contextmenu")&&t.preventDefault()},zn.prototype.isEnabled=function(){return!0},zn.prototype.isActive=function(){return!1},zn.prototype.enable=function(){},zn.prototype.disable=function(){};var Nn=function(t,e){this._map=t,this._el=t.getCanvasContainer(),this._container=t.getContainer(),this._clickTolerance=e.clickTolerance||1};function jn(t,e){for(var r={},n=0;n<t.length;n++)r[t[n].identifier]=e[n];return r}Nn.prototype.isEnabled=function(){return!!this._enabled},Nn.prototype.isActive=function(){return!!this._active},Nn.prototype.enable=function(){this.isEnabled()||(this._enabled=!0)},Nn.prototype.disable=function(){this.isEnabled()&&(this._enabled=!1)},Nn.prototype.mousedown=function(t,e){this.isEnabled()&&t.shiftKey&&0===t.button&&(r.disableDrag(),this._startPos=this._lastPos=e,this._active=!0)},Nn.prototype.mousemoveWindow=function(t,e){if(this._active){var n=e;if(!(this._lastPos.equals(n)||!this._box&&n.dist(this._startPos)<this._clickTolerance)){var i=this._startPos;this._lastPos=n,this._box||(this._box=r.create("div","mapboxgl-boxzoom",this._container),this._container.classList.add("mapboxgl-crosshair"),this._fireEvent("boxzoomstart",t));var o=Math.min(i.x,n.x),a=Math.max(i.x,n.x),s=Math.min(i.y,n.y),l=Math.max(i.y,n.y);r.setTransform(this._box,"translate("+o+"px,"+s+"px)"),this._box.style.width=a-o+"px",this._box.style.height=l-s+"px"}}},Nn.prototype.mouseupWindow=function(e,n){var i=this;if(this._active&&0===e.button){var o=this._startPos,a=n;if(this.reset(),r.suppressClick(),o.x!==a.x||o.y!==a.y)return this._map.fire(new t.Event("boxzoomend",{originalEvent:e})),{cameraAnimation:function(t){return t.fitScreenCoordinates(o,a,i._map.getBearing(),{linear:!0})}};this._fireEvent("boxzoomcancel",e)}},Nn.prototype.keydown=function(t){this._active&&27===t.keyCode&&(this.reset(),this._fireEvent("boxzoomcancel",t))},Nn.prototype.reset=function(){this._active=!1,this._container.classList.remove("mapboxgl-crosshair"),this._box&&(r.remove(this._box),this._box=null),r.enableDrag(),delete this._startPos,delete this._lastPos},Nn.prototype._fireEvent=function(e,r){return this._map.fire(new t.Event(e,{originalEvent:r}))};var Un=function(t){this.reset(),this.numTouches=t.numTouches};Un.prototype.reset=function(){delete this.centroid,delete this.startTime,delete this.touches,this.aborted=!1},Un.prototype.touchstart=function(e,r,n){(this.centroid||n.length>this.numTouches)&&(this.aborted=!0),this.aborted||(void 0===this.startTime&&(this.startTime=e.timeStamp),n.length===this.numTouches&&(this.centroid=function(e){for(var r=new t.Point(0,0),n=0,i=e;n<i.length;n+=1)r._add(i[n]);return r.div(e.length)}(r),this.touches=jn(n,r)))},Un.prototype.touchmove=function(t,e,r){if(!this.aborted&&this.centroid){var n=jn(r,e);for(var i in this.touches){var o=n[i];(!o||o.dist(this.touches[i])>30)&&(this.aborted=!0)}}},Un.prototype.touchend=function(t,e,r){if((!this.centroid||t.timeStamp-this.startTime>500)&&(this.aborted=!0),0===r.length){var n=!this.aborted&&this.centroid;if(this.reset(),n)return n}};var Vn=function(t){this.singleTap=new Un(t),this.numTaps=t.numTaps,this.reset()};Vn.prototype.reset=function(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()},Vn.prototype.touchstart=function(t,e,r){this.singleTap.touchstart(t,e,r)},Vn.prototype.touchmove=function(t,e,r){this.singleTap.touchmove(t,e,r)},Vn.prototype.touchend=function(t,e,r){var n=this.singleTap.touchend(t,e,r);if(n){var i=t.timeStamp-this.lastTime<500,o=!this.lastTap||this.lastTap.dist(n)<30;if(i&&o||this.reset(),this.count++,this.lastTime=t.timeStamp,this.lastTap=n,this.count===this.numTaps)return this.reset(),n}};var qn=function(){this._zoomIn=new Vn({numTouches:1,numTaps:2}),this._zoomOut=new Vn({numTouches:2,numTaps:1}),this.reset()};qn.prototype.reset=function(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()},qn.prototype.touchstart=function(t,e,r){this._zoomIn.touchstart(t,e,r),this._zoomOut.touchstart(t,e,r)},qn.prototype.touchmove=function(t,e,r){this._zoomIn.touchmove(t,e,r),this._zoomOut.touchmove(t,e,r)},qn.prototype.touchend=function(t,e,r){var n=this,i=this._zoomIn.touchend(t,e,r),o=this._zoomOut.touchend(t,e,r);return i?(this._active=!0,t.preventDefault(),setTimeout((function(){return n.reset()}),0),{cameraAnimation:function(e){return e.easeTo({duration:300,zoom:e.getZoom()+1,around:e.unproject(i)},{originalEvent:t})}}):o?(this._active=!0,t.preventDefault(),setTimeout((function(){return n.reset()}),0),{cameraAnimation:function(e){return e.easeTo({duration:300,zoom:e.getZoom()-1,around:e.unproject(o)},{originalEvent:t})}}):void 0},qn.prototype.touchcancel=function(){this.reset()},qn.prototype.enable=function(){this._enabled=!0},qn.prototype.disable=function(){this._enabled=!1,this.reset()},qn.prototype.isEnabled=function(){return this._enabled},qn.prototype.isActive=function(){return this._active};var Hn={0:1,2:2},Gn=function(t){this.reset(),this._clickTolerance=t.clickTolerance||1};Gn.prototype.reset=function(){this._active=!1,this._moved=!1,delete this._lastPoint,delete this._eventButton},Gn.prototype._correctButton=function(t,e){return!1},Gn.prototype._move=function(t,e){return{}},Gn.prototype.mousedown=function(t,e){if(!this._lastPoint){var n=r.mouseButton(t);this._correctButton(t,n)&&(this._lastPoint=e,this._eventButton=n)}},Gn.prototype.mousemoveWindow=function(t,e){var r=this._lastPoint;if(r)if(t.preventDefault(),function(t,e){var r=Hn[e];return void 0===t.buttons||(t.buttons&r)!==r}(t,this._eventButton))this.reset();else if(this._moved||!(e.dist(r)<this._clickTolerance))return this._moved=!0,this._lastPoint=e,this._move(r,e)},Gn.prototype.mouseupWindow=function(t){this._lastPoint&&r.mouseButton(t)===this._eventButton&&(this._moved&&r.suppressClick(),this.reset())},Gn.prototype.enable=function(){this._enabled=!0},Gn.prototype.disable=function(){this._enabled=!1,this.reset()},Gn.prototype.isEnabled=function(){return this._enabled},Gn.prototype.isActive=function(){return this._active};var Zn=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.mousedown=function(e,r){t.prototype.mousedown.call(this,e,r),this._lastPoint&&(this._active=!0)},e.prototype._correctButton=function(t,e){return 0===e&&!t.ctrlKey},e.prototype._move=function(t,e){return{around:e,panDelta:e.sub(t)}},e}(Gn),Wn=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._correctButton=function(t,e){return 0===e&&t.ctrlKey||2===e},e.prototype._move=function(t,e){var r=.8*(e.x-t.x);if(r)return this._active=!0,{bearingDelta:r}},e.prototype.contextmenu=function(t){t.preventDefault()},e}(Gn),Yn=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype._correctButton=function(t,e){return 0===e&&t.ctrlKey||2===e},e.prototype._move=function(t,e){var r=-.5*(e.y-t.y);if(r)return this._active=!0,{pitchDelta:r}},e.prototype.contextmenu=function(t){t.preventDefault()},e}(Gn),Xn=function(t){this._minTouches=1,this._clickTolerance=t.clickTolerance||1,this.reset()};Xn.prototype.reset=function(){this._active=!1,this._touches={},this._sum=new t.Point(0,0)},Xn.prototype.touchstart=function(t,e,r){return this._calculateTransform(t,e,r)},Xn.prototype.touchmove=function(t,e,r){if(this._active&&!(r.length<this._minTouches))return t.preventDefault(),this._calculateTransform(t,e,r)},Xn.prototype.touchend=function(t,e,r){this._calculateTransform(t,e,r),this._active&&r.length<this._minTouches&&this.reset()},Xn.prototype.touchcancel=function(){this.reset()},Xn.prototype._calculateTransform=function(e,r,n){n.length>0&&(this._active=!0);var i=jn(n,r),o=new t.Point(0,0),a=new t.Point(0,0),s=0;for(var l in i){var u=i[l],c=this._touches[l];c&&(o._add(u),a._add(u.sub(c)),s++,i[l]=u)}if(this._touches=i,!(s<this._minTouches)&&a.mag()){var p=a.div(s);if(this._sum._add(p),!(this._sum.mag()<this._clickTolerance))return{around:o.div(s),panDelta:p}}},Xn.prototype.enable=function(){this._enabled=!0},Xn.prototype.disable=function(){this._enabled=!1,this.reset()},Xn.prototype.isEnabled=function(){return this._enabled},Xn.prototype.isActive=function(){return this._active};var Kn=function(){this.reset()};function Jn(t,e,r){for(var n=0;n<t.length;n++)if(t[n].identifier===r)return e[n]}function Qn(t,e){return Math.log(t/e)/Math.LN2}Kn.prototype.reset=function(){this._active=!1,delete this._firstTwoTouches},Kn.prototype._start=function(t){},Kn.prototype._move=function(t,e,r){return{}},Kn.prototype.touchstart=function(t,e,r){this._firstTwoTouches||r.length<2||(this._firstTwoTouches=[r[0].identifier,r[1].identifier],this._start([e[0],e[1]]))},Kn.prototype.touchmove=function(t,e,r){if(this._firstTwoTouches){t.preventDefault();var n=this._firstTwoTouches,i=n[1],o=Jn(r,e,n[0]),a=Jn(r,e,i);if(o&&a){var s=this._aroundCenter?null:o.add(a).div(2);return this._move([o,a],s,t)}}},Kn.prototype.touchend=function(t,e,n){if(this._firstTwoTouches){var i=this._firstTwoTouches,o=i[1],a=Jn(n,e,i[0]),s=Jn(n,e,o);a&&s||(this._active&&r.suppressClick(),this.reset())}},Kn.prototype.touchcancel=function(){this.reset()},Kn.prototype.enable=function(t){this._enabled=!0,this._aroundCenter=!!t&&"center"===t.around},Kn.prototype.disable=function(){this._enabled=!1,this.reset()},Kn.prototype.isEnabled=function(){return this._enabled},Kn.prototype.isActive=function(){return this._active};var $n=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.reset=function(){t.prototype.reset.call(this),delete this._distance,delete this._startDistance},e.prototype._start=function(t){this._startDistance=this._distance=t[0].dist(t[1])},e.prototype._move=function(t,e){var r=this._distance;if(this._distance=t[0].dist(t[1]),this._active||!(Math.abs(Qn(this._distance,this._startDistance))<.1))return this._active=!0,{zoomDelta:Qn(this._distance,r),pinchAround:e}},e}(Kn);function ti(t,e){return 180*t.angleWith(e)/Math.PI}var ei=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.reset=function(){t.prototype.reset.call(this),delete this._minDiameter,delete this._startVector,delete this._vector},e.prototype._start=function(t){this._startVector=this._vector=t[0].sub(t[1]),this._minDiameter=t[0].dist(t[1])},e.prototype._move=function(t,e){var r=this._vector;if(this._vector=t[0].sub(t[1]),this._active||!this._isBelowThreshold(this._vector))return this._active=!0,{bearingDelta:ti(this._vector,r),pinchAround:e}},e.prototype._isBelowThreshold=function(t){this._minDiameter=Math.min(this._minDiameter,t.mag());var e=25/(Math.PI*this._minDiameter)*360,r=ti(t,this._startVector);return Math.abs(r)<e},e}(Kn);function ri(t){return Math.abs(t.y)>Math.abs(t.x)}var ni=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e.prototype.reset=function(){t.prototype.reset.call(this),this._valid=void 0,delete this._firstMove,delete this._lastPoints},e.prototype._start=function(t){this._lastPoints=t,ri(t[0].sub(t[1]))&&(this._valid=!1)},e.prototype._move=function(t,e,r){var n=t[0].sub(this._lastPoints[0]),i=t[1].sub(this._lastPoints[1]);if(this._valid=this.gestureBeginsVertically(n,i,r.timeStamp),this._valid)return this._lastPoints=t,this._active=!0,{pitchDelta:(n.y+i.y)/2*-.5}},e.prototype.gestureBeginsVertically=function(t,e,r){if(void 0!==this._valid)return this._valid;var n=t.mag()>=2,i=e.mag()>=2;if(n||i){if(!n||!i)return void 0===this._firstMove&&(this._firstMove=r),r-this._firstMove<100&&void 0;var o=t.y>0==e.y>0;return ri(t)&&ri(e)&&o}},e}(Kn),ii={panStep:100,bearingStep:15,pitchStep:10},oi=function(){var t=ii;this._panStep=t.panStep,this._bearingStep=t.bearingStep,this._pitchStep=t.pitchStep,this._rotationDisabled=!1};function ai(t){return t*(2-t)}oi.prototype.reset=function(){this._active=!1},oi.prototype.keydown=function(t){var e=this;if(!(t.altKey||t.ctrlKey||t.metaKey)){var r=0,n=0,i=0,o=0,a=0;switch(t.keyCode){case 61:case 107:case 171:case 187:r=1;break;case 189:case 109:case 173:r=-1;break;case 37:t.shiftKey?n=-1:(t.preventDefault(),o=-1);break;case 39:t.shiftKey?n=1:(t.preventDefault(),o=1);break;case 38:t.shiftKey?i=1:(t.preventDefault(),a=-1);break;case 40:t.shiftKey?i=-1:(t.preventDefault(),a=1);break;default:return}return this._rotationDisabled&&(n=0,i=0),{cameraAnimation:function(s){var l=s.getZoom();s.easeTo({duration:300,easeId:"keyboardHandler",easing:ai,zoom:r?Math.round(l)+r*(t.shiftKey?2:1):l,bearing:s.getBearing()+n*e._bearingStep,pitch:s.getPitch()+i*e._pitchStep,offset:[-o*e._panStep,-a*e._panStep],center:s.getCenter()},{originalEvent:t})}}}},oi.prototype.enable=function(){this._enabled=!0},oi.prototype.disable=function(){this._enabled=!1,this.reset()},oi.prototype.isEnabled=function(){return this._enabled},oi.prototype.isActive=function(){return this._active},oi.prototype.disableRotation=function(){this._rotationDisabled=!0},oi.prototype.enableRotation=function(){this._rotationDisabled=!1};var si=function(e,r){this._map=e,this._el=e.getCanvasContainer(),this._handler=r,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=1/450,t.bindAll(["_onTimeout"],this)};si.prototype.setZoomRate=function(t){this._defaultZoomRate=t},si.prototype.setWheelZoomRate=function(t){this._wheelZoomRate=t},si.prototype.isEnabled=function(){return!!this._enabled},si.prototype.isActive=function(){return!!this._active||void 0!==this._finishTimeout},si.prototype.isZooming=function(){return!!this._zooming},si.prototype.enable=function(t){this.isEnabled()||(this._enabled=!0,this._aroundCenter=t&&"center"===t.around)},si.prototype.disable=function(){this.isEnabled()&&(this._enabled=!1)},si.prototype.wheel=function(e){if(this.isEnabled()){var r=e.deltaMode===t.window.WheelEvent.DOM_DELTA_LINE?40*e.deltaY:e.deltaY,n=t.browser.now(),i=n-(this._lastWheelEventTime||0);this._lastWheelEventTime=n,0!==r&&r%4.000244140625==0?this._type="wheel":0!==r&&Math.abs(r)<4?this._type="trackpad":i>400?(this._type=null,this._lastValue=r,this._timeout=setTimeout(this._onTimeout,40,e)):this._type||(this._type=Math.abs(i*r)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,r+=this._lastValue)),e.shiftKey&&r&&(r/=4),this._type&&(this._lastWheelEvent=e,this._delta-=r,this._active||this._start(e)),e.preventDefault()}},si.prototype._onTimeout=function(t){this._type="wheel",this._delta-=this._lastValue,this._active||this._start(t)},si.prototype._start=function(e){if(this._delta){this._frameId&&(this._frameId=null),this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);var n=r.mousePos(this._el,e);this._around=t.LngLat.convert(this._aroundCenter?this._map.getCenter():this._map.unproject(n)),this._aroundPoint=this._map.transform.locationPoint(this._around),this._frameId||(this._frameId=!0,this._handler._triggerRenderFrame())}},si.prototype.renderFrame=function(){var e=this;if(this._frameId&&(this._frameId=null,this.isActive())){var r=this._map.transform;if(0!==this._delta){var n="wheel"===this._type&&Math.abs(this._delta)>4.000244140625?this._wheelZoomRate:this._defaultZoomRate,i=2/(1+Math.exp(-Math.abs(this._delta*n)));this._delta<0&&0!==i&&(i=1/i);var o="number"==typeof this._targetZoom?r.zoomScale(this._targetZoom):r.scale;this._targetZoom=Math.min(r.maxZoom,Math.max(r.minZoom,r.scaleZoom(o*i))),"wheel"===this._type&&(this._startZoom=r.zoom,this._easing=this._smoothOutEasing(200)),this._delta=0}var a,s="number"==typeof this._targetZoom?this._targetZoom:r.zoom,l=this._startZoom,u=this._easing,c=!1;if("wheel"===this._type&&l&&u){var p=Math.min((t.browser.now()-this._lastWheelEventTime)/200,1),h=u(p);a=t.number(l,s,h),p<1?this._frameId||(this._frameId=!0):c=!0}else a=s,c=!0;return this._active=!0,c&&(this._active=!1,this._finishTimeout=setTimeout((function(){e._zooming=!1,e._handler._triggerRenderFrame(),delete e._targetZoom,delete e._finishTimeout}),200)),{noInertia:!0,needsRenderFrame:!c,zoomDelta:a-r.zoom,around:this._aroundPoint,originalEvent:this._lastWheelEvent}}},si.prototype._smoothOutEasing=function(e){var r=t.ease;if(this._prevEase){var n=this._prevEase,i=(t.browser.now()-n.start)/n.duration,o=n.easing(i+.01)-n.easing(i),a=.27/Math.sqrt(o*o+1e-4)*.01,s=Math.sqrt(.0729-a*a);r=t.bezier(a,s,.25,1)}return this._prevEase={start:t.browser.now(),duration:e,easing:r},r},si.prototype.reset=function(){this._active=!1};var li=function(t,e){this._clickZoom=t,this._tapZoom=e};li.prototype.enable=function(){this._clickZoom.enable(),this._tapZoom.enable()},li.prototype.disable=function(){this._clickZoom.disable(),this._tapZoom.disable()},li.prototype.isEnabled=function(){return this._clickZoom.isEnabled()&&this._tapZoom.isEnabled()},li.prototype.isActive=function(){return this._clickZoom.isActive()||this._tapZoom.isActive()};var ui=function(){this.reset()};ui.prototype.reset=function(){this._active=!1},ui.prototype.dblclick=function(t,e){return t.preventDefault(),{cameraAnimation:function(r){r.easeTo({duration:300,zoom:r.getZoom()+(t.shiftKey?-1:1),around:r.unproject(e)},{originalEvent:t})}}},ui.prototype.enable=function(){this._enabled=!0},ui.prototype.disable=function(){this._enabled=!1,this.reset()},ui.prototype.isEnabled=function(){return this._enabled},ui.prototype.isActive=function(){return this._active};var ci=function(){this._tap=new Vn({numTouches:1,numTaps:1}),this.reset()};ci.prototype.reset=function(){this._active=!1,delete this._swipePoint,delete this._swipeTouch,delete this._tapTime,this._tap.reset()},ci.prototype.touchstart=function(t,e,r){this._swipePoint||(this._tapTime&&t.timeStamp-this._tapTime>500&&this.reset(),this._tapTime?r.length>0&&(this._swipePoint=e[0],this._swipeTouch=r[0].identifier):this._tap.touchstart(t,e,r))},ci.prototype.touchmove=function(t,e,r){if(this._tapTime){if(this._swipePoint){if(r[0].identifier!==this._swipeTouch)return;var n=e[0],i=n.y-this._swipePoint.y;return this._swipePoint=n,t.preventDefault(),this._active=!0,{zoomDelta:i/128}}}else this._tap.touchmove(t,e,r)},ci.prototype.touchend=function(t,e,r){this._tapTime?this._swipePoint&&0===r.length&&this.reset():this._tap.touchend(t,e,r)&&(this._tapTime=t.timeStamp)},ci.prototype.touchcancel=function(){this.reset()},ci.prototype.enable=function(){this._enabled=!0},ci.prototype.disable=function(){this._enabled=!1,this.reset()},ci.prototype.isEnabled=function(){return this._enabled},ci.prototype.isActive=function(){return this._active};var pi=function(t,e,r){this._el=t,this._mousePan=e,this._touchPan=r};pi.prototype.enable=function(t){this._inertiaOptions=t||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("mapboxgl-touch-drag-pan")},pi.prototype.disable=function(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("mapboxgl-touch-drag-pan")},pi.prototype.isEnabled=function(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()},pi.prototype.isActive=function(){return this._mousePan.isActive()||this._touchPan.isActive()};var hi=function(t,e,r){this._pitchWithRotate=t.pitchWithRotate,this._mouseRotate=e,this._mousePitch=r};hi.prototype.enable=function(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable()},hi.prototype.disable=function(){this._mouseRotate.disable(),this._mousePitch.disable()},hi.prototype.isEnabled=function(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())},hi.prototype.isActive=function(){return this._mouseRotate.isActive()||this._mousePitch.isActive()};var fi=function(t,e,r,n){this._el=t,this._touchZoom=e,this._touchRotate=r,this._tapDragZoom=n,this._rotationDisabled=!1,this._enabled=!0};fi.prototype.enable=function(t){this._touchZoom.enable(t),this._rotationDisabled||this._touchRotate.enable(t),this._tapDragZoom.enable(),this._el.classList.add("mapboxgl-touch-zoom-rotate")},fi.prototype.disable=function(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("mapboxgl-touch-zoom-rotate")},fi.prototype.isEnabled=function(){return this._touchZoom.isEnabled()&&(this._rotationDisabled||this._touchRotate.isEnabled())&&this._tapDragZoom.isEnabled()},fi.prototype.isActive=function(){return this._touchZoom.isActive()||this._touchRotate.isActive()||this._tapDragZoom.isActive()},fi.prototype.disableRotation=function(){this._rotationDisabled=!0,this._touchRotate.disable()},fi.prototype.enableRotation=function(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()};var di=function(t){return t.zoom||t.drag||t.pitch||t.rotate},mi=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),(e.prototype=Object.create(t&&t.prototype)).constructor=e,e}(t.Event);function gi(t){return t.panDelta&&t.panDelta.mag()||t.zoomDelta||t.bearingDelta||t.pitchDelta}var yi=function(e,n){this._map=e,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new On(e),this._bearingSnap=n.bearingSnap,this._previousActiveHandlers={},this._eventsInProgress={},this._addDefaultHandlers(n),t.bindAll(["handleEvent","handleWindowEvent"],this);var i=this._el;this._listeners=[[i,"touchstart",{passive:!0}],[i,"touchmove",{passive:!1}],[i,"touchend",void 0],[i,"touchcancel",void 0],[i,"mousedown",void 0],[i,"mousemove",void 0],[i,"mouseup",void 0],[t.window.document,"mousemove",{capture:!0}],[t.window.document,"mouseup",void 0],[i,"mouseover",void 0],[i,"mouseout",void 0],[i,"dblclick",void 0],[i,"click",void 0],[i,"keydown",{capture:!1}],[i,"keyup",void 0],[i,"wheel",{passive:!1}],[i,"contextmenu",void 0],[t.window,"blur",void 0]];for(var o=0,a=this._listeners;o<a.length;o+=1){var s=a[o],l=s[0];r.addEventListener(l,s[1],l===t.window.document?this.handleWindowEvent:this.handleEvent,s[2])}};yi.prototype.destroy=function(){for(var e=0,n=this._listeners;e<n.length;e+=1){var i=n[e],o=i[0];r.removeEventListener(o,i[1],o===t.window.document?this.handleWindowEvent:this.handleEvent,i[2])}},yi.prototype._addDefaultHandlers=function(t){var e=this._map,r=e.getCanvasContainer();this._add("mapEvent",new Rn(e,t));var n=e.boxZoom=new Nn(e,t);this._add("boxZoom",n);var i=new qn,o=new ui;e.doubleClickZoom=new li(o,i),this._add("tapZoom",i),this._add("clickZoom",o);var a=new ci;this._add("tapDragZoom",a);var s=e.touchPitch=new ni;this._add("touchPitch",s);var l=new Wn(t),u=new Yn(t);e.dragRotate=new hi(t,l,u),this._add("mouseRotate",l,["mousePitch"]),this._add("mousePitch",u,["mouseRotate"]);var c=new Zn(t),p=new Xn(t);e.dragPan=new pi(r,c,p),this._add("mousePan",c),this._add("touchPan",p,["touchZoom","touchRotate"]);var h=new ei,f=new $n;e.touchZoomRotate=new fi(r,f,h,a),this._add("touchRotate",h,["touchPan","touchZoom"]),this._add("touchZoom",f,["touchPan","touchRotate"]);var d=e.scrollZoom=new si(e,this);this._add("scrollZoom",d,["mousePan"]);var m=e.keyboard=new oi;this._add("keyboard",m),this._add("blockableMapEvent",new zn(e));for(var g=0,y=["boxZoom","doubleClickZoom","tapDragZoom","touchPitch","dragRotate","dragPan","touchZoomRotate","scrollZoom","keyboard"];g<y.length;g+=1){var v=y[g];t.interactive&&t[v]&&e[v].enable(t[v])}},yi.prototype._add=function(t,e,r){this._handlers.push({handlerName:t,handler:e,allowed:r}),this._handlersById[t]=e},yi.prototype.stop=function(t){if(!this._updatingCamera){for(var e=0,r=this._handlers;e<r.length;e+=1)r[e].handler.reset();this._inertia.clear(),this._fireEvents({},{},t),this._changes=[]}},yi.prototype.isActive=function(){for(var t=0,e=this._handlers;t<e.length;t+=1)if(e[t].handler.isActive())return!0;return!1},yi.prototype.isZooming=function(){return!!this._eventsInProgress.zoom||this._map.scrollZoom.isZooming()},yi.prototype.isRotating=function(){return!!this._eventsInProgress.rotate},yi.prototype.isMoving=function(){return Boolean(di(this._eventsInProgress))||this.isZooming()},yi.prototype._blockedByActive=function(t,e,r){for(var n in t)if(n!==r&&(!e||e.indexOf(n)<0))return!0;return!1},yi.prototype.handleWindowEvent=function(t){this.handleEvent(t,t.type+"Window")},yi.prototype._getMapTouches=function(t){for(var e=[],r=0,n=t;r<n.length;r+=1){var i=n[r];this._el.contains(i.target)&&e.push(i)}return e},yi.prototype.handleEvent=function(t,e){if("blur"!==t.type){this._updatingCamera=!0;for(var n="renderFrame"===t.type?void 0:t,i={needsRenderFrame:!1},o={},a={},s=t.touches?this._getMapTouches(t.touches):void 0,l=s?r.touchPos(this._el,s):r.mousePos(this._el,t),u=0,c=this._handlers;u<c.length;u+=1){var p=c[u],h=p.handlerName,f=p.handler,d=p.allowed;if(f.isEnabled()){var m=void 0;this._blockedByActive(a,d,h)?f.reset():f[e||t.type]&&(m=f[e||t.type](t,l,s),this.mergeHandlerResult(i,o,m,h,n),m&&m.needsRenderFrame&&this._triggerRenderFrame()),(m||f.isActive())&&(a[h]=f)}}var g={};for(var y in this._previousActiveHandlers)a[y]||(g[y]=n);this._previousActiveHandlers=a,(Object.keys(g).length||gi(i))&&(this._changes.push([i,o,g]),this._triggerRenderFrame()),(Object.keys(a).length||gi(i))&&this._map._stop(!0),this._updatingCamera=!1;var v=i.cameraAnimation;v&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],v(this._map))}else this.stop(!0)},yi.prototype.mergeHandlerResult=function(e,r,n,i,o){if(n){t.extend(e,n);var a={handlerName:i,originalEvent:n.originalEvent||o};void 0!==n.zoomDelta&&(r.zoom=a),void 0!==n.panDelta&&(r.drag=a),void 0!==n.pitchDelta&&(r.pitch=a),void 0!==n.bearingDelta&&(r.rotate=a)}},yi.prototype._applyChanges=function(){for(var e={},r={},n={},i=0,o=this._changes;i<o.length;i+=1){var a=o[i],s=a[0],l=a[1],u=a[2];s.panDelta&&(e.panDelta=(e.panDelta||new t.Point(0,0))._add(s.panDelta)),s.zoomDelta&&(e.zoomDelta=(e.zoomDelta||0)+s.zoomDelta),s.bearingDelta&&(e.bearingDelta=(e.bearingDelta||0)+s.bearingDelta),s.pitchDelta&&(e.pitchDelta=(e.pitchDelta||0)+s.pitchDelta),void 0!==s.around&&(e.around=s.around),void 0!==s.pinchAround&&(e.pinchAround=s.pinchAround),s.noInertia&&(e.noInertia=s.noInertia),t.extend(r,l),t.extend(n,u)}this._updateMapTransform(e,r,n),this._changes=[]},yi.prototype._updateMapTransform=function(t,e,r){var n=this._map,i=n.transform;if(!gi(t))return this._fireEvents(e,r,!0);var o=t.panDelta,a=t.zoomDelta,s=t.bearingDelta,l=t.pitchDelta,u=t.around,c=t.pinchAround;void 0!==c&&(u=c),n._stop(!0),u=u||n.transform.centerPoint;var p=i.pointLocation(o?u.sub(o):u);s&&(i.bearing+=s),l&&(i.pitch+=l),a&&(i.zoom+=a),i.setLocationAtPoint(p,u),this._map._update(),t.noInertia||this._inertia.record(t),this._fireEvents(e,r,!0)},yi.prototype._fireEvents=function(e,r,n){var i=this,o=di(this._eventsInProgress),a=di(e),s={};for(var l in e)this._eventsInProgress[l]||(s[l+"start"]=e[l].originalEvent),this._eventsInProgress[l]=e[l];for(var u in!o&&a&&this._fireEvent("movestart",a.originalEvent),s)this._fireEvent(u,s[u]);for(var c in a&&this._fireEvent("move",a.originalEvent),e)this._fireEvent(c,e[c].originalEvent);var p,h={};for(var f in this._eventsInProgress){var d=this._eventsInProgress[f],m=d.handlerName,g=d.originalEvent;this._handlersById[m].isActive()||(delete this._eventsInProgress[f],h[f+"end"]=p=r[m]||g)}for(var y in h)this._fireEvent(y,h[y]);var v=di(this._eventsInProgress);if(n&&(o||a)&&!v){this._updatingCamera=!0;var _=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),b=function(t){return 0!==t&&-i._bearingSnap<t&&t<i._bearingSnap};_?(b(_.bearing||this._map.getBearing())&&(_.bearing=0),this._map.easeTo(_,{originalEvent:p})):(this._map.fire(new t.Event("moveend",{originalEvent:p})),b(this._map.getBearing())&&this._map.resetNorth()),this._updatingCamera=!1}},yi.prototype._fireEvent=function(e,r){this._map.fire(new t.Event(e,r?{originalEvent:r}:{}))},yi.prototype._requestFrame=function(){var t=this;return this._map.triggerRepaint(),this._map._renderTaskQueue.add((function(e){delete t._frameId,t.handleEvent(new mi("renderFrame",{timeStamp:e})),t._applyChanges()}))},yi.prototype._triggerRenderFrame=function(){void 0===this._frameId&&(this._frameId=this._requestFrame())};var vi=function(e){function r(r,n){e.call(this),this._moving=!1,this._zooming=!1,this.transform=r,this._bearingSnap=n.bearingSnap,t.bindAll(["_renderFrameCallback"],this)}return e&&(r.__proto__=e),(r.prototype=Object.create(e&&e.prototype)).constructor=r,r.prototype.getCenter=function(){return new t.LngLat(this.transform.center.lng,this.transform.center.lat)},r.prototype.setCenter=function(t,e){return this.jumpTo({center:t},e)},r.prototype.panBy=function(e,r,n){return e=t.Point.convert(e).mult(-1),this.panTo(this.transform.center,t.extend({offset:e},r),n)},r.prototype.panTo=function(e,r,n){return this.easeTo(t.extend({center:e},r),n)},r.prototype.getZoom=function(){return this.transform.zoom},r.prototype.setZoom=function(t,e){return this.jumpTo({zoom:t},e),this},r.prototype.zoomTo=function(e,r,n){return this.easeTo(t.extend({zoom:e},r),n)},r.prototype.zoomIn=function(t,e){return this.zoomTo(this.getZoom()+1,t,e),this},r.prototype.zoomOut=function(t,e){return this.zoomTo(this.getZoom()-1,t,e),this},r.prototype.getBearing=function(){return this.transform.bearing},r.prototype.setBearing=function(t,e){return this.jumpTo({bearing:t},e),this},r.prototype.getPadding=function(){return this.transform.padding},r.prototype.setPadding=function(t,e){return this.jumpTo({padding:t},e),this},r.prototype.rotateTo=function(e,r,n){return this.easeTo(t.extend({bearing:e},r),n)},r.prototype.resetNorth=function(e,r){return this.rotateTo(0,t.extend({duration:1e3},e),r),this},r.prototype.resetNorthPitch=function(e,r){return this.easeTo(t.extend({bearing:0,pitch:0,duration:1e3},e),r),this},r.prototype.snapToNorth=function(t,e){return Math.abs(this.getBearing())<this._bearingSnap?this.resetNorth(t,e):this},r.prototype.getPitch=function(){return this.transform.pitch},r.prototype.setPitch=function(t,e){return this.jumpTo({pitch:t},e),this},r.prototype.cameraForBounds=function(e,r){e=t.LngLatBounds.convert(e);var n=r&&r.bearing||0;return this._cameraForBoxAndBearing(e.getNorthWest(),e.getSouthEast(),n,r)},r.prototype._cameraForBoxAndBearing=function(e,r,n,i){var o={top:0,bottom:0,right:0,left:0};if("number"==typeof(i=t.extend({padding:o,offset:[0,0],maxZoom:this.transform.maxZoom},i)).padding){var a=i.padding;i.padding={top:a,bottom:a,right:a,left:a}}i.padding=t.extend(o,i.padding);var s=this.transform,l=s.padding,u=s.project(t.LngLat.convert(e)),c=s.project(t.LngLat.convert(r)),p=u.rotate(-n*Math.PI/180),h=c.rotate(-n*Math.PI/180),f=new t.Point(Math.max(p.x,h.x),Math.max(p.y,h.y)),d=new t.Point(Math.min(p.x,h.x),Math.min(p.y,h.y)),m=f.sub(d),g=(s.width-(l.left+l.right+i.padding.left+i.padding.right))/m.x,y=(s.height-(l.top+l.bottom+i.padding.top+i.padding.bottom))/m.y;if(!(y<0||g<0)){var v=Math.min(s.scaleZoom(s.scale*Math.min(g,y)),i.maxZoom),_="number"==typeof i.offset.x?new t.Point(i.offset.x,i.offset.y):t.Point.convert(i.offset),b=new t.Point((i.padding.left-i.padding.right)/2,(i.padding.top-i.padding.bottom)/2).rotate(n*Math.PI/180),x=_.add(b).mult(s.scale/s.zoomScale(v));return{center:s.unproject(u.add(c).div(2).sub(x)),zoom:v,bearing:n}}t.warnOnce("Map cannot fit within canvas with the given bounds, padding, and/or offset.")},r.prototype.fitBounds=function(t,e,r){return this._fitInternal(this.cameraForBounds(t,e),e,r)},r.prototype.fitScreenCoordinates=function(e,r,n,i,o){return this._fitInternal(this._cameraForBoxAndBearing(this.transform.pointLocation(t.Point.convert(e)),this.transform.pointLocation(t.Point.convert(r)),n,i),i,o)},r.prototype._fitInternal=function(e,r,n){return e?(delete(r=t.extend(e,r)).padding,r.linear?this.easeTo(r,n):this.flyTo(r,n)):this},r.prototype.jumpTo=function(e,r){this.stop();var n=this.transform,i=!1,o=!1,a=!1;return"zoom"in e&&n.zoom!==+e.zoom&&(i=!0,n.zoom=+e.zoom),void 0!==e.center&&(n.center=t.LngLat.convert(e.center)),"bearing"in e&&n.bearing!==+e.bearing&&(o=!0,n.bearing=+e.bearing),"pitch"in e&&n.pitch!==+e.pitch&&(a=!0,n.pitch=+e.pitch),null==e.padding||n.isPaddingEqual(e.padding)||(n.padding=e.padding),this.fire(new t.Event("movestart",r)).fire(new t.Event("move",r)),i&&this.fire(new t.Event("zoomstart",r)).fire(new t.Event("zoom",r)).fire(new t.Event("zoomend",r)),o&&this.fire(new t.Event("rotatestart",r)).fire(new t.Event("rotate",r)).fire(new t.Event("rotateend",r)),a&&this.fire(new t.Event("pitchstart",r)).fire(new t.Event("pitch",r)).fire(new t.Event("pitchend",r)),this.fire(new t.Event("moveend",r))},r.prototype.easeTo=function(e,r){var n=this;this._stop(!1,e.easeId),(!1===(e=t.extend({offset:[0,0],duration:500,easing:t.ease},e)).animate||!e.essential&&t.browser.prefersReducedMotion)&&(e.duration=0);var i=this.transform,o=this.getZoom(),a=this.getBearing(),s=this.getPitch(),l=this.getPadding(),u="zoom"in e?+e.zoom:o,c="bearing"in e?this._normalizeBearing(e.bearing,a):a,p="pitch"in e?+e.pitch:s,h="padding"in e?e.padding:i.padding,f=t.Point.convert(e.offset),d=i.centerPoint.add(f),m=i.pointLocation(d),g=t.LngLat.convert(e.center||m);this._normalizeCenter(g);var y,v,_=i.project(m),b=i.project(g).sub(_),x=i.zoomScale(u-o);e.around&&(y=t.LngLat.convert(e.around),v=i.locationPoint(y));var w={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching};return this._zooming=this._zooming||u!==o,this._rotating=this._rotating||a!==c,this._pitching=this._pitching||p!==s,this._padding=!i.isPaddingEqual(h),this._easeId=e.easeId,this._prepareEase(r,e.noMoveStart,w),this._ease((function(e){if(n._zooming&&(i.zoom=t.number(o,u,e)),n._rotating&&(i.bearing=t.number(a,c,e)),n._pitching&&(i.pitch=t.number(s,p,e)),n._padding&&(i.interpolatePadding(l,h,e),d=i.centerPoint.add(f)),y)i.setLocationAtPoint(y,v);else{var m=i.zoomScale(i.zoom-o),g=u>o?Math.min(2,x):Math.max(.5,x),w=Math.pow(g,1-e),E=i.unproject(_.add(b.mult(e*w)).mult(m));i.setLocationAtPoint(i.renderWorldCopies?E.wrap():E,d)}n._fireMoveEvents(r)}),(function(t){n._afterEase(r,t)}),e),this},r.prototype._prepareEase=function(e,r,n){void 0===n&&(n={}),this._moving=!0,r||n.moving||this.fire(new t.Event("movestart",e)),this._zooming&&!n.zooming&&this.fire(new t.Event("zoomstart",e)),this._rotating&&!n.rotating&&this.fire(new t.Event("rotatestart",e)),this._pitching&&!n.pitching&&this.fire(new t.Event("pitchstart",e))},r.prototype._fireMoveEvents=function(e){this.fire(new t.Event("move",e)),this._zooming&&this.fire(new t.Event("zoom",e)),this._rotating&&this.fire(new t.Event("rotate",e)),this._pitching&&this.fire(new t.Event("pitch",e))},r.prototype._afterEase=function(e,r){if(!this._easeId||!r||this._easeId!==r){delete this._easeId;var n=this._zooming,i=this._rotating,o=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,n&&this.fire(new t.Event("zoomend",e)),i&&this.fire(new t.Event("rotateend",e)),o&&this.fire(new t.Event("pitchend",e)),this.fire(new t.Event("moveend",e))}},r.prototype.flyTo=function(e,r){var n=this;if(!e.essential&&t.browser.prefersReducedMotion){var i=t.pick(e,["center","zoom","bearing","pitch","around"]);return this.jumpTo(i,r)}this.stop(),e=t.extend({offset:[0,0],speed:1.2,curve:1.42,easing:t.ease},e);var o=this.transform,a=this.getZoom(),s=this.getBearing(),l=this.getPitch(),u=this.getPadding(),c="zoom"in e?t.clamp(+e.zoom,o.minZoom,o.maxZoom):a,p="bearing"in e?this._normalizeBearing(e.bearing,s):s,h="pitch"in e?+e.pitch:l,f="padding"in e?e.padding:o.padding,d=o.zoomScale(c-a),m=t.Point.convert(e.offset),g=o.centerPoint.add(m),y=o.pointLocation(g),v=t.LngLat.convert(e.center||y);this._normalizeCenter(v);var _=o.project(y),b=o.project(v).sub(_),x=e.curve,w=Math.max(o.width,o.height),E=w/d,T=b.mag();if("minZoom"in e){var A=t.clamp(Math.min(e.minZoom,a,c),o.minZoom,o.maxZoom),C=w/o.zoomScale(A-a);x=Math.sqrt(C/T*2)}var S=x*x;function P(t){var e=(E*E-w*w+(t?-1:1)*S*S*T*T)/(2*(t?E:w)*S*T);return Math.log(Math.sqrt(e*e+1)-e)}function I(t){return(Math.exp(t)-Math.exp(-t))/2}function D(t){return(Math.exp(t)+Math.exp(-t))/2}var O=P(0),M=function(t){return D(O)/D(O+x*t)},B=function(t){return w*((D(O)*(I(e=O+x*t)/D(e))-I(O))/S)/T;var e},k=(P(1)-O)/x;if(Math.abs(T)<1e-6||!isFinite(k)){if(Math.abs(w-E)<1e-6)return this.easeTo(e,r);var F=E<w?-1:1;k=Math.abs(Math.log(E/w))/x,B=function(){return 0},M=function(t){return Math.exp(F*x*t)}}return e.duration="duration"in e?+e.duration:1e3*k/("screenSpeed"in e?+e.screenSpeed/x:+e.speed),e.maxDuration&&e.duration>e.maxDuration&&(e.duration=0),this._zooming=!0,this._rotating=s!==p,this._pitching=h!==l,this._padding=!o.isPaddingEqual(f),this._prepareEase(r,!1),this._ease((function(e){var i=e*k,d=1/M(i);o.zoom=1===e?c:a+o.scaleZoom(d),n._rotating&&(o.bearing=t.number(s,p,e)),n._pitching&&(o.pitch=t.number(l,h,e)),n._padding&&(o.interpolatePadding(u,f,e),g=o.centerPoint.add(m));var y=1===e?v:o.unproject(_.add(b.mult(B(i))).mult(d));o.setLocationAtPoint(o.renderWorldCopies?y.wrap():y,g),n._fireMoveEvents(r)}),(function(){return n._afterEase(r)}),e),this},r.prototype.isEasing=function(){return!!this._easeFrameId},r.prototype.stop=function(){return this._stop()},r.prototype._stop=function(t,e){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),delete this._easeFrameId,delete this._onEaseFrame),this._onEaseEnd){var r=this._onEaseEnd;delete this._onEaseEnd,r.call(this,e)}if(!t){var n=this.handlers;n&&n.stop(!1)}return this},r.prototype._ease=function(e,r,n){!1===n.animate||0===n.duration?(e(1),r()):(this._easeStart=t.browser.now(),this._easeOptions=n,this._onEaseFrame=e,this._onEaseEnd=r,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))},r.prototype._renderFrameCallback=function(){var e=Math.min((t.browser.now()-this._easeStart)/this._easeOptions.duration,1);this._onEaseFrame(this._easeOptions.easing(e)),e<1?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()},r.prototype._normalizeBearing=function(e,r){e=t.wrap(e,-180,180);var n=Math.abs(e-r);return Math.abs(e-360-r)<n&&(e-=360),Math.abs(e+360-r)<n&&(e+=360),e},r.prototype._normalizeCenter=function(t){var e=this.transform;if(e.renderWorldCopies&&!e.lngRange){var r=t.lng-e.center.lng;t.lng+=r>180?-360:r<-180?360:0}},r}(t.Evented),_i=function(e){void 0===e&&(e={}),this.options=e,t.bindAll(["_toggleAttribution","_updateEditLink","_updateData","_updateCompact"],this)};_i.prototype.getDefaultPosition=function(){return"bottom-right"},_i.prototype.onAdd=function(t){var e=this.options&&this.options.compact;return this._map=t,this._container=r.create("div","mapboxgl-ctrl mapboxgl-ctrl-attrib"),this._compactButton=r.create("button","mapboxgl-ctrl-attrib-button",this._container),this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=r.create("div","mapboxgl-ctrl-attrib-inner",this._container),this._innerContainer.setAttribute("role","list"),e&&this._container.classList.add("mapboxgl-compact"),this._updateAttributions(),this._updateEditLink(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("moveend",this._updateEditLink),void 0===e&&(this._map.on("resize",this._updateCompact),this._updateCompact()),this._container},_i.prototype.onRemove=function(){r.remove(this._container),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("moveend",this._updateEditLink),this._map.off("resize",this._updateCompact),this._map=void 0,this._attribHTML=void 0},_i.prototype._setElementTitle=function(t,e){var r=this._map._getUIString("AttributionControl."+e);t.title=r,t.setAttribute("aria-label",r)},_i.prototype._toggleAttribution=function(){this._container.classList.contains("mapboxgl-compact-show")?(this._container.classList.remove("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-pressed","false")):(this._container.classList.add("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-pressed","true"))},_i.prototype._updateEditLink=function(){var e=this._editLink;e||(e=this._editLink=this._container.querySelector(".mapbox-improve-map"));var r=[{key:"owner",value:this.styleOwner},{key:"id",value:this.styleId},{key:"access_token",value:this._map._requestManager._customAccessToken||t.config.ACCESS_TOKEN}];if(e){var n=r.reduce((function(t,e,n){return e.value&&(t+=e.key+"="+e.value+(n<r.length-1?"&":"")),t}),"?");e.href=t.config.FEEDBACK_URL+"/"+n+(this._map._hash?this._map._hash.getHashString(!0):""),e.rel="noopener nofollow",this._setElementTitle(e,"MapFeedback")}},_i.prototype._updateData=function(t){!t||"metadata"!==t.sourceDataType&&"visibility"!==t.sourceDataType&&"style"!==t.dataType||(this._updateAttributions(),this._updateEditLink())},_i.prototype._updateAttributions=function(){if(this._map.style){var t=[];if(this.options.customAttribution&&(Array.isArray(this.options.customAttribution)?t=t.concat(this.options.customAttribution.map((function(t){return"string"!=typeof t?"":t}))):"string"==typeof this.options.customAttribution&&t.push(this.options.customAttribution)),this._map.style.stylesheet){var e=this._map.style.stylesheet;this.styleOwner=e.owner,this.styleId=e.id}var r=this._map.style.sourceCaches;for(var n in r){var i=r[n];if(i.used){var o=i.getSource();o.attribution&&t.indexOf(o.attribution)<0&&t.push(o.attribution)}}t.sort((function(t,e){return t.length-e.length}));var a=(t=t.filter((function(e,r){for(var n=r+1;n<t.length;n++)if(t[n].indexOf(e)>=0)return!1;return!0}))).join(" | ");a!==this._attribHTML&&(this._attribHTML=a,t.length?(this._innerContainer.innerHTML=a,this._container.classList.remove("mapboxgl-attrib-empty")):this._container.classList.add("mapboxgl-attrib-empty"),this._editLink=null)}},_i.prototype._updateCompact=function(){this._map.getCanvasContainer().offsetWidth<=640?this._container.classList.add("mapboxgl-compact"):this._container.classList.remove("mapboxgl-compact","mapboxgl-compact-show")};var bi=function(){t.bindAll(["_updateLogo"],this),t.bindAll(["_updateCompact"],this)};bi.prototype.onAdd=function(t){this._map=t,this._container=r.create("div","mapboxgl-ctrl");var e=r.create("a","mapboxgl-ctrl-logo");return e.target="_blank",e.rel="noopener nofollow",e.href="https://www.mapbox.com/",e.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),e.setAttribute("rel","noopener nofollow"),this._container.appendChild(e),this._container.style.display="none",this._map.on("sourcedata",this._updateLogo),this._updateLogo(),this._map.on("resize",this._updateCompact),this._updateCompact(),this._container},bi.prototype.onRemove=function(){r.remove(this._container),this._map.off("sourcedata",this._updateLogo),this._map.off("resize",this._updateCompact)},bi.prototype.getDefaultPosition=function(){return"bottom-left"},bi.prototype._updateLogo=function(t){t&&"metadata"!==t.sourceDataType||(this._container.style.display=this._logoRequired()?"block":"none")},bi.prototype._logoRequired=function(){if(this._map.style){var t=this._map.style.sourceCaches;for(var e in t)if(t[e].getSource().mapbox_logo)return!0;return!1}},bi.prototype._updateCompact=function(){var t=this._container.children;if(t.length){var e=t[0];this._map.getCanvasContainer().offsetWidth<250?e.classList.add("mapboxgl-compact"):e.classList.remove("mapboxgl-compact")}};var xi=function(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1};xi.prototype.add=function(t){var e=++this._id;return this._queue.push({callback:t,id:e,cancelled:!1}),e},xi.prototype.remove=function(t){for(var e=this._currentlyRunning,r=0,n=e?this._queue.concat(e):this._queue;r<n.length;r+=1){var i=n[r];if(i.id===t)return void(i.cancelled=!0)}},xi.prototype.run=function(t){void 0===t&&(t=0);var e=this._currentlyRunning=this._queue;this._queue=[];for(var r=0,n=e;r<n.length;r+=1){var i=n[r];if(!i.cancelled&&(i.callback(t),this._cleared))break}this._cleared=!1,this._currentlyRunning=!1},xi.prototype.clear=function(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]};var wi={"AttributionControl.ToggleAttribution":"Toggle attribution","AttributionControl.MapFeedback":"Map feedback","FullscreenControl.Enter":"Enter fullscreen","FullscreenControl.Exit":"Exit fullscreen","GeolocateControl.FindMyLocation":"Find my location","GeolocateControl.LocationNotAvailable":"Location not available","LogoControl.Title":"Mapbox logo","NavigationControl.ResetBearing":"Reset bearing to north","NavigationControl.ZoomIn":"Zoom in","NavigationControl.ZoomOut":"Zoom out","ScaleControl.Feet":"ft","ScaleControl.Meters":"m","ScaleControl.Kilometers":"km","ScaleControl.Miles":"mi","ScaleControl.NauticalMiles":"nm"},Ei=t.window.HTMLImageElement,Ti=t.window.HTMLElement,Ai=t.window.ImageBitmap,Ci={center:[0,0],zoom:0,bearing:0,pitch:0,minZoom:-2,maxZoom:22,minPitch:0,maxPitch:60,interactive:!0,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,hash:!1,attributionControl:!0,failIfMajorPerformanceCaveat:!1,preserveDrawingBuffer:!1,trackResize:!0,renderWorldCopies:!0,refreshExpiredTiles:!0,maxTileCacheSize:null,localIdeographFontFamily:"sans-serif",transformRequest:null,accessToken:null,fadeDuration:300,crossSourceCollisions:!0},Si=function(n){function i(e){var r=this;if(null!=(e=t.extend({},Ci,e)).minZoom&&null!=e.maxZoom&&e.minZoom>e.maxZoom)throw new Error("maxZoom must be greater than or equal to minZoom");if(null!=e.minPitch&&null!=e.maxPitch&&e.minPitch>e.maxPitch)throw new Error("maxPitch must be greater than or equal to minPitch");if(null!=e.minPitch&&e.minPitch<0)throw new Error("minPitch must be greater than or equal to 0");if(null!=e.maxPitch&&e.maxPitch>60)throw new Error("maxPitch must be less than or equal to 60");var i=new En(e.minZoom,e.maxZoom,e.minPitch,e.maxPitch,e.renderWorldCopies);if(n.call(this,i,e),this._interactive=e.interactive,this._maxTileCacheSize=e.maxTileCacheSize,this._failIfMajorPerformanceCaveat=e.failIfMajorPerformanceCaveat,this._preserveDrawingBuffer=e.preserveDrawingBuffer,this._antialias=e.antialias,this._trackResize=e.trackResize,this._bearingSnap=e.bearingSnap,this._refreshExpiredTiles=e.refreshExpiredTiles,this._fadeDuration=e.fadeDuration,this._crossSourceCollisions=e.crossSourceCollisions,this._crossFadingFactor=1,this._collectResourceTiming=e.collectResourceTiming,this._renderTaskQueue=new xi,this._controls=[],this._mapId=t.uniqueId(),this._locale=t.extend({},wi,e.locale),this._clickTolerance=e.clickTolerance,this._requestManager=new t.RequestManager(e.transformRequest,e.accessToken),"string"==typeof e.container){if(this._container=t.window.document.getElementById(e.container),!this._container)throw new Error("Container '"+e.container+"' not found.")}else{if(!(e.container instanceof Ti))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");this._container=e.container}if(e.maxBounds&&this.setMaxBounds(e.maxBounds),t.bindAll(["_onWindowOnline","_onWindowResize","_onMapScroll","_contextLost","_contextRestored"],this),this._setupContainer(),this._setupPainter(),void 0===this.painter)throw new Error("Failed to initialize WebGL.");this.on("move",(function(){return r._update(!1)})),this.on("moveend",(function(){return r._update(!1)})),this.on("zoom",(function(){return r._update(!0)})),void 0!==t.window&&(t.window.addEventListener("online",this._onWindowOnline,!1),t.window.addEventListener("resize",this._onWindowResize,!1),t.window.addEventListener("orientationchange",this._onWindowResize,!1)),this.handlers=new yi(this,e),this._hash=e.hash&&new An("string"==typeof e.hash&&e.hash||void 0).addTo(this),this._hash&&this._hash._onHashChange()||(this.jumpTo({center:e.center,zoom:e.zoom,bearing:e.bearing,pitch:e.pitch}),e.bounds&&(this.resize(),this.fitBounds(e.bounds,t.extend({},e.fitBoundsOptions,{duration:0})))),this.resize(),this._localIdeographFontFamily=e.localIdeographFontFamily,e.style&&this.setStyle(e.style,{localIdeographFontFamily:e.localIdeographFontFamily}),e.attributionControl&&this.addControl(new _i({customAttribution:e.customAttribution})),this.addControl(new bi,e.logoPosition),this.on("style.load",(function(){r.transform.unmodified&&r.jumpTo(r.style.stylesheet)})),this.on("data",(function(e){r._update("style"===e.dataType),r.fire(new t.Event(e.dataType+"data",e))})),this.on("dataloading",(function(e){r.fire(new t.Event(e.dataType+"dataloading",e))}))}n&&(i.__proto__=n),(i.prototype=Object.create(n&&n.prototype)).constructor=i;var o={showTileBoundaries:{configurable:!0},showPadding:{configurable:!0},showCollisionBoxes:{configurable:!0},showOverdrawInspector:{configurable:!0},repaint:{configurable:!0},vertices:{configurable:!0},version:{configurable:!0}};return i.prototype._getMapId=function(){return this._mapId},i.prototype.addControl=function(e,r){if(void 0===r&&(r=e.getDefaultPosition?e.getDefaultPosition():"top-right"),!e||!e.onAdd)return this.fire(new t.ErrorEvent(new Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));var n=e.onAdd(this);this._controls.push(e);var i=this._controlPositions[r];return-1!==r.indexOf("bottom")?i.insertBefore(n,i.firstChild):i.appendChild(n),this},i.prototype.removeControl=function(e){if(!e||!e.onRemove)return this.fire(new t.ErrorEvent(new Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));var r=this._controls.indexOf(e);return r>-1&&this._controls.splice(r,1),e.onRemove(this),this},i.prototype.hasControl=function(t){return this._controls.indexOf(t)>-1},i.prototype.resize=function(e){var r=this._containerDimensions(),n=r[0],i=r[1];this._resizeCanvas(n,i),this.transform.resize(n,i),this.painter.resize(n,i);var o=!this._moving;return o&&(this.stop(),this.fire(new t.Event("movestart",e)).fire(new t.Event("move",e))),this.fire(new t.Event("resize",e)),o&&this.fire(new t.Event("moveend",e)),this},i.prototype.getBounds=function(){return this.transform.getBounds()},i.prototype.getMaxBounds=function(){return this.transform.getMaxBounds()},i.prototype.setMaxBounds=function(e){return this.transform.setMaxBounds(t.LngLatBounds.convert(e)),this._update()},i.prototype.setMinZoom=function(t){if((t=null==t?-2:t)>=-2&&t<=this.transform.maxZoom)return this.transform.minZoom=t,this._update(),this.getZoom()<t&&this.setZoom(t),this;throw new Error("minZoom must be between -2 and the current maxZoom, inclusive")},i.prototype.getMinZoom=function(){return this.transform.minZoom},i.prototype.setMaxZoom=function(t){if((t=null==t?22:t)>=this.transform.minZoom)return this.transform.maxZoom=t,this._update(),this.getZoom()>t&&this.setZoom(t),this;throw new Error("maxZoom must be greater than the current minZoom")},i.prototype.getMaxZoom=function(){return this.transform.maxZoom},i.prototype.setMinPitch=function(t){if((t=null==t?0:t)<0)throw new Error("minPitch must be greater than or equal to 0");if(t>=0&&t<=this.transform.maxPitch)return this.transform.minPitch=t,this._update(),this.getPitch()<t&&this.setPitch(t),this;throw new Error("minPitch must be between 0 and the current maxPitch, inclusive")},i.prototype.getMinPitch=function(){return this.transform.minPitch},i.prototype.setMaxPitch=function(t){if((t=null==t?60:t)>60)throw new Error("maxPitch must be less than or equal to 60");if(t>=this.transform.minPitch)return this.transform.maxPitch=t,this._update(),this.getPitch()>t&&this.setPitch(t),this;throw new Error("maxPitch must be greater than the current minPitch")},i.prototype.getMaxPitch=function(){return this.transform.maxPitch},i.prototype.getRenderWorldCopies=function(){return this.transform.renderWorldCopies},i.prototype.setRenderWorldCopies=function(t){return this.transform.renderWorldCopies=t,this._update()},i.prototype.project=function(e){return this.transform.locationPoint(t.LngLat.convert(e))},i.prototype.unproject=function(e){return this.transform.pointLocation(t.Point.convert(e))},i.prototype.isMoving=function(){return this._moving||this.handlers.isMoving()},i.prototype.isZooming=function(){return this._zooming||this.handlers.isZooming()},i.prototype.isRotating=function(){return this._rotating||this.handlers.isRotating()},i.prototype._createDelegatedListener=function(t,e,r){var n,i=this;if("mouseenter"===t||"mouseover"===t){var o=!1;return{layer:e,listener:r,delegates:{mousemove:function(n){var a=i.getLayer(e)?i.queryRenderedFeatures(n.point,{layers:[e]}):[];a.length?o||(o=!0,r.call(i,new kn(t,i,n.originalEvent,{features:a}))):o=!1},mouseout:function(){o=!1}}}}if("mouseleave"===t||"mouseout"===t){var a=!1;return{layer:e,listener:r,delegates:{mousemove:function(n){(i.getLayer(e)?i.queryRenderedFeatures(n.point,{layers:[e]}):[]).length?a=!0:a&&(a=!1,r.call(i,new kn(t,i,n.originalEvent)))},mouseout:function(e){a&&(a=!1,r.call(i,new kn(t,i,e.originalEvent)))}}}}return{layer:e,listener:r,delegates:(n={},n[t]=function(t){var n=i.getLayer(e)?i.queryRenderedFeatures(t.point,{layers:[e]}):[];n.length&&(t.features=n,r.call(i,t),delete t.features)},n)}},i.prototype.on=function(t,e,r){if(void 0===r)return n.prototype.on.call(this,t,e);var i=this._createDelegatedListener(t,e,r);for(var o in this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[t]=this._delegatedListeners[t]||[],this._delegatedListeners[t].push(i),i.delegates)this.on(o,i.delegates[o]);return this},i.prototype.once=function(t,e,r){if(void 0===r)return n.prototype.once.call(this,t,e);var i=this._createDelegatedListener(t,e,r);for(var o in i.delegates)this.once(o,i.delegates[o]);return this},i.prototype.off=function(t,e,r){var i=this;return void 0===r?n.prototype.off.call(this,t,e):(this._delegatedListeners&&this._delegatedListeners[t]&&function(n){for(var o=n[t],a=0;a<o.length;a++){var s=o[a];if(s.layer===e&&s.listener===r){for(var l in s.delegates)i.off(l,s.delegates[l]);return o.splice(a,1),i}}}(this._delegatedListeners),this)},i.prototype.queryRenderedFeatures=function(e,r){if(!this.style)return[];var n;if(void 0!==r||void 0===e||e instanceof t.Point||Array.isArray(e)||(r=e,e=void 0),r=r||{},(e=e||[[0,0],[this.transform.width,this.transform.height]])instanceof t.Point||"number"==typeof e[0])n=[t.Point.convert(e)];else{var i=t.Point.convert(e[0]),o=t.Point.convert(e[1]);n=[i,new t.Point(o.x,i.y),o,new t.Point(i.x,o.y),i]}return this.style.queryRenderedFeatures(n,r,this.transform)},i.prototype.querySourceFeatures=function(t,e){return this.style.querySourceFeatures(t,e)},i.prototype.setStyle=function(e,r){return!1!==(r=t.extend({},{localIdeographFontFamily:this._localIdeographFontFamily},r)).diff&&r.localIdeographFontFamily===this._localIdeographFontFamily&&this.style&&e?(this._diffStyle(e,r),this):(this._localIdeographFontFamily=r.localIdeographFontFamily,this._updateStyle(e,r))},i.prototype._getUIString=function(t){var e=this._locale[t];if(null==e)throw new Error("Missing UI string '"+t+"'");return e},i.prototype._updateStyle=function(t,e){return this.style&&(this.style.setEventedParent(null),this.style._remove()),t?(this.style=new qe(this,e||{}),this.style.setEventedParent(this,{style:this.style}),"string"==typeof t?this.style.loadURL(t):this.style.loadJSON(t),this):(delete this.style,this)},i.prototype._lazyInitEmptyStyle=function(){this.style||(this.style=new qe(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())},i.prototype._diffStyle=function(e,r){var n=this;if("string"==typeof e){var i=this._requestManager.normalizeStyleURL(e),o=this._requestManager.transformRequest(i,t.ResourceType.Style);t.getJSON(o,(function(e,i){e?n.fire(new t.ErrorEvent(e)):i&&n._updateDiff(i,r)}))}else"object"==typeof e&&this._updateDiff(e,r)},i.prototype._updateDiff=function(e,r){try{this.style.setState(e)&&this._update(!0)}catch(n){t.warnOnce("Unable to perform style diff: "+(n.message||n.error||n)+". Rebuilding the style from scratch."),this._updateStyle(e,r)}},i.prototype.getStyle=function(){if(this.style)return this.style.serialize()},i.prototype.isStyleLoaded=function(){return this.style?this.style.loaded():t.warnOnce("There is no style added to the map.")},i.prototype.addSource=function(t,e){return this._lazyInitEmptyStyle(),this.style.addSource(t,e),this._update(!0)},i.prototype.isSourceLoaded=function(e){var r=this.style&&this.style.sourceCaches[e];if(void 0!==r)return r.loaded();this.fire(new t.ErrorEvent(new Error("There is no source with ID '"+e+"'")))},i.prototype.areTilesLoaded=function(){var t=this.style&&this.style.sourceCaches;for(var e in t){var r=t[e]._tiles;for(var n in r){var i=r[n];if("loaded"!==i.state&&"errored"!==i.state)return!1}}return!0},i.prototype.addSourceType=function(t,e,r){return this._lazyInitEmptyStyle(),this.style.addSourceType(t,e,r)},i.prototype.removeSource=function(t){return this.style.removeSource(t),this._update(!0)},i.prototype.getSource=function(t){return this.style.getSource(t)},i.prototype.addImage=function(e,r,n){void 0===n&&(n={});var i=n.pixelRatio;void 0===i&&(i=1);var o=n.sdf;void 0===o&&(o=!1);var a=n.stretchX,s=n.stretchY,l=n.content;if(this._lazyInitEmptyStyle(),r instanceof Ei||Ai&&r instanceof Ai){var u=t.browser.getImageData(r);this.style.addImage(e,{data:new t.RGBAImage({width:u.width,height:u.height},u.data),pixelRatio:i,stretchX:a,stretchY:s,content:l,sdf:o,version:0})}else{if(void 0===r.width||void 0===r.height)return this.fire(new t.ErrorEvent(new Error("Invalid arguments to map.addImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")));var c=r;this.style.addImage(e,{data:new t.RGBAImage({width:r.width,height:r.height},new Uint8Array(r.data)),pixelRatio:i,stretchX:a,stretchY:s,content:l,sdf:o,version:0,userImage:c}),c.onAdd&&c.onAdd(this,e)}},i.prototype.updateImage=function(e,r){var n=this.style.getImage(e);if(!n)return this.fire(new t.ErrorEvent(new Error("The map has no image with that id. If you are adding a new image use `map.addImage(...)` instead.")));var i=r instanceof Ei||Ai&&r instanceof Ai?t.browser.getImageData(r):r,o=i.width,a=i.height,s=i.data;return void 0===o||void 0===a?this.fire(new t.ErrorEvent(new Error("Invalid arguments to map.updateImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`"))):o!==n.data.width||a!==n.data.height?this.fire(new t.ErrorEvent(new Error("The width and height of the updated image must be that same as the previous version of the image"))):(n.data.replace(s,!(r instanceof Ei||Ai&&r instanceof Ai)),void this.style.updateImage(e,n))},i.prototype.hasImage=function(e){return e?!!this.style.getImage(e):(this.fire(new t.ErrorEvent(new Error("Missing required image id"))),!1)},i.prototype.removeImage=function(t){this.style.removeImage(t)},i.prototype.loadImage=function(e,r){t.getImage(this._requestManager.transformRequest(e,t.ResourceType.Image),r)},i.prototype.listImages=function(){return this.style.listImages()},i.prototype.addLayer=function(t,e){return this._lazyInitEmptyStyle(),this.style.addLayer(t,e),this._update(!0)},i.prototype.moveLayer=function(t,e){return this.style.moveLayer(t,e),this._update(!0)},i.prototype.removeLayer=function(t){return this.style.removeLayer(t),this._update(!0)},i.prototype.getLayer=function(t){return this.style.getLayer(t)},i.prototype.setLayerZoomRange=function(t,e,r){return this.style.setLayerZoomRange(t,e,r),this._update(!0)},i.prototype.setFilter=function(t,e,r){return void 0===r&&(r={}),this.style.setFilter(t,e,r),this._update(!0)},i.prototype.getFilter=function(t){return this.style.getFilter(t)},i.prototype.setPaintProperty=function(t,e,r,n){return void 0===n&&(n={}),this.style.setPaintProperty(t,e,r,n),this._update(!0)},i.prototype.getPaintProperty=function(t,e){return this.style.getPaintProperty(t,e)},i.prototype.setLayoutProperty=function(t,e,r,n){return void 0===n&&(n={}),this.style.setLayoutProperty(t,e,r,n),this._update(!0)},i.prototype.getLayoutProperty=function(t,e){return this.style.getLayoutProperty(t,e)},i.prototype.setLight=function(t,e){return void 0===e&&(e={}),this._lazyInitEmptyStyle(),this.style.setLight(t,e),this._update(!0)},i.prototype.getLight=function(){return this.style.getLight()},i.prototype.setFeatureState=function(t,e){return this.style.setFeatureState(t,e),this._update()},i.prototype.removeFeatureState=function(t,e){return this.style.removeFeatureState(t,e),this._update()},i.prototype.getFeatureState=function(t){return this.style.getFeatureState(t)},i.prototype.getContainer=function(){return this._container},i.prototype.getCanvasContainer=function(){return this._canvasContainer},i.prototype.getCanvas=function(){return this._canvas},i.prototype._containerDimensions=function(){var t=0,e=0;return this._container&&(t=this._container.clientWidth||400,e=this._container.clientHeight||300),[t,e]},i.prototype._detectMissingCSS=function(){"rgb(250, 128, 114)"!==t.window.getComputedStyle(this._missingCSSCanary).getPropertyValue("background-color")&&t.warnOnce("This page appears to be missing CSS declarations for Mapbox GL JS, which may cause the map to display incorrectly. Please ensure your page includes mapbox-gl.css, as described in https://www.mapbox.com/mapbox-gl-js/api/.")},i.prototype._setupContainer=function(){var t=this._container;t.classList.add("mapboxgl-map"),(this._missingCSSCanary=r.create("div","mapboxgl-canary",t)).style.visibility="hidden",this._detectMissingCSS();var e=this._canvasContainer=r.create("div","mapboxgl-canvas-container",t);this._interactive&&e.classList.add("mapboxgl-interactive"),this._canvas=r.create("canvas","mapboxgl-canvas",e),this._canvas.addEventListener("webglcontextlost",this._contextLost,!1),this._canvas.addEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.setAttribute("tabindex","0"),this._canvas.setAttribute("aria-label","Map"),this._canvas.setAttribute("role","region");var n=this._containerDimensions();this._resizeCanvas(n[0],n[1]);var i=this._controlContainer=r.create("div","mapboxgl-control-container",t),o=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach((function(t){o[t]=r.create("div","mapboxgl-ctrl-"+t,i)})),this._container.addEventListener("scroll",this._onMapScroll,!1)},i.prototype._resizeCanvas=function(e,r){var n=t.browser.devicePixelRatio||1;this._canvas.width=n*e,this._canvas.height=n*r,this._canvas.style.width=e+"px",this._canvas.style.height=r+"px"},i.prototype._setupPainter=function(){var r=t.extend({},e.webGLContextAttributes,{failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer,antialias:this._antialias||!1}),n=this._canvas.getContext("webgl",r)||this._canvas.getContext("experimental-webgl",r);n?(this.painter=new _n(n,this.transform),t.webpSupported.testSupport(n)):this.fire(new t.ErrorEvent(new Error("Failed to initialize WebGL")))},i.prototype._contextLost=function(e){e.preventDefault(),this._frame&&(this._frame.cancel(),this._frame=null),this.fire(new t.Event("webglcontextlost",{originalEvent:e}))},i.prototype._contextRestored=function(e){this._setupPainter(),this.resize(),this._update(),this.fire(new t.Event("webglcontextrestored",{originalEvent:e}))},i.prototype._onMapScroll=function(t){if(t.target===this._container)return this._container.scrollTop=0,this._container.scrollLeft=0,!1},i.prototype.loaded=function(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()},i.prototype._update=function(t){return this.style?(this._styleDirty=this._styleDirty||t,this._sourcesDirty=!0,this.triggerRepaint(),this):this},i.prototype._requestRenderFrame=function(t){return this._update(),this._renderTaskQueue.add(t)},i.prototype._cancelRenderFrame=function(t){this._renderTaskQueue.remove(t)},i.prototype._render=function(e){var r,n=this,i=0,o=this.painter.context.extTimerQuery;if(this.listens("gpu-timing-frame")&&(r=o.createQueryEXT(),o.beginQueryEXT(o.TIME_ELAPSED_EXT,r),i=t.browser.now()),this.painter.context.setDirty(),this.painter.setBaseState(),this._renderTaskQueue.run(e),!this._removed){var a=!1;if(this.style&&this._styleDirty){this._styleDirty=!1;var s=this.transform.zoom,l=t.browser.now();this.style.zoomHistory.update(s,l);var u=new t.EvaluationParameters(s,{now:l,fadeDuration:this._fadeDuration,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),c=u.crossFadingFactor();1===c&&c===this._crossFadingFactor||(a=!0,this._crossFadingFactor=c),this.style.update(u)}if(this.style&&this._sourcesDirty&&(this._sourcesDirty=!1,this.style._updateSources(this.transform)),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,this._fadeDuration,this._crossSourceCollisions),this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showOverdrawInspector:this._showOverdrawInspector,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:this._fadeDuration,showPadding:this.showPadding,gpuTiming:!!this.listens("gpu-timing-layer")}),this.fire(new t.Event("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,this.fire(new t.Event("load"))),this.style&&(this.style.hasTransitions()||a)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles(),this.listens("gpu-timing-frame")){var p=t.browser.now()-i;o.endQueryEXT(o.TIME_ELAPSED_EXT,r),setTimeout((function(){var e=o.getQueryObjectEXT(r,o.QUERY_RESULT_EXT)/1e6;o.deleteQueryEXT(r),n.fire(new t.Event("gpu-timing-frame",{cpuTime:p,gpuTime:e}))}),50)}if(this.listens("gpu-timing-layer")){var h=this.painter.collectGpuTimers();setTimeout((function(){var e=n.painter.queryGpuTimers(h);n.fire(new t.Event("gpu-timing-layer",{layerTimes:e}))}),50)}var f=this._sourcesDirty||this._styleDirty||this._placementDirty;return f||this._repaint?this.triggerRepaint():!this.isMoving()&&this.loaded()&&this.fire(new t.Event("idle")),!this._loaded||this._fullyLoaded||f||(this._fullyLoaded=!0),this}},i.prototype.remove=function(){this._hash&&this._hash.remove();for(var e=0,r=this._controls;e<r.length;e+=1)r[e].onRemove(this);this._controls=[],this._frame&&(this._frame.cancel(),this._frame=null),this._renderTaskQueue.clear(),this.painter.destroy(),this.handlers.destroy(),delete this.handlers,this.setStyle(null),void 0!==t.window&&(t.window.removeEventListener("resize",this._onWindowResize,!1),t.window.removeEventListener("orientationchange",this._onWindowResize,!1),t.window.removeEventListener("online",this._onWindowOnline,!1));var n=this.painter.context.gl.getExtension("WEBGL_lose_context");n&&n.loseContext(),Pi(this._canvasContainer),Pi(this._controlContainer),Pi(this._missingCSSCanary),this._container.classList.remove("mapboxgl-map"),this._removed=!0,this.fire(new t.Event("remove"))},i.prototype.triggerRepaint=function(){var e=this;this.style&&!this._frame&&(this._frame=t.browser.frame((function(t){e._frame=null,e._render(t)})))},i.prototype._onWindowOnline=function(){this._update()},i.prototype._onWindowResize=function(t){this._trackResize&&this.resize({originalEvent:t})._update()},o.showTileBoundaries.get=function(){return!!this._showTileBoundaries},o.showTileBoundaries.set=function(t){this._showTileBoundaries!==t&&(this._showTileBoundaries=t,this._update())},o.showPadding.get=function(){return!!this._showPadding},o.showPadding.set=function(t){this._showPadding!==t&&(this._showPadding=t,this._update())},o.showCollisionBoxes.get=function(){return!!this._showCollisionBoxes},o.showCollisionBoxes.set=function(t){this._showCollisionBoxes!==t&&(this._showCollisionBoxes=t,t?this.style._generateCollisionBoxes():this._update())},o.showOverdrawInspector.get=function(){return!!this._showOverdrawInspector},o.showOverdrawInspector.set=function(t){this._showOverdrawInspector!==t&&(this._showOverdrawInspector=t,this._update())},o.repaint.get=function(){return!!this._repaint},o.repaint.set=function(t){this._repaint!==t&&(this._repaint=t,this.triggerRepaint())},o.vertices.get=function(){return!!this._vertices},o.vertices.set=function(t){this._vertices=t,this._update()},i.prototype._setCacheLimits=function(e,r){t.setCacheLimits(e,r)},o.version.get=function(){return t.version},Object.defineProperties(i.prototype,o),i}(vi);function Pi(t){t.parentNode&&t.parentNode.removeChild(t)}var Ii={showCompass:!0,showZoom:!0,visualizePitch:!1},Di=function(e){var n=this;this.options=t.extend({},Ii,e),this._container=r.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._container.addEventListener("contextmenu",(function(t){return t.preventDefault()})),this.options.showZoom&&(t.bindAll(["_setButtonTitle","_updateZoomButtons"],this),this._zoomInButton=this._createButton("mapboxgl-ctrl-zoom-in",(function(t){return n._map.zoomIn({},{originalEvent:t})})),r.create("span","mapboxgl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden",!0),this._zoomOutButton=this._createButton("mapboxgl-ctrl-zoom-out",(function(t){return n._map.zoomOut({},{originalEvent:t})})),r.create("span","mapboxgl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden",!0)),this.options.showCompass&&(t.bindAll(["_rotateCompassArrow"],this),this._compass=this._createButton("mapboxgl-ctrl-compass",(function(t){n.options.visualizePitch?n._map.resetNorthPitch({},{originalEvent:t}):n._map.resetNorth({},{originalEvent:t})})),this._compassIcon=r.create("span","mapboxgl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden",!0))};Di.prototype._updateZoomButtons=function(){var t=this._map.getZoom(),e=t===this._map.getMaxZoom(),r=t===this._map.getMinZoom();this._zoomInButton.disabled=e,this._zoomOutButton.disabled=r,this._zoomInButton.setAttribute("aria-disabled",e.toString()),this._zoomOutButton.setAttribute("aria-disabled",r.toString())},Di.prototype._rotateCompassArrow=function(){var t=this.options.visualizePitch?"scale("+1/Math.pow(Math.cos(this._map.transform.pitch*(Math.PI/180)),.5)+") rotateX("+this._map.transform.pitch+"deg) rotateZ("+this._map.transform.angle*(180/Math.PI)+"deg)":"rotate("+this._map.transform.angle*(180/Math.PI)+"deg)";this._compassIcon.style.transform=t},Di.prototype.onAdd=function(t){return this._map=t,this.options.showZoom&&(this._setButtonTitle(this._zoomInButton,"ZoomIn"),this._setButtonTitle(this._zoomOutButton,"ZoomOut"),this._map.on("zoom",this._updateZoomButtons),this._updateZoomButtons()),this.options.showCompass&&(this._setButtonTitle(this._compass,"ResetBearing"),this.options.visualizePitch&&this._map.on("pitch",this._rotateCompassArrow),this._map.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new Oi(this._map,this._compass,this.options.visualizePitch)),this._container},Di.prototype.onRemove=function(){r.remove(this._container),this.options.showZoom&&this._map.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&this._map.off("pitch",this._rotateCompassArrow),this._map.off("rotate",this._rotateCompassArrow),this._handler.off(),delete this._handler),delete this._map},Di.prototype._createButton=function(t,e){var n=r.create("button",t,this._container);return n.type="button",n.addEventListener("click",e),n},Di.prototype._setButtonTitle=function(t,e){var r=this._map._getUIString("NavigationControl."+e);t.title=r,t.setAttribute("aria-label",r)};var Oi=function(e,n,i){void 0===i&&(i=!1),this._clickTolerance=10,this.element=n,this.mouseRotate=new Wn({clickTolerance:e.dragRotate._mouseRotate._clickTolerance}),this.map=e,i&&(this.mousePitch=new Yn({clickTolerance:e.dragRotate._mousePitch._clickTolerance})),t.bindAll(["mousedown","mousemove","mouseup","touchstart","touchmove","touchend","reset"],this),r.addEventListener(n,"mousedown",this.mousedown),r.addEventListener(n,"touchstart",this.touchstart,{passive:!1}),r.addEventListener(n,"touchmove",this.touchmove),r.addEventListener(n,"touchend",this.touchend),r.addEventListener(n,"touchcancel",this.reset)};function Mi(e,r,n){if(e=new t.LngLat(e.lng,e.lat),r){var i=new t.LngLat(e.lng-360,e.lat),o=new t.LngLat(e.lng+360,e.lat),a=n.locationPoint(e).distSqr(r);n.locationPoint(i).distSqr(r)<a?e=i:n.locationPoint(o).distSqr(r)<a&&(e=o)}for(;Math.abs(e.lng-n.center.lng)>180;){var s=n.locationPoint(e);if(s.x>=0&&s.y>=0&&s.x<=n.width&&s.y<=n.height)break;e.lng>n.center.lng?e.lng-=360:e.lng+=360}return e}Oi.prototype.down=function(t,e){this.mouseRotate.mousedown(t,e),this.mousePitch&&this.mousePitch.mousedown(t,e),r.disableDrag()},Oi.prototype.move=function(t,e){var r=this.map,n=this.mouseRotate.mousemoveWindow(t,e);if(n&&n.bearingDelta&&r.setBearing(r.getBearing()+n.bearingDelta),this.mousePitch){var i=this.mousePitch.mousemoveWindow(t,e);i&&i.pitchDelta&&r.setPitch(r.getPitch()+i.pitchDelta)}},Oi.prototype.off=function(){var t=this.element;r.removeEventListener(t,"mousedown",this.mousedown),r.removeEventListener(t,"touchstart",this.touchstart,{passive:!1}),r.removeEventListener(t,"touchmove",this.touchmove),r.removeEventListener(t,"touchend",this.touchend),r.removeEventListener(t,"touchcancel",this.reset),this.offTemp()},Oi.prototype.offTemp=function(){r.enableDrag(),r.removeEventListener(t.window,"mousemove",this.mousemove),r.removeEventListener(t.window,"mouseup",this.mouseup)},Oi.prototype.mousedown=function(e){this.down(t.extend({},e,{ctrlKey:!0,preventDefault:function(){return e.preventDefault()}}),r.mousePos(this.element,e)),r.addEventListener(t.window,"mousemove",this.mousemove),r.addEventListener(t.window,"mouseup",this.mouseup)},Oi.prototype.mousemove=function(t){this.move(t,r.mousePos(this.element,t))},Oi.prototype.mouseup=function(t){this.mouseRotate.mouseupWindow(t),this.mousePitch&&this.mousePitch.mouseupWindow(t),this.offTemp()},Oi.prototype.touchstart=function(t){1!==t.targetTouches.length?this.reset():(this._startPos=this._lastPos=r.touchPos(this.element,t.targetTouches)[0],this.down({type:"mousedown",button:0,ctrlKey:!0,preventDefault:function(){return t.preventDefault()}},this._startPos))},Oi.prototype.touchmove=function(t){1!==t.targetTouches.length?this.reset():(this._lastPos=r.touchPos(this.element,t.targetTouches)[0],this.move({preventDefault:function(){return t.preventDefault()}},this._lastPos))},Oi.prototype.touchend=function(t){0===t.targetTouches.length&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)<this._clickTolerance&&this.element.click(),this.reset()},Oi.prototype.reset=function(){this.mouseRotate.reset(),this.mousePitch&&this.mousePitch.reset(),delete this._startPos,delete this._lastPos,this.offTemp()};var Bi={center:"translate(-50%,-50%)",top:"translate(-50%,0)","top-left":"translate(0,0)","top-right":"translate(-100%,0)",bottom:"translate(-50%,-100%)","bottom-left":"translate(0,-100%)","bottom-right":"translate(-100%,-100%)",left:"translate(0,-50%)",right:"translate(-100%,-50%)"};function ki(t,e,r){var n=t.classList;for(var i in Bi)n.remove("mapboxgl-"+r+"-anchor-"+i);n.add("mapboxgl-"+r+"-anchor-"+e)}var Fi,Li=function(e){function n(n,i){if(e.call(this),(n instanceof t.window.HTMLElement||i)&&(n=t.extend({element:n},i)),t.bindAll(["_update","_onMove","_onUp","_addDragHandler","_onMapClick","_onKeyPress"],this),this._anchor=n&&n.anchor||"center",this._color=n&&n.color||"#3FB1CE",this._scale=n&&n.scale||1,this._draggable=n&&n.draggable||!1,this._clickTolerance=n&&n.clickTolerance||0,this._isDragging=!1,this._state="inactive",this._rotation=n&&n.rotation||0,this._rotationAlignment=n&&n.rotationAlignment||"auto",this._pitchAlignment=n&&n.pitchAlignment&&"auto"!==n.pitchAlignment?n.pitchAlignment:this._rotationAlignment,n&&n.element)this._element=n.element,this._offset=t.Point.convert(n&&n.offset||[0,0]);else{this._defaultMarker=!0,this._element=r.create("div"),this._element.setAttribute("aria-label","Map marker");var o=r.createNS("http://www.w3.org/2000/svg","svg");o.setAttributeNS(null,"display","block"),o.setAttributeNS(null,"height","41px"),o.setAttributeNS(null,"width","27px"),o.setAttributeNS(null,"viewBox","0 0 27 41");var a=r.createNS("http://www.w3.org/2000/svg","g");a.setAttributeNS(null,"stroke","none"),a.setAttributeNS(null,"stroke-width","1"),a.setAttributeNS(null,"fill","none"),a.setAttributeNS(null,"fill-rule","evenodd");var s=r.createNS("http://www.w3.org/2000/svg","g");s.setAttributeNS(null,"fill-rule","nonzero");var l=r.createNS("http://www.w3.org/2000/svg","g");l.setAttributeNS(null,"transform","translate(3.0, 29.0)"),l.setAttributeNS(null,"fill","#000000");for(var u=0,c=[{rx:"10.5",ry:"5.25002273"},{rx:"10.5",ry:"5.25002273"},{rx:"9.5",ry:"4.77275007"},{rx:"8.5",ry:"4.29549936"},{rx:"7.5",ry:"3.81822308"},{rx:"6.5",ry:"3.34094679"},{rx:"5.5",ry:"2.86367051"},{rx:"4.5",ry:"2.38636864"}];u<c.length;u+=1){var p=c[u],h=r.createNS("http://www.w3.org/2000/svg","ellipse");h.setAttributeNS(null,"opacity","0.04"),h.setAttributeNS(null,"cx","10.5"),h.setAttributeNS(null,"cy","5.80029008"),h.setAttributeNS(null,"rx",p.rx),h.setAttributeNS(null,"ry",p.ry),l.appendChild(h)}var f=r.createNS("http://www.w3.org/2000/svg","g");f.setAttributeNS(null,"fill",this._color);var d=r.createNS("http://www.w3.org/2000/svg","path");d.setAttributeNS(null,"d","M27,13.5 C27,19.074644 20.250001,27.000002 14.75,34.500002 C14.016665,35.500004 12.983335,35.500004 12.25,34.500002 C6.7499993,27.000002 0,19.222562 0,13.5 C0,6.0441559 6.0441559,0 13.5,0 C20.955844,0 27,6.0441559 27,13.5 Z"),f.appendChild(d);var m=r.createNS("http://www.w3.org/2000/svg","g");m.setAttributeNS(null,"opacity","0.25"),m.setAttributeNS(null,"fill","#000000");var g=r.createNS("http://www.w3.org/2000/svg","path");g.setAttributeNS(null,"d","M13.5,0 C6.0441559,0 0,6.0441559 0,13.5 C0,19.222562 6.7499993,27 12.25,34.5 C13,35.522727 14.016664,35.500004 14.75,34.5 C20.250001,27 27,19.074644 27,13.5 C27,6.0441559 20.955844,0 13.5,0 Z M13.5,1 C20.415404,1 26,6.584596 26,13.5 C26,15.898657 24.495584,19.181431 22.220703,22.738281 C19.945823,26.295132 16.705119,30.142167 13.943359,33.908203 C13.743445,34.180814 13.612715,34.322738 13.5,34.441406 C13.387285,34.322738 13.256555,34.180814 13.056641,33.908203 C10.284481,30.127985 7.4148684,26.314159 5.015625,22.773438 C2.6163816,19.232715 1,15.953538 1,13.5 C1,6.584596 6.584596,1 13.5,1 Z"),m.appendChild(g);var y=r.createNS("http://www.w3.org/2000/svg","g");y.setAttributeNS(null,"transform","translate(6.0, 7.0)"),y.setAttributeNS(null,"fill","#FFFFFF");var v=r.createNS("http://www.w3.org/2000/svg","g");v.setAttributeNS(null,"transform","translate(8.0, 8.0)");var _=r.createNS("http://www.w3.org/2000/svg","circle");_.setAttributeNS(null,"fill","#000000"),_.setAttributeNS(null,"opacity","0.25"),_.setAttributeNS(null,"cx","5.5"),_.setAttributeNS(null,"cy","5.5"),_.setAttributeNS(null,"r","5.4999962");var b=r.createNS("http://www.w3.org/2000/svg","circle");b.setAttributeNS(null,"fill","#FFFFFF"),b.setAttributeNS(null,"cx","5.5"),b.setAttributeNS(null,"cy","5.5"),b.setAttributeNS(null,"r","5.4999962"),v.appendChild(_),v.appendChild(b),s.appendChild(l),s.appendChild(f),s.appendChild(m),s.appendChild(y),s.appendChild(v),o.appendChild(s),o.setAttributeNS(null,"height",41*this._scale+"px"),o.setAttributeNS(null,"width",27*this._scale+"px"),this._element.appendChild(o),this._offset=t.Point.convert(n&&n.offset||[0,-14])}this._element.classList.add("mapboxgl-marker"),this._element.addEventListener("dragstart",(function(t){t.preventDefault()})),this._element.addEventListener("mousedown",(function(t){t.preventDefault()})),ki(this._element,this._anchor,"marker"),this._popup=null}return e&&(n.__proto__=e),(n.prototype=Object.create(e&&e.prototype)).constructor=n,n.prototype.addTo=function(t){return this.remove(),this._map=t,t.getCanvasContainer().appendChild(this._element),t.on("move",this._update),t.on("moveend",this._update),this.setDraggable(this._draggable),this._update(),this._map.on("click",this._onMapClick),this},n.prototype.remove=function(){return this._map&&(this._map.off("click",this._onMapClick),this._map.off("move",this._update),this._map.off("moveend",this._update),this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler),this._map.off("mouseup",this._onUp),this._map.off("touchend",this._onUp),this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),delete this._map),r.remove(this._element),this._popup&&this._popup.remove(),this},n.prototype.getLngLat=function(){return this._lngLat},n.prototype.setLngLat=function(e){return this._lngLat=t.LngLat.convert(e),this._pos=null,this._popup&&this._popup.setLngLat(this._lngLat),this._update(),this},n.prototype.getElement=function(){return this._element},n.prototype.setPopup=function(t){if(this._popup&&(this._popup.remove(),this._popup=null,this._element.removeEventListener("keypress",this._onKeyPress),this._originalTabIndex||this._element.removeAttribute("tabindex")),t){if(!("offset"in t.options)){var e=Math.sqrt(Math.pow(13.5,2)/2);t.options.offset=this._defaultMarker?{top:[0,0],"top-left":[0,0],"top-right":[0,0],bottom:[0,-38.1],"bottom-left":[e,-1*(24.6+e)],"bottom-right":[-e,-1*(24.6+e)],left:[13.5,-24.6],right:[-13.5,-24.6]}:this._offset}this._popup=t,this._lngLat&&this._popup.setLngLat(this._lngLat),this._originalTabIndex=this._element.getAttribute("tabindex"),this._originalTabIndex||this._element.setAttribute("tabindex","0"),this._element.addEventListener("keypress",this._onKeyPress)}return this},n.prototype._onKeyPress=function(t){var e=t.code,r=t.charCode||t.keyCode;"Space"!==e&&"Enter"!==e&&32!==r&&13!==r||this.togglePopup()},n.prototype._onMapClick=function(t){var e=t.originalEvent.target,r=this._element;this._popup&&(e===r||r.contains(e))&&this.togglePopup()},n.prototype.getPopup=function(){return this._popup},n.prototype.togglePopup=function(){var t=this._popup;return t?(t.isOpen()?t.remove():t.addTo(this._map),this):this},n.prototype._update=function(t){if(this._map){this._map.transform.renderWorldCopies&&(this._lngLat=Mi(this._lngLat,this._pos,this._map.transform)),this._pos=this._map.project(this._lngLat)._add(this._offset);var e="";"viewport"===this._rotationAlignment||"auto"===this._rotationAlignment?e="rotateZ("+this._rotation+"deg)":"map"===this._rotationAlignment&&(e="rotateZ("+(this._rotation-this._map.getBearing())+"deg)");var n="";"viewport"===this._pitchAlignment||"auto"===this._pitchAlignment?n="rotateX(0deg)":"map"===this._pitchAlignment&&(n="rotateX("+this._map.getPitch()+"deg)"),t&&"moveend"!==t.type||(this._pos=this._pos.round()),r.setTransform(this._element,Bi[this._anchor]+" translate("+this._pos.x+"px, "+this._pos.y+"px) "+n+" "+e)}},n.prototype.getOffset=function(){return this._offset},n.prototype.setOffset=function(e){return this._offset=t.Point.convert(e),this._update(),this},n.prototype._onMove=function(e){if(!this._isDragging){var r=this._clickTolerance||this._map._clickTolerance;this._isDragging=e.point.dist(this._pointerdownPos)>=r}this._isDragging&&(this._pos=e.point.sub(this._positionDelta),this._lngLat=this._map.unproject(this._pos),this.setLngLat(this._lngLat),this._element.style.pointerEvents="none","pending"===this._state&&(this._state="active",this.fire(new t.Event("dragstart"))),this.fire(new t.Event("drag")))},n.prototype._onUp=function(){this._element.style.pointerEvents="auto",this._positionDelta=null,this._pointerdownPos=null,this._isDragging=!1,this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),"active"===this._state&&this.fire(new t.Event("dragend")),this._state="inactive"},n.prototype._addDragHandler=function(t){this._element.contains(t.originalEvent.target)&&(t.preventDefault(),this._positionDelta=t.point.sub(this._pos).add(this._offset),this._pointerdownPos=t.point,this._state="pending",this._map.on("mousemove",this._onMove),this._map.on("touchmove",this._onMove),this._map.once("mouseup",this._onUp),this._map.once("touchend",this._onUp))},n.prototype.setDraggable=function(t){return this._draggable=!!t,this._map&&(t?(this._map.on("mousedown",this._addDragHandler),this._map.on("touchstart",this._addDragHandler)):(this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler))),this},n.prototype.isDraggable=function(){return this._draggable},n.prototype.setRotation=function(t){return this._rotation=t||0,this._update(),this},n.prototype.getRotation=function(){return this._rotation},n.prototype.setRotationAlignment=function(t){return this._rotationAlignment=t||"auto",this._update(),this},n.prototype.getRotationAlignment=function(){return this._rotationAlignment},n.prototype.setPitchAlignment=function(t){return this._pitchAlignment=t&&"auto"!==t?t:this._rotationAlignment,this._update(),this},n.prototype.getPitchAlignment=function(){return this._pitchAlignment},n}(t.Evented),Ri={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0},zi=0,Ni=!1,ji=function(e){function n(r){e.call(this),this.options=t.extend({},Ri,r),t.bindAll(["_onSuccess","_onError","_onZoom","_finish","_setupUI","_updateCamera","_updateMarker"],this)}return e&&(n.__proto__=e),(n.prototype=Object.create(e&&e.prototype)).constructor=n,n.prototype.onAdd=function(e){var n;return this._map=e,this._container=r.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),n=this._setupUI,void 0!==Fi?n(Fi):void 0!==t.window.navigator.permissions?t.window.navigator.permissions.query({name:"geolocation"}).then((function(t){n(Fi="denied"!==t.state)})):n(Fi=!!t.window.navigator.geolocation),this._container},n.prototype.onRemove=function(){void 0!==this._geolocationWatchID&&(t.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),r.remove(this._container),this._map.off("zoom",this._onZoom),this._map=void 0,zi=0,Ni=!1},n.prototype._isOutOfMapMaxBounds=function(t){var e=this._map.getMaxBounds(),r=t.coords;return e&&(r.longitude<e.getWest()||r.longitude>e.getEast()||r.latitude<e.getSouth()||r.latitude>e.getNorth())},n.prototype._setErrorState=function(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting")}},n.prototype._onSuccess=function(e){if(this._map){if(this._isOutOfMapMaxBounds(e))return this._setErrorState(),this.fire(new t.Event("outofmaxbounds",e)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=e,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background")}this.options.showUserLocation&&"OFF"!==this._watchState&&this._updateMarker(e),this.options.trackUserLocation&&"ACTIVE_LOCK"!==this._watchState||this._updateCamera(e),this.options.showUserLocation&&this._dotElement.classList.remove("mapboxgl-user-location-dot-stale"),this.fire(new t.Event("geolocate",e)),this._finish()}},n.prototype._updateCamera=function(e){var r=new t.LngLat(e.coords.longitude,e.coords.latitude),n=e.coords.accuracy,i=this._map.getBearing(),o=t.extend({bearing:i},this.options.fitBoundsOptions);this._map.fitBounds(r.toBounds(n),o,{geolocateSource:!0})},n.prototype._updateMarker=function(e){if(e){var r=new t.LngLat(e.coords.longitude,e.coords.latitude);this._accuracyCircleMarker.setLngLat(r).addTo(this._map),this._userLocationDotMarker.setLngLat(r).addTo(this._map),this._accuracy=e.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()},n.prototype._updateCircleRadius=function(){var t=this._map._container.clientHeight/2,e=this._map.unproject([0,t]),r=this._map.unproject([1,t]),n=e.distanceTo(r),i=Math.ceil(2*this._accuracy/n);this._circleElement.style.width=i+"px",this._circleElement.style.height=i+"px"},n.prototype._onZoom=function(){this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()},n.prototype._onError=function(e){if(this._map){if(this.options.trackUserLocation)if(1===e.code){this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;var r=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.title=r,this._geolocateButton.setAttribute("aria-label",r),void 0!==this._geolocationWatchID&&this._clearWatch()}else{if(3===e.code&&Ni)return;this._setErrorState()}"OFF"!==this._watchState&&this.options.showUserLocation&&this._dotElement.classList.add("mapboxgl-user-location-dot-stale"),this.fire(new t.Event("error",e)),this._finish()}},n.prototype._finish=function(){this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0},n.prototype._setupUI=function(e){var n=this;if(this._container.addEventListener("contextmenu",(function(t){return t.preventDefault()})),this._geolocateButton=r.create("button","mapboxgl-ctrl-geolocate",this._container),r.create("span","mapboxgl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden",!0),this._geolocateButton.type="button",!1===e){t.warnOnce("Geolocation support is not available so the GeolocateControl will be disabled.");var i=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.title=i,this._geolocateButton.setAttribute("aria-label",i)}else{var o=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.title=o,this._geolocateButton.setAttribute("aria-label",o)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","false"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=r.create("div","mapboxgl-user-location-dot"),this._userLocationDotMarker=new Li(this._dotElement),this._circleElement=r.create("div","mapboxgl-user-location-accuracy-circle"),this._accuracyCircleMarker=new Li({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",this.trigger.bind(this)),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",(function(e){e.geolocateSource||"ACTIVE_LOCK"!==n._watchState||e.originalEvent&&"resize"===e.originalEvent.type||(n._watchState="BACKGROUND",n._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background"),n._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),n.fire(new t.Event("trackuserlocationend")))}))},n.prototype.trigger=function(){if(!this._setup)return t.warnOnce("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new t.Event("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":zi--,Ni=!1,this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this.fire(new t.Event("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new t.Event("trackuserlocationstart"))}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"BACKGROUND":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background");break;case"BACKGROUND_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error")}if("OFF"===this._watchState&&void 0!==this._geolocationWatchID)this._clearWatch();else if(void 0===this._geolocationWatchID){var e;this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),++zi>1?(e={maximumAge:6e5,timeout:0},Ni=!0):(e=this.options.positionOptions,Ni=!1),this._geolocationWatchID=t.window.navigator.geolocation.watchPosition(this._onSuccess,this._onError,e)}}else t.window.navigator.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0},n.prototype._clearWatch=function(){t.window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","false"),this.options.showUserLocation&&this._updateMarker(null)},n}(t.Evented),Ui={maxWidth:100,unit:"metric"},Vi=function(e){this.options=t.extend({},Ui,e),t.bindAll(["_onMove","setUnit"],this)};function qi(t,e,r){var n=r&&r.maxWidth||100,i=t._container.clientHeight/2,o=t.unproject([0,i]),a=t.unproject([n,i]),s=o.distanceTo(a);if(r&&"imperial"===r.unit){var l=3.2808*s;l>5280?Hi(e,n,l/5280,t._getUIString("ScaleControl.Miles")):Hi(e,n,l,t._getUIString("ScaleControl.Feet"))}else r&&"nautical"===r.unit?Hi(e,n,s/1852,t._getUIString("ScaleControl.NauticalMiles")):s>=1e3?Hi(e,n,s/1e3,t._getUIString("ScaleControl.Kilometers")):Hi(e,n,s,t._getUIString("ScaleControl.Meters"))}function Hi(t,e,r,n){var i,o,a,s=(i=r,(o=Math.pow(10,(""+Math.floor(i)).length-1))*(a=(a=i/o)>=10?10:a>=5?5:a>=3?3:a>=2?2:a>=1?1:function(t){var e=Math.pow(10,Math.ceil(-Math.log(t)/Math.LN10));return Math.round(t*e)/e}(a)));t.style.width=e*(s/r)+"px",t.innerHTML=s+"&nbsp;"+n}Vi.prototype.getDefaultPosition=function(){return"bottom-left"},Vi.prototype._onMove=function(){qi(this._map,this._container,this.options)},Vi.prototype.onAdd=function(t){return this._map=t,this._container=r.create("div","mapboxgl-ctrl mapboxgl-ctrl-scale",t.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container},Vi.prototype.onRemove=function(){r.remove(this._container),this._map.off("move",this._onMove),this._map=void 0},Vi.prototype.setUnit=function(t){this.options.unit=t,qi(this._map,this._container,this.options)};var Gi=function(e){this._fullscreen=!1,e&&e.container&&(e.container instanceof t.window.HTMLElement?this._container=e.container:t.warnOnce("Full screen control 'container' must be a DOM element.")),t.bindAll(["_onClickFullscreen","_changeIcon"],this),"onfullscreenchange"in t.window.document?this._fullscreenchange="fullscreenchange":"onmozfullscreenchange"in t.window.document?this._fullscreenchange="mozfullscreenchange":"onwebkitfullscreenchange"in t.window.document?this._fullscreenchange="webkitfullscreenchange":"onmsfullscreenchange"in t.window.document&&(this._fullscreenchange="MSFullscreenChange")};Gi.prototype.onAdd=function(e){return this._map=e,this._container||(this._container=this._map.getContainer()),this._controlContainer=r.create("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._checkFullscreenSupport()?this._setupUI():(this._controlContainer.style.display="none",t.warnOnce("This device does not support fullscreen mode.")),this._controlContainer},Gi.prototype.onRemove=function(){r.remove(this._controlContainer),this._map=null,t.window.document.removeEventListener(this._fullscreenchange,this._changeIcon)},Gi.prototype._checkFullscreenSupport=function(){return!!(t.window.document.fullscreenEnabled||t.window.document.mozFullScreenEnabled||t.window.document.msFullscreenEnabled||t.window.document.webkitFullscreenEnabled)},Gi.prototype._setupUI=function(){var e=this._fullscreenButton=r.create("button","mapboxgl-ctrl-fullscreen",this._controlContainer);r.create("span","mapboxgl-ctrl-icon",e).setAttribute("aria-hidden",!0),e.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),t.window.document.addEventListener(this._fullscreenchange,this._changeIcon)},Gi.prototype._updateTitle=function(){var t=this._getTitle();this._fullscreenButton.setAttribute("aria-label",t),this._fullscreenButton.title=t},Gi.prototype._getTitle=function(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")},Gi.prototype._isFullscreen=function(){return this._fullscreen},Gi.prototype._changeIcon=function(){(t.window.document.fullscreenElement||t.window.document.mozFullScreenElement||t.window.document.webkitFullscreenElement||t.window.document.msFullscreenElement)===this._container!==this._fullscreen&&(this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("mapboxgl-ctrl-shrink"),this._fullscreenButton.classList.toggle("mapboxgl-ctrl-fullscreen"),this._updateTitle())},Gi.prototype._onClickFullscreen=function(){this._isFullscreen()?t.window.document.exitFullscreen?t.window.document.exitFullscreen():t.window.document.mozCancelFullScreen?t.window.document.mozCancelFullScreen():t.window.document.msExitFullscreen?t.window.document.msExitFullscreen():t.window.document.webkitCancelFullScreen&&t.window.document.webkitCancelFullScreen():this._container.requestFullscreen?this._container.requestFullscreen():this._container.mozRequestFullScreen?this._container.mozRequestFullScreen():this._container.msRequestFullscreen?this._container.msRequestFullscreen():this._container.webkitRequestFullscreen&&this._container.webkitRequestFullscreen()};var Zi={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},Wi=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", "),Yi=function(e){function n(r){e.call(this),this.options=t.extend(Object.create(Zi),r),t.bindAll(["_update","_onClose","remove","_onMouseMove","_onMouseUp","_onDrag"],this)}return e&&(n.__proto__=e),(n.prototype=Object.create(e&&e.prototype)).constructor=n,n.prototype.addTo=function(e){return this._map&&this.remove(),this._map=e,this.options.closeOnClick&&this._map.on("click",this._onClose),this.options.closeOnMove&&this._map.on("move",this._onClose),this._map.on("remove",this.remove),this._update(),this._focusFirstElement(),this._trackPointer?(this._map.on("mousemove",this._onMouseMove),this._map.on("mouseup",this._onMouseUp),this._container&&this._container.classList.add("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.add("mapboxgl-track-pointer")):this._map.on("move",this._update),this.fire(new t.Event("open")),this},n.prototype.isOpen=function(){return!!this._map},n.prototype.remove=function(){return this._content&&r.remove(this._content),this._container&&(r.remove(this._container),delete this._container),this._map&&(this._map.off("move",this._update),this._map.off("move",this._onClose),this._map.off("click",this._onClose),this._map.off("remove",this.remove),this._map.off("mousemove",this._onMouseMove),this._map.off("mouseup",this._onMouseUp),this._map.off("drag",this._onDrag),delete this._map),this.fire(new t.Event("close")),this},n.prototype.getLngLat=function(){return this._lngLat},n.prototype.setLngLat=function(e){return this._lngLat=t.LngLat.convert(e),this._pos=null,this._trackPointer=!1,this._update(),this._map&&(this._map.on("move",this._update),this._map.off("mousemove",this._onMouseMove),this._container&&this._container.classList.remove("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.remove("mapboxgl-track-pointer")),this},n.prototype.trackPointer=function(){return this._trackPointer=!0,this._pos=null,this._update(),this._map&&(this._map.off("move",this._update),this._map.on("mousemove",this._onMouseMove),this._map.on("drag",this._onDrag),this._container&&this._container.classList.add("mapboxgl-popup-track-pointer"),this._map._canvasContainer.classList.add("mapboxgl-track-pointer")),this},n.prototype.getElement=function(){return this._container},n.prototype.setText=function(e){return this.setDOMContent(t.window.document.createTextNode(e))},n.prototype.setHTML=function(e){var r,n=t.window.document.createDocumentFragment(),i=t.window.document.createElement("body");for(i.innerHTML=e;r=i.firstChild;)n.appendChild(r);return this.setDOMContent(n)},n.prototype.getMaxWidth=function(){return this._container&&this._container.style.maxWidth},n.prototype.setMaxWidth=function(t){return this.options.maxWidth=t,this._update(),this},n.prototype.setDOMContent=function(t){if(this._content)for(;this._content.hasChildNodes();)this._content.firstChild&&this._content.removeChild(this._content.firstChild);else this._content=r.create("div","mapboxgl-popup-content",this._container);return this._content.appendChild(t),this._createCloseButton(),this._update(),this._focusFirstElement(),this},n.prototype.addClassName=function(t){this._container&&this._container.classList.add(t)},n.prototype.removeClassName=function(t){this._container&&this._container.classList.remove(t)},n.prototype.setOffset=function(t){return this.options.offset=t,this._update(),this},n.prototype.toggleClassName=function(t){if(this._container)return this._container.classList.toggle(t)},n.prototype._createCloseButton=function(){this.options.closeButton&&(this._closeButton=r.create("button","mapboxgl-popup-close-button",this._content),this._closeButton.type="button",this._closeButton.setAttribute("aria-label","Close popup"),this._closeButton.innerHTML="&#215;",this._closeButton.addEventListener("click",this._onClose))},n.prototype._onMouseUp=function(t){this._update(t.point)},n.prototype._onMouseMove=function(t){this._update(t.point)},n.prototype._onDrag=function(t){this._update(t.point)},n.prototype._update=function(e){var n=this;if(this._map&&(this._lngLat||this._trackPointer)&&this._content&&(this._container||(this._container=r.create("div","mapboxgl-popup",this._map.getContainer()),this._tip=r.create("div","mapboxgl-popup-tip",this._container),this._container.appendChild(this._content),this.options.className&&this.options.className.split(" ").forEach((function(t){return n._container.classList.add(t)})),this._trackPointer&&this._container.classList.add("mapboxgl-popup-track-pointer")),this.options.maxWidth&&this._container.style.maxWidth!==this.options.maxWidth&&(this._container.style.maxWidth=this.options.maxWidth),this._map.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=Mi(this._lngLat,this._pos,this._map.transform)),!this._trackPointer||e)){var i=this._pos=this._trackPointer&&e?e:this._map.project(this._lngLat),o=this.options.anchor,a=function e(r){if(r){if("number"==typeof r){var n=Math.round(Math.sqrt(.5*Math.pow(r,2)));return{center:new t.Point(0,0),top:new t.Point(0,r),"top-left":new t.Point(n,n),"top-right":new t.Point(-n,n),bottom:new t.Point(0,-r),"bottom-left":new t.Point(n,-n),"bottom-right":new t.Point(-n,-n),left:new t.Point(r,0),right:new t.Point(-r,0)}}if(r instanceof t.Point||Array.isArray(r)){var i=t.Point.convert(r);return{center:i,top:i,"top-left":i,"top-right":i,bottom:i,"bottom-left":i,"bottom-right":i,left:i,right:i}}return{center:t.Point.convert(r.center||[0,0]),top:t.Point.convert(r.top||[0,0]),"top-left":t.Point.convert(r["top-left"]||[0,0]),"top-right":t.Point.convert(r["top-right"]||[0,0]),bottom:t.Point.convert(r.bottom||[0,0]),"bottom-left":t.Point.convert(r["bottom-left"]||[0,0]),"bottom-right":t.Point.convert(r["bottom-right"]||[0,0]),left:t.Point.convert(r.left||[0,0]),right:t.Point.convert(r.right||[0,0])}}return e(new t.Point(0,0))}(this.options.offset);if(!o){var s,l=this._container.offsetWidth,u=this._container.offsetHeight;s=i.y+a.bottom.y<u?["top"]:i.y>this._map.transform.height-u?["bottom"]:[],i.x<l/2?s.push("left"):i.x>this._map.transform.width-l/2&&s.push("right"),o=0===s.length?"bottom":s.join("-")}var c=i.add(a[o]).round();r.setTransform(this._container,Bi[o]+" translate("+c.x+"px,"+c.y+"px)"),ki(this._container,o,"popup")}},n.prototype._focusFirstElement=function(){if(this.options.focusAfterOpen&&this._container){var t=this._container.querySelector(Wi);t&&t.focus()}},n.prototype._onClose=function(){this.remove()},n}(t.Evented),Xi={version:t.version,supported:e,setRTLTextPlugin:t.setRTLTextPlugin,getRTLTextPluginStatus:t.getRTLTextPluginStatus,Map:Si,NavigationControl:Di,GeolocateControl:ji,AttributionControl:_i,ScaleControl:Vi,FullscreenControl:Gi,Popup:Yi,Marker:Li,Style:qe,LngLat:t.LngLat,LngLatBounds:t.LngLatBounds,Point:t.Point,MercatorCoordinate:t.MercatorCoordinate,Evented:t.Evented,config:t.config,prewarm:function(){zt().acquire(kt)},clearPrewarmedResources:function(){var t=Lt;t&&(t.isPreloaded()&&1===t.numActive()?(t.release(kt),Lt=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},get accessToken(){return t.config.ACCESS_TOKEN},set accessToken(e){t.config.ACCESS_TOKEN=e},get baseApiUrl(){return t.config.API_URL},set baseApiUrl(e){t.config.API_URL=e},get workerCount(){return Ft.workerCount},set workerCount(t){Ft.workerCount=t},get maxParallelImageRequests(){return t.config.MAX_PARALLEL_IMAGE_REQUESTS},set maxParallelImageRequests(e){t.config.MAX_PARALLEL_IMAGE_REQUESTS=e},clearStorage:function(e){t.clearTileCache(e)},workerUrl:""};return Xi})),r}()},function(t,e){var r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(r){var n=new Uint8Array(16);t.exports=function(){return r(n),n}}else{var i=new Array(16);t.exports=function(){for(var t,e=0;e<16;e++)0==(3&e)&&(t=4294967296*Math.random()),i[e]=t>>>((3&e)<<3)&255;return i}}},function(t,e){for(var r=[],n=0;n<256;++n)r[n]=(n+256).toString(16).substr(1);t.exports=function(t,e){var n=e||0,i=r;return[i[t[n++]],i[t[n++]],i[t[n++]],i[t[n++]],"-",i[t[n++]],i[t[n++]],"-",i[t[n++]],i[t[n++]],"-",i[t[n++]],i[t[n++]],"-",i[t[n++]],i[t[n++]],i[t[n++]],i[t[n++]],i[t[n++]],i[t[n++]]].join("")}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.COMPARE_TYPES=e.TOOLTIP_FORMATS=e.TOOLTIP_KEY=e.TOOLTIP_FORMAT_TYPES=void 0;var n={NONE:"none",DATE:"date",DATE_TIME:"date_time",DECIMAL:"decimal",PERCENTAGE:"percentage",BOOLEAN:"boolean"};e.TOOLTIP_FORMAT_TYPES=n;e.TOOLTIP_KEY="format";var i={NONE:{id:"NONE",label:"None",format:null,type:n.NONE},DECIMAL_SHORT:{id:"DECIMAL_SHORT",label:"12345 → 10k",format:".1s",type:n.DECIMAL},DECIMAL_COMMA:{id:"DECIMAL_COMMA",label:"12345 → 12,345",format:",",type:n.DECIMAL},DECIMAL_SHORT_COMMA:{id:"DECIMAL_SHORT_COMMA",label:"12345 → 12.3k",format:".3~s",type:n.DECIMAL},DECIMAL_PERCENT_FULL_1:{id:"DECIMAL_PERCENT_FULL_1",label:".01 → 1.0%",format:".1%",type:n.DECIMAL},DECIMAL_PERCENT_FULL_2:{id:"DECIMAL_PERCENT_FULL_2",label:".01 → 1.00%",format:".2%",type:n.DECIMAL},DECIMAL_PRECENT_REGULAR:{id:"DECIMAL_PRECENT_REGULAR",label:"12.345 → 12.35%",format:"~%",type:n.PERCENTAGE},DECIMAL_DECIMAL_FIXED_2:{id:"DECIMAL_DECIMAL_FIXED_2",label:"1.2345 → 1.23",format:".2~f",type:n.DECIMAL},DECIMAL_DECIMAL_FIXED_3:{id:"DECIMAL_DECIMAL_FIXED_3",label:"1.2345 → 1.234",format:".3~f",type:n.DECIMAL},DECIMAL_INT:{id:"DECIMAL_INT",label:"12345 → 12350",format:".4~r",type:n.DECIMAL},DECIMAL_THREE:{id:"DECIMAL_THREE",label:"12345.4321 → 12,345.432",format:",.3~f",type:n.DECIMAL},DECIMAL_DELTA:{id:"DECIMAL_DELTA",label:"12345.4321 → +12,345.432",format:"+,.3f",type:n.DECIMAL},DECIMAL_CURRENCY:{id:"DECIMAL_CURRENCY",label:"12345.4321 → $12,345.43",format:"$,.2f",type:n.DECIMAL},DATE_L:{id:"DATE_L",label:"",format:"L",type:n.DATE},DATE_LL:{id:"DATE_LL",label:"",format:"LL",type:n.DATE},DATE_dddd_LL:{id:"DATE_dddd_LL",label:"",format:"dddd LL",type:n.DATE},DATE_ddd_LL:{id:"DATE_ddd_LL",label:"",format:"ddd LL",type:n.DATE},DATE_TIME_L_LT:{id:"DATE_TIME_L_LT",label:"",format:"L LT",type:n.DATE_TIME},DATE_TIME_L_LTS:{id:"DATE_TIME_L_LTS",label:"",format:"L LTS",type:n.DATE_TIME},DATE_TIME_LLL:{id:"DATE_TIME_LLL",label:"",format:"LLL",type:n.DATE_TIME},DATE_TIME_LL_LTS:{id:"DATE_TIME_LL_LTS",label:"",format:"LL LTS",type:n.DATE_TIME},DATE_TIME_ddd_LLL:{id:"DATE_TIME_ddd_LLL",label:"",format:"ddd LLL",type:n.DATE_TIME},DATE_TIME_LTS:{id:"DATE_TIME_LTS",label:"",format:"LTS",type:n.DATE_TIME},BOOLEAN_NUM:{id:"BOOLEAN_NUM",label:"0 | 1",format:"01",type:n.BOOLEAN},BOOLEAN_Y_N:{id:"BOOLEAN_Y_N",label:"yes | no",format:"yn",type:n.BOOLEAN}};e.TOOLTIP_FORMATS=i;e.COMPARE_TYPES={ABSOLUTE:"absolute",RELATIVE:"relative"}},function(t,e,r){"use strict";(function(t){var r=function(){if("undefined"!=typeof Map)return Map;function t(t,e){var r=-1;return t.some((function(t,n){return t[0]===e&&(r=n,!0)})),r}return function(){function e(){this.__entries__=[]}return Object.defineProperty(e.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),e.prototype.get=function(e){var r=t(this.__entries__,e),n=this.__entries__[r];return n&&n[1]},e.prototype.set=function(e,r){var n=t(this.__entries__,e);~n?this.__entries__[n][1]=r:this.__entries__.push([e,r])},e.prototype.delete=function(e){var r=this.__entries__,n=t(r,e);~n&&r.splice(n,1)},e.prototype.has=function(e){return!!~t(this.__entries__,e)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,e){void 0===e&&(e=null);for(var r=0,n=this.__entries__;r<n.length;r++){var i=n[r];t.call(e,i[1],i[0])}},e}()}(),n="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,i=void 0!==t&&t.Math===Math?t:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),o="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(i):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)};var a=["top","right","bottom","left","width","height","size","weight"],s="undefined"!=typeof MutationObserver,l=function(){function t(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(t,e){var r=!1,n=!1,i=0;function a(){r&&(r=!1,t()),n&&l()}function s(){o(a)}function l(){var t=Date.now();if(r){if(t-i<2)return;n=!0}else r=!0,n=!1,setTimeout(s,e);i=t}return l}(this.refresh.bind(this),20)}return t.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},t.prototype.removeObserver=function(t){var e=this.observers_,r=e.indexOf(t);~r&&e.splice(r,1),!e.length&&this.connected_&&this.disconnect_()},t.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},t.prototype.updateObservers_=function(){var t=this.observers_.filter((function(t){return t.gatherActive(),t.hasActive()}));return t.forEach((function(t){return t.broadcastActive()})),t.length>0},t.prototype.connect_=function(){n&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),s?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},t.prototype.disconnect_=function(){n&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},t.prototype.onTransitionEnd_=function(t){var e=t.propertyName,r=void 0===e?"":e;a.some((function(t){return!!~r.indexOf(t)}))&&this.refresh()},t.getInstance=function(){return this.instance_||(this.instance_=new t),this.instance_},t.instance_=null,t}(),u=function(t,e){for(var r=0,n=Object.keys(e);r<n.length;r++){var i=n[r];Object.defineProperty(t,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return t},c=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView||i},p=y(0,0,0,0);function h(t){return parseFloat(t)||0}function f(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];return e.reduce((function(e,r){return e+h(t["border-"+r+"-width"])}),0)}function d(t){var e=t.clientWidth,r=t.clientHeight;if(!e&&!r)return p;var n=c(t).getComputedStyle(t),i=function(t){for(var e={},r=0,n=["top","right","bottom","left"];r<n.length;r++){var i=n[r],o=t["padding-"+i];e[i]=h(o)}return e}(n),o=i.left+i.right,a=i.top+i.bottom,s=h(n.width),l=h(n.height);if("border-box"===n.boxSizing&&(Math.round(s+o)!==e&&(s-=f(n,"left","right")+o),Math.round(l+a)!==r&&(l-=f(n,"top","bottom")+a)),!function(t){return t===c(t).document.documentElement}(t)){var u=Math.round(s+o)-e,d=Math.round(l+a)-r;1!==Math.abs(u)&&(s-=u),1!==Math.abs(d)&&(l-=d)}return y(i.left,i.top,s,l)}var m="undefined"!=typeof SVGGraphicsElement?function(t){return t instanceof c(t).SVGGraphicsElement}:function(t){return t instanceof c(t).SVGElement&&"function"==typeof t.getBBox};function g(t){return n?m(t)?function(t){var e=t.getBBox();return y(0,0,e.width,e.height)}(t):d(t):p}function y(t,e,r,n){return{x:t,y:e,width:r,height:n}}var v=function(){function t(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=y(0,0,0,0),this.target=t}return t.prototype.isActive=function(){var t=g(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},t.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t},t}(),_=function(t,e){var r,n,i,o,a,s,l,c=(n=(r=e).x,i=r.y,o=r.width,a=r.height,s="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,l=Object.create(s.prototype),u(l,{x:n,y:i,width:o,height:a,top:i,right:n+o,bottom:a+i,left:n}),l);u(this,{target:t,contentRect:c})},b=function(){function t(t,e,n){if(this.activeObservations_=[],this.observations_=new r,"function"!=typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=n}return t.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof c(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new v(t)),this.controller_.addObserver(this),this.controller_.refresh())}},t.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof c(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)&&(e.delete(t),e.size||this.controller_.removeObserver(this))}},t.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},t.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},t.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new _(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},t.prototype.clearActive=function(){this.activeObservations_.splice(0)},t.prototype.hasActive=function(){return this.activeObservations_.length>0},t}(),x="undefined"!=typeof WeakMap?new WeakMap:new r,w=function t(e){if(!(this instanceof t))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var r=l.getInstance(),n=new b(e,r,this);x.set(this,n)};["observe","unobserve","disconnect"].forEach((function(t){w.prototype[t]=function(){var e;return(e=x.get(this))[t].apply(e,arguments)}}));var E=void 0!==i.ResizeObserver?i.ResizeObserver:w;e.a=E}).call(this,r(14))},function(t,e){function r(e){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(t.exports=r=function(t){return typeof t},t.exports.default=t.exports,t.exports.__esModule=!0):(t.exports=r=function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.default=t.exports,t.exports.__esModule=!0),r(e)}t.exports=r,t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=r(41);Object.keys(n).forEach((function(t){"default"!==t&&"__esModule"!==t&&(t in e&&e[t]===n[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return n[t]}}))}));var i=r(68);Object.keys(i).forEach((function(t){"default"!==t&&"__esModule"!==t&&(t in e&&e[t]===i[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return i[t]}}))}))},,,,function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),e.inputColor=e.inputBorderActiveColorLT=e.inputBorderActiveColor=e.inputBorderHoverColorLT=e.inputBorderHoverColor=e.inputBorderColor=e.inputBgdActiveLT=e.inputBgdActive=e.inputBgdHover=e.inputBgd=e.inputFontWeight=e.inputFontSizeSmall=e.inputFontSize=e.inputPaddingTiny=e.inputPaddingSmall=e.inputPadding=e.inputBoxHeightTiny=e.inputBoxHeightSmall=e.inputBoxHeight=e.selectionBtnBorderActColor=e.selectionBtnBorderColor=e.selectionBtnBorder=e.selectionBtnBgdHover=e.selectionBtnActColor=e.selectionBtnColor=e.selectionBtnActBgd=e.selectionBtnBgd=e.floatingBtnActColor=e.floatingBtnColor=e.floatingBtnBorderHover=e.floatingBtnBorder=e.floatingBtnBgdHover=e.floatingBtnActBgd=e.floatingBtnBgd=e.negativeBtnActColor=e.negativeBtnColor=e.negativeBtnBorder=e.negativeBtnBgdHover=e.negativeBtnActBgd=e.negativeBtnBgd=e.linkBtnBorder=e.linkBtnActBgdHover=e.linkBtnActColor=e.linkBtnColor=e.linkBtnActBgd=e.linkBtnBgd=e.ctaBtnActColor=e.ctaBtnColor=e.ctaBtnActBgd=e.ctaBtnBgdHover=e.ctaBtnBgd=e.secondaryBtnBorder=e.secondaryBtnBgdHover=e.secondaryBtnActColor=e.secondaryBtnColor=e.secondaryBtnActBgd=e.secondaryBtnBgd=e.primaryBtnBorder=e.primaryBtnFontSizeLarge=e.primaryBtnFontSizeSmall=e.primaryBtnFontSizeDefault=e.primaryBtnRadius=e.primaryBtnBgdHover=e.primaryBtnActColor=e.primaryBtnColor=e.primaryBtnActBgd=e.primaryBtnBgd=e.btnFontFamily=e.logoColor=e.errorColor=e.activeColorHover=e.activeColorLT=e.activeColor=e.textColorHlLT=e.textColorHl=e.titleTextColor=e.panelTabWidth=e.panelToggleBorderColor=e.subtextColorActive=e.subtextColorLT=e.subtextColor=e.titleColorLT=e.dataTableTextColor=e.textColorLT=e.textColor=e.labelColorLT=e.labelHoverColor=e.labelColor=e.lineHeight=e.fontSize=e.fontWeight=e.fontFamily=e.borderColorLT=e.borderColor=e.borderRadius=e.boxSizing=e.boxShadow=e.transitionSlow=e.transitionFast=e.transition=void 0,e.panelBorderRadius=e.panelBoxShadow=e.layerPanelHeaderHeight=e.panelHeaderHeight=e.panelHeaderIconHover=e.panelHeaderIconActive=e.panelHeaderIcon=e.chickletBgdLT=e.chickletBgd=e.panelHeaderBorderRadius=e.panelBackgroundHover=e.panelContentBackground=e.panelBackground=e.sidePanelTitleLineHeight=e.sidePanelTitleFontsize=e.sideBarCloseBtnBgdHover=e.sideBarCloseBtnColor=e.sideBarCloseBtnBgd=e.sidePanelScrollBarHeight=e.sidePanelScrollBarWidth=e.sidePanelBg=e.sidePanelBorderColor=e.sidePanelBorder=e.sidePanelInnerPadding=e.layerConfigGroupPaddingLeft=e.layerConfigGroupMarginBottom=e.sidePanelHeaderBorder=e.sidePanelHeaderBg=e.radioButtonBgdColor=e.radioButtonRadius=e.radioBorderColor=e.radioBorderRadius=e.radioRadius=e.checkboxBoxBgdChecked=e.checkboxBoxBgd=e.checkboxBorderColorLT=e.checkboxBorderRadius=e.checkboxBorderColor=e.checkboxMargin=e.checkboxHeight=e.checkboxWidth=e.secondarySwitchBtnBgd=e.secondarySwitchTrackBgd=e.switchBtnHeight=e.switchBtnWidth=e.switchBtnBorderRadius=e.switchBtnBoxShadow=e.switchBtnBgdActive=e.switchBtnBgd=e.switchTrackBorderRadius=e.switchTrackBgdActive=e.switchTrackBgd=e.switchLabelMargin=e.switchHeight=e.switchWidth=e.dropdownWapperMargin=e.dropdownWrapperZ=e.dropdownListLineHeight=e.dropdownListBorderTopLT=e.dropdownListBorderTop=e.dropdownListBgdLT=e.toolbarItemBorderRaddius=e.toolbarItemBorderHover=e.toolbarItemIconHover=e.toolbarItemBgdHover=e.dropdownListBgd=e.dropdownListShadow=e.dropdownListHighlightBgLT=e.dropdownListHighlightBg=e.panelTabColor=e.selectBorder=e.selectBorderRadius=e.selectBorderColorLT=e.selectBorderColor=e.selectBackgroundHoverLT=e.selectBackgroundLT=e.selectBackgroundHover=e.selectBackground=e.selectColorPlaceHolderLT=e.selectColorPlaceHolder=e.selectFontWeightBold=e.selectFontWeight=e.selectFontSize=e.selectActiveBorderColor=e.selectColorLT=e.selectColor=e.dropdownSelectHeight=e.secondaryInputBorderActiveColor=e.secondaryInputBorderColor=e.secondaryInputColor=e.secondaryInputBgdActive=e.secondaryInputBgdHover=e.secondaryInputBgd=e.inputBoxShadowActiveLT=e.inputBoxShadowActive=e.inputBoxShadow=e.inputPlaceholderFontWeight=e.inputPlaceholderColorLT=e.inputPlaceholderColor=e.inputBorderRadius=void 0,e.styledConfigGroupHeaderBorder=e.layerConfigGroupLabelLabelFontSize=e.layerConfigGroupLabelLabelMargin=e.layerConfigGroupColor=e.layerConfigGroupLabelPadding=e.layerConfigGroupLabelMargin=e.layerConfigGroupLabelBorderLeft=e.textTruncate=e.fieldTokenRightMargin=e.actionPanelHeight=e.actionPanelWidth=e.notificationPanelItemHeight=e.notificationPanelItemWidth=e.notificationPanelWidth=e.notificationColors=e.rangePlotContainerHLargePalm=e.rangePlotContainerHLarge=e.rangePlotHLargePalm=e.rangePlotHLarge=e.rangePlotContainerH=e.rangePlotH=e.rangePlotMarginLarge=e.rangePlotMargin=e.timeTitleFontSize=e.axisFontColor=e.axisFontSize=e.histogramFillOutRange=e.histogramFillInRange=e.rangeBrushBgd=e.geocoderInputHeight=e.geocoderRight=e.geocoderTop=e.geocoderWidth=e.sliderMarginBottom=e.sliderMarginTop=e.sliderMarginTopIsTime=e.sliderInputPadding=e.sliderInputFontSize=e.sliderInputWidth=e.sliderInputHeight=e.sliderHandleShadow=e.sliderHandleAfterContent=e.sliderHandleHoverColor=e.sliderBorderRadius=e.sliderInactiveBorderColor=e.sliderHandleTextColor=e.sliderHandleColor=e.sliderHandleWidth=e.sliderHandleHeight=e.sliderBarHeight=e.sliderBarRadius=e.sliderBarHoverColor=e.sliderBarBgd=e.sliderBarColor=e.modalDialogColor=e.modalDialogBgd=e.modalDropdownBackground=e.modalButtonZ=e.modalTitleZ=e.modalFooterZ=e.modalContentZ=e.modalOverlayBgd=e.modalOverLayZ=e.modalPortableLateralPadding=e.modalLateralPadding=e.modalPadding=e.modalImagePlaceHolder=e.modalFooterBgd=e.modalTitleFontSizeSmaller=e.modalTitleFontSize=e.modalTitleColor=e.bottomWidgetBgd=e.bottomWidgetPaddingLeft=e.bottomWidgetPaddingBottom=e.bottomWidgetPaddingRight=e.bottomWidgetPaddingTop=e.bottomPanelGapPalm=e.bottomPanelGap=e.bottomInnerPdVert=e.bottomInnerPdSide=e.sidepanelDividerHeight=e.sidepanelDividerMargin=e.sidepanelDividerBorder=e.layerPanelToggleOptionColorActive=e.layerPanelToggleOptionColor=e.layerTypeIconSizeSM=e.layerTypeIconPdL=e.layerTypeIconSizeL=e.tooltipFontSize=e.tooltipBoxShadow=e.tooltipColor=e.tooltipBg=e.mapPanelHeaderBackgroundColor=e.mapPanelBackgroundColor=e.panelBorderLT=e.panelBorder=e.panelBorderColor=e.panelToggleBottomPadding=e.panelToggleMarginRight=e.panelBackgroundLT=void 0,e.themeBS=e.themeLT=e.theme=e.modalScrollBar=e.breakPoints=e.layerConfiguratorPadding=e.layerConfiguratorMargin=e.layerConfiguratorBorderColor=e.layerConfiguratorBorder=void 0;var i,o,a,s,l,u,c,p,h,f,d,m,g,y,v,_,b,x,w,E,T,A,C,S,P,I,D,O,M,B,k,F,L,R,z=n(r(13)),N=n(r(22)),j=r(23),U=r(42);function V(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function q(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?V(Object(r),!0).forEach((function(e){(0,z.default)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):V(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}e.transition="all .4s ease";e.transitionFast="all .2s ease";e.transitionSlow="all .8s ease";var H="0 1px 2px 0 rgba(0,0,0,0.10)";e.boxShadow=H;e.boxSizing="border-box";e.borderRadius="1px";e.borderColor="#3A414C";e.borderColorLT="#F1F1F1";var G="ff-clan-web-pro, 'Helvetica Neue', Helvetica, sans-serif";e.fontFamily=G;e.fontWeight=400;e.fontSize="0.875em";e.lineHeight=1.71429;e.labelColor="#6A7485";e.labelHoverColor="#C6C6C6";e.labelColorLT="#6A7485";e.textColor="#A0A7B4";e.textColorLT="#3A414C";e.dataTableTextColor="#3A414C";e.titleColorLT="#29323C";e.subtextColor="#6A7485";e.subtextColorLT="#A0A7B4";e.subtextColorActive="#FFFFFF";e.panelToggleBorderColor="#FFFFFF";e.panelTabWidth="30px";e.titleTextColor="#FFFFFF";e.textColorHl="#F0F0F0";e.textColorHlLT="#000000";e.activeColor="#1FBAD6";e.activeColorLT="#2473BD";e.activeColorHover="#108188";e.errorColor="#F9042C";e.logoColor="#1FBAD6";var Z=G;e.btnFontFamily=Z;e.primaryBtnBgd="#0F9668";e.primaryBtnActBgd="#13B17B";e.primaryBtnColor="#FFFFFF";e.primaryBtnActColor="#FFFFFF";e.primaryBtnBgdHover="#13B17B";e.primaryBtnRadius="2px";e.primaryBtnFontSizeDefault="11px";e.primaryBtnFontSizeSmall="10px";e.primaryBtnFontSizeLarge="14px";e.primaryBtnBorder="0";e.secondaryBtnBgd="#6A7485";e.secondaryBtnActBgd="#A0A7B4";e.secondaryBtnColor="#FFFFFF";e.secondaryBtnActColor="#FFFFFF";e.secondaryBtnBgdHover="#A0A7B4";e.secondaryBtnBorder="0";e.ctaBtnBgd="#0F9668";e.ctaBtnBgdHover="#13B17B";e.ctaBtnActBgd="#13B17B";e.ctaBtnColor="#FFFFFF";e.ctaBtnActColor="#FFFFFF";e.linkBtnBgd="transparent";e.linkBtnActBgd="transparent";e.linkBtnColor="#A0A7B4";e.linkBtnActColor="#F1F1F1";e.linkBtnActBgdHover="transparent";e.linkBtnBorder="0";e.negativeBtnBgd="#F9042C";e.negativeBtnActBgd="#FF193E";e.negativeBtnBgdHover="#FF193E";e.negativeBtnBorder="0";e.negativeBtnColor="#FFFFFF";e.negativeBtnActColor="#FFFFFF";e.floatingBtnBgd="#29323C";e.floatingBtnActBgd="#3A4552";e.floatingBtnBgdHover="#3A4552";e.floatingBtnBorder="0";e.floatingBtnBorderHover="0";e.floatingBtnColor="#6A7485";e.floatingBtnActColor="#FFFFFF";e.selectionBtnBgd="transparent";e.selectionBtnActBgd="transparent";e.selectionBtnColor="#D3D8E0";e.selectionBtnActColor="#0F9668";e.selectionBtnBgdHover="#0F9668";e.selectionBtnBorder="1";e.selectionBtnBorderColor="#D3D8E0";e.selectionBtnBorderActColor="#0F9668";e.inputBoxHeight="34px";e.inputBoxHeightSmall="24px";e.inputBoxHeightTiny="18px";e.inputPadding="4px 10px";e.inputPaddingSmall="4px 6px";e.inputPaddingTiny="2px 4px";e.inputFontSize="11px";e.inputFontSizeSmall="10px";e.inputFontWeight=500;e.inputBgd="#29323C";e.inputBgdHover="#3A414C";e.inputBgdActive="#3A414C";e.inputBgdActiveLT="#FFFFFF";e.inputBorderColor="#29323C";e.inputBorderHoverColor="#3A414C";e.inputBorderHoverColorLT="#6A7485";e.inputBorderActiveColor="#3A414C";e.inputBorderActiveColorLT="#3A414C";e.inputColor="#A0A7B4";e.inputBorderRadius="1px";e.inputPlaceholderColor="#6A7485";e.inputPlaceholderColorLT="#A0A7B4";e.inputPlaceholderFontWeight=400;e.inputBoxShadow="none";e.inputBoxShadowActive="none";e.inputBoxShadowActiveLT="none";e.secondaryInputBgd="#242730";e.secondaryInputBgdHover="#3A414C";e.secondaryInputBgdActive="#3A414C";e.secondaryInputColor="#A0A7B4";e.secondaryInputBorderColor="#242730";e.secondaryInputBorderActiveColor="#D3D8E0";e.dropdownSelectHeight=30;e.selectColor="#A0A7B4";e.selectColorLT="#29323C";e.selectActiveBorderColor="#D3D8E0";e.selectFontSize="11px";e.selectFontWeight="400";e.selectFontWeightBold="500";e.selectColorPlaceHolder="#6A7485";e.selectColorPlaceHolderLT="#29323C";e.selectBackground="#29323C";e.selectBackgroundHover="#3A414C";e.selectBackgroundLT="#FFFFFF";e.selectBackgroundHoverLT="#F8F8F9";e.selectBorderColor="#D3D8E0";e.selectBorderColorLT="#D3D8E0";e.selectBorderRadius="1px";e.selectBorder=0;e.panelTabColor="#6A7485";e.dropdownListHighlightBg="#6A7485";e.dropdownListHighlightBgLT="#F8F8F9";e.dropdownListShadow="0 6px 12px 0 rgba(0,0,0,0.16)";e.dropdownListBgd="#29323C";e.toolbarItemBgdHover="#3A4552";e.toolbarItemIconHover="#F0F0F0";e.toolbarItemBorderHover="transparent";e.toolbarItemBorderRaddius="0px";e.dropdownListBgdLT="#FFFFFF";e.dropdownListBorderTop="#242730";e.dropdownListBorderTopLT="#D3D8E0";e.dropdownListLineHeight=20;e.dropdownWrapperZ=100;e.dropdownWapperMargin=4;e.switchWidth=24;e.switchHeight=12;e.switchLabelMargin=12;e.switchTrackBgd="#29323C";e.switchTrackBgdActive="#1FBAD6";e.switchTrackBorderRadius="1px";e.switchBtnBgd="#6A7485";e.switchBtnBgdActive="#D3D8E0";e.switchBtnBoxShadow="0 2px 4px 0 rgba(0,0,0,0.40)";e.switchBtnBorderRadius="0";e.switchBtnWidth=12;e.switchBtnHeight=12;e.secondarySwitchTrackBgd="#242730";e.secondarySwitchBtnBgd="#3A414C";e.checkboxWidth=16;e.checkboxHeight=16;e.checkboxMargin=12;e.checkboxBorderColor="#D3D8E0";e.checkboxBorderRadius="2px";e.checkboxBorderColorLT="#D3D8E0";e.checkboxBoxBgd="white";e.checkboxBoxBgdChecked="#0F9668";e.radioRadius=8;e.radioBorderRadius=100;e.radioBorderColor="transparent";e.radioButtonRadius=4;e.radioButtonBgdColor="#D3D8E0";e.sidePanelHeaderBg="#29323C";e.sidePanelHeaderBorder="transparent";e.layerConfigGroupMarginBottom=12;e.layerConfigGroupPaddingLeft=18;e.sidePanelInnerPadding=16;e.sidePanelBorder=0;e.sidePanelBorderColor="transparent";e.sidePanelBg="#242730";e.sidePanelScrollBarWidth=10;e.sidePanelScrollBarHeight=10;e.sideBarCloseBtnBgd="#6A7485";e.sideBarCloseBtnColor="#29323C";e.sideBarCloseBtnBgdHover="#A0A7B4";e.sidePanelTitleFontsize="20px";e.sidePanelTitleLineHeight="1.71429";e.panelBackground="#29323C";e.panelContentBackground="#292E36";e.panelBackgroundHover="#3A4552";e.panelHeaderBorderRadius="0px";e.chickletBgd="#3A4552";e.chickletBgdLT="#D3D8E0";e.panelHeaderIcon="#6A7485";e.panelHeaderIconActive="#A0A7B4";e.panelHeaderIconHover="#F0F0F0";e.panelHeaderHeight=48;e.layerPanelHeaderHeight=48;e.panelBoxShadow="0 6px 12px 0 rgba(0,0,0,0.16)";e.panelBorderRadius="2px";e.panelBackgroundLT="#F8F8F9";e.panelToggleMarginRight=12;e.panelToggleBottomPadding=6;e.panelBorderColor="#3A414C";var W="1px solid ".concat("#3A414C");e.panelBorder=W;var Y="1px solid ".concat("#F1F1F1");e.panelBorderLT=Y;e.mapPanelBackgroundColor="#242730";e.mapPanelHeaderBackgroundColor="#29323C";e.tooltipBg="#3A414C";e.tooltipColor="#F0F0F0";e.tooltipBoxShadow="0 1px 2px 0 rgba(0,0,0,0.10)";e.tooltipFontSize="10px";e.layerTypeIconSizeL=50;e.layerTypeIconPdL=12;e.layerTypeIconSizeSM=28;e.layerPanelToggleOptionColor="#6A7485";e.layerPanelToggleOptionColorActive="#F0F0F0";e.sidepanelDividerBorder="1px";e.sidepanelDividerMargin=12;e.sidepanelDividerHeight=12;e.bottomInnerPdSide=32;e.bottomInnerPdVert=6;e.bottomPanelGap=20;e.bottomPanelGapPalm=20;e.bottomWidgetPaddingTop=20;e.bottomWidgetPaddingRight=20;e.bottomWidgetPaddingBottom=30;e.bottomWidgetPaddingLeft=20;e.bottomWidgetBgd="#29323C";e.modalTitleColor="#3A414C";e.modalTitleFontSize="24px";e.modalTitleFontSizeSmaller="18px";e.modalFooterBgd="#F8F8F9";e.modalImagePlaceHolder="#DDDFE3";e.modalPadding="10px 0";e.modalLateralPadding="72px";e.modalPortableLateralPadding="36px";e.modalOverLayZ=1001;e.modalOverlayBgd="rgba(0, 0, 0, 0.5)";e.modalContentZ=10002;e.modalFooterZ=10001;e.modalTitleZ=10003;e.modalButtonZ=10005;e.modalDropdownBackground="#FFFFFF";e.modalDialogBgd="#3A414C";e.modalDialogColor="#F0F0F0";e.sliderBarColor="#6A7485";e.sliderBarBgd="#3A414C";e.sliderBarHoverColor="#D3D8E0";e.sliderBarRadius="1px";e.sliderBarHeight=4;e.sliderHandleHeight=12;e.sliderHandleWidth=12;e.sliderHandleColor="#D3D8E0";e.sliderHandleTextColor="#D3D8E0";e.sliderInactiveBorderColor="#D3D8E0";e.sliderBorderRadius="0";e.sliderHandleHoverColor="#FFFFFF";e.sliderHandleAfterContent="";e.sliderHandleShadow="0 2px 4px 0 rgba(0,0,0,0.40)";e.sliderInputHeight=24;e.sliderInputWidth=56;e.sliderInputFontSize="10px";e.sliderInputPadding="4px 6px";e.sliderMarginTopIsTime=-12;e.sliderMarginTop=12;e.sliderMarginBottom=12;e.geocoderWidth=360;e.geocoderTop=20;e.geocoderRight=12;e.geocoderInputHeight=36;e.rangeBrushBgd="#3A414C";e.histogramFillInRange="#1FBAD6";e.histogramFillOutRange="#6A7485";e.axisFontSize="10px";e.axisFontColor="#A0A7B4";e.timeTitleFontSize="10px";var X={top:12,bottom:0,left:0,right:0};e.rangePlotMargin=X;var K={top:18,bottom:0,left:0,right:0};e.rangePlotMarginLarge=K;e.rangePlotH=62;e.rangePlotContainerH=78;e.rangePlotHLarge=102;e.rangePlotHLargePalm=102;e.rangePlotContainerHLarge=120;e.rangePlotContainerHLargePalm=120;var J={info:"#276ef1",error:"#f25138",success:"#47b275",warning:"#ffc043"};e.notificationColors=J;e.notificationPanelWidth=240;e.notificationPanelItemWidth=180;e.notificationPanelItemHeight=60;e.actionPanelWidth=110;e.actionPanelHeight=32;e.fieldTokenRightMargin=4;var Q={maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",wordWrap:"normal"};e.textTruncate=Q;e.layerConfigGroupLabelBorderLeft="2px";e.layerConfigGroupLabelMargin="-12px";e.layerConfigGroupLabelPadding="10px";e.layerConfigGroupColor="transparent";e.layerConfigGroupLabelLabelMargin="0";e.layerConfigGroupLabelLabelFontSize="12px";e.styledConfigGroupHeaderBorder="2px";e.layerConfiguratorBorder="0";e.layerConfiguratorBorderColor="";e.layerConfiguratorMargin="12px";e.layerConfiguratorPadding="12px 0 8px 0";var $={palm:588,desk:768};e.breakPoints=$;var tt=(0,j.css)(i||(i=(0,N.default)(["\n ::placeholder {\n color: ",";\n font-weight: ",";\n }\n\n /* Disable Arrows on Number Inputs */\n ::-webkit-inner-spin-button,\n ::-webkit-outer-spin-button {\n -webkit-appearance: none;\n margin: 0;\n }\n\n align-items: center;\n background-color: ",";\n border: 1px solid\n ",";\n border-radius: 2px;\n caret-color: ",";\n color: ",";\n display: flex;\n font-size: ",";\n font-weight: ",";\n font-family: ",";\n height: ",";\n justify-content: space-between;\n outline: none;\n overflow: hidden;\n padding: ",";\n text-overflow: ellipsis;\n transition: ",";\n white-space: nowrap;\n width: 100%;\n word-wrap: normal;\n pointer-events: ",";\n opacity: ",";\n box-shadow: ",";\n\n :hover {\n cursor: ",";\n background-color: ",";\n border-color: ",";\n }\n\n :active,\n :focus,\n &.focus,\n &.active {\n background-color: ",";\n border-color: ",";\n box-shadow: ",";\n }\n"])),(function(t){return t.theme.inputPlaceholderColor}),(function(t){return t.theme.inputPlaceholderFontWeight}),(function(t){return t.theme.inputBgd}),(function(t){return t.active?t.theme.inputBorderActiveColor:t.error?t.theme.errorColor:t.theme.inputBgd}),(function(t){return t.theme.inputBorderActiveColor}),(function(t){return t.theme.inputColor}),(function(t){return["small","tiny"].includes(t.size)?t.theme.inputFontSizeSmall:t.theme.inputFontSize}),(function(t){return t.theme.inputFontWeight}),(function(t){return t.theme.fontFamily}),(function(t){return"small"===t.size?t.theme.inputBoxHeightSmall:"tiny"===t.size?t.theme.inputBoxHeightTiny:t.theme.inputBoxHeight}),(function(t){return"small"===t.size?t.theme.inputPaddingSmall:"tiny"===t.size?t.theme.inputPaddingTiny:t.theme.inputPadding}),(function(t){return t.theme.transition}),(function(t){return t.disabled?"none":"all"}),(function(t){return t.disabled?.5:1}),(function(t){return t.theme.inputBoxShadow}),(function(t){return"number"===t.type||"text"===t.type?"text":"pointer"}),(function(t){return t.active?t.theme.inputBgdActive:t.theme.inputBgdHover}),(function(t){return t.active?t.theme.inputBorderActiveColor:t.theme.inputBorderHoverColor}),(function(t){return t.theme.inputBgdActive}),(function(t){return t.theme.inputBorderActiveColor}),(function(t){return t.theme.inputBoxShadowActive})),et=(0,j.css)(o||(o=(0,N.default)(["\n ::placeholder {\n color: ",";\n font-weight: 400;\n }\n ","\n\n background-color: ",";\n border: 1px solid\n ",";\n color: ",";\n caret-color: ",";\n\n :hover {\n background-color: ",";\n cursor: ",";\n border-color: ",";\n }\n\n :active,\n :focus,\n &.focus,\n &.active {\n background-color: ",";\n border-color: ",";\n box-shadow: ",";\n }\n"])),(function(t){return t.theme.inputPlaceholderColorLT}),tt,(function(t){return t.theme.selectBackgroundLT}),(function(t){return t.active?t.theme.selectActiveBorderColor:t.error?t.theme.errorColor:t.theme.selectBorderColorLT}),(function(t){return t.theme.selectColorLT}),(function(t){return t.theme.inputBorderActiveColorLT}),(function(t){return t.theme.inputBgdActiveLT}),(function(t){return["number","text"].includes(t.type)?"text":"pointer"}),(function(t){return t.active?t.theme.inputBorderActiveColorLT:t.theme.inputBorderHoverColorLT}),(function(t){return t.theme.inputBgdActiveLT}),(function(t){return t.theme.inputBorderActiveColorLT}),(function(t){return t.theme.inputBoxShadowActiveLT})),rt=(0,j.css)(a||(a=(0,N.default)(["\n ","\n color: ",";\n background-color: ",";\n border: 1px solid\n ",";\n\n :hover {\n cursor: pointer;\n background-color: ",";\n border-color: ",";\n }\n\n :active,\n &.active {\n background-color: ",";\n border-color: ",";\n }\n"])),(function(t){return t.theme.input}),(function(t){return t.theme.secondaryInputColor}),(function(t){return t.theme.secondaryInputBgd}),(function(t){return t.error?t.theme.errorColor:t.theme.secondaryInputBorderColor}),(function(t){return t.theme.secondaryInputBgdHover}),(function(t){return t.theme.secondaryInputBgdHover}),(function(t){return t.theme.secondaryInputBgdActive}),(function(t){return t.theme.secondaryInputBorderActiveColor})),nt=(0,j.css)(s||(s=(0,N.default)(["\n cursor: pointer;\n flex-wrap: wrap;\n height: auto;\n justify-content: start;\n margin-bottom: 2px;\n padding: 0px 7px 0px 4px;\n white-space: normal;\n\n .chickleted-input__placeholder {\n line-height: 24px;\n margin: 4px;\n }\n"]))),it=(0,j.css)(l||(l=(0,N.default)(["\n "," ",";\n"])),(function(t){return t.theme.input}),(function(t){return t.theme.chickletedInputContainer})),ot=(0,j.css)(u||(u=(0,N.default)(["\n "," ",";\n"])),(function(t){return t.theme.inputLT}),(function(t){return t.theme.chickletedInputContainer})),at=(0,j.css)(c||(c=(0,N.default)(["\n "," ",";\n"])),(function(t){return t.theme.secondaryInput}),(function(t){return t.theme.chickletedInputContainer})),st=(0,j.css)(p||(p=(0,N.default)(["\n "," color: ",";\n font-size: 13px;\n letter-spacing: 0.43px;\n line-height: 18px;\n height: 24px;\n font-weight: 400;\n padding-left: 4px;\n margin-left: -4px;\n background-color: transparent;\n border: 1px solid transparent;\n\n :hover {\n height: 24px;\n cursor: text;\n background-color: transparent;\n border: 1px solid ",";\n }\n\n :active,\n .active,\n :focus {\n background-color: transparent;\n border: 1px solid ",";\n }\n"])),(function(t){return t.theme.input}),(function(t){return t.theme.textColor}),(function(t){return t.theme.labelColor}),(function(t){return t.theme.inputBorderActiveColor})),lt=(0,j.css)(h||(h=(0,N.default)(["\n background: ",";\n position: absolute;\n top: 0;\n left: ","px;\n content: '';\n display: block;\n width: ","px;\n height: ","px;\n border-radius: ",";\n"])),(function(t){return t.checked?t.theme.switchTrackBgdActive:t.theme.switchTrackBgd}),(function(t){return-t.theme.switchLabelMargin}),(function(t){return t.theme.switchWidth}),(function(t){return t.theme.switchHeight}),(function(t){return t.theme.switchTrackBorderRadius})),ut=(0,j.css)(f||(f=(0,N.default)(["\n transition: ",";\n position: absolute;\n top: ","px;\n left: ","px;\n content: '';\n display: block;\n height: ","px;\n width: ","px;\n background: ",";\n box-shadow: ",";\n border-radius: ",";\n"])),(function(t){return t.theme.transition}),(function(t){return(t.theme.switchHeight-t.theme.switchBtnHeight)/2}),(function(t){return(t.checked?t.theme.switchWidth/2:(t.theme.switchHeight-t.theme.switchBtnHeight)/2)-t.theme.switchLabelMargin}),(function(t){return t.theme.switchBtnHeight}),(function(t){return t.theme.switchBtnWidth}),(function(t){return t.checked?t.theme.switchBtnBgdActive:t.theme.switchBtnBgd}),(function(t){return t.theme.switchBtnBoxShadow}),(function(t){return t.theme.switchBtnBorderRadius})),ct=(0,j.css)(d||(d=(0,N.default)(["\n user-select: none;\n cursor: pointer;\n line-height: ","px;\n font-weight: 500;\n font-size: 12px;\n color: ",";\n position: relative;\n display: inline-block;\n padding-top: 0;\n padding-right: 0;\n padding-bottom: 0;\n padding-left: ","px;\n\n :before {\n ",";\n }\n\n :after {\n ",";\n }\n"])),(function(t){return t.theme.switchHeight}),(function(t){return t.theme.labelColor}),(function(t){return t.theme.switchWidth}),(function(t){return t.theme.switchTrack}),(function(t){return t.theme.switchButton})),pt=(0,j.css)(m||(m=(0,N.default)(["\n display: block;\n position: absolute;\n top: 0;\n left: 0;\n width: ","px;\n height: ","px;\n background: ",";\n border: 1px solid\n ",";\n border-radius: 2px;\n content: '';\n"])),(function(t){return t.theme.checkboxWidth}),(function(t){return t.theme.checkboxHeight}),(function(t){return t.checked?t.theme.checkboxBoxBgdChecked:t.theme.checkboxBoxBgd}),(function(t){return t.checked?t.theme.checkboxBoxBgdChecked:t.theme.checkboxBorderColor})),ht=(0,j.css)(g||(g=(0,N.default)(["\n width: 10px;\n height: 5px;\n border-bottom: 2px solid white;\n border-left: 2px solid white;\n top: 4px;\n left: 3px;\n transform: rotate(-45deg);\n display: block;\n position: absolute;\n opacity: ",";\n content: '';\n"])),(function(t){return t.checked?1:0})),ft=(0,j.css)(y||(y=(0,N.default)(["\n display: inline-block;\n position: relative;\n padding-left: 32px;\n margin-bottom: 24px;\n line-height: 20px;\n vertical-align: middle;\n cursor: pointer;\n font-size: 12px;\n color: ",";\n margin-left: -","px;\n\n :before {\n ",";\n }\n\n :after {\n ",";\n }\n"])),(function(t){return t.theme.labelColor}),(function(t){return t.theme.switchLabelMargin}),(function(t){return t.theme.checkboxBox}),(function(t){return t.theme.checkboxCheck})),dt=(0,j.css)(v||(v=(0,N.default)(["\n ","\n width: ","px;\n height: ","px;\n border-radius: ","px;\n background-color: ",";\n border-color: ",";\n"])),(function(t){return t.theme.checkboxBox}),(function(t){return 2*t.theme.radioRadius}),(function(t){return 2*t.theme.radioRadius}),(function(t){return t.theme.radioBorderRadius}),(function(t){return t.theme.switchTrackBgd}),(function(t){return t.theme.radioBorderColor})),mt=(0,j.css)(_||(_=(0,N.default)(["\n border: 0;\n display: table;\n top: ","px;\n left: ","px;\n width: ","px;\n height: ","px;\n border-radius: ","px;\n background-color: ",";\n"])),(function(t){return t.theme.radioRadius-t.theme.radioButtonRadius}),(function(t){return t.theme.radioRadius-t.theme.radioButtonRadius}),(function(t){return 2*t.theme.radioButtonRadius}),(function(t){return 2*t.theme.radioButtonRadius}),(function(t){return 2*t.theme.radioButtonRadius}),(function(t){return t.theme.radioButtonBgdColor})),gt=(0,j.css)(b||(b=(0,N.default)(["\n ","\n padding-left: ","px;\n margin-bottom: 0;\n margin-left: 0;\n line-height: ","px;\n color: ",";\n cursor: pointer;\n\n :before {\n ","\n }\n\n :after {\n ","\n }\n"])),(function(t){return t.theme.inputCheckbox}),(function(t){return 2*t.theme.radioRadius+8}),(function(t){return 2*t.theme.radioRadius}),(function(t){return t.theme.textColorHl}),(function(t){return t.theme.radioTrack}),(function(t){return t.theme.radioButton})),yt=(0,j.css)(x||(x=(0,N.default)(["\n ","\n\n :before {\n "," background: ",";\n }\n\n :after {\n ","\n background: ",";\n }\n"])),(function(t){return t.theme.inputRadio}),(function(t){return t.theme.radioTrack}),(function(t){return t.theme.secondarySwitchTrackBgd}),(function(t){return t.theme.radioButton}),(function(t){return t.checked?t.theme.switchBtnBgdActive:t.theme.secondarySwitchBtnBgd})),vt=(0,j.css)(w||(w=(0,N.default)(["\n ","\n\n :before {\n "," background: ",";\n }\n\n :after {\n ","\n background: ",";\n }\n"])),(function(t){return t.theme.inputSwitch}),(function(t){return t.theme.switchTrack}),(function(t){return t.checked?t.theme.switchTrackBgdActive:t.theme.secondarySwitchTrackBgd}),(function(t){return t.theme.switchButton}),(function(t){return t.checked?t.theme.switchBtnBgdActive:t.theme.secondarySwitchBtnBgd})),_t=(0,j.css)(E||(E=(0,N.default)(["\n ::-webkit-scrollbar {\n height: 10px;\n width: 10px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n }\n\n :vertical:hover {\n background: ",";\n cursor: pointer;\n }\n"])),(function(t){return t.theme.dropdownListBgd}),(function(t){return t.theme.dropdownListBgd}),(function(t){return t.theme.labelColor}),(function(t){return t.theme.dropdownListBgd}),(function(t){return t.theme.textColorHl})),bt=(0,j.css)(T||(T=(0,N.default)(["\n "," ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n }\n\n :vertical:hover {\n background: ",";\n cursor: pointer;\n }\n"])),_t,(function(t){return t.theme.dropdownListBgdLT}),(function(t){return t.theme.dropdownListBgdLT}),(function(t){return t.theme.labelColorLT}),(function(t){return t.theme.dropdownListBgdLT}),(function(t){return t.theme.textColorHlLT})),xt=(0,j.css)(A||(A=(0,N.default)(["\n color: ",";\n padding-left: 3px;\n font-size: ",";\n line-height: ","px;\n"])),(function(t){return t.theme.selectColor}),(function(t){return t.theme.selectFontSize}),(function(t){return t.theme.dropdownListLineHeight})),wt=(0,j.css)(C||(C=(0,N.default)(["\n ","\n color: ",";\n"])),xt,(function(t){return t.theme.selectColorLT})),Et=(0,j.css)(S||(S=(0,N.default)(["\n font-size: 11px;\n padding: 3px 9px;\n font-weight: 500;\n white-space: nowrap;\n"]))),Tt=(0,j.css)(P||(P=(0,N.default)(["\n "," &.hover,\n &:hover {\n cursor: pointer;\n background-color: ",";\n\n .list__item__anchor {\n color: ",";\n }\n }\n"])),Et,(function(t){return t.theme.dropdownListHighlightBg}),(function(t){return t.theme.textColorHl})),At=(0,j.css)(I||(I=(0,N.default)(["\n ","\n color: ",";\n\n &.hover,\n &:hover {\n cursor: pointer;\n color: ",";\n background-color: ",";\n\n .list__item__anchor {\n color: ",";\n }\n }\n"])),Et,(function(t){return t.theme.textColorLT}),(function(t){return t.theme.textColorHlLT}),(function(t){return t.theme.dropdownListHighlightBgLT}),(function(t){return t.theme.selectColorLT})),Ct=(0,j.css)(D||(D=(0,N.default)(["\n font-size: 11px;\n padding: 5px 9px;\n color: ",";\n"])),(function(t){return t.theme.labelColor})),St=(0,j.css)(O||(O=(0,N.default)(["\n padding: 0 0 4px 0;\n margin-bottom: 4px;\n border-bottom: 1px solid ",";\n"])),(function(t){return t.theme.labelColor})),Pt=(0,j.css)(M||(M=(0,N.default)(["\n overflow-y: auto;\n max-height: 280px;\n box-shadow: ",";\n border-radius: 2px;\n\n .list__section {\n ",";\n }\n .list__header {\n ",";\n }\n\n .list__item {\n ",";\n }\n\n .list__item__anchor {\n ",";\n }\n\n ",";\n"])),(function(t){return t.theme.dropdownListShadow}),(function(t){return t.theme.dropdownListSection}),(function(t){return t.theme.dropdownListHeader}),(function(t){return t.theme.dropdownListItem}),(function(t){return t.theme.dropdownListAnchor}),(function(t){return t.theme.dropdownScrollBar})),It=(0,j.css)(B||(B=(0,N.default)(["\n "," .list__item {\n ",";\n }\n\n .list__item__anchor {\n ",";\n }\n\n ",";\n"])),Pt,(function(t){return t.theme.dropdownListItemLT}),(function(t){return t.theme.dropdownListAnchorLT}),(function(t){return t.theme.dropdownScrollBarLT})),Dt=(0,j.css)(k||(k=(0,N.default)(["\n ::-webkit-scrollbar {\n height: ","px;\n width: ","px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n\n :hover {\n background: ",";\n cursor: pointer;\n }\n }\n"])),(function(t){return t.theme.sidePanelScrollBarHeight}),(function(t){return t.theme.sidePanelScrollBarWidth}),(function(t){return t.theme.sidePanelBg}),(function(t){return t.theme.sidePanelBg}),(function(t){return t.theme.panelBackgroundHover}),(function(t){return t.theme.sidePanelBg}),(function(t){return t.theme.labelColor})),Ot=(0,j.css)(F||(F=(0,N.default)(["\n ::-webkit-scrollbar {\n height: 10px;\n width: 10px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n :hover {\n background: ",";\n cursor: pointer;\n }\n }\n"])),(function(t){return t.theme.panelBackground}),(function(t){return t.theme.panelBackground}),(function(t){return t.theme.panelBackgroundHover}),(function(t){return t.theme.panelBackground}),(function(t){return t.theme.labelColor})),Mt=(0,j.css)(L||(L=(0,N.default)(["\n ::-webkit-scrollbar {\n height: 10px;\n width: 10px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ","\n\n :vertical:hover {\n background: ",";\n cursor: pointer;\n }\n\n :horizontal:hover {\n background: ",";\n cursor: pointer;\n }\n }\n"])),(function(t){return t.theme.panelBackground}),(function(t){return t.theme.panelBackground}),(function(t){return t.theme.labelColor}),(function(t){return t.theme.panelBackground}),(function(t){return t.theme.textColorHl}),(function(t){return t.theme.textColorHl})),Bt=(0,j.css)(R||(R=(0,N.default)(["\n ::-webkit-scrollbar {\n width: 14px;\n height: 16px;\n }\n\n ::-webkit-scrollbar-track {\n background: white;\n }\n ::-webkit-scrollbar-track:horizontal {\n background: ",";\n }\n ::-webkit-scrollbar-thumb {\n background: ",";\n border: 4px solid white;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb:hover {\n background: #969da9;\n }\n\n ::-webkit-scrollbar-thumb:vertical {\n border-radius: 7px;\n }\n\n ::-webkit-scrollbar-thumb:horizontal {\n border-radius: 9px;\n border: 4px solid ",";\n }\n"])),(function(t){return t.theme.textColorHl}),(function(t){return t.theme.labelColorLT}),(function(t){return t.theme.textColorHl}),(function(t){return t.theme.textColorHl}));e.modalScrollBar=Bt;var kt=q(q({},U.DIMENSIONS),{},{input:tt,inputLT:et,inlineInput:st,chickletedInput:it,chickletedInputLT:ot,chickletedInputContainer:nt,secondaryChickletedInput:at,borderColor:"#3A414C",borderColorLT:"#F1F1F1",secondaryInput:rt,dropdownScrollBar:_t,dropdownScrollBarLT:bt,dropdownList:Pt,dropdownListLT:It,dropdownListItem:Tt,dropdownListItemLT:At,dropdownListAnchor:xt,dropdownListAnchorLT:wt,dropdownListHeader:Ct,dropdownListSection:St,dropdownListShadow:"0 6px 12px 0 rgba(0,0,0,0.16)",dropdownWrapperZ:100,dropdownWapperMargin:4,modalScrollBar:Bt,scrollBar:Mt,sidePanelScrollBar:Dt,inputSwitch:ct,secondarySwitch:vt,switchTrack:lt,switchButton:ut,inputCheckbox:ft,inputRadio:gt,checkboxBox:pt,checkboxCheck:ht,transition:"all .4s ease",transitionFast:"all .2s ease",transitionSlow:"all .8s ease",activeColor:"#1FBAD6",activeColorHover:"#108188",borderRadius:"1px",boxShadow:H,errorColor:"#F9042C",dropdownListHighlightBg:"#6A7485",dropdownListHighlightBgLT:"#F8F8F9",dropdownListBgd:"#29323C",toolbarItemBgdHover:"#3A4552",toolbarItemBorderHover:"transparent",toolbarItemIconHover:"#F0F0F0",toolbarItemBorderRaddius:"0px",dropdownListBgdLT:"#FFFFFF",dropdownListBorderTop:"#242730",dropdownListBorderTopLT:"#D3D8E0",dropdownListLineHeight:20,labelColor:"#6A7485",labelColorLT:"#6A7485",labelHoverColor:"#C6C6C6",mapPanelBackgroundColor:"#242730",mapPanelHeaderBackgroundColor:"#29323C",selectActiveBorderColor:"#D3D8E0",selectBackground:"#29323C",selectBackgroundLT:"#FFFFFF",selectBackgroundHover:"#3A414C",selectBackgroundHoverLT:"#F8F8F9",selectBorder:0,selectBorderColor:"#D3D8E0",selectBorderRadius:"1px",selectBorderColorLT:"#D3D8E0",selectColor:"#A0A7B4",selectColorPlaceHolder:"#6A7485",selectColorPlaceHolderLT:"#29323C",selectFontSize:"11px",selectFontWeight:"400",selectColorLT:"#29323C",selectFontWeightBold:"500",panelTabColor:"#6A7485",inputBgd:"#29323C",inputBgdHover:"#3A414C",inputBgdActive:"#3A414C",inputBgdActiveLT:"#FFFFFF",inputBoxHeight:"34px",inputBoxHeightSmall:"24px",inputBoxHeightTiny:"18px",inputBorderColor:"#29323C",inputBorderActiveColor:"#3A414C",inputBorderHoverColor:"#3A414C",inputBorderRadius:"1px",inputColor:"#A0A7B4",inputPadding:"4px 10px",inputPaddingSmall:"4px 6px",inputPaddingTiny:"2px 4px",inputFontSize:"11px",inputFontSizeSmall:"10px",inputFontWeight:500,inputPlaceholderColor:"#6A7485",inputPlaceholderColorLT:"#A0A7B4",inputPlaceholderFontWeight:400,inputBoxShadow:"none",inputBoxShadowActive:"none",inputBoxShadowActiveLT:"none",secondaryInputBgd:"#242730",secondaryInputBgdHover:"#3A414C",secondaryInputBgdActive:"#3A414C",secondaryInputColor:"#A0A7B4",secondaryInputBorderColor:"#242730",secondaryInputBorderActiveColor:"#D3D8E0",dropdownSelectHeight:30,switchWidth:24,switchHeight:12,switchTrackBgd:"#29323C",switchTrackBgdActive:"#1FBAD6",switchTrackBorderRadius:"1px",switchBtnBgd:"#6A7485",switchBtnBgdActive:"#D3D8E0",switchBtnBoxShadow:"0 2px 4px 0 rgba(0,0,0,0.40)",switchBtnBorderRadius:"0",switchBtnWidth:12,switchBtnHeight:12,switchLabelMargin:12,secondarySwitchTrackBgd:"#242730",secondarySwitchBtnBgd:"#3A414C",checkboxWidth:16,checkboxHeight:16,checkboxMargin:12,checkboxBorderColor:"#D3D8E0",checkboxBorderRadius:"2px",checkboxBorderColorLT:"#D3D8E0",checkboxBoxBgd:"white",checkboxBoxBgdChecked:"#0F9668",radioRadius:8,radioBorderRadius:100,radioBorderColor:"transparent",radioButtonRadius:4,radioButtonBgdColor:"#D3D8E0",radioTrack:dt,radioButton:mt,secondaryRadio:yt,btnFontFamily:Z,primaryBtnBgd:"#0F9668",primaryBtnActBgd:"#13B17B",primaryBtnColor:"#FFFFFF",primaryBtnActColor:"#FFFFFF",primaryBtnBgdHover:"#13B17B",primaryBtnRadius:"2px",primaryBtnFontSizeDefault:"11px",primaryBtnFontSizeSmall:"10px",primaryBtnFontSizeLarge:"14px",primaryBtnBorder:"0",secondaryBtnBgd:"#6A7485",secondaryBtnActBgd:"#A0A7B4",secondaryBtnBgdHover:"#A0A7B4",secondaryBtnColor:"#FFFFFF",secondaryBtnActColor:"#FFFFFF",secondaryBtnBorder:"0",negativeBtnBgd:"#F9042C",negativeBtnActBgd:"#FF193E",negativeBtnBgdHover:"#FF193E",negativeBtnBorder:"0",negativeBtnColor:"#FFFFFF",negativeBtnActColor:"#FFFFFF",linkBtnBgd:"transparent",linkBtnActBgd:"transparent",linkBtnColor:"#A0A7B4",linkBtnActColor:"#F1F1F1",linkBtnActBgdHover:"transparent",linkBtnBorder:"0",floatingBtnBgd:"#29323C",floatingBtnActBgd:"#3A4552",floatingBtnBgdHover:"#3A4552",floatingBtnBorder:"0",floatingBtnBorderHover:"0",floatingBtnColor:"#6A7485",floatingBtnActColor:"#FFFFFF",ctaBtnBgd:"#0F9668",ctaBtnBgdHover:"#13B17B",ctaBtnActBgd:"#13B17B",ctaBtnColor:"#FFFFFF",ctaBtnActColor:"#FFFFFF",selectionBtnBgd:"transparent",selectionBtnActBgd:"transparent",selectionBtnColor:"#D3D8E0",selectionBtnActColor:"#0F9668",selectionBtnBgdHover:"#0F9668",selectionBtnBorder:"1",selectionBtnBorderColor:"#D3D8E0",selectionBtnBorderActColor:"#0F9668",modalTitleColor:"#3A414C",modalTitleFontSize:"24px",modalTitleFontSizeSmaller:"18px",modalFooterBgd:"#F8F8F9",modalImagePlaceHolder:"#DDDFE3",modalPadding:"10px 0",modalDialogBgd:"#3A414C",modalDialogColor:"#F0F0F0",modalLateralPadding:"72px",modalPortableLateralPadding:"36px",modalOverLayZ:1001,modalOverlayBgd:"rgba(0, 0, 0, 0.5)",modalContentZ:10002,modalFooterZ:10001,modalTitleZ:10003,modalButtonZ:10005,modalDropdownBackground:"#FFFFFF",sidePanelBg:"#242730",sidePanelInnerPadding:16,sideBarCloseBtnBgd:"#6A7485",sideBarCloseBtnColor:"#29323C",sideBarCloseBtnBgdHover:"#A0A7B4",sidePanelHeaderBg:"#29323C",sidePanelHeaderBorder:"transparent",sidePanelScrollBarWidth:10,sidePanelScrollBarHeight:10,sidePanelTitleFontsize:"20px",sidePanelTitleLineHeight:"1.71429",panelHeaderBorderRadius:"0px",sidePanelBorder:0,sidePanelBorderColor:"transparent",layerConfigGroupLabelLabelFontSize:"12px",layerConfigGroupMarginBottom:12,layerConfigGroupPaddingLeft:18,chickletBgd:"#3A4552",chickletBgdLT:"#D3D8E0",panelBackground:"#29323C",panelContentBackground:"#292E36",panelBackgroundHover:"#3A4552",panelBackgroundLT:"#F8F8F9",panelToggleMarginRight:12,panelToggleBottomPadding:6,panelBoxShadow:"0 6px 12px 0 rgba(0,0,0,0.16)",panelBorderRadius:"2px",panelBorder:W,panelBorderColor:"#3A414C",panelBorderLT:Y,panelHeaderIcon:"#6A7485",panelHeaderIconActive:"#A0A7B4",panelHeaderIconHover:"#F0F0F0",panelHeaderHeight:48,layerPanelHeaderHeight:48,panelDropdownScrollBar:Ot,layerTypeIconSizeL:50,layerTypeIconPdL:12,layerTypeIconSizeSM:28,layerPanelToggleOptionColor:"#6A7485",layerPanelToggleOptionColorActive:"#F0F0F0",fontFamily:G,fontWeight:400,fontSize:"0.875em",lineHeight:1.71429,textColor:"#A0A7B4",textColorLT:"#3A414C",dataTableTextColor:"#3A414C",textColorHl:"#F0F0F0",titleTextColor:"#FFFFFF",subtextColor:"#6A7485",subtextColorLT:"#A0A7B4",subtextColorActive:"#FFFFFF",panelToggleBorderColor:"#FFFFFF",panelTabWidth:"30px",textTruncate:Q,titleColorLT:"#29323C",tooltipBg:"#3A414C",tooltipColor:"#F0F0F0",tooltipBoxShadow:"0 1px 2px 0 rgba(0,0,0,0.10)",tooltipFontSize:"10px",logoColor:"#1FBAD6",sidepanelDividerBorder:"1px",sidepanelDividerMargin:12,sidepanelDividerHeight:12,bottomInnerPdSide:32,bottomInnerPdVert:6,bottomPanelGap:20,bottomPanelGapPalm:20,bottomWidgetPaddingTop:20,bottomWidgetPaddingRight:20,bottomWidgetPaddingBottom:30,bottomWidgetPaddingLeft:20,bottomWidgetBgd:"#29323C",sliderBarColor:"#6A7485",sliderBarBgd:"#3A414C",sliderBarHoverColor:"#D3D8E0",sliderBarRadius:"1px",sliderBarHeight:4,sliderHandleHeight:12,sliderHandleWidth:12,sliderHandleColor:"#D3D8E0",sliderHandleTextColor:"#D3D8E0",sliderInactiveBorderColor:"#D3D8E0",sliderBorderRadius:"0",sliderHandleHoverColor:"#FFFFFF",sliderHandleAfterContent:"",sliderHandleShadow:"0 2px 4px 0 rgba(0,0,0,0.40)",sliderInputHeight:24,sliderInputWidth:56,sliderMarginTopIsTime:-12,sliderMarginTop:12,sliderMarginBottom:12,geocoderWidth:360,geocoderTop:20,geocoderRight:12,geocoderInputHeight:36,rangeBrushBgd:"#3A414C",histogramFillInRange:"#1FBAD6",histogramFillOutRange:"#6A7485",axisFontSize:"10px",axisFontColor:"#A0A7B4",timeTitleFontSize:"10px",rangePlotMargin:X,rangePlotMarginLarge:K,rangePlotH:62,rangePlotHLarge:102,rangePlotHLargePalm:102,rangePlotContainerH:78,rangePlotContainerHLarge:120,rangePlotContainerHLargePalm:120,notificationColors:J,notificationPanelWidth:240,notificationPanelItemWidth:180,notificationPanelItemHeight:60,headerRowHeight:70,rowHeight:32,headerPaddingTop:6,headerPaddingBottom:8,cellPaddingSide:10,edgeCellPaddingSide:10,cellFontSize:10,gridPaddingSide:24,optionButtonColor:"#6A7485",headerCellBackground:"#FFFFFF",headerCellBorderColor:"#E0E0E0",headerCellIconColor:"#666666",cellBorderColor:"#E0E0E0",evenRowBackground:"#FFFFFF",oddRowBackground:"#F7F7F7",pinnedGridBorderColor:"#E0E0E0",timeDisplayBorderRadius:32,timeDisplayHeight:64,timeDisplayMinWidth:176,timeDisplayOpacity:.8,timeDisplayPadding:"0 24px",exportIntraSectionMargin:"8",actionPanelWidth:110,actionPanelHeight:32,breakPoints:$,progressBarColor:"#0F9668",progressBarTrackColor:"#E8E8E8",layerConfigGroupLabelBorderLeft:"2px",layerConfigGroupLabelMargin:"-12px",layerConfigGroupLabelPadding:"10px",layerConfigGroupColor:"transparent",layerConfigGroupLabelLabelMargin:"0",styledConfigGroupHeaderBorder:"2px",layerConfiguratorBorder:"0",layerConfiguratorBorderColor:"",layerConfiguratorMargin:"12px",layerConfiguratorPadding:"12px 0 8px 0",fieldTokenRightMargin:4});e.theme=kt;var Ft=q(q({},kt),{},{activeColor:"#2473BD",input:et,textColor:"#3A414C",sidePanelBg:"#FFFFFF",selectColor:"#29323C",titleTextColor:"#000000",sidePanelHeaderBg:"#F7F7F7",subtextColorActive:"#2473BD",tooltipBg:"#1869B5",tooltipColor:"#FFFFFF",dropdownListBgd:"#FFFFFF",toolbarItemBgdHover:"#F7F7F7",textColorHl:"#2473BD",inputBgd:"#F7F7F7",inputBgdHover:"#FFFFFF",inputBgdActive:"#FFFFFF",inputBgdActiveLT:"#FFFFFF",dropdownListHighlightBg:"#F0F0F0",toolbarItemIconHover:"#2473BD",panelBackground:"#F7F7F7",panelContentBackground:"#F7F7F7",bottomWidgetBgd:"#F7F7F7",panelBackgroundHover:"#F7F7F7",panelBorderColor:"#D3D8E0",panelHeaderIconActive:"#000000",panelHeaderIconHover:"#000000",sideBarCloseBtnBgd:"#F7F7F7",sideBarCloseBtnColor:"#3A414C",sideBarCloseBtnBgdHover:"#F7F7F7",secondaryInputBgd:"#F7F7F7",secondaryInputBgdActive:"#F7F7F7",secondaryInputBgdHover:"#FFFFFF",secondaryInputBorderActiveColor:"#000000",secondaryInputBorderColor:"none",secondaryInputColor:"#545454",chickletBgd:"#F7F7F7",mapPanelBackgroundColor:"#FFFFFF",mapPanelHeaderBackgroundColor:"#F7F7F7",sliderBarColor:"#A0A7B4",sliderBarBgd:"#D3D8E0",sliderHandleColor:"#F7F7F7",sliderInactiveBorderColor:"#F7F7F7",sliderHandleTextColor:"#F7F7F7",sliderHandleHoverColor:"#F7F7F7",subtextColor:"#A0A7B4",switchBtnBgd:"#F7F7F7",secondarySwitchBtnBgd:"#F7F7F7",secondarySwitchTrackBgd:"#D3D8E0",switchBtnBgdActive:"#F7F7F7",switchTrackBgd:"#D3D8E0",switchTrackBgdActive:"#2473BD",primaryBtnBgd:"#13B17B",primaryBtnActBgd:"#0F9668",primaryBtnBgdHover:"#0F9668",secondaryBtnBgd:"#A0A7B4",secondaryBtnActBgd:"#6A7485",secondaryBtnBgdHover:"#6A7485",floatingBtnBgd:"#F7F7F7",floatingBtnActBgd:"#F7F7F7",floatingBtnBgdHover:"#F7F7F7",floatingBtnColor:"#6A7485",floatingBtnActColor:"#2473BD",linkBtnActColor:"#3A414C",rangeBrushBgd:"#D3D8E0",histogramFillInRange:"#2473BD",histogramFillOutRange:"#A0A7B4",axisFontColor:"#3A414C"});e.themeLT=Ft;var Lt=q(q({},kt),{},{activeColor:"#E2E2E2",dropdownListBgd:"#FFFFFF",toolbarItemBgdHover:"#F7F7F7",dropdownListBorderTop:"none",dropdownListHighlightBg:"#F6F6F6",toolbarItemIconHover:"#000000",inputBgd:"#E2E2E2",inputBgdActive:"#E2E2E2",inputBgdHover:"inherit",inputBorderActiveColor:"#000000",inputColor:"#000000",chickletBgd:"#E2E2E2",panelBackground:"#FFFFFF",panelBackgroundHover:"#EEEEEE",panelContentBackground:"#FFFFFF",bottomWidgetBgd:"#F7F7F7",panelHeaderIconActive:"#000000",panelHeaderIconHover:"#000000",panelBorderColor:"#E2E2E2",primaryBtnBgd:"#E2E2E2",primaryBtnBgdHover:"#333333",primaryBtnColor:"#000000",secondaryBtnActBgd:"#EEEEEE",secondaryBtnActColor:"#000000",secondaryBtnBgd:"#E2E2E2",secondaryBtnBgdHover:"#CBCBCB",ctnBtnBgd:"#E2E2E2",ctnBtnBgdHover:"333333",ctnBtnColor:"#000000",ctnBtnActColor:"#000000",sideBarCloseBtnBgd:"#E2E2E2",sideBarCloseBtnColor:"#000000",sideBarCloseBtnBgdHover:"#FFFFFF",floatingBtnBgd:"#FFFFFF",floatingBtnActBgd:"#EEEEEE",floatingBtnBgdHover:"#EEEEEE",floatingBtnColor:"#757575",floatingBtnActColor:"#000000",secondaryBtnColor:"#000000",secondaryInputBgd:"#F6F6F6",secondaryInputBgdActive:"#F6F6F6",secondaryInputBgdHover:"#F6F6F6",secondaryInputBorderActiveColor:"#000000",secondaryInputBorderColor:"none",secondaryInputColor:"#545454",sidePanelBg:"#F6F6F6",sidePanelHeaderBg:"#FFFFFF",subtextColor:"#AFAFAF",panelTabColor:"#AFAFAF",subtextColorActive:"#000000",textColor:"#000000",textColorHl:"#545454",mapPanelBackgroundColor:"#F6F6F6",mapPanelHeaderBackgroundColor:"#FFFFFF",titleTextColor:"#000000",switchBtnBgdActive:"#000000",switchBtnBgd:"#FFFFFF",switchTrackBgdActive:"#E2E2E2",secondarySwitchTrackBgd:"#E2E2E2",switchTrackBgd:"#E2E2E2",secondarySwitchBtnBgd:"#FFFFFF",histogramFillInRange:"#000000",histogramFillOutRange:"#E2E2E2",rangeBrushBgd:"#E2E2E2",sliderBarBgd:"#E2E2E2",sliderHandleColor:"#FFFFFF",sliderInactiveBorderColor:"#FFFFFF",sliderHandleTextColor:"#FFFFFF",sliderBarColor:"#000000"});e.themeBS=Lt},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0});var i={KeyEvent:!0};Object.defineProperty(e,"KeyEvent",{enumerable:!0,get:function(){return c.default}});var o=r(43);Object.keys(o).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===o[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return o[t]}}))}));var a=r(27);Object.keys(a).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===a[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return a[t]}}))}));var s=r(28);Object.keys(s).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===s[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return s[t]}}))}));var l=r(29);Object.keys(l).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===l[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return l[t]}}))}));var u=r(63);Object.keys(u).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===u[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return u[t]}}))}));var c=n(r(64)),p=r(34);Object.keys(p).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===p[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return p[t]}}))}));var h=r(66);Object.keys(h).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===h[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return h[t]}}))}));var f=r(67);Object.keys(f).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(i,t)||t in e&&e[t]===f[t]||Object.defineProperty(e,t,{enumerable:!0,get:function(){return f[t]}}))}))},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),e.Themes=e.ColorsByTheme=e.default=void 0;var i=n(r(13)),o=n(r(24));function a(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function s(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?a(Object(r),!0).forEach((function(e){(0,i.default)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var l={grey_7:"#898989",brick_20:"#B77B6A",brick_21:"#8B574F",brick_22:"#392421",lime_8:"#7DC240",lime_9:"#76B73D",lime_4:"#CFEDB5",lime_5:"#B6E490",lime_6:"#9EDB6B",lime_7:"#8ECF56",lime_1:"#F3FBED",lime_2:"#EBF8E1",lime_3:"#E3F5D4",orange_22:"#32221D",orange_20:"#DDA37C",orange_21:"#A2705B",stone_9:"#716852",stone_8:"#776E57",stone_20:"#4D4A44",stone_1:"#F3F2EF",amber_22:"#32251D",stone_21:"#282623",amber_20:"#DDB27C",amber_21:"#A2785B",navy_17:"#CAD1E6",navy_16:"#18264D",navy_15:"#132559",navy_14:"#162A65",navy_13:"#1A3177",navy_12:"#1E3788",navy_11:"#223F9A",navy_10:"#2647AC",navy_19:"#7989B7",navy_18:"#9CAAD3",teal_9:"#1C8EB4",teal_8:"#1E96BE",teal_5:"#79C7E3",teal_4:"#A6DAEC",teal_7:"#35A6CC",teal_6:"#4DB5D9",teal_1:"#E9F6FA",teal_3:"#CBE9F4",teal_2:"#DAF0F7",teal_19:"#73A6B7",teal_18:"#96C3D2",teal_11:"#17779A",teal_10:"#1A85AB",teal_13:"#125C77",teal_12:"#146988",teal_15:"#0D4559",teal_14:"#0F4E65",teal_17:"#C7DDE5",teal_16:"#103B49",gold_20:"#DDBE7C",gold_21:"#A27E5B",gold_22:"#32271D",olive_9:"#B8C436",olive_8:"#C3D039",olive_7:"#CFDC4F",olive_6:"#DBE765",olive_5:"#E4ED8B",olive_4:"#EDF3B2",olive_3:"#F5F8D2",olive_2:"#F8FADF",olive_1:"#FBFCEC",green_22:"#212A1F",green_20:"#5A735A",green_21:"#2F3C2F",indigo_17:"#CCC7E4",indigo_16:"#1B1247",indigo_15:"#1C0F58",indigo_14:"#201163",indigo_13:"#261474",indigo_12:"#2C1685",indigo_11:"#321A97",indigo_10:"#371DA8",indigo_19:"#7E71B2",indigo_18:"#A095CF",blue_22:"#222A34",blue_20:"#536A81",blue_21:"#2D3946",olive_22:"#28291C",olive_20:"#878A5E",olive_21:"#484A32",violet_16:"#510E30",violet_17:"#E0C1D8",violet_14:"#6B083F",violet_15:"#620736",violet_12:"#860A5A",violet_13:"#79094D",violet_10:"#A40D77",violet_11:"#950C69",dirt_16:"#261A10",dirt_17:"#BCB6B1",dirt_14:"#322113",dirt_15:"#2D1D10",dirt_12:"#442D19",dirt_13:"#3B2716",violet_18:"#C78BB8",violet_19:"#B1699C",stone_15:"#373227",stone_14:"#3E392D",stone_17:"#C6C4C0",stone_16:"#2E2A22",stone_11:"#5F5845",stone_10:"#6A624D",stone_13:"#494335",stone_12:"#544D3D",stone_19:"#706C63",stone_18:"#938F87",aqua_3:"#CAF2F4",aqua_2:"#D9F6F7",aqua_1:"#E8FAFA",aqua_7:"#2FC5CC",aqua_6:"#47D3D9",aqua_5:"#75DEE3",aqua_4:"#A3E9EC",aqua_9:"#15AEB4",aqua_8:"#17B8BE",orange_7:"#FE891A",orange_6:"#FF9833",orange_5:"#FFB266",orange_4:"#FFCB99",orange_3:"#FFE1C4",orange_2:"#FFEAD5",orange_1:"#FFF2E6",orange_9:"#FA7400",orange_8:"#FD7900",purple_13:"#510869",purple_11:"#670B8C",purple_10:"#720C9D",purple_7:"#9226BE",purple_6:"#A13ECD",purple_5:"#B86EDA",purple_4:"#D09FE6",purple_3:"#E4C7F1",purple_2:"#ECD7F5",purple_1:"#F3E7F9",blue_18:"#99B6D3",blue_17:"#C9D7E6",blue_16:"#16314D",blue_15:"#103459",blue_14:"#133B65",blue_13:"#164677",blue_12:"#195188",purple_9:"#7A0DA6",blue_10:"#2067AC",orange_13:"#D65200",orange_12:"#E45D00",orange_11:"#ED6600",orange_10:"#F26C00",orange_17:"#F8E2CC",orange_16:"#8C330A",orange_15:"#B93C00",orange_14:"#C84600",orange_19:"#F6BD8A",orange_18:"#F8CCA1",magenta_11:"#B51241",magenta_10:"#C5154A",magenta_13:"#970E2D",magenta_12:"#A51037",magenta_15:"#7E0A1D",magenta_14:"#880B23",magenta_17:"#EDCAD6",magenta_16:"#63101D",magenta_19:"#D2809A",magenta_18:"#E29DB4",stone_3:"#E2E0DA",stone_2:"#EBE9E4",stone_5:"#B3AD9E",stone_4:"#CDC9BF",stone_7:"#89806B",stone_6:"#9A927E",blue_9:"#226DB5",blue_8:"#2473BD",blue_7:"#3B85CC",blue_6:"#5297DA",blue_5:"#7DB1E3",blue_4:"#A9CBED",blue_3:"#CDE1F4",blue_2:"#DCEAF7",blue_1:"#EAF2FA",gold_9:"#FAC200",gold_8:"#FDC900",gold_5:"#FFE466",gold_4:"#FFEB8C",gold_7:"#FED21A",gold_6:"#FFDB33",gold_1:"#FFFBE6",gold_3:"#FFF5C4",gold_2:"#FFF8D5",dirt_22:"#191410",dirt_21:"#201B17",dirt_20:"#3D342C",white:"#FFFFFF",gold_19:"#F6E08A",gold_18:"#F8E8A1",grey_8:"#777777",grey_9:"#717171",gold_11:"#EDAB00",gold_10:"#F6BA00",gold_13:"#D68800",gold_12:"#E49B00",gold_15:"#B96500",gold_14:"#C87500",gold_17:"#F8F0CC",gold_16:"#8C500A",grey_10:"#6A6A6A",grey_11:"#5F5F5F",grey_12:"#545454",grey_13:"#494949",grey_14:"#3E3E3E",grey_15:"#373636",grey_16:"#2E2D2D",grey_17:"#C6C6C6",grey_18:"#939393",grey_19:"#707070",dirt_19:"#5B4D42",yellow_20:"#DDC97C",yellow_21:"#A2845B",yellow_22:"#32291D",dirt_10:"#573921",dirt_11:"#4E331D",brown_8:"#986232",brown_9:"#905D2F",stone_22:"#1C1A18",brown_6:"#B7885E",brown_7:"#A87548",brick_1:"#FEEEE8",brick_3:"#FCD6C8",brick_2:"#FDE2D8",brick_5:"#F89570",brick_4:"#FAB8A0",brick_7:"#EF5D28",brick_6:"#F57141",brick_9:"#DF4916",brick_8:"#E7531F",amber_7:"#FEB31A",amber_6:"#FFBE33",amber_5:"#FFCE66",amber_4:"#FFDF99",amber_3:"#FFECC4",amber_2:"#FFF2D5",amber_1:"#FFF7E6",amber_9:"#FAA100",amber_8:"#FDA700",grey_2:"#F1F1F1",grey_3:"#E5E5E4",violet_22:"#301C25",violet_21:"#51303F",violet_20:"#7F4B6D",grey_1:"#F8F8F9",red_19:"#D37676",red_18:"#E49595",red_15:"#880000",red_14:"#910000",red_17:"#EEC7C7",red_16:"#6D0A0A",red_11:"#BB0000",red_10:"#C90000",red_13:"#9F0000",red_12:"#AC0000",black:"#000000",grey_4:"#D6D6D5",grey_5:"#C0C0C0",navy_7:"#4265CC",navy_6:"#5879DA",navy_5:"#829AE3",navy_4:"#ABBCED",navy_3:"#CFD8F4",navy_2:"#DDE3F7",navy_1:"#EBEFFA",navy_9:"#294CB5",navy_8:"#2C51BE",yellow_15:"#B97600",yellow_14:"#C88900",yellow_17:"#F8F6CC",yellow_16:"#8C5C0A",yellow_11:"#EDC800",yellow_10:"#F6DA00",yellow_13:"#D6A000",yellow_12:"#E4B600",yellow_19:"#F6EF8A",yellow_18:"#F8F5A1",purple_20:"#664473",purple_21:"#352139",magenta_1:"#FCE9EF",magenta_3:"#F9CADA",magenta_2:"#FBDAE4",magenta_5:"#EF769E",magenta_4:"#F4A3BF",magenta_7:"#E1316A",magenta_6:"#E9487E",magenta_9:"#CF1750",magenta_8:"#D91955",indigo_3:"#D4CCF3",indigo_2:"#E1DBF6",indigo_1:"#EDE9FA",indigo_7:"#5438C8",indigo_6:"#694FD6",indigo_5:"#8F7BE0",indigo_4:"#B4A7EB",indigo_9:"#3B1EB1",indigo_8:"#482BBD",magenta_20:"#9E5F70",magenta_21:"#6D4046",magenta_22:"#2C1B1E",purple_22:"#231727",red_9:"#D20000",red_8:"#DA0000",red_5:"#F06D6D",red_4:"#F59999",red_7:"#E31A1A",red_6:"#EA4444",red_1:"#FDE6E6",red_3:"#F9C4C4",red_2:"#FBD5D5",grey_21:"#282727",grey_20:"#4D4D4D",grey_22:"#1C1B1B",lime_16:"#30471D",lime_17:"#D9E6CE",lime_14:"#406422",lime_15:"#39581E",lime_12:"#57882E",lime_13:"#4C7628",lime_10:"#6EAC3A",lime_11:"#639A34",lime_18:"#BAD4A4",lime_19:"#9EBB84",dirt_18:"#81746B",violet_8:"#B80F87",violet_9:"#AE0E7F",violet_4:"#E79FD5",violet_5:"#DA70BF",violet_6:"#CE40AA",violet_7:"#C32899",violet_1:"#F9E8F5",violet_2:"#F5D8EE",violet_3:"#F1C8E6",red_20:"#A55C5C",red_21:"#784343",red_22:"#361F1F",amber_19:"#F6D18A",amber_18:"#F8DCA1",amber_13:"#D67100",amber_12:"#E48000",amber_11:"#ED8D00",amber_10:"#F69A00",amber_17:"#F8EACC",amber_16:"#8C440A",amber_15:"#B95300",amber_14:"#C86100",green_17:"#CDDDCD",green_16:"#254325",green_15:"#274F28",green_14:"#2C5A2E",green_13:"#356A36",green_12:"#3D7A3E",green_11:"#458A46",green_10:"#4C9A4E",green_19:"#82A682",green_18:"#A2C2A2",turquoise_19:"#77AC9B",turquoise_18:"#99C7B9",turquoise_15:"#185240",turquoise_14:"#1B5D48",turquoise_17:"#C9E0D9",turquoise_16:"#1A4538",turquoise_11:"#2B8F70",turquoise_10:"#309F7D",turquoise_13:"#216E56",turquoise_12:"#267E63",aqua_22:"#1A2C2B",aqua_20:"#4F7E81",aqua_21:"#2B4447",yellow_9:"#FAE300",yellow_8:"#FDEC00",yellow_5:"#FFFA66",yellow_4:"#FFFB98",yellow_7:"#FEF21A",yellow_6:"#FFF833",yellow_1:"#FFFEE6",yellow_3:"#FFFDC4",yellow_2:"#FFFED5",teal_20:"#507481",teal_21:"#2C3F46",teal_22:"#152629",indigo_22:"#1A1724",purple_12:"#5C097A",indigo_20:"#59507E",indigo_21:"#312C45",purple_17:"#D5C1DF",purple_16:"#360B40",purple_15:"#3F054C",purple_14:"#460658",purple_19:"#9563A8",purple_18:"#B389C6",blue_19:"#7597B6",lime_22:"#1E241A",lime_21:"#3A4531",lime_20:"#6C815B",turquoise_1:"#ECF9F5",turquoise_3:"#D2F1E7",turquoise_2:"#DFF5EE",turquoise_5:"#89DAC1",turquoise_4:"#B1E7D6",turquoise_7:"#4DC19C",turquoise_6:"#62CEAD",turquoise_9:"#34A984",turquoise_8:"#37B38B",brown_4:"#DBC3AF",brown_5:"#C9A686",brown_2:"#F0E7DE",brown_3:"#EADDD0",brown_1:"#F6F0EB",blue_11:"#1C5C9A",brown_14:"#4F3319",purple_8:"#820DAF",brown_15:"#452D16",brown_16:"#3C2A18",brown_18:"#B09C8A",brick_19:"#E19D84",brick_18:"#EEB5A1",brick_15:"#9B1C04",brick_14:"#A42105",brick_17:"#F3D7CC",brick_16:"#7A1F0E",brick_11:"#CB380B",brick_10:"#D73F0D",brick_13:"#B12907",brick_12:"#BE3009",olive_13:"#777E23",olive_12:"#899128",olive_11:"#9BA52E",olive_10:"#ADB933",olive_17:"#E9ECD0",olive_16:"#494C1B",olive_15:"#595E1A",olive_14:"#656B1D",olive_19:"#C3C989",olive_18:"#DBE0A8",navy_22:"#232734",navy_20:"#555F81",navy_21:"#2E3446",brown_21:"#352D24",brown_20:"#645446",brown_22:"#29231C",dirt_4:"#C3B5A9",dirt_5:"#A68F7E",dirt_6:"#886A53",dirt_7:"#75553C",dirt_1:"#F0EDEA",dirt_2:"#E7E1DC",dirt_3:"#DDD4CD",dirt_8:"#624025",dirt_9:"#5D3D23",green_3:"#DAEFDA",green_2:"#E4F3E4",green_1:"#EFF8EF",green_7:"#6ABB6B",green_6:"#7DC97F",green_5:"#9ED79F",green_4:"#BEE4BF",green_9:"#52A353",green_8:"#57AD57",brown_10:"#88572C",brown_11:"#7A4E28",brown_12:"#6B4523",brown_13:"#5D3C1E",turquoise_20:"#52776C",turquoise_21:"#2C403A",turquoise_22:"#1E2C27",brown_17:"#D4CAC1",grey_6:"#A6A5A5",brown_19:"#917A66",aqua_19:"#70B4B7",aqua_18:"#94CFD2",aqua_13:"#0E7077",aqua_12:"#108188",aqua_11:"#12939A",aqua_10:"#13A4AB",aqua_17:"#C6E4E5",aqua_16:"#0F474A",aqua_15:"#0A545A",aqua_14:"#0B5F65"},u=l;e.default=u;var c=Object.keys(l).reduce((function(t,e){if(!e.includes("_"))return t;var r=e.split("_"),n=(0,o.default)(r,2),a=n[0],u=n[1];return s(s({},t),{},(0,i.default)({},a,s(s({},t[a]),{},(0,i.default)({},u,l[e]))))}),{});e.ColorsByTheme=c;e.Themes=["yellow","gold","amber","orange","brick","red","magenta","violet","purple","indigo","navy","blue","teal","aqua","turquoise","green","lime","olive","grey","stone","brown","dirt"]},function(t,e){t.exports=function(t){if(Array.isArray(t))return t},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e){t.exports=function(t,e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t)){var r=[],n=!0,i=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(n=(a=s.next()).done)&&(r.push(a.value),!e||r.length!==e);n=!0);}catch(t){i=!0,o=t}finally{try{n||null==s.return||s.return()}finally{if(i)throw o}}return r}},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e){t.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){var n=r(48),i=r(49),o=r(25),a=r(50);t.exports=function(t){return n(t)||i(t)||o(t)||a()},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){var n=r(26);t.exports=function(t){if(Array.isArray(t))return n(t)},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e){t.exports=function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e){t.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},t.exports.default=t.exports,t.exports.__esModule=!0},function(t,e,r){"use strict";r.r(e);e.default={schemeGroups:{sequential:["BuGn","BuPu","GnBu","OrRd","PuBu","PuBuGn","PuRd","RdPu","YlGn","YlGnBu","YlOrBr","YlOrRd"],singlehue:["Blues","Greens","Greys","Oranges","Purples","Reds"],diverging:["BrBG","PiYG","PRGn","PuOr","RdBu","RdGy","RdYlBu","RdYlGn","Spectral"],qualitative:["Accent","Dark2","Paired","Pastel1","Pastel2","Set1","Set2","Set3"]},YlGn:{3:["#f7fcb9","#addd8e","#31a354"],4:["#ffffcc","#c2e699","#78c679","#238443"],5:["#ffffcc","#c2e699","#78c679","#31a354","#006837"],6:["#ffffcc","#d9f0a3","#addd8e","#78c679","#31a354","#006837"],7:["#ffffcc","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#005a32"],8:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#005a32"],9:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"]},YlGnBu:{3:["#edf8b1","#7fcdbb","#2c7fb8"],4:["#ffffcc","#a1dab4","#41b6c4","#225ea8"],5:["#ffffcc","#a1dab4","#41b6c4","#2c7fb8","#253494"],6:["#ffffcc","#c7e9b4","#7fcdbb","#41b6c4","#2c7fb8","#253494"],7:["#ffffcc","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#0c2c84"],8:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#0c2c84"],9:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"]},GnBu:{3:["#e0f3db","#a8ddb5","#43a2ca"],4:["#f0f9e8","#bae4bc","#7bccc4","#2b8cbe"],5:["#f0f9e8","#bae4bc","#7bccc4","#43a2ca","#0868ac"],6:["#f0f9e8","#ccebc5","#a8ddb5","#7bccc4","#43a2ca","#0868ac"],7:["#f0f9e8","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#08589e"],8:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#08589e"],9:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"]},BuGn:{3:["#e5f5f9","#99d8c9","#2ca25f"],4:["#edf8fb","#b2e2e2","#66c2a4","#238b45"],5:["#edf8fb","#b2e2e2","#66c2a4","#2ca25f","#006d2c"],6:["#edf8fb","#ccece6","#99d8c9","#66c2a4","#2ca25f","#006d2c"],7:["#edf8fb","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#005824"],8:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#005824"],9:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"]},PuBuGn:{3:["#ece2f0","#a6bddb","#1c9099"],4:["#f6eff7","#bdc9e1","#67a9cf","#02818a"],5:["#f6eff7","#bdc9e1","#67a9cf","#1c9099","#016c59"],6:["#f6eff7","#d0d1e6","#a6bddb","#67a9cf","#1c9099","#016c59"],7:["#f6eff7","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016450"],8:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016450"],9:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"]},PuBu:{3:["#ece7f2","#a6bddb","#2b8cbe"],4:["#f1eef6","#bdc9e1","#74a9cf","#0570b0"],5:["#f1eef6","#bdc9e1","#74a9cf","#2b8cbe","#045a8d"],6:["#f1eef6","#d0d1e6","#a6bddb","#74a9cf","#2b8cbe","#045a8d"],7:["#f1eef6","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#034e7b"],8:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#034e7b"],9:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"]},BuPu:{3:["#e0ecf4","#9ebcda","#8856a7"],4:["#edf8fb","#b3cde3","#8c96c6","#88419d"],5:["#edf8fb","#b3cde3","#8c96c6","#8856a7","#810f7c"],6:["#edf8fb","#bfd3e6","#9ebcda","#8c96c6","#8856a7","#810f7c"],7:["#edf8fb","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#6e016b"],8:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#6e016b"],9:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"]},RdPu:{3:["#fde0dd","#fa9fb5","#c51b8a"],4:["#feebe2","#fbb4b9","#f768a1","#ae017e"],5:["#feebe2","#fbb4b9","#f768a1","#c51b8a","#7a0177"],6:["#feebe2","#fcc5c0","#fa9fb5","#f768a1","#c51b8a","#7a0177"],7:["#feebe2","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177"],8:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177"],9:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"]},PuRd:{3:["#e7e1ef","#c994c7","#dd1c77"],4:["#f1eef6","#d7b5d8","#df65b0","#ce1256"],5:["#f1eef6","#d7b5d8","#df65b0","#dd1c77","#980043"],6:["#f1eef6","#d4b9da","#c994c7","#df65b0","#dd1c77","#980043"],7:["#f1eef6","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#91003f"],8:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#91003f"],9:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"]},OrRd:{3:["#fee8c8","#fdbb84","#e34a33"],4:["#fef0d9","#fdcc8a","#fc8d59","#d7301f"],5:["#fef0d9","#fdcc8a","#fc8d59","#e34a33","#b30000"],6:["#fef0d9","#fdd49e","#fdbb84","#fc8d59","#e34a33","#b30000"],7:["#fef0d9","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#990000"],8:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#990000"],9:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"]},YlOrRd:{3:["#ffeda0","#feb24c","#f03b20"],4:["#ffffb2","#fecc5c","#fd8d3c","#e31a1c"],5:["#ffffb2","#fecc5c","#fd8d3c","#f03b20","#bd0026"],6:["#ffffb2","#fed976","#feb24c","#fd8d3c","#f03b20","#bd0026"],7:["#ffffb2","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#b10026"],8:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#b10026"],9:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"]},YlOrBr:{3:["#fff7bc","#fec44f","#d95f0e"],4:["#ffffd4","#fed98e","#fe9929","#cc4c02"],5:["#ffffd4","#fed98e","#fe9929","#d95f0e","#993404"],6:["#ffffd4","#fee391","#fec44f","#fe9929","#d95f0e","#993404"],7:["#ffffd4","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#8c2d04"],8:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#8c2d04"],9:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"]},Purples:{3:["#efedf5","#bcbddc","#756bb1"],4:["#f2f0f7","#cbc9e2","#9e9ac8","#6a51a3"],5:["#f2f0f7","#cbc9e2","#9e9ac8","#756bb1","#54278f"],6:["#f2f0f7","#dadaeb","#bcbddc","#9e9ac8","#756bb1","#54278f"],7:["#f2f0f7","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#4a1486"],8:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#4a1486"],9:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"]},Blues:{3:["#deebf7","#9ecae1","#3182bd"],4:["#eff3ff","#bdd7e7","#6baed6","#2171b5"],5:["#eff3ff","#bdd7e7","#6baed6","#3182bd","#08519c"],6:["#eff3ff","#c6dbef","#9ecae1","#6baed6","#3182bd","#08519c"],7:["#eff3ff","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#084594"],8:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#084594"],9:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"]},Greens:{3:["#e5f5e0","#a1d99b","#31a354"],4:["#edf8e9","#bae4b3","#74c476","#238b45"],5:["#edf8e9","#bae4b3","#74c476","#31a354","#006d2c"],6:["#edf8e9","#c7e9c0","#a1d99b","#74c476","#31a354","#006d2c"],7:["#edf8e9","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#005a32"],8:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#005a32"],9:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"]},Oranges:{3:["#fee6ce","#fdae6b","#e6550d"],4:["#feedde","#fdbe85","#fd8d3c","#d94701"],5:["#feedde","#fdbe85","#fd8d3c","#e6550d","#a63603"],6:["#feedde","#fdd0a2","#fdae6b","#fd8d3c","#e6550d","#a63603"],7:["#feedde","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#8c2d04"],8:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#8c2d04"],9:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"]},Reds:{3:["#fee0d2","#fc9272","#de2d26"],4:["#fee5d9","#fcae91","#fb6a4a","#cb181d"],5:["#fee5d9","#fcae91","#fb6a4a","#de2d26","#a50f15"],6:["#fee5d9","#fcbba1","#fc9272","#fb6a4a","#de2d26","#a50f15"],7:["#fee5d9","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#99000d"],8:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#99000d"],9:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"]},Greys:{3:["#f0f0f0","#bdbdbd","#636363"],4:["#f7f7f7","#cccccc","#969696","#525252"],5:["#f7f7f7","#cccccc","#969696","#636363","#252525"],6:["#f7f7f7","#d9d9d9","#bdbdbd","#969696","#636363","#252525"],7:["#f7f7f7","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525"],8:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525"],9:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"]},PuOr:{3:["#f1a340","#f7f7f7","#998ec3"],4:["#e66101","#fdb863","#b2abd2","#5e3c99"],5:["#e66101","#fdb863","#f7f7f7","#b2abd2","#5e3c99"],6:["#b35806","#f1a340","#fee0b6","#d8daeb","#998ec3","#542788"],7:["#b35806","#f1a340","#fee0b6","#f7f7f7","#d8daeb","#998ec3","#542788"],8:["#b35806","#e08214","#fdb863","#fee0b6","#d8daeb","#b2abd2","#8073ac","#542788"],9:["#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788"],10:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],11:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"]},BrBG:{3:["#d8b365","#f5f5f5","#5ab4ac"],4:["#a6611a","#dfc27d","#80cdc1","#018571"],5:["#a6611a","#dfc27d","#f5f5f5","#80cdc1","#018571"],6:["#8c510a","#d8b365","#f6e8c3","#c7eae5","#5ab4ac","#01665e"],7:["#8c510a","#d8b365","#f6e8c3","#f5f5f5","#c7eae5","#5ab4ac","#01665e"],8:["#8c510a","#bf812d","#dfc27d","#f6e8c3","#c7eae5","#80cdc1","#35978f","#01665e"],9:["#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e"],10:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],11:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"]},PRGn:{3:["#af8dc3","#f7f7f7","#7fbf7b"],4:["#7b3294","#c2a5cf","#a6dba0","#008837"],5:["#7b3294","#c2a5cf","#f7f7f7","#a6dba0","#008837"],6:["#762a83","#af8dc3","#e7d4e8","#d9f0d3","#7fbf7b","#1b7837"],7:["#762a83","#af8dc3","#e7d4e8","#f7f7f7","#d9f0d3","#7fbf7b","#1b7837"],8:["#762a83","#9970ab","#c2a5cf","#e7d4e8","#d9f0d3","#a6dba0","#5aae61","#1b7837"],9:["#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837"],10:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],11:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"]},PiYG:{3:["#e9a3c9","#f7f7f7","#a1d76a"],4:["#d01c8b","#f1b6da","#b8e186","#4dac26"],5:["#d01c8b","#f1b6da","#f7f7f7","#b8e186","#4dac26"],6:["#c51b7d","#e9a3c9","#fde0ef","#e6f5d0","#a1d76a","#4d9221"],7:["#c51b7d","#e9a3c9","#fde0ef","#f7f7f7","#e6f5d0","#a1d76a","#4d9221"],8:["#c51b7d","#de77ae","#f1b6da","#fde0ef","#e6f5d0","#b8e186","#7fbc41","#4d9221"],9:["#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221"],10:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],11:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"]},RdBu:{3:["#ef8a62","#f7f7f7","#67a9cf"],4:["#ca0020","#f4a582","#92c5de","#0571b0"],5:["#ca0020","#f4a582","#f7f7f7","#92c5de","#0571b0"],6:["#b2182b","#ef8a62","#fddbc7","#d1e5f0","#67a9cf","#2166ac"],7:["#b2182b","#ef8a62","#fddbc7","#f7f7f7","#d1e5f0","#67a9cf","#2166ac"],8:["#b2182b","#d6604d","#f4a582","#fddbc7","#d1e5f0","#92c5de","#4393c3","#2166ac"],9:["#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac"],10:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],11:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"]},RdGy:{3:["#ef8a62","#ffffff","#999999"],4:["#ca0020","#f4a582","#bababa","#404040"],5:["#ca0020","#f4a582","#ffffff","#bababa","#404040"],6:["#b2182b","#ef8a62","#fddbc7","#e0e0e0","#999999","#4d4d4d"],7:["#b2182b","#ef8a62","#fddbc7","#ffffff","#e0e0e0","#999999","#4d4d4d"],8:["#b2182b","#d6604d","#f4a582","#fddbc7","#e0e0e0","#bababa","#878787","#4d4d4d"],9:["#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d"],10:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],11:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"]},RdYlBu:{3:["#fc8d59","#ffffbf","#91bfdb"],4:["#d7191c","#fdae61","#abd9e9","#2c7bb6"],5:["#d7191c","#fdae61","#ffffbf","#abd9e9","#2c7bb6"],6:["#d73027","#fc8d59","#fee090","#e0f3f8","#91bfdb","#4575b4"],7:["#d73027","#fc8d59","#fee090","#ffffbf","#e0f3f8","#91bfdb","#4575b4"],8:["#d73027","#f46d43","#fdae61","#fee090","#e0f3f8","#abd9e9","#74add1","#4575b4"],9:["#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4"],10:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],11:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"]},Spectral:{3:["#fc8d59","#ffffbf","#99d594"],4:["#d7191c","#fdae61","#abdda4","#2b83ba"],5:["#d7191c","#fdae61","#ffffbf","#abdda4","#2b83ba"],6:["#d53e4f","#fc8d59","#fee08b","#e6f598","#99d594","#3288bd"],7:["#d53e4f","#fc8d59","#fee08b","#ffffbf","#e6f598","#99d594","#3288bd"],8:["#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd"],9:["#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd"],10:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],11:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"]},RdYlGn:{3:["#fc8d59","#ffffbf","#91cf60"],4:["#d7191c","#fdae61","#a6d96a","#1a9641"],5:["#d7191c","#fdae61","#ffffbf","#a6d96a","#1a9641"],6:["#d73027","#fc8d59","#fee08b","#d9ef8b","#91cf60","#1a9850"],7:["#d73027","#fc8d59","#fee08b","#ffffbf","#d9ef8b","#91cf60","#1a9850"],8:["#d73027","#f46d43","#fdae61","#fee08b","#d9ef8b","#a6d96a","#66bd63","#1a9850"],9:["#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850"],10:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],11:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"]},Accent:{3:["#7fc97f","#beaed4","#fdc086"],4:["#7fc97f","#beaed4","#fdc086","#ffff99"],5:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0"],6:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f"],7:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17"],8:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"]},Dark2:{3:["#1b9e77","#d95f02","#7570b3"],4:["#1b9e77","#d95f02","#7570b3","#e7298a"],5:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e"],6:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02"],7:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d"],8:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"]},Paired:{3:["#a6cee3","#1f78b4","#b2df8a"],4:["#a6cee3","#1f78b4","#b2df8a","#33a02c"],5:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99"],6:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c"],7:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f"],8:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00"],9:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6"],10:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a"],11:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99"],12:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"]},Pastel1:{3:["#fbb4ae","#b3cde3","#ccebc5"],4:["#fbb4ae","#b3cde3","#ccebc5","#decbe4"],5:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6"],6:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc"],7:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd"],8:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec"],9:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},Pastel2:{3:["#b3e2cd","#fdcdac","#cbd5e8"],4:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4"],5:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9"],6:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae"],7:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc"],8:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"]},Set1:{3:["#e41a1c","#377eb8","#4daf4a"],4:["#e41a1c","#377eb8","#4daf4a","#984ea3"],5:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00"],6:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33"],7:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628"],8:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf"],9:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"]},Set2:{3:["#66c2a5","#fc8d62","#8da0cb"],4:["#66c2a5","#fc8d62","#8da0cb","#e78ac3"],5:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854"],6:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f"],7:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494"],8:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"]},Set3:{3:["#8dd3c7","#ffffb3","#bebada"],4:["#8dd3c7","#ffffb3","#bebada","#fb8072"],5:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3"],6:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462"],7:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69"],8:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5"],9:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9"],10:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd"],11:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5"],12:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"]}}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"Editor",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(e,"EditorModes",{enumerable:!0,get:function(){return o.MODES}}),Object.defineProperty(e,"RenderTypes",{enumerable:!0,get:function(){return o.RENDER_TYPE}}),Object.defineProperty(e,"RenderStates",{enumerable:!0,get:function(){return o.RENDER_STATE}});var n,i=(n=r(53))&&n.__esModule?n:{default:n},o=r(15)},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(t,r):{};n.get||n.set?Object.defineProperty(e,r,n):e[r]=t[r]}return e.default=t,e}(r(1)),i=(r(19),r(70)),o=c(r(57)),a=c(r(60)),s=r(61),l=r(15),u=r(62);function c(t){return t&&t.__esModule?t:{default:t}}function p(t){return(p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function h(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function f(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){_(t,e,r[e])}))}return t}function d(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function m(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function g(t){return(g=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function y(t,e){return(y=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function v(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var b={mode:l.MODES.READ_ONLY,clickRadius:0,getEditHandleStyle:s.getEditHandleStyle,getFeatureStyle:s.getFeatureStyle,getFeatureShape:"circle",getEditHandleShape:"circle",onSelect:function(){}},x=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==p(e)&&"function"!=typeof e?v(t):e}(this,g(e).call(this,t)),_(v(v(r)),"_containerRef",void 0),_(v(v(r)),"_events",void 0),_(v(v(r)),"_context",void 0),_(v(v(r)),"_update",(function(t){t&&r.props.onUpdate(t.map((function(t){return t.toFeature()})))})),_(v(v(r)),"_updateRectangle",(function(t,e){var n=e.vertexIndex,i=e.lngLat,o=n,a=t.points[(o+2)%4];t.replacePoint(o,[i[0],i[1]]),t.replacePoint((o+1)%4,[i[0],a[1]]),t.replacePoint((o+3)%4,[a[0],i[1]]),r._update(r.state.features)})),_(v(v(r)),"_updateFeature",(function(t,e,n){switch(e){case"vertex":t.renderType===l.RENDER_TYPE.RECTANGLE?r._updateRectangle(t,n):(t.replacePoint(n.vertexIndex,[n.lngLat[0],n.lngLat[1]]),r._update(r.state.features));break;case"feature":var i=n.dx,o=n.dy;t.points=t.points.map((function(t){var e=r._project(t);return e?(e[0]+=i,e[1]+=o,r._unproject(e)):null})).filter(Boolean),r._update(r.state.features);break;case"Rectangle":r._updateRectangle(t,n)}})),_(v(v(r)),"_addPoint",(function(t,e,n){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(n=n||r._getSelectedFeature()){var o=r._unproject([t,e]);if(o){n.addPoint([o[0],o[1]]);var a=r.state.features||[];i&&a.push(n);var s=n.points&&n.points.length>=2,u=r.props,c=u.mode,p=u.onSelect;c===l.MODES.DRAW_POINT||c===l.MODES.DRAW_PATH&&s?(r._update(a),p({selectedFeatureId:n&&n.id})):r.setState({features:d(a),selectedFeatureId:n&&n.id})}}})),_(v(v(r)),"_clearCache",(function(){r.setState({selectedFeatureId:null,uncommittedLngLat:null,hoveredFeatureId:null,hoveredLngLat:null,hoveredVertexIndex:-1,draggingVertexIndex:-1,startDragPos:null,isDragging:!1,didDrag:!1})})),_(v(v(r)),"_closePath",(function(){var t=r._getSelectedFeature();t&&(t.closePath(),r._update(r.state.features))})),_(v(v(r)),"_addFeature",(function(t,e){var n=l.MODE_TO_GEOJSON_TYPE[t],i=l.MODE_TO_RENDER_TYPE[t],s=new a.default({id:(0,o.default)(),type:n,renderType:i});if(r._addPoint(e.x,e.y,s,!0),t===l.MODES.DRAW_RECTANGLE)for(var u=0;u<3;u++)r._addPoint(e.x,e.y,s,!1)})),_(v(v(r)),"_onEvent",(function(t,e,n){var i=r.props.mode;if(i!==l.MODES.READ_ONLY){for(var o=arguments.length,a=new Array(o>3?o-3:0),s=3;s<o;s++)a[s-3]=arguments[s];t.apply(void 0,[e].concat(a)),n&&e.stopImmediatePropagation()}})),_(v(v(r)),"_onMouseUp",(function(t){r.setState({isDragging:!1,didDrag:!1});var e=r.state.draggingVertexIndex;Number(e)>=0&&r.setState({draggingVertexIndex:-1})})),_(v(v(r)),"_onMouseDown",(function(t){var e=r._getEventPosition(t),n=e.x,i=e.y,o=(0,u.parseElemDataAttributes)(t.target);if(o&&o.type===l.ELEMENT_TYPE.VERTEX){var a=o.vertexIndex;r.setState({draggingVertexIndex:a,startDragPos:{x:n,y:i},isDragging:!0})}else r._matchesFeature(o,r._getSelectedFeature())&&r.setState({startDragPos:{x:n,y:i},isDragging:!0})})),_(v(v(r)),"_onMouseMove",(function(t){var e=(0,u.parseElemDataAttributes)(t.target)||{},n=e.vertexIndex,i=e.featureIndex,o=e.type,a=r.state,s=a.startDragPos,c=a.isDragging,p=a.didDrag,h=r.props.mode,f=r._getEventPosition(t),d=f.x,m=f.y,g=r._unproject([d,m]);if(c&&!p&&s){var y=d-s.x,v=m-s.y;y*y+v*v>5&&r.setState({didDrag:!0})}var _=r._getSelectedFeature(),b=-1!==l.DRAWING_MODES.indexOf(h),x=h===l.MODES.EDIT_VERTEX;if(_)if(p&&s){var w=Number(r.state.draggingVertexIndex);if(w>=0)r._updateFeature(_,"vertex",{vertexIndex:w,lngLat:g});else{var E=d-s.x,T=m-s.y;r.setState({startDragPos:{x:d,y:m}}),r._updateFeature(_,"feature",{dx:E,dy:T})}}else if(h===l.MODES.DRAW_RECTANGLE)r._updateFeature(_,"Rectangle",{vertexIndex:2,lngLat:g});else if(b)r.setState({uncommittedLngLat:g});else if(x)if(_.renderType!==l.RENDER_TYPE.LINE_STRING&&_.renderType!==l.RENDER_TYPE.POLYGON||o!==l.ELEMENT_TYPE.SEGMENT)r.setState({uncommittedLngLat:null});else{var A=null;g&&"number"==typeof n&&(A=r._getClosestPositionOnSegment(n,g,_)),r.setState({uncommittedLngLat:A})}var C=r.state,S=C.features,P=C.selectedFeatureId;if(P&&o===l.ELEMENT_TYPE.VERTEX&&"number"==typeof i){var I=S&&S[i];P===(I&&I.id)&&r.setState({hoveredVertexIndex:n})}else o!==l.ELEMENT_TYPE.VERTEX&&r.setState({hoveredVertexIndex:null});if(o===l.ELEMENT_TYPE.FEATURE&&"number"==typeof i){var D=S&&S[i];r.setState({hoveredFeatureId:D&&D.id})}else r.setState({hoveredFeatureId:null})})),_(v(v(r)),"_onClickFeature",(function(t,e){var n=e.featureIndex,i=r.state.features,o=i&&"number"==typeof n&&i[n];o&&r.props.onSelect({selectedFeatureId:o.id,sourceEvent:t})})),_(v(v(r)),"_onClickVertex",(function(t,e){var n=r.props.mode,i=e.operation;(i===l.OPERATIONS.INTERSECT||i===l.OPERATIONS.SET&&n===l.MODES.DRAW_RECTANGLE)&&(r._closePath(),r._clearCache())})),_(v(v(r)),"_onClickSegment",(function(t,e){var n=r._getSelectedFeature();if(n&&(n.renderType===l.RENDER_TYPE.POLYGON||n.renderType===l.RENDER_TYPE.LINE_STRING)&&e){var i=e.vertexIndex,o=r.state.uncommittedLngLat;if(!o&&"number"==typeof i){var a=r._getEventPosition(t),s=a.x,u=a.y;o=r._unproject([s,u]),o=r._getClosestPositionOnSegment(i,o,n)}if(o){var c=(i+1)%n.points.length;n.insertPoint(o,c),r._update(r.state.features)}r.setState({uncommittedLngLat:null,hoveredLngLat:null})}})),_(v(v(r)),"_onClick",(function(t){var e=r.props.mode,n=(0,u.parseElemDataAttributes)(t.target);if(n&&n.type===l.ELEMENT_TYPE.VERTEX)r._onClickVertex(t,n);else if(e===l.MODES.EDIT_VERTEX&&n&&n.type===l.ELEMENT_TYPE.SEGMENT)r._onClickSegment(t,n);else if(e!==l.MODES.SELECT_FEATURE&&e!==l.MODES.EDIT_VERTEX||!n||n.type!==l.ELEMENT_TYPE.FEATURE){var i=r._getSelectedFeature(),o=r._getEventPosition(t),a=o.x,s=o.y;switch(e){case l.MODES.EDIT_VERTEX:i&&r.props.onSelect({selectedFeatureId:null,sourceEvent:t});break;case l.MODES.DRAW_POINT:r._addFeature(e,{x:a,y:s});break;case l.MODES.DRAW_PATH:case l.MODES.DRAW_POLYGON:i&&i.isClosed?r._clearCache():i?r._addPoint(a,s,i):r._addFeature(e,{x:a,y:s});break;case l.MODES.DRAW_RECTANGLE:i&&i.isClosed?(r._clearCache(),r.props.onSelect({selectedFeatureId:null,sourceEvent:t})):r._addFeature(e,{x:a,y:s})}}else r._onClickFeature(t,n)})),_(v(v(r)),"_onPan",(function(t){var e=(0,u.parseElemDataAttributes)(t.target),n=e&&e.type;(n===l.ELEMENT_TYPE.VERTEX||n===l.ELEMENT_TYPE.SEGMENT||r.state.isDragging||null!==r.state.uncommittedLngLat)&&t.stopImmediatePropagation()})),_(v(v(r)),"_project",(function(t){return r._context&&r._context.viewport&&r._context.viewport.project(t)})),_(v(v(r)),"_unproject",(function(t){return r._context&&r._context.viewport&&r._context.viewport.unproject(t)})),_(v(v(r)),"_matchesFeature",(function(t,e){if(!t||t.type!==l.ELEMENT_TYPE.FEATURE||!e)return!1;var n=t.featureIndex,i=r.props.features,o=i&&i[n];return o&&e.id===o.id})),_(v(v(r)),"_getClosestPositionOnSegment",(function(t,e,r){var n=r&&r.points;if(!n||!n.length)return null;var i=n[t],o=n[(t+1)%n.length];return(0,u.findClosestPointOnLineSegment)(i,o,e)})),_(v(v(r)),"_getEventPosition",(function(t){var e=t.offsetCenter,r=e.x,n=e.y;return{x:Number(r),y:Number(n)}})),_(v(v(r)),"_getSelectedFeature",(function(){var t=r.state,e=t.features,n=t.selectedFeatureId;return e&&e.find((function(t){return t.id===n}))})),_(v(v(r)),"_getEditHandleState",(function(t,e){var n=r.props.mode,i=r.state,o=i.draggingVertexIndex,a=i.hoveredVertexIndex,s=r._getSelectedFeature(),u=t===o||s&&s.renderType===l.RENDER_TYPE.POINT,c=n===l.MODES.DRAW_POLYGON&&0===a&&-1===t;if(e)return e;if(c)return l.RENDER_STATE.CLOSING;if(u)return l.RENDER_STATE.SELECTED;switch(t){case a:return l.RENDER_STATE.HOVERED;case"uncommitted":return l.RENDER_STATE.UNCOMMITTED;default:return l.RENDER_STATE.INACTIVE}})),_(v(v(r)),"_getFeatureRenderState",(function(t,e){var n=r.state,i=n.selectedFeatureId,o=n.hoveredFeatureId;if(e)return e;switch(t){case i:return l.RENDER_STATE.SELECTED;case o:return l.RENDER_STATE.HOVERED;case"uncommitted":return l.RENDER_STATE.UNCOMMITTED;default:return l.RENDER_STATE.INACTIVE}})),_(v(v(r)),"_renderVertex",(function(t,e,i,o,a,u){var c=r._project(t);if(!c)return null;var p=r.props.clickRadius,h="".concat(l.ELEMENT_TYPE.VERTEX,".").concat(e,".").concat(i,".").concat(o);switch(u){case"circle":return n.default.createElement("g",{key:h,transform:"translate(".concat(c[0],", ").concat(c[1],")")},n.default.createElement("circle",{"data-type":l.ELEMENT_TYPE.VERTEX,"data-feature-index":e,"data-vertex-index":i,"data-operation":o,key:"".concat(h,".hidden"),style:f({},a,s.HIDDEN_CLICKABLE_STYLE,{stroke:"none"}),cx:0,cy:0,r:p}),n.default.createElement("circle",{"data-type":l.ELEMENT_TYPE.VERTEX,"data-feature-index":e,"data-vertex-index":i,"data-operation":o,key:h,style:a,cx:0,cy:0}));case"rect":return n.default.createElement("g",{key:"vertex.".concat(i),transform:"translate(".concat(c[0],", ").concat(c[1],")")},n.default.createElement("rect",{"data-type":l.ELEMENT_TYPE.VERTEX,"data-feature-index":e,"data-vertex-index":i,"data-operation":o,key:"".concat(h,".hidden"),style:f({},a,s.HIDDEN_CLICKABLE_STYLE,{width:p,height:p})}),n.default.createElement("rect",{"data-type":l.ELEMENT_TYPE.VERTEX,"data-feature-index":e,"data-vertex-index":i,"data-operation":o,key:h,style:a}));default:return null}})),_(v(v(r)),"_renderSegment",(function(t,e,i,o){var a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},s=r.props.clickRadius,u=r._getProjectedData([i,o],l.RENDER_TYPE.LINE_STRING),c=a.radius,p=h(a,["radius"]),d="".concat(l.ELEMENT_TYPE.SEGMENT,".").concat(t,".").concat(e);return n.default.createElement("g",{key:d},n.default.createElement("path",{"data-type":l.ELEMENT_TYPE.SEGMENT,"data-feature-index":t,"data-vertex-index":e,key:"".concat(d,".hidden"),style:f({},p,{strokeWidth:s||c,opacity:0}),d:u}),n.default.createElement("path",{"data-type":l.ELEMENT_TYPE.SEGMENT,"data-feature-index":t,"data-vertex-index":e,key:d,style:p,d:u}))})),_(v(v(r)),"_renderCommittedStroke",(function(t,e,i){var o=e.points,a=e.isClosed,s=e.renderType;if(!o||o.length<2||s===l.RENDER_TYPE.RECTANGLE&&!a)return null;for(var u=[],c=0;c<o.length-1;c++)u.push(r._renderSegment(t,c,o[c],o[c+1],i));if(a){var p=o.length-1;u.push(r._renderSegment(t,p,o[p],o[0],i))}return n.default.createElement("g",{key:"committed group"},u)})),_(v(v(r)),"_renderUncommittedStrokes",(function(t,e,n){var i=e.points,o=e.isClosed,a=e.renderType,s=r.props.mode,u=r.state.uncommittedLngLat,c=l.DRAWING_MODES.find((function(t){return t===s}));if(!i||o||!c)return null;var p=[];if(a===l.RENDER_TYPE.RECTANGLE){for(var h=0;h<i.length-1;h++)p.push(r._renderSegment(t,h,i[h],i[h+1],n));4===i.length&&p.push(r._renderSegment(t,3,i[3],i[0],n))}return u?(p.push(r._renderSegment(t,i.length-1,i.slice(-1)[0],u,n)),p.filter(Boolean)):p.length?p:null})),_(v(v(r)),"_renderClosingStroke",(function(t,e,n){var i=e.points,o=e.isClosed,a=r.props.mode,s=r.state.uncommittedLngLat;return s&&a===l.MODES.DRAW_POLYGON&&i.length>2&&!o?r._renderSegment(t,"uncommitted-close",s,i[0],n):null})),_(v(v(r)),"_renderFill",(function(t,e,i){var o=r.props.mode,a=l.DRAWING_MODES.find((function(t){return t===o})),s=e.points,u=e.renderType,c=e.isClosed;if(u!==l.RENDER_TYPE.POLYGON&&u!==l.RENDER_TYPE.RECTANGLE)return null;var p=r.state.uncommittedLngLat,h=s;p&&a&&(h=d(s).concat([p]));var m=r._getProjectedData(h,u,c);return n.default.createElement("path",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":t,key:"".concat(l.ELEMENT_TYPE.FEATURE,".").concat(t,".fill"),style:f({},i,{stroke:"none"}),d:m})})),_(v(v(r)),"_renderCurrentPath",(function(t,e){var n=t.points,i=t.renderType;if(!n||!n.length||i===l.RENDER_TYPE.POINT)return null;var o=r.props.getFeatureStyle,a=t.toFeature(),s=o({feature:a,state:l.RENDER_STATE.SELECTED}),u=o({feature:a,state:l.RENDER_STATE.UNCOMMITTED}),c=o({feature:a,state:l.RENDER_STATE.CLOSING}),p=r._renderCommittedStroke(e,t,s),h=r._renderUncommittedStrokes(e,t,u)||[],f=r._renderClosingStroke(e,t,c);return[r._renderFill(e,t,u),p].concat(d(h),[f]).filter(Boolean)})),_(v(v(r)),"_renderCommittedVertices",(function(t,e,n){for(var i=r.props,o=i.mode,a=i.getEditHandleStyle,s=i.getEditHandleShape,u=e.isClosed,c=e.points,p=[],h=0;h<c.length;h++){var f=c[h],d=l.OPERATIONS.SET,m=a({feature:n,index:h,state:r._getEditHandleState(h)}),g="function"==typeof s?s({feature:n,index:h,state:r._getEditHandleState(h)}):s;u||o===l.MODES.DRAW_POLYGON&&0===h&&c.length>2&&(d=l.OPERATIONS.INTERSECT),p.push(r._renderVertex(f,t,h,d,m,g))}return p})),_(v(v(r)),"_renderUncommittedVertex",(function(t,e,n){var i=r.props,o=i.getEditHandleStyle,a=i.getEditHandleShape,s=r.state,u=s.selectedFeatureId,c=s.uncommittedLngLat,p=null;if(u===e.id&&c){var h=o({feature:n,index:"uncommitted",state:r._getEditHandleState(-1,l.RENDER_STATE.UNCOMMITTED)}),d="function"==typeof a?a({feature:n,index:null,state:r._getEditHandleState(-1)}):a;p=r._renderVertex(c,t,"uncommitted",l.OPERATIONS.INSERT,f({},h,{pointerEvents:"none"}),d)}return p})),_(v(v(r)),"_renderCurrentVertices",(function(t,e){var i=t.points;if(!i||!i.length)return null;var o=t.toFeature(),a=r._renderCommittedVertices(e,t,o),s=r._renderUncommittedVertex(e,t,o);return n.default.createElement("g",{key:"edit-handles"},a,s)})),_(v(v(r)),"_renderCurrent",(function(){var t=r.state.features,e=r._getSelectedFeature();if(!t||!e||!e.points)return null;var i=r.props.mode,o=t.findIndex((function(t){return t.id===e.id}));return n.default.createElement("g",{key:"feature current",style:i===l.MODES.READ_ONLY||i===l.MODES.SELECT_FEATURE?l.STATIC_STYLE:null},r._renderCurrentPath(e,o),r._renderCurrentVertices(e,o))})),_(v(v(r)),"_renderFeature",(function(t,e){if(t===r._getSelectedFeature())return null;var i=r.props.clickRadius,o=t.id,a=t.points,u=t.renderType,c=t.isClosed;if(!a||!a.length)return null;var p=r._getProjectedData(a,u,c);if(!p)return null;var h=t.toFeature(),d=r._getFeatureRenderState(o),m=r.props,g=m.getFeatureStyle,y=m.getFeatureShape,v=g({feature:h,state:d}),_="function"==typeof y?y({feature:h,state:d}):y,b="".concat(l.ELEMENT_TYPE.FEATURE,".").concat(e);switch(u){case l.RENDER_TYPE.POINT:return"rect"===_?n.default.createElement("g",{key:b,transform:"translate(".concat(p[0][0],", ").concat(p[0][1],")")},n.default.createElement("rect",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:"".concat(b,".hidden"),style:f({},v,s.HIDDEN_CLICKABLE_STYLE,{width:i,height:i})}),n.default.createElement("rect",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:b,style:v})):n.default.createElement("g",{key:b,transform:"translate(".concat(p[0][0],", ").concat(p[0][1],")")},n.default.createElement("circle",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:"".concat(b,".hidden"),style:f({},v,{opacity:0}),cx:0,cy:0,r:i}),n.default.createElement("circle",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:"feature.".concat(e),style:v,cx:0,cy:0}));case l.RENDER_TYPE.LINE_STRING:return n.default.createElement("g",{key:b},n.default.createElement("path",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:"".concat(b,".hidden"),style:f({},v,{strokeWidth:i,opacity:0}),d:p}),n.default.createElement("path",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:b,style:v,d:p}));case"Polygon":case"Rectangle":return n.default.createElement("path",{"data-type":l.ELEMENT_TYPE.FEATURE,"data-feature-index":e,key:b,style:v,d:p});default:return null}})),_(v(v(r)),"_renderFeatures",(function(){var t=r.state.features;return t&&t.map(r._renderFeature)})),_(v(v(r)),"_renderCanvas",(function(){var t=r.state,e=t.selectedFeatureId,i=t.features;return n.default.createElement("svg",{key:"draw-canvas",width:"100%",height:"100%"},i&&i.length>0&&n.default.createElement("g",{key:"feature-group"},r._renderFeatures()),e&&r._renderCurrent())})),_(v(v(r)),"_renderEditor",(function(){var t=r._context&&r._context.viewport||{},e=r.props.style,i=t.width,o=t.height;return n.default.createElement("div",{id:"editor",style:f({width:i,height:o},e),ref:function(t){r._containerRef=t}},r._renderCanvas())})),r.state={features:t.features?t.features.map((function(t){return a.default.fromFeature(t)})).filter(Boolean):null,selectedFeatureId:-1,hoveredFeatureId:null,hoveredLngLat:null,hoveredVertexIndex:-1,uncommittedLngLat:null,draggingVertexIndex:-1,startDragPos:null,isDragging:!1,didDrag:!1},r._containerRef=null,r._events={},r._context=null,r}var r,c,b;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&y(t,e)}(e,t),r=e,(c=[{key:"componentDidMount",value:function(){this.props.mode&&this.props.mode!==l.MODES.READ_ONLY&&this._setupEvents()}},{key:"componentWillReceiveProps",value:function(t){this.props.mode!==t.mode&&(t.mode&&t.mode!==l.MODES.READ_ONLY||this._removeEvents(),this.props.mode&&this.props.mode!==l.MODES.READ_ONLY||this._setupEvents()),this.props.mode===t.mode&&this.props.features===t.features||this.setState({features:t.features&&t.features.map((function(t){return a.default.fromFeature(t)})).filter(Boolean)}),this.props.mode===t.mode&&this.props.selectedFeatureId===t.selectedFeatureId||(this._clearCache(),this.setState({selectedFeatureId:t.selectedFeatureId}))}},{key:"componentWillUnmount",value:function(){this._removeEvents()}},{key:"_setupEvents",value:function(){var t=this,e=this._containerRef;e&&this._context&&this._context.eventManager&&(this._events={anyclick:function(e){return t._onEvent(t._onClick,e,!0)},click:function(t){return t.stopImmediatePropagation()},pointermove:function(e){return t._onEvent(t._onMouseMove,e,!0)},pointerdown:function(e){return t._onEvent(t._onMouseDown,e,!0)},pointerup:function(e){return t._onEvent(t._onMouseUp,e,!0)},panmove:function(e){return t._onEvent(t._onPan,e,!1)},panstart:function(e){return t._onEvent(t._onPan,e,!1)},panend:function(e){return t._onEvent(t._onPan,e,!1)}},this._context.eventManager.on(this._events,e))}},{key:"_removeEvents",value:function(){this._context&&this._context.eventManager&&this._events&&(this._context.eventManager.off(this._events),this._events=null)}},{key:"_getProjectedData",value:function(t,e){var r=this,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(0===t.length)return"";var i=t.map((function(t){return r._project(t)}));switch(e){case l.RENDER_TYPE.POINT:return i;case l.RENDER_TYPE.LINE_STRING:case l.RENDER_TYPE.POLYGON:case l.RENDER_TYPE.RECTANGLE:var o=i.map((function(t){return"".concat(t[0],",").concat(t[1])})).join("L");return"M ".concat(o," ").concat(n?"z":"");default:return null}}},{key:"render",value:function(){var t=this;return n.default.createElement(i._MapContext.Consumer,null,(function(e){t._context=e;var r=e&&e.viewport;return!r||r.height<=0||r.width<=0?null:t._renderEditor()}))}}])&&m(r.prototype,c),b&&m(r,b),e}(n.PureComponent);e.default=x,_(x,"defaultProps",b)},function(t,e,r){"use strict";var n=r(55);function i(){}function o(){}o.resetWarningCache=i,t.exports=function(){function t(t,e,r,i,o,a){if(a!==n){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function e(){return t}t.isRequired=t;var r={array:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:o,resetWarningCache:i};return r.PropTypes=r,r}},function(t,e,r){"use strict";t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(t,e){var r,n,i=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(r===setTimeout)return setTimeout(t,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(t,0);try{return r(t,0)}catch(e){try{return r.call(null,t,0)}catch(e){return r.call(this,t,0)}}}!function(){try{r="function"==typeof setTimeout?setTimeout:o}catch(t){r=o}try{n="function"==typeof clearTimeout?clearTimeout:a}catch(t){n=a}}();var l,u=[],c=!1,p=-1;function h(){c&&l&&(c=!1,l.length?u=l.concat(u):p=-1,u.length&&f())}function f(){if(!c){var t=s(h);c=!0;for(var e=u.length;e;){for(l=u,u=[];++p<e;)l&&l[p].run();p=-1,e=u.length}l=null,c=!1,function(t){if(n===clearTimeout)return clearTimeout(t);if((n===a||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(t);try{n(t)}catch(e){try{return n.call(null,t)}catch(e){return n.call(this,t)}}}(t)}}function d(t,e){this.fun=t,this.array=e}function m(){}i.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];u.push(new d(t,e)),1!==u.length||c||s(f)},d.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=m,i.addListener=m,i.once=m,i.off=m,i.removeListener=m,i.removeAllListeners=m,i.emit=m,i.prependListener=m,i.prependOnceListener=m,i.listeners=function(t){return[]},i.binding=function(t){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(t){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(t,e,r){var n=r(58),i=r(59),o=i;o.v1=n,o.v4=i,t.exports=o},function(t,e,r){var n,i,o=r(32),a=r(33),s=0,l=0;t.exports=function(t,e,r){var u=e&&r||0,c=e||[],p=(t=t||{}).node||n,h=void 0!==t.clockseq?t.clockseq:i;if(null==p||null==h){var f=o();null==p&&(p=n=[1|f[0],f[1],f[2],f[3],f[4],f[5]]),null==h&&(h=i=16383&(f[6]<<8|f[7]))}var d=void 0!==t.msecs?t.msecs:(new Date).getTime(),m=void 0!==t.nsecs?t.nsecs:l+1,g=d-s+(m-l)/1e4;if(g<0&&void 0===t.clockseq&&(h=h+1&16383),(g<0||d>s)&&void 0===t.nsecs&&(m=0),m>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");s=d,l=m,i=h;var y=(1e4*(268435455&(d+=122192928e5))+m)%4294967296;c[u++]=y>>>24&255,c[u++]=y>>>16&255,c[u++]=y>>>8&255,c[u++]=255&y;var v=d/4294967296*1e4&268435455;c[u++]=v>>>8&255,c[u++]=255&v,c[u++]=v>>>24&15|16,c[u++]=v>>>16&255,c[u++]=h>>>8|128,c[u++]=255&h;for(var _=0;_<6;++_)c[u+_]=p[_];return e||a(c)}},function(t,e,r){var n=r(32),i=r(33);t.exports=function(t,e,r){var o=e&&r||0;"string"==typeof t&&(e="binary"===t?new Array(16):null,t=null);var a=(t=t||{}).random||(t.rng||n)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,e)for(var s=0;s<16;++s)e[o+s]=a[s];return e||i(a)}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(15);function i(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function o(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){u(t,e,r[e])}))}return t}function a(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function l(t,e,r){return e&&s(t.prototype,e),r&&s(t,r),t}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var c=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),u(this,"id",void 0),u(this,"type",void 0),u(this,"renderType",void 0),u(this,"isClosed",!1),u(this,"points",void 0),u(this,"otherProps",void 0),this.id=e.id,this.type=e.type,this.renderType=e.renderType,this.points=e.points||[],this.isClosed=e.isClosed,this.otherProps=e.otherProps}return l(t,null,[{key:"fromFeature",value:function(e){var r=e.id,i=e.geometry,o=i.coordinates,s=i.type,l=e.properties,u=l.renderType,c=a(l,["renderType"]);switch(s){case n.GEOJSON_TYPE.POINT:return new t({id:r,type:s,renderType:u,points:[o],otherProps:c});case n.GEOJSON_TYPE.LINE_STRING:return new t({id:r,type:s,renderType:u,points:o,otherProps:c});case n.GEOJSON_TYPE.POLYGON:return new t({id:r,type:s,renderType:u,points:o[0]&&o[0].slice(0,-1),isClosed:!0,otherProps:c});default:return null}}}]),l(t,[{key:"addPoint",value:function(t){return this.points.push(t),!0}},{key:"insertPoint",value:function(t,e){this.points.splice(e,0,t)}},{key:"getBoundingBox",value:function(){return this.points&&this.points.length?this.points.reduce((function(t,e){return t.xmin=Math.min(e[0],t.xmin),t.xmax=Math.min(e[0],t.xmax),t.ymin=Math.min(e[1],t.ymin),t.ymax=Math.min(e[1],t.ymax),t}),{xmin:1/0,xmax:-1/0,ymin:1/0,ymax:-1/0}):null}},{key:"removePoint",value:function(t){var e=this.points;return t>=0&&t<e.length&&(e.splice(t,1),e.length<3&&(this.isClosed=!1),!0)}},{key:"replacePoint",value:function(t,e){var r=this.points;return t>=0&&t<r.length&&(r[t]=e,!0)}},{key:"closePath",value:function(){return this.points.length>=3&&!this.isClosed&&(this.isClosed=!0,!0)}},{key:"toFeature",value:function(){var t=this.id,e=this.points,r=this.isClosed,a=this.renderType,s=this.otherProps;return e.length<2?{type:"Feature",geometry:{type:n.GEOJSON_TYPE.POINT,coordinates:e[0]},properties:o({renderType:a},s),id:t}:e.length<3||!r?{type:"Feature",geometry:{type:n.GEOJSON_TYPE.LINE_STRING,coordinates:e},properties:o({renderType:a,bbox:this.getBoundingBox()},s),id:t}:{type:"Feature",geometry:{type:n.GEOJSON_TYPE.POLYGON,coordinates:[i(e).concat([e[0]])]},properties:o({renderType:a,isClosed:r,bbox:this.getBoundingBox()},s),id:t}}}]),t}();e.default=c},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getFeatureStyle=function(t){var e=t.feature,r=t.state,i={stroke:r===n.RENDER_STATE.SELECTED||r===n.RENDER_STATE.HOVERED?"#7ac943":r===n.RENDER_STATE.UNCOMMITTED||r===n.RENDER_STATE.CLOSING?"#a9a9a9":"#000",strokeWidth:2,fill:r===n.RENDER_STATE.INACTIVE?"#333333":r===n.RENDER_STATE.HOVERED?"#7ac943":r===n.RENDER_STATE.SELECTED?"#ffff00":r===n.RENDER_STATE.UNCOMMITTED||r===n.RENDER_STATE.CLOSING?"#a9a9a9":"#000000",fillOpacity:r===n.RENDER_STATE.INACTIVE?.1:r===n.RENDER_STATE.SELECTED?.7:r===n.RENDER_STATE.HOVERED?.5:r===n.RENDER_STATE.UNCOMMITTED||r===n.RENDER_STATE.CLOSING?.3:1};switch(e.properties?e.properties.renderType:e.renderType){case n.RENDER_TYPE.POINT:i.r=8;break;case n.RENDER_TYPE.LINE_STRING:i.fill="none";break;case n.RENDER_TYPE.POLYGON:r===n.RENDER_STATE.CLOSING&&(i.strokeDasharray="4,2");break;case n.RENDER_TYPE.RECTANGLE:r===n.RENDER_STATE.UNCOMMITTED&&(i.strokeDasharray="4,2")}return i},e.getEditHandleStyle=function(t){var e=t.feature,r=(t.index,t.state),a={fill:r===n.RENDER_STATE.INACTIVE?"#ffffff":r===n.RENDER_STATE.SELECTED||r===n.RENDER_STATE.CLOSING?"#ffff00":r===n.RENDER_STATE.HOVERED?"#7ac943":r===n.RENDER_STATE.UNCOMMITTED?"#a9a9a9":"#000000",fillOpacity:r===n.RENDER_STATE.INACTIVE||r===n.RENDER_STATE.HOVERED?1:r===n.RENDER_STATE.SELECTED||r===n.RENDER_STATE.CLOSING?.8:r===n.RENDER_STATE.UNCOMMITTED?.3:1,stroke:r===n.RENDER_STATE.SELECTED||r===n.RENDER_STATE.HOVERED||r===n.RENDER_STATE.CLOSING?"#7ac943":"#000",strokeWidth:r===n.RENDER_STATE.SELECTED||r===n.RENDER_STATE.CLOSING?4:2,r:8};switch(e.properties?e.properties.renderType:e.renderType){case n.RENDER_TYPE.POINT:a.fill=r===n.RENDER_STATE.INACTIVE?"#333333":r===n.RENDER_STATE.SELECTED?"#ffff00":r===n.RENDER_STATE.HOVERED?"#7ac943":r===n.RENDER_STATE.UNCOMMITTED?"none":"#000000",a.stroke=r===n.RENDER_STATE.SELECTED?"#7ac943":r===n.RENDER_STATE.UNCOMMITTED?"none":"#000";break;case n.RENDER_TYPE.LINE_STRING:case n.RENDER_TYPE.POLYGON:case n.RENDER_TYPE.RECTANGLE:r===n.RENDER_STATE.CLOSING?Object.assign(a,o):Object.assign(a,i)}return a},e.HIDDEN_CLICKABLE_STYLE=void 0;var n=r(15),i={x:-6,y:-6,height:12,width:12},o={x:-10,y:-10,height:20,width:20};e.HIDDEN_CLICKABLE_STYLE={fill:"#000",opacity:0}},function(t,e,r){"use strict";function n(t,e,r){var n=[Math.min(t[0],e[0]),Math.max(t[0],e[0]),Math.min(t[1],e[1]),Math.max(t[1],e[1])];return r[0]>=n[0]&&r[0]<=n[1]&&r[1]>=n[2]&&r[1]<=n[3]}function i(t){return!Array.isArray(t)&&!isNaN(parseFloat(t))&&isFinite(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.findClosestPointOnLineSegment=function(t,e,r){var i=(e[1]-t[1])/(e[0]-t[0]),o=t[1]-i*t[0];if(!isFinite(i)){var a=[t[0],r[1]];return n(t,e,a)?a:null}if(r[0]*i+o-r[1]==0)return n(t,e,r)?r:null;var s=(i*r[1]+r[0]-i*o)/(i*i+1),l=i*s+o;return n(t,e,[s,l])?[s,l]:null},e.isNumeric=i,e.parseElemDataAttributes=function(t){var e=t&&t.dataset;if(!e)return null;var r=e.featureIndex,n=e.vertexIndex;return{type:e.type,operation:e.operation,featureIndex:i(r)?Number(r):void 0,vertexIndex:i(n)?Number(n):void 0}}},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"DEFAULT_COLOR_RANGE",{enumerable:!0,get:function(){return o.DEFAULT_COLOR_RANGE}}),e.EDITOR_AVAILABLE_LAYERS=e.LAYER_TYPES=e.LAYER_TEXT_CONFIGS=e.LAYER_VIS_CONFIGS=e.DEFAULT_COLOR_UI=e.UNKNOWN_COLOR_KEY=e.DEFAULT_CUSTOM_PALETTE=e.DEFAULT_TEXT_LABEL=e.DEFAULT_LAYER_LABEL=e.DEFAULT_HIGHLIGHT_COLOR=e.DEFAULT_LAYER_OPACITY=e.PROPERTY_GROUPS=void 0;var i=n(r(30)),o=r(27),a=r(29),s=(0,i.default)({color:null,stroke:null,radius:null,height:null,angle:null,cell:null,precision:null,display:null});e.PROPERTY_GROUPS=s;e.DEFAULT_LAYER_OPACITY=.8;e.DEFAULT_HIGHLIGHT_COLOR=[252,242,26,255];e.DEFAULT_LAYER_LABEL="new layer";e.DEFAULT_TEXT_LABEL={field:null,color:[255,255,255],size:18,offset:[0,0],anchor:"start",alignment:"center"};var l={name:"color.customPalette",type:"custom",category:"Custom",colors:[]};e.DEFAULT_CUSTOM_PALETTE=l;e.UNKNOWN_COLOR_KEY="__unknownColor__";var u={customPalette:l,showSketcher:!1,showDropdown:!1,colorRangeConfig:{type:"all",steps:6,reversed:!1,custom:!1}};e.DEFAULT_COLOR_UI=u;var c={thickness:{type:"number",defaultValue:2,label:"layerVisConfigs.strokeWidth",isRanged:!1,range:[0,100],step:.1,group:s.stroke,property:"thickness",allowCustomValue:!0},strokeWidthRange:{type:"number",defaultValue:[0,10],label:"layerVisConfigs.strokeWidthRange",isRanged:!0,range:[0,200],step:.1,group:s.stroke,property:"sizeRange",allowCustomValue:!0},trailLength:{type:"number",defaultValue:180,label:"layerVisConfigs.strokeWidth",isRanged:!1,range:[1,1e3],step:1,group:s.stroke,property:"trailLength",allowCustomValue:!0},radius:{type:"number",defaultValue:10,label:"layerVisConfigs.radius",isRanged:!1,range:[0,100],step:.1,group:s.radius,property:"radius",allowCustomValue:!0},fixedRadius:{defaultValue:!1,type:"boolean",label:"layerVisConfigs.fixedRadius",description:"layerVisConfigs.fixedRadiusDescription",group:s.radius,property:"fixedRadius"},radiusRange:{type:"number",defaultValue:[0,50],isRanged:!0,range:[0,500],step:.1,label:"layerVisConfigs.radiusRange",group:s.radius,property:"radiusRange",allowCustomValue:!0},clusterRadius:{type:"number",label:"layerVisConfigs.clusterRadius",defaultValue:40,isRanged:!1,range:[1,500],step:.1,group:s.radius,property:"clusterRadius",allowCustomValue:!0},clusterRadiusRange:{type:"number",label:"layerVisConfigs.radiusRangePixels",defaultValue:[1,40],isRanged:!0,range:[1,150],step:.1,group:s.radius,property:"radiusRange",allowCustomValue:!0},opacity:{type:"number",defaultValue:.8,label:"layerVisConfigs.opacity",isRanged:!1,range:[0,1],step:.01,group:s.color,property:"opacity",allowCustomValue:!1},coverage:{type:"number",defaultValue:1,label:"layerVisConfigs.coverage",isRanged:!1,range:[0,1],step:.01,group:s.cell,property:"coverage",allowCustomValue:!1},outline:{type:"boolean",defaultValue:!1,label:"layer.outline",group:s.display,property:"outline"},colorRange:{type:"color-range-select",defaultValue:o.DEFAULT_COLOR_RANGE,label:"layerVisConfigs.colorRange",group:s.color,property:"colorRange"},strokeColorRange:{type:"color-range-select",defaultValue:o.DEFAULT_COLOR_RANGE,label:"layerVisConfigs.strokeColorRange",group:s.color,property:"strokeColorRange"},targetColor:{type:"color-select",label:"layerVisConfigs.targetColor",defaultValue:null,group:s.color,property:"targetColor"},strokeColor:{type:"color-select",label:"layerVisConfigs.strokeColor",defaultValue:null,group:s.color,property:"strokeColor"},colorAggregation:{type:"select",defaultValue:a.AGGREGATION_TYPES.average,label:"layerVisConfigs.colorAggregation",options:Object.keys(a.AGGREGATION_TYPES),group:s.color,property:"colorAggregation",condition:function(t){return Boolean(t.colorField)}},sizeAggregation:{type:"select",defaultValue:a.AGGREGATION_TYPES.average,label:"layerVisConfigs.heightAggregation",options:Object.keys(a.AGGREGATION_TYPES),group:s.height,property:"sizeAggregation",condition:function(t){return Boolean(t.sizeField)}},percentile:{type:"number",defaultValue:[0,100],label:function(t){return"Filter by ".concat(t.colorField?"".concat(t.visConfig.colorAggregation," ").concat(t.colorField.name):"count"," percentile")},isRanged:!0,range:[0,100],step:.01,group:s.color,property:"percentile",condition:function(t){return"ordinal"!==t.colorScale},allowCustomValue:!1},elevationPercentile:{type:"number",defaultValue:[0,100],label:function(t){return"Filter by ".concat(t.sizeField?"".concat(t.visConfig.sizeAggregation," ").concat(t.sizeField.name):"count"," percentile")},isRanged:!0,range:[0,100],step:.01,group:s.height,property:"elevationPercentile",condition:function(t){return Boolean(t.visConfig.enable3d&&(t.colorField||t.sizeField))},allowCustomValue:!1},resolution:{type:"number",defaultValue:8,label:"layerVisConfigs.resolution",isRanged:!1,range:[0,13],step:1,group:s.cell,property:"resolution",allowCustomValue:!0},sizeScale:{type:"number",defaultValue:10,label:"layerVisConfigs.sizeScale",isRanged:!1,range:[1,1e3],step:1,group:s.stroke,property:"sizeScale",allowCustomValue:!0},angle:{type:"number",label:"layerVisConfigs.angle",defaultValue:0,isRanged:!1,range:[0,360],group:s.angle,step:1,property:"angle",allowCustomValue:!0},worldUnitSize:{type:"number",defaultValue:1,label:"layerVisConfigs.worldUnitSize",isRanged:!1,range:[0,500],step:1e-4,group:s.cell,property:"worldUnitSize",allowCustomValue:!0},elevationScale:{type:"number",defaultValue:5,label:"layerVisConfigs.elevationScale",isRanged:!1,range:[0,100],step:.1,group:s.height,property:"elevationScale",allowCustomValue:!0},enableElevationZoomFactor:{type:"boolean",defaultValue:!0,label:"layerVisConfigs.enableElevationZoomFactor",group:s.height,property:"enableElevationZoomFactor",description:"layerVisConfigs.enableElevationZoomFactorDescription"},elevationRange:{type:"number",defaultValue:[0,500],label:"layerVisConfigs.heightScale",isRanged:!0,range:[0,1e3],step:.01,group:s.height,property:"sizeRange",allowCustomValue:!0},heightRange:{type:"number",defaultValue:[0,500],label:"Height Scale",isRanged:!0,range:[0,1e3],step:.01,group:s.height,property:"heightRange",allowCustomValue:!0},coverageRange:{type:"number",defaultValue:[0,1],label:"layerVisConfigs.coverageRange",isRanged:!0,range:[0,1],step:.01,group:s.radius,property:"coverageRange",allowCustomValue:!1},"hi-precision":{type:"boolean",defaultValue:!1,label:"layerVisConfigs.highPrecisionRendering",group:s.precision,property:"hi-precision",description:"layerVisConfigs.highPrecisionRenderingDescription"},enable3d:{type:"boolean",defaultValue:!1,label:"layerVisConfigs.height",group:s.height,property:"enable3d",description:"layerVisConfigs.heightDescription"},stroked:{type:"boolean",label:"layerVisConfigs.stroke",defaultValue:!0,group:s.display,property:"stroked"},filled:{type:"boolean",label:"layerVisConfigs.fill",defaultValue:!1,group:s.display,property:"filled"},extruded:{type:"boolean",defaultValue:!1,label:"layerVisConfigs.enablePolygonHeight",group:s.display,property:"extruded"},wireframe:{type:"boolean",defaultValue:!1,label:"layerVisConfigs.showWireframe",group:s.display,property:"wireframe"},weight:{type:"number",defaultValue:1,label:"layerVisConfigs.weightIntensity",isRanged:!1,range:[.01,500],step:.01,group:s.cell,property:"weight",condition:function(t){return Boolean(t.weightField)},allowCustomValue:!0},heatmapRadius:{type:"number",defaultValue:20,label:"layerVisConfigs.radius",isRanged:!1,range:[0,100],step:.1,group:s.cell,property:"radius",allowCustomValue:!0}};e.LAYER_VIS_CONFIGS=c;e.LAYER_TEXT_CONFIGS={fontSize:{type:"number",range:[1,100],value0:1,step:1,isRanged:!1,label:"Font size",showInput:!0},textAnchor:{type:"select",options:["start","middle","end"],multiSelect:!1,searchable:!1},textAlignment:{type:"select",options:["top","center","bottom"],multiSelect:!1,searchable:!1}};var p=(0,i.default)({point:null,arc:null,line:null,grid:null,hexagon:null,geojson:null,cluster:null,icon:null,heatmap:null,hexagonId:null,"3D":null,trip:null,s2:null});e.LAYER_TYPES=p;var h=[p.point,p.hexagon,p.arc,p.line,p.hexagonId];e.EDITOR_AVAILABLE_LAYERS=h},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n(r(65)),o=Object.assign({},i.default.KeyEvent);o.DOM_VK_UP=o.DOM_VK_UP||38,o.DOM_VK_DOWN=o.DOM_VK_DOWN||40,o.DOM_VK_BACK_SPACE=o.DOM_VK_BACK_SPACE||8,o.DOM_VK_RETURN=o.DOM_VK_RETURN||13,o.DOM_VK_ENTER=o.DOM_VK_ENTER||14,o.DOM_VK_ESCAPE=o.DOM_VK_ESCAPE||27,o.DOM_VK_TAB=o.DOM_VK_TAB||9,o.DOM_VK_DELETE=o.DOM_VK_DELETE||46;var a=o;e.default=a},function(t,e,r){(function(e){var r;r="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},t.exports=r}).call(this,r(14))},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IMAGE_EXPORT_ERRORS=e.MISSING_MAPBOX_TOKEN=void 0;e.MISSING_MAPBOX_TOKEN="Mapbox Token not valid. [Click here](https://github.com/keplergl/kepler.gl#mapboxapiaccesstoken-string-required)";e.IMAGE_EXPORT_ERRORS={dataUri:'[kepler.gl] Failed to create image from data uri.\n Copy the uri in the javascript console when reporting this bug.\n The uri is the string starts with "data:image/png"',styleSheet:"[kepler.gl] Failed to fetch stylesheet when exporting image.\n This probably will not affect the map. It might affect the legend.\n The stylesheet failed to load is: "}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BUG_REPORT_LINK=e.GUIDES_FILE_FORMAT_DOC=e.EXPORT_HTML_MAP_MODES_DOC=e.MAPBOX_ACCESS_TOKEN=e.ADD_DATA_TO_MAP_DOC=e.EXPORT_HTML_MAP_DOC=e.API_REFERENCE_DOC=e.ACTIONS_DOC=e.USER_GUIDE_DOC=void 0;var n="https://docs.kepler.gl/docs/user-guides";e.USER_GUIDE_DOC=n;var i="https://docs.kepler.gl/docs/api-reference/actions/actions";e.ACTIONS_DOC=i;e.API_REFERENCE_DOC="https://docs.kepler.gl/docs/api-reference";var o="".concat(n,"/k-save-and-export");e.EXPORT_HTML_MAP_DOC=o;var a="".concat(i,"#adddatatomap");e.ADD_DATA_TO_MAP_DOC=a;e.MAPBOX_ACCESS_TOKEN="https://docs.mapbox.com/help/how-mapbox-works/access-tokens/";var s="".concat(n,"/k-save-and-export#export-html-map");e.EXPORT_HTML_MAP_MODES_DOC=s;var l="".concat(n,"/b-kepler-gl-workflow/a-add-data-to-the-map#supported-file-formats");e.GUIDES_FILE_FORMAT_DOC=l;e.BUG_REPORT_LINK="https://github.com/keplergl/kepler.gl/issues/new?assignees=&labels=bug&template=bug_report.md&title=%5BBug%5D"},function(t,e,r){"use strict";var n=r(8);Object.defineProperty(e,"__esModule",{value:!0}),e.media=e.breakPointValues=void 0;var i,o,a,s=n(r(22)),l=r(23),u={palm:588,desk:768};e.breakPointValues=u;var c={palm:function(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];return(0,l.css)(i||(i=(0,s.default)(["\n @media (max-width: ","px) {\n ",";\n }\n "])),(function(t){return(t.theme.breakPoints||u).palm}),l.css.apply(void 0,[t].concat(r)))},portable:function(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];return(0,l.css)(o||(o=(0,s.default)(["\n @media (max-width: ","px) {\n ",";\n }\n "])),(function(t){return(t.theme.breakPoints||u).desk}),l.css.apply(void 0,[t].concat(r)))},desk:function(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];return(0,l.css)(a||(a=(0,s.default)(["\n @media (min-width: ","px) {\n ",";\n }\n "])),(function(t){return(t.theme.breakPoints||u).desk+1}),l.css.apply(void 0,[t].concat(r)))}};e.media=c},function(t,e,r){"use strict";r.r(e),r.d(e,"scaleBand",(function(){return l})),r.d(e,"scalePoint",(function(){return c})),r.d(e,"scaleIdentity",(function(){return Vt})),r.d(e,"scaleLinear",(function(){return Ut})),r.d(e,"scaleLog",(function(){return Jt})),r.d(e,"scaleSymlog",(function(){return ee})),r.d(e,"scaleOrdinal",(function(){return s})),r.d(e,"scaleImplicit",(function(){return a})),r.d(e,"scalePow",(function(){return ae})),r.d(e,"scaleSqrt",(function(){return se})),r.d(e,"scaleRadial",(function(){return ce})),r.d(e,"scaleQuantile",(function(){return ge})),r.d(e,"scaleQuantize",(function(){return ye})),r.d(e,"scaleThreshold",(function(){return ve})),r.d(e,"scaleTime",(function(){return In})),r.d(e,"scaleUtc",(function(){return Ln})),r.d(e,"scaleSequential",(function(){return Nn})),r.d(e,"scaleSequentialLog",(function(){return jn})),r.d(e,"scaleSequentialPow",(function(){return Vn})),r.d(e,"scaleSequentialSqrt",(function(){return qn})),r.d(e,"scaleSequentialSymlog",(function(){return Un})),r.d(e,"scaleSequentialQuantile",(function(){return Hn})),r.d(e,"scaleDiverging",(function(){return Wn})),r.d(e,"scaleDivergingLog",(function(){return Yn})),r.d(e,"scaleDivergingPow",(function(){return Kn})),r.d(e,"scaleDivergingSqrt",(function(){return Jn})),r.d(e,"scaleDivergingSymlog",(function(){return Xn})),r.d(e,"tickFormat",(function(){return Nt}));var n=function(t,e,r){t=+t,e=+e,r=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+r;for(var n=-1,i=0|Math.max(0,Math.ceil((e-t)/r)),o=new Array(i);++n<i;)o[n]=t+n*r;return o};function i(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}function o(t,e){switch(arguments.length){case 0:break;case 1:"function"==typeof t?this.interpolator(t):this.range(t);break;default:this.domain(t),"function"==typeof e?this.interpolator(e):this.range(e)}return this}const a=Symbol("implicit");function s(){var t=new Map,e=[],r=[],n=a;function o(i){var o=i+"",s=t.get(o);if(!s){if(n!==a)return n;t.set(o,s=e.push(i))}return r[(s-1)%r.length]}return o.domain=function(r){if(!arguments.length)return e.slice();e=[],t=new Map;for(const n of r){const r=n+"";t.has(r)||t.set(r,e.push(n))}return o},o.range=function(t){return arguments.length?(r=Array.from(t),o):r.slice()},o.unknown=function(t){return arguments.length?(n=t,o):n},o.copy=function(){return s(e,r).unknown(n)},i.apply(o,arguments),o}function l(){var t,e,r=s().unknown(void 0),o=r.domain,a=r.range,u=0,c=1,p=!1,h=0,f=0,d=.5;function m(){var r=o().length,i=c<u,s=i?c:u,l=i?u:c;t=(l-s)/Math.max(1,r-h+2*f),p&&(t=Math.floor(t)),s+=(l-s-t*(r-h))*d,e=t*(1-h),p&&(s=Math.round(s),e=Math.round(e));var m=n(r).map((function(e){return s+t*e}));return a(i?m.reverse():m)}return delete r.unknown,r.domain=function(t){return arguments.length?(o(t),m()):o()},r.range=function(t){return arguments.length?([u,c]=t,u=+u,c=+c,m()):[u,c]},r.rangeRound=function(t){return[u,c]=t,u=+u,c=+c,p=!0,m()},r.bandwidth=function(){return e},r.step=function(){return t},r.round=function(t){return arguments.length?(p=!!t,m()):p},r.padding=function(t){return arguments.length?(h=Math.min(1,f=+t),m()):h},r.paddingInner=function(t){return arguments.length?(h=Math.min(1,t),m()):h},r.paddingOuter=function(t){return arguments.length?(f=+t,m()):f},r.align=function(t){return arguments.length?(d=Math.max(0,Math.min(1,t)),m()):d},r.copy=function(){return l(o(),[u,c]).round(p).paddingInner(h).paddingOuter(f).align(d)},i.apply(m(),arguments)}function u(t){var e=t.copy;return t.padding=t.paddingOuter,delete t.paddingInner,delete t.paddingOuter,t.copy=function(){return u(e())},t}function c(){return u(l.apply(null,arguments).paddingInner(1))}var p=Math.sqrt(50),h=Math.sqrt(10),f=Math.sqrt(2),d=function(t,e,r){var n,i,o,a,s=-1;if(r=+r,(t=+t)===(e=+e)&&r>0)return[t];if((n=e<t)&&(i=t,t=e,e=i),0===(a=m(t,e,r))||!isFinite(a))return[];if(a>0){let r=Math.round(t/a),n=Math.round(e/a);for(r*a<t&&++r,n*a>e&&--n,o=new Array(i=n-r+1);++s<i;)o[s]=(r+s)*a}else{a=-a;let r=Math.round(t*a),n=Math.round(e*a);for(r/a<t&&++r,n/a>e&&--n,o=new Array(i=n-r+1);++s<i;)o[s]=(r+s)/a}return n&&o.reverse(),o};function m(t,e,r){var n=(e-t)/Math.max(0,r),i=Math.floor(Math.log(n)/Math.LN10),o=n/Math.pow(10,i);return i>=0?(o>=p?10:o>=h?5:o>=f?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=p?10:o>=h?5:o>=f?2:1)}function g(t,e,r){var n=Math.abs(e-t)/Math.max(0,r),i=Math.pow(10,Math.floor(Math.log(n)/Math.LN10)),o=n/i;return o>=p?i*=10:o>=h?i*=5:o>=f&&(i*=2),e<t?-i:i}var y=function(t,e){return t<e?-1:t>e?1:t>=e?0:NaN},v=function(t){let e=t,r=t;function n(t,e,n,i){for(null==n&&(n=0),null==i&&(i=t.length);n<i;){const o=n+i>>>1;r(t[o],e)<0?n=o+1:i=o}return n}return 1===t.length&&(e=(e,r)=>t(e)-r,r=function(t){return(e,r)=>y(t(e),r)}(t)),{left:n,center:function(t,r,i,o){null==i&&(i=0),null==o&&(o=t.length);const a=n(t,r,i,o-1);return a>i&&e(t[a-1],r)>-e(t[a],r)?a-1:a},right:function(t,e,n,i){for(null==n&&(n=0),null==i&&(i=t.length);n<i;){const o=n+i>>>1;r(t[o],e)>0?i=o:n=o+1}return n}}};var _=function(t){return null===t?NaN:+t};const b=v(y),x=b.right;b.left,v(_).center;var w=x,E=function(t,e,r){t.prototype=e.prototype=r,r.constructor=t};function T(t,e){var r=Object.create(t.prototype);for(var n in e)r[n]=e[n];return r}function A(){}var C="\\s*([+-]?\\d+)\\s*",S="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",P="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",I=/^#([0-9a-f]{3,8})$/,D=new RegExp("^rgb\\("+[C,C,C]+"\\)$"),O=new RegExp("^rgb\\("+[P,P,P]+"\\)$"),M=new RegExp("^rgba\\("+[C,C,C,S]+"\\)$"),B=new RegExp("^rgba\\("+[P,P,P,S]+"\\)$"),k=new RegExp("^hsl\\("+[S,P,P]+"\\)$"),F=new RegExp("^hsla\\("+[S,P,P,S]+"\\)$"),L={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function R(){return this.rgb().formatHex()}function z(){return this.rgb().formatRgb()}function N(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=I.exec(t))?(r=e[1].length,e=parseInt(e[1],16),6===r?j(e):3===r?new H(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===r?U(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===r?U(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=D.exec(t))?new H(e[1],e[2],e[3],1):(e=O.exec(t))?new H(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=M.exec(t))?U(e[1],e[2],e[3],e[4]):(e=B.exec(t))?U(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=k.exec(t))?Y(e[1],e[2]/100,e[3]/100,1):(e=F.exec(t))?Y(e[1],e[2]/100,e[3]/100,e[4]):L.hasOwnProperty(t)?j(L[t]):"transparent"===t?new H(NaN,NaN,NaN,0):null}function j(t){return new H(t>>16&255,t>>8&255,255&t,1)}function U(t,e,r,n){return n<=0&&(t=e=r=NaN),new H(t,e,r,n)}function V(t){return t instanceof A||(t=N(t)),t?new H((t=t.rgb()).r,t.g,t.b,t.opacity):new H}function q(t,e,r,n){return 1===arguments.length?V(t):new H(t,e,r,null==n?1:n)}function H(t,e,r,n){this.r=+t,this.g=+e,this.b=+r,this.opacity=+n}function G(){return"#"+W(this.r)+W(this.g)+W(this.b)}function Z(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function W(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function Y(t,e,r,n){return n<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new K(t,e,r,n)}function X(t){if(t instanceof K)return new K(t.h,t.s,t.l,t.opacity);if(t instanceof A||(t=N(t)),!t)return new K;if(t instanceof K)return t;var e=(t=t.rgb()).r/255,r=t.g/255,n=t.b/255,i=Math.min(e,r,n),o=Math.max(e,r,n),a=NaN,s=o-i,l=(o+i)/2;return s?(a=e===o?(r-n)/s+6*(r<n):r===o?(n-e)/s+2:(e-r)/s+4,s/=l<.5?o+i:2-o-i,a*=60):s=l>0&&l<1?0:a,new K(a,s,l,t.opacity)}function K(t,e,r,n){this.h=+t,this.s=+e,this.l=+r,this.opacity=+n}function J(t,e,r){return 255*(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)}function Q(t,e,r,n,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*r+(1+3*t+3*o-3*a)*n+a*i)/6}E(A,N,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:R,formatHex:R,formatHsl:function(){return X(this).formatHsl()},formatRgb:z,toString:z}),E(H,q,T(A,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new H(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new H(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:G,formatHex:G,formatRgb:Z,toString:Z})),E(K,(function(t,e,r,n){return 1===arguments.length?X(t):new K(t,e,r,null==n?1:n)}),T(A,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new K(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new K(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*e,i=2*r-n;return new H(J(t>=240?t-240:t+120,i,n),J(t,i,n),J(t<120?t+240:t-120,i,n),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var $=t=>()=>t;function tt(t,e){return function(r){return t+r*e}}function et(t){return 1==(t=+t)?rt:function(e,r){return r-e?function(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(n){return Math.pow(t+n*e,r)}}(e,r,t):$(isNaN(e)?r:e)}}function rt(t,e){var r=e-t;return r?tt(t,r):$(isNaN(t)?e:t)}var nt=function t(e){var r=et(e);function n(t,e){var n=r((t=q(t)).r,(e=q(e)).r),i=r(t.g,e.g),o=r(t.b,e.b),a=rt(t.opacity,e.opacity);return function(e){return t.r=n(e),t.g=i(e),t.b=o(e),t.opacity=a(e),t+""}}return n.gamma=t,n}(1);function it(t){return function(e){var r,n,i=e.length,o=new Array(i),a=new Array(i),s=new Array(i);for(r=0;r<i;++r)n=q(e[r]),o[r]=n.r||0,a[r]=n.g||0,s[r]=n.b||0;return o=t(o),a=t(a),s=t(s),n.opacity=1,function(t){return n.r=o(t),n.g=a(t),n.b=s(t),n+""}}}it((function(t){var e=t.length-1;return function(r){var n=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),i=t[n],o=t[n+1],a=n>0?t[n-1]:2*i-o,s=n<e-1?t[n+2]:2*o-i;return Q((r-n/e)*e,a,i,o,s)}})),it((function(t){var e=t.length;return function(r){var n=Math.floor(((r%=1)<0?++r:r)*e),i=t[(n+e-1)%e],o=t[n%e],a=t[(n+1)%e],s=t[(n+2)%e];return Q((r-n/e)*e,i,o,a,s)}}));var ot=function(t,e){e||(e=[]);var r,n=t?Math.min(e.length,t.length):0,i=e.slice();return function(o){for(r=0;r<n;++r)i[r]=t[r]*(1-o)+e[r]*o;return i}};function at(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function st(t,e){var r,n=e?e.length:0,i=t?Math.min(n,t.length):0,o=new Array(i),a=new Array(n);for(r=0;r<i;++r)o[r]=dt(t[r],e[r]);for(;r<n;++r)a[r]=e[r];return function(t){for(r=0;r<i;++r)a[r]=o[r](t);return a}}var lt=function(t,e){var r=new Date;return t=+t,e=+e,function(n){return r.setTime(t*(1-n)+e*n),r}},ut=function(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}},ct=function(t,e){var r,n={},i={};for(r in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)r in t?n[r]=dt(t[r],e[r]):i[r]=e[r];return function(t){for(r in n)i[r]=n[r](t);return i}},pt=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,ht=new RegExp(pt.source,"g");var ft=function(t,e){var r,n,i,o=pt.lastIndex=ht.lastIndex=0,a=-1,s=[],l=[];for(t+="",e+="";(r=pt.exec(t))&&(n=ht.exec(e));)(i=n.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(r=r[0])===(n=n[0])?s[a]?s[a]+=n:s[++a]=n:(s[++a]=null,l.push({i:a,x:ut(r,n)})),o=ht.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?l[0]?function(t){return function(e){return t(e)+""}}(l[0].x):function(t){return function(){return t}}(e):(e=l.length,function(t){for(var r,n=0;n<e;++n)s[(r=l[n]).i]=r.x(t);return s.join("")})},dt=function(t,e){var r,n=typeof e;return null==e||"boolean"===n?$(e):("number"===n?ut:"string"===n?(r=N(e))?(e=r,nt):ft:e instanceof N?nt:e instanceof Date?lt:at(e)?ot:Array.isArray(e)?st:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?ct:ut)(t,e)},mt=function(t,e){return t=+t,e=+e,function(r){return Math.round(t*(1-r)+e*r)}};function gt(t){return+t}var yt=[0,1];function vt(t){return t}function _t(t,e){return(e-=t=+t)?function(r){return(r-t)/e}:(r=isNaN(e)?NaN:.5,function(){return r});var r}function bt(t,e,r){var n=t[0],i=t[1],o=e[0],a=e[1];return i<n?(n=_t(i,n),o=r(a,o)):(n=_t(n,i),o=r(o,a)),function(t){return o(n(t))}}function xt(t,e,r){var n=Math.min(t.length,e.length)-1,i=new Array(n),o=new Array(n),a=-1;for(t[n]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<n;)i[a]=_t(t[a],t[a+1]),o[a]=r(e[a],e[a+1]);return function(e){var r=w(t,e,1,n)-1;return o[r](i[r](e))}}function wt(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Et(){var t,e,r,n,i,o,a=yt,s=yt,l=dt,u=vt;function c(){var t,e,r,l=Math.min(a.length,s.length);return u!==vt&&(t=a[0],e=a[l-1],t>e&&(r=t,t=e,e=r),u=function(r){return Math.max(t,Math.min(e,r))}),n=l>2?xt:bt,i=o=null,p}function p(e){return isNaN(e=+e)?r:(i||(i=n(a.map(t),s,l)))(t(u(e)))}return p.invert=function(r){return u(e((o||(o=n(s,a.map(t),ut)))(r)))},p.domain=function(t){return arguments.length?(a=Array.from(t,gt),c()):a.slice()},p.range=function(t){return arguments.length?(s=Array.from(t),c()):s.slice()},p.rangeRound=function(t){return s=Array.from(t),l=mt,c()},p.clamp=function(t){return arguments.length?(u=!!t||vt,c()):u!==vt},p.interpolate=function(t){return arguments.length?(l=t,c()):l},p.unknown=function(t){return arguments.length?(r=t,p):r},function(r,n){return t=r,e=n,c()}}function Tt(){return Et()(vt,vt)}var At=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Ct(t){if(!(e=At.exec(t)))throw new Error("invalid format: "+t);var e;return new St({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function St(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}Ct.prototype=St.prototype,St.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};function Pt(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,n=t.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+t.slice(r+1)]}var It,Dt,Ot,Mt,Bt=function(t){return(t=Pt(Math.abs(t)))?t[1]:NaN},kt=function(t,e){var r=Pt(t,e);if(!r)return t+"";var n=r[0],i=r[1];return i<0?"0."+new Array(-i).join("0")+n:n.length>i+1?n.slice(0,i+1)+"."+n.slice(i+1):n+new Array(i-n.length+2).join("0")},Ft={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>kt(100*t,e),r:kt,s:function(t,e){var r=Pt(t,e);if(!r)return t+"";var n=r[0],i=r[1],o=i-(It=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=n.length;return o===a?n:o>a?n+new Array(o-a+1).join("0"):o>0?n.slice(0,o)+"."+n.slice(o):"0."+new Array(1-o).join("0")+Pt(t,Math.max(0,e+o-1))[0]},X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)},Lt=function(t){return t},Rt=Array.prototype.map,zt=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];Dt=function(t){var e,r,n=void 0===t.grouping||void 0===t.thousands?Lt:(e=Rt.call(t.grouping,Number),r=t.thousands+"",function(t,n){for(var i=t.length,o=[],a=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>n&&(s=Math.max(1,n-l)),o.push(t.substring(i-=s,i+s)),!((l+=s+1)>n));)s=e[a=(a+1)%e.length];return o.reverse().join(r)}),i=void 0===t.currency?"":t.currency[0]+"",o=void 0===t.currency?"":t.currency[1]+"",a=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?Lt:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(Rt.call(t.numerals,String)),l=void 0===t.percent?"%":t.percent+"",u=void 0===t.minus?"−":t.minus+"",c=void 0===t.nan?"NaN":t.nan+"";function p(t){var e=(t=Ct(t)).fill,r=t.align,p=t.sign,h=t.symbol,f=t.zero,d=t.width,m=t.comma,g=t.precision,y=t.trim,v=t.type;"n"===v?(m=!0,v="g"):Ft[v]||(void 0===g&&(g=12),y=!0,v="g"),(f||"0"===e&&"="===r)&&(f=!0,e="0",r="=");var _="$"===h?i:"#"===h&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",b="$"===h?o:/[%p]/.test(v)?l:"",x=Ft[v],w=/[defgprs%]/.test(v);function E(t){var i,o,l,h=_,E=b;if("c"===v)E=x(t)+E,t="";else{var T=(t=+t)<0||1/t<0;if(t=isNaN(t)?c:x(Math.abs(t),g),y&&(t=function(t){t:for(var e,r=t.length,n=1,i=-1;n<r;++n)switch(t[n]){case".":i=e=n;break;case"0":0===i&&(i=n),e=n;break;default:if(!+t[n])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),T&&0==+t&&"+"!==p&&(T=!1),h=(T?"("===p?p:u:"-"===p||"("===p?"":p)+h,E=("s"===v?zt[8+It/3]:"")+E+(T&&"("===p?")":""),w)for(i=-1,o=t.length;++i<o;)if(48>(l=t.charCodeAt(i))||l>57){E=(46===l?a+t.slice(i+1):t.slice(i))+E,t=t.slice(0,i);break}}m&&!f&&(t=n(t,1/0));var A=h.length+t.length+E.length,C=A<d?new Array(d-A+1).join(e):"";switch(m&&f&&(t=n(C+t,C.length?d-E.length:1/0),C=""),r){case"<":t=h+t+E+C;break;case"=":t=h+C+t+E;break;case"^":t=C.slice(0,A=C.length>>1)+h+t+E+C.slice(A);break;default:t=C+h+t+E}return s(t)}return g=void 0===g?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),E.toString=function(){return t+""},E}return{format:p,formatPrefix:function(t,e){var r=p(((t=Ct(t)).type="f",t)),n=3*Math.max(-8,Math.min(8,Math.floor(Bt(e)/3))),i=Math.pow(10,-n),o=zt[8+n/3];return function(t){return r(i*t)+o}}}}({thousands:",",grouping:[3],currency:["$",""]}),Ot=Dt.format,Mt=Dt.formatPrefix;function Nt(t,e,r,n){var i,o=g(t,e,r);switch((n=Ct(null==n?",f":n)).type){case"s":var a=Math.max(Math.abs(t),Math.abs(e));return null!=n.precision||isNaN(i=function(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Bt(e)/3)))-Bt(Math.abs(t)))}(o,a))||(n.precision=i),Mt(n,a);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(i=function(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Bt(e)-Bt(t))+1}(o,Math.max(Math.abs(t),Math.abs(e))))||(n.precision=i-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(i=function(t){return Math.max(0,-Bt(Math.abs(t)))}(o))||(n.precision=i-2*("%"===n.type))}return Ot(n)}function jt(t){var e=t.domain;return t.ticks=function(t){var r=e();return d(r[0],r[r.length-1],null==t?10:t)},t.tickFormat=function(t,r){var n=e();return Nt(n[0],n[n.length-1],null==t?10:t,r)},t.nice=function(r){null==r&&(r=10);var n,i,o=e(),a=0,s=o.length-1,l=o[a],u=o[s],c=10;for(u<l&&(i=l,l=u,u=i,i=a,a=s,s=i);c-- >0;){if((i=m(l,u,r))===n)return o[a]=l,o[s]=u,e(o);if(i>0)l=Math.floor(l/i)*i,u=Math.ceil(u/i)*i;else{if(!(i<0))break;l=Math.ceil(l*i)/i,u=Math.floor(u*i)/i}n=i}return t},t}function Ut(){var t=Tt();return t.copy=function(){return wt(t,Ut())},i.apply(t,arguments),jt(t)}function Vt(t){var e;function r(t){return isNaN(t=+t)?e:t}return r.invert=r,r.domain=r.range=function(e){return arguments.length?(t=Array.from(e,gt),r):t.slice()},r.unknown=function(t){return arguments.length?(e=t,r):e},r.copy=function(){return Vt(t).unknown(e)},t=arguments.length?Array.from(t,gt):[0,1],jt(r)}function qt(t,e){var r,n=0,i=(t=t.slice()).length-1,o=t[n],a=t[i];return a<o&&(r=n,n=i,i=r,r=o,o=a,a=r),t[n]=e.floor(o),t[i]=e.ceil(a),t}function Ht(t){return Math.log(t)}function Gt(t){return Math.exp(t)}function Zt(t){return-Math.log(-t)}function Wt(t){return-Math.exp(-t)}function Yt(t){return isFinite(t)?+("1e"+t):t<0?0:t}function Xt(t){return function(e){return-t(-e)}}function Kt(t){var e,r,n=t(Ht,Gt),i=n.domain,o=10;function a(){return e=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}(o),r=function(t){return 10===t?Yt:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}(o),i()[0]<0?(e=Xt(e),r=Xt(r),t(Zt,Wt)):t(Ht,Gt),n}return n.base=function(t){return arguments.length?(o=+t,a()):o},n.domain=function(t){return arguments.length?(i(t),a()):i()},n.ticks=function(t){var n,a=i(),s=a[0],l=a[a.length-1];(n=l<s)&&(h=s,s=l,l=h);var u,c,p,h=e(s),f=e(l),m=null==t?10:+t,g=[];if(!(o%1)&&f-h<m){if(h=Math.floor(h),f=Math.ceil(f),s>0){for(;h<=f;++h)for(c=1,u=r(h);c<o;++c)if(!((p=u*c)<s)){if(p>l)break;g.push(p)}}else for(;h<=f;++h)for(c=o-1,u=r(h);c>=1;--c)if(!((p=u*c)<s)){if(p>l)break;g.push(p)}2*g.length<m&&(g=d(s,l,m))}else g=d(h,f,Math.min(f-h,m)).map(r);return n?g.reverse():g},n.tickFormat=function(t,i){if(null==i&&(i=10===o?".0e":","),"function"!=typeof i&&(i=Ot(i)),t===1/0)return i;null==t&&(t=10);var a=Math.max(1,o*t/n.ticks().length);return function(t){var n=t/r(Math.round(e(t)));return n*o<o-.5&&(n*=o),n<=a?i(t):""}},n.nice=function(){return i(qt(i(),{floor:function(t){return r(Math.floor(e(t)))},ceil:function(t){return r(Math.ceil(e(t)))}}))},n}function Jt(){var t=Kt(Et()).domain([1,10]);return t.copy=function(){return wt(t,Jt()).base(t.base())},i.apply(t,arguments),t}function Qt(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function $t(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function te(t){var e=1,r=t(Qt(e),$t(e));return r.constant=function(r){return arguments.length?t(Qt(e=+r),$t(e)):e},jt(r)}function ee(){var t=te(Et());return t.copy=function(){return wt(t,ee()).constant(t.constant())},i.apply(t,arguments)}function re(t){return function(e){return e<0?-Math.pow(-e,t):Math.pow(e,t)}}function ne(t){return t<0?-Math.sqrt(-t):Math.sqrt(t)}function ie(t){return t<0?-t*t:t*t}function oe(t){var e=t(vt,vt),r=1;function n(){return 1===r?t(vt,vt):.5===r?t(ne,ie):t(re(r),re(1/r))}return e.exponent=function(t){return arguments.length?(r=+t,n()):r},jt(e)}function ae(){var t=oe(Et());return t.copy=function(){return wt(t,ae()).exponent(t.exponent())},i.apply(t,arguments),t}function se(){return ae.apply(null,arguments).exponent(.5)}function le(t){return Math.sign(t)*t*t}function ue(t){return Math.sign(t)*Math.sqrt(Math.abs(t))}function ce(){var t,e=Tt(),r=[0,1],n=!1;function o(r){var i=ue(e(r));return isNaN(i)?t:n?Math.round(i):i}return o.invert=function(t){return e.invert(le(t))},o.domain=function(t){return arguments.length?(e.domain(t),o):e.domain()},o.range=function(t){return arguments.length?(e.range((r=Array.from(t,gt)).map(le)),o):r.slice()},o.rangeRound=function(t){return o.range(t).round(!0)},o.round=function(t){return arguments.length?(n=!!t,o):n},o.clamp=function(t){return arguments.length?(e.clamp(t),o):e.clamp()},o.unknown=function(e){return arguments.length?(t=e,o):t},o.copy=function(){return ce(e.domain(),r).round(n).clamp(e.clamp()).unknown(t)},i.apply(o,arguments),jt(o)}function pe(t,e){let r;if(void 0===e)for(const e of t)null!=e&&(r<e||void 0===r&&e>=e)&&(r=e);else{let n=-1;for(let i of t)null!=(i=e(i,++n,t))&&(r<i||void 0===r&&i>=i)&&(r=i)}return r}function he(t,e){let r;if(void 0===e)for(const e of t)null!=e&&(r>e||void 0===r&&e>=e)&&(r=e);else{let n=-1;for(let i of t)null!=(i=e(i,++n,t))&&(r>i||void 0===r&&i>=i)&&(r=i)}return r}function fe(t,e,r){const n=t[e];t[e]=t[r],t[r]=n}function de(t,e,r){if(n=(t=Float64Array.from(function*(t,e){if(void 0===e)for(let e of t)null!=e&&(e=+e)>=e&&(yield e);else{let r=-1;for(let n of t)null!=(n=e(n,++r,t))&&(n=+n)>=n&&(yield n)}}(t,r))).length){if((e=+e)<=0||n<2)return he(t);if(e>=1)return pe(t);var n,i=(n-1)*e,o=Math.floor(i),a=pe(function t(e,r,n=0,i=e.length-1,o=y){for(;i>n;){if(i-n>600){const a=i-n+1,s=r-n+1,l=Math.log(a),u=.5*Math.exp(2*l/3),c=.5*Math.sqrt(l*u*(a-u)/a)*(s-a/2<0?-1:1);t(e,r,Math.max(n,Math.floor(r-s*u/a+c)),Math.min(i,Math.floor(r+(a-s)*u/a+c)),o)}const a=e[r];let s=n,l=i;for(fe(e,n,r),o(e[i],a)>0&&fe(e,n,i);s<l;){for(fe(e,s,l),++s,--l;o(e[s],a)<0;)++s;for(;o(e[l],a)>0;)--l}0===o(e[n],a)?fe(e,n,l):(++l,fe(e,l,i)),l<=r&&(n=l+1),r<=l&&(i=l-1)}return e}(t,o).subarray(0,o+1));return a+(he(t.subarray(o+1))-a)*(i-o)}}function me(t,e,r=_){if(n=t.length){if((e=+e)<=0||n<2)return+r(t[0],0,t);if(e>=1)return+r(t[n-1],n-1,t);var n,i=(n-1)*e,o=Math.floor(i),a=+r(t[o],o,t);return a+(+r(t[o+1],o+1,t)-a)*(i-o)}}function ge(){var t,e=[],r=[],n=[];function o(){var t=0,i=Math.max(1,r.length);for(n=new Array(i-1);++t<i;)n[t-1]=me(e,t/i);return a}function a(e){return isNaN(e=+e)?t:r[w(n,e)]}return a.invertExtent=function(t){var i=r.indexOf(t);return i<0?[NaN,NaN]:[i>0?n[i-1]:e[0],i<n.length?n[i]:e[e.length-1]]},a.domain=function(t){if(!arguments.length)return e.slice();e=[];for(let r of t)null==r||isNaN(r=+r)||e.push(r);return e.sort(y),o()},a.range=function(t){return arguments.length?(r=Array.from(t),o()):r.slice()},a.unknown=function(e){return arguments.length?(t=e,a):t},a.quantiles=function(){return n.slice()},a.copy=function(){return ge().domain(e).range(r).unknown(t)},i.apply(a,arguments)}function ye(){var t,e=0,r=1,n=1,o=[.5],a=[0,1];function s(e){return e<=e?a[w(o,e,0,n)]:t}function l(){var t=-1;for(o=new Array(n);++t<n;)o[t]=((t+1)*r-(t-n)*e)/(n+1);return s}return s.domain=function(t){return arguments.length?([e,r]=t,e=+e,r=+r,l()):[e,r]},s.range=function(t){return arguments.length?(n=(a=Array.from(t)).length-1,l()):a.slice()},s.invertExtent=function(t){var i=a.indexOf(t);return i<0?[NaN,NaN]:i<1?[e,o[0]]:i>=n?[o[n-1],r]:[o[i-1],o[i]]},s.unknown=function(e){return arguments.length?(t=e,s):s},s.thresholds=function(){return o.slice()},s.copy=function(){return ye().domain([e,r]).range(a).unknown(t)},i.apply(jt(s),arguments)}function ve(){var t,e=[.5],r=[0,1],n=1;function o(i){return i<=i?r[w(e,i,0,n)]:t}return o.domain=function(t){return arguments.length?(e=Array.from(t),n=Math.min(e.length,r.length-1),o):e.slice()},o.range=function(t){return arguments.length?(r=Array.from(t),n=Math.min(e.length,r.length-1),o):r.slice()},o.invertExtent=function(t){var n=r.indexOf(t);return[e[n-1],e[n]]},o.unknown=function(e){return arguments.length?(t=e,o):t},o.copy=function(){return ve().domain(e).range(r).unknown(t)},i.apply(o,arguments)}var _e=new Date,be=new Date;function xe(t,e,r,n){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=function(e){return t(e=new Date(+e)),e},i.ceil=function(r){return t(r=new Date(r-1)),e(r,1),t(r),r},i.round=function(t){var e=i(t),r=i.ceil(t);return t-e<r-t?e:r},i.offset=function(t,r){return e(t=new Date(+t),null==r?1:Math.floor(r)),t},i.range=function(r,n,o){var a,s=[];if(r=i.ceil(r),o=null==o?1:Math.floor(o),!(r<n&&o>0))return s;do{s.push(a=new Date(+r)),e(r,o),t(r)}while(a<r&&r<n);return s},i.filter=function(r){return xe((function(e){if(e>=e)for(;t(e),!r(e);)e.setTime(e-1)}),(function(t,n){if(t>=t)if(n<0)for(;++n<=0;)for(;e(t,-1),!r(t););else for(;--n>=0;)for(;e(t,1),!r(t););}))},r&&(i.count=function(e,n){return _e.setTime(+e),be.setTime(+n),t(_e),t(be),Math.floor(r(_e,be))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(n?function(e){return n(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var we=xe((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));we.every=function(t){return isFinite(t=Math.floor(t))&&t>0?xe((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,r){e.setFullYear(e.getFullYear()+r*t)})):null};var Ee=we,Te=(we.range,xe((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}))),Ae=Te;Te.range;function Ce(t){return xe((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var Se=Ce(0),Pe=Ce(1),Ie=Ce(2),De=Ce(3),Oe=Ce(4),Me=Ce(5),Be=Ce(6),ke=(Se.range,Pe.range,Ie.range,De.range,Oe.range,Me.range,Be.range,xe(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5,t=>t.getDate()-1)),Fe=ke,Le=(ke.range,xe((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()}))),Re=Le,ze=(Le.range,xe((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()}))),Ne=ze,je=(ze.range,xe((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()}))),Ue=je,Ve=(je.range,xe((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t})));Ve.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?xe((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,r){e.setTime(+e+r*t)}),(function(e,r){return(r-e)/t})):Ve:null};var qe=Ve;Ve.range;function He(t){return xe((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var Ge=He(0),Ze=He(1),We=He(2),Ye=He(3),Xe=He(4),Ke=He(5),Je=He(6),Qe=(Ge.range,Ze.range,We.range,Ye.range,Xe.range,Ke.range,Je.range,xe((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1}))),$e=Qe,tr=(Qe.range,xe((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()})));tr.every=function(t){return isFinite(t=Math.floor(t))&&t>0?xe((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,r){e.setUTCFullYear(e.getUTCFullYear()+r*t)})):null};var er=tr;tr.range;function rr(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function nr(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function ir(t,e,r){return{y:t,m:e,d:r,H:0,M:0,S:0,L:0}}var or,ar,sr,lr={"-":"",_:" ",0:"0"},ur=/^\s*\d+/,cr=/^%/,pr=/[\\^$*+?|[\]().{}]/g;function hr(t,e,r){var n=t<0?"-":"",i=(n?-t:t)+"",o=i.length;return n+(o<r?new Array(r-o+1).join(e)+i:i)}function fr(t){return t.replace(pr,"\\$&")}function dr(t){return new RegExp("^(?:"+t.map(fr).join("|")+")","i")}function mr(t){return new Map(t.map((t,e)=>[t.toLowerCase(),e]))}function gr(t,e,r){var n=ur.exec(e.slice(r,r+1));return n?(t.w=+n[0],r+n[0].length):-1}function yr(t,e,r){var n=ur.exec(e.slice(r,r+1));return n?(t.u=+n[0],r+n[0].length):-1}function vr(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.U=+n[0],r+n[0].length):-1}function _r(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.V=+n[0],r+n[0].length):-1}function br(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.W=+n[0],r+n[0].length):-1}function xr(t,e,r){var n=ur.exec(e.slice(r,r+4));return n?(t.y=+n[0],r+n[0].length):-1}function wr(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function Er(t,e,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return n?(t.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Tr(t,e,r){var n=ur.exec(e.slice(r,r+1));return n?(t.q=3*n[0]-3,r+n[0].length):-1}function Ar(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.m=n[0]-1,r+n[0].length):-1}function Cr(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.d=+n[0],r+n[0].length):-1}function Sr(t,e,r){var n=ur.exec(e.slice(r,r+3));return n?(t.m=0,t.d=+n[0],r+n[0].length):-1}function Pr(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.H=+n[0],r+n[0].length):-1}function Ir(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.M=+n[0],r+n[0].length):-1}function Dr(t,e,r){var n=ur.exec(e.slice(r,r+2));return n?(t.S=+n[0],r+n[0].length):-1}function Or(t,e,r){var n=ur.exec(e.slice(r,r+3));return n?(t.L=+n[0],r+n[0].length):-1}function Mr(t,e,r){var n=ur.exec(e.slice(r,r+6));return n?(t.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function Br(t,e,r){var n=cr.exec(e.slice(r,r+1));return n?r+n[0].length:-1}function kr(t,e,r){var n=ur.exec(e.slice(r));return n?(t.Q=+n[0],r+n[0].length):-1}function Fr(t,e,r){var n=ur.exec(e.slice(r));return n?(t.s=+n[0],r+n[0].length):-1}function Lr(t,e){return hr(t.getDate(),e,2)}function Rr(t,e){return hr(t.getHours(),e,2)}function zr(t,e){return hr(t.getHours()%12||12,e,2)}function Nr(t,e){return hr(1+Fe.count(Ee(t),t),e,3)}function jr(t,e){return hr(t.getMilliseconds(),e,3)}function Ur(t,e){return jr(t,e)+"000"}function Vr(t,e){return hr(t.getMonth()+1,e,2)}function qr(t,e){return hr(t.getMinutes(),e,2)}function Hr(t,e){return hr(t.getSeconds(),e,2)}function Gr(t){var e=t.getDay();return 0===e?7:e}function Zr(t,e){return hr(Se.count(Ee(t)-1,t),e,2)}function Wr(t){var e=t.getDay();return e>=4||0===e?Oe(t):Oe.ceil(t)}function Yr(t,e){return t=Wr(t),hr(Oe.count(Ee(t),t)+(4===Ee(t).getDay()),e,2)}function Xr(t){return t.getDay()}function Kr(t,e){return hr(Pe.count(Ee(t)-1,t),e,2)}function Jr(t,e){return hr(t.getFullYear()%100,e,2)}function Qr(t,e){return hr((t=Wr(t)).getFullYear()%100,e,2)}function $r(t,e){return hr(t.getFullYear()%1e4,e,4)}function tn(t,e){var r=t.getDay();return hr((t=r>=4||0===r?Oe(t):Oe.ceil(t)).getFullYear()%1e4,e,4)}function en(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+hr(e/60|0,"0",2)+hr(e%60,"0",2)}function rn(t,e){return hr(t.getUTCDate(),e,2)}function nn(t,e){return hr(t.getUTCHours(),e,2)}function on(t,e){return hr(t.getUTCHours()%12||12,e,2)}function an(t,e){return hr(1+$e.count(er(t),t),e,3)}function sn(t,e){return hr(t.getUTCMilliseconds(),e,3)}function ln(t,e){return sn(t,e)+"000"}function un(t,e){return hr(t.getUTCMonth()+1,e,2)}function cn(t,e){return hr(t.getUTCMinutes(),e,2)}function pn(t,e){return hr(t.getUTCSeconds(),e,2)}function hn(t){var e=t.getUTCDay();return 0===e?7:e}function fn(t,e){return hr(Ge.count(er(t)-1,t),e,2)}function dn(t){var e=t.getUTCDay();return e>=4||0===e?Xe(t):Xe.ceil(t)}function mn(t,e){return t=dn(t),hr(Xe.count(er(t),t)+(4===er(t).getUTCDay()),e,2)}function gn(t){return t.getUTCDay()}function yn(t,e){return hr(Ze.count(er(t)-1,t),e,2)}function vn(t,e){return hr(t.getUTCFullYear()%100,e,2)}function _n(t,e){return hr((t=dn(t)).getUTCFullYear()%100,e,2)}function bn(t,e){return hr(t.getUTCFullYear()%1e4,e,4)}function xn(t,e){var r=t.getUTCDay();return hr((t=r>=4||0===r?Xe(t):Xe.ceil(t)).getUTCFullYear()%1e4,e,4)}function wn(){return"+0000"}function En(){return"%"}function Tn(t){return+t}function An(t){return Math.floor(+t/1e3)}!function(t){or=function(t){var e=t.dateTime,r=t.date,n=t.time,i=t.periods,o=t.days,a=t.shortDays,s=t.months,l=t.shortMonths,u=dr(i),c=mr(i),p=dr(o),h=mr(o),f=dr(a),d=mr(a),m=dr(s),g=mr(s),y=dr(l),v=mr(l),_={a:function(t){return a[t.getDay()]},A:function(t){return o[t.getDay()]},b:function(t){return l[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:Lr,e:Lr,f:Ur,g:Qr,G:tn,H:Rr,I:zr,j:Nr,L:jr,m:Vr,M:qr,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Tn,s:An,S:Hr,u:Gr,U:Zr,V:Yr,w:Xr,W:Kr,x:null,X:null,y:Jr,Y:$r,Z:en,"%":En},b={a:function(t){return a[t.getUTCDay()]},A:function(t){return o[t.getUTCDay()]},b:function(t){return l[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:rn,e:rn,f:ln,g:_n,G:xn,H:nn,I:on,j:an,L:sn,m:un,M:cn,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Tn,s:An,S:pn,u:hn,U:fn,V:mn,w:gn,W:yn,x:null,X:null,y:vn,Y:bn,Z:wn,"%":En},x={a:function(t,e,r){var n=f.exec(e.slice(r));return n?(t.w=d.get(n[0].toLowerCase()),r+n[0].length):-1},A:function(t,e,r){var n=p.exec(e.slice(r));return n?(t.w=h.get(n[0].toLowerCase()),r+n[0].length):-1},b:function(t,e,r){var n=y.exec(e.slice(r));return n?(t.m=v.get(n[0].toLowerCase()),r+n[0].length):-1},B:function(t,e,r){var n=m.exec(e.slice(r));return n?(t.m=g.get(n[0].toLowerCase()),r+n[0].length):-1},c:function(t,r,n){return T(t,e,r,n)},d:Cr,e:Cr,f:Mr,g:wr,G:xr,H:Pr,I:Pr,j:Sr,L:Or,m:Ar,M:Ir,p:function(t,e,r){var n=u.exec(e.slice(r));return n?(t.p=c.get(n[0].toLowerCase()),r+n[0].length):-1},q:Tr,Q:kr,s:Fr,S:Dr,u:yr,U:vr,V:_r,w:gr,W:br,x:function(t,e,n){return T(t,r,e,n)},X:function(t,e,r){return T(t,n,e,r)},y:wr,Y:xr,Z:Er,"%":Br};function w(t,e){return function(r){var n,i,o,a=[],s=-1,l=0,u=t.length;for(r instanceof Date||(r=new Date(+r));++s<u;)37===t.charCodeAt(s)&&(a.push(t.slice(l,s)),null!=(i=lr[n=t.charAt(++s)])?n=t.charAt(++s):i="e"===n?" ":"0",(o=e[n])&&(n=o(r,i)),a.push(n),l=s+1);return a.push(t.slice(l,s)),a.join("")}}function E(t,e){return function(r){var n,i,o=ir(1900,void 0,1);if(T(o,t,r+="",0)!=r.length)return null;if("Q"in o)return new Date(o.Q);if("s"in o)return new Date(1e3*o.s+("L"in o?o.L:0));if(e&&!("Z"in o)&&(o.Z=0),"p"in o&&(o.H=o.H%12+12*o.p),void 0===o.m&&(o.m="q"in o?o.q:0),"V"in o){if(o.V<1||o.V>53)return null;"w"in o||(o.w=1),"Z"in o?(i=(n=nr(ir(o.y,0,1))).getUTCDay(),n=i>4||0===i?Ze.ceil(n):Ze(n),n=$e.offset(n,7*(o.V-1)),o.y=n.getUTCFullYear(),o.m=n.getUTCMonth(),o.d=n.getUTCDate()+(o.w+6)%7):(i=(n=rr(ir(o.y,0,1))).getDay(),n=i>4||0===i?Pe.ceil(n):Pe(n),n=Fe.offset(n,7*(o.V-1)),o.y=n.getFullYear(),o.m=n.getMonth(),o.d=n.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),i="Z"in o?nr(ir(o.y,0,1)).getUTCDay():rr(ir(o.y,0,1)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(i+5)%7:o.w+7*o.U-(i+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,nr(o)):rr(o)}}function T(t,e,r,n){for(var i,o,a=0,s=e.length,l=r.length;a<s;){if(n>=l)return-1;if(37===(i=e.charCodeAt(a++))){if(i=e.charAt(a++),!(o=x[i in lr?e.charAt(a++):i])||(n=o(t,r,n))<0)return-1}else if(i!=r.charCodeAt(n++))return-1}return n}return _.x=w(r,_),_.X=w(n,_),_.c=w(e,_),b.x=w(r,b),b.X=w(n,b),b.c=w(e,b),{format:function(t){var e=w(t+="",_);return e.toString=function(){return t},e},parse:function(t){var e=E(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=w(t+="",b);return e.toString=function(){return t},e},utcParse:function(t){var e=E(t+="",!0);return e.toString=function(){return t},e}}}(t),ar=or.format,or.parse,sr=or.utcFormat,or.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Cn(t){return new Date(t)}function Sn(t){return t instanceof Date?+t:+new Date(+t)}function Pn(t,e,r,n,i,o,a,s,l){var u=Tt(),c=u.invert,p=u.domain,h=l(".%L"),f=l(":%S"),d=l("%I:%M"),m=l("%I %p"),y=l("%a %d"),_=l("%b %d"),b=l("%B"),x=l("%Y"),w=[[a,1,1e3],[a,5,5e3],[a,15,15e3],[a,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[n,1,864e5],[n,2,1728e5],[r,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function E(s){return(a(s)<s?h:o(s)<s?f:i(s)<s?d:n(s)<s?m:e(s)<s?r(s)<s?y:_:t(s)<s?b:x)(s)}function T(e,r,n){if(null==e&&(e=10),"number"==typeof e){var i,o=Math.abs(n-r)/e,a=v((function(t){return t[2]})).right(w,o);return a===w.length?(i=g(r/31536e6,n/31536e6,e),e=t):a?(i=(a=w[o/w[a-1][2]<w[a][2]/o?a-1:a])[1],e=a[0]):(i=Math.max(g(r,n,e),1),e=s),e.every(i)}return e}return u.invert=function(t){return new Date(c(t))},u.domain=function(t){return arguments.length?p(Array.from(t,Sn)):p().map(Cn)},u.ticks=function(t){var e,r=p(),n=r[0],i=r[r.length-1],o=i<n;return o&&(e=n,n=i,i=e),e=(e=T(t,n,i))?e.range(n,i+1):[],o?e.reverse():e},u.tickFormat=function(t,e){return null==e?E:l(e)},u.nice=function(t){var e=p();return(t=T(t,e[0],e[e.length-1]))?p(qt(e,t)):u},u.copy=function(){return wt(u,Pn(t,e,r,n,i,o,a,s,l))},u}function In(){return i.apply(Pn(Ee,Ae,Se,Fe,Re,Ne,Ue,qe,ar).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var Dn=xe((function(t){t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCMonth(t.getUTCMonth()+e)}),(function(t,e){return e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())}),(function(t){return t.getUTCMonth()})),On=Dn,Mn=(Dn.range,xe((function(t){t.setUTCMinutes(0,0,0)}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getUTCHours()}))),Bn=Mn,kn=(Mn.range,xe((function(t){t.setUTCSeconds(0,0)}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getUTCMinutes()}))),Fn=kn;kn.range;function Ln(){return i.apply(Pn(er,On,Ge,$e,Bn,Fn,Ue,qe,sr).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Rn(){var t,e,r,n,i,o=0,a=1,s=vt,l=!1;function u(e){return isNaN(e=+e)?i:s(0===r?.5:(e=(n(e)-t)*r,l?Math.max(0,Math.min(1,e)):e))}function c(t){return function(e){var r,n;return arguments.length?([r,n]=e,s=t(r,n),u):[s(0),s(1)]}}return u.domain=function(i){return arguments.length?([o,a]=i,t=n(o=+o),e=n(a=+a),r=t===e?0:1/(e-t),u):[o,a]},u.clamp=function(t){return arguments.length?(l=!!t,u):l},u.interpolator=function(t){return arguments.length?(s=t,u):s},u.range=c(dt),u.rangeRound=c(mt),u.unknown=function(t){return arguments.length?(i=t,u):i},function(i){return n=i,t=i(o),e=i(a),r=t===e?0:1/(e-t),u}}function zn(t,e){return e.domain(t.domain()).interpolator(t.interpolator()).clamp(t.clamp()).unknown(t.unknown())}function Nn(){var t=jt(Rn()(vt));return t.copy=function(){return zn(t,Nn())},o.apply(t,arguments)}function jn(){var t=Kt(Rn()).domain([1,10]);return t.copy=function(){return zn(t,jn()).base(t.base())},o.apply(t,arguments)}function Un(){var t=te(Rn());return t.copy=function(){return zn(t,Un()).constant(t.constant())},o.apply(t,arguments)}function Vn(){var t=oe(Rn());return t.copy=function(){return zn(t,Vn()).exponent(t.exponent())},o.apply(t,arguments)}function qn(){return Vn.apply(null,arguments).exponent(.5)}function Hn(){var t=[],e=vt;function r(r){if(!isNaN(r=+r))return e((w(t,r,1)-1)/(t.length-1))}return r.domain=function(e){if(!arguments.length)return t.slice();t=[];for(let r of e)null==r||isNaN(r=+r)||t.push(r);return t.sort(y),r},r.interpolator=function(t){return arguments.length?(e=t,r):e},r.range=function(){return t.map((r,n)=>e(n/(t.length-1)))},r.quantiles=function(e){return Array.from({length:e+1},(r,n)=>de(t,n/e))},r.copy=function(){return Hn(e).domain(t)},o.apply(r,arguments)}function Gn(t,e){void 0===e&&(e=t,t=dt);for(var r=0,n=e.length-1,i=e[0],o=new Array(n<0?0:n);r<n;)o[r]=t(i,i=e[++r]);return function(t){var e=Math.max(0,Math.min(n-1,Math.floor(t*=n)));return o[e](t-e)}}function Zn(){var t,e,r,n,i,o,a,s=0,l=.5,u=1,c=1,p=vt,h=!1;function f(t){return isNaN(t=+t)?a:(t=.5+((t=+o(t))-e)*(c*t<c*e?n:i),p(h?Math.max(0,Math.min(1,t)):t))}function d(t){return function(e){var r,n,i;return arguments.length?([r,n,i]=e,p=Gn(t,[r,n,i]),f):[p(0),p(.5),p(1)]}}return f.domain=function(a){return arguments.length?([s,l,u]=a,t=o(s=+s),e=o(l=+l),r=o(u=+u),n=t===e?0:.5/(e-t),i=e===r?0:.5/(r-e),c=e<t?-1:1,f):[s,l,u]},f.clamp=function(t){return arguments.length?(h=!!t,f):h},f.interpolator=function(t){return arguments.length?(p=t,f):p},f.range=d(dt),f.rangeRound=d(mt),f.unknown=function(t){return arguments.length?(a=t,f):a},function(a){return o=a,t=a(s),e=a(l),r=a(u),n=t===e?0:.5/(e-t),i=e===r?0:.5/(r-e),c=e<t?-1:1,f}}function Wn(){var t=jt(Zn()(vt));return t.copy=function(){return zn(t,Wn())},o.apply(t,arguments)}function Yn(){var t=Kt(Zn()).domain([.1,1,10]);return t.copy=function(){return zn(t,Yn()).base(t.base())},o.apply(t,arguments)}function Xn(){var t=te(Zn());return t.copy=function(){return zn(t,Xn()).constant(t.constant())},o.apply(t,arguments)}function Kn(){var t=oe(Zn());return t.copy=function(){return zn(t,Kn()).exponent(t.exponent())},o.apply(t,arguments)}function Jn(){return Kn.apply(null,arguments).exponent(.5)}},function(t,e,r){"use strict";function n(){return(n=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}r.r(e),r.d(e,"default",(function(){return Be})),r.d(e,"InteractiveMap",(function(){return Be})),r.d(e,"StaticMap",(function(){return Ot})),r.d(e,"Source",(function(){return Ue})),r.d(e,"Layer",(function(){return Xe})),r.d(e,"BaseControl",(function(){return rr})),r.d(e,"Marker",(function(){return yr})),r.d(e,"Popup",(function(){return Sr})),r.d(e,"AttributionControl",(function(){return Mr})),r.d(e,"FullscreenControl",(function(){return Nr})),r.d(e,"GeolocateControl",(function(){return Wr})),r.d(e,"NavigationControl",(function(){return rn})),r.d(e,"ScaleControl",(function(){return ln})),r.d(e,"CanvasOverlay",(function(){return hn})),r.d(e,"HTMLOverlay",(function(){return gn})),r.d(e,"SVGOverlay",(function(){return bn})),r.d(e,"TRANSITION_EVENTS",(function(){return oe})),r.d(e,"TransitionInterpolator",(function(){return kt})),r.d(e,"LinearInterpolator",(function(){return ne})),r.d(e,"FlyToInterpolator",(function(){return Qt})),r.d(e,"MapController",(function(){return be})),r.d(e,"WebMercatorViewport",(function(){return W})),r.d(e,"setRTLTextPlugin",(function(){return xn})),r.d(e,"MapContext",(function(){return bt})),r.d(e,"_useMapControl",(function(){return $e})),r.d(e,"_MapContext",(function(){return bt}));var i=r(10);var o=r(16);function a(t){return function(t){if(Array.isArray(t))return Object(i.a)(t)}(t)||function(t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(t))return Array.from(t)}(t)||Object(o.a)(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var s=r(2),l=r(1),u=r(0),c=r(3),p=r(4),h=r(5),f=1e-6,d="undefined"!=typeof Float32Array?Float32Array:Array;Math.random;Math.PI;Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});var m,g;m=new d(4),d!=Float32Array&&(m[0]=0,m[1]=0,m[2]=0,m[3]=0),g=m;function y(t,e){var r=function(t,e,r){var n=e[0],i=e[1],o=e[2],a=e[3];return t[0]=r[0]*n+r[4]*i+r[8]*o+r[12]*a,t[1]=r[1]*n+r[5]*i+r[9]*o+r[13]*a,t[2]=r[2]*n+r[6]*i+r[10]*o+r[14]*a,t[3]=r[3]*n+r[7]*i+r[11]*o+r[15]*a,t}([],e,t);return function(t,e,r){t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r}(r,r,1/r[3]),r}function v(t,e){var r=t%e;return r<0?e+r:r}function _(t,e,r){return r*e+(1-r)*t}function b(t,e,r){var n=e[0],i=e[1],o=e[2],a=e[3],s=e[4],l=e[5],u=e[6],c=e[7],p=e[8],h=e[9],f=e[10],d=e[11],m=e[12],g=e[13],y=e[14],v=e[15],_=r[0],b=r[1],x=r[2],w=r[3];return t[0]=_*n+b*s+x*p+w*m,t[1]=_*i+b*l+x*h+w*g,t[2]=_*o+b*u+x*f+w*y,t[3]=_*a+b*c+x*d+w*v,_=r[4],b=r[5],x=r[6],w=r[7],t[4]=_*n+b*s+x*p+w*m,t[5]=_*i+b*l+x*h+w*g,t[6]=_*o+b*u+x*f+w*y,t[7]=_*a+b*c+x*d+w*v,_=r[8],b=r[9],x=r[10],w=r[11],t[8]=_*n+b*s+x*p+w*m,t[9]=_*i+b*l+x*h+w*g,t[10]=_*o+b*u+x*f+w*y,t[11]=_*a+b*c+x*d+w*v,_=r[12],b=r[13],x=r[14],w=r[15],t[12]=_*n+b*s+x*p+w*m,t[13]=_*i+b*l+x*h+w*g,t[14]=_*o+b*u+x*f+w*y,t[15]=_*a+b*c+x*d+w*v,t}function x(t,e,r){var n,i,o,a,s,l,u,c,p,h,f,d,m=r[0],g=r[1],y=r[2];return e===t?(t[12]=e[0]*m+e[4]*g+e[8]*y+e[12],t[13]=e[1]*m+e[5]*g+e[9]*y+e[13],t[14]=e[2]*m+e[6]*g+e[10]*y+e[14],t[15]=e[3]*m+e[7]*g+e[11]*y+e[15]):(n=e[0],i=e[1],o=e[2],a=e[3],s=e[4],l=e[5],u=e[6],c=e[7],p=e[8],h=e[9],f=e[10],d=e[11],t[0]=n,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=l,t[6]=u,t[7]=c,t[8]=p,t[9]=h,t[10]=f,t[11]=d,t[12]=n*m+s*g+p*y+e[12],t[13]=i*m+l*g+h*y+e[13],t[14]=o*m+u*g+f*y+e[14],t[15]=a*m+c*g+d*y+e[15]),t}function w(t,e,r){var n=r[0],i=r[1],o=r[2];return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function E(t,e){var r=t[0],n=t[1],i=t[2],o=t[3],a=t[4],s=t[5],l=t[6],u=t[7],c=t[8],p=t[9],h=t[10],d=t[11],m=t[12],g=t[13],y=t[14],v=t[15],_=e[0],b=e[1],x=e[2],w=e[3],E=e[4],T=e[5],A=e[6],C=e[7],S=e[8],P=e[9],I=e[10],D=e[11],O=e[12],M=e[13],B=e[14],k=e[15];return Math.abs(r-_)<=f*Math.max(1,Math.abs(r),Math.abs(_))&&Math.abs(n-b)<=f*Math.max(1,Math.abs(n),Math.abs(b))&&Math.abs(i-x)<=f*Math.max(1,Math.abs(i),Math.abs(x))&&Math.abs(o-w)<=f*Math.max(1,Math.abs(o),Math.abs(w))&&Math.abs(a-E)<=f*Math.max(1,Math.abs(a),Math.abs(E))&&Math.abs(s-T)<=f*Math.max(1,Math.abs(s),Math.abs(T))&&Math.abs(l-A)<=f*Math.max(1,Math.abs(l),Math.abs(A))&&Math.abs(u-C)<=f*Math.max(1,Math.abs(u),Math.abs(C))&&Math.abs(c-S)<=f*Math.max(1,Math.abs(c),Math.abs(S))&&Math.abs(p-P)<=f*Math.max(1,Math.abs(p),Math.abs(P))&&Math.abs(h-I)<=f*Math.max(1,Math.abs(h),Math.abs(I))&&Math.abs(d-D)<=f*Math.max(1,Math.abs(d),Math.abs(D))&&Math.abs(m-O)<=f*Math.max(1,Math.abs(m),Math.abs(O))&&Math.abs(g-M)<=f*Math.max(1,Math.abs(g),Math.abs(M))&&Math.abs(y-B)<=f*Math.max(1,Math.abs(y),Math.abs(B))&&Math.abs(v-k)<=f*Math.max(1,Math.abs(v),Math.abs(k))}function T(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t}function A(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t}function C(t){var e=t[0],r=t[1];return Math.hypot(e,r)}function S(t,e,r,n){var i=e[0],o=e[1];return t[0]=i+n*(r[0]-i),t[1]=o+n*(r[1]-o),t}var P=function(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t};!function(){var t=function(){var t=new d(2);return d!=Float32Array&&(t[0]=0,t[1]=0),t}()}();!function(){var t=function(){var t=new d(3);return d!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t}()}();function I(t,e){if(!t)throw new Error(e||"@math.gl/web-mercator: assertion failed.")}var D=Math.PI,O=D/4,M=D/180,B=180/D;function k(t){return Math.pow(2,t)}function F(t){return Math.log2(t)}function L(t){var e=Object(c.a)(t,2),r=e[0],n=e[1];I(Number.isFinite(r)),I(Number.isFinite(n)&&n>=-90&&n<=90,"invalid latitude");var i=n*M;return[512*(r*M+D)/(2*D),512*(D+Math.log(Math.tan(O+.5*i)))/(2*D)]}function R(t){var e=Object(c.a)(t,2),r=e[0],n=e[1],i=r/512*(2*D)-D,o=2*(Math.atan(Math.exp(n/512*(2*D)-D))-O);return[i*B,o*B]}function z(t){var e=t.latitude,r=t.longitude,n=t.highPrecision,i=void 0!==n&&n;I(Number.isFinite(e)&&Number.isFinite(r));var o={},a=Math.cos(e*M),s=512/360/a,l=512/4003e4/a;if(o.unitsPerMeter=[l,l,l],o.metersPerUnit=[1/l,1/l,1/l],o.unitsPerDegree=[512/360,s,l],o.degreesPerUnit=[.703125,1/s,1/l],i){var u=M*Math.tan(e*M)/a,c=512/360*u/2,p=512/4003e4*u,h=p/s*l;o.unitsPerDegree2=[0,c,p],o.unitsPerMeter2=[h,0,h]}return o}function N(t){var e=t.height,r=t.pitch,n=t.bearing,i=t.altitude,o=t.scale,a=t.center,s=void 0===a?null:a,l=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];return x(l,l,[0,0,-i]),function(t,e,r){var n=Math.sin(r),i=Math.cos(r),o=e[4],a=e[5],s=e[6],l=e[7],u=e[8],c=e[9],p=e[10],h=e[11];e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=o*i+u*n,t[5]=a*i+c*n,t[6]=s*i+p*n,t[7]=l*i+h*n,t[8]=u*i-o*n,t[9]=c*i-a*n,t[10]=p*i-s*n,t[11]=h*i-l*n}(l,l,-r*M),function(t,e,r){var n=Math.sin(r),i=Math.cos(r),o=e[0],a=e[1],s=e[2],l=e[3],u=e[4],c=e[5],p=e[6],h=e[7];e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i+u*n,t[1]=a*i+c*n,t[2]=s*i+p*n,t[3]=l*i+h*n,t[4]=u*i-o*n,t[5]=c*i-a*n,t[6]=p*i-s*n,t[7]=h*i-l*n}(l,l,n*M),w(l,l,[o/=e,o,o]),s&&x(l,l,function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t}([],s)),l}function j(t){var e=t.width,r=t.height,n=t.pitch,i=function(t){var e=t.width,r=t.height,n=t.altitude,i=void 0===n?1.5:n,o=t.pitch,a=void 0===o?0:o,s=t.nearZMultiplier,l=void 0===s?1:s,u=t.farZMultiplier,c=void 0===u?1:u,p=a*M,h=Math.atan(.5/i),f=Math.sin(h)*i/Math.sin(Math.min(Math.max(Math.PI/2-p-h,.01),Math.PI-.01));return{fov:2*h,aspect:e/r,focalDistance:i,near:l,far:(Math.sin(p)*f+i)*c}}({width:e,height:r,altitude:t.altitude,pitch:n,nearZMultiplier:t.nearZMultiplier,farZMultiplier:t.farZMultiplier});return function(t,e,r,n,i){var o,a=1/Math.tan(e/2);return t[0]=a/r,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=a,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=i&&i!==1/0?(o=1/(n-i),t[10]=(i+n)*o,t[14]=2*i*n*o):(t[10]=-1,t[14]=-2*n),t}([],i.fov,i.aspect,i.near,i.far)}function U(t,e){var r=Object(c.a)(t,3),n=r[0],i=r[1],o=r[2],a=void 0===o?0:o;return I(Number.isFinite(n)&&Number.isFinite(i)&&Number.isFinite(a)),y(e,[n,i,a,1])}function V(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=Object(c.a)(t,3),i=n[0],o=n[1],a=n[2];if(I(Number.isFinite(i)&&Number.isFinite(o),"invalid pixel coordinate"),Number.isFinite(a)){var s=y(e,[i,o,a,1]);return s}var l=y(e,[i,o,0,1]),u=y(e,[i,o,1,1]),p=l[2],h=u[2],f=p===h?0:((r||0)-p)/(h-p);return S([],l,u,f)}function q(t){var e=t.width,r=t.height,n=t.bounds,i=t.minExtent,o=void 0===i?0:i,a=t.maxZoom,s=void 0===a?24:a,l=t.padding,u=void 0===l?0:l,p=t.offset,h=void 0===p?[0,0]:p,f=Object(c.a)(n,2),d=Object(c.a)(f[0],2),m=d[0],g=d[1],y=Object(c.a)(f[1],2),v=y[0],_=y[1];if(Number.isFinite(u)){u={top:u,bottom:u,left:u,right:u}}else I(Number.isFinite(u.top)&&Number.isFinite(u.bottom)&&Number.isFinite(u.left)&&Number.isFinite(u.right));var b=new W({width:e,height:r,longitude:0,latitude:0,zoom:0}),x=b.project([m,_]),w=b.project([v,g]),E=[Math.max(Math.abs(w[0]-x[0]),o),Math.max(Math.abs(w[1]-x[1]),o)],T=[e-u.left-u.right-2*Math.abs(h[0]),r-u.top-u.bottom-2*Math.abs(h[1])];I(T[0]>0&&T[1]>0);var A=T[0]/E[0],C=T[1]/E[1],S=(u.right-u.left)/2/A,P=(u.bottom-u.top)/2/C,D=[(w[0]+x[0])/2+S,(w[1]+x[1])/2+P],O=b.unproject(D),M=Math.min(s,b.zoom+Math.log2(Math.abs(Math.min(A,C))));return I(Number.isFinite(M)),{longitude:O[0],latitude:O[1],zoom:M}}var H=Math.PI/180;function G(t){var e,r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=t.width,o=t.height,a=t.unproject,s={targetZ:n},l=a([0,o],s),u=a([i,o],s),c=Math.atan(.5/t.altitude),p=(90-t.pitch)*H;return c>p-.01?(e=Z(t,0,n),r=Z(t,i,n)):(e=a([0,0],s),r=a([i,0],s)),[l,u,r,e]}function Z(t,e,r){var n=t.pixelUnprojectionMatrix,i=y(n,[e,0,1,1]),o=y(n,[e,t.height,1,1]),a=R(S([],i,o,(r*t.distanceScales.unitsPerMeter[2]-i[2])/(o[2]-i[2])));return a[2]=r,a}var W=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{width:1,height:1},r=e.width,n=e.height,i=e.latitude,o=void 0===i?0:i,a=e.longitude,s=void 0===a?0:a,l=e.zoom,u=void 0===l?0:l,c=e.pitch,h=void 0===c?0:c,f=e.bearing,d=void 0===f?0:f,m=e.altitude,g=void 0===m?1.5:m,y=e.nearZMultiplier,v=void 0===y?.02:y,_=e.farZMultiplier,b=void 0===_?1.01:_;Object(p.a)(this,t),r=r||1,n=n||1;var x=k(u);g=Math.max(.75,g);var w=L([s,o]);w[2]=0,this.projectionMatrix=j({width:r,height:n,pitch:h,altitude:g,nearZMultiplier:v,farZMultiplier:b}),this.viewMatrix=N({height:n,scale:x,center:w,pitch:h,bearing:d,altitude:g}),this.width=r,this.height=n,this.scale=x,this.latitude=o,this.longitude=s,this.zoom=u,this.pitch=h,this.bearing=d,this.altitude=g,this.center=w,this.distanceScales=z(this),this._initMatrices(),this.equals=this.equals.bind(this),this.project=this.project.bind(this),this.unproject=this.unproject.bind(this),this.projectPosition=this.projectPosition.bind(this),this.unprojectPosition=this.unprojectPosition.bind(this),Object.freeze(this)}return Object(h.a)(t,[{key:"_initMatrices",value:function(){var t=this.width,e=this.height,r=this.projectionMatrix,n=this.viewMatrix,i=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];b(i,i,r),b(i,i,n),this.viewProjectionMatrix=i;var o=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];w(o,o,[t/2,-e/2,1]),x(o,o,[1,-1,0]),b(o,o,i);var a=function(t,e){var r=e[0],n=e[1],i=e[2],o=e[3],a=e[4],s=e[5],l=e[6],u=e[7],c=e[8],p=e[9],h=e[10],f=e[11],d=e[12],m=e[13],g=e[14],y=e[15],v=r*s-n*a,_=r*l-i*a,b=r*u-o*a,x=n*l-i*s,w=n*u-o*s,E=i*u-o*l,T=c*m-p*d,A=c*g-h*d,C=c*y-f*d,S=p*g-h*m,P=p*y-f*m,I=h*y-f*g,D=v*I-_*P+b*S+x*C-w*A+E*T;return D?(D=1/D,t[0]=(s*I-l*P+u*S)*D,t[1]=(i*P-n*I-o*S)*D,t[2]=(m*E-g*w+y*x)*D,t[3]=(h*w-p*E-f*x)*D,t[4]=(l*C-a*I-u*A)*D,t[5]=(r*I-i*C+o*A)*D,t[6]=(g*b-d*E-y*_)*D,t[7]=(c*E-h*b+f*_)*D,t[8]=(a*P-s*C+u*T)*D,t[9]=(n*C-r*P-o*T)*D,t[10]=(d*w-m*b+y*v)*D,t[11]=(p*b-c*w-f*v)*D,t[12]=(s*A-a*S-l*T)*D,t[13]=(r*S-n*A+i*T)*D,t[14]=(m*_-d*x-g*v)*D,t[15]=(c*x-p*_+h*v)*D,t):null}([1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],o);if(!a)throw new Error("Pixel project matrix not invertible");this.pixelProjectionMatrix=o,this.pixelUnprojectionMatrix=a}},{key:"equals",value:function(e){return e instanceof t&&(e.width===this.width&&e.height===this.height&&E(e.projectionMatrix,this.projectionMatrix)&&E(e.viewMatrix,this.viewMatrix))}},{key:"project",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e.topLeft,n=void 0===r||r,i=this.projectPosition(t),o=U(i,this.pixelProjectionMatrix),a=Object(c.a)(o,2),s=a[0],l=a[1],u=n?l:this.height-l;return 2===t.length?[s,u]:[s,u,o[2]]}},{key:"unproject",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e.topLeft,n=void 0===r||r,i=e.targetZ,o=void 0===i?void 0:i,a=Object(c.a)(t,3),s=a[0],l=a[1],u=a[2],p=n?l:this.height-l,h=o&&o*this.distanceScales.unitsPerMeter[2],f=V([s,p,u],this.pixelUnprojectionMatrix,h),d=this.unprojectPosition(f),m=Object(c.a)(d,3),g=m[0],y=m[1],v=m[2];return Number.isFinite(u)?[g,y,v]:Number.isFinite(o)?[g,y,o]:[g,y]}},{key:"projectPosition",value:function(t){var e=L(t),r=Object(c.a)(e,2);return[r[0],r[1],(t[2]||0)*this.distanceScales.unitsPerMeter[2]]}},{key:"unprojectPosition",value:function(t){var e=R(t),r=Object(c.a)(e,2);return[r[0],r[1],(t[2]||0)*this.distanceScales.metersPerUnit[2]]}},{key:"projectFlat",value:function(t){return L(t)}},{key:"unprojectFlat",value:function(t){return R(t)}},{key:"getMapCenterByLngLatPosition",value:function(t){var e=t.lngLat,r=V(t.pos,this.pixelUnprojectionMatrix),n=T([],L(e),function(t,e){return t[0]=-e[0],t[1]=-e[1],t}([],r));return R(T([],this.center,n))}},{key:"getLocationAtPoint",value:function(t){var e=t.lngLat,r=t.pos;return this.getMapCenterByLngLatPosition({lngLat:e,pos:r})}},{key:"fitBounds",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.width,i=this.height,o=q(Object.assign({width:n,height:i,bounds:e},r)),a=o.longitude,s=o.latitude,l=o.zoom;return new t({width:n,height:i,longitude:a,latitude:s,zoom:l})}},{key:"getBounds",value:function(t){var e=this.getBoundingRegion(t),r=Math.min.apply(Math,a(e.map((function(t){return t[0]})))),n=Math.max.apply(Math,a(e.map((function(t){return t[0]}))));return[[r,Math.min.apply(Math,a(e.map((function(t){return t[1]}))))],[n,Math.max.apply(Math,a(e.map((function(t){return t[1]}))))]]}},{key:"getBoundingRegion",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return G(this,t.z||0)}}]),t}();function Y(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return X(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return X(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}function X(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var K=["longitude","latitude","zoom"],J={curve:1.414,speed:1.2};function Q(t,e,r){var n=(r=Object.assign({},J,r)).curve,i=t.zoom,o=[t.longitude,t.latitude],a=k(i),s=e.zoom,l=[e.longitude,e.latitude],u=k(s-i),c=L(o),p=L(l),h=P([],p,c),f=Math.max(t.width,t.height),d=f/u,m=C(h)*a,g=Math.max(m,.01),y=n*n,v=(d*d-f*f+y*y*g*g)/(2*f*y*g),_=(d*d-f*f-y*y*g*g)/(2*d*y*g),b=Math.log(Math.sqrt(v*v+1)-v),x=Math.log(Math.sqrt(_*_+1)-_);return{startZoom:i,startCenterXY:c,uDelta:h,w0:f,u1:m,S:(x-b)/n,rho:n,rho2:y,r0:b,r1:x}}var $=r(35),tt=r(17),et=r(31),rt=r.n(et);function nt(t){return Array.isArray(t)||ArrayBuffer.isView(t)}function it(t,e){if(t===e)return!0;if(nt(t)&&nt(e)){if(t.length!==e.length)return!1;for(var r=0;r<t.length;++r)if(!it(t[r],e[r]))return!1;return!0}return Math.abs(t-e)<=1e-7}function ot(t,e,r){return Math.max(e,Math.min(r,t))}function at(t,e,r){return nt(t)?t.map((function(t,n){return at(t,e[n],r)})):r*e+(1-r)*t}function st(t,e){if(!t)throw new Error(e||"react-map-gl: assertion failed.")}function lt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ut(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?lt(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):lt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var ct={minZoom:0,maxZoom:24,minPitch:0,maxPitch:60},pt=0,ht=0,ft=1.5,dt=function(){function t(e){var r=e.width,n=e.height,i=e.latitude,o=e.longitude,a=e.zoom,s=e.bearing,l=void 0===s?ht:s,u=e.pitch,c=void 0===u?pt:u,h=e.altitude,f=void 0===h?ft:h,d=e.maxZoom,m=void 0===d?ct.maxZoom:d,g=e.minZoom,y=void 0===g?ct.minZoom:g,v=e.maxPitch,_=void 0===v?ct.maxPitch:v,b=e.minPitch,x=void 0===b?ct.minPitch:b,w=e.transitionDuration,E=e.transitionEasing,T=e.transitionInterpolator,A=e.transitionInterruption,C=e.startPanLngLat,S=e.startZoomLngLat,P=e.startRotatePos,I=e.startBearing,D=e.startPitch,O=e.startZoom;Object(p.a)(this,t),st(Number.isFinite(r),"`width` must be supplied"),st(Number.isFinite(n),"`height` must be supplied"),st(Number.isFinite(o),"`longitude` must be supplied"),st(Number.isFinite(i),"`latitude` must be supplied"),st(Number.isFinite(a),"`zoom` must be supplied"),this._viewportProps=this._applyConstraints({width:r,height:n,latitude:i,longitude:o,zoom:a,bearing:l,pitch:c,altitude:f,maxZoom:m,minZoom:y,maxPitch:_,minPitch:x,transitionDuration:w,transitionEasing:E,transitionInterpolator:T,transitionInterruption:A}),this._state={startPanLngLat:C,startZoomLngLat:S,startRotatePos:P,startBearing:I,startPitch:D,startZoom:O}}return Object(h.a)(t,[{key:"getViewportProps",value:function(){return this._viewportProps}},{key:"getState",value:function(){return this._state}},{key:"panStart",value:function(t){var e=t.pos;return this._getUpdatedMapState({startPanLngLat:this._unproject(e)})}},{key:"pan",value:function(t){var e=t.pos,r=t.startPos,n=this._state.startPanLngLat||this._unproject(r);if(!n)return this;var i=this._calculateNewLngLat({startPanLngLat:n,pos:e}),o=Object(c.a)(i,2),a=o[0],s=o[1];return this._getUpdatedMapState({longitude:a,latitude:s})}},{key:"panEnd",value:function(){return this._getUpdatedMapState({startPanLngLat:null})}},{key:"rotateStart",value:function(t){var e=t.pos;return this._getUpdatedMapState({startRotatePos:e,startBearing:this._viewportProps.bearing,startPitch:this._viewportProps.pitch})}},{key:"rotate",value:function(t){var e,r=t.pos,n=t.deltaAngleX,i=void 0===n?0:n,o=t.deltaAngleY,a=void 0===o?0:o,s=this._state,l=s.startRotatePos,u=s.startBearing,c=s.startPitch;return Number.isFinite(u)&&Number.isFinite(c)?(e=r?this._calculateNewPitchAndBearing(ut(ut({},this._getRotationParams(r,l)),{},{startBearing:u,startPitch:c})):{bearing:u+i,pitch:c+a},this._getUpdatedMapState(e)):this}},{key:"rotateEnd",value:function(){return this._getUpdatedMapState({startBearing:null,startPitch:null})}},{key:"zoomStart",value:function(t){var e=t.pos;return this._getUpdatedMapState({startZoomLngLat:this._unproject(e),startZoom:this._viewportProps.zoom})}},{key:"zoom",value:function(t){var e=t.pos,r=t.startPos,n=t.scale;st(n>0,"`scale` must be a positive number");var i=this._state,o=i.startZoom,a=i.startZoomLngLat;Number.isFinite(o)||(o=this._viewportProps.zoom,a=this._unproject(r)||this._unproject(e)),st(a,"`startZoomLngLat` prop is required for zoom behavior to calculate where to position the map.");var s=this._calculateNewZoom({scale:n,startZoom:o||0}),l=new W(Object.assign({},this._viewportProps,{zoom:s})).getMapCenterByLngLatPosition({lngLat:a,pos:e}),u=Object(c.a)(l,2),p=u[0],h=u[1];return this._getUpdatedMapState({zoom:s,longitude:p,latitude:h})}},{key:"zoomEnd",value:function(){return this._getUpdatedMapState({startZoomLngLat:null,startZoom:null})}},{key:"_getUpdatedMapState",value:function(e){return new t(Object.assign({},this._viewportProps,this._state,e))}},{key:"_applyConstraints",value:function(t){var e=t.maxZoom,r=t.minZoom,n=t.zoom;t.zoom=ot(n,r,e);var i=t.maxPitch,o=t.minPitch,a=t.pitch;return t.pitch=ot(a,o,i),Object.assign(t,function(t){var e=t.width,r=t.height,n=t.longitude,i=t.latitude,o=t.zoom,a=t.pitch,s=void 0===a?0:a,l=t.bearing,u=void 0===l?0:l;(n<-180||n>180)&&(n=v(n+180,360)-180),(u<-180||u>180)&&(u=v(u+180,360)-180);var c=new W({width:e,height:r,longitude:n,latitude:i,zoom:o}),p=c.project([n,85.05113])[1],h=c.project([n,-85.05113])[1],f=0;return h-p<r&&(o+=Math.log2(r/(h-p)),p=(c=new W({width:e,height:r,longitude:n,latitude:i,zoom:o})).project([n,85.05113])[1],h=c.project([n,-85.05113])[1]),p>0?f=p:h<r&&(f=h-r),f&&(i=c.unproject([e/2,r/2+f])[1]),{width:e,height:r,longitude:n,latitude:i,zoom:o,pitch:s,bearing:u}}(t)),t}},{key:"_unproject",value:function(t){var e=new W(this._viewportProps);return t&&e.unproject(t)}},{key:"_calculateNewLngLat",value:function(t){var e=t.startPanLngLat,r=t.pos;return new W(this._viewportProps).getMapCenterByLngLatPosition({lngLat:e,pos:r})}},{key:"_calculateNewZoom",value:function(t){var e=t.scale,r=t.startZoom,n=this._viewportProps,i=n.maxZoom,o=n.minZoom;return ot(r+Math.log2(e),o,i)}},{key:"_calculateNewPitchAndBearing",value:function(t){var e=t.deltaScaleX,r=t.deltaScaleY,n=t.startBearing,i=t.startPitch;r=ot(r,-1,1);var o=this._viewportProps,a=o.minPitch,s=o.maxPitch,l=i;return r>0?l=i+r*(s-i):r<0&&(l=i-r*(a-i)),{pitch:l,bearing:n+180*e}}},{key:"_getRotationParams",value:function(t,e){var r=t[0]-e[0],n=t[1]-e[1],i=t[1],o=e[1],a=this._viewportProps,s=a.width,l=a.height,u=r/s,c=0;return n>0?Math.abs(l-o)>5&&(c=n/(o-l)*1.2):n<0&&o>5&&(c=1-i/o),{deltaScaleX:u,deltaScaleY:c=Math.min(1,Math.max(-1,c))}}}]),t}();function mt(t){return t[0].toLowerCase()+t.slice(1)}function gt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function yt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?gt(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):gt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var vt=Object(l.createContext)({viewport:null,map:null,container:null,onViewportChange:null,onViewStateChange:null,eventManager:null}),_t=vt.Provider;vt.Provider=function(t){var e=t.value,r=t.children,n=Object(l.useState)(null),i=Object(c.a)(n,2),o=i[0],a=i[1],s=Object(l.useContext)(vt);return e=yt(yt({setMap:a},s),{},{map:s&&s.map||o},e),l.createElement(_t,{value:e},r)};var bt=vt,xt="undefined"!=typeof window?l.useLayoutEffect:l.useEffect;function wt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Et(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?wt(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):wt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var Tt="A valid API access token is required to use Mapbox data";var At={position:"absolute",width:"100%",height:"100%",overflow:"hidden"},Ct=Object.assign({},tt.a.propTypes,{width:u.oneOfType([u.number,u.string]),height:u.oneOfType([u.number,u.string]),onResize:u.func,disableTokenWarning:u.bool,visible:u.bool,className:u.string,style:u.object,visibilityConstraints:u.object}),St=Object.assign({},tt.a.defaultProps,{disableTokenWarning:!1,visible:!0,onResize:function(){},className:"",style:null,visibilityConstraints:ct});function Pt(){return l.createElement("div",{key:"warning",id:"no-token-warning",style:{position:"absolute",left:0,top:0}},l.createElement("h3",{key:"header"},Tt),l.createElement("div",{key:"text"},"For information on setting up your basemap, read"),l.createElement("a",{key:"link",href:"https://visgl.github.io/react-map-gl/docs/get-started/mapbox-tokens"},"Note on Map Tokens"))}function It(t){t.target.scrollTo(0,0)}var Dt=Object(l.forwardRef)((function(t,e){var r=Object(l.useState)(!0),n=Object(c.a)(r,2),i=n[0],o=n[1],a=Object(l.useState)([0,0]),s=Object(c.a)(a,2),u=s[0],p=s[1],h=Object(l.useRef)(null),f=Object(l.useRef)(null),d=Object(l.useRef)(null),m=Object(l.useContext)(bt);xt((function(){if(Dt.supported()){var e=new tt.a(Et(Et({},t),{},{mapboxgl:rt.a,width:u[0],height:u[1],container:f.current,onError:function(e){401===(e.error&&e.error.status||e.status)&&i&&(console.error(Tt),o(!1)),t.onError(e)}}));h.current=e,m&&m.setMap&&m.setMap(e.getMap());var r=new $.a((function(e){if(e[0].contentRect){var r=e[0].contentRect,n=r.width,i=r.height;p([n,i]),t.onResize({width:n,height:i})}}));return r.observe(d.current),function(){e.finalize(),h.current=null,r.disconnect()}}}),[]),xt((function(){h.current&&h.current.setProps(Object.assign({},t,{width:u[0],height:u[1]}))}));var g=h.current&&h.current.getMap();Object(l.useImperativeHandle)(e,(function(){return function(t){return{getMap:function(){return t.current&&t.current.getMap()},queryRenderedFeatures:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.current&&t.current.getMap();return n&&n.queryRenderedFeatures(e,r)}}}(h)}),[]);var y=g&&l.createElement(_t,{value:Et(Et({},m),{},{viewport:m.viewport||new W(Et(Et(Et({},t),t.viewState),{},{width:u[0],height:u[1]})),map:g,container:m.container||d.current})},l.createElement("div",{key:"map-overlays",className:"overlays",style:At,onScroll:It},t.children)),v=t.className,_=t.width,b=t.height,x=t.style,w=t.visibilityConstraints,E=Object.assign({position:"relative"},x,{width:_,height:b}),T=t.visible&&function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:ct;for(var r in e){var n=r.slice(0,3),i=mt(r.slice(3));if("min"===n&&t[i]<e[r])return!1;if("max"===n&&t[i]>e[r])return!1}return!0}(t.viewState||t,w),A=Object.assign({},At,{visibility:T?"inherit":"hidden"});return l.createElement("div",{key:"map-container",ref:d,style:E},l.createElement("div",{key:"map-mapbox",ref:f,style:A,className:v}),y,!i&&!t.disableTokenWarning&&l.createElement(Pt,null))}));Dt.supported=function(){return rt.a&&rt.a.supported()},Dt.propTypes=Ct,Dt.defaultProps=St;var Ot=Dt;function Mt(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return Bt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Bt(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}function Bt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var kt=function(){function t(){Object(p.a)(this,t),Object(s.a)(this,"propNames",[])}return Object(h.a)(t,[{key:"arePropsEqual",value:function(t,e){var r,n=Mt(this.propNames||[]);try{for(n.s();!(r=n.n()).done;){var i=r.value;if(!it(t[i],e[i]))return!1}}catch(t){n.e(t)}finally{n.f()}return!0}},{key:"initializeProps",value:function(t,e){return{start:t,end:e}}},{key:"interpolateProps",value:function(t,e,r){st(!1,"interpolateProps is not implemented")}},{key:"getDuration",value:function(t,e){return e.transitionDuration}}]),t}();function Ft(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Lt(t,e){return(Lt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function Rt(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Lt(t,e)}var zt=r(36),Nt=r.n(zt);function jt(t,e){return!e||"object"!==Nt()(e)&&"function"!=typeof e?Ft(t):e}function Ut(t){return(Ut=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}var Vt={longitude:1,bearing:1};function qt(t){return Number.isFinite(t)||Array.isArray(t)}function Ht(t,e,r){return function(t){return t in Vt}(t)&&Math.abs(r-e)>180&&(r=r<0?r+360:r-360),r}function Gt(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return Zt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Zt(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}function Zt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Wt(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var r,n=Ut(t);if(e){var i=Ut(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return jt(this,r)}}var Yt=["longitude","latitude","zoom","bearing","pitch"],Xt=["latitude","longitude","zoom","width","height"],Kt=["bearing","pitch"],Jt={speed:1.2,curve:1.414},Qt=function(t){Rt(r,t);var e=Wt(r);function r(){var t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object(p.a)(this,r),t=e.call(this),Object(s.a)(Ft(t),"propNames",Yt),t.props=Object.assign({},Jt,n),t}return Object(h.a)(r,[{key:"initializeProps",value:function(t,e){var r,n={},i={},o=Gt(Xt);try{for(o.s();!(r=o.n()).done;){var a=r.value,s=t[a],l=e[a];st(qt(s)&&qt(l),"".concat(a," must be supplied for transition")),n[a]=s,i[a]=Ht(a,s,l)}}catch(t){o.e(t)}finally{o.f()}var u,c=Gt(Kt);try{for(c.s();!(u=c.n()).done;){var p=u.value,h=t[p]||0,f=e[p]||0;n[p]=h,i[p]=Ht(p,h,f)}}catch(t){c.e(t)}finally{c.f()}return{start:n,end:i}}},{key:"interpolateProps",value:function(t,e,r){var n,i=function(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i={},o=Q(t,e,n),a=o.startZoom,s=o.startCenterXY,l=o.uDelta,u=o.w0,c=o.u1,p=o.S,h=o.rho,f=o.rho2,d=o.r0;if(c<.01){var m,g=Y(K);try{for(g.s();!(m=g.n()).done;){var y=m.value,v=t[y],b=e[y];i[y]=_(v,b,r)}}catch(t){g.e(t)}finally{g.f()}return i}var x=r*p,w=Math.cosh(d)/Math.cosh(d+h*x),E=u*((Math.cosh(d)*Math.tanh(d+h*x)-Math.sinh(d))/f)/c,C=1/w,S=a+F(C),P=A([],l,E);T(P,P,s);var I=R(P);return i.longitude=I[0],i.latitude=I[1],i.zoom=S,i}(t,e,r,this.props),o=Gt(Kt);try{for(o.s();!(n=o.n()).done;){var a=n.value;i[a]=at(t[a],e[a],r)}}catch(t){o.e(t)}finally{o.f()}return i}},{key:"getDuration",value:function(t,e){var r=e.transitionDuration;return"auto"===r&&(r=function(t,e){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=n=Object.assign({},J,n),o=i.screenSpeed,a=i.speed,s=i.maxDuration,l=Q(t,e,n),u=l.S,c=l.rho,p=1e3*u;return r=Number.isFinite(o)?p/(o/c):p/a,Number.isFinite(s)&&r>s?0:r}(t,e,this.props)),r}}]),r}(kt);function $t(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return te(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return te(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==r.return||r.return()}finally{if(s)throw o}}}}function te(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function ee(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var r,n=Ut(t);if(e){var i=Ut(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return jt(this,r)}}var re=["longitude","latitude","zoom","bearing","pitch"],ne=function(t){Rt(r,t);var e=ee(r);function r(){var t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object(p.a)(this,r),t=e.call(this),Array.isArray(n)&&(n={transitionProps:n}),t.propNames=n.transitionProps||re,n.around&&(t.around=n.around),t}return Object(h.a)(r,[{key:"initializeProps",value:function(t,e){var r={},n={};if(this.around){r.around=this.around;var i=new W(t).unproject(this.around);Object.assign(n,e,{around:new W(e).project(i),aroundLngLat:i})}var o,a=$t(this.propNames);try{for(a.s();!(o=a.n()).done;){var s=o.value,l=t[s],u=e[s];st(qt(l)&&qt(u),"".concat(s," must be supplied for transition")),r[s]=l,n[s]=Ht(s,l,u)}}catch(t){a.e(t)}finally{a.f()}return{start:r,end:n}}},{key:"interpolateProps",value:function(t,e,r){var n,i={},o=$t(this.propNames);try{for(o.s();!(n=o.n()).done;){var a=n.value;i[a]=at(t[a],e[a],r)}}catch(t){o.e(t)}finally{o.f()}if(e.around){var s=new W(Object.assign({},e,i)).getMapCenterByLngLatPosition({lngLat:e.aroundLngLat,pos:at(t.around,e.around,r)}),l=Object(c.a)(s,2),u=l[0],p=l[1];i.longitude=u,i.latitude=p}return i}}]),r}(kt),ie=function(){};var oe={BREAK:1,SNAP_TO_END:2,IGNORE:3,UPDATE:4},ae={transitionDuration:0,transitionEasing:function(t){return t},transitionInterpolator:new ne,transitionInterruption:oe.BREAK,onTransitionStart:ie,onTransitionInterrupt:ie,onTransitionEnd:ie,onViewportChange:ie,onStateChange:ie},se=function(){function t(){var e=this,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};Object(p.a)(this,t),Object(s.a)(this,"_animationFrame",null),Object(s.a)(this,"_onTransitionFrame",(function(){e._animationFrame=requestAnimationFrame(e._onTransitionFrame),e._updateViewport()})),this.props=null,this.onViewportChange=r.onViewportChange||ie,this.onStateChange=r.onStateChange||ie,this.time=r.getTime||Date.now}return Object(h.a)(t,[{key:"getViewportInTransition",value:function(){return this._animationFrame?this.state.propsInTransition:null}},{key:"processViewportChange",value:function(t){var e=this.props;if(this.props=t,!e||this._shouldIgnoreViewportChange(e,t))return!1;if(this._isTransitionEnabled(t)){var r=Object.assign({},e),n=Object.assign({},t);if(this._isTransitionInProgress()&&(e.onTransitionInterrupt(),this.state.interruption===oe.SNAP_TO_END?Object.assign(r,this.state.endProps):Object.assign(r,this.state.propsInTransition),this.state.interruption===oe.UPDATE)){var i=this.time(),o=(i-this.state.startTime)/this.state.duration;n.transitionDuration=this.state.duration-(i-this.state.startTime),n.transitionEasing=function(t,e){var r=t(e);return function(n){return 1/(1-r)*(t(n*(1-e)+e)-r)}}(this.state.easing,o),n.transitionInterpolator=r.transitionInterpolator}return n.onTransitionStart(),this._triggerTransition(r,n),!0}return this._isTransitionInProgress()&&(e.onTransitionInterrupt(),this._endTransition()),!1}},{key:"_isTransitionInProgress",value:function(){return Boolean(this._animationFrame)}},{key:"_isTransitionEnabled",value:function(t){var e=t.transitionDuration,r=t.transitionInterpolator;return(e>0||"auto"===e)&&Boolean(r)}},{key:"_isUpdateDueToCurrentTransition",value:function(t){return!!this.state.propsInTransition&&this.state.interpolator.arePropsEqual(t,this.state.propsInTransition)}},{key:"_shouldIgnoreViewportChange",value:function(t,e){return!t||(this._isTransitionInProgress()?this.state.interruption===oe.IGNORE||this._isUpdateDueToCurrentTransition(e):!this._isTransitionEnabled(e)||e.transitionInterpolator.arePropsEqual(t,e))}},{key:"_triggerTransition",value:function(t,e){st(this._isTransitionEnabled(e)),this._animationFrame&&cancelAnimationFrame(this._animationFrame);var r=e.transitionInterpolator,n=r.getDuration?r.getDuration(t,e):e.transitionDuration;if(0!==n){var i=e.transitionInterpolator.initializeProps(t,e),o={inTransition:!0,isZooming:t.zoom!==e.zoom,isPanning:t.longitude!==e.longitude||t.latitude!==e.latitude,isRotating:t.bearing!==e.bearing||t.pitch!==e.pitch};this.state={duration:n,easing:e.transitionEasing,interpolator:e.transitionInterpolator,interruption:e.transitionInterruption,startTime:this.time(),startProps:i.start,endProps:i.end,animation:null,propsInTransition:{}},this._onTransitionFrame(),this.onStateChange(o)}}},{key:"_endTransition",value:function(){this._animationFrame&&(cancelAnimationFrame(this._animationFrame),this._animationFrame=null),this.onStateChange({inTransition:!1,isZooming:!1,isPanning:!1,isRotating:!1})}},{key:"_updateViewport",value:function(){var t=this.time(),e=this.state,r=e.startTime,n=e.duration,i=e.easing,o=e.interpolator,a=e.startProps,s=e.endProps,l=!1,u=(t-r)/n;u>=1&&(u=1,l=!0),u=i(u);var c=o.interpolateProps(a,s,u),p=new dt(Object.assign({},this.props,c));this.state.propsInTransition=p.getViewportProps(),this.onViewportChange(this.state.propsInTransition,this.props),l&&(this._endTransition(),this.props.onTransitionEnd())}}]),t}();Object(s.a)(se,"defaultProps",ae);var le=r(19);function ue(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ce(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?ue(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):ue(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var pe={transitionDuration:0},he={transitionDuration:300,transitionEasing:function(t){return t},transitionInterpolator:new ne,transitionInterruption:oe.BREAK},fe=function(t){return 1-(1-t)*(1-t)},de=["wheel"],me=["panstart","panmove","panend"],ge=["pinchstart","pinchmove","pinchend"],ye=["tripanstart","tripanmove","tripanend"],ve=["doubletap"],_e=["keydown"],be=function(){function t(){var e=this;Object(p.a)(this,t),Object(s.a)(this,"events",[]),Object(s.a)(this,"scrollZoom",!0),Object(s.a)(this,"dragPan",!0),Object(s.a)(this,"dragRotate",!0),Object(s.a)(this,"doubleClickZoom",!0),Object(s.a)(this,"touchZoom",!0),Object(s.a)(this,"touchRotate",!1),Object(s.a)(this,"keyboard",!0),Object(s.a)(this,"_interactionState",{isDragging:!1}),Object(s.a)(this,"_events",{}),Object(s.a)(this,"_setInteractionState",(function(t){Object.assign(e._interactionState,t),e.onStateChange&&e.onStateChange(e._interactionState)})),Object(s.a)(this,"_onTransition",(function(t,r){e.onViewportChange(t,e._interactionState,r)})),this.handleEvent=this.handleEvent.bind(this),this._transitionManager=new se({onViewportChange:this._onTransition,onStateChange:this._setInteractionState})}return Object(h.a)(t,[{key:"handleEvent",value:function(t){this.mapState=this.getMapState();var e=this._eventStartBlocked;switch(t.type){case"panstart":return!e&&this._onPanStart(t);case"panmove":return this._onPan(t);case"panend":return this._onPanEnd(t);case"pinchstart":return!e&&this._onPinchStart(t);case"pinchmove":return this._onPinch(t);case"pinchend":return this._onPinchEnd(t);case"tripanstart":return!e&&this._onTriplePanStart(t);case"tripanmove":return this._onTriplePan(t);case"tripanend":return this._onTriplePanEnd(t);case"doubletap":return this._onDoubleTap(t);case"wheel":return this._onWheel(t);case"keydown":return this._onKeyDown(t);default:return!1}}},{key:"getCenter",value:function(t){var e=t.offsetCenter;return[e.x,e.y]}},{key:"isFunctionKeyPressed",value:function(t){var e=t.srcEvent;return Boolean(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}},{key:"blockEvents",value:function(t){var e=this,r=setTimeout((function(){e._eventStartBlocked===r&&(e._eventStartBlocked=null)}),t);this._eventStartBlocked=r}},{key:"updateViewport",value:function(t,e,r){var n=this.mapState instanceof dt?this.mapState.getViewportProps():this.mapState,i=ce(ce({},t.getViewportProps()),e),o=Object.keys(i).some((function(t){return n[t]!==i[t]}));this._state=t.getState(),this._setInteractionState(r),o&&this.onViewportChange(i,this._interactionState,n)}},{key:"getMapState",value:function(t){return new dt(ce(ce(ce({},this.mapStateProps),this._state),t))}},{key:"isDragging",value:function(){return this._interactionState.isDragging}},{key:"setOptions",value:function(t){var e=t.onViewportChange,r=t.onStateChange,n=t.eventManager,i=void 0===n?this.eventManager:n,o=t.isInteractive,a=void 0===o||o,s=t.scrollZoom,l=void 0===s?this.scrollZoom:s,u=t.dragPan,c=void 0===u?this.dragPan:u,p=t.dragRotate,h=void 0===p?this.dragRotate:p,f=t.doubleClickZoom,d=void 0===f?this.doubleClickZoom:f,m=t.touchZoom,g=void 0===m?this.touchZoom:m,y=t.touchRotate,v=void 0===y?this.touchRotate:y,_=t.keyboard,b=void 0===_?this.keyboard:_;this.onViewportChange=e,this.onStateChange=r;var x=this.mapStateProps||{},w=x.height!==t.height||x.width!==t.width;this.mapStateProps=t,w&&(this.mapState=x,this.updateViewport(new dt(t))),this._transitionManager.processViewportChange(t),this.eventManager!==i&&(this.eventManager=i,this._events={},this.toggleEvents(this.events,!0)),this.toggleEvents(de,a&&Boolean(l)),this.toggleEvents(me,a&&Boolean(c||h)),this.toggleEvents(ge,a&&Boolean(g||v)),this.toggleEvents(ye,a&&Boolean(v)),this.toggleEvents(ve,a&&Boolean(d)),this.toggleEvents(_e,a&&Boolean(b)),this.scrollZoom=l,this.dragPan=c,this.dragRotate=h,this.doubleClickZoom=d,this.touchZoom=g,this.touchRotate=v,this.keyboard=b}},{key:"toggleEvents",value:function(t,e){var r=this;this.eventManager&&t.forEach((function(t){r._events[t]!==e&&(r._events[t]=e,e?r.eventManager.on(t,r.handleEvent):r.eventManager.off(t,r.handleEvent))}))}},{key:"_onPanStart",value:function(t){var e=this.getCenter(t);this._panRotate=this.isFunctionKeyPressed(t)||t.rightButton;var r=this._panRotate?this.mapState.rotateStart({pos:e}):this.mapState.panStart({pos:e});return this.updateViewport(r,pe,{isDragging:!0}),!0}},{key:"_onPan",value:function(t){return!!this.isDragging()&&(this._panRotate?this._onPanRotate(t):this._onPanMove(t))}},{key:"_onPanEnd",value:function(t){return!!this.isDragging()&&(this._panRotate?this._onPanRotateEnd(t):this._onPanMoveEnd(t))}},{key:"_onPanMove",value:function(t){if(!this.dragPan)return!1;var e=this.getCenter(t),r=this.mapState.pan({pos:e});return this.updateViewport(r,pe,{isPanning:!0}),!0}},{key:"_onPanMoveEnd",value:function(t){if(this.dragPan){var e=this.dragPan.inertia,r=void 0===e?300:e;if(r&&t.velocity){var n=this.getCenter(t),i=[n[0]+t.velocityX*r/2,n[1]+t.velocityY*r/2],o=this.mapState.pan({pos:i}).panEnd();return this.updateViewport(o,ce(ce({},he),{},{transitionDuration:r,transitionEasing:fe}),{isDragging:!1,isPanning:!0}),!0}}var a=this.mapState.panEnd();return this.updateViewport(a,null,{isDragging:!1,isPanning:!1}),!0}},{key:"_onPanRotate",value:function(t){if(!this.dragRotate)return!1;var e=this.getCenter(t),r=this.mapState.rotate({pos:e});return this.updateViewport(r,pe,{isRotating:!0}),!0}},{key:"_onPanRotateEnd",value:function(t){if(this.dragRotate){var e=this.dragRotate.inertia,r=void 0===e?300:e;if(r&&t.velocity){var n=this.getCenter(t),i=[n[0]+t.velocityX*r/2,n[1]+t.velocityY*r/2],o=this.mapState.rotate({pos:i}).rotateEnd();return this.updateViewport(o,ce(ce({},he),{},{transitionDuration:r,transitionEasing:fe}),{isDragging:!1,isRotating:!0}),!0}}var a=this.mapState.panEnd();return this.updateViewport(a,null,{isDragging:!1,isRotating:!1}),!0}},{key:"_onWheel",value:function(t){if(!this.scrollZoom)return!1;var e=this.scrollZoom,r=e.speed,n=void 0===r?.01:r,i=e.smooth,o=void 0!==i&&i;t.preventDefault();var a=this.getCenter(t),s=t.delta,l=2/(1+Math.exp(-Math.abs(s*n)));s<0&&0!==l&&(l=1/l);var u=this.mapState.zoom({pos:a,scale:l});return this.updateViewport(u,ce(ce({},he),{},{transitionInterpolator:new ne({around:a}),transitionDuration:o?250:1}),{isPanning:!0,isZooming:!0}),!0}},{key:"_onPinchStart",value:function(t){var e=this.getCenter(t),r=this.mapState.zoomStart({pos:e}).rotateStart({pos:e});return this._startPinchRotation=t.rotation,this._lastPinchEvent=t,this.updateViewport(r,pe,{isDragging:!0}),!0}},{key:"_onPinch",value:function(t){if(!this.isDragging())return!1;if(!this.touchZoom&&!this.touchRotate)return!1;var e=this.mapState;if(this.touchZoom){var r=t.scale,n=this.getCenter(t);e=e.zoom({pos:n,scale:r})}if(this.touchRotate){var i=t.rotation;e=e.rotate({deltaAngleX:this._startPinchRotation-i})}return this.updateViewport(e,pe,{isDragging:!0,isPanning:Boolean(this.touchZoom),isZooming:Boolean(this.touchZoom),isRotating:Boolean(this.touchRotate)}),this._lastPinchEvent=t,!0}},{key:"_onPinchEnd",value:function(t){if(!this.isDragging())return!1;if(this.touchZoom){var e=this.touchZoom.inertia,r=void 0===e?300:e,n=this._lastPinchEvent;if(r&&n&&t.scale!==n.scale){var i=this.getCenter(t),o=this.mapState.rotateEnd(),a=Math.log2(t.scale),s=(a-Math.log2(n.scale))/(t.deltaTime-n.deltaTime),l=Math.pow(2,a+s*r/2);return o=o.zoom({pos:i,scale:l}).zoomEnd(),this.updateViewport(o,ce(ce({},he),{},{transitionInterpolator:new ne({around:i}),transitionDuration:r,transitionEasing:fe}),{isDragging:!1,isPanning:Boolean(this.touchZoom),isZooming:Boolean(this.touchZoom),isRotating:!1}),this.blockEvents(r),!0}}var u=this.mapState.zoomEnd().rotateEnd();return this._state.startPinchRotation=0,this.updateViewport(u,null,{isDragging:!1,isPanning:!1,isZooming:!1,isRotating:!1}),this._startPinchRotation=null,this._lastPinchEvent=null,!0}},{key:"_onTriplePanStart",value:function(t){var e=this.getCenter(t),r=this.mapState.rotateStart({pos:e});return this.updateViewport(r,pe,{isDragging:!0}),!0}},{key:"_onTriplePan",value:function(t){if(!this.isDragging())return!1;if(!this.touchRotate)return!1;var e=this.getCenter(t);e[0]-=t.deltaX;var r=this.mapState.rotate({pos:e});return this.updateViewport(r,pe,{isRotating:!0}),!0}},{key:"_onTriplePanEnd",value:function(t){if(!this.isDragging())return!1;if(this.touchRotate){var e=this.touchRotate.inertia,r=void 0===e?300:e;if(r&&t.velocityY){var n=this.getCenter(t),i=[n[0],n[1]+=t.velocityY*r/2],o=this.mapState.rotate({pos:i});return this.updateViewport(o,ce(ce({},he),{},{transitionDuration:r,transitionEasing:fe}),{isDragging:!1,isRotating:!0}),this.blockEvents(r),!1}}var a=this.mapState.rotateEnd();return this.updateViewport(a,null,{isDragging:!1,isRotating:!1}),!0}},{key:"_onDoubleTap",value:function(t){if(!this.doubleClickZoom)return!1;var e=this.getCenter(t),r=this.isFunctionKeyPressed(t),n=this.mapState.zoom({pos:e,scale:r?.5:2});return this.updateViewport(n,Object.assign({},he,{transitionInterpolator:new ne({around:e})}),{isZooming:!0}),!0}},{key:"_onKeyDown",value:function(t){if(!this.keyboard)return!1;var e,r=this.isFunctionKeyPressed(t),n=this.keyboard,i=n.zoomSpeed,o=void 0===i?2:i,a=n.moveSpeed,s=void 0===a?100:a,l=n.rotateSpeedX,u=void 0===l?15:l,c=n.rotateSpeedY,p=void 0===c?10:c,h=this.mapStateProps;switch(t.srcEvent.keyCode){case 189:e=r?this.getMapState({zoom:h.zoom-Math.log2(o)-1}):this.getMapState({zoom:h.zoom-Math.log2(o)});break;case 187:e=r?this.getMapState({zoom:h.zoom+Math.log2(o)+1}):this.getMapState({zoom:h.zoom+Math.log2(o)});break;case 37:e=r?this.getMapState({bearing:h.bearing-u}):this.mapState.pan({pos:[s,0],startPos:[0,0]});break;case 39:e=r?this.getMapState({bearing:h.bearing+u}):this.mapState.pan({pos:[-s,0],startPos:[0,0]});break;case 38:e=r?this.getMapState({pitch:h.pitch+p}):this.mapState.pan({pos:[0,s],startPos:[0,0]});break;case 40:e=r?this.getMapState({pitch:h.pitch-p}):this.mapState.pan({pos:[0,-s],startPos:[0,0]});break;default:return!1}return this.updateViewport(e,he)}}]),t}();function xe(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function we(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?xe(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):xe(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var Ee=Object.assign({},Ot.propTypes,{maxZoom:u.number,minZoom:u.number,maxPitch:u.number,minPitch:u.number,onViewStateChange:u.func,onViewportChange:u.func,onInteractionStateChange:u.func,transitionDuration:u.oneOfType([u.number,u.string]),transitionInterpolator:u.object,transitionInterruption:u.number,transitionEasing:u.func,onTransitionStart:u.func,onTransitionInterrupt:u.func,onTransitionEnd:u.func,scrollZoom:u.oneOfType([u.bool,u.object]),dragPan:u.oneOfType([u.bool,u.object]),dragRotate:u.oneOfType([u.bool,u.object]),doubleClickZoom:u.bool,touchZoom:u.oneOfType([u.bool,u.object]),touchRotate:u.oneOfType([u.bool,u.object]),keyboard:u.oneOfType([u.bool,u.object]),onHover:u.func,onClick:u.func,onDblClick:u.func,onContextMenu:u.func,onMouseDown:u.func,onMouseMove:u.func,onMouseUp:u.func,onTouchStart:u.func,onTouchMove:u.func,onTouchEnd:u.func,onMouseEnter:u.func,onMouseLeave:u.func,onMouseOut:u.func,onWheel:u.func,touchAction:u.string,eventRecognizerOptions:u.object,clickRadius:u.number,interactiveLayerIds:u.array,getCursor:u.func,controller:u.instanceOf(be)}),Te=Object.assign({},Ot.defaultProps,ct,se.defaultProps,{onViewStateChange:null,onViewportChange:null,onClick:null,onNativeClick:null,onHover:null,onContextMenu:function(t){return t.preventDefault()},scrollZoom:!0,dragPan:!0,dragRotate:!0,doubleClickZoom:!0,touchZoom:!0,touchRotate:!1,keyboard:!0,touchAction:"none",eventRecognizerOptions:{},clickRadius:0,getCursor:function(t){var e=t.isDragging,r=t.isHovering;return e?"grabbing":r?"pointer":"grab"}});function Ae(t){if(t.lngLat||!t.offsetCenter)return t;var e=t.offsetCenter,r=[e.x,e.y],n=new W(Object.assign({},this.props,this.props.viewState,{width:this.width,height:this.height}));return t.point=r,t.lngLat=n.unproject(r),t}function Ce(t){var e=this.map;if(!e||!t)return null;var r={},n=this.props.clickRadius;this.props.interactiveLayerIds&&(r.layers=this.props.interactiveLayerIds);try{return e.queryRenderedFeatures(n?[[t[0]-n,t[1]+n],[t[0]+n,t[1]-n]]:t,r)}catch(t){return null}}function Se(t,e){var r=this.props[t];r&&r(Ae.call(this,e))}function Pe(t){Se.call(this,"touch"===t.pointerType?"onTouchStart":"onMouseDown",t)}function Ie(t){Se.call(this,"touch"===t.pointerType?"onTouchEnd":"onMouseUp",t)}function De(t){if(Se.call(this,"touch"===t.pointerType?"onTouchMove":"onMouseMove",t),!this.state.isDragging){var e,r=this.props,n=r.onHover,i=r.interactiveLayerIds;t=Ae.call(this,t),(i||n)&&(e=Ce.call(this,t.point)),n&&(t.features=e,n(t));var o=Boolean(i&&e&&e.length>0),a=o&&!this.state.isHovering,s=!o&&this.state.isHovering;a&&Se.call(this,"onMouseEnter",t),s&&Se.call(this,"onMouseLeave",t),(a||s)&&this.setState({isHovering:o})}}function Oe(t){var e=this.props,r=e.onClick,n=e.onNativeClick,i=e.onDblClick,o=e.doubleClickZoom,a=[],s=i||o;switch(t.type){case"anyclick":a.push(n),s||a.push(r);break;case"click":s&&a.push(r)}(a=a.filter(Boolean)).length&&((t=Ae.call(this,t)).features=Ce.call(this,t.point),a.forEach((function(e){return e(t)})))}var Me=Object(l.forwardRef)((function(t,e){var r=Object(l.useContext)(bt),i=Object(l.useMemo)((function(){return t.controller||new be}),[]),o=Object(l.useMemo)((function(){return new le.EventManager(null,{touchAction:t.touchAction,recognizerOptions:t.eventRecognizerOptions})}),[]),s=Object(l.useRef)(null),u=Object(l.useRef)(null),c=Object(l.useRef)({width:0,height:0,state:{isHovering:!1,isDragging:!1}}).current;c.props=t,c.map=u.current&&u.current.getMap(),c.setState=function(e){c.state=we(we({},c.state),e),s.current.style.cursor=t.getCursor(c.state)};var p,h,f=!0,d=function(t,e,r){if(f)p=[t,e,r];else{var n=c.props,i=n.onViewStateChange,o=n.onViewportChange;i&&i({viewState:t,interactionState:e,oldViewState:r}),o&&o(t,e,r)}};Object(l.useImperativeHandle)(e,(function(){return function(t){return{getMap:t.current&&t.current.getMap,queryRenderedFeatures:t.current&&t.current.queryRenderedFeatures}}(u)}),[]);var m=Object(l.useMemo)((function(){return we(we({},r),{},{eventManager:o,container:r.container||s.current})}),[r,s.current]);m.onViewportChange=d;var g=function(t){var e=t.isDragging,r=void 0!==e&&e;if(r!==c.state.isDragging&&c.setState({isDragging:r}),f)h=t;else{var n=c.props.onInteractionStateChange;n&&n(t)}},y=function(){c.width&&c.height&&i.setOptions(we(we(we({},c.props),c.props.viewState),{},{isInteractive:Boolean(c.props.onViewStateChange||c.props.onViewportChange),onViewportChange:d,onStateChange:g,eventManager:o,width:c.width,height:c.height}))};Object(l.useEffect)((function(){return o.setElement(s.current),o.on({pointerdown:Pe.bind(c),pointermove:De.bind(c),pointerup:Ie.bind(c),pointerleave:Se.bind(c,"onMouseOut"),click:Oe.bind(c),anyclick:Oe.bind(c),dblclick:Se.bind(c,"onDblClick"),wheel:Se.bind(c,"onWheel"),contextmenu:Se.bind(c,"onContextMenu")}),function(){o.destroy()}}),[]),xt((function(){p&&d.apply(void 0,a(p)),h&&g(h)})),y();var v=t.width,_=t.height,b=t.style,x=t.getCursor,w=Object(l.useMemo)((function(){return we(we({position:"relative"},b),{},{width:v,height:_,cursor:x(c.state)})}),[b,v,_,x,c.state]);return p&&c._child||(c._child=l.createElement(_t,{value:m},l.createElement("div",{key:"event-canvas",ref:s,style:w},l.createElement(Ot,n({},t,{width:"100%",height:"100%",style:null,onResize:function(t){var e=t.width,r=t.height;c.width=e,c.height=r,y(),c.props.onResize({width:e,height:r})},ref:u}))))),f=!1,c._child}));Me.supported=Ot.supported,Me.propTypes=Ee,Me.defaultProps=Te;var Be=Me,ke=r(11);function Fe(t,e){if(t===e)return!0;if(!t||!e)return!1;if(Array.isArray(t)){if(!Array.isArray(e)||t.length!==e.length)return!1;for(var r=0;r<t.length;r++)if(!Fe(t[r],e[r]))return!1;return!0}if(Array.isArray(e))return!1;if("object"===Object(ke.a)(t)&&"object"===Object(ke.a)(e)){var n=Object.keys(t),i=Object.keys(e);if(n.length!==i.length)return!1;for(var o=0,a=n;o<a.length;o++){var s=a[o];if(!e.hasOwnProperty(s))return!1;if(!Fe(t[s],e[s]))return!1}return!0}return!1}function Le(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var Re={type:u.string.isRequired,id:u.string},ze=0;function Ne(t,e,r){if(t.style&&t.style._loaded){var n=function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Le(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Le(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({},r);return delete n.id,delete n.children,t.addSource(e,n),t.getSource(e)}return null}function je(t){var e=Object(l.useContext)(bt),r=Object(l.useRef)({id:t.id,type:t.type}),n=Object(l.useState)(0),i=Object(c.a)(n,2)[1],o=Object(l.useMemo)((function(){return t.id||"jsx-source-".concat(ze++)}),[]),a=e.map;Object(l.useEffect)((function(){if(a){var t=function(){return i((function(t){return t+1}))};return a.on("styledata",t),function(){a.off("styledata",t),requestAnimationFrame((function(){a.style&&a.style._loaded&&a.removeSource(o)}))}}}),[a]);var s=a&&a.style&&a.getSource(o);return s?function(t,e,r){st(e.id===r.id,"source id changed"),st(e.type===r.type,"source type changed");var n="",i=0;for(var o in e)"children"===o||"id"===o||Fe(r[o],e[o])||(n=o,i++);if(i){var a=e.type;if("geojson"===a)t.setData(e.data);else if("image"===a)t.updateImage({url:e.url,coordinates:e.coordinates});else if("canvas"!==a&&"video"!==a||1!==i||"coordinates"!==n)if("vector"===a&&t.setUrl)switch(n){case"url":t.setUrl(e.url);break;case"tiles":t.setTiles(e.tiles)}else console.warn("Unable to update <Source> prop: ".concat(n));else t.setCoordinates(e.coordinates)}}(s,t,r.current):s=Ne(a,o,t),r.current=t,s&&l.Children.map(t.children,(function(t){return t&&Object(l.cloneElement)(t,{source:o})}))||null}je.propTypes=Re;var Ue=je;function Ve(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)r=o[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function qe(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function He(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?qe(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):qe(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var Ge={type:u.oneOf(["fill","line","symbol","circle","fill-extrusion","raster","background","heatmap","hillshade"]).isRequired,id:u.string,source:u.string,beforeId:u.string};function Ze(t,e,r,n){st(r.id===n.id,"layer id changed"),st(r.type===n.type,"layer type changed");try{!function(t,e,r,n){var i=r.layout,o=void 0===i?{}:i,a=r.paint,s=void 0===a?{}:a,l=r.filter,u=r.minzoom,c=r.maxzoom,p=r.beforeId,h=Ve(r,["layout","paint","filter","minzoom","maxzoom","beforeId"]);if(p!==n.beforeId&&t.moveLayer(e,p),o!==n.layout){var f=n.layout||{};for(var d in o)Fe(o[d],f[d])||t.setLayoutProperty(e,d,o[d]);for(var m in f)o.hasOwnProperty(m)||t.setLayoutProperty(e,m,void 0)}if(s!==n.paint){var g=n.paint||{};for(var y in s)Fe(s[y],g[y])||t.setPaintProperty(e,y,s[y]);for(var v in g)s.hasOwnProperty(v)||t.setPaintProperty(e,v,void 0)}for(var _ in Fe(l,n.filter)||t.setFilter(e,l),u===n.minzoom&&c===n.maxzoom||t.setLayerZoomRange(e,u,c),h)Fe(h[_],n[_])||t.setLayerProperty(e,_,h[_])}(t,e,r,n)}catch(t){console.warn(t)}}var We=0;function Ye(t){var e=Object(l.useContext)(bt),r=Object(l.useRef)({id:t.id,type:t.type}),n=Object(l.useState)(0),i=Object(c.a)(n,2)[1],o=Object(l.useMemo)((function(){return t.id||"jsx-layer-".concat(We++)}),[]),a=e.map;return Object(l.useEffect)((function(){if(a){var t=function(){return i((function(t){return t+1}))};return a.on("styledata",t),function(){a.off("styledata",t),a.style&&a.style._loaded&&a.removeLayer(o)}}}),[a]),a&&a.style&&a.getLayer(o)?Ze(a,o,t,r.current):function(t,e,r){if(t.style&&t.style._loaded){var n=He(He({},r),{},{id:e});delete n.beforeId,t.addLayer(n,r.beforeId)}}(a,o,t),r.current=t,null}Ye.propTypes=Ge;var Xe=Ye,Ke={captureScroll:!1,captureDrag:!0,captureClick:!0,captureDoubleClick:!0,capturePointerMove:!1},Je={captureScroll:u.bool,captureDrag:u.bool,captureClick:u.bool,captureDoubleClick:u.bool,capturePointerMove:u.bool};function Qe(t){var e=t.containerRef.current,r=t.context.eventManager;if(e&&r){var n={wheel:function(e){var r=t.props;r.captureScroll&&e.stopPropagation(),r.onScroll&&r.onScroll(e,t)},panstart:function(e){var r=t.props;r.captureDrag&&e.stopPropagation(),r.onDragStart&&r.onDragStart(e,t)},anyclick:function(e){var r=t.props;r.captureClick&&e.stopPropagation(),r.onClick&&r.onClick(e,t)},click:function(e){var r=t.props;r.captureClick&&e.stopPropagation(),r.onClick&&r.onClick(e,t)},dblclick:function(e){var r=t.props;r.captureDoubleClick&&e.stopPropagation(),r.onDoubleClick&&r.onDoubleClick(e,t)},pointermove:function(e){var r=t.props;r.capturePointerMove&&e.stopPropagation(),r.onPointerMove&&r.onPointerMove(e,t)}};return r.watch(n,e),function(){r.off(n)}}}function $e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=Object(l.useContext)(bt),r=Object(l.useRef)(null),n=Object(l.useRef)({props:t,state:{},context:e,containerRef:r}),i=n.current;return i.props=t,i.context=e,Object(l.useEffect)((function(){return Qe(i)}),[e.eventManager]),i}function tr(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var r,n=Ut(t);if(e){var i=Ut(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return jt(this,r)}}function er(t){var e=t.instance,r=$e(t),n=r.context,i=r.containerRef;return e._context=n,e._containerRef=i,e._render()}var rr=function(t){Rt(r,t);var e=tr(r);function r(){var t;Object(p.a)(this,r);for(var n=arguments.length,i=new Array(n),o=0;o<n;o++)i[o]=arguments[o];return t=e.call.apply(e,[this].concat(i)),Object(s.a)(Ft(t),"_context",{}),Object(s.a)(Ft(t),"_containerRef",Object(l.createRef)()),Object(s.a)(Ft(t),"_onScroll",(function(t){})),Object(s.a)(Ft(t),"_onDragStart",(function(t){})),Object(s.a)(Ft(t),"_onDblClick",(function(t){})),Object(s.a)(Ft(t),"_onClick",(function(t){})),Object(s.a)(Ft(t),"_onPointerMove",(function(t){})),t}return Object(h.a)(r,[{key:"_render",value:function(){throw new Error("_render() not implemented")}},{key:"render",value:function(){return l.createElement(er,n({instance:this},this.props,{onScroll:this._onScroll,onDragStart:this._onDragStart,onDblClick:this._onDblClick,onClick:this._onClick,onPointerMove:this._onPointerMove}))}}]),r}(l.PureComponent);function nr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ir(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?nr(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):nr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}Object(s.a)(rr,"propTypes",Je),Object(s.a)(rr,"defaultProps",Ke);var or=Object.assign({},Je,{draggable:u.bool,onDrag:u.func,onDragEnd:u.func,onDragStart:u.func,offsetLeft:u.number,offsetTop:u.number}),ar=Object.assign({},Ke,{draggable:!1,offsetLeft:0,offsetTop:0});function sr(t){var e=t.offsetCenter;return[e.x,e.y]}function lr(t,e,r,n){var i=t[0]+e[0]-r.offsetLeft,o=t[1]+e[1]-r.offsetTop;return n.viewport.unproject([i,o])}function ur(t,e){var r=e.props,n=e.callbacks,i=e.state,o=e.context,a=e.containerRef;if(r.draggable){t.stopPropagation();var s=sr(t),l=function(t,e){var r=t.center,n=r.x,i=r.y;if(e){var o=e.getBoundingClientRect();return[o.left-n,o.top-i]}return null}(t,a.current);if(i.setDragPos(s),i.setDragOffset(l),n.onDragStart&&l){var u=Object.assign({},t);u.lngLat=lr(s,l,r,o),n.onDragStart(u)}}}function cr(t){var e=t.context.eventManager;if(e&&t.state.dragPos){var r={panmove:function(e){return function(t,e){var r=e.props,n=e.callbacks,i=e.state,o=e.context;t.stopPropagation();var a=sr(t);i.setDragPos(a);var s=i.dragOffset;if(n.onDrag&&s){var l=Object.assign({},t);l.lngLat=lr(a,s,r,o),n.onDrag(l)}}(e,t)},panend:function(e){return function(t,e){var r=e.props,n=e.callbacks,i=e.state,o=e.context;t.stopPropagation();var a=i.dragPos,s=i.dragOffset;if(i.setDragPos(null),i.setDragOffset(null),n.onDragEnd&&a&&s){var l=Object.assign({},t);l.lngLat=lr(a,s,r,o),n.onDragEnd(l)}}(e,t)},pancancel:function(e){return r=e,n=t.state,r.stopPropagation(),n.setDragPos(null),void n.setDragOffset(null);var r,n}};return e.watch(r),function(){e.off(r)}}}var pr="undefined"!=typeof window&&window.devicePixelRatio||1,hr=function(t){return Math.round(t*pr)/pr},fr=function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"x";if(null===t)return e;var n="x"===r?t.offsetWidth:t.offsetHeight;return hr(e/100*n)/n*100},dr=Object.assign({},or,{className:u.string,longitude:u.number.isRequired,latitude:u.number.isRequired}),mr=Object.assign({},ar,{className:""});function gr(t){var e=function(t){var e=Object(l.useState)(null),r=Object(c.a)(e,2),n=r[0],i=r[1],o=Object(l.useState)(null),a=Object(c.a)(o,2),s=a[0],u=a[1],p=$e(ir(ir({},t),{},{onDragStart:ur}));return p.callbacks=t,p.state.dragPos=n,p.state.setDragPos=i,p.state.dragOffset=s,p.state.setDragOffset=u,Object(l.useEffect)((function(){return cr(p)}),[p.context.eventManager,Boolean(n)]),p}(t),r=e.state,n=e.containerRef,i=t.children,o=t.className,a=t.draggable,s=r.dragPos,u=function(t){var e=t.props,r=t.state,n=t.context,i=e.longitude,o=e.latitude,a=e.offsetLeft,s=e.offsetTop,l=r.dragPos,u=r.dragOffset;if(l&&u)return[l[0]+u[0],l[1]+u[1]];var p=n.viewport.project([i,o]),h=Object(c.a)(p,2),f=h[0],d=h[1];return[f+=a,d+=s]}(e),p=Object(c.a)(u,2),h=p[0],f=p[1],d="translate(".concat(hr(h),"px, ").concat(hr(f),"px)"),m=a?s?"grabbing":"grab":"auto",g=Object(l.useMemo)((function(){var t={position:"absolute",left:0,top:0,transform:d,cursor:m};return l.createElement("div",{className:"mapboxgl-marker ".concat(o),ref:e.containerRef,style:t},i)}),[i,o]),y=n.current;return y&&(y.style.transform=d,y.style.cursor=m),g}gr.defaultProps=mr,gr.propTypes=dr;var yr=l.memo(gr),vr={top:{x:.5,y:0},"top-left":{x:0,y:0},"top-right":{x:1,y:0},bottom:{x:.5,y:1},"bottom-left":{x:0,y:1},"bottom-right":{x:1,y:1},left:{x:0,y:.5},right:{x:1,y:.5}},_r=Object.keys(vr);function br(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function xr(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?br(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):br(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var wr=Object.assign({},Je,{className:u.string,longitude:u.number.isRequired,latitude:u.number.isRequired,altitude:u.number,offsetLeft:u.number,offsetTop:u.number,tipSize:u.number,closeButton:u.bool,closeOnClick:u.bool,anchor:u.oneOf(Object.keys(vr)),dynamicPosition:u.bool,sortByDepth:u.bool,onClose:u.func}),Er=Object.assign({},Ke,{className:"",altitude:0,offsetLeft:0,offsetTop:0,tipSize:10,anchor:"bottom",dynamicPosition:!0,sortByDepth:!1,closeButton:!0,closeOnClick:!0,onClose:function(){}});function Tr(t,e,r,n){var i=Object(c.a)(n,2),o=i[0],a=i[1],s=t.anchor,l=t.dynamicPosition,u=t.tipSize;return r&&l?function(t){var e=t.x,r=t.y,n=t.width,i=t.height,o=t.selfWidth,a=t.selfHeight,s=t.anchor,l=t.padding,u=void 0===l?0:l,c=vr[s],p=c.x,h=c.y,f=r-h*a,d=f+a,m=Math.max(0,u-f)+Math.max(0,d-i+u);if(m>0){var g=h,y=m;for(h=0;h<=1;h+=.5)d=(f=r-h*a)+a,(m=Math.max(0,u-f)+Math.max(0,d-i+u))<y&&(y=m,g=h);h=g}var v=.5;.5===h&&(p=Math.floor(p),v=1);var _=e-p*o,b=_+o,x=Math.max(0,u-_)+Math.max(0,b-n+u);if(x>0){var w=p,E=x;for(p=0;p<=1;p+=v)b=(_=e-p*o)+o,(x=Math.max(0,u-_)+Math.max(0,b-n+u))<E&&(E=x,w=p);p=w}return _r.find((function(t){var e=vr[t];return e.x===p&&e.y===h}))||s}({x:o,y:a,anchor:s,padding:u,width:e.width,height:e.height,selfWidth:r.clientWidth,selfHeight:r.clientHeight}):s}function Ar(t,e){var r=e.props,n=e.context;(r.closeOnClick||"mapboxgl-popup-close-button"===t.target.className)&&(r.onClose(),n.eventManager&&n.eventManager.once("click",(function(t){return t.stopPropagation()}),t.target))}function Cr(t){var e=Object(l.useRef)(null),r=$e(xr(xr({},t),{},{onClick:Ar})),n=r.context,i=r.containerRef,o=Object(l.useState)(!1),a=Object(c.a)(o,2)[1];Object(l.useEffect)((function(){a(!0)}),[e.current]);var s=n.viewport,u=t.className,p=t.longitude,h=t.latitude,f=t.altitude,d=t.tipSize,m=t.closeButton,g=t.children,y=s.project([p,h,f]),v=Tr(t,s,e.current,y),_=function(t,e,r,n,i){var o=Object(c.a)(n,3),a=o[0],s=o[1],l=o[2],u=t.offsetLeft,p=t.offsetTop,h=t.sortByDepth,f=vr[i],d=a+u,m=s+p,g=fr(r,100*-f.x),y=fr(r,100*-f.y,"y"),v={position:"absolute",transform:"\n translate(".concat(g,"%, ").concat(y,"%)\n translate(").concat(hr(d),"px, ").concat(hr(m),"px)\n "),display:void 0,zIndex:void 0};return h?(l>1||l<-1||a<0||a>e.width||s<0||s>e.height?v.display="none":v.zIndex=Math.floor((1-l)/2*1e5),v):v}(t,s,i.current,y,v),b=Object(l.useCallback)((function(t){return!n.eventManager&&Ar(t,r)}),[n.eventManager]);return l.createElement("div",{className:"mapboxgl-popup mapboxgl-popup-anchor-".concat(v," ").concat(u),style:_,ref:i},l.createElement("div",{key:"tip",className:"mapboxgl-popup-tip",style:{borderWidth:d}}),l.createElement("div",{key:"content",ref:e,className:"mapboxgl-popup-content",onClick:b},m&&l.createElement("button",{key:"close-button",className:"mapboxgl-popup-close-button",type:"button"},"×"),g))}Cr.propTypes=wr,Cr.defaultProps=Er;var Sr=l.memo(Cr);function Pr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var Ir=Object.assign({},Je,{toggleLabel:u.string,className:u.string,style:u.object,compact:u.bool,customAttribution:u.oneOfType([u.string,u.arrayOf(u.string)])}),Dr=Object.assign({},Ke,{className:"",toggleLabel:"Toggle Attribution"});function Or(t){var e=$e(t),r=e.context,n=e.containerRef,i=Object(l.useRef)(null),o=Object(l.useState)(!1),a=Object(c.a)(o,2),u=a[0],p=a[1];Object(l.useEffect)((function(){var e;return r.map&&(e=function(t,e,r,n){var i=new rt.a.AttributionControl(t);return i._map=e,i._container=r,i._innerContainer=n,i._updateAttributions(),i._updateEditLink(),e.on("styledata",i._updateData),e.on("sourcedata",i._updateData),i}({customAttribution:t.customAttribution},r.map,n.current,i.current)),function(){return e&&function(t){t._map.off("styledata",t._updateData),t._map.off("sourcedata",t._updateData)}(e)}}),[r.map]);var h=void 0===t.compact?r.viewport.width<=640:t.compact;Object(l.useEffect)((function(){!h&&u&&p(!1)}),[h]);var f=Object(l.useCallback)((function(){return p((function(t){return!t}))}),[]),d=Object(l.useMemo)((function(){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Pr(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Pr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute"},t.style)}),[t.style]);return l.createElement("div",{style:d,className:t.className},l.createElement("div",{ref:n,"aria-pressed":u,className:"mapboxgl-ctrl mapboxgl-ctrl-attrib ".concat(h?"mapboxgl-compact":""," ").concat(u?"mapboxgl-compact-show":"")},l.createElement("button",{className:"mapboxgl-ctrl-attrib-button",title:t.toggleLabel,onClick:f}),l.createElement("div",{ref:i,className:"mapboxgl-ctrl-attrib-inner",role:"list"})))}Or.propTypes=Ir,Or.defaultProps=Dr;var Mr=l.memo(Or),Br=r(6);function kr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var Fr=Object.assign({},Je,{className:u.string,style:u.object,container:u.object,label:u.string}),Lr=Object.assign({},Ke,{className:"",container:null,label:"Toggle fullscreen"});function Rr(t){var e=$e(t),r=e.context,n=e.containerRef,i=Object(l.useState)(!1),o=Object(c.a)(i,2),a=o[0],u=o[1],p=Object(l.useState)(!1),h=Object(c.a)(p,2),f=h[0],d=h[1],m=Object(l.useState)(null),g=Object(c.a)(m,2),y=g[0],v=g[1];Object(l.useEffect)((function(){var e=t.container||r.container,n=new rt.a.FullscreenControl({container:e});v(n),d(n._checkFullscreenSupport());var i=function(){var t=!n._fullscreen;n._fullscreen=t,u(t)};return Br.a.addEventListener(n._fullscreenchange,i),function(){Br.a.removeEventListener(n._fullscreenchange,i)}}),[]);var _=Object(l.useMemo)((function(){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?kr(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):kr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute"},t.style)}),[t.style]);if(!f)return null;var b=t.className,x=t.label,w=a?"shrink":"fullscreen";return l.createElement("div",{style:_,className:b},l.createElement("div",{className:"mapboxgl-ctrl mapboxgl-ctrl-group",ref:n},l.createElement("button",{key:w,className:"mapboxgl-ctrl-icon mapboxgl-ctrl-".concat(w),type:"button",title:x,onClick:function(){y&&y._onClickFullscreen()}},l.createElement("span",{className:"mapboxgl-ctrl-icon","aria-hidden":"true"}))))}Rr.propTypes=Fr,Rr.defaultProps=Lr;var zr,Nr=l.memo(Rr);function jr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var Ur=Object.assign({},se.defaultProps,{transitionDuration:500}),Vr=function(){},qr=Object.assign({},Je,{className:u.string,style:u.object,label:u.string,disabledLabel:u.string,auto:u.bool,positionOptions:u.object,fitBoundsOptions:u.object,trackUserLocation:u.bool,showUserLocation:u.bool,showAccuracyCircle:u.bool,onViewStateChange:u.func,onViewportChange:u.func,onGeolocate:u.func}),Hr=Object.assign({},Ke,{className:"",label:"Find My Location",disabledLabel:"Location Not Available",auto:!1,positionOptions:{enableHighAccuracy:!1,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showUserLocation:!0,showAccuracyCircle:!0,onGeolocate:function(){}});function Gr(t,e){var r=e.context,n=e.props,i=function(t){var e=new rt.a.LngLat(t.coords.longitude,t.coords.latitude),r=t.coords.accuracy,n=e.toBounds(r);return[[n._ne.lng,n._ne.lat],[n._sw.lng,n._sw.lat]]}(t),o=r.viewport.fitBounds(i,n.fitBoundsOptions),a=o.longitude,s=o.latitude,l=o.zoom,u=Object.assign({},r.viewport,{longitude:a,latitude:s,zoom:l}),c=new dt(u),p=Object.assign({},c.getViewportProps(),Ur),h=n.onViewportChange||r.onViewportChange||Vr;(n.onViewStateChange||r.onViewStateChange||Vr)({viewState:p}),h(p)}function Zr(t){var e=$e(t),r=e.context,n=e.containerRef,i=Object(l.useRef)(null),o=Object(l.useState)(null),a=Object(c.a)(o,2),u=a[0],p=a[1],h=Object(l.useState)(!1),f=Object(c.a)(h,2),d=f[0],m=f[1];Object(l.useEffect)((function(){var n;return r.map&&(void 0!==zr?Promise.resolve(zr):void 0!==window.navigator.permissions?window.navigator.permissions.query({name:"geolocation"}).then((function(t){return zr="denied"!==t.state})):(zr=Boolean(window.navigator.geolocation),Promise.resolve(zr))).then((function(o){m(o),i.current&&((n=function(t,e,r){var n=new rt.a.GeolocateControl(e);n._container=Br.a.createElement("div"),n._map={on:function(){},_getUIString:function(){return""}},n._setupUI(!0),n._map=t.map,n._geolocateButton=r;var i=t.eventManager;return n.options.trackUserLocation&&i&&i.on("panstart",(function(){"ACTIVE_LOCK"===n._watchState&&(n._watchState="BACKGROUND",r.classList.add("mapboxgl-ctrl-geolocate-background"),r.classList.remove("mapboxgl-ctrl-geolocate-active"))})),n.on("geolocate",e.onGeolocate),n}(r,t,i.current))._updateCamera=function(t){return Gr(t,e)},p(n))})),function(){n&&n._clearWatch()}}),[r.map]);var g=Object(l.useCallback)((function(){u&&(u.options=e.props,u.trigger())}),[u]);Object(l.useEffect)((function(){t.auto&&g()}),[u,t.auto]),Object(l.useEffect)((function(){u&&u._onZoom()}),[r.viewport.zoom]);var y=t.className,v=t.label,_=t.disabledLabel,b=t.trackUserLocation,x=Object(l.useMemo)((function(){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?jr(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):jr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute"},t.style)}),[t.style]);return l.createElement("div",{style:x,className:y},l.createElement("div",{key:"geolocate-control",className:"mapboxgl-ctrl mapboxgl-ctrl-group",ref:n},l.createElement("button",{key:"geolocate",className:"mapboxgl-ctrl-icon mapboxgl-ctrl-geolocate",ref:i,disabled:!d,"aria-pressed":!b,type:"button",title:d?v:_,"aria-label":d?v:_,onClick:g},l.createElement("span",{className:"mapboxgl-ctrl-icon","aria-hidden":"true"}))))}Zr.propTypes=qr,Zr.defaultProps=Hr;var Wr=l.memo(Zr);function Yr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var Xr=function(){},Kr=Object.assign({},Je,{className:u.string,style:u.object,onViewStateChange:u.func,onViewportChange:u.func,showCompass:u.bool,showZoom:u.bool,zoomInLabel:u.string,zoomOutLabel:u.string,compassLabel:u.string}),Jr=Object.assign({},Ke,{className:"",showCompass:!0,showZoom:!0,zoomInLabel:"Zoom In",zoomOutLabel:"Zoom Out",compassLabel:"Reset North"});function Qr(t){return function(t,e){for(var r=(t||"").split(".").map(Number),n=(e||"").split(".").map(Number),i=0;i<3;i++){var o=r[i]||0,a=n[i]||0;if(o<a)return-1;if(o>a)return 1}return 0}(t,"1.6.0")>=0?2:1}function $r(t,e,r){var n=t.viewport,i=new dt(Object.assign({},n,r)),o=Object.assign({},i.getViewportProps(),he),a=e.onViewportChange||t.onViewportChange||Xr;(e.onViewStateChange||t.onViewStateChange||Xr)({viewState:o}),a(o)}function tn(t,e,r,n){return l.createElement("button",{key:t,className:"mapboxgl-ctrl-icon mapboxgl-ctrl-".concat(t),type:"button",title:e,onClick:r},n||l.createElement("span",{className:"mapboxgl-ctrl-icon","aria-hidden":"true"}))}function en(t){var e=$e(t),r=e.context,n=e.containerRef,i=t.className,o=t.showCompass,a=t.showZoom,u=t.zoomInLabel,c=t.zoomOutLabel,p=t.compassLabel,h=Object(l.useMemo)((function(){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Yr(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Yr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute"},t.style)}),[t.style]);return l.createElement("div",{style:h,className:i},l.createElement("div",{className:"mapboxgl-ctrl mapboxgl-ctrl-group",ref:n},a&&tn("zoom-in",u,(function(){$r(r,t,{zoom:r.viewport.zoom+1})})),a&&tn("zoom-out",c,(function(){$r(r,t,{zoom:r.viewport.zoom-1})})),o&&tn("compass",p,(function(){$r(r,t,{bearing:0,pitch:0})}),function(t){var e=Object(l.useMemo)((function(){return t.map?Qr(t.map.version):2}),[t.map]),r=t.viewport.bearing,n={transform:"rotate(".concat(-r,"deg)")};return 2===e?l.createElement("span",{className:"mapboxgl-ctrl-icon","aria-hidden":"true",style:n}):l.createElement("span",{className:"mapboxgl-ctrl-compass-arrow",style:n})}(r))))}en.propTypes=Kr,en.defaultProps=Jr;var rn=l.memo(en);function nn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var on=Object.assign({},Je,{className:u.string,style:u.object,maxWidth:u.number,unit:u.oneOf(["imperial","metric","nautical"])}),an=Object.assign({},Ke,{className:"",maxWidth:100,unit:"metric"});function sn(t){var e=$e(t),r=e.context,n=e.containerRef,i=Object(l.useState)(null),o=Object(c.a)(i,2),a=o[0],u=o[1];Object(l.useEffect)((function(){if(r.map){var t=new rt.a.ScaleControl;t._map=r.map,t._container=n.current,u(t)}}),[r.map]),a&&(a.options=t,a._onMove());var p=Object(l.useMemo)((function(){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?nn(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):nn(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute"},t.style)}),[t.style]);return l.createElement("div",{style:p,className:t.className},l.createElement("div",{ref:n,className:"mapboxgl-ctrl mapboxgl-ctrl-scale"}))}sn.propTypes=on,sn.defaultProps=an;var ln=l.memo(sn),un="undefined"!=typeof window&&window.devicePixelRatio||1,cn=Object.assign({},Je,{redraw:u.func.isRequired});function pn(t){var e=$e(t),r=e.context,n=e.containerRef,i=Object(l.useState)(null),o=Object(c.a)(i,2),a=o[0],s=o[1];Object(l.useEffect)((function(){s(n.current.getContext("2d"))}),[]);var u=r.viewport,p=r.isDragging;return a&&(a.save(),a.scale(un,un),t.redraw({width:u.width,height:u.height,ctx:a,isDragging:p,project:u.project,unproject:u.unproject}),a.restore()),l.createElement("canvas",{ref:n,width:u.width*un,height:u.height*un,style:{width:"".concat(u.width,"px"),height:"".concat(u.height,"px"),position:"absolute",left:0,top:0}})}pn.propTypes=cn,pn.defaultProps={captureScroll:!1,captureDrag:!1,captureClick:!1,captureDoubleClick:!1,capturePointerMove:!1};var hn=pn;function fn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var dn=Object.assign({},Je,{redraw:u.func.isRequired,style:u.object});function mn(t){var e=$e(t),r=e.context,n=e.containerRef,i=r.viewport,o=r.isDragging,a=function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?fn(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):fn(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute",left:0,top:0,width:i.width,height:i.height},t.style);return l.createElement("div",{ref:n,style:a},t.redraw({width:i.width,height:i.height,isDragging:o,project:i.project,unproject:i.unproject}))}mn.propTypes=dn,mn.defaultProps={captureScroll:!1,captureDrag:!1,captureClick:!1,captureDoubleClick:!1,capturePointerMove:!1};var gn=mn;function yn(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}var vn=Object.assign({},Je,{redraw:u.func.isRequired,style:u.object});function _n(t){var e=$e(t),r=e.context,n=e.containerRef,i=r.viewport,o=r.isDragging,a=function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?yn(Object(r),!0).forEach((function(e){Object(s.a)(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):yn(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({position:"absolute",left:0,top:0},t.style);return l.createElement("svg",{width:i.width,height:i.height,ref:n,style:a},t.redraw({width:i.width,height:i.height,isDragging:o,project:i.project,unproject:i.unproject}))}_n.propTypes=vn,_n.defaultProps={captureScroll:!1,captureDrag:!1,captureClick:!1,captureDoubleClick:!1,capturePointerMove:!1};var bn=_n,xn=rt.a?rt.a.setRTLTextPlugin:function(){}}])}));
4
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("styled-components")):"function"==typeof define&&define.amd?define(["react","styled-components"],t):"object"==typeof exports?exports.KeplerGl=t(require("react"),require("styled-components")):e.KeplerGl=t(e.React,e.styled)}(this,(function(e,t){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=17)}([function(t,n){t.exports=e},,function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(24),o=n(25),a=n(9),i=n(26);e.exports=function(e,t){return r(e)||o(e,t)||a(e,t)||i()},e.exports.default=e.exports,e.exports.__esModule=!0},,,function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,n){e.exports=t},function(e,t,n){var r=n(10);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_COLOR_RANGE=t.COLOR_RANGES=void 0;var o=r(n(12)),a=r(n(3)),i=r(n(4)),l=r(n(30)),c=n(13);function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach((function(t){(0,a.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}for(var f=Object.entries(l.default.schemeGroups).reduce((function(e,t){var n=(0,i.default)(t,2),r=n[0],o=n[1];return u(u({},e),o.reduce((function(e,t){return u(u({},e),{},(0,a.default)({},t,r))}),{}))}),{}),s=(0,o.default)(c.VizColorPalette),g=0,p=Object.entries(l.default);g<p.length;g++){var b=(0,i.default)(p[g],2),h=b[0],E=b[1];if("schemeGroups"!==h)for(var m=0,_=Object.entries(E);m<_.length;m++){var C=(0,i.default)(_[m],2),A=C[0],B=C[1];s.push({name:"ColorBrewer ".concat(h,"-").concat(A),type:f[h],category:"ColorBrewer",colors:B})}}var F=s;t.COLOR_RANGES=F;var y=s.find((function(e){return"Global Warming"===e.name}))||{name:"Global Warming",type:"SEQ",category:"Uber",colors:["#5A1846","#900C3F","#C70039","#E3611C","#F1920E","#FFC300"]};t.DEFAULT_COLOR_RANGE=y},function(e,t,n){var r=n(27),o=n(28),a=n(9),i=n(29);e.exports=function(e){return r(e)||o(e)||a(e)||i()},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VizColorPalette=t.DataVizColors=t.DIV=t.QUA=t.SIN=t.SEQ=void 0;var r="sequential";t.SEQ=r;t.SIN="singlehue";var o="qualitative";t.QUA=o;var a="diverging";t.DIV=a;var i={aqua:"#12939A",tumbleweed:"#DDB27C",mule_fawn:"#88572C",tree_poppy:"#FF991F",flame:"#F15C17",sapphire:"#223F9A",orchid:"#DA70BF",chathams_blue:"#125C77",med_aquamarine:"#4DC19C",crocodile:"#776E57",java:"#17B8BE",chalky:"#F6D18A",light_taupe:"#B7885E",peach_orange:"#FFCB99",apricot:"#F89570",portage:"#829AE3",light_orchid:"#E79FD5",blue_green:"#1E96BE",bermuda:"#89DAC1",cloudy:"#B3AD9E"};t.DataVizColors=i;var l=Object.values(i),c=[{name:"Uber Viz Qualitative 0",type:o,category:"Uber",colors:l.slice(0,3)},{name:"Uber Viz Qualitative 0.5",type:o,category:"Uber",colors:l.slice(0,4)},{name:"Uber Viz Qualitative 1",type:o,category:"Uber",colors:l.slice(0,5)},{name:"Uber Viz Qualitative 1.2",type:o,category:"Uber",colors:l.slice(0,6)},{name:"Uber Viz Qualitative 1.4",type:o,category:"Uber",colors:l.slice(0,7)},{name:"Uber Viz Qualitative 1.6",type:o,category:"Uber",colors:l.slice(0,8)},{name:"Uber Viz Qualitative 1.8",type:o,category:"Uber",colors:l.slice(0,9)},{name:"Uber Viz Qualitative 2",type:o,category:"Uber",colors:l.slice(0,10)},{name:"Uber Viz Qualitative 3",type:o,category:"Uber",colors:l.slice(0,15)},{name:"Uber Viz Qualitative 4",type:o,category:"Uber",colors:l.slice(0,20)}],d=[{name:"Uber Viz Sequential 1",type:r,category:"Uber",colors:["#E6FAFA","#89C6CA","#00939C"]},{name:"Uber Viz Sequential 2",type:r,category:"Uber",colors:["#E6FAFA","#AAD7DA","#68B4BB","#00939C"]},{name:"Uber Viz Sequential 3",type:r,category:"Uber",colors:["#E6FAFA","#B8E0E1","#89C6CA","#56ACB3","#00939C"]},{name:"Uber Viz Sequential 4",type:r,category:"Uber",colors:["#E6FAFA","#C1E5E6","#9DD0D4","#75BBC1","#4BA7AF","#00939C"]},{name:"Uber Viz Sequential 5",type:r,category:"Uber",colors:["#E6FAFA","#C1E5E6","#9DD0D4","#75BBC1","#4BA7AF","#00939C","#108188"]},{name:"Uber Viz Sequential 6",type:r,category:"Uber",colors:["#E6FAFA","#C1E5E6","#9DD0D4","#75BBC1","#4BA7AF","#00939C","#108188","#0E7077"]}],u=[{name:"Uber Viz Diverging 0",type:a,category:"Uber",colors:["#C22E00","#FEEEE8","#00939C"].reverse()},{name:"Uber Viz Diverging 0.5",type:a,category:"Uber",colors:["#C22E00","#EFBEAE","#A2D4D7","#00939C"].reverse()},{name:"Uber Viz Diverging 1",type:a,category:"Uber",colors:["#C22E00","#EC9370","#FEEEE8","#85C4C8","#00939C"].reverse()},{name:"Uber Viz Diverging 1.5",type:a,category:"Uber",colors:["#C22E00","#DD7755","#F8C0AA","#BAE1E2","#5DBABF","#00939C"].reverse()},{name:"Uber Viz Diverging 2",type:a,category:"Uber",colors:["#C22E00","#E17449","#F5B097","#FEEEE8","#A2D4D7","#65B3BA","#00939C"].reverse()},{name:"Uber Viz Diverging 2.5",type:a,category:"Uber",colors:["#C22E00","#D45F39","#E68F71","#F8C0AA","#BAE1E2","#7CC7CB","#3EADB3","#00939C"].reverse()},{name:"Uber Viz Diverging 3",type:a,category:"Uber",colors:["#C22E00","#DA6436","#EC9370","#F8C0AA","#FEEEE8","#B2DCDF","#65B3BA","#49A6AE","#00939C"].reverse()},{name:"Uber Viz Diverging 3.5",type:a,category:"Uber",colors:["#C22E00","#D0532B","#DD7755","#EB9C80","#F8C0AA","#BAE1E2","#8CCED1","#5DBABF","#2FA7AE","#00939C"].reverse()},{name:"Uber Viz Diverging 4",type:a,category:"Uber",colors:["#C22E00","#D55A2B","#E68059","#F2A587","#F8C0AA","#FEEEE8","#BAE1E2","#97CED1","#71BABF","#49A6AE","#00939C"].reverse()}],f=[].concat(u,d,c,[{name:"UberPool",type:a,category:"Uber",colors:["#223F9A","#2C51BE","#482BBD","#7A0DA6","#AE0E7F","#CF1750","#E31A1A","#FD7900","#FAC200","#FAE300"]},{name:"UberPool 9",type:a,category:"Uber",colors:["#2C51BE","#482BBD","#7A0DA6","#AE0E7F","#CF1750","#E31A1A","#FD7900","#FAC200","#FAE300"]},{name:"UberPool 8",type:a,category:"Uber",colors:["#213E9A","#3C1FA7","#811CB5","#C318B0","#D01367","#DE0F0E","#EC7007","#F9E200"]},{name:"UberPool 7",type:a,category:"Uber",colors:["#213E9A","#461FA9","#9B1BBA","#CA168E","#DA102C","#E95E08","#F9E200"]},{name:"UberPool 6",type:a,category:"Uber",colors:["#213E9A","#551EAD","#C019BD","#D31256","#E6470A","#F9E200"]},{name:"UberPool 5",type:a,category:"Uber",colors:["#213E9A","#6E1DB2","#CA168E","#E2260C","#F9E200"]},{name:"UberPool 4",type:a,category:"Uber",colors:["#213E9A","#9B1BBA","#DA102C","#F9E200"]},{name:"UberPool 3",type:a,category:"Uber",colors:["#213E9A","#CA168E","#F9E200"]},{name:"Ice And Fire 3",type:a,category:"Uber",colors:["#0198BD","#FAFEB3","#D50255"]},{name:"Ice And Fire 4",type:a,category:"Uber",colors:["#0198BD","#E8FEB5","#FEAD54","#D50255"]},{name:"Ice And Fire 5",type:a,category:"Uber",colors:["#0198BD","#49E3CE","#FAFEB3","#FEAD54","#D50255"]},{name:"Ice And Fire",type:a,category:"Uber",colors:["#0198BD","#49E3CE","#E8FEB5","#FEEDB1","#FEAD54","#D50255"]},{name:"Ice And Fire 7",type:a,category:"Uber",colors:["#0198BD","#54BAB9","#A7DCB6","#FAFEB3","#FCD583","#FEAD54","#D50255"]},{name:"Ice And Fire 8",type:a,category:"Uber",colors:["#007A99","#0198BD","#49E3CE","#E8FEB5","#FEEDB1","#FEAD54","#D50255","#7F1941"]},{name:"Global Warming 3",type:r,category:"Uber",colors:["#5A1846","#C70039","#FFC300"]},{name:"Global Warming 4",type:r,category:"Uber",colors:["#5A1846","#831A3D","#E3611C","#FFC300"]},{name:"Global Warming 5",type:r,category:"Uber",colors:["#5A1846","#831A3D","#AC1C17","#D55D0E","#FFC300"]},{name:"Global Warming",type:r,category:"Uber",colors:["#5A1846","#900C3F","#C70039","#E3611C","#F1920E","#FFC300"]},{name:"Global Warming 7",type:r,category:"Uber",colors:["#5A1846","#751A43","#911932","#AC1C17","#C84411","#E37B0A","#FFC300"]},{name:"Global Warming 8",type:r,category:"Uber",colors:["#4C0035","#650031","#7F0023","#98000A","#B21800","#CB4600","#E57F00","#FFC300"]},{name:"Sunrise 3",type:r,category:"Uber",colors:["#355C7D","#C06C84","#F8B195"]},{name:"Sunrise 4",type:r,category:"Uber",colors:["#355C7D","#9A627C","#C86A7E","#F8B195"]},{name:"Sunrise",type:r,category:"Uber",colors:["#355C7D","#6C5B7B","#C06C84","#F67280","#F8B195"]},{name:"Sunrise 6",type:r,category:"Uber",colors:["#355C7D","#63617F","#916681","#D88185","#E8998D","#F8B195"]},{name:"Sunrise 7",type:r,category:"Uber",colors:["#355C7D","#63617F","#916681","#C06C84","#D28389","#E59A8F","#F8B195"]},{name:"Sunrise 8",type:r,category:"Uber",colors:["#194266","#355C7D","#63617F","#916681","#C06C84","#D28389","#E59A8F","#F8B195"]},{name:"Ocean Green 3",type:r,category:"Uber",colors:["#3A748A","#3EACA8","#E5EEc1"]},{name:"Ocean Green 4",type:r,category:"Uber",colors:["#547A82","#3EACA8","#A2D4AB","#E5EEc1"]},{name:"Ocean Green 5",type:r,category:"Uber",colors:["#3A748A","#54A38F","#73BC84","#A9D597","#E5EEc1"]},{name:"Ocean Green 6",type:r,category:"Uber",colors:["#37535E","#3A748A","#4095B5","#52AEC9","#72BFC4","#93CFBF"]},{name:"Ocean Green 7",type:r,category:"Uber",colors:["#3A748A","#4B9A95","#5EAB8B","#73BC84","#92CC8B","#BEDDA5","#E5EEc1"]},{name:"Ocean Green 8",type:r,category:"Uber",colors:["#37535E","#3A748A","#4B9A95","#5EAB8B","#73BC84","#92CC8B","#BEDDA5","#E5EEc1"]},{name:"Pink Wine 3",type:r,category:"Uber",colors:["#50315E","#956485","#EDD1CA"]},{name:"Pink Wine 4",type:r,category:"Uber",colors:["#50315E","#774976","#B28294","#EDD1CA"]},{name:"Pink Wine 5",type:r,category:"Uber",colors:["#50315E","#643D68","#956485","#C1939D","#EDD1CA"]},{name:"Pink Wine 6",type:r,category:"Uber",colors:["#2C1E3D","#573660","#83537C","#A6758E","#C99DA4","#EDD1CA"]},{name:"Pink Wine 7",type:r,category:"Uber",colors:["#2C1E3D","#4F315A","#774976","#956485","#B28294","#CFA4A8","#EDD1CA"]},{name:"Pink Wine",type:r,category:"Uber",colors:["#2C1E3D","#50315E","#764476","#9A5B88","#B77495","#CF91A3","#E0B1B3","#EDD1CA"]},{name:"Purple Blue Yellow 3",type:r,category:"Uber",colors:["#2B1E3E","#5EA28D","#D6DEBF"]},{name:"Purple Blue Yellow 4",type:r,category:"Uber",colors:["#2B1E3E","#466373","#7BA889","#D6DEBF"]},{name:"Purple Blue Yellow 5",type:r,category:"Uber",colors:["#2B1E3E","#3A4B66","#5F8E86","#8BB68D","#D6DEBF"]},{name:"Purple Blue Yellow 6",type:r,category:"Uber",colors:["#2B1E3E","#343D5E","#4F777E","#709E87","#99BE95","#D6DEBF"]},{name:"Purple Blue Yellow 7",type:r,category:"Uber",colors:["#2B1E3E","#303558","#466373","#5F8E86","#7BA889","#A4C39B","#D6DEBF"]},{name:"Purple Blue Yellow",type:r,category:"Uber",colors:["#2B1E3E","#383C65","#3E5F7E","#49838A","#5EA28D","#82BB92","#AECEA1","#D6DEBF"]}]);t.VizColorPalette=f},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),t.getHTMLMapModeTileUrl=Ce,t.GEOCODER_LAYER_ID=t.GEOCODER_DATASET_NAME=t.SPEED_CONTROL_STEP=t.SPEED_CONTROL_RANGE=t.DEFAULT_TIME_FORMAT=t.ANIMATION_WINDOW=t.FPS=t.BASE_SPEED=t.THROTTLE_NOTIFICATION_TIME=t.DEFAULT_NOTIFICATION_TOPICS=t.DEFAULT_NOTIFICATION_TYPES=t.DEFAULT_NOTIFICATION_MESSAGE=t.DEFAULT_UUID_COUNT=t.EXPORT_HTML_MAP_MODE_OPTIONS=t.EXPORT_MAP_FORMAT_OPTIONS=t.EXPORT_HTML_MAP_MODES=t.EXPORT_MAP_FORMATS=t.EXPORT_DATA_TYPE_OPTIONS=t.EXPORT_DATA_TYPE=t.EXPORT_IMG_RESOLUTION_OPTIONS=t.TwoXResolutionOption=t.OneXResolutionOption=t.EXPORT_IMG_RATIO_OPTIONS=t.SixteenByNineRatioOption=t.FourByThreeRatioOption=t.CustomRatioOption=t.ScreenRatioOption=t.EXPORT_IMG_RATIOS=t.RESOLUTIONS=t.MAX_DEFAULT_TOOLTIPS=t.LAYER_BLENDINGS=t.OVERLAY_BLENDINGS=t.DEFAULT_PICKING_RADIUS=t.NO_VALUE_COLOR=t.DEFAULT_TOOLTIP_FIELDS=t.DEFAULT_LAYER_COLOR=t.CHANNEL_SCALE_SUPPORTED_FIELDS=t.FIELD_OPTS=t.DEFAULT_AGGREGATION=t.notSupportAggrOpts=t.notSupportedScaleOpts=t.ordinalFieldAggrScaleFunctions=t.ordinalFieldScaleFunctions=t.linearFieldAggrScaleFunctions=t.linearFieldScaleFunctions=t.AGGREGATION_TYPE_OPTIONS=t.AGGREGATION_TYPES=t.CHANNEL_SCALES=t.HIGHLIGH_COLOR_3D=t.FIELD_COLORS=t.FIELD_TYPE_DISPLAY=t.TABLE_OPTION_LIST=t.TABLE_OPTION=t.SORT_ORDER=t.ALL_FIELD_TYPES=t.SCALE_FUNC=t.SCALE_TYPES=t.DEFAULT_FILTER_VIEW_TYPE=t.FILTER_VIEW_TYPES=t.FILTER_TYPES=t.TRIP_ARC_FIELDS=t.ALTITUDE_FIELDS=t.TRIP_POINT_FIELDS=t.ICON_FIELDS=t.GEOJSON_FIELDS=t.DEFAULT_MAP_STYLES=t.NO_BASEMAP_ICON=t.EMPTY_MAPBOX_STYLE=t.NO_MAP_ID=t.BASE_MAP_COLOR_MODES=t.DEFAULT_LAYER_GROUPS=t.BACKGROUND_LAYER_GROUP=t.THREE_D_BUILDING_LAYER_GROUP_SLUG=t.BACKGROUND_LAYER_GROUP_SLUG=t.BASE_MAP_BACKGROUND_LAYER_IDS=t.DEFAULT_BACKGROUND_COLOR=t.DEFAULT_BLDG_COLOR=t.PANELS=t.PANEL_VIEW_TOGGLES=t.SIDEBAR_PANELS=t.THEME=t.DIMENSIONS=t.KEPLER_GL_WEBSITE=t.KEPLER_GL_VERSION=t.KEPLER_GL_NAME=t.SHARE_MAP_ID=t.OVERWRITE_MAP_ID=t.SAVE_MAP_ID=t.EXPORT_MAP_ID=t.ADD_MAP_STYLE_ID=t.EXPORT_DATA_ID=t.EXPORT_IMAGE_ID=t.ADD_DATA_ID=t.DELETE_DATA_ID=t.DATA_TABLE_ID=t.TRANSITION_DURATION=t.DEFAULT_MAPBOX_API_URL=t.BASEMAP_ICON_PREFIX=t.KEPLER_UNFOLDED_BUCKET=t.ACTION_PREFIX=void 0,t.EFFECT_DESCRIPTIONS=t.POSTPROCESSING_EFFECTS=t.LIGHT_AND_SHADOW_EFFECT=t.DEFAULT_LIGHT_AND_SHADOW_PROPS=t.LIGHT_AND_SHADOW_EFFECT_TIME_MODES=t.DEFAULT_SHADOW_COLOR=t.DEFAULT_SHADOW_INTENSITY=t.DEFAULT_LIGHT_INTENSITY=t.DEFAULT_LIGHT_COLOR=t.DEFAULT_POST_PROCESSING_EFFECT_TYPE=t.DEFAULT_TIMEZONE=t.dataTestIds=t.TEXT_OUTLINE_MULTIPLIER=t.PROJECTED_PIXEL_SIZE_MULTIPLIER=t.MAP_CONTROLS=t.DATASET_FORMATS=t.DEFAULT_FEATURE_FLAGS=t.LOADING_METHODS=t.MAP_INFO_CHARACTER=t.MAP_THUMBNAIL_DIMENSION=t.MAX_GPU_FILTERS=t.INIT_FILTER_ITEMS_IN_DROPDOWN=t.PLOT_TYPES=t.EDITOR_MODES=t.EDITOR_LAYER_PICKING_RADIUS=t.EDITOR_LAYER_ID=t.GEOCODER_ICON_SIZE=t.GEOCODER_ICON_COLOR=t.GEOCODER_GEO_OFFSET=void 0;var o,a,i,l,c,d,u,f,s,g,p,b,h,E=r(n(12)),m=r(n(4)),_=r(n(3)),C=r(n(15)),A=n(39),B=n(16);function F(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?F(Object(n),!0).forEach((function(t){(0,_.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):F(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}t.ACTION_PREFIX="@@kepler.gl/";t.KEPLER_UNFOLDED_BUCKET="https://studio-public-data.foursquare.com/statics/keplergl";var T="".concat("https://studio-public-data.foursquare.com/statics/keplergl","/geodude");t.BASEMAP_ICON_PREFIX=T;t.DEFAULT_MAPBOX_API_URL="https://api.mapbox.com";t.TRANSITION_DURATION=0;t.DATA_TABLE_ID="dataTable";t.DELETE_DATA_ID="deleteData";t.ADD_DATA_ID="addData";t.EXPORT_IMAGE_ID="exportImage";t.EXPORT_DATA_ID="exportData";t.ADD_MAP_STYLE_ID="addMapStyle";t.EXPORT_MAP_ID="exportMap";t.SAVE_MAP_ID="saveMap";t.OVERWRITE_MAP_ID="overwriteMap";t.SHARE_MAP_ID="shareMap";t.KEPLER_GL_NAME="kepler.gl";t.KEPLER_GL_VERSION="3.0.0-alpha.2";t.KEPLER_GL_WEBSITE="http://kepler.gl/";t.DIMENSIONS={sidePanel:{width:300,margin:{top:20,left:20,bottom:30,right:20},headerHeight:96},mapControl:{width:184,padding:12,mapLegend:{pinned:{bottom:22,right:12}}}};var D=(0,C.default)({light:null,dark:null,base:null});t.THEME=D;var v=[{id:"layer",label:"sidebar.panels.layer",onClick:null},{id:"filter",label:"sidebar.panels.filter",onClick:null},{id:"interaction",label:"sidebar.panels.interaction",onClick:null},{id:"map",label:"sidebar.panels.basemap",onClick:null}];t.SIDEBAR_PANELS=v;var L=(0,C.default)({list:null,byDataset:null});t.PANEL_VIEW_TOGGLES=L;var O=v;t.PANELS=O;t.DEFAULT_BLDG_COLOR="#D1CEC7";t.DEFAULT_BACKGROUND_COLOR="#000000";t.BASE_MAP_BACKGROUND_LAYER_IDS=["background","bg","land","water"];t.BACKGROUND_LAYER_GROUP_SLUG="Background";t.THREE_D_BUILDING_LAYER_GROUP_SLUG="3d building";var P={slug:"Background",filter:function(){return!1},defaultVisibility:!1,isVisibilityToggleAvailable:!1,isMoveToTopAvailable:!1,isColorPickerAvailable:!0};t.BACKGROUND_LAYER_GROUP=P;var I=[{slug:"label",filter:function(e){return e.id.match(/(?=(label|place-|poi-))/)},defaultVisibility:!0,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!1},{slug:"road",filter:function(e){return e.id.match(/(?=(road|railway|tunnel|street|bridge))(?!.*label)/)},defaultVisibility:!0,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!1},{slug:"border",filter:function(e){return e.id.match(/border|boundaries|boundary/)},defaultVisibility:!1,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!1},{slug:"building",filter:function(e){return e.id.match(/building/)},defaultVisibility:!0,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!1},{slug:"water",filter:function(e){return e.id.match(/(?=(water|stream|ferry))/)},defaultVisibility:!0,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!1},{slug:"land",filter:function(e){return e.id.match(/(?=(parks|landcover|industrial|sand|hillshade))/)},defaultVisibility:!0,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!1},{slug:"3d building",filter:function(){return!1},defaultVisibility:!1,isVisibilityToggleAvailable:!0,isMoveToTopAvailable:!0,isColorPickerAvailable:!0}];t.DEFAULT_LAYER_GROUPS=I;var S=(0,C.default)({NONE:null,DARK:null,LIGHT:null});t.BASE_MAP_COLOR_MODES=S;t.NO_MAP_ID="no_map";var x={version:8,sources:{},layers:[]};t.EMPTY_MAPBOX_STYLE=x;var w="".concat(T,"/NO_BASEMAP.png");t.NO_BASEMAP_ICON=w;var M=[{id:"no_map",label:"No Basemap",url:"",icon:w,layerGroups:[P],colorMode:S.NONE,style:x},{id:"dark-matter",label:"DarkMatter",url:"https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json",icon:"".concat(T,"/DARKMATTER.png"),layerGroups:I,colorMode:S.DARK,complimentaryStyleId:"positron"},{id:"dark-matter-nolabels",label:"DarkMatterNoLabels",url:"https://basemaps.cartocdn.com/gl/dark-matter-nolabels-gl-style/style.json",icon:"".concat(T,"/DARKMATTER_NOLABELS.png"),layerGroups:I,colorMode:S.DARK,complimentaryStyleId:"positron-nolabels"},{id:"positron",label:"Positron",url:"https://basemaps.cartocdn.com/gl/positron-gl-style/style.json",icon:"".concat(T,"/POSITRON.png"),layerGroups:I,colorMode:S.LIGHT,complimentaryStyleId:"dark-matter"},{id:"positron-nolabels",label:"PositronNoLabels",url:"https://basemaps.cartocdn.com/gl/positron-nolabels-gl-style/style.json",icon:"".concat(T,"/POSITRON_NOLABELS.png"),layerGroups:I,colorMode:S.LIGHT,complimentaryStyleId:"dark-matter-nolabels"},{id:"voyager",label:"Voyager",url:"https://basemaps.cartocdn.com/gl/voyager-gl-style/style.json",icon:"".concat(T,"/VOYAGER.png"),layerGroups:I,colorMode:S.LIGHT,complimentaryStyleId:"dark-matter"},{id:"voyager-nolabels",label:"VoyagerNoLabels",url:"https://basemaps.cartocdn.com/gl/voyager-nolabels-gl-style/style.json",icon:"".concat(T,"/VOYAGER_NOLABELS.png"),layerGroups:I,colorMode:S.LIGHT,complimentaryStyleId:"dark-matter-nolabels"}];t.DEFAULT_MAP_STYLES=M;t.GEOJSON_FIELDS={geojson:["_geojson","all_points","geojson"]};t.ICON_FIELDS={icon:["icon"]};t.TRIP_POINT_FIELDS=[["lat","lng"],["lat","lon"],["lat","long"],["latitude","longitude"]];t.ALTITUDE_FIELDS=["alt","altitude"];t.TRIP_ARC_FIELDS={lat0:"begintrip",lng0:"begintrip",lat1:"dropoff",lng1:"dropoff"};var R=(0,C.default)({range:null,select:null,input:null,timeRange:null,multiSelect:null,polygon:null});t.FILTER_TYPES=R;var k=(0,C.default)({side:null,enlarged:null,minified:null});t.FILTER_VIEW_TYPES=k;var H=k.side;t.DEFAULT_FILTER_VIEW_TYPE=H;var N=(0,C.default)({ordinal:null,quantile:null,quantize:null,linear:null,sqrt:null,log:null,point:null});t.SCALE_TYPES=N;var U=(o={},(0,_.default)(o,N.linear,A.scaleLinear),(0,_.default)(o,N.quantize,A.scaleQuantize),(0,_.default)(o,N.quantile,A.scaleQuantile),(0,_.default)(o,N.ordinal,A.scaleOrdinal),(0,_.default)(o,N.sqrt,A.scaleSqrt),(0,_.default)(o,N.log,A.scaleLog),(0,_.default)(o,N.point,A.scalePoint),o);t.SCALE_FUNC=U;var G=(0,C.default)({boolean:null,date:null,geojson:null,integer:null,real:null,string:null,timestamp:null,point:null,array:null,object:null,geoarrow:null});t.ALL_FIELD_TYPES=G;var V=(0,C.default)({ASCENDING:null,DESCENDING:null,UNSORT:null});t.SORT_ORDER=V;var Y=(0,C.default)({SORT_ASC:null,SORT_DES:null,UNSORT:null,PIN:null,UNPIN:null,COPY:null,FORMAT_COLUMN:null});t.TABLE_OPTION=Y;var z=[{value:Y.SORT_ASC,display:"Sort Ascending",icon:"ArrowUp",condition:function(e){return e.sortMode!==V.ASCENDING}},{value:Y.SORT_DES,display:"Sort Descending",icon:"ArrowDown",condition:function(e){return e.sortMode!==V.DESCENDING}},{value:Y.UNSORT,display:"Unsort Column",icon:"Cancel",condition:function(e){return e.isSorted}},{value:Y.PIN,display:"Pin Column",icon:"Pin",condition:function(e){return!e.isPinned}},{value:Y.UNPIN,display:"Unpin Column",icon:"Cancel",condition:function(e){return e.isPinned}},{value:Y.COPY,display:"Copy Column",icon:"Clipboard"},{value:Y.FORMAT_COLUMN,display:"Format Column",icon:"Hash"}];t.TABLE_OPTION_LIST=z;var j=(a={},(0,_.default)(a,G.boolean,{label:"bool",color:"242, 152, 163"}),(0,_.default)(a,G.date,{label:"date",color:"160, 106, 206"}),(0,_.default)(a,G.geojson,{label:"geo",color:"106, 160, 206"}),(0,_.default)(a,G.geoarrow,{label:"geo",color:"106, 160, 206"}),(0,_.default)(a,G.integer,{label:"int",color:"248, 194, 28"}),(0,_.default)(a,G.real,{label:"float",color:"248, 194, 28"}),(0,_.default)(a,G.string,{label:"string",color:"140, 210, 205"}),(0,_.default)(a,G.timestamp,{label:"time",color:"106, 160, 56"}),(0,_.default)(a,G.point,{label:"point",color:"0, 172, 237"}),(0,_.default)(a,G.array,{label:"array",color:"231, 110, 58"}),(0,_.default)(a,G.object,{label:"object",color:"74, 165, 150"}),a);t.FIELD_TYPE_DISPLAY=j;var W={default:"237, 88, 106"};t.FIELD_COLORS=W;t.HIGHLIGH_COLOR_3D=[255,255,255,60];var q=(0,C.default)({color:null,radius:null,size:null,colorAggr:null,sizeAggr:null});t.CHANNEL_SCALES=q;var X={count:"count",average:"average",maximum:"maximum",minimum:"minimum",median:"median",stdev:"stdev",sum:"sum",variance:"variance",mode:"mode",countUnique:"countUnique"};t.AGGREGATION_TYPES=X;var K=Object.entries(X).map((function(e){var t=(0,m.default)(e,2),n=t[0],r=t[1];return{id:n,label:"stdev"===n?"Std Deviation":"countUnique"===n?"Count Unique":"string"==typeof r?r.charAt(0).toUpperCase()+r.slice(1):r}}));t.AGGREGATION_TYPE_OPTIONS=K;var Z=(i={},(0,_.default)(i,q.color,[N.quantize,N.quantile]),(0,_.default)(i,q.radius,[N.sqrt]),(0,_.default)(i,q.size,[N.linear,N.sqrt,N.log]),i);t.linearFieldScaleFunctions=Z;var Q=(d={},(0,_.default)(d,q.colorAggr,(l={},(0,_.default)(l,X.average,[N.quantize,N.quantile]),(0,_.default)(l,X.maximum,[N.quantize,N.quantile]),(0,_.default)(l,X.minimum,[N.quantize,N.quantile]),(0,_.default)(l,X.median,[N.quantize,N.quantile]),(0,_.default)(l,X.stdev,[N.quantize,N.quantile]),(0,_.default)(l,X.sum,[N.quantize,N.quantile]),(0,_.default)(l,X.variance,[N.quantize,N.quantile]),l)),(0,_.default)(d,q.sizeAggr,(c={},(0,_.default)(c,X.average,[N.linear,N.sqrt,N.log]),(0,_.default)(c,X.maximum,[N.linear,N.sqrt,N.log]),(0,_.default)(c,X.minimum,[N.linear,N.sqrt,N.log]),(0,_.default)(c,X.median,[N.linear,N.sqrt,N.log]),(0,_.default)(c,X.stdev,[N.linear,N.sqrt,N.log]),(0,_.default)(c,X.sum,[N.linear,N.sqrt,N.log]),(0,_.default)(c,X.variance,[N.linear,N.sqrt,N.log]),c)),d);t.linearFieldAggrScaleFunctions=Q;var $=(u={},(0,_.default)(u,q.color,[N.ordinal]),(0,_.default)(u,q.radius,[N.point]),(0,_.default)(u,q.size,[N.point]),u);t.ordinalFieldScaleFunctions=$;var J=(s={},(0,_.default)(s,q.colorAggr,(f={},(0,_.default)(f,X.mode,[N.ordinal]),(0,_.default)(f,X.countUnique,[N.quantize,N.quantile]),f)),(0,_.default)(s,q.sizeAggr,{}),s);t.ordinalFieldAggrScaleFunctions=J;var ee=(g={},(0,_.default)(g,q.color,[]),(0,_.default)(g,q.radius,[]),(0,_.default)(g,q.size,[]),g);t.notSupportedScaleOpts=ee;var te=(p={},(0,_.default)(p,q.colorAggr,{}),(0,_.default)(p,q.sizeAggr,{}),p);t.notSupportAggrOpts=te;var ne=(b={},(0,_.default)(b,q.colorAggr,(0,_.default)({},X.count,[N.quantize,N.quantile])),(0,_.default)(b,q.sizeAggr,(0,_.default)({},X.count,[N.linear,N.sqrt,N.log])),b);t.DEFAULT_AGGREGATION=ne;var re=(h={},(0,_.default)(h,G.string,{type:"categorical",scale:y(y({},$),J),format:{legend:function(e){return e},tooltip:[]}}),(0,_.default)(h,G.real,{type:"numerical",scale:y(y({},Z),Q),format:{legend:function(e){return e},tooltip:[B.TOOLTIP_FORMAT_TYPES.NONE,B.TOOLTIP_FORMAT_TYPES.DECIMAL,B.TOOLTIP_FORMAT_TYPES.PERCENTAGE]}}),(0,_.default)(h,G.timestamp,{type:"time",scale:y(y({},Z),te),format:{legend:function(e){return e},tooltip:[B.TOOLTIP_FORMAT_TYPES.NONE,B.TOOLTIP_FORMAT_TYPES.DATE,B.TOOLTIP_FORMAT_TYPES.DATE_TIME]}}),(0,_.default)(h,G.integer,{type:"numerical",scale:y(y({},Z),Q),format:{legend:function(e){return e},tooltip:[B.TOOLTIP_FORMAT_TYPES.NONE,B.TOOLTIP_FORMAT_TYPES.DECIMAL,B.TOOLTIP_FORMAT_TYPES.PERCENTAGE]}}),(0,_.default)(h,G.boolean,{type:"boolean",scale:y(y({},$),J),format:{legend:function(e){return e},tooltip:[B.TOOLTIP_FORMAT_TYPES.NONE,B.TOOLTIP_FORMAT_TYPES.BOOLEAN]}}),(0,_.default)(h,G.date,{type:"time",scale:y(y({},$),J),format:{legend:function(e){return e},tooltip:[B.TOOLTIP_FORMAT_TYPES.NONE,B.TOOLTIP_FORMAT_TYPES.DATE]}}),(0,_.default)(h,G.geojson,{type:"geometry",scale:y(y({},ee),te),format:{legend:function(e){return"..."},tooltip:[]}}),(0,_.default)(h,G.geoarrow,{type:"geometry",scale:y(y({},ee),te),format:{legend:function(e){return"..."},tooltip:[]}}),(0,_.default)(h,G.object,{type:"numerical",scale:{},format:{legend:function(e){return"..."},tooltip:[]}}),(0,_.default)(h,G.array,{type:"numerical",scale:{},format:{legend:function(e){return"..."},tooltip:[]}}),h);t.FIELD_OPTS=re;var oe=Object.keys(q).reduce((function(e,t){return y(y({},e),{},(0,_.default)({},t,Object.keys(re).filter((function(e){return re[e].scale[t]&&Object.keys(re[e].scale[t]).length}))))}),{});t.CHANNEL_SCALE_SUPPORTED_FIELDS=oe;t.DEFAULT_LAYER_COLOR={tripArc:"#9226C6",begintrip_lat:"#1E96BE",dropoff_lat:"#FF991F",request_lat:"#52A353"};t.DEFAULT_TOOLTIP_FIELDS=[];t.NO_VALUE_COLOR=[0,0,0,0];t.DEFAULT_PICKING_RADIUS=3;t.OVERLAY_BLENDINGS={normal:{label:"overlayBlending.normal",value:"normal"},screen:{label:"overlayBlending.screen",value:"screen"},darken:{label:"overlayBlending.darken",value:"darken"}};t.LAYER_BLENDINGS={additive:{label:"layerBlending.additive",blendFunc:["SRC_ALPHA","DST_ALPHA"],blendEquation:"FUNC_ADD"},normal:{label:"layerBlending.normal",blendFunc:["SRC_ALPHA","ONE_MINUS_SRC_ALPHA","ONE","ONE_MINUS_SRC_ALPHA"],blendEquation:["FUNC_ADD","FUNC_ADD"]},subtractive:{label:"layerBlending.subtractive",blendFunc:["ONE","ONE_MINUS_DST_COLOR","SRC_ALPHA","DST_ALPHA"],blendEquation:["FUNC_SUBTRACT","FUNC_ADD"]}};t.MAX_DEFAULT_TOOLTIPS=5;var ae=(0,C.default)({ONE_X:null,TWO_X:null});t.RESOLUTIONS=ae;var ie=(0,C.default)({SCREEN:null,FOUR_BY_THREE:null,SIXTEEN_BY_NINE:null,CUSTOM:null});t.EXPORT_IMG_RATIOS=ie;var le={id:ie.SCREEN,label:"modal.exportImage.ratioOriginalScreen",getSize:function(e,t){return{width:e,height:t}}};t.ScreenRatioOption=le;var ce={id:ie.CUSTOM,hidden:!0,label:"modal.exportImage.ratioCustom",getSize:function(e,t){return{width:e,height:t}}};t.CustomRatioOption=ce;var de={id:ie.FOUR_BY_THREE,label:"modal.exportImage.ratio4_3",getSize:function(e,t){return{width:e,height:Math.round(.75*e)}}};t.FourByThreeRatioOption=de;var ue={id:ie.SIXTEEN_BY_NINE,label:"modal.exportImage.ratio16_9",getSize:function(e,t){return{width:e,height:Math.round(.5625*e)}}};t.SixteenByNineRatioOption=ue;var fe=[le,ce,de,ue];t.EXPORT_IMG_RATIO_OPTIONS=fe;var se={id:ae.ONE_X,label:"1x",available:!0,scale:1,getSize:function(e,t){return{width:e,height:t}}};t.OneXResolutionOption=se;var ge={id:ae.TWO_X,label:"2x",available:!0,scale:2,getSize:function(e,t){return{width:2*e,height:2*t}}};t.TwoXResolutionOption=ge;var pe=[se,ge];t.EXPORT_IMG_RESOLUTION_OPTIONS=pe;var be=(0,C.default)({CSV:null});t.EXPORT_DATA_TYPE=be;var he=[{id:be.CSV,label:be.CSV.toLowerCase(),available:!0}];t.EXPORT_DATA_TYPE_OPTIONS=he;var Ee=(0,C.default)({HTML:null,JSON:null});t.EXPORT_MAP_FORMATS=Ee;var me=(0,C.default)({READ:null,EDIT:null});t.EXPORT_HTML_MAP_MODES=me;var _e=Object.entries(Ee).map((function(e){return{id:e[0],label:e[1].toLowerCase(),available:!0}}));function Ce(e){return"https://d1a3f4spazzrp4.cloudfront.net/kepler.gl/documentation/map-".concat(e.toLowerCase(),"-mode.png")}t.EXPORT_MAP_FORMAT_OPTIONS=_e;var Ae=Object.entries(me).map((function(e){return{id:e[0],label:"modal.exportMap.html.".concat(e[1].toLowerCase()),available:!0,url:Ce(e[1])}}));t.EXPORT_HTML_MAP_MODE_OPTIONS=Ae;t.DEFAULT_UUID_COUNT=6;t.DEFAULT_NOTIFICATION_MESSAGE="MESSAGE_NOT_PROVIDED";var Be=(0,C.default)({info:null,error:null,warning:null,success:null});t.DEFAULT_NOTIFICATION_TYPES=Be;var Fe=(0,C.default)({global:null,file:null});t.DEFAULT_NOTIFICATION_TOPICS=Fe;t.THROTTLE_NOTIFICATION_TIME=330;t.BASE_SPEED=600;t.FPS=60;var ye=(0,C.default)({free:null,incremental:null,point:null,interval:null});t.ANIMATION_WINDOW=ye;t.DEFAULT_TIME_FORMAT="MM/DD/YY HH:mm:ssa";t.SPEED_CONTROL_RANGE=[0,10];t.SPEED_CONTROL_STEP=.001;t.GEOCODER_DATASET_NAME="geocoder_dataset";t.GEOCODER_LAYER_ID="geocoder_layer";t.GEOCODER_GEO_OFFSET=.05;t.GEOCODER_ICON_COLOR=[255,0,0];t.GEOCODER_ICON_SIZE=80;t.EDITOR_LAYER_ID="kepler_editor_layer";t.EDITOR_LAYER_PICKING_RADIUS=6;t.EDITOR_MODES={DRAW_POLYGON:"DRAW_POLYGON",DRAW_RECTANGLE:"DRAW_RECTANGLE",EDIT:"EDIT_VERTEX"};var Te=(0,C.default)({histogram:null,lineChart:null});t.PLOT_TYPES=Te;t.INIT_FILTER_ITEMS_IN_DROPDOWN=100;t.MAX_GPU_FILTERS=4;t.MAP_THUMBNAIL_DIMENSION={width:300,height:200};t.MAP_INFO_CHARACTER={title:100,description:100};var De=(0,C.default)({upload:null,storage:null});t.LOADING_METHODS=De;t.DEFAULT_FEATURE_FLAGS={};var ve=(0,C.default)({row:null,geojson:null,csv:null,keplergl:null,arrow:null});t.DATASET_FORMATS=ve;var Le=(0,C.default)({visibleLayers:null,mapLegend:null,toggle3d:null,splitMap:null,mapDraw:null,mapLocale:null,effect:null});t.MAP_CONTROLS=Le;t.PROJECTED_PIXEL_SIZE_MULTIPLIER=2/3;t.TEXT_OUTLINE_MULTIPLIER=5;t.dataTestIds={infoIcon:"info-icon",warningIcon:"warning-icon",errorIcon:"error-icon",successIcon:"success-icon",checkmarkIcon:"checkmark-icon",sortableLayerItem:"sortable-layer-item",staticLayerItem:"static-layer-item",layerTitleEditor:"layer__title__editor",removeLayerAction:"remove-layer-action",layerPanel:"layer-panel",sortableEffectItem:"sortable-effect-item",staticEffectItem:"static-effect-item",providerLoading:"provider-loading",providerMapInfoPanel:"provider-map-info-panel",providerSelect:"provider-select",cloudHeader:"cloud-header",providerShareMap:"provider-share-map"};t.DEFAULT_TIMEZONE="UTC";t.DEFAULT_POST_PROCESSING_EFFECT_TYPE="ink";var Oe=[255,255,255];t.DEFAULT_LIGHT_COLOR=Oe;t.DEFAULT_LIGHT_INTENSITY=1;t.DEFAULT_SHADOW_INTENSITY=.5;var Pe=[0,0,0];t.DEFAULT_SHADOW_COLOR=Pe;var Ie={pick:"pick",current:"current",animation:"animation"};t.LIGHT_AND_SHADOW_EFFECT_TIME_MODES=Ie;var Se={timestamp:Date.now(),timeMode:Ie.pick,shadowIntensity:.5,shadowColor:[].concat(Pe),sunLightColor:[].concat(Oe),sunLightIntensity:1,ambientLightColor:[].concat(Oe),ambientLightIntensity:1};t.DEFAULT_LIGHT_AND_SHADOW_PROPS=Se;var xe={type:"lightAndShadow",name:"Light & Shadow",parameters:[{name:"timestamp",min:0,max:Number.MAX_SAFE_INTEGER},{name:"shadowIntensity",min:0,max:1,defaultValue:.5},{name:"sunLightIntensity",min:0,max:1,defaultValue:1},{name:"ambientLightIntensity",min:0,max:1,defaultValue:1},{name:"shadowColor",type:"color",min:0,max:255,defaultValue:Pe},{name:"sunLightColor",type:"color",min:0,max:255,defaultValue:Oe},{name:"ambientLightColor",type:"color",min:0,max:255,defaultValue:Oe}]};t.LIGHT_AND_SHADOW_EFFECT=xe;var we={ink:{type:"ink",name:"Ink",parameters:[{name:"strength",min:0,max:1}]},brightnessContrast:{type:"brightnessContrast",name:"Brightness & Contrast",parameters:[{name:"brightness",min:-1,max:1},{name:"contrast",min:-1,max:1}]},hueSaturation:{type:"hueSaturation",name:"Hue & Saturation",parameters:[{name:"hue",min:-1,max:1},{name:"saturation",defaultValue:.25,min:-1,max:1}]},vibrance:{type:"vibrance",name:"Vibrance",parameters:[{name:"amount",defaultValue:.5,min:-1,max:1}]},sepia:{type:"sepia",name:"Sepia",parameters:[{name:"amount",min:0,max:1}]},dotScreen:{type:"dotScreen",name:"Dot Screen",parameters:[{name:"angle",min:0,max:Math.PI/2},{name:"size",min:1,max:20},{name:"center",type:"array",label:["Center X","Center Y"],defaultValue:[.5,.5],min:0,max:1}]},colorHalftone:{type:"colorHalftone",name:"Color Halftone",parameters:[{name:"angle",min:0,max:Math.PI/2},{name:"size",min:1,max:20},{name:"center",type:"array",label:["Center X","Center Y"],defaultValue:[.5,.5],min:0,max:1}]},noise:{type:"noise",name:"Noise",parameters:[{name:"amount",min:0,max:1}]},triangleBlur:{type:"triangleBlur",name:"Blur (Triangle)",parameters:[{name:"radius",min:0,max:100}]},zoomBlur:{type:"zoomBlur",name:"Blur (Zoom)",parameters:[{name:"strength",defaultValue:.05,min:0,max:1},{name:"center",type:"array",label:["Center X","Center Y"],defaultValue:[.5,.5],min:0,max:1}]},tiltShift:{type:"tiltShift",name:"Blur (Tilt Shift)",parameters:[{name:"blurRadius",label:"Blur",min:0,max:50},{name:"gradientRadius",label:"Gradient",min:0,max:400},{name:"start",type:"array",label:["Start",!1],defaultValue:[0,0],min:0,max:1},{name:"end",type:"array",label:["End",!1],defaultValue:[1,1],min:0,max:1}]},edgeWork:{type:"edgeWork",name:"Edge work",parameters:[{name:"radius",min:1,max:50}]},vignette:{type:"vignette",name:"Vignette",parameters:[{name:"amount",min:0,max:1},{name:"radius",min:0,max:1}]},magnify:{type:"magnify",name:"Magnify",parameters:[{name:"screenXY",type:"array",label:["Position X","Position Y"],defaultValue:[.5,.5],min:0,max:1},{name:"radiusPixels",label:"Size",min:10,max:500},{name:"zoom",min:.5,max:50},{name:"borderWidthPixels",label:"Border Width",defaultValue:3,min:0,max:50}]},hexagonalPixelate:{type:"hexagonalPixelate",name:"Hexagonal Pixelate",parameters:[{name:"scale",defaultValue:20,min:1,max:50}]}};t.POSTPROCESSING_EFFECTS=we;var Me=[xe].concat((0,E.default)(Object.keys(we).map((function(e){return we[e]}))));t.EFFECT_DESCRIPTIONS=Me},function(e,t,n){"use strict";e.exports=function(e){var t,n={};if(!(e instanceof Object)||Array.isArray(e))throw new Error("keyMirror(...): Argument must be an object.");for(t in e)e.hasOwnProperty(t)&&(n[t]=t);return n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.COMPARE_TYPES=t.TOOLTIP_FORMATS=t.TOOLTIP_KEY=t.TOOLTIP_FORMAT_TYPES=void 0;var r={NONE:"none",DATE:"date",DATE_TIME:"date_time",DECIMAL:"decimal",PERCENTAGE:"percentage",BOOLEAN:"boolean"};t.TOOLTIP_FORMAT_TYPES=r;t.TOOLTIP_KEY="format";var o={NONE:{id:"NONE",label:"None",format:null,type:r.NONE},DECIMAL_SHORT:{id:"DECIMAL_SHORT",label:"12345 → 10k",format:".1s",type:r.DECIMAL},DECIMAL_COMMA:{id:"DECIMAL_COMMA",label:"12345 → 12,345",format:",",type:r.DECIMAL},DECIMAL_SHORT_COMMA:{id:"DECIMAL_SHORT_COMMA",label:"12345 → 12.3k",format:".3~s",type:r.DECIMAL},DECIMAL_PERCENT_FULL_0:{id:"DECIMAL_PERCENT_FULL_0",label:".01 → 1%",format:".0%",type:r.DECIMAL},DECIMAL_PERCENT_FULL_1:{id:"DECIMAL_PERCENT_FULL_1",label:".01 → 1.0%",format:".1%",type:r.DECIMAL},DECIMAL_PERCENT_FULL_2:{id:"DECIMAL_PERCENT_FULL_2",label:".01 → 1.00%",format:".2%",type:r.DECIMAL},DECIMAL_PRECENT_REGULAR:{id:"DECIMAL_PRECENT_REGULAR",label:"12.345 → 12.35%",format:"~%",type:r.PERCENTAGE},DECIMAL_DECIMAL_FIXED_2:{id:"DECIMAL_DECIMAL_FIXED_2",label:"1.2345 → 1.23",format:".2~f",type:r.DECIMAL},DECIMAL_DECIMAL_FIXED_3:{id:"DECIMAL_DECIMAL_FIXED_3",label:"1.2345 → 1.234",format:".3~f",type:r.DECIMAL},DECIMAL_DECIMAL_FIXED_4:{id:"DECIMAL_DECIMAL_FIXED_4",label:"1.23456 → 1.2346",format:".4~f",type:r.DECIMAL},DECIMAL_SCIENTIFIC_FIXED_2:{id:"DECIMAL_SCIENTIFIC_FIXED_2",label:"0.12345 → 1.23e-1",format:".2~e",type:r.DECIMAL},DECIMAL_SCIENTIFIC_FIXED_3:{id:"DECIMAL_SCIENTIFIC_FIXED_3",label:"0.12345 → 1.235e-1",format:".3~e",type:r.DECIMAL},DECIMAL_SCIENTIFIC_FIXED_4:{id:"DECIMAL_SCIENTIFIC_FIXED_4",label:"0.123456 → 1.2346e-1",format:".4~e",type:r.DECIMAL},DECIMAL_INT:{id:"DECIMAL_INT",label:"12345 → 12350",format:".4~r",type:r.DECIMAL},DECIMAL_THREE:{id:"DECIMAL_THREE",label:"12345.4321 → 12,345.432",format:",.3~f",type:r.DECIMAL},DECIMAL_FOUR:{id:"DECIMAL_FOUR",label:"12345.54321 → 12,345.5432",format:",.4~f",type:r.DECIMAL},DECIMAL_DELTA:{id:"DECIMAL_DELTA",label:"12345.4321 → +12,345.432",format:"+,.3f",type:r.DECIMAL},DECIMAL_CURRENCY:{id:"DECIMAL_CURRENCY",label:"12345.4321 → $12,345.43",format:"$,.2f",type:r.DECIMAL},DATE_L:{id:"DATE_L",label:"",format:"L",type:r.DATE},DATE_LL:{id:"DATE_LL",label:"",format:"LL",type:r.DATE},DATE_dddd_LL:{id:"DATE_dddd_LL",label:"",format:"dddd LL",type:r.DATE},DATE_ddd_LL:{id:"DATE_ddd_LL",label:"",format:"ddd LL",type:r.DATE},DATE_TIME_L_LT:{id:"DATE_TIME_L_LT",label:"",format:"L LT",type:r.DATE_TIME},DATE_TIME_L_LTS:{id:"DATE_TIME_L_LTS",label:"",format:"L LTS",type:r.DATE_TIME},DATE_TIME_LLL:{id:"DATE_TIME_LLL",label:"",format:"LLL",type:r.DATE_TIME},DATE_TIME_LL_LTS:{id:"DATE_TIME_LL_LTS",label:"",format:"LL LTS",type:r.DATE_TIME},DATE_TIME_ddd_LLL:{id:"DATE_TIME_ddd_LLL",label:"",format:"ddd LLL",type:r.DATE_TIME},DATE_TIME_LTS:{id:"DATE_TIME_LTS",label:"",format:"LTS",type:r.DATE_TIME},BOOLEAN_NUM:{id:"BOOLEAN_NUM",label:"0 | 1",format:"01",type:r.BOOLEAN},BOOLEAN_Y_N:{id:"BOOLEAN_Y_N",label:"yes | no",format:"yn",type:r.BOOLEAN}};t.TOOLTIP_FORMATS=o;t.COMPARE_TYPES={ABSOLUTE:"absolute",RELATIVE:"relative"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(21);Object.keys(r).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===r[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return r[e]}}))}));var o=n(38);Object.keys(o).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===o[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return o[e]}}))}))},,,,function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),t.inputBorderActiveColor=t.inputBorderHoverColorLT=t.inputBorderHoverColor=t.inputBorderColor=t.inputBgdActiveLT=t.inputBgdActive=t.inputBgdHover=t.inputBgd=t.inputFontWeight=t.inputFontSizeSmall=t.inputFontSize=t.inputPaddingTiny=t.inputPaddingSmall=t.inputPadding=t.inputBoxHeightTiny=t.inputBoxHeightSmall=t.inputBoxHeight=t.scrollbarThumbColorHoverLT=t.scrollbarThumbColorLT=t.selectionBtnBorderActColor=t.selectionBtnBorderColor=t.selectionBtnBorder=t.selectionBtnBgdHover=t.selectionBtnActColor=t.selectionBtnColor=t.selectionBtnActBgd=t.selectionBtnBgd=t.floatingBtnActColor=t.floatingBtnColor=t.floatingBtnBorderHover=t.floatingBtnBorder=t.floatingBtnBgdHover=t.floatingBtnActBgd=t.floatingBtnBgd=t.negativeBtnActColor=t.negativeBtnColor=t.negativeBtnBorder=t.negativeBtnBgdHover=t.negativeBtnActBgd=t.negativeBtnBgd=t.linkBtnBorder=t.linkBtnActBgdHover=t.linkBtnActColor=t.linkBtnColor=t.linkBtnActBgd=t.linkBtnBgd=t.ctaBtnActColor=t.ctaBtnColor=t.ctaBtnActBgd=t.ctaBtnBgdHover=t.ctaBtnBgd=t.secondaryBtnBorder=t.secondaryBtnBgdHover=t.secondaryBtnActColor=t.secondaryBtnColor=t.secondaryBtnActBgd=t.secondaryBtnBgd=t.primaryBtnBorder=t.primaryBtnFontSizeLarge=t.primaryBtnFontSizeSmall=t.primaryBtnFontSizeDefault=t.primaryBtnRadius=t.primaryBtnBgdHover=t.primaryBtnActColor=t.primaryBtnColor=t.primaryBtnActBgd=t.primaryBtnBgd=t.btnFontFamily=t.logoColor=t.errorColor=t.activeColorHover=t.activeColorLT=t.activeColor=t.textColorHlLT=t.textColorHl=t.titleTextColor=t.panelTabWidth=t.panelToggleBorderColor=t.subtextColorActive=t.subtextColorLT=t.subtextColor=t.titleColorLT=t.dataTableTextColor=t.textColorLT=t.textColor=t.labelColorLT=t.labelHoverColor=t.labelColor=t.lineHeight=t.fontSize=t.fontWeight=t.fontFamily=t.borderColorLT=t.borderColor=t.borderRadius=t.boxSizing=t.boxShadow=t.transitionSlow=t.transitionFast=t.transition=void 0,t.panelHeaderHeight=t.panelHeaderIconHover=t.panelHeaderIconActive=t.panelHeaderIcon=t.chickletBgdLT=t.chickletBgd=t.panelHeaderBorderRadius=t.panelBackgroundHover=t.panelContentBackground=t.panelBackground=t.sidePanelTitleLineHeight=t.sidePanelTitleFontsize=t.sideBarCloseBtnBgdHover=t.sideBarCloseBtnColor=t.sideBarCloseBtnBgd=t.sidePanelScrollBarHeight=t.sidePanelScrollBarWidth=t.sidePanelBg=t.sidePanelBorderColor=t.sidePanelBorder=t.sidePanelInnerPadding=t.layerConfigGroupPaddingLeft=t.layerConfigGroupMarginBottom=t.sidePanelHeaderBorder=t.sidePanelHeaderBg=t.radioButtonBgdColor=t.radioButtonRadius=t.radioBorderColor=t.radioBorderRadius=t.radioRadius=t.checkboxBoxBgdChecked=t.checkboxBoxBgd=t.checkboxBorderColorLT=t.checkboxBorderRadius=t.checkboxBorderColor=t.checkboxMargin=t.checkboxHeight=t.checkboxWidth=t.secondarySwitchBtnBgd=t.secondarySwitchTrackBgd=t.switchBtnHeight=t.switchBtnWidth=t.switchBtnBorderRadius=t.switchBtnBoxShadow=t.switchBtnBgdActive=t.switchBtnBgd=t.switchTrackBorderRadius=t.switchTrackBgdActive=t.switchTrackBgd=t.switchLabelMargin=t.switchHeight=t.switchWidth=t.dndOverBackgroundColor=t.dropdownWapperMargin=t.dropdownWrapperZ=t.dropdownListLineHeight=t.dropdownListBorderTopLT=t.dropdownListBorderTop=t.dropdownListBgdLT=t.toolbarItemBorderRaddius=t.toolbarItemBorderHover=t.toolbarItemIconHover=t.toolbarItemBgdHover=t.dropdownListBgd=t.dropdownListShadow=t.dropdownListHighlightBgLT=t.dropdownListHighlightBg=t.panelTabColor=t.selectBorder=t.selectBorderRadius=t.selectBorderColorLT=t.selectBorderColor=t.selectBackgroundHoverLT=t.selectBackgroundLT=t.selectBackgroundHover=t.selectBackground=t.selectColorPlaceHolderLT=t.selectColorPlaceHolder=t.selectFontWeightBold=t.selectFontWeight=t.selectFontSize=t.selectActiveBorderColor=t.selectColorLT=t.selectColor=t.dropdownSelectHeight=t.secondaryInputBorderActiveColor=t.secondaryInputBorderColor=t.secondaryInputColor=t.secondaryInputBgdActive=t.secondaryInputBgdHover=t.secondaryInputBgd=t.inputBoxShadowActiveLT=t.inputBoxShadowActive=t.inputBoxShadow=t.inputPlaceholderFontWeight=t.inputPlaceholderColorLT=t.inputPlaceholderColor=t.inputBorderRadius=t.inputColor=t.inputBorderActiveColorLT=void 0,t.fieldTokenWidth=t.fieldTokenHeight=t.fieldTokenRightMargin=t.actionPanelHeight=t.actionPanelWidth=t.notificationPanelItemHeight=t.notificationPanelItemWidth=t.notificationPanelWidth=t.notificationColors=t.rangePlotContainerHLargePalm=t.rangePlotContainerHLarge=t.rangePlotHLargePalm=t.rangePlotHLarge=t.rangePlotContainerH=t.rangePlotH=t.rangePlotMarginLarge=t.rangePlotMargin=t.timeTitleFontSize=t.axisFontColor=t.axisFontSize=t.histogramFillOutRange=t.histogramFillInRange=t.rangeBrushBgd=t.mapControlTop=t.geocoderInputHeight=t.geocoderRight=t.geocoderTop=t.geocoderWidth=t.sliderMarginBottom=t.sliderMarginTop=t.sliderMarginTopIsTime=t.sliderInputPadding=t.sliderInputFontSize=t.sliderInputWidth=t.sliderInputHeight=t.sliderHandleShadow=t.sliderHandleAfterContent=t.sliderHandleHoverColor=t.sliderBorderRadius=t.sliderInactiveBorderColor=t.sliderHandleTextColor=t.sliderHandleColor=t.sliderHandleWidth=t.sliderHandleHeight=t.sliderBarHeight=t.sliderBarRadius=t.sliderBarHoverColor=t.sliderBarBgd=t.sliderBarColor=t.modalDialogColor=t.modalDialogBgd=t.modalDropdownBackground=t.modalButtonZ=t.modalTitleZ=t.modalFooterZ=t.modalContentZ=t.modalOverlayBgd=t.modalOverLayZ=t.modalPortableLateralPadding=t.modalLateralPadding=t.modalPadding=t.modalImagePlaceHolder=t.modalFooterBgd=t.modalTitleFontSizeSmaller=t.modalTitleFontSize=t.modalTitleColor=t.bottomWidgetBgd=t.bottomWidgetPaddingLeft=t.bottomWidgetPaddingBottom=t.bottomWidgetPaddingRight=t.bottomWidgetPaddingTop=t.bottomPanelGapPalm=t.bottomPanelGap=t.bottomInnerPdVert=t.bottomInnerPdSide=t.sidepanelDividerHeight=t.sidepanelDividerMargin=t.sidepanelDividerBorder=t.layerPanelToggleOptionColorActive=t.layerPanelToggleOptionColor=t.layerTypeIconSizeSM=t.layerTypeIconPdL=t.layerTypeIconSizeL=t.tooltipFontSize=t.tooltipBoxShadow=t.tooltipColorLT=t.tooltipColor=t.tooltipBgLT=t.tooltipBg=t.mapPanelHeaderBackgroundColor=t.mapPanelBackgroundColor=t.panelBorderLT=t.panelBorder=t.panelBorderColor=t.panelToggleBottomPadding=t.panelToggleMarginRight=t.panelBackgroundLT=t.panelBorderRadius=t.panelBoxShadow=t.layerPanelHeaderHeight=void 0,t.themeBS=t.themeLT=t.theme=t.modalScrollBar=t.rightPanelMarginRight=t.rightPanelMarginTop=t.effectPanelElementColorSun=t.effectPanelElementColorSelected=t.effectPanelElementColorHovered=t.effectPanelElementColorActive=t.effectPanelElementColor=t.effectPanelTextSecondary3=t.effectPanelTextSecondary2=t.effectPanelTextSecondary1=t.effectPanelTextMain=t.effectTypeIconBgHoverColor=t.effectTypeIconSizeL=t.effectTypeIconMarginSide=t.effectPanelAddEffectFontFamily=t.effectPanelPaddingTop=t.effectPanelPaddingSide=t.effectPanelHeight=t.effectPanelWidth=t.effectConfiguratorPadding=t.effectConfiguratorMargin=t.breakPoints=t.layerConfiguratorPadding=t.layerConfiguratorMargin=t.layerConfiguratorBorderColor=t.layerConfiguratorBorder=t.styledConfigGroupHeaderBorder=t.layerConfigGroupLabelLabelFontSize=t.layerConfigGroupLabelLabelMargin=t.layerConfigGroupColor=t.layerConfigGroupLabelPadding=t.layerConfigGroupLabelMargin=t.layerConfigGroupLabelBorderLeft=t.textTruncate=void 0;var o,a,i,l,c,d,u,f,s,g,p,b,h,E,m,_,C,A,B,F,y,T,D,v,L,O,P,I,S,x,w,M,R,k,H=r(n(3)),N=r(n(7)),U=n(8),G=n(22);function V(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Y(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?V(Object(n),!0).forEach((function(t){(0,H.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):V(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}t.transition="all .4s ease";t.transitionFast="all .2s ease";t.transitionSlow="all .8s ease";var z="0 1px 2px 0 rgba(0,0,0,0.10)";t.boxShadow=z;t.boxSizing="border-box";t.borderRadius="1px";t.borderColor="#3A414C";t.borderColorLT="#F1F1F1";var j="ff-clan-web-pro, 'Helvetica Neue', Helvetica, sans-serif";t.fontFamily=j;t.fontWeight=400;t.fontSize="0.875em";t.lineHeight=1.71429;t.labelColor="#6A7485";t.labelHoverColor="#C6C6C6";t.labelColorLT="#6A7485";t.textColor="#A0A7B4";t.textColorLT="#3A414C";t.dataTableTextColor="#3A414C";t.titleColorLT="#29323C";t.subtextColor="#6A7485";t.subtextColorLT="#A0A7B4";t.subtextColorActive="#FFFFFF";t.panelToggleBorderColor="#FFFFFF";t.panelTabWidth="30px";t.titleTextColor="#FFFFFF";t.textColorHl="#F0F0F0";t.textColorHlLT="#000000";t.activeColor="#1FBAD6";t.activeColorLT="#2473BD";t.activeColorHover="#108188";t.errorColor="#F9042C";t.logoColor="#1FBAD6";var W=j;t.btnFontFamily=W;t.primaryBtnBgd="#0F9668";t.primaryBtnActBgd="#13B17B";t.primaryBtnColor="#FFFFFF";t.primaryBtnActColor="#FFFFFF";t.primaryBtnBgdHover="#13B17B";t.primaryBtnRadius="2px";t.primaryBtnFontSizeDefault="11px";t.primaryBtnFontSizeSmall="10px";t.primaryBtnFontSizeLarge="14px";t.primaryBtnBorder="0";t.secondaryBtnBgd="#6A7485";t.secondaryBtnActBgd="#A0A7B4";t.secondaryBtnColor="#FFFFFF";t.secondaryBtnActColor="#FFFFFF";t.secondaryBtnBgdHover="#A0A7B4";t.secondaryBtnBorder="0";t.ctaBtnBgd="#0F9668";t.ctaBtnBgdHover="#13B17B";t.ctaBtnActBgd="#13B17B";t.ctaBtnColor="#FFFFFF";t.ctaBtnActColor="#FFFFFF";t.linkBtnBgd="transparent";t.linkBtnActBgd="transparent";t.linkBtnColor="#A0A7B4";t.linkBtnActColor="#F1F1F1";t.linkBtnActBgdHover="transparent";t.linkBtnBorder="0";t.negativeBtnBgd="#F9042C";t.negativeBtnActBgd="#FF193E";t.negativeBtnBgdHover="#FF193E";t.negativeBtnBorder="0";t.negativeBtnColor="#FFFFFF";t.negativeBtnActColor="#FFFFFF";t.floatingBtnBgd="#29323C";t.floatingBtnActBgd="#3A4552";t.floatingBtnBgdHover="#3A4552";t.floatingBtnBorder="0";t.floatingBtnBorderHover="0";t.floatingBtnColor="#6A7485";t.floatingBtnActColor="#FFFFFF";t.selectionBtnBgd="transparent";t.selectionBtnActBgd="transparent";t.selectionBtnColor="#D3D8E0";t.selectionBtnActColor="#0F9668";t.selectionBtnBgdHover="#0F9668";t.selectionBtnBorder="1";t.selectionBtnBorderColor="#D3D8E0";t.selectionBtnBorderActColor="#0F9668";t.scrollbarThumbColorLT="#6A7485";t.scrollbarThumbColorHoverLT="#000000";t.inputBoxHeight="34px";t.inputBoxHeightSmall="24px";t.inputBoxHeightTiny="18px";t.inputPadding="4px 10px";t.inputPaddingSmall="4px 6px";t.inputPaddingTiny="2px 4px";t.inputFontSize="11px";t.inputFontSizeSmall="10px";t.inputFontWeight=500;t.inputBgd="#29323C";t.inputBgdHover="#3A414C";t.inputBgdActive="#3A414C";t.inputBgdActiveLT="#FFFFFF";t.inputBorderColor="#29323C";t.inputBorderHoverColor="#3A414C";t.inputBorderHoverColorLT="#6A7485";t.inputBorderActiveColor="#3A414C";t.inputBorderActiveColorLT="#3A414C";t.inputColor="#A0A7B4";t.inputBorderRadius="1px";t.inputPlaceholderColor="#6A7485";t.inputPlaceholderColorLT="#A0A7B4";t.inputPlaceholderFontWeight=400;t.inputBoxShadow="none";t.inputBoxShadowActive="none";t.inputBoxShadowActiveLT="none";t.secondaryInputBgd="#242730";t.secondaryInputBgdHover="#3A414C";t.secondaryInputBgdActive="#3A414C";t.secondaryInputColor="#A0A7B4";t.secondaryInputBorderColor="#242730";t.secondaryInputBorderActiveColor="#D3D8E0";t.dropdownSelectHeight=30;t.selectColor="#A0A7B4";t.selectColorLT="#29323C";t.selectActiveBorderColor="#D3D8E0";t.selectFontSize="11px";t.selectFontWeight="400";t.selectFontWeightBold="500";t.selectColorPlaceHolder="#6A7485";t.selectColorPlaceHolderLT="#29323C";t.selectBackground="#29323C";t.selectBackgroundHover="#3A414C";t.selectBackgroundLT="#FFFFFF";t.selectBackgroundHoverLT="#F8F8F9";t.selectBorderColor="#D3D8E0";t.selectBorderColorLT="#D3D8E0";t.selectBorderRadius="1px";t.selectBorder=0;t.panelTabColor="#6A7485";t.dropdownListHighlightBg="#6A7485";t.dropdownListHighlightBgLT="#F8F8F9";t.dropdownListShadow="0 6px 12px 0 rgba(0,0,0,0.16)";t.dropdownListBgd="#29323C";t.toolbarItemBgdHover="#3A4552";t.toolbarItemIconHover="#F0F0F0";t.toolbarItemBorderHover="transparent";t.toolbarItemBorderRaddius="0px";t.dropdownListBgdLT="#FFFFFF";t.dropdownListBorderTop="#242730";t.dropdownListBorderTopLT="#D3D8E0";t.dropdownListLineHeight=20;t.dropdownWrapperZ=100;t.dropdownWapperMargin=4;t.dndOverBackgroundColor="rgba(128, 128, 128, 0.2)";t.switchWidth=24;t.switchHeight=12;t.switchLabelMargin=12;t.switchTrackBgd="#29323C";t.switchTrackBgdActive="#1FBAD6";t.switchTrackBorderRadius="1px";t.switchBtnBgd="#6A7485";t.switchBtnBgdActive="#D3D8E0";t.switchBtnBoxShadow="0 2px 4px 0 rgba(0,0,0,0.40)";t.switchBtnBorderRadius="0";t.switchBtnWidth=12;t.switchBtnHeight=12;t.secondarySwitchTrackBgd="#242730";t.secondarySwitchBtnBgd="#3A414C";t.checkboxWidth=16;t.checkboxHeight=16;t.checkboxMargin=12;t.checkboxBorderColor="#D3D8E0";t.checkboxBorderRadius="2px";t.checkboxBorderColorLT="#D3D8E0";t.checkboxBoxBgd="white";t.checkboxBoxBgdChecked="#0F9668";t.radioRadius=8;t.radioBorderRadius=100;t.radioBorderColor="transparent";t.radioButtonRadius=4;t.radioButtonBgdColor="#D3D8E0";t.sidePanelHeaderBg="#29323C";t.sidePanelHeaderBorder="transparent";t.layerConfigGroupMarginBottom=12;t.layerConfigGroupPaddingLeft=18;t.sidePanelInnerPadding=16;t.sidePanelBorder=0;t.sidePanelBorderColor="transparent";t.sidePanelBg="#242730";t.sidePanelScrollBarWidth=10;t.sidePanelScrollBarHeight=10;t.sideBarCloseBtnBgd="#6A7485";t.sideBarCloseBtnColor="#29323C";t.sideBarCloseBtnBgdHover="#A0A7B4";t.sidePanelTitleFontsize="20px";t.sidePanelTitleLineHeight="1.71429";t.panelBackground="#29323C";t.panelContentBackground="#292E36";t.panelBackgroundHover="#3A4552";t.panelHeaderBorderRadius="0px";t.chickletBgd="#3A4552";t.chickletBgdLT="#D3D8E0";t.panelHeaderIcon="#6A7485";t.panelHeaderIconActive="#A0A7B4";t.panelHeaderIconHover="#F0F0F0";t.panelHeaderHeight=48;t.layerPanelHeaderHeight=48;t.panelBoxShadow="0 6px 12px 0 rgba(0,0,0,0.16)";t.panelBorderRadius="2px";t.panelBackgroundLT="#F8F8F9";t.panelToggleMarginRight=12;t.panelToggleBottomPadding=6;t.panelBorderColor="#3A414C";var q="1px solid ".concat("#3A414C");t.panelBorder=q;var X="1px solid ".concat("#F1F1F1");t.panelBorderLT=X;t.mapPanelBackgroundColor="#242730";t.mapPanelHeaderBackgroundColor="#29323C";t.tooltipBg="#3A414C";t.tooltipBgLT="#1869B5";t.tooltipColor="#F0F0F0";t.tooltipColorLT="#FFFFFF";t.tooltipBoxShadow="0 1px 2px 0 rgba(0,0,0,0.10)";t.tooltipFontSize="10px";t.layerTypeIconSizeL=50;t.layerTypeIconPdL=12;t.layerTypeIconSizeSM=28;t.layerPanelToggleOptionColor="#6A7485";t.layerPanelToggleOptionColorActive="#F0F0F0";t.sidepanelDividerBorder="1px";t.sidepanelDividerMargin=12;t.sidepanelDividerHeight=12;t.bottomInnerPdSide=32;t.bottomInnerPdVert=6;t.bottomPanelGap=20;t.bottomPanelGapPalm=20;t.bottomWidgetPaddingTop=20;t.bottomWidgetPaddingRight=20;t.bottomWidgetPaddingBottom=30;t.bottomWidgetPaddingLeft=20;t.bottomWidgetBgd="#29323C";t.modalTitleColor="#3A414C";t.modalTitleFontSize="24px";t.modalTitleFontSizeSmaller="18px";t.modalFooterBgd="#F8F8F9";t.modalImagePlaceHolder="#DDDFE3";t.modalPadding="10px 0";t.modalLateralPadding="72px";t.modalPortableLateralPadding="36px";t.modalOverLayZ=1001;t.modalOverlayBgd="rgba(0, 0, 0, 0.5)";t.modalContentZ=10002;t.modalFooterZ=10001;t.modalTitleZ=10003;t.modalButtonZ=10005;t.modalDropdownBackground="#FFFFFF";t.modalDialogBgd="#3A414C";t.modalDialogColor="#F0F0F0";t.sliderBarColor="#6A7485";t.sliderBarBgd="#3A414C";t.sliderBarHoverColor="#D3D8E0";t.sliderBarRadius="1px";t.sliderBarHeight=4;t.sliderHandleHeight=12;t.sliderHandleWidth=12;t.sliderHandleColor="#D3D8E0";t.sliderHandleTextColor="#D3D8E0";t.sliderInactiveBorderColor="#D3D8E0";t.sliderBorderRadius="0";t.sliderHandleHoverColor="#FFFFFF";t.sliderHandleAfterContent="";t.sliderHandleShadow="0 2px 4px 0 rgba(0,0,0,0.40)";t.sliderInputHeight=24;t.sliderInputWidth=56;t.sliderInputFontSize="10px";t.sliderInputPadding="4px 6px";t.sliderMarginTopIsTime=-12;t.sliderMarginTop=12;t.sliderMarginBottom=12;t.geocoderWidth=360;t.geocoderTop=20;t.geocoderRight=12;t.geocoderInputHeight=36;t.mapControlTop=52;t.rangeBrushBgd="#3A414C";t.histogramFillInRange="#1FBAD6";t.histogramFillOutRange="#6A7485";t.axisFontSize="10px";t.axisFontColor="#A0A7B4";t.timeTitleFontSize="10px";var K={top:12,bottom:0,left:0,right:0};t.rangePlotMargin=K;var Z={top:18,bottom:0,left:0,right:0};t.rangePlotMarginLarge=Z;t.rangePlotH=62;t.rangePlotContainerH=78;t.rangePlotHLarge=102;t.rangePlotHLargePalm=102;t.rangePlotContainerHLarge=120;t.rangePlotContainerHLargePalm=120;var Q={info:"#276ef1",error:"#f25138",success:"#47b275",warning:"#ffc043"};t.notificationColors=Q;t.notificationPanelWidth=240;t.notificationPanelItemWidth=180;t.notificationPanelItemHeight=60;t.actionPanelWidth=110;t.actionPanelHeight=32;t.fieldTokenRightMargin=4;t.fieldTokenHeight=20;t.fieldTokenWidth=40;var $={maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",wordWrap:"normal"};t.textTruncate=$;t.layerConfigGroupLabelBorderLeft="2px";t.layerConfigGroupLabelMargin="-12px";t.layerConfigGroupLabelPadding="10px";t.layerConfigGroupColor="transparent";t.layerConfigGroupLabelLabelMargin="0";t.layerConfigGroupLabelLabelFontSize="12px";t.styledConfigGroupHeaderBorder="2px";t.layerConfiguratorBorder="0";t.layerConfiguratorBorderColor="";t.layerConfiguratorMargin="12px";t.layerConfiguratorPadding="12px 0 8px 0";var J={palm:588,desk:768};t.breakPoints=J;t.effectConfiguratorMargin="18px 0 18px 0";t.effectConfiguratorPadding="0 0 0 18px";t.effectPanelWidth=345;t.effectPanelHeight=180;t.effectPanelPaddingSide=16;t.effectPanelPaddingTop=16;t.effectPanelAddEffectFontFamily="ff-clan-web-pro, 'Helvetica Neue', Helvetica, sans-serif";t.effectTypeIconMarginSide=6;t.effectTypeIconSizeL=56;t.effectTypeIconBgHoverColor="#262D40";t.effectPanelTextMain="#F7F7F7";t.effectPanelTextSecondary1="#A0A7B4";t.effectPanelTextSecondary2="#6A7485";t.effectPanelTextSecondary3="#5A6475";t.effectPanelElementColor="#29323C";t.effectPanelElementColorActive="#323843";t.effectPanelElementColorHovered="#3A414C";t.effectPanelElementColorSelected="#454e5d";t.effectPanelElementColorSun="#F7B26B";t.rightPanelMarginTop=12;t.rightPanelMarginRight=12;var ee=(0,U.css)(o||(o=(0,N.default)(["\n ::placeholder {\n color: ",";\n font-weight: ",";\n }\n\n /* Disable Arrows on Number Inputs */\n ::-webkit-inner-spin-button,\n ::-webkit-outer-spin-button {\n -webkit-appearance: none;\n margin: 0;\n }\n\n align-items: center;\n background-color: ",";\n border: 1px solid\n ",";\n border-radius: 2px;\n caret-color: ",";\n color: ",";\n display: flex;\n font-size: ",";\n font-weight: ",";\n font-family: ",";\n height: ",";\n justify-content: space-between;\n outline: none;\n overflow: hidden;\n padding: ",";\n text-overflow: ellipsis;\n transition: ",";\n white-space: nowrap;\n width: 100%;\n word-wrap: normal;\n pointer-events: ",";\n opacity: ",";\n box-shadow: ",";\n\n :hover {\n cursor: ",";\n background-color: ",";\n border-color: ",";\n }\n\n :active,\n :focus,\n &.focus,\n &.active {\n background-color: ",";\n border-color: ",";\n box-shadow: ",";\n }\n"])),(function(e){return e.theme.inputPlaceholderColor}),(function(e){return e.theme.inputPlaceholderFontWeight}),(function(e){return e.theme.inputBgd}),(function(e){return e.active?e.theme.inputBorderActiveColor:e.error?e.theme.errorColor:e.theme.inputBgd}),(function(e){return e.theme.inputBorderActiveColor}),(function(e){return e.theme.inputColor}),(function(e){return["small","tiny"].includes(e.size)?e.theme.inputFontSizeSmall:e.theme.inputFontSize}),(function(e){return e.theme.inputFontWeight}),(function(e){return e.theme.fontFamily}),(function(e){return"small"===e.size?e.theme.inputBoxHeightSmall:"tiny"===e.size?e.theme.inputBoxHeightTiny:e.theme.inputBoxHeight}),(function(e){return"small"===e.size?e.theme.inputPaddingSmall:"tiny"===e.size?e.theme.inputPaddingTiny:e.theme.inputPadding}),(function(e){return e.theme.transition}),(function(e){return e.disabled?"none":"all"}),(function(e){return e.disabled?.5:1}),(function(e){return e.theme.inputBoxShadow}),(function(e){return"number"===e.type||"text"===e.type?"text":"pointer"}),(function(e){return e.active?e.theme.inputBgdActive:e.theme.inputBgdHover}),(function(e){return e.active?e.theme.inputBorderActiveColor:e.theme.inputBorderHoverColor}),(function(e){return e.theme.inputBgdActive}),(function(e){return e.theme.inputBorderActiveColor}),(function(e){return e.theme.inputBoxShadowActive})),te=(0,U.css)(a||(a=(0,N.default)(["\n ::placeholder {\n color: ",";\n font-weight: 400;\n }\n ","\n\n background-color: ",";\n border: 1px solid\n ",";\n color: ",";\n caret-color: ",";\n\n :hover {\n background-color: ",";\n cursor: ",";\n border-color: ",";\n }\n\n :active,\n :focus,\n &.focus,\n &.active {\n background-color: ",";\n border-color: ",";\n box-shadow: ",";\n }\n"])),(function(e){return e.theme.inputPlaceholderColorLT}),ee,(function(e){return e.theme.selectBackgroundLT}),(function(e){return e.active?e.theme.selectActiveBorderColor:e.error?e.theme.errorColor:e.theme.selectBorderColorLT}),(function(e){return e.theme.selectColorLT}),(function(e){return e.theme.inputBorderActiveColorLT}),(function(e){return e.theme.inputBgdActiveLT}),(function(e){return["number","text"].includes(e.type)?"text":"pointer"}),(function(e){return e.active?e.theme.inputBorderActiveColorLT:e.theme.inputBorderHoverColorLT}),(function(e){return e.theme.inputBgdActiveLT}),(function(e){return e.theme.inputBorderActiveColorLT}),(function(e){return e.theme.inputBoxShadowActiveLT})),ne=(0,U.css)(i||(i=(0,N.default)(["\n ","\n color: ",";\n background-color: ",";\n border: 1px solid\n ",";\n\n :hover {\n cursor: pointer;\n background-color: ",";\n border-color: ",";\n }\n\n :active,\n &.active {\n background-color: ",";\n border-color: ",";\n }\n"])),(function(e){return e.theme.input}),(function(e){return e.theme.secondaryInputColor}),(function(e){return e.theme.secondaryInputBgd}),(function(e){return e.error?e.theme.errorColor:e.theme.secondaryInputBorderColor}),(function(e){return e.theme.secondaryInputBgdHover}),(function(e){return e.theme.secondaryInputBgdHover}),(function(e){return e.theme.secondaryInputBgdActive}),(function(e){return e.theme.secondaryInputBorderActiveColor})),re=(0,U.css)(l||(l=(0,N.default)(["\n cursor: pointer;\n flex-wrap: wrap;\n height: auto;\n justify-content: start;\n margin-bottom: 2px;\n padding: 0px 7px 0px 4px;\n white-space: normal;\n\n .chickleted-input__placeholder {\n line-height: 24px;\n margin: 4px;\n }\n"]))),oe=(0,U.css)(c||(c=(0,N.default)(["\n "," ",";\n"])),(function(e){return e.theme.input}),(function(e){return e.theme.chickletedInputContainer})),ae=(0,U.css)(d||(d=(0,N.default)(["\n "," ",";\n"])),(function(e){return e.theme.inputLT}),(function(e){return e.theme.chickletedInputContainer})),ie=(0,U.css)(u||(u=(0,N.default)(["\n "," ",";\n"])),(function(e){return e.theme.secondaryInput}),(function(e){return e.theme.chickletedInputContainer})),le=(0,U.css)(f||(f=(0,N.default)(["\n "," color: ",";\n font-size: 13px;\n letter-spacing: 0.43px;\n line-height: 18px;\n height: 24px;\n font-weight: 400;\n padding-left: 4px;\n margin-left: -4px;\n background-color: transparent;\n border: 1px solid transparent;\n\n :hover {\n height: 24px;\n cursor: text;\n background-color: transparent;\n border: 1px solid ",";\n }\n\n :active,\n .active,\n :focus {\n background-color: transparent;\n border: 1px solid ",";\n }\n"])),(function(e){return e.theme.input}),(function(e){return e.theme.textColor}),(function(e){return e.theme.labelColor}),(function(e){return e.theme.inputBorderActiveColor})),ce=(0,U.css)(s||(s=(0,N.default)(["\n background: ",";\n position: absolute;\n top: 0;\n left: ","px;\n content: '';\n display: block;\n width: ","px;\n height: ","px;\n border-radius: ",";\n"])),(function(e){return e.checked?e.theme.switchTrackBgdActive:e.theme.switchTrackBgd}),(function(e){return-e.theme.switchLabelMargin}),(function(e){return e.theme.switchWidth}),(function(e){return e.theme.switchHeight}),(function(e){return e.theme.switchTrackBorderRadius})),de=(0,U.css)(g||(g=(0,N.default)(["\n transition: ",";\n position: absolute;\n top: ","px;\n left: ","px;\n content: '';\n display: block;\n height: ","px;\n width: ","px;\n background: ",";\n box-shadow: ",";\n border-radius: ",";\n"])),(function(e){return e.theme.transition}),(function(e){return(e.theme.switchHeight-e.theme.switchBtnHeight)/2}),(function(e){return(e.checked?e.theme.switchWidth/2:(e.theme.switchHeight-e.theme.switchBtnHeight)/2)-e.theme.switchLabelMargin}),(function(e){return e.theme.switchBtnHeight}),(function(e){return e.theme.switchBtnWidth}),(function(e){return e.checked?e.theme.switchBtnBgdActive:e.theme.switchBtnBgd}),(function(e){return e.theme.switchBtnBoxShadow}),(function(e){return e.theme.switchBtnBorderRadius})),ue=(0,U.css)(p||(p=(0,N.default)(["\n user-select: none;\n cursor: pointer;\n line-height: ","px;\n font-weight: 500;\n font-size: 12px;\n color: ",";\n position: relative;\n display: inline-block;\n padding-top: 0;\n padding-right: 0;\n padding-bottom: 0;\n padding-left: ","px;\n\n :before {\n ",";\n }\n\n :after {\n ",";\n }\n"])),(function(e){return e.theme.switchHeight}),(function(e){return e.theme.labelColor}),(function(e){return e.theme.switchWidth}),(function(e){return e.theme.switchTrack}),(function(e){return e.theme.switchButton})),fe=(0,U.css)(b||(b=(0,N.default)(["\n display: block;\n position: absolute;\n top: 0;\n left: 0;\n width: ","px;\n height: ","px;\n background: ",";\n border: 1px solid\n ",";\n border-radius: 2px;\n content: '';\n"])),(function(e){return e.theme.checkboxWidth}),(function(e){return e.theme.checkboxHeight}),(function(e){return e.checked?e.theme.checkboxBoxBgdChecked:e.theme.checkboxBoxBgd}),(function(e){return e.checked?e.theme.checkboxBoxBgdChecked:e.theme.checkboxBorderColor})),se=(0,U.css)(h||(h=(0,N.default)(["\n width: 10px;\n height: 5px;\n border-bottom: 2px solid white;\n border-left: 2px solid white;\n top: 4px;\n left: 3px;\n transform: rotate(-45deg);\n display: block;\n position: absolute;\n opacity: ",";\n content: '';\n"])),(function(e){return e.checked?1:0})),ge=(0,U.css)(E||(E=(0,N.default)(["\n display: inline-block;\n position: relative;\n padding-left: 32px;\n margin-bottom: 24px;\n line-height: 20px;\n vertical-align: middle;\n cursor: pointer;\n font-size: 12px;\n color: ",";\n margin-left: -","px;\n\n :before {\n ",";\n }\n\n :after {\n ",";\n }\n"])),(function(e){return e.theme.labelColor}),(function(e){return e.theme.switchLabelMargin}),(function(e){return e.theme.checkboxBox}),(function(e){return e.theme.checkboxCheck})),pe=(0,U.css)(m||(m=(0,N.default)(["\n ","\n width: ","px;\n height: ","px;\n border-radius: ","px;\n background-color: ",";\n border-color: ",";\n"])),(function(e){return e.theme.checkboxBox}),(function(e){return 2*e.theme.radioRadius}),(function(e){return 2*e.theme.radioRadius}),(function(e){return e.theme.radioBorderRadius}),(function(e){return e.theme.switchTrackBgd}),(function(e){return e.theme.radioBorderColor})),be=(0,U.css)(_||(_=(0,N.default)(["\n border: 0;\n display: table;\n top: ","px;\n left: ","px;\n width: ","px;\n height: ","px;\n border-radius: ","px;\n background-color: ",";\n"])),(function(e){return e.theme.radioRadius-e.theme.radioButtonRadius}),(function(e){return e.theme.radioRadius-e.theme.radioButtonRadius}),(function(e){return 2*e.theme.radioButtonRadius}),(function(e){return 2*e.theme.radioButtonRadius}),(function(e){return 2*e.theme.radioButtonRadius}),(function(e){return e.theme.radioButtonBgdColor})),he=(0,U.css)(C||(C=(0,N.default)(["\n ","\n padding-left: ","px;\n margin-bottom: 0;\n margin-left: 0;\n line-height: ","px;\n color: ",";\n cursor: pointer;\n\n :before {\n ","\n }\n\n :after {\n ","\n }\n"])),(function(e){return e.theme.inputCheckbox}),(function(e){return 2*e.theme.radioRadius+8}),(function(e){return 2*e.theme.radioRadius}),(function(e){return e.theme.textColorHl}),(function(e){return e.theme.radioTrack}),(function(e){return e.theme.radioButton})),Ee=(0,U.css)(A||(A=(0,N.default)(["\n ","\n\n :before {\n "," background: ",";\n }\n\n :after {\n ","\n background: ",";\n }\n"])),(function(e){return e.theme.inputRadio}),(function(e){return e.theme.radioTrack}),(function(e){return e.theme.secondarySwitchTrackBgd}),(function(e){return e.theme.radioButton}),(function(e){return e.checked?e.theme.switchBtnBgdActive:e.theme.secondarySwitchBtnBgd})),me=(0,U.css)(B||(B=(0,N.default)(["\n ","\n\n :before {\n "," background: ",";\n }\n\n :after {\n ","\n background: ",";\n }\n"])),(function(e){return e.theme.inputSwitch}),(function(e){return e.theme.switchTrack}),(function(e){return e.checked?e.theme.switchTrackBgdActive:e.theme.secondarySwitchTrackBgd}),(function(e){return e.theme.switchButton}),(function(e){return e.checked?e.theme.switchBtnBgdActive:e.theme.secondarySwitchBtnBgd})),_e=(0,U.css)(F||(F=(0,N.default)(["\n ::-webkit-scrollbar {\n height: 10px;\n width: 10px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n }\n\n :vertical:hover {\n background: ",";\n cursor: pointer;\n }\n"])),(function(e){return e.theme.dropdownListBgd}),(function(e){return e.theme.dropdownListBgd}),(function(e){return e.theme.labelColor}),(function(e){return e.theme.dropdownListBgd}),(function(e){return e.theme.textColorHl})),Ce=(0,U.css)(y||(y=(0,N.default)(["\n "," ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n }\n\n :vertical:hover {\n background: ",";\n cursor: pointer;\n }\n"])),_e,(function(e){return e.theme.dropdownListBgdLT}),(function(e){return e.theme.dropdownListBgdLT}),(function(e){return e.theme.scrollbarThumbColorLT}),(function(e){return e.theme.dropdownListBgdLT}),(function(e){return e.theme.scrollbarThumbColorHoverLT})),Ae=(0,U.css)(T||(T=(0,N.default)(["\n color: ",";\n padding-left: 3px;\n font-size: ",";\n line-height: ","px;\n overflow: hidden;\n text-overflow: ellipsis;\n\n &.disabled {\n color: ",";\n }\n"])),(function(e){return e.theme.selectColor}),(function(e){return e.theme.selectFontSize}),(function(e){return e.theme.dropdownListLineHeight}),(function(e){return e.theme.subtextColor})),Be=(0,U.css)(D||(D=(0,N.default)(["\n ","\n color: ",";\n"])),Ae,(function(e){return e.theme.selectColorLT})),Fe=(0,U.css)(v||(v=(0,N.default)(["\n font-size: 11px;\n padding: 3px 9px;\n font-weight: 500;\n white-space: nowrap;\n"]))),ye=(0,U.css)(L||(L=(0,N.default)(["\n "," &.hover,\n &:hover {\n cursor: pointer;\n background-color: ",";\n\n .list__item__anchor {\n color: ",";\n }\n }\n"])),Fe,(function(e){return e.theme.dropdownListHighlightBg}),(function(e){return e.theme.textColorHl})),Te=(0,U.css)(O||(O=(0,N.default)(["\n ","\n color: ",";\n\n &.hover,\n &:hover {\n cursor: pointer;\n color: ",";\n background-color: ",";\n\n .list__item__anchor {\n color: ",";\n }\n }\n &.selected {\n background-color: ",";\n }\n"])),Fe,(function(e){return e.theme.textColorLT}),(function(e){return e.theme.textColorHlLT}),(function(e){return e.theme.dropdownListHighlightBgLT}),(function(e){return e.theme.selectColorLT}),(function(e){return e.theme.dropdownListHighlightBgLT})),De=(0,U.css)(P||(P=(0,N.default)(["\n font-size: 11px;\n padding: 5px 9px;\n color: ",";\n"])),(function(e){return e.theme.labelColor})),ve=(0,U.css)(I||(I=(0,N.default)(["\n padding: 0 0 4px 0;\n margin-bottom: 4px;\n border-bottom: 1px solid ",";\n"])),(function(e){return e.theme.labelColor})),Le=(0,U.css)(S||(S=(0,N.default)(["\n overflow-y: auto;\n max-height: 280px;\n box-shadow: ",";\n border-radius: 2px;\n\n .list__section {\n ",";\n }\n .list__header {\n ",";\n }\n\n .list__item {\n ",";\n }\n\n .list__item__anchor {\n ",";\n }\n\n ",";\n"])),(function(e){return e.theme.dropdownListShadow}),(function(e){return e.theme.dropdownListSection}),(function(e){return e.theme.dropdownListHeader}),(function(e){return e.theme.dropdownListItem}),(function(e){return e.theme.dropdownListAnchor}),(function(e){return e.theme.dropdownScrollBar})),Oe=(0,U.css)(x||(x=(0,N.default)(["\n "," .list__item {\n ",";\n }\n\n .list__item__anchor {\n ",";\n }\n\n ",";\n"])),Le,(function(e){return e.theme.dropdownListItemLT}),(function(e){return e.theme.dropdownListAnchorLT}),(function(e){return e.theme.dropdownScrollBarLT})),Pe=(0,U.css)(w||(w=(0,N.default)(["\n ::-webkit-scrollbar {\n height: ","px;\n width: ","px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n\n :hover {\n background: ",";\n cursor: pointer;\n }\n }\n"])),(function(e){return e.theme.sidePanelScrollBarHeight}),(function(e){return e.theme.sidePanelScrollBarWidth}),(function(e){return e.theme.sidePanelBg}),(function(e){return e.theme.sidePanelBg}),(function(e){return e.theme.panelBackgroundHover}),(function(e){return e.theme.sidePanelBg}),(function(e){return e.theme.labelColor})),Ie=(0,U.css)(M||(M=(0,N.default)(["\n ::-webkit-scrollbar {\n height: 10px;\n width: 10px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n :hover {\n background: ",";\n cursor: pointer;\n }\n }\n"])),(function(e){return e.theme.panelBackground}),(function(e){return e.theme.panelBackground}),(function(e){return e.theme.panelBackgroundHover}),(function(e){return e.theme.panelBackground}),(function(e){return e.theme.labelColor})),Se=(0,U.css)(R||(R=(0,N.default)(["\n ::-webkit-scrollbar {\n height: 10px;\n width: 10px;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-track {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb {\n border-radius: 10px;\n background: ",";\n border: 3px solid ",";\n\n :vertical:hover {\n background: ",";\n cursor: pointer;\n }\n\n :horizontal:hover {\n background: ",";\n cursor: pointer;\n }\n }\n"])),(function(e){return e.theme.panelBackground}),(function(e){return e.theme.panelBackground}),(function(e){return e.theme.labelColor}),(function(e){return e.theme.panelBackground}),(function(e){return e.theme.textColorHl}),(function(e){return e.theme.textColorHl})),xe=(0,U.css)(k||(k=(0,N.default)(["\n ::-webkit-scrollbar {\n width: 14px;\n height: 16px;\n }\n\n ::-webkit-scrollbar-track {\n background: white;\n }\n ::-webkit-scrollbar-track:horizontal {\n background: ",";\n }\n ::-webkit-scrollbar-thumb {\n background: ",";\n border: 4px solid white;\n }\n\n ::-webkit-scrollbar-corner {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb:hover {\n background: ",";\n }\n\n ::-webkit-scrollbar-thumb:vertical {\n border-radius: 7px;\n }\n\n ::-webkit-scrollbar-thumb:horizontal {\n border-radius: 9px;\n border: 4px solid ",";\n }\n"])),(function(e){return e.theme.textColorHl}),(function(e){return e.theme.scrollbarThumbColorLT}),(function(e){return e.theme.textColorHl}),(function(e){return e.theme.scrollbarThumbColorHoverLT}),(function(e){return e.theme.textColorHl}));t.modalScrollBar=xe;var we=Y(Y({},G.DIMENSIONS),{},{input:ee,inputLT:te,inlineInput:le,chickletedInput:oe,chickletedInputLT:ae,chickletedInputContainer:re,secondaryChickletedInput:ie,borderColor:"#3A414C",borderColorLT:"#F1F1F1",secondaryInput:ne,dropdownScrollBar:_e,dropdownScrollBarLT:Ce,dropdownList:Le,dropdownListLT:Oe,dropdownListItem:ye,dropdownListItemLT:Te,dropdownListAnchor:Ae,dropdownListAnchorLT:Be,dropdownListHeader:De,dropdownListSection:ve,dropdownListShadow:"0 6px 12px 0 rgba(0,0,0,0.16)",dropdownWrapperZ:100,dropdownWapperMargin:4,dndOverBackgroundColor:"rgba(128, 128, 128, 0.2)",modalScrollBar:xe,scrollBar:Se,sidePanelScrollBar:Pe,inputSwitch:ue,secondarySwitch:me,switchTrack:ce,switchButton:de,inputCheckbox:ge,inputRadio:he,checkboxBox:fe,checkboxCheck:se,transition:"all .4s ease",transitionFast:"all .2s ease",transitionSlow:"all .8s ease",activeColor:"#1FBAD6",activeColorHover:"#108188",borderRadius:"1px",boxShadow:z,errorColor:"#F9042C",dropdownListHighlightBg:"#6A7485",dropdownListHighlightBgLT:"#F8F8F9",dropdownListBgd:"#29323C",toolbarItemBgdHover:"#3A4552",toolbarItemBorderHover:"transparent",toolbarItemIconHover:"#F0F0F0",toolbarItemBorderRaddius:"0px",dropdownListBgdLT:"#FFFFFF",dropdownListBorderTop:"#242730",dropdownListBorderTopLT:"#D3D8E0",dropdownListLineHeight:20,labelColor:"#6A7485",labelColorLT:"#6A7485",labelHoverColor:"#C6C6C6",mapPanelBackgroundColor:"#242730",mapPanelHeaderBackgroundColor:"#29323C",selectActiveBorderColor:"#D3D8E0",selectBackground:"#29323C",selectBackgroundLT:"#FFFFFF",selectBackgroundHover:"#3A414C",selectBackgroundHoverLT:"#F8F8F9",selectBorder:0,selectBorderColor:"#D3D8E0",selectBorderRadius:"1px",selectBorderColorLT:"#D3D8E0",selectColor:"#A0A7B4",selectColorPlaceHolder:"#6A7485",selectColorPlaceHolderLT:"#29323C",selectFontSize:"11px",selectFontWeight:"400",selectColorLT:"#29323C",selectFontWeightBold:"500",panelTabColor:"#6A7485",inputBgd:"#29323C",inputBgdHover:"#3A414C",inputBgdActive:"#3A414C",inputBgdActiveLT:"#FFFFFF",inputBoxHeight:"34px",inputBoxHeightSmall:"24px",inputBoxHeightTiny:"18px",inputBorderColor:"#29323C",inputBorderActiveColor:"#3A414C",inputBorderHoverColor:"#3A414C",inputBorderRadius:"1px",inputColor:"#A0A7B4",inputPadding:"4px 10px",inputPaddingSmall:"4px 6px",inputPaddingTiny:"2px 4px",inputFontSize:"11px",inputFontSizeSmall:"10px",inputFontWeight:500,inputPlaceholderColor:"#6A7485",inputPlaceholderColorLT:"#A0A7B4",inputPlaceholderFontWeight:400,inputBoxShadow:"none",inputBoxShadowActive:"none",inputBoxShadowActiveLT:"none",secondaryInputBgd:"#242730",secondaryInputBgdHover:"#3A414C",secondaryInputBgdActive:"#3A414C",secondaryInputColor:"#A0A7B4",secondaryInputBorderColor:"#242730",secondaryInputBorderActiveColor:"#D3D8E0",dropdownSelectHeight:30,switchWidth:24,switchHeight:12,switchTrackBgd:"#29323C",switchTrackBgdActive:"#1FBAD6",switchTrackBorderRadius:"1px",switchBtnBgd:"#6A7485",switchBtnBgdActive:"#D3D8E0",switchBtnBoxShadow:"0 2px 4px 0 rgba(0,0,0,0.40)",switchBtnBorderRadius:"0",switchBtnWidth:12,switchBtnHeight:12,switchLabelMargin:12,secondarySwitchTrackBgd:"#242730",secondarySwitchBtnBgd:"#3A414C",checkboxWidth:16,checkboxHeight:16,checkboxMargin:12,checkboxBorderColor:"#D3D8E0",checkboxBorderRadius:"2px",checkboxBorderColorLT:"#D3D8E0",checkboxBoxBgd:"white",checkboxBoxBgdChecked:"#0F9668",radioRadius:8,radioBorderRadius:100,radioBorderColor:"transparent",radioButtonRadius:4,radioButtonBgdColor:"#D3D8E0",radioTrack:pe,radioButton:be,secondaryRadio:Ee,btnFontFamily:W,primaryBtnBgd:"#0F9668",primaryBtnActBgd:"#13B17B",primaryBtnColor:"#FFFFFF",primaryBtnActColor:"#FFFFFF",primaryBtnBgdHover:"#13B17B",primaryBtnRadius:"2px",primaryBtnFontSizeDefault:"11px",primaryBtnFontSizeSmall:"10px",primaryBtnFontSizeLarge:"14px",primaryBtnBorder:"0",secondaryBtnBgd:"#6A7485",secondaryBtnActBgd:"#A0A7B4",secondaryBtnBgdHover:"#A0A7B4",secondaryBtnColor:"#FFFFFF",secondaryBtnActColor:"#FFFFFF",secondaryBtnBorder:"0",negativeBtnBgd:"#F9042C",negativeBtnActBgd:"#FF193E",negativeBtnBgdHover:"#FF193E",negativeBtnBorder:"0",negativeBtnColor:"#FFFFFF",negativeBtnActColor:"#FFFFFF",linkBtnBgd:"transparent",linkBtnActBgd:"transparent",linkBtnColor:"#A0A7B4",linkBtnActColor:"#F1F1F1",linkBtnActBgdHover:"transparent",linkBtnBorder:"0",floatingBtnBgd:"#29323C",floatingBtnActBgd:"#3A4552",floatingBtnBgdHover:"#3A4552",floatingBtnBorder:"0",floatingBtnBorderHover:"0",floatingBtnColor:"#6A7485",floatingBtnActColor:"#FFFFFF",ctaBtnBgd:"#0F9668",ctaBtnBgdHover:"#13B17B",ctaBtnActBgd:"#13B17B",ctaBtnColor:"#FFFFFF",ctaBtnActColor:"#FFFFFF",selectionBtnBgd:"transparent",selectionBtnActBgd:"transparent",selectionBtnColor:"#D3D8E0",selectionBtnActColor:"#0F9668",selectionBtnBgdHover:"#0F9668",selectionBtnBorder:"1",selectionBtnBorderColor:"#D3D8E0",selectionBtnBorderActColor:"#0F9668",scrollbarThumbColorLT:"#6A7485",scrollbarThumbColorHoverLT:"#000000",modalTitleColor:"#3A414C",modalTitleFontSize:"24px",modalTitleFontSizeSmaller:"18px",modalFooterBgd:"#F8F8F9",modalImagePlaceHolder:"#DDDFE3",modalPadding:"10px 0",modalDialogBgd:"#3A414C",modalDialogColor:"#F0F0F0",modalLateralPadding:"72px",modalPortableLateralPadding:"36px",modalOverLayZ:1001,modalOverlayBgd:"rgba(0, 0, 0, 0.5)",modalContentZ:10002,modalFooterZ:10001,modalTitleZ:10003,modalButtonZ:10005,modalDropdownBackground:"#FFFFFF",sidePanelBg:"#242730",sidePanelInnerPadding:16,sideBarCloseBtnBgd:"#6A7485",sideBarCloseBtnColor:"#29323C",sideBarCloseBtnBgdHover:"#A0A7B4",sidePanelHeaderBg:"#29323C",sidePanelHeaderBorder:"transparent",sidePanelScrollBarWidth:10,sidePanelScrollBarHeight:10,sidePanelTitleFontsize:"20px",sidePanelTitleLineHeight:"1.71429",panelHeaderBorderRadius:"0px",sidePanelBorder:0,sidePanelBorderColor:"transparent",layerConfigGroupLabelLabelFontSize:"12px",layerConfigGroupMarginBottom:12,layerConfigGroupPaddingLeft:18,chickletBgd:"#3A4552",chickletBgdLT:"#D3D8E0",panelBackground:"#29323C",panelContentBackground:"#292E36",panelBackgroundHover:"#3A4552",panelBackgroundLT:"#F8F8F9",panelToggleMarginRight:12,panelToggleBottomPadding:6,panelBoxShadow:"0 6px 12px 0 rgba(0,0,0,0.16)",panelBorderRadius:"2px",panelBorder:q,panelBorderColor:"#3A414C",panelBorderLT:X,panelHeaderIcon:"#6A7485",panelHeaderIconActive:"#A0A7B4",panelHeaderIconHover:"#F0F0F0",panelHeaderHeight:48,layerPanelHeaderHeight:48,panelDropdownScrollBar:Ie,layerTypeIconSizeL:50,layerTypeIconPdL:12,layerTypeIconSizeSM:28,layerPanelToggleOptionColor:"#6A7485",layerPanelToggleOptionColorActive:"#F0F0F0",fontFamily:j,fontWeight:400,fontSize:"0.875em",lineHeight:1.71429,textColor:"#A0A7B4",textColorLT:"#3A414C",dataTableTextColor:"#3A414C",textColorHl:"#F0F0F0",titleTextColor:"#FFFFFF",subtextColor:"#6A7485",subtextColorLT:"#A0A7B4",subtextColorActive:"#FFFFFF",panelToggleBorderColor:"#FFFFFF",panelTabWidth:"30px",textTruncate:$,titleColorLT:"#29323C",tooltipBg:"#3A414C",tooltipBgLT:"#1869B5",tooltipColor:"#F0F0F0",tooltipColorLT:"#FFFFFF",tooltipBoxShadow:"0 1px 2px 0 rgba(0,0,0,0.10)",tooltipFontSize:"10px",logoColor:"#1FBAD6",sidepanelDividerBorder:"1px",sidepanelDividerMargin:12,sidepanelDividerHeight:12,bottomInnerPdSide:32,bottomInnerPdVert:6,bottomPanelGap:20,bottomPanelGapPalm:20,bottomWidgetPaddingTop:20,bottomWidgetPaddingRight:20,bottomWidgetPaddingBottom:30,bottomWidgetPaddingLeft:20,bottomWidgetBgd:"#29323C",sliderBarColor:"#6A7485",sliderBarBgd:"#3A414C",sliderBarHoverColor:"#D3D8E0",sliderBarRadius:"1px",sliderBarHeight:4,sliderHandleHeight:12,sliderHandleWidth:12,sliderHandleColor:"#D3D8E0",sliderHandleTextColor:"#D3D8E0",sliderInactiveBorderColor:"#D3D8E0",sliderBorderRadius:"0",sliderHandleHoverColor:"#FFFFFF",sliderHandleAfterContent:"",sliderHandleShadow:"0 2px 4px 0 rgba(0,0,0,0.40)",sliderInputHeight:24,sliderInputWidth:56,sliderMarginTopIsTime:-12,sliderMarginTop:12,sliderMarginBottom:12,geocoderWidth:360,geocoderTop:20,geocoderRight:12,geocoderInputHeight:36,mapControlTop:52,rangeBrushBgd:"#3A414C",histogramFillInRange:"#1FBAD6",histogramFillOutRange:"#6A7485",axisFontSize:"10px",axisFontColor:"#A0A7B4",timeTitleFontSize:"10px",rangePlotMargin:K,rangePlotMarginLarge:Z,rangePlotH:62,rangePlotHLarge:102,rangePlotHLargePalm:102,rangePlotContainerH:78,rangePlotContainerHLarge:120,rangePlotContainerHLargePalm:120,notificationColors:Q,notificationPanelWidth:240,notificationPanelItemWidth:180,notificationPanelItemHeight:60,headerRowHeight:70,headerRowWStatsHeight:364,headerStatsControlHeight:32,rowHeight:32,headerPaddingTop:6,headerPaddingBottom:8,cellPaddingSide:10,edgeCellPaddingSide:10,cellFontSize:10,gridPaddingSide:24,optionButtonColor:"#6A7485",headerCellBackground:"#FFFFFF",headerCellBorderColor:"#E0E0E0",headerCellStatsBackground:"#F8FAFF",headerCellStatsControlBackground:"#EAF0FF",headerCellIconColor:"#666666",cellBorderColor:"#E0E0E0",evenRowBackground:"#FFFFFF",oddRowBackground:"#F7F7F7",pinnedGridBorderColor:"#E0E0E0",timeDisplayBorderRadius:32,timeDisplayHeight:64,timeDisplayMinWidth:176,timeDisplayOpacity:.8,timeDisplayPadding:"0 24px",exportIntraSectionMargin:"8",actionPanelWidth:110,actionPanelHeight:32,breakPoints:J,progressBarColor:"#0F9668",progressBarTrackColor:"#E8E8E8",layerConfigGroupLabelBorderLeft:"2px",layerConfigGroupLabelMargin:"-12px",layerConfigGroupLabelPadding:"10px",layerConfigGroupColor:"transparent",layerConfigGroupLabelLabelMargin:"0",styledConfigGroupHeaderBorder:"2px",layerConfiguratorBorder:"0",layerConfiguratorBorderColor:"",layerConfiguratorMargin:"12px",layerConfiguratorPadding:"12px 0 8px 0",fieldTokenRightMargin:4,fieldTokenHeight:20,fieldTokenWidth:40,effectPanelWidth:345,effectPanelHeight:180,effectPanelPaddingSide:16,effectPanelPaddingTop:16,rightPanelMarginTop:12,rightPanelMarginRight:12,effectPanelAddEffectFontFamily:"ff-clan-web-pro, 'Helvetica Neue', Helvetica, sans-serif",effectTypeIconMarginSide:6,effectTypeIconSizeL:56,effectTypeIconBgHoverColor:"#262D40",effectConfiguratorMargin:"18px 0 18px 0",effectConfiguratorPadding:"0 0 0 18px",effectPanelTextMain:"#F7F7F7",effectPanelTextSecondary1:"#A0A7B4",effectPanelTextSecondary2:"#6A7485",effectPanelTextSecondary3:"#5A6475",effectPanelElementColor:"#29323C",effectPanelElementColorActive:"#323843",effectPanelElementColorHovered:"#3A414C",effectPanelElementColorSun:"#F7B26B",effectPanelElementColorSelected:"#454e5d"});t.theme=we;var Me=Y(Y({},we),{},{activeColor:"#2473BD",input:te,textColor:"#3A414C",sidePanelBg:"#FFFFFF",selectColor:"#29323C",titleTextColor:"#000000",sidePanelHeaderBg:"#F7F7F7",subtextColorActive:"#2473BD",tooltipBg:"#1869B5",tooltipColor:"#FFFFFF",dropdownListBgd:"#FFFFFF",toolbarItemBgdHover:"#F7F7F7",textColorHl:"#2473BD",inputBgd:"#F7F7F7",inputBgdHover:"#FFFFFF",inputBgdActive:"#FFFFFF",inputBgdActiveLT:"#FFFFFF",dropdownListHighlightBg:"#F0F0F0",toolbarItemIconHover:"#2473BD",panelBackground:"#F7F7F7",panelContentBackground:"#F7F7F7",bottomWidgetBgd:"#F7F7F7",panelBackgroundHover:"#F7F7F7",panelBorderColor:"#D3D8E0",panelHeaderIconActive:"#000000",panelHeaderIconHover:"#000000",sideBarCloseBtnBgd:"#F7F7F7",sideBarCloseBtnColor:"#3A414C",sideBarCloseBtnBgdHover:"#F7F7F7",secondaryInputBgd:"#F7F7F7",secondaryInputBgdActive:"#F7F7F7",secondaryInputBgdHover:"#FFFFFF",secondaryInputBorderActiveColor:"#000000",secondaryInputBorderColor:"none",secondaryInputColor:"#545454",chickletBgd:"#F7F7F7",mapPanelBackgroundColor:"#FFFFFF",mapPanelHeaderBackgroundColor:"#F7F7F7",sliderBarColor:"#A0A7B4",sliderBarBgd:"#D3D8E0",sliderHandleColor:"#F7F7F7",sliderInactiveBorderColor:"#F7F7F7",sliderHandleTextColor:"#F7F7F7",sliderHandleHoverColor:"#F7F7F7",subtextColor:"#A0A7B4",switchBtnBgd:"#F7F7F7",secondarySwitchBtnBgd:"#F7F7F7",secondarySwitchTrackBgd:"#D3D8E0",switchBtnBgdActive:"#F7F7F7",switchTrackBgd:"#D3D8E0",switchTrackBgdActive:"#2473BD",primaryBtnBgd:"#13B17B",primaryBtnActBgd:"#0F9668",primaryBtnBgdHover:"#0F9668",secondaryBtnBgd:"#A0A7B4",secondaryBtnActBgd:"#6A7485",secondaryBtnBgdHover:"#6A7485",floatingBtnBgd:"#F7F7F7",floatingBtnActBgd:"#F7F7F7",floatingBtnBgdHover:"#F7F7F7",floatingBtnColor:"#6A7485",floatingBtnActColor:"#2473BD",linkBtnActColor:"#3A414C",rangeBrushBgd:"#D3D8E0",histogramFillInRange:"#2473BD",histogramFillOutRange:"#A0A7B4",axisFontColor:"#3A414C"});t.themeLT=Me;var Re=Y(Y({},we),{},{activeColor:"#E2E2E2",dropdownListBgd:"#FFFFFF",toolbarItemBgdHover:"#F7F7F7",dropdownListBorderTop:"none",dropdownListHighlightBg:"#F6F6F6",toolbarItemIconHover:"#000000",inputBgd:"#E2E2E2",inputBgdActive:"#E2E2E2",inputBgdHover:"inherit",inputBorderActiveColor:"#000000",inputColor:"#000000",chickletBgd:"#E2E2E2",panelBackground:"#FFFFFF",panelBackgroundHover:"#EEEEEE",panelContentBackground:"#FFFFFF",bottomWidgetBgd:"#F7F7F7",panelHeaderIconActive:"#000000",panelHeaderIconHover:"#000000",panelBorderColor:"#E2E2E2",primaryBtnBgd:"#E2E2E2",primaryBtnBgdHover:"#333333",primaryBtnColor:"#000000",secondaryBtnActBgd:"#EEEEEE",secondaryBtnActColor:"#000000",secondaryBtnBgd:"#E2E2E2",secondaryBtnBgdHover:"#CBCBCB",ctnBtnBgd:"#E2E2E2",ctnBtnBgdHover:"333333",ctnBtnColor:"#000000",ctnBtnActColor:"#000000",sideBarCloseBtnBgd:"#E2E2E2",sideBarCloseBtnColor:"#000000",sideBarCloseBtnBgdHover:"#FFFFFF",floatingBtnBgd:"#FFFFFF",floatingBtnActBgd:"#EEEEEE",floatingBtnBgdHover:"#EEEEEE",floatingBtnColor:"#757575",floatingBtnActColor:"#000000",secondaryBtnColor:"#000000",secondaryInputBgd:"#F6F6F6",secondaryInputBgdActive:"#F6F6F6",secondaryInputBgdHover:"#F6F6F6",secondaryInputBorderActiveColor:"#000000",secondaryInputBorderColor:"none",secondaryInputColor:"#545454",sidePanelBg:"#F6F6F6",sidePanelHeaderBg:"#FFFFFF",subtextColor:"#AFAFAF",panelTabColor:"#AFAFAF",subtextColorActive:"#000000",textColor:"#000000",textColorHl:"#545454",mapPanelBackgroundColor:"#F6F6F6",mapPanelHeaderBackgroundColor:"#FFFFFF",titleTextColor:"#000000",switchBtnBgdActive:"#000000",switchBtnBgd:"#FFFFFF",switchTrackBgdActive:"#E2E2E2",secondarySwitchTrackBgd:"#E2E2E2",switchTrackBgd:"#E2E2E2",secondarySwitchBtnBgd:"#FFFFFF",histogramFillInRange:"#000000",histogramFillOutRange:"#E2E2E2",rangeBrushBgd:"#E2E2E2",sliderBarBgd:"#E2E2E2",sliderHandleColor:"#FFFFFF",sliderInactiveBorderColor:"#FFFFFF",sliderHandleTextColor:"#FFFFFF",sliderBarColor:"#000000"});t.themeBS=Re},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0});var o={KeyEvent:!0};Object.defineProperty(t,"KeyEvent",{enumerable:!0,get:function(){return u.default}});var a=n(23);Object.keys(a).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===a[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return a[e]}}))}));var i=n(11);Object.keys(i).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===i[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return i[e]}}))}));var l=n(13);Object.keys(l).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===l[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return l[e]}}))}));var c=n(14);Object.keys(c).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===c[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return c[e]}}))}));var d=n(31);Object.keys(d).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===d[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return d[e]}}))}));var u=r(n(32)),f=n(16);Object.keys(f).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===f[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return f[e]}}))}));var s=n(35);Object.keys(s).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===s[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return s[e]}}))}));var g=n(36);Object.keys(g).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===g[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return g[e]}}))}));var p=n(37);Object.keys(p).forEach((function(e){"default"!==e&&"__esModule"!==e&&(Object.prototype.hasOwnProperty.call(o,e)||e in t&&t[e]===p[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return p[e]}}))}))},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),t.Themes=t.ColorsByTheme=t.default=void 0;var o=r(n(3)),a=r(n(4));function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){(0,o.default)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var c={grey_7:"#898989",brick_20:"#B77B6A",brick_21:"#8B574F",brick_22:"#392421",lime_8:"#7DC240",lime_9:"#76B73D",lime_4:"#CFEDB5",lime_5:"#B6E490",lime_6:"#9EDB6B",lime_7:"#8ECF56",lime_1:"#F3FBED",lime_2:"#EBF8E1",lime_3:"#E3F5D4",orange_22:"#32221D",orange_20:"#DDA37C",orange_21:"#A2705B",stone_9:"#716852",stone_8:"#776E57",stone_20:"#4D4A44",stone_1:"#F3F2EF",amber_22:"#32251D",stone_21:"#282623",amber_20:"#DDB27C",amber_21:"#A2785B",navy_17:"#CAD1E6",navy_16:"#18264D",navy_15:"#132559",navy_14:"#162A65",navy_13:"#1A3177",navy_12:"#1E3788",navy_11:"#223F9A",navy_10:"#2647AC",navy_19:"#7989B7",navy_18:"#9CAAD3",teal_9:"#1C8EB4",teal_8:"#1E96BE",teal_5:"#79C7E3",teal_4:"#A6DAEC",teal_7:"#35A6CC",teal_6:"#4DB5D9",teal_1:"#E9F6FA",teal_3:"#CBE9F4",teal_2:"#DAF0F7",teal_19:"#73A6B7",teal_18:"#96C3D2",teal_11:"#17779A",teal_10:"#1A85AB",teal_13:"#125C77",teal_12:"#146988",teal_15:"#0D4559",teal_14:"#0F4E65",teal_17:"#C7DDE5",teal_16:"#103B49",gold_20:"#DDBE7C",gold_21:"#A27E5B",gold_22:"#32271D",olive_9:"#B8C436",olive_8:"#C3D039",olive_7:"#CFDC4F",olive_6:"#DBE765",olive_5:"#E4ED8B",olive_4:"#EDF3B2",olive_3:"#F5F8D2",olive_2:"#F8FADF",olive_1:"#FBFCEC",green_22:"#212A1F",green_20:"#5A735A",green_21:"#2F3C2F",indigo_17:"#CCC7E4",indigo_16:"#1B1247",indigo_15:"#1C0F58",indigo_14:"#201163",indigo_13:"#261474",indigo_12:"#2C1685",indigo_11:"#321A97",indigo_10:"#371DA8",indigo_19:"#7E71B2",indigo_18:"#A095CF",blue_22:"#222A34",blue_20:"#536A81",blue_21:"#2D3946",olive_22:"#28291C",olive_20:"#878A5E",olive_21:"#484A32",violet_16:"#510E30",violet_17:"#E0C1D8",violet_14:"#6B083F",violet_15:"#620736",violet_12:"#860A5A",violet_13:"#79094D",violet_10:"#A40D77",violet_11:"#950C69",dirt_16:"#261A10",dirt_17:"#BCB6B1",dirt_14:"#322113",dirt_15:"#2D1D10",dirt_12:"#442D19",dirt_13:"#3B2716",violet_18:"#C78BB8",violet_19:"#B1699C",stone_15:"#373227",stone_14:"#3E392D",stone_17:"#C6C4C0",stone_16:"#2E2A22",stone_11:"#5F5845",stone_10:"#6A624D",stone_13:"#494335",stone_12:"#544D3D",stone_19:"#706C63",stone_18:"#938F87",aqua_3:"#CAF2F4",aqua_2:"#D9F6F7",aqua_1:"#E8FAFA",aqua_7:"#2FC5CC",aqua_6:"#47D3D9",aqua_5:"#75DEE3",aqua_4:"#A3E9EC",aqua_9:"#15AEB4",aqua_8:"#17B8BE",orange_7:"#FE891A",orange_6:"#FF9833",orange_5:"#FFB266",orange_4:"#FFCB99",orange_3:"#FFE1C4",orange_2:"#FFEAD5",orange_1:"#FFF2E6",orange_9:"#FA7400",orange_8:"#FD7900",purple_13:"#510869",purple_11:"#670B8C",purple_10:"#720C9D",purple_7:"#9226BE",purple_6:"#A13ECD",purple_5:"#B86EDA",purple_4:"#D09FE6",purple_3:"#E4C7F1",purple_2:"#ECD7F5",purple_1:"#F3E7F9",blue_18:"#99B6D3",blue_17:"#C9D7E6",blue_16:"#16314D",blue_15:"#103459",blue_14:"#133B65",blue_13:"#164677",blue_12:"#195188",purple_9:"#7A0DA6",blue_10:"#2067AC",orange_13:"#D65200",orange_12:"#E45D00",orange_11:"#ED6600",orange_10:"#F26C00",orange_17:"#F8E2CC",orange_16:"#8C330A",orange_15:"#B93C00",orange_14:"#C84600",orange_19:"#F6BD8A",orange_18:"#F8CCA1",magenta_11:"#B51241",magenta_10:"#C5154A",magenta_13:"#970E2D",magenta_12:"#A51037",magenta_15:"#7E0A1D",magenta_14:"#880B23",magenta_17:"#EDCAD6",magenta_16:"#63101D",magenta_19:"#D2809A",magenta_18:"#E29DB4",stone_3:"#E2E0DA",stone_2:"#EBE9E4",stone_5:"#B3AD9E",stone_4:"#CDC9BF",stone_7:"#89806B",stone_6:"#9A927E",blue_9:"#226DB5",blue_8:"#2473BD",blue_7:"#3B85CC",blue_6:"#5297DA",blue_5:"#7DB1E3",blue_4:"#A9CBED",blue_3:"#CDE1F4",blue_2:"#DCEAF7",blue_1:"#EAF2FA",gold_9:"#FAC200",gold_8:"#FDC900",gold_5:"#FFE466",gold_4:"#FFEB8C",gold_7:"#FED21A",gold_6:"#FFDB33",gold_1:"#FFFBE6",gold_3:"#FFF5C4",gold_2:"#FFF8D5",dirt_22:"#191410",dirt_21:"#201B17",dirt_20:"#3D342C",white:"#FFFFFF",gold_19:"#F6E08A",gold_18:"#F8E8A1",grey_8:"#777777",grey_9:"#717171",gold_11:"#EDAB00",gold_10:"#F6BA00",gold_13:"#D68800",gold_12:"#E49B00",gold_15:"#B96500",gold_14:"#C87500",gold_17:"#F8F0CC",gold_16:"#8C500A",grey_10:"#6A6A6A",grey_11:"#5F5F5F",grey_12:"#545454",grey_13:"#494949",grey_14:"#3E3E3E",grey_15:"#373636",grey_16:"#2E2D2D",grey_17:"#C6C6C6",grey_18:"#939393",grey_19:"#707070",dirt_19:"#5B4D42",yellow_20:"#DDC97C",yellow_21:"#A2845B",yellow_22:"#32291D",dirt_10:"#573921",dirt_11:"#4E331D",brown_8:"#986232",brown_9:"#905D2F",stone_22:"#1C1A18",brown_6:"#B7885E",brown_7:"#A87548",brick_1:"#FEEEE8",brick_3:"#FCD6C8",brick_2:"#FDE2D8",brick_5:"#F89570",brick_4:"#FAB8A0",brick_7:"#EF5D28",brick_6:"#F57141",brick_9:"#DF4916",brick_8:"#E7531F",amber_7:"#FEB31A",amber_6:"#FFBE33",amber_5:"#FFCE66",amber_4:"#FFDF99",amber_3:"#FFECC4",amber_2:"#FFF2D5",amber_1:"#FFF7E6",amber_9:"#FAA100",amber_8:"#FDA700",grey_2:"#F1F1F1",grey_3:"#E5E5E4",violet_22:"#301C25",violet_21:"#51303F",violet_20:"#7F4B6D",grey_1:"#F8F8F9",red_19:"#D37676",red_18:"#E49595",red_15:"#880000",red_14:"#910000",red_17:"#EEC7C7",red_16:"#6D0A0A",red_11:"#BB0000",red_10:"#C90000",red_13:"#9F0000",red_12:"#AC0000",black:"#000000",grey_4:"#D6D6D5",grey_5:"#C0C0C0",navy_7:"#4265CC",navy_6:"#5879DA",navy_5:"#829AE3",navy_4:"#ABBCED",navy_3:"#CFD8F4",navy_2:"#DDE3F7",navy_1:"#EBEFFA",navy_9:"#294CB5",navy_8:"#2C51BE",yellow_15:"#B97600",yellow_14:"#C88900",yellow_17:"#F8F6CC",yellow_16:"#8C5C0A",yellow_11:"#EDC800",yellow_10:"#F6DA00",yellow_13:"#D6A000",yellow_12:"#E4B600",yellow_19:"#F6EF8A",yellow_18:"#F8F5A1",purple_20:"#664473",purple_21:"#352139",magenta_1:"#FCE9EF",magenta_3:"#F9CADA",magenta_2:"#FBDAE4",magenta_5:"#EF769E",magenta_4:"#F4A3BF",magenta_7:"#E1316A",magenta_6:"#E9487E",magenta_9:"#CF1750",magenta_8:"#D91955",indigo_3:"#D4CCF3",indigo_2:"#E1DBF6",indigo_1:"#EDE9FA",indigo_7:"#5438C8",indigo_6:"#694FD6",indigo_5:"#8F7BE0",indigo_4:"#B4A7EB",indigo_9:"#3B1EB1",indigo_8:"#482BBD",magenta_20:"#9E5F70",magenta_21:"#6D4046",magenta_22:"#2C1B1E",purple_22:"#231727",red_9:"#D20000",red_8:"#DA0000",red_5:"#F06D6D",red_4:"#F59999",red_7:"#E31A1A",red_6:"#EA4444",red_1:"#FDE6E6",red_3:"#F9C4C4",red_2:"#FBD5D5",grey_21:"#282727",grey_20:"#4D4D4D",grey_22:"#1C1B1B",lime_16:"#30471D",lime_17:"#D9E6CE",lime_14:"#406422",lime_15:"#39581E",lime_12:"#57882E",lime_13:"#4C7628",lime_10:"#6EAC3A",lime_11:"#639A34",lime_18:"#BAD4A4",lime_19:"#9EBB84",dirt_18:"#81746B",violet_8:"#B80F87",violet_9:"#AE0E7F",violet_4:"#E79FD5",violet_5:"#DA70BF",violet_6:"#CE40AA",violet_7:"#C32899",violet_1:"#F9E8F5",violet_2:"#F5D8EE",violet_3:"#F1C8E6",red_20:"#A55C5C",red_21:"#784343",red_22:"#361F1F",amber_19:"#F6D18A",amber_18:"#F8DCA1",amber_13:"#D67100",amber_12:"#E48000",amber_11:"#ED8D00",amber_10:"#F69A00",amber_17:"#F8EACC",amber_16:"#8C440A",amber_15:"#B95300",amber_14:"#C86100",green_17:"#CDDDCD",green_16:"#254325",green_15:"#274F28",green_14:"#2C5A2E",green_13:"#356A36",green_12:"#3D7A3E",green_11:"#458A46",green_10:"#4C9A4E",green_19:"#82A682",green_18:"#A2C2A2",turquoise_19:"#77AC9B",turquoise_18:"#99C7B9",turquoise_15:"#185240",turquoise_14:"#1B5D48",turquoise_17:"#C9E0D9",turquoise_16:"#1A4538",turquoise_11:"#2B8F70",turquoise_10:"#309F7D",turquoise_13:"#216E56",turquoise_12:"#267E63",aqua_22:"#1A2C2B",aqua_20:"#4F7E81",aqua_21:"#2B4447",yellow_9:"#FAE300",yellow_8:"#FDEC00",yellow_5:"#FFFA66",yellow_4:"#FFFB98",yellow_7:"#FEF21A",yellow_6:"#FFF833",yellow_1:"#FFFEE6",yellow_3:"#FFFDC4",yellow_2:"#FFFED5",teal_20:"#507481",teal_21:"#2C3F46",teal_22:"#152629",indigo_22:"#1A1724",purple_12:"#5C097A",indigo_20:"#59507E",indigo_21:"#312C45",purple_17:"#D5C1DF",purple_16:"#360B40",purple_15:"#3F054C",purple_14:"#460658",purple_19:"#9563A8",purple_18:"#B389C6",blue_19:"#7597B6",lime_22:"#1E241A",lime_21:"#3A4531",lime_20:"#6C815B",turquoise_1:"#ECF9F5",turquoise_3:"#D2F1E7",turquoise_2:"#DFF5EE",turquoise_5:"#89DAC1",turquoise_4:"#B1E7D6",turquoise_7:"#4DC19C",turquoise_6:"#62CEAD",turquoise_9:"#34A984",turquoise_8:"#37B38B",brown_4:"#DBC3AF",brown_5:"#C9A686",brown_2:"#F0E7DE",brown_3:"#EADDD0",brown_1:"#F6F0EB",blue_11:"#1C5C9A",brown_14:"#4F3319",purple_8:"#820DAF",brown_15:"#452D16",brown_16:"#3C2A18",brown_18:"#B09C8A",brick_19:"#E19D84",brick_18:"#EEB5A1",brick_15:"#9B1C04",brick_14:"#A42105",brick_17:"#F3D7CC",brick_16:"#7A1F0E",brick_11:"#CB380B",brick_10:"#D73F0D",brick_13:"#B12907",brick_12:"#BE3009",olive_13:"#777E23",olive_12:"#899128",olive_11:"#9BA52E",olive_10:"#ADB933",olive_17:"#E9ECD0",olive_16:"#494C1B",olive_15:"#595E1A",olive_14:"#656B1D",olive_19:"#C3C989",olive_18:"#DBE0A8",navy_22:"#232734",navy_20:"#555F81",navy_21:"#2E3446",brown_21:"#352D24",brown_20:"#645446",brown_22:"#29231C",dirt_4:"#C3B5A9",dirt_5:"#A68F7E",dirt_6:"#886A53",dirt_7:"#75553C",dirt_1:"#F0EDEA",dirt_2:"#E7E1DC",dirt_3:"#DDD4CD",dirt_8:"#624025",dirt_9:"#5D3D23",green_3:"#DAEFDA",green_2:"#E4F3E4",green_1:"#EFF8EF",green_7:"#6ABB6B",green_6:"#7DC97F",green_5:"#9ED79F",green_4:"#BEE4BF",green_9:"#52A353",green_8:"#57AD57",brown_10:"#88572C",brown_11:"#7A4E28",brown_12:"#6B4523",brown_13:"#5D3C1E",turquoise_20:"#52776C",turquoise_21:"#2C403A",turquoise_22:"#1E2C27",brown_17:"#D4CAC1",grey_6:"#A6A5A5",brown_19:"#917A66",aqua_19:"#70B4B7",aqua_18:"#94CFD2",aqua_13:"#0E7077",aqua_12:"#108188",aqua_11:"#12939A",aqua_10:"#13A4AB",aqua_17:"#C6E4E5",aqua_16:"#0F474A",aqua_15:"#0A545A",aqua_14:"#0B5F65"},d=c;t.default=d;var u=Object.keys(c).reduce((function(e,t){if(!t.includes("_"))return e;var n=t.split("_"),r=(0,a.default)(n,2),i=r[0],d=r[1];return l(l({},e),{},(0,o.default)({},i,l(l({},e[i]),{},(0,o.default)({},d,c[t]))))}),{});t.ColorsByTheme=u;t.Themes=["yellow","gold","amber","orange","brick","red","magenta","violet","purple","indigo","navy","blue","teal","aqua","turquoise","green","lime","olive","grey","stone","brown","dirt"]},function(e,t){e.exports=function(e){if(Array.isArray(e))return e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,o=!1,a=void 0;try{for(var i,l=e[Symbol.iterator]();!(r=(i=l.next()).done)&&(n.push(i.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==l.return||l.return()}finally{if(o)throw a}}return n}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(10);e.exports=function(e){if(Array.isArray(e))return r(e)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";n.r(t);t.default={schemeGroups:{sequential:["BuGn","BuPu","GnBu","OrRd","PuBu","PuBuGn","PuRd","RdPu","YlGn","YlGnBu","YlOrBr","YlOrRd"],singlehue:["Blues","Greens","Greys","Oranges","Purples","Reds"],diverging:["BrBG","PiYG","PRGn","PuOr","RdBu","RdGy","RdYlBu","RdYlGn","Spectral"],qualitative:["Accent","Dark2","Paired","Pastel1","Pastel2","Set1","Set2","Set3"]},YlGn:{3:["#f7fcb9","#addd8e","#31a354"],4:["#ffffcc","#c2e699","#78c679","#238443"],5:["#ffffcc","#c2e699","#78c679","#31a354","#006837"],6:["#ffffcc","#d9f0a3","#addd8e","#78c679","#31a354","#006837"],7:["#ffffcc","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#005a32"],8:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#005a32"],9:["#ffffe5","#f7fcb9","#d9f0a3","#addd8e","#78c679","#41ab5d","#238443","#006837","#004529"]},YlGnBu:{3:["#edf8b1","#7fcdbb","#2c7fb8"],4:["#ffffcc","#a1dab4","#41b6c4","#225ea8"],5:["#ffffcc","#a1dab4","#41b6c4","#2c7fb8","#253494"],6:["#ffffcc","#c7e9b4","#7fcdbb","#41b6c4","#2c7fb8","#253494"],7:["#ffffcc","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#0c2c84"],8:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#0c2c84"],9:["#ffffd9","#edf8b1","#c7e9b4","#7fcdbb","#41b6c4","#1d91c0","#225ea8","#253494","#081d58"]},GnBu:{3:["#e0f3db","#a8ddb5","#43a2ca"],4:["#f0f9e8","#bae4bc","#7bccc4","#2b8cbe"],5:["#f0f9e8","#bae4bc","#7bccc4","#43a2ca","#0868ac"],6:["#f0f9e8","#ccebc5","#a8ddb5","#7bccc4","#43a2ca","#0868ac"],7:["#f0f9e8","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#08589e"],8:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#08589e"],9:["#f7fcf0","#e0f3db","#ccebc5","#a8ddb5","#7bccc4","#4eb3d3","#2b8cbe","#0868ac","#084081"]},BuGn:{3:["#e5f5f9","#99d8c9","#2ca25f"],4:["#edf8fb","#b2e2e2","#66c2a4","#238b45"],5:["#edf8fb","#b2e2e2","#66c2a4","#2ca25f","#006d2c"],6:["#edf8fb","#ccece6","#99d8c9","#66c2a4","#2ca25f","#006d2c"],7:["#edf8fb","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#005824"],8:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#005824"],9:["#f7fcfd","#e5f5f9","#ccece6","#99d8c9","#66c2a4","#41ae76","#238b45","#006d2c","#00441b"]},PuBuGn:{3:["#ece2f0","#a6bddb","#1c9099"],4:["#f6eff7","#bdc9e1","#67a9cf","#02818a"],5:["#f6eff7","#bdc9e1","#67a9cf","#1c9099","#016c59"],6:["#f6eff7","#d0d1e6","#a6bddb","#67a9cf","#1c9099","#016c59"],7:["#f6eff7","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016450"],8:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016450"],9:["#fff7fb","#ece2f0","#d0d1e6","#a6bddb","#67a9cf","#3690c0","#02818a","#016c59","#014636"]},PuBu:{3:["#ece7f2","#a6bddb","#2b8cbe"],4:["#f1eef6","#bdc9e1","#74a9cf","#0570b0"],5:["#f1eef6","#bdc9e1","#74a9cf","#2b8cbe","#045a8d"],6:["#f1eef6","#d0d1e6","#a6bddb","#74a9cf","#2b8cbe","#045a8d"],7:["#f1eef6","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#034e7b"],8:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#034e7b"],9:["#fff7fb","#ece7f2","#d0d1e6","#a6bddb","#74a9cf","#3690c0","#0570b0","#045a8d","#023858"]},BuPu:{3:["#e0ecf4","#9ebcda","#8856a7"],4:["#edf8fb","#b3cde3","#8c96c6","#88419d"],5:["#edf8fb","#b3cde3","#8c96c6","#8856a7","#810f7c"],6:["#edf8fb","#bfd3e6","#9ebcda","#8c96c6","#8856a7","#810f7c"],7:["#edf8fb","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#6e016b"],8:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#6e016b"],9:["#f7fcfd","#e0ecf4","#bfd3e6","#9ebcda","#8c96c6","#8c6bb1","#88419d","#810f7c","#4d004b"]},RdPu:{3:["#fde0dd","#fa9fb5","#c51b8a"],4:["#feebe2","#fbb4b9","#f768a1","#ae017e"],5:["#feebe2","#fbb4b9","#f768a1","#c51b8a","#7a0177"],6:["#feebe2","#fcc5c0","#fa9fb5","#f768a1","#c51b8a","#7a0177"],7:["#feebe2","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177"],8:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177"],9:["#fff7f3","#fde0dd","#fcc5c0","#fa9fb5","#f768a1","#dd3497","#ae017e","#7a0177","#49006a"]},PuRd:{3:["#e7e1ef","#c994c7","#dd1c77"],4:["#f1eef6","#d7b5d8","#df65b0","#ce1256"],5:["#f1eef6","#d7b5d8","#df65b0","#dd1c77","#980043"],6:["#f1eef6","#d4b9da","#c994c7","#df65b0","#dd1c77","#980043"],7:["#f1eef6","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#91003f"],8:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#91003f"],9:["#f7f4f9","#e7e1ef","#d4b9da","#c994c7","#df65b0","#e7298a","#ce1256","#980043","#67001f"]},OrRd:{3:["#fee8c8","#fdbb84","#e34a33"],4:["#fef0d9","#fdcc8a","#fc8d59","#d7301f"],5:["#fef0d9","#fdcc8a","#fc8d59","#e34a33","#b30000"],6:["#fef0d9","#fdd49e","#fdbb84","#fc8d59","#e34a33","#b30000"],7:["#fef0d9","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#990000"],8:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#990000"],9:["#fff7ec","#fee8c8","#fdd49e","#fdbb84","#fc8d59","#ef6548","#d7301f","#b30000","#7f0000"]},YlOrRd:{3:["#ffeda0","#feb24c","#f03b20"],4:["#ffffb2","#fecc5c","#fd8d3c","#e31a1c"],5:["#ffffb2","#fecc5c","#fd8d3c","#f03b20","#bd0026"],6:["#ffffb2","#fed976","#feb24c","#fd8d3c","#f03b20","#bd0026"],7:["#ffffb2","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#b10026"],8:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#b10026"],9:["#ffffcc","#ffeda0","#fed976","#feb24c","#fd8d3c","#fc4e2a","#e31a1c","#bd0026","#800026"]},YlOrBr:{3:["#fff7bc","#fec44f","#d95f0e"],4:["#ffffd4","#fed98e","#fe9929","#cc4c02"],5:["#ffffd4","#fed98e","#fe9929","#d95f0e","#993404"],6:["#ffffd4","#fee391","#fec44f","#fe9929","#d95f0e","#993404"],7:["#ffffd4","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#8c2d04"],8:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#8c2d04"],9:["#ffffe5","#fff7bc","#fee391","#fec44f","#fe9929","#ec7014","#cc4c02","#993404","#662506"]},Purples:{3:["#efedf5","#bcbddc","#756bb1"],4:["#f2f0f7","#cbc9e2","#9e9ac8","#6a51a3"],5:["#f2f0f7","#cbc9e2","#9e9ac8","#756bb1","#54278f"],6:["#f2f0f7","#dadaeb","#bcbddc","#9e9ac8","#756bb1","#54278f"],7:["#f2f0f7","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#4a1486"],8:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#4a1486"],9:["#fcfbfd","#efedf5","#dadaeb","#bcbddc","#9e9ac8","#807dba","#6a51a3","#54278f","#3f007d"]},Blues:{3:["#deebf7","#9ecae1","#3182bd"],4:["#eff3ff","#bdd7e7","#6baed6","#2171b5"],5:["#eff3ff","#bdd7e7","#6baed6","#3182bd","#08519c"],6:["#eff3ff","#c6dbef","#9ecae1","#6baed6","#3182bd","#08519c"],7:["#eff3ff","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#084594"],8:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#084594"],9:["#f7fbff","#deebf7","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#08519c","#08306b"]},Greens:{3:["#e5f5e0","#a1d99b","#31a354"],4:["#edf8e9","#bae4b3","#74c476","#238b45"],5:["#edf8e9","#bae4b3","#74c476","#31a354","#006d2c"],6:["#edf8e9","#c7e9c0","#a1d99b","#74c476","#31a354","#006d2c"],7:["#edf8e9","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#005a32"],8:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#005a32"],9:["#f7fcf5","#e5f5e0","#c7e9c0","#a1d99b","#74c476","#41ab5d","#238b45","#006d2c","#00441b"]},Oranges:{3:["#fee6ce","#fdae6b","#e6550d"],4:["#feedde","#fdbe85","#fd8d3c","#d94701"],5:["#feedde","#fdbe85","#fd8d3c","#e6550d","#a63603"],6:["#feedde","#fdd0a2","#fdae6b","#fd8d3c","#e6550d","#a63603"],7:["#feedde","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#8c2d04"],8:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#8c2d04"],9:["#fff5eb","#fee6ce","#fdd0a2","#fdae6b","#fd8d3c","#f16913","#d94801","#a63603","#7f2704"]},Reds:{3:["#fee0d2","#fc9272","#de2d26"],4:["#fee5d9","#fcae91","#fb6a4a","#cb181d"],5:["#fee5d9","#fcae91","#fb6a4a","#de2d26","#a50f15"],6:["#fee5d9","#fcbba1","#fc9272","#fb6a4a","#de2d26","#a50f15"],7:["#fee5d9","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#99000d"],8:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#99000d"],9:["#fff5f0","#fee0d2","#fcbba1","#fc9272","#fb6a4a","#ef3b2c","#cb181d","#a50f15","#67000d"]},Greys:{3:["#f0f0f0","#bdbdbd","#636363"],4:["#f7f7f7","#cccccc","#969696","#525252"],5:["#f7f7f7","#cccccc","#969696","#636363","#252525"],6:["#f7f7f7","#d9d9d9","#bdbdbd","#969696","#636363","#252525"],7:["#f7f7f7","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525"],8:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525"],9:["#ffffff","#f0f0f0","#d9d9d9","#bdbdbd","#969696","#737373","#525252","#252525","#000000"]},PuOr:{3:["#f1a340","#f7f7f7","#998ec3"],4:["#e66101","#fdb863","#b2abd2","#5e3c99"],5:["#e66101","#fdb863","#f7f7f7","#b2abd2","#5e3c99"],6:["#b35806","#f1a340","#fee0b6","#d8daeb","#998ec3","#542788"],7:["#b35806","#f1a340","#fee0b6","#f7f7f7","#d8daeb","#998ec3","#542788"],8:["#b35806","#e08214","#fdb863","#fee0b6","#d8daeb","#b2abd2","#8073ac","#542788"],9:["#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788"],10:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"],11:["#7f3b08","#b35806","#e08214","#fdb863","#fee0b6","#f7f7f7","#d8daeb","#b2abd2","#8073ac","#542788","#2d004b"]},BrBG:{3:["#d8b365","#f5f5f5","#5ab4ac"],4:["#a6611a","#dfc27d","#80cdc1","#018571"],5:["#a6611a","#dfc27d","#f5f5f5","#80cdc1","#018571"],6:["#8c510a","#d8b365","#f6e8c3","#c7eae5","#5ab4ac","#01665e"],7:["#8c510a","#d8b365","#f6e8c3","#f5f5f5","#c7eae5","#5ab4ac","#01665e"],8:["#8c510a","#bf812d","#dfc27d","#f6e8c3","#c7eae5","#80cdc1","#35978f","#01665e"],9:["#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e"],10:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"],11:["#543005","#8c510a","#bf812d","#dfc27d","#f6e8c3","#f5f5f5","#c7eae5","#80cdc1","#35978f","#01665e","#003c30"]},PRGn:{3:["#af8dc3","#f7f7f7","#7fbf7b"],4:["#7b3294","#c2a5cf","#a6dba0","#008837"],5:["#7b3294","#c2a5cf","#f7f7f7","#a6dba0","#008837"],6:["#762a83","#af8dc3","#e7d4e8","#d9f0d3","#7fbf7b","#1b7837"],7:["#762a83","#af8dc3","#e7d4e8","#f7f7f7","#d9f0d3","#7fbf7b","#1b7837"],8:["#762a83","#9970ab","#c2a5cf","#e7d4e8","#d9f0d3","#a6dba0","#5aae61","#1b7837"],9:["#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837"],10:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"],11:["#40004b","#762a83","#9970ab","#c2a5cf","#e7d4e8","#f7f7f7","#d9f0d3","#a6dba0","#5aae61","#1b7837","#00441b"]},PiYG:{3:["#e9a3c9","#f7f7f7","#a1d76a"],4:["#d01c8b","#f1b6da","#b8e186","#4dac26"],5:["#d01c8b","#f1b6da","#f7f7f7","#b8e186","#4dac26"],6:["#c51b7d","#e9a3c9","#fde0ef","#e6f5d0","#a1d76a","#4d9221"],7:["#c51b7d","#e9a3c9","#fde0ef","#f7f7f7","#e6f5d0","#a1d76a","#4d9221"],8:["#c51b7d","#de77ae","#f1b6da","#fde0ef","#e6f5d0","#b8e186","#7fbc41","#4d9221"],9:["#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221"],10:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"],11:["#8e0152","#c51b7d","#de77ae","#f1b6da","#fde0ef","#f7f7f7","#e6f5d0","#b8e186","#7fbc41","#4d9221","#276419"]},RdBu:{3:["#ef8a62","#f7f7f7","#67a9cf"],4:["#ca0020","#f4a582","#92c5de","#0571b0"],5:["#ca0020","#f4a582","#f7f7f7","#92c5de","#0571b0"],6:["#b2182b","#ef8a62","#fddbc7","#d1e5f0","#67a9cf","#2166ac"],7:["#b2182b","#ef8a62","#fddbc7","#f7f7f7","#d1e5f0","#67a9cf","#2166ac"],8:["#b2182b","#d6604d","#f4a582","#fddbc7","#d1e5f0","#92c5de","#4393c3","#2166ac"],9:["#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac"],10:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"],11:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#f7f7f7","#d1e5f0","#92c5de","#4393c3","#2166ac","#053061"]},RdGy:{3:["#ef8a62","#ffffff","#999999"],4:["#ca0020","#f4a582","#bababa","#404040"],5:["#ca0020","#f4a582","#ffffff","#bababa","#404040"],6:["#b2182b","#ef8a62","#fddbc7","#e0e0e0","#999999","#4d4d4d"],7:["#b2182b","#ef8a62","#fddbc7","#ffffff","#e0e0e0","#999999","#4d4d4d"],8:["#b2182b","#d6604d","#f4a582","#fddbc7","#e0e0e0","#bababa","#878787","#4d4d4d"],9:["#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d"],10:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"],11:["#67001f","#b2182b","#d6604d","#f4a582","#fddbc7","#ffffff","#e0e0e0","#bababa","#878787","#4d4d4d","#1a1a1a"]},RdYlBu:{3:["#fc8d59","#ffffbf","#91bfdb"],4:["#d7191c","#fdae61","#abd9e9","#2c7bb6"],5:["#d7191c","#fdae61","#ffffbf","#abd9e9","#2c7bb6"],6:["#d73027","#fc8d59","#fee090","#e0f3f8","#91bfdb","#4575b4"],7:["#d73027","#fc8d59","#fee090","#ffffbf","#e0f3f8","#91bfdb","#4575b4"],8:["#d73027","#f46d43","#fdae61","#fee090","#e0f3f8","#abd9e9","#74add1","#4575b4"],9:["#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4"],10:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"],11:["#a50026","#d73027","#f46d43","#fdae61","#fee090","#ffffbf","#e0f3f8","#abd9e9","#74add1","#4575b4","#313695"]},Spectral:{3:["#fc8d59","#ffffbf","#99d594"],4:["#d7191c","#fdae61","#abdda4","#2b83ba"],5:["#d7191c","#fdae61","#ffffbf","#abdda4","#2b83ba"],6:["#d53e4f","#fc8d59","#fee08b","#e6f598","#99d594","#3288bd"],7:["#d53e4f","#fc8d59","#fee08b","#ffffbf","#e6f598","#99d594","#3288bd"],8:["#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd"],9:["#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd"],10:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],11:["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"]},RdYlGn:{3:["#fc8d59","#ffffbf","#91cf60"],4:["#d7191c","#fdae61","#a6d96a","#1a9641"],5:["#d7191c","#fdae61","#ffffbf","#a6d96a","#1a9641"],6:["#d73027","#fc8d59","#fee08b","#d9ef8b","#91cf60","#1a9850"],7:["#d73027","#fc8d59","#fee08b","#ffffbf","#d9ef8b","#91cf60","#1a9850"],8:["#d73027","#f46d43","#fdae61","#fee08b","#d9ef8b","#a6d96a","#66bd63","#1a9850"],9:["#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850"],10:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"],11:["#a50026","#d73027","#f46d43","#fdae61","#fee08b","#ffffbf","#d9ef8b","#a6d96a","#66bd63","#1a9850","#006837"]},Accent:{3:["#7fc97f","#beaed4","#fdc086"],4:["#7fc97f","#beaed4","#fdc086","#ffff99"],5:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0"],6:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f"],7:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17"],8:["#7fc97f","#beaed4","#fdc086","#ffff99","#386cb0","#f0027f","#bf5b17","#666666"]},Dark2:{3:["#1b9e77","#d95f02","#7570b3"],4:["#1b9e77","#d95f02","#7570b3","#e7298a"],5:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e"],6:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02"],7:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d"],8:["#1b9e77","#d95f02","#7570b3","#e7298a","#66a61e","#e6ab02","#a6761d","#666666"]},Paired:{3:["#a6cee3","#1f78b4","#b2df8a"],4:["#a6cee3","#1f78b4","#b2df8a","#33a02c"],5:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99"],6:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c"],7:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f"],8:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00"],9:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6"],10:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a"],11:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99"],12:["#a6cee3","#1f78b4","#b2df8a","#33a02c","#fb9a99","#e31a1c","#fdbf6f","#ff7f00","#cab2d6","#6a3d9a","#ffff99","#b15928"]},Pastel1:{3:["#fbb4ae","#b3cde3","#ccebc5"],4:["#fbb4ae","#b3cde3","#ccebc5","#decbe4"],5:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6"],6:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc"],7:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd"],8:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec"],9:["#fbb4ae","#b3cde3","#ccebc5","#decbe4","#fed9a6","#ffffcc","#e5d8bd","#fddaec","#f2f2f2"]},Pastel2:{3:["#b3e2cd","#fdcdac","#cbd5e8"],4:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4"],5:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9"],6:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae"],7:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc"],8:["#b3e2cd","#fdcdac","#cbd5e8","#f4cae4","#e6f5c9","#fff2ae","#f1e2cc","#cccccc"]},Set1:{3:["#e41a1c","#377eb8","#4daf4a"],4:["#e41a1c","#377eb8","#4daf4a","#984ea3"],5:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00"],6:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33"],7:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628"],8:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf"],9:["#e41a1c","#377eb8","#4daf4a","#984ea3","#ff7f00","#ffff33","#a65628","#f781bf","#999999"]},Set2:{3:["#66c2a5","#fc8d62","#8da0cb"],4:["#66c2a5","#fc8d62","#8da0cb","#e78ac3"],5:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854"],6:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f"],7:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494"],8:["#66c2a5","#fc8d62","#8da0cb","#e78ac3","#a6d854","#ffd92f","#e5c494","#b3b3b3"]},Set3:{3:["#8dd3c7","#ffffb3","#bebada"],4:["#8dd3c7","#ffffb3","#bebada","#fb8072"],5:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3"],6:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462"],7:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69"],8:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5"],9:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9"],10:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd"],11:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5"],12:["#8dd3c7","#ffffb3","#bebada","#fb8072","#80b1d3","#fdb462","#b3de69","#fccde5","#d9d9d9","#bc80bd","#ccebc5","#ffed6f"]}}},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"DEFAULT_COLOR_RANGE",{enumerable:!0,get:function(){return a.DEFAULT_COLOR_RANGE}}),t.EDITOR_AVAILABLE_LAYERS=t.LAYER_TYPES=t.LAYER_TEXT_CONFIGS=t.LAYER_VIS_CONFIGS=t.DEFAULT_COLOR_UI=t.UNKNOWN_COLOR_KEY=t.DEFAULT_CUSTOM_PALETTE=t.DEFAULT_TEXT_LABEL=t.DEFAULT_LAYER_LABEL=t.DEFAULT_HIGHLIGHT_COLOR=t.DEFAULT_LAYER_OPACITY=t.PROPERTY_GROUPS=void 0;var o=r(n(15)),a=n(11),i=n(14),l=(0,o.default)({color:null,stroke:null,radius:null,height:null,angle:null,cell:null,precision:null,display:null});t.PROPERTY_GROUPS=l;t.DEFAULT_LAYER_OPACITY=.8;t.DEFAULT_HIGHLIGHT_COLOR=[252,242,26,255];t.DEFAULT_LAYER_LABEL="new layer";t.DEFAULT_TEXT_LABEL={field:null,color:[255,255,255],size:18,offset:[0,0],anchor:"start",alignment:"center",outlineWidth:0,outlineColor:[255,0,0,255],background:!1,backgroundColor:[0,0,200,255]};var c={name:"color.customPalette",type:"custom",category:"Custom",colors:[]};t.DEFAULT_CUSTOM_PALETTE=c;t.UNKNOWN_COLOR_KEY="__unknownColor__";var d={customPalette:c,showSketcher:!1,showDropdown:!1,colorRangeConfig:{type:"all",steps:6,reversed:!1,custom:!1}};t.DEFAULT_COLOR_UI=d;var u={thickness:{type:"number",defaultValue:2,label:"layerVisConfigs.strokeWidth",isRanged:!1,range:[0,100],step:.1,group:l.stroke,property:"thickness",allowCustomValue:!0},strokeWidthRange:{type:"number",defaultValue:[0,10],label:"layerVisConfigs.strokeWidthRange",isRanged:!0,range:[0,200],step:.1,group:l.stroke,property:"sizeRange",allowCustomValue:!0},trailLength:{type:"number",defaultValue:180,label:"layerVisConfigs.strokeWidth",isRanged:!1,range:[1,1e3],step:1,group:l.stroke,property:"trailLength",allowCustomValue:!0},radius:{type:"number",defaultValue:10,label:"layerVisConfigs.radius",isRanged:!1,range:[0,100],step:.1,group:l.radius,property:"radius",allowCustomValue:!0},fixedRadius:{defaultValue:!1,type:"boolean",label:"layerVisConfigs.fixedRadius",description:"layerVisConfigs.fixedRadiusDescription",group:l.radius,property:"fixedRadius"},radiusRange:{type:"number",defaultValue:[0,50],isRanged:!0,range:[0,500],step:.1,label:"layerVisConfigs.radiusRange",group:l.radius,property:"radiusRange",allowCustomValue:!0},clusterRadius:{type:"number",label:"layerVisConfigs.clusterRadius",defaultValue:40,isRanged:!1,range:[1,500],step:.1,group:l.radius,property:"clusterRadius",allowCustomValue:!0},clusterRadiusRange:{type:"number",label:"layerVisConfigs.radiusRangePixels",defaultValue:[1,40],isRanged:!0,range:[1,150],step:.1,group:l.radius,property:"radiusRange",allowCustomValue:!0},opacity:{type:"number",defaultValue:.8,label:"layerVisConfigs.opacity",isRanged:!1,range:[0,1],step:.01,group:l.color,property:"opacity",allowCustomValue:!1},coverage:{type:"number",defaultValue:1,label:"layerVisConfigs.coverage",isRanged:!1,range:[0,1],step:.01,group:l.cell,property:"coverage",allowCustomValue:!1},outline:{type:"boolean",defaultValue:!1,label:"layer.outline",group:l.display,property:"outline"},colorRange:{type:"color-range-select",defaultValue:a.DEFAULT_COLOR_RANGE,label:"layerVisConfigs.colorRange",group:l.color,property:"colorRange"},strokeColorRange:{type:"color-range-select",defaultValue:a.DEFAULT_COLOR_RANGE,label:"layerVisConfigs.strokeColorRange",group:l.color,property:"strokeColorRange"},targetColor:{type:"color-select",label:"layerVisConfigs.targetColor",defaultValue:null,group:l.color,property:"targetColor"},strokeColor:{type:"color-select",label:"layerVisConfigs.strokeColor",defaultValue:null,group:l.color,property:"strokeColor"},colorAggregation:{type:"select",defaultValue:i.AGGREGATION_TYPES.average,label:"layerVisConfigs.colorAggregation",options:Object.keys(i.AGGREGATION_TYPES),group:l.color,property:"colorAggregation",condition:function(e){return Boolean(e.colorField)}},sizeAggregation:{type:"select",defaultValue:i.AGGREGATION_TYPES.average,label:"layerVisConfigs.heightAggregation",options:Object.keys(i.AGGREGATION_TYPES),group:l.height,property:"sizeAggregation",condition:function(e){return Boolean(e.sizeField)}},percentile:{type:"number",defaultValue:[0,100],label:function(e){return"Filter by ".concat(e.colorField?"".concat(e.visConfig.colorAggregation," ").concat(e.colorField.name):"count"," percentile")},isRanged:!0,range:[0,100],step:.01,group:l.color,property:"percentile",condition:function(e){return"ordinal"!==e.colorScale},allowCustomValue:!1},elevationPercentile:{type:"number",defaultValue:[0,100],label:function(e){return"Filter by ".concat(e.sizeField?"".concat(e.visConfig.sizeAggregation," ").concat(e.sizeField.name):"count"," percentile")},isRanged:!0,range:[0,100],step:.01,group:l.height,property:"elevationPercentile",condition:function(e){return Boolean(e.visConfig.enable3d&&(e.colorField||e.sizeField))},allowCustomValue:!1},resolution:{type:"number",defaultValue:8,label:"layerVisConfigs.resolution",isRanged:!1,range:[0,13],step:1,group:l.cell,property:"resolution",allowCustomValue:!0},sizeScale:{type:"number",defaultValue:10,label:"layerVisConfigs.sizeScale",isRanged:!1,range:[1,1e3],step:1,group:l.stroke,property:"sizeScale",allowCustomValue:!0},angle:{type:"number",label:"layerVisConfigs.angle",defaultValue:0,isRanged:!1,range:[0,360],group:l.angle,step:1,property:"angle",allowCustomValue:!0},worldUnitSize:{type:"number",defaultValue:1,label:"layerVisConfigs.worldUnitSize",isRanged:!1,range:[0,500],step:1e-4,group:l.cell,property:"worldUnitSize",allowCustomValue:!0},elevationScale:{type:"number",defaultValue:5,label:"layerVisConfigs.elevationScale",isRanged:!1,range:[0,100],step:.1,group:l.height,property:"elevationScale",allowCustomValue:!0},enableElevationZoomFactor:{type:"boolean",defaultValue:!0,label:"layerVisConfigs.enableElevationZoomFactor",group:l.height,property:"enableElevationZoomFactor",description:"layerVisConfigs.enableElevationZoomFactorDescription"},elevationRange:{type:"number",defaultValue:[0,500],label:"layerVisConfigs.heightScale",isRanged:!0,range:[0,1e3],step:.01,group:l.height,property:"sizeRange",allowCustomValue:!0},heightRange:{type:"number",defaultValue:[0,500],label:"Height Scale",isRanged:!0,range:[0,1e3],step:.01,group:l.height,property:"heightRange",allowCustomValue:!0},coverageRange:{type:"number",defaultValue:[0,1],label:"layerVisConfigs.coverageRange",isRanged:!0,range:[0,1],step:.01,group:l.radius,property:"coverageRange",allowCustomValue:!1},"hi-precision":{type:"boolean",defaultValue:!1,label:"layerVisConfigs.highPrecisionRendering",group:l.precision,property:"hi-precision",description:"layerVisConfigs.highPrecisionRenderingDescription"},enable3d:{type:"boolean",defaultValue:!1,label:"layerVisConfigs.height",group:l.height,property:"enable3d",description:"layerVisConfigs.heightDescription"},stroked:{type:"boolean",label:"layerVisConfigs.stroke",defaultValue:!0,group:l.display,property:"stroked"},filled:{type:"boolean",label:"layerVisConfigs.fill",defaultValue:!1,group:l.display,property:"filled"},extruded:{type:"boolean",defaultValue:!1,label:"layerVisConfigs.enablePolygonHeight",group:l.display,property:"extruded"},wireframe:{type:"boolean",defaultValue:!1,label:"layerVisConfigs.showWireframe",group:l.display,property:"wireframe"},weight:{type:"number",defaultValue:1,label:"layerVisConfigs.weightIntensity",isRanged:!1,range:[.01,500],step:.01,group:l.cell,property:"weight",condition:function(e){return Boolean(e.weightField)},allowCustomValue:!0},heatmapRadius:{type:"number",defaultValue:20,label:"layerVisConfigs.radius",isRanged:!1,range:[0,100],step:.1,group:l.cell,property:"radius",allowCustomValue:!0},darkBaseMapEnabled:{type:"boolean",defaultValue:!0,label:"layerVisConfigs.darkModeEnabled",property:"darkBaseMapEnabled",group:l.display}};t.LAYER_VIS_CONFIGS=u;t.LAYER_TEXT_CONFIGS={fontSize:{type:"number",range:[1,100],value0:1,step:1,isRanged:!1,label:"Font size",showInput:!0},outlineWidth:{type:"number",range:[0,1],value0:0,step:.01,isRanged:!1,label:"Outline width",showInput:!0},textAnchor:{type:"select",options:["start","middle","end"],multiSelect:!1,searchable:!1},textAlignment:{type:"select",options:["top","center","bottom"],multiSelect:!1,searchable:!1}};var f=(0,o.default)({point:null,arc:null,line:null,grid:null,hexagon:null,geojson:null,cluster:null,icon:null,heatmap:null,hexagonId:null,"3D":null,trip:null,s2:null});t.LAYER_TYPES=f;var s=[f.point,f.hexagon,f.arc,f.line,f.hexagonId,f.geojson];t.EDITOR_AVAILABLE_LAYERS=s},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(n(33)),a=Object.assign({},o.default.KeyEvent);a.DOM_VK_UP=a.DOM_VK_UP||38,a.DOM_VK_DOWN=a.DOM_VK_DOWN||40,a.DOM_VK_BACK_SPACE=a.DOM_VK_BACK_SPACE||8,a.DOM_VK_RETURN=a.DOM_VK_RETURN||13,a.DOM_VK_ENTER=a.DOM_VK_ENTER||14,a.DOM_VK_ESCAPE=a.DOM_VK_ESCAPE||27,a.DOM_VK_TAB=a.DOM_VK_TAB||9,a.DOM_VK_DELETE=a.DOM_VK_DELETE||46;var i=a;t.default=i},function(e,t,n){(function(t){var n;n="undefined"!=typeof window?window:void 0!==t?t:"undefined"!=typeof self?self:{},e.exports=n}).call(this,n(34))},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IMAGE_EXPORT_ERRORS=t.MISSING_MAPBOX_TOKEN=void 0;t.MISSING_MAPBOX_TOKEN="Mapbox Token not valid. [Click here](https://github.com/keplergl/kepler.gl#mapboxapiaccesstoken-string-required)";t.IMAGE_EXPORT_ERRORS={dataUri:'[kepler.gl] Failed to create image from data uri.\n Copy the uri in the javascript console when reporting this bug.\n The uri is the string starts with "data:image/png"',styleSheet:"[kepler.gl] Failed to fetch stylesheet when exporting image.\n This probably will not affect the map. It might affect the legend.\n The stylesheet failed to load is: "}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BUG_REPORT_LINK=t.GUIDES_FILE_FORMAT_DOC=t.EXPORT_HTML_MAP_MODES_DOC=t.MAPBOX_ACCESS_TOKEN=t.ADD_DATA_TO_MAP_DOC=t.EXPORT_HTML_MAP_DOC=t.API_REFERENCE_DOC=t.ACTIONS_DOC=t.USER_GUIDE_DOC=void 0;var r="https://docs.kepler.gl/docs/user-guides";t.USER_GUIDE_DOC=r;var o="https://docs.kepler.gl/docs/api-reference/actions/actions";t.ACTIONS_DOC=o;t.API_REFERENCE_DOC="https://docs.kepler.gl/docs/api-reference";var a="".concat(r,"/k-save-and-export");t.EXPORT_HTML_MAP_DOC=a;var i="".concat(o,"#adddatatomap");t.ADD_DATA_TO_MAP_DOC=i;t.MAPBOX_ACCESS_TOKEN="https://docs.mapbox.com/help/how-mapbox-works/access-tokens/";var l="".concat(r,"/k-save-and-export#export-html-map");t.EXPORT_HTML_MAP_MODES_DOC=l;var c="".concat(r,"/b-kepler-gl-workflow/a-add-data-to-the-map#supported-file-formats");t.GUIDES_FILE_FORMAT_DOC=c;t.BUG_REPORT_LINK="https://github.com/keplergl/kepler.gl/issues/new?assignees=&labels=bug&template=bug_report.md&title=%5BBug%5D"},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SORTABLE_EFFECT_TYPE=t.SORTABLE_EFFECT_PANEL_TYPE=t.SORTABLE_LAYER_TYPE=t.DROPPABLE_MAP_CONTAINER_TYPE=t.SORTABLE_SIDE_PANEL_TYPE=t.DND_EMPTY_MODIFIERS=t.DND_MODIFIERS=void 0;var r=[n(40).restrictToVerticalAxis];t.DND_MODIFIERS=r;t.DND_EMPTY_MODIFIERS=[];t.SORTABLE_SIDE_PANEL_TYPE="root";t.DROPPABLE_MAP_CONTAINER_TYPE="map";t.SORTABLE_LAYER_TYPE="layer";t.SORTABLE_EFFECT_PANEL_TYPE="root";t.SORTABLE_EFFECT_TYPE="effect"},function(e,t,n){"use strict";var r=n(2);Object.defineProperty(t,"__esModule",{value:!0}),t.media=t.breakPointValues=void 0;var o,a,i,l=r(n(7)),c=n(8),d={palm:588,desk:768};t.breakPointValues=d;var u={palm:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return(0,c.css)(o||(o=(0,l.default)(["\n @media (max-width: ","px) {\n ",";\n }\n "])),(function(e){return(e.theme.breakPoints||d).palm}),c.css.apply(void 0,[e].concat(n)))},portable:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return(0,c.css)(a||(a=(0,l.default)(["\n @media (max-width: ","px) {\n ",";\n }\n "])),(function(e){return(e.theme.breakPoints||d).desk}),c.css.apply(void 0,[e].concat(n)))},desk:function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return(0,c.css)(i||(i=(0,l.default)(["\n @media (min-width: ","px) {\n ",";\n }\n "])),(function(e){return(e.theme.breakPoints||d).desk+1}),c.css.apply(void 0,[e].concat(n)))}};t.media=u},function(e,t,n){"use strict";n.r(t),n.d(t,"scaleBand",(function(){return c})),n.d(t,"scalePoint",(function(){return u})),n.d(t,"scaleIdentity",(function(){return Ve})),n.d(t,"scaleLinear",(function(){return Ge})),n.d(t,"scaleLog",(function(){return Qe})),n.d(t,"scaleSymlog",(function(){return tt})),n.d(t,"scaleOrdinal",(function(){return l})),n.d(t,"scaleImplicit",(function(){return i})),n.d(t,"scalePow",(function(){return it})),n.d(t,"scaleSqrt",(function(){return lt})),n.d(t,"scaleRadial",(function(){return ut})),n.d(t,"scaleQuantile",(function(){return ht})),n.d(t,"scaleQuantize",(function(){return Et})),n.d(t,"scaleThreshold",(function(){return mt})),n.d(t,"scaleTime",(function(){return Or})),n.d(t,"scaleUtc",(function(){return Rr})),n.d(t,"scaleSequential",(function(){return Nr})),n.d(t,"scaleSequentialLog",(function(){return Ur})),n.d(t,"scaleSequentialPow",(function(){return Vr})),n.d(t,"scaleSequentialSqrt",(function(){return Yr})),n.d(t,"scaleSequentialSymlog",(function(){return Gr})),n.d(t,"scaleSequentialQuantile",(function(){return zr})),n.d(t,"scaleDiverging",(function(){return qr})),n.d(t,"scaleDivergingLog",(function(){return Xr})),n.d(t,"scaleDivergingPow",(function(){return Zr})),n.d(t,"scaleDivergingSqrt",(function(){return Qr})),n.d(t,"scaleDivergingSymlog",(function(){return Kr})),n.d(t,"tickFormat",(function(){return Ne}));var r=function(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n;for(var r=-1,o=0|Math.max(0,Math.ceil((t-e)/n)),a=new Array(o);++r<o;)a[r]=e+r*n;return a};function o(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}function a(e,t){switch(arguments.length){case 0:break;case 1:"function"==typeof e?this.interpolator(e):this.range(e);break;default:this.domain(e),"function"==typeof t?this.interpolator(t):this.range(t)}return this}const i=Symbol("implicit");function l(){var e=new Map,t=[],n=[],r=i;function a(o){var a=o+"",l=e.get(a);if(!l){if(r!==i)return r;e.set(a,l=t.push(o))}return n[(l-1)%n.length]}return a.domain=function(n){if(!arguments.length)return t.slice();t=[],e=new Map;for(const r of n){const n=r+"";e.has(n)||e.set(n,t.push(r))}return a},a.range=function(e){return arguments.length?(n=Array.from(e),a):n.slice()},a.unknown=function(e){return arguments.length?(r=e,a):r},a.copy=function(){return l(t,n).unknown(r)},o.apply(a,arguments),a}function c(){var e,t,n=l().unknown(void 0),a=n.domain,i=n.range,d=0,u=1,f=!1,s=0,g=0,p=.5;function b(){var n=a().length,o=u<d,l=o?u:d,c=o?d:u;e=(c-l)/Math.max(1,n-s+2*g),f&&(e=Math.floor(e)),l+=(c-l-e*(n-s))*p,t=e*(1-s),f&&(l=Math.round(l),t=Math.round(t));var b=r(n).map((function(t){return l+e*t}));return i(o?b.reverse():b)}return delete n.unknown,n.domain=function(e){return arguments.length?(a(e),b()):a()},n.range=function(e){return arguments.length?([d,u]=e,d=+d,u=+u,b()):[d,u]},n.rangeRound=function(e){return[d,u]=e,d=+d,u=+u,f=!0,b()},n.bandwidth=function(){return t},n.step=function(){return e},n.round=function(e){return arguments.length?(f=!!e,b()):f},n.padding=function(e){return arguments.length?(s=Math.min(1,g=+e),b()):s},n.paddingInner=function(e){return arguments.length?(s=Math.min(1,e),b()):s},n.paddingOuter=function(e){return arguments.length?(g=+e,b()):g},n.align=function(e){return arguments.length?(p=Math.max(0,Math.min(1,e)),b()):p},n.copy=function(){return c(a(),[d,u]).round(f).paddingInner(s).paddingOuter(g).align(p)},o.apply(b(),arguments)}function d(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return d(t())},e}function u(){return d(c.apply(null,arguments).paddingInner(1))}var f=Math.sqrt(50),s=Math.sqrt(10),g=Math.sqrt(2),p=function(e,t,n){var r,o,a,i,l=-1;if(n=+n,(e=+e)===(t=+t)&&n>0)return[e];if((r=t<e)&&(o=e,e=t,t=o),0===(i=b(e,t,n))||!isFinite(i))return[];if(i>0){let n=Math.round(e/i),r=Math.round(t/i);for(n*i<e&&++n,r*i>t&&--r,a=new Array(o=r-n+1);++l<o;)a[l]=(n+l)*i}else{i=-i;let n=Math.round(e*i),r=Math.round(t*i);for(n/i<e&&++n,r/i>t&&--r,a=new Array(o=r-n+1);++l<o;)a[l]=(n+l)/i}return r&&a.reverse(),a};function b(e,t,n){var r=(t-e)/Math.max(0,n),o=Math.floor(Math.log(r)/Math.LN10),a=r/Math.pow(10,o);return o>=0?(a>=f?10:a>=s?5:a>=g?2:1)*Math.pow(10,o):-Math.pow(10,-o)/(a>=f?10:a>=s?5:a>=g?2:1)}function h(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),o=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),a=r/o;return a>=f?o*=10:a>=s?o*=5:a>=g&&(o*=2),t<e?-o:o}var E=function(e,t){return e<t?-1:e>t?1:e>=t?0:NaN},m=function(e){let t=e,n=e;function r(e,t,r,o){for(null==r&&(r=0),null==o&&(o=e.length);r<o;){const a=r+o>>>1;n(e[a],t)<0?r=a+1:o=a}return r}return 1===e.length&&(t=(t,n)=>e(t)-n,n=function(e){return(t,n)=>E(e(t),n)}(e)),{left:r,center:function(e,n,o,a){null==o&&(o=0),null==a&&(a=e.length);const i=r(e,n,o,a-1);return i>o&&t(e[i-1],n)>-t(e[i],n)?i-1:i},right:function(e,t,r,o){for(null==r&&(r=0),null==o&&(o=e.length);r<o;){const a=r+o>>>1;n(e[a],t)>0?o=a:r=a+1}return r}}};var _=function(e){return null===e?NaN:+e};const C=m(E),A=C.right;C.left,m(_).center;var B=A,F=function(e,t,n){e.prototype=t.prototype=n,n.constructor=e};function y(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function T(){}var D="\\s*([+-]?\\d+)\\s*",v="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",L="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",O=/^#([0-9a-f]{3,8})$/,P=new RegExp("^rgb\\("+[D,D,D]+"\\)$"),I=new RegExp("^rgb\\("+[L,L,L]+"\\)$"),S=new RegExp("^rgba\\("+[D,D,D,v]+"\\)$"),x=new RegExp("^rgba\\("+[L,L,L,v]+"\\)$"),w=new RegExp("^hsl\\("+[v,L,L]+"\\)$"),M=new RegExp("^hsla\\("+[v,L,L,v]+"\\)$"),R={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function k(){return this.rgb().formatHex()}function H(){return this.rgb().formatRgb()}function N(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=O.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?U(t):3===n?new z(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?G(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?G(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=P.exec(e))?new z(t[1],t[2],t[3],1):(t=I.exec(e))?new z(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=S.exec(e))?G(t[1],t[2],t[3],t[4]):(t=x.exec(e))?G(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=w.exec(e))?X(t[1],t[2]/100,t[3]/100,1):(t=M.exec(e))?X(t[1],t[2]/100,t[3]/100,t[4]):R.hasOwnProperty(e)?U(R[e]):"transparent"===e?new z(NaN,NaN,NaN,0):null}function U(e){return new z(e>>16&255,e>>8&255,255&e,1)}function G(e,t,n,r){return r<=0&&(e=t=n=NaN),new z(e,t,n,r)}function V(e){return e instanceof T||(e=N(e)),e?new z((e=e.rgb()).r,e.g,e.b,e.opacity):new z}function Y(e,t,n,r){return 1===arguments.length?V(e):new z(e,t,n,null==r?1:r)}function z(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function j(){return"#"+q(this.r)+q(this.g)+q(this.b)}function W(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function q(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function X(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Z(e,t,n,r)}function K(e){if(e instanceof Z)return new Z(e.h,e.s,e.l,e.opacity);if(e instanceof T||(e=N(e)),!e)return new Z;if(e instanceof Z)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),a=Math.max(t,n,r),i=NaN,l=a-o,c=(a+o)/2;return l?(i=t===a?(n-r)/l+6*(n<r):n===a?(r-t)/l+2:(t-n)/l+4,l/=c<.5?a+o:2-a-o,i*=60):l=c>0&&c<1?0:i,new Z(i,l,c,e.opacity)}function Z(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Q(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}function $(e,t,n,r,o){var a=e*e,i=a*e;return((1-3*e+3*a-i)*t+(4-6*a+3*i)*n+(1+3*e+3*a-3*i)*r+i*o)/6}F(T,N,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:k,formatHex:k,formatHsl:function(){return K(this).formatHsl()},formatRgb:H,toString:H}),F(z,Y,y(T,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new z(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new z(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:j,formatHex:j,formatRgb:W,toString:W})),F(Z,(function(e,t,n,r){return 1===arguments.length?K(e):new Z(e,t,n,null==r?1:r)}),y(T,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new Z(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new Z(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new z(Q(e>=240?e-240:e+120,o,r),Q(e,o,r),Q(e<120?e+240:e-120,o,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}));var J=e=>()=>e;function ee(e,t){return function(n){return e+n*t}}function te(e){return 1==(e=+e)?ne:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):J(isNaN(t)?n:t)}}function ne(e,t){var n=t-e;return n?ee(e,n):J(isNaN(e)?t:e)}var re=function e(t){var n=te(t);function r(e,t){var r=n((e=Y(e)).r,(t=Y(t)).r),o=n(e.g,t.g),a=n(e.b,t.b),i=ne(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=o(t),e.b=a(t),e.opacity=i(t),e+""}}return r.gamma=e,r}(1);function oe(e){return function(t){var n,r,o=t.length,a=new Array(o),i=new Array(o),l=new Array(o);for(n=0;n<o;++n)r=Y(t[n]),a[n]=r.r||0,i[n]=r.g||0,l[n]=r.b||0;return a=e(a),i=e(i),l=e(l),r.opacity=1,function(e){return r.r=a(e),r.g=i(e),r.b=l(e),r+""}}}oe((function(e){var t=e.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),o=e[r],a=e[r+1],i=r>0?e[r-1]:2*o-a,l=r<t-1?e[r+2]:2*a-o;return $((n-r/t)*t,i,o,a,l)}})),oe((function(e){var t=e.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*t),o=e[(r+t-1)%t],a=e[r%t],i=e[(r+1)%t],l=e[(r+2)%t];return $((n-r/t)*t,o,a,i,l)}}));var ae=function(e,t){t||(t=[]);var n,r=e?Math.min(t.length,e.length):0,o=t.slice();return function(a){for(n=0;n<r;++n)o[n]=e[n]*(1-a)+t[n]*a;return o}};function ie(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function le(e,t){var n,r=t?t.length:0,o=e?Math.min(r,e.length):0,a=new Array(o),i=new Array(r);for(n=0;n<o;++n)a[n]=pe(e[n],t[n]);for(;n<r;++n)i[n]=t[n];return function(e){for(n=0;n<o;++n)i[n]=a[n](e);return i}}var ce=function(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}},de=function(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}},ue=function(e,t){var n,r={},o={};for(n in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)n in e?r[n]=pe(e[n],t[n]):o[n]=t[n];return function(e){for(n in r)o[n]=r[n](e);return o}},fe=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,se=new RegExp(fe.source,"g");var ge=function(e,t){var n,r,o,a=fe.lastIndex=se.lastIndex=0,i=-1,l=[],c=[];for(e+="",t+="";(n=fe.exec(e))&&(r=se.exec(t));)(o=r.index)>a&&(o=t.slice(a,o),l[i]?l[i]+=o:l[++i]=o),(n=n[0])===(r=r[0])?l[i]?l[i]+=r:l[++i]=r:(l[++i]=null,c.push({i:i,x:de(n,r)})),a=se.lastIndex;return a<t.length&&(o=t.slice(a),l[i]?l[i]+=o:l[++i]=o),l.length<2?c[0]?function(e){return function(t){return e(t)+""}}(c[0].x):function(e){return function(){return e}}(t):(t=c.length,function(e){for(var n,r=0;r<t;++r)l[(n=c[r]).i]=n.x(e);return l.join("")})},pe=function(e,t){var n,r=typeof t;return null==t||"boolean"===r?J(t):("number"===r?de:"string"===r?(n=N(t))?(t=n,re):ge:t instanceof N?re:t instanceof Date?ce:ie(t)?ae:Array.isArray(t)?le:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?ue:de)(e,t)},be=function(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}};function he(e){return+e}var Ee=[0,1];function me(e){return e}function _e(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:(n=isNaN(t)?NaN:.5,function(){return n});var n}function Ce(e,t,n){var r=e[0],o=e[1],a=t[0],i=t[1];return o<r?(r=_e(o,r),a=n(i,a)):(r=_e(r,o),a=n(a,i)),function(e){return a(r(e))}}function Ae(e,t,n){var r=Math.min(e.length,t.length)-1,o=new Array(r),a=new Array(r),i=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++i<r;)o[i]=_e(e[i],e[i+1]),a[i]=n(t[i],t[i+1]);return function(t){var n=B(e,t,1,r)-1;return a[n](o[n](t))}}function Be(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Fe(){var e,t,n,r,o,a,i=Ee,l=Ee,c=pe,d=me;function u(){var e,t,n,c=Math.min(i.length,l.length);return d!==me&&(e=i[0],t=i[c-1],e>t&&(n=e,e=t,t=n),d=function(n){return Math.max(e,Math.min(t,n))}),r=c>2?Ae:Ce,o=a=null,f}function f(t){return isNaN(t=+t)?n:(o||(o=r(i.map(e),l,c)))(e(d(t)))}return f.invert=function(n){return d(t((a||(a=r(l,i.map(e),de)))(n)))},f.domain=function(e){return arguments.length?(i=Array.from(e,he),u()):i.slice()},f.range=function(e){return arguments.length?(l=Array.from(e),u()):l.slice()},f.rangeRound=function(e){return l=Array.from(e),c=be,u()},f.clamp=function(e){return arguments.length?(d=!!e||me,u()):d!==me},f.interpolate=function(e){return arguments.length?(c=e,u()):c},f.unknown=function(e){return arguments.length?(n=e,f):n},function(n,r){return e=n,t=r,u()}}function ye(){return Fe()(me,me)}var Te=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function De(e){if(!(t=Te.exec(e)))throw new Error("invalid format: "+e);var t;return new ve({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function ve(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}De.prototype=ve.prototype,ve.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};function Le(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}var Oe,Pe,Ie,Se,xe=function(e){return(e=Le(Math.abs(e)))?e[1]:NaN},we=function(e,t){var n=Le(e,t);if(!n)return e+"";var r=n[0],o=n[1];return o<0?"0."+new Array(-o).join("0")+r:r.length>o+1?r.slice(0,o+1)+"."+r.slice(o+1):r+new Array(o-r.length+2).join("0")},Me={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>we(100*e,t),r:we,s:function(e,t){var n=Le(e,t);if(!n)return e+"";var r=n[0],o=n[1],a=o-(Oe=3*Math.max(-8,Math.min(8,Math.floor(o/3))))+1,i=r.length;return a===i?r:a>i?r+new Array(a-i+1).join("0"):a>0?r.slice(0,a)+"."+r.slice(a):"0."+new Array(1-a).join("0")+Le(e,Math.max(0,t+a-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)},Re=function(e){return e},ke=Array.prototype.map,He=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];Pe=function(e){var t,n,r=void 0===e.grouping||void 0===e.thousands?Re:(t=ke.call(e.grouping,Number),n=e.thousands+"",function(e,r){for(var o=e.length,a=[],i=0,l=t[0],c=0;o>0&&l>0&&(c+l+1>r&&(l=Math.max(1,r-c)),a.push(e.substring(o-=l,o+l)),!((c+=l+1)>r));)l=t[i=(i+1)%t.length];return a.reverse().join(n)}),o=void 0===e.currency?"":e.currency[0]+"",a=void 0===e.currency?"":e.currency[1]+"",i=void 0===e.decimal?".":e.decimal+"",l=void 0===e.numerals?Re:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(ke.call(e.numerals,String)),c=void 0===e.percent?"%":e.percent+"",d=void 0===e.minus?"−":e.minus+"",u=void 0===e.nan?"NaN":e.nan+"";function f(e){var t=(e=De(e)).fill,n=e.align,f=e.sign,s=e.symbol,g=e.zero,p=e.width,b=e.comma,h=e.precision,E=e.trim,m=e.type;"n"===m?(b=!0,m="g"):Me[m]||(void 0===h&&(h=12),E=!0,m="g"),(g||"0"===t&&"="===n)&&(g=!0,t="0",n="=");var _="$"===s?o:"#"===s&&/[boxX]/.test(m)?"0"+m.toLowerCase():"",C="$"===s?a:/[%p]/.test(m)?c:"",A=Me[m],B=/[defgprs%]/.test(m);function F(e){var o,a,c,s=_,F=C;if("c"===m)F=A(e)+F,e="";else{var y=(e=+e)<0||1/e<0;if(e=isNaN(e)?u:A(Math.abs(e),h),E&&(e=function(e){e:for(var t,n=e.length,r=1,o=-1;r<n;++r)switch(e[r]){case".":o=t=r;break;case"0":0===o&&(o=r),t=r;break;default:if(!+e[r])break e;o>0&&(o=0)}return o>0?e.slice(0,o)+e.slice(t+1):e}(e)),y&&0==+e&&"+"!==f&&(y=!1),s=(y?"("===f?f:d:"-"===f||"("===f?"":f)+s,F=("s"===m?He[8+Oe/3]:"")+F+(y&&"("===f?")":""),B)for(o=-1,a=e.length;++o<a;)if(48>(c=e.charCodeAt(o))||c>57){F=(46===c?i+e.slice(o+1):e.slice(o))+F,e=e.slice(0,o);break}}b&&!g&&(e=r(e,1/0));var T=s.length+e.length+F.length,D=T<p?new Array(p-T+1).join(t):"";switch(b&&g&&(e=r(D+e,D.length?p-F.length:1/0),D=""),n){case"<":e=s+e+F+D;break;case"=":e=s+D+e+F;break;case"^":e=D.slice(0,T=D.length>>1)+s+e+F+D.slice(T);break;default:e=D+s+e+F}return l(e)}return h=void 0===h?6:/[gprs]/.test(m)?Math.max(1,Math.min(21,h)):Math.max(0,Math.min(20,h)),F.toString=function(){return e+""},F}return{format:f,formatPrefix:function(e,t){var n=f(((e=De(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(xe(t)/3))),o=Math.pow(10,-r),a=He[8+r/3];return function(e){return n(o*e)+a}}}}({thousands:",",grouping:[3],currency:["$",""]}),Ie=Pe.format,Se=Pe.formatPrefix;function Ne(e,t,n,r){var o,a=h(e,t,n);switch((r=De(null==r?",f":r)).type){case"s":var i=Math.max(Math.abs(e),Math.abs(t));return null!=r.precision||isNaN(o=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(xe(t)/3)))-xe(Math.abs(e)))}(a,i))||(r.precision=o),Se(r,i);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(o=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,xe(t)-xe(e))+1}(a,Math.max(Math.abs(e),Math.abs(t))))||(r.precision=o-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(o=function(e){return Math.max(0,-xe(Math.abs(e)))}(a))||(r.precision=o-2*("%"===r.type))}return Ie(r)}function Ue(e){var t=e.domain;return e.ticks=function(e){var n=t();return p(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){var r=t();return Ne(r[0],r[r.length-1],null==e?10:e,n)},e.nice=function(n){null==n&&(n=10);var r,o,a=t(),i=0,l=a.length-1,c=a[i],d=a[l],u=10;for(d<c&&(o=c,c=d,d=o,o=i,i=l,l=o);u-- >0;){if((o=b(c,d,n))===r)return a[i]=c,a[l]=d,t(a);if(o>0)c=Math.floor(c/o)*o,d=Math.ceil(d/o)*o;else{if(!(o<0))break;c=Math.ceil(c*o)/o,d=Math.floor(d*o)/o}r=o}return e},e}function Ge(){var e=ye();return e.copy=function(){return Be(e,Ge())},o.apply(e,arguments),Ue(e)}function Ve(e){var t;function n(e){return isNaN(e=+e)?t:e}return n.invert=n,n.domain=n.range=function(t){return arguments.length?(e=Array.from(t,he),n):e.slice()},n.unknown=function(e){return arguments.length?(t=e,n):t},n.copy=function(){return Ve(e).unknown(t)},e=arguments.length?Array.from(e,he):[0,1],Ue(n)}function Ye(e,t){var n,r=0,o=(e=e.slice()).length-1,a=e[r],i=e[o];return i<a&&(n=r,r=o,o=n,n=a,a=i,i=n),e[r]=t.floor(a),e[o]=t.ceil(i),e}function ze(e){return Math.log(e)}function je(e){return Math.exp(e)}function We(e){return-Math.log(-e)}function qe(e){return-Math.exp(-e)}function Xe(e){return isFinite(e)?+("1e"+e):e<0?0:e}function Ke(e){return function(t){return-e(-t)}}function Ze(e){var t,n,r=e(ze,je),o=r.domain,a=10;function i(){return t=function(e){return e===Math.E?Math.log:10===e&&Math.log10||2===e&&Math.log2||(e=Math.log(e),function(t){return Math.log(t)/e})}(a),n=function(e){return 10===e?Xe:e===Math.E?Math.exp:function(t){return Math.pow(e,t)}}(a),o()[0]<0?(t=Ke(t),n=Ke(n),e(We,qe)):e(ze,je),r}return r.base=function(e){return arguments.length?(a=+e,i()):a},r.domain=function(e){return arguments.length?(o(e),i()):o()},r.ticks=function(e){var r,i=o(),l=i[0],c=i[i.length-1];(r=c<l)&&(s=l,l=c,c=s);var d,u,f,s=t(l),g=t(c),b=null==e?10:+e,h=[];if(!(a%1)&&g-s<b){if(s=Math.floor(s),g=Math.ceil(g),l>0){for(;s<=g;++s)for(u=1,d=n(s);u<a;++u)if(!((f=d*u)<l)){if(f>c)break;h.push(f)}}else for(;s<=g;++s)for(u=a-1,d=n(s);u>=1;--u)if(!((f=d*u)<l)){if(f>c)break;h.push(f)}2*h.length<b&&(h=p(l,c,b))}else h=p(s,g,Math.min(g-s,b)).map(n);return r?h.reverse():h},r.tickFormat=function(e,o){if(null==o&&(o=10===a?".0e":","),"function"!=typeof o&&(o=Ie(o)),e===1/0)return o;null==e&&(e=10);var i=Math.max(1,a*e/r.ticks().length);return function(e){var r=e/n(Math.round(t(e)));return r*a<a-.5&&(r*=a),r<=i?o(e):""}},r.nice=function(){return o(Ye(o(),{floor:function(e){return n(Math.floor(t(e)))},ceil:function(e){return n(Math.ceil(t(e)))}}))},r}function Qe(){var e=Ze(Fe()).domain([1,10]);return e.copy=function(){return Be(e,Qe()).base(e.base())},o.apply(e,arguments),e}function $e(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function Je(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function et(e){var t=1,n=e($e(t),Je(t));return n.constant=function(n){return arguments.length?e($e(t=+n),Je(t)):t},Ue(n)}function tt(){var e=et(Fe());return e.copy=function(){return Be(e,tt()).constant(e.constant())},o.apply(e,arguments)}function nt(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function rt(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function ot(e){return e<0?-e*e:e*e}function at(e){var t=e(me,me),n=1;function r(){return 1===n?e(me,me):.5===n?e(rt,ot):e(nt(n),nt(1/n))}return t.exponent=function(e){return arguments.length?(n=+e,r()):n},Ue(t)}function it(){var e=at(Fe());return e.copy=function(){return Be(e,it()).exponent(e.exponent())},o.apply(e,arguments),e}function lt(){return it.apply(null,arguments).exponent(.5)}function ct(e){return Math.sign(e)*e*e}function dt(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function ut(){var e,t=ye(),n=[0,1],r=!1;function a(n){var o=dt(t(n));return isNaN(o)?e:r?Math.round(o):o}return a.invert=function(e){return t.invert(ct(e))},a.domain=function(e){return arguments.length?(t.domain(e),a):t.domain()},a.range=function(e){return arguments.length?(t.range((n=Array.from(e,he)).map(ct)),a):n.slice()},a.rangeRound=function(e){return a.range(e).round(!0)},a.round=function(e){return arguments.length?(r=!!e,a):r},a.clamp=function(e){return arguments.length?(t.clamp(e),a):t.clamp()},a.unknown=function(t){return arguments.length?(e=t,a):e},a.copy=function(){return ut(t.domain(),n).round(r).clamp(t.clamp()).unknown(e)},o.apply(a,arguments),Ue(a)}function ft(e,t){let n;if(void 0===t)for(const t of e)null!=t&&(n<t||void 0===n&&t>=t)&&(n=t);else{let r=-1;for(let o of e)null!=(o=t(o,++r,e))&&(n<o||void 0===n&&o>=o)&&(n=o)}return n}function st(e,t){let n;if(void 0===t)for(const t of e)null!=t&&(n>t||void 0===n&&t>=t)&&(n=t);else{let r=-1;for(let o of e)null!=(o=t(o,++r,e))&&(n>o||void 0===n&&o>=o)&&(n=o)}return n}function gt(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function pt(e,t,n){if(r=(e=Float64Array.from(function*(e,t){if(void 0===t)for(let t of e)null!=t&&(t=+t)>=t&&(yield t);else{let n=-1;for(let r of e)null!=(r=t(r,++n,e))&&(r=+r)>=r&&(yield r)}}(e,n))).length){if((t=+t)<=0||r<2)return st(e);if(t>=1)return ft(e);var r,o=(r-1)*t,a=Math.floor(o),i=ft(function e(t,n,r=0,o=t.length-1,a=E){for(;o>r;){if(o-r>600){const i=o-r+1,l=n-r+1,c=Math.log(i),d=.5*Math.exp(2*c/3),u=.5*Math.sqrt(c*d*(i-d)/i)*(l-i/2<0?-1:1);e(t,n,Math.max(r,Math.floor(n-l*d/i+u)),Math.min(o,Math.floor(n+(i-l)*d/i+u)),a)}const i=t[n];let l=r,c=o;for(gt(t,r,n),a(t[o],i)>0&&gt(t,r,o);l<c;){for(gt(t,l,c),++l,--c;a(t[l],i)<0;)++l;for(;a(t[c],i)>0;)--c}0===a(t[r],i)?gt(t,r,c):(++c,gt(t,c,o)),c<=n&&(r=c+1),n<=c&&(o=c-1)}return t}(e,a).subarray(0,a+1));return i+(st(e.subarray(a+1))-i)*(o-a)}}function bt(e,t,n=_){if(r=e.length){if((t=+t)<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,o=(r-1)*t,a=Math.floor(o),i=+n(e[a],a,e);return i+(+n(e[a+1],a+1,e)-i)*(o-a)}}function ht(){var e,t=[],n=[],r=[];function a(){var e=0,o=Math.max(1,n.length);for(r=new Array(o-1);++e<o;)r[e-1]=bt(t,e/o);return i}function i(t){return isNaN(t=+t)?e:n[B(r,t)]}return i.invertExtent=function(e){var o=n.indexOf(e);return o<0?[NaN,NaN]:[o>0?r[o-1]:t[0],o<r.length?r[o]:t[t.length-1]]},i.domain=function(e){if(!arguments.length)return t.slice();t=[];for(let n of e)null==n||isNaN(n=+n)||t.push(n);return t.sort(E),a()},i.range=function(e){return arguments.length?(n=Array.from(e),a()):n.slice()},i.unknown=function(t){return arguments.length?(e=t,i):e},i.quantiles=function(){return r.slice()},i.copy=function(){return ht().domain(t).range(n).unknown(e)},o.apply(i,arguments)}function Et(){var e,t=0,n=1,r=1,a=[.5],i=[0,1];function l(t){return t<=t?i[B(a,t,0,r)]:e}function c(){var e=-1;for(a=new Array(r);++e<r;)a[e]=((e+1)*n-(e-r)*t)/(r+1);return l}return l.domain=function(e){return arguments.length?([t,n]=e,t=+t,n=+n,c()):[t,n]},l.range=function(e){return arguments.length?(r=(i=Array.from(e)).length-1,c()):i.slice()},l.invertExtent=function(e){var o=i.indexOf(e);return o<0?[NaN,NaN]:o<1?[t,a[0]]:o>=r?[a[r-1],n]:[a[o-1],a[o]]},l.unknown=function(t){return arguments.length?(e=t,l):l},l.thresholds=function(){return a.slice()},l.copy=function(){return Et().domain([t,n]).range(i).unknown(e)},o.apply(Ue(l),arguments)}function mt(){var e,t=[.5],n=[0,1],r=1;function a(o){return o<=o?n[B(t,o,0,r)]:e}return a.domain=function(e){return arguments.length?(t=Array.from(e),r=Math.min(t.length,n.length-1),a):t.slice()},a.range=function(e){return arguments.length?(n=Array.from(e),r=Math.min(t.length,n.length-1),a):n.slice()},a.invertExtent=function(e){var r=n.indexOf(e);return[t[r-1],t[r]]},a.unknown=function(t){return arguments.length?(e=t,a):e},a.copy=function(){return mt().domain(t).range(n).unknown(e)},o.apply(a,arguments)}var _t=new Date,Ct=new Date;function At(e,t,n,r){function o(t){return e(t=0===arguments.length?new Date:new Date(+t)),t}return o.floor=function(t){return e(t=new Date(+t)),t},o.ceil=function(n){return e(n=new Date(n-1)),t(n,1),e(n),n},o.round=function(e){var t=o(e),n=o.ceil(e);return e-t<n-e?t:n},o.offset=function(e,n){return t(e=new Date(+e),null==n?1:Math.floor(n)),e},o.range=function(n,r,a){var i,l=[];if(n=o.ceil(n),a=null==a?1:Math.floor(a),!(n<r&&a>0))return l;do{l.push(i=new Date(+n)),t(n,a),e(n)}while(i<n&&n<r);return l},o.filter=function(n){return At((function(t){if(t>=t)for(;e(t),!n(t);)t.setTime(t-1)}),(function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););}))},n&&(o.count=function(t,r){return _t.setTime(+t),Ct.setTime(+r),e(_t),e(Ct),Math.floor(n(_t,Ct))},o.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?o.filter(r?function(t){return r(t)%e==0}:function(t){return o.count(0,t)%e==0}):o:null}),o}var Bt=At((function(e){e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,t){e.setFullYear(e.getFullYear()+t)}),(function(e,t){return t.getFullYear()-e.getFullYear()}),(function(e){return e.getFullYear()}));Bt.every=function(e){return isFinite(e=Math.floor(e))&&e>0?At((function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,n){t.setFullYear(t.getFullYear()+n*e)})):null};var Ft=Bt,yt=(Bt.range,At((function(e){e.setDate(1),e.setHours(0,0,0,0)}),(function(e,t){e.setMonth(e.getMonth()+t)}),(function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())}),(function(e){return e.getMonth()}))),Tt=yt;yt.range;function Dt(e){return At((function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)}),(function(e,t){e.setDate(e.getDate()+7*t)}),(function(e,t){return(t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/6048e5}))}var vt=Dt(0),Lt=Dt(1),Ot=Dt(2),Pt=Dt(3),It=Dt(4),St=Dt(5),xt=Dt(6),wt=(vt.range,Lt.range,Ot.range,Pt.range,It.range,St.range,xt.range,At(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/864e5,e=>e.getDate()-1)),Mt=wt,Rt=(wt.range,At((function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds()-6e4*e.getMinutes())}),(function(e,t){e.setTime(+e+36e5*t)}),(function(e,t){return(t-e)/36e5}),(function(e){return e.getHours()}))),kt=Rt,Ht=(Rt.range,At((function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds())}),(function(e,t){e.setTime(+e+6e4*t)}),(function(e,t){return(t-e)/6e4}),(function(e){return e.getMinutes()}))),Nt=Ht,Ut=(Ht.range,At((function(e){e.setTime(e-e.getMilliseconds())}),(function(e,t){e.setTime(+e+1e3*t)}),(function(e,t){return(t-e)/1e3}),(function(e){return e.getUTCSeconds()}))),Gt=Ut,Vt=(Ut.range,At((function(){}),(function(e,t){e.setTime(+e+t)}),(function(e,t){return t-e})));Vt.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?At((function(t){t.setTime(Math.floor(t/e)*e)}),(function(t,n){t.setTime(+t+n*e)}),(function(t,n){return(n-t)/e})):Vt:null};var Yt=Vt;Vt.range;function zt(e){return At((function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+7*t)}),(function(e,t){return(t-e)/6048e5}))}var jt=zt(0),Wt=zt(1),qt=zt(2),Xt=zt(3),Kt=zt(4),Zt=zt(5),Qt=zt(6),$t=(jt.range,Wt.range,qt.range,Xt.range,Kt.range,Zt.range,Qt.range,At((function(e){e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+t)}),(function(e,t){return(t-e)/864e5}),(function(e){return e.getUTCDate()-1}))),Jt=$t,en=($t.range,At((function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)}),(function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}),(function(e){return e.getUTCFullYear()})));en.every=function(e){return isFinite(e=Math.floor(e))&&e>0?At((function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})):null};var tn=en;en.range;function nn(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function rn(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function on(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}var an,ln,cn,dn={"-":"",_:" ",0:"0"},un=/^\s*\d+/,fn=/^%/,sn=/[\\^$*+?|[\]().{}]/g;function gn(e,t,n){var r=e<0?"-":"",o=(r?-e:e)+"",a=o.length;return r+(a<n?new Array(n-a+1).join(t)+o:o)}function pn(e){return e.replace(sn,"\\$&")}function bn(e){return new RegExp("^(?:"+e.map(pn).join("|")+")","i")}function hn(e){return new Map(e.map((e,t)=>[e.toLowerCase(),t]))}function En(e,t,n){var r=un.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function mn(e,t,n){var r=un.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function _n(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function Cn(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function An(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function Bn(e,t,n){var r=un.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function Fn(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function yn(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Tn(e,t,n){var r=un.exec(t.slice(n,n+1));return r?(e.q=3*r[0]-3,n+r[0].length):-1}function Dn(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function vn(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Ln(e,t,n){var r=un.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function On(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function Pn(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function In(e,t,n){var r=un.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Sn(e,t,n){var r=un.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function xn(e,t,n){var r=un.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function wn(e,t,n){var r=fn.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Mn(e,t,n){var r=un.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function Rn(e,t,n){var r=un.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function kn(e,t){return gn(e.getDate(),t,2)}function Hn(e,t){return gn(e.getHours(),t,2)}function Nn(e,t){return gn(e.getHours()%12||12,t,2)}function Un(e,t){return gn(1+Mt.count(Ft(e),e),t,3)}function Gn(e,t){return gn(e.getMilliseconds(),t,3)}function Vn(e,t){return Gn(e,t)+"000"}function Yn(e,t){return gn(e.getMonth()+1,t,2)}function zn(e,t){return gn(e.getMinutes(),t,2)}function jn(e,t){return gn(e.getSeconds(),t,2)}function Wn(e){var t=e.getDay();return 0===t?7:t}function qn(e,t){return gn(vt.count(Ft(e)-1,e),t,2)}function Xn(e){var t=e.getDay();return t>=4||0===t?It(e):It.ceil(e)}function Kn(e,t){return e=Xn(e),gn(It.count(Ft(e),e)+(4===Ft(e).getDay()),t,2)}function Zn(e){return e.getDay()}function Qn(e,t){return gn(Lt.count(Ft(e)-1,e),t,2)}function $n(e,t){return gn(e.getFullYear()%100,t,2)}function Jn(e,t){return gn((e=Xn(e)).getFullYear()%100,t,2)}function er(e,t){return gn(e.getFullYear()%1e4,t,4)}function tr(e,t){var n=e.getDay();return gn((e=n>=4||0===n?It(e):It.ceil(e)).getFullYear()%1e4,t,4)}function nr(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+gn(t/60|0,"0",2)+gn(t%60,"0",2)}function rr(e,t){return gn(e.getUTCDate(),t,2)}function or(e,t){return gn(e.getUTCHours(),t,2)}function ar(e,t){return gn(e.getUTCHours()%12||12,t,2)}function ir(e,t){return gn(1+Jt.count(tn(e),e),t,3)}function lr(e,t){return gn(e.getUTCMilliseconds(),t,3)}function cr(e,t){return lr(e,t)+"000"}function dr(e,t){return gn(e.getUTCMonth()+1,t,2)}function ur(e,t){return gn(e.getUTCMinutes(),t,2)}function fr(e,t){return gn(e.getUTCSeconds(),t,2)}function sr(e){var t=e.getUTCDay();return 0===t?7:t}function gr(e,t){return gn(jt.count(tn(e)-1,e),t,2)}function pr(e){var t=e.getUTCDay();return t>=4||0===t?Kt(e):Kt.ceil(e)}function br(e,t){return e=pr(e),gn(Kt.count(tn(e),e)+(4===tn(e).getUTCDay()),t,2)}function hr(e){return e.getUTCDay()}function Er(e,t){return gn(Wt.count(tn(e)-1,e),t,2)}function mr(e,t){return gn(e.getUTCFullYear()%100,t,2)}function _r(e,t){return gn((e=pr(e)).getUTCFullYear()%100,t,2)}function Cr(e,t){return gn(e.getUTCFullYear()%1e4,t,4)}function Ar(e,t){var n=e.getUTCDay();return gn((e=n>=4||0===n?Kt(e):Kt.ceil(e)).getUTCFullYear()%1e4,t,4)}function Br(){return"+0000"}function Fr(){return"%"}function yr(e){return+e}function Tr(e){return Math.floor(+e/1e3)}!function(e){an=function(e){var t=e.dateTime,n=e.date,r=e.time,o=e.periods,a=e.days,i=e.shortDays,l=e.months,c=e.shortMonths,d=bn(o),u=hn(o),f=bn(a),s=hn(a),g=bn(i),p=hn(i),b=bn(l),h=hn(l),E=bn(c),m=hn(c),_={a:function(e){return i[e.getDay()]},A:function(e){return a[e.getDay()]},b:function(e){return c[e.getMonth()]},B:function(e){return l[e.getMonth()]},c:null,d:kn,e:kn,f:Vn,g:Jn,G:tr,H:Hn,I:Nn,j:Un,L:Gn,m:Yn,M:zn,p:function(e){return o[+(e.getHours()>=12)]},q:function(e){return 1+~~(e.getMonth()/3)},Q:yr,s:Tr,S:jn,u:Wn,U:qn,V:Kn,w:Zn,W:Qn,x:null,X:null,y:$n,Y:er,Z:nr,"%":Fr},C={a:function(e){return i[e.getUTCDay()]},A:function(e){return a[e.getUTCDay()]},b:function(e){return c[e.getUTCMonth()]},B:function(e){return l[e.getUTCMonth()]},c:null,d:rr,e:rr,f:cr,g:_r,G:Ar,H:or,I:ar,j:ir,L:lr,m:dr,M:ur,p:function(e){return o[+(e.getUTCHours()>=12)]},q:function(e){return 1+~~(e.getUTCMonth()/3)},Q:yr,s:Tr,S:fr,u:sr,U:gr,V:br,w:hr,W:Er,x:null,X:null,y:mr,Y:Cr,Z:Br,"%":Fr},A={a:function(e,t,n){var r=g.exec(t.slice(n));return r?(e.w=p.get(r[0].toLowerCase()),n+r[0].length):-1},A:function(e,t,n){var r=f.exec(t.slice(n));return r?(e.w=s.get(r[0].toLowerCase()),n+r[0].length):-1},b:function(e,t,n){var r=E.exec(t.slice(n));return r?(e.m=m.get(r[0].toLowerCase()),n+r[0].length):-1},B:function(e,t,n){var r=b.exec(t.slice(n));return r?(e.m=h.get(r[0].toLowerCase()),n+r[0].length):-1},c:function(e,n,r){return y(e,t,n,r)},d:vn,e:vn,f:xn,g:Fn,G:Bn,H:On,I:On,j:Ln,L:Sn,m:Dn,M:Pn,p:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.p=u.get(r[0].toLowerCase()),n+r[0].length):-1},q:Tn,Q:Mn,s:Rn,S:In,u:mn,U:_n,V:Cn,w:En,W:An,x:function(e,t,r){return y(e,n,t,r)},X:function(e,t,n){return y(e,r,t,n)},y:Fn,Y:Bn,Z:yn,"%":wn};function B(e,t){return function(n){var r,o,a,i=[],l=-1,c=0,d=e.length;for(n instanceof Date||(n=new Date(+n));++l<d;)37===e.charCodeAt(l)&&(i.push(e.slice(c,l)),null!=(o=dn[r=e.charAt(++l)])?r=e.charAt(++l):o="e"===r?" ":"0",(a=t[r])&&(r=a(n,o)),i.push(r),c=l+1);return i.push(e.slice(c,l)),i.join("")}}function F(e,t){return function(n){var r,o,a=on(1900,void 0,1);if(y(a,e,n+="",0)!=n.length)return null;if("Q"in a)return new Date(a.Q);if("s"in a)return new Date(1e3*a.s+("L"in a?a.L:0));if(t&&!("Z"in a)&&(a.Z=0),"p"in a&&(a.H=a.H%12+12*a.p),void 0===a.m&&(a.m="q"in a?a.q:0),"V"in a){if(a.V<1||a.V>53)return null;"w"in a||(a.w=1),"Z"in a?(o=(r=rn(on(a.y,0,1))).getUTCDay(),r=o>4||0===o?Wt.ceil(r):Wt(r),r=Jt.offset(r,7*(a.V-1)),a.y=r.getUTCFullYear(),a.m=r.getUTCMonth(),a.d=r.getUTCDate()+(a.w+6)%7):(o=(r=nn(on(a.y,0,1))).getDay(),r=o>4||0===o?Lt.ceil(r):Lt(r),r=Mt.offset(r,7*(a.V-1)),a.y=r.getFullYear(),a.m=r.getMonth(),a.d=r.getDate()+(a.w+6)%7)}else("W"in a||"U"in a)&&("w"in a||(a.w="u"in a?a.u%7:"W"in a?1:0),o="Z"in a?rn(on(a.y,0,1)).getUTCDay():nn(on(a.y,0,1)).getDay(),a.m=0,a.d="W"in a?(a.w+6)%7+7*a.W-(o+5)%7:a.w+7*a.U-(o+6)%7);return"Z"in a?(a.H+=a.Z/100|0,a.M+=a.Z%100,rn(a)):nn(a)}}function y(e,t,n,r){for(var o,a,i=0,l=t.length,c=n.length;i<l;){if(r>=c)return-1;if(37===(o=t.charCodeAt(i++))){if(o=t.charAt(i++),!(a=A[o in dn?t.charAt(i++):o])||(r=a(e,n,r))<0)return-1}else if(o!=n.charCodeAt(r++))return-1}return r}return _.x=B(n,_),_.X=B(r,_),_.c=B(t,_),C.x=B(n,C),C.X=B(r,C),C.c=B(t,C),{format:function(e){var t=B(e+="",_);return t.toString=function(){return e},t},parse:function(e){var t=F(e+="",!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=B(e+="",C);return t.toString=function(){return e},t},utcParse:function(e){var t=F(e+="",!0);return t.toString=function(){return e},t}}}(e),ln=an.format,an.parse,cn=an.utcFormat,an.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Dr(e){return new Date(e)}function vr(e){return e instanceof Date?+e:+new Date(+e)}function Lr(e,t,n,r,o,a,i,l,c){var d=ye(),u=d.invert,f=d.domain,s=c(".%L"),g=c(":%S"),p=c("%I:%M"),b=c("%I %p"),E=c("%a %d"),_=c("%b %d"),C=c("%B"),A=c("%Y"),B=[[i,1,1e3],[i,5,5e3],[i,15,15e3],[i,30,3e4],[a,1,6e4],[a,5,3e5],[a,15,9e5],[a,30,18e5],[o,1,36e5],[o,3,108e5],[o,6,216e5],[o,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[t,1,2592e6],[t,3,7776e6],[e,1,31536e6]];function F(l){return(i(l)<l?s:a(l)<l?g:o(l)<l?p:r(l)<l?b:t(l)<l?n(l)<l?E:_:e(l)<l?C:A)(l)}function y(t,n,r){if(null==t&&(t=10),"number"==typeof t){var o,a=Math.abs(r-n)/t,i=m((function(e){return e[2]})).right(B,a);return i===B.length?(o=h(n/31536e6,r/31536e6,t),t=e):i?(o=(i=B[a/B[i-1][2]<B[i][2]/a?i-1:i])[1],t=i[0]):(o=Math.max(h(n,r,t),1),t=l),t.every(o)}return t}return d.invert=function(e){return new Date(u(e))},d.domain=function(e){return arguments.length?f(Array.from(e,vr)):f().map(Dr)},d.ticks=function(e){var t,n=f(),r=n[0],o=n[n.length-1],a=o<r;return a&&(t=r,r=o,o=t),t=(t=y(e,r,o))?t.range(r,o+1):[],a?t.reverse():t},d.tickFormat=function(e,t){return null==t?F:c(t)},d.nice=function(e){var t=f();return(e=y(e,t[0],t[t.length-1]))?f(Ye(t,e)):d},d.copy=function(){return Be(d,Lr(e,t,n,r,o,a,i,l,c))},d}function Or(){return o.apply(Lr(Ft,Tt,vt,Mt,kt,Nt,Gt,Yt,ln).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var Pr=At((function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCMonth(e.getUTCMonth()+t)}),(function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())}),(function(e){return e.getUTCMonth()})),Ir=Pr,Sr=(Pr.range,At((function(e){e.setUTCMinutes(0,0,0)}),(function(e,t){e.setTime(+e+36e5*t)}),(function(e,t){return(t-e)/36e5}),(function(e){return e.getUTCHours()}))),xr=Sr,wr=(Sr.range,At((function(e){e.setUTCSeconds(0,0)}),(function(e,t){e.setTime(+e+6e4*t)}),(function(e,t){return(t-e)/6e4}),(function(e){return e.getUTCMinutes()}))),Mr=wr;wr.range;function Rr(){return o.apply(Lr(tn,Ir,jt,Jt,xr,Mr,Gt,Yt,cn).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function kr(){var e,t,n,r,o,a=0,i=1,l=me,c=!1;function d(t){return isNaN(t=+t)?o:l(0===n?.5:(t=(r(t)-e)*n,c?Math.max(0,Math.min(1,t)):t))}function u(e){return function(t){var n,r;return arguments.length?([n,r]=t,l=e(n,r),d):[l(0),l(1)]}}return d.domain=function(o){return arguments.length?([a,i]=o,e=r(a=+a),t=r(i=+i),n=e===t?0:1/(t-e),d):[a,i]},d.clamp=function(e){return arguments.length?(c=!!e,d):c},d.interpolator=function(e){return arguments.length?(l=e,d):l},d.range=u(pe),d.rangeRound=u(be),d.unknown=function(e){return arguments.length?(o=e,d):o},function(o){return r=o,e=o(a),t=o(i),n=e===t?0:1/(t-e),d}}function Hr(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function Nr(){var e=Ue(kr()(me));return e.copy=function(){return Hr(e,Nr())},a.apply(e,arguments)}function Ur(){var e=Ze(kr()).domain([1,10]);return e.copy=function(){return Hr(e,Ur()).base(e.base())},a.apply(e,arguments)}function Gr(){var e=et(kr());return e.copy=function(){return Hr(e,Gr()).constant(e.constant())},a.apply(e,arguments)}function Vr(){var e=at(kr());return e.copy=function(){return Hr(e,Vr()).exponent(e.exponent())},a.apply(e,arguments)}function Yr(){return Vr.apply(null,arguments).exponent(.5)}function zr(){var e=[],t=me;function n(n){if(!isNaN(n=+n))return t((B(e,n,1)-1)/(e.length-1))}return n.domain=function(t){if(!arguments.length)return e.slice();e=[];for(let n of t)null==n||isNaN(n=+n)||e.push(n);return e.sort(E),n},n.interpolator=function(e){return arguments.length?(t=e,n):t},n.range=function(){return e.map((n,r)=>t(r/(e.length-1)))},n.quantiles=function(t){return Array.from({length:t+1},(n,r)=>pt(e,r/t))},n.copy=function(){return zr(t).domain(e)},a.apply(n,arguments)}function jr(e,t){void 0===t&&(t=e,e=pe);for(var n=0,r=t.length-1,o=t[0],a=new Array(r<0?0:r);n<r;)a[n]=e(o,o=t[++n]);return function(e){var t=Math.max(0,Math.min(r-1,Math.floor(e*=r)));return a[t](e-t)}}function Wr(){var e,t,n,r,o,a,i,l=0,c=.5,d=1,u=1,f=me,s=!1;function g(e){return isNaN(e=+e)?i:(e=.5+((e=+a(e))-t)*(u*e<u*t?r:o),f(s?Math.max(0,Math.min(1,e)):e))}function p(e){return function(t){var n,r,o;return arguments.length?([n,r,o]=t,f=jr(e,[n,r,o]),g):[f(0),f(.5),f(1)]}}return g.domain=function(i){return arguments.length?([l,c,d]=i,e=a(l=+l),t=a(c=+c),n=a(d=+d),r=e===t?0:.5/(t-e),o=t===n?0:.5/(n-t),u=t<e?-1:1,g):[l,c,d]},g.clamp=function(e){return arguments.length?(s=!!e,g):s},g.interpolator=function(e){return arguments.length?(f=e,g):f},g.range=p(pe),g.rangeRound=p(be),g.unknown=function(e){return arguments.length?(i=e,g):i},function(i){return a=i,e=i(l),t=i(c),n=i(d),r=e===t?0:.5/(t-e),o=t===n?0:.5/(n-t),u=t<e?-1:1,g}}function qr(){var e=Ue(Wr()(me));return e.copy=function(){return Hr(e,qr())},a.apply(e,arguments)}function Xr(){var e=Ze(Wr()).domain([.1,1,10]);return e.copy=function(){return Hr(e,Xr()).base(e.base())},a.apply(e,arguments)}function Kr(){var e=et(Wr());return e.copy=function(){return Hr(e,Kr()).constant(e.constant())},a.apply(e,arguments)}function Zr(){var e=at(Wr());return e.copy=function(){return Hr(e,Zr()).exponent(e.exponent())},a.apply(e,arguments)}function Qr(){return Zr.apply(null,arguments).exponent(.5)}},function(e,t,n){"use strict";n.r(t),n.d(t,"createSnapModifier",(function(){return c})),n.d(t,"restrictToFirstScrollableAncestor",(function(){return s})),n.d(t,"restrictToHorizontalAxis",(function(){return d})),n.d(t,"restrictToParentElement",(function(){return f})),n.d(t,"restrictToVerticalAxis",(function(){return g})),n.d(t,"restrictToWindowEdges",(function(){return p})),n.d(t,"snapCenterToCursor",(function(){return b}));var r=n(0);function o(e){const t=Object.prototype.toString.call(e);return"[object Window]"===t||"[object global]"===t}function a(e){return"nodeType"in e}function i(e){var t,n;return e?o(e)?e:a(e)&&null!=(t=null==(n=e.ownerDocument)?void 0:n.defaultView)?t:window:window}"undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?r.useLayoutEffect:r.useEffect;function l(e){if(function(e){if(!e)return!1;const{TouchEvent:t}=i(e.target);return t&&e instanceof t}(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return function(e){return"clientX"in e&&"clientY"in e}(e)?{x:e.clientX,y:e.clientY}:null}function c(e){return t=>{let{transform:n}=t;return{...n,x:Math.ceil(n.x/e)*e,y:Math.ceil(n.y/e)*e}}}const d=e=>{let{transform:t}=e;return{...t,y:0}};function u(e,t,n){const r={...e};return t.top+e.y<=n.top?r.y=n.top-t.top:t.bottom+e.y>=n.top+n.height&&(r.y=n.top+n.height-t.bottom),t.left+e.x<=n.left?r.x=n.left-t.left:t.right+e.x>=n.left+n.width&&(r.x=n.left+n.width-t.right),r}const f=e=>{let{containerNodeRect:t,draggingNodeRect:n,transform:r}=e;return n&&t?u(r,n,t):r},s=e=>{let{draggingNodeRect:t,transform:n,scrollableAncestorRects:r}=e;const o=r[0];return t&&o?u(n,t,o):n},g=e=>{let{transform:t}=e;return{...t,x:0}},p=e=>{let{transform:t,draggingNodeRect:n,windowRect:r}=e;return n&&r?u(t,n,r):t},b=e=>{let{activatorEvent:t,draggingNodeRect:n,transform:r}=e;if(n&&t){const e=l(t);if(!e)return r;const o=e.x-n.left,a=e.y-n.top;return{...r,x:r.x+o-n.width/2,y:r.y+a-n.height/2}}return r}}])}));