azure-maps-control 3.6.0 → 3.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/atlas-core-bare-snr-min.js +1 -1
- package/dist/atlas-core-bare-snr.js +4 -6
- package/dist/atlas-core-bare.js +4 -6
- package/dist/atlas-core-bare.min.js +1 -1
- package/dist/atlas-core-snr.js +4 -6
- package/dist/atlas-core.js +4 -6
- package/dist/atlas-core.min.js +1 -1
- package/dist/atlas-esm.js +4 -6
- package/dist/atlas-esm.min.js +1 -1
- package/dist/atlas.js +4 -6
- package/dist/atlas.min.js +1 -1
- package/package.json +1 -1
|
@@ -52,4 +52,4 @@ Elle s’applique également, même si Microsoft connaissait ou devrait connaît
|
|
|
52
52
|
EFFET JURIDIQUE. Le présent contrat décrit certains droits juridiques. Vous pourriez avoir d’autres droits prévus par les lois de votre pays. Le présent contrat ne modifie pas les droits que vous confèrent les lois de votre pays si celles-ci ne le permettent pas.
|
|
53
53
|
*/
|
|
54
54
|
|
|
55
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("azuremaps-maplibre-gl")):"function"==typeof define&&define.amd?define(["exports","azuremaps-maplibre-gl"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).atlas=t.atlas||{},t.maplibregl)}(this,function(u,D){"use strict";var R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function B(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function F(o){var e,n;return o.__esModule?o:("function"==typeof(e=o.default)?(n=function t(){return this instanceof t?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)}).prototype=e.prototype:n={},Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(o).forEach(function(t){var e=Object.getOwnPropertyDescriptor(o,t);Object.defineProperty(n,t,e.get?e:{enumerable:!0,get:function(){return o[t]}})}),n)}for(var N,Z,q={exports:{}},H=F(Object.freeze({__proto__:null,default:{}})),U=q,W=0,G=[],V=0;V<256;V++)G[V]=(V+256).toString(16).substr(1);function K(){t=16,(!N||Y.BUFFER_SIZE<W+t)&&(W=0,N=Y.randomBytes(Y.BUFFER_SIZE));var t=N.slice(W,W+=t);return t[6]=15&t[6]|64,t[8]=63&t[8]|128,t}function Y(){var t=K();return G[t[0]]+G[t[1]]+G[t[2]]+G[t[3]]+"-"+G[t[4]]+G[t[5]]+"-"+G[t[6]]+G[t[7]]+"-"+G[t[8]]+G[t[9]]+"-"+G[t[10]]+G[t[11]]+G[t[12]]+G[t[13]]+G[t[14]]+G[t[15]]}Y.BUFFER_SIZE=4096,Y.bin=K,Y.clearBuffer=function(){N=null,W=0},Y.test=function(t){return"string"==typeof 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)},"undefined"!=typeof crypto?Z=crypto:"undefined"!=typeof window&&void 0!==window.msCrypto&&(Z=window.msCrypto),Z=Z||H,(U.exports=Y).randomBytes=function(){if(Z){if(Z.randomBytes)return Z.randomBytes;if(Z.getRandomValues)return"function"!=typeof Uint8Array.prototype.slice?function(t){t=new Uint8Array(t);return Z.getRandomValues(t),Array.from(t)}:function(t){t=new Uint8Array(t);return Z.getRandomValues(t),t}}return function(t){for(var e=[],o=0;o<t;o++)e.push(Math.floor(256*Math.random()));return e}}();var J=B(q.exports),$="atlas.microsoft.com",X="atlas.microsoft.com",H="styling",U="2023-01-01",Q="api-version",tt="Authorization",et="{{azMapsDomain}}",ot="{azMapsDomain}",nt="{{azMapsView}}",rt="view",it="{{azMapsLanguage}}",st="{{azMapsStylingPath}}",at="{{azMapsStylePath}}",ct="styling",lt="styles",q="2.0",ut="x-ms-client-id",pt=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},t=(ht.prototype.merge=function(){for(var e,t,o,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];try{for(var i=pt(n),s=i.next();!s.done;s=i.next()){var a=s.value;if(a)for(var c in a)a.hasOwnProperty(c)&&this.hasOwnProperty(c)&&(void 0!==a[c]&&null!=a[c]?this[c]instanceof ht?this[c].merge(a[c]):this[c]=a[c]:(o=o||new(Object.getPrototypeOf(this).constructor),this[c]=o[c]))}}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}return this},ht);function ht(){}var dt,ft,yt=window&&window.__extends||(dt=function(t,e){return(dt=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}dt(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),mt=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},gt=(yt(vt,ft=t),vt);function vt(){var t=null!==ft&&ft.apply(this,arguments)||this;return t.domain=void 0,t.headers={},t.path="",t.protocol="https",t.queryParams={},t.subdomain="",t}_t.prototype.get=function(){return fetch(this.toString(),{method:"GET",mode:"cors",headers:new Headers(this.options.headers)}).then(function(t){if(t.ok)return t.json();throw new Error("HTTP ".concat(t.status,": ").concat(t.statusText))})},_t.prototype.toString=function(){var t=this,e=Object.entries(t.options.queryParams).map(function(t){var t=mt(t,2),e=t[0],t=t[1];return"".concat(e,"=").concat(t)}).join("&"),o=[],n=t.options.path||"";return _t.protoRegEx.test(n)?o.push(n):(t.options.domain&&(_t.protoRegEx.test(t.options.domain)||(o.push("".concat(t.options.protocol,"://")),o.push(t.options.subdomain?"".concat(t.options.subdomain,"."):"")),o.push(t.options.domain)),o.push(t.options.path?"/".concat(n):"")),o.push(e?"?".concat(e):""),o.join("")},_t.protoRegEx=new RegExp(/^(((file|http|https):\/\/)|blob:)/i);var wt=_t;function _t(t){this.options=(new gt).merge(t)}xt.parse=function(t){var e=(t=t.toLowerCase()).lastIndexOf("-");return-1!==e?{code:t,language:t.substring(0,e),region:t.substring(e+1)}:{code:t,language:t}};var bt=xt;function xt(){}var Ot={localizationsPath:"locs/mapcontrol/2019-3-12",sensitiveUserRegions:["il","kr","pk","in","cn","ar","bh","eg","jo","sa","kw","om","qa","ma","ae"],locales:{defaultLanguage:{defaultRegion:{code:"NGT",strings:"en/resource.json"},latn:{code:"NGT-Latn",strings:"en/resource.json"}},ar:{defaultRegion:{code:"ar",strings:"ar-sa/resource.json"}},bg:{defaultRegion:{code:"bg-BG",strings:"bg-bg/resource.json"}},cs:{defaultRegion:{code:"cs-CZ",strings:"cs-cz/resource.json"}},da:{defaultRegion:{code:"da-DK",strings:"da-dk/resource.json"}},de:{defaultRegion:{code:"de-DE",strings:"de-de/resource.json"}},el:{defaultRegion:{code:"el-GR",strings:"el-gr/resource.json"}},en:{defaultRegion:{code:"en",strings:"en/resource.json"},us:{code:"en-US",strings:"en/resource.json"},au:{code:"en-AU",strings:"en/resource.json"},gb:{code:"en-GB",strings:"en/resource.json"},nz:{code:"en-NZ",strings:"en/resource.json"}},es:{defaultRegion:{code:"es-ES",strings:"es-es/resource.json"},mx:{code:"es-MX",strings:"es-mx/resource.json"}},fi:{defaultRegion:{code:"fi-FI",strings:"fi-fi/resource.json"}},fr:{defaultRegion:{code:"fr-FR",strings:"fr-fr/resource.json"}},hu:{defaultRegion:{code:"hu-HU",strings:"hu-hu/resource.json"}},id:{defaultRegion:{code:"id-ID",strings:"id-id/resource.json"}},it:{defaultRegion:{code:"it-IT",strings:"it-it/resource.json"}},ko:{defaultRegion:{code:"ko-KR",strings:"ko-kr/resource.json"}},lt:{defaultRegion:{code:"lt-LT",strings:"lt-lt/resource.json"}},ms:{defaultRegion:{code:"ms-MY",strings:"ms-my/resource.json"}},nb:{defaultRegion:{code:"nb-NO",strings:"nb-no/resource.json"}},nl:{defaultRegion:{code:"nl-NL",strings:"nl-nl/resource.json"}},pl:{defaultRegion:{code:"pl-PL",strings:"pl-pl/resource.json"}},pt:{defaultRegion:{code:"pt-PT",strings:"pt-pt/resource.json"},br:{code:"pt-BR",strings:"pt-br/resource.json"}},ru:{defaultRegion:{code:"ru-RU",strings:"ru-ru/resource.json"}},sk:{defaultRegion:{code:"sk-SK",strings:"sk-sk/resource.json"}},sl:{defaultRegion:{code:"sl-SL",strings:"sl-sl/resource.json"}},sv:{defaultRegion:{code:"sv-SE",strings:"sv-se/resource.json"}},th:{defaultRegion:{code:"th-TH",strings:"th-th/resource.json"}},tr:{defaultRegion:{code:"tr-TR",strings:"tr-tr/resource.json"}},zh:{defaultRegion:{code:"zh",strings:"en/resource.json"}},"zh-hans":{defaultRegion:{code:"zh-Hans",strings:"zh-cn/resource.json"},cn:{code:"zh-Hans-CN",strings:"zh-cn/resource.json"}},"zh-hant":{defaultRegion:{code:"zh-Hant",strings:"en/resource.json"},tw:{code:"zh-Hant-TW",strings:"zh-tw/resource.json"}}}},St=function(){this.Unknown="Unknown",this.Accident="Accident",this.Fog="Fog",this.Danger="Danger",this.Rain="Rain",this.Ice="Ice",this.Jam="Jam",this.LaneClosed="Lane Closed",this.RoadClosed="Road Closed",this.RoadWorks="Road Works",this.Wind="Wind",this.Flood="Flood",this.Detour="Detour"},Ct=(Pt.getCode=function(t){0===t.localeCompare("auto",void 0,{sensitivity:"base"})&&(t=navigator.language);var e=bt.parse(t);return-1===Ot.sensitiveUserRegions.indexOf(e.region)?this.getLocaleData(e).code:t},Pt.getStrings=function(t){t=this.getLocaleData(t);return Ot.locales.defaultLanguage.defaultRegion.code===t.code?new Promise(function(t){t(new St)}):new wt({domain:X,path:"".concat(Ot.localizationsPath,"/").concat(t.strings)}).get().then(function(t){return t},function(){return new St})},Pt.getLocaleData=function(t){if("string"==typeof t&&(t=bt.parse(t)),Ot.locales[t.code])return Ot.locales[t.code].defaultRegion;var e;if(Ot.locales[t.language])e=Ot.locales[t.language];else{if(-1!==t.language.indexOf("-"))return this.getLocaleData(t.language);e=Ot.locales.defaultLanguage}return t.region&&e[t.region]?e[t.region]:e.defaultRegion},Pt);function Pt(){}kt.getEdgeOrIEVersion=function(){var t=window.navigator.userAgent,e=t.indexOf("MSIE ");return 0<e?parseInt(t.substring(e+5,t.indexOf(".",e)),10):0<t.indexOf("Trident/")?(e=t.indexOf("rv:"),parseInt(t.substring(e+3,t.indexOf(".",e)),10)):0<(e=t.indexOf("Edge/"))?parseInt(t.substring(e+5,t.indexOf(".",e)),10):-1},kt.isEdgeOrIE=function(){return-1!==this.getEdgeOrIEVersion()},kt.isIE=function(){var t=this.getEdgeOrIEVersion();return-1!==t&&t<=11};var Lt=kt;function kt(){}var At="3.6.0",Mt=(Et.getFullVersion=function(){return At},Et.getEndpointVersion=function(){var t=At.indexOf(".");return-1===(t=At.indexOf(".",t+1))?At:At.substring(0,t)},Et);function Et(){}var jt,It,yt=window&&window.__extends||(jt=function(t,e){return(jt=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}jt(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Tt=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},zt=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Dt=(u.AuthenticationType=void 0,(ze=u.AuthenticationType||(u.AuthenticationType={})).subscriptionKey="subscriptionKey",ze.aad="aad",ze.anonymous="anonymous",ze.sas="sas",yt(Rt,It=t),Rt.prototype.setSubscriptionKey=function(t){this.authType=u.AuthenticationType.subscriptionKey,this.subscriptionKey=t},Rt.prototype.setAadProperties=function(t,e,o,n,r){this.authType=u.AuthenticationType.aad,this.authContext=r||this.authContext,this.aadInstance=n||this.aadInstance,this.clientId=t,this.aadAppId=e,this.aadTenant=o},Rt.prototype.setTokenCallbackFunction=function(t){this.authType=u.AuthenticationType.anonymous,this.getToken=t},Rt.prototype.setSasCallbackFunction=function(t){this.authType=u.AuthenticationType.sas,this.getToken=t},Rt.prototype.merge=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var o=It.prototype.merge.apply(this,zt([],Tt(t),!1));return o.authType===u.AuthenticationType.subscriptionKey?o.authContext=o.aadAppId=o.getToken=void 0:o.authType===u.AuthenticationType.aad?o.subscriptionKey=o.getToken=void 0:o.authType===u.AuthenticationType.anonymous?o.subscriptionKey=o.authContext=o.aadAppId=void 0:o.authType===u.AuthenticationType.sas&&(o.authContext=o.subscriptionKey=o.aadAppId=void 0),o},Rt);function Rt(){var t=null!==It&&It.apply(this,arguments)||this;return t.authType=void 0,t.subscriptionKey=void 0,t.clientId=void 0,t.aadAppId=void 0,t.aadTenant=void 0,t.aadInstance=void 0,t.getToken=void 0,t.sasToken=void 0,t.authContext=void 0,t}var Bt;var Ft="NGT",Nt=J(),Zt=$,qt=X,Ht=H,Ut=U,Wt=q,Gt=new Dt,Vt=!1,Kt=!1,Yt=!1,Jt=!1,$t=!1,Xt=!1,Qt=!1,te=!1,ee=!1;function oe(){return Object.assign({},Gt)}function ne(){return qt}function re(){return Zt}function ie(){return Ht}function se(){return Ut}function ae(){return Wt}function ce(){return D.getWorkerCount()}function le(){return D.getMaxParallelImageRequests()}function ue(){return Ft}function pe(){return Nt}function he(){return Gt.authType===u.AuthenticationType.subscriptionKey?Gt.subscriptionKey:void 0}function de(){return Bt}function fe(t){Gt=(new Dt).merge(Gt,t),ee=!0}function ye(t){Zt=t,Kt=!0}function me(t){Ht=t,Yt=!0}function ge(t){0<t&&(D.setWorkerCount(t),$t=!0)}function ve(t){0<t&&(D.setMaxParallelImageRequests(t),Xt=!0)}function we(t){Ft=Ct.getCode(t),Qt=!0}function _e(t){Nt=t,te=!0}function be(t){Gt.setSubscriptionKey(t),ee=!0}function xe(t){Bt=t,Vt=!0}function Oe(t,e){if(e=Math.abs(e||1),"string"==typeof t&&Te[t.toLowerCase()]){for(var o=Te[t.toLowerCase()],n=/calc\(([0-9.]+)[px]*\s*\*\s*\{scale\}\)/gi,r=o,i=n.exec(o);i;)r=r.replace(i[0],parseFloat(i[1])*e+""),i=n.exec(o);return r=r.replace("{scale}",e+"")}throw new Error("Invalid templateName.")}function Se(){return ee}function Ce(){return Kt}function Pe(){return Yt}function Le(){return $t}function ke(){return Xt}function Ae(){return Qt}function Me(){return te}function Ee(){return Vt}function _(t){var e=document.createElement("span");return e.innerText=t,e.classList.add("tooltiptext"),-1!=navigator.userAgent.indexOf("Edg")?e.classList.add("edge"):-1!=navigator.userAgent.indexOf("Chrome")?e.classList.add("chrome"):-1!=navigator.userAgent.indexOf("Safari")?e.classList.add("safari"):-1!=navigator.userAgent.indexOf("Firefox")&&e.classList.add("firefox"),-1!=navigator.userAgent.indexOf("Windows")?e.classList.add("win"):-1!=navigator.userAgent.indexOf("Macintosh")&&e.classList.add("mac"),e}function b(r,i,s){function t(t){var e=i.getBoundingClientRect(),o=r.getBoundingClientRect(),n=e.x+o.width>window.innerWidth?window.innerWidth-o.width:e.x,o=e.y+e.height+o.height+4>window.innerHeight?e.y-o.height-4:e.y+e.height+4;s&&i.parentElement&&(e=i.parentElement?i.parentElement.getBoundingClientRect():null,r.style.position="absolute",n-=e.x,o-=e.y),r.style.transform="translate(".concat(n,"px, ").concat(o,"px)"),r.style.display="block"}void 0===s&&(s=!1),i.addEventListener("mouseover",t),i.addEventListener("focusin",t),i.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||"block"!==r.style.display||(t.stopPropagation(),r.style.display="none")})}var je,Ie,Te={marker:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(27 * {scale})" height="calc(39 * {scale})" viewBox="-1 -1 26 38"><path d="M12.25.25a12.254 12.254 0 0 0-12 12.494c0 6.444 6.488 12.109 11.059 22.564.549 1.256 1.333 1.256 1.882 0C17.762 24.853 24.25 19.186 24.25 12.744A12.254 12.254 0 0 0 12.25.25Z" style="fill:{color};stroke:{secondaryColor};stroke-width:1"/><text x="12.5" y="17.5" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(39 * {scale})" viewBox="-1 -1 27 38"><path d="M12.25.25a12.254 12.254 0 0 0-12 12.494c0 6.444 6.488 12.109 11.059 22.564.549 1.256 1.333 1.256 1.882 0C17.762 24.853 24.25 19.186 24.25 12.744A12.254 12.254 0 0 0 12.25.25Z" style="fill:{color};stroke:{secondaryColor};stroke-width:2"/><text x="12.5" y="18.5" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-circle":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(39 * {scale})" viewBox="-1 -1 27 38"><path d="M12.25.25a12.254 12.254 0 0 0-12 12.494c0 6.444 6.488 12.109 11.059 22.564.549 1.256 1.333 1.256 1.882 0C17.762 24.853 24.25 19.186 24.25 12.744A12.254 12.254 0 0 0 12.25.25Z" style="fill:{color};stroke:{secondaryColor};stroke-width:1"/><circle cx="12.5" cy="12.5" r="9" fill="{secondaryColor}"/><text x="12" y="17.5" style="font-size:14px;fill:#000;text-anchor:middle">{text}</text></svg>',pin:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(24 * {scale})" height="calc(28 * {scale})" viewBox="0 0 24 28"><path d="m11.988 16.615a5.15 5.15 0 0 1-2.268-.525 4.909 4.909 0 0 1-2.805-4.442 5.019 5.019 0 0 1 5.072-4.936h.012a5.03 5.03 0 0 1 5.085 4.961 4.907 4.907 0 0 1-.549 2.224 5.114 5.114 0 0 1-4.548 2.718zm0-8.06a3.173 3.173 0 0 0-3.226 3.099 3.081 3.081 0 0 0 1.77 2.782 3.299 3.299 0 0 0 4.365-1.386 3.049 3.049 0 0 0 .342-1.381 3.184 3.184 0 0 0-3.239-3.114h-.012z" fill="{secondaryColor}"/><path d="m11.999.922a10.908 10.908 0 0 0-11.076 10.732 10.639 10.639 0 0 0 4.418 8.598l6.658 6.464 6.658-6.463a10.537 10.537 0 0 0 2.198-15.041 11.182 11.182 0 0 0-8.856-4.289zm1.873 14.341a4.221 4.221 0 0 1-5.589-1.789 3.945 3.945 0 0 1-.445-1.8 4.164 4.164 0 0 1 8.323-.037 4.028 4.028 0 0 1-2.289 3.626Z" fill="{color}"/><path d="m11.999 28-7.256-7.044a11.611 11.611 0 0 1-4.743-9.303 11.844 11.844 0 0 1 11.988-11.652.102 .102 0 0 1 .02 0 12.164 12.164 0 0 1 9.577 4.647 11.357 11.357 0 0 1 2.299 8.614 11.521 11.521 0 0 1-4.63 7.695zm-.01-26.157a9.997 9.997 0 0 0-10.143 9.812 9.769 9.769 0 0 0 4.04 7.853l.099.083 6.014 5.838 6.113-5.922a9.7 9.7 0 0 0 3.945-6.505 9.533 9.533 0 0 0-1.933-7.229 10.305 10.305 0 0 0-8.116-3.931h-.021zm.021 14.772a5.11 5.11 0 0 1-4.547-2.718 4.868 4.868 0 0 1 .932-5.743 5.118 5.118 0 0 1 3.58-1.46h.024a5.031 5.031 0 0 1 5.084 4.938 4.92 4.92 0 0 1-2.805 4.457h0a5.152 5.152 0 0 1-2.269.525zm-.011-8.079h-.015a3.277 3.277 0 0 0-2.295.933 3.029 3.029 0 0 0-.587 3.58 3.297 3.297 0 0 0 4.364 1.386h0a3.092 3.092 0 0 0 1.772-2.795 3.185 3.185 0 0 0-3.239-3.105z" fill="{secondaryColor}"/><text x="12" y="17" style="font-size:14px;fill:#000;text-anchor:middle">{text}</text></svg>',"pin-round":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(25 * {scale})" height="calc(25 * {scale})" viewBox="0 0 25 25"><g transform="translate(0 1)"><circle cx="12.25" cy="11.5833" r="11" fill="{color}"/><path d="m12.25 23.583a12 12 0 1 1 12-12 12 12 0 0 1-12 12zm0-22a10 10 0 1 0 10 10 10 10 0 0 0-10-10z" fill="{secondaryColor}"/><circle cx="12.25" cy="11.5833" r="4.2386" fill="{secondaryColor}"/></g><text x="12.5" y="17" style="font-size:14px;fill:#000;text-anchor:middle">{text}</text></svg>',"marker-flat":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(27 * {scale})" height="calc(42.8 * {scale})" viewBox="0 0 1600 2570"><g fill="{color}"><path d="M691 2419c-409-575-641-1086-683-1504-10-106-10-136 5-224 31-188 105-330 241-458 129-124 270-190 453-214 69-9 113-10 182-1 373 46 655 326 703 698 40 308-120 801-424 1309-134 224-348 535-369 535-4 0-53-63-108-141z"/></g><g fill="rgba(0,0,0,0.15)" style="transform:scale(-1,1);transform-origin:center"><path d="M691 2419c-407-571-639-1083-682-1498-14-139-3-249 37-371 69-208 254-402 459-481 68-27 217-59 271-59h24v160 180 940 635c0 349-2 635-5 635-2 0-49-63-104-141z"/></g><circle cx="800" cy="800" r="600" fill="{secondaryColor}"/><text x="800" y="1100" style="font-size:800px;fill:#000;text-anchor:middle">{text}</text></svg>',"marker-arrow":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(25.47 * {scale})" height="calc(35.18 * {scale})" viewBox="0 0 4330 5980"><g fill="{color}"><path d="m2080 5969c-49-20-93-63-115-113-25-55-1928-5486-1953-5573-40-138 67-282 210-283 36 0 246 73 987 345 518 190 947 345 955 345 8 0 438-155 955-345 615-226 954-345 979-345 87 0 165 47 204 123 46 91 107-95-957 2942-537 1535-986 2805-997 2823-11 18-43 46-72 62-41 24-62 30-111 29-33 0-71-5-85-10z"/></g><g fill="{secondaryColor}"><path d="m2200 1600c-36 10-83 2-484-84-243-53-451-94-461-91-11 4-22 18-25 31-5 19 114 371 436 1292 244 697 448 1273 454 1281 19 24 50 30 71 12z"/><path d="m2200 1600c-36 10-83 2-484-84-243-53-451-94-461-91-11 4-22 18-25 31-5 19 114 371 436 1292 244 697 448 1273 454 1281 19 24 50 30 71 12z" style="transform:scale(-1,1);transform-origin:center"/></g><g fill="rgba(0,0,0,0.2)" ><path d="m2165 685c8 0 438-155 955-345 615-226 954-345 979-345 87 0 165 47 204 123 46 91 107-95-957 2942-537 1535-986 2805-997 2823-11 18-43 46-72 62-41 24-62 30-111 29z"/></g><text x="2165" y="3300" style="font-size:2500px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-ball-pin":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(15.67 * {scale})" height="calc(33.33 * {scale})" viewBox="0 0 235 452"><g transform="translate(-135 10)"><path fill="{secondaryColor}" d="m256 442 0 0c-13 0-18-11-18-24l-6-323c0-13 11-24 24-24h0c13 0 24 11 24 24l-6 323c0 13-5 24-18 24z"/><circle style="fill:{color};stroke-width:10;stroke:{secondaryColor}" cx="256" cy="112" r="111"/><ellipse transform="matrix(0.834 0.5518 -0.5518 0.834 65.7916 -97.18)" fill="rgba(255,255,255,0.3)" cx="194.399" cy="60.749" rx="19.076" ry="32.428"/></g><text x="117.5" y="160" style="font-size:160px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(26.67 * {scale})" height="calc(32.27 * {scale})" viewBox="0 0 2000 2420"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="M845 2152c-22-37-58-95-80-129-22-35-62-99-90-143l-50-80-312 0-313 0 0-900 0-900 900 0 900 0 0 900 0 900-313 0-313 0-34 58c-19 31-38 59-42 60-5 2-8 8-8 12 0 9-69 123-88 145-5 6-11 15-13 21-16 39-77 123-89 124-8 0-33-31-55-68z"/></g><text x="1000" y="1300" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square-cluster":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(33.33 * {scale})" height="calc(38.8 * {scale})" viewBox="0 0 2500 2910"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="m866 2652c-17-31-37-68-46-82-9-14-32-54-51-90-19-36-50-92-70-125l-36-60-332-3-331-2 0-905 0-905 660 0 660 0 0-38c0-71 50-196 102-258 71-85 189-164 244-164 12 0 26-4 29-10 8-13 222-13 230 0 3 6 17 10 30 10 25 0 117 45 154 76 130 107 191 232 191 392 0 155-63 284-190 386-36 29-129 76-150 76-11 0-22 5-25 10-3 6-31 10-61 10l-54 0 0 660 0 660-332 2-332 3-29 50c-17 28-48 84-70 125-22 41-47 86-56 100-9 14-30 51-46 83-17 32-36 57-45 57-8 0-28-25-44-58z"/></g><text x="1650" y="900" style="font-size:1000px;fill:#fff">+</text><text x="1000" y="1800" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square-rounded":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(26.8 * {scale})" height="calc(32.27 * {scale})" viewBox="0 0 2010 2410"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="M856 2155c-20-30-36-59-36-65 0-5-4-10-10-10-5 0-10-5-10-11 0-5-18-37-40-69-22-32-40-64-40-69 0-6-4-11-10-11-5 0-10-5-10-10 0-6-15-33-32-60l-33-50-127 0c-74 0-129-4-133-10-3-5-17-10-30-10-25 0-116-45-155-76-87-69-142-151-178-265-15-46-17-1075-2-1084 5-3 10-17 10-30 0-13 5-27 10-30 6-3 10-13 10-22 0-22 83-135 122-168 57-46 62-50 112-75l50-25 585 0 586 0 63 34c84 46 169 133 212 218l35 68 0 565 0 565-28 59c-32 69-100 157-139 180-15 9-33 22-40 29-23 22-99 57-123 57-13 0-27 5-30 10-4 6-60 10-135 10l-128 0-128 205c-84 136-133 205-144 205-10 0-33-24-54-55z"/></g><text x="1000" y="1300" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square-rounded-cluster":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(33.33 * {scale})" height="calc(32.13 * {scale})" viewBox="0 0 2500 2900"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="m874 2669c-9-18-26-49-37-68-11-20-30-55-43-78-13-24-36-64-51-90-14-27-38-69-52-95l-26-48-142 0c-84 0-144-4-148-10-3-5-17-10-30-10-25 0-118-46-154-76-91-76-136-142-175-254-13-38-16-119-16-554 0-358 3-520 12-545 40-125 106-219 195-278 127-84 116-83 646-83l467 0 0-42c0-46 11-87 45-163 54-121 169-220 306-264 46-14 232-14 278 0 165 53 284 175 340 350 19 61 14 204-10 273-32 91-94 178-169 240-38 31-130 76-155 76-13 0-27 5-30 10-3 6-28 10-56 10l-49 0 0 462c0 446-1 464-21 522-32 91-94 178-169 240-38 31-130 76-155 76-13 0-27 5-30 10-4 6-65 10-149 10-138 0-143 1-154 23-12 23-62 114-112 202-16 28-44 79-63 115-42 77-67 88-93 39z"/></g><text x="1650" y="900" style="font-size:1000px;fill:#fff">+</text><text x="1000" y="1800" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',flag:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(23.5 * {scale})" height="calc(40 * {scale})" viewBox="34 28 198 308"><path style="stroke:{secondaryColor};stroke-width:15;stroke-linecap:round;" d="M42 327l0 -291"/><path style="fill:{color};stroke:{secondaryColor};stroke-width:10;stroke-linejoin:round;" d="M49 50c70 30 104 28 178 2-21 42-21 74 0 116-72 25-101 25-178 0l0-118z"/><text x="130" y="165" style="font-size:100px;fill:#fff;text-anchor:middle">{text}</text></svg>',"flag-triangle":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(27 * {scale})" height="calc(35.33 * {scale})" viewBox="0 0 40.5 53"><g transform="translate(-31 -20)"><path fill="{secondaryColor}" d="M34.7,73.3V48.4l34.6-10.1c0.7-0.2,1.2-0.8,1.2-1.5s-0.4-1.4-1-1.7L33.7,20.5c-0.5-0.2-1.1-0.2-1.6,0.2 c-0.5,0.3-0.7,0.8-0.7,1.4v51.2H34.7z"/><polygon points="34.7,24.5 66,36.5 34.7,45 34.7,10" fill="{color}"/></g><text x="11" y="21" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"rounded-square":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(34 * {scale})" height="calc(34 * {scale})" viewBox="0 0 34 34"><g transform="translate(2 2)"><rect x="0" y="0" rx="8" ry="8" width="30" height="30" style="stroke:{secondaryColor};stroke-width:2;fill:{color}"/></g><text x="17" y="22" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"rounded-square-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(38 * {scale})" height="calc(38 * {scale})" viewBox="0 0 38 38"><g transform="translate(4 4)"><rect x="0" y="0" rx="8" ry="8" width="30" height="30" style="stroke:{secondaryColor};stroke-width:4;fill:{color}"/></g><text x="19" y="24" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',triangle:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(36 * {scale})" height="calc(36 * {scale})" viewBox="0 0 36 36"><g transform="translate(2 2)"><polygon points="16,0 32,32 0,32 16,0" style="stroke:{secondaryColor};stroke-width:2;fill:{color}"/></g><text x="17.5" y="30" style="font-size:12px;fill:#fff;text-anchor:middle">{text}</text></svg>',"triangle-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 40 40"><g transform="translate(4 4)"><polygon points="16,0 32,32 0,32 16,0" style="stroke:{secondaryColor};stroke-width:4;fill:{color}"/></g><text x="19.5" y="32" style="font-size:12px;fill:#fff;text-anchor:middle">{text}</text></svg>',hexagon:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(35 * {scale})" height="calc(40 * {scale})" viewBox="0 0 35 40"><g transform="translate(2 2)"><path d="M31 9 15.5 0 0 9 0 27 15.5 36 31 27 31 9Z" style="stroke:{secondaryColor};stroke-width:2;fill:{color}"/></g><text x="17.5" y="25" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"hexagon-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(39 * {scale})" height="calc(44 * {scale})" viewBox="0 0 39 44"><g transform="translate(4 4)"><path d="M31 9 15.5 0 0 9 0 27 15.5 36 31 27 31 9Z" style="stroke:{secondaryColor};stroke-width:4;fill:{color}"/></g><text x="19.5" y="27" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"hexagon-rounded":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 1100 1100"><g transform="translate(50 50)"><path style="stroke:{secondaryColor};stroke-width:50;fill:{color}" d="M881 210 561 25c-33-19-88-19-121 0L119 210c-33 19-61 67-61 105v370c0 39 27 86 61 105l321 185c33 19 88 19 122 0l321-185c33-19 61-67 61-105V315C942 276 915 229 881 210z"/></g><text x="550" y="700" style="font-size:400px;fill:#fff;text-anchor:middle">{text}</text></svg>',"hexagon-rounded-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 1200 1200"><g transform="translate(100 100)"><path style="stroke:{secondaryColor};stroke-width:100;fill:{color}" d="M881 210 561 25c-33-19-88-19-121 0L119 210c-33 19-61 67-61 105v370c0 39 27 86 61 105l321 185c33 19 88 19 122 0l321-185c33-19 61-67 61-105V315C942 276 915 229 881 210z"/></g><text x="600" y="750" style="font-size:400px;fill:#fff;text-anchor:middle">{text}</text></svg>',"triangle-arrow-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(28 * {scale})" viewBox="0 0 28 28"><g transform="translate(2 2)"><polygon points="12,0 0,24 12,17 24,24" stroke-width="2" stroke="{secondaryColor}" fill="{color}"/></g><text x="14" y="17" style="font-size:8px;fill:#fff;text-anchor:middle">{text}</text></svg>',"triangle-arrow-left":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(28 * {scale})" viewBox="0 0 28 28"><g transform="translate(2 2)"><polygon points="24,12 0,0 7,12 0,24" stroke-width="2" stroke="{secondaryColor}" fill="{color}"/></g><text x="14" y="16.5" style="font-size:8px;fill:#fff;text-anchor:middle">{text}</text></svg>',"arrow-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(12.16 * {scale})" height="calc(30.1 * {scale})" viewBox="0 0 902 364"><g fill="{color}" transform="matrix(0,2.4,-2.4,0,897,-930)"><polygon points="902,222 233,222 233,364 0,182 233,0 233,141 902,141 902,222"/></g><text x="450" y="700" style="font-size:900px;fill:#000;text-anchor:middle">{text}</text></svg>',"arrow-up-thin":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(16 * {scale})" height="calc(33.33 * {scale})" viewBox="0 0 12 25"><g transform="translate(-136.91823 -751.91998)"><path fill="{color}" d="m148.271 760.71c-1.641-.547-3.186-1.47-4.633-2.769l0 18.07-1.675 0 0-18.07c-1.447 1.299-2.986 2.222-4.616 2.769l0-1.231c2.325-1.596 4.006-3.812 5.043-6.65l.838 0c1.037 2.838 2.718 5.055 5.043 6.65l0 1.231z"/></g><text x="6" y="20" style="font-size:10px;fill:#000;text-anchor:middle">{text}</text></svg>',car:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(21.93 * {scale})" height="calc(40.9 * {scale})" viewBox="0 0 6580 12270"><g transform="translate(0 12270) rotate(-90)"><path fill="{secondaryColor}" d="M7045 6566c-42-13-105-44-105-51 0-2 23-105 50-228 28-123 50-230 50-236 0-8-241-11-907-11-855 0-1145 6-1513 30-85 6-189 13-230 15-41 3-133 10-205 15-286 21-430 32-705 50-953 63-1459 18-2335-205-304-77-746-209-799-238-131-72-221-408-285-1062-34-345-42-532-48-1130-16-1557 108-2532 336-2649 32-17 469-149 676-205 409-110 819-191 1205-238 116-14 224-18 540-18 395 1 494 5 1140 50 1124 79 1224 82 2496 78l641-3-53-237c-29-131-52-238-51-239 1-1 31-14 66-29 56-23 76-26 142-23 67 3 83 7 120 33 23 17 50 41 61 55 10 14 51 117 91 230l73 205 674 3 675 2 90-39c98-43 198-72 315-93 122-21 829-18 990 5 321 45 626 143 849 270 293 168 516 378 704 662 266 402 416 893 467 1527 15 174 8 882-9 998-6 41-18 127-27 190-69 502-253 969-523 1325-79 105-262 284-381 374-189 142-355 229-574 300-336 110-526 139-952 148-457 9-685-23-887-124l-47-24-678-6-678-6-64 179c-79 224-92 253-121 284-67 70-177 97-274 66zm-2752-5073c-23-2-64-2-90 0-26 2-7 3 42 3 50 0 71-1 48-3zm395 0c-21-2-55-2-75 0-21 2-4 4 37 4 41 0 58-2 38-4z"/><path fill="{color}" d="M7043 6498c-13-6-23-19-23-28 0-9 23-117 50-240 28-123 50-230 50-237 0-22-2126-13-2465 10-132 10-400 28-595 42-661 47-824 55-1160 62-435 7-656-8-1040-73-415-70-865-183-1447-365-168-53-272-556-325-1569-16-319-16-1311 0-1630 45-872 129-1366 257-1518 22-26 51-39 172-77 557-177 1122-310 1563-369 271-36 351-40 690-40 361 1 463 6 1165 54 1122 78 1288 83 2337 79 460-2 840-7 843-11 4-4-17-117-47-252l-55-245 39-16c76-30 180-8 224 47 10 13 54 124 98 246l79 222 709 0 709 0 47-24c74-37 219-83 322-101 122-22 606-32 802-16 374 29 658 102 933 238 124 62 271 155 361 230l61 51 6 100c19 278 103 497 247 643 88 89 173 136 278 152l70 11 41 131c116 369 159 673 168 1170 10 584-38 984-167 1397l-40 126-70 12c-193 33-348 175-441 405-56 139-89 302-89 445 0 43-3 47-58 91-290 235-644 384-1068 450-191 29-796 39-974 16-135-18-263-54-368-102l-75-35-701 0-701 0-79 223c-82 232-102 267-163 293-38 16-138 17-170 2zm-2023-820c332-15 1155-12 1835 6 308 8 563 12 566 8 4-4 10-21 13-38 7-30 6-31-92-77-518-244-1197-396-2112-474-295-25-1282-25-1579 0-231 20-473 46-479 51-6 7 49 110 93 171 160 226 416 335 855 365 142 10 539 5 900-12zm3304-263c525-111 899-887 934-1935 19-557-37-1023-172-1435-186-563-521-900-896-899-81 0-158 14-525 92-426 91-431 92-540 146-195 96-287 207-306 368-12 104-11 2985 1 3078 22 170 135 291 365 389 49 21 191 55 480 115 226 47 419 87 430 89 45 10 164 6 229-8zm-5570-485c112-43 197-156 216-291 12-83 13-2623 1-2706-23-158-125-273-270-304-44-9-100-1-542 75-272 47-514 91-539 98-266 68-487 424-594 958-56 280-70 548-40 800 56 484 207 878 414 1081 115 114 122 116 702 218 277 49 524 90 550 90 26 1 72-8 102-19zm2111-3440c1023-44 1884-213 2462-486l113-53-7-33c-3-18-8-35-10-37-2-3-236 1-521 7-993 24-1271 26-1708 11-541-18-1128-18-1249-1-377 56-588 181-734 437-32 55-41 79-32 84 12 8 246 32 491 51 356 28 815 36 1195 20z"/></g><text x="3250" y="8250" style="font-size:3000px;fill:#fff;text-anchor:middle">{text}</text></svg>',checker:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(16 * {scale})" height="calc(16 * {scale})" viewBox="0 0 16 16"><pattern id="p" x="0" y="0" width="16" height="16" patternUnits="userSpaceOnUse"><rect fill="{color}" x="0" width="8" height="8" y="0"/><rect fill="{color}" x="8" width="8" height="8" y="8"/></pattern><rect x="0" y="0" width="16" height="16" fill="{secondaryColor}"/><rect x="0" y="0" width="16" height="16" fill="url(#p)"/></svg>',"checker-rotated":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(16 * {scale})" height="calc(16 * {scale})" viewBox="0 0 60 60"><rect width="60" height="60" fill="{secondaryColor}"/><rect width="42.42" height="42.42" transform="translate(30 0) rotate(45)" fill="{color}"/></svg>',"zig-zag":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(15 * {scale})" height="calc(15 * {scale})" viewBox="0 0 120 120"><rect x="0" y="0" width="120" height="120" fill="{secondaryColor}"/><polygon fill="{color}" points="120 120 60 120 90 90 120 60 120 0 120 0 60 60 0 0 0 60 30 90 60 120 120 120"/></svg>',"zig-zag-vertical":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(15 * {scale})" height="calc(15 * {scale})" viewBox="0 0 120 120"><rect x="0" y="0" width="120" height="120" fill="{secondaryColor}"/><polygon fill="{color}" points="120 0 120 60 90 30 60 0 0 0 0 0 60 60 0 120 60 120 90 90 120 60 120 0"/></svg>',"circles-spaced":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 20 20"><defs><pattern id="p" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="2" stroke="none" fill="{color}"/></pattern></defs><rect x="0" y="0" width="20" height="20" fill="{secondaryColor}"/><rect x="0" y="0" width="100" height="100" fill="url(#p)"/></svg>',circles:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(7 * {scale})" height="calc(7 * {scale})" viewBox="0 0 20 20"><defs><pattern id="p" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="6" stroke="none" fill="{color}"/></pattern></defs><rect x="0" y="0" width="20" height="20" fill="{secondaryColor}"/><rect x="0" y="0" width="100" height="100" fill="url(#p)"/></svg>',"diagonal-lines-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(18 * {scale})" height="calc(18 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"diagonal-lines-down":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(18 * {scale})" height="calc(18 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g transform="rotate(90 3 3)" fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"diagonal-stripes-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="40" height="40" fill="{secondaryColor}"/><g fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g></svg>',"diagonal-stripes-down":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="40" height="40" fill="{secondaryColor}"/><g transform="rotate(90 20 20)" fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g></svg>',"grid-lines":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(14 * {scale})" height="calc(14 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g transform="rotate(45 3 3)" fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g><g fill="{color}" transform="rotate(-45 3 3)"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"rotated-grid-lines":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(18 * {scale})" height="calc(18 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g transform="rotate(90 3 3)" fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g><g fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"rotated-grid-stripes":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="40" height="40" fill="{secondaryColor}"/><g transform="rotate(90 20 20)" fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g><g fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g></svg>',"x-fill":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="45.3" height="45.3" fill="{secondaryColor}"/><g fill="{color}"><path d="M0 38.59l2.83-2.83 1.41 1.41L1.41 40H0v-1.41zM0 1.4l2.83 2.83 1.41-1.41L1.41 0H0v1.41zM38.59 40l-2.83-2.83 1.41-1.41L40 38.59V40h-1.41zM40 1.41l-2.83 2.83-1.41-1.41L38.59 0H40v1.41zM20 18.6l2.83-2.83 1.41 1.41L21.41 20l2.83 2.83-1.41 1.41L20 21.41l-2.83 2.83-1.41-1.41L18.59 20l-2.83-2.83 1.41-1.41L20 18.59z"/></g></svg>',dots:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(13 * {scale})" height="calc(13 * {scale})" viewBox="0 0 20 20"><rect x="0" y="0" width="20" height="20" fill="{secondaryColor}"/><g fill="{color}"><circle cx="3" cy="3" r="3"/><circle cx="13" cy="13" r="3"/></g></svg>'},ze=window&&window.__extends||(je=function(t,e){return(je=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}je(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),De=(u.ControlPosition=void 0,(yt=u.ControlPosition||(u.ControlPosition={})).TopLeft="top-left",yt.TopRight="top-right",yt.BottomLeft="bottom-left",yt.BottomRight="bottom-right",yt.NonFixed="non-fixed",ze(Re,Ie=t),Re);function Re(){var t=null!==Ie&&Ie.apply(this,arguments)||this;return t.position=u.ControlPosition.NonFixed,t}Fe.prototype.getLuminosity=function(){for(var t=[this.r,this.g,this.b],e=[],o=0;o<t.length;o++){var n=t[o]/255;e[o]=n<=.03928?n/12.92:Math.pow((.055+n)/1.055,2.4)}return.2126*e[0]+.7152*e[1]+.0722*e[2]},Fe.prototype.getRBGA=function(t){var e=document.createElement("canvas").getContext("2d"),t=(e.globalAlpha=1,e.fillStyle=t,e.fillRect(0,0,1,1),e.getImageData(0,0,1,1).data);return[t[0],t[1],t[2],t[3]]};var Be=Fe;function Fe(t){var e;t&&(e=void 0,3<=(e="string"==typeof t?this.getRBGA(t):t).length)&&(this.r=e[0],this.g=e[1],this.b=e[2],3<e.length)&&(this.a=e[3])}u.ControlStyle=void 0,(H=u.ControlStyle||(u.ControlStyle={})).light="light",H.dark="dark",H.auto="auto";var Ne=Map,Ze=(qe.prototype._addEventListener=function(t,e,o){this.listeners.has(t)||this.listeners.set(t,new Ne),this.listeners.get(t).set(e,o)},qe.prototype._removeEventListener=function(t,e){this.listeners.has(t)&&this.listeners.get(t).delete(e)},qe.prototype._invokeEvent=function(o,n){var r=this;this.listeners.has(o)&&this.listeners.get(o).forEach(function(t,e){t&&r._removeEventListener(o,e);try{e(n)}catch(t){console.error(t)}})},qe);function qe(){this.listeners=new Ne}var He,Ue,U=Object.freeze({__proto__:null,EventEmitter:Ze}),We=((window&&window.__extends||(He=function(t,e){return(He=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}He(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ge,Ue=Ze),Ge.prototype.onRemove=function(){this._container&&(this._container.remove(),delete this._container),this._map&&(this._map.events.remove("stylechanged",this._onStyleChange),delete this._map),this._observer&&(this._observer.disconnect(),delete this._observer),delete this._theme},Ge.prototype.buildContainer=function(t,e,o,n){return this._map=t,this._container=document.createElement(n||"div"),this._container.classList.add("azure-maps-control-container"),"string"==typeof o&&this._container.setAttribute("aria-label",o),e.toLowerCase()===u.ControlStyle.auto?this._map&&this._map.events.add("stylechanged",this._onStyleChange):this._container.classList.add(e),this._container},Ge.prototype._setTheme=function(t){this._theme!==t&&(this._container.classList.remove(this._theme),this._container.classList.add(t),this._theme=t)},Ge.activateClickDelay=100,Ge);function Ge(){var e=null!==Ue&&Ue.apply(this,arguments)||this;return e._onStyleChange=function(){e._map.getStyle().style.toLowerCase().startsWith("blank")?e._observer||(e._onBackgroundChange(),e._observer=new MutationObserver(e._onBackgroundChange),e._observer.observe(e._map.getMapContainer(),{attributes:!0,attributeFilter:["style"]})):(e._observer&&(e._observer.disconnect(),delete e._observer),e._map.styles.getThemeAsync(e._map.getStyle()).then(function(t){e._setTheme(t)}))},e._onBackgroundChange=function(){var t=new Be(e._map.getMapContainer().style.backgroundColor).getLuminosity(),t=isNaN(t)||.5<t?u.ControlStyle.light:u.ControlStyle.dark;e._setTheme(t)},e}(window&&window.__extends||(Ve=function(t,e){return(Ve=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ve(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Je,Ke=t);var Ve,Ke,Ye=Je;function Je(){var t=null!==Ke&&Ke.apply(this,arguments)||this;return t.rotationDegreesDelta=15,t.style=u.ControlStyle.light,t.inverted=!1,t}(window&&window.__extends||($e=function(t,e){return($e=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}$e(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Qe,Xe=We),Qe.prototype.onAdd=function(t,e){function o(t){t?(r.classList.add("in-use"),s.classList.remove("hidden-accessible-element")):(r.classList.remove("in-use"),s.classList.add("hidden-accessible-element"))}var n=this,r=this.buildContainer(t,this.options.style,"Rotation Control"),i=this.constructRotationButton(t),s=this.constructRotationGrid(t,e),a=_("Reset to Default Rotation");return r.addEventListener("mouseover",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasMouse=!0,o(!0)}),r.addEventListener("focusin",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasFocus=!0,o(!0)}),r.addEventListener("mouseleave",function(){n.hasMouse=!1,n.hasFocus||(delete n.lastActiveTime,o(!1))}),r.addEventListener("focusout",function(t){t.relatedTarget instanceof Node&&r.contains(t.relatedTarget)||(n.hasFocus=!1,n.hasMouse)||(delete n.lastActiveTime,o(!1))}),s.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||(t.stopPropagation(),i.focus(),o(!1))}),i.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||null==r||!r.classList.contains("in-use")||"none"!==(null==a?void 0:a.style.display)||(t.stopPropagation(),o(!1))}),e&&Qe.InvertOrderPositions.includes(e.position)?(r.appendChild(s),r.appendChild(i),r.appendChild(a),b(a,i)):(r.appendChild(i),r.appendChild(a),b(a,i),r.appendChild(s)),r},Qe.prototype.constructRotationGrid=function(t,e){var o=document.createElement("div"),n=(o.classList.add("sub-container"),o.classList.add("hidden-accessible-element"),this.constructRightRotationButton(t)),t=this.constructLeftRotationButton(t),r=_("Rotate Left"),i=_("Rotate Right");return e&&Qe.InvertOrderPositions.includes(e.position)?(o.appendChild(n),o.appendChild(i),b(i,n),o.appendChild(t),o.appendChild(r),b(r,t)):(o.appendChild(t),o.appendChild(r),b(r,t),o.appendChild(n),o.appendChild(i),b(i,n)),o},Qe.prototype.constructRotationButton=function(e){var o=this,t=document.createElement("button"),n=(t.classList.add("azure-maps-control-button"),t.classList.add("rotation"),t.setAttribute("aria-label","Reset to Default Rotation"),t.setAttribute("alt","Reset to Default Rotation"),t.setAttribute("type","button"),document.createElement("div"));return t.appendChild(n),t.addEventListener("click",function(t){t.timeStamp-o.lastActiveTime>We.activateClickDelay&&e.setCamera({bearing:Qe.DefaultRotation},!0)}),e.events.add("rotate",function(t){n.style.transform="rotate(".concat(-t.map.getCamera().bearing,"deg)")}),t},Qe.prototype.constructRightRotationButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("rotation-right"),o.setAttribute("aria-label","Rotate Right"),o.setAttribute("alt","Rotate Right"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({bearing:t.getCamera().bearing-(e.options.inverted?-1:1)*e.options.rotationDegreesDelta,duration:Qe.RotationDuration,type:"ease"},!0)}),o},Qe.prototype.constructLeftRotationButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("rotation-left"),o.setAttribute("aria-label","Rotate Left"),o.setAttribute("alt","Rotate Left"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({bearing:t.getCamera().bearing+(e.options.inverted?-1:1)*e.options.rotationDegreesDelta,duration:Qe.RotationDuration,type:"ease"},!0)}),o},Qe.DefaultRotation=0,Qe.RotationDuration=100,Qe.InvertOrderPositions=[u.ControlPosition.BottomRight,u.ControlPosition.TopRight];var $e,Xe,q=Qe;function Qe(t){var e=Xe.call(this)||this;return e.hasMouse=!1,e.hasFocus=!1,e.options=(new Ye).merge(t),e}(window&&window.__extends||(to=function(t,e){return(to=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}to(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(no,eo=t);var to,eo,oo=no;function no(){var t=null!==eo&&eo.apply(this,arguments)||this;return t.pitchDegreesDelta=10,t.style=u.ControlStyle.light,t.inverted=!1,t}(window&&window.__extends||(ro=function(t,e){return(ro=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ro(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(so,io=We),so.prototype.onAdd=function(t,e){function o(t){t?(r.classList.add("in-use"),s.classList.remove("hidden-accessible-element")):(r.classList.remove("in-use"),s.classList.add("hidden-accessible-element"))}var n=this,r=this.buildContainer(t,this.options.style,"Pitch Control"),i=this.constructPitchButton(t),s=this.constructPitchGrid(t,e),a=_("Reset to Default Pitch");return r.addEventListener("mouseover",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasMouse=!0,o(!0)}),r.addEventListener("focusin",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasFocus=!0,o(!0)}),r.addEventListener("mouseleave",function(){n.hasMouse=!1,n.hasFocus||(delete n.lastActiveTime,o(!1))}),r.addEventListener("focusout",function(t){t.relatedTarget instanceof Node&&r.contains(t.relatedTarget)||(n.hasFocus=!1,n.hasMouse)||(delete n.lastActiveTime,o(!1))}),s.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||(t.stopPropagation(),i.focus(),o(!1))}),i.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||null==r||!r.classList.contains("in-use")||"none"!==(null==a?void 0:a.style.display)||(t.stopPropagation(),o(!1))}),e&&so.INVERT_ORDER_POSITIONS.includes(e.position)?(r.appendChild(s),r.appendChild(i),r.appendChild(a),b(a,r)):(r.appendChild(i),r.appendChild(a),b(a,r),r.appendChild(s)),this.map=t,this.container=r,this.pitchButton=i,t.events.add("pitch",this.pitchChanged),this.updatePitchButtonsState(),r},so.prototype.onRemove=function(){this.container&&(this.container.remove(),this.container=null,this.pitchButton=null,this.pitchIncrementButton=null,this.pitchDecrementButton=null),this.map&&(this.map.events.remove("pitch",this.pitchChanged),this.map=null)},so.prototype.constructPitchGrid=function(t,e){var o=document.createElement("div"),t=(o.classList.add("sub-container"),o.classList.add("hidden-accessible-element"),this.pitchIncrementButton=this.constructPitchIncrementButton(t),this.pitchDecrementButton=this.constructPitchDecrementButton(t),_("Increase Pitch")),n=_("Decrease Pitch");return e&&so.INVERT_ORDER_POSITIONS.includes(e.position)?(o.appendChild(this.pitchDecrementButton),o.appendChild(n),b(n,this.pitchDecrementButton),o.appendChild(this.pitchIncrementButton),o.appendChild(t),b(t,this.pitchIncrementButton)):(o.appendChild(this.pitchIncrementButton),o.appendChild(t),b(t,this.pitchIncrementButton),o.appendChild(this.pitchDecrementButton),o.appendChild(n),b(n,this.pitchDecrementButton)),o},so.prototype.constructPitchButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("pitch"),o.setAttribute("aria-label","Reset to Default Pitch"),o.setAttribute("alt","Reset to Default Pitch"),o.setAttribute("type","button"),o.addEventListener("click",function(){event.timeStamp-e.lastActiveTime>We.activateClickDelay&&t.setCamera({pitch:so.DEFAULT_PITCH},!0)}),o},so.prototype.constructPitchDecrementButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("pitch-down"),o.setAttribute("aria-label","Decrease Pitch"),o.setAttribute("alt","Decrease Pitch"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({pitch:t.getCamera().pitch-(e.options.inverted?-1:1)*e.options.pitchDegreesDelta,duration:so.PITCH_DURATION_MS,type:"ease"},!0)}),o},so.prototype.constructPitchIncrementButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("pitch-up"),o.setAttribute("aria-label","Increase Pitch"),o.setAttribute("alt","Increase Pitch"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({pitch:t.getCamera().pitch+(e.options.inverted?-1:1)*e.options.pitchDegreesDelta,duration:so.PITCH_DURATION_MS,type:"ease"},!0)}),o},so.PITCH_DURATION_MS=100,so.DEFAULT_PITCH=0,so.INVERT_ORDER_POSITIONS=[u.ControlPosition.BottomRight,u.ControlPosition.TopRight];var ro,io,yt=so;function so(t){var o=io.call(this)||this;return o.container=null,o.map=null,o.pitchButton=null,o.pitchIncrementButton=null,o.pitchDecrementButton=null,o.hasMouse=!1,o.hasFocus=!1,o.pitchChanged=function(t){return o.updatePitchButtonsState()},o.updatePitchButtonsState=function(){var t=o.map.getCamera().pitch<=0,e=60<=o.map.getCamera().pitch;o.hasFocus&&o.pitchButton&&(t||e)&&o.pitchButton.focus(),o.options.inverted?(o.pitchIncrementButton&&o.pitchIncrementButton.disabled!=t&&(o.pitchIncrementButton.disabled=t),o.pitchDecrementButton&&o.pitchDecrementButton.disabled!=e&&(o.pitchDecrementButton.disabled=e)):(o.pitchIncrementButton&&o.pitchIncrementButton.disabled!=e&&(o.pitchIncrementButton.disabled=e),o.pitchDecrementButton&&o.pitchDecrementButton.disabled!=t&&(o.pitchDecrementButton.disabled=t))},o.options=(new oo).merge(t),o}(window&&window.__extends||(ao=function(t,e){return(ao=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ao(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(lo,co=We),lo.prototype.onAdd=function(t,e){this.map=t,null!=(o=null==(o=this.map)?void 0:o._getMap())&&o.addControl(this.control);var o=this.buildContainer(t,u.ControlStyle.auto,"Scale Bar");return o.appendChild(null==(t=this.control)?void 0:t._container),o},lo.prototype.onRemove=function(){var t;co.prototype.onRemove.call(this),null!=(t=null==(t=this.map)?void 0:t._getMap())&&t.removeControl(this.control),this.map=null},lo.prototype.setUnit=function(t){var e;null!=(e=this.control)&&e.setUnit(t)};var ao,co,ze=lo;function lo(t){var e=co.call(this)||this;return e.map=null,e.control=new D.ScaleControl({maxWidth:null==t?void 0:t.maxWidth,unit:null==t?void 0:t.unit}),e}function uo(t,e){return t===e||t!=t&&e!=e}var po=uo;function ho(t,e){for(var o=t.length;o--;)if(po(t[o][0],e))return o;return-1}var fo=ho,yo=Array.prototype.splice;var mo=ho;var go=ho;var vo=ho;function wo(t){var e=this.__data__;return!((t=fo(e,t))<0||(t==e.length-1?e.pop():yo.call(e,t,1),--this.size,0))}function _o(t){var e=this.__data__;return(t=mo(e,t))<0?void 0:e[t][1]}function bo(t){return-1<go(this.__data__,t)}function xo(t,e){var o=this.__data__,n=vo(o,t);return n<0?(++this.size,o.push([t,e])):o[n][1]=e,this}function Oo(t){var e=-1,o=null==t?0:t.length;for(this.clear();++e<o;){var n=t[e];this.set(n[0],n[1])}}Oo.prototype.clear=function(){this.__data__=[],this.size=0},Oo.prototype.delete=wo,Oo.prototype.get=_o,Oo.prototype.has=bo,Oo.prototype.set=xo;var H=Oo,So=H;function Co(){this.__data__=new So,this.size=0}function Po(t){var e=this.__data__,t=e.delete(t);return this.size=e.size,t}function Lo(t){return this.__data__.get(t)}function ko(t){return this.__data__.has(t)}var R="object"==typeof R&&R&&R.Object===Object&&R,e="object"==typeof self&&self&&self.Object===Object&&self,e=R||e||Function("return this")(),Ao=e.Symbol,o=Object.prototype,Mo=o.hasOwnProperty,Eo=o.toString,jo=Ao?Ao.toStringTag:void 0;var Io=Object.prototype.toString;var To=function(t){var e=Mo.call(t,jo),o=t[jo];try{var n=!(t[jo]=void 0)}catch(t){}var r=Eo.call(t);return n&&(e?t[jo]=o:delete t[jo]),r},zo=function(t){return Io.call(t)},Do=Ao?Ao.toStringTag:void 0;function Ro(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":(Do&&Do in Object(t)?To:zo)(t)}function Bo(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Fo=Ro,No=Bo;function Zo(t){return!!No(t)&&("[object Function]"==(t=Fo(t))||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t)}var o=e["__core-js_shared__"],qo=(o=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+o:"";var Ho=Function.prototype.toString;function Uo(t){if(null!=t){try{return Ho.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var Wo=Zo,Go=function(t){return!!qo&&qo in t},Vo=Bo,Ko=Uo,Yo=/^\[object .+?Constructor\]$/,o=Function.prototype,Jo=Object.prototype,o=o.toString,Jo=Jo.hasOwnProperty,$o=RegExp("^"+o.call(Jo).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var Xo=function(t){return!(!Vo(t)||Go(t))&&(Wo(t)?$o:Yo).test(Ko(t))},Qo=function(t,e){return null==t?void 0:t[e]};function tn(t,e){return t=Qo(t,e),Xo(t)?t:void 0}var o=tn(e,"Map"),Jo=tn(Object,"create"),en=Jo;var on=Jo,nn=Object.prototype.hasOwnProperty;var rn=Jo,sn=Object.prototype.hasOwnProperty;var an=Jo;function cn(t){return t=this.has(t)&&delete this.__data__[t],this.size-=t?1:0,t}function ln(t){var e,o=this.__data__;return on?"__lodash_hash_undefined__"===(e=o[t])?void 0:e:nn.call(o,t)?o[t]:void 0}function un(t){var e=this.__data__;return rn?void 0!==e[t]:sn.call(e,t)}function pn(t,e){var o=this.__data__;return this.size+=this.has(t)?0:1,o[t]=an&&void 0===e?"__lodash_hash_undefined__":e,this}function hn(t){var e=-1,o=null==t?0:t.length;for(this.clear();++e<o;){var n=t[e];this.set(n[0],n[1])}}hn.prototype.clear=function(){this.__data__=en?en(null):{},this.size=0},hn.prototype.delete=cn,hn.prototype.get=ln,hn.prototype.has=un,hn.prototype.set=pn;var dn=hn,fn=H,yn=o;var mn=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t};function gn(t,e){return t=t.__data__,mn(e)?t["string"==typeof e?"string":"hash"]:t.map}var vn=gn;var wn=gn;var _n=gn;var bn=gn;function xn(t){return t=vn(this,t).delete(t),this.size-=t?1:0,t}function On(t){return wn(this,t).get(t)}function Sn(t){return _n(this,t).has(t)}function Cn(t,e){var o=bn(this,t),n=o.size;return o.set(t,e),this.size+=o.size==n?0:1,this}function Pn(t){var e=-1,o=null==t?0:t.length;for(this.clear();++e<o;){var n=t[e];this.set(n[0],n[1])}}Pn.prototype.clear=function(){this.size=0,this.__data__={hash:new dn,map:new(yn||fn),string:new dn}},Pn.prototype.delete=xn,Pn.prototype.get=On,Pn.prototype.has=Sn,Pn.prototype.set=Cn;var Jo=Pn,Ln=H,kn=o,An=Jo;function Mn(t,e){var o=this.__data__;if(o instanceof Ln){var n=o.__data__;if(!kn||n.length<199)return n.push([t,e]),this.size=++o.size,this;o=this.__data__=new An(n)}return o.set(t,e),this.size=o.size,this}var En=H,H=Po,jn=Lo,In=ko;function Tn(t){t=this.__data__=new En(t);this.size=t.size}Tn.prototype.clear=Co,Tn.prototype.delete=H,Tn.prototype.get=jn,Tn.prototype.has=In,Tn.prototype.set=Mn;H=Tn;function zn(t,e){for(var o=-1,n=null==t?0:t.length;++o<n&&!1!==e(t[o],o,t););return t}var Dn=tn,jn=function(){try{var t=Dn(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),Rn=jn;function Bn(t,e,o){"__proto__"==e&&Rn?Rn(t,e,{configurable:!0,enumerable:!0,value:o,writable:!0}):t[e]=o}var Fn=Bn,Nn=uo,Zn=Object.prototype.hasOwnProperty;function qn(t,e,o){var n=t[e];Zn.call(t,e)&&Nn(n,o)&&(void 0!==o||e in t)||Fn(t,e,o)}var Hn=qn,Un=Bn;function Wn(t,e,o,n){for(var r=!o,i=(o=o||{},-1),s=e.length;++i<s;){var a=e[i],c=n?n(o[a],t[a],a,o,t):void 0;void 0===c&&(c=t[a]),(r?Un:Hn)(o,a,c)}return o}function Gn(t,e){for(var o=-1,n=Array(t);++o<t;)n[o]=e(o);return n}function Vn(t){return null!=t&&"object"==typeof t}var Kn=Ro,Yn=Vn;var In=function(t){return Yn(t)&&"[object Arguments]"==Kn(t)},Jn=Vn,$n=Object.prototype,Xn=$n.hasOwnProperty,Qn=$n.propertyIsEnumerable,$n=In(function(){return arguments}())?In:function(t){return Jn(t)&&Xn.call(t,"callee")&&!Qn.call(t,"callee")},In=Array.isArray,tr={exports:{}};i=(i=(r=tr).exports)&&!i.nodeType&&i,er=(er=i&&r&&!r.nodeType&&r)&&er.exports===i?e.Buffer:void 0,i=er?er.isBuffer:void 0,r.exports=i||function(){return!1};var er=tr.exports,or=/^(?:0|[1-9]\d*)$/;function nr(t,e){var o=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==o||"symbol"!=o&&or.test(t))&&-1<t&&t%1==0&&t<e}function rr(t){return"number"==typeof t&&-1<t&&t%1==0&&t<=9007199254740991}var ir=Ro,sr=rr,ar=Vn,n={};n["[object Float32Array]"]=n["[object Float64Array]"]=n["[object Int8Array]"]=n["[object Int16Array]"]=n["[object Int32Array]"]=n["[object Uint8Array]"]=n["[object Uint8ClampedArray]"]=n["[object Uint16Array]"]=n["[object Uint32Array]"]=!0,n["[object Arguments]"]=n["[object Array]"]=n["[object ArrayBuffer]"]=n["[object Boolean]"]=n["[object DataView]"]=n["[object Date]"]=n["[object Error]"]=n["[object Function]"]=n["[object Map]"]=n["[object Number]"]=n["[object Object]"]=n["[object RegExp]"]=n["[object Set]"]=n["[object String]"]=n["[object WeakMap]"]=!1;function cr(t){return ar(t)&&sr(t.length)&&!!n[ir(t)]}function lr(e){return function(t){return e(t)}}var ur,pr,r={exports:{}},R=(tr=(tr=(i=r).exports)&&!tr.nodeType&&tr,ur=tr&&i&&!i.nodeType&&i,pr=ur&&ur.exports===tr&&R.process,tr=function(){try{var t=ur&&ur.require&&ur.require("util").types;return t?t:pr&&pr.binding&&pr.binding("util")}catch(t){}}(),i.exports=tr,r.exports),i=cr,tr=lr,r=R&&R.isTypedArray,tr=r?tr(r):i,hr=Gn,dr=$n,fr=In,yr=er,mr=nr,gr=tr,vr=Object.prototype.hasOwnProperty;function wr(t,e){var o,n=fr(t),r=!n&&dr(t),i=!n&&!r&&yr(t),s=!n&&!r&&!i&&gr(t),a=n||r||i||s,c=a?hr(t.length,String):[],l=c.length;for(o in t)!e&&!vr.call(t,o)||a&&("length"==o||i&&("offset"==o||"parent"==o)||s&&("buffer"==o||"byteLength"==o||"byteOffset"==o)||mr(o,l))||c.push(o);return c}var _r=Object.prototype;function br(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||_r)}function xr(e,o){return function(t){return e(o(t))}}var r=xr(Object.keys,Object),Or=br,Sr=r,Cr=Object.prototype.hasOwnProperty;var Pr=Zo,Lr=rr;function kr(t){return null!=t&&Lr(t.length)&&!Pr(t)}var Ar=wr,Mr=function(t){if(!Or(t))return Sr(t);var e,o=[];for(e in Object(t))Cr.call(t,e)&&"constructor"!=e&&o.push(e);return o},Er=kr;function jr(t){return(Er(t)?Ar:Mr)(t)}var Ir=Wn,Tr=jr;function zr(t,e){return t&&Ir(e,Tr(e),t)}var Dr=Bo,Rr=br,Br=function(t){var e=[];if(null!=t)for(var o in Object(t))e.push(o);return e},Fr=Object.prototype.hasOwnProperty;var Nr=wr,Zr=function(t){if(!Dr(t))return Br(t);var e,o=Rr(t),n=[];for(e in t)("constructor"!=e||!o&&Fr.call(t,e))&&n.push(e);return n},qr=kr;function Hr(t){return qr(t)?Nr(t,!0):Zr(t)}var Ur=Wn,Wr=Hr;function Gr(t,e){return t&&Ur(e,Wr(e),t)}var Vr,i={exports:{}},Kr=(Kr=(Kr=(r=i).exports)&&!Kr.nodeType&&Kr,s=(s=Kr&&r&&!r.nodeType&&r)&&s.exports===Kr?e.Buffer:void 0,Vr=s?s.allocUnsafe:void 0,r.exports=function(t,e){return e?t.slice():(e=t.length,e=Vr?Vr(e):new t.constructor(e),t.copy(e),e)},i.exports);function Yr(t,e){var o=-1,n=t.length;for(e=e||Array(n);++o<n;)e[o]=t[o];return e}function Jr(){return[]}var $r=function(t,e){for(var o=-1,n=null==t?0:t.length,r=0,i=[];++o<n;){var s=t[o];e(s,o,t)&&(i[r++]=s)}return i},Xr=Object.prototype.propertyIsEnumerable,Qr=Object.getOwnPropertySymbols,s=Qr?function(e){return null==e?[]:(e=Object(e),$r(Qr(e),function(t){return Xr.call(e,t)}))}:Jr,ti=Wn,ei=s;function oi(t,e){return ti(t,ei(t),e)}function ni(t,e){for(var o=-1,n=e.length,r=t.length;++o<n;)t[r+o]=e[o];return t}var r=xr(Object.getPrototypeOf,Object),ri=ni,ii=r,si=s,i=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)ri(e,si(t)),t=ii(t);return e}:Jr,ai=Wn,ci=i;function li(t,e){return ai(t,ci(t),e)}var ui=ni,pi=In;function hi(t,e,o){return e=e(t),pi(t)?e:ui(e,o(t))}var di=hi,fi=s,yi=jr;function mi(t){return di(t,yi,fi)}var gi=hi,vi=i,wi=Hr;function _i(t){return gi(t,wi,vi)}var s=tn(e,"DataView"),i=o,o=tn(e,"Promise"),bi=tn(e,"Set"),xi=tn(e,"WeakMap"),Oi=Ro,Si=Uo,Ci="[object Map]",Pi="[object Promise]",Li="[object Set]",ki="[object WeakMap]",Ai="[object DataView]",Mi=Si(s),Ei=Si(i),ji=Si(o),Ii=Si(bi),Ti=Si(xi),a=Oi,s=a=s&&a(new s(new ArrayBuffer(1)))!=Ai||i&&a(new i)!=Ci||o&&a(o.resolve())!=Pi||bi&&a(new bi)!=Li||xi&&a(new xi)!=ki?function(t){var e=Oi(t),t="[object Object]"==e?t.constructor:void 0,t=t?Si(t):"";if(t)switch(t){case Mi:return Ai;case Ei:return Ci;case ji:return Pi;case Ii:return Li;case Ti:return ki}return e}:a,zi=Object.prototype.hasOwnProperty;function Di(t){var e=t.length,o=new t.constructor(e);return e&&"string"==typeof t[0]&&zi.call(t,"index")&&(o.index=t.index,o.input=t.input),o}var i=e.Uint8Array,Ri=i;function Bi(t){var e=new t.constructor(t.byteLength);return new Ri(e).set(new Ri(t)),e}var Fi=Bi;var Ni=/\w*$/;var o=Ao?Ao.prototype:void 0,Zi=o?o.valueOf:void 0;var qi=Bi;function Hi(t,e){return e=e?qi(t.buffer):t.buffer,new t.constructor(e,t.byteOffset,t.length)}var Ui=Bi,Wi=function(t,e){return e=e?Fi(t.buffer):t.buffer,new t.constructor(e,t.byteOffset,t.byteLength)},Gi=function(t){var e=new t.constructor(t.source,Ni.exec(t));return e.lastIndex=t.lastIndex,e},Vi=function(t){return Zi?Object(Zi.call(t)):{}},Ki=Hi;function Yi(t,e,o){var n=t.constructor;switch(e){case"[object ArrayBuffer]":return Ui(t);case"[object Boolean]":case"[object Date]":return new n(+t);case"[object DataView]":return Wi(t,o);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Ki(t,o);case"[object Map]":return new n;case"[object Number]":case"[object String]":return new n(t);case"[object RegExp]":return Gi(t);case"[object Set]":return new n;case"[object Symbol]":return Vi(t)}}var Ji=Bo,$i=Object.create;function Xi(){}var Qi=function(t){if(!Ji(t))return{};if($i)return $i(t);Xi.prototype=t;t=new Xi;return Xi.prototype=void 0,t},ts=r,es=br;function os(t){return"function"!=typeof t.constructor||es(t)?{}:Qi(ts(t))}var ns=s,rs=Vn;function is(t){return rs(t)&&"[object Map]"==ns(t)}var bi=lr,xi=R&&R.isMap,a=xi?bi(xi):is,ss=s,as=Vn;function cs(t){return as(t)&&"[object Set]"==ss(t)}var e=lr,o=R&&R.isSet,bi=o?e(o):cs,ls=H,us=zn,ps=qn,hs=zr,ds=Gr,fs=Kr,ys=Yr,ms=oi,gs=li,vs=mi,ws=_i,_s=s,bs=Di,xs=Yi,Os=os,Ss=In,Cs=er,Ps=a,Ls=Bo,ks=bi,As=jr,Ms=Hr,Es="[object Arguments]",js="[object Function]",Is="[object Object]",d={};d[Es]=d["[object Array]"]=d["[object ArrayBuffer]"]=d["[object DataView]"]=d["[object Boolean]"]=d["[object Date]"]=d["[object Float32Array]"]=d["[object Float64Array]"]=d["[object Int8Array]"]=d["[object Int16Array]"]=d["[object Int32Array]"]=d["[object Map]"]=d["[object Number]"]=d[Is]=d["[object RegExp]"]=d["[object Set]"]=d["[object String]"]=d["[object Symbol]"]=d["[object Uint8Array]"]=d["[object Uint8ClampedArray]"]=d["[object Uint16Array]"]=d["[object Uint32Array]"]=!0,d["[object Error]"]=d[js]=d["[object WeakMap]"]=!1;function Ts(o,n,r,t,e,i){var s,a=1&n,c=2&n,l=4&n;if(void 0===(s=r?e?r(o,t,e,i):r(o):s)){if(!Ls(o))return o;if(t=Ss(o)){if(s=bs(o),!a)return ys(o,s)}else{var u=_s(o),p=u==js||"[object GeneratorFunction]"==u;if(Cs(o))return fs(o,a);if(u==Is||u==Es||p&&!e){if(s=c||p?{}:Os(o),!a)return c?gs(o,ds(s,o)):ms(o,hs(s,o))}else{if(!d[u])return e?o:{};s=xs(o,u,a)}}if(p=(i=i||new ls).get(o))return p;i.set(o,s),ks(o)?o.forEach(function(t){s.add(Ts(t,n,r,t,o,i))}):Ps(o)&&o.forEach(function(t,e){s.set(e,Ts(t,n,r,e,o,i))});var h=t?void 0:(l?c?ws:vs:c?Ms:As)(o);us(h||o,function(t,e){h&&(t=o[e=t]),ps(s,e,Ts(t,n,r,e,o,i))})}return s}var zs=Ts;var c=B(function(t){return zs(t,5)}),Ds=Bn,Rs=uo;function Bs(t,e,o){(void 0===o||Rs(t[e],o))&&(void 0!==o||e in t)||Ds(t,e,o)}var xi=function(c){return function(t,e,o){for(var n=-1,r=Object(t),i=o(t),s=i.length;s--;){var a=i[c?s:++n];if(!1===e(r[a],a,r))break}return t}}(),Fs=kr,Ns=Vn;function Zs(t){return Ns(t)&&Fs(t)}var qs=Ro,Hs=r,Us=Vn,R=Function.prototype,e=Object.prototype,Ws=R.toString,Gs=e.hasOwnProperty,Vs=Ws.call(Object);function Ks(t){return!(!Us(t)||"[object Object]"!=qs(t))&&(null===(t=Hs(t))||"function"==typeof(t=Gs.call(t,"constructor")&&t.constructor)&&t instanceof t&&Ws.call(t)==Vs)}function Ys(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Js=Wn,$s=Hr;var Xs=Bs,Qs=Kr,ta=Hi,ea=Yr,oa=os,na=$n,ra=In,ia=Zs,sa=er,aa=Zo,ca=Bo,la=Ks,ua=tr,pa=Ys,ha=function(t){return Js(t,$s(t))};var da=H,fa=Bs,ya=xi,ma=function(t,e,o,n,r,i,s){var a,c,l,u=pa(t,o),p=pa(e,o),h=s.get(p);h||((e=void 0===(h=i?i(u,p,o+"",t,e,s):void 0))&&(c=!(a=ra(p))&&sa(p),l=!a&&!c&&ua(p),h=p,a||c||l?h=ra(u)?u:ia(u)?ea(u):c?Qs(p,!(e=!1)):l?ta(p,!(e=!1)):[]:la(p)||na(p)?na(h=u)?h=ha(u):ca(u)&&!aa(u)||(h=oa(p)):e=!1),e&&(s.set(p,h),r(h,p,n,i,s),s.delete(p))),Xs(t,o,h)},ga=Bo,va=Hr,wa=Ys;function _a(t){return t}var ba=function(t,e,o){switch(o.length){case 0:return t.call(e);case 1:return t.call(e,o[0]);case 2:return t.call(e,o[0],o[1]);case 3:return t.call(e,o[0],o[1],o[2])}return t.apply(e,o)},xa=Math.max;var Oa=function(t){return function(){return t}},Sa=jn,Ca=Date.now;var o=function(o){var n=0,r=0;return function(){var t=Ca(),e=16-(t-r);if(r=t,0<e){if(800<=++n)return arguments[0]}else n=0;return o.apply(void 0,arguments)}}(Sa?function(t,e){return Sa(t,"toString",{configurable:!0,enumerable:!1,value:Oa(e),writable:!0})}:_a),Pa=_a,La=function(i,s,a){return s=xa(void 0===s?i.length-1:s,0),function(){for(var t=arguments,e=-1,o=xa(t.length-s,0),n=Array(o);++e<o;)n[e]=t[s+e];for(var e=-1,r=Array(s+1);++e<s;)r[e]=t[e];return r[s]=a(n),ba(i,this,r)}},ka=o;var Aa=uo,Ma=kr,Ea=nr,ja=Bo;var Ia=function(t,e){return ka(La(t,e,Pa),t+"")},Ta=function(t,e,o){var n;return!!ja(o)&&!!("number"==(n=typeof e)?Ma(o)&&Ea(e,o.length):"string"==n&&e in o)&&Aa(o[e],t)};var za,Da,Ra=function n(r,i,s,a,c){r!==i&&ya(i,function(t,e){var o;c=c||new da,ga(t)?ma(r,i,e,s,n,a,c):(o=a?a(wa(r,e),t,e+"",r,i,c):void 0,fa(r,e,o=void 0===o?t:o))},va)},Ba=B(function(a){return Ia(function(t,e){var o=-1,n=e.length,r=1<n?e[n-1]:void 0,i=2<n?e[2]:void 0,r=3<a.length&&"function"==typeof r?(n--,r):void 0;for(i&&Ta(e[0],e[1],i)&&(r=n<3?void 0:r,n=1),t=Object(t);++o<n;){var s=e[o];s&&a(t,s,o,r)}return t})}(function(t,e,o){Ra(t,e,o)})),Fa=((window&&window.__extends||(za=function(t,e){return(za=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}za(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Na,Da=t),Na);function Na(){var t=null!==Da&&Da.apply(this,arguments)||this;return t.layout="icons",t.mapStyles=["road","grayscale_light","grayscale_dark","night","road_shaded_relief"],t.style=u.ControlStyle.light,t.autoSelectionMode=!0,t}var Za,qa,a=window&&window.__extends||(Za=function(t,e){return(Za=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Za(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ha=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},Ua=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},Wa=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},bi=(a(l,qa=We),l.prototype.onAdd=function(t,e){function o(t){t?(r.classList.add(l.Css.inUse),i.classList.remove("hidden-accessible-element")):(r.classList.remove(l.Css.inUse),i.classList.add("hidden-accessible-element"))}var n=this,r=(this.map=t,this.buildContainer(t,this.options.style,"Map Style Control")),i=this.buildStyleOpsGrid(),s=(this.styleOpsGrid=i,this.buildCurrStyleBtn()),t=_("Select Style");return i.classList.add(e&&e.position||"top-right"),r.addEventListener("mouseover",function(){n.hasMouse=!0,o(!0)}),r.addEventListener("focusin",function(){n.hasFocus=!0,o(!0)}),r.addEventListener("mouseleave",function(){n.hasMouse=!1,n.hasFocus||o(!1)}),r.addEventListener("focusout",function(t){t.target===s&&Array.from(i.children).forEach(function(t){return t.removeAttribute("tabIndex")}),t.relatedTarget instanceof Node&&r.contains(t.relatedTarget)||(n.hasFocus=!1,n.hasMouse)||o(!1)}),i.addEventListener("keydown",function(t){27===t.keyCode&&(t.stopPropagation(),s.focus(),Array.from(i.children).forEach(function(t){return t.setAttribute("tabIndex","-1")}),r.classList.contains(l.Css.inUse))&&o(!1)}),s.addEventListener("click",function(t){r.classList.contains(l.Css.inUse)?o(!1):(o(!0),i.firstElementChild&&i.firstElementChild.focus())}),e&&l.InvertOrderPositions.includes(e.position)?(r.appendChild(i),r.appendChild(s),r.appendChild(t),b(t,s)):(r.appendChild(s),r.appendChild(t),b(t,s),r.appendChild(i)),r},l.prototype.onRemove=function(){qa.prototype.onRemove.call(this),this.styleOpsGrid=null,this.styleButtons.clear(),this.thumbnailCache.response.clear(),this.thumbnailCache.blob.clear(),this.thumbnailCache.assumedConfiguration=void 0,this.map.events.remove("stylechanged",this.onStyleChange),this.map.events.remove("mapconfigurationchanged",this.onMapConfigurationChange)},l.prototype.setSelectedStyle=function(o){var e,t,n=this;this.styleIcons.has(o)&&(e=this.currStyleImage,t=this.styleIcons.get(o),e.src!==t&&(e.src=t),Object.entries(this.styleButtons).forEach(function(t){var t=Wa(t,2),e=t[0];return t[1].setAttribute("aria-current",e===o?"true":"false")}),this.map.styles.definitions().then(function(t){t=n.mapToFriendlyStyleName(o,t);e.alt!==t&&(e.alt=t),e.parentElement.lastChild instanceof Text&&(e.parentElement.lastChild.textContent=t)}))},l.prototype.disableStyle=function(t){t=this.styleButtons[t];t&&t.setAttribute("disabled","true")},l.prototype.enableStyle=function(t){t=this.styleButtons[t];t&&t.removeAttribute("disabled")},l.prototype.buildSelectStyleBtn=function(o,t,e){var n=this,r=document.createElement("button"),i=this.mapToFriendlyStyleName(o,t),s=(r.setAttribute("aria-label",i),r.setAttribute("type","button"),new Image),t=(e.then(function(t){var e;return n.thumbnailCache.blob.has(t.url)?n.thumbnailCache.blob.get(t.url):(e=t.clone().blob(),n.thumbnailCache.blob.set(t.url,e),e)}).then(function(t){t=URL.createObjectURL(t);s.src=t,o===n.map.getStyle().style&&(n.currStyleImage.src=t,n.currStyleImage.alt=i,n.currStyleImage.parentElement.lastChild.nodeType==Node.TEXT_NODE?n.currStyleImage.parentElement.lastChild.textContent=i:n.currStyleImage.parentElement.appendChild(document.createTextNode(i))),n.styleIcons.set(o,t)}),s.setAttribute("aria-hidden","true"),r.appendChild(s),"icons"===this.options.layout?r.classList.add(l.Css.button):(r.classList.add(l.Css.listButton),r.classList.add(l.Css.expanded),r.appendChild(document.createTextNode(i))),r.addEventListener("click",function(){n.hasMouse=!1,n.hasFocus=!1;var t=n.styleButtons[o];t&&!t.hasAttribute("disabled")&&(n._invokeEvent("styleselected",o),n.options.autoSelectionMode&&n.map.setStyle({style:o}),Object.entries(n.styleButtons).forEach(function(t){var t=Wa(t,2),e=t[0];return t[1].setAttribute("aria-current",e===o?"true":"false")}))}),document.createElement("div"));return t.classList.add("selected-icon"),r.appendChild(t),r},l.prototype.buildCurrStyleBtn=function(){var t=document.createElement("button"),e=("icons"==this.options.layout?t.classList.add(l.Css.button):t.classList.add(l.Css.listButton),t.classList.add(l.Css.currentStyle),t.setAttribute("aria-label","Select Style"),t.setAttribute("tabindex","-1"),this.currStyleImage=new Image,t.appendChild(this.currStyleImage),document.createElement("div"));return e.classList.add("icon"),t.appendChild(e),t},l.prototype.buildStyleOpsGrid=function(){var t=this,e=document.createElement("div");return e.classList.add(l.Css.styleOptions),"icons"===this.options.layout?e.classList.add(this.options.layout):e.classList.add(l.Css.dropdown),e.setAttribute("aria-label","Style Options"),e.classList.add("hidden-accessible-element"),this.map.styles.definitions().then(function(e){return Ha(t,void 0,void 0,function(){return Ua(this,function(t){return this.onMapConfigurationChange(e),this.map.events.add("stylechanged",this.onStyleChange),[2]})})}),this.map.events.add("mapconfigurationchanged",this.onMapConfigurationChange),e},l.prototype.populateOpsGridFromDefinitions=function(r){var t,o,i=this;this.styleOpsGrid&&(t=r.configurations,(t=Array.isArray(this.options.mapStyles)?t.filter(function(t){return i.options.mapStyles.includes(t.name.split("_indoor")[0])}):t).forEach(function(t){var e,o={url:t.thumbnail},n=(t.thumbnail&&i.map.styles._transformStyleRequest(t.thumbnail,o),i.map.getServiceOptions()),n=(n.transformRequest&&Ba(o,n.transformRequest(o.url,"Thumbnail")),i.thumbnailCache.response.has(o.url)?e=Promise.resolve(i.thumbnailCache.response.get(o.url)):(e=fetch(o.url,{headers:o.headers}),i.thumbnailCache.response.set(o.url,e)),i.buildSelectStyleBtn(t.name,r,e));i.styleOpsGrid.appendChild(n),i.styleButtons[t.name]=n,"icons"===i.options.layout&&(o=_(i.mapToFriendlyStyleName(t.name,r)),i.styleOpsGrid.appendChild(o),b(o,n))}),o=this.map.getStyle().style,Object.entries(this.styleButtons).forEach(function(t){var t=Wa(t,2),e=t[0];return t[1].setAttribute("aria-current",e===o?"true":"false")}))},l.InvertOrderPositions=[u.ControlPosition.TopRight,u.ControlPosition.BottomRight],l.Css={button:"azure-maps-control-button",listButton:"azure-maps-control-list-button",expanded:"expanded",currentStyle:"curr-style",inUse:"in-use",styleOptions:"style-options",dropdown:"azure-maps-control-dropdown"},l);function l(t){var e=qa.call(this)||this;return e.styleOpsGrid=null,e.hasMouse=!1,e.hasFocus=!1,e.styleButtons=new Ne,e.styleIcons=new Ne,e.thumbnailCache={assumedConfiguration:void 0,response:new Ne,blob:new Ne},e.onStyleChange=function(){var t;e.options.autoSelectionMode&&(t=e.map.getStyle().style,e.setSelectedStyle(t))},e.onMapConfigurationChange=function(t){!e.styleOpsGrid||0<e.styleOpsGrid.children.length&&e.thumbnailCache.assumedConfiguration===t||(e.thumbnailCache.assumedConfiguration=t,Array.from(e.styleOpsGrid.children).forEach(function(t){return t.remove()}),e.styleButtons.clear(),e.populateOpsGridFromDefinitions(t))},e.mapToFriendlyStyleName=function(e,t){t=t.configurations.find(function(t){return t.name===e});return(null==t?void 0:t.displayName)||e},e.options=(new Fa).merge(c(t)),e}(window&&window.__extends||(Ga=function(t,e){return(Ga=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ga(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ya,Va=t);var Ga,Va,Ka=Ya;function Ya(){var t=null!==Va&&Va.apply(this,arguments)||this;return t.flow="none",t.incidents=!1,t}(window&&window.__extends||(Ja=function(t,e){return(Ja=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ja(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Qa,$a=Ka);var Ja,$a,Xa=Qa;function Qa(){var t=null!==$a&&$a.apply(this,arguments)||this;return t.isActive=!1,t.style=u.ControlStyle.light,t}(window&&window.__extends||(tc=function(t,e){return(tc=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}tc(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(nc,ec=We),Object.defineProperty(nc.prototype,"isActive",{get:function(){var t;return!!this.map&&("none"!==(t=this.map.getTraffic()).flow||t.incidents)},set:function(t){this.map&&this.map.setTraffic({flow:t?this.options.flow:"none",incidents:!!t&&this.options.incidents})},enumerable:!1,configurable:!0}),nc.prototype.onAdd=function(t){(this.map=t).getTraffic(),void 0!==this.initIsActive&&(this.isActive=this.initIsActive),this.container=this.buildContainer(t,this.style,"Traffic Control"),this.container.style.flexDirection="column";var t=this.constructTrafficButton(t),e=(this.container.appendChild(t),_("Toggle Traffic Display"));return this.container.appendChild(e),b(e,t),this.container},nc.prototype.onRemove=function(){ec.prototype.onRemove.call(this),this.map=null},nc.prototype.getOptions=function(){return(new Xa).merge({isActive:this.isActive,flow:this.options.flow,incidents:this.options.incidents,style:this.style})},nc.prototype.updateButtonState=function(){this.trafficButton&&(this.isActive?(this.container.classList.add("in-use"),this.trafficButton.setAttribute("aria-description","Traffic is displayed")):(this.container.classList.remove("in-use"),this.trafficButton.removeAttribute("aria-description")),this.trafficButton.setAttribute("aria-pressed",this.isActive?"true":"false"))},nc.prototype.constructTrafficButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("traffic"),o.setAttribute("aria-label","Toggle Traffic Display"),o.setAttribute("alt","Toggle Traffic Display"),o.setAttribute("type","button"),this.trafficButton=o,this.updateButtonState(),o.addEventListener("click",function(){e.isActive=!e.isActive}),o};var tc,ec,oc=nc;function nc(t){var e,o=this;return(o=ec.call(this)||this).hasMouse=!1,o.hasFocus=!1,o.options=(new Ka).merge({flow:"relative",incidents:!0}),o.style=u.ControlStyle.light,o.container=null,o.trafficButton=null,o.map=null,t&&(o.initIsActive=null!=(e=t.isActive)&&e,o.options.flow=t.flow||"relative",o.options.incidents=null==(e=t.incidents)||e,o.style=t.style||u.ControlStyle.light),o}var rc,ic,r=window&&window.__extends||(rc=function(t,e){return(rc=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}rc(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),sc=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},R=(r(ac,ic=We),ac.prototype.onAdd=function(t){this.map=t;var e=this.buildContainer(t,u.ControlStyle.auto,"Traffic Legend"),t=this.buildTrafficLegendDiv(t);return e.setAttribute("role","definition"),e.appendChild(t),e},ac.prototype.onRemove=function(){ic.prototype.onRemove.call(this),this.syncHiddenState&&(this.map.events.remove("styledata",this.syncHiddenState),this.syncHiddenState=null),this.map=null},ac.prototype.buildTrafficLegendDiv=function(e){var o,t,n,r,i=document.createElement("div"),s=(i.classList.add("traffic-legend","hidden"),i.setAttribute("alt","Traffic Legend"),document.createElement("table")),a=document.createElement("tr"),c=document.createElement("td"),l=(c.setAttribute("alt","Traffic"),c.appendChild(document.createTextNode("Traffic")),_("Traffic")),u=(c.classList.add("traffic-legend-title"),c.colSpan=6,a.appendChild(c),a.appendChild(l),b(l,c),s.appendChild(a),document.createElement("tr"));try{for(var p=sc(this.table),h=p.next();!h.done;h=p.next()){var d=h.value,f=document.createElement("td");if("Fast"===d||"Slow"===d)f.setAttribute("alt",d),f.appendChild(document.createTextNode(d)),f.classList.add("traffic-legend-text");else{f.classList.add("traffic-legend-colors"),f.setAttribute("aria-label","Traffic Legend"),f.setAttribute("role","img");try{n=void 0;for(var y=sc(d),m=y.next();!m.done;m=y.next()){var g=m.value,v=document.createElement("div");v.classList.add(g),f.appendChild(v)}}catch(t){n={error:t}}finally{try{m&&!m.done&&(r=y.return)&&r.call(y)}finally{if(n)throw n.error}}}u.appendChild(f);var w=_(d instanceof Array?"Traffic Legend":d);u.appendChild(w),b(w,f)}}catch(t){o={error:t}}finally{try{h&&!h.done&&(t=p.return)&&t.call(p)}finally{if(o)throw o.error}}return s.appendChild(u),i.appendChild(s),this.syncHiddenState=function(t){"style"===t.dataType&&((t=e.getTraffic()).flow&&"none"!==t.flow?i.classList.remove("hidden"):i.classList.add("hidden"))},this.syncHiddenState({dataType:"style"}),e.events.add("styledata",this.syncHiddenState),i},ac);function ac(){var t=ic.call(this)||this;return t.table=["Fast",["green","yellow","red","dark-red"],"Slow"],t.map=null,t.syncHiddenState=null,t}function cc(t){return this.__data__.has(t)}var lc=Jo;function uc(t){var e=-1,o=null==t?0:t.length;for(this.__data__=new lc;++e<o;)this.add(t[e])}uc.prototype.add=uc.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},uc.prototype.has=cc;var pc=uc,hc=function(t,e){for(var o=-1,n=null==t?0:t.length;++o<n;)if(e(t[o],o,t))return!0;return!1},dc=function(t,e){return t.has(e)};function fc(t,e,o,n,r,i){var s=1&o,a=t.length,c=e.length;if(a!=c&&!(s&&a<c))return!1;var c=i.get(t),l=i.get(e);if(c&&l)return c==e&&l==t;var u=-1,p=!0,h=2&o?new pc:void 0;for(i.set(t,e),i.set(e,t);++u<a;){var d,f=t[u],y=e[u];if(void 0!==(d=n?s?n(y,f,u,e,t,i):n(f,y,u,t,e,i):d)){if(d)continue;p=!1;break}if(h){if(!hc(e,function(t,e){if(!dc(h,e)&&(f===t||r(f,t,o,n,i)))return h.push(e)})){p=!1;break}}else if(f!==y&&!r(f,y,o,n,i)){p=!1;break}}return i.delete(t),i.delete(e),p}function yc(t){var o=-1,n=Array(t.size);return t.forEach(function(t,e){n[++o]=[e,t]}),n}function mc(t){var e=-1,o=Array(t.size);return t.forEach(function(t){o[++e]=t}),o}var gc=i,vc=uo,wc=fc,e=Ao?Ao.prototype:void 0,_c=e?e.valueOf:void 0;var bc=mi,xc=Object.prototype.hasOwnProperty;var Oc=H,Sc=fc,Cc=function(t,e,o,n,r,i,s){switch(o){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return t.byteLength==e.byteLength&&i(new gc(t),new gc(e))?!0:!1;case"[object Boolean]":case"[object Date]":case"[object Number]":return vc(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var a=yc;case"[object Set]":a=a||mc;if(t.size!=e.size&&!(1&n))return!1;var c=s.get(t);if(c)return c==e;n|=2,s.set(t,e);c=wc(a(t),a(e),n,r,i,s);return s.delete(t),c;case"[object Symbol]":if(_c)return _c.call(t)==_c.call(e)}return!1},Pc=function(t,e,o,n,r,i){var s=1&o,a=bc(t),c=a.length;if(c!=bc(e).length&&!s)return!1;for(var l=c;l--;){var u=a[l];if(!(s?u in e:xc.call(e,u)))return!1}var p=i.get(t),h=i.get(e);if(p&&h)return p==e&&h==t;for(var d=!0,f=(i.set(t,e),i.set(e,t),s);++l<c;){var y,m=t[u=a[l]],g=e[u];if(!(void 0===(y=n?s?n(g,m,u,e,t,i):n(m,g,u,t,e,i):y)?m===g||r(m,g,o,n,i):y)){d=!1;break}f=f||"constructor"==u}return d&&!f&&(p=t.constructor)!=(h=e.constructor)&&"constructor"in t&&"constructor"in e&&!("function"==typeof p&&p instanceof p&&"function"==typeof h&&h instanceof h)&&(d=!1),i.delete(t),i.delete(e),d},Lc=s,kc=In,Ac=er,Mc=tr,Ec="[object Arguments]",jc="[object Array]",Ic="[object Object]",Tc=Object.prototype.hasOwnProperty;var zc=function(t,e,o,n,r,i){var s=kc(t),a=kc(e),c=s?jc:Lc(t),a=a?jc:Lc(e),l=(c=c==Ec?Ic:c)==Ic,u=(a=a==Ec?Ic:a)==Ic;if((a=c==a)&&Ac(t)){if(!Ac(e))return!1;l=!(s=!0)}if(a&&!l)return i=i||new Oc,s||Mc(t)?Sc(t,e,o,n,r,i):Cc(t,e,c,o,n,r,i);if(!(1&o)){s=l&&Tc.call(t,"__wrapped__"),c=u&&Tc.call(e,"__wrapped__");if(s||c)return r(s?t.value():t,c?e.value():e,o,n,i=i||new Oc)}return a&&(i=i||new Oc,Pc(t,e,o,n,r,i))},Dc=Vn;var Rc=function t(e,o,n,r,i){return e===o||(null==e||null==o||!Dc(e)&&!Dc(o)?e!=e&&o!=o:zc(e,o,n,r,t,i))};var Bc=B(function(t,e){return Rc(t,e)}),Fc=(Nc.TYPE="Feature",Nc);function Nc(t,e,o,n){this.type="Feature",this.type=Nc.TYPE,this.properties=e||{},this.id=o,this.geometry=t,this.bbox=n}var Zc,qc,Kr=window&&window.__extends||(Zc=function(t,e){return(Zc=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Zc(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Hc=(qc=Array,Kr(p,qc),p.fromData=function(o){var n=NaN,r=NaN,i=new Set(["y"]),s=new Set(["x"]);return Object.keys(o).forEach(function(t){var e=t.toLowerCase();isNaN(n)&&i.has(e)&&"number"==typeof o[t]?n=o[t]:isNaN(r)&&s.has(e)&&"number"==typeof o[t]&&(r=o[t])}),isNaN(n)||isNaN(r)?null:new p(n,r)},p.getX=function(t){return 0<t.length?t[0]:NaN},p.getY=function(t){return 1<t.length?t[1]:NaN},p.getDestination=function(t,e,o){return new p(p.getX(t)+o*Math.cos((e+270)*Math.PI/180),p.getY(t)+o*Math.sin((e+270)*Math.PI/180))},p.getDistance=function(t,e){var o=p.getX(t)-p.getX(e),t=p.getY(t)-p.getY(e);return Math.sqrt(o*o+t*t)},p.getHeading=function(t,e){var o=p.getX(e)-p.getX(t),t=p.getY(t)-p.getY(e);return 180*(2.5*Math.PI-Math.atan2(t,o))/Math.PI%360},p);function p(t,e){return qc.call(this,t,e)||this}Wc.TYPE="Point";var Uc=Wc;function Wc(t){this.type="Point",this.type=Wc.TYPE,this.coordinates=t}var h,f,y,m,g,Gc=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Vc=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Kc=6378137,Yc=Math.PI/180,Jc=180/Math.PI,$c=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9],Xc=85.0511;function Qc(t){return t*Yc}function tl(t){return t*Jc}function el(t,e,o){return Math.min(Math.max(t,e),o)}function ol(t,e){var o=Qc(e[1]-t[1]),n=Qc(e[0]-t[0]),o=Math.pow(Math.sin(o/2),2)+Math.cos(Qc(t[1]))*Math.cos(Qc(e[1]))*Math.pow(Math.sin(n/2),2),t=2*Math.atan2(Math.sqrt(o),Math.sqrt(1-o));return Math.round(Kc*t*100)/100}function nl(t){if(t)switch(t.toLowerCase()){case"feet":case"foot":case"ft":return f.feet;case"kilometers":case"kilometer":case"kilometres":case"kilometre":case"km":case"kms":return f.kilometers;case"miles":case"mile":case"mi":return f.miles;case"nauticalmiles":case"nauticalmile":case"nms":case"nm":return f.nauticalMiles;case"yards":case"yard":case"yds":case"yrd":case"yrds":return f.yards;default:return f.meters}return f.meters}function rl(t){if(t)switch(t.toLowerCase()){case"milespersecondsquared":case"milepersecondsquared":case"mi/s^2":case"mi/s2":return g.milesPerSecondSquared;case"kilometerspersecondsquared":case"kilometrespersecondsquared":case"kilometerpersecondsquared":case"kilometrepersecondsquared":case"km/s^2":case"km/s2":return g.kilometersPerSecondSquared;case"knotspersecond":case"knotpersecond":case"knts/s":case"kn/s":case"kt/s":return g.knotsPerSecond;case"standardgravity":case"g":return g.standardGravity;case"feetpersecondsquared":case"footpersecondsquared":case"ft/s^2":case"ft/s2":return g.feetPerSecondSquared;case"yardspersecondsquared":case"yardpersecondsquared":case"yds/s^2":case"yds/s2":case"yd/s^2":case"yd/s2":return g.yardsPerSecondSquared;case"milesperhoursecond":case"mileperhoursecond":case"milesperhourseconds":case"mileperhourseconds":case"mi/h/s":return g.milesPerHourSecond;case"kilometersperhoursecond":case"kilometrespersoursecond":case"kilometerperhoursecond":case"kilometrepersoursecond":case"kilometersperhourssecond":case"kilometrespersourssecond":case"kilometerperhourssecond":case"kilometrepersourssecond":case"kmhs":case"km/h/s":return g.kilometersPerHourSecond;default:return g.metersPerSecondSquared}return g.metersPerSecondSquared}function il(t){if(t)switch(t){case"acres":case"ac":return h.acres;case"hectares":case"ha":return h.hectares;case"squareFeet":case"ft^2":case"ft2":return h.squareFeet;case"squareYards":case"squareYard":case"yds^2":case"yds2":case"yd^2":case"yd2":return h.squareYards;case"squareKilometers":case"squareKilometres":case"squareKilometer":case"squareKilometre":case"km^2":case"km2":return h.squareKilometers;case"squareMiles":case"squareMile":case"mi^2":case"mi2":return h.squareMiles;default:return h.squareMeters}return h.squareMeters}function sl(t){if(t)switch(t.toLowerCase()){case"feetpersecond":case"footsecond":case"ftps":case"ft/s":return m.feetPerSecond;case"milesperhour":case"mileperhour":case"mph":case"mi/hr":case"mi/h":return m.milesPerHour;case"knots":case"knot":case"knts":case"knt":case"kn":case"kt":return m.knots;case"mach":case"m":return m.mach;case"kilometersperhour":case"kilometresperhour":case"kmperhour":case"kmph":case"km/hr":case"km/h":return m.kilometersPerHour;default:return m.metersPerSecond}return m.metersPerSecond}function al(t){if(t)switch(t.toLowerCase()){case"milliseconds":case"ms":return y.ms;case"minutes":case"minute":case"mins":case"min":return y.minutes;case"hours":case"hour":case"hr":case"h":return y.hours;case"days":case"day":case"d":return y.days;default:return y.seconds}return y.seconds}function cl(t){var e=0;if(t&&0<t.length)for(var e=Math.abs(ll(t[0])),o=1,n=t.length;o<n;o++)e-=Math.abs(ll(t[o]));return e}function ll(t){var e=0;if(3<=t.length){for(var o=void 0,n=void 0,r=0,i=t.length;r<i;r++)e+=(Qc(t[r===i-2?(o=i-2,n=i-1,0):r===i-1?(o=i-1,n=0,1):(n=(o=r)+1,r+2)][0])-Qc(t[o][0]))*Math.sin(Qc(t[n][1]));e=e*Kc*Kc/2}return e}function ul(t,e,o){return(t[0]-o[0])*(e[1]-o[1])-(t[1]-o[1])*(e[0]-o[0])}function pl(t,e,o){if(2<=o.length){for(var n,r,i,s=1/0,a=null,c=Ll(o,22),l=0,u=c.length-1;l<u;l++)r=function(t,e,o){if(e[0]===o[0]&&e[1]===o[1])return e;var n=t[0]-e[0],t=t[1]-e[1],r=o[0]-e[0],i=o[1]-e[1],n=(r*n+i*t)/(r*r+i*i);return n<0?e:1<n?o:[e[0]+r*n,e[1]+i*n]}(e,c[l],c[l+1]),(n=Hc.getDistance(e,r))<s&&(s=n,a=r);if(a)return i=Pl([a],22)[0],new Fc(new Uc(i),{distance:yl(t,i)})}else if(1===o.length)return new Fc(new Uc(o[0]),{distance:yl(t,o[0])});return null}function hl(t,e){var o;return!isNaN(t)&&"number"==typeof e&&0<=e&&(o=void 0,o=e<$c.length?$c[e]:Math.pow(10,e),t=Math.round(t*o)/o),t}function dl(t,e,o,n){switch(nl(e)){case f.meters:t/=1e3;break;case f.feet:t/=3280.8399;break;case f.miles:t/=.62137119;break;case f.yards:t/=1093.6133;break;case f.nauticalMiles:t/=.5399568;break;case f.kilometers:}switch(nl(o)){case f.meters:t*=1e3;break;case f.feet:t*=3280.8399;break;case f.miles:t*=.62137119;break;case f.yards:t*=1093.6133;break;case f.nauticalMiles:t*=.5399568;break;case f.kilometers:}return"number"==typeof n&&0<=n&&(e=Math.pow(10,n),t=Math.round(t*e)/e),t}function fl(t,e,o,n){n=n||"meters",t=Rl(t);var n=ml(n),r=Qc(t[1]),t=Qc(t[0]),e=e*Yc,o=o/n,n=Math.asin(Math.sin(r)*Math.cos(o)+Math.cos(r)*Math.sin(o)*Math.cos(e)),t=t+Math.atan2(Math.sin(e)*Math.sin(o)*Math.cos(r),Math.cos(o)-Math.sin(r)*Math.sin(n)),e=el(v(n*Jc),-85,85);return[w(t*Jc),e]}function yl(t,e,o){t=ol(t=Rl(t),e=Rl(e));return"meters"===o?t:dl(t,"meters",o||"meters")}function ml(t){t=nl(t);return dl(Kc,f.meters,t)}function gl(t,e,o){for(var n=[],r=Qc(t[1]),i=Qc(t[0]),s=Qc(e[1]),a=Qc(e[0]),c=2*Math.asin(Math.sqrt(Math.pow(Math.sin((r-s)/2),2)+Math.cos(r)*Math.cos(s)*Math.pow(Math.sin((i-a)/2),2))),l=0;l<=o;l++){var u=l/o,p=Math.sin((1-u)*c)/Math.sin(c),u=Math.sin(u*c)/Math.sin(c),h=p*Math.cos(r)*Math.cos(i)+u*Math.cos(s)*Math.cos(a),d=p*Math.cos(r)*Math.sin(i)+u*Math.cos(s)*Math.sin(a),p=p*Math.sin(r)+u*Math.sin(s),u=Math.atan2(p,Math.sqrt(Math.pow(h,2)+Math.pow(d,2))),p=Math.atan2(d,h),u=el(u*Jc,-85,85);n.push([p*=Jc,u])}return n}function vl(t){return(Array.isArray(t)?t:t.coordinates).reduce(function(t,e){var o=0<t.length?t[t.length-1]:null;return o&&180<Math.abs(e[0]-o[0])?(o=o[0]<0?e[0]-360:e[0]+360,t.push([o,e[1]])):t.push(e),t},[])}function wl(t){for(var e,o,n,r,i,s=Array.isArray(t)?t:t.coordinates,a=[],c=[],l=0;l<s.length;l++)a.push(s[l]),l+1>=s.length||(e=(o=Gc(s[l],2))[0],o=o[1],r=(i=Gc(s[l+1],2))[0],i=i[1],180<Math.abs(r-e)&&(n=0<e?180:-180,r=Math.abs((0<e?r+360:r-360)-e),i=o+(i-o)*(Math.abs(n-e)/r),a.push([n,i]),c.push(a),a=[[-n,i]]));return c.push(a),c}function _l(t,e){var o,n;return t=Rl(t),e=Rl(e),t&&2<=t.length&&e&&2<=e.length?(n=Qc(t[1]),o=Qc(e[1]),e=Qc(e[0]-t[0]),t=Math.sin(e)*Math.cos(o),n=Math.cos(n)*Math.sin(o)-Math.sin(n)*Math.cos(o)*Math.cos(e),(tl(Math.atan2(t,n))+360)%360):NaN}function bl(t,e){var o,n=0;Array.isArray(t)?o=t:t.type&&"LineString"===t.type&&(o=t.coordinates);for(var r=0,i=o.length-1;r<i;r++)n+=ol(o[r],o[r+1]);return dl(n,"meters",e||"meters")}function xl(t,e,o){o=o||"meters";var n,r=0;if(Array.isArray(t)?n=t:t.type&&"LineString"===t.type&&(n=t.coordinates),2<=n.length){for(var i,s,a=n.length,c=1;c<a;c++){if(e<=r+(s=yl(n[c-1],n[c],o)))return i=_l(n[c-1],n[c]),fl(n[c-1],i,e-r,o);r+=s}return r<=e?n[a-1]:n[0]}return null}function Ol(t,e,o,n,r){n=n||"meters",r=r||0,t=Rl(t);for(var i=[],s=360/o,a=0;a<=o;a++)i.push(fl(t,(a*s+r)%360,e,n));return i}function Sl(t,e,o,n,r){return vl(Ol(t,e,o,n,r))}function v(t){return 90<t?180<(t=(t+90)%360)?90-(t-180):t-90:t<-90?(t=(t-90)%360)<-180?-90-(t+180):t+90:t}function w(t){return 180<t?(t+180)%360-180:t<-180?(t-180)%360+180:t}function Cl(t,e,o){if(0===o)return Object.assign({},t);e=Rl(e);for(var n,r,i=[],s=0,a=t.length;s<a;s++)n=yl(e,t[s]),r=_l(e,t[s]),i.push(fl(e,r+o,n));return i}function Pl(t,e){for(var o,n,r=512*Math.pow(2,e),i=[],s=0,a=t.length;s<a;s++)o=t[s][0]/r-.5,n=.5-t[s][1]/r,i.push([360*o,90-360*Math.atan(Math.exp(2*-n*Math.PI))/Math.PI]);return i}function Ll(t,e){for(var o,n,r=512*Math.pow(2,e),i=[],s=0,a=t.length;s<a;s++)n=Math.sin(t[s][1]*Math.PI/180),o=(t[s][0]+180)/360,n=.5-Math.log((1+n)/(1-n))/(4*Math.PI),i.push([Math.round(o*r),Math.round(n*r)]);return i}function kl(t,e,o,n){switch(rl(e)){case g.kilometersPerHourSecond:t/=3.6;break;case g.milesPerHourSecond:t/=2.236936292054;break;case g.knotsPerSecond:t/=1.943844492441;break;case g.standardGravity:t/=.1019716212978;break;case g.kilometersPerSecondSquared:t/=.001;break;case g.milesPerSecondSquared:t/=.000621371192;break;case g.feetPerSecondSquared:t/=3.280839895012;break;case g.yardsPerSecondSquared:t/=1.093613298338;break;case g.metersPerSecondSquared:}switch(rl(o)){case g.kilometersPerHourSecond:t*=3.6;break;case g.milesPerHourSecond:t*=2.236936292054;break;case g.knotsPerSecond:t*=1.943844492441;break;case g.standardGravity:t*=.1019716212978;break;case g.kilometersPerSecondSquared:t*=.001;break;case g.milesPerSecondSquared:t*=.000621371192;break;case g.feetPerSecondSquared:t*=3.280839895012;break;case g.yardsPerSecondSquared:t*=1.093613298338;break;case g.metersPerSecondSquared:}return hl(t,n)}function Al(t,e,o,n){switch(il(e)){case h.acres:t*=4046.8564224;break;case h.hectares:t*=1e4;break;case h.squareFeet:t*=.09290304;break;case h.squareKilometers:t*=1e6;break;case h.squareMiles:t*=259e4;break;case h.squareYards:t*=.83612736;break;case h.squareMeters:}switch(il(o)){case h.acres:t/=4046.8564224;break;case h.hectares:t/=1e4;break;case h.squareFeet:t/=.09290304;break;case h.squareKilometers:t/=1e6;break;case h.squareMiles:t/=259e4;break;case h.squareYards:t/=.83612736;break;case h.squareMeters:}return hl(t,n)}function Ml(t,e,o,n){switch(sl(e)){case m.feetPerSecond:t*=1.09728;break;case m.milesPerHour:t*=1.6093;break;case m.knots:t*=1.852;break;case m.metersPerSecond:t*=3.6;break;case m.mach:t*=1234.8;break;case m.kilometersPerHour:}switch(sl(o)){case m.feetPerSecond:t/=1.09728;break;case m.milesPerHour:t/=1.6093;break;case m.knots:t/=1.852;break;case m.metersPerSecond:t/=3.6;break;case m.mach:t/=1234.8;break;case m.kilometersPerHour:}return hl(t,n)}function El(t,e,o,n){switch(al(e)){case y.ms:t/=1e3;break;case y.hours:t*=3600;break;case y.minutes:t*=60;break;case y.days:t*=86400;break;case y.seconds:}switch(al(o)){case y.ms:t*=1e3;break;case y.hours:t/=3600;break;case y.minutes:t/=60;break;case y.days:t/=86400;break;case y.seconds:}return hl(t,n)}function jl(t,e,o,n,r,i,s,a){e=dl(e,r,f.meters),r=El(o,i,y.seconds);return kl(2*(e-Ml(t,n,m.metersPerSecond)*r)/(r*r),g.metersPerSecondSquared,s,a)}function Il(t,e,o,n,r,i,s){t=Ml(t,n,m.metersPerSecond);return kl((Ml(e,n,m.metersPerSecond)-t)/El(o,r,y.seconds),g.metersPerSecondSquared,i,s)}function Tl(t,e,o,n){t=zl(t),e=zl(e);return null!=t&&null!=e?El(e.getTime()-t.getTime(),y.ms,o,n):NaN}function zl(t){if("[object Date]"===Object.prototype.toString.call(t))return t;if("string"==typeof t){var e=Date.parse(t);if(!isNaN(e))return new Date(e);if(0<=t.indexOf("Date("))return e=(e=0)<(t=t.replace("/Date(","").replace(")/","")).indexOf("+")?parseInt(t.substr(0,t.indexOf("+")),10):0<t.indexOf("-")?parseInt(t.substr(0,t.indexOf("-")),10):parseInt(t,10),new Date(e)}else if("number"==typeof t)return new Date(t);return null}function Dl(t){var e=[],o=null,n=null;if(Array.isArray(t)&&0<t.length)if(Array.isArray(t[0])&&"number"==typeof t[0][0])e=t;else for(var r=t.length,i=0;i<r;i++)e=e.concat(Dl(t[i]));else if(t.type)switch(t.type){case"Point":e=[t.coordinates];break;case"LineString":e=t.coordinates;break;case"Polygon":o=t.coordinates;break;case"MultiPoint":e=t.coordinates;break;case"MultiLineString":o=t.coordinates;break;case"MultiPolygon":n=t.coordinates;break;case"Feature":var s=t,e=x._isCircle(s)?x._getCirclePositions(s):Dl(s.geometry);break;case"FeatureCollection":e=Dl(t.features);break;case"GeometryCollection":e=Dl(t.geometries)}else if(t instanceof x)return Dl(t.toJson());if(o)for(r=o.length,i=0;i<r;i++)e=e.concat(o[i]);else if(n)for(var a=n.length,i=0;i<a;i++)for(var c=n[i].length,l=0;l<c;l++)e=e.concat(n[i][l]);return e}function Rl(t){if(Array.isArray(t)&&"number"==typeof t[0])return t;if(t.type){if("Point"===t.type)return t.coordinates;if("Feature"===t.type&&"Point"===t.geometry.type)return t.geometry.coordinates}else if(t instanceof x&&"Point"===t.getType())return t.getCoordinates();return null}function Bl(t,e,o){o=o||"meters";var n,r=0;if(Array.isArray(t)?n=t:t.type&&"LineString"===t.type&&(n=t.coordinates),2<=n.length){for(var i,s,a,c=n.length,l=1;l<c;l++){if(e<=r+(a=yl(n[l-1],n[l],o)))return i=_l(n[l-1],n[l]),s=fl(n[l-1],i,e-r,o),new Fc(new Uc(s),{heading:i});r+=a}return r<=e?new Fc(new Uc(n[c-1]),{heading:_l(n[c-2],n[c-1])}):new Fc(new Uc(n[0]),{heading:_l(n[0],n[1])})}return null}($n=h=h||{}).squareMeters="squareMeters",$n.acres="acres",$n.hectares="hectares",$n.squareFeet="squareFeet",$n.squareKilometers="squareKilometers",$n.squareMiles="squareMiles",$n.squareYards="squareYards",(xi=f=f||{}).meters="meters",xi.kilometers="kilometers",xi.feet="feet",xi.miles="miles",xi.nauticalMiles="nauticalMiles",xi.yards="yards",(jn=y=y||{}).seconds="seconds",jn.hours="hours",jn.ms="ms",jn.minutes="minutes",jn.days="days",(o=m=m||{}).metersPerSecond="metersPerSecond",o.kilometersPerHour="kilometersPerHour",o.feetPerSecond="feetPerSecond",o.milesPerHour="milesPerHour",o.knots="knots",o.mach="mach",(a=g=g||{}).milesPerSecondSquared="milesPerSecondSquared",a.kilometersPerSecondSquared="kilometersPerSecondSquared",a.knotsPerSecond="knotsPerSecond",a.standardGravity="standardGravity",a.feetPerSecondSquared="feetPerSecondSquared",a.yardsPerSecondSquared="yardsPerSecondSquared",a.milesPerHourSecond="milesPerHourSecond",a.kilometersPerHourSecond="kilometersPerHourSecond",a.metersPerSecondSquared="metersPerSecondSquared";var Fl,Nl,r=window&&window.__extends||(Fl=function(t,e){return(Fl=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fl(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Zl=(Nl=Array,r(ql,Nl),ql.fromPosition=function(t){return 2===t.length?new ql(t[0],t[1]):2<t.length?new ql(t[0],t[1],t[2]):null},ql.areEqual=function(t,e,o){var n,r;return void 0===o&&(o=6),!!(t&&2<=t.length&&e&&2<=e.length)&&(o=Math.pow(10,o),r=v(t[1]),n=v(e[1]),t=w(t[0]),e=w(e[0]),0==Math.round((r-n)*o)/o)&&(0==(r=Math.round((t-e)*o)/o)||360==r)},ql.fromLatLng=function(r,t,e){var i,s,a,c,l,u,o=[];return"number"==typeof r?("number"==typeof t&&o.push(t),o.push(r),"number"==typeof e&&o.push(e)):Array.isArray(r)?2<=r.length&&"number"==typeof r[0]&&"number"==typeof r[1]&&(3<=r.length&&"number"==typeof r[2]?o.push(r[1],r[0],r[2]):o.push(r[1],r[0])):"object"==typeof r&&(i=["lat","latitude","y"],s=["lng","longitude","lon","x"],a=["elv","elevation","alt","altitude","z"],u=l=c=NaN,Object.keys(r).forEach(function(t,e,o){var n=t.toLowerCase();isNaN(c)&&0<=i.indexOf(n)&&"number"==typeof r[t]?c=r[t]:isNaN(l)&&0<=s.indexOf(n)&&"number"==typeof r[t]?l=r[t]:isNaN(u)&&0<=a.indexOf(n)&&"number"==typeof r[t]&&(u=r[t])}),isNaN(c)||isNaN(l)||(o.push(l,c),isNaN(u))||o.push(u)),2<=o.length?o:null},ql.fromLatLngs=function(t){var e=[];if(Array.isArray(t))for(var o=0,n=t.length;o<n;o++){var r=ql.fromLatLng(t[o]);r&&e.push(r)}return e},ql._getDimensions=function(t){for(var e=0;Array.isArray(t);)t=t[0],e++;return"number"==typeof t&&e--,e},ql);function ql(t,e,o){return o?Nl.call(this,t,e,o)||this:Nl.call(this,t,e)||this}Ul.TYPE="Polygon";var Hl=Ul;function Ul(t,e){this.type="Polygon",this.type=Ul.TYPE,1===Zl._getDimensions(t)?this.coordinates=[t]:this.coordinates=t,this.bbox=e}var Wl,Gl,Jo=window&&window.__extends||(Wl=function(t,e){return(Wl=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Wl(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Vl=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},x=(Jo(O,Gl=Ze),O.prototype.addProperty=function(t,e){Bc(this.data.properties[t],e)||(this.data.properties[t]=c(e),"subType"!==t&&"radius"!==t||this._handleCircle(),this.dataSource&&this.dataSource._updateSource(),this._invokeEvent("shapechanged",this))},O.prototype.getBounds=function(){var e,t,o,n,r,i=this.getCoordinates(),s=this.getType();if("Point"===s)r=this.circlePolygon?(a=this.circlePolygon.geometry.coordinates,S.fromPositions(a[0])):new S(a=i,a);else if("MultiPoint"===s||"LineString"===s){var a=i;r=S.fromPositions(a)}else if("Polygon"===s){a=i;r=S.fromPositions(a[0])}else if("MultiLineString"===s){a=i;try{for(var c=Vl(a),l=c.next();!l.done;l=c.next()){var u=l.value;r=S.merge(r,S.fromPositions(u))}}catch(t){e={error:t}}finally{try{l&&!l.done&&(t=c.return)&&t.call(c)}finally{if(e)throw e.error}}}else if("MultiPolygon"===s){a=i;try{for(var p=Vl(a),h=p.next();!h.done;h=p.next()){var d=h.value;r=S.merge(r,S.fromPositions(d[0]))}}catch(t){o={error:t}}finally{try{h&&!h.done&&(n=p.return)&&n.call(p)}finally{if(o)throw o.error}}}return r},O.prototype.getCoordinates=function(){return c(this.data.geometry.coordinates)},O.prototype.getCircleCoordinates=function(){return this.circlePolygon?c(this.circlePolygon.geometry.coordinates[0]):null},O.prototype.getId=function(){return this.data.id},O.prototype.getProperties=function(){return c(this.data.properties)},O.prototype.getType=function(){return this.data.geometry.type},O.prototype.isCircle=function(){return O._isCircle(this.data)},O.prototype.isRectangle=function(){return O._isRectangle(this.data)},O.prototype.setCoordinates=function(t){t="Polygon"===this.getType()&&1===Zl._getDimensions(t)?[t]:t;Bc(this.data.geometry.coordinates,t)||(this.data.geometry.coordinates=c(t),this._handleCircle(),this.dataSource&&this.dataSource._updateSource(),this._invokeEvent("shapechanged",this))},O.prototype.setProperties=function(t){t[O._shapeIdPropName]=this.data.id,Bc(this.data.properties,t)||(this.data.properties=c(t),this._handleCircle(),this.dataSource&&this.dataSource._updateSource(),this._invokeEvent("shapechanged",this))},O.prototype.toJson=function(){return JSON.parse(JSON.stringify(this.data))},O.prototype._toJson=function(){return this.circlePolygon||this.data},O.prototype._setDataSource=function(t){void 0===t||null==t?delete this.dataSource:this.dataSource=t},O.prototype._handleCircle=function(){var t;this.isCircle()?(t=O._getCirclePositions(this.data),this.circlePolygon=new Fc(new Hl([t]),this.data.properties,this.data.id),this.data.properties.subType="Circle"):delete this.circlePolygon},O._isCircle=function(t){return t&&t.geometry&&"Point"===t.geometry.type&&t.geometry.coordinates&&t.properties&&"string"==typeof t.properties.subType&&"circle"===t.properties.subType.toLowerCase()&&"number"==typeof t.properties.radius},O._isRectangle=function(t){if("Polygon"===t.geometry.type&&t.geometry.coordinates&&"string"==typeof t.properties.subType&&"rectangle"===t.properties.subType.toLowerCase()){t=t.geometry.coordinates;if(1===t.length){t=t[0];if(5===t.length)return t[0][0]===t[4][0]&&t[0][1]===t[4][1];if(4===t.length)return!0}}return!1},O._getCirclePositions=function(t){return Sl(t.geometry.coordinates,t.properties.radius,72,"meters")},O._shapeIdPropName="_azureMapsShapeId",O);function O(t,e,o){var n,r,i=Gl.call(this)||this;return"Feature"===t.type?(r=c((n=t).geometry),o=n.properties?c(n.properties):{},e=null==n.id||""===n.id?J():n.id):(r=c(t),e=null==e||""===e?J():e,o=o?c(o):{}),o[O._shapeIdPropName]=e,i.data=new Fc(r,o,e),i._handleCircle(),i}var Kl,Yl,i=window&&window.__extends||(Kl=function(t,e){return(Kl=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Kl(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Jl=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},S=(Yl=Array,i(C,Yl),C.fromBoundingBox=function(t){var e=C.getWest(t),o=C.getSouth(t),n=C.getEast(t),t=C.getNorth(t);return new C([e,o,n,t])},C.fromDimensions=function(t,e,o){var n=t[0],t=t[1],r=Math.min(Math.max(t+o/2,-85.5),85.5),t=Math.min(Math.max(t-o/2,-85.5),85.5),o=w(n+e/2);return new C([w(n-e/2),t,o,r])},C.fromEdges=function(t,e,o,n){return new C([t,e,o,n])},C.containsPosition=function(t,e){var o=C.getCenter(t),n=Math.abs(o[1]-e[1]),o=Math.abs(o[0]-e[0]),e=(180<o&&(o=360-o),C.getHeight(t)),t=C.getWidth(t);return n<=e/2+1e-8&&o<=t/2+1e-8},C.containsBoundingBox=function(t,e){var o=t&&4===t.length,n=e&&4===e.length;return!(!o||!n)&&C.getWest(t)<C.getWest(e)&&C.getWest(e)<C.getEast(t)&&C.getWest(t)<C.getEast(e)&&C.getEast(e)<C.getEast(t)&&C.getSouth(t)<C.getSouth(e)&&C.getSouth(e)<C.getNorth(t)&&C.getSouth(t)<C.getNorth(e)&&C.getNorth(e)<C.getNorth(t)},C.crossesAntimeridian=function(t){return w(C.getEast(t))-w(C.getWest(t))<0||C.isBoundingBoxWithSixOrMoreElementsLargerThanGlobe(t)||C.isBoundingBoxWithLessThanSixElementsLargerThanGlobe(t)},C.getCenter=function(t){var e=w(C.getEast(t)),o=w(C.getWest(t)),o=(e<o&&(e+=360),w((o+e)/2)),e=v(C.getSouth(t)),t=v(C.getNorth(t));return[o,v((e+t)/2)]},C.getHeight=function(t){t=v(C.getNorth(t))-v(C.getSouth(t));return isNaN(t)?0:t},C.getWidth=function(t){t=w(C.getEast(t))-w(C.getWest(t));return isNaN(t)?0:t<0?t+360:t},C.getSouthWest=function(t){var e=this.getSouth(t),t=this.getWest(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getNorthEast=function(t){var e=this.getNorth(t),t=this.getEast(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getNorthWest=function(t){var e=this.getNorth(t),t=this.getWest(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getSouthEast=function(t){var e=this.getSouth(t),t=this.getEast(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getSouth=function(t){return t&&4<=t.length?Number(t[1]):NaN},C.getWest=function(t){return t&&4<=t.length?Number(t[0]):NaN},C.getNorth=function(t){if(t){if(4===t.length)return Number(t[3]);if(6===t.length)return Number(t[4])}return NaN},C.getEast=function(t){if(t){if(4===t.length)return Number(t[2]);if(6===t.length)return Number(t[3])}return NaN},C.intersect=function(t,e){var o=C.getCenter(t),n=C.getCenter(e),r=Math.abs(o[1]-n[1]),o=Math.abs(o[0]-n[0]),n=(180<o&&(o=360-o),C.getHeight(t)),t=C.getWidth(t),i=C.getHeight(e),e=C.getWidth(e);return r<=n/2+i/2&&o<=t/2+e/2},C.merge=function(t,e){var o=t&&4===t.length,n=e&&4===e.length;if(o&&!n)return t;if(n&&!o)return e;if(!o&&!n)return null;for(var o=Math.max(v(C.getNorth(t)),v(C.getNorth(e))),n=Math.min(v(C.getSouth(t)),v(C.getSouth(e))),r=[t,e],i=[],s=0,s=0;s<r.length;s++){var a=r[s],c=w(C.getWest(a)),l=w(C.getEast(a));C.crossesAntimeridian(a)?(i.push([c,180]),i.push([-180,l])):i.push([c,l])}i.sort(function(t,e){return t[0]===e[0]?t[1]-e[1]:t[0]-e[0]});var u=[],p=i[0];for(s=1;s<i.length;){var h=i[s];p[1]>=h[0]?p[1]=Math.max(p[1],h[1]):(u.push(p),p=h),s++}u.push(p);var d=u.length,f=u[0][0]+360-u[d-1][1],y=[u[d-1][1],u[0][0]];for(s=1;s<d;s++){var m=u[s][0]-u[s-1][1];f<m&&(f=m,y=[u[s-1][1],u[s][0]])}return new C([y[1],n],[y[0],o])},C.fromPositions=function(t){for(var e,o,n=NaN,r=NaN,i=NaN,s=NaN,a=t.length,c=new Array(a),l=0;a--;)(o=t[a])&&2<=o.length&&(e=v(o[1]),n=isNaN(n)?e:Math.max(n,e),r=isNaN(r)?e:Math.min(r,e),c[l++]=w(o[0]));if(l){c.length=l,c.sort(function(t,e){return t-e});for(var u=c[0]+360-c[l-1],p=0,a=1;a<l;a++){var h=c[a]-c[a-1];u<h&&(u=h,p=a)}i=c[p],s=c[(p||l)-1]}return isNaN(i)||isNaN(r)||isNaN(s)||isNaN(n)?null:new C([i,r,s,n])},C.fromLatLngs=function(t){return C.fromPositions(Zl.fromLatLngs(t))},C.fromData=function(t){var e,o,n=null;if(Array.isArray(t)&&0<t.length){try{for(var r=Jl(t),i=r.next();!i.done;i=r.next()){var s,a=i.value;null!=(s=C.fromData(a))&&(n=null===n?s:C.merge(n,s))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}return n}if(t instanceof x)return t.getBounds();if(t&&t.type){var c=t;if(c.bbox&&4===c.bbox.length)return c.bbox;switch(c.type){case"FeatureCollection":return C.fromData(c.features);case"Feature":return x._isCircle(c)?C.fromPositions(x._getCirclePositions(c)):C.fromData(c.geometry);case"GeometryCollection":return C.fromData(c.geometries);case"Point":var l=c.coordinates;if(l&&2<=l.length)return[l[0],l[1],l[0],l[1]];break;case"LineString":case"MultiPoint":return C.fromPositions(c.coordinates);case"Polygon":case"MultiLineString":var u=c.coordinates;if(u&&0<u.length){for(var p=0,h=u.length;p<h;p++)null!=(s=C.fromPositions(u[p]))&&(n=null===n?s:C.merge(n,s));if(null!=n)return n}break;case"MultiPolygon":var d=c.coordinates;if(d&&0<d.length){for(p=0,h=d.length;p<h;p++)for(var f=0,y=d[p].length;f<y;f++)null!=(s=C.fromPositions(d[p][f]))&&(n=null===n?s:C.merge(n,s));return n}}}return null},C.splitOnAntimeridian=function(t){var e,o,n,r,i,s,a=[];return C.isBoundingBoxWithSixOrMoreElementsLargerThanGlobe(t)?[[-180,t[1],t[2],180,t[4],t[5]]]:C.isBoundingBoxWithLessThanSixElementsLargerThanGlobe(t)?[[-180,t[1],180,t[3]]]:(C.crossesAntimeridian(t)?(s=e=void 0,o=w(C.getWest(t)),n=w(C.getEast(t)),r=v(C.getNorth(t)),i=v(C.getSouth(t)),s=6<=t.length?(e=[o,i,t[2],180,r,t[5]],[-180,i,t[2],n,r,t[5]]):(e=[o,i,180,r],[-180,i,n,r]),a.push(e,s)):a.push(t),a)},C.isBoundingBoxWithSixOrMoreElementsLargerThanGlobe=function(t){return 6<=t.length&&360<t[3]-t[0]},C.isBoundingBoxWithLessThanSixElementsLargerThanGlobe=function(t){return t.length<6&&360<t[2]-t[0]},C);function C(t,e){var o,n=this;return t&&e?n=(o=t)[2]&&e[2]?Yl.call(this,o[0],o[1],o[2]||0,e[0],e[1],e[2]||0)||this:Yl.call(this,o[0],o[1],e[0],e[1])||this:t&&(o=t)&&(4===o.length?n=Yl.call(this,o[0],o[1],o[2],o[3])||this:6<=o.length&&(n=Yl.call(this,o[0],o[1],o[2],o[3],o[4],o[5])||this)),n}Xl.TYPE="FeatureCollection";var $l=Xl;function Xl(t,e){this.type="FeatureCollection",this.type=Xl.TYPE,this.features=t,this.bbox=e}Ql.TYPE="GeometryCollection";Ao=Ql;function Ql(t){this.type="GeometryCollection",this.type=Ql.TYPE,this.geometries=t}tu.TYPE="LineString";e=tu;function tu(t,e){this.type="LineString",this.type=tu.TYPE,this.coordinates=t,this.bbox=e}eu.TYPE="MultiLineString";H=eu;function eu(t,e){this.type="MultiLineString",this.type=eu.TYPE,this.coordinates=t,this.bbox=e}ou.TYPE="MultiPoint";s=ou;function ou(t,e){this.type="MultiPoint",this.type=ou.TYPE,this.coordinates=t,this.bbox=e}nu.TYPE="MultiPolygon";In=nu;function nu(t,e){this.type="MultiPolygon",this.type=nu.TYPE,this.coordinates=t,this.bbox=e}var ru,iu,er=window&&window.__extends||(ru=function(t,e){return(ru=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ru(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),tr=(iu=Array,er(P,iu),P.fromPosition=function(t){return 2<=t.length?new P((180+t[0])/360,P._latToMercatorY(t[1]),3<=t.length?P._altitudeToMercatorZ(t[2],t[1]):0):[0,0,0]},P.fromPositions=function(t){for(var e=[],o=0,n=t.length;o<n;o++)e.push(this.fromPosition(t[o]));return e},P.toFloat32Array=function(t){for(var e=new Float32Array(3*t.length),o=0,n=t.length;o<n;o++){var r=3*o,i=t[o];e[r]=(180+i[0])/360,e[1+r]=P._latToMercatorY(i[1]),e[2+r]=3<=i.length?P._altitudeToMercatorZ(i[2],i[1]):0}return e},P.toPosition=function(t){var e;return 2<=t.length?(e=360/Math.PI*Math.atan(Math.exp((180-360*t[1])*Math.PI/180))-90,new Zl(360*t[0]-180,e,3<=t.length?P._mercatorZToAltitude(t[2],t[1]):0)):[0,0,0]},P.toPositions=function(t){for(var e=[],o=0,n=t.length;o<n;o++)e.push(this.toPosition(t[o]));return e},P.mercatorScale=function(t){return 1/Math.cos(t*Math.PI/180)},P.meterInMercatorUnits=function(t){return 1/P.earthCircumference*P.mercatorScale(P._latToMercatorY(t))},P._circumferenceAtLatitude=function(t){return P.earthCircumference*Math.cos(t*Math.PI/180)},P._altitudeToMercatorZ=function(t,e){return t/P._circumferenceAtLatitude(e)},P._mercatorZToAltitude=function(t,e){return t*P._circumferenceAtLatitude(P._latToMercatorY(e))},P._latToMercatorY=function(t){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+t*Math.PI/360)))/360},P.earthCircumference=2*Math.PI*ml(),P);function P(t,e,o){return iu.call(this,t,e,o||0)||this}var Kr=Object.freeze({__proto__:null,BoundingBox:S,Feature:Fc,FeatureCollection:$l,GeometryCollection:Ao,LineString:e,MercatorPoint:tr,MultiLineString:H,MultiPoint:s,MultiPolygon:In,Point:Uc,Polygon:Hl,Position:Zl});function su(t,e){return t*t+e*e}function au(t,e){for(var o,n,r,i=t[0],s=[i],a=1,c=t.length;a<c;a++)o=t[a],r=i,su((n=o)[0]-r[0],n[1]-r[1])>e&&(s.push(o),i=o);return i!==o&&s.push(o),s}function cu(t,e,o,n,r){for(var i,s,a,c,l,u,p,h=n,d=e+1;d<o;d++){s=t[d],a=t[e],f=t[o],p=u=l=c=void 0,l=a[0],a=a[1],u=f[0]-l,p=f[1]-a,0==u&&0==p||(1<(c=((s[0]-l)*u+(s[1]-a)*p)/su(u,p))?(l=f[0],a=f[1]):0<c&&(l+=u*c,a+=p*c));var f=su(s[0]-l,s[1]-a);h<f&&(i=d,h=f)}n<h&&(1<i-e&&cu(t,e,i,n,r),r.push(t[i]),1<o-i)&&cu(t,i,o,n,r)}var lu=function(t,e,o){var n,r;return void 0===e&&(e=1),void 0===o&&(o=!1),t.length<=2||(e=e*e,t=o?t:au(t,e),n=(o=t).length-1,r=[o[0]],cu(o,0,n,e,r),r.push(o[n]),t=r),t};var uu=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},pu=(hu.prototype.toTarget=function(t,e){return this.transformArray(t,this.M,e)},hu.prototype.toSource=function(t,e){return this.transformArray(t,this.inverseM,e)},hu.prototype.transformArray=function(t,e,o){var n,r;if(t&&Array.isArray(t)&&Array.isArray(t[0])){var i=[];try{for(var s=uu(t),a=s.next();!a.done;a=s.next()){var c=a.value;i.push(this.transform(c,e,o))}}catch(t){n={error:t}}finally{try{a&&!a.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return i}return null},hu.prototype.transform=function(t,e,o){var n=t[0]*e[0][3]+t[1]*e[1][3]+e[2][3],t=t[0]*e[0][4]+t[1]*e[1][4]+e[2][4];return"number"==typeof o&&0<=o?[hl(n,o),hl(t,o)]:[hl(n,6),hl(t,6)]},hu._calculateAffineTransform=function(t,e){if(t.length!==e.length||t.length<1)throw new Error("Error: source and target arrays must have the same length.");var o=Math.min(t[0].length,e[0].length),n=o+1;if(t.length<o)throw new Error("Erorr: At least "+o+" reference points required.");for(var r=[],i=[],s=0;s<n;s++){i[s]=[];for(var a=0;a<n;a++){a<o&&(r[a]=0);for(var c=i[s][a]=0;c<t.length;c++)a<o&&(r[a]+=s<o?t[c][s]*e[c][a]:e[c][a]),i[s][a]+=o<=s&&o<=a?1:o<=s?t[c][a]:o<=a?t[c][s]:t[c][s]*t[c][a]}i[s]=i[s].concat(r)}if(this._gaussJordanElimination(i))return i;throw new Error("Error: Singular matrix. Points are likely coplanar.")},hu._gaussJordanElimination=function(t){for(var e,o=t.length,n=2*o-1,r=0;r<o;r++){for(var i=r,s=r+1;s<o;s++)Math.abs(t[s][r])>Math.abs(t[i][r])&&(i=s);if(e=t[i],t[i]=t[r],t[r]=e,Math.abs(t[r][r])<=1e-12)return!1;for(var a=r+1;a<o;a++)for(var c=t[a][r]/t[r][r],l=r;l<n;l++)t[a][l]-=t[r][l]*c}for(r=o-1;-1<r;r--){c=t[r][r];for(s=0;s<r;s++)for(var u=n-1;r-1<u;u--)t[s][u]-=t[r][u]*t[s][r]/c;t[r][r]/=c;for(var p=o;p<n;p++)t[r][p]/=c}return!0},hu);function hu(t,e){this.M=hu._calculateAffineTransform(t,e),this.inverseM=hu._calculateAffineTransform(e,t)}var du,fu,$n=Object.freeze({__proto__:null,get AccelerationUnits(){return g},AffineTransform:pu,get AreaUnits(){return h},get DistanceUnits(){return f},get SpeedUnits(){return m},get TimeUnits(){return y},WEBMERCATOR_MAXLAT:Xc,_precision:hl,boundingBoxToPolygon:function(t){var e=w(S.getWest(t)),o=w(S.getEast(t)),n=v(S.getNorth(t)),r=v(S.getSouth(t)),t=S.getCenter(t),r=[[e,n],[e,r],[t[0],r],[o,r],[o,n],[t[0],n],[e,n]];return new Hl([r])},convertAcceleration:kl,convertArea:Al,convertDistance:dl,convertSpeed:Ml,convertTimespan:El,getAcceleration:jl,getAccelerationFromFeatures:function(t,e,o,n,r,i,s){if("string"==typeof o&&"Feature"===t.type&&"Point"===t.geometry.type&&"Feature"===e.type&&"Point"===e.geometry.type){o=Tl(t.properties[o],e.properties[o],y.seconds);if(!isNaN(o)){var a=0;if(n&&"string"==typeof n){var c=t.properties[n],n=e.properties[n];if("number"==typeof c&&(a=c,"number"==typeof n))return Il(c,n,o,r,y.seconds,i,s)}return jl(a,yl(t.geometry.coordinates,e.geometry.coordinates,f.meters),o,r,f.meters,y.seconds,i,s)}}return NaN},getAccelerationFromSpeeds:Il,getArea:function t(e,o,n){if(e){var r=0;switch((e=e instanceof x?e.toJson():e).type){case"Feature":var i=e;if(i.geometry)return t(i.geometry,o,n);break;case"Polygon":(i=e).coordinates&&(r=cl(i.coordinates));break;case"MultiPolygon":var s=e;if(s.coordinates)for(var a=0,c=s.coordinates.length;a<c;a++)r+=cl(s.coordinates[a])}return Al(r,h.squareMeters,o,n)}return 0},getCardinalSpline:function(t,e,o,n){if(!t||t.length<=2)return c;"number"!=typeof e&&(e=.5),("number"!=typeof o||o<=0)&&(o=15);var r,i,s,a=t.length,c=t.slice(0),l=(n?(Zl.areEqual(c[0],c[a-1])&&(c.pop(),a--),c.unshift(t[a-1]),c.push(t[0]),c.push(t[1]),a++):(c.unshift(t[0]),c.push(t[a-1])),[]);l.push([1,0,0,0]);for(var u=1;u<o-1;u++)l.push([2*(s=(r=u/o)*(i=r*r))-3*i+1,-2*s+3*i,s-2*i+r,s-i]);l.push([0,1,0,0]);for(var p,h,d,f,y,m,g=[],u=1;u<a;u++)for(p=e*(c[u+1][0]-c[u-1][0]),h=e*(c[u+1][1]-c[u-1][1]),d=e*(c[u+2][0]-c[u][0]),f=e*(c[u+2][1]-c[u][1]),r=0;r<o;r++)m=(y=l[r])[0]*c[u][0]+y[1]*c[u+1][0]+y[2]*p+y[3]*d,y=el(y[0]*c[u][1]+y[1]*c[u+1][1]+y[2]*h+y[3]*f,-85,85),g.push([m,y]);return g},getClosestPointOnGeometry:function t(e,o,n,r){var i=Rl(e),s=Ll([i],22)[0],a=null,c=1/0;switch((o=o instanceof x?o.toJson():o).type){case"Feature":return t(e,o.geometry,n);case"Point":f=[[o.coordinates]];break;case"MultiPoint":for(var l,u=o.coordinates,p=0,h=u.length;p<h;p++)(l=yl(i,u[p]))<c&&(c=l,a=new Fc(new Uc(u[p]),{distance:l}));break;case"LineString":f=[o.coordinates];break;case"Polygon":case"MultiLineString":f=o.coordinates;break;case"MultiPolygon":var d=o.coordinates;if(0<d.length)for(var f=d[0],p=1,h=d.length;p<h;p++)f=f.concat(d[p])}if(f)for(var y,p=0,h=f.length;p<h;p++)(y=pl(i,s,f[p]))&&y.properties.distance<c&&(c=y.properties.distance,a=y);return a&&(a.properties.distance=dl(a.properties.distance,"meters",n,r)),a},getConvexHull:function(t){var e,o,n=Dl(t).map(function(t){return[w(t[0]),v(t[1])]}),r=(n.sort(function(t,e){return t[0]===e[0]?t[1]-e[1]:t[0]-e[0]}),[]);try{for(var i=Vc(n),s=i.next();!s.done;s=i.next()){for(var a=s.value;2<=r.length&&ul(r[r.length-2],r[r.length-1],a)<=0;)r.pop();r.push(a)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(o=i.return)&&o.call(i)}finally{if(e)throw e.error}}for(var c=[],l=n.length-1;0<=l;l--){for(;2<=c.length&&ul(c[c.length-2],c[c.length-1],n[l])<=0;)c.pop();c.push(n[l])}return new Hl([r.concat(c)])},getDestination:fl,getDistanceTo:yl,getEarthRadius:ml,getGeodesicPath:function(t,e){(!e||e<=0)&&(e=15),Array.isArray(t)?o=t:t.type&&"LineString"===t.type&&(o=t.coordinates);for(var o,n=o.length-1,r=[],i=0;i<n;i++)r=r.concat(gl(o[i],o[i+1],e));return vl(r)},getGeodesicPaths:function(t,e){(!e||e<=0)&&(e=15),Array.isArray(t)?o=t:t.type&&"LineString"===t.type&&(o=t.coordinates);for(var o,n=o.length-1,r=[],i=[],s=0;s<n;s++)for(var a,c,l,u,p,h=gl(o[s],o[s+1],e),d=0;d<h.length;d++)r.push(h[d]),d+1>=h.length||(a=(c=Gc(h[d],2))[0],c=c[1],u=(p=Gc(h[d+1],2))[0],p=p[1],180<Math.abs(u-a)&&(l=0<a?180:-180,u=Math.abs((0<a?u+360:u-360)-a),p=c+(p-c)*(Math.abs(l-a)/u),r.push([l,p]),i.push(r),r=[[-l,p]]));return i.push(r),i},getHeading:_l,getLengthOfPath:bl,getPathDenormalizedAtAntimerian:vl,getPathSplitByAntimeridian:wl,getPixelHeading:function(t,e){t=Rl(t),e=Rl(e);var e=(t=Gc(Ll([t,e],21),2))[0],o=(t=t[1])[0]-e[0],e=e[1]-t[1];return(2.5*Math.PI-Math.atan2(e,o))*Jc%360},getPointWithHeadingAlongPath:Bl,getPointsWithHeadingsAlongPath:function(t,e){if(e<=0)return[];for(var o=[],n=bl(t,f.meters)/(e-1),r=0;r<e;r++){var i=Bl(t,n*r,f.meters);null!=i&&o.push(i)}return o},getPosition:Rl,getPositionAlongPath:xl,getPositions:Dl,getPositionsAlongPath:function(t,e){if(e<2)return[];for(var o=[],n=bl(t,f.meters)/(e-1),r=0;r<e;r++){var i=xl(t,n*r,f.meters);null!=i&&o.push(i)}return o},getRegularPolygonPath:Sl,getRegularPolygonPaths:function(t,e,o,n,r){return wl(Ol(t,e,o,n,r))},getSpeed:function(t,e,o,n,r,i){return t=Rl(t),e=Rl(e),t&&e?(o=El(o,n,y.seconds),Ml(yl(t,e,f.meters)/o,m.metersPerSecond,r,i)):0},getSpeedFromFeatures:function(t,e,o,n,r){if("string"==typeof o&&"Feature"===t.type&&"Point"===t.geometry.type&&"Feature"===e.type&&"Point"===e.geometry.type){o=Tl(t.properties[o],e.properties[o],y.seconds);if(!isNaN(o))return Ml(yl(t.geometry.coordinates,e.geometry.coordinates,f.meters)/o,m.metersPerSecond,n,r)}return NaN},getTimespan:Tl,getTravelDistance:function(t,e,o,n,r,i,s,a){return e=El(e,r,y.seconds),r=(o=Ml(o,i,m.metersPerSecond))*e,"number"==typeof n&&(r+=.5*kl(n,s,g.metersPerSecondSquared)*e*e),dl(r,f.meters,t,a)},interpolate:function(t,e,o){o=void 0===o?.5:o;var n=yl(t=Rl(t),e=Rl(e),"kilometers");return fl(t,_l(t,e),n*o,"kilometers")},mercatorPixelsToPositions:Pl,mercatorPositionsToPixels:Ll,normalizeLatitude:v,normalizeLongitude:w,parseTimestamp:zl,rotatePositions:Cl,simplify:function(t,e){return lu(t,e,!0)}}),yu=((window&&window.__extends||(du=function(t,e){return(du=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}du(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(mu,fu=t),mu);function mu(){var t=null!==fu&&fu.apply(this,arguments)||this;return t.zoomDelta=1,t.style=u.ControlStyle.light,t}(window&&window.__extends||(gu=function(t,e){return(gu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}gu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(wu,vu=We),wu.prototype.onAdd=function(t){this.container=this.buildContainer(t,this.options.style,"Zoom Control"),this.container.style.flexDirection="column",this.zoomInButton=this.constructZoomInButton(t),this.zoomOutButton=this.constructZoomOutButton(t);var e=_("Zoom In"),o=_("Zoom Out");return this.container.appendChild(this.zoomInButton),this.container.appendChild(e),this.container.appendChild(this.zoomOutButton),this.container.appendChild(o),b(e,this.zoomInButton),b(o,this.zoomOutButton),t.events.add("zoom",this.zoomChanged),t.events.add("minzoomchanged",this.minZoomChanged),t.events.add("maxzoomchanged",this.maxZoomChanged),this.map=t,this.container},wu.prototype.onRemove=function(){vu.prototype.onRemove.call(this),this.map&&(this.map.events.remove("zoom",this.zoomChanged),this.map.events.remove("minzoomchanged",this.minZoomChanged),this.map.events.remove("maxzoomchanged",this.maxZoomChanged),this.map=null),this.container&&(this.container.remove(),this.container=null,this.zoomInButton=null,this.zoomOutButton=null)},wu.prototype.updateZoomButtonsState=function(){var t=this.map.getCamera().zoom>=this.map._getMap().getMaxZoom(),e=S.getSouth(this.map.getCamera().bounds)<=-Xc&&S.getNorth(this.map.getCamera().bounds)>=Xc,e=this.map.getCamera().zoom<=this.map._getMap().getMinZoom()||e;this.zoomInButton&&this.zoomInButton.disabled!=t&&(this.zoomInButton.disabled=t,this.zoomInButton.setAttribute("aria-label",t?"Zoom In disabled":"Zoom In")),this.zoomOutButton&&this.zoomOutButton.disabled!=e&&(this.zoomOutButton.disabled=e,this.zoomOutButton.setAttribute("aria-label",t?"Zoom Out disabled":"Zoom Out"))},wu.prototype.constructZoomInButton=function(e){var o=this,t=document.createElement("button");return t.classList.add("azure-maps-control-button"),t.classList.add("zoom-in"),t.setAttribute("aria-label","Zoom In"),t.setAttribute("alt","Zoom In"),t.setAttribute("type","button"),t.addEventListener("click",function(){var t;e.setCamera({maxBounds:null==(t=e._getMap().getMaxBounds())?void 0:t.toArray().flat(),zoom:e.getCamera().zoom+o.options.zoomDelta,duration:wu.ZOOM_DURATION_MS,type:"ease"},!0)}),t},wu.prototype.constructZoomOutButton=function(e){var o=this,t=document.createElement("button");return t.classList.add("azure-maps-control-button"),t.classList.add("zoom-out"),t.setAttribute("aria-label","Zoom Out"),t.setAttribute("alt","Zoom Out"),t.setAttribute("type","button"),t.addEventListener("click",function(){var t;e.setCamera({maxBounds:null==(t=e._getMap().getMaxBounds())?void 0:t.toArray().flat(),zoom:e.getCamera().zoom-o.options.zoomDelta,duration:wu.ZOOM_DURATION_MS,type:"ease"},!0)}),t},wu.ZOOM_DURATION_MS=200;var gu,vu,xi=wu;function wu(t){var e=vu.call(this)||this;return e.container=null,e.zoomInButton=null,e.zoomOutButton=null,e.zoomChanged=function(t){return e.updateZoomButtonsState()},e.minZoomChanged=function(t){return e.updateZoomButtonsState()},e.maxZoomChanged=function(t){return e.updateZoomButtonsState()},e.options=(new yu).merge(t),e}(window&&window.__extends||(_u=function(t,e){return(_u=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}_u(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ou,bu=t);var _u,bu,xu=Ou;function Ou(){var t=null!==bu&&bu.apply(this,arguments)||this;return t.style=u.ControlStyle.light,t.hideIfUnsupported=!1,t.container=void 0,t}(window&&window.__extends||(Su=function(t,e){return(Su=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Su(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Pu,Cu=We),Pu.prototype.onAdd=function(t){var e,o,n=this,r=(this.map=t,null!=(r=null==(r=this.map)?void 0:r._getMap())&&r.addControl(this.control),this.buildContainer(t,this.options.style,"Fullscreen Control")),i=this.control._fullscreenButton;return i&&(e=i.querySelector("span"))&&(o=_("Enter Fullscreen"),r.appendChild(i),i.classList.add("azure-maps-control-button","fullscreen"),e.classList.add("fullscreen-icon","fullscreen-end"),i.removeAttribute("title"),r.appendChild(o),b(o,i),this.control.on("fullscreenstart",function(){i.removeAttribute("title"),e.classList.remove("fullscreen-end"),e.classList.add("fullscreen-start"),o.innerText="Exit Fullscreen",n.isFullscreenState=!0}),this.control.on("fullscreenend",function(){i.removeAttribute("title"),e.classList.remove("fullscreen-start"),e.classList.add("fullscreen-end"),o.innerText="Enter Fullscreen",n.isFullscreenState=!1})),this.options.hideIfUnsupported&&!Pu.isSupported()&&(r.style.display="none"),r},Pu.prototype.onRemove=function(){var t;Cu.prototype.onRemove.call(this),null!=(t=null==(t=this.map)?void 0:t._getMap())&&t.removeControl(this.control),this.map=null},Pu.prototype.isFullscreen=function(){return this.isFullscreenState},Pu.isSupported=function(){var t=document;return t.fullscreenEnabled||t.msFullscreenEnabled||t.mozFullScreenEnabled||t.webkitFullscreenEnabled};var Su,Cu,jn=Pu;function Pu(t){var e=Cu.call(this)||this;return e.map=null,e.isFullscreenState=!1,e.options=(new xu).merge(t),e.control=new D.FullscreenControl({container:e.options.container}),e}var o=Object.freeze({__proto__:null,CompassControl:q,ControlBase:We,FullscreenControl:jn,PitchControl:yt,ScaleControl:ze,StyleControl:bi,TrafficControl:oc,TrafficLegendControl:R,ZoomControl:xi}),Lu=Ts;var L=B(function(t,e){return Lu(t,5,e="function"==typeof e?e:void 0)}),ku=(Au.Css={hidden:"hidden-accessible-element"},Au);function Au(t){var e=this;this.attach=function(t){e.map!==t&&(e.map&&e.detachFromCurrentMap(),e.map=t,e.map.indicators._getCollectionDiv().appendChild(e.element),e.map.indicators.add(e))},this.remove=function(){e.detachFromCurrentMap(),e.element.remove()},this.getElement=function(){return e.element},this.detachFromCurrentMap=function(){e.map&&(e.map.indicators.remove(e),delete e.map)},this.element=document.createElement("div"),this.element.setAttribute("tabindex","0"),this.element.setAttribute("role","option"),null!=t&&t.setSize&&this.element.setAttribute("aria-setsize",t.setSize.toString()),null!=t&&t.positionInSet&&this.element.setAttribute("aria-posinset",t.positionInSet.toString()),this.element.setAttribute("aria-label","data point"),this.element.classList.add(Au.Css.hidden)}(window&&window.__extends||(Mu=function(t,e){return(Mu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Mu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Iu,Eu=t);var Mu,Eu,ju=Iu;function Iu(){var t=null!==Eu&&Eu.apply(this,arguments)||this;return t.buffer=128,t.maxZoom=18,t.cluster=!1,t.clusterRadius=50,t.clusterMaxZoom=void 0,t.clusterProperties=void 0,t.lineMetrics=!1,t.tolerance=.375,t.clusterMinPoints=2,t.generateId=!1,t.promoteId=void 0,t.filter=void 0,t}(window&&window.__extends||(Tu=function(t,e){return(Tu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Tu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Du,zu=Ze),Du.prototype.getId=function(){return this.id},Du.prototype._setMap=function(t,e){var o;void 0===e&&(e=!0),null==t||void 0===t?(o=this.map,delete this.map,e&&(this._invokeEvent("sourceremoved",this),o)&&o.events.invoke("sourceremoved",this)):(this.map=t,e&&(this._invokeEvent("sourceadded",this),this.map.events.invoke("sourceadded",this)))};var Tu,zu,k=Du;function Du(t){var e=zu.call(this)||this;return e.id=t||J(),e}var Ru,Bu,a=window&&window.__extends||(Ru=function(t,e){return(Ru=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ru(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Fu=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Nu=(a(A,Bu=k),A.prototype.add=function(t,e){this._addNoUpdate(t,e),this._updateSource()},A.prototype.clear=function(){this._clearNoUpdate(),this._updateSource()},A.prototype.dispose=function(){this.options=null,this.shapes=null,this.shapesMap=null,this.map=null},A.prototype.getClusterExpansionZoom=function(n){var r=this;return new Promise(function(e,o){var t;r.map?(t=r.map._getMap().getSource(r.getId()))&&"geojson"===t.type&&t.getClusterExpansionZoom(n).then(function(t){"number"==typeof t&&e(t)}).catch(function(t){t&&o(t)}):o("The DataSource hasn't been added to a map.")})},A.prototype.getClusterChildren=function(n){var r=this;return new Promise(function(e,o){var t;r.map?(t=r.map._getMap().getSource(r.getId()))&&"geojson"===t.type&&t.getClusterChildren(n).then(function(t){t&&e(r.map.sources._mapFeaturesToShapes(t,!1,r))}).catch(function(t){t&&o(t)}):o("The DataSource hasn't been added to a map.")})},A.prototype.getClusterLeaves=function(n,r,i){var s=this;return new Promise(function(e,o){var t;s.map?(t=s.map._getMap().getSource(s.getId()))&&"geojson"===t.type&&t.getClusterLeaves(n,r,i).then(function(t){t&&e(s.map.sources._mapFeaturesToShapes(t,!1,s))}).catch(function(t){t&&o(t)}):o("The DataSource hasn't been added to a map.")})},A.prototype.getOptions=function(){return c(this.options)},A.prototype.getShapes=function(){return Array.from(this.shapes)},A.prototype.importDataFromUrl=function(t){var e=this;return fetch(t,{method:"GET",mode:"cors"}).then(function(t){if(t.ok)return t.json();throw new Error("HTTP ".concat(t.status,": ").concat(t.statusText))}).then(function(t){e.add(t)})},A.prototype.getShapeById=function(t){return this.shapes[this.shapesMap.get(t)]||null},A.prototype.remove=function(t){var e,o,t=Array.isArray(t)?t:[t];try{for(var n=Fu(t),r=n.next();!r.done;r=n.next()){var i=r.value;"number"==typeof i?this._removeByIndex(i):this._removeById(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}this._updateSource()},A.prototype.removeById=function(t){var e,o,t=Array.isArray(t)?t:[t];try{for(var n=Fu(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._removeById(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}this._updateSource()},A.prototype.setOptions=function(t){t=(new ju).merge(this.options,c(t));Bc(this.options,t)||(this._invokeEvent("datasourceupdated",this),this.options=t,this.map&&this.map._rebuildStyle())},A.prototype.setShapes=function(t){this._clearNoUpdate(),this.add(t)},A.prototype.toJson=function(){return new $l(this.shapes.map(function(t){return t.toJson()}))},A.prototype._toJson=function(){return new $l(this.shapes.map(function(t){return t._toJson()}))},A.prototype._buildSource=function(){var t={type:"geojson",data:this._toJson(),maxzoom:this.options.maxZoom,cluster:this.options.cluster,clusterRadius:this.options.clusterRadius,tolerance:this.options.tolerance,lineMetrics:this.options.lineMetrics,clusterProperties:this.options.clusterProperties,buffer:this.options.buffer,clusterMinPoints:this.options.clusterMinPoints,generateId:this.options.generateId,promoteId:this.options.promoteId,filter:this.options.filter};return"number"==typeof this.options.clusterMaxZoom&&(t.clusterMaxZoom=this.options.clusterMaxZoom),t},A.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this._buildSource(),t=t._buildSource(),e.type===t.type)&&e.maxzoom===t.maxzoom&&e.cluster===t.cluster&&e.clusterRadius===t.clusterRadius&&e.tolerance===t.tolerance&&e.lineMetrics===t.lineMetrics&&JSON.stringify(e.clusterProperties)===JSON.stringify(t.clusterProperties)&&e.buffer===t.buffer&&e.clusterMinPoints===t.clusterMinPoints&&e.generateId===t.generateId&&e.promoteId===t.promoteId&&e.filter===t.filter},A.prototype._addNoUpdate=function(t,e){var o;t instanceof x?(this._addToSources(t,e),o=[t]):Array.isArray(t)?(o=t.map(function(t){return t instanceof x?t:new x(t)}),this._addToSources(o,e)):"FeatureCollection"===t.type?(o=t.features.map(function(t){return new x(t)}),this._addToSources(o,e)):"GeometryCollection"===t.type?(o=t.geometries.map(function(t){return new x(t)}),this._addToSources(o,e)):(t=new x(t),this._addToSources(t,e),o=[t]),this._invokeEvent("dataadded",o)},A.prototype._clearNoUpdate=function(){var t=this.shapes;this.shapes=[],this.shapesMap=new Ne,t&&0<t.length&&this._invokeEvent("dataremoved",t)},A.prototype._updateSource=function(){var t=this;void 0===this.requestId&&(this.requestId=requestAnimationFrame(function(){t._updateMboxSource(),t.requestId=void 0}))},A.prototype._addToSources=function(t,e){var o,n,r,i;if(t=Array.isArray(t)?t:[t],"number"!=typeof e)try{for(var s=Fu(t),a=s.next();!a.done;a=s.next()){var c=a.value;this.shapes.push(c),this.shapesMap.set(c.getId(),this.shapes.length-1)}}catch(t){o={error:t}}finally{try{a&&!a.done&&(n=s.return)&&n.call(s)}finally{if(o)throw o.error}}else for(var l=t.length-1;0<=l;l--)this.shapes.splice(e,0,t[l]),this._updateShapesMap(e);try{for(var u=Fu(t),p=u.next();!p.done;p=u.next())(c=p.value)._setDataSource(this)}catch(t){r={error:t}}finally{try{p&&!p.done&&(i=u.return)&&i.call(u)}finally{if(r)throw r.error}}},A.prototype._removeById=function(t){var t=t instanceof x?t.getId():"string"==typeof t||"number"==typeof t?t:t.id,e=this.shapes[this.shapesMap.get(t)];e&&(e._setDataSource(null),this.shapes.splice(this.shapesMap.get(t),1),this._updateShapesMap(this.shapesMap.get(t)),this.shapesMap.delete(t),this._invokeEvent("dataremoved",[e]))},A.prototype._removeByIndex=function(t){var e;if(t>=this.shapes.length)throw new Error("The specified remove index '".concat(t,"' ")+"is greater than the maximum possible index '".concat(this.shapes.length-1,"'"));e=this.shapes[t],this.shapesMap.delete(e.getId()),e._setDataSource(null),this.shapes.splice(t,1),this._updateShapesMap(t),this._invokeEvent("dataremoved",[e])},A.prototype._updateShapesMap=function(t){for(var e=t;e<this.shapes.length;e++)this.shapesMap.set(this.shapes[e].getId(),e)},A.prototype._updateMboxSource=function(){var t;this.map&&this.map._getMap()&&(t=this.map._getMap().getSource(this.getId()))&&"geojson"===t.type&&t.setData(this._toJson())},A);function A(t,e){t=Bu.call(this,t)||this;return t.requestId=void 0,t.options=(new ju).merge(c(e)),t.shapes=[],t.shapesMap=new Ne,t}(window&&window.__extends||(Zu=function(t,e){return(Zu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Zu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Uu,qu=t);var Zu,qu,Hu=Uu;function Uu(){var t=null!==qu&&qu.apply(this,arguments)||this;return t.bounds=void 0,t.minZoom=0,t.maxZoom=22,t.isTMS=!1,t.tiles=void 0,t.url=void 0,t}(window&&window.__extends||(Wu=function(t,e){return(Wu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Wu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Vu,Gu=k),Vu.prototype.getOptions=function(){return c(this.options)},Vu.prototype.getShape=function(t,e){return this.map._getMap().querySourceFeatures(this.getId(),{sourceLayer:t,filter:e})},Vu.prototype._buildSource=function(){var t={type:"vector"};return this.options.bounds&&(t.bounds=this.options.bounds),this.options.tiles?(t.tiles=this.options.tiles,t.minzoom=this.options.minZoom,t.maxzoom=this.options.maxZoom):this.options.url&&(t.url=this.options.url),this.options.isTMS&&(t.scheme="tms"),t},Vu.prototype._isDeepEqual=function(t){var e,o;return this.constructor===t.constructor&&(e=this._buildSource(),o=t._buildSource(),e.type===o.type)&&e.url===o.url&&(void 0===e.tiles&&void 0===o.tiles||e.tiles&&o.tiles&&e.tiles.length===o.tiles.length&&e.tiles.every(function(t,e){return t===o.tiles[e]}))&&e.minzoom===o.minzoom&&e.maxzoom===o.maxzoom&&e.bounds===o.bounds&&e.attribution===o.attribution&&e.promoteId===o.promoteId&&e.scheme===o.scheme};var Wu,Gu,r=Vu;function Vu(t,e){t=Gu.call(this,t)||this;return t.options=(new Hu).merge(c(e)),t}(window&&window.__extends||(Ku=function(t,e){return(Ku=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ku(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))($u,Yu=k),$u.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)&&e.canvas===t.canvas&&JSON.stringify(e.coordinates)===JSON.stringify(t.coordinates)&&e.animate===t.animate},$u.prototype._buildSource=function(){return this.source};var Ku,Yu,Ju=$u;function $u(t,e,o){t=Yu.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(Xu=function(t,e){return(Xu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Xu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(ep,Qu=k),ep.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)},ep.prototype._buildSource=function(){return this.source};var Xu,Qu,tp=ep;function ep(t,e,o){t=Qu.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(op=function(t,e){return(op=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}op(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(ip,np=k),ip.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)&&JSON.stringify(e.coordinates)===JSON.stringify(t.coordinates)&&e.url===t.url},ip.prototype._buildSource=function(){return this.source};var op,np,rp=ip;function ip(t,e,o){t=np.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(sp=function(t,e){return(sp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}sp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(lp,ap=k),lp.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)&&JSON.stringify(e.coordinates)===JSON.stringify(t.coordinates)&&e.urls===t.urls},lp.prototype._buildSource=function(){return this.source};var sp,ap,cp=lp;function lp(t,e,o){t=ap.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(up=function(t,e){return(up=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}up(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(hp,pp=Hu);var up,pp,Jo=hp;function hp(){var t=null!==pp&&pp.apply(this,arguments)||this;return t.tileSize=512,t}(window&&window.__extends||(dp=function(t,e){return(dp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}dp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(mp,fp=Jo);var dp,fp,yp=mp;function mp(){var t=null!==fp&&fp.apply(this,arguments)||this;return t.encoding=void 0,t}var gp,vp,i=window&&window.__extends||(gp=function(t,e){return(gp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}gp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),wp=window&&window.__assign||function(){return(wp=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},er=(i(_p,vp=k),_p.prototype.getOptions=function(){return c(this.options)},_p.prototype._buildSource=function(){return wp({type:"raster-dem",bounds:this.options.bounds,minzoom:this.options.minZoom,maxzoom:this.options.maxZoom,tileSize:this.options.tileSize,encoding:this.options.encoding},this.options.tiles?{tiles:this.options.tiles}:{url:this.options.url})},_p.prototype._isDeepEqual=function(t){return this.constructor===t.constructor&&(t=t.getOptions(),this.options.url===t.url)&&this.options.tiles===t.tiles&&this.options.bounds===t.bounds&&this.options.minZoom===t.minZoom&&this.options.maxZoom===t.maxZoom&&this.options.tileSize===t.tileSize&&this.options.encoding===t.encoding},_p);function _p(t,e){t=vp.call(this,t)||this;return t.options=(new yp).merge(c(e)),t}var bp,xp,Ao=Object.freeze({__proto__:null,CanvasSource:Ju,DataSource:Nu,ElevationTileSource:er,ImageSource:rp,Source:k,UnknownSource:tp,VectorTileSource:r,VideoSource:cp}),M=((window&&window.__extends||(bp=function(t,e){return(bp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}bp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Op,xp=Ze),Op.prototype.getId=function(){return this.id},Op.prototype.getMap=function(){return this.map||null},Op.prototype.onAdd=function(t){this.map=t,this._invokeEvent("layeradded",this),this.map.events.invoke("layeradded",this)},Op.prototype.onRemove=function(){var t=this.map;delete this.map,this._invokeEvent("layerremoved",this),t&&t.events.invoke("layerremoved",this)},Op._isMBoxEvent=function(t){return!this.LayerEvents.hasOwnProperty(t)},Op.prototype._updateBaseProperties=function(t,e){this._updateFilter(t.filter,e.filter),this._updateZoomRange(t.minZoom,e.minZoom,t.maxZoom,e.maxZoom),this._updateLayoutProperty("visibility",t.visible,e.visible,t.visible?"visible":"none")},Op.prototype._updateFilter=function(t,e){Bc(t,e)||this.map._getMap().setFilter(this.id,t)},Op.prototype._updatePaintProperty=function(t,e,o,n){Bc(e,o)||this.map._getMap().setPaintProperty(this.id,t,n||e)},Op.prototype._updateLayoutProperty=function(t,e,o,n){Bc(e,o)||this.map._getMap().setLayoutProperty(this.id,t,n||e)},Op.prototype._updateZoomRange=function(t,e,o,n){t===e&&n===o||this.map._getMap().setLayerZoomRange(this.id,t,o)},Op.LayerEvents={layeradded:void 0,layerremoved:void 0,focusin:void 0,focusout:void 0},Op);function Op(t){var e=xp.call(this)||this;return e.id=t||J(),e}(window&&window.__extends||(Sp=function(t,e){return(Sp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Sp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Pp,Cp=t),Pp._cloneCustomizer=function(t){if(t instanceof k)return t};var Sp,Cp,e=Pp;function Pp(){var t=null!==Cp&&Cp.apply(this,arguments)||this;return t.filter=void 0,t.minZoom=0,t.maxZoom=24,t.visible=!0,t}(window&&window.__extends||(Lp=function(t,e){return(Lp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Lp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Mp,kp=e);var Lp,kp,Ap=Mp;function Mp(){var t=null!==kp&&kp.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.color="#1A73AA",t.blur=0,t.opacity=1,t.strokeColor="#FFFFFF",t.strokeOpacity=1,t.strokeWidth=2,t.pitchAlignment="viewport",t.radius=8,t.createIndicators=!1,t.accessibilityIdKey=void 0,t}var Ep,jp,tr=window&&window.__extends||(Ep=function(t,e){return(Ep=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ep(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ip=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},Tp=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},zp=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Dp=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Rp=(tr(Bp,jp=M),Bp.prototype.getOptions=function(){return L(this.options,Ap._cloneCustomizer)},Bp.prototype.getSource=function(){return this.options.source},Bp.prototype.setOptions=function(t){t=(new Ap).merge(this.options,L(t,Ap._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("circle-blur",t.blur,this.options.blur),this._updatePaintProperty("circle-color",t.color,this.options.color),this._updatePaintProperty("circle-opacity",t.opacity,this.options.opacity),this._updatePaintProperty("circle-radius",t.radius,this.options.radius),this._updatePaintProperty("circle-stroke-color",t.strokeColor,this.options.strokeColor),this._updatePaintProperty("circle-stroke-opacity",t.strokeOpacity,this.options.strokeOpacity),this._updatePaintProperty("circle-stroke-width",t.strokeWidth,this.options.strokeWidth),this._updatePaintProperty("circle-pitch-alignment",t.pitchAlignment,this.options.pitchAlignment)}this.options=t},Bp.prototype.onAdd=function(e){var t,o,n=this;jp.prototype.onAdd.call(this,e),this.options.createIndicators&&(e.events.addOnce("idle",this._setAccessibleIndicator),e.events.add("moveend",this._setAccessibleIndicator),(t=this._getDataSource())?e.events.add("dataadded",t,function(){e.events.addOnce("idle",n._setAccessibleIndicator)}):(o="string"==typeof this.options.source?this.options.source:this.options.source.getId(),e.events.add("sourcedata",function(t){(null==(t=t.source)?void 0:t.getId())===o&&e._getMap().isSourceLoaded(o)&&(t=n._getSourceDataEventCacheKey())!==n.sourceDataEventCacheKey&&(n._setAccessibleIndicator(),n.sourceDataEventCacheKey=t)})))},Bp.prototype.onRemove=function(){var t;this.options.createIndicators&&(this.map.events.remove("idle",this._setAccessibleIndicator),this.map.events.remove("moveend",this._setAccessibleIndicator),(t=this._getDataSource())?this.map.events.remove("dataadded",t,this._setAccessibleIndicator):this.map.events.remove("sourcedata",this._setAccessibleIndicator)),jp.prototype.onRemove.call(this)},Bp.prototype._getSourceDataEventCacheKey=function(){var t;if(this.map)return t=this.map.getServiceOptions().mapConfiguration,Dp(Dp([],zp(this.map.getCamera().bounds),!1),[this.map.getCamera().zoom,this.map.getCamera().pitch,this.map.getStyle().style,t instanceof Object?t.id:t],!1).join(",")},Bp.prototype._getDataSource=function(){var t="string"==typeof this.options.source?this.map.sources.getById(this.options.source):this.options.source;if(t instanceof Nu)return t},Bp.prototype._buildLayers=function(){var t={id:this.id,type:"circle",source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:{"circle-color":this.options.color,"circle-blur":this.options.blur,"circle-opacity":this.options.opacity,"circle-stroke-color":this.options.strokeColor,"circle-stroke-opacity":this.options.strokeOpacity,"circle-stroke-width":this.options.strokeWidth,"circle-pitch-alignment":this.options.pitchAlignment,"circle-radius":this.options.radius},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),this.options.sourceLayer&&(t["source-layer"]=this.options.sourceLayer),[t]},Bp.prototype._getLayerIds=function(){return[this.id]},Bp.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},Bp.prototype.getFirstCoordinate=function(t){return Array.isArray(t[0])?this.getFirstCoordinate(t[0]):t},Bp);function Bp(t,e,o){var n=jp.call(this,e)||this;return n.accessibleIndicator=[],n._setAccessibleIndicator=function(){return Ip(n,void 0,void 0,function(){var e,c,l,u,p,h,d=this;return Tp(this,function(t){return this.accessibleIndicator.forEach(function(t){return t.remove()}),this.accessibleIndicator=[],e=this.map.layers.getRenderedShapes(this.map.getCamera().bounds,this),c=this.options.accessibilityIdKey||(this._getDataSource()?x._shapeIdPropName:void 0),l=function(e,o){var n=e[o],r=n instanceof x?n.toJson():n,i=new ku({positionInSet:o+1,setSize:e.length}),s=i.getElement(),a=zp(d.map.positionsToPixels([d.getFirstCoordinate(r.geometry.coordinates)]),1)[0];return s.addEventListener("focusin",function(t){d.accessibleIndicator.filter(function(t){return t!==i}).forEach(function(t){return t.remove()}),0<=o-1&&u(i,l(e,o-1)),o+1<e.length&&h(l(e,o+1)),2<=o&&o==e.length-1&&p(l(e,0)),0==o&&2<=e.length&&h(l(e,e.length-1)),void 0!==c&&d.map._getMap().setPaintProperty(d.id,"circle-stroke-color",["case",["==",["get",c],r.properties[c]],"#000000",d.options.strokeColor]);t={target:s,type:"focusin",map:d.map,shape:n,originalEvent:t,pixel:a};d._invokeEvent("focusin",t)}),s.addEventListener("focusout",function(t){void 0!==c&&d.map._getMap().setPaintProperty(d.id,"circle-stroke-color",["case",["==",["get",c],r.properties[c]],d.options.strokeColor,d.options.strokeColor]);t={target:s,type:"focusout",map:d.map,shape:n,originalEvent:t,pixel:a};d._invokeEvent("focusout",t)}),d.accessibleIndicator.push(i),i},u=function(t,e){e.attach(d.map);e=e.getElement(),t=t.getElement();t.parentElement.insertBefore(e,t)},p=function(t){t.attach(d.map);var t=t.getElement(),e=t.parentElement;e.insertBefore(t,e.firstElementChild)},h=function(t){t.attach(d.map)},0<e.length&&h(l(e,0)),1<e.length&&h(l(e,e.length-1)),[2]})})},n.options=(new Ap).merge(L(o,Ap._cloneCustomizer)),n.options.source=t||n.options.source,n}(window&&window.__extends||(Fp=function(t,e){return(Fp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(qp,Np=e),qp._cloneCustomizer=function(t){if(t instanceof k)return t};var Fp,Np,Zp=qp;function qp(){var t=null!==Np&&Np.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.color=["interpolate",["linear"],["heatmap-density"],0,"rgba(0,0, 255,0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],t.intensity=1,t.opacity=1,t.radius=30,t.weight=1,t}(window&&window.__extends||(Hp=function(t,e){return(Hp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Hp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Wp,Up=M),Wp.prototype.getOptions=function(){return L(this.options,Zp._cloneCustomizer)},Wp.prototype.getSource=function(){return this.options.source},Wp.prototype.setOptions=function(t){t=(new Zp).merge(this.options,L(t,Zp._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("heatmap-color",t.color,this.options.color),this._updatePaintProperty("heatmap-intensity",t.intensity,this.options.intensity),this._updatePaintProperty("heatmap-opacity",t.opacity,this.options.opacity),this._updatePaintProperty("heatmap-radius",t.radius,this.options.radius),this._updatePaintProperty("heatmap-weight",t.weight,this.options.weight)}this.options=t},Wp.prototype._buildLayers=function(){var t={id:this.id,type:"heatmap",source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:{"heatmap-color":this.options.color,"heatmap-intensity":this.options.intensity,"heatmap-opacity":this.options.opacity,"heatmap-radius":this.options.radius,"heatmap-weight":this.options.weight},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),this.options.sourceLayer&&(t["source-layer"]=this.options.sourceLayer),[t]},Wp.prototype._getLayerIds=function(){return[this.id]},Wp.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t};var Hp,Up,H=Wp;function Wp(t,e,o){e=Up.call(this,e)||this;return e.options=(new Zp).merge(L(o,Zp._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(Gp=function(t,e){return(Gp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Gp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Kp,Vp=e);var Gp,Vp,s=Kp;function Kp(){var t=null!==Vp&&Vp.apply(this,arguments)||this;return t.contrast=0,t.fadeDuration=300,t.hueRotation=0,t.maxBrightness=1,t.minBrightness=0,t.opacity=1,t.saturation=0,t}(window&&window.__extends||(Yp=function(t,e){return(Yp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Yp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Xp,Jp=s),Xp._cloneCustomizer=function(t){if(t instanceof k)return t};var Yp,Jp,$p=Xp;function Xp(){var t=null!==Jp&&Jp.apply(this,arguments)||this;return t.url=void 0,t.coordinates=void 0,t}(window&&window.__extends||(Qp=function(t,e){return(Qp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Qp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(oh,th=M),oh.prototype._getSourceIds=function(){var t=new Set;return t.add(this._getSourceId()),t},oh.prototype.onAdd=function(t){th.prototype.onAdd.call(this,t)};var Qp,th,eh=oh;function oh(){return null!==th&&th.apply(this,arguments)||this}(window&&window.__extends||(nh=function(t,e){return(nh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}nh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(ih,rh=eh),ih.prototype.getOptions=function(){return L(this.options,$p._cloneCustomizer)},ih.prototype.setOptions=function(t){var e,o=(new $p).merge(this.options,L(t,$p._cloneCustomizer)),n="string"==typeof t.url&&t.url!==this.getOptions().url,t=void 0!==t.coordinates&&t.coordinates!==this.getOptions().coordinates;this.map&&(this._updateBaseProperties(o,this.options),this._updatePaintProperty("raster-contrast",o.contrast,this.options.contrast),this._updatePaintProperty("raster-fade-duration",o.fadeDuration,this.options.fadeDuration),this._updatePaintProperty("raster-hue-rotate",o.hueRotation,this.options.hueRotation),this._updatePaintProperty("raster-brightness-max",o.maxBrightness,this.options.maxBrightness),this._updatePaintProperty("raster-opacity",o.opacity,this.options.opacity),this._updatePaintProperty("raster-saturation",o.saturation,this.options.saturation),e=this.map._getMap().getSource(this._getSourceId()))&&(n||t)&&e.updateImage(o),this.options=o,n?this.reloadImage():t&&this.updateTransform()},ih.prototype.getPositions=function(e){return this.transform.then(function(t){return t.toTarget(e)})},ih.prototype.getPixels=function(e){return this.transform.then(function(t){return t.toSource(e)})},ih.getCoordinatesFromRefPoints=function(t,e,o,n){return new pu(o,n).toTarget([[0,0],[t,0],[t,e],[0,e]])},ih.getCoordinatesFromEdges=function(t,e,o,n,r){"number"!=typeof r&&(r=0);e=[Math.min(n,o),e,Math.max(n,o),t],n=S.getCenter(e);return Cl([S.getNorthWest(e),S.getNorthEast(e),S.getSouthEast(e),S.getSouthWest(e)],n,r)},ih.prototype._buildLayers=function(){var t={id:this.id,type:"raster",source:this._getSourceId(),layout:{visibility:this.options.visible?"visible":"none"},paint:{"raster-opacity":this.options.opacity,"raster-hue-rotate":this.options.hueRotation,"raster-brightness-min":this.options.minBrightness,"raster-brightness-max":this.options.maxBrightness,"raster-saturation":this.options.saturation,"raster-contrast":this.options.contrast,"raster-fade-duration":this.options.fadeDuration},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),[t]},ih.prototype._getLayerIds=function(){return[this.id]},ih.prototype._buildSource=function(){return{type:"image",url:this.options.url,coordinates:this.options.coordinates}},ih.prototype._getSourceId=function(){return"".concat(this.getId(),"-ImageSource")},ih.prototype.reloadImage=function(){var o=this;this.options.url&&(this.transform=new Promise(function(e,t){o.img.onload=function(){var t=[[0,0],[o.img.width,0],[o.img.width,o.img.height],[0,o.img.height]];e(new pu(t,o.options.coordinates)),o.isLoading=!1},o.img.onerror=o.img.onabort=function(){t("Failed to load image")},o.isLoading=!0,o.img.src=o.options.url}))},ih.prototype.updateTransform=function(){var t;this.isLoading||(t=[[0,0],[this.img.width,0],[this.img.width,this.img.height],[0,this.img.height]],this.transform=Promise.resolve(new pu(t,this.options.coordinates)))},ih.prototype._getSourceWrapper=function(){var t=this._getSourceId(),e=this._buildSource();return new rp(t,e)};var nh,rh,In=ih;function ih(t,e){e=rh.call(this,e)||this;return e.isLoading=!1,e.options=(new $p).merge(L(t,$p._cloneCustomizer)),e.img=new Image,e.reloadImage(),e}(window&&window.__extends||(sh=function(t,e){return(sh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}sh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(lh,ah=e);var sh,ah,ch=lh;function lh(){var t=null!==ah&&ah.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.lineCap="round",t.lineJoin="round",t.blur=0,t.strokeColor="#1E90FF",t.strokeDashArray=void 0,t.strokeGradient=void 0,t.offset=0,t.strokeOpacity=1,t.translate=new Hc(0,0),t.translateAnchor="map",t.strokeWidth=2,t}var uh,ph,q=window&&window.__extends||(uh=function(t,e){return(uh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}uh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),hh=window&&window.__assign||function(){return(hh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},dh=(q(fh,ph=M),fh.prototype.getOptions=function(){return L(this.options,ch._cloneCustomizer)},fh.prototype.getSource=function(){return this.options.source},fh.prototype.setOptions=function(t){t=(new ch).merge(this.options,L(t,ch._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("line-blur",t.blur,this.options.blur),this._updateLayoutProperty("line-cap",t.lineCap,this.options.lineCap),this._updateLayoutProperty("line-join",t.lineJoin,this.options.lineJoin),this._updatePaintProperty("line-offset",t.offset,this.options.offset),this._updatePaintProperty("line-color",t.strokeColor,this.options.strokeColor),this._updatePaintProperty("line-dasharray",t.strokeDashArray,this.options.strokeDashArray),this._updatePaintProperty("line-gradient",t.strokeGradient,this.options.strokeGradient),this._updatePaintProperty("line-opacity",t.strokeOpacity,this.options.strokeOpacity),this._updatePaintProperty("line-width",t.strokeWidth,this.options.strokeWidth),this._updatePaintProperty("line-translate",t.translate,this.options.translate),this._updatePaintProperty("line-translate-anchor",t.translateAnchor,this.options.translateAnchor)}this.options=t},fh.prototype._buildLayers=function(){return[hh(hh(hh(hh({id:this.id,type:"line"},this.options.sourceLayer&&{"source-layer":this.options.sourceLayer}),{source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none","line-cap":this.options.lineCap,"line-join":this.options.lineJoin},paint:hh(hh(hh({"line-blur":this.options.blur,"line-color":this.options.strokeColor},this.options.strokeDashArray?{"line-dasharray":this.options.strokeDashArray}:{}),this.options.strokeGradient?{"line-gradient":this.options.strokeGradient}:{}),{"line-offset":this.options.offset,"line-opacity":this.options.strokeOpacity,"line-translate":this.options.translate,"line-translate-anchor":this.options.translateAnchor,"line-width":this.options.strokeWidth})}),this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom})]},fh.prototype._getLayerIds=function(){return[this.id]},fh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},fh);function fh(t,e,o){e=ph.call(this,e)||this;return e.options=(new ch).merge(L(o,ch._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(yh=function(t,e){return(yh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}yh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(vh,mh=e);var yh,mh,gh=vh;function vh(){var t=null!==mh&&mh.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.base=0,t.fillColor="#1E90FF",t.height=0,t.fillOpacity=1,t.fillPattern=void 0,t.translate=new Hc(0,0),t.translateAnchor="map",t.verticalGradient=!0,t}var wh,_h,jn=window&&window.__extends||(wh=function(t,e){return(wh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}wh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),bh=window&&window.__assign||function(){return(bh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},yt=(jn(xh,_h=M),xh.prototype.getOptions=function(){return L(this.options,gh._cloneCustomizer)},xh.prototype.getSource=function(){return this.options.source},xh.prototype.setOptions=function(t){t=(new gh).merge(this.options,L(t,gh._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("fill-extrusion-base",t.base,this.options.base),this._updatePaintProperty("fill-extrusion-color",t.fillColor,this.options.fillColor),this._updatePaintProperty("fill-extrusion-height",t.height,this.options.height),this._updatePaintProperty("fill-extrusion-opacity",t.fillOpacity,this.options.fillOpacity),this._updatePaintProperty("fill-extrusion-pattern",t.fillPattern,this.options.fillPattern),this._updatePaintProperty("fill-extrusion-translate",t.translate,this.options.translate),this._updatePaintProperty("fill-extrusion-translate-anchor",t.translateAnchor,this.options.translateAnchor),this._updatePaintProperty("fill-extrusion-vertical-gradient",t.verticalGradient,this.options.verticalGradient)}this.options=t},xh.prototype._buildLayers=function(){return[bh(bh(bh(bh({id:this.id,type:"fill-extrusion"},this.options.sourceLayer&&{"source-layer":this.options.sourceLayer}),{source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:bh(bh({"fill-extrusion-base":this.options.base,"fill-extrusion-height":this.options.height,"fill-extrusion-opacity":this.options.fillOpacity},this.options.fillPattern?{"fill-extrusion-pattern":this.options.fillPattern}:{"fill-extrusion-color":this.options.fillColor}),{"fill-extrusion-translate":this.options.translate,"fill-extrusion-translate-anchor":this.options.translateAnchor,"fill-extrusion-vertical-gradient":this.options.verticalGradient})}),this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom})]},xh.prototype._getLayerIds=function(){return[this.id]},xh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},xh);function xh(t,e,o){e=_h.call(this,e)||this;return e.options=(new gh).merge(L(o,gh._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(Oh=function(t,e){return(Oh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Oh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ph,Sh=e);var Oh,Sh,Ch=Ph;function Ph(){var t=null!==Sh&&Sh.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.fillColor="#1E90FF",t.fillOpacity=.5,t.fillPattern=void 0,t.fillAntialias=!0,t}(window&&window.__extends||(Lh=function(t,e){return(Lh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Lh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Mh,kh=M),Mh.prototype.getOptions=function(){return L(this.options,Ch._cloneCustomizer)},Mh.prototype.getSource=function(){return this.options.source},Mh.prototype.setOptions=function(t){t=(new Ch).merge(this.options,L(t,Ch._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("fill-color",t.fillColor,this.options.fillColor),this._updatePaintProperty("fill-opacity",t.fillOpacity,this.options.fillOpacity),this._updatePaintProperty("fill-pattern",t.fillPattern,this.options.fillPattern),this._updatePaintProperty("fill-antialias",t.fillAntialias,this.options.fillAntialias)}this.options=t},Mh.prototype._buildLayers=function(){var t={id:this.id,type:"fill",source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:{"fill-opacity":this.options.fillOpacity,"fill-antialias":this.options.fillAntialias},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),this.options.sourceLayer&&(t["source-layer"]=this.options.sourceLayer),this.options.fillPattern?t.paint["fill-pattern"]=this.options.fillPattern:t.paint["fill-color"]=this.options.fillColor,[t]},Mh.prototype._getLayerIds=function(){return[this.id]},Mh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t};var Lh,kh,Ah=Mh;function Mh(t,e,o){e=kh.call(this,e)||this;return e.options=(new Ch).merge(L(o,Ch._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(Eh=function(t,e){return(Eh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Eh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Th,jh=t);var Eh,jh,Ih=Th;function Th(){var t=null!==jh&&jh.apply(this,arguments)||this;return t.allowOverlap=!1,t.anchor="bottom",t.ignorePlacement=!1,t.image="marker-blue",t.offset=new Hc(0,0),t.optional=!1,t.padding=2,t.pitchAlignment="auto",t.rotation=0,t.rotationAlignment="auto",t.size=1,t.opacity=1,t}(window&&window.__extends||(zh=function(t,e){return(zh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}zh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Bh,Dh=t);var zh,Dh,Rh=Bh;function Bh(){var t=null!==Dh&&Dh.apply(this,arguments)||this;return t.allowOverlap=!1,t.anchor="center",t.textField=void 0,t.font=["StandardFont-Regular"],t.ignorePlacement=!1,t.justify="center",t.offset=new Hc(0,0),t.optional=!1,t.padding=2,t.pitchAlignment="auto",t.radialOffset=void 0,t.rotation=0,t.rotationAlignment="auto",t.variableAnchor=void 0,t.size=16,t.color="#000000",t.haloBlur=0,t.haloColor="rgba(0,0,0,0)",t.haloWidth=0,t.opacity=1,t}(window&&window.__extends||(Fh=function(t,e){return(Fh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(qh,Nh=e);var Fh,Nh,Zh=qh;function qh(){var t=null!==Nh&&Nh.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.iconOptions=new Ih,t.textOptions=new Rh,t.placement="point",t.sortKey=void 0,t.zOrder="auto",t.lineSpacing=250,t}var Hh,Uh,ze=window&&window.__extends||(Hh=function(t,e){return(Hh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Hh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Wh=window&&window.__assign||function(){return(Wh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Gh=(ze(Vh,Uh=M),Vh.prototype.getOptions=function(){return L(this.options,Zh._cloneCustomizer)},Vh.prototype.getSource=function(){return this.options.source},Vh.prototype.setOptions=function(t){t=(new Zh).merge(this.options,L(t,Zh._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);var e=this.options,o=t.iconOptions,n=e.iconOptions,r=t.textOptions,i=e.textOptions;this._updateBaseProperties(t,e),this._updateLayoutProperty("symbol-spacing",t.lineSpacing,e.lineSpacing),this._updateLayoutProperty("symbol-placement",t.placement,e.placement),this._updateLayoutProperty("symbol-sort-key",t.sortKey,e.sortKey),this._updateLayoutProperty("symbol-z-order",t.zOrder,e.zOrder),this._updateLayoutProperty("icon-allow-overlap",o.allowOverlap,n.allowOverlap),this._updateLayoutProperty("icon-anchor",o.anchor,n.anchor),this._updateLayoutProperty("icon-ignore-placement",o.ignorePlacement,n.ignorePlacement),this._updateLayoutProperty("icon-image",o.image,n.image),this._updateLayoutProperty("icon-offset",o.offset,n.offset),this._updatePaintProperty("icon-opacity",o.opacity,n.opacity),this._updateLayoutProperty("icon-optional",o.optional,n.optional),this._updateLayoutProperty("icon-padding",o.padding,n.padding),this._updateLayoutProperty("icon-pitch-alignment",o.pitchAlignment,n.pitchAlignment),this._updateLayoutProperty("icon-rotate",o.rotation,n.rotation),this._updateLayoutProperty("icon-rotation-alignment",o.rotationAlignment,n.rotationAlignment),this._updateLayoutProperty("icon-size",o.size,n.size),this._updateLayoutProperty("text-allow-overlap",r.allowOverlap,i.allowOverlap),this._updateLayoutProperty("text-anchor",r.anchor,i.anchor),this._updatePaintProperty("text-color",r.color,i.color),this._updateLayoutProperty("text-font",r.font,i.font),this._updateLayoutProperty("text-ignore-placement",r.ignorePlacement,i.ignorePlacement),this._updateLayoutProperty("text-justify",r.justify,i.justify),this._updatePaintProperty("text-halo-blur",r.haloBlur,i.haloBlur),this._updatePaintProperty("text-halo-color",r.haloColor,i.haloColor),this._updatePaintProperty("text-halo-width",r.haloWidth,i.haloWidth),this._updateLayoutProperty("text-offset",r.offset,i.offset),this._updatePaintProperty("text-opacity",r.opacity,i.opacity),this._updateLayoutProperty("text-optional",r.optional,i.optional),this._updateLayoutProperty("text-padding",r.padding,i.padding),this._updateLayoutProperty("text-pitch-alignment",r.pitchAlignment,i.pitchAlignment),this._updateLayoutProperty("text-radial-offset",r.radialOffset,i.radialOffset),this._updateLayoutProperty("text-rotate",r.rotation,i.rotation),this._updateLayoutProperty("text-rotation-alignment",r.rotationAlignment,i.rotationAlignment),this._updateLayoutProperty("text-size",r.size,i.size),this._updateLayoutProperty("text-variable-anchor",r.variableAnchor,i.variableAnchor),this._updateLayoutProperty("text-field",r.textField,i.textField)}this.options=t},Vh.prototype._buildLayers=function(){var t=Wh(Wh(Wh(Wh({id:this.id,type:"symbol"},this.options.sourceLayer&&{"source-layer":this.options.sourceLayer}),{source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:Wh(Wh({visibility:this.options.visible?"visible":"none","symbol-placement":this.options.placement,"symbol-spacing":this.options.lineSpacing,"symbol-z-order":this.options.zOrder,"text-allow-overlap":this.options.textOptions.allowOverlap,"text-anchor":this.options.textOptions.anchor},this.options.textOptions.textField&&{"text-field":this.options.textOptions.textField}),{"text-font":this.options.textOptions.font,"text-ignore-placement":this.options.textOptions.ignorePlacement,"text-justify":this.options.textOptions.justify,"text-offset":this.options.textOptions.offset,"text-optional":this.options.textOptions.optional,"text-padding":this.options.textOptions.padding,"text-pitch-alignment":this.options.textOptions.pitchAlignment,"text-rotate":this.options.textOptions.rotation,"text-rotation-alignment":this.options.textOptions.rotationAlignment,"text-size":this.options.textOptions.size,"icon-allow-overlap":this.options.iconOptions.allowOverlap,"icon-anchor":this.options.iconOptions.anchor,"icon-ignore-placement":this.options.iconOptions.ignorePlacement,"icon-image":this.options.iconOptions.image,"icon-offset":this.options.iconOptions.offset,"icon-optional":this.options.iconOptions.optional,"icon-padding":this.options.iconOptions.padding,"icon-pitch-alignment":this.options.iconOptions.pitchAlignment,"icon-rotate":this.options.iconOptions.rotation,"icon-rotation-alignment":this.options.iconOptions.rotationAlignment,"icon-size":this.options.iconOptions.size}),paint:{"text-color":this.options.textOptions.color,"text-halo-blur":this.options.textOptions.haloBlur,"text-halo-color":this.options.textOptions.haloColor,"text-halo-width":this.options.textOptions.haloWidth,"text-opacity":this.options.textOptions.opacity,"icon-opacity":this.options.iconOptions.opacity}}),this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom});return void 0!==this.options.sortKey&&(t.layout["symbol-sort-key"]=this.options.sortKey),void 0!==this.options.textOptions.radialOffset&&(t.layout["text-radial-offset"]=this.options.textOptions.radialOffset),void 0!==this.options.textOptions.variableAnchor&&(t.layout["text-variable-anchor"]=this.options.textOptions.variableAnchor),[t]},Vh.prototype._getLayerIds=function(){return[this.id]},Vh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},Vh);function Vh(t,e,o){e=Uh.call(this,e)||this;return e.options=(new Zh).merge(L(o,Zh._cloneCustomizer)),e.options.source=t||e.options.source,e}var Kh,Yh,bi=window&&window.__extends||(Kh=function(t,e){return(Kh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Kh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Jh=window&&window.__assign||function(){return(Jh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},$h=(bi(Xh,Yh=k),Xh.prototype._buildSource=function(){return this.source},Xh.prototype._isDeepEqual=function(t){var o,e,n,r;return this.constructor===t.constructor&&(r=this.source,o=t.source,t=r.type===o.type&&r.url===o.url&&(void 0===r.tiles&&void 0===o.tiles||r.tiles&&o.tiles&&r.tiles.length===o.tiles.length&&r.tiles.every(function(t,e){return t===o.tiles[e]}))&&r.minzoom===o.minzoom&&r.maxzoom===o.maxzoom&&r.bounds===o.bounds&&r.attribution===o.attribution,e="raster"!==r.type||"raster"===r.type&&r.type===o.type&&r.tileSize===o.tileSize&&r.scheme===o.scheme,n="raster-dem"!==r.type||"raster-dem"===r.type&&r.type===o.type&&r.tileSize===o.tileSize&&r.encoding===o.encoding,r="vector"!==r.type||"vector"===r.type&&r.type===o.type&&r.promoteId===o.promoteId&&r.scheme===o.scheme,t)&&e&&n&&r},Xh.prototype._modifySource=function(t,e){if("raster"!==t.type&&"raster-dem"!==t.type&&"vector"!==t.type||!t.tiles){if("raster"!==t.type&&"raster-dem"!==t.type&&"vector"!==t.type||!t.url)throw new Error("Source definition must define a TileJSON 'url' or a 'tiles' array.");t.url="string"==typeof t.url?t.url:new wt({domain:et,path:t.url.path,queryParams:Jh(Jh({},e),t.url.queryParams)}).toString()}else{var o=t.tiles.map(function(t){return"string"==typeof t?t:new wt({domain:et,path:t.path,queryParams:Jh(Jh({},e),t.queryParams)}).toString()});t.tiles=o}return t},Xh);function Xh(t,e,o){t=Yh.call(this,t)||this;return t.source=t._modifySource(e,o),t}(window&&window.__extends||(Qh=function(t,e){return(Qh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Qh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(od,td=s);var Qh,td,ed=od;function od(){var t=null!==td&&td.apply(this,arguments)||this;return t.bounds=[-180,-85.0511,180,85.0511],t.minSourceZoom=0,t.maxSourceZoom=22,t.tileSize=512,t.isTMS=!1,t.subdomains=void 0,t.tileUrl=void 0,t}var nd,rd,R=window&&window.__extends||(nd=function(t,e){return(nd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}nd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),id=window&&window.__assign||function(){return(id=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},sd=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},ad=(R(cd,rd=eh),cd.prototype.getOptions=function(){return L(this.options,ed._cloneCustomizer)},cd.prototype.setOptions=function(t){t=(new ed).merge(this.options,L(t,ed._cloneCustomizer));if(this.map){if(!Bc(t.bounds,this.options.bounds)||t.isTMS!==this.options.isTMS||t.maxSourceZoom!==this.options.maxSourceZoom||t.minSourceZoom!==this.options.minSourceZoom||!Bc(t.subdomains,this.options.subdomains)||t.tileSize!==this.options.tileSize||t.tileUrl!==this.options.tileUrl)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("raster-contrast",t.contrast,this.options.contrast),this._updatePaintProperty("raster-fade-duration",t.fadeDuration,this.options.fadeDuration),this._updatePaintProperty("raster-hue-rotate",t.hueRotation,this.options.hueRotation),this._updatePaintProperty("raster-brightness-max",t.maxBrightness,this.options.maxBrightness),this._updatePaintProperty("raster-opacity",t.opacity,this.options.opacity),this._updatePaintProperty("raster-saturation",t.saturation,this.options.saturation)}this.options=t},cd.prototype._setOptionsNoUpdate=function(t){this.options=(new ed).merge(this.options,L(t,ed._cloneCustomizer))},cd.prototype._buildLayers=function(){return[id(id({id:this.id,type:"raster",source:this._getSourceId(),layout:{visibility:this.options.visible?"visible":"none"},paint:{"raster-contrast":this.options.contrast,"raster-fade-duration":this.options.fadeDuration,"raster-hue-rotate":this.options.hueRotation,"raster-brightness-max":this.options.maxBrightness,"raster-brightness-min":this.options.minBrightness,"raster-opacity":this.options.opacity,"raster-saturation":this.options.saturation}},this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom})]},cd.prototype._getLayerIds=function(){return[this.id]},cd.prototype._buildSource=function(){var e,t;if(this.options.tileUrl){if(-1===this.options.tileUrl.indexOf("{"))return{type:"raster",url:this.options.tileUrl};if(-1!==this.options.tileUrl.indexOf("{subdomain}")){if(!(this.options.subdomains&&0<this.options.subdomains.length))throw new Error("The {subdomain} placeholder was included in the tileUrl but no subdomains were specified");var o=[];try{for(var n=sd(this.options.subdomains),r=n.next();!r.done;r=n.next()){var i=r.value;o.push(this.options.tileUrl.replace(/{subdomain}/g,i))}}catch(t){e={error:t}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}t=o}else t=[this.options.tileUrl]}return id({type:"raster",bounds:this.options.bounds,maxzoom:this.options.maxSourceZoom,minzoom:this.options.minSourceZoom,scheme:this.options.isTMS?"tms":"xyz",tileSize:this.options.tileSize},t&&{tiles:t})},cd.prototype._getSourceId=function(){return"".concat(this.getId(),"-RasterSource")},cd.prototype._getSourceWrapper=function(){var t=this._getSourceId(),e=this._buildSource();return new $h(t,{name:t,tiles:e.tiles,type:e.type,url:e.url})},cd);function cd(t,e){e=rd.call(this,e)||this;return t&&e.setOptions(t),e}(window&&window.__extends||(ld=function(t,e){return(ld=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ld(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(hd,ud=e);var ld,ud,pd=hd;function hd(){var t=null!==ud&&ud.apply(this,arguments)||this;return t.renderer=void 0,t}(window&&window.__extends||(dd=function(t,e){return(dd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}dd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(md,fd=M),md.prototype.getOptions=function(){return L(this.options,pd._cloneCustomizer)},md.prototype.setOptions=function(t){t=(new pd).merge(this.options,L(t,pd._cloneCustomizer));this.map&&this.map.triggerRepaint(),this.options=t},md.prototype.onAdd=function(t){var e,o;fd.prototype.onAdd.call(this,t),this.map.events.add("stylechanged",this._onStyleChange),this.options.renderer&&this.glContext&&null!=(o=(e=this.options.renderer).onAdd)&&o.call(e,t,this.glContext)},md.prototype.onRemove=function(){var t,e;this.options.renderer&&this.glContext&&null!=(e=(t=this.options.renderer).onRemove)&&e.call(t,this.map,this.glContext),this.map.events.remove("stylechanged",this._onStyleChange),this.glContext=null,fd.prototype.onRemove.call(this)},md.prototype._buildLayers=function(){var r=this;if(this.options.renderer)return[{id:this.id,type:"custom",renderingMode:this.options.renderer.renderingMode,onAdd:function(t,e){r.glContext=e},onRemove:function(t,e){},prerender:function(t,e){var o,n;r._shouldRender()&&null!=(n=(o=r.options.renderer).prerender)&&n.call(o,t,e)},render:function(t,e){r._shouldRender()&&r.options.renderer.render(t,e)}}];throw new Error("Cannot build the WebGL layer because renderer was not set.")},md.prototype._getLayerIds=function(){return[this.id]},md.prototype._getSourceIds=function(){return(new Set).add(this.source.getId())},md.prototype._shouldRender=function(){var t;return!!this.map&&(t=this.map.getCamera().zoom,this.options.visible)&&this.options.minZoom<=t&&this.options.maxZoom>t};var dd,fd,yd=md;function md(t,e){var o=fd.call(this,t)||this;return o._onStyleChange=function(){var t,e;o.map._getMap().getLayer(o.id)||(t=o.map,e=null==(e=o.map.layers._getUserLayers().find(function(t){return t.layer.getId()==o.id}))?void 0:e.before,t.layers.remove(o),t.layers.add(o,e))},o.options=(new pd).merge(L(e,pd._cloneCustomizer)),o.source=new Nu,o}var xi=Object.freeze({__proto__:null,BubbleLayer:Rp,HeatMapLayer:H,ImageLayer:In,Layer:M,LineLayer:dh,PolygonExtrusionLayer:yt,PolygonLayer:Ah,SymbolLayer:Gh,TileLayer:ad,WebGLLayer:yd}),gd=(vd.convertHtmlString=function(t){var e;return"string"==typeof t?((e=document.createElement("div")).innerHTML=t,e):t},vd.parseWithFilter=function(t,e,o,n){var r=this;if(void 0===e&&(e=function(t){return!0}),void 0===o&&(o=function(t){return t}),void 0===n&&(n=function(){return document.createElement("div")}),"string"==typeof t){var i=(new DOMParser).parseFromString(t,"text/html").body;if(0==i.children.length)return o(i.innerHTML);var s,i=1==i.children.length&&1==i.childNodes.length?i.children[0]:(s=n(),Array.from(i.childNodes).map(function(t){return s.append(t)}),s)}else i=t;return Array.from(i.children).forEach(function(t){return r.parseWithFilter(t,e,o)}),e(i)?o(i):(i.parentNode&&i.parentNode.removeChild(i),null)},vd);function vd(){}var wd=Vn,_d=Ks;var bd,xd,Od=B(function(t){return wd(t)&&1===t.nodeType&&!_d(t)}),Sd=((window&&window.__extends||(bd=function(t,e){return(bd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}bd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Cd,xd=t),Cd._cloneCustomizer=function(t){if(Od(t))return t},Cd);function Cd(){var t=null!==xd&&xd.apply(this,arguments)||this;return t.anchor="none",t.draggable=!1,t.closeButton=!0,t.content=document.createElement("span"),t.fillColor="#FFFFFF",t.pixelOffset=new Hc(0,0),t.position=new Zl(0,0),t.showPointer=!0,t}var Pd,Ld,a=window&&window.__extends||(Pd=function(t,e){return(Pd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Pd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),kd=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Ad=(a(E,Ld=Ze),E.prototype.setPopupOptions=function(t){this.setOptions(t)},E.prototype.setOptions=function(t){var e,t=(new Sd).merge(this.options,L(t,Sd._cloneCustomizer));t.content!==this.options.content?(this.htmlContent.remove(),this.htmlContent=this._createHtmlContent(t),this.contentDiv.prepend(this.htmlContent)):t.draggable!==this.options.draggable&&this._setDraggable(this.htmlContent,t.draggable),t.closeButton&&!this.closeBtn?(this.closeBtn=this._createCloseButton(),this.contentDiv.appendChild(this.closeBtn),e=_("close"),this.contentDiv.appendChild(e),b(e,this.closeBtn,!0)):!t.closeButton&&this.closeBtn&&(this.contentDiv.removeChild(this.closeBtn),delete this.closeBtn),t.showPointer&&!this.arrowDiv?(this.arrowDiv=this._createArrowDiv(),this.containerDiv.appendChild(this.arrowDiv)):!t.showPointer&&this.arrowDiv&&(this.containerDiv.removeChild(this.arrowDiv),delete this.arrowDiv),t.fillColor!==this.options.fillColor&&(this.containerDiv.style.borderColor=t.fillColor,this.contentDiv.style.backgroundColor=t.fillColor),this.marker&&(t.anchor!==this.options.anchor?"none"===this.options.anchor?(this.autoAnchor!==t.anchor&&this._replaceMarker(this.map,t),this.map.events.remove("move",this._onMove),delete this.autoAnchor):(this._replaceMarker(this.map,t),"none"===t.anchor&&this.map.events.add("move",this._onMove)):(Bc(t.position,this.options.position)||this.marker.setLngLat(t.position),Bc(t.pixelOffset,this.options.pixelOffset)||this.marker.setOffset(t.pixelOffset))),this.options=t},E.prototype.getPopupOptions=function(){return this.getOptions()},E.prototype.getOptions=function(){return L(this.options,Sd._cloneCustomizer)},E.prototype.getPopupContainer=function(){return this.containerDiv},E.prototype._dragToPixel=function(t){this.dragging||(this.dragging=!0,this.contentDiv.style.pointerEvents="none",this._invokeEvent("dragstart",{type:"dragstart",target:this}));t=[t[0]+this.dragOffset[0],t[1]+this.dragOffset[1]],t=kd(this.map.pixelsToPositions([t]),1)[0];this.options.position=t,this.marker.setLngLat(this.options.position),this._invokeEvent("drag",{type:"drag",target:this})},E.prototype._onUp=function(){this.dragging&&(this.contentDiv.style.pointerEvents="",this._invokeEvent("dragend",{type:"dragend",target:this}),"none"===this.options.anchor)&&this._onMove(),delete this.dragOffset,delete this.dragging},E.prototype._createContainerDiv=function(t){var e=this,o=document.createElement("div"),n=(o.classList.add(E.Css.container),o.classList.add(E.Css.hidden),o.style.borderColor=t.fillColor,o.setAttribute("role","dialog"),o.setAttribute("aria-label","Map Information Window"),!1);return o.addEventListener("keydown",function(t){"Tab"!==t.key&&"Escape"!==t.key&&"Esc"!==t.key||(n=!0)}),o.addEventListener("keyup",function(t){"Tab"!==t.key&&"Escape"!==t.key&&"Esc"!==t.key||(n=!1)}),o.addEventListener("focusin",function(t){e.map&&!e.isOpen()&&(e.open(e.map),t.target instanceof HTMLElement)&&t.target.focus()}),o.addEventListener("focusout",function(t){n&&t.relatedTarget instanceof Node&&!o.contains(t.relatedTarget)&&(n=!1,e.isOpen())&&e.close()}),o},E.prototype._createContentDiv=function(t){var e=document.createElement("div");return e.classList.add(E.Css.content),e.style.backgroundColor=t.fillColor,e.setAttribute("tabindex","0"),this.htmlContent=this._createHtmlContent(t),e.appendChild(this.htmlContent),e},E.prototype._createArrowDiv=function(){var t=document.createElement("div");return t.classList.add(E.Css.arrow),t},E.prototype._createCloseButton=function(){var t=document.createElement("button");return t.addEventListener("click",this.close),t.classList.add(E.Css.close),t.setAttribute("aria-label","close"),t.setAttribute("type","button"),t.setAttribute("tabindex","0"),t.innerHTML="×",t},E.prototype._createHtmlContent=function(t){var e=gd.convertHtmlString(t.content);return t.draggable&&this._setDraggable(e,t.draggable),e},E.prototype._createMarker=function(t,e){var o=this.marker?this.marker.getLngLat():t.position,e=("none"===t.anchor?(this.autoAnchor=e||"bottom",this.containerDiv.classList.add(this.autoAnchor),new D.Marker({anchor:this.autoAnchor,element:this.containerDiv,offset:t.pixelOffset})):(this.containerDiv.classList.add(t.anchor),new D.Marker({anchor:t.anchor,element:this.containerDiv,offset:t.pixelOffset}))).setLngLat(o);return e},E.prototype._getAutoAnchor=function(t,e){var o,n,r=this.containerDiv.offsetWidth,i=this.containerDiv.offsetHeight,s=[];return(n=this.marker?(o=(n=t._getMap().project(this.marker.getLngLat())).x,n.y):(n=kd(t.positionsToPixels([e.position]),1),o=(e=kd(n[0],2))[0],e[1]))<i?s.push("top"):n>t.getCanvas().offsetHeight-i&&s.push("bottom"),o<r/2?s.push("left"):o>t.getCanvas().offsetWidth-r/2&&s.push("right"),0<s.length?s.join("-"):"bottom"},E.prototype._replaceMarker=function(t,e,o){var n=this.containerDiv.nextElementSibling;this.marker.remove(),this.containerDiv.classList.remove(this.autoAnchor||this.options.anchor),this.marker=this._createMarker(e,o),this.marker.addTo(t._getMap()),t.popups._getCollectionDiv().insertBefore(this.containerDiv,n||null)},E.prototype._setDraggable=function(t,e){e?(t.addEventListener("mousedown",this._onDown),t.addEventListener("touchstart",this._onDown),t.addEventListener("dragstart",this._onDragStart)):(t.removeEventListener("mousedown",this._onDown),t.removeEventListener("touchstart",this._onDown),t.removeEventListener("dragstart",this._onDragStart))},E.Css={arrow:"popup-arrow",close:"popup-close",container:"popup-container",content:"popup-content-container",hidden:"hidden-accessible-element"},E);function E(t){var o=Ld.call(this)||this;return o.attach=function(t){o.map!==t&&(o.map&&o.remove(),o.map=t,o.marker=o._createMarker(o.options),o.marker.addTo(o.map._getMap()),o.map.popups._getCollectionDiv().appendChild(o.containerDiv),o.map.popups.add(o))},o.open=function(t){if(!t&&!o.map)throw new Error("Must specify a map to open on or attach to a map in advance");o.attach(t||o.map),o.containerDiv.classList.remove(E.Css.hidden),o.map.events.add("move",o._onMove),o._onMove(),o._invokeEvent("open",{target:o,type:"open"})},o.close=function(){o.map&&o.map.events.remove("move",o._onMove),o.containerDiv.classList.add(E.Css.hidden),o._invokeEvent("close",{target:o,type:"close"})},o.remove=function(){o.map&&(o.marker.remove(),o.containerDiv.classList.remove(o.autoAnchor||o.options.anchor),o.map.events.remove("move",o._onMove),o.map.popups.remove(o),delete o.map,delete o.marker,delete o.autoAnchor)},o.isOpen=function(){return o.map&&!o.containerDiv.classList.contains(E.Css.hidden)},o._onMove=function(){var t=o._getAutoAnchor(o.map,o.options);t!==o.autoAnchor&&(o._replaceMarker(o.map,o.options,t),o.map.events.add("move",o._onMove))},o._onDown=function(t){o.map.popups._addDraggedPopup(o);var e=kd(o.map.positionsToPixels([o.options.position]),1)[0];"mousedown"===t.type?o.dragOffset=[e[0]-t.clientX,e[1]-t.clientY]:"touchstart"===t.type&&(o.dragOffset=[e[0]-t.touches[0].clientX,e[1]-t.touches[0].clientY])},o._onDragStart=function(t){t.preventDefault()},o.options=(new Sd).merge(L(t,Sd._cloneCustomizer)),o.containerDiv=o._createContainerDiv(o.options),o.contentDiv=o._createContentDiv(o.options),o.containerDiv.appendChild(o.contentDiv),o.options.showPointer&&(o.arrowDiv=o._createArrowDiv(),o.containerDiv.appendChild(o.arrowDiv)),o.options.closeButton&&(o.closeBtn=o._createCloseButton(),o.contentDiv.appendChild(o.closeBtn),t=_("close"),o.contentDiv.appendChild(t),b(t,o.closeBtn,!0)),o}(window&&window.__extends||(Md=function(t,e){return(Md=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Md(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Id,Ed=t),Id._cloneCustomizer=function(t){if(t instanceof Ad||Od(t))return t};var Md,Ed,jd=Id;function Id(){var t=null!==Ed&&Ed.apply(this,arguments)||this;return t.anchor="bottom",t.color="#1A73AA",t.draggable=!1,t.htmlContent='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24.5 36.5" id="marker_'.concat(J(),'" width="24.5" height="36.5" display="block"><path d="M12.25.25a12.2543,12.2543,0,0,0-12,12.4937c0,6.4436,6.4879,12.1093,11.059,22.5641.5493,1.2563,1.3327,1.2563,1.882,0C17.7621,24.8529,24.25,19.1857,24.25,12.7437A12.2543,12.2543,0,0,0,12.25.25Z" fill="{color}" stroke="{secondaryColor}" stroke-width="0.5"/><text style="font-family: Arial, Helvetica, sans-serif; font-size: 14px; fill: white;" text-anchor="middle" x="12" y="18">{text}</text></svg>'),t.pixelOffset=new Hc(0,0),t.position=new Zl(0,0),t.popup=void 0,t.secondaryColor="white",t.text=void 0,t.visible=!0,t}(window&&window.__extends||(Td=function(t,e){return(Td=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Td(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(j,zd=Ze),j.prototype.getOptions=function(){return L(this.options,jd._cloneCustomizer)},j.prototype.getElement=function(){return this.marker.getElement()},j.prototype.setOptions=function(t){t=(new jd).merge(this.options,L(t,jd._cloneCustomizer));Bc(t.htmlContent,this.options.htmlContent)&&t.anchor===this.options.anchor?("string"!=typeof t.htmlContent||t.color===this.options.color&&t.text===this.options.text&&t.secondaryColor===this.options.secondaryColor||(this.element.innerHTML=this._getSubbedHtmlString(t)||""),t.draggable!==this.options.draggable&&(this._setDraggable(t.draggable),this.marker.setDraggable(t.draggable)),Bc(t.pixelOffset,this.options.pixelOffset)||this.marker.setOffset(t.pixelOffset),Bc(t.position,this.options.position)||this.marker.setLngLat(t.position),t.visible!==this.options.visible&&(t.visible?this.element.classList.remove(j.hiddenClass):this.element.classList.add(j.hiddenClass))):(this.marker.remove(),this._buildMarker(t),this.map&&(this.marker.addTo(this.map._getMap()),this._getCollectionContainer().appendChild(this.element))),this.options=t},j.prototype.togglePopup=function(){if(this.options.popup)if(this.options.popup.isOpen())this.options.popup.close();else{if(!this.map)throw new Error("The marker must be added to a map before calling togglePopup().");this.options.popup.setOptions({position:this.options.position}),this.options.popup.open(this.map)}},j.prototype._addToMap=function(t,e){this.map&&this.map!==t&&this._removeFromMap(),e&&(this.options.position=c(e),this.marker.setLngLat(this.options.position)),this.map!==t&&(this.map=t,this.marker.addTo(t._getMap()),this._getCollectionContainer().appendChild(this.element))},j.prototype._removeFromMap=function(){this.map&&(this.marker.remove(),delete this.map)},j.prototype._getId=function(){if(this.element)return("string"==typeof this.options.htmlContent?this.element.firstChild:this.element).id},j.prototype._buildMarker=function(t){var e;"string"==typeof t.htmlContent?(e=this._getSubbedHtmlString(t)||"",this.element=gd.convertHtmlString(e)):this.element=t.htmlContent,this.element.classList.add(j.containerClass),t.draggable&&this._setDraggable(!0),t.visible||this.element.classList.add(j.hiddenClass),this.marker=new D.Marker({element:this.element,offset:t.pixelOffset,draggable:t.draggable,anchor:t.anchor}).setLngLat(t.position),this.marker.on("drag",this._onDrag),this.marker.on("dragstart",this._onDragStart),this.marker.on("dragend",this._onDragEnd),this.element.addEventListener("click",this._bubbleElementEvent),this.element.addEventListener("dblclick",this._bubbleElementEvent),this.element.addEventListener("contextmenu",this._bubbleElementEvent),this.element.addEventListener("keydown",this._bubbleElementEvent),this.element.addEventListener("keypress",this._bubbleElementEvent),this.element.addEventListener("keyup",this._bubbleElementEvent),this.element.addEventListener("mousedown",this._bubbleElementEvent),this.element.addEventListener("mouseenter",this._bubbleElementEvent),this.element.addEventListener("mouseleave",this._bubbleElementEvent),this.element.addEventListener("mousemove",this._bubbleElementEvent),this.element.addEventListener("mouseout",this._bubbleElementEvent),this.element.addEventListener("mouseover",this._bubbleElementEvent),this.element.addEventListener("mouseup",this._bubbleElementEvent)},j.prototype._getSubbedHtmlString=function(t){return"string"==typeof t.htmlContent?t.htmlContent.replace(/{color}/gi,t.color||"").replace(/{secondaryColor}/gi,t.secondaryColor||"").replace(/{text}/gi,t.text||""):null},j.prototype._getCollectionContainer=function(){var t=this.map.getCanvasContainer().querySelector(".".concat(j.collectionContainerClass));return t||((t=document.createElement("div")).classList.add(j.collectionContainerClass),this.map.getCanvasContainer().appendChild(t)),t},j.prototype._setDraggable=function(t){t?this.element.addEventListener("dragstart",this._onEleDragStart):this.element.removeEventListener("dragstart",this._onEleDragStart)},j.collectionContainerClass="marker-collection-container",j.hiddenClass="hidden-accessible-element",j.containerClass="marker-container";var Td,zd,Dd=j;function j(t){var e=zd.call(this)||this;return e._onDrag=function(){var t=e.marker.getLngLat().wrap();e.options.position=new Zl(t.lng,t.lat),e._invokeEvent("drag",{type:"drag",target:e})},e._onDragStart=function(){e._invokeEvent("dragstart",{type:"dragstart",target:e})},e._onDragEnd=function(){e._invokeEvent("dragend",{type:"dragend",target:e})},e._bubbleElementEvent=function(t){e._invokeEvent(t.type,{type:t.type,target:e})},e._onEleDragStart=function(t){t.preventDefault()},e.options=(new jd).merge(L(t,jd._cloneCustomizer)),e._buildMarker(e.options),e}Bd.getHighContrastMode=function(){return matchMedia("(-ms-high-contrast: white-on-black)").matches?"dark":matchMedia("(-ms-high-contrast: black-on-white)").matches?"light":matchMedia("(-ms-high-contrast: active)").matches?"dark":matchMedia("(inverted-colors: inverted)").matches?"invert":null};var Rd=Bd;function Bd(){}(window&&window.__extends||(Fd=function(t,e){return(Fd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(qd,Nd=t);var Fd,Nd,Zd=qd;function qd(){var t=null!==Nd&&Nd.apply(this,arguments)||this;return t.copyrightMessage=void 0,t.copyrightContent=void 0,t.customAttribution=void 0,t.showFeedbackLink=!0,t.showLogo=!0,t}(window&&window.__extends||(Hd=function(t,e){return(Hd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Hd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Gd,Ud=We),Gd.prototype.onAdd=function(t){return this.map=t,this.container=this.buildContainer(t,u.ControlStyle.auto),this.container.className="map-copyright without-bg",this.copyrightDiv=this.buildCopyrightDiv(),this.copyrightDiv.className="azure-map-copyright",this.container.appendChild(this.copyrightDiv),this.options.showFeedbackLink&&this.addRemoveFeedbackDiv(!0),this.container},Gd.prototype.onRemove=function(){Ud.prototype.onRemove.call(this),delete this.container},Gd.prototype.setOptions=function(t){var e,o=this,t=(new Zd).merge(this.options,t);t.copyrightMessage===this.options.copyrightMessage&&t.customAttribution===this.options.customAttribution||(this.copyrightDiv.innerText=this.textAttribution(t)),t.copyrightContent!==this.options.copyrightContent&&(this.options.copyrightContent&&(e=Array.from(this.copyrightDiv.children).find(function(t){return t===o.options.copyrightContent}),this.copyrightDiv.removeChild(e)),0<this.copyrightDiv.childNodes.length?this.copyrightDiv.insertBefore(t.copyrightContent,this.copyrightDiv.childNodes[0]):this.copyrightDiv.appendChild(t.copyrightContent),this.options.copyrightContent=t.copyrightContent),!t.showFeedbackLink&&this.feedbackAnchor?this.addRemoveFeedbackDiv(!1):t.showFeedbackLink&&!this.feedbackAnchor&&this.addRemoveFeedbackDiv(!0),this.options=t},Gd.prototype.getDefaultAttributions=function(){var t=(new Date).getFullYear(),e=["©".concat(t," TomTom")];return this.options.showLogo||e.push("©".concat(t," Microsoft")),e},Gd.prototype.buildCopyrightDiv=function(){var t=document.createElement("div");return t.innerText=this.textAttribution(this.options)||"",t},Gd.prototype.buildFeedbackLink=function(){var t=document.createElement("a");return t.setAttribute("alt","Provide Map Data Feedback"),t.setAttribute("aria-label","Provide Map Data Feedback"),t.innerText="Feedback",t.href=Gd.feedbackLink,t.target="_blank",t.rel="noopener",t.className="azure-map-feedback-text",t},Gd.prototype.addRemoveFeedbackDiv=function(t){t?(this.feedbackAnchor=this.buildFeedbackLink(),this.feedbackTooltip=_("Provide Map Data Feedback"),this.container.appendChild(this.feedbackAnchor),this.container.appendChild(this.feedbackTooltip),b(this.feedbackTooltip,this.feedbackAnchor),null!=(t=null==(t=this.map)?void 0:t.events)&&t.add("moveend",this.updateFeedbackLink)):(this.feedbackAnchor.remove(),this.feedbackTooltip.remove(),delete this.feedbackTooltip,delete this.feedbackAnchor,null!=(t=null==(t=this.map)?void 0:t.events)&&t.remove("moveend",this.updateFeedbackLink))},Gd.feedbackLink="https://aka.ms/azuremaps-feedback?feedbackep=UrlAzureMapsWebSdk";var Hd,Ud,Wd=Gd;function Gd(t){var o=Ud.call(this)||this;return o.textAttribution=function(t){return[o.options.copyrightMessage,o.options.customAttribution].filter(function(t){return t}).join("")},o.updateFeedbackLink=function(){var t,e;o.feedbackAnchor&&o.map&&(t=(e=o.map.getCamera()).center,e=e.zoom,o.feedbackAnchor.href="".concat(Gd.feedbackLink,"&cp=").concat(t[1],"~").concat(t[0],"&lvl=").concat(e+1))},o.options=(new Zd).merge(t),o}(window&&window.__extends||(Vd=function(t,e){return(Vd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Vd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Jd,Kd=t);var Vd,Kd,Yd=Jd;function Jd(){var t=null!==Kd&&Kd.apply(this,arguments)||this;return t.showLogo=!0,t}(window&&window.__extends||($d=function(t,e){return($d=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}$d(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(tf,Xd=We),tf.prototype.onAdd=function(t){return this.map=t,this.container=this.buildContainer(t,u.ControlStyle.auto),this.container.className="map-logo-control",null!=(t=this.map)&&t.events.add("resize",this._onResize),this._addRemoveLogo(this.options.showLogo),this.container},tf.prototype.onRemove=function(){var t;Xd.prototype.onRemove.call(this),null!=(t=this.map)&&t.events.remove("resize",this._onResize),this.map=null,delete this.container},tf.prototype.setOptions=function(t){t=(new Yd).merge(this.options,t);!t.showLogo&&this.logoAnchor?this._addRemoveLogo(!1):t.showLogo&&!this.logoAnchor&&this._addRemoveLogo(!0),this.options=t},tf.prototype._addRemoveLogo=function(t){t?(this.logoAnchor=document.createElement("a"),this.logoAnchor.className="azure-map-logo",this.logoAnchor.href="https://aka.ms/azuremaps",this.logoAnchor.setAttribute("aria-label","Visit azure.microsoft.com"),this.logoAnchor.setAttribute("target","_blank"),this.container.appendChild(this.logoAnchor),this.logoTooltip=_("Visit azure.microsoft.com"),this.container.appendChild(this.logoTooltip),b(this.logoTooltip,this.logoAnchor),this._setVisiblity(!0)):(null!=(t=this.logoAnchor)&&t.remove(),null!=(t=this.logoTooltip)&&t.remove(),delete this.logoAnchor,this._setVisiblity(!1))},tf.prototype._setVisiblity=function(t){this.container&&(this.container.style.display=t?"flex":"none")},tf.CONTAINER_MIN_WIDTH=480;var $d,Xd,Qd=tf;function tf(t){var e=Xd.call(this)||this;return e.map=null,e._onResize=function(){var t=(null==(t=null==(t=e.map)?void 0:t.getMapContainer())?void 0:t.clientWidth)||0;e._setVisiblity(e.options.showLogo&&tf.CONTAINER_MIN_WIDTH<=t)},e.options=(new Yd).merge(t),e}window&&window.__assign;window&&window.__awaiter,window&&window.__generator,window&&window.__read,window&&window.__spreadArray;var ef,of,nf=function(t){var o=this;this.addToMap=function(){null==o.mapViewDesc&&(o.initializeMapLiveStateInfo(),o.initializeMapStyleInfo(),o.createMapKeyBindingInfo(),o.map.getMapContainer().setAttribute("role","application"),o.map.getMapContainer().setAttribute("aria-label","Map Application"),o.map.getCanvasContainer().setAttribute("aria-live","polite"),o.map.getCanvasContainer().setAttribute("aria-describedby","atlas-map-state atlas-map-style"),o.map.getCanvas().setAttribute("aria-label","Interactive Map"),o.map.getCanvas().setAttribute("aria-describedby","atlas-map-shortcuts"),o.map.getCanvas().setAttribute("alt","Interactive Map"))},this.removeFromMap=function(){null!=o.mapViewDesc&&o.mapViewDesc.dispose(),delete o.mapViewDesc,null!=o.atlasMapKeyBindings&&o.map.getCanvasContainer().removeChild(o.atlasMapKeyBindings),delete o.atlasMapKeyBindings,null!=o.atlasMapLiveStateInfo&&o.map.getCanvasContainer().removeChild(o.atlasMapLiveStateInfo),delete o.atlasMapLiveStateInfo,null!=o.atlasMapStyleInfo&&o.map.getCanvasContainer().removeChild(o.atlasMapStyleInfo),delete o.atlasMapStyleInfo,o.map.getMapContainer().removeAttribute("role"),o.map.getMapContainer().removeAttribute("aria-label"),o.map.getCanvasContainer().removeAttribute("aria-live"),o.map.getCanvasContainer().removeAttribute("aria-describedby"),o.map.getCanvas().removeAttribute("aria-label"),o.map.getCanvas().removeAttribute("aria-describedby"),o.map.getCanvas().removeAttribute("alt"),o.map.events.remove("stylechanged",o.updateMapStyle)},this.createMapKeyBindingInfo=function(){o.atlasMapKeyBindings=document.createElement("div"),o.atlasMapKeyBindings.setAttribute("tabindex","-1"),o.atlasMapKeyBindings.setAttribute("aria-hidden","true"),o.atlasMapKeyBindings.id="atlas-map-shortcuts",o.atlasMapKeyBindings.classList.add("hidden-accessible-element"),o.atlasMapKeyBindings.innerHTML=["Map shortcuts:","Zoom out: hyphen.","Zoom in: plus.","Pan right 100 pixels: right arrow.","Pan left 100 pixels: left arrow.","Pan up 100 pixels: up arrow.","Pan down 100 pixels: down arrow.","Rotate 15 degrees clockwise: shift + right arrow.","Rotate 15 degrees counter clockwise: shift + left arrow.","Increase pitch 10 degrees: shift + up arrow.","Decrease pitch 10 degrees: shift + down arrow.","Jump focus to the map: Escape."].join("\n"),o.map.getCanvasContainer().appendChild(o.atlasMapKeyBindings);var t=[189,187,38,37,39,40],e=o.map._getMap()._canvas;null!=e&&e.addEventListener("keyup",function(e){t.find(function(t){return e.keyCode===t})&&(o.atlasMapKeyBindings.innerHTML="")})},this.initializeMapLiveStateInfo=function(){},this.initializeMapStyleInfo=function(){o.atlasMapStyleInfo=document.createElement("div"),o.atlasMapStyleInfo.setAttribute("tabindex","-1"),o.atlasMapStyleInfo.setAttribute("aria-hidden","true"),o.atlasMapStyleInfo.id="atlas-map-style",o.atlasMapStyleInfo.classList.add("hidden-accessible-element"),o.map.events.add("stylechanged",o.updateMapStyle),o.map.getCanvasContainer().appendChild(o.atlasMapStyleInfo)},this.updateMapStyle=function(){o.atlasMapStyleInfo.innerHTML="<p>Map style: ".concat(o.map.getStyle().style,".</p>")},this.updateMapState=function(t){o.atlasMapLiveStateInfo.innerHTML=t},this.map=t},rf=function(t){var o=this;this.listenerEnabled=!1,this.lastFlowMode="none",this.addToMap=function(){if(!o.map._isReady())throw new Error("Traffic flow could not be added to the map because the map is not ready. Please use a ready event listener to guarantee the map is ready before enabling traffic flow.");o.listenerEnabled||(o.map.events.add("styledata",o.addToMap),o.listenerEnabled=!0);var t,e=o.map.getTraffic();"none"!==e.flow&&(t=o.map.layers.getLayerById("traffic_".concat(e.flow)))&&(o.lastFlowMode=e.flow,t._updateLayoutProperty("visibility","visible","none"))},this.removeFromMap=function(){var t;o.map.getTraffic(),"none"!=o.lastFlowMode&&((t=o.map.layers.getLayerById("traffic_".concat(o.lastFlowMode)))&&t._updateLayoutProperty("visibility","none","visible"),o.lastFlowMode="none"),o.listenerEnabled&&(o.map.events.remove("styledata",o.addToMap),o.listenerEnabled=!1)},this.map=t},sf=((window&&window.__extends||(ef=function(t,e){return(ef=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ef(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(af,of=t),af);function af(){var t=null!==of&&of.apply(this,arguments)||this;return t.interactive=!0,t.scrollZoomInteraction=!0,t.boxZoomInteraction=!0,t.dragRotateInteraction=!0,t.dragPanInteraction=!0,t.keyboardInteraction=!0,t.dblClickZoomInteraction=!0,t.touchInteraction=!0,t.touchRotate=!0,t.wheelZoomRate=1/450,t}lf.prototype.enable=function(){this.map.getMapContainer().addEventListener("keydown",this._onKeyDown)},lf.prototype.disable=function(){this.map.getMapContainer().removeEventListener("keydown",this._onKeyDown)};var cf=lf;function lf(t){var e=this;this._onKeyDown=function(t){27===t.keyCode&&e.map.getCanvas().focus()},this.map=t}pf.prototype.enable=function(){this.map.getCanvasContainer().addEventListener("gesturestart",this._onGestureStart),this.map.getCanvasContainer().addEventListener("gesturechange",this._onGestureChange),this.map.getCanvasContainer().addEventListener("touchstart",this._onTouchStart),this.map.getCanvasContainer().addEventListener("touchend",this._onTouchEnd)},pf.prototype.disable=function(){this.map.getCanvasContainer().removeEventListener("gesturestart",this._onGestureStart),this.map.getCanvasContainer().removeEventListener("gesturechange",this._onGestureChange),this.map.getCanvasContainer().removeEventListener("touchstart",this._onTouchStart),this.map.getCanvasContainer().removeEventListener("touchend",this._onTouchEnd)};var uf=pf;function pf(t){var e=this;this._onGestureStart=function(t){e.hasTouch||(t.preventDefault(),e.initZoom=e.map.getCamera().zoom)},this._onGestureChange=function(t){e.hasTouch||(t.preventDefault(),e.map.setCamera({zoom:e.initZoom+t.scale-1}))},this._onTouchStart=function(t){e.hasTouch=!0},this._onTouchEnd=function(t){0===t.touches.length&&(e.hasTouch=!1)},this.map=t}df.prototype.addToMap=function(){this.added||(this.added=!0,this._setInteractions(this.options))},df.prototype.removeFromMap=function(){this.added&&(this.added=!1,this._setInteractions({interactive:!1}))},df.prototype.setOptions=function(t){this.options=(new sf).merge(this.options,t),this.added&&this._setInteractions(this.options)},df.prototype.getOptions=function(){return Object.assign({},this.options)},df.prototype._setInteractions=function(t){var e;t.interactive?(t.boxZoomInteraction?this.map._getMap().boxZoom.enable():this.map._getMap().boxZoom.disable(),t.dblClickZoomInteraction?this.map._getMap().doubleClickZoom.enable():this.map._getMap().doubleClickZoom.disable(),t.dragPanInteraction?this.map._getMap().dragPan.enable():this.map._getMap().dragPan.disable(),t.dragRotateInteraction?this.map._getMap().dragRotate.enable():this.map._getMap().dragRotate.disable(),t.keyboardInteraction?(this.map._getMap().keyboard.enable(),this.focusShortcut.enable()):(this.map._getMap().keyboard.disable(),this.focusShortcut.disable()),t.scrollZoomInteraction?(this.map._getMap().scrollZoom.enable(),this.map._getMap().scrollZoom.setWheelZoomRate(t.wheelZoomRate)):this.map._getMap().scrollZoom.disable(),e=this.map._getMap().touchZoomRotate,t.touchInteraction?(e.enable(),t.touchRotate?e.enableRotation():e.disableRotation()):e.disable(),this.pinchZoom.enable()):(this.map._getMap().boxZoom.disable(),this.map._getMap().doubleClickZoom.disable(),this.map._getMap().dragPan.disable(),this.map._getMap().dragRotate.disable(),this.map._getMap().keyboard.disable(),this.focusShortcut.disable(),this.map._getMap().scrollZoom.disable(),this.map._getMap().touchZoomRotate.disable(),this.pinchZoom.disable())};var hf=df;function df(t,e){this.added=!1,this.map=t,this.focusShortcut=new cf(t),this.pinchZoom=new uf(t),this.options=(new sf).merge(e)}var ff=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},yf=(mf.prototype.add=function(t,e){var o,n;if(Array.isArray(t))try{for(var r=ff(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._add(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._add(t,e)},mf.prototype.getControls=function(){return Array.from(this.controls)},mf.prototype.remove=function(t){var e,o;if(Array.isArray(t))try{for(var n=ff(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._remove(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}else this._remove(t)},mf.prototype._add=function(t,e){this.controls.add(t);var o=(new De).merge(e),t=t.onAdd(this.map,e),e=this.controlContainer.getElementsByClassName(o.position);if(!(0<e.length))throw new Error("Control position ".concat(o.position," does not exist."));e.item(0).appendChild(t)},mf.prototype._remove=function(t){t.onRemove(),this.controls.delete(t)},mf);function mf(t){for(var e in this.map=t,this.controlContainer=document.createElement("div"),this.controlContainer.classList.add("atlas-control-container"),u.ControlPosition){var o;u.ControlPosition.hasOwnProperty(e)&&((o=document.createElement("div")).classList.add(u.ControlPosition[e]),o.classList.add("subcontrol-container"),this.controlContainer.appendChild(o))}this.map.getMapContainer().appendChild(this.controlContainer),this.controls=new Set}var gf=window&&window.__assign||function(){return(gf=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},vf=(wf.prototype.addCallback=function(s,a,c,t,l){var e,u,p=this;if(t)e=function(t){var e=t.lngLat?new Zl(t.lngLat.lng,t.lngLat.lat):void 0,o=t.point?[t.point.x,t.point.y]:void 0,n=t.features?t.features.map(function(t){return new Fc(t.geometry,t.properties,t.id)}):[],t={type:t.type,originalEvent:t.originalEvent,position:e,coordinate:o,features:n};c(t)};else switch(s){case"data":case"sourcedata":case"styledata":e=function(t){t=gf(gf({dataType:t.dataType},"source"===t.dataType&&gf(gf(gf({isSourceLoaded:t.isSourceLoaded},t.sourceDataType&&{sourceDataType:t.sourceDataType}),{source:p.map.sources.getById(t.sourceId)}),t.tile&&{tile:{id:{x:t.tile.tileID.canonical.x,y:t.tile.tileID.canonical.y,z:t.tile.tileID.canonical.z},size:t.tile.tileSize,state:t.tile.state}})),{map:p.map,type:t.type});l&&p.map.events._removeListener(s,a,c),c(t)};break;case"error":e=function(t){t={error:t.error,map:p.map,type:t.type};l&&p.map.events._removeListener(s,a,c),c(t)};break;case"touchstart":case"touchend":case"touchmove":case"touchcancel":e=function(t){if(t.originalEvent){if(t.originalEvent===u)return;u=t.originalEvent}var e=t.point?new Hc(t.point.x,t.point.y):void 0,o=t.points?t.points.map(function(t){return new Hc(t.x,t.y)}):[],n=t.lngLat?new Zl(t.lngLat.lng,t.lngLat.lat):void 0,r=t.lngLats?t.lngLats.map(function(t){return new Zl(t.lng,t.lat)}):[],i=n?p.map.layers.getRenderedShapes(new Uc(n),a?[a]:void 0):[],e={map:p.map,originalEvent:t.originalEvent,pixel:e,pixels:o,position:n,positions:r,shapes:i,layerId:a||void 0,preventDefault:function(){return t.preventDefault()},type:t.type};l&&p.map.events._removeListener(s,a,c),c(e)};break;case"mousedown":case"mouseup":case"mouseover":case"mousemove":case"click":case"dblclick":case"mouseout":case"mouseenter":case"mouseleave":case"contextmenu":e=function(t){if(t.originalEvent){if(t.originalEvent===u)return;u=t.originalEvent}var e=t.lngLat?new Zl(t.lngLat.lng,t.lngLat.lat):void 0,o=t.point?new Hc(t.point.x,t.point.y):void 0,n=e?p.map.layers.getRenderedShapes(new Uc(e),a?[a]:void 0):[],e={map:p.map,originalEvent:t.originalEvent,position:e,pixel:o,preventDefault:function(){return t.preventDefault()},shapes:n,layerId:a||void 0,type:t.type};l&&p.map.events._removeListener(s,a,c),c(e)};break;case"styleimagemissing":e=function(t){l&&p.map.events._removeListener(s,a,c),c(t.id)};break;case"wheel":e=function(t){if(t.originalEvent){if(t.originalEvent===u)return;u=t.originalEvent}var e={map:p.map,originalEvent:t.originalEvent,preventDefault:function(){return t.preventDefault()},type:t.type};l&&p.map.events._removeListener(s,a,c),c(e)};break;case"resize":e=function(t){var e,o={map:p.map,type:t.type};for(e in t)"type"!==e&&"target"!==e&&(o[e]=t[e]);l&&p.map.events._removeListener(s,a,c),c(o)};break;default:e=function(t){var e={map:p.map,type:t.type};t.originalEvent&&(e.originalEvent=t.originalEvent),l&&p.map.events._removeListener(s,a,c),c(e)}}this.callbacks.has(a)||this.callbacks.set(a,new Ne),this.callbacks.get(a).has(s)||this.callbacks.get(a).set(s,new Map),this.callbacks.get(a).get(s).set(c,[e,l])},wf.prototype.removeCallback=function(t,e,o){this.callbacks.has(e)&&this.callbacks.get(e).has(t)&&this.callbacks.get(e).get(t).has(o)&&this.callbacks.get(e).get(t).delete(o)},wf.prototype.getModifiedCallback=function(t,e,o){if(this.callbacks.has(e)&&this.callbacks.get(e).has(t)&&this.callbacks.get(e).get(t).has(o))return this.callbacks.get(e).get(t).get(o)[0]},wf.prototype.getLayerCallbacks=function(t){if(this.callbacks.has(t))return this.callbacks.get(t)},wf.prototype.getEventCallbacks=function(t,e){if(this.callbacks.has(e)){e=this.callbacks.get(e);if(e.has(t))return e.get(t)}},wf);function wf(t){this.callbacks=new Ne,this.map=t}var _f=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},bf=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},xf=["maxzoomchanged","minzoomchanged","mapconfigurationchanged"],Of=(Sf.prototype.add=function(t,e,o){var n,r;if("function"==typeof e)this._addGlobalListener(t,e,!1,!1);else{e=Array.isArray(e)?e:[e];try{for(var i=_f(e),s=i.next();!s.done;s=i.next()){var a=s.value;a instanceof M&&M._isMBoxEvent(t)?this._addLayerListener(t,a,o,!1,!1):a._addEventListener(t,o,!1)}}catch(t){n={error:t}}finally{try{s&&!s.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}},Sf.prototype.addOnce=function(t,e,o){"function"==typeof e?this._addGlobalListener(t,e,!1,!0):e instanceof M&&M._isMBoxEvent(t)?this._addLayerListener(t,e,o,!1,!0):e._addEventListener(t,o,!0)},Sf.prototype._addLegacy=function(t,e,o){"function"==typeof e?this._addGlobalListener(t,e,!0,!1):this._addLayerListener(t,e,o,!0,!1)},Sf.prototype._addLayerListener=function(t,e,o,n,r){var i,s,a,c,e=e instanceof M?e.getId():e,l=this.map.layers.getLayerById(e),u=this.mapCallbackHandler.getModifiedCallback(t,e,o);if(u&&l)try{for(var p=_f(l._getLayerIds()),h=p.next();!h.done;h=p.next()){var d=h.value;this.map._getMap().off(t,d,u)}}catch(t){i={error:t}}finally{try{h&&!h.done&&(s=p.return)&&s.call(p)}finally{if(i)throw i.error}}if(this.mapCallbackHandler.addCallback(t,e,o,n,r),l){u=this.mapCallbackHandler.getModifiedCallback(t,e,o);try{for(var f=_f(l._getLayerIds()),y=f.next();!y.done;y=f.next()){d=y.value;this.map._getMap().on(t,d,u)}}catch(t){a={error:t}}finally{try{y&&!y.done&&(c=f.return)&&c.call(f)}finally{if(a)throw a.error}}}},Sf.prototype._addGlobalListener=function(t,e,o,n){var r,i,s,a;xf.includes(t)?this.map._addEventListener(t,e,n):(r=this.mapCallbackHandler.getModifiedCallback(t,"",e),this.mapCallbackHandler.addCallback(t,"",e,o,n),i=this.mapCallbackHandler.getModifiedCallback(t,"",e),"load"===t&&this.map._isLoaded()?(s={type:"load",map:this.map},setTimeout(function(){return i(s)})):"ready"===t?this.map._isReady()&&(a={type:"ready",map:this.map},setTimeout(function(){return i(a)})):(r&&this.map._getMap().off(t,r),this.map._getMap().on(t,i)))},Sf.prototype.invoke=function(t,e,o){if(void 0===o)this._invokeListeners(t,"",e);else if(e instanceof M&&M._isMBoxEvent(t))this._invokeListeners(t,e.getId(),o);else{if(!(e instanceof Ze))throw new Error("The invoke target is invalid.");e._invokeEvent(t,o)}},Sf.prototype._invokeListeners=function(o,n,r){var i=this,t=new Ne(this.mapCallbackHandler.getEventCallbacks(o,n));t?t.forEach(function(t,e){t=bf(t,2);t[0],t[1]&&i._removeListener(o,n,e),e(r)}):"error"===o&&console.error("error"in r?r.error:r)},Sf.prototype.remove=function(t,e,o){var n,r;if("function"==typeof e)this._removeListener(t,"",e);else{e=Array.isArray(e)?e:[e];try{for(var i=_f(e),s=i.next();!s.done;s=i.next()){var a=s.value;a instanceof M&&M._isMBoxEvent(t)?this._removeListener(t,a,o):null!=a&&a._removeEventListener(t,o)}}catch(t){n={error:t}}finally{try{s&&!s.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}},Sf.prototype._removeLegacy=function(t,e,o){"function"==typeof e?this._removeListener(t,"",e):this._removeListener(t,e,o)},Sf.prototype._removeListener=function(t,e,o){var n,r;if(xf.includes(t))this.map._removeEventListener(t,o);else{var e=e instanceof M?e.getId():e,i=this.mapCallbackHandler.getModifiedCallback(t,e,o);if(i)if(e){var s=this.map.layers.getLayerById(e);if(s)try{for(var a=_f(s._getLayerIds()),c=a.next();!c.done;c=a.next()){var l=c.value;this.map._getMap().off(t,l,i)}}catch(t){n={error:t}}finally{try{c&&!c.done&&(r=a.return)&&r.call(a)}finally{if(n)throw n.error}}}else this.map._getMap().off(t,i);this.mapCallbackHandler.removeCallback(t,e,o)}},Sf.prototype._enableLayerEvents=function(c){var l=this,t=this.mapCallbackHandler.getLayerCallbacks(c.getId());t&&t.forEach(function(t,a){t.forEach(function(t){var e,o,n=bf(t,1)[0];try{for(var r=_f(c._getLayerIds()),i=r.next();!i.done;i=r.next()){var s=i.value;l.map._getMap().on(a,s,n)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}})})},Sf.prototype._disableLayerEvents=function(c){var l=this,t=this.mapCallbackHandler.getLayerCallbacks(c.getId());t&&t.forEach(function(t,a){t.forEach(function(t){var e,o,n=bf(t,1)[0];try{for(var r=_f(c._getLayerIds()),i=r.next();!i.done;i=r.next()){var s=i.value;l.map._getMap().off(a,s,n)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}})})},Sf);function Sf(t){this.map=t,this.mapCallbackHandler=new vf(this.map)}var Cf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Pf=(Lf.prototype.add=function(t,e){var o,n;if(Array.isArray(t))try{for(var r=Cf(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._addMarker(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._addMarker(t,e)},Lf.prototype._addMarker=function(t,e){t._addToMap(this.map,e),this.markers.add(t)},Lf.prototype.getMarkers=function(){return Array.from(this.markers)},Lf.prototype.remove=function(t){var e,o;if(Array.isArray(t))try{for(var n=Cf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._removeMarker(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}else this._removeMarker(t)},Lf.prototype._removeMarker=function(e){var o=this;e instanceof Dd?(e._removeFromMap(),this.markers.delete(e)):this.markers.forEach(function(t){t._getId()===e&&(t._removeFromMap(),o.markers.delete(t))})},Lf.prototype.clear=function(){var e=this;this.markers.forEach(function(t){t._removeFromMap(),e.markers.delete(t)})},Lf);function Lf(t){this.markers=new Set,this.map=t}Af.prototype.add=function(s,e,a){var c=this;return new Promise(function(o,n){var r,t,i;c.userImages.has(s)?o():e instanceof HTMLImageElement||e instanceof ImageData?(c.map._getMap().addImage(s,e,a),c.userImages.set(s,{image:e,meta:a}),o()):"string"==typeof e&&(t=void 0,t=/<svg/i.test(e)&&!/^data:/i.test(e)?"data:image/svg+xml;base64,"+window.btoa(e):e,i=!1,c.map._sendRequest(t,"Image").then(function(t){return i?void 0:t.blob()}).then(function(t){var e;!i&&t&&(clearTimeout(r),(e=new Image).onload=function(){c.map._getMap().addImage(s,e,a),c.userImages.set(s,{image:e,meta:a}),o()},e.onerror=e.onabort=function(){n("Failed to load image into HTML element.")},e.src=URL.createObjectURL(t))}).catch(function(){i||(clearTimeout(r),n("Failed to load image into HTML element."))}),r=setTimeout(function(){i=!0,n("Failed to load image within specified timeout: ".concat(c.imageLoadTimeout," ms."))},c.imageLoadTimeout))})},Af.prototype.clear=function(){var o=this;this.userImages.forEach(function(t,e){o.map._getMap().removeImage(e)}),this.userImages.clear()},Af.prototype.getImageIds=function(){var o=[];return this.userImages.forEach(function(t,e){o.push(e)}),o},Af.prototype.createFromTemplate=function(t,e,o,n,r){o=o||"#1A73AA",n=n||"#fff";e=(e=Oe(e,r)).replace(/{color}/g,o).replace(/{secondaryColor}/g,n).replace(/{text}/g,"");return this.add(t,e)},Af.prototype.hasImage=function(t){return this.userImages.has(t)},Af.prototype.remove=function(t){this.map._getMap().removeImage(t),this.userImages.delete(t)},Af.prototype._restoreImages=function(){var o=this;this.userImages.forEach(function(t,e){o.map._getMap().hasImage(e)||o.map._getMap().addImage(e,t.image,t.meta)})};var kf=Af;function Af(t){this.userImages=new Ne,this.imageLoadTimeout=5e3,this.map=t}var Mf,Ef,Jo=window&&window.__extends||(Mf=function(t,e){return(Mf=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Mf(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),jf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},If=(Jo(Tf,Ef=M),Tf.prototype.getOptions=function(){return{}},Tf.prototype.setOptions=function(t){},Tf.prototype._buildLayers=function(){return this.layers},Tf.prototype._getLayerIds=function(){return this.layers.map(function(t){return t.id})},Tf.prototype._getSourceIds=function(){var e,t,o=new Set;try{for(var n=jf(this.layers),r=n.next();!r.done;r=n.next()){var i=r.value;"source"in i&&"string"==typeof i.source?o.add(i.source):"source"in i&&i.source&&o.add(i.id)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return o},Tf.prototype._updateLayoutProperty=function(e,o,t,n){var r;Bc(o,t)||(r=this.map._getMap(),this.layers.forEach(function(t){r.getLayer(t.id)?r.setLayoutProperty(t.id,e,n||o):console.warn("Could not update layout property ".concat(e," for layer ").concat(t.id," to ").concat(n||o))}))},Tf);function Tf(t,e){e=Ef.call(this,e)||this;return e.layers=t,e}var zf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Df=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Rf=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Bf=(Ff.prototype.add=function(t,e){var o,n,r=e instanceof M?e.getId():e;if(Array.isArray(t))try{for(var i=zf(t),s=i.next();!s.done;s=i.next()){var a=s.value;this._addLayer(a,r)}}catch(t){o={error:t}}finally{try{s&&!s.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}else this._addLayer(t,r)},Ff.prototype._addLayer=function(e,o){if(!(this.map._isReady()||e instanceof If))throw new Error("The layer '".concat(e.getId(),"' could not be added to the map because ")+"the map is not ready. Please use a ready event listener to guarantee the map is ready before adding a layer to it.");var t,n,r,i;o!==e.getId()&&this.layerIndex.find(function(t){return o===t.getId()})?this._getMapboxLayerExists(e)?(n=this.layerIndex.findIndex(function(t){return t.getId()===e.getId()}),r=this.userLayers.findIndex(function(t){return t.layer.getId()===e.getId()}),this._removeMapboxLayers(e),this._addMapboxLayers(e,o),(i=this.layerIndex[n])&&this.map.events._disableLayerEvents(i),this.map.events._enableLayerEvents(e),this.layerIndex.splice(n,1),t=this.layerIndex.findIndex(function(t){return t.getId()===o}),this.layerIndex.splice(t,0,e),e instanceof If||(this.userLayers[r]={layer:e,before:o}),i&&i.onRemove()):(this._addMapboxLayers(e,o),this.map.events._enableLayerEvents(e),t=this.layerIndex.findIndex(function(t){return t.getId()===o}),this.layerIndex.splice(t,0,e),e instanceof If||this.userLayers.push({layer:e,before:o})):(n=this.layerIndex.findIndex(function(t){return t.getId()===e.getId()}),r=this.userLayers.findIndex(function(t){return t.layer.getId()===e.getId()}),0<=n&&0<=r?(i=this.layerIndex[n],this._removeMapboxLayers(i),this._addMapboxLayers(e,n+1),this.map.events._disableLayerEvents(i),this.map.events._enableLayerEvents(e),(this.layerIndex[n]=e)instanceof If||(this.userLayers[r]={layer:e,before:void 0}),i.onRemove()):(this._addMapboxLayers(e),this.map.events._enableLayerEvents(e),this.layerIndex.push(e),e instanceof If||this.userLayers.push({layer:e,before:o}))),e.onAdd(this.map)},Ff.prototype._addMapboxLayers=function(t,e){var o,n;if(!(t instanceof ad)||t.getOptions().tileUrl){if(!(t instanceof If)){t instanceof eh&&(this.map._getMap().addSource(t._getSourceId(),t._buildSource()),this.map.sources.setSourceState(t._getSourceWrapper()));var r=this._getMapboxBefore(e);try{for(var i=zf(t._buildLayers()),s=i.next();!s.done;s=i.next()){var a=s.value;this.map._getMap().addLayer(a,r)}}catch(t){o={error:t}}finally{try{s&&!s.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}}this.map.events._enableLayerEvents(t)}},Ff.prototype._removeMapboxLayers=function(t,e){var o,n;if(t instanceof If&&!e)this.map.events._disableLayerEvents(t);else{try{for(var r=zf(t._getLayerIds()),i=r.next();!i.done;i=r.next()){var s=i.value;this.map._getMap().getLayer(s)&&this.map._getMap().removeLayer(s)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}this.map.events._disableLayerEvents(t),t instanceof eh&&this.map._getMap().getSource(t._getSourceId())&&this.map._getMap().removeSource(t._getSourceId())}},Ff.prototype._getMapboxLayerExists=function(e){var o=this,n=!1;return"string"==typeof e?!!(e=this.layerIndex.find(function(t){return t.getId()===e})):(e._getLayerIds().forEach(function(t){o.map._getMap().getLayer(t)&&(n=!0)}),n)},Ff.prototype._getMapboxBefore=function(e){var o,t,n,r;if("string"==typeof e){var i=this.layerIndex.find(function(t){return t.getId()===e});if(!i)return;try{for(var s=zf(i._getLayerIds()),a=s.next();!a.done;a=s.next()){var c=a.value;if(this.map._getMap().getLayer(c))return c}}catch(t){o={error:t}}finally{try{a&&!a.done&&(t=s.return)&&t.call(s)}finally{if(o)throw o.error}}e=this.layerIndex.findIndex(function(t){return t.getId()===e})+1}for(var l=e;l<this.layerIndex.length;l++)try{n=void 0;for(var u=zf(this.layerIndex[l]._getLayerIds()),p=u.next();!p.done;p=u.next()){c=p.value;if(this.map._getMap().getLayer(c))return c}}catch(t){n={error:t}}finally{try{p&&!p.done&&(r=u.return)&&r.call(u)}finally{if(n)throw n.error}}},Ff.prototype.clear=function(){for(var t=this.layerIndex.length-1;0<=t;t--){var e=this.layerIndex[t];e&&(this._removeMapboxLayers(e,!0),this.layerIndex.splice(t,1),e.onRemove())}this.userLayers=[]},Ff.prototype.getLayerById=function(e){var t=this.layerIndex.find(function(t){return t.getId()===e});if(t)return t},Ff.prototype.getLayers=function(){return this.layerIndex.slice(0)},Ff.prototype._getSourceIds=function(){var e,t,o=new Set;try{for(var n=zf(this.layerIndex),r=n.next();!r.done;r=n.next())r.value._getSourceIds().forEach(function(t){return o.add(t)})}catch(t){e={error:t}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return o},Ff.prototype._getUserLayers=function(){return Array.from(this.userLayers)},Ff.prototype.move=function(t,e){var o=t instanceof M?t.getId():t,n=e instanceof M?e.getId():e;if(!this.layerIndex.find(function(t){return t.getId()===o}))throw new Error("The layer '".concat(o,"' has not been added to the map and cannot be moved."));e=this.layerIndex.findIndex(function(t){return t.getId()===o}),this._moveMapboxLayers(this.layerIndex[e],n),t=this.layerIndex[e],this.layerIndex.splice(e,1),e=this.layerIndex.findIndex(function(t){return t.getId()===n}),-1<e?this.layerIndex.splice(e,0,t):this.layerIndex.push(t),e=this.userLayers.find(function(t){return t.layer.getId()===o});e&&(e.before=n)},Ff.prototype._moveMapboxLayers=function(t,e){var o,n,r=this._getMapboxBefore(e);try{for(var i=zf(t._getLayerIds()),s=i.next();!s.done;s=i.next()){var a=s.value;this.map._getMap().moveLayer(a,r)}}catch(t){o={error:t}}finally{try{s&&!s.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}},Ff.prototype.getRenderedShapes=function(t,e,o){var n,r,i,s=this;if(t=t||[-180,-85.0511,180,85.0511],Array.isArray(t)?4===t.length||6===t.length?i=this.map.positionsToPixels([S.getSouthWest(t),S.getNorthEast(t)]):2!==t.length&&3!==t.length||(i=this.map.positionsToPixels([t])[0]):i=this.map.positionsToPixels([t.coordinates])[0],e){e=Array.isArray(e)?e:[e];var a=[],c=this;try{for(var l=zf(e),u=l.next();!u.done;u=l.next())!function(t){var e=t instanceof M?t.getId():t,t=c.layerIndex.findIndex(function(t){return t.getId()===e});if(!(-1<t))throw new Error("The layer '".concat(e,"' has not been added to the map ")+"and its rendered features cannot be retrieved.");a.push.apply(a,Rf([],Df(c.layerIndex[t]._getLayerIds().filter(function(t){return!!s.map._getMap().getLayer(t)})),!1))}(u.value)}catch(t){n={error:t}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}t=this.map._getMap().queryRenderedFeatures(i,{layers:a,filter:o});return this.map.sources._mapFeaturesToShapes(t)},Ff.prototype.remove=function(t){var e,o;if(Array.isArray(t))try{for(var n=zf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._removeLayer(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}else this._removeLayer(t)},Ff.prototype._removeLayer=function(t){var e=t instanceof M?t.getId():t,o=this.layerIndex.findIndex(function(t){return t.getId()===e});if(-1==o)throw new Error("The layer '".concat(e,"' has not been added to the map and cannot be removed."));var n=this.layerIndex[o],o=(this._removeMapboxLayers(n),this.layerIndex.splice(o,1),this.userLayers.findIndex(function(t){return t.layer.getId()===e}));-1!=o&&this.userLayers.splice(o,1),t instanceof eh&&this.map.sources.unsetSourceState(t._getSourceId()),n.onRemove()},Ff);function Ff(t){this.layerIndex=[],this.userLayers=[],this.map=t}var Nf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Zf=(qf.prototype.add=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=Nf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.popups.has(i)||(this.popups.add(i),i.attach(this.map))}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},qf.prototype.clear=function(){var e=this;this.popups.forEach(function(t){e.popups.delete(t),t.remove()})},qf.prototype.remove=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=Nf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.popups.has(i)&&(this.popups.delete(i),i.remove())}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},qf.prototype.getPopups=function(){return Array.from(this.popups)},qf.prototype._getCollectionDiv=function(){var t=this.map.getMapContainer().querySelector(".".concat(qf.Css.collection));return t||((t=document.createElement("div")).classList.add(qf.Css.collection),t.setAttribute("aria-label","Map Information"),this.map.getMapContainer().appendChild(t)),t},qf.prototype._addDraggedPopup=function(t){0===this.draggedPopups.size&&(this.map.getMapContainer().addEventListener("mousemove",this._onDrag),this.map.getMapContainer().addEventListener("touchmove",this._onDrag),this.map.getMapContainer().addEventListener("mouseup",this._onUp),this.map.getMapContainer().addEventListener("touchend",this._onUp)),this.draggedPopups.add(t)},qf.Css={collection:"popup-collection-container"},qf);function qf(t){var n=this;this._onDrag=function(t){var e,o;"mousemove"===t.type?(e=t.clientX,o=t.clientY):"touchmove"===t.type&&(e=t.touches[0].clientX,o=t.touches[0].clientY),n.draggedPopups.forEach(function(t){t._dragToPixel([e,o])})},this._onUp=function(){n.map.getMapContainer().removeEventListener("mousemove",n._onDrag),n.map.getMapContainer().removeEventListener("touchmove",n._onDrag),n.map.getMapContainer().removeEventListener("mouseup",n._onUp),n.map.getMapContainer().removeEventListener("touchend",n._onUp),n.draggedPopups.forEach(function(t){n.draggedPopups.delete(t),t._onUp()})},this.map=t,this.popups=new Set,this.draggedPopups=new Set}var Hf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Uf=(Wf.prototype.add=function(t,e){var o,n;if(void 0===e&&(e=!0),Array.isArray(t))try{for(var r=Hf(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._addSource(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._addSource(t,e)},Wf.prototype.getRenderedShapes=function(t,e,o){t="string"==typeof t?t:t.getId(),o=this.map._getMap().querySourceFeatures(t,{sourceLayer:o,filter:e});return this.map.sources._mapFeaturesToShapes(o,!0,this.sources.get(t))},Wf.prototype.getFeatureState=function(t,e,o){t="string"==typeof t?t:t instanceof x?t.getId():t.id,e="string"==typeof e?e:e.getId();return this.map._getMap().getFeatureState({id:t,source:e,sourceLayer:o})},Wf.prototype.removeFeatureState=function(t,e,o,n){t="string"==typeof t?t:t instanceof x?t.getId():t.id,e="string"==typeof e?e:e.getId();this.map._getMap().removeFeatureState({id:t,source:e,sourceLayer:o},n)},Wf.prototype.setFeatureState=function(t,e,o,n){t="string"==typeof t?t:t instanceof x?t.getId():t.id,e="string"==typeof e?e:e.getId();this.map._getMap().setFeatureState({id:t,source:e,sourceLayer:n},o)},Wf.prototype._buildSources=function(){var e={};return this.sources.forEach(function(t){e[t.getId()]=t._buildSource()}),e},Wf.prototype.clear=function(){var e=this;this.sources.forEach(function(t){e.remove(t)})},Wf.prototype.getById=function(t){return this.sources.get(t)},Wf.prototype.getSources=function(){return Array.from(this.sources.values())},Wf.prototype.isSourceLoaded=function(t){t=t instanceof k?t.getId():t;return this.map._getMap().isSourceLoaded(t)},Wf.prototype.remove=function(t,e){var o,n;if(void 0===e&&(e=!0),Array.isArray(t))try{for(var r=Hf(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._removeSource(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._removeSource(t,e)},Wf.prototype.setSourceState=function(t,e){void 0===e&&(e=!0),this.sources.set(t.getId(),t),t._setMap(this.map,e)},Wf.prototype.unsetSourceState=function(t){this.sources.has(t)&&(this.sources.get(t)._setMap(null),this.sources.delete(t))},Wf.prototype._removeSource=function(t,e){t=t instanceof k?t.getId():t;if(!this.sources.has(t))throw new Error("'".concat(t,"' is not added to the map"));if(this.map._getMap().getSource(t)&&e&&this.map._getMap().removeSource(t),this.map._getMap().getSource(t)&&e)throw new Error("One or more layers have a dependency on the source '".concat(t,"'"));this.unsetSourceState(t)},Wf.prototype._addSource=function(t,e){if(this.sources.has(t.getId())){if(e)throw new Error("'".concat(t.getId(),"' is already added to the map"));this.unsetSourceState(t.getId())}if(e){if(!this.map._isReady())throw new Error("The source '".concat(t.getId(),"' could not be added to the map because ")+"the map is not ready. Please use a ready event listener to guarantee the map is ready before adding a source to it.");this.map._getMap().addSource(t.getId(),t._buildSource())}this.setSourceState(t)},Wf.prototype._mapFeaturesToShapes=function(t,e,o){var n,r,i=[];try{for(var s=Hf(t),a=s.next();!a.done;a=s.next()){var c=a.value;if((o||"string"==typeof c.source)&&"string"==typeof c.properties[x._shapeIdPropName]){var l=o||this.sources.get(c.source);if(l instanceof Nu){var u=l.getShapeById(c.properties[x._shapeIdPropName]);if(u instanceof x){i.push(u);continue}}}e||i.push(c)}}catch(t){n={error:t}}finally{try{a&&!a.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return i},Wf.prototype._syncSources=function(r){var n=this;r?(Object.keys(r).map(function(t){var e,o=r[t];switch(o.type){case"vector":case"raster":case"raster-dem":e=new $h(t,{name:t,tiles:o.tiles,type:o.type,url:o.url,tileSize:"tileSize"in o?o.tileSize:void 0});break;case"canvas":e=new Ju(t,o);break;case"geojson":var n=new Nu(t,{maxZoom:o.maxzoom,cluster:o.cluster,clusterRadius:o.clusterRadius,tolerance:o.tolerance,lineMetrics:o.lineMetrics,clusterProperties:o.clusterProperties,buffer:o.buffer,clusterMinPoints:o.clusterMinPoints,generateId:o.generateId,promoteId:o.promoteId,filter:o.filter});"string"!=typeof o.data&&void 0!==o.data&&n._addNoUpdate(o.data),e=n;break;case"image":e=new rp(t,o);break;case"video":e=new cp(t,o);break;default:e=new tp(t,o)}return e}).forEach(function(t){var e=n.sources.get(t.getId()),o=e&&t._isDeepEqual(e);!o&&e&&n.unsetSourceState(e.getId()),n.setSourceState(t,!o)}),Array.from(this.sources.keys()).filter(function(t){return!(t in r)}).forEach(function(t){return n.unsetSourceState(t)})):console.warn("syncSources called with no style sources which is unexpected.")},Wf);function Wf(t){this.map=t,this.sources=new Ne}(window&&window.__extends||(Gf=function(t,e){return(Gf=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Gf(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Yf,Vf=t);var Gf,Vf,Kf=Yf;function Yf(){var t=null!==Vf&&Vf.apply(this,arguments)||this;return t.duration=1e3,t.type="jump",t}(window&&window.__extends||(Jf=function(t,e){return(Jf=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Jf(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Qf,$f=t);var Jf,$f,Xf=Qf;function Qf(){var t=null!==$f&&$f.apply(this,arguments)||this;return t.bottom=0,t.left=0,t.right=0,t.top=0,t}var ty,ey,i=window&&window.__extends||(ty=function(t,e){return(ty=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ty(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),oy=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},ny=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},ry=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},iy=(i(sy,ey=t),sy.prototype.merge=function(){for(var e,t,o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];try{for(var r=oy(o),i=r.next();!i.done;i=r.next()){var s=i.value;s&&"number"==typeof s.padding&&(s.padding={top:s.padding,bottom:s.padding,left:s.padding,right:s.padding})}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return ey.prototype.merge.apply(this,ry([],ny(o),!1))},sy);function sy(){var t=null!==ey&&ey.apply(this,arguments)||this;return t.bounds=[-180,-89,180,90],t.maxBounds=void 0,t.maxZoom=20,t.offset=new Hc(0,0),t.padding=new Xf,t}(window&&window.__extends||(ay=function(t,e){return(ay=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ay(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(uy,cy=t);var ay,cy,ly=uy;function uy(){var t=null!==cy&&cy.apply(this,arguments)||this;return t.zoom=1,t.center=new Zl(0,0),t.centerOffset=new Hc(0,0),t.bearing=0,t.pitch=0,t.minZoom=1,t.maxZoom=20,t.minPitch=0,t.maxPitch=60,t.maxBounds=void 0,t}(window&&window.__extends||(py=function(t,e){return(py=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}py(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(dy,hy=t);var py,hy,er=dy;function dy(){var t=null!==hy&&hy.apply(this,arguments)||this;return t.name=void 0,t.before=void 0,t.minZoom=1,t.maxZoom=20,t.overwrite=!1,t.opacity=1,t}(window&&window.__extends||(fy=function(t,e){return(fy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}fy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(gy,yy=er);var fy,yy,my=gy;function gy(){var t=null!==yy&&yy.apply(this,arguments)||this;return t.color="rgba(0,0,0,.5)",t.outlineColor="#000",t.radius=1,t.outlineWidth=5,t.name="default-circles",t}(window&&window.__extends||(vy=function(t,e){return(vy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}vy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(by,wy=er);var vy,wy,_y=by;function by(){var t=null!==wy&&wy.apply(this,arguments)||this;return t.cap="butt",t.join="miter",t.name="default-linestrings",t.color="#000",t.width=1,t}(window&&window.__extends||(xy=function(t,e){return(xy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}xy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Cy,Oy=er);var xy,Oy,Sy=Cy;function Cy(){var t=null!==Oy&&Oy.apply(this,arguments)||this;return t.iconSize=1,t.fontSize=14,t.fontColor="#000",t.textFont="SegoeUi-Regular",t.cluster=!0,t.clusterIcon=void 0,t.textOffset=[0,0],t.name="default-pins",t.icon="pin-darkblue",t.title="",t}(window&&window.__extends||(Py=function(t,e){return(Py=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Py(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ay,Ly=er);var Py,Ly,ky=Ay;function Ay(){var t=null!==Ly&&Ly.apply(this,arguments)||this;return t.color="rgba(0,0,0,.5)",t.outlineColor="#000",t.name="default-polygons",t}(window&&window.__extends||(My=function(t,e){return(My=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}My(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Iy,Ey=er);var My,Ey,jy=Iy;function Iy(){var t=null!==Ey&&Ey.apply(this,arguments)||this;return t.name="default-raster",t}(window&&window.__extends||(Ty=function(t,e){return(Ty=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ty(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ry,zy=t);var Ty,zy,Dy=Ry;function Ry(){var t=null!==zy&&zy.apply(this,arguments)||this;return t.anchor="map",t.color="#FFFFFF",t.intensity=.5,t.position=[1.15,210,30],t}var By,Fy,r=window&&window.__extends||(By=function(t,e){return(By=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}By(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ny=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Zy=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},qy=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Hy=(r(Uy,Fy=t),Uy.prototype.merge=function(){for(var e,t,o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];try{for(var r=Ny(o),i=r.next();!i.done;i=r.next()){var s=i.value;s&&(s.hasOwnProperty("view")?s.userRegion=s.view:s.hasOwnProperty("userRegion")&&(s.view=s.userRegion),"string"==typeof s.language)&&(s.language=Ct.getCode(s.language))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return Fy.prototype.merge.apply(this,qy([],Zy(o),!1))},Uy);function Uy(){var t=null!==Fy&&Fy.apply(this,arguments)||this;return t.antialias=void 0,t.autoResize=!0,t.language=Ft,t.light=new Dy,t.preserveDrawingBuffer=!1,t.progressiveLoading=!1,t.progressiveLoadingInitialLayerGroups=["base"],t.renderWorldCopies=!0,t.showBuildingModels=!1,t.showFeedbackLink=!0,t.showLogo=!0,t.showLabels=!0,t.customAttribution=void 0,t.showTileBoundaries=!1,t.style=void 0,t.view=Bt,t.userRegion=t.view,t.styleOverrides=void 0,t.customStyleTransform=void 0,t}function Wy(t){return 0==t.length?void 0:t.slice(1).reduce(function(o,n){return function(t,e){t=o(t,e);return Ky(Ky({},t),n(t.url,e))}},t[0])}var Gy,Vy,tr=window&&window.__extends||(Gy=function(t,e){return(Gy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Gy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ky=window&&window.__assign||function(){return(Ky=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Yy=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Jy=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},$y=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Xy=(tr(Qy,Vy=t),Qy.prototype.merge=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var o=this.styleDefinitionsVersion;try{for(var n=Yy(t),r=n.next();!r.done;r=n.next()){var i=r.value;i&&(i.authOptions?"string"==typeof i.authOptions.subscriptionKey&&(i.subscriptionKey=i["subscription-key"]=i.authOptions.subscriptionKey):"string"==typeof i.subscriptionKey?(i["subscription-key"]=i.subscriptionKey,i.authOptions={authType:u.AuthenticationType.subscriptionKey,subscriptionKey:i.subscriptionKey}):"string"==typeof i["subscription-key"]&&(i.subscriptionKey=i["subscription-key"],i.authOptions={authType:u.AuthenticationType.subscriptionKey,subscriptionKey:i["subscription-key"]}),"string"==typeof i.sessionId?i["session-id"]=i.sessionId:"string"==typeof i["session-id"]&&(i.sessionId=i["session-id"]),"boolean"==typeof i.disableTelemetry?i["disable-telemetry"]=i.disableTelemetry:"boolean"==typeof i["disable-telemetry"]&&(i.disableTelemetry=i["disable-telemetry"]),"boolean"==typeof i.enableAccessibility?i["enable-accessibility"]=i.enableAccessibility:"boolean"==typeof i["enable-accessibility"]&&(i.enableAccessibility=i["enable-accessibility"]))}}catch(t){c={error:t}}finally{try{r&&!r.done&&(a=n.return)&&a.call(n)}finally{if(c)throw c.error}}var s=this._transformers,a=t?t.filter(function(t){return void 0!==t}).reduce(function(t,e){return $y($y([],Jy(t),!1),Jy(e._transformers||[]),!1)},[]):[],c=Vy.prototype.merge.apply(this,$y([],Jy(t),!1)),a=(c.authOptions.authType!==u.AuthenticationType.subscriptionKey&&(c["subscription-key"]=c.subscriptionKey=void 0),void 0!==c.styleSet&&void 0===c.mapConfiguration&&(c.mapConfiguration=c.styleSet),c.mapConfiguration&&"string"!=typeof c.mapConfiguration&&(c.mapConfiguration=Ky(Ky({},c.mapConfiguration),{defaultConfiguration:c.mapConfiguration.defaultConfiguration||c.mapConfiguration.defaultStyle,configurations:c.mapConfiguration.configurations||c.mapConfiguration.styles})),this._transformers=$y($y([],Jy(s||[]),!1),Jy(a.filter(function(t){return!s.includes(t)})),!1),this.transformRequest&&!this._transformers.includes(this.transformRequest)&&this._transformers.push(this.transformRequest),new Date(Date.UTC(2023,0))),l=new Date(this.styleDefinitionsVersion);return(isNaN(l.getTime())||l.getTime()<a.getTime())&&(console.warn("Style definition version ".concat(this.styleDefinitionsVersion," is invalid or deprecated, style definition version is unchanged (").concat(o,")")),this.styleDefinitionsVersion=o),this.transformRequest=Wy(this._transformers),c},Qy.prototype.addTransformer=function(t){this._transformers||(this._transformers=[]),this._transformers.push(t),this.transformRequest=Wy(this._transformers)},Qy.prototype.removeTransformer=function(e){this._transformers&&(this._transformers=this._transformers.filter(function(t){return e!==t}),this.transformRequest=Wy(this._transformers))},Qy._cloneCustomizer=function(t){if("object"==typeof t)return Object.assign({},t)},Qy);function Qy(){var t=null!==Vy&&Vy.apply(this,arguments)||this;return t.authOptions=oe(),t.disableTelemetry=!0,t["disable-telemetry"]=t.disableTelemetry,t.domain=Zt,t.staticAssetsDomain=qt,t.styleDefinitionsPath=Ht,t.styleDefinitionsVersion=Ut,t.styleAPIVersion=Wt,t.mapConfiguration=void 0,t.styleSet=void 0,t.enableAccessibility=!0,t["enable-accessibility"]=t.enableAccessibility,t.enableAccessibilityLocationFallback=!0,t.maxParallelImageRequests=le(),t.refreshExpiredTiles=!0,t.subscriptionKey=he(),t["subscription-key"]=t.subscriptionKey,t.sessionId=Nt,t["session-id"]=t.sessionId,t._transformers=[],t.transformRequest=void 0,t.workerCount=ce(),t.fadeDuration=300,t.localIdeographFontFamily="sans-serif",t.validateStyle=!1,t}em.getLayerGroup=function(t){return"string"!=typeof t&&t.metadata&&t.metadata["microsoft.maps:layerGroup"]?t.metadata["microsoft.maps:layerGroup"]:(t="string"!=typeof t?t.id:t).startsWith("microsoft.")&&4<=(t=t.split(".")).length?t[3]:void 0};var tm=em;function em(){}nm.resolve=function(t){return new nm(Promise.resolve(t))},nm.reject=function(t){return new nm(Promise.reject(t))},nm.prototype.then=function(t,e){var o=this;return new Promise(function(t,e){o._resolve=t,o._reject=e,o._thenResolver(t,e)}).then(t,e)},nm.prototype.catch=function(t){var o=this;return new Promise(function(t,e){o._resolve=t,o._reject=e,o._thenResolver(t,e)}).catch(t)},nm.prototype.finally=function(t){var o=this;return new Promise(function(t,e){o._resolve=t,o._reject=e,o._thenResolver(t,e)}).finally(t)},nm.prototype.hijackAndResolve=function(t){this._hijackedToResolve=t,this._resolve&&this._resolve(t)},nm.prototype.hijackAndReject=function(t){this._hijackedToReject=t,this._reject&&this._reject(t)},nm.prototype.switchWith=function(t){this.origin=t,this._toResolve=void 0,this._toReject=void 0};var om=nm;function nm(t){var r=this;this.isHijacked=function(){return void 0!==r._hijackedToResolve||void 0!==r._hijackedToReject},this.isResolved=function(){return void 0!==r._hijackedToResolve||void 0!==r._toResolve},this.isRejected=function(){return void 0!==r._hijackedToReject||void 0!==r._toReject},this.resultIfResolved=function(){return r._hijackedToResolve||r._toResolve},this.errorIfRejected=function(){return r._hijackedToReject||r._toReject},this._thenResolver=function(e,o){var n;r._hijackedToResolve?e(r._hijackedToResolve):r._hijackedToReject?o(r._hijackedToReject):(n=r.origin,r.origin.then(function(t){r.isHijacked()||(n!==r.origin?r._thenResolver(e,o):(r._toResolve=t,e(t)))}).catch(function(t){r.isHijacked()||(n!==r.origin?r._thenResolver(e,o):(r._toReject=t,o(t)))}))},this.origin=t,this[Symbol.toStringTag]=this.origin[Symbol.toStringTag]}var rm={road:"Road",satellite:"Satellite",satellite_road_labels:"Hybrid",grayscale_dark:"Grayscale (Dark)",grayscale_light:"Grayscale (Light)",night:"Night",road_shaded_relief:"Terra",blank:"Blank",blank_accessible:"Blank (Accessible)",high_contrast_dark:"High contrast (Dark)",high_contrast_light:"High contrast (Light)"},im=window&&window.__assign||function(){return(im=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},sm=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},am=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},cm=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},lm=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},um=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},pm={countryRegion:"cr|bv:0",adminDistrict:"ad|bv:0",adminDistrict2:"ds|bv:0",buildingFootprint:"bld|v:0_adr|lv:0",roadDetails:"g|rasterDetailsVisible:0"},hm=(I.prototype.updateIndoorState=function(t,e){var o,n,r=this,i=this.map.styles.getMapConfiguration();i?(this.preservedPreindoorMapConfiguration=i,o=this.map.getStyle().style?"".concat(this.map.getStyle().style,"_indoor").concat("dark"===t?"_dark":"","_tileset_").concat(e):void 0,this.map.styles.setMapConfiguration("defaultIndoor_".concat(e),"microsoft-maps:default"===i?o:void 0)):(n=(null==(i=this.indoorState)?void 0:i.tilesetId)!==e,this.indoorState={tilesetId:e,theme:t},this.initStyleset(),this.definitions().then(function(t){var e=(r.map.getStyle().style||t.defaultConfiguration).replace("_indoor_dark","").replace("_indoor",""),o="".concat(e,"_indoor"),e=t.configurations.find(function(t){return t.name.startsWith(o)});e&&r.map.setStyle({style:e.name},!n)}))},I.prototype.unsetIndoorState=function(){var o=this,t=this.preservedPreindoorMapConfiguration;t?this.map.styles.setMapConfiguration(t):(this.indoorState=void 0,this.initStyleset(),this.definitions().then(function(t){var e=o.map.getStyle().style;e.includes("_indoor")&&e.split("_indoor")[0]?o.map.setStyle({style:e.split("_indoor")[0]}):o.map.setStyle({style:void 0})}))},I.prototype.initStyleset=function(){var t,o=this;return t=this.serviceOptions.mapConfiguration?"string"==typeof this.serviceOptions.mapConfiguration?(t=this.map.authentication?this.map.authentication.initialize():Promise.resolve(),new om(t.then(function(){return o._request(o.serviceOptions.domain,"".concat(lt,"/mapconfigurations/metadata/").concat(o.serviceOptions.mapConfiguration),"StyleDefinitions").then(function(t){return im(im({},t),{defaultConfiguration:t.defaultConfiguration||t.defaultStyle,configurations:t.configurations||t.styles})})}))):om.resolve(this.serviceOptions.mapConfiguration):(t=this.map.authentication?this.map.authentication.initialize():Promise.resolve(),new om(t.then(function(){return o._request(o.serviceOptions.staticAssetsDomain,"".concat(ct,"/").concat(lt),"StyleDefinitions",{version:o.serviceOptions.styleDefinitionsVersion,mcv:At.replace(/\./g,"")}).then(function(e){return{version:isNaN(e.version)?0:parseFloat(e.version),defaultConfiguration:e.defaultStyle,configurations:e.styles.filter(function(t){return o.indoorState?"auto"===o.indoorState.theme?t.name.endsWith("dark"===t.theme?"_indoor_dark":"_indoor"):t.name.endsWith("dark"===o.indoorState.theme?"_indoor_dark":"_indoor"):!t.name.includes("indoor")}).map(function(t){return{copyright:t.copyright.join(" "),name:t.name,displayName:function(t){t=o.indoorState&&t.includes("_indoor")?t.split("_indoor")[0]:t;return t in rm?rm[t]:t}(t.name),theme:t.theme,thumbnail:new wt({domain:o.serviceOptions.staticAssetsDomain,path:t.thumbnail,protocol:"https"}).toString(),url:new wt({domain:o.serviceOptions.staticAssetsDomain,path:"".concat(ct,"/").concat(lt,"/").concat(t.name),queryParams:{styleVersion:void 0!==e.version&&null!==e.version?e.version:o.serviceOptions.styleDefinitionsVersion,mcv:At.replace(/\./g,"")},protocol:"https"}).toString()}})}})}))),this.initPromise&&this.initPromise.switchWith(t),this.initPromise=t,this.initPromise.then(function(t){return o.map._invokeEvent("mapconfigurationchanged",t)}),this.initPromise},I.prototype.getStyle=function(t){t=this._lookUp(t);if(!t)throw Error("Style definition is not available.");if(t.url)return t.url;if(t.style)return t.style;throw Error("Style definition neither contains URL nor style object.")},I.prototype.deriveNewStyleAndLayerGroups=function(t,e){for(var o,n,r=this.map.getStyle(),i=this.map.getTraffic(),s={},a=0;a<e.layers.length;a++){var c=e.layers[a],l=tm.getLayerGroup(c);l?(s[l]||(s[l]=[]),s[l].push(c),r.showBuildingModels||"fill-extrusion"!==c.type?"fill-extrusion"===c.type&&(c.layout=null!=(o=c.layout)?o:{},c.layout.visibility="visible"):(c.layout=null!=(o=c.layout)?o:{},c.layout.visibility="none"),"none"!==i.flow&&l&&l==="traffic_".concat(i.flow)&&"line"==c.type&&(c.layout=null!=(n=c.layout)?n:{},c.layout.visibility="visible"),"labels"!==l&&"labels_places"!==l&&"labels_indoor"!==l||"symbol"!==c.type||(r.showLabels&&"none"!==(null==(n=c.layout)?void 0:n.visibility)?(c.layout=null!=(l=c.layout)?l:{},c.layout.visibility="visible"):(c.layout=null!=(l=c.layout)?l:{},c.layout.visibility="none"))):s[c.id]=[c]}return[e,s]},I.prototype.injectUserLayersIntoStyle=function(s,a,c){return s?this.map.layers._getUserLayers().reduce(function(o,e){var n,t,r,i;return e.layer instanceof yd||(n=(null==(t=null==(t=null==c?void 0:c[e.before])?void 0:t[0])?void 0:t.id)||e.before,t=s.layers.find(function(t){return t.id===e.layer.getId()}),-1<(r=a.layers.findIndex(function(t){return t.id===e.layer.getId()}))&&a.layers.splice(r,1),t&&(r=new Set(Array.from(e.layer._getSourceIds()).map(function(t){var e;return!o.sources[t]&&(e=s.sources[t])?{source:e,id:t}:void 0}).filter(function(t){return void 0!==t})),-1<(i=n?o.layers.findIndex(function(t){return t.id===n}):-1)?o.layers.splice(i,0,t):o.layers.push(t),r.forEach(function(t){var e=t.source,t=t.id;o.sources[t]=e}))),o},im({},a)):a},I.prototype.setStyle=function(r,t){var i=this,e=(void 0===t&&(t=!0),this._lookUp(r));if(!e)throw Error("Style definition ".concat(r.style," is not available."));if(!e.url&&!e.style)throw Error("Style definition neither contains URL nor style object.");var o,n,s,a=function(){return i._onStyleData(e)},c=function(){i.map.events.remove("styledata",a),i.map.events.addOnce("styledata",a)},l=r&&r.customStyleTransform?function(t,e){t=r.customStyleTransform(t,e);return c(),t}:function(t,e){var o=im(im({},e),{layers:lm([],cm(e.layers),!1),sources:im({},e.sources)}),n=r.progressiveLoading&&!i.map._isLoaded(),e=(n&&Array.isArray(null==e?void 0:e.layers)&&((o=im({},e)).layers=o.layers.map(function(t){var e=im({},t);return t.layout&&(e.layout=im({},t.layout)),e})),cm(i.deriveNewStyleAndLayerGroups(t,o),2)),o=e[0],e=e[1],n=(n&&(n=r.progressiveLoadingInitialLayerGroups,Array.isArray(n))&&0<n.length&&i._deferLayerGroupVisibilities(e,n),i.injectUserLayersIntoStyle(t,o,e)),t=Object.entries(e).map(function(t){var t=cm(t,2),e=t[0],t=t[1];return i._buildFundamentalLayerFrom(t,e)}),o=i.map.layers._getUserLayers().reduce(function(t,e){var o=e.before?t.findIndex(function(t){return t.getId()===e.before}):-1;return-1<o?t.splice(o,0,e.layer):t.push(e.layer),t},t);return i.map.layers.layerIndex=o,i.map.sources._syncSources(n.sources),c(),n},u=e.url;u&&null!=r&&r.styleOverrides&&(o=new URL(u),n=new URLSearchParams(o.search),0<(s=Object.entries(null==r?void 0:r.styleOverrides).filter(function(t){var t=cm(t,2),e=t[0],t=t[1];return e in pm&&(pm[e].includes("bv")&&!1===(null==t?void 0:t.borderVisible)||!pm[e].includes("bv")&&!1===(null==t?void 0:t.visible))}).map(function(t){var t=cm(t,2),e=t[0];return t[1],pm[e]})).length)&&(n.set("st",s.join("_")),o.search=n.toString(),u=o.toString()),this.map._getMap().setStyle(u||e.style,{diff:t,validate:this.serviceOptions.validateStyle,transformStyle:l})},I.prototype.getTheme=function(t){t=this._lookUp(t);if(t)return t.theme.toLowerCase()},I.prototype.getThemeAsync=function(e){return sm(this,void 0,void 0,function(){return am(this,function(t){switch(t.label){case 0:return[4,this._lookUpAsync(e)];case 1:return[2,t.sent().theme]}})})},I.prototype.setMapConfiguration=function(t,o){var n=this;"string"==typeof(this.serviceOptions.mapConfiguration=t)?this.initStyleset():this.initPromise?this.initPromise.hijackAndResolve(t):this.initPromise=om.resolve(t),this.definitions().then(function(t){var e=t.defaultConfiguration;t.configurations.find(function(t){return t.name===o})&&(e=o),n.map.setStyle({style:e})})},I.prototype.getMapConfiguration=function(){return this.serviceOptions.mapConfiguration},I.prototype.setStyleSet=function(t){this.updateIndoorState("indoor_dark"===t?"dark":"light",null)},I.prototype.getStyleSet=function(){return void 0!==this.indoorState?"dark"===this.indoorState.theme?"indoor_dark":"indoor":"base"},I.prototype.clearStyleSet=function(){this.unsetIndoorState()},I.prototype._buildFundamentalLayerFrom=function(t,e){if(t&&0<t.length)return(t=new If(t,e)).onAdd(this.map),t;throw new Error("Unable to construct fundamental map layer for ID: ".concat(e,"."))},I.prototype._transformStyleRequest=function(t,e){t.includes(et)&&(e.url=e.url.replace(et,this.serviceOptions.domain)),t.includes(st)&&(e.url=e.url.replace(st,ct)),t.includes(at)&&(e.url=e.url.replace(at,lt)),(e.url.toLocaleLowerCase().includes(this.serviceOptions.domain.toLocaleLowerCase())||e.url.toLocaleLowerCase().includes(this.serviceOptions.staticAssetsDomain.toLocaleLowerCase()))&&((t=new URL(e.url)).searchParams.get(Q)||(t.searchParams.set(Q,this.serviceOptions.styleAPIVersion),e.url=t.href),null!=(t=this.map.authentication)&&t.signRequest(e),this._deleteAuthTokenForStaticAssets(e))},I.prototype._request=function(n,r,i,s){var a;return void 0===s&&(s={}),sm(this,void 0,void 0,function(){var e,o;return am(this,function(t){switch(t.label){case 0:return o={url:new wt({protocol:"https",domain:n,path:r,queryParams:im(((o={})[Q]=this.serviceOptions.styleAPIVersion,o),s)}).toString()},"function"==typeof this.serviceOptions.transformRequest&&i&&(o=this.serviceOptions.transformRequest(o.url,i)),null!=(a=this.map.authentication)&&a.signRequest(o),this._deleteAuthTokenForStaticAssets(o),e={method:"GET",mode:"cors"},o.credentials&&(e.credentials=o.credentials),o.headers&&(e.headers=o.headers),[4,fetch(o.url,e).then(function(t){if(t.ok)return t.json();throw new Error("HTTP ".concat(t.status,": ").concat(t.statusText," "))})];case 1:return[2,t.sent()]}})})},I.prototype._deleteAuthTokenForStaticAssets=function(t){t.url.startsWith("https://".concat(this.serviceOptions.staticAssetsDomain,"/").concat(ct))&&(delete t.headers[ut],delete t.headers[tt])},I);function I(t,e){var u=this;this.definitions=function(){var t=u.initPromise||u.initStyleset();return t},this.indoorState=void 0,this.preservedPreindoorMapConfiguration=void 0,this._progressiveLoadingState={mapStyle:void 0,pendingVisibilityChange:void 0},this._deferLayerGroupVisibilities=function(e,t){var o,r,n,i,s=t.filter(function(t){return t in e});0!==s.length&&(o=u.map._getMap(),r=o.getZoom(),n=u.map.getStyle().style,u._progressiveLoadingState.pendingVisibilityChange&&(u.map.events.remove("load",u._progressiveLoadingState.pendingVisibilityChange),u._progressiveLoadingState.pendingVisibilityChange=null),u._progressiveLoadingState.mapStyle=n,(i=Object.entries(e).reduce(function(t,e){var e=cm(e,2),o=e[0],e=e[1],n=s.includes(o);return lm(lm([],cm(t),!1),cm(e.filter(function(t){if("custom"===t.type)return!1;if(n)if("number"==typeof t.maxzoom&&"number"==typeof t.minzoom){if(r<=t.maxzoom&&r>=t.minzoom)return!1}else if("number"==typeof t.minzoom){if(r>=t.minzoom)return!1}else{if("number"!=typeof t.maxzoom)return!1;if(r<=t.maxzoom)return!1}return"none"!==(null==(t=t.layout)?void 0:t.visibility)})),!1)},[])).forEach(function(t){t.layout=t.layout||{},t.layout.visibility="none"}),u._progressiveLoadingState.pendingVisibilityChange=function(){u._progressiveLoadingState.pendingVisibilityChange=null;var t=u.map.getStyle().style;n===t&&(i.forEach(function(t){t.layout.visibility="visible",o.setLayoutProperty(t.id,"visibility","visible")}),null!=(t=u.map.copyrightDelegate))&&t.reloadAttribution()},u.map.events.addOnce("load",u._progressiveLoadingState.pendingVisibilityChange))},this._onStyleData=function(t){u.map.events.invoke("stylechanged",{style:t.name,map:u.map,type:"stylechanged"})},this._lookUp=function(t){var e,o,n=u.definitions(),r=n.errorIfRejected(),i=n.resultIfResolved();if(r||!i)return null;var n=i.configurations,s=void 0;try{for(var a=um(n),c=a.next();!c.done;c=a.next()){var l=c.value;if(l.name===t.style)return l;l.name===i.defaultConfiguration&&(s=s||l)}}catch(t){e={error:t}}finally{try{c&&!c.done&&(o=a.return)&&o.call(a)}finally{if(e)throw e.error}}return s=s||n[0]},this._lookUpAsync=function(o){return sm(u,void 0,void 0,function(){var e;return am(this,function(t){switch(t.label){case 0:return[4,this.definitions()];case 1:return e=t.sent(),[2,e.configurations.find(function(t){return t.name===(o.style||e.defaultConfiguration)})||e.configurations.find(function(t){return t.name===e.defaultConfiguration})||e.configurations[0]]}})})},this.map=t,this.serviceOptions=e}var dm=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},fm=(ym.prototype.add=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=dm(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.indicators.has(i)||(this.indicators.add(i),i.attach(this.map))}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},ym.prototype.clear=function(){var e=this;this.indicators.forEach(function(t){e.indicators.delete(t),t.remove()})},ym.prototype.remove=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=dm(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.indicators.has(i)&&(this.indicators.delete(i),i.remove())}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},ym.prototype.getIndicators=function(){return Array.from(this.indicators)},ym.prototype._getCollectionDiv=function(){var t=this.map.getMapContainer().querySelector(".".concat(ym.Css.collection));return t||((t=document.createElement("div")).setAttribute("aria-label","map data"),t.setAttribute("role","listbox"),t.classList.add(ym.Css.collection),this.map.getMapContainer().appendChild(t)),t},ym.Css={collection:"accessible-indicator-collection-container"},ym);function ym(t){this.map=t,this.indicators=new Set}var mm,gm,q=window&&window.__extends||(mm=function(t,e){return(mm=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}mm(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),vm=window&&window.__assign||function(){return(vm=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},wm=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},_m=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},bm=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},xm=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Om=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},jn=(q(T,gm=Ze),Object.defineProperty(T.prototype,"isDisposed",{get:function(){return this.removed},enumerable:!1,configurable:!0}),T.prototype.getCanvas=function(){return this.map.getCanvas()},T.prototype.getCanvasContainer=function(){return this.map.getCanvasContainer()},T.prototype.getMapContainer=function(){return this.map.getContainer()},T.prototype.getServiceOptions=function(){return L(this.serviceOptions,Xy._cloneCustomizer)},T.prototype.setServiceOptions=function(t){this.serviceOptions=(new Xy).merge(this.serviceOptions,t),this.serviceOptions["enable-accessibility"]?this.accessibleMapDelegate.addToMap():this.accessibleMapDelegate.removeFromMap();t=this.styles.serviceOptions.mapConfiguration!==this.serviceOptions.mapConfiguration||this.styles.serviceOptions.staticAssetsDomain!==this.serviceOptions.staticAssetsDomain||this.styles.serviceOptions.styleDefinitionsVersion!==this.serviceOptions.styleDefinitionsVersion||this.styles.serviceOptions.domain!==this.serviceOptions.domain||this.styles.serviceOptions.styleAPIVersion!==this.serviceOptions.styleAPIVersion;this.styles.serviceOptions=this.serviceOptions,t&&(this.styles.initPromise=null,this.setStyle({}))},T.prototype.addRequestTransformer=function(t){this.serviceOptions.addTransformer(t)},T.prototype.removeRequestTransformer=function(t){this.serviceOptions.removeTransformer(t)},T.prototype.setCamera=function(t,e){if(void 0===e&&(e=!1),"padding"in t||"offset"in t||"bounds"in t){var o,n=(new iy).merge({maxZoom:this.getCamera().maxZoom},t),r=this._generateSafeBounds(n.bounds),i={padding:n.padding,offset:n.offset,maxZoom:n.maxZoom};if(!(o=this.map.cameraForBounds(r,i)))throw s={message:"The map cannot be fit to the current canvas with the given CameraBoundsOptions.",containerWidth:null==(s=null==(s=this.map)?void 0:s.getContainer())?void 0:s.clientWidth,containerHeight:null==s?void 0:s.clientHeight,safeBounds:r,cameraForBoundsOptions:i},new Error(JSON.stringify(s));"pitch"in t&&(o.pitch=t.pitch),"bearing"in t&&(o.bearing=t.bearing),"minPitch"in t&&this.map.setMinPitch(t.minPitch),"maxPitch"in t&&this.map.setMaxPitch(t.maxPitch),"minZoom"in t&&this.map.setMinZoom(t.minZoom),r=this._generateSafeBounds(n.maxBounds)}else{i=(new ly).merge(this.getCamera(),t);i.centerOffset&&2<=i.centerOffset.length&&(s=i.centerOffset,(n=Ll([i.center],i.zoom))[0][0]+=s[0],n[0][1]+=s[1],i.center=Pl(n,i.zoom)[0]),o={center:i.center,zoom:i.zoom,bearing:i.bearing,pitch:i.pitch,around:void 0},i.minZoom<1&&console.warn("Setting minZoom below 1 may result in an empty map when the zoom level is less than 1."),this.map.setMinZoom(i.minZoom),this.map.setMaxZoom(i.maxZoom),i.minPitch&&this.map.setMinPitch(i.minPitch),i.maxPitch&&this.map.setMaxPitch(i.maxPitch),this._invokeEvent("minzoomchanged",this.map.getMinZoom()),this._invokeEvent("maxzoomchanged",this.map.getMaxZoom()),r=this._generateSafeBounds(i.maxBounds)}r?this.map.setMaxBounds(r):this.map.setMaxBounds(null);var s=(new Kf).merge(t),n={duration:s.duration,easing:function(t){return t},offset:[0,0],animate:!0},i={fromControl:e};"jump"===s.type?this.map.jumpTo(o,i):"ease"===s.type?this.map.easeTo(vm(vm({},o),n),i):"fly"===s.type&&this.map.flyTo(vm(vm({},o),n),i)},T.prototype.setCameraBounds=function(t){this.setCamera(t)},T.prototype.getCamera=function(){var t=this.map.getBounds().getSouthWest().toArray(),e=this.map.getBounds().getNorthEast().toArray();return{zoom:this.map.getZoom(),center:this.map.getCenter().toArray(),bearing:this.map.getBearing(),pitch:this.map.getPitch(),bounds:new S(t,e),minZoom:this.map.getMinZoom(),maxZoom:this.map.getMaxZoom()}},T.prototype.setStyle=function(t,e){void 0===e&&(e=!0),delete t.preserveDrawingBuffer;t=(new Hy).merge(this.styleOptions,t),t.autoResize!==this.styleOptions.autoResize&&this._setAutoResize(t.autoResize),t.language!==this.styleOptions.language&&(this.localizedStringsPromise=Ct.getStrings(t.language)),t.renderWorldCopies!==this.styleOptions.renderWorldCopies&&this.map.setRenderWorldCopies(t.renderWorldCopies),t.showFeedbackLink!==this.styleOptions.showFeedbackLink&&this.copyrightControl.setOptions({showFeedbackLink:t.showFeedbackLink}),t.customAttribution!==this.styleOptions.customAttribution&&this.copyrightControl.setOptions({customAttribution:t.customAttribution}),t.showLogo!==this.styleOptions.showLogo&&(this.copyrightControl.setOptions({showLogo:t.showLogo}),this.logoControl.setOptions({showLogo:t.showLogo})),t.showTileBoundaries!==this.styleOptions.showTileBoundaries&&(this.map.showTileBoundaries=t.showTileBoundaries),t.showBuildingModels&&console.warn("showBuildingModels is deprecated."),e=e&&this.styleOptions.language===t.language&&this.styleOptions.view===t.view;this.styleOptions=t,this._setStyleComponents(t,e)},T.prototype.getStyle=function(){return c(this.styleOptions)},T.prototype.addIcon=function(t,e){this.imageSprite.add(t,e)},T.prototype.addPins=function(t,e){var e=(new Sy).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new Gh("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,iconOptions:{anchor:"center",size:e.iconSize,image:["case",["has","icon"],["get","icon"],e.icon],ignorePlacement:!e.cluster,opacity:e.opacity},textOptions:{anchor:"center",textField:["case",["has","point_count"],["to-string",["get","point_count"]],["has","title"],["to-string",["get","title"]],e.title],font:["case",["has","point_count"],["literal",["StandardFontCondensed-Bold"]],["literal",[e.textFont]]],size:["case",["has","point_count"],20,e.fontSize],ignorePlacement:!e.cluster,opacity:e.opacity,offset:["case",["has","point_count"],["literal",[.5,-.45]],["literal",[e.textOffset[0]/16,e.textOffset[1]/16]]],color:e.fontColor}})),!(o instanceof Gh))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a SymbolLayer.")+"A SymbolLayer should be used for rendering pins.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s,{cluster:e.cluster})),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addCircles=function(t,e){var e=(new my).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new Rp("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,opacity:e.opacity,radius:["case",["has","radius"],["get","radius"],e.radius],color:["case",["has","color"],["get","color"],e.color],strokeColor:["case",["has","outlineColor"],["get","outlineColor"],e.outlineColor],strokeWidth:["case",["has","outlineWidth"],["get","outlineWidth"],e.outlineWidth]})),!(o instanceof Rp))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a BubbleLayer.")+"A BubbleLayer should be used for rendering circles.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s)),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addLinestrings=function(t,e){var e=(new _y).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new dh("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,lineCap:e.cap,lineJoin:e.join,strokeOpacity:e.opacity,strokeColor:["case",["has","color"],["get","color"],e.color],strokeWidth:["case",["has","width"],["get","width"],e.width]})),!(o instanceof dh))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a LineLayer.")+"A LineLayer should be used for rendering linestrings.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s)),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addPolygons=function(t,e){var e=(new ky).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new Ah("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,fillOpacity:e.opacity,fillColor:["case",["has","color"],["get","color"],e.color]})),!(o instanceof Ah))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a PolygonLayer.")+"A PolygonLayer should be used for rendering linestrings.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s)),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addRaster=function(t,e){var o,e=(new jy).merge(e),n=this.layers.getLayerById(e.name);if(!((n=n||new ad({maxZoom:e.maxZoom,minZoom:e.minZoom,opacity:e.opacity,tileSize:256,tileUrl:"{subdomain}"},e.name))instanceof ad))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a TileLayer.")+"A TileLayer should be used for rendering raster images.");if("{subdomain}"!==n.getOptions().tileUrl)throw new Error("A TileLayer with name '".concat(e.name,"' already exists but was configured ")+"for a single tile url [default for new TileLayer(...)].");(o=!e.overwrite&&n.getOptions().subdomains||[]).push.apply(o,xm([],bm(t),!1)),n._setOptionsNoUpdate({subdomains:o}),this.layers.add(n,e.before)},T.prototype.getLayers=function(){return this.layers.getLayers().map(function(t){return t.getId()})},T.prototype.removeLayers=function(t){var e,o;try{for(var n=Om(t),r=n.next();!r.done;r=n.next()){var i,s=r.value;this.layers.getLayerById(s)&&(this.layers.remove(s),i="".concat(s,"-source"),this.sources.getById(i))&&this.sources.remove(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},T.prototype.addHtml=function(t,e){t.id||(t.id="marker_".concat(J()));var o=new Dd({htmlContent:t});return this.markers.add(o,e),t.id},T.prototype.removeHtml=function(t){this.markers.remove(t)},T.prototype.addEventListener=function(t,e,o){this.events._addLegacy(t,e,o)},T.prototype.removeEventListener=function(t,e,o){this.events._removeLegacy(t,e,o)},T.prototype.setUserInteraction=function(t){this.userInteractionDelegate.setOptions(t)},T.prototype.getUserInteraction=function(){return this.userInteractionDelegate.getOptions()},T.prototype.addControl=function(t,e){this.controls.add(t,e)},T.prototype.removeControl=function(t){this.controls.remove(t)},T.prototype.setTraffic=function(t){var e=this.trafficOptions.incidents,o=this.trafficOptions.flow;if(this.trafficOptions=(new Ka).merge(this.trafficOptions,t),this.controls.getControls().filter(function(t){return t instanceof oc}).forEach(function(t){return t.updateButtonState()}),this.incidentDelegate&&(this.trafficOptions.incidents?e||this.incidentDelegate.addToMap():this.incidentDelegate.removeFromMap()),this.trafficOptions.flow&&"none"!==this.trafficOptions.flow){["absolute","relative-delay"].includes(this.trafficOptions.flow)&&console.warn("The 'absolute' and 'relative-delay' flow options are deprecated. Please use 'relative' instead.");try{this.trafficOptions.flow!==o&&this.flowDelegate.addToMap()}catch(t){throw this.trafficOptions.flow=o,t}}else this.flowDelegate.removeFromMap()},T.prototype.getTraffic=function(){return c(this.trafficOptions)},T.prototype.remove=function(){this.dispose()},T.prototype.clear=function(){this.popups.clear(),this.layers.clear(),this.sources.clear(),this.markers.clear(),this.indicators.clear()},T.prototype.dispose=function(){var t;for(this.clear(),this.map.remove(),null!=(t=this.authentication)&&t.dispose(),this.removed=!0,null!=(t=this.resizeObserver)&&t.disconnect(),this.resizeObserver=null;this.getMapContainer().firstChild;){var e=this.getMapContainer().firstChild;this.getMapContainer().removeChild(e)}},T.prototype.resize=function(t,e,o){"number"!=typeof t&&"string"!=typeof t||"number"!=typeof e&&"string"!=typeof e?o=t:(t=t,this.getMapContainer().style.height="number"==typeof t?"".concat(t,"px"):t,this.getMapContainer().style.width="number"==typeof e?"".concat(e,"px"):e);t=this.getMapContainer().style.overflow;this.getMapContainer().style.overflow="hidden",this.map.resize(o),this.getMapContainer().style.overflow=t},T.prototype.pixelsToPositions=function(t){var e,o,n=[];try{for(var r=Om(t),i=r.next();!i.done;i=r.next()){var s=i.value,a=this.map.unproject(s);n.push(new Zl(a.lng,a.lat))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}return n},T.prototype.positionsToPixels=function(t){var e,o,n=[];try{for(var r=Om(t),i=r.next();!i.done;i=r.next()){var s=i.value,a=this.map.project(s);n.push(new Hc(a.x,a.y))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}return n},T.prototype.areTilesLoaded=function(){return this.map.areTilesLoaded()},T.prototype.stop=function(){this.map.stop()},T.prototype.triggerRepaint=function(){this.map.triggerRepaint()},T.prototype.enableElevation=function(t,e){this.map.setTerrain("string"==typeof t?{source:t,exaggeration:e}:{source:t.getId(),exaggeration:e})},T.prototype.disableElevation=function(){this.map.setTerrain(null)},T.prototype._getMap=function(){return this.map},T.prototype._rebuildStyle=function(e){return void 0===e&&(e=!0),wm(this,void 0,void 0,function(){return _m(this,function(t){return this.styles.setStyle(this.styleOptions,e),this.imageSprite._restoreImages(),[2]})})},T.prototype._isLoaded=function(){return this.loaded},T.prototype._isReady=function(){return this.ready},T.prototype._getLocalizedStrings=function(){return this.localizedStringsPromise},T.prototype._sendRequest=function(t,e,o){var n;return(n="function"==typeof this.serviceOptions.transformRequest?this.serviceOptions.transformRequest(t,e):n)?fetch(n.url||t,{credentials:n.credentials,headers:vm(vm({},o),n.headers),method:"GET",mode:"cors"}):fetch(t,{headers:o,method:"GET",mode:"cors"})},T.prototype._substituteDomainLanguageViewAndSignInRequest=function(t,e){var o;(t.includes(ot)||t.includes(et))&&(o=new RegExp("[^{]".concat(ot,"[^}]")),t.match(o)&&(e.url=e.url.replace(ot,et)),wt.protoRegEx.test(this.serviceOptions.domain)?(o=e.url.indexOf(et),e.url=this.serviceOptions.domain+e.url.substring(o+et.length)):e.url=e.url.replace(et,this.serviceOptions.domain)),(e.url.toLocaleLowerCase().includes(this.serviceOptions.domain.toLocaleLowerCase())||e.url.toLocaleLowerCase().includes(this.serviceOptions.staticAssetsDomain.toLocaleLowerCase()))&&null!=(o=this.authentication)&&o.signRequest(e),t.includes(it)&&(e.url=e.url.replace(it,this.styleOptions.language)),t.includes(nt)&&(e.url=this.styleOptions.view?e.url.replace(nt,this.styleOptions.view):e.url.replace(nt,"").replace("&".concat(rt,"="),""))},T.prototype._setAutoResize=function(t){t?(this.resizeObserver||(this.resizeObserver=new ResizeObserver(this._resizeCallback)),this.resizeObserver.observe(this.map.getContainer())):this.resizeObserver&&this.resizeObserver.unobserve(this.map.getContainer())},T.prototype._setStyleComponents=function(a,c){var l=this;void 0===c&&(c=!0),this.removed||this.styles.definitions().then(function(t){var e,o,n=!0;if(l.styleOptions.style)try{for(var r=Om(t.configurations),i=r.next();!i.done;i=r.next()){var s=i.value;if(l.styleOptions.style===s.name){n=!1;break}}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}n&&(l.styleOptions.style=t.defaultConfiguration),l.styleOptions=a,l._rebuildStyle(c)})},T.prototype._updateGlobalDefaults=function(t){t&&(t.authOptions&&!ee&&fe(t.authOptions),t.domain&&!Kt&&ye(t.domain),t.styleDefinitionsPath&&!Yt&&me(t.styleDefinitionsPath),t.workerCount&&!$t&&ge(t.workerCount),t.maxParallelImageRequests&&!Xt&&ve(t.maxParallelImageRequests),!t.subscriptionKey&&!t["subscription-key"]||ee||be(t.subscriptionKey||t["subscription-key"]),!t.sessionId&&!t["session-id"]||te||_e(t.sessionId||t["session-id"]),t.language&&!Qt&&we(t.language),!t.userRegion&&!t.view||Vt||xe(t.userRegion||t.view))},T.prototype._generateSafeBounds=function(t){if(t){var e=S.getSouth(t),o=S.getWest(t),n=S.getNorth(t),r=S.getEast(t);if(!(isFinite(e)&&isFinite(o)&&isFinite(n)&&isFinite(r)))throw new Error("The bounds specified are invalid: [".concat(t,"]"));for(;r<o;)r+=360;return new S([o,e,r,n])}return t},T.prototype._detectHighContrast=function(){var t,e;switch(Rd.getHighContrastMode()){case"invert":case"light":t=T.Css.hcLight,e="high_contrast_light";break;case"dark":t=T.Css.hcDark,e="high_contrast_dark"}t&&this.map.getContainer().classList.add(t),e&&"road"===this.styleOptions.style&&(this.styleOptions.style=e)},T.Css={canvasContainer:"atlas-map-canvas-container",canvas:"atlas-map-canvas",container:"atlas-map",hcDark:"high-contrast-dark",hcLight:"high-contrast-light"},T);function T(t,e){var o,n,r=gm.call(this)||this;r.removed=!1,r.loaded=!1,r.ready=!1,r._resizeCallback=function(){return r.resize()},r._updateGlobalDefaults(e),r.serviceOptions=(new Xy).merge(e),r.styleOptions=(new Hy).merge(e),r.trafficOptions=new Ka,r.styles=new hm(r,r.serviceOptions),r.serviceOptions.authOptions.subscriptionKey&&(r.serviceOptions.authOptions.subscriptionKey=encodeURIComponent(r.serviceOptions.authOptions.subscriptionKey)),o=r.serviceOptions.authOptions.clientId||(r.serviceOptions.authOptions.subscriptionKey?r.serviceOptions.authOptions.subscriptionKey.replace(/.(?=.{3,}$)/g,"*"):"invalid-setting"),r.insights&&r.insights.setAuthenticatedUserContext(r.serviceOptions.sessionId,o),arguments[2]&&"ENVIRONMENT"in window&&window.ENVIRONMENT.hmr?(n=arguments[2],r.ready=!0,r.loaded=!0):(o={antialias:r.styleOptions.antialias,attributionControl:!1,container:t,fadeDuration:r.serviceOptions.fadeDuration,localIdeographFontFamily:r.serviceOptions.localIdeographFontFamily,preserveDrawingBuffer:r.styleOptions.preserveDrawingBuffer,refreshExpiredTiles:r.serviceOptions.refreshExpiredTiles,renderWorldCopies:r.styleOptions.renderWorldCopies,trackResize:!1,transformRequest:function(t,e){var o={url:t};return"Tile"===e||"Source"===e?(t.includes(ot)&&r.insights&&r.insights.trackEvent({name:"TileLoad"}),r._substituteDomainLanguageViewAndSignInRequest(t,o)):"Style"!==e&&"SpriteJSON"!==e&&"SpriteImage"!==e&&"Glyphs"!==e||r.styles._transformStyleRequest(t,o),r.serviceOptions.transformRequest&&Ba(o,r.serviceOptions.transformRequest(o.url,e)),o}},n=new D.Map(o));try{r.map=n,r.controls=new yf(r),r.events=new Of(r),r.imageSprite=new kf(r),r.layers=new Bf(r),r.markers=new Pf(r),r.sources=new Uf(r),r.popups=new Zf(r),r.indicators=new fm(r),r.map.getContainer().classList.add(T.Css.container),r.map.getCanvasContainer().classList.add(T.Css.canvasContainer),r.map.getCanvas().classList.add(T.Css.canvas),r._detectHighContrast(),r.copyrightControl=new Wd({showFeedbackLink:r.styleOptions.showFeedbackLink,showLogo:r.styleOptions.showLogo,customAttribution:r.styleOptions.customAttribution}),r.controls.add(r.copyrightControl,{position:u.ControlPosition.NonFixed}),r.logoControl=new Qd({showLogo:r.styleOptions.showLogo}),r.controls.add(r.logoControl,{position:u.ControlPosition.BottomLeft});var i=r.authentication?r.authentication.initialize():Promise.resolve();if(r.removed)return r;var s=function(){r.loaded=!0,r.map.off("load",s)},a=(r.map.on("load",s),function(){r.ready=!0,r.map.off("styledata",a),r.events.invoke("ready",{map:r,type:"ready"})});r.map.on("styledata",a),r._setAutoResize(r.styleOptions.autoResize),r.map.showTileBoundaries=r.styleOptions.showTileBoundaries,r.localizedStringsPromise=Ct.getStrings(r.styleOptions.language),i.then(function(){return r.styles.definitions()}).then(function(t){if(!r.removed){if(r.authentication&&!r.authentication.getToken())throw new Error("AuthenticationManager finished initializing, but no token is available");r.serviceOptions["enable-accessibility"]&&r.accessibleMapDelegate.addToMap(),r._setStyleComponents(r.styleOptions),r.copyrightDelegate&&r.copyrightDelegate.addToMap()}}).catch(function(t){t=t instanceof Error?t:new Error(t);r.events.invoke("error",{map:r,type:"error",error:t})}),r.setCamera(vm(vm({minZoom:1},e),{type:"jump",duration:0})),r.flowDelegate=new rf(r),r.accessibleMapDelegate=new nf(r),r.userInteractionDelegate=new hf(r,e),r.userInteractionDelegate.addToMap(),r.copyrightControl.setOptions({copyrightMessage:r.copyrightControl.getDefaultAttributions().join(", ")})}catch(t){throw t}return r}var Sm=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Cm=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},ze=(z.applyTemplate=function(e,o){var n,r,t,i=this,s=document.createElement("div");return s.classList.add(z.Css.template),e&&("boolean"!=typeof(o=o||{}).singleDescription&&(o.singleDescription=!0),o.sandboxContent="boolean"!=typeof o.sandboxContent||o.sandboxContent,o.title&&"string"==typeof o.content&&(o.content.includes("{title}")||o.content.includes("{name}"))||(e.title?o.title="{title}":e.name&&(o.title="{name}")),"boolean"!=typeof o.detectHyperlinks&&(o.detectHyperlinks=!0),"boolean"!=typeof o.parsePropertyPaths&&(o.parsePropertyPaths=!0),o.textColor&&(s.style.color=o.textColor),o.fillColor&&(s.style.backgroundColor=o.fillColor),o.title&&((t=this._applyStringTemplate(e,o.title,o)).innerText=t.textContent||t.innerText||"",this._appendChild(s,t,z.Css.title)),(n=document.createElement("div")).classList.add(z.Css.content),Array.isArray(o.content)?0<o.content.length&&o.content[0].propertyPath?this._appendChild(n,this._generateContent(e,o.content,o),z.Css.item):o.content.forEach(function(t){i._appendChild(n,i._generateContent(e,t,o),z.Css.item)}):(r=0,t=void(e.description&&Object.keys(e).forEach(function(t){i._ignoreProperty(t,e[t])||r++})),1===r||o.singleDescription&&e.description||2===r&&e.Snippet?(t=document.createElement("div")).innerHTML=e.description:t=this._generateContent(e,o.content,o),this._appendChild(n,t,z.Css.item)),""!==n.innerHTML)&&(o.sandboxContent?s.appendChild(z._createSandboxedIframe(n,o)):s.appendChild(n)),s},z._createSandboxedIframe=function(t,e){var o=document.createElement("iframe"),t=(o.sandbox.add("allow-popups"),t.innerHTML),n=!1,r=100,i=550,s=10,a=(document.body.scrollWidth<=340&&(i=300,r=50),t.split(/<(tr|div|br|li|h[0-9]|p>)/)),c=Math.max.apply(Math,Cm([],Sm(a.map(function(t){return t.replace(/<[a-zA-Z0-9\s=\/]+>/g,"").length})),!1))-1,l=Math.ceil(3.5*c),c=(l<i&&(i=l,r=c),t.includes("<img")||t.includes("<video")?(n=!0,o.width="550px"):(l=-1<t.indexOf(z.Css.table)?25:20,s+=Math.max(.5*a.length*l,Math.ceil(t.replace(/<[a-zA-Z0-9\s=\/]+>/g,"").length/r)*l)),o.width=i+"px",o.height=n||280<s?"280px":s+"px",e.textColor?"color:".concat(e.textColor,";"):""),a=e.fillColor?"background-color:".concat(e.fillColor,";"):"",r='<html><head><title></title><meta charset="utf-8" /><meta http-equiv="x-ua-compatible" content="IE=Edge" />'+'<link rel="stylesheet" href="'.concat(z._cssUrl,'" type="text/css"/>')+"<style>html, body{margin:0;padding:0;".concat(c).concat(a,"}</style></head>")+'<body><div class="'.concat(z.Css.template,'" style="padding:0;width:').concat(i-20,'px">').concat(t,"</div></body></html>");return void 0===o.srcdoc?o.src="data:text/html;charset=utf-8,"+encodeURI(r):o.srcdoc=r,o},z._appendChild=function(t,e,o){e&&(o&&(e.className=(e.className?e.className+" ":"")+o),t.appendChild(e))},z._generateContent=function(t,e,o){return e?Array.isArray(e)?this._generatePropertyInfoTable(t,e,o):this._applyStringTemplate(t,e,o):(e=this._generateDynamicTableHtml(t,null,o))?((t=document.createElement("div")).innerHTML=e,t):null},z._applyStringTemplate=function(t,e,o){if(e){for(var n,r,i=e,s=this._placeholderRx.exec(e);s;)2<=s.length&&(n=this._getPropertyValue(t,s[1],o),i=i.replace(s[0],n)),s=this._placeholderRx.exec(e);if(i)return(i=i.trim()).includes("<")&&(i=i.replace(/[\r\n]+/g,"<br/>")),(r=document.createElement("div")).innerHTML=i,r}return null},z._getPropertyValue=function(t,e,o,n){var r=o.parsePropertyPaths?e.split("/"):[e],i=r.length;if(0<i&&t){var s=r[0],a=t[s];if(o.detectHyperlinks&&"link"===e&&(!n||n.hyperlinkFormat)){var c,l,u,p=[];if(Array.isArray(a)?a.forEach(function(t){t.href?p.push(t):"string"==typeof t&&p.push({href:t})}):a.href&&p.push(a),0<p.length)return n&&n.hyperlinkFormat?c=n.hyperlinkFormat:o&&o.hyperlinkFormat&&(c=o.hyperlinkFormat),l=c&&c.target?c.target:"_blank",u=[],p.forEach(function(t){t.title||c&&c.label||!t.rel||u.push(t.rel," - "),u.push('<a href="',t.href,'" target="',l,'">'),t.title?u.push(t.title):c&&c.label?u.push(c.label):u.push(t.href),u.push("</a>","<br/>")}),u.pop(),u.join("")}if(null!=a){for(var h=void 0,h=1;h<i&&(a=a[r[h]],s=r[h],null!=a);h++);if(h===i&&null!=a){t=void 0;if((t=void 0!==a.value?a.value:a)instanceof Date)return n&&n.dateFormat?t.toLocaleString(void 0,n.dateFormat):o.dateFormat?t.toLocaleString(void 0,o.dateFormat):t.toISOString();if("object"==typeof t)return(d=this._generateDynamicTableHtml(t,r.slice(1),o))||"";if("number"==typeof t){if(n){if(n.dateFormat)return new Date(t).toLocaleString(void 0,n.dateFormat);if(n.numberFormat)return t.toLocaleString(void 0,n.numberFormat)}else if(/(timestamp|date)/gi.test(s))return new Date(t).toISOString();return t.toLocaleString(void 0,o.numberFormat)}if("string"==typeof t&&""!==t&&!/[\n\r<>\s]/g.test(t)&&(o.detectHyperlinks||n&&n.hyperlinkFormat)){var d,t=t.trim(),e=this._isUrlRx.test(t)||n&&n.hyperlinkFormat,f=this._isImageUrlRx.test(t)&&(e||t.startsWith("data:image")),y=this._emailRx.test(t);if(e||f||y)return e=void 0,d=void(n&&n.hyperlinkFormat?e=n.hyperlinkFormat:o&&o.hyperlinkFormat&&(e=o.hyperlinkFormat)),d=e&&e.target?' target="'.concat(e.target,'"'):' target="_blank"',n="".concat(e&&e.label?e.label:t),e&&e.scheme?t=e.scheme+t:y&&(t="mailto:"+t),o=e&&e.label?' alt="'.concat(e.label,'"'):"",(e&&e.isImage||f)&&(n='<img src="'.concat(t,'" style="max-width:100%"').concat(o,'"/>')),'<a href="'.concat(t,'"').concat(d,">").concat(n,"</a>")}return t.toString()}}}return""},z._generatePropertyInfoTable=function(o,t,n){var r,i;return o&&t&&0<t.length?((r=[]).push('<table class="'.concat((i=this).Css.table,'">')),t.forEach(function(t){var e=i._getPropertyValue(o,t.propertyPath,n,t);t.hideLabel?r.push('<tr><td colspan="2">',e,"</td></tr>"):(t=t.label||t.propertyPath.split("/")[0],r.push("<tr><th>",t,"</th><td>",e,"</td></tr>"))}),r.push("</table>"),(t=document.createElement("div")).innerHTML=r.join(""),t):null},z._generateDynamicTableHtml=function(e,t,o){var n,r,i,s,a=this;return!e||((n=[]).push('<table class="'.concat((r=this).Css.table,'">')),i=t&&0<t.length?t.join("/")+"/":"",s=0,Object.keys(e).forEach(function(t){a._ignoreProperty(t,e[t])||(n.push("<tr><th>",t,"</th><td>",r._getPropertyValue(e,i+t,o),"</td></tr>"),s++)}),0===s)?null:(n.push("</table>"),n.join(""))},z._ignoreProperty=function(t,e){switch(t){case"title":case"name":case"base":case"popupTemplate":case"anchor":case"icon":case"image":case"imageUrl":case"rotation":case"color":case"size":case"offset":case"strokeColor":case"strokeWidth":case"strokeOpacity":case"subType":case"fillColor":case"fillOpacity":case"visibility":case"visible":return!0;default:if(0===t.indexOf("_")||null==e||""===e)return!0}return!1},z._placeholderRx=/\{([a-zA-Z0-9_\/\s]+)\}/gi,z._isUrlRx=/^(http|https|ftp|tel|mailto):\/\//i,z._isImageUrlRx=/(^data:image|.png$|.jpg$|.jpeg$|.gif$|.bmp$|.svg|.tif|.tiff$)/i,z._emailRx=/^[^\.\s@:](?:[^\s@:]*[^\s@:\.])?@[^\.\s@]+(?:\.[^\.\s@]+)*$/,z._cssUrl=new wt({domain:X,path:"sdk/javascript/mapcontrol/".concat(Mt.getEndpointVersion(),"/atlas.min.css")}).toString(),z.Css={template:"azure-maps-control-popup-template",title:"azure-maps-control-popup-template-title",content:"azure-maps-control-popup-template-content",item:"azure-maps-control-popup-template-content-item",table:"azure-maps-control-popup-template-table"},z);function z(){this.detectHyperlinks=!0,this.parsePropertyPaths=!0}u.HtmlMarker=Dd,u.Map=jn,u.Pixel=Hc,u.Popup=Ad,u.PopupTemplate=ze,u.Shape=x,u._enableRTLTextPlugin=function(){var t=new wt({domain:X,path:"sdk/javascript/mapcontrol/".concat(Mt.getEndpointVersion(),"/mapbox-gl-rtl-text.min.js")});D.setRTLTextPlugin(t.toString(),!0).catch(function(t){t&&console.warn(t)})},u._getAssetDomain=function(){return $},u._getDomain=function(){return Zt},u._hasMaxParallelImageRequests=ke,u._hasSetAuthenticationOptions=Se,u._hasSetDomain=Ce,u._hasSetLanguage=Ae,u._hasSetSessionId=Me,u._hasSetStyleDefinitionsPath=Pe,u._hasSetStyleDefinitionsVersion=function(){return Jt},u._hasSetView=Ee,u._hasWorkerCount=Le,u.addImageTemplate=function(t,e,o){!o&&Te[t.toLowerCase()]||(Te[t.toLowerCase()]=e)},u.addProtocol=function(t,e){D.addProtocol(t,e)},u.clearPrewarmedResources=function(){D.clearPrewarmedResources()},u.control=o,u.data=Kr,u.getAllImageTemplateNames=function(){return Object.keys(Te)},u.getAuthenticationOptions=oe,u.getDomain=re,u.getImageTemplate=Oe,u.getLanguage=ue,u.getMaxParallelImageRequests=le,u.getSessionId=pe,u.getStaticAssetsDomain=ne,u.getStyleAPIVersion=ae,u.getStyleDefinitionsPath=ie,u.getStyleDefinitionsVersion=se,u.getSubscriptionKey=he,u.getUserRegion=function(){return Bt},u.getVersion=function(){return Mt.getFullVersion()},u.getView=de,u.getWorkerCount=ce,u.internal=U,u.isSupported=function(t){return!Lt.isIE()},u.layer=xi,u.math=$n,u.prewarm=function(){D.prewarm()},u.removeProtocol=function(t){D.removeProtocol(t)},u.setAuthenticationOptions=fe,u.setDomain=ye,u.setLanguage=we,u.setMaxParallelImageRequests=ve,u.setSessionId=_e,u.setStyleAPIVersion=function(t){Wt=t},u.setStyleDefinitionsPath=me,u.setStyleDefinitionsVersion=function(t){Ut=t,Jt=!0},u.setSubscriptionKey=be,u.setUserRegion=xe,u.setView=function(t){Bt=t,Vt=!0},u.setWorkerCount=ge,u.source=Ao});
|
|
55
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("azuremaps-maplibre-gl")):"function"==typeof define&&define.amd?define(["exports","azuremaps-maplibre-gl"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).atlas=t.atlas||{},t.maplibregl)}(this,function(u,D){"use strict";var R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function B(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function F(o){var e,n;return o.__esModule?o:("function"==typeof(e=o.default)?(n=function t(){return this instanceof t?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)}).prototype=e.prototype:n={},Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(o).forEach(function(t){var e=Object.getOwnPropertyDescriptor(o,t);Object.defineProperty(n,t,e.get?e:{enumerable:!0,get:function(){return o[t]}})}),n)}for(var N,Z,q={exports:{}},H=F(Object.freeze({__proto__:null,default:{}})),U=q,W=0,G=[],V=0;V<256;V++)G[V]=(V+256).toString(16).substr(1);function K(){t=16,(!N||Y.BUFFER_SIZE<W+t)&&(W=0,N=Y.randomBytes(Y.BUFFER_SIZE));var t=N.slice(W,W+=t);return t[6]=15&t[6]|64,t[8]=63&t[8]|128,t}function Y(){var t=K();return G[t[0]]+G[t[1]]+G[t[2]]+G[t[3]]+"-"+G[t[4]]+G[t[5]]+"-"+G[t[6]]+G[t[7]]+"-"+G[t[8]]+G[t[9]]+"-"+G[t[10]]+G[t[11]]+G[t[12]]+G[t[13]]+G[t[14]]+G[t[15]]}Y.BUFFER_SIZE=4096,Y.bin=K,Y.clearBuffer=function(){N=null,W=0},Y.test=function(t){return"string"==typeof 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)},"undefined"!=typeof crypto?Z=crypto:"undefined"!=typeof window&&void 0!==window.msCrypto&&(Z=window.msCrypto),Z=Z||H,(U.exports=Y).randomBytes=function(){if(Z){if(Z.randomBytes)return Z.randomBytes;if(Z.getRandomValues)return"function"!=typeof Uint8Array.prototype.slice?function(t){t=new Uint8Array(t);return Z.getRandomValues(t),Array.from(t)}:function(t){t=new Uint8Array(t);return Z.getRandomValues(t),t}}return function(t){for(var e=[],o=0;o<t;o++)e.push(Math.floor(256*Math.random()));return e}}();var J=B(q.exports),$="atlas.microsoft.com",X="atlas.microsoft.com",H="styling",U="2023-01-01",Q="api-version",tt="Authorization",et="{{azMapsDomain}}",ot="{azMapsDomain}",nt="{{azMapsView}}",rt="view",it="{{azMapsLanguage}}",st="{{azMapsStylingPath}}",at="{{azMapsStylePath}}",ct="styling",lt="styles",q="2.0",ut="x-ms-client-id",pt=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},t=(ht.prototype.merge=function(){for(var e,t,o,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];try{for(var i=pt(n),s=i.next();!s.done;s=i.next()){var a=s.value;if(a)for(var c in a)a.hasOwnProperty(c)&&this.hasOwnProperty(c)&&(void 0!==a[c]&&null!=a[c]?this[c]instanceof ht?this[c].merge(a[c]):this[c]=a[c]:(o=o||new(Object.getPrototypeOf(this).constructor),this[c]=o[c]))}}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=i.return)&&t.call(i)}finally{if(e)throw e.error}}return this},ht);function ht(){}var dt,ft,yt=window&&window.__extends||(dt=function(t,e){return(dt=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}dt(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),mt=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},gt=(yt(vt,ft=t),vt);function vt(){var t=null!==ft&&ft.apply(this,arguments)||this;return t.domain=void 0,t.headers={},t.path="",t.protocol="https",t.queryParams={},t.subdomain="",t}_t.prototype.get=function(){return fetch(this.toString(),{method:"GET",mode:"cors",headers:new Headers(this.options.headers)}).then(function(t){if(t.ok)return t.json();throw new Error("HTTP ".concat(t.status,": ").concat(t.statusText))})},_t.prototype.toString=function(){var t=this,e=Object.entries(t.options.queryParams).map(function(t){var t=mt(t,2),e=t[0],t=t[1];return"".concat(e,"=").concat(t)}).join("&"),o=[],n=t.options.path||"";return _t.protoRegEx.test(n)?o.push(n):(t.options.domain&&(_t.protoRegEx.test(t.options.domain)||(o.push("".concat(t.options.protocol,"://")),o.push(t.options.subdomain?"".concat(t.options.subdomain,"."):"")),o.push(t.options.domain)),o.push(t.options.path?"/".concat(n):"")),o.push(e?"?".concat(e):""),o.join("")},_t.protoRegEx=new RegExp(/^(((file|http|https):\/\/)|blob:)/i);var wt=_t;function _t(t){this.options=(new gt).merge(t)}xt.parse=function(t){var e=(t=t.toLowerCase()).lastIndexOf("-");return-1!==e?{code:t,language:t.substring(0,e),region:t.substring(e+1)}:{code:t,language:t}};var bt=xt;function xt(){}var Ot={localizationsPath:"locs/mapcontrol/2019-3-12",sensitiveUserRegions:["il","kr","pk","in","cn","ar","bh","eg","jo","sa","kw","om","qa","ma","ae"],locales:{defaultLanguage:{defaultRegion:{code:"NGT",strings:"en/resource.json"},latn:{code:"NGT-Latn",strings:"en/resource.json"}},ar:{defaultRegion:{code:"ar",strings:"ar-sa/resource.json"}},bg:{defaultRegion:{code:"bg-BG",strings:"bg-bg/resource.json"}},cs:{defaultRegion:{code:"cs-CZ",strings:"cs-cz/resource.json"}},da:{defaultRegion:{code:"da-DK",strings:"da-dk/resource.json"}},de:{defaultRegion:{code:"de-DE",strings:"de-de/resource.json"}},el:{defaultRegion:{code:"el-GR",strings:"el-gr/resource.json"}},en:{defaultRegion:{code:"en",strings:"en/resource.json"},us:{code:"en-US",strings:"en/resource.json"},au:{code:"en-AU",strings:"en/resource.json"},gb:{code:"en-GB",strings:"en/resource.json"},nz:{code:"en-NZ",strings:"en/resource.json"}},es:{defaultRegion:{code:"es-ES",strings:"es-es/resource.json"},mx:{code:"es-MX",strings:"es-mx/resource.json"}},fi:{defaultRegion:{code:"fi-FI",strings:"fi-fi/resource.json"}},fr:{defaultRegion:{code:"fr-FR",strings:"fr-fr/resource.json"}},hu:{defaultRegion:{code:"hu-HU",strings:"hu-hu/resource.json"}},id:{defaultRegion:{code:"id-ID",strings:"id-id/resource.json"}},it:{defaultRegion:{code:"it-IT",strings:"it-it/resource.json"}},ko:{defaultRegion:{code:"ko-KR",strings:"ko-kr/resource.json"}},lt:{defaultRegion:{code:"lt-LT",strings:"lt-lt/resource.json"}},ms:{defaultRegion:{code:"ms-MY",strings:"ms-my/resource.json"}},nb:{defaultRegion:{code:"nb-NO",strings:"nb-no/resource.json"}},nl:{defaultRegion:{code:"nl-NL",strings:"nl-nl/resource.json"}},pl:{defaultRegion:{code:"pl-PL",strings:"pl-pl/resource.json"}},pt:{defaultRegion:{code:"pt-PT",strings:"pt-pt/resource.json"},br:{code:"pt-BR",strings:"pt-br/resource.json"}},ru:{defaultRegion:{code:"ru-RU",strings:"ru-ru/resource.json"}},sk:{defaultRegion:{code:"sk-SK",strings:"sk-sk/resource.json"}},sl:{defaultRegion:{code:"sl-SL",strings:"sl-sl/resource.json"}},sv:{defaultRegion:{code:"sv-SE",strings:"sv-se/resource.json"}},th:{defaultRegion:{code:"th-TH",strings:"th-th/resource.json"}},tr:{defaultRegion:{code:"tr-TR",strings:"tr-tr/resource.json"}},zh:{defaultRegion:{code:"zh",strings:"en/resource.json"}},"zh-hans":{defaultRegion:{code:"zh-Hans",strings:"zh-cn/resource.json"},cn:{code:"zh-Hans-CN",strings:"zh-cn/resource.json"}},"zh-hant":{defaultRegion:{code:"zh-Hant",strings:"en/resource.json"},tw:{code:"zh-Hant-TW",strings:"zh-tw/resource.json"}}}},St=function(){this.Unknown="Unknown",this.Accident="Accident",this.Fog="Fog",this.Danger="Danger",this.Rain="Rain",this.Ice="Ice",this.Jam="Jam",this.LaneClosed="Lane Closed",this.RoadClosed="Road Closed",this.RoadWorks="Road Works",this.Wind="Wind",this.Flood="Flood",this.Detour="Detour"},Ct=(Pt.getCode=function(t){0===t.localeCompare("auto",void 0,{sensitivity:"base"})&&(t=navigator.language);var e=bt.parse(t);return-1===Ot.sensitiveUserRegions.indexOf(e.region)?this.getLocaleData(e).code:t},Pt.getStrings=function(t){t=this.getLocaleData(t);return Ot.locales.defaultLanguage.defaultRegion.code===t.code?new Promise(function(t){t(new St)}):new wt({domain:X,path:"".concat(Ot.localizationsPath,"/").concat(t.strings)}).get().then(function(t){return t},function(){return new St})},Pt.getLocaleData=function(t){if("string"==typeof t&&(t=bt.parse(t)),Ot.locales[t.code])return Ot.locales[t.code].defaultRegion;var e;if(Ot.locales[t.language])e=Ot.locales[t.language];else{if(-1!==t.language.indexOf("-"))return this.getLocaleData(t.language);e=Ot.locales.defaultLanguage}return t.region&&e[t.region]?e[t.region]:e.defaultRegion},Pt);function Pt(){}kt.getEdgeOrIEVersion=function(){var t=window.navigator.userAgent,e=t.indexOf("MSIE ");return 0<e?parseInt(t.substring(e+5,t.indexOf(".",e)),10):0<t.indexOf("Trident/")?(e=t.indexOf("rv:"),parseInt(t.substring(e+3,t.indexOf(".",e)),10)):0<(e=t.indexOf("Edge/"))?parseInt(t.substring(e+5,t.indexOf(".",e)),10):-1},kt.isEdgeOrIE=function(){return-1!==this.getEdgeOrIEVersion()},kt.isIE=function(){var t=this.getEdgeOrIEVersion();return-1!==t&&t<=11};var Lt=kt;function kt(){}var At="3.6.1",Mt=(Et.getFullVersion=function(){return At},Et.getEndpointVersion=function(){var t=At.indexOf(".");return-1===(t=At.indexOf(".",t+1))?At:At.substring(0,t)},Et);function Et(){}var jt,It,yt=window&&window.__extends||(jt=function(t,e){return(jt=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}jt(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Tt=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},zt=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Dt=(u.AuthenticationType=void 0,(ze=u.AuthenticationType||(u.AuthenticationType={})).subscriptionKey="subscriptionKey",ze.aad="aad",ze.anonymous="anonymous",ze.sas="sas",yt(Rt,It=t),Rt.prototype.setSubscriptionKey=function(t){this.authType=u.AuthenticationType.subscriptionKey,this.subscriptionKey=t},Rt.prototype.setAadProperties=function(t,e,o,n,r){this.authType=u.AuthenticationType.aad,this.authContext=r||this.authContext,this.aadInstance=n||this.aadInstance,this.clientId=t,this.aadAppId=e,this.aadTenant=o},Rt.prototype.setTokenCallbackFunction=function(t){this.authType=u.AuthenticationType.anonymous,this.getToken=t},Rt.prototype.setSasCallbackFunction=function(t){this.authType=u.AuthenticationType.sas,this.getToken=t},Rt.prototype.merge=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var o=It.prototype.merge.apply(this,zt([],Tt(t),!1));return o.authType===u.AuthenticationType.subscriptionKey?o.authContext=o.aadAppId=o.getToken=void 0:o.authType===u.AuthenticationType.aad?o.subscriptionKey=o.getToken=void 0:o.authType===u.AuthenticationType.anonymous?o.subscriptionKey=o.authContext=o.aadAppId=void 0:o.authType===u.AuthenticationType.sas&&(o.authContext=o.subscriptionKey=o.aadAppId=void 0),o},Rt);function Rt(){var t=null!==It&&It.apply(this,arguments)||this;return t.authType=void 0,t.subscriptionKey=void 0,t.clientId=void 0,t.aadAppId=void 0,t.aadTenant=void 0,t.aadInstance=void 0,t.getToken=void 0,t.sasToken=void 0,t.authContext=void 0,t}var Bt;var Ft="NGT",Nt=J(),Zt=$,qt=X,Ht=H,Ut=U,Wt=q,Gt=new Dt,Vt=!1,Kt=!1,Yt=!1,Jt=!1,$t=!1,Xt=!1,Qt=!1,te=!1,ee=!1;function oe(){return Object.assign({},Gt)}function ne(){return qt}function re(){return Zt}function ie(){return Ht}function se(){return Ut}function ae(){return Wt}function ce(){return D.getWorkerCount()}function le(){return D.getMaxParallelImageRequests()}function ue(){return Ft}function pe(){return Nt}function he(){return Gt.authType===u.AuthenticationType.subscriptionKey?Gt.subscriptionKey:void 0}function de(){return Bt}function fe(t){Gt=(new Dt).merge(Gt,t),ee=!0}function ye(t){Zt=t,Kt=!0}function me(t){Ht=t,Yt=!0}function ge(t){0<t&&(D.setWorkerCount(t),$t=!0)}function ve(t){0<t&&(D.setMaxParallelImageRequests(t),Xt=!0)}function we(t){Ft=Ct.getCode(t),Qt=!0}function _e(t){Nt=t,te=!0}function be(t){Gt.setSubscriptionKey(t),ee=!0}function xe(t){Bt=t,Vt=!0}function Oe(t,e){if(e=Math.abs(e||1),"string"==typeof t&&Te[t.toLowerCase()]){for(var o=Te[t.toLowerCase()],n=/calc\(([0-9.]+)[px]*\s*\*\s*\{scale\}\)/gi,r=o,i=n.exec(o);i;)r=r.replace(i[0],parseFloat(i[1])*e+""),i=n.exec(o);return r=r.replace("{scale}",e+"")}throw new Error("Invalid templateName.")}function Se(){return ee}function Ce(){return Kt}function Pe(){return Yt}function Le(){return $t}function ke(){return Xt}function Ae(){return Qt}function Me(){return te}function Ee(){return Vt}function _(t){var e=document.createElement("span");return e.innerText=t,e.classList.add("tooltiptext"),-1!=navigator.userAgent.indexOf("Edg")?e.classList.add("edge"):-1!=navigator.userAgent.indexOf("Chrome")?e.classList.add("chrome"):-1!=navigator.userAgent.indexOf("Safari")?e.classList.add("safari"):-1!=navigator.userAgent.indexOf("Firefox")&&e.classList.add("firefox"),-1!=navigator.userAgent.indexOf("Windows")?e.classList.add("win"):-1!=navigator.userAgent.indexOf("Macintosh")&&e.classList.add("mac"),e}function b(r,i,s){function t(t){var e=i.getBoundingClientRect(),o=r.getBoundingClientRect(),n=e.x+o.width>window.innerWidth?window.innerWidth-o.width:e.x,o=e.y+e.height+o.height+4>window.innerHeight?e.y-o.height-4:e.y+e.height+4;s&&i.parentElement&&(e=i.parentElement?i.parentElement.getBoundingClientRect():null,r.style.position="absolute",n-=e.x,o-=e.y),r.style.transform="translate(".concat(n,"px, ").concat(o,"px)"),r.style.display="block"}void 0===s&&(s=!1),i.addEventListener("mouseover",t),i.addEventListener("focusin",t),i.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||"block"!==r.style.display||(t.stopPropagation(),r.style.display="none")})}var je,Ie,Te={marker:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(27 * {scale})" height="calc(39 * {scale})" viewBox="-1 -1 26 38"><path d="M12.25.25a12.254 12.254 0 0 0-12 12.494c0 6.444 6.488 12.109 11.059 22.564.549 1.256 1.333 1.256 1.882 0C17.762 24.853 24.25 19.186 24.25 12.744A12.254 12.254 0 0 0 12.25.25Z" style="fill:{color};stroke:{secondaryColor};stroke-width:1"/><text x="12.5" y="17.5" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(39 * {scale})" viewBox="-1 -1 27 38"><path d="M12.25.25a12.254 12.254 0 0 0-12 12.494c0 6.444 6.488 12.109 11.059 22.564.549 1.256 1.333 1.256 1.882 0C17.762 24.853 24.25 19.186 24.25 12.744A12.254 12.254 0 0 0 12.25.25Z" style="fill:{color};stroke:{secondaryColor};stroke-width:2"/><text x="12.5" y="18.5" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-circle":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(39 * {scale})" viewBox="-1 -1 27 38"><path d="M12.25.25a12.254 12.254 0 0 0-12 12.494c0 6.444 6.488 12.109 11.059 22.564.549 1.256 1.333 1.256 1.882 0C17.762 24.853 24.25 19.186 24.25 12.744A12.254 12.254 0 0 0 12.25.25Z" style="fill:{color};stroke:{secondaryColor};stroke-width:1"/><circle cx="12.5" cy="12.5" r="9" fill="{secondaryColor}"/><text x="12" y="17.5" style="font-size:14px;fill:#000;text-anchor:middle">{text}</text></svg>',pin:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(24 * {scale})" height="calc(28 * {scale})" viewBox="0 0 24 28"><path d="m11.988 16.615a5.15 5.15 0 0 1-2.268-.525 4.909 4.909 0 0 1-2.805-4.442 5.019 5.019 0 0 1 5.072-4.936h.012a5.03 5.03 0 0 1 5.085 4.961 4.907 4.907 0 0 1-.549 2.224 5.114 5.114 0 0 1-4.548 2.718zm0-8.06a3.173 3.173 0 0 0-3.226 3.099 3.081 3.081 0 0 0 1.77 2.782 3.299 3.299 0 0 0 4.365-1.386 3.049 3.049 0 0 0 .342-1.381 3.184 3.184 0 0 0-3.239-3.114h-.012z" fill="{secondaryColor}"/><path d="m11.999.922a10.908 10.908 0 0 0-11.076 10.732 10.639 10.639 0 0 0 4.418 8.598l6.658 6.464 6.658-6.463a10.537 10.537 0 0 0 2.198-15.041 11.182 11.182 0 0 0-8.856-4.289zm1.873 14.341a4.221 4.221 0 0 1-5.589-1.789 3.945 3.945 0 0 1-.445-1.8 4.164 4.164 0 0 1 8.323-.037 4.028 4.028 0 0 1-2.289 3.626Z" fill="{color}"/><path d="m11.999 28-7.256-7.044a11.611 11.611 0 0 1-4.743-9.303 11.844 11.844 0 0 1 11.988-11.652.102 .102 0 0 1 .02 0 12.164 12.164 0 0 1 9.577 4.647 11.357 11.357 0 0 1 2.299 8.614 11.521 11.521 0 0 1-4.63 7.695zm-.01-26.157a9.997 9.997 0 0 0-10.143 9.812 9.769 9.769 0 0 0 4.04 7.853l.099.083 6.014 5.838 6.113-5.922a9.7 9.7 0 0 0 3.945-6.505 9.533 9.533 0 0 0-1.933-7.229 10.305 10.305 0 0 0-8.116-3.931h-.021zm.021 14.772a5.11 5.11 0 0 1-4.547-2.718 4.868 4.868 0 0 1 .932-5.743 5.118 5.118 0 0 1 3.58-1.46h.024a5.031 5.031 0 0 1 5.084 4.938 4.92 4.92 0 0 1-2.805 4.457h0a5.152 5.152 0 0 1-2.269.525zm-.011-8.079h-.015a3.277 3.277 0 0 0-2.295.933 3.029 3.029 0 0 0-.587 3.58 3.297 3.297 0 0 0 4.364 1.386h0a3.092 3.092 0 0 0 1.772-2.795 3.185 3.185 0 0 0-3.239-3.105z" fill="{secondaryColor}"/><text x="12" y="17" style="font-size:14px;fill:#000;text-anchor:middle">{text}</text></svg>',"pin-round":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(25 * {scale})" height="calc(25 * {scale})" viewBox="0 0 25 25"><g transform="translate(0 1)"><circle cx="12.25" cy="11.5833" r="11" fill="{color}"/><path d="m12.25 23.583a12 12 0 1 1 12-12 12 12 0 0 1-12 12zm0-22a10 10 0 1 0 10 10 10 10 0 0 0-10-10z" fill="{secondaryColor}"/><circle cx="12.25" cy="11.5833" r="4.2386" fill="{secondaryColor}"/></g><text x="12.5" y="17" style="font-size:14px;fill:#000;text-anchor:middle">{text}</text></svg>',"marker-flat":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(27 * {scale})" height="calc(42.8 * {scale})" viewBox="0 0 1600 2570"><g fill="{color}"><path d="M691 2419c-409-575-641-1086-683-1504-10-106-10-136 5-224 31-188 105-330 241-458 129-124 270-190 453-214 69-9 113-10 182-1 373 46 655 326 703 698 40 308-120 801-424 1309-134 224-348 535-369 535-4 0-53-63-108-141z"/></g><g fill="rgba(0,0,0,0.15)" style="transform:scale(-1,1);transform-origin:center"><path d="M691 2419c-407-571-639-1083-682-1498-14-139-3-249 37-371 69-208 254-402 459-481 68-27 217-59 271-59h24v160 180 940 635c0 349-2 635-5 635-2 0-49-63-104-141z"/></g><circle cx="800" cy="800" r="600" fill="{secondaryColor}"/><text x="800" y="1100" style="font-size:800px;fill:#000;text-anchor:middle">{text}</text></svg>',"marker-arrow":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(25.47 * {scale})" height="calc(35.18 * {scale})" viewBox="0 0 4330 5980"><g fill="{color}"><path d="m2080 5969c-49-20-93-63-115-113-25-55-1928-5486-1953-5573-40-138 67-282 210-283 36 0 246 73 987 345 518 190 947 345 955 345 8 0 438-155 955-345 615-226 954-345 979-345 87 0 165 47 204 123 46 91 107-95-957 2942-537 1535-986 2805-997 2823-11 18-43 46-72 62-41 24-62 30-111 29-33 0-71-5-85-10z"/></g><g fill="{secondaryColor}"><path d="m2200 1600c-36 10-83 2-484-84-243-53-451-94-461-91-11 4-22 18-25 31-5 19 114 371 436 1292 244 697 448 1273 454 1281 19 24 50 30 71 12z"/><path d="m2200 1600c-36 10-83 2-484-84-243-53-451-94-461-91-11 4-22 18-25 31-5 19 114 371 436 1292 244 697 448 1273 454 1281 19 24 50 30 71 12z" style="transform:scale(-1,1);transform-origin:center"/></g><g fill="rgba(0,0,0,0.2)" ><path d="m2165 685c8 0 438-155 955-345 615-226 954-345 979-345 87 0 165 47 204 123 46 91 107-95-957 2942-537 1535-986 2805-997 2823-11 18-43 46-72 62-41 24-62 30-111 29z"/></g><text x="2165" y="3300" style="font-size:2500px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-ball-pin":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(15.67 * {scale})" height="calc(33.33 * {scale})" viewBox="0 0 235 452"><g transform="translate(-135 10)"><path fill="{secondaryColor}" d="m256 442 0 0c-13 0-18-11-18-24l-6-323c0-13 11-24 24-24h0c13 0 24 11 24 24l-6 323c0 13-5 24-18 24z"/><circle style="fill:{color};stroke-width:10;stroke:{secondaryColor}" cx="256" cy="112" r="111"/><ellipse transform="matrix(0.834 0.5518 -0.5518 0.834 65.7916 -97.18)" fill="rgba(255,255,255,0.3)" cx="194.399" cy="60.749" rx="19.076" ry="32.428"/></g><text x="117.5" y="160" style="font-size:160px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(26.67 * {scale})" height="calc(32.27 * {scale})" viewBox="0 0 2000 2420"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="M845 2152c-22-37-58-95-80-129-22-35-62-99-90-143l-50-80-312 0-313 0 0-900 0-900 900 0 900 0 0 900 0 900-313 0-313 0-34 58c-19 31-38 59-42 60-5 2-8 8-8 12 0 9-69 123-88 145-5 6-11 15-13 21-16 39-77 123-89 124-8 0-33-31-55-68z"/></g><text x="1000" y="1300" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square-cluster":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(33.33 * {scale})" height="calc(38.8 * {scale})" viewBox="0 0 2500 2910"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="m866 2652c-17-31-37-68-46-82-9-14-32-54-51-90-19-36-50-92-70-125l-36-60-332-3-331-2 0-905 0-905 660 0 660 0 0-38c0-71 50-196 102-258 71-85 189-164 244-164 12 0 26-4 29-10 8-13 222-13 230 0 3 6 17 10 30 10 25 0 117 45 154 76 130 107 191 232 191 392 0 155-63 284-190 386-36 29-129 76-150 76-11 0-22 5-25 10-3 6-31 10-61 10l-54 0 0 660 0 660-332 2-332 3-29 50c-17 28-48 84-70 125-22 41-47 86-56 100-9 14-30 51-46 83-17 32-36 57-45 57-8 0-28-25-44-58z"/></g><text x="1650" y="900" style="font-size:1000px;fill:#fff">+</text><text x="1000" y="1800" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square-rounded":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(26.8 * {scale})" height="calc(32.27 * {scale})" viewBox="0 0 2010 2410"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="M856 2155c-20-30-36-59-36-65 0-5-4-10-10-10-5 0-10-5-10-11 0-5-18-37-40-69-22-32-40-64-40-69 0-6-4-11-10-11-5 0-10-5-10-10 0-6-15-33-32-60l-33-50-127 0c-74 0-129-4-133-10-3-5-17-10-30-10-25 0-116-45-155-76-87-69-142-151-178-265-15-46-17-1075-2-1084 5-3 10-17 10-30 0-13 5-27 10-30 6-3 10-13 10-22 0-22 83-135 122-168 57-46 62-50 112-75l50-25 585 0 586 0 63 34c84 46 169 133 212 218l35 68 0 565 0 565-28 59c-32 69-100 157-139 180-15 9-33 22-40 29-23 22-99 57-123 57-13 0-27 5-30 10-4 6-60 10-135 10l-128 0-128 205c-84 136-133 205-144 205-10 0-33-24-54-55z"/></g><text x="1000" y="1300" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',"marker-square-rounded-cluster":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(33.33 * {scale})" height="calc(32.13 * {scale})" viewBox="0 0 2500 2900"><g transform="translate(100 100)" style="stroke:{secondaryColor};stroke-width:100;fill:{color}"><path d="m874 2669c-9-18-26-49-37-68-11-20-30-55-43-78-13-24-36-64-51-90-14-27-38-69-52-95l-26-48-142 0c-84 0-144-4-148-10-3-5-17-10-30-10-25 0-118-46-154-76-91-76-136-142-175-254-13-38-16-119-16-554 0-358 3-520 12-545 40-125 106-219 195-278 127-84 116-83 646-83l467 0 0-42c0-46 11-87 45-163 54-121 169-220 306-264 46-14 232-14 278 0 165 53 284 175 340 350 19 61 14 204-10 273-32 91-94 178-169 240-38 31-130 76-155 76-13 0-27 5-30 10-3 6-28 10-56 10l-49 0 0 462c0 446-1 464-21 522-32 91-94 178-169 240-38 31-130 76-155 76-13 0-27 5-30 10-4 6-65 10-149 10-138 0-143 1-154 23-12 23-62 114-112 202-16 28-44 79-63 115-42 77-67 88-93 39z"/></g><text x="1650" y="900" style="font-size:1000px;fill:#fff">+</text><text x="1000" y="1800" style="font-size:1000px;fill:#fff;text-anchor:middle">{text}</text></svg>',flag:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(23.5 * {scale})" height="calc(40 * {scale})" viewBox="34 28 198 308"><path style="stroke:{secondaryColor};stroke-width:15;stroke-linecap:round;" d="M42 327l0 -291"/><path style="fill:{color};stroke:{secondaryColor};stroke-width:10;stroke-linejoin:round;" d="M49 50c70 30 104 28 178 2-21 42-21 74 0 116-72 25-101 25-178 0l0-118z"/><text x="130" y="165" style="font-size:100px;fill:#fff;text-anchor:middle">{text}</text></svg>',"flag-triangle":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(27 * {scale})" height="calc(35.33 * {scale})" viewBox="0 0 40.5 53"><g transform="translate(-31 -20)"><path fill="{secondaryColor}" d="M34.7,73.3V48.4l34.6-10.1c0.7-0.2,1.2-0.8,1.2-1.5s-0.4-1.4-1-1.7L33.7,20.5c-0.5-0.2-1.1-0.2-1.6,0.2 c-0.5,0.3-0.7,0.8-0.7,1.4v51.2H34.7z"/><polygon points="34.7,24.5 66,36.5 34.7,45 34.7,10" fill="{color}"/></g><text x="11" y="21" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"rounded-square":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(34 * {scale})" height="calc(34 * {scale})" viewBox="0 0 34 34"><g transform="translate(2 2)"><rect x="0" y="0" rx="8" ry="8" width="30" height="30" style="stroke:{secondaryColor};stroke-width:2;fill:{color}"/></g><text x="17" y="22" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"rounded-square-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(38 * {scale})" height="calc(38 * {scale})" viewBox="0 0 38 38"><g transform="translate(4 4)"><rect x="0" y="0" rx="8" ry="8" width="30" height="30" style="stroke:{secondaryColor};stroke-width:4;fill:{color}"/></g><text x="19" y="24" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',triangle:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(36 * {scale})" height="calc(36 * {scale})" viewBox="0 0 36 36"><g transform="translate(2 2)"><polygon points="16,0 32,32 0,32 16,0" style="stroke:{secondaryColor};stroke-width:2;fill:{color}"/></g><text x="17.5" y="30" style="font-size:12px;fill:#fff;text-anchor:middle">{text}</text></svg>',"triangle-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 40 40"><g transform="translate(4 4)"><polygon points="16,0 32,32 0,32 16,0" style="stroke:{secondaryColor};stroke-width:4;fill:{color}"/></g><text x="19.5" y="32" style="font-size:12px;fill:#fff;text-anchor:middle">{text}</text></svg>',hexagon:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(35 * {scale})" height="calc(40 * {scale})" viewBox="0 0 35 40"><g transform="translate(2 2)"><path d="M31 9 15.5 0 0 9 0 27 15.5 36 31 27 31 9Z" style="stroke:{secondaryColor};stroke-width:2;fill:{color}"/></g><text x="17.5" y="25" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"hexagon-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(39 * {scale})" height="calc(44 * {scale})" viewBox="0 0 39 44"><g transform="translate(4 4)"><path d="M31 9 15.5 0 0 9 0 27 15.5 36 31 27 31 9Z" style="stroke:{secondaryColor};stroke-width:4;fill:{color}"/></g><text x="19.5" y="27" style="font-size:14px;fill:#fff;text-anchor:middle">{text}</text></svg>',"hexagon-rounded":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 1100 1100"><g transform="translate(50 50)"><path style="stroke:{secondaryColor};stroke-width:50;fill:{color}" d="M881 210 561 25c-33-19-88-19-121 0L119 210c-33 19-61 67-61 105v370c0 39 27 86 61 105l321 185c33 19 88 19 122 0l321-185c33-19 61-67 61-105V315C942 276 915 229 881 210z"/></g><text x="550" y="700" style="font-size:400px;fill:#fff;text-anchor:middle">{text}</text></svg>',"hexagon-rounded-thick":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 1200 1200"><g transform="translate(100 100)"><path style="stroke:{secondaryColor};stroke-width:100;fill:{color}" d="M881 210 561 25c-33-19-88-19-121 0L119 210c-33 19-61 67-61 105v370c0 39 27 86 61 105l321 185c33 19 88 19 122 0l321-185c33-19 61-67 61-105V315C942 276 915 229 881 210z"/></g><text x="600" y="750" style="font-size:400px;fill:#fff;text-anchor:middle">{text}</text></svg>',"triangle-arrow-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(28 * {scale})" viewBox="0 0 28 28"><g transform="translate(2 2)"><polygon points="12,0 0,24 12,17 24,24" stroke-width="2" stroke="{secondaryColor}" fill="{color}"/></g><text x="14" y="17" style="font-size:8px;fill:#fff;text-anchor:middle">{text}</text></svg>',"triangle-arrow-left":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(28 * {scale})" height="calc(28 * {scale})" viewBox="0 0 28 28"><g transform="translate(2 2)"><polygon points="24,12 0,0 7,12 0,24" stroke-width="2" stroke="{secondaryColor}" fill="{color}"/></g><text x="14" y="16.5" style="font-size:8px;fill:#fff;text-anchor:middle">{text}</text></svg>',"arrow-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(12.16 * {scale})" height="calc(30.1 * {scale})" viewBox="0 0 902 364"><g fill="{color}" transform="matrix(0,2.4,-2.4,0,897,-930)"><polygon points="902,222 233,222 233,364 0,182 233,0 233,141 902,141 902,222"/></g><text x="450" y="700" style="font-size:900px;fill:#000;text-anchor:middle">{text}</text></svg>',"arrow-up-thin":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(16 * {scale})" height="calc(33.33 * {scale})" viewBox="0 0 12 25"><g transform="translate(-136.91823 -751.91998)"><path fill="{color}" d="m148.271 760.71c-1.641-.547-3.186-1.47-4.633-2.769l0 18.07-1.675 0 0-18.07c-1.447 1.299-2.986 2.222-4.616 2.769l0-1.231c2.325-1.596 4.006-3.812 5.043-6.65l.838 0c1.037 2.838 2.718 5.055 5.043 6.65l0 1.231z"/></g><text x="6" y="20" style="font-size:10px;fill:#000;text-anchor:middle">{text}</text></svg>',car:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(21.93 * {scale})" height="calc(40.9 * {scale})" viewBox="0 0 6580 12270"><g transform="translate(0 12270) rotate(-90)"><path fill="{secondaryColor}" d="M7045 6566c-42-13-105-44-105-51 0-2 23-105 50-228 28-123 50-230 50-236 0-8-241-11-907-11-855 0-1145 6-1513 30-85 6-189 13-230 15-41 3-133 10-205 15-286 21-430 32-705 50-953 63-1459 18-2335-205-304-77-746-209-799-238-131-72-221-408-285-1062-34-345-42-532-48-1130-16-1557 108-2532 336-2649 32-17 469-149 676-205 409-110 819-191 1205-238 116-14 224-18 540-18 395 1 494 5 1140 50 1124 79 1224 82 2496 78l641-3-53-237c-29-131-52-238-51-239 1-1 31-14 66-29 56-23 76-26 142-23 67 3 83 7 120 33 23 17 50 41 61 55 10 14 51 117 91 230l73 205 674 3 675 2 90-39c98-43 198-72 315-93 122-21 829-18 990 5 321 45 626 143 849 270 293 168 516 378 704 662 266 402 416 893 467 1527 15 174 8 882-9 998-6 41-18 127-27 190-69 502-253 969-523 1325-79 105-262 284-381 374-189 142-355 229-574 300-336 110-526 139-952 148-457 9-685-23-887-124l-47-24-678-6-678-6-64 179c-79 224-92 253-121 284-67 70-177 97-274 66zm-2752-5073c-23-2-64-2-90 0-26 2-7 3 42 3 50 0 71-1 48-3zm395 0c-21-2-55-2-75 0-21 2-4 4 37 4 41 0 58-2 38-4z"/><path fill="{color}" d="M7043 6498c-13-6-23-19-23-28 0-9 23-117 50-240 28-123 50-230 50-237 0-22-2126-13-2465 10-132 10-400 28-595 42-661 47-824 55-1160 62-435 7-656-8-1040-73-415-70-865-183-1447-365-168-53-272-556-325-1569-16-319-16-1311 0-1630 45-872 129-1366 257-1518 22-26 51-39 172-77 557-177 1122-310 1563-369 271-36 351-40 690-40 361 1 463 6 1165 54 1122 78 1288 83 2337 79 460-2 840-7 843-11 4-4-17-117-47-252l-55-245 39-16c76-30 180-8 224 47 10 13 54 124 98 246l79 222 709 0 709 0 47-24c74-37 219-83 322-101 122-22 606-32 802-16 374 29 658 102 933 238 124 62 271 155 361 230l61 51 6 100c19 278 103 497 247 643 88 89 173 136 278 152l70 11 41 131c116 369 159 673 168 1170 10 584-38 984-167 1397l-40 126-70 12c-193 33-348 175-441 405-56 139-89 302-89 445 0 43-3 47-58 91-290 235-644 384-1068 450-191 29-796 39-974 16-135-18-263-54-368-102l-75-35-701 0-701 0-79 223c-82 232-102 267-163 293-38 16-138 17-170 2zm-2023-820c332-15 1155-12 1835 6 308 8 563 12 566 8 4-4 10-21 13-38 7-30 6-31-92-77-518-244-1197-396-2112-474-295-25-1282-25-1579 0-231 20-473 46-479 51-6 7 49 110 93 171 160 226 416 335 855 365 142 10 539 5 900-12zm3304-263c525-111 899-887 934-1935 19-557-37-1023-172-1435-186-563-521-900-896-899-81 0-158 14-525 92-426 91-431 92-540 146-195 96-287 207-306 368-12 104-11 2985 1 3078 22 170 135 291 365 389 49 21 191 55 480 115 226 47 419 87 430 89 45 10 164 6 229-8zm-5570-485c112-43 197-156 216-291 12-83 13-2623 1-2706-23-158-125-273-270-304-44-9-100-1-542 75-272 47-514 91-539 98-266 68-487 424-594 958-56 280-70 548-40 800 56 484 207 878 414 1081 115 114 122 116 702 218 277 49 524 90 550 90 26 1 72-8 102-19zm2111-3440c1023-44 1884-213 2462-486l113-53-7-33c-3-18-8-35-10-37-2-3-236 1-521 7-993 24-1271 26-1708 11-541-18-1128-18-1249-1-377 56-588 181-734 437-32 55-41 79-32 84 12 8 246 32 491 51 356 28 815 36 1195 20z"/></g><text x="3250" y="8250" style="font-size:3000px;fill:#fff;text-anchor:middle">{text}</text></svg>',checker:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(16 * {scale})" height="calc(16 * {scale})" viewBox="0 0 16 16"><pattern id="p" x="0" y="0" width="16" height="16" patternUnits="userSpaceOnUse"><rect fill="{color}" x="0" width="8" height="8" y="0"/><rect fill="{color}" x="8" width="8" height="8" y="8"/></pattern><rect x="0" y="0" width="16" height="16" fill="{secondaryColor}"/><rect x="0" y="0" width="16" height="16" fill="url(#p)"/></svg>',"checker-rotated":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(16 * {scale})" height="calc(16 * {scale})" viewBox="0 0 60 60"><rect width="60" height="60" fill="{secondaryColor}"/><rect width="42.42" height="42.42" transform="translate(30 0) rotate(45)" fill="{color}"/></svg>',"zig-zag":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(15 * {scale})" height="calc(15 * {scale})" viewBox="0 0 120 120"><rect x="0" y="0" width="120" height="120" fill="{secondaryColor}"/><polygon fill="{color}" points="120 120 60 120 90 90 120 60 120 0 120 0 60 60 0 0 0 60 30 90 60 120 120 120"/></svg>',"zig-zag-vertical":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(15 * {scale})" height="calc(15 * {scale})" viewBox="0 0 120 120"><rect x="0" y="0" width="120" height="120" fill="{secondaryColor}"/><polygon fill="{color}" points="120 0 120 60 90 30 60 0 0 0 0 0 60 60 0 120 60 120 90 90 120 60 120 0"/></svg>',"circles-spaced":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 20 20"><defs><pattern id="p" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="2" stroke="none" fill="{color}"/></pattern></defs><rect x="0" y="0" width="20" height="20" fill="{secondaryColor}"/><rect x="0" y="0" width="100" height="100" fill="url(#p)"/></svg>',circles:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(7 * {scale})" height="calc(7 * {scale})" viewBox="0 0 20 20"><defs><pattern id="p" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="6" stroke="none" fill="{color}"/></pattern></defs><rect x="0" y="0" width="20" height="20" fill="{secondaryColor}"/><rect x="0" y="0" width="100" height="100" fill="url(#p)"/></svg>',"diagonal-lines-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(18 * {scale})" height="calc(18 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"diagonal-lines-down":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(18 * {scale})" height="calc(18 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g transform="rotate(90 3 3)" fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"diagonal-stripes-up":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="40" height="40" fill="{secondaryColor}"/><g fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g></svg>',"diagonal-stripes-down":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="40" height="40" fill="{secondaryColor}"/><g transform="rotate(90 20 20)" fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g></svg>',"grid-lines":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(14 * {scale})" height="calc(14 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g transform="rotate(45 3 3)" fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g><g fill="{color}" transform="rotate(-45 3 3)"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"rotated-grid-lines":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(18 * {scale})" height="calc(18 * {scale})" viewBox="0 0 6 6"><rect x="0" y="0" width="6" height="6" fill="{secondaryColor}"/><g transform="rotate(90 3 3)" fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g><g fill="{color}"><path d="M5 0h1L0 6V5zM6 5v1H5z"/></g></svg>',"rotated-grid-stripes":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(20 * {scale})" height="calc(20 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="40" height="40" fill="{secondaryColor}"/><g transform="rotate(90 20 20)" fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g><g fill="{color}"><path d="M0 40L40 0H20L0 20M40 40V20L20 40"/></g></svg>',"x-fill":'<svg xmlns="http://www.w3.org/2000/svg" width="calc(40 * {scale})" height="calc(40 * {scale})" viewBox="0 0 40 40"><rect x="0" y="0" width="45.3" height="45.3" fill="{secondaryColor}"/><g fill="{color}"><path d="M0 38.59l2.83-2.83 1.41 1.41L1.41 40H0v-1.41zM0 1.4l2.83 2.83 1.41-1.41L1.41 0H0v1.41zM38.59 40l-2.83-2.83 1.41-1.41L40 38.59V40h-1.41zM40 1.41l-2.83 2.83-1.41-1.41L38.59 0H40v1.41zM20 18.6l2.83-2.83 1.41 1.41L21.41 20l2.83 2.83-1.41 1.41L20 21.41l-2.83 2.83-1.41-1.41L18.59 20l-2.83-2.83 1.41-1.41L20 18.59z"/></g></svg>',dots:'<svg xmlns="http://www.w3.org/2000/svg" width="calc(13 * {scale})" height="calc(13 * {scale})" viewBox="0 0 20 20"><rect x="0" y="0" width="20" height="20" fill="{secondaryColor}"/><g fill="{color}"><circle cx="3" cy="3" r="3"/><circle cx="13" cy="13" r="3"/></g></svg>'},ze=window&&window.__extends||(je=function(t,e){return(je=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}je(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),De=(u.ControlPosition=void 0,(yt=u.ControlPosition||(u.ControlPosition={})).TopLeft="top-left",yt.TopRight="top-right",yt.BottomLeft="bottom-left",yt.BottomRight="bottom-right",yt.NonFixed="non-fixed",ze(Re,Ie=t),Re);function Re(){var t=null!==Ie&&Ie.apply(this,arguments)||this;return t.position=u.ControlPosition.NonFixed,t}Fe.prototype.getLuminosity=function(){for(var t=[this.r,this.g,this.b],e=[],o=0;o<t.length;o++){var n=t[o]/255;e[o]=n<=.03928?n/12.92:Math.pow((.055+n)/1.055,2.4)}return.2126*e[0]+.7152*e[1]+.0722*e[2]},Fe.prototype.getRBGA=function(t){var e=document.createElement("canvas").getContext("2d"),t=(e.globalAlpha=1,e.fillStyle=t,e.fillRect(0,0,1,1),e.getImageData(0,0,1,1).data);return[t[0],t[1],t[2],t[3]]};var Be=Fe;function Fe(t){var e;t&&(e=void 0,3<=(e="string"==typeof t?this.getRBGA(t):t).length)&&(this.r=e[0],this.g=e[1],this.b=e[2],3<e.length)&&(this.a=e[3])}u.ControlStyle=void 0,(H=u.ControlStyle||(u.ControlStyle={})).light="light",H.dark="dark",H.auto="auto";var Ne=Map,Ze=(qe.prototype._addEventListener=function(t,e,o){this.listeners.has(t)||this.listeners.set(t,new Ne),this.listeners.get(t).set(e,o)},qe.prototype._removeEventListener=function(t,e){this.listeners.has(t)&&this.listeners.get(t).delete(e)},qe.prototype._invokeEvent=function(o,n){var r=this;this.listeners.has(o)&&this.listeners.get(o).forEach(function(t,e){t&&r._removeEventListener(o,e);try{e(n)}catch(t){console.error(t)}})},qe);function qe(){this.listeners=new Ne}var He,Ue,U=Object.freeze({__proto__:null,EventEmitter:Ze}),We=((window&&window.__extends||(He=function(t,e){return(He=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}He(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ge,Ue=Ze),Ge.prototype.onRemove=function(){this._container&&(this._container.remove(),delete this._container),this._map&&(this._map.events.remove("stylechanged",this._onStyleChange),delete this._map),this._observer&&(this._observer.disconnect(),delete this._observer),delete this._theme},Ge.prototype.buildContainer=function(t,e,o,n){return this._map=t,this._container=document.createElement(n||"div"),this._container.classList.add("azure-maps-control-container"),"string"==typeof o&&this._container.setAttribute("aria-label",o),e.toLowerCase()===u.ControlStyle.auto?this._map&&this._map.events.add("stylechanged",this._onStyleChange):this._container.classList.add(e),this._container},Ge.prototype._setTheme=function(t){this._theme!==t&&(this._container.classList.remove(this._theme),this._container.classList.add(t),this._theme=t)},Ge.activateClickDelay=100,Ge);function Ge(){var e=null!==Ue&&Ue.apply(this,arguments)||this;return e._onStyleChange=function(){e._map.getStyle().style.toLowerCase().startsWith("blank")?e._observer||(e._onBackgroundChange(),e._observer=new MutationObserver(e._onBackgroundChange),e._observer.observe(e._map.getMapContainer(),{attributes:!0,attributeFilter:["style"]})):(e._observer&&(e._observer.disconnect(),delete e._observer),e._map.styles.getThemeAsync(e._map.getStyle()).then(function(t){e._setTheme(t)}))},e._onBackgroundChange=function(){var t=new Be(e._map.getMapContainer().style.backgroundColor).getLuminosity(),t=isNaN(t)||.5<t?u.ControlStyle.light:u.ControlStyle.dark;e._setTheme(t)},e}(window&&window.__extends||(Ve=function(t,e){return(Ve=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ve(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Je,Ke=t);var Ve,Ke,Ye=Je;function Je(){var t=null!==Ke&&Ke.apply(this,arguments)||this;return t.rotationDegreesDelta=15,t.style=u.ControlStyle.light,t.inverted=!1,t}(window&&window.__extends||($e=function(t,e){return($e=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}$e(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Qe,Xe=We),Qe.prototype.onAdd=function(t,e){function o(t){t?(r.classList.add("in-use"),s.classList.remove("hidden-accessible-element")):(r.classList.remove("in-use"),s.classList.add("hidden-accessible-element"))}var n=this,r=this.buildContainer(t,this.options.style,"Rotation Control"),i=this.constructRotationButton(t),s=this.constructRotationGrid(t,e),a=_("Reset to Default Rotation");return r.addEventListener("mouseover",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasMouse=!0,o(!0)}),r.addEventListener("focusin",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasFocus=!0,o(!0)}),r.addEventListener("mouseleave",function(){n.hasMouse=!1,n.hasFocus||(delete n.lastActiveTime,o(!1))}),r.addEventListener("focusout",function(t){t.relatedTarget instanceof Node&&r.contains(t.relatedTarget)||(n.hasFocus=!1,n.hasMouse)||(delete n.lastActiveTime,o(!1))}),s.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||(t.stopPropagation(),i.focus(),o(!1))}),i.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||null==r||!r.classList.contains("in-use")||"none"!==(null==a?void 0:a.style.display)||(t.stopPropagation(),o(!1))}),e&&Qe.InvertOrderPositions.includes(e.position)?(r.appendChild(s),r.appendChild(i),r.appendChild(a),b(a,i)):(r.appendChild(i),r.appendChild(a),b(a,i),r.appendChild(s)),r},Qe.prototype.constructRotationGrid=function(t,e){var o=document.createElement("div"),n=(o.classList.add("sub-container"),o.classList.add("hidden-accessible-element"),this.constructRightRotationButton(t)),t=this.constructLeftRotationButton(t),r=_("Rotate Left"),i=_("Rotate Right");return e&&Qe.InvertOrderPositions.includes(e.position)?(o.appendChild(n),o.appendChild(i),b(i,n),o.appendChild(t),o.appendChild(r),b(r,t)):(o.appendChild(t),o.appendChild(r),b(r,t),o.appendChild(n),o.appendChild(i),b(i,n)),o},Qe.prototype.constructRotationButton=function(e){var o=this,t=document.createElement("button"),n=(t.classList.add("azure-maps-control-button"),t.classList.add("rotation"),t.setAttribute("aria-label","Reset to Default Rotation"),t.setAttribute("alt","Reset to Default Rotation"),t.setAttribute("type","button"),document.createElement("div"));return t.appendChild(n),t.addEventListener("click",function(t){t.timeStamp-o.lastActiveTime>We.activateClickDelay&&e.setCamera({bearing:Qe.DefaultRotation},!0)}),e.events.add("rotate",function(t){n.style.transform="rotate(".concat(-t.map.getCamera().bearing,"deg)")}),t},Qe.prototype.constructRightRotationButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("rotation-right"),o.setAttribute("aria-label","Rotate Right"),o.setAttribute("alt","Rotate Right"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({bearing:t.getCamera().bearing-(e.options.inverted?-1:1)*e.options.rotationDegreesDelta,duration:Qe.RotationDuration,type:"ease"},!0)}),o},Qe.prototype.constructLeftRotationButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("rotation-left"),o.setAttribute("aria-label","Rotate Left"),o.setAttribute("alt","Rotate Left"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({bearing:t.getCamera().bearing+(e.options.inverted?-1:1)*e.options.rotationDegreesDelta,duration:Qe.RotationDuration,type:"ease"},!0)}),o},Qe.DefaultRotation=0,Qe.RotationDuration=100,Qe.InvertOrderPositions=[u.ControlPosition.BottomRight,u.ControlPosition.TopRight];var $e,Xe,q=Qe;function Qe(t){var e=Xe.call(this)||this;return e.hasMouse=!1,e.hasFocus=!1,e.options=(new Ye).merge(t),e}(window&&window.__extends||(to=function(t,e){return(to=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}to(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(no,eo=t);var to,eo,oo=no;function no(){var t=null!==eo&&eo.apply(this,arguments)||this;return t.pitchDegreesDelta=10,t.style=u.ControlStyle.light,t.inverted=!1,t}(window&&window.__extends||(ro=function(t,e){return(ro=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ro(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(so,io=We),so.prototype.onAdd=function(t,e){function o(t){t?(r.classList.add("in-use"),s.classList.remove("hidden-accessible-element")):(r.classList.remove("in-use"),s.classList.add("hidden-accessible-element"))}var n=this,r=this.buildContainer(t,this.options.style,"Pitch Control"),i=this.constructPitchButton(t),s=this.constructPitchGrid(t,e),a=_("Reset to Default Pitch");return r.addEventListener("mouseover",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasMouse=!0,o(!0)}),r.addEventListener("focusin",function(t){n.lastActiveTime=n.lastActiveTime||t.timeStamp,n.hasFocus=!0,o(!0)}),r.addEventListener("mouseleave",function(){n.hasMouse=!1,n.hasFocus||(delete n.lastActiveTime,o(!1))}),r.addEventListener("focusout",function(t){t.relatedTarget instanceof Node&&r.contains(t.relatedTarget)||(n.hasFocus=!1,n.hasMouse)||(delete n.lastActiveTime,o(!1))}),s.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||(t.stopPropagation(),i.focus(),o(!1))}),i.addEventListener("keydown",function(t){"Escape"!==t.key&&"Esc"!==t.key||null==r||!r.classList.contains("in-use")||"none"!==(null==a?void 0:a.style.display)||(t.stopPropagation(),o(!1))}),e&&so.INVERT_ORDER_POSITIONS.includes(e.position)?(r.appendChild(s),r.appendChild(i),r.appendChild(a),b(a,r)):(r.appendChild(i),r.appendChild(a),b(a,r),r.appendChild(s)),this.map=t,this.container=r,this.pitchButton=i,t.events.add("pitch",this.pitchChanged),this.updatePitchButtonsState(),r},so.prototype.onRemove=function(){this.container&&(this.container.remove(),this.container=null,this.pitchButton=null,this.pitchIncrementButton=null,this.pitchDecrementButton=null),this.map&&(this.map.events.remove("pitch",this.pitchChanged),this.map=null)},so.prototype.constructPitchGrid=function(t,e){var o=document.createElement("div"),t=(o.classList.add("sub-container"),o.classList.add("hidden-accessible-element"),this.pitchIncrementButton=this.constructPitchIncrementButton(t),this.pitchDecrementButton=this.constructPitchDecrementButton(t),_("Increase Pitch")),n=_("Decrease Pitch");return e&&so.INVERT_ORDER_POSITIONS.includes(e.position)?(o.appendChild(this.pitchDecrementButton),o.appendChild(n),b(n,this.pitchDecrementButton),o.appendChild(this.pitchIncrementButton),o.appendChild(t),b(t,this.pitchIncrementButton)):(o.appendChild(this.pitchIncrementButton),o.appendChild(t),b(t,this.pitchIncrementButton),o.appendChild(this.pitchDecrementButton),o.appendChild(n),b(n,this.pitchDecrementButton)),o},so.prototype.constructPitchButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("pitch"),o.setAttribute("aria-label","Reset to Default Pitch"),o.setAttribute("alt","Reset to Default Pitch"),o.setAttribute("type","button"),o.addEventListener("click",function(){event.timeStamp-e.lastActiveTime>We.activateClickDelay&&t.setCamera({pitch:so.DEFAULT_PITCH},!0)}),o},so.prototype.constructPitchDecrementButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("pitch-down"),o.setAttribute("aria-label","Decrease Pitch"),o.setAttribute("alt","Decrease Pitch"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({pitch:t.getCamera().pitch-(e.options.inverted?-1:1)*e.options.pitchDegreesDelta,duration:so.PITCH_DURATION_MS,type:"ease"},!0)}),o},so.prototype.constructPitchIncrementButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("pitch-up"),o.setAttribute("aria-label","Increase Pitch"),o.setAttribute("alt","Increase Pitch"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({pitch:t.getCamera().pitch+(e.options.inverted?-1:1)*e.options.pitchDegreesDelta,duration:so.PITCH_DURATION_MS,type:"ease"},!0)}),o},so.PITCH_DURATION_MS=100,so.DEFAULT_PITCH=0,so.INVERT_ORDER_POSITIONS=[u.ControlPosition.BottomRight,u.ControlPosition.TopRight];var ro,io,yt=so;function so(t){var o=io.call(this)||this;return o.container=null,o.map=null,o.pitchButton=null,o.pitchIncrementButton=null,o.pitchDecrementButton=null,o.hasMouse=!1,o.hasFocus=!1,o.pitchChanged=function(t){return o.updatePitchButtonsState()},o.updatePitchButtonsState=function(){var t=o.map.getCamera().pitch<=0,e=60<=o.map.getCamera().pitch;o.hasFocus&&o.pitchButton&&(t||e)&&o.pitchButton.focus(),o.options.inverted?(o.pitchIncrementButton&&o.pitchIncrementButton.disabled!=t&&(o.pitchIncrementButton.disabled=t),o.pitchDecrementButton&&o.pitchDecrementButton.disabled!=e&&(o.pitchDecrementButton.disabled=e)):(o.pitchIncrementButton&&o.pitchIncrementButton.disabled!=e&&(o.pitchIncrementButton.disabled=e),o.pitchDecrementButton&&o.pitchDecrementButton.disabled!=t&&(o.pitchDecrementButton.disabled=t))},o.options=(new oo).merge(t),o}(window&&window.__extends||(ao=function(t,e){return(ao=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ao(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(lo,co=We),lo.prototype.onAdd=function(t,e){this.map=t,null!=(o=null==(o=this.map)?void 0:o._getMap())&&o.addControl(this.control);var o=this.buildContainer(t,u.ControlStyle.auto,"Scale Bar");return o.appendChild(null==(t=this.control)?void 0:t._container),o},lo.prototype.onRemove=function(){var t;co.prototype.onRemove.call(this),null!=(t=null==(t=this.map)?void 0:t._getMap())&&t.removeControl(this.control),this.map=null},lo.prototype.setUnit=function(t){var e;null!=(e=this.control)&&e.setUnit(t)};var ao,co,ze=lo;function lo(t){var e=co.call(this)||this;return e.map=null,e.control=new D.ScaleControl({maxWidth:null==t?void 0:t.maxWidth,unit:null==t?void 0:t.unit}),e}function uo(t,e){return t===e||t!=t&&e!=e}var po=uo;function ho(t,e){for(var o=t.length;o--;)if(po(t[o][0],e))return o;return-1}var fo=ho,yo=Array.prototype.splice;var mo=ho;var go=ho;var vo=ho;function wo(t){var e=this.__data__;return!((t=fo(e,t))<0||(t==e.length-1?e.pop():yo.call(e,t,1),--this.size,0))}function _o(t){var e=this.__data__;return(t=mo(e,t))<0?void 0:e[t][1]}function bo(t){return-1<go(this.__data__,t)}function xo(t,e){var o=this.__data__,n=vo(o,t);return n<0?(++this.size,o.push([t,e])):o[n][1]=e,this}function Oo(t){var e=-1,o=null==t?0:t.length;for(this.clear();++e<o;){var n=t[e];this.set(n[0],n[1])}}Oo.prototype.clear=function(){this.__data__=[],this.size=0},Oo.prototype.delete=wo,Oo.prototype.get=_o,Oo.prototype.has=bo,Oo.prototype.set=xo;var H=Oo,So=H;function Co(){this.__data__=new So,this.size=0}function Po(t){var e=this.__data__,t=e.delete(t);return this.size=e.size,t}function Lo(t){return this.__data__.get(t)}function ko(t){return this.__data__.has(t)}var R="object"==typeof R&&R&&R.Object===Object&&R,e="object"==typeof self&&self&&self.Object===Object&&self,e=R||e||Function("return this")(),Ao=e.Symbol,o=Object.prototype,Mo=o.hasOwnProperty,Eo=o.toString,jo=Ao?Ao.toStringTag:void 0;var Io=Object.prototype.toString;var To=function(t){var e=Mo.call(t,jo),o=t[jo];try{var n=!(t[jo]=void 0)}catch(t){}var r=Eo.call(t);return n&&(e?t[jo]=o:delete t[jo]),r},zo=function(t){return Io.call(t)},Do=Ao?Ao.toStringTag:void 0;function Ro(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":(Do&&Do in Object(t)?To:zo)(t)}function Bo(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Fo=Ro,No=Bo;function Zo(t){return!!No(t)&&("[object Function]"==(t=Fo(t))||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t)}var o=e["__core-js_shared__"],qo=(o=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+o:"";var Ho=Function.prototype.toString;function Uo(t){if(null!=t){try{return Ho.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var Wo=Zo,Go=function(t){return!!qo&&qo in t},Vo=Bo,Ko=Uo,Yo=/^\[object .+?Constructor\]$/,o=Function.prototype,Jo=Object.prototype,o=o.toString,Jo=Jo.hasOwnProperty,$o=RegExp("^"+o.call(Jo).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var Xo=function(t){return!(!Vo(t)||Go(t))&&(Wo(t)?$o:Yo).test(Ko(t))},Qo=function(t,e){return null==t?void 0:t[e]};function tn(t,e){return t=Qo(t,e),Xo(t)?t:void 0}var o=tn(e,"Map"),Jo=tn(Object,"create"),en=Jo;var on=Jo,nn=Object.prototype.hasOwnProperty;var rn=Jo,sn=Object.prototype.hasOwnProperty;var an=Jo;function cn(t){return t=this.has(t)&&delete this.__data__[t],this.size-=t?1:0,t}function ln(t){var e,o=this.__data__;return on?"__lodash_hash_undefined__"===(e=o[t])?void 0:e:nn.call(o,t)?o[t]:void 0}function un(t){var e=this.__data__;return rn?void 0!==e[t]:sn.call(e,t)}function pn(t,e){var o=this.__data__;return this.size+=this.has(t)?0:1,o[t]=an&&void 0===e?"__lodash_hash_undefined__":e,this}function hn(t){var e=-1,o=null==t?0:t.length;for(this.clear();++e<o;){var n=t[e];this.set(n[0],n[1])}}hn.prototype.clear=function(){this.__data__=en?en(null):{},this.size=0},hn.prototype.delete=cn,hn.prototype.get=ln,hn.prototype.has=un,hn.prototype.set=pn;var dn=hn,fn=H,yn=o;var mn=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t};function gn(t,e){return t=t.__data__,mn(e)?t["string"==typeof e?"string":"hash"]:t.map}var vn=gn;var wn=gn;var _n=gn;var bn=gn;function xn(t){return t=vn(this,t).delete(t),this.size-=t?1:0,t}function On(t){return wn(this,t).get(t)}function Sn(t){return _n(this,t).has(t)}function Cn(t,e){var o=bn(this,t),n=o.size;return o.set(t,e),this.size+=o.size==n?0:1,this}function Pn(t){var e=-1,o=null==t?0:t.length;for(this.clear();++e<o;){var n=t[e];this.set(n[0],n[1])}}Pn.prototype.clear=function(){this.size=0,this.__data__={hash:new dn,map:new(yn||fn),string:new dn}},Pn.prototype.delete=xn,Pn.prototype.get=On,Pn.prototype.has=Sn,Pn.prototype.set=Cn;var Jo=Pn,Ln=H,kn=o,An=Jo;function Mn(t,e){var o=this.__data__;if(o instanceof Ln){var n=o.__data__;if(!kn||n.length<199)return n.push([t,e]),this.size=++o.size,this;o=this.__data__=new An(n)}return o.set(t,e),this.size=o.size,this}var En=H,H=Po,jn=Lo,In=ko;function Tn(t){t=this.__data__=new En(t);this.size=t.size}Tn.prototype.clear=Co,Tn.prototype.delete=H,Tn.prototype.get=jn,Tn.prototype.has=In,Tn.prototype.set=Mn;H=Tn;function zn(t,e){for(var o=-1,n=null==t?0:t.length;++o<n&&!1!==e(t[o],o,t););return t}var Dn=tn,jn=function(){try{var t=Dn(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),Rn=jn;function Bn(t,e,o){"__proto__"==e&&Rn?Rn(t,e,{configurable:!0,enumerable:!0,value:o,writable:!0}):t[e]=o}var Fn=Bn,Nn=uo,Zn=Object.prototype.hasOwnProperty;function qn(t,e,o){var n=t[e];Zn.call(t,e)&&Nn(n,o)&&(void 0!==o||e in t)||Fn(t,e,o)}var Hn=qn,Un=Bn;function Wn(t,e,o,n){for(var r=!o,i=(o=o||{},-1),s=e.length;++i<s;){var a=e[i],c=n?n(o[a],t[a],a,o,t):void 0;void 0===c&&(c=t[a]),(r?Un:Hn)(o,a,c)}return o}function Gn(t,e){for(var o=-1,n=Array(t);++o<t;)n[o]=e(o);return n}function Vn(t){return null!=t&&"object"==typeof t}var Kn=Ro,Yn=Vn;var In=function(t){return Yn(t)&&"[object Arguments]"==Kn(t)},Jn=Vn,$n=Object.prototype,Xn=$n.hasOwnProperty,Qn=$n.propertyIsEnumerable,$n=In(function(){return arguments}())?In:function(t){return Jn(t)&&Xn.call(t,"callee")&&!Qn.call(t,"callee")},In=Array.isArray,tr={exports:{}};i=(i=(r=tr).exports)&&!i.nodeType&&i,er=(er=i&&r&&!r.nodeType&&r)&&er.exports===i?e.Buffer:void 0,i=er?er.isBuffer:void 0,r.exports=i||function(){return!1};var er=tr.exports,or=/^(?:0|[1-9]\d*)$/;function nr(t,e){var o=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==o||"symbol"!=o&&or.test(t))&&-1<t&&t%1==0&&t<e}function rr(t){return"number"==typeof t&&-1<t&&t%1==0&&t<=9007199254740991}var ir=Ro,sr=rr,ar=Vn,n={};n["[object Float32Array]"]=n["[object Float64Array]"]=n["[object Int8Array]"]=n["[object Int16Array]"]=n["[object Int32Array]"]=n["[object Uint8Array]"]=n["[object Uint8ClampedArray]"]=n["[object Uint16Array]"]=n["[object Uint32Array]"]=!0,n["[object Arguments]"]=n["[object Array]"]=n["[object ArrayBuffer]"]=n["[object Boolean]"]=n["[object DataView]"]=n["[object Date]"]=n["[object Error]"]=n["[object Function]"]=n["[object Map]"]=n["[object Number]"]=n["[object Object]"]=n["[object RegExp]"]=n["[object Set]"]=n["[object String]"]=n["[object WeakMap]"]=!1;function cr(t){return ar(t)&&sr(t.length)&&!!n[ir(t)]}function lr(e){return function(t){return e(t)}}var ur,pr,r={exports:{}},R=(tr=(tr=(i=r).exports)&&!tr.nodeType&&tr,ur=tr&&i&&!i.nodeType&&i,pr=ur&&ur.exports===tr&&R.process,tr=function(){try{var t=ur&&ur.require&&ur.require("util").types;return t?t:pr&&pr.binding&&pr.binding("util")}catch(t){}}(),i.exports=tr,r.exports),i=cr,tr=lr,r=R&&R.isTypedArray,tr=r?tr(r):i,hr=Gn,dr=$n,fr=In,yr=er,mr=nr,gr=tr,vr=Object.prototype.hasOwnProperty;function wr(t,e){var o,n=fr(t),r=!n&&dr(t),i=!n&&!r&&yr(t),s=!n&&!r&&!i&&gr(t),a=n||r||i||s,c=a?hr(t.length,String):[],l=c.length;for(o in t)!e&&!vr.call(t,o)||a&&("length"==o||i&&("offset"==o||"parent"==o)||s&&("buffer"==o||"byteLength"==o||"byteOffset"==o)||mr(o,l))||c.push(o);return c}var _r=Object.prototype;function br(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||_r)}function xr(e,o){return function(t){return e(o(t))}}var r=xr(Object.keys,Object),Or=br,Sr=r,Cr=Object.prototype.hasOwnProperty;var Pr=Zo,Lr=rr;function kr(t){return null!=t&&Lr(t.length)&&!Pr(t)}var Ar=wr,Mr=function(t){if(!Or(t))return Sr(t);var e,o=[];for(e in Object(t))Cr.call(t,e)&&"constructor"!=e&&o.push(e);return o},Er=kr;function jr(t){return(Er(t)?Ar:Mr)(t)}var Ir=Wn,Tr=jr;function zr(t,e){return t&&Ir(e,Tr(e),t)}var Dr=Bo,Rr=br,Br=function(t){var e=[];if(null!=t)for(var o in Object(t))e.push(o);return e},Fr=Object.prototype.hasOwnProperty;var Nr=wr,Zr=function(t){if(!Dr(t))return Br(t);var e,o=Rr(t),n=[];for(e in t)("constructor"!=e||!o&&Fr.call(t,e))&&n.push(e);return n},qr=kr;function Hr(t){return qr(t)?Nr(t,!0):Zr(t)}var Ur=Wn,Wr=Hr;function Gr(t,e){return t&&Ur(e,Wr(e),t)}var Vr,i={exports:{}},Kr=(Kr=(Kr=(r=i).exports)&&!Kr.nodeType&&Kr,s=(s=Kr&&r&&!r.nodeType&&r)&&s.exports===Kr?e.Buffer:void 0,Vr=s?s.allocUnsafe:void 0,r.exports=function(t,e){return e?t.slice():(e=t.length,e=Vr?Vr(e):new t.constructor(e),t.copy(e),e)},i.exports);function Yr(t,e){var o=-1,n=t.length;for(e=e||Array(n);++o<n;)e[o]=t[o];return e}function Jr(){return[]}var $r=function(t,e){for(var o=-1,n=null==t?0:t.length,r=0,i=[];++o<n;){var s=t[o];e(s,o,t)&&(i[r++]=s)}return i},Xr=Object.prototype.propertyIsEnumerable,Qr=Object.getOwnPropertySymbols,s=Qr?function(e){return null==e?[]:(e=Object(e),$r(Qr(e),function(t){return Xr.call(e,t)}))}:Jr,ti=Wn,ei=s;function oi(t,e){return ti(t,ei(t),e)}function ni(t,e){for(var o=-1,n=e.length,r=t.length;++o<n;)t[r+o]=e[o];return t}var r=xr(Object.getPrototypeOf,Object),ri=ni,ii=r,si=s,i=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)ri(e,si(t)),t=ii(t);return e}:Jr,ai=Wn,ci=i;function li(t,e){return ai(t,ci(t),e)}var ui=ni,pi=In;function hi(t,e,o){return e=e(t),pi(t)?e:ui(e,o(t))}var di=hi,fi=s,yi=jr;function mi(t){return di(t,yi,fi)}var gi=hi,vi=i,wi=Hr;function _i(t){return gi(t,wi,vi)}var s=tn(e,"DataView"),i=o,o=tn(e,"Promise"),bi=tn(e,"Set"),xi=tn(e,"WeakMap"),Oi=Ro,Si=Uo,Ci="[object Map]",Pi="[object Promise]",Li="[object Set]",ki="[object WeakMap]",Ai="[object DataView]",Mi=Si(s),Ei=Si(i),ji=Si(o),Ii=Si(bi),Ti=Si(xi),a=Oi,s=a=s&&a(new s(new ArrayBuffer(1)))!=Ai||i&&a(new i)!=Ci||o&&a(o.resolve())!=Pi||bi&&a(new bi)!=Li||xi&&a(new xi)!=ki?function(t){var e=Oi(t),t="[object Object]"==e?t.constructor:void 0,t=t?Si(t):"";if(t)switch(t){case Mi:return Ai;case Ei:return Ci;case ji:return Pi;case Ii:return Li;case Ti:return ki}return e}:a,zi=Object.prototype.hasOwnProperty;function Di(t){var e=t.length,o=new t.constructor(e);return e&&"string"==typeof t[0]&&zi.call(t,"index")&&(o.index=t.index,o.input=t.input),o}var i=e.Uint8Array,Ri=i;function Bi(t){var e=new t.constructor(t.byteLength);return new Ri(e).set(new Ri(t)),e}var Fi=Bi;var Ni=/\w*$/;var o=Ao?Ao.prototype:void 0,Zi=o?o.valueOf:void 0;var qi=Bi;function Hi(t,e){return e=e?qi(t.buffer):t.buffer,new t.constructor(e,t.byteOffset,t.length)}var Ui=Bi,Wi=function(t,e){return e=e?Fi(t.buffer):t.buffer,new t.constructor(e,t.byteOffset,t.byteLength)},Gi=function(t){var e=new t.constructor(t.source,Ni.exec(t));return e.lastIndex=t.lastIndex,e},Vi=function(t){return Zi?Object(Zi.call(t)):{}},Ki=Hi;function Yi(t,e,o){var n=t.constructor;switch(e){case"[object ArrayBuffer]":return Ui(t);case"[object Boolean]":case"[object Date]":return new n(+t);case"[object DataView]":return Wi(t,o);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Ki(t,o);case"[object Map]":return new n;case"[object Number]":case"[object String]":return new n(t);case"[object RegExp]":return Gi(t);case"[object Set]":return new n;case"[object Symbol]":return Vi(t)}}var Ji=Bo,$i=Object.create;function Xi(){}var Qi=function(t){if(!Ji(t))return{};if($i)return $i(t);Xi.prototype=t;t=new Xi;return Xi.prototype=void 0,t},ts=r,es=br;function os(t){return"function"!=typeof t.constructor||es(t)?{}:Qi(ts(t))}var ns=s,rs=Vn;function is(t){return rs(t)&&"[object Map]"==ns(t)}var bi=lr,xi=R&&R.isMap,a=xi?bi(xi):is,ss=s,as=Vn;function cs(t){return as(t)&&"[object Set]"==ss(t)}var e=lr,o=R&&R.isSet,bi=o?e(o):cs,ls=H,us=zn,ps=qn,hs=zr,ds=Gr,fs=Kr,ys=Yr,ms=oi,gs=li,vs=mi,ws=_i,_s=s,bs=Di,xs=Yi,Os=os,Ss=In,Cs=er,Ps=a,Ls=Bo,ks=bi,As=jr,Ms=Hr,Es="[object Arguments]",js="[object Function]",Is="[object Object]",d={};d[Es]=d["[object Array]"]=d["[object ArrayBuffer]"]=d["[object DataView]"]=d["[object Boolean]"]=d["[object Date]"]=d["[object Float32Array]"]=d["[object Float64Array]"]=d["[object Int8Array]"]=d["[object Int16Array]"]=d["[object Int32Array]"]=d["[object Map]"]=d["[object Number]"]=d[Is]=d["[object RegExp]"]=d["[object Set]"]=d["[object String]"]=d["[object Symbol]"]=d["[object Uint8Array]"]=d["[object Uint8ClampedArray]"]=d["[object Uint16Array]"]=d["[object Uint32Array]"]=!0,d["[object Error]"]=d[js]=d["[object WeakMap]"]=!1;function Ts(o,n,r,t,e,i){var s,a=1&n,c=2&n,l=4&n;if(void 0===(s=r?e?r(o,t,e,i):r(o):s)){if(!Ls(o))return o;if(t=Ss(o)){if(s=bs(o),!a)return ys(o,s)}else{var u=_s(o),p=u==js||"[object GeneratorFunction]"==u;if(Cs(o))return fs(o,a);if(u==Is||u==Es||p&&!e){if(s=c||p?{}:Os(o),!a)return c?gs(o,ds(s,o)):ms(o,hs(s,o))}else{if(!d[u])return e?o:{};s=xs(o,u,a)}}if(p=(i=i||new ls).get(o))return p;i.set(o,s),ks(o)?o.forEach(function(t){s.add(Ts(t,n,r,t,o,i))}):Ps(o)&&o.forEach(function(t,e){s.set(e,Ts(t,n,r,e,o,i))});var h=t?void 0:(l?c?ws:vs:c?Ms:As)(o);us(h||o,function(t,e){h&&(t=o[e=t]),ps(s,e,Ts(t,n,r,e,o,i))})}return s}var zs=Ts;var c=B(function(t){return zs(t,5)}),Ds=Bn,Rs=uo;function Bs(t,e,o){(void 0===o||Rs(t[e],o))&&(void 0!==o||e in t)||Ds(t,e,o)}var xi=function(c){return function(t,e,o){for(var n=-1,r=Object(t),i=o(t),s=i.length;s--;){var a=i[c?s:++n];if(!1===e(r[a],a,r))break}return t}}(),Fs=kr,Ns=Vn;function Zs(t){return Ns(t)&&Fs(t)}var qs=Ro,Hs=r,Us=Vn,R=Function.prototype,e=Object.prototype,Ws=R.toString,Gs=e.hasOwnProperty,Vs=Ws.call(Object);function Ks(t){return!(!Us(t)||"[object Object]"!=qs(t))&&(null===(t=Hs(t))||"function"==typeof(t=Gs.call(t,"constructor")&&t.constructor)&&t instanceof t&&Ws.call(t)==Vs)}function Ys(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Js=Wn,$s=Hr;var Xs=Bs,Qs=Kr,ta=Hi,ea=Yr,oa=os,na=$n,ra=In,ia=Zs,sa=er,aa=Zo,ca=Bo,la=Ks,ua=tr,pa=Ys,ha=function(t){return Js(t,$s(t))};var da=H,fa=Bs,ya=xi,ma=function(t,e,o,n,r,i,s){var a,c,l,u=pa(t,o),p=pa(e,o),h=s.get(p);h||((e=void 0===(h=i?i(u,p,o+"",t,e,s):void 0))&&(c=!(a=ra(p))&&sa(p),l=!a&&!c&&ua(p),h=p,a||c||l?h=ra(u)?u:ia(u)?ea(u):c?Qs(p,!(e=!1)):l?ta(p,!(e=!1)):[]:la(p)||na(p)?na(h=u)?h=ha(u):ca(u)&&!aa(u)||(h=oa(p)):e=!1),e&&(s.set(p,h),r(h,p,n,i,s),s.delete(p))),Xs(t,o,h)},ga=Bo,va=Hr,wa=Ys;function _a(t){return t}var ba=function(t,e,o){switch(o.length){case 0:return t.call(e);case 1:return t.call(e,o[0]);case 2:return t.call(e,o[0],o[1]);case 3:return t.call(e,o[0],o[1],o[2])}return t.apply(e,o)},xa=Math.max;var Oa=function(t){return function(){return t}},Sa=jn,Ca=Date.now;var o=function(o){var n=0,r=0;return function(){var t=Ca(),e=16-(t-r);if(r=t,0<e){if(800<=++n)return arguments[0]}else n=0;return o.apply(void 0,arguments)}}(Sa?function(t,e){return Sa(t,"toString",{configurable:!0,enumerable:!1,value:Oa(e),writable:!0})}:_a),Pa=_a,La=function(i,s,a){return s=xa(void 0===s?i.length-1:s,0),function(){for(var t=arguments,e=-1,o=xa(t.length-s,0),n=Array(o);++e<o;)n[e]=t[s+e];for(var e=-1,r=Array(s+1);++e<s;)r[e]=t[e];return r[s]=a(n),ba(i,this,r)}},ka=o;var Aa=uo,Ma=kr,Ea=nr,ja=Bo;var Ia=function(t,e){return ka(La(t,e,Pa),t+"")},Ta=function(t,e,o){var n;return!!ja(o)&&!!("number"==(n=typeof e)?Ma(o)&&Ea(e,o.length):"string"==n&&e in o)&&Aa(o[e],t)};var za,Da,Ra=function n(r,i,s,a,c){r!==i&&ya(i,function(t,e){var o;c=c||new da,ga(t)?ma(r,i,e,s,n,a,c):(o=a?a(wa(r,e),t,e+"",r,i,c):void 0,fa(r,e,o=void 0===o?t:o))},va)},Ba=B(function(a){return Ia(function(t,e){var o=-1,n=e.length,r=1<n?e[n-1]:void 0,i=2<n?e[2]:void 0,r=3<a.length&&"function"==typeof r?(n--,r):void 0;for(i&&Ta(e[0],e[1],i)&&(r=n<3?void 0:r,n=1),t=Object(t);++o<n;){var s=e[o];s&&a(t,s,o,r)}return t})}(function(t,e,o){Ra(t,e,o)})),Fa=((window&&window.__extends||(za=function(t,e){return(za=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}za(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Na,Da=t),Na);function Na(){var t=null!==Da&&Da.apply(this,arguments)||this;return t.layout="icons",t.mapStyles=["road","grayscale_light","grayscale_dark","night","road_shaded_relief"],t.style=u.ControlStyle.light,t.autoSelectionMode=!0,t}var Za,qa,a=window&&window.__extends||(Za=function(t,e){return(Za=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Za(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ha=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},Ua=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},Wa=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},bi=(a(l,qa=We),l.prototype.onAdd=function(t,e){function o(t){t?(r.classList.add(l.Css.inUse),i.classList.remove("hidden-accessible-element")):(r.classList.remove(l.Css.inUse),i.classList.add("hidden-accessible-element"))}var n=this,r=(this.map=t,this.buildContainer(t,this.options.style,"Map Style Control")),i=this.buildStyleOpsGrid(),s=(this.styleOpsGrid=i,this.buildCurrStyleBtn()),t=_("Select Style");return i.classList.add(e&&e.position||"top-right"),r.addEventListener("mouseover",function(){n.hasMouse=!0,o(!0)}),r.addEventListener("focusin",function(){n.hasFocus=!0,o(!0)}),r.addEventListener("mouseleave",function(){n.hasMouse=!1,n.hasFocus||o(!1)}),r.addEventListener("focusout",function(t){t.target===s&&Array.from(i.children).forEach(function(t){return t.removeAttribute("tabIndex")}),t.relatedTarget instanceof Node&&r.contains(t.relatedTarget)||(n.hasFocus=!1,n.hasMouse)||o(!1)}),i.addEventListener("keydown",function(t){27===t.keyCode&&(t.stopPropagation(),s.focus(),Array.from(i.children).forEach(function(t){return t.setAttribute("tabIndex","-1")}),r.classList.contains(l.Css.inUse))&&o(!1)}),s.addEventListener("click",function(t){r.classList.contains(l.Css.inUse)?o(!1):(o(!0),i.firstElementChild&&i.firstElementChild.focus())}),e&&l.InvertOrderPositions.includes(e.position)?(r.appendChild(i),r.appendChild(s),r.appendChild(t),b(t,s)):(r.appendChild(s),r.appendChild(t),b(t,s),r.appendChild(i)),r},l.prototype.onRemove=function(){qa.prototype.onRemove.call(this),this.styleOpsGrid=null,this.styleButtons.clear(),this.thumbnailCache.response.clear(),this.thumbnailCache.blob.clear(),this.thumbnailCache.assumedConfiguration=void 0,this.map.events.remove("stylechanged",this.onStyleChange),this.map.events.remove("mapconfigurationchanged",this.onMapConfigurationChange)},l.prototype.setSelectedStyle=function(o){var e,t,n=this;this.styleIcons.has(o)&&(e=this.currStyleImage,t=this.styleIcons.get(o),e.src!==t&&(e.src=t),Object.entries(this.styleButtons).forEach(function(t){var t=Wa(t,2),e=t[0];return t[1].setAttribute("aria-current",e===o?"true":"false")}),this.map.styles.definitions().then(function(t){t=n.mapToFriendlyStyleName(o,t);e.alt!==t&&(e.alt=t),e.parentElement.lastChild instanceof Text&&(e.parentElement.lastChild.textContent=t)}))},l.prototype.disableStyle=function(t){t=this.styleButtons[t];t&&t.setAttribute("disabled","true")},l.prototype.enableStyle=function(t){t=this.styleButtons[t];t&&t.removeAttribute("disabled")},l.prototype.buildSelectStyleBtn=function(o,t,e){var n=this,r=document.createElement("button"),i=this.mapToFriendlyStyleName(o,t),s=(r.setAttribute("aria-label",i),r.setAttribute("type","button"),new Image),t=(e.then(function(t){var e;return n.thumbnailCache.blob.has(t.url)?n.thumbnailCache.blob.get(t.url):(e=t.clone().blob(),n.thumbnailCache.blob.set(t.url,e),e)}).then(function(t){t=URL.createObjectURL(t);s.src=t,o===n.map.getStyle().style&&(n.currStyleImage.src=t,n.currStyleImage.alt=i,n.currStyleImage.parentElement.lastChild.nodeType==Node.TEXT_NODE?n.currStyleImage.parentElement.lastChild.textContent=i:n.currStyleImage.parentElement.appendChild(document.createTextNode(i))),n.styleIcons.set(o,t)}),s.setAttribute("aria-hidden","true"),r.appendChild(s),"icons"===this.options.layout?r.classList.add(l.Css.button):(r.classList.add(l.Css.listButton),r.classList.add(l.Css.expanded),r.appendChild(document.createTextNode(i))),r.addEventListener("click",function(){n.hasMouse=!1,n.hasFocus=!1;var t=n.styleButtons[o];t&&!t.hasAttribute("disabled")&&(n._invokeEvent("styleselected",o),n.options.autoSelectionMode&&n.map.setStyle({style:o}),Object.entries(n.styleButtons).forEach(function(t){var t=Wa(t,2),e=t[0];return t[1].setAttribute("aria-current",e===o?"true":"false")}))}),document.createElement("div"));return t.classList.add("selected-icon"),r.appendChild(t),r},l.prototype.buildCurrStyleBtn=function(){var t=document.createElement("button"),e=("icons"==this.options.layout?t.classList.add(l.Css.button):t.classList.add(l.Css.listButton),t.classList.add(l.Css.currentStyle),t.setAttribute("aria-label","Select Style"),t.setAttribute("tabindex","-1"),this.currStyleImage=new Image,t.appendChild(this.currStyleImage),document.createElement("div"));return e.classList.add("icon"),t.appendChild(e),t},l.prototype.buildStyleOpsGrid=function(){var t=this,e=document.createElement("div");return e.classList.add(l.Css.styleOptions),"icons"===this.options.layout?e.classList.add(this.options.layout):e.classList.add(l.Css.dropdown),e.setAttribute("aria-label","Style Options"),e.classList.add("hidden-accessible-element"),this.map.styles.definitions().then(function(e){return Ha(t,void 0,void 0,function(){return Ua(this,function(t){return this.onMapConfigurationChange(e),this.map.events.add("stylechanged",this.onStyleChange),[2]})})}),this.map.events.add("mapconfigurationchanged",this.onMapConfigurationChange),e},l.prototype.populateOpsGridFromDefinitions=function(r){var t,o,i=this;this.styleOpsGrid&&(t=r.configurations,(t=Array.isArray(this.options.mapStyles)?t.filter(function(t){return i.options.mapStyles.includes(t.name.split("_indoor")[0])}):t).forEach(function(t){var e,o={url:t.thumbnail},n=(t.thumbnail&&i.map.styles._transformStyleRequest(t.thumbnail,o),i.map.getServiceOptions()),n=(n.transformRequest&&Ba(o,n.transformRequest(o.url,"Thumbnail")),i.thumbnailCache.response.has(o.url)?e=Promise.resolve(i.thumbnailCache.response.get(o.url)):(e=fetch(o.url,{headers:o.headers}),i.thumbnailCache.response.set(o.url,e)),i.buildSelectStyleBtn(t.name,r,e));i.styleOpsGrid.appendChild(n),i.styleButtons[t.name]=n,"icons"===i.options.layout&&(o=_(i.mapToFriendlyStyleName(t.name,r)),i.styleOpsGrid.appendChild(o),b(o,n))}),o=this.map.getStyle().style,Object.entries(this.styleButtons).forEach(function(t){var t=Wa(t,2),e=t[0];return t[1].setAttribute("aria-current",e===o?"true":"false")}))},l.InvertOrderPositions=[u.ControlPosition.TopRight,u.ControlPosition.BottomRight],l.Css={button:"azure-maps-control-button",listButton:"azure-maps-control-list-button",expanded:"expanded",currentStyle:"curr-style",inUse:"in-use",styleOptions:"style-options",dropdown:"azure-maps-control-dropdown"},l);function l(t){var e=qa.call(this)||this;return e.styleOpsGrid=null,e.hasMouse=!1,e.hasFocus=!1,e.styleButtons=new Ne,e.styleIcons=new Ne,e.thumbnailCache={assumedConfiguration:void 0,response:new Ne,blob:new Ne},e.onStyleChange=function(){var t;e.options.autoSelectionMode&&(t=e.map.getStyle().style,e.setSelectedStyle(t))},e.onMapConfigurationChange=function(t){!e.styleOpsGrid||0<e.styleOpsGrid.children.length&&e.thumbnailCache.assumedConfiguration===t||(e.thumbnailCache.assumedConfiguration=t,Array.from(e.styleOpsGrid.children).forEach(function(t){return t.remove()}),e.styleButtons.clear(),e.populateOpsGridFromDefinitions(t))},e.mapToFriendlyStyleName=function(e,t){t=t.configurations.find(function(t){return t.name===e});return(null==t?void 0:t.displayName)||e},e.options=(new Fa).merge(c(t)),e}(window&&window.__extends||(Ga=function(t,e){return(Ga=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ga(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ya,Va=t);var Ga,Va,Ka=Ya;function Ya(){var t=null!==Va&&Va.apply(this,arguments)||this;return t.flow="none",t.incidents=!1,t}(window&&window.__extends||(Ja=function(t,e){return(Ja=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ja(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Qa,$a=Ka);var Ja,$a,Xa=Qa;function Qa(){var t=null!==$a&&$a.apply(this,arguments)||this;return t.isActive=!1,t.style=u.ControlStyle.light,t}(window&&window.__extends||(tc=function(t,e){return(tc=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}tc(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(nc,ec=We),Object.defineProperty(nc.prototype,"isActive",{get:function(){var t;return!!this.map&&("none"!==(t=this.map.getTraffic()).flow||t.incidents)},set:function(t){this.map&&this.map.setTraffic({flow:t?this.options.flow:"none",incidents:!!t&&this.options.incidents})},enumerable:!1,configurable:!0}),nc.prototype.onAdd=function(t){(this.map=t).getTraffic(),void 0!==this.initIsActive&&(this.isActive=this.initIsActive),this.container=this.buildContainer(t,this.style,"Traffic Control"),this.container.style.flexDirection="column";var t=this.constructTrafficButton(t),e=(this.container.appendChild(t),_("Toggle Traffic Display"));return this.container.appendChild(e),b(e,t),this.container},nc.prototype.onRemove=function(){ec.prototype.onRemove.call(this),this.map=null},nc.prototype.getOptions=function(){return(new Xa).merge({isActive:this.isActive,flow:this.options.flow,incidents:this.options.incidents,style:this.style})},nc.prototype.updateButtonState=function(){this.trafficButton&&(this.isActive?(this.container.classList.add("in-use"),this.trafficButton.setAttribute("aria-description","Traffic is displayed")):(this.container.classList.remove("in-use"),this.trafficButton.removeAttribute("aria-description")),this.trafficButton.setAttribute("aria-pressed",this.isActive?"true":"false"))},nc.prototype.constructTrafficButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("traffic"),o.setAttribute("aria-label","Toggle Traffic Display"),o.setAttribute("alt","Toggle Traffic Display"),o.setAttribute("type","button"),this.trafficButton=o,this.updateButtonState(),o.addEventListener("click",function(){e.isActive=!e.isActive}),o};var tc,ec,oc=nc;function nc(t){var e,o=this;return(o=ec.call(this)||this).hasMouse=!1,o.hasFocus=!1,o.options=(new Ka).merge({flow:"relative",incidents:!0}),o.style=u.ControlStyle.light,o.container=null,o.trafficButton=null,o.map=null,t&&(o.initIsActive=null!=(e=t.isActive)&&e,o.options.flow=t.flow||"relative",o.options.incidents=null==(e=t.incidents)||e,o.style=t.style||u.ControlStyle.light),o}var rc,ic,r=window&&window.__extends||(rc=function(t,e){return(rc=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}rc(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),sc=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},R=(r(ac,ic=We),ac.prototype.onAdd=function(t){this.map=t;var e=this.buildContainer(t,u.ControlStyle.auto,"Traffic Legend"),t=this.buildTrafficLegendDiv(t);return e.setAttribute("role","definition"),e.appendChild(t),e},ac.prototype.onRemove=function(){ic.prototype.onRemove.call(this),this.syncHiddenState&&(this.map.events.remove("styledata",this.syncHiddenState),this.syncHiddenState=null),this.map=null},ac.prototype.buildTrafficLegendDiv=function(e){var o,t,n,r,i=document.createElement("div"),s=(i.classList.add("traffic-legend","hidden"),i.setAttribute("alt","Traffic Legend"),document.createElement("table")),a=document.createElement("tr"),c=document.createElement("td"),l=(c.setAttribute("alt","Traffic"),c.appendChild(document.createTextNode("Traffic")),_("Traffic")),u=(c.classList.add("traffic-legend-title"),c.colSpan=6,a.appendChild(c),a.appendChild(l),b(l,c),s.appendChild(a),document.createElement("tr"));try{for(var p=sc(this.table),h=p.next();!h.done;h=p.next()){var d=h.value,f=document.createElement("td");if("Fast"===d||"Slow"===d)f.setAttribute("alt",d),f.appendChild(document.createTextNode(d)),f.classList.add("traffic-legend-text");else{f.classList.add("traffic-legend-colors"),f.setAttribute("aria-label","Traffic Legend"),f.setAttribute("role","img");try{n=void 0;for(var y=sc(d),m=y.next();!m.done;m=y.next()){var g=m.value,v=document.createElement("div");v.classList.add(g),f.appendChild(v)}}catch(t){n={error:t}}finally{try{m&&!m.done&&(r=y.return)&&r.call(y)}finally{if(n)throw n.error}}}u.appendChild(f);var w=_(d instanceof Array?"Traffic Legend":d);u.appendChild(w),b(w,f)}}catch(t){o={error:t}}finally{try{h&&!h.done&&(t=p.return)&&t.call(p)}finally{if(o)throw o.error}}return s.appendChild(u),i.appendChild(s),this.syncHiddenState=function(t){"style"===t.dataType&&((t=e.getTraffic()).flow&&"none"!==t.flow?i.classList.remove("hidden"):i.classList.add("hidden"))},this.syncHiddenState({dataType:"style"}),e.events.add("styledata",this.syncHiddenState),i},ac);function ac(){var t=ic.call(this)||this;return t.table=["Fast",["green","yellow","red","dark-red"],"Slow"],t.map=null,t.syncHiddenState=null,t}function cc(t){return this.__data__.has(t)}var lc=Jo;function uc(t){var e=-1,o=null==t?0:t.length;for(this.__data__=new lc;++e<o;)this.add(t[e])}uc.prototype.add=uc.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},uc.prototype.has=cc;var pc=uc,hc=function(t,e){for(var o=-1,n=null==t?0:t.length;++o<n;)if(e(t[o],o,t))return!0;return!1},dc=function(t,e){return t.has(e)};function fc(t,e,o,n,r,i){var s=1&o,a=t.length,c=e.length;if(a!=c&&!(s&&a<c))return!1;var c=i.get(t),l=i.get(e);if(c&&l)return c==e&&l==t;var u=-1,p=!0,h=2&o?new pc:void 0;for(i.set(t,e),i.set(e,t);++u<a;){var d,f=t[u],y=e[u];if(void 0!==(d=n?s?n(y,f,u,e,t,i):n(f,y,u,t,e,i):d)){if(d)continue;p=!1;break}if(h){if(!hc(e,function(t,e){if(!dc(h,e)&&(f===t||r(f,t,o,n,i)))return h.push(e)})){p=!1;break}}else if(f!==y&&!r(f,y,o,n,i)){p=!1;break}}return i.delete(t),i.delete(e),p}function yc(t){var o=-1,n=Array(t.size);return t.forEach(function(t,e){n[++o]=[e,t]}),n}function mc(t){var e=-1,o=Array(t.size);return t.forEach(function(t){o[++e]=t}),o}var gc=i,vc=uo,wc=fc,e=Ao?Ao.prototype:void 0,_c=e?e.valueOf:void 0;var bc=mi,xc=Object.prototype.hasOwnProperty;var Oc=H,Sc=fc,Cc=function(t,e,o,n,r,i,s){switch(o){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return t.byteLength==e.byteLength&&i(new gc(t),new gc(e))?!0:!1;case"[object Boolean]":case"[object Date]":case"[object Number]":return vc(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var a=yc;case"[object Set]":a=a||mc;if(t.size!=e.size&&!(1&n))return!1;var c=s.get(t);if(c)return c==e;n|=2,s.set(t,e);c=wc(a(t),a(e),n,r,i,s);return s.delete(t),c;case"[object Symbol]":if(_c)return _c.call(t)==_c.call(e)}return!1},Pc=function(t,e,o,n,r,i){var s=1&o,a=bc(t),c=a.length;if(c!=bc(e).length&&!s)return!1;for(var l=c;l--;){var u=a[l];if(!(s?u in e:xc.call(e,u)))return!1}var p=i.get(t),h=i.get(e);if(p&&h)return p==e&&h==t;for(var d=!0,f=(i.set(t,e),i.set(e,t),s);++l<c;){var y,m=t[u=a[l]],g=e[u];if(!(void 0===(y=n?s?n(g,m,u,e,t,i):n(m,g,u,t,e,i):y)?m===g||r(m,g,o,n,i):y)){d=!1;break}f=f||"constructor"==u}return d&&!f&&(p=t.constructor)!=(h=e.constructor)&&"constructor"in t&&"constructor"in e&&!("function"==typeof p&&p instanceof p&&"function"==typeof h&&h instanceof h)&&(d=!1),i.delete(t),i.delete(e),d},Lc=s,kc=In,Ac=er,Mc=tr,Ec="[object Arguments]",jc="[object Array]",Ic="[object Object]",Tc=Object.prototype.hasOwnProperty;var zc=function(t,e,o,n,r,i){var s=kc(t),a=kc(e),c=s?jc:Lc(t),a=a?jc:Lc(e),l=(c=c==Ec?Ic:c)==Ic,u=(a=a==Ec?Ic:a)==Ic;if((a=c==a)&&Ac(t)){if(!Ac(e))return!1;l=!(s=!0)}if(a&&!l)return i=i||new Oc,s||Mc(t)?Sc(t,e,o,n,r,i):Cc(t,e,c,o,n,r,i);if(!(1&o)){s=l&&Tc.call(t,"__wrapped__"),c=u&&Tc.call(e,"__wrapped__");if(s||c)return r(s?t.value():t,c?e.value():e,o,n,i=i||new Oc)}return a&&(i=i||new Oc,Pc(t,e,o,n,r,i))},Dc=Vn;var Rc=function t(e,o,n,r,i){return e===o||(null==e||null==o||!Dc(e)&&!Dc(o)?e!=e&&o!=o:zc(e,o,n,r,t,i))};var Bc=B(function(t,e){return Rc(t,e)}),Fc=(Nc.TYPE="Feature",Nc);function Nc(t,e,o,n){this.type="Feature",this.type=Nc.TYPE,this.properties=e||{},this.id=o,this.geometry=t,this.bbox=n}var Zc,qc,Kr=window&&window.__extends||(Zc=function(t,e){return(Zc=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Zc(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Hc=(qc=Array,Kr(p,qc),p.fromData=function(o){var n=NaN,r=NaN,i=new Set(["y"]),s=new Set(["x"]);return Object.keys(o).forEach(function(t){var e=t.toLowerCase();isNaN(n)&&i.has(e)&&"number"==typeof o[t]?n=o[t]:isNaN(r)&&s.has(e)&&"number"==typeof o[t]&&(r=o[t])}),isNaN(n)||isNaN(r)?null:new p(n,r)},p.getX=function(t){return 0<t.length?t[0]:NaN},p.getY=function(t){return 1<t.length?t[1]:NaN},p.getDestination=function(t,e,o){return new p(p.getX(t)+o*Math.cos((e+270)*Math.PI/180),p.getY(t)+o*Math.sin((e+270)*Math.PI/180))},p.getDistance=function(t,e){var o=p.getX(t)-p.getX(e),t=p.getY(t)-p.getY(e);return Math.sqrt(o*o+t*t)},p.getHeading=function(t,e){var o=p.getX(e)-p.getX(t),t=p.getY(t)-p.getY(e);return 180*(2.5*Math.PI-Math.atan2(t,o))/Math.PI%360},p);function p(t,e){return qc.call(this,t,e)||this}Wc.TYPE="Point";var Uc=Wc;function Wc(t){this.type="Point",this.type=Wc.TYPE,this.coordinates=t}var h,f,y,m,g,Gc=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Vc=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Kc=6378137,Yc=Math.PI/180,Jc=180/Math.PI,$c=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9],Xc=85.0511;function Qc(t){return t*Yc}function tl(t){return t*Jc}function el(t,e,o){return Math.min(Math.max(t,e),o)}function ol(t,e){var o=Qc(e[1]-t[1]),n=Qc(e[0]-t[0]),o=Math.pow(Math.sin(o/2),2)+Math.cos(Qc(t[1]))*Math.cos(Qc(e[1]))*Math.pow(Math.sin(n/2),2),t=2*Math.atan2(Math.sqrt(o),Math.sqrt(1-o));return Math.round(Kc*t*100)/100}function nl(t){if(t)switch(t.toLowerCase()){case"feet":case"foot":case"ft":return f.feet;case"kilometers":case"kilometer":case"kilometres":case"kilometre":case"km":case"kms":return f.kilometers;case"miles":case"mile":case"mi":return f.miles;case"nauticalmiles":case"nauticalmile":case"nms":case"nm":return f.nauticalMiles;case"yards":case"yard":case"yds":case"yrd":case"yrds":return f.yards;default:return f.meters}return f.meters}function rl(t){if(t)switch(t.toLowerCase()){case"milespersecondsquared":case"milepersecondsquared":case"mi/s^2":case"mi/s2":return g.milesPerSecondSquared;case"kilometerspersecondsquared":case"kilometrespersecondsquared":case"kilometerpersecondsquared":case"kilometrepersecondsquared":case"km/s^2":case"km/s2":return g.kilometersPerSecondSquared;case"knotspersecond":case"knotpersecond":case"knts/s":case"kn/s":case"kt/s":return g.knotsPerSecond;case"standardgravity":case"g":return g.standardGravity;case"feetpersecondsquared":case"footpersecondsquared":case"ft/s^2":case"ft/s2":return g.feetPerSecondSquared;case"yardspersecondsquared":case"yardpersecondsquared":case"yds/s^2":case"yds/s2":case"yd/s^2":case"yd/s2":return g.yardsPerSecondSquared;case"milesperhoursecond":case"mileperhoursecond":case"milesperhourseconds":case"mileperhourseconds":case"mi/h/s":return g.milesPerHourSecond;case"kilometersperhoursecond":case"kilometrespersoursecond":case"kilometerperhoursecond":case"kilometrepersoursecond":case"kilometersperhourssecond":case"kilometrespersourssecond":case"kilometerperhourssecond":case"kilometrepersourssecond":case"kmhs":case"km/h/s":return g.kilometersPerHourSecond;default:return g.metersPerSecondSquared}return g.metersPerSecondSquared}function il(t){if(t)switch(t){case"acres":case"ac":return h.acres;case"hectares":case"ha":return h.hectares;case"squareFeet":case"ft^2":case"ft2":return h.squareFeet;case"squareYards":case"squareYard":case"yds^2":case"yds2":case"yd^2":case"yd2":return h.squareYards;case"squareKilometers":case"squareKilometres":case"squareKilometer":case"squareKilometre":case"km^2":case"km2":return h.squareKilometers;case"squareMiles":case"squareMile":case"mi^2":case"mi2":return h.squareMiles;default:return h.squareMeters}return h.squareMeters}function sl(t){if(t)switch(t.toLowerCase()){case"feetpersecond":case"footsecond":case"ftps":case"ft/s":return m.feetPerSecond;case"milesperhour":case"mileperhour":case"mph":case"mi/hr":case"mi/h":return m.milesPerHour;case"knots":case"knot":case"knts":case"knt":case"kn":case"kt":return m.knots;case"mach":case"m":return m.mach;case"kilometersperhour":case"kilometresperhour":case"kmperhour":case"kmph":case"km/hr":case"km/h":return m.kilometersPerHour;default:return m.metersPerSecond}return m.metersPerSecond}function al(t){if(t)switch(t.toLowerCase()){case"milliseconds":case"ms":return y.ms;case"minutes":case"minute":case"mins":case"min":return y.minutes;case"hours":case"hour":case"hr":case"h":return y.hours;case"days":case"day":case"d":return y.days;default:return y.seconds}return y.seconds}function cl(t){var e=0;if(t&&0<t.length)for(var e=Math.abs(ll(t[0])),o=1,n=t.length;o<n;o++)e-=Math.abs(ll(t[o]));return e}function ll(t){var e=0;if(3<=t.length){for(var o=void 0,n=void 0,r=0,i=t.length;r<i;r++)e+=(Qc(t[r===i-2?(o=i-2,n=i-1,0):r===i-1?(o=i-1,n=0,1):(n=(o=r)+1,r+2)][0])-Qc(t[o][0]))*Math.sin(Qc(t[n][1]));e=e*Kc*Kc/2}return e}function ul(t,e,o){return(t[0]-o[0])*(e[1]-o[1])-(t[1]-o[1])*(e[0]-o[0])}function pl(t,e,o){if(2<=o.length){for(var n,r,i,s=1/0,a=null,c=Ll(o,22),l=0,u=c.length-1;l<u;l++)r=function(t,e,o){if(e[0]===o[0]&&e[1]===o[1])return e;var n=t[0]-e[0],t=t[1]-e[1],r=o[0]-e[0],i=o[1]-e[1],n=(r*n+i*t)/(r*r+i*i);return n<0?e:1<n?o:[e[0]+r*n,e[1]+i*n]}(e,c[l],c[l+1]),(n=Hc.getDistance(e,r))<s&&(s=n,a=r);if(a)return i=Pl([a],22)[0],new Fc(new Uc(i),{distance:yl(t,i)})}else if(1===o.length)return new Fc(new Uc(o[0]),{distance:yl(t,o[0])});return null}function hl(t,e){var o;return!isNaN(t)&&"number"==typeof e&&0<=e&&(o=void 0,o=e<$c.length?$c[e]:Math.pow(10,e),t=Math.round(t*o)/o),t}function dl(t,e,o,n){switch(nl(e)){case f.meters:t/=1e3;break;case f.feet:t/=3280.8399;break;case f.miles:t/=.62137119;break;case f.yards:t/=1093.6133;break;case f.nauticalMiles:t/=.5399568;break;case f.kilometers:}switch(nl(o)){case f.meters:t*=1e3;break;case f.feet:t*=3280.8399;break;case f.miles:t*=.62137119;break;case f.yards:t*=1093.6133;break;case f.nauticalMiles:t*=.5399568;break;case f.kilometers:}return"number"==typeof n&&0<=n&&(e=Math.pow(10,n),t=Math.round(t*e)/e),t}function fl(t,e,o,n){n=n||"meters",t=Rl(t);var n=ml(n),r=Qc(t[1]),t=Qc(t[0]),e=e*Yc,o=o/n,n=Math.asin(Math.sin(r)*Math.cos(o)+Math.cos(r)*Math.sin(o)*Math.cos(e)),t=t+Math.atan2(Math.sin(e)*Math.sin(o)*Math.cos(r),Math.cos(o)-Math.sin(r)*Math.sin(n)),e=el(v(n*Jc),-85,85);return[w(t*Jc),e]}function yl(t,e,o){t=ol(t=Rl(t),e=Rl(e));return"meters"===o?t:dl(t,"meters",o||"meters")}function ml(t){t=nl(t);return dl(Kc,f.meters,t)}function gl(t,e,o){for(var n=[],r=Qc(t[1]),i=Qc(t[0]),s=Qc(e[1]),a=Qc(e[0]),c=2*Math.asin(Math.sqrt(Math.pow(Math.sin((r-s)/2),2)+Math.cos(r)*Math.cos(s)*Math.pow(Math.sin((i-a)/2),2))),l=0;l<=o;l++){var u=l/o,p=Math.sin((1-u)*c)/Math.sin(c),u=Math.sin(u*c)/Math.sin(c),h=p*Math.cos(r)*Math.cos(i)+u*Math.cos(s)*Math.cos(a),d=p*Math.cos(r)*Math.sin(i)+u*Math.cos(s)*Math.sin(a),p=p*Math.sin(r)+u*Math.sin(s),u=Math.atan2(p,Math.sqrt(Math.pow(h,2)+Math.pow(d,2))),p=Math.atan2(d,h),u=el(u*Jc,-85,85);n.push([p*=Jc,u])}return n}function vl(t){return(Array.isArray(t)?t:t.coordinates).reduce(function(t,e){var o=0<t.length?t[t.length-1]:null;return o&&180<Math.abs(e[0]-o[0])?(o=o[0]<0?e[0]-360:e[0]+360,t.push([o,e[1]])):t.push(e),t},[])}function wl(t){for(var e,o,n,r,i,s=Array.isArray(t)?t:t.coordinates,a=[],c=[],l=0;l<s.length;l++)a.push(s[l]),l+1>=s.length||(e=(o=Gc(s[l],2))[0],o=o[1],r=(i=Gc(s[l+1],2))[0],i=i[1],180<Math.abs(r-e)&&(n=0<e?180:-180,r=Math.abs((0<e?r+360:r-360)-e),i=o+(i-o)*(Math.abs(n-e)/r),a.push([n,i]),c.push(a),a=[[-n,i]]));return c.push(a),c}function _l(t,e){var o,n;return t=Rl(t),e=Rl(e),t&&2<=t.length&&e&&2<=e.length?(n=Qc(t[1]),o=Qc(e[1]),e=Qc(e[0]-t[0]),t=Math.sin(e)*Math.cos(o),n=Math.cos(n)*Math.sin(o)-Math.sin(n)*Math.cos(o)*Math.cos(e),(tl(Math.atan2(t,n))+360)%360):NaN}function bl(t,e){var o,n=0;Array.isArray(t)?o=t:t.type&&"LineString"===t.type&&(o=t.coordinates);for(var r=0,i=o.length-1;r<i;r++)n+=ol(o[r],o[r+1]);return dl(n,"meters",e||"meters")}function xl(t,e,o){o=o||"meters";var n,r=0;if(Array.isArray(t)?n=t:t.type&&"LineString"===t.type&&(n=t.coordinates),2<=n.length){for(var i,s,a=n.length,c=1;c<a;c++){if(e<=r+(s=yl(n[c-1],n[c],o)))return i=_l(n[c-1],n[c]),fl(n[c-1],i,e-r,o);r+=s}return r<=e?n[a-1]:n[0]}return null}function Ol(t,e,o,n,r){n=n||"meters",r=r||0,t=Rl(t);for(var i=[],s=360/o,a=0;a<=o;a++)i.push(fl(t,(a*s+r)%360,e,n));return i}function Sl(t,e,o,n,r){return vl(Ol(t,e,o,n,r))}function v(t){return 90<t?180<(t=(t+90)%360)?90-(t-180):t-90:t<-90?(t=(t-90)%360)<-180?-90-(t+180):t+90:t}function w(t){return 180<t?(t+180)%360-180:t<-180?(t-180)%360+180:t}function Cl(t,e,o){if(0===o)return Object.assign({},t);e=Rl(e);for(var n,r,i=[],s=0,a=t.length;s<a;s++)n=yl(e,t[s]),r=_l(e,t[s]),i.push(fl(e,r+o,n));return i}function Pl(t,e){for(var o,n,r=512*Math.pow(2,e),i=[],s=0,a=t.length;s<a;s++)o=t[s][0]/r-.5,n=.5-t[s][1]/r,i.push([360*o,90-360*Math.atan(Math.exp(2*-n*Math.PI))/Math.PI]);return i}function Ll(t,e){for(var o,n,r=512*Math.pow(2,e),i=[],s=0,a=t.length;s<a;s++)n=Math.sin(t[s][1]*Math.PI/180),o=(t[s][0]+180)/360,n=.5-Math.log((1+n)/(1-n))/(4*Math.PI),i.push([Math.round(o*r),Math.round(n*r)]);return i}function kl(t,e,o,n){switch(rl(e)){case g.kilometersPerHourSecond:t/=3.6;break;case g.milesPerHourSecond:t/=2.236936292054;break;case g.knotsPerSecond:t/=1.943844492441;break;case g.standardGravity:t/=.1019716212978;break;case g.kilometersPerSecondSquared:t/=.001;break;case g.milesPerSecondSquared:t/=.000621371192;break;case g.feetPerSecondSquared:t/=3.280839895012;break;case g.yardsPerSecondSquared:t/=1.093613298338;break;case g.metersPerSecondSquared:}switch(rl(o)){case g.kilometersPerHourSecond:t*=3.6;break;case g.milesPerHourSecond:t*=2.236936292054;break;case g.knotsPerSecond:t*=1.943844492441;break;case g.standardGravity:t*=.1019716212978;break;case g.kilometersPerSecondSquared:t*=.001;break;case g.milesPerSecondSquared:t*=.000621371192;break;case g.feetPerSecondSquared:t*=3.280839895012;break;case g.yardsPerSecondSquared:t*=1.093613298338;break;case g.metersPerSecondSquared:}return hl(t,n)}function Al(t,e,o,n){switch(il(e)){case h.acres:t*=4046.8564224;break;case h.hectares:t*=1e4;break;case h.squareFeet:t*=.09290304;break;case h.squareKilometers:t*=1e6;break;case h.squareMiles:t*=259e4;break;case h.squareYards:t*=.83612736;break;case h.squareMeters:}switch(il(o)){case h.acres:t/=4046.8564224;break;case h.hectares:t/=1e4;break;case h.squareFeet:t/=.09290304;break;case h.squareKilometers:t/=1e6;break;case h.squareMiles:t/=259e4;break;case h.squareYards:t/=.83612736;break;case h.squareMeters:}return hl(t,n)}function Ml(t,e,o,n){switch(sl(e)){case m.feetPerSecond:t*=1.09728;break;case m.milesPerHour:t*=1.6093;break;case m.knots:t*=1.852;break;case m.metersPerSecond:t*=3.6;break;case m.mach:t*=1234.8;break;case m.kilometersPerHour:}switch(sl(o)){case m.feetPerSecond:t/=1.09728;break;case m.milesPerHour:t/=1.6093;break;case m.knots:t/=1.852;break;case m.metersPerSecond:t/=3.6;break;case m.mach:t/=1234.8;break;case m.kilometersPerHour:}return hl(t,n)}function El(t,e,o,n){switch(al(e)){case y.ms:t/=1e3;break;case y.hours:t*=3600;break;case y.minutes:t*=60;break;case y.days:t*=86400;break;case y.seconds:}switch(al(o)){case y.ms:t*=1e3;break;case y.hours:t/=3600;break;case y.minutes:t/=60;break;case y.days:t/=86400;break;case y.seconds:}return hl(t,n)}function jl(t,e,o,n,r,i,s,a){e=dl(e,r,f.meters),r=El(o,i,y.seconds);return kl(2*(e-Ml(t,n,m.metersPerSecond)*r)/(r*r),g.metersPerSecondSquared,s,a)}function Il(t,e,o,n,r,i,s){t=Ml(t,n,m.metersPerSecond);return kl((Ml(e,n,m.metersPerSecond)-t)/El(o,r,y.seconds),g.metersPerSecondSquared,i,s)}function Tl(t,e,o,n){t=zl(t),e=zl(e);return null!=t&&null!=e?El(e.getTime()-t.getTime(),y.ms,o,n):NaN}function zl(t){if("[object Date]"===Object.prototype.toString.call(t))return t;if("string"==typeof t){var e=Date.parse(t);if(!isNaN(e))return new Date(e);if(0<=t.indexOf("Date("))return e=(e=0)<(t=t.replace("/Date(","").replace(")/","")).indexOf("+")?parseInt(t.substr(0,t.indexOf("+")),10):0<t.indexOf("-")?parseInt(t.substr(0,t.indexOf("-")),10):parseInt(t,10),new Date(e)}else if("number"==typeof t)return new Date(t);return null}function Dl(t){var e=[],o=null,n=null;if(Array.isArray(t)&&0<t.length)if(Array.isArray(t[0])&&"number"==typeof t[0][0])e=t;else for(var r=t.length,i=0;i<r;i++)e=e.concat(Dl(t[i]));else if(t.type)switch(t.type){case"Point":e=[t.coordinates];break;case"LineString":e=t.coordinates;break;case"Polygon":o=t.coordinates;break;case"MultiPoint":e=t.coordinates;break;case"MultiLineString":o=t.coordinates;break;case"MultiPolygon":n=t.coordinates;break;case"Feature":var s=t,e=x._isCircle(s)?x._getCirclePositions(s):Dl(s.geometry);break;case"FeatureCollection":e=Dl(t.features);break;case"GeometryCollection":e=Dl(t.geometries)}else if(t instanceof x)return Dl(t.toJson());if(o)for(r=o.length,i=0;i<r;i++)e=e.concat(o[i]);else if(n)for(var a=n.length,i=0;i<a;i++)for(var c=n[i].length,l=0;l<c;l++)e=e.concat(n[i][l]);return e}function Rl(t){if(Array.isArray(t)&&"number"==typeof t[0])return t;if(t.type){if("Point"===t.type)return t.coordinates;if("Feature"===t.type&&"Point"===t.geometry.type)return t.geometry.coordinates}else if(t instanceof x&&"Point"===t.getType())return t.getCoordinates();return null}function Bl(t,e,o){o=o||"meters";var n,r=0;if(Array.isArray(t)?n=t:t.type&&"LineString"===t.type&&(n=t.coordinates),2<=n.length){for(var i,s,a,c=n.length,l=1;l<c;l++){if(e<=r+(a=yl(n[l-1],n[l],o)))return i=_l(n[l-1],n[l]),s=fl(n[l-1],i,e-r,o),new Fc(new Uc(s),{heading:i});r+=a}return r<=e?new Fc(new Uc(n[c-1]),{heading:_l(n[c-2],n[c-1])}):new Fc(new Uc(n[0]),{heading:_l(n[0],n[1])})}return null}($n=h=h||{}).squareMeters="squareMeters",$n.acres="acres",$n.hectares="hectares",$n.squareFeet="squareFeet",$n.squareKilometers="squareKilometers",$n.squareMiles="squareMiles",$n.squareYards="squareYards",(xi=f=f||{}).meters="meters",xi.kilometers="kilometers",xi.feet="feet",xi.miles="miles",xi.nauticalMiles="nauticalMiles",xi.yards="yards",(jn=y=y||{}).seconds="seconds",jn.hours="hours",jn.ms="ms",jn.minutes="minutes",jn.days="days",(o=m=m||{}).metersPerSecond="metersPerSecond",o.kilometersPerHour="kilometersPerHour",o.feetPerSecond="feetPerSecond",o.milesPerHour="milesPerHour",o.knots="knots",o.mach="mach",(a=g=g||{}).milesPerSecondSquared="milesPerSecondSquared",a.kilometersPerSecondSquared="kilometersPerSecondSquared",a.knotsPerSecond="knotsPerSecond",a.standardGravity="standardGravity",a.feetPerSecondSquared="feetPerSecondSquared",a.yardsPerSecondSquared="yardsPerSecondSquared",a.milesPerHourSecond="milesPerHourSecond",a.kilometersPerHourSecond="kilometersPerHourSecond",a.metersPerSecondSquared="metersPerSecondSquared";var Fl,Nl,r=window&&window.__extends||(Fl=function(t,e){return(Fl=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fl(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Zl=(Nl=Array,r(ql,Nl),ql.fromPosition=function(t){return 2===t.length?new ql(t[0],t[1]):2<t.length?new ql(t[0],t[1],t[2]):null},ql.areEqual=function(t,e,o){var n,r;return void 0===o&&(o=6),!!(t&&2<=t.length&&e&&2<=e.length)&&(o=Math.pow(10,o),r=v(t[1]),n=v(e[1]),t=w(t[0]),e=w(e[0]),0==Math.round((r-n)*o)/o)&&(0==(r=Math.round((t-e)*o)/o)||360==r)},ql.fromLatLng=function(r,t,e){var i,s,a,c,l,u,o=[];return"number"==typeof r?("number"==typeof t&&o.push(t),o.push(r),"number"==typeof e&&o.push(e)):Array.isArray(r)?2<=r.length&&"number"==typeof r[0]&&"number"==typeof r[1]&&(3<=r.length&&"number"==typeof r[2]?o.push(r[1],r[0],r[2]):o.push(r[1],r[0])):"object"==typeof r&&(i=["lat","latitude","y"],s=["lng","longitude","lon","x"],a=["elv","elevation","alt","altitude","z"],u=l=c=NaN,Object.keys(r).forEach(function(t,e,o){var n=t.toLowerCase();isNaN(c)&&0<=i.indexOf(n)&&"number"==typeof r[t]?c=r[t]:isNaN(l)&&0<=s.indexOf(n)&&"number"==typeof r[t]?l=r[t]:isNaN(u)&&0<=a.indexOf(n)&&"number"==typeof r[t]&&(u=r[t])}),isNaN(c)||isNaN(l)||(o.push(l,c),isNaN(u))||o.push(u)),2<=o.length?o:null},ql.fromLatLngs=function(t){var e=[];if(Array.isArray(t))for(var o=0,n=t.length;o<n;o++){var r=ql.fromLatLng(t[o]);r&&e.push(r)}return e},ql._getDimensions=function(t){for(var e=0;Array.isArray(t);)t=t[0],e++;return"number"==typeof t&&e--,e},ql);function ql(t,e,o){return o?Nl.call(this,t,e,o)||this:Nl.call(this,t,e)||this}Ul.TYPE="Polygon";var Hl=Ul;function Ul(t,e){this.type="Polygon",this.type=Ul.TYPE,1===Zl._getDimensions(t)?this.coordinates=[t]:this.coordinates=t,this.bbox=e}var Wl,Gl,Jo=window&&window.__extends||(Wl=function(t,e){return(Wl=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Wl(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Vl=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},x=(Jo(O,Gl=Ze),O.prototype.addProperty=function(t,e){Bc(this.data.properties[t],e)||(this.data.properties[t]=c(e),"subType"!==t&&"radius"!==t||this._handleCircle(),this.dataSource&&this.dataSource._updateSource(),this._invokeEvent("shapechanged",this))},O.prototype.getBounds=function(){var e,t,o,n,r,i=this.getCoordinates(),s=this.getType();if("Point"===s)r=this.circlePolygon?(a=this.circlePolygon.geometry.coordinates,S.fromPositions(a[0])):new S(a=i,a);else if("MultiPoint"===s||"LineString"===s){var a=i;r=S.fromPositions(a)}else if("Polygon"===s){a=i;r=S.fromPositions(a[0])}else if("MultiLineString"===s){a=i;try{for(var c=Vl(a),l=c.next();!l.done;l=c.next()){var u=l.value;r=S.merge(r,S.fromPositions(u))}}catch(t){e={error:t}}finally{try{l&&!l.done&&(t=c.return)&&t.call(c)}finally{if(e)throw e.error}}}else if("MultiPolygon"===s){a=i;try{for(var p=Vl(a),h=p.next();!h.done;h=p.next()){var d=h.value;r=S.merge(r,S.fromPositions(d[0]))}}catch(t){o={error:t}}finally{try{h&&!h.done&&(n=p.return)&&n.call(p)}finally{if(o)throw o.error}}}return r},O.prototype.getCoordinates=function(){return c(this.data.geometry.coordinates)},O.prototype.getCircleCoordinates=function(){return this.circlePolygon?c(this.circlePolygon.geometry.coordinates[0]):null},O.prototype.getId=function(){return this.data.id},O.prototype.getProperties=function(){return c(this.data.properties)},O.prototype.getType=function(){return this.data.geometry.type},O.prototype.isCircle=function(){return O._isCircle(this.data)},O.prototype.isRectangle=function(){return O._isRectangle(this.data)},O.prototype.setCoordinates=function(t){t="Polygon"===this.getType()&&1===Zl._getDimensions(t)?[t]:t;Bc(this.data.geometry.coordinates,t)||(this.data.geometry.coordinates=c(t),this._handleCircle(),this.dataSource&&this.dataSource._updateSource(),this._invokeEvent("shapechanged",this))},O.prototype.setProperties=function(t){t[O._shapeIdPropName]=this.data.id,Bc(this.data.properties,t)||(this.data.properties=c(t),this._handleCircle(),this.dataSource&&this.dataSource._updateSource(),this._invokeEvent("shapechanged",this))},O.prototype.toJson=function(){return JSON.parse(JSON.stringify(this.data))},O.prototype._toJson=function(){return this.circlePolygon||this.data},O.prototype._setDataSource=function(t){void 0===t||null==t?delete this.dataSource:this.dataSource=t},O.prototype._handleCircle=function(){var t;this.isCircle()?(t=O._getCirclePositions(this.data),this.circlePolygon=new Fc(new Hl([t]),this.data.properties,this.data.id),this.data.properties.subType="Circle"):delete this.circlePolygon},O._isCircle=function(t){return t&&t.geometry&&"Point"===t.geometry.type&&t.geometry.coordinates&&t.properties&&"string"==typeof t.properties.subType&&"circle"===t.properties.subType.toLowerCase()&&"number"==typeof t.properties.radius},O._isRectangle=function(t){if("Polygon"===t.geometry.type&&t.geometry.coordinates&&"string"==typeof t.properties.subType&&"rectangle"===t.properties.subType.toLowerCase()){t=t.geometry.coordinates;if(1===t.length){t=t[0];if(5===t.length)return t[0][0]===t[4][0]&&t[0][1]===t[4][1];if(4===t.length)return!0}}return!1},O._getCirclePositions=function(t){return Sl(t.geometry.coordinates,t.properties.radius,72,"meters")},O._shapeIdPropName="_azureMapsShapeId",O);function O(t,e,o){var n,r,i=Gl.call(this)||this;return"Feature"===t.type?(r=c((n=t).geometry),o=n.properties?c(n.properties):{},e=null==n.id||""===n.id?J():n.id):(r=c(t),e=null==e||""===e?J():e,o=o?c(o):{}),o[O._shapeIdPropName]=e,i.data=new Fc(r,o,e),i._handleCircle(),i}var Kl,Yl,i=window&&window.__extends||(Kl=function(t,e){return(Kl=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Kl(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Jl=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},S=(Yl=Array,i(C,Yl),C.fromBoundingBox=function(t){var e=C.getWest(t),o=C.getSouth(t),n=C.getEast(t),t=C.getNorth(t);return new C([e,o,n,t])},C.fromDimensions=function(t,e,o){var n=t[0],t=t[1],r=Math.min(Math.max(t+o/2,-85.5),85.5),t=Math.min(Math.max(t-o/2,-85.5),85.5),o=w(n+e/2);return new C([w(n-e/2),t,o,r])},C.fromEdges=function(t,e,o,n){return new C([t,e,o,n])},C.containsPosition=function(t,e){var o=C.getCenter(t),n=Math.abs(o[1]-e[1]),o=Math.abs(o[0]-e[0]),e=(180<o&&(o=360-o),C.getHeight(t)),t=C.getWidth(t);return n<=e/2+1e-8&&o<=t/2+1e-8},C.containsBoundingBox=function(t,e){var o=t&&4===t.length,n=e&&4===e.length;return!(!o||!n)&&C.getWest(t)<C.getWest(e)&&C.getWest(e)<C.getEast(t)&&C.getWest(t)<C.getEast(e)&&C.getEast(e)<C.getEast(t)&&C.getSouth(t)<C.getSouth(e)&&C.getSouth(e)<C.getNorth(t)&&C.getSouth(t)<C.getNorth(e)&&C.getNorth(e)<C.getNorth(t)},C.crossesAntimeridian=function(t){return w(C.getEast(t))-w(C.getWest(t))<0||C.isBoundingBoxWithSixOrMoreElementsLargerThanGlobe(t)||C.isBoundingBoxWithLessThanSixElementsLargerThanGlobe(t)},C.getCenter=function(t){var e=w(C.getEast(t)),o=w(C.getWest(t)),o=(e<o&&(e+=360),w((o+e)/2)),e=v(C.getSouth(t)),t=v(C.getNorth(t));return[o,v((e+t)/2)]},C.getHeight=function(t){t=v(C.getNorth(t))-v(C.getSouth(t));return isNaN(t)?0:t},C.getWidth=function(t){t=w(C.getEast(t))-w(C.getWest(t));return isNaN(t)?0:t<0?t+360:t},C.getSouthWest=function(t){var e=this.getSouth(t),t=this.getWest(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getNorthEast=function(t){var e=this.getNorth(t),t=this.getEast(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getNorthWest=function(t){var e=this.getNorth(t),t=this.getWest(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getSouthEast=function(t){var e=this.getSouth(t),t=this.getEast(t);return isNaN(e)||isNaN(t)?null:[t,e]},C.getSouth=function(t){return t&&4<=t.length?Number(t[1]):NaN},C.getWest=function(t){return t&&4<=t.length?Number(t[0]):NaN},C.getNorth=function(t){if(t){if(4===t.length)return Number(t[3]);if(6===t.length)return Number(t[4])}return NaN},C.getEast=function(t){if(t){if(4===t.length)return Number(t[2]);if(6===t.length)return Number(t[3])}return NaN},C.intersect=function(t,e){var o=C.getCenter(t),n=C.getCenter(e),r=Math.abs(o[1]-n[1]),o=Math.abs(o[0]-n[0]),n=(180<o&&(o=360-o),C.getHeight(t)),t=C.getWidth(t),i=C.getHeight(e),e=C.getWidth(e);return r<=n/2+i/2&&o<=t/2+e/2},C.merge=function(t,e){var o=t&&4===t.length,n=e&&4===e.length;if(o&&!n)return t;if(n&&!o)return e;if(!o&&!n)return null;for(var o=Math.max(v(C.getNorth(t)),v(C.getNorth(e))),n=Math.min(v(C.getSouth(t)),v(C.getSouth(e))),r=[t,e],i=[],s=0,s=0;s<r.length;s++){var a=r[s],c=w(C.getWest(a)),l=w(C.getEast(a));C.crossesAntimeridian(a)?(i.push([c,180]),i.push([-180,l])):i.push([c,l])}i.sort(function(t,e){return t[0]===e[0]?t[1]-e[1]:t[0]-e[0]});var u=[],p=i[0];for(s=1;s<i.length;){var h=i[s];p[1]>=h[0]?p[1]=Math.max(p[1],h[1]):(u.push(p),p=h),s++}u.push(p);var d=u.length,f=u[0][0]+360-u[d-1][1],y=[u[d-1][1],u[0][0]];for(s=1;s<d;s++){var m=u[s][0]-u[s-1][1];f<m&&(f=m,y=[u[s-1][1],u[s][0]])}return new C([y[1],n],[y[0],o])},C.fromPositions=function(t){for(var e,o,n=NaN,r=NaN,i=NaN,s=NaN,a=t.length,c=new Array(a),l=0;a--;)(o=t[a])&&2<=o.length&&(e=v(o[1]),n=isNaN(n)?e:Math.max(n,e),r=isNaN(r)?e:Math.min(r,e),c[l++]=w(o[0]));if(l){c.length=l,c.sort(function(t,e){return t-e});for(var u=c[0]+360-c[l-1],p=0,a=1;a<l;a++){var h=c[a]-c[a-1];u<h&&(u=h,p=a)}i=c[p],s=c[(p||l)-1]}return isNaN(i)||isNaN(r)||isNaN(s)||isNaN(n)?null:new C([i,r,s,n])},C.fromLatLngs=function(t){return C.fromPositions(Zl.fromLatLngs(t))},C.fromData=function(t){var e,o,n=null;if(Array.isArray(t)&&0<t.length){try{for(var r=Jl(t),i=r.next();!i.done;i=r.next()){var s,a=i.value;null!=(s=C.fromData(a))&&(n=null===n?s:C.merge(n,s))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}return n}if(t instanceof x)return t.getBounds();if(t&&t.type){var c=t;if(c.bbox&&4===c.bbox.length)return c.bbox;switch(c.type){case"FeatureCollection":return C.fromData(c.features);case"Feature":return x._isCircle(c)?C.fromPositions(x._getCirclePositions(c)):C.fromData(c.geometry);case"GeometryCollection":return C.fromData(c.geometries);case"Point":var l=c.coordinates;if(l&&2<=l.length)return[l[0],l[1],l[0],l[1]];break;case"LineString":case"MultiPoint":return C.fromPositions(c.coordinates);case"Polygon":case"MultiLineString":var u=c.coordinates;if(u&&0<u.length){for(var p=0,h=u.length;p<h;p++)null!=(s=C.fromPositions(u[p]))&&(n=null===n?s:C.merge(n,s));if(null!=n)return n}break;case"MultiPolygon":var d=c.coordinates;if(d&&0<d.length){for(p=0,h=d.length;p<h;p++)for(var f=0,y=d[p].length;f<y;f++)null!=(s=C.fromPositions(d[p][f]))&&(n=null===n?s:C.merge(n,s));return n}}}return null},C.splitOnAntimeridian=function(t){var e,o,n,r,i,s,a=[];return C.isBoundingBoxWithSixOrMoreElementsLargerThanGlobe(t)?[[-180,t[1],t[2],180,t[4],t[5]]]:C.isBoundingBoxWithLessThanSixElementsLargerThanGlobe(t)?[[-180,t[1],180,t[3]]]:(C.crossesAntimeridian(t)?(s=e=void 0,o=w(C.getWest(t)),n=w(C.getEast(t)),r=v(C.getNorth(t)),i=v(C.getSouth(t)),s=6<=t.length?(e=[o,i,t[2],180,r,t[5]],[-180,i,t[2],n,r,t[5]]):(e=[o,i,180,r],[-180,i,n,r]),a.push(e,s)):a.push(t),a)},C.isBoundingBoxWithSixOrMoreElementsLargerThanGlobe=function(t){return 6<=t.length&&360<t[3]-t[0]},C.isBoundingBoxWithLessThanSixElementsLargerThanGlobe=function(t){return t.length<6&&360<t[2]-t[0]},C);function C(t,e){var o,n=this;return t&&e?n=(o=t)[2]&&e[2]?Yl.call(this,o[0],o[1],o[2]||0,e[0],e[1],e[2]||0)||this:Yl.call(this,o[0],o[1],e[0],e[1])||this:t&&(o=t)&&(4===o.length?n=Yl.call(this,o[0],o[1],o[2],o[3])||this:6<=o.length&&(n=Yl.call(this,o[0],o[1],o[2],o[3],o[4],o[5])||this)),n}Xl.TYPE="FeatureCollection";var $l=Xl;function Xl(t,e){this.type="FeatureCollection",this.type=Xl.TYPE,this.features=t,this.bbox=e}Ql.TYPE="GeometryCollection";Ao=Ql;function Ql(t){this.type="GeometryCollection",this.type=Ql.TYPE,this.geometries=t}tu.TYPE="LineString";e=tu;function tu(t,e){this.type="LineString",this.type=tu.TYPE,this.coordinates=t,this.bbox=e}eu.TYPE="MultiLineString";H=eu;function eu(t,e){this.type="MultiLineString",this.type=eu.TYPE,this.coordinates=t,this.bbox=e}ou.TYPE="MultiPoint";s=ou;function ou(t,e){this.type="MultiPoint",this.type=ou.TYPE,this.coordinates=t,this.bbox=e}nu.TYPE="MultiPolygon";In=nu;function nu(t,e){this.type="MultiPolygon",this.type=nu.TYPE,this.coordinates=t,this.bbox=e}var ru,iu,er=window&&window.__extends||(ru=function(t,e){return(ru=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ru(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),tr=(iu=Array,er(P,iu),P.fromPosition=function(t){return 2<=t.length?new P((180+t[0])/360,P._latToMercatorY(t[1]),3<=t.length?P._altitudeToMercatorZ(t[2],t[1]):0):[0,0,0]},P.fromPositions=function(t){for(var e=[],o=0,n=t.length;o<n;o++)e.push(this.fromPosition(t[o]));return e},P.toFloat32Array=function(t){for(var e=new Float32Array(3*t.length),o=0,n=t.length;o<n;o++){var r=3*o,i=t[o];e[r]=(180+i[0])/360,e[1+r]=P._latToMercatorY(i[1]),e[2+r]=3<=i.length?P._altitudeToMercatorZ(i[2],i[1]):0}return e},P.toPosition=function(t){var e;return 2<=t.length?(e=360/Math.PI*Math.atan(Math.exp((180-360*t[1])*Math.PI/180))-90,new Zl(360*t[0]-180,e,3<=t.length?P._mercatorZToAltitude(t[2],t[1]):0)):[0,0,0]},P.toPositions=function(t){for(var e=[],o=0,n=t.length;o<n;o++)e.push(this.toPosition(t[o]));return e},P.mercatorScale=function(t){return 1/Math.cos(t*Math.PI/180)},P.meterInMercatorUnits=function(t){return 1/P.earthCircumference*P.mercatorScale(P._latToMercatorY(t))},P._circumferenceAtLatitude=function(t){return P.earthCircumference*Math.cos(t*Math.PI/180)},P._altitudeToMercatorZ=function(t,e){return t/P._circumferenceAtLatitude(e)},P._mercatorZToAltitude=function(t,e){return t*P._circumferenceAtLatitude(P._latToMercatorY(e))},P._latToMercatorY=function(t){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+t*Math.PI/360)))/360},P.earthCircumference=2*Math.PI*ml(),P);function P(t,e,o){return iu.call(this,t,e,o||0)||this}var Kr=Object.freeze({__proto__:null,BoundingBox:S,Feature:Fc,FeatureCollection:$l,GeometryCollection:Ao,LineString:e,MercatorPoint:tr,MultiLineString:H,MultiPoint:s,MultiPolygon:In,Point:Uc,Polygon:Hl,Position:Zl});function su(t,e){return t*t+e*e}function au(t,e){for(var o,n,r,i=t[0],s=[i],a=1,c=t.length;a<c;a++)o=t[a],r=i,su((n=o)[0]-r[0],n[1]-r[1])>e&&(s.push(o),i=o);return i!==o&&s.push(o),s}function cu(t,e,o,n,r){for(var i,s,a,c,l,u,p,h=n,d=e+1;d<o;d++){s=t[d],a=t[e],f=t[o],p=u=l=c=void 0,l=a[0],a=a[1],u=f[0]-l,p=f[1]-a,0==u&&0==p||(1<(c=((s[0]-l)*u+(s[1]-a)*p)/su(u,p))?(l=f[0],a=f[1]):0<c&&(l+=u*c,a+=p*c));var f=su(s[0]-l,s[1]-a);h<f&&(i=d,h=f)}n<h&&(1<i-e&&cu(t,e,i,n,r),r.push(t[i]),1<o-i)&&cu(t,i,o,n,r)}var lu=function(t,e,o){var n,r;return void 0===e&&(e=1),void 0===o&&(o=!1),t.length<=2||(e=e*e,t=o?t:au(t,e),n=(o=t).length-1,r=[o[0]],cu(o,0,n,e,r),r.push(o[n]),t=r),t};var uu=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},pu=(hu.prototype.toTarget=function(t,e){return this.transformArray(t,this.M,e)},hu.prototype.toSource=function(t,e){return this.transformArray(t,this.inverseM,e)},hu.prototype.transformArray=function(t,e,o){var n,r;if(t&&Array.isArray(t)&&Array.isArray(t[0])){var i=[];try{for(var s=uu(t),a=s.next();!a.done;a=s.next()){var c=a.value;i.push(this.transform(c,e,o))}}catch(t){n={error:t}}finally{try{a&&!a.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return i}return null},hu.prototype.transform=function(t,e,o){var n=t[0]*e[0][3]+t[1]*e[1][3]+e[2][3],t=t[0]*e[0][4]+t[1]*e[1][4]+e[2][4];return"number"==typeof o&&0<=o?[hl(n,o),hl(t,o)]:[hl(n,6),hl(t,6)]},hu._calculateAffineTransform=function(t,e){if(t.length!==e.length||t.length<1)throw new Error("Error: source and target arrays must have the same length.");var o=Math.min(t[0].length,e[0].length),n=o+1;if(t.length<o)throw new Error("Erorr: At least "+o+" reference points required.");for(var r=[],i=[],s=0;s<n;s++){i[s]=[];for(var a=0;a<n;a++){a<o&&(r[a]=0);for(var c=i[s][a]=0;c<t.length;c++)a<o&&(r[a]+=s<o?t[c][s]*e[c][a]:e[c][a]),i[s][a]+=o<=s&&o<=a?1:o<=s?t[c][a]:o<=a?t[c][s]:t[c][s]*t[c][a]}i[s]=i[s].concat(r)}if(this._gaussJordanElimination(i))return i;throw new Error("Error: Singular matrix. Points are likely coplanar.")},hu._gaussJordanElimination=function(t){for(var e,o=t.length,n=2*o-1,r=0;r<o;r++){for(var i=r,s=r+1;s<o;s++)Math.abs(t[s][r])>Math.abs(t[i][r])&&(i=s);if(e=t[i],t[i]=t[r],t[r]=e,Math.abs(t[r][r])<=1e-12)return!1;for(var a=r+1;a<o;a++)for(var c=t[a][r]/t[r][r],l=r;l<n;l++)t[a][l]-=t[r][l]*c}for(r=o-1;-1<r;r--){c=t[r][r];for(s=0;s<r;s++)for(var u=n-1;r-1<u;u--)t[s][u]-=t[r][u]*t[s][r]/c;t[r][r]/=c;for(var p=o;p<n;p++)t[r][p]/=c}return!0},hu);function hu(t,e){this.M=hu._calculateAffineTransform(t,e),this.inverseM=hu._calculateAffineTransform(e,t)}var du,fu,$n=Object.freeze({__proto__:null,get AccelerationUnits(){return g},AffineTransform:pu,get AreaUnits(){return h},get DistanceUnits(){return f},get SpeedUnits(){return m},get TimeUnits(){return y},WEBMERCATOR_MAXLAT:Xc,_precision:hl,boundingBoxToPolygon:function(t){var e=w(S.getWest(t)),o=w(S.getEast(t)),n=v(S.getNorth(t)),r=v(S.getSouth(t)),t=S.getCenter(t),r=[[e,n],[e,r],[t[0],r],[o,r],[o,n],[t[0],n],[e,n]];return new Hl([r])},convertAcceleration:kl,convertArea:Al,convertDistance:dl,convertSpeed:Ml,convertTimespan:El,getAcceleration:jl,getAccelerationFromFeatures:function(t,e,o,n,r,i,s){if("string"==typeof o&&"Feature"===t.type&&"Point"===t.geometry.type&&"Feature"===e.type&&"Point"===e.geometry.type){o=Tl(t.properties[o],e.properties[o],y.seconds);if(!isNaN(o)){var a=0;if(n&&"string"==typeof n){var c=t.properties[n],n=e.properties[n];if("number"==typeof c&&(a=c,"number"==typeof n))return Il(c,n,o,r,y.seconds,i,s)}return jl(a,yl(t.geometry.coordinates,e.geometry.coordinates,f.meters),o,r,f.meters,y.seconds,i,s)}}return NaN},getAccelerationFromSpeeds:Il,getArea:function t(e,o,n){if(e){var r=0;switch((e=e instanceof x?e.toJson():e).type){case"Feature":var i=e;if(i.geometry)return t(i.geometry,o,n);break;case"Polygon":(i=e).coordinates&&(r=cl(i.coordinates));break;case"MultiPolygon":var s=e;if(s.coordinates)for(var a=0,c=s.coordinates.length;a<c;a++)r+=cl(s.coordinates[a])}return Al(r,h.squareMeters,o,n)}return 0},getCardinalSpline:function(t,e,o,n){if(!t||t.length<=2)return c;"number"!=typeof e&&(e=.5),("number"!=typeof o||o<=0)&&(o=15);var r,i,s,a=t.length,c=t.slice(0),l=(n?(Zl.areEqual(c[0],c[a-1])&&(c.pop(),a--),c.unshift(t[a-1]),c.push(t[0]),c.push(t[1]),a++):(c.unshift(t[0]),c.push(t[a-1])),[]);l.push([1,0,0,0]);for(var u=1;u<o-1;u++)l.push([2*(s=(r=u/o)*(i=r*r))-3*i+1,-2*s+3*i,s-2*i+r,s-i]);l.push([0,1,0,0]);for(var p,h,d,f,y,m,g=[],u=1;u<a;u++)for(p=e*(c[u+1][0]-c[u-1][0]),h=e*(c[u+1][1]-c[u-1][1]),d=e*(c[u+2][0]-c[u][0]),f=e*(c[u+2][1]-c[u][1]),r=0;r<o;r++)m=(y=l[r])[0]*c[u][0]+y[1]*c[u+1][0]+y[2]*p+y[3]*d,y=el(y[0]*c[u][1]+y[1]*c[u+1][1]+y[2]*h+y[3]*f,-85,85),g.push([m,y]);return g},getClosestPointOnGeometry:function t(e,o,n,r){var i=Rl(e),s=Ll([i],22)[0],a=null,c=1/0;switch((o=o instanceof x?o.toJson():o).type){case"Feature":return t(e,o.geometry,n);case"Point":f=[[o.coordinates]];break;case"MultiPoint":for(var l,u=o.coordinates,p=0,h=u.length;p<h;p++)(l=yl(i,u[p]))<c&&(c=l,a=new Fc(new Uc(u[p]),{distance:l}));break;case"LineString":f=[o.coordinates];break;case"Polygon":case"MultiLineString":f=o.coordinates;break;case"MultiPolygon":var d=o.coordinates;if(0<d.length)for(var f=d[0],p=1,h=d.length;p<h;p++)f=f.concat(d[p])}if(f)for(var y,p=0,h=f.length;p<h;p++)(y=pl(i,s,f[p]))&&y.properties.distance<c&&(c=y.properties.distance,a=y);return a&&(a.properties.distance=dl(a.properties.distance,"meters",n,r)),a},getConvexHull:function(t){var e,o,n=Dl(t).map(function(t){return[w(t[0]),v(t[1])]}),r=(n.sort(function(t,e){return t[0]===e[0]?t[1]-e[1]:t[0]-e[0]}),[]);try{for(var i=Vc(n),s=i.next();!s.done;s=i.next()){for(var a=s.value;2<=r.length&&ul(r[r.length-2],r[r.length-1],a)<=0;)r.pop();r.push(a)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(o=i.return)&&o.call(i)}finally{if(e)throw e.error}}for(var c=[],l=n.length-1;0<=l;l--){for(;2<=c.length&&ul(c[c.length-2],c[c.length-1],n[l])<=0;)c.pop();c.push(n[l])}return new Hl([r.concat(c)])},getDestination:fl,getDistanceTo:yl,getEarthRadius:ml,getGeodesicPath:function(t,e){(!e||e<=0)&&(e=15),Array.isArray(t)?o=t:t.type&&"LineString"===t.type&&(o=t.coordinates);for(var o,n=o.length-1,r=[],i=0;i<n;i++)r=r.concat(gl(o[i],o[i+1],e));return vl(r)},getGeodesicPaths:function(t,e){(!e||e<=0)&&(e=15),Array.isArray(t)?o=t:t.type&&"LineString"===t.type&&(o=t.coordinates);for(var o,n=o.length-1,r=[],i=[],s=0;s<n;s++)for(var a,c,l,u,p,h=gl(o[s],o[s+1],e),d=0;d<h.length;d++)r.push(h[d]),d+1>=h.length||(a=(c=Gc(h[d],2))[0],c=c[1],u=(p=Gc(h[d+1],2))[0],p=p[1],180<Math.abs(u-a)&&(l=0<a?180:-180,u=Math.abs((0<a?u+360:u-360)-a),p=c+(p-c)*(Math.abs(l-a)/u),r.push([l,p]),i.push(r),r=[[-l,p]]));return i.push(r),i},getHeading:_l,getLengthOfPath:bl,getPathDenormalizedAtAntimerian:vl,getPathSplitByAntimeridian:wl,getPixelHeading:function(t,e){t=Rl(t),e=Rl(e);var e=(t=Gc(Ll([t,e],21),2))[0],o=(t=t[1])[0]-e[0],e=e[1]-t[1];return(2.5*Math.PI-Math.atan2(e,o))*Jc%360},getPointWithHeadingAlongPath:Bl,getPointsWithHeadingsAlongPath:function(t,e){if(e<=0)return[];for(var o=[],n=bl(t,f.meters)/(e-1),r=0;r<e;r++){var i=Bl(t,n*r,f.meters);null!=i&&o.push(i)}return o},getPosition:Rl,getPositionAlongPath:xl,getPositions:Dl,getPositionsAlongPath:function(t,e){if(e<2)return[];for(var o=[],n=bl(t,f.meters)/(e-1),r=0;r<e;r++){var i=xl(t,n*r,f.meters);null!=i&&o.push(i)}return o},getRegularPolygonPath:Sl,getRegularPolygonPaths:function(t,e,o,n,r){return wl(Ol(t,e,o,n,r))},getSpeed:function(t,e,o,n,r,i){return t=Rl(t),e=Rl(e),t&&e?(o=El(o,n,y.seconds),Ml(yl(t,e,f.meters)/o,m.metersPerSecond,r,i)):0},getSpeedFromFeatures:function(t,e,o,n,r){if("string"==typeof o&&"Feature"===t.type&&"Point"===t.geometry.type&&"Feature"===e.type&&"Point"===e.geometry.type){o=Tl(t.properties[o],e.properties[o],y.seconds);if(!isNaN(o))return Ml(yl(t.geometry.coordinates,e.geometry.coordinates,f.meters)/o,m.metersPerSecond,n,r)}return NaN},getTimespan:Tl,getTravelDistance:function(t,e,o,n,r,i,s,a){return e=El(e,r,y.seconds),r=(o=Ml(o,i,m.metersPerSecond))*e,"number"==typeof n&&(r+=.5*kl(n,s,g.metersPerSecondSquared)*e*e),dl(r,f.meters,t,a)},interpolate:function(t,e,o){o=void 0===o?.5:o;var n=yl(t=Rl(t),e=Rl(e),"kilometers");return fl(t,_l(t,e),n*o,"kilometers")},mercatorPixelsToPositions:Pl,mercatorPositionsToPixels:Ll,normalizeLatitude:v,normalizeLongitude:w,parseTimestamp:zl,rotatePositions:Cl,simplify:function(t,e){return lu(t,e,!0)}}),yu=((window&&window.__extends||(du=function(t,e){return(du=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}du(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(mu,fu=t),mu);function mu(){var t=null!==fu&&fu.apply(this,arguments)||this;return t.zoomDelta=1,t.style=u.ControlStyle.light,t}(window&&window.__extends||(gu=function(t,e){return(gu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}gu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(wu,vu=We),wu.prototype.onAdd=function(t){this.container=this.buildContainer(t,this.options.style,"Zoom Control"),this.container.style.flexDirection="column",this.zoomInButton=this.constructZoomInButton(t),this.zoomOutButton=this.constructZoomOutButton(t);var e=_("Zoom In"),o=_("Zoom Out");return this.container.appendChild(this.zoomInButton),this.container.appendChild(e),this.container.appendChild(this.zoomOutButton),this.container.appendChild(o),b(e,this.zoomInButton),b(o,this.zoomOutButton),t.events.add("zoom",this.zoomChanged),t.events.add("minzoomchanged",this.minZoomChanged),t.events.add("maxzoomchanged",this.maxZoomChanged),this.map=t,this.container},wu.prototype.onRemove=function(){vu.prototype.onRemove.call(this),this.map&&(this.map.events.remove("zoom",this.zoomChanged),this.map.events.remove("minzoomchanged",this.minZoomChanged),this.map.events.remove("maxzoomchanged",this.maxZoomChanged),this.map=null),this.container&&(this.container.remove(),this.container=null,this.zoomInButton=null,this.zoomOutButton=null)},wu.prototype.updateZoomButtonsState=function(){var t=this.map.getCamera().zoom>=this.map._getMap().getMaxZoom(),e=S.getSouth(this.map.getCamera().bounds)<=-Xc&&S.getNorth(this.map.getCamera().bounds)>=Xc,e=this.map.getCamera().zoom<=this.map._getMap().getMinZoom()||e;this.zoomInButton&&this.zoomInButton.disabled!=t&&(this.zoomInButton.disabled=t,this.zoomInButton.setAttribute("aria-label",t?"Zoom In disabled":"Zoom In")),this.zoomOutButton&&this.zoomOutButton.disabled!=e&&(this.zoomOutButton.disabled=e,this.zoomOutButton.setAttribute("aria-label",t?"Zoom Out disabled":"Zoom Out"))},wu.prototype.constructZoomInButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("zoom-in"),o.setAttribute("aria-label","Zoom In"),o.setAttribute("alt","Zoom In"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({zoom:t.getCamera().zoom+e.options.zoomDelta,duration:wu.ZOOM_DURATION_MS,type:"ease"},!0)}),o},wu.prototype.constructZoomOutButton=function(t){var e=this,o=document.createElement("button");return o.classList.add("azure-maps-control-button"),o.classList.add("zoom-out"),o.setAttribute("aria-label","Zoom Out"),o.setAttribute("alt","Zoom Out"),o.setAttribute("type","button"),o.addEventListener("click",function(){t.setCamera({zoom:t.getCamera().zoom-e.options.zoomDelta,duration:wu.ZOOM_DURATION_MS,type:"ease"},!0)}),o},wu.ZOOM_DURATION_MS=200;var gu,vu,xi=wu;function wu(t){var e=vu.call(this)||this;return e.container=null,e.zoomInButton=null,e.zoomOutButton=null,e.zoomChanged=function(t){return e.updateZoomButtonsState()},e.minZoomChanged=function(t){return e.updateZoomButtonsState()},e.maxZoomChanged=function(t){return e.updateZoomButtonsState()},e.options=(new yu).merge(t),e}(window&&window.__extends||(_u=function(t,e){return(_u=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}_u(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ou,bu=t);var _u,bu,xu=Ou;function Ou(){var t=null!==bu&&bu.apply(this,arguments)||this;return t.style=u.ControlStyle.light,t.hideIfUnsupported=!1,t.container=void 0,t}(window&&window.__extends||(Su=function(t,e){return(Su=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Su(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Pu,Cu=We),Pu.prototype.onAdd=function(t){var e,o,n=this,r=(this.map=t,null!=(r=null==(r=this.map)?void 0:r._getMap())&&r.addControl(this.control),this.buildContainer(t,this.options.style,"Fullscreen Control")),i=this.control._fullscreenButton;return i&&(e=i.querySelector("span"))&&(o=_("Enter Fullscreen"),r.appendChild(i),i.classList.add("azure-maps-control-button","fullscreen"),e.classList.add("fullscreen-icon","fullscreen-end"),i.removeAttribute("title"),r.appendChild(o),b(o,i),this.control.on("fullscreenstart",function(){i.removeAttribute("title"),e.classList.remove("fullscreen-end"),e.classList.add("fullscreen-start"),o.innerText="Exit Fullscreen",n.isFullscreenState=!0}),this.control.on("fullscreenend",function(){i.removeAttribute("title"),e.classList.remove("fullscreen-start"),e.classList.add("fullscreen-end"),o.innerText="Enter Fullscreen",n.isFullscreenState=!1})),this.options.hideIfUnsupported&&!Pu.isSupported()&&(r.style.display="none"),r},Pu.prototype.onRemove=function(){var t;Cu.prototype.onRemove.call(this),null!=(t=null==(t=this.map)?void 0:t._getMap())&&t.removeControl(this.control),this.map=null},Pu.prototype.isFullscreen=function(){return this.isFullscreenState},Pu.isSupported=function(){var t=document;return t.fullscreenEnabled||t.msFullscreenEnabled||t.mozFullScreenEnabled||t.webkitFullscreenEnabled};var Su,Cu,jn=Pu;function Pu(t){var e=Cu.call(this)||this;return e.map=null,e.isFullscreenState=!1,e.options=(new xu).merge(t),e.control=new D.FullscreenControl({container:e.options.container}),e}var o=Object.freeze({__proto__:null,CompassControl:q,ControlBase:We,FullscreenControl:jn,PitchControl:yt,ScaleControl:ze,StyleControl:bi,TrafficControl:oc,TrafficLegendControl:R,ZoomControl:xi}),Lu=Ts;var L=B(function(t,e){return Lu(t,5,e="function"==typeof e?e:void 0)}),ku=(Au.Css={hidden:"hidden-accessible-element"},Au);function Au(t){var e=this;this.attach=function(t){e.map!==t&&(e.map&&e.detachFromCurrentMap(),e.map=t,e.map.indicators._getCollectionDiv().appendChild(e.element),e.map.indicators.add(e))},this.remove=function(){e.detachFromCurrentMap(),e.element.remove()},this.getElement=function(){return e.element},this.detachFromCurrentMap=function(){e.map&&(e.map.indicators.remove(e),delete e.map)},this.element=document.createElement("div"),this.element.setAttribute("tabindex","0"),this.element.setAttribute("role","option"),null!=t&&t.setSize&&this.element.setAttribute("aria-setsize",t.setSize.toString()),null!=t&&t.positionInSet&&this.element.setAttribute("aria-posinset",t.positionInSet.toString()),this.element.setAttribute("aria-label","data point"),this.element.classList.add(Au.Css.hidden)}(window&&window.__extends||(Mu=function(t,e){return(Mu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Mu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Iu,Eu=t);var Mu,Eu,ju=Iu;function Iu(){var t=null!==Eu&&Eu.apply(this,arguments)||this;return t.buffer=128,t.maxZoom=18,t.cluster=!1,t.clusterRadius=50,t.clusterMaxZoom=void 0,t.clusterProperties=void 0,t.lineMetrics=!1,t.tolerance=.375,t.clusterMinPoints=2,t.generateId=!1,t.promoteId=void 0,t.filter=void 0,t}(window&&window.__extends||(Tu=function(t,e){return(Tu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Tu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Du,zu=Ze),Du.prototype.getId=function(){return this.id},Du.prototype._setMap=function(t,e){var o;void 0===e&&(e=!0),null==t||void 0===t?(o=this.map,delete this.map,e&&(this._invokeEvent("sourceremoved",this),o)&&o.events.invoke("sourceremoved",this)):(this.map=t,e&&(this._invokeEvent("sourceadded",this),this.map.events.invoke("sourceadded",this)))};var Tu,zu,k=Du;function Du(t){var e=zu.call(this)||this;return e.id=t||J(),e}var Ru,Bu,a=window&&window.__extends||(Ru=function(t,e){return(Ru=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ru(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Fu=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Nu=(a(A,Bu=k),A.prototype.add=function(t,e){this._addNoUpdate(t,e),this._updateSource()},A.prototype.clear=function(){this._clearNoUpdate(),this._updateSource()},A.prototype.dispose=function(){this.options=null,this.shapes=null,this.shapesMap=null,this.map=null},A.prototype.getClusterExpansionZoom=function(n){var r=this;return new Promise(function(e,o){var t;r.map?(t=r.map._getMap().getSource(r.getId()))&&"geojson"===t.type&&t.getClusterExpansionZoom(n).then(function(t){"number"==typeof t&&e(t)}).catch(function(t){t&&o(t)}):o("The DataSource hasn't been added to a map.")})},A.prototype.getClusterChildren=function(n){var r=this;return new Promise(function(e,o){var t;r.map?(t=r.map._getMap().getSource(r.getId()))&&"geojson"===t.type&&t.getClusterChildren(n).then(function(t){t&&e(r.map.sources._mapFeaturesToShapes(t,!1,r))}).catch(function(t){t&&o(t)}):o("The DataSource hasn't been added to a map.")})},A.prototype.getClusterLeaves=function(n,r,i){var s=this;return new Promise(function(e,o){var t;s.map?(t=s.map._getMap().getSource(s.getId()))&&"geojson"===t.type&&t.getClusterLeaves(n,r,i).then(function(t){t&&e(s.map.sources._mapFeaturesToShapes(t,!1,s))}).catch(function(t){t&&o(t)}):o("The DataSource hasn't been added to a map.")})},A.prototype.getOptions=function(){return c(this.options)},A.prototype.getShapes=function(){return Array.from(this.shapes)},A.prototype.importDataFromUrl=function(t){var e=this;return fetch(t,{method:"GET",mode:"cors"}).then(function(t){if(t.ok)return t.json();throw new Error("HTTP ".concat(t.status,": ").concat(t.statusText))}).then(function(t){e.add(t)})},A.prototype.getShapeById=function(t){return this.shapes[this.shapesMap.get(t)]||null},A.prototype.remove=function(t){var e,o,t=Array.isArray(t)?t:[t];try{for(var n=Fu(t),r=n.next();!r.done;r=n.next()){var i=r.value;"number"==typeof i?this._removeByIndex(i):this._removeById(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}this._updateSource()},A.prototype.removeById=function(t){var e,o,t=Array.isArray(t)?t:[t];try{for(var n=Fu(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._removeById(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}this._updateSource()},A.prototype.setOptions=function(t){t=(new ju).merge(this.options,c(t));Bc(this.options,t)||(this._invokeEvent("datasourceupdated",this),this.options=t,this.map&&this.map._rebuildStyle())},A.prototype.setShapes=function(t){this._clearNoUpdate(),this.add(t)},A.prototype.toJson=function(){return new $l(this.shapes.map(function(t){return t.toJson()}))},A.prototype._toJson=function(){return new $l(this.shapes.map(function(t){return t._toJson()}))},A.prototype._buildSource=function(){var t={type:"geojson",data:this._toJson(),maxzoom:this.options.maxZoom,cluster:this.options.cluster,clusterRadius:this.options.clusterRadius,tolerance:this.options.tolerance,lineMetrics:this.options.lineMetrics,clusterProperties:this.options.clusterProperties,buffer:this.options.buffer,clusterMinPoints:this.options.clusterMinPoints,generateId:this.options.generateId,promoteId:this.options.promoteId,filter:this.options.filter};return"number"==typeof this.options.clusterMaxZoom&&(t.clusterMaxZoom=this.options.clusterMaxZoom),t},A.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this._buildSource(),t=t._buildSource(),e.type===t.type)&&e.maxzoom===t.maxzoom&&e.cluster===t.cluster&&e.clusterRadius===t.clusterRadius&&e.tolerance===t.tolerance&&e.lineMetrics===t.lineMetrics&&JSON.stringify(e.clusterProperties)===JSON.stringify(t.clusterProperties)&&e.buffer===t.buffer&&e.clusterMinPoints===t.clusterMinPoints&&e.generateId===t.generateId&&e.promoteId===t.promoteId&&e.filter===t.filter},A.prototype._addNoUpdate=function(t,e){var o;t instanceof x?(this._addToSources(t,e),o=[t]):Array.isArray(t)?(o=t.map(function(t){return t instanceof x?t:new x(t)}),this._addToSources(o,e)):"FeatureCollection"===t.type?(o=t.features.map(function(t){return new x(t)}),this._addToSources(o,e)):"GeometryCollection"===t.type?(o=t.geometries.map(function(t){return new x(t)}),this._addToSources(o,e)):(t=new x(t),this._addToSources(t,e),o=[t]),this._invokeEvent("dataadded",o)},A.prototype._clearNoUpdate=function(){var t=this.shapes;this.shapes=[],this.shapesMap=new Ne,t&&0<t.length&&this._invokeEvent("dataremoved",t)},A.prototype._updateSource=function(){var t=this;void 0===this.requestId&&(this.requestId=requestAnimationFrame(function(){t._updateMboxSource(),t.requestId=void 0}))},A.prototype._addToSources=function(t,e){var o,n,r,i;if(t=Array.isArray(t)?t:[t],"number"!=typeof e)try{for(var s=Fu(t),a=s.next();!a.done;a=s.next()){var c=a.value;this.shapes.push(c),this.shapesMap.set(c.getId(),this.shapes.length-1)}}catch(t){o={error:t}}finally{try{a&&!a.done&&(n=s.return)&&n.call(s)}finally{if(o)throw o.error}}else for(var l=t.length-1;0<=l;l--)this.shapes.splice(e,0,t[l]),this._updateShapesMap(e);try{for(var u=Fu(t),p=u.next();!p.done;p=u.next())(c=p.value)._setDataSource(this)}catch(t){r={error:t}}finally{try{p&&!p.done&&(i=u.return)&&i.call(u)}finally{if(r)throw r.error}}},A.prototype._removeById=function(t){var t=t instanceof x?t.getId():"string"==typeof t||"number"==typeof t?t:t.id,e=this.shapes[this.shapesMap.get(t)];e&&(e._setDataSource(null),this.shapes.splice(this.shapesMap.get(t),1),this._updateShapesMap(this.shapesMap.get(t)),this.shapesMap.delete(t),this._invokeEvent("dataremoved",[e]))},A.prototype._removeByIndex=function(t){var e;if(t>=this.shapes.length)throw new Error("The specified remove index '".concat(t,"' ")+"is greater than the maximum possible index '".concat(this.shapes.length-1,"'"));e=this.shapes[t],this.shapesMap.delete(e.getId()),e._setDataSource(null),this.shapes.splice(t,1),this._updateShapesMap(t),this._invokeEvent("dataremoved",[e])},A.prototype._updateShapesMap=function(t){for(var e=t;e<this.shapes.length;e++)this.shapesMap.set(this.shapes[e].getId(),e)},A.prototype._updateMboxSource=function(){var t;this.map&&this.map._getMap()&&(t=this.map._getMap().getSource(this.getId()))&&"geojson"===t.type&&t.setData(this._toJson())},A);function A(t,e){t=Bu.call(this,t)||this;return t.requestId=void 0,t.options=(new ju).merge(c(e)),t.shapes=[],t.shapesMap=new Ne,t}(window&&window.__extends||(Zu=function(t,e){return(Zu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Zu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Uu,qu=t);var Zu,qu,Hu=Uu;function Uu(){var t=null!==qu&&qu.apply(this,arguments)||this;return t.bounds=void 0,t.minZoom=0,t.maxZoom=22,t.isTMS=!1,t.tiles=void 0,t.url=void 0,t}(window&&window.__extends||(Wu=function(t,e){return(Wu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Wu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Vu,Gu=k),Vu.prototype.getOptions=function(){return c(this.options)},Vu.prototype.getShape=function(t,e){return this.map._getMap().querySourceFeatures(this.getId(),{sourceLayer:t,filter:e})},Vu.prototype._buildSource=function(){var t={type:"vector"};return this.options.bounds&&(t.bounds=this.options.bounds),this.options.tiles?(t.tiles=this.options.tiles,t.minzoom=this.options.minZoom,t.maxzoom=this.options.maxZoom):this.options.url&&(t.url=this.options.url),this.options.isTMS&&(t.scheme="tms"),t},Vu.prototype._isDeepEqual=function(t){var e,o;return this.constructor===t.constructor&&(e=this._buildSource(),o=t._buildSource(),e.type===o.type)&&e.url===o.url&&(void 0===e.tiles&&void 0===o.tiles||e.tiles&&o.tiles&&e.tiles.length===o.tiles.length&&e.tiles.every(function(t,e){return t===o.tiles[e]}))&&e.minzoom===o.minzoom&&e.maxzoom===o.maxzoom&&e.bounds===o.bounds&&e.attribution===o.attribution&&e.promoteId===o.promoteId&&e.scheme===o.scheme};var Wu,Gu,r=Vu;function Vu(t,e){t=Gu.call(this,t)||this;return t.options=(new Hu).merge(c(e)),t}(window&&window.__extends||(Ku=function(t,e){return(Ku=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ku(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))($u,Yu=k),$u.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)&&e.canvas===t.canvas&&JSON.stringify(e.coordinates)===JSON.stringify(t.coordinates)&&e.animate===t.animate},$u.prototype._buildSource=function(){return this.source};var Ku,Yu,Ju=$u;function $u(t,e,o){t=Yu.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(Xu=function(t,e){return(Xu=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Xu(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(ep,Qu=k),ep.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)},ep.prototype._buildSource=function(){return this.source};var Xu,Qu,tp=ep;function ep(t,e,o){t=Qu.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(op=function(t,e){return(op=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}op(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(ip,np=k),ip.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)&&JSON.stringify(e.coordinates)===JSON.stringify(t.coordinates)&&e.url===t.url},ip.prototype._buildSource=function(){return this.source};var op,np,rp=ip;function ip(t,e,o){t=np.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(sp=function(t,e){return(sp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}sp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(lp,ap=k),lp.prototype._isDeepEqual=function(t){var e;return this.constructor===t.constructor&&(e=this.source,t=t.source,e.type===t.type)&&JSON.stringify(e.coordinates)===JSON.stringify(t.coordinates)&&e.urls===t.urls},lp.prototype._buildSource=function(){return this.source};var sp,ap,cp=lp;function lp(t,e,o){t=ap.call(this,t)||this;return t.source=e,t}(window&&window.__extends||(up=function(t,e){return(up=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}up(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(hp,pp=Hu);var up,pp,Jo=hp;function hp(){var t=null!==pp&&pp.apply(this,arguments)||this;return t.tileSize=512,t}(window&&window.__extends||(dp=function(t,e){return(dp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}dp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(mp,fp=Jo);var dp,fp,yp=mp;function mp(){var t=null!==fp&&fp.apply(this,arguments)||this;return t.encoding=void 0,t}var gp,vp,i=window&&window.__extends||(gp=function(t,e){return(gp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}gp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),wp=window&&window.__assign||function(){return(wp=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},er=(i(_p,vp=k),_p.prototype.getOptions=function(){return c(this.options)},_p.prototype._buildSource=function(){return wp({type:"raster-dem",bounds:this.options.bounds,minzoom:this.options.minZoom,maxzoom:this.options.maxZoom,tileSize:this.options.tileSize,encoding:this.options.encoding},this.options.tiles?{tiles:this.options.tiles}:{url:this.options.url})},_p.prototype._isDeepEqual=function(t){return this.constructor===t.constructor&&(t=t.getOptions(),this.options.url===t.url)&&this.options.tiles===t.tiles&&this.options.bounds===t.bounds&&this.options.minZoom===t.minZoom&&this.options.maxZoom===t.maxZoom&&this.options.tileSize===t.tileSize&&this.options.encoding===t.encoding},_p);function _p(t,e){t=vp.call(this,t)||this;return t.options=(new yp).merge(c(e)),t}var bp,xp,Ao=Object.freeze({__proto__:null,CanvasSource:Ju,DataSource:Nu,ElevationTileSource:er,ImageSource:rp,Source:k,UnknownSource:tp,VectorTileSource:r,VideoSource:cp}),M=((window&&window.__extends||(bp=function(t,e){return(bp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}bp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Op,xp=Ze),Op.prototype.getId=function(){return this.id},Op.prototype.getMap=function(){return this.map||null},Op.prototype.onAdd=function(t){this.map=t,this._invokeEvent("layeradded",this),this.map.events.invoke("layeradded",this)},Op.prototype.onRemove=function(){var t=this.map;delete this.map,this._invokeEvent("layerremoved",this),t&&t.events.invoke("layerremoved",this)},Op._isMBoxEvent=function(t){return!this.LayerEvents.hasOwnProperty(t)},Op.prototype._updateBaseProperties=function(t,e){this._updateFilter(t.filter,e.filter),this._updateZoomRange(t.minZoom,e.minZoom,t.maxZoom,e.maxZoom),this._updateLayoutProperty("visibility",t.visible,e.visible,t.visible?"visible":"none")},Op.prototype._updateFilter=function(t,e){Bc(t,e)||this.map._getMap().setFilter(this.id,t)},Op.prototype._updatePaintProperty=function(t,e,o,n){Bc(e,o)||this.map._getMap().setPaintProperty(this.id,t,n||e)},Op.prototype._updateLayoutProperty=function(t,e,o,n){Bc(e,o)||this.map._getMap().setLayoutProperty(this.id,t,n||e)},Op.prototype._updateZoomRange=function(t,e,o,n){t===e&&n===o||this.map._getMap().setLayerZoomRange(this.id,t,o)},Op.LayerEvents={layeradded:void 0,layerremoved:void 0,focusin:void 0,focusout:void 0},Op);function Op(t){var e=xp.call(this)||this;return e.id=t||J(),e}(window&&window.__extends||(Sp=function(t,e){return(Sp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Sp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Pp,Cp=t),Pp._cloneCustomizer=function(t){if(t instanceof k)return t};var Sp,Cp,e=Pp;function Pp(){var t=null!==Cp&&Cp.apply(this,arguments)||this;return t.filter=void 0,t.minZoom=0,t.maxZoom=24,t.visible=!0,t}(window&&window.__extends||(Lp=function(t,e){return(Lp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Lp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Mp,kp=e);var Lp,kp,Ap=Mp;function Mp(){var t=null!==kp&&kp.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.color="#1A73AA",t.blur=0,t.opacity=1,t.strokeColor="#FFFFFF",t.strokeOpacity=1,t.strokeWidth=2,t.pitchAlignment="viewport",t.radius=8,t.createIndicators=!1,t.accessibilityIdKey=void 0,t}var Ep,jp,tr=window&&window.__extends||(Ep=function(t,e){return(Ep=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ep(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ip=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},Tp=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},zp=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Dp=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Rp=(tr(Bp,jp=M),Bp.prototype.getOptions=function(){return L(this.options,Ap._cloneCustomizer)},Bp.prototype.getSource=function(){return this.options.source},Bp.prototype.setOptions=function(t){t=(new Ap).merge(this.options,L(t,Ap._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("circle-blur",t.blur,this.options.blur),this._updatePaintProperty("circle-color",t.color,this.options.color),this._updatePaintProperty("circle-opacity",t.opacity,this.options.opacity),this._updatePaintProperty("circle-radius",t.radius,this.options.radius),this._updatePaintProperty("circle-stroke-color",t.strokeColor,this.options.strokeColor),this._updatePaintProperty("circle-stroke-opacity",t.strokeOpacity,this.options.strokeOpacity),this._updatePaintProperty("circle-stroke-width",t.strokeWidth,this.options.strokeWidth),this._updatePaintProperty("circle-pitch-alignment",t.pitchAlignment,this.options.pitchAlignment)}this.options=t},Bp.prototype.onAdd=function(e){var t,o,n=this;jp.prototype.onAdd.call(this,e),this.options.createIndicators&&(e.events.addOnce("idle",this._setAccessibleIndicator),e.events.add("moveend",this._setAccessibleIndicator),(t=this._getDataSource())?e.events.add("dataadded",t,function(){e.events.addOnce("idle",n._setAccessibleIndicator)}):(o="string"==typeof this.options.source?this.options.source:this.options.source.getId(),e.events.add("sourcedata",function(t){(null==(t=t.source)?void 0:t.getId())===o&&e._getMap().isSourceLoaded(o)&&(t=n._getSourceDataEventCacheKey())!==n.sourceDataEventCacheKey&&(n._setAccessibleIndicator(),n.sourceDataEventCacheKey=t)})))},Bp.prototype.onRemove=function(){var t;this.options.createIndicators&&(this.map.events.remove("idle",this._setAccessibleIndicator),this.map.events.remove("moveend",this._setAccessibleIndicator),(t=this._getDataSource())?this.map.events.remove("dataadded",t,this._setAccessibleIndicator):this.map.events.remove("sourcedata",this._setAccessibleIndicator)),jp.prototype.onRemove.call(this)},Bp.prototype._getSourceDataEventCacheKey=function(){var t;if(this.map)return t=this.map.getServiceOptions().mapConfiguration,Dp(Dp([],zp(this.map.getCamera().bounds),!1),[this.map.getCamera().zoom,this.map.getCamera().pitch,this.map.getStyle().style,t instanceof Object?t.id:t],!1).join(",")},Bp.prototype._getDataSource=function(){var t="string"==typeof this.options.source?this.map.sources.getById(this.options.source):this.options.source;if(t instanceof Nu)return t},Bp.prototype._buildLayers=function(){var t={id:this.id,type:"circle",source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:{"circle-color":this.options.color,"circle-blur":this.options.blur,"circle-opacity":this.options.opacity,"circle-stroke-color":this.options.strokeColor,"circle-stroke-opacity":this.options.strokeOpacity,"circle-stroke-width":this.options.strokeWidth,"circle-pitch-alignment":this.options.pitchAlignment,"circle-radius":this.options.radius},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),this.options.sourceLayer&&(t["source-layer"]=this.options.sourceLayer),[t]},Bp.prototype._getLayerIds=function(){return[this.id]},Bp.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},Bp.prototype.getFirstCoordinate=function(t){return Array.isArray(t[0])?this.getFirstCoordinate(t[0]):t},Bp);function Bp(t,e,o){var n=jp.call(this,e)||this;return n.accessibleIndicator=[],n._setAccessibleIndicator=function(){return Ip(n,void 0,void 0,function(){var e,c,l,u,p,h,d=this;return Tp(this,function(t){return this.accessibleIndicator.forEach(function(t){return t.remove()}),this.accessibleIndicator=[],e=this.map.layers.getRenderedShapes(this.map.getCamera().bounds,this),c=this.options.accessibilityIdKey||(this._getDataSource()?x._shapeIdPropName:void 0),l=function(e,o){var n=e[o],r=n instanceof x?n.toJson():n,i=new ku({positionInSet:o+1,setSize:e.length}),s=i.getElement(),a=zp(d.map.positionsToPixels([d.getFirstCoordinate(r.geometry.coordinates)]),1)[0];return s.addEventListener("focusin",function(t){d.accessibleIndicator.filter(function(t){return t!==i}).forEach(function(t){return t.remove()}),0<=o-1&&u(i,l(e,o-1)),o+1<e.length&&h(l(e,o+1)),2<=o&&o==e.length-1&&p(l(e,0)),0==o&&2<=e.length&&h(l(e,e.length-1)),void 0!==c&&d.map._getMap().setPaintProperty(d.id,"circle-stroke-color",["case",["==",["get",c],r.properties[c]],"#000000",d.options.strokeColor]);t={target:s,type:"focusin",map:d.map,shape:n,originalEvent:t,pixel:a};d._invokeEvent("focusin",t)}),s.addEventListener("focusout",function(t){void 0!==c&&d.map._getMap().setPaintProperty(d.id,"circle-stroke-color",["case",["==",["get",c],r.properties[c]],d.options.strokeColor,d.options.strokeColor]);t={target:s,type:"focusout",map:d.map,shape:n,originalEvent:t,pixel:a};d._invokeEvent("focusout",t)}),d.accessibleIndicator.push(i),i},u=function(t,e){e.attach(d.map);e=e.getElement(),t=t.getElement();t.parentElement.insertBefore(e,t)},p=function(t){t.attach(d.map);var t=t.getElement(),e=t.parentElement;e.insertBefore(t,e.firstElementChild)},h=function(t){t.attach(d.map)},0<e.length&&h(l(e,0)),1<e.length&&h(l(e,e.length-1)),[2]})})},n.options=(new Ap).merge(L(o,Ap._cloneCustomizer)),n.options.source=t||n.options.source,n}(window&&window.__extends||(Fp=function(t,e){return(Fp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(qp,Np=e),qp._cloneCustomizer=function(t){if(t instanceof k)return t};var Fp,Np,Zp=qp;function qp(){var t=null!==Np&&Np.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.color=["interpolate",["linear"],["heatmap-density"],0,"rgba(0,0, 255,0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],t.intensity=1,t.opacity=1,t.radius=30,t.weight=1,t}(window&&window.__extends||(Hp=function(t,e){return(Hp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Hp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Wp,Up=M),Wp.prototype.getOptions=function(){return L(this.options,Zp._cloneCustomizer)},Wp.prototype.getSource=function(){return this.options.source},Wp.prototype.setOptions=function(t){t=(new Zp).merge(this.options,L(t,Zp._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("heatmap-color",t.color,this.options.color),this._updatePaintProperty("heatmap-intensity",t.intensity,this.options.intensity),this._updatePaintProperty("heatmap-opacity",t.opacity,this.options.opacity),this._updatePaintProperty("heatmap-radius",t.radius,this.options.radius),this._updatePaintProperty("heatmap-weight",t.weight,this.options.weight)}this.options=t},Wp.prototype._buildLayers=function(){var t={id:this.id,type:"heatmap",source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:{"heatmap-color":this.options.color,"heatmap-intensity":this.options.intensity,"heatmap-opacity":this.options.opacity,"heatmap-radius":this.options.radius,"heatmap-weight":this.options.weight},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),this.options.sourceLayer&&(t["source-layer"]=this.options.sourceLayer),[t]},Wp.prototype._getLayerIds=function(){return[this.id]},Wp.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t};var Hp,Up,H=Wp;function Wp(t,e,o){e=Up.call(this,e)||this;return e.options=(new Zp).merge(L(o,Zp._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(Gp=function(t,e){return(Gp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Gp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Kp,Vp=e);var Gp,Vp,s=Kp;function Kp(){var t=null!==Vp&&Vp.apply(this,arguments)||this;return t.contrast=0,t.fadeDuration=300,t.hueRotation=0,t.maxBrightness=1,t.minBrightness=0,t.opacity=1,t.saturation=0,t}(window&&window.__extends||(Yp=function(t,e){return(Yp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Yp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Xp,Jp=s),Xp._cloneCustomizer=function(t){if(t instanceof k)return t};var Yp,Jp,$p=Xp;function Xp(){var t=null!==Jp&&Jp.apply(this,arguments)||this;return t.url=void 0,t.coordinates=void 0,t}(window&&window.__extends||(Qp=function(t,e){return(Qp=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Qp(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(oh,th=M),oh.prototype._getSourceIds=function(){var t=new Set;return t.add(this._getSourceId()),t},oh.prototype.onAdd=function(t){th.prototype.onAdd.call(this,t)};var Qp,th,eh=oh;function oh(){return null!==th&&th.apply(this,arguments)||this}(window&&window.__extends||(nh=function(t,e){return(nh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}nh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(ih,rh=eh),ih.prototype.getOptions=function(){return L(this.options,$p._cloneCustomizer)},ih.prototype.setOptions=function(t){var e,o=(new $p).merge(this.options,L(t,$p._cloneCustomizer)),n="string"==typeof t.url&&t.url!==this.getOptions().url,t=void 0!==t.coordinates&&t.coordinates!==this.getOptions().coordinates;this.map&&(this._updateBaseProperties(o,this.options),this._updatePaintProperty("raster-contrast",o.contrast,this.options.contrast),this._updatePaintProperty("raster-fade-duration",o.fadeDuration,this.options.fadeDuration),this._updatePaintProperty("raster-hue-rotate",o.hueRotation,this.options.hueRotation),this._updatePaintProperty("raster-brightness-max",o.maxBrightness,this.options.maxBrightness),this._updatePaintProperty("raster-opacity",o.opacity,this.options.opacity),this._updatePaintProperty("raster-saturation",o.saturation,this.options.saturation),e=this.map._getMap().getSource(this._getSourceId()))&&(n||t)&&e.updateImage(o),this.options=o,n?this.reloadImage():t&&this.updateTransform()},ih.prototype.getPositions=function(e){return this.transform.then(function(t){return t.toTarget(e)})},ih.prototype.getPixels=function(e){return this.transform.then(function(t){return t.toSource(e)})},ih.getCoordinatesFromRefPoints=function(t,e,o,n){return new pu(o,n).toTarget([[0,0],[t,0],[t,e],[0,e]])},ih.getCoordinatesFromEdges=function(t,e,o,n,r){"number"!=typeof r&&(r=0);e=[Math.min(n,o),e,Math.max(n,o),t],n=S.getCenter(e);return Cl([S.getNorthWest(e),S.getNorthEast(e),S.getSouthEast(e),S.getSouthWest(e)],n,r)},ih.prototype._buildLayers=function(){var t={id:this.id,type:"raster",source:this._getSourceId(),layout:{visibility:this.options.visible?"visible":"none"},paint:{"raster-opacity":this.options.opacity,"raster-hue-rotate":this.options.hueRotation,"raster-brightness-min":this.options.minBrightness,"raster-brightness-max":this.options.maxBrightness,"raster-saturation":this.options.saturation,"raster-contrast":this.options.contrast,"raster-fade-duration":this.options.fadeDuration},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),[t]},ih.prototype._getLayerIds=function(){return[this.id]},ih.prototype._buildSource=function(){return{type:"image",url:this.options.url,coordinates:this.options.coordinates}},ih.prototype._getSourceId=function(){return"".concat(this.getId(),"-ImageSource")},ih.prototype.reloadImage=function(){var o=this;this.options.url&&(this.transform=new Promise(function(e,t){o.img.onload=function(){var t=[[0,0],[o.img.width,0],[o.img.width,o.img.height],[0,o.img.height]];e(new pu(t,o.options.coordinates)),o.isLoading=!1},o.img.onerror=o.img.onabort=function(){t("Failed to load image")},o.isLoading=!0,o.img.src=o.options.url}))},ih.prototype.updateTransform=function(){var t;this.isLoading||(t=[[0,0],[this.img.width,0],[this.img.width,this.img.height],[0,this.img.height]],this.transform=Promise.resolve(new pu(t,this.options.coordinates)))},ih.prototype._getSourceWrapper=function(){var t=this._getSourceId(),e=this._buildSource();return new rp(t,e)};var nh,rh,In=ih;function ih(t,e){e=rh.call(this,e)||this;return e.isLoading=!1,e.options=(new $p).merge(L(t,$p._cloneCustomizer)),e.img=new Image,e.reloadImage(),e}(window&&window.__extends||(sh=function(t,e){return(sh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}sh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(lh,ah=e);var sh,ah,ch=lh;function lh(){var t=null!==ah&&ah.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.lineCap="round",t.lineJoin="round",t.blur=0,t.strokeColor="#1E90FF",t.strokeDashArray=void 0,t.strokeGradient=void 0,t.offset=0,t.strokeOpacity=1,t.translate=new Hc(0,0),t.translateAnchor="map",t.strokeWidth=2,t}var uh,ph,q=window&&window.__extends||(uh=function(t,e){return(uh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}uh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),hh=window&&window.__assign||function(){return(hh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},dh=(q(fh,ph=M),fh.prototype.getOptions=function(){return L(this.options,ch._cloneCustomizer)},fh.prototype.getSource=function(){return this.options.source},fh.prototype.setOptions=function(t){t=(new ch).merge(this.options,L(t,ch._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("line-blur",t.blur,this.options.blur),this._updateLayoutProperty("line-cap",t.lineCap,this.options.lineCap),this._updateLayoutProperty("line-join",t.lineJoin,this.options.lineJoin),this._updatePaintProperty("line-offset",t.offset,this.options.offset),this._updatePaintProperty("line-color",t.strokeColor,this.options.strokeColor),this._updatePaintProperty("line-dasharray",t.strokeDashArray,this.options.strokeDashArray),this._updatePaintProperty("line-gradient",t.strokeGradient,this.options.strokeGradient),this._updatePaintProperty("line-opacity",t.strokeOpacity,this.options.strokeOpacity),this._updatePaintProperty("line-width",t.strokeWidth,this.options.strokeWidth),this._updatePaintProperty("line-translate",t.translate,this.options.translate),this._updatePaintProperty("line-translate-anchor",t.translateAnchor,this.options.translateAnchor)}this.options=t},fh.prototype._buildLayers=function(){return[hh(hh(hh(hh({id:this.id,type:"line"},this.options.sourceLayer&&{"source-layer":this.options.sourceLayer}),{source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none","line-cap":this.options.lineCap,"line-join":this.options.lineJoin},paint:hh(hh(hh({"line-blur":this.options.blur,"line-color":this.options.strokeColor},this.options.strokeDashArray?{"line-dasharray":this.options.strokeDashArray}:{}),this.options.strokeGradient?{"line-gradient":this.options.strokeGradient}:{}),{"line-offset":this.options.offset,"line-opacity":this.options.strokeOpacity,"line-translate":this.options.translate,"line-translate-anchor":this.options.translateAnchor,"line-width":this.options.strokeWidth})}),this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom})]},fh.prototype._getLayerIds=function(){return[this.id]},fh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},fh);function fh(t,e,o){e=ph.call(this,e)||this;return e.options=(new ch).merge(L(o,ch._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(yh=function(t,e){return(yh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}yh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(vh,mh=e);var yh,mh,gh=vh;function vh(){var t=null!==mh&&mh.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.base=0,t.fillColor="#1E90FF",t.height=0,t.fillOpacity=1,t.fillPattern=void 0,t.translate=new Hc(0,0),t.translateAnchor="map",t.verticalGradient=!0,t}var wh,_h,jn=window&&window.__extends||(wh=function(t,e){return(wh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}wh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),bh=window&&window.__assign||function(){return(bh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},yt=(jn(xh,_h=M),xh.prototype.getOptions=function(){return L(this.options,gh._cloneCustomizer)},xh.prototype.getSource=function(){return this.options.source},xh.prototype.setOptions=function(t){t=(new gh).merge(this.options,L(t,gh._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("fill-extrusion-base",t.base,this.options.base),this._updatePaintProperty("fill-extrusion-color",t.fillColor,this.options.fillColor),this._updatePaintProperty("fill-extrusion-height",t.height,this.options.height),this._updatePaintProperty("fill-extrusion-opacity",t.fillOpacity,this.options.fillOpacity),this._updatePaintProperty("fill-extrusion-pattern",t.fillPattern,this.options.fillPattern),this._updatePaintProperty("fill-extrusion-translate",t.translate,this.options.translate),this._updatePaintProperty("fill-extrusion-translate-anchor",t.translateAnchor,this.options.translateAnchor),this._updatePaintProperty("fill-extrusion-vertical-gradient",t.verticalGradient,this.options.verticalGradient)}this.options=t},xh.prototype._buildLayers=function(){return[bh(bh(bh(bh({id:this.id,type:"fill-extrusion"},this.options.sourceLayer&&{"source-layer":this.options.sourceLayer}),{source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:bh(bh({"fill-extrusion-base":this.options.base,"fill-extrusion-height":this.options.height,"fill-extrusion-opacity":this.options.fillOpacity},this.options.fillPattern?{"fill-extrusion-pattern":this.options.fillPattern}:{"fill-extrusion-color":this.options.fillColor}),{"fill-extrusion-translate":this.options.translate,"fill-extrusion-translate-anchor":this.options.translateAnchor,"fill-extrusion-vertical-gradient":this.options.verticalGradient})}),this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom})]},xh.prototype._getLayerIds=function(){return[this.id]},xh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},xh);function xh(t,e,o){e=_h.call(this,e)||this;return e.options=(new gh).merge(L(o,gh._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(Oh=function(t,e){return(Oh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Oh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ph,Sh=e);var Oh,Sh,Ch=Ph;function Ph(){var t=null!==Sh&&Sh.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.fillColor="#1E90FF",t.fillOpacity=.5,t.fillPattern=void 0,t.fillAntialias=!0,t}(window&&window.__extends||(Lh=function(t,e){return(Lh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Lh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Mh,kh=M),Mh.prototype.getOptions=function(){return L(this.options,Ch._cloneCustomizer)},Mh.prototype.getSource=function(){return this.options.source},Mh.prototype.setOptions=function(t){t=(new Ch).merge(this.options,L(t,Ch._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("fill-color",t.fillColor,this.options.fillColor),this._updatePaintProperty("fill-opacity",t.fillOpacity,this.options.fillOpacity),this._updatePaintProperty("fill-pattern",t.fillPattern,this.options.fillPattern),this._updatePaintProperty("fill-antialias",t.fillAntialias,this.options.fillAntialias)}this.options=t},Mh.prototype._buildLayers=function(){var t={id:this.id,type:"fill",source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:{visibility:this.options.visible?"visible":"none"},paint:{"fill-opacity":this.options.fillOpacity,"fill-antialias":this.options.fillAntialias},minzoom:this.options.minZoom,maxzoom:this.options.maxZoom};return this.options.filter&&(t.filter=this.options.filter),this.options.sourceLayer&&(t["source-layer"]=this.options.sourceLayer),this.options.fillPattern?t.paint["fill-pattern"]=this.options.fillPattern:t.paint["fill-color"]=this.options.fillColor,[t]},Mh.prototype._getLayerIds=function(){return[this.id]},Mh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t};var Lh,kh,Ah=Mh;function Mh(t,e,o){e=kh.call(this,e)||this;return e.options=(new Ch).merge(L(o,Ch._cloneCustomizer)),e.options.source=t||e.options.source,e}(window&&window.__extends||(Eh=function(t,e){return(Eh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Eh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Th,jh=t);var Eh,jh,Ih=Th;function Th(){var t=null!==jh&&jh.apply(this,arguments)||this;return t.allowOverlap=!1,t.anchor="bottom",t.ignorePlacement=!1,t.image="marker-blue",t.offset=new Hc(0,0),t.optional=!1,t.padding=2,t.pitchAlignment="auto",t.rotation=0,t.rotationAlignment="auto",t.size=1,t.opacity=1,t}(window&&window.__extends||(zh=function(t,e){return(zh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}zh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Bh,Dh=t);var zh,Dh,Rh=Bh;function Bh(){var t=null!==Dh&&Dh.apply(this,arguments)||this;return t.allowOverlap=!1,t.anchor="center",t.textField=void 0,t.font=["StandardFont-Regular"],t.ignorePlacement=!1,t.justify="center",t.offset=new Hc(0,0),t.optional=!1,t.padding=2,t.pitchAlignment="auto",t.radialOffset=void 0,t.rotation=0,t.rotationAlignment="auto",t.variableAnchor=void 0,t.size=16,t.color="#000000",t.haloBlur=0,t.haloColor="rgba(0,0,0,0)",t.haloWidth=0,t.opacity=1,t}(window&&window.__extends||(Fh=function(t,e){return(Fh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(qh,Nh=e);var Fh,Nh,Zh=qh;function qh(){var t=null!==Nh&&Nh.apply(this,arguments)||this;return t.source=void 0,t.sourceLayer=void 0,t.iconOptions=new Ih,t.textOptions=new Rh,t.placement="point",t.sortKey=void 0,t.zOrder="auto",t.lineSpacing=250,t}var Hh,Uh,ze=window&&window.__extends||(Hh=function(t,e){return(Hh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Hh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Wh=window&&window.__assign||function(){return(Wh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Gh=(ze(Vh,Uh=M),Vh.prototype.getOptions=function(){return L(this.options,Zh._cloneCustomizer)},Vh.prototype.getSource=function(){return this.options.source},Vh.prototype.setOptions=function(t){t=(new Zh).merge(this.options,L(t,Zh._cloneCustomizer));if(this.map){if(t.source!==this.options.source||t.sourceLayer!==this.options.sourceLayer)return this.options=t,void this.map.layers.add(this);var e=this.options,o=t.iconOptions,n=e.iconOptions,r=t.textOptions,i=e.textOptions;this._updateBaseProperties(t,e),this._updateLayoutProperty("symbol-spacing",t.lineSpacing,e.lineSpacing),this._updateLayoutProperty("symbol-placement",t.placement,e.placement),this._updateLayoutProperty("symbol-sort-key",t.sortKey,e.sortKey),this._updateLayoutProperty("symbol-z-order",t.zOrder,e.zOrder),this._updateLayoutProperty("icon-allow-overlap",o.allowOverlap,n.allowOverlap),this._updateLayoutProperty("icon-anchor",o.anchor,n.anchor),this._updateLayoutProperty("icon-ignore-placement",o.ignorePlacement,n.ignorePlacement),this._updateLayoutProperty("icon-image",o.image,n.image),this._updateLayoutProperty("icon-offset",o.offset,n.offset),this._updatePaintProperty("icon-opacity",o.opacity,n.opacity),this._updateLayoutProperty("icon-optional",o.optional,n.optional),this._updateLayoutProperty("icon-padding",o.padding,n.padding),this._updateLayoutProperty("icon-pitch-alignment",o.pitchAlignment,n.pitchAlignment),this._updateLayoutProperty("icon-rotate",o.rotation,n.rotation),this._updateLayoutProperty("icon-rotation-alignment",o.rotationAlignment,n.rotationAlignment),this._updateLayoutProperty("icon-size",o.size,n.size),this._updateLayoutProperty("text-allow-overlap",r.allowOverlap,i.allowOverlap),this._updateLayoutProperty("text-anchor",r.anchor,i.anchor),this._updatePaintProperty("text-color",r.color,i.color),this._updateLayoutProperty("text-font",r.font,i.font),this._updateLayoutProperty("text-ignore-placement",r.ignorePlacement,i.ignorePlacement),this._updateLayoutProperty("text-justify",r.justify,i.justify),this._updatePaintProperty("text-halo-blur",r.haloBlur,i.haloBlur),this._updatePaintProperty("text-halo-color",r.haloColor,i.haloColor),this._updatePaintProperty("text-halo-width",r.haloWidth,i.haloWidth),this._updateLayoutProperty("text-offset",r.offset,i.offset),this._updatePaintProperty("text-opacity",r.opacity,i.opacity),this._updateLayoutProperty("text-optional",r.optional,i.optional),this._updateLayoutProperty("text-padding",r.padding,i.padding),this._updateLayoutProperty("text-pitch-alignment",r.pitchAlignment,i.pitchAlignment),this._updateLayoutProperty("text-radial-offset",r.radialOffset,i.radialOffset),this._updateLayoutProperty("text-rotate",r.rotation,i.rotation),this._updateLayoutProperty("text-rotation-alignment",r.rotationAlignment,i.rotationAlignment),this._updateLayoutProperty("text-size",r.size,i.size),this._updateLayoutProperty("text-variable-anchor",r.variableAnchor,i.variableAnchor),this._updateLayoutProperty("text-field",r.textField,i.textField)}this.options=t},Vh.prototype._buildLayers=function(){var t=Wh(Wh(Wh(Wh({id:this.id,type:"symbol"},this.options.sourceLayer&&{"source-layer":this.options.sourceLayer}),{source:this.options.source instanceof k?this.options.source.getId():this.options.source,layout:Wh(Wh({visibility:this.options.visible?"visible":"none","symbol-placement":this.options.placement,"symbol-spacing":this.options.lineSpacing,"symbol-z-order":this.options.zOrder,"text-allow-overlap":this.options.textOptions.allowOverlap,"text-anchor":this.options.textOptions.anchor},this.options.textOptions.textField&&{"text-field":this.options.textOptions.textField}),{"text-font":this.options.textOptions.font,"text-ignore-placement":this.options.textOptions.ignorePlacement,"text-justify":this.options.textOptions.justify,"text-offset":this.options.textOptions.offset,"text-optional":this.options.textOptions.optional,"text-padding":this.options.textOptions.padding,"text-pitch-alignment":this.options.textOptions.pitchAlignment,"text-rotate":this.options.textOptions.rotation,"text-rotation-alignment":this.options.textOptions.rotationAlignment,"text-size":this.options.textOptions.size,"icon-allow-overlap":this.options.iconOptions.allowOverlap,"icon-anchor":this.options.iconOptions.anchor,"icon-ignore-placement":this.options.iconOptions.ignorePlacement,"icon-image":this.options.iconOptions.image,"icon-offset":this.options.iconOptions.offset,"icon-optional":this.options.iconOptions.optional,"icon-padding":this.options.iconOptions.padding,"icon-pitch-alignment":this.options.iconOptions.pitchAlignment,"icon-rotate":this.options.iconOptions.rotation,"icon-rotation-alignment":this.options.iconOptions.rotationAlignment,"icon-size":this.options.iconOptions.size}),paint:{"text-color":this.options.textOptions.color,"text-halo-blur":this.options.textOptions.haloBlur,"text-halo-color":this.options.textOptions.haloColor,"text-halo-width":this.options.textOptions.haloWidth,"text-opacity":this.options.textOptions.opacity,"icon-opacity":this.options.iconOptions.opacity}}),this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom});return void 0!==this.options.sortKey&&(t.layout["symbol-sort-key"]=this.options.sortKey),void 0!==this.options.textOptions.radialOffset&&(t.layout["text-radial-offset"]=this.options.textOptions.radialOffset),void 0!==this.options.textOptions.variableAnchor&&(t.layout["text-variable-anchor"]=this.options.textOptions.variableAnchor),[t]},Vh.prototype._getLayerIds=function(){return[this.id]},Vh.prototype._getSourceIds=function(){var t=new Set;return this.options.source instanceof k?t.add(this.options.source.getId()):t.add(this.options.source),t},Vh);function Vh(t,e,o){e=Uh.call(this,e)||this;return e.options=(new Zh).merge(L(o,Zh._cloneCustomizer)),e.options.source=t||e.options.source,e}var Kh,Yh,bi=window&&window.__extends||(Kh=function(t,e){return(Kh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Kh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Jh=window&&window.__assign||function(){return(Jh=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},$h=(bi(Xh,Yh=k),Xh.prototype._buildSource=function(){return this.source},Xh.prototype._isDeepEqual=function(t){var o,e,n,r;return this.constructor===t.constructor&&(r=this.source,o=t.source,t=r.type===o.type&&r.url===o.url&&(void 0===r.tiles&&void 0===o.tiles||r.tiles&&o.tiles&&r.tiles.length===o.tiles.length&&r.tiles.every(function(t,e){return t===o.tiles[e]}))&&r.minzoom===o.minzoom&&r.maxzoom===o.maxzoom&&r.bounds===o.bounds&&r.attribution===o.attribution,e="raster"!==r.type||"raster"===r.type&&r.type===o.type&&r.tileSize===o.tileSize&&r.scheme===o.scheme,n="raster-dem"!==r.type||"raster-dem"===r.type&&r.type===o.type&&r.tileSize===o.tileSize&&r.encoding===o.encoding,r="vector"!==r.type||"vector"===r.type&&r.type===o.type&&r.promoteId===o.promoteId&&r.scheme===o.scheme,t)&&e&&n&&r},Xh.prototype._modifySource=function(t,e){if("raster"!==t.type&&"raster-dem"!==t.type&&"vector"!==t.type||!t.tiles){if("raster"!==t.type&&"raster-dem"!==t.type&&"vector"!==t.type||!t.url)throw new Error("Source definition must define a TileJSON 'url' or a 'tiles' array.");t.url="string"==typeof t.url?t.url:new wt({domain:et,path:t.url.path,queryParams:Jh(Jh({},e),t.url.queryParams)}).toString()}else{var o=t.tiles.map(function(t){return"string"==typeof t?t:new wt({domain:et,path:t.path,queryParams:Jh(Jh({},e),t.queryParams)}).toString()});t.tiles=o}return t},Xh);function Xh(t,e,o){t=Yh.call(this,t)||this;return t.source=t._modifySource(e,o),t}(window&&window.__extends||(Qh=function(t,e){return(Qh=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Qh(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(od,td=s);var Qh,td,ed=od;function od(){var t=null!==td&&td.apply(this,arguments)||this;return t.bounds=[-180,-85.0511,180,85.0511],t.minSourceZoom=0,t.maxSourceZoom=22,t.tileSize=512,t.isTMS=!1,t.subdomains=void 0,t.tileUrl=void 0,t}var nd,rd,R=window&&window.__extends||(nd=function(t,e){return(nd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}nd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),id=window&&window.__assign||function(){return(id=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},sd=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},ad=(R(cd,rd=eh),cd.prototype.getOptions=function(){return L(this.options,ed._cloneCustomizer)},cd.prototype.setOptions=function(t){t=(new ed).merge(this.options,L(t,ed._cloneCustomizer));if(this.map){if(!Bc(t.bounds,this.options.bounds)||t.isTMS!==this.options.isTMS||t.maxSourceZoom!==this.options.maxSourceZoom||t.minSourceZoom!==this.options.minSourceZoom||!Bc(t.subdomains,this.options.subdomains)||t.tileSize!==this.options.tileSize||t.tileUrl!==this.options.tileUrl)return this.options=t,void this.map.layers.add(this);this._updateBaseProperties(t,this.options),this._updatePaintProperty("raster-contrast",t.contrast,this.options.contrast),this._updatePaintProperty("raster-fade-duration",t.fadeDuration,this.options.fadeDuration),this._updatePaintProperty("raster-hue-rotate",t.hueRotation,this.options.hueRotation),this._updatePaintProperty("raster-brightness-max",t.maxBrightness,this.options.maxBrightness),this._updatePaintProperty("raster-opacity",t.opacity,this.options.opacity),this._updatePaintProperty("raster-saturation",t.saturation,this.options.saturation)}this.options=t},cd.prototype._setOptionsNoUpdate=function(t){this.options=(new ed).merge(this.options,L(t,ed._cloneCustomizer))},cd.prototype._buildLayers=function(){return[id(id({id:this.id,type:"raster",source:this._getSourceId(),layout:{visibility:this.options.visible?"visible":"none"},paint:{"raster-contrast":this.options.contrast,"raster-fade-duration":this.options.fadeDuration,"raster-hue-rotate":this.options.hueRotation,"raster-brightness-max":this.options.maxBrightness,"raster-brightness-min":this.options.minBrightness,"raster-opacity":this.options.opacity,"raster-saturation":this.options.saturation}},this.options.filter&&{filter:this.options.filter}),{minzoom:this.options.minZoom,maxzoom:this.options.maxZoom})]},cd.prototype._getLayerIds=function(){return[this.id]},cd.prototype._buildSource=function(){var e,t;if(this.options.tileUrl){if(-1===this.options.tileUrl.indexOf("{"))return{type:"raster",url:this.options.tileUrl};if(-1!==this.options.tileUrl.indexOf("{subdomain}")){if(!(this.options.subdomains&&0<this.options.subdomains.length))throw new Error("The {subdomain} placeholder was included in the tileUrl but no subdomains were specified");var o=[];try{for(var n=sd(this.options.subdomains),r=n.next();!r.done;r=n.next()){var i=r.value;o.push(this.options.tileUrl.replace(/{subdomain}/g,i))}}catch(t){e={error:t}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}t=o}else t=[this.options.tileUrl]}return id({type:"raster",bounds:this.options.bounds,maxzoom:this.options.maxSourceZoom,minzoom:this.options.minSourceZoom,scheme:this.options.isTMS?"tms":"xyz",tileSize:this.options.tileSize},t&&{tiles:t})},cd.prototype._getSourceId=function(){return"".concat(this.getId(),"-RasterSource")},cd.prototype._getSourceWrapper=function(){var t=this._getSourceId(),e=this._buildSource();return new $h(t,{name:t,tiles:e.tiles,type:e.type,url:e.url})},cd);function cd(t,e){e=rd.call(this,e)||this;return t&&e.setOptions(t),e}(window&&window.__extends||(ld=function(t,e){return(ld=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ld(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(hd,ud=e);var ld,ud,pd=hd;function hd(){var t=null!==ud&&ud.apply(this,arguments)||this;return t.renderer=void 0,t}(window&&window.__extends||(dd=function(t,e){return(dd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}dd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(md,fd=M),md.prototype.getOptions=function(){return L(this.options,pd._cloneCustomizer)},md.prototype.setOptions=function(t){t=(new pd).merge(this.options,L(t,pd._cloneCustomizer));this.map&&this.map.triggerRepaint(),this.options=t},md.prototype.onAdd=function(t){var e,o;fd.prototype.onAdd.call(this,t),this.map.events.add("stylechanged",this._onStyleChange),this.options.renderer&&this.glContext&&null!=(o=(e=this.options.renderer).onAdd)&&o.call(e,t,this.glContext)},md.prototype.onRemove=function(){var t,e;this.options.renderer&&this.glContext&&null!=(e=(t=this.options.renderer).onRemove)&&e.call(t,this.map,this.glContext),this.map.events.remove("stylechanged",this._onStyleChange),this.glContext=null,fd.prototype.onRemove.call(this)},md.prototype._buildLayers=function(){var r=this;if(this.options.renderer)return[{id:this.id,type:"custom",renderingMode:this.options.renderer.renderingMode,onAdd:function(t,e){r.glContext=e},onRemove:function(t,e){},prerender:function(t,e){var o,n;r._shouldRender()&&null!=(n=(o=r.options.renderer).prerender)&&n.call(o,t,e)},render:function(t,e){r._shouldRender()&&r.options.renderer.render(t,e)}}];throw new Error("Cannot build the WebGL layer because renderer was not set.")},md.prototype._getLayerIds=function(){return[this.id]},md.prototype._getSourceIds=function(){return(new Set).add(this.source.getId())},md.prototype._shouldRender=function(){var t;return!!this.map&&(t=this.map.getCamera().zoom,this.options.visible)&&this.options.minZoom<=t&&this.options.maxZoom>t};var dd,fd,yd=md;function md(t,e){var o=fd.call(this,t)||this;return o._onStyleChange=function(){var t,e;o.map._getMap().getLayer(o.id)||(t=o.map,e=null==(e=o.map.layers._getUserLayers().find(function(t){return t.layer.getId()==o.id}))?void 0:e.before,t.layers.remove(o),t.layers.add(o,e))},o.options=(new pd).merge(L(e,pd._cloneCustomizer)),o.source=new Nu,o}var xi=Object.freeze({__proto__:null,BubbleLayer:Rp,HeatMapLayer:H,ImageLayer:In,Layer:M,LineLayer:dh,PolygonExtrusionLayer:yt,PolygonLayer:Ah,SymbolLayer:Gh,TileLayer:ad,WebGLLayer:yd}),gd=(vd.convertHtmlString=function(t){var e;return"string"==typeof t?((e=document.createElement("div")).innerHTML=t,e):t},vd.parseWithFilter=function(t,e,o,n){var r=this;if(void 0===e&&(e=function(t){return!0}),void 0===o&&(o=function(t){return t}),void 0===n&&(n=function(){return document.createElement("div")}),"string"==typeof t){var i=(new DOMParser).parseFromString(t,"text/html").body;if(0==i.children.length)return o(i.innerHTML);var s,i=1==i.children.length&&1==i.childNodes.length?i.children[0]:(s=n(),Array.from(i.childNodes).map(function(t){return s.append(t)}),s)}else i=t;return Array.from(i.children).forEach(function(t){return r.parseWithFilter(t,e,o)}),e(i)?o(i):(i.parentNode&&i.parentNode.removeChild(i),null)},vd);function vd(){}var wd=Vn,_d=Ks;var bd,xd,Od=B(function(t){return wd(t)&&1===t.nodeType&&!_d(t)}),Sd=((window&&window.__extends||(bd=function(t,e){return(bd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}bd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Cd,xd=t),Cd._cloneCustomizer=function(t){if(Od(t))return t},Cd);function Cd(){var t=null!==xd&&xd.apply(this,arguments)||this;return t.anchor="none",t.draggable=!1,t.closeButton=!0,t.content=document.createElement("span"),t.fillColor="#FFFFFF",t.pixelOffset=new Hc(0,0),t.position=new Zl(0,0),t.showPointer=!0,t}var Pd,Ld,a=window&&window.__extends||(Pd=function(t,e){return(Pd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Pd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),kd=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Ad=(a(E,Ld=Ze),E.prototype.setPopupOptions=function(t){this.setOptions(t)},E.prototype.setOptions=function(t){var e,t=(new Sd).merge(this.options,L(t,Sd._cloneCustomizer));t.content!==this.options.content?(this.htmlContent.remove(),this.htmlContent=this._createHtmlContent(t),this.contentDiv.prepend(this.htmlContent)):t.draggable!==this.options.draggable&&this._setDraggable(this.htmlContent,t.draggable),t.closeButton&&!this.closeBtn?(this.closeBtn=this._createCloseButton(),this.contentDiv.appendChild(this.closeBtn),e=_("close"),this.contentDiv.appendChild(e),b(e,this.closeBtn,!0)):!t.closeButton&&this.closeBtn&&(this.contentDiv.removeChild(this.closeBtn),delete this.closeBtn),t.showPointer&&!this.arrowDiv?(this.arrowDiv=this._createArrowDiv(),this.containerDiv.appendChild(this.arrowDiv)):!t.showPointer&&this.arrowDiv&&(this.containerDiv.removeChild(this.arrowDiv),delete this.arrowDiv),t.fillColor!==this.options.fillColor&&(this.containerDiv.style.borderColor=t.fillColor,this.contentDiv.style.backgroundColor=t.fillColor),this.marker&&(t.anchor!==this.options.anchor?"none"===this.options.anchor?(this.autoAnchor!==t.anchor&&this._replaceMarker(this.map,t),this.map.events.remove("move",this._onMove),delete this.autoAnchor):(this._replaceMarker(this.map,t),"none"===t.anchor&&this.map.events.add("move",this._onMove)):(Bc(t.position,this.options.position)||this.marker.setLngLat(t.position),Bc(t.pixelOffset,this.options.pixelOffset)||this.marker.setOffset(t.pixelOffset))),this.options=t},E.prototype.getPopupOptions=function(){return this.getOptions()},E.prototype.getOptions=function(){return L(this.options,Sd._cloneCustomizer)},E.prototype.getPopupContainer=function(){return this.containerDiv},E.prototype._dragToPixel=function(t){this.dragging||(this.dragging=!0,this.contentDiv.style.pointerEvents="none",this._invokeEvent("dragstart",{type:"dragstart",target:this}));t=[t[0]+this.dragOffset[0],t[1]+this.dragOffset[1]],t=kd(this.map.pixelsToPositions([t]),1)[0];this.options.position=t,this.marker.setLngLat(this.options.position),this._invokeEvent("drag",{type:"drag",target:this})},E.prototype._onUp=function(){this.dragging&&(this.contentDiv.style.pointerEvents="",this._invokeEvent("dragend",{type:"dragend",target:this}),"none"===this.options.anchor)&&this._onMove(),delete this.dragOffset,delete this.dragging},E.prototype._createContainerDiv=function(t){var e=this,o=document.createElement("div"),n=(o.classList.add(E.Css.container),o.classList.add(E.Css.hidden),o.style.borderColor=t.fillColor,o.setAttribute("role","dialog"),o.setAttribute("aria-label","Map Information Window"),!1);return o.addEventListener("keydown",function(t){"Tab"!==t.key&&"Escape"!==t.key&&"Esc"!==t.key||(n=!0)}),o.addEventListener("keyup",function(t){"Tab"!==t.key&&"Escape"!==t.key&&"Esc"!==t.key||(n=!1)}),o.addEventListener("focusin",function(t){e.map&&!e.isOpen()&&(e.open(e.map),t.target instanceof HTMLElement)&&t.target.focus()}),o.addEventListener("focusout",function(t){n&&t.relatedTarget instanceof Node&&!o.contains(t.relatedTarget)&&(n=!1,e.isOpen())&&e.close()}),o},E.prototype._createContentDiv=function(t){var e=document.createElement("div");return e.classList.add(E.Css.content),e.style.backgroundColor=t.fillColor,e.setAttribute("tabindex","0"),this.htmlContent=this._createHtmlContent(t),e.appendChild(this.htmlContent),e},E.prototype._createArrowDiv=function(){var t=document.createElement("div");return t.classList.add(E.Css.arrow),t},E.prototype._createCloseButton=function(){var t=document.createElement("button");return t.addEventListener("click",this.close),t.classList.add(E.Css.close),t.setAttribute("aria-label","close"),t.setAttribute("type","button"),t.setAttribute("tabindex","0"),t.innerHTML="×",t},E.prototype._createHtmlContent=function(t){var e=gd.convertHtmlString(t.content);return t.draggable&&this._setDraggable(e,t.draggable),e},E.prototype._createMarker=function(t,e){var o=this.marker?this.marker.getLngLat():t.position,e=("none"===t.anchor?(this.autoAnchor=e||"bottom",this.containerDiv.classList.add(this.autoAnchor),new D.Marker({anchor:this.autoAnchor,element:this.containerDiv,offset:t.pixelOffset})):(this.containerDiv.classList.add(t.anchor),new D.Marker({anchor:t.anchor,element:this.containerDiv,offset:t.pixelOffset}))).setLngLat(o);return e},E.prototype._getAutoAnchor=function(t,e){var o,n,r=this.containerDiv.offsetWidth,i=this.containerDiv.offsetHeight,s=[];return(n=this.marker?(o=(n=t._getMap().project(this.marker.getLngLat())).x,n.y):(n=kd(t.positionsToPixels([e.position]),1),o=(e=kd(n[0],2))[0],e[1]))<i?s.push("top"):n>t.getCanvas().offsetHeight-i&&s.push("bottom"),o<r/2?s.push("left"):o>t.getCanvas().offsetWidth-r/2&&s.push("right"),0<s.length?s.join("-"):"bottom"},E.prototype._replaceMarker=function(t,e,o){var n=this.containerDiv.nextElementSibling;this.marker.remove(),this.containerDiv.classList.remove(this.autoAnchor||this.options.anchor),this.marker=this._createMarker(e,o),this.marker.addTo(t._getMap()),t.popups._getCollectionDiv().insertBefore(this.containerDiv,n||null)},E.prototype._setDraggable=function(t,e){e?(t.addEventListener("mousedown",this._onDown),t.addEventListener("touchstart",this._onDown),t.addEventListener("dragstart",this._onDragStart)):(t.removeEventListener("mousedown",this._onDown),t.removeEventListener("touchstart",this._onDown),t.removeEventListener("dragstart",this._onDragStart))},E.Css={arrow:"popup-arrow",close:"popup-close",container:"popup-container",content:"popup-content-container",hidden:"hidden-accessible-element"},E);function E(t){var o=Ld.call(this)||this;return o.attach=function(t){o.map!==t&&(o.map&&o.remove(),o.map=t,o.marker=o._createMarker(o.options),o.marker.addTo(o.map._getMap()),o.map.popups._getCollectionDiv().appendChild(o.containerDiv),o.map.popups.add(o))},o.open=function(t){if(!t&&!o.map)throw new Error("Must specify a map to open on or attach to a map in advance");o.attach(t||o.map),o.containerDiv.classList.remove(E.Css.hidden),o.map.events.add("move",o._onMove),o._onMove(),o._invokeEvent("open",{target:o,type:"open"})},o.close=function(){o.map&&o.map.events.remove("move",o._onMove),o.containerDiv.classList.add(E.Css.hidden),o._invokeEvent("close",{target:o,type:"close"})},o.remove=function(){o.map&&(o.marker.remove(),o.containerDiv.classList.remove(o.autoAnchor||o.options.anchor),o.map.events.remove("move",o._onMove),o.map.popups.remove(o),delete o.map,delete o.marker,delete o.autoAnchor)},o.isOpen=function(){return o.map&&!o.containerDiv.classList.contains(E.Css.hidden)},o._onMove=function(){var t=o._getAutoAnchor(o.map,o.options);t!==o.autoAnchor&&(o._replaceMarker(o.map,o.options,t),o.map.events.add("move",o._onMove))},o._onDown=function(t){o.map.popups._addDraggedPopup(o);var e=kd(o.map.positionsToPixels([o.options.position]),1)[0];"mousedown"===t.type?o.dragOffset=[e[0]-t.clientX,e[1]-t.clientY]:"touchstart"===t.type&&(o.dragOffset=[e[0]-t.touches[0].clientX,e[1]-t.touches[0].clientY])},o._onDragStart=function(t){t.preventDefault()},o.options=(new Sd).merge(L(t,Sd._cloneCustomizer)),o.containerDiv=o._createContainerDiv(o.options),o.contentDiv=o._createContentDiv(o.options),o.containerDiv.appendChild(o.contentDiv),o.options.showPointer&&(o.arrowDiv=o._createArrowDiv(),o.containerDiv.appendChild(o.arrowDiv)),o.options.closeButton&&(o.closeBtn=o._createCloseButton(),o.contentDiv.appendChild(o.closeBtn),t=_("close"),o.contentDiv.appendChild(t),b(t,o.closeBtn,!0)),o}(window&&window.__extends||(Md=function(t,e){return(Md=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Md(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Id,Ed=t),Id._cloneCustomizer=function(t){if(t instanceof Ad||Od(t))return t};var Md,Ed,jd=Id;function Id(){var t=null!==Ed&&Ed.apply(this,arguments)||this;return t.anchor="bottom",t.color="#1A73AA",t.draggable=!1,t.htmlContent='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24.5 36.5" id="marker_'.concat(J(),'" width="24.5" height="36.5" display="block"><path d="M12.25.25a12.2543,12.2543,0,0,0-12,12.4937c0,6.4436,6.4879,12.1093,11.059,22.5641.5493,1.2563,1.3327,1.2563,1.882,0C17.7621,24.8529,24.25,19.1857,24.25,12.7437A12.2543,12.2543,0,0,0,12.25.25Z" fill="{color}" stroke="{secondaryColor}" stroke-width="0.5"/><text style="font-family: Arial, Helvetica, sans-serif; font-size: 14px; fill: white;" text-anchor="middle" x="12" y="18">{text}</text></svg>'),t.pixelOffset=new Hc(0,0),t.position=new Zl(0,0),t.popup=void 0,t.secondaryColor="white",t.text=void 0,t.visible=!0,t}(window&&window.__extends||(Td=function(t,e){return(Td=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Td(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(j,zd=Ze),j.prototype.getOptions=function(){return L(this.options,jd._cloneCustomizer)},j.prototype.getElement=function(){return this.marker.getElement()},j.prototype.setOptions=function(t){t=(new jd).merge(this.options,L(t,jd._cloneCustomizer));Bc(t.htmlContent,this.options.htmlContent)&&t.anchor===this.options.anchor?("string"!=typeof t.htmlContent||t.color===this.options.color&&t.text===this.options.text&&t.secondaryColor===this.options.secondaryColor||(this.element.innerHTML=this._getSubbedHtmlString(t)||""),t.draggable!==this.options.draggable&&(this._setDraggable(t.draggable),this.marker.setDraggable(t.draggable)),Bc(t.pixelOffset,this.options.pixelOffset)||this.marker.setOffset(t.pixelOffset),Bc(t.position,this.options.position)||this.marker.setLngLat(t.position),t.visible!==this.options.visible&&(t.visible?this.element.classList.remove(j.hiddenClass):this.element.classList.add(j.hiddenClass))):(this.marker.remove(),this._buildMarker(t),this.map&&(this.marker.addTo(this.map._getMap()),this._getCollectionContainer().appendChild(this.element))),this.options=t},j.prototype.togglePopup=function(){if(this.options.popup)if(this.options.popup.isOpen())this.options.popup.close();else{if(!this.map)throw new Error("The marker must be added to a map before calling togglePopup().");this.options.popup.setOptions({position:this.options.position}),this.options.popup.open(this.map)}},j.prototype._addToMap=function(t,e){this.map&&this.map!==t&&this._removeFromMap(),e&&(this.options.position=c(e),this.marker.setLngLat(this.options.position)),this.map!==t&&(this.map=t,this.marker.addTo(t._getMap()),this._getCollectionContainer().appendChild(this.element))},j.prototype._removeFromMap=function(){this.map&&(this.marker.remove(),delete this.map)},j.prototype._getId=function(){if(this.element)return("string"==typeof this.options.htmlContent?this.element.firstChild:this.element).id},j.prototype._buildMarker=function(t){var e;"string"==typeof t.htmlContent?(e=this._getSubbedHtmlString(t)||"",this.element=gd.convertHtmlString(e)):this.element=t.htmlContent,this.element.classList.add(j.containerClass),t.draggable&&this._setDraggable(!0),t.visible||this.element.classList.add(j.hiddenClass),this.marker=new D.Marker({element:this.element,offset:t.pixelOffset,draggable:t.draggable,anchor:t.anchor}).setLngLat(t.position),this.marker.on("drag",this._onDrag),this.marker.on("dragstart",this._onDragStart),this.marker.on("dragend",this._onDragEnd),this.element.addEventListener("click",this._bubbleElementEvent),this.element.addEventListener("dblclick",this._bubbleElementEvent),this.element.addEventListener("contextmenu",this._bubbleElementEvent),this.element.addEventListener("keydown",this._bubbleElementEvent),this.element.addEventListener("keypress",this._bubbleElementEvent),this.element.addEventListener("keyup",this._bubbleElementEvent),this.element.addEventListener("mousedown",this._bubbleElementEvent),this.element.addEventListener("mouseenter",this._bubbleElementEvent),this.element.addEventListener("mouseleave",this._bubbleElementEvent),this.element.addEventListener("mousemove",this._bubbleElementEvent),this.element.addEventListener("mouseout",this._bubbleElementEvent),this.element.addEventListener("mouseover",this._bubbleElementEvent),this.element.addEventListener("mouseup",this._bubbleElementEvent)},j.prototype._getSubbedHtmlString=function(t){return"string"==typeof t.htmlContent?t.htmlContent.replace(/{color}/gi,t.color||"").replace(/{secondaryColor}/gi,t.secondaryColor||"").replace(/{text}/gi,t.text||""):null},j.prototype._getCollectionContainer=function(){var t=this.map.getCanvasContainer().querySelector(".".concat(j.collectionContainerClass));return t||((t=document.createElement("div")).classList.add(j.collectionContainerClass),this.map.getCanvasContainer().appendChild(t)),t},j.prototype._setDraggable=function(t){t?this.element.addEventListener("dragstart",this._onEleDragStart):this.element.removeEventListener("dragstart",this._onEleDragStart)},j.collectionContainerClass="marker-collection-container",j.hiddenClass="hidden-accessible-element",j.containerClass="marker-container";var Td,zd,Dd=j;function j(t){var e=zd.call(this)||this;return e._onDrag=function(){var t=e.marker.getLngLat().wrap();e.options.position=new Zl(t.lng,t.lat),e._invokeEvent("drag",{type:"drag",target:e})},e._onDragStart=function(){e._invokeEvent("dragstart",{type:"dragstart",target:e})},e._onDragEnd=function(){e._invokeEvent("dragend",{type:"dragend",target:e})},e._bubbleElementEvent=function(t){e._invokeEvent(t.type,{type:t.type,target:e})},e._onEleDragStart=function(t){t.preventDefault()},e.options=(new jd).merge(L(t,jd._cloneCustomizer)),e._buildMarker(e.options),e}Bd.getHighContrastMode=function(){return matchMedia("(-ms-high-contrast: white-on-black)").matches?"dark":matchMedia("(-ms-high-contrast: black-on-white)").matches?"light":matchMedia("(-ms-high-contrast: active)").matches?"dark":matchMedia("(inverted-colors: inverted)").matches?"invert":null};var Rd=Bd;function Bd(){}(window&&window.__extends||(Fd=function(t,e){return(Fd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Fd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(qd,Nd=t);var Fd,Nd,Zd=qd;function qd(){var t=null!==Nd&&Nd.apply(this,arguments)||this;return t.copyrightMessage=void 0,t.copyrightContent=void 0,t.customAttribution=void 0,t.showFeedbackLink=!0,t.showLogo=!0,t}(window&&window.__extends||(Hd=function(t,e){return(Hd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Hd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Gd,Ud=We),Gd.prototype.onAdd=function(t){return this.map=t,this.container=this.buildContainer(t,u.ControlStyle.auto),this.container.className="map-copyright without-bg",this.copyrightDiv=this.buildCopyrightDiv(),this.copyrightDiv.className="azure-map-copyright",this.container.appendChild(this.copyrightDiv),this.options.showFeedbackLink&&this.addRemoveFeedbackDiv(!0),this.container},Gd.prototype.onRemove=function(){Ud.prototype.onRemove.call(this),delete this.container},Gd.prototype.setOptions=function(t){var e,o=this,t=(new Zd).merge(this.options,t);t.copyrightMessage===this.options.copyrightMessage&&t.customAttribution===this.options.customAttribution||(this.copyrightDiv.innerText=this.textAttribution(t)),t.copyrightContent!==this.options.copyrightContent&&(this.options.copyrightContent&&(e=Array.from(this.copyrightDiv.children).find(function(t){return t===o.options.copyrightContent}),this.copyrightDiv.removeChild(e)),0<this.copyrightDiv.childNodes.length?this.copyrightDiv.insertBefore(t.copyrightContent,this.copyrightDiv.childNodes[0]):this.copyrightDiv.appendChild(t.copyrightContent),this.options.copyrightContent=t.copyrightContent),!t.showFeedbackLink&&this.feedbackAnchor?this.addRemoveFeedbackDiv(!1):t.showFeedbackLink&&!this.feedbackAnchor&&this.addRemoveFeedbackDiv(!0),this.options=t},Gd.prototype.getDefaultAttributions=function(){var t=(new Date).getFullYear(),e=["©".concat(t," TomTom")];return this.options.showLogo||e.push("©".concat(t," Microsoft")),e},Gd.prototype.buildCopyrightDiv=function(){var t=document.createElement("div");return t.innerText=this.textAttribution(this.options)||"",t},Gd.prototype.buildFeedbackLink=function(){var t=document.createElement("a");return t.setAttribute("alt","Provide Map Data Feedback"),t.setAttribute("aria-label","Provide Map Data Feedback"),t.innerText="Feedback",t.href=Gd.feedbackLink,t.target="_blank",t.rel="noopener",t.className="azure-map-feedback-text",t},Gd.prototype.addRemoveFeedbackDiv=function(t){t?(this.feedbackAnchor=this.buildFeedbackLink(),this.feedbackTooltip=_("Provide Map Data Feedback"),this.container.appendChild(this.feedbackAnchor),this.container.appendChild(this.feedbackTooltip),b(this.feedbackTooltip,this.feedbackAnchor),null!=(t=null==(t=this.map)?void 0:t.events)&&t.add("moveend",this.updateFeedbackLink)):(this.feedbackAnchor.remove(),this.feedbackTooltip.remove(),delete this.feedbackTooltip,delete this.feedbackAnchor,null!=(t=null==(t=this.map)?void 0:t.events)&&t.remove("moveend",this.updateFeedbackLink))},Gd.feedbackLink="https://aka.ms/azuremaps-feedback?feedbackep=UrlAzureMapsWebSdk";var Hd,Ud,Wd=Gd;function Gd(t){var o=Ud.call(this)||this;return o.textAttribution=function(t){return[o.options.copyrightMessage,o.options.customAttribution].filter(function(t){return t}).join("")},o.updateFeedbackLink=function(){var t,e;o.feedbackAnchor&&o.map&&(t=(e=o.map.getCamera()).center,e=e.zoom,o.feedbackAnchor.href="".concat(Gd.feedbackLink,"&cp=").concat(t[1],"~").concat(t[0],"&lvl=").concat(e+1))},o.options=(new Zd).merge(t),o}(window&&window.__extends||(Vd=function(t,e){return(Vd=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Vd(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Jd,Kd=t);var Vd,Kd,Yd=Jd;function Jd(){var t=null!==Kd&&Kd.apply(this,arguments)||this;return t.showLogo=!0,t}(window&&window.__extends||($d=function(t,e){return($d=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}$d(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(tf,Xd=We),tf.prototype.onAdd=function(t){return this.map=t,this.container=this.buildContainer(t,u.ControlStyle.auto),this.container.className="map-logo-control",null!=(t=this.map)&&t.events.add("resize",this._onResize),this._addRemoveLogo(this.options.showLogo),this.container},tf.prototype.onRemove=function(){var t;Xd.prototype.onRemove.call(this),null!=(t=this.map)&&t.events.remove("resize",this._onResize),this.map=null,delete this.container},tf.prototype.setOptions=function(t){t=(new Yd).merge(this.options,t);!t.showLogo&&this.logoAnchor?this._addRemoveLogo(!1):t.showLogo&&!this.logoAnchor&&this._addRemoveLogo(!0),this.options=t},tf.prototype._addRemoveLogo=function(t){t?(this.logoAnchor=document.createElement("a"),this.logoAnchor.className="azure-map-logo",this.logoAnchor.href="https://aka.ms/azuremaps",this.logoAnchor.setAttribute("aria-label","Visit azure.microsoft.com"),this.logoAnchor.setAttribute("target","_blank"),this.container.appendChild(this.logoAnchor),this.logoTooltip=_("Visit azure.microsoft.com"),this.container.appendChild(this.logoTooltip),b(this.logoTooltip,this.logoAnchor),this._setVisiblity(!0)):(null!=(t=this.logoAnchor)&&t.remove(),null!=(t=this.logoTooltip)&&t.remove(),delete this.logoAnchor,this._setVisiblity(!1))},tf.prototype._setVisiblity=function(t){this.container&&(this.container.style.display=t?"flex":"none")},tf.CONTAINER_MIN_WIDTH=480;var $d,Xd,Qd=tf;function tf(t){var e=Xd.call(this)||this;return e.map=null,e._onResize=function(){var t=(null==(t=null==(t=e.map)?void 0:t.getMapContainer())?void 0:t.clientWidth)||0;e._setVisiblity(e.options.showLogo&&tf.CONTAINER_MIN_WIDTH<=t)},e.options=(new Yd).merge(t),e}window&&window.__assign;window&&window.__awaiter,window&&window.__generator,window&&window.__read,window&&window.__spreadArray;var ef,of,nf=function(t){var o=this;this.addToMap=function(){null==o.mapViewDesc&&(o.initializeMapLiveStateInfo(),o.initializeMapStyleInfo(),o.createMapKeyBindingInfo(),o.map.getMapContainer().setAttribute("role","application"),o.map.getMapContainer().setAttribute("aria-label","Map Application"),o.map.getCanvasContainer().setAttribute("aria-live","polite"),o.map.getCanvasContainer().setAttribute("aria-describedby","atlas-map-state atlas-map-style"),o.map.getCanvas().setAttribute("aria-label","Interactive Map"),o.map.getCanvas().setAttribute("aria-describedby","atlas-map-shortcuts"),o.map.getCanvas().setAttribute("alt","Interactive Map"))},this.removeFromMap=function(){null!=o.mapViewDesc&&o.mapViewDesc.dispose(),delete o.mapViewDesc,null!=o.atlasMapKeyBindings&&o.map.getCanvasContainer().removeChild(o.atlasMapKeyBindings),delete o.atlasMapKeyBindings,null!=o.atlasMapLiveStateInfo&&o.map.getCanvasContainer().removeChild(o.atlasMapLiveStateInfo),delete o.atlasMapLiveStateInfo,null!=o.atlasMapStyleInfo&&o.map.getCanvasContainer().removeChild(o.atlasMapStyleInfo),delete o.atlasMapStyleInfo,o.map.getMapContainer().removeAttribute("role"),o.map.getMapContainer().removeAttribute("aria-label"),o.map.getCanvasContainer().removeAttribute("aria-live"),o.map.getCanvasContainer().removeAttribute("aria-describedby"),o.map.getCanvas().removeAttribute("aria-label"),o.map.getCanvas().removeAttribute("aria-describedby"),o.map.getCanvas().removeAttribute("alt"),o.map.events.remove("stylechanged",o.updateMapStyle)},this.createMapKeyBindingInfo=function(){o.atlasMapKeyBindings=document.createElement("div"),o.atlasMapKeyBindings.setAttribute("tabindex","-1"),o.atlasMapKeyBindings.setAttribute("aria-hidden","true"),o.atlasMapKeyBindings.id="atlas-map-shortcuts",o.atlasMapKeyBindings.classList.add("hidden-accessible-element"),o.atlasMapKeyBindings.innerHTML=["Map shortcuts:","Zoom out: hyphen.","Zoom in: plus.","Pan right 100 pixels: right arrow.","Pan left 100 pixels: left arrow.","Pan up 100 pixels: up arrow.","Pan down 100 pixels: down arrow.","Rotate 15 degrees clockwise: shift + right arrow.","Rotate 15 degrees counter clockwise: shift + left arrow.","Increase pitch 10 degrees: shift + up arrow.","Decrease pitch 10 degrees: shift + down arrow.","Jump focus to the map: Escape."].join("\n"),o.map.getCanvasContainer().appendChild(o.atlasMapKeyBindings);var t=[189,187,38,37,39,40],e=o.map._getMap()._canvas;null!=e&&e.addEventListener("keyup",function(e){t.find(function(t){return e.keyCode===t})&&(o.atlasMapKeyBindings.innerHTML="")})},this.initializeMapLiveStateInfo=function(){},this.initializeMapStyleInfo=function(){o.atlasMapStyleInfo=document.createElement("div"),o.atlasMapStyleInfo.setAttribute("tabindex","-1"),o.atlasMapStyleInfo.setAttribute("aria-hidden","true"),o.atlasMapStyleInfo.id="atlas-map-style",o.atlasMapStyleInfo.classList.add("hidden-accessible-element"),o.map.events.add("stylechanged",o.updateMapStyle),o.map.getCanvasContainer().appendChild(o.atlasMapStyleInfo)},this.updateMapStyle=function(){o.atlasMapStyleInfo.innerHTML="<p>Map style: ".concat(o.map.getStyle().style,".</p>")},this.updateMapState=function(t){o.atlasMapLiveStateInfo.innerHTML=t},this.map=t},rf=function(t){var o=this;this.listenerEnabled=!1,this.lastFlowMode="none",this.addToMap=function(){if(!o.map._isReady())throw new Error("Traffic flow could not be added to the map because the map is not ready. Please use a ready event listener to guarantee the map is ready before enabling traffic flow.");o.listenerEnabled||(o.map.events.add("styledata",o.addToMap),o.listenerEnabled=!0);var t,e=o.map.getTraffic();"none"!==e.flow&&(t=o.map.layers.getLayerById("traffic_".concat(e.flow)))&&(o.lastFlowMode=e.flow,t._updateLayoutProperty("visibility","visible","none"))},this.removeFromMap=function(){var t;o.map.getTraffic(),"none"!=o.lastFlowMode&&((t=o.map.layers.getLayerById("traffic_".concat(o.lastFlowMode)))&&t._updateLayoutProperty("visibility","none","visible"),o.lastFlowMode="none"),o.listenerEnabled&&(o.map.events.remove("styledata",o.addToMap),o.listenerEnabled=!1)},this.map=t},sf=((window&&window.__extends||(ef=function(t,e){return(ef=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ef(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(af,of=t),af);function af(){var t=null!==of&&of.apply(this,arguments)||this;return t.interactive=!0,t.scrollZoomInteraction=!0,t.boxZoomInteraction=!0,t.dragRotateInteraction=!0,t.dragPanInteraction=!0,t.keyboardInteraction=!0,t.dblClickZoomInteraction=!0,t.touchInteraction=!0,t.touchRotate=!0,t.wheelZoomRate=1/450,t}lf.prototype.enable=function(){this.map.getMapContainer().addEventListener("keydown",this._onKeyDown)},lf.prototype.disable=function(){this.map.getMapContainer().removeEventListener("keydown",this._onKeyDown)};var cf=lf;function lf(t){var e=this;this._onKeyDown=function(t){27===t.keyCode&&e.map.getCanvas().focus()},this.map=t}pf.prototype.enable=function(){this.map.getCanvasContainer().addEventListener("gesturestart",this._onGestureStart),this.map.getCanvasContainer().addEventListener("gesturechange",this._onGestureChange),this.map.getCanvasContainer().addEventListener("touchstart",this._onTouchStart),this.map.getCanvasContainer().addEventListener("touchend",this._onTouchEnd)},pf.prototype.disable=function(){this.map.getCanvasContainer().removeEventListener("gesturestart",this._onGestureStart),this.map.getCanvasContainer().removeEventListener("gesturechange",this._onGestureChange),this.map.getCanvasContainer().removeEventListener("touchstart",this._onTouchStart),this.map.getCanvasContainer().removeEventListener("touchend",this._onTouchEnd)};var uf=pf;function pf(t){var e=this;this._onGestureStart=function(t){e.hasTouch||(t.preventDefault(),e.initZoom=e.map.getCamera().zoom)},this._onGestureChange=function(t){e.hasTouch||(t.preventDefault(),e.map.setCamera({zoom:e.initZoom+t.scale-1}))},this._onTouchStart=function(t){e.hasTouch=!0},this._onTouchEnd=function(t){0===t.touches.length&&(e.hasTouch=!1)},this.map=t}df.prototype.addToMap=function(){this.added||(this.added=!0,this._setInteractions(this.options))},df.prototype.removeFromMap=function(){this.added&&(this.added=!1,this._setInteractions({interactive:!1}))},df.prototype.setOptions=function(t){this.options=(new sf).merge(this.options,t),this.added&&this._setInteractions(this.options)},df.prototype.getOptions=function(){return Object.assign({},this.options)},df.prototype._setInteractions=function(t){var e;t.interactive?(t.boxZoomInteraction?this.map._getMap().boxZoom.enable():this.map._getMap().boxZoom.disable(),t.dblClickZoomInteraction?this.map._getMap().doubleClickZoom.enable():this.map._getMap().doubleClickZoom.disable(),t.dragPanInteraction?this.map._getMap().dragPan.enable():this.map._getMap().dragPan.disable(),t.dragRotateInteraction?this.map._getMap().dragRotate.enable():this.map._getMap().dragRotate.disable(),t.keyboardInteraction?(this.map._getMap().keyboard.enable(),this.focusShortcut.enable()):(this.map._getMap().keyboard.disable(),this.focusShortcut.disable()),t.scrollZoomInteraction?(this.map._getMap().scrollZoom.enable(),this.map._getMap().scrollZoom.setWheelZoomRate(t.wheelZoomRate)):this.map._getMap().scrollZoom.disable(),e=this.map._getMap().touchZoomRotate,t.touchInteraction?(e.enable(),t.touchRotate?e.enableRotation():e.disableRotation()):e.disable(),this.pinchZoom.enable()):(this.map._getMap().boxZoom.disable(),this.map._getMap().doubleClickZoom.disable(),this.map._getMap().dragPan.disable(),this.map._getMap().dragRotate.disable(),this.map._getMap().keyboard.disable(),this.focusShortcut.disable(),this.map._getMap().scrollZoom.disable(),this.map._getMap().touchZoomRotate.disable(),this.pinchZoom.disable())};var hf=df;function df(t,e){this.added=!1,this.map=t,this.focusShortcut=new cf(t),this.pinchZoom=new uf(t),this.options=(new sf).merge(e)}var ff=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},yf=(mf.prototype.add=function(t,e){var o,n;if(Array.isArray(t))try{for(var r=ff(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._add(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._add(t,e)},mf.prototype.getControls=function(){return Array.from(this.controls)},mf.prototype.remove=function(t){var e,o;if(Array.isArray(t))try{for(var n=ff(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._remove(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}else this._remove(t)},mf.prototype._add=function(t,e){this.controls.add(t);var o=(new De).merge(e),t=t.onAdd(this.map,e),e=this.controlContainer.getElementsByClassName(o.position);if(!(0<e.length))throw new Error("Control position ".concat(o.position," does not exist."));e.item(0).appendChild(t)},mf.prototype._remove=function(t){t.onRemove(),this.controls.delete(t)},mf);function mf(t){for(var e in this.map=t,this.controlContainer=document.createElement("div"),this.controlContainer.classList.add("atlas-control-container"),u.ControlPosition){var o;u.ControlPosition.hasOwnProperty(e)&&((o=document.createElement("div")).classList.add(u.ControlPosition[e]),o.classList.add("subcontrol-container"),this.controlContainer.appendChild(o))}this.map.getMapContainer().appendChild(this.controlContainer),this.controls=new Set}var gf=window&&window.__assign||function(){return(gf=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},vf=(wf.prototype.addCallback=function(s,a,c,t,l){var e,u,p=this;if(t)e=function(t){var e=t.lngLat?new Zl(t.lngLat.lng,t.lngLat.lat):void 0,o=t.point?[t.point.x,t.point.y]:void 0,n=t.features?t.features.map(function(t){return new Fc(t.geometry,t.properties,t.id)}):[],t={type:t.type,originalEvent:t.originalEvent,position:e,coordinate:o,features:n};c(t)};else switch(s){case"data":case"sourcedata":case"styledata":e=function(t){t=gf(gf({dataType:t.dataType},"source"===t.dataType&&gf(gf(gf({isSourceLoaded:t.isSourceLoaded},t.sourceDataType&&{sourceDataType:t.sourceDataType}),{source:p.map.sources.getById(t.sourceId)}),t.tile&&{tile:{id:{x:t.tile.tileID.canonical.x,y:t.tile.tileID.canonical.y,z:t.tile.tileID.canonical.z},size:t.tile.tileSize,state:t.tile.state}})),{map:p.map,type:t.type});l&&p.map.events._removeListener(s,a,c),c(t)};break;case"error":e=function(t){t={error:t.error,map:p.map,type:t.type};l&&p.map.events._removeListener(s,a,c),c(t)};break;case"touchstart":case"touchend":case"touchmove":case"touchcancel":e=function(t){if(t.originalEvent){if(t.originalEvent===u)return;u=t.originalEvent}var e=t.point?new Hc(t.point.x,t.point.y):void 0,o=t.points?t.points.map(function(t){return new Hc(t.x,t.y)}):[],n=t.lngLat?new Zl(t.lngLat.lng,t.lngLat.lat):void 0,r=t.lngLats?t.lngLats.map(function(t){return new Zl(t.lng,t.lat)}):[],i=n?p.map.layers.getRenderedShapes(new Uc(n),a?[a]:void 0):[],e={map:p.map,originalEvent:t.originalEvent,pixel:e,pixels:o,position:n,positions:r,shapes:i,layerId:a||void 0,preventDefault:function(){return t.preventDefault()},type:t.type};l&&p.map.events._removeListener(s,a,c),c(e)};break;case"mousedown":case"mouseup":case"mouseover":case"mousemove":case"click":case"dblclick":case"mouseout":case"mouseenter":case"mouseleave":case"contextmenu":e=function(t){if(t.originalEvent){if(t.originalEvent===u)return;u=t.originalEvent}var e=t.lngLat?new Zl(t.lngLat.lng,t.lngLat.lat):void 0,o=t.point?new Hc(t.point.x,t.point.y):void 0,n=e?p.map.layers.getRenderedShapes(new Uc(e),a?[a]:void 0):[],e={map:p.map,originalEvent:t.originalEvent,position:e,pixel:o,preventDefault:function(){return t.preventDefault()},shapes:n,layerId:a||void 0,type:t.type};l&&p.map.events._removeListener(s,a,c),c(e)};break;case"styleimagemissing":e=function(t){l&&p.map.events._removeListener(s,a,c),c(t.id)};break;case"wheel":e=function(t){if(t.originalEvent){if(t.originalEvent===u)return;u=t.originalEvent}var e={map:p.map,originalEvent:t.originalEvent,preventDefault:function(){return t.preventDefault()},type:t.type};l&&p.map.events._removeListener(s,a,c),c(e)};break;case"resize":e=function(t){var e,o={map:p.map,type:t.type};for(e in t)"type"!==e&&"target"!==e&&(o[e]=t[e]);l&&p.map.events._removeListener(s,a,c),c(o)};break;default:e=function(t){var e={map:p.map,type:t.type};t.originalEvent&&(e.originalEvent=t.originalEvent),l&&p.map.events._removeListener(s,a,c),c(e)}}this.callbacks.has(a)||this.callbacks.set(a,new Ne),this.callbacks.get(a).has(s)||this.callbacks.get(a).set(s,new Map),this.callbacks.get(a).get(s).set(c,[e,l])},wf.prototype.removeCallback=function(t,e,o){this.callbacks.has(e)&&this.callbacks.get(e).has(t)&&this.callbacks.get(e).get(t).has(o)&&this.callbacks.get(e).get(t).delete(o)},wf.prototype.getModifiedCallback=function(t,e,o){if(this.callbacks.has(e)&&this.callbacks.get(e).has(t)&&this.callbacks.get(e).get(t).has(o))return this.callbacks.get(e).get(t).get(o)[0]},wf.prototype.getLayerCallbacks=function(t){if(this.callbacks.has(t))return this.callbacks.get(t)},wf.prototype.getEventCallbacks=function(t,e){if(this.callbacks.has(e)){e=this.callbacks.get(e);if(e.has(t))return e.get(t)}},wf);function wf(t){this.callbacks=new Ne,this.map=t}var _f=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},bf=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},xf=["maxzoomchanged","minzoomchanged","mapconfigurationchanged"],Of=(Sf.prototype.add=function(t,e,o){var n,r;if("function"==typeof e)this._addGlobalListener(t,e,!1,!1);else{e=Array.isArray(e)?e:[e];try{for(var i=_f(e),s=i.next();!s.done;s=i.next()){var a=s.value;a instanceof M&&M._isMBoxEvent(t)?this._addLayerListener(t,a,o,!1,!1):a._addEventListener(t,o,!1)}}catch(t){n={error:t}}finally{try{s&&!s.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}},Sf.prototype.addOnce=function(t,e,o){"function"==typeof e?this._addGlobalListener(t,e,!1,!0):e instanceof M&&M._isMBoxEvent(t)?this._addLayerListener(t,e,o,!1,!0):e._addEventListener(t,o,!0)},Sf.prototype._addLegacy=function(t,e,o){"function"==typeof e?this._addGlobalListener(t,e,!0,!1):this._addLayerListener(t,e,o,!0,!1)},Sf.prototype._addLayerListener=function(t,e,o,n,r){var i,s,a,c,e=e instanceof M?e.getId():e,l=this.map.layers.getLayerById(e),u=this.mapCallbackHandler.getModifiedCallback(t,e,o);if(u&&l)try{for(var p=_f(l._getLayerIds()),h=p.next();!h.done;h=p.next()){var d=h.value;this.map._getMap().off(t,d,u)}}catch(t){i={error:t}}finally{try{h&&!h.done&&(s=p.return)&&s.call(p)}finally{if(i)throw i.error}}if(this.mapCallbackHandler.addCallback(t,e,o,n,r),l){u=this.mapCallbackHandler.getModifiedCallback(t,e,o);try{for(var f=_f(l._getLayerIds()),y=f.next();!y.done;y=f.next()){d=y.value;this.map._getMap().on(t,d,u)}}catch(t){a={error:t}}finally{try{y&&!y.done&&(c=f.return)&&c.call(f)}finally{if(a)throw a.error}}}},Sf.prototype._addGlobalListener=function(t,e,o,n){var r,i,s,a;xf.includes(t)?this.map._addEventListener(t,e,n):(r=this.mapCallbackHandler.getModifiedCallback(t,"",e),this.mapCallbackHandler.addCallback(t,"",e,o,n),i=this.mapCallbackHandler.getModifiedCallback(t,"",e),"load"===t&&this.map._isLoaded()?(s={type:"load",map:this.map},setTimeout(function(){return i(s)})):"ready"===t?this.map._isReady()&&(a={type:"ready",map:this.map},setTimeout(function(){return i(a)})):(r&&this.map._getMap().off(t,r),this.map._getMap().on(t,i)))},Sf.prototype.invoke=function(t,e,o){if(void 0===o)this._invokeListeners(t,"",e);else if(e instanceof M&&M._isMBoxEvent(t))this._invokeListeners(t,e.getId(),o);else{if(!(e instanceof Ze))throw new Error("The invoke target is invalid.");e._invokeEvent(t,o)}},Sf.prototype._invokeListeners=function(o,n,r){var i=this,t=new Ne(this.mapCallbackHandler.getEventCallbacks(o,n));t?t.forEach(function(t,e){t=bf(t,2);t[0],t[1]&&i._removeListener(o,n,e),e(r)}):"error"===o&&console.error("error"in r?r.error:r)},Sf.prototype.remove=function(t,e,o){var n,r;if("function"==typeof e)this._removeListener(t,"",e);else{e=Array.isArray(e)?e:[e];try{for(var i=_f(e),s=i.next();!s.done;s=i.next()){var a=s.value;a instanceof M&&M._isMBoxEvent(t)?this._removeListener(t,a,o):null!=a&&a._removeEventListener(t,o)}}catch(t){n={error:t}}finally{try{s&&!s.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}},Sf.prototype._removeLegacy=function(t,e,o){"function"==typeof e?this._removeListener(t,"",e):this._removeListener(t,e,o)},Sf.prototype._removeListener=function(t,e,o){var n,r;if(xf.includes(t))this.map._removeEventListener(t,o);else{var e=e instanceof M?e.getId():e,i=this.mapCallbackHandler.getModifiedCallback(t,e,o);if(i)if(e){var s=this.map.layers.getLayerById(e);if(s)try{for(var a=_f(s._getLayerIds()),c=a.next();!c.done;c=a.next()){var l=c.value;this.map._getMap().off(t,l,i)}}catch(t){n={error:t}}finally{try{c&&!c.done&&(r=a.return)&&r.call(a)}finally{if(n)throw n.error}}}else this.map._getMap().off(t,i);this.mapCallbackHandler.removeCallback(t,e,o)}},Sf.prototype._enableLayerEvents=function(c){var l=this,t=this.mapCallbackHandler.getLayerCallbacks(c.getId());t&&t.forEach(function(t,a){t.forEach(function(t){var e,o,n=bf(t,1)[0];try{for(var r=_f(c._getLayerIds()),i=r.next();!i.done;i=r.next()){var s=i.value;l.map._getMap().on(a,s,n)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}})})},Sf.prototype._disableLayerEvents=function(c){var l=this,t=this.mapCallbackHandler.getLayerCallbacks(c.getId());t&&t.forEach(function(t,a){t.forEach(function(t){var e,o,n=bf(t,1)[0];try{for(var r=_f(c._getLayerIds()),i=r.next();!i.done;i=r.next()){var s=i.value;l.map._getMap().off(a,s,n)}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}})})},Sf);function Sf(t){this.map=t,this.mapCallbackHandler=new vf(this.map)}var Cf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Pf=(Lf.prototype.add=function(t,e){var o,n;if(Array.isArray(t))try{for(var r=Cf(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._addMarker(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._addMarker(t,e)},Lf.prototype._addMarker=function(t,e){t._addToMap(this.map,e),this.markers.add(t)},Lf.prototype.getMarkers=function(){return Array.from(this.markers)},Lf.prototype.remove=function(t){var e,o;if(Array.isArray(t))try{for(var n=Cf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._removeMarker(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}else this._removeMarker(t)},Lf.prototype._removeMarker=function(e){var o=this;e instanceof Dd?(e._removeFromMap(),this.markers.delete(e)):this.markers.forEach(function(t){t._getId()===e&&(t._removeFromMap(),o.markers.delete(t))})},Lf.prototype.clear=function(){var e=this;this.markers.forEach(function(t){t._removeFromMap(),e.markers.delete(t)})},Lf);function Lf(t){this.markers=new Set,this.map=t}Af.prototype.add=function(s,e,a){var c=this;return new Promise(function(o,n){var r,t,i;c.userImages.has(s)?o():e instanceof HTMLImageElement||e instanceof ImageData?(c.map._getMap().addImage(s,e,a),c.userImages.set(s,{image:e,meta:a}),o()):"string"==typeof e&&(t=void 0,t=/<svg/i.test(e)&&!/^data:/i.test(e)?"data:image/svg+xml;base64,"+window.btoa(e):e,i=!1,c.map._sendRequest(t,"Image").then(function(t){return i?void 0:t.blob()}).then(function(t){var e;!i&&t&&(clearTimeout(r),(e=new Image).onload=function(){c.map._getMap().addImage(s,e,a),c.userImages.set(s,{image:e,meta:a}),o()},e.onerror=e.onabort=function(){n("Failed to load image into HTML element.")},e.src=URL.createObjectURL(t))}).catch(function(){i||(clearTimeout(r),n("Failed to load image into HTML element."))}),r=setTimeout(function(){i=!0,n("Failed to load image within specified timeout: ".concat(c.imageLoadTimeout," ms."))},c.imageLoadTimeout))})},Af.prototype.clear=function(){var o=this;this.userImages.forEach(function(t,e){o.map._getMap().removeImage(e)}),this.userImages.clear()},Af.prototype.getImageIds=function(){var o=[];return this.userImages.forEach(function(t,e){o.push(e)}),o},Af.prototype.createFromTemplate=function(t,e,o,n,r){o=o||"#1A73AA",n=n||"#fff";e=(e=Oe(e,r)).replace(/{color}/g,o).replace(/{secondaryColor}/g,n).replace(/{text}/g,"");return this.add(t,e)},Af.prototype.hasImage=function(t){return this.userImages.has(t)},Af.prototype.remove=function(t){this.map._getMap().removeImage(t),this.userImages.delete(t)},Af.prototype._restoreImages=function(){var o=this;this.userImages.forEach(function(t,e){o.map._getMap().hasImage(e)||o.map._getMap().addImage(e,t.image,t.meta)})};var kf=Af;function Af(t){this.userImages=new Ne,this.imageLoadTimeout=5e3,this.map=t}var Mf,Ef,Jo=window&&window.__extends||(Mf=function(t,e){return(Mf=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Mf(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),jf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},If=(Jo(Tf,Ef=M),Tf.prototype.getOptions=function(){return{}},Tf.prototype.setOptions=function(t){},Tf.prototype._buildLayers=function(){return this.layers},Tf.prototype._getLayerIds=function(){return this.layers.map(function(t){return t.id})},Tf.prototype._getSourceIds=function(){var e,t,o=new Set;try{for(var n=jf(this.layers),r=n.next();!r.done;r=n.next()){var i=r.value;"source"in i&&"string"==typeof i.source?o.add(i.source):"source"in i&&i.source&&o.add(i.id)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return o},Tf.prototype._updateLayoutProperty=function(e,o,t,n){var r;Bc(o,t)||(r=this.map._getMap(),this.layers.forEach(function(t){r.getLayer(t.id)?r.setLayoutProperty(t.id,e,n||o):console.warn("Could not update layout property ".concat(e," for layer ").concat(t.id," to ").concat(n||o))}))},Tf);function Tf(t,e){e=Ef.call(this,e)||this;return e.layers=t,e}var zf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Df=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Rf=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Bf=(Ff.prototype.add=function(t,e){var o,n,r=e instanceof M?e.getId():e;if(Array.isArray(t))try{for(var i=zf(t),s=i.next();!s.done;s=i.next()){var a=s.value;this._addLayer(a,r)}}catch(t){o={error:t}}finally{try{s&&!s.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}else this._addLayer(t,r)},Ff.prototype._addLayer=function(e,o){if(!(this.map._isReady()||e instanceof If))throw new Error("The layer '".concat(e.getId(),"' could not be added to the map because ")+"the map is not ready. Please use a ready event listener to guarantee the map is ready before adding a layer to it.");var t,n,r,i;o!==e.getId()&&this.layerIndex.find(function(t){return o===t.getId()})?this._getMapboxLayerExists(e)?(n=this.layerIndex.findIndex(function(t){return t.getId()===e.getId()}),r=this.userLayers.findIndex(function(t){return t.layer.getId()===e.getId()}),this._removeMapboxLayers(e),this._addMapboxLayers(e,o),(i=this.layerIndex[n])&&this.map.events._disableLayerEvents(i),this.map.events._enableLayerEvents(e),this.layerIndex.splice(n,1),t=this.layerIndex.findIndex(function(t){return t.getId()===o}),this.layerIndex.splice(t,0,e),e instanceof If||(this.userLayers[r]={layer:e,before:o}),i&&i.onRemove()):(this._addMapboxLayers(e,o),this.map.events._enableLayerEvents(e),t=this.layerIndex.findIndex(function(t){return t.getId()===o}),this.layerIndex.splice(t,0,e),e instanceof If||this.userLayers.push({layer:e,before:o})):(n=this.layerIndex.findIndex(function(t){return t.getId()===e.getId()}),r=this.userLayers.findIndex(function(t){return t.layer.getId()===e.getId()}),0<=n&&0<=r?(i=this.layerIndex[n],this._removeMapboxLayers(i),this._addMapboxLayers(e,n+1),this.map.events._disableLayerEvents(i),this.map.events._enableLayerEvents(e),(this.layerIndex[n]=e)instanceof If||(this.userLayers[r]={layer:e,before:void 0}),i.onRemove()):(this._addMapboxLayers(e),this.map.events._enableLayerEvents(e),this.layerIndex.push(e),e instanceof If||this.userLayers.push({layer:e,before:o}))),e.onAdd(this.map)},Ff.prototype._addMapboxLayers=function(t,e){var o,n;if(!(t instanceof ad)||t.getOptions().tileUrl){if(!(t instanceof If)){t instanceof eh&&(this.map._getMap().addSource(t._getSourceId(),t._buildSource()),this.map.sources.setSourceState(t._getSourceWrapper()));var r=this._getMapboxBefore(e);try{for(var i=zf(t._buildLayers()),s=i.next();!s.done;s=i.next()){var a=s.value;this.map._getMap().addLayer(a,r)}}catch(t){o={error:t}}finally{try{s&&!s.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}}this.map.events._enableLayerEvents(t)}},Ff.prototype._removeMapboxLayers=function(t,e){var o,n;if(t instanceof If&&!e)this.map.events._disableLayerEvents(t);else{try{for(var r=zf(t._getLayerIds()),i=r.next();!i.done;i=r.next()){var s=i.value;this.map._getMap().getLayer(s)&&this.map._getMap().removeLayer(s)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}this.map.events._disableLayerEvents(t),t instanceof eh&&this.map._getMap().getSource(t._getSourceId())&&this.map._getMap().removeSource(t._getSourceId())}},Ff.prototype._getMapboxLayerExists=function(e){var o=this,n=!1;return"string"==typeof e?!!(e=this.layerIndex.find(function(t){return t.getId()===e})):(e._getLayerIds().forEach(function(t){o.map._getMap().getLayer(t)&&(n=!0)}),n)},Ff.prototype._getMapboxBefore=function(e){var o,t,n,r;if("string"==typeof e){var i=this.layerIndex.find(function(t){return t.getId()===e});if(!i)return;try{for(var s=zf(i._getLayerIds()),a=s.next();!a.done;a=s.next()){var c=a.value;if(this.map._getMap().getLayer(c))return c}}catch(t){o={error:t}}finally{try{a&&!a.done&&(t=s.return)&&t.call(s)}finally{if(o)throw o.error}}e=this.layerIndex.findIndex(function(t){return t.getId()===e})+1}for(var l=e;l<this.layerIndex.length;l++)try{n=void 0;for(var u=zf(this.layerIndex[l]._getLayerIds()),p=u.next();!p.done;p=u.next()){c=p.value;if(this.map._getMap().getLayer(c))return c}}catch(t){n={error:t}}finally{try{p&&!p.done&&(r=u.return)&&r.call(u)}finally{if(n)throw n.error}}},Ff.prototype.clear=function(){for(var t=this.layerIndex.length-1;0<=t;t--){var e=this.layerIndex[t];e&&(this._removeMapboxLayers(e,!0),this.layerIndex.splice(t,1),e.onRemove())}this.userLayers=[]},Ff.prototype.getLayerById=function(e){var t=this.layerIndex.find(function(t){return t.getId()===e});if(t)return t},Ff.prototype.getLayers=function(){return this.layerIndex.slice(0)},Ff.prototype._getSourceIds=function(){var e,t,o=new Set;try{for(var n=zf(this.layerIndex),r=n.next();!r.done;r=n.next())r.value._getSourceIds().forEach(function(t){return o.add(t)})}catch(t){e={error:t}}finally{try{r&&!r.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return o},Ff.prototype._getUserLayers=function(){return Array.from(this.userLayers)},Ff.prototype.move=function(t,e){var o=t instanceof M?t.getId():t,n=e instanceof M?e.getId():e;if(!this.layerIndex.find(function(t){return t.getId()===o}))throw new Error("The layer '".concat(o,"' has not been added to the map and cannot be moved."));e=this.layerIndex.findIndex(function(t){return t.getId()===o}),this._moveMapboxLayers(this.layerIndex[e],n),t=this.layerIndex[e],this.layerIndex.splice(e,1),e=this.layerIndex.findIndex(function(t){return t.getId()===n}),-1<e?this.layerIndex.splice(e,0,t):this.layerIndex.push(t),e=this.userLayers.find(function(t){return t.layer.getId()===o});e&&(e.before=n)},Ff.prototype._moveMapboxLayers=function(t,e){var o,n,r=this._getMapboxBefore(e);try{for(var i=zf(t._getLayerIds()),s=i.next();!s.done;s=i.next()){var a=s.value;this.map._getMap().moveLayer(a,r)}}catch(t){o={error:t}}finally{try{s&&!s.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}},Ff.prototype.getRenderedShapes=function(t,e,o){var n,r,i,s=this;if(t=t||[-180,-85.0511,180,85.0511],Array.isArray(t)?4===t.length||6===t.length?i=this.map.positionsToPixels([S.getSouthWest(t),S.getNorthEast(t)]):2!==t.length&&3!==t.length||(i=this.map.positionsToPixels([t])[0]):i=this.map.positionsToPixels([t.coordinates])[0],e){e=Array.isArray(e)?e:[e];var a=[],c=this;try{for(var l=zf(e),u=l.next();!u.done;u=l.next())!function(t){var e=t instanceof M?t.getId():t,t=c.layerIndex.findIndex(function(t){return t.getId()===e});if(!(-1<t))throw new Error("The layer '".concat(e,"' has not been added to the map ")+"and its rendered features cannot be retrieved.");a.push.apply(a,Rf([],Df(c.layerIndex[t]._getLayerIds().filter(function(t){return!!s.map._getMap().getLayer(t)})),!1))}(u.value)}catch(t){n={error:t}}finally{try{u&&!u.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}}t=this.map._getMap().queryRenderedFeatures(i,{layers:a,filter:o});return this.map.sources._mapFeaturesToShapes(t)},Ff.prototype.remove=function(t){var e,o;if(Array.isArray(t))try{for(var n=zf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this._removeLayer(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}else this._removeLayer(t)},Ff.prototype._removeLayer=function(t){var e=t instanceof M?t.getId():t,o=this.layerIndex.findIndex(function(t){return t.getId()===e});if(-1==o)throw new Error("The layer '".concat(e,"' has not been added to the map and cannot be removed."));var n=this.layerIndex[o],o=(this._removeMapboxLayers(n),this.layerIndex.splice(o,1),this.userLayers.findIndex(function(t){return t.layer.getId()===e}));-1!=o&&this.userLayers.splice(o,1),t instanceof eh&&this.map.sources.unsetSourceState(t._getSourceId()),n.onRemove()},Ff);function Ff(t){this.layerIndex=[],this.userLayers=[],this.map=t}var Nf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Zf=(qf.prototype.add=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=Nf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.popups.has(i)||(this.popups.add(i),i.attach(this.map))}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},qf.prototype.clear=function(){var e=this;this.popups.forEach(function(t){e.popups.delete(t),t.remove()})},qf.prototype.remove=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=Nf(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.popups.has(i)&&(this.popups.delete(i),i.remove())}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},qf.prototype.getPopups=function(){return Array.from(this.popups)},qf.prototype._getCollectionDiv=function(){var t=this.map.getMapContainer().querySelector(".".concat(qf.Css.collection));return t||((t=document.createElement("div")).classList.add(qf.Css.collection),t.setAttribute("aria-label","Map Information"),this.map.getMapContainer().appendChild(t)),t},qf.prototype._addDraggedPopup=function(t){0===this.draggedPopups.size&&(this.map.getMapContainer().addEventListener("mousemove",this._onDrag),this.map.getMapContainer().addEventListener("touchmove",this._onDrag),this.map.getMapContainer().addEventListener("mouseup",this._onUp),this.map.getMapContainer().addEventListener("touchend",this._onUp)),this.draggedPopups.add(t)},qf.Css={collection:"popup-collection-container"},qf);function qf(t){var n=this;this._onDrag=function(t){var e,o;"mousemove"===t.type?(e=t.clientX,o=t.clientY):"touchmove"===t.type&&(e=t.touches[0].clientX,o=t.touches[0].clientY),n.draggedPopups.forEach(function(t){t._dragToPixel([e,o])})},this._onUp=function(){n.map.getMapContainer().removeEventListener("mousemove",n._onDrag),n.map.getMapContainer().removeEventListener("touchmove",n._onDrag),n.map.getMapContainer().removeEventListener("mouseup",n._onUp),n.map.getMapContainer().removeEventListener("touchend",n._onUp),n.draggedPopups.forEach(function(t){n.draggedPopups.delete(t),t._onUp()})},this.map=t,this.popups=new Set,this.draggedPopups=new Set}var Hf=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Uf=(Wf.prototype.add=function(t,e){var o,n;if(void 0===e&&(e=!0),Array.isArray(t))try{for(var r=Hf(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._addSource(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._addSource(t,e)},Wf.prototype.getRenderedShapes=function(t,e,o){t="string"==typeof t?t:t.getId(),o=this.map._getMap().querySourceFeatures(t,{sourceLayer:o,filter:e});return this.map.sources._mapFeaturesToShapes(o,!0,this.sources.get(t))},Wf.prototype.getFeatureState=function(t,e,o){t="string"==typeof t?t:t instanceof x?t.getId():t.id,e="string"==typeof e?e:e.getId();return this.map._getMap().getFeatureState({id:t,source:e,sourceLayer:o})},Wf.prototype.removeFeatureState=function(t,e,o,n){t="string"==typeof t?t:t instanceof x?t.getId():t.id,e="string"==typeof e?e:e.getId();this.map._getMap().removeFeatureState({id:t,source:e,sourceLayer:o},n)},Wf.prototype.setFeatureState=function(t,e,o,n){t="string"==typeof t?t:t instanceof x?t.getId():t.id,e="string"==typeof e?e:e.getId();this.map._getMap().setFeatureState({id:t,source:e,sourceLayer:n},o)},Wf.prototype._buildSources=function(){var e={};return this.sources.forEach(function(t){e[t.getId()]=t._buildSource()}),e},Wf.prototype.clear=function(){var e=this;this.sources.forEach(function(t){e.remove(t)})},Wf.prototype.getById=function(t){return this.sources.get(t)},Wf.prototype.getSources=function(){return Array.from(this.sources.values())},Wf.prototype.isSourceLoaded=function(t){t=t instanceof k?t.getId():t;return this.map._getMap().isSourceLoaded(t)},Wf.prototype.remove=function(t,e){var o,n;if(void 0===e&&(e=!0),Array.isArray(t))try{for(var r=Hf(t),i=r.next();!i.done;i=r.next()){var s=i.value;this._removeSource(s,e)}}catch(t){o={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(o)throw o.error}}else this._removeSource(t,e)},Wf.prototype.setSourceState=function(t,e){void 0===e&&(e=!0),this.sources.set(t.getId(),t),t._setMap(this.map,e)},Wf.prototype.unsetSourceState=function(t){this.sources.has(t)&&(this.sources.get(t)._setMap(null),this.sources.delete(t))},Wf.prototype._removeSource=function(t,e){t=t instanceof k?t.getId():t;if(!this.sources.has(t))throw new Error("'".concat(t,"' is not added to the map"));if(this.map._getMap().getSource(t)&&e&&this.map._getMap().removeSource(t),this.map._getMap().getSource(t)&&e)throw new Error("One or more layers have a dependency on the source '".concat(t,"'"));this.unsetSourceState(t)},Wf.prototype._addSource=function(t,e){if(this.sources.has(t.getId())){if(e)throw new Error("'".concat(t.getId(),"' is already added to the map"));this.unsetSourceState(t.getId())}if(e){if(!this.map._isReady())throw new Error("The source '".concat(t.getId(),"' could not be added to the map because ")+"the map is not ready. Please use a ready event listener to guarantee the map is ready before adding a source to it.");this.map._getMap().addSource(t.getId(),t._buildSource())}this.setSourceState(t)},Wf.prototype._mapFeaturesToShapes=function(t,e,o){var n,r,i=[];try{for(var s=Hf(t),a=s.next();!a.done;a=s.next()){var c=a.value;if((o||"string"==typeof c.source)&&"string"==typeof c.properties[x._shapeIdPropName]){var l=o||this.sources.get(c.source);if(l instanceof Nu){var u=l.getShapeById(c.properties[x._shapeIdPropName]);if(u instanceof x){i.push(u);continue}}}e||i.push(c)}}catch(t){n={error:t}}finally{try{a&&!a.done&&(r=s.return)&&r.call(s)}finally{if(n)throw n.error}}return i},Wf.prototype._syncSources=function(r){var n=this;r?(Object.keys(r).map(function(t){var e,o=r[t];switch(o.type){case"vector":case"raster":case"raster-dem":e=new $h(t,{name:t,tiles:o.tiles,type:o.type,url:o.url,tileSize:"tileSize"in o?o.tileSize:void 0});break;case"canvas":e=new Ju(t,o);break;case"geojson":var n=new Nu(t,{maxZoom:o.maxzoom,cluster:o.cluster,clusterRadius:o.clusterRadius,tolerance:o.tolerance,lineMetrics:o.lineMetrics,clusterProperties:o.clusterProperties,buffer:o.buffer,clusterMinPoints:o.clusterMinPoints,generateId:o.generateId,promoteId:o.promoteId,filter:o.filter});"string"!=typeof o.data&&void 0!==o.data&&n._addNoUpdate(o.data),e=n;break;case"image":e=new rp(t,o);break;case"video":e=new cp(t,o);break;default:e=new tp(t,o)}return e}).forEach(function(t){var e=n.sources.get(t.getId()),o=e&&t._isDeepEqual(e);!o&&e&&n.unsetSourceState(e.getId()),n.setSourceState(t,!o)}),Array.from(this.sources.keys()).filter(function(t){return!(t in r)}).forEach(function(t){return n.unsetSourceState(t)})):console.warn("syncSources called with no style sources which is unexpected.")},Wf);function Wf(t){this.map=t,this.sources=new Ne}(window&&window.__extends||(Gf=function(t,e){return(Gf=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Gf(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Yf,Vf=t);var Gf,Vf,Kf=Yf;function Yf(){var t=null!==Vf&&Vf.apply(this,arguments)||this;return t.duration=1e3,t.type="jump",t}(window&&window.__extends||(Jf=function(t,e){return(Jf=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Jf(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Qf,$f=t);var Jf,$f,Xf=Qf;function Qf(){var t=null!==$f&&$f.apply(this,arguments)||this;return t.bottom=0,t.left=0,t.right=0,t.top=0,t}var ty,ey,i=window&&window.__extends||(ty=function(t,e){return(ty=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ty(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),oy=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},ny=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},ry=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},iy=(i(sy,ey=t),sy.prototype.merge=function(){for(var e,t,o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];try{for(var r=oy(o),i=r.next();!i.done;i=r.next()){var s=i.value;s&&"number"==typeof s.padding&&(s.padding={top:s.padding,bottom:s.padding,left:s.padding,right:s.padding})}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return ey.prototype.merge.apply(this,ry([],ny(o),!1))},sy);function sy(){var t=null!==ey&&ey.apply(this,arguments)||this;return t.bounds=[-180,-89,180,90],t.maxBounds=void 0,t.maxZoom=20,t.offset=new Hc(0,0),t.padding=new Xf,t}(window&&window.__extends||(ay=function(t,e){return(ay=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}ay(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(uy,cy=t);var ay,cy,ly=uy;function uy(){var t=null!==cy&&cy.apply(this,arguments)||this;return t.zoom=1,t.center=new Zl(0,0),t.centerOffset=new Hc(0,0),t.bearing=0,t.pitch=0,t.minZoom=1,t.maxZoom=20,t.minPitch=0,t.maxPitch=60,t.maxBounds=void 0,t}(window&&window.__extends||(py=function(t,e){return(py=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}py(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(dy,hy=t);var py,hy,er=dy;function dy(){var t=null!==hy&&hy.apply(this,arguments)||this;return t.name=void 0,t.before=void 0,t.minZoom=1,t.maxZoom=20,t.overwrite=!1,t.opacity=1,t}(window&&window.__extends||(fy=function(t,e){return(fy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}fy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(gy,yy=er);var fy,yy,my=gy;function gy(){var t=null!==yy&&yy.apply(this,arguments)||this;return t.color="rgba(0,0,0,.5)",t.outlineColor="#000",t.radius=1,t.outlineWidth=5,t.name="default-circles",t}(window&&window.__extends||(vy=function(t,e){return(vy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}vy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(by,wy=er);var vy,wy,_y=by;function by(){var t=null!==wy&&wy.apply(this,arguments)||this;return t.cap="butt",t.join="miter",t.name="default-linestrings",t.color="#000",t.width=1,t}(window&&window.__extends||(xy=function(t,e){return(xy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}xy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Cy,Oy=er);var xy,Oy,Sy=Cy;function Cy(){var t=null!==Oy&&Oy.apply(this,arguments)||this;return t.iconSize=1,t.fontSize=14,t.fontColor="#000",t.textFont="SegoeUi-Regular",t.cluster=!0,t.clusterIcon=void 0,t.textOffset=[0,0],t.name="default-pins",t.icon="pin-darkblue",t.title="",t}(window&&window.__extends||(Py=function(t,e){return(Py=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Py(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ay,Ly=er);var Py,Ly,ky=Ay;function Ay(){var t=null!==Ly&&Ly.apply(this,arguments)||this;return t.color="rgba(0,0,0,.5)",t.outlineColor="#000",t.name="default-polygons",t}(window&&window.__extends||(My=function(t,e){return(My=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}My(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Iy,Ey=er);var My,Ey,jy=Iy;function Iy(){var t=null!==Ey&&Ey.apply(this,arguments)||this;return t.name="default-raster",t}(window&&window.__extends||(Ty=function(t,e){return(Ty=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Ty(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}))(Ry,zy=t);var Ty,zy,Dy=Ry;function Ry(){var t=null!==zy&&zy.apply(this,arguments)||this;return t.anchor="map",t.color="#FFFFFF",t.intensity=.5,t.position=[1.15,210,30],t}var By,Fy,r=window&&window.__extends||(By=function(t,e){return(By=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}By(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ny=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Zy=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},qy=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Hy=(r(Uy,Fy=t),Uy.prototype.merge=function(){for(var e,t,o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];try{for(var r=Ny(o),i=r.next();!i.done;i=r.next()){var s=i.value;s&&(s.hasOwnProperty("view")?s.userRegion=s.view:s.hasOwnProperty("userRegion")&&(s.view=s.userRegion),"string"==typeof s.language)&&(s.language=Ct.getCode(s.language))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return Fy.prototype.merge.apply(this,qy([],Zy(o),!1))},Uy);function Uy(){var t=null!==Fy&&Fy.apply(this,arguments)||this;return t.antialias=void 0,t.autoResize=!0,t.language=Ft,t.light=new Dy,t.preserveDrawingBuffer=!1,t.progressiveLoading=!1,t.progressiveLoadingInitialLayerGroups=["base"],t.renderWorldCopies=!0,t.showBuildingModels=!1,t.showFeedbackLink=!0,t.showLogo=!0,t.showLabels=!0,t.customAttribution=void 0,t.showTileBoundaries=!1,t.style=void 0,t.view=Bt,t.userRegion=t.view,t.styleOverrides=void 0,t.customStyleTransform=void 0,t}function Wy(t){return 0==t.length?void 0:t.slice(1).reduce(function(o,n){return function(t,e){t=o(t,e);return Ky(Ky({},t),n(t.url,e))}},t[0])}var Gy,Vy,tr=window&&window.__extends||(Gy=function(t,e){return(Gy=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}Gy(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),Ky=window&&window.__assign||function(){return(Ky=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},Yy=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Jy=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},$y=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Xy=(tr(Qy,Vy=t),Qy.prototype.merge=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var o=this.styleDefinitionsVersion;try{for(var n=Yy(t),r=n.next();!r.done;r=n.next()){var i=r.value;i&&(i.authOptions?"string"==typeof i.authOptions.subscriptionKey&&(i.subscriptionKey=i["subscription-key"]=i.authOptions.subscriptionKey):"string"==typeof i.subscriptionKey?(i["subscription-key"]=i.subscriptionKey,i.authOptions={authType:u.AuthenticationType.subscriptionKey,subscriptionKey:i.subscriptionKey}):"string"==typeof i["subscription-key"]&&(i.subscriptionKey=i["subscription-key"],i.authOptions={authType:u.AuthenticationType.subscriptionKey,subscriptionKey:i["subscription-key"]}),"string"==typeof i.sessionId?i["session-id"]=i.sessionId:"string"==typeof i["session-id"]&&(i.sessionId=i["session-id"]),"boolean"==typeof i.disableTelemetry?i["disable-telemetry"]=i.disableTelemetry:"boolean"==typeof i["disable-telemetry"]&&(i.disableTelemetry=i["disable-telemetry"]),"boolean"==typeof i.enableAccessibility?i["enable-accessibility"]=i.enableAccessibility:"boolean"==typeof i["enable-accessibility"]&&(i.enableAccessibility=i["enable-accessibility"]))}}catch(t){c={error:t}}finally{try{r&&!r.done&&(a=n.return)&&a.call(n)}finally{if(c)throw c.error}}var s=this._transformers,a=t?t.filter(function(t){return void 0!==t}).reduce(function(t,e){return $y($y([],Jy(t),!1),Jy(e._transformers||[]),!1)},[]):[],c=Vy.prototype.merge.apply(this,$y([],Jy(t),!1)),a=(c.authOptions.authType!==u.AuthenticationType.subscriptionKey&&(c["subscription-key"]=c.subscriptionKey=void 0),void 0!==c.styleSet&&void 0===c.mapConfiguration&&(c.mapConfiguration=c.styleSet),c.mapConfiguration&&"string"!=typeof c.mapConfiguration&&(c.mapConfiguration=Ky(Ky({},c.mapConfiguration),{defaultConfiguration:c.mapConfiguration.defaultConfiguration||c.mapConfiguration.defaultStyle,configurations:c.mapConfiguration.configurations||c.mapConfiguration.styles})),this._transformers=$y($y([],Jy(s||[]),!1),Jy(a.filter(function(t){return!s.includes(t)})),!1),this.transformRequest&&!this._transformers.includes(this.transformRequest)&&this._transformers.push(this.transformRequest),new Date(Date.UTC(2023,0))),l=new Date(this.styleDefinitionsVersion);return(isNaN(l.getTime())||l.getTime()<a.getTime())&&(console.warn("Style definition version ".concat(this.styleDefinitionsVersion," is invalid or deprecated, style definition version is unchanged (").concat(o,")")),this.styleDefinitionsVersion=o),this.transformRequest=Wy(this._transformers),c},Qy.prototype.addTransformer=function(t){this._transformers||(this._transformers=[]),this._transformers.push(t),this.transformRequest=Wy(this._transformers)},Qy.prototype.removeTransformer=function(e){this._transformers&&(this._transformers=this._transformers.filter(function(t){return e!==t}),this.transformRequest=Wy(this._transformers))},Qy._cloneCustomizer=function(t){if("object"==typeof t)return Object.assign({},t)},Qy);function Qy(){var t=null!==Vy&&Vy.apply(this,arguments)||this;return t.authOptions=oe(),t.disableTelemetry=!0,t["disable-telemetry"]=t.disableTelemetry,t.domain=Zt,t.staticAssetsDomain=qt,t.styleDefinitionsPath=Ht,t.styleDefinitionsVersion=Ut,t.styleAPIVersion=Wt,t.mapConfiguration=void 0,t.styleSet=void 0,t.enableAccessibility=!0,t["enable-accessibility"]=t.enableAccessibility,t.enableAccessibilityLocationFallback=!0,t.maxParallelImageRequests=le(),t.refreshExpiredTiles=!0,t.subscriptionKey=he(),t["subscription-key"]=t.subscriptionKey,t.sessionId=Nt,t["session-id"]=t.sessionId,t._transformers=[],t.transformRequest=void 0,t.workerCount=ce(),t.fadeDuration=300,t.localIdeographFontFamily="sans-serif",t.validateStyle=!1,t}em.getLayerGroup=function(t){return"string"!=typeof t&&t.metadata&&t.metadata["microsoft.maps:layerGroup"]?t.metadata["microsoft.maps:layerGroup"]:(t="string"!=typeof t?t.id:t).startsWith("microsoft.")&&4<=(t=t.split(".")).length?t[3]:void 0};var tm=em;function em(){}nm.resolve=function(t){return new nm(Promise.resolve(t))},nm.reject=function(t){return new nm(Promise.reject(t))},nm.prototype.then=function(t,e){var o=this;return new Promise(function(t,e){o._resolve=t,o._reject=e,o._thenResolver(t,e)}).then(t,e)},nm.prototype.catch=function(t){var o=this;return new Promise(function(t,e){o._resolve=t,o._reject=e,o._thenResolver(t,e)}).catch(t)},nm.prototype.finally=function(t){var o=this;return new Promise(function(t,e){o._resolve=t,o._reject=e,o._thenResolver(t,e)}).finally(t)},nm.prototype.hijackAndResolve=function(t){this._hijackedToResolve=t,this._resolve&&this._resolve(t)},nm.prototype.hijackAndReject=function(t){this._hijackedToReject=t,this._reject&&this._reject(t)},nm.prototype.switchWith=function(t){this.origin=t,this._toResolve=void 0,this._toReject=void 0};var om=nm;function nm(t){var r=this;this.isHijacked=function(){return void 0!==r._hijackedToResolve||void 0!==r._hijackedToReject},this.isResolved=function(){return void 0!==r._hijackedToResolve||void 0!==r._toResolve},this.isRejected=function(){return void 0!==r._hijackedToReject||void 0!==r._toReject},this.resultIfResolved=function(){return r._hijackedToResolve||r._toResolve},this.errorIfRejected=function(){return r._hijackedToReject||r._toReject},this._thenResolver=function(e,o){var n;r._hijackedToResolve?e(r._hijackedToResolve):r._hijackedToReject?o(r._hijackedToReject):(n=r.origin,r.origin.then(function(t){r.isHijacked()||(n!==r.origin?r._thenResolver(e,o):(r._toResolve=t,e(t)))}).catch(function(t){r.isHijacked()||(n!==r.origin?r._thenResolver(e,o):(r._toReject=t,o(t)))}))},this.origin=t,this[Symbol.toStringTag]=this.origin[Symbol.toStringTag]}var rm={road:"Road",satellite:"Satellite",satellite_road_labels:"Hybrid",grayscale_dark:"Grayscale (Dark)",grayscale_light:"Grayscale (Light)",night:"Night",road_shaded_relief:"Terra",blank:"Blank",blank_accessible:"Blank (Accessible)",high_contrast_dark:"High contrast (Dark)",high_contrast_light:"High contrast (Light)"},im=window&&window.__assign||function(){return(im=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},sm=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},am=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},cm=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},lm=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},um=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},pm={countryRegion:"cr|bv:0",adminDistrict:"ad|bv:0",adminDistrict2:"ds|bv:0",buildingFootprint:"bld|v:0_adr|lv:0",roadDetails:"g|rasterDetailsVisible:0"},hm=(I.prototype.updateIndoorState=function(t,e){var o,n,r=this,i=this.map.styles.getMapConfiguration();i?(this.preservedPreindoorMapConfiguration=i,o=this.map.getStyle().style?"".concat(this.map.getStyle().style,"_indoor").concat("dark"===t?"_dark":"","_tileset_").concat(e):void 0,this.map.styles.setMapConfiguration("defaultIndoor_".concat(e),"microsoft-maps:default"===i?o:void 0)):(n=(null==(i=this.indoorState)?void 0:i.tilesetId)!==e,this.indoorState={tilesetId:e,theme:t},this.initStyleset(),this.definitions().then(function(t){var e=(r.map.getStyle().style||t.defaultConfiguration).replace("_indoor_dark","").replace("_indoor",""),o="".concat(e,"_indoor"),e=t.configurations.find(function(t){return t.name.startsWith(o)});e&&r.map.setStyle({style:e.name},!n)}))},I.prototype.unsetIndoorState=function(){var o=this,t=this.preservedPreindoorMapConfiguration;t?this.map.styles.setMapConfiguration(t):(this.indoorState=void 0,this.initStyleset(),this.definitions().then(function(t){var e=o.map.getStyle().style;e.includes("_indoor")&&e.split("_indoor")[0]?o.map.setStyle({style:e.split("_indoor")[0]}):o.map.setStyle({style:void 0})}))},I.prototype.initStyleset=function(){var t,o=this;return t=this.serviceOptions.mapConfiguration?"string"==typeof this.serviceOptions.mapConfiguration?(t=this.map.authentication?this.map.authentication.initialize():Promise.resolve(),new om(t.then(function(){return o._request(o.serviceOptions.domain,"".concat(lt,"/mapconfigurations/metadata/").concat(o.serviceOptions.mapConfiguration),"StyleDefinitions").then(function(t){return im(im({},t),{defaultConfiguration:t.defaultConfiguration||t.defaultStyle,configurations:t.configurations||t.styles})})}))):om.resolve(this.serviceOptions.mapConfiguration):(t=this.map.authentication?this.map.authentication.initialize():Promise.resolve(),new om(t.then(function(){return o._request(o.serviceOptions.staticAssetsDomain,"".concat(ct,"/").concat(lt),"StyleDefinitions",{version:o.serviceOptions.styleDefinitionsVersion,mcv:At.replace(/\./g,"")}).then(function(e){return{version:isNaN(e.version)?0:parseFloat(e.version),defaultConfiguration:e.defaultStyle,configurations:e.styles.filter(function(t){return o.indoorState?"auto"===o.indoorState.theme?t.name.endsWith("dark"===t.theme?"_indoor_dark":"_indoor"):t.name.endsWith("dark"===o.indoorState.theme?"_indoor_dark":"_indoor"):!t.name.includes("indoor")}).map(function(t){return{copyright:t.copyright.join(" "),name:t.name,displayName:function(t){t=o.indoorState&&t.includes("_indoor")?t.split("_indoor")[0]:t;return t in rm?rm[t]:t}(t.name),theme:t.theme,thumbnail:new wt({domain:o.serviceOptions.staticAssetsDomain,path:t.thumbnail,protocol:"https"}).toString(),url:new wt({domain:o.serviceOptions.staticAssetsDomain,path:"".concat(ct,"/").concat(lt,"/").concat(t.name),queryParams:{styleVersion:void 0!==e.version&&null!==e.version?e.version:o.serviceOptions.styleDefinitionsVersion,mcv:At.replace(/\./g,"")},protocol:"https"}).toString()}})}})}))),this.initPromise&&this.initPromise.switchWith(t),this.initPromise=t,this.initPromise.then(function(t){return o.map._invokeEvent("mapconfigurationchanged",t)}),this.initPromise},I.prototype.getStyle=function(t){t=this._lookUp(t);if(!t)throw Error("Style definition is not available.");if(t.url)return t.url;if(t.style)return t.style;throw Error("Style definition neither contains URL nor style object.")},I.prototype.deriveNewStyleAndLayerGroups=function(t,e){for(var o,n,r=this.map.getStyle(),i=this.map.getTraffic(),s={},a=0;a<e.layers.length;a++){var c=e.layers[a],l=tm.getLayerGroup(c);l?(s[l]||(s[l]=[]),s[l].push(c),r.showBuildingModels||"fill-extrusion"!==c.type?"fill-extrusion"===c.type&&(c.layout=null!=(o=c.layout)?o:{},c.layout.visibility="visible"):(c.layout=null!=(o=c.layout)?o:{},c.layout.visibility="none"),"none"!==i.flow&&l&&l==="traffic_".concat(i.flow)&&"line"==c.type&&(c.layout=null!=(n=c.layout)?n:{},c.layout.visibility="visible"),"labels"!==l&&"labels_places"!==l&&"labels_indoor"!==l||"symbol"!==c.type||(r.showLabels&&"none"!==(null==(n=c.layout)?void 0:n.visibility)?(c.layout=null!=(l=c.layout)?l:{},c.layout.visibility="visible"):(c.layout=null!=(l=c.layout)?l:{},c.layout.visibility="none"))):s[c.id]=[c]}return[e,s]},I.prototype.injectUserLayersIntoStyle=function(s,a,c){return s?this.map.layers._getUserLayers().reduce(function(o,e){var n,t,r,i;return e.layer instanceof yd||(n=(null==(t=null==(t=null==c?void 0:c[e.before])?void 0:t[0])?void 0:t.id)||e.before,t=s.layers.find(function(t){return t.id===e.layer.getId()}),-1<(r=a.layers.findIndex(function(t){return t.id===e.layer.getId()}))&&a.layers.splice(r,1),t&&(r=new Set(Array.from(e.layer._getSourceIds()).map(function(t){var e;return!o.sources[t]&&(e=s.sources[t])?{source:e,id:t}:void 0}).filter(function(t){return void 0!==t})),-1<(i=n?o.layers.findIndex(function(t){return t.id===n}):-1)?o.layers.splice(i,0,t):o.layers.push(t),r.forEach(function(t){var e=t.source,t=t.id;o.sources[t]=e}))),o},im({},a)):a},I.prototype.setStyle=function(r,t){var i=this,e=(void 0===t&&(t=!0),this._lookUp(r));if(!e)throw Error("Style definition ".concat(r.style," is not available."));if(!e.url&&!e.style)throw Error("Style definition neither contains URL nor style object.");var o,n,s,a=function(){return i._onStyleData(e)},c=function(){i.map.events.remove("styledata",a),i.map.events.addOnce("styledata",a)},l=r&&r.customStyleTransform?function(t,e){t=r.customStyleTransform(t,e);return c(),t}:function(t,e){var o=im(im({},e),{layers:lm([],cm(e.layers),!1),sources:im({},e.sources)}),n=r.progressiveLoading&&!i.map._isLoaded(),e=(n&&Array.isArray(null==e?void 0:e.layers)&&((o=im({},e)).layers=o.layers.map(function(t){var e=im({},t);return t.layout&&(e.layout=im({},t.layout)),e})),cm(i.deriveNewStyleAndLayerGroups(t,o),2)),o=e[0],e=e[1],n=(n&&(n=r.progressiveLoadingInitialLayerGroups,Array.isArray(n))&&0<n.length&&i._deferLayerGroupVisibilities(e,n),i.injectUserLayersIntoStyle(t,o,e)),t=Object.entries(e).map(function(t){var t=cm(t,2),e=t[0],t=t[1];return i._buildFundamentalLayerFrom(t,e)}),o=i.map.layers._getUserLayers().reduce(function(t,e){var o=e.before?t.findIndex(function(t){return t.getId()===e.before}):-1;return-1<o?t.splice(o,0,e.layer):t.push(e.layer),t},t);return i.map.layers.layerIndex=o,i.map.sources._syncSources(n.sources),c(),n},u=e.url;u&&null!=r&&r.styleOverrides&&(o=new URL(u),n=new URLSearchParams(o.search),0<(s=Object.entries(null==r?void 0:r.styleOverrides).filter(function(t){var t=cm(t,2),e=t[0],t=t[1];return e in pm&&(pm[e].includes("bv")&&!1===(null==t?void 0:t.borderVisible)||!pm[e].includes("bv")&&!1===(null==t?void 0:t.visible))}).map(function(t){var t=cm(t,2),e=t[0];return t[1],pm[e]})).length)&&(n.set("st",s.join("_")),o.search=n.toString(),u=o.toString()),this.map._getMap().setStyle(u||e.style,{diff:t,validate:this.serviceOptions.validateStyle,transformStyle:l})},I.prototype.getTheme=function(t){t=this._lookUp(t);if(t)return t.theme.toLowerCase()},I.prototype.getThemeAsync=function(e){return sm(this,void 0,void 0,function(){return am(this,function(t){switch(t.label){case 0:return[4,this._lookUpAsync(e)];case 1:return[2,t.sent().theme]}})})},I.prototype.setMapConfiguration=function(t,o){var n=this;"string"==typeof(this.serviceOptions.mapConfiguration=t)?this.initStyleset():this.initPromise?this.initPromise.hijackAndResolve(t):this.initPromise=om.resolve(t),this.definitions().then(function(t){var e=t.defaultConfiguration;t.configurations.find(function(t){return t.name===o})&&(e=o),n.map.setStyle({style:e})})},I.prototype.getMapConfiguration=function(){return this.serviceOptions.mapConfiguration},I.prototype.setStyleSet=function(t){this.updateIndoorState("indoor_dark"===t?"dark":"light",null)},I.prototype.getStyleSet=function(){return void 0!==this.indoorState?"dark"===this.indoorState.theme?"indoor_dark":"indoor":"base"},I.prototype.clearStyleSet=function(){this.unsetIndoorState()},I.prototype._buildFundamentalLayerFrom=function(t,e){if(t&&0<t.length)return(t=new If(t,e)).onAdd(this.map),t;throw new Error("Unable to construct fundamental map layer for ID: ".concat(e,"."))},I.prototype._transformStyleRequest=function(t,e){t.includes(et)&&(e.url=e.url.replace(et,this.serviceOptions.domain)),t.includes(st)&&(e.url=e.url.replace(st,ct)),t.includes(at)&&(e.url=e.url.replace(at,lt)),(e.url.toLocaleLowerCase().includes(this.serviceOptions.domain.toLocaleLowerCase())||e.url.toLocaleLowerCase().includes(this.serviceOptions.staticAssetsDomain.toLocaleLowerCase()))&&((t=new URL(e.url)).searchParams.get(Q)||(t.searchParams.set(Q,this.serviceOptions.styleAPIVersion),e.url=t.href),null!=(t=this.map.authentication)&&t.signRequest(e),this._deleteAuthTokenForStaticAssets(e))},I.prototype._request=function(n,r,i,s){var a;return void 0===s&&(s={}),sm(this,void 0,void 0,function(){var e,o;return am(this,function(t){switch(t.label){case 0:return o={url:new wt({protocol:"https",domain:n,path:r,queryParams:im(((o={})[Q]=this.serviceOptions.styleAPIVersion,o),s)}).toString()},"function"==typeof this.serviceOptions.transformRequest&&i&&(o=this.serviceOptions.transformRequest(o.url,i)),null!=(a=this.map.authentication)&&a.signRequest(o),this._deleteAuthTokenForStaticAssets(o),e={method:"GET",mode:"cors"},o.credentials&&(e.credentials=o.credentials),o.headers&&(e.headers=o.headers),[4,fetch(o.url,e).then(function(t){if(t.ok)return t.json();throw new Error("HTTP ".concat(t.status,": ").concat(t.statusText," "))})];case 1:return[2,t.sent()]}})})},I.prototype._deleteAuthTokenForStaticAssets=function(t){t.url.startsWith("https://".concat(this.serviceOptions.staticAssetsDomain,"/").concat(ct))&&(delete t.headers[ut],delete t.headers[tt])},I);function I(t,e){var u=this;this.definitions=function(){var t=u.initPromise||u.initStyleset();return t},this.indoorState=void 0,this.preservedPreindoorMapConfiguration=void 0,this._progressiveLoadingState={mapStyle:void 0,pendingVisibilityChange:void 0},this._deferLayerGroupVisibilities=function(e,t){var o,r,n,i,s=t.filter(function(t){return t in e});0!==s.length&&(o=u.map._getMap(),r=o.getZoom(),n=u.map.getStyle().style,u._progressiveLoadingState.pendingVisibilityChange&&(u.map.events.remove("load",u._progressiveLoadingState.pendingVisibilityChange),u._progressiveLoadingState.pendingVisibilityChange=null),u._progressiveLoadingState.mapStyle=n,(i=Object.entries(e).reduce(function(t,e){var e=cm(e,2),o=e[0],e=e[1],n=s.includes(o);return lm(lm([],cm(t),!1),cm(e.filter(function(t){if("custom"===t.type)return!1;if(n)if("number"==typeof t.maxzoom&&"number"==typeof t.minzoom){if(r<=t.maxzoom&&r>=t.minzoom)return!1}else if("number"==typeof t.minzoom){if(r>=t.minzoom)return!1}else{if("number"!=typeof t.maxzoom)return!1;if(r<=t.maxzoom)return!1}return"none"!==(null==(t=t.layout)?void 0:t.visibility)})),!1)},[])).forEach(function(t){t.layout=t.layout||{},t.layout.visibility="none"}),u._progressiveLoadingState.pendingVisibilityChange=function(){u._progressiveLoadingState.pendingVisibilityChange=null;var t=u.map.getStyle().style;n===t&&(i.forEach(function(t){t.layout.visibility="visible",o.setLayoutProperty(t.id,"visibility","visible")}),null!=(t=u.map.copyrightDelegate))&&t.reloadAttribution()},u.map.events.addOnce("load",u._progressiveLoadingState.pendingVisibilityChange))},this._onStyleData=function(t){u.map.events.invoke("stylechanged",{style:t.name,map:u.map,type:"stylechanged"})},this._lookUp=function(t){var e,o,n=u.definitions(),r=n.errorIfRejected(),i=n.resultIfResolved();if(r||!i)return null;var n=i.configurations,s=void 0;try{for(var a=um(n),c=a.next();!c.done;c=a.next()){var l=c.value;if(l.name===t.style)return l;l.name===i.defaultConfiguration&&(s=s||l)}}catch(t){e={error:t}}finally{try{c&&!c.done&&(o=a.return)&&o.call(a)}finally{if(e)throw e.error}}return s=s||n[0]},this._lookUpAsync=function(o){return sm(u,void 0,void 0,function(){var e;return am(this,function(t){switch(t.label){case 0:return[4,this.definitions()];case 1:return e=t.sent(),[2,e.configurations.find(function(t){return t.name===(o.style||e.defaultConfiguration)})||e.configurations.find(function(t){return t.name===e.defaultConfiguration})||e.configurations[0]]}})})},this.map=t,this.serviceOptions=e}var dm=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},fm=(ym.prototype.add=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=dm(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.indicators.has(i)||(this.indicators.add(i),i.attach(this.map))}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},ym.prototype.clear=function(){var e=this;this.indicators.forEach(function(t){e.indicators.delete(t),t.remove()})},ym.prototype.remove=function(t){var e,o;t=Array.isArray(t)?t:[t];try{for(var n=dm(t),r=n.next();!r.done;r=n.next()){var i=r.value;this.indicators.has(i)&&(this.indicators.delete(i),i.remove())}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},ym.prototype.getIndicators=function(){return Array.from(this.indicators)},ym.prototype._getCollectionDiv=function(){var t=this.map.getMapContainer().querySelector(".".concat(ym.Css.collection));return t||((t=document.createElement("div")).setAttribute("aria-label","map data"),t.setAttribute("role","listbox"),t.classList.add(ym.Css.collection),this.map.getMapContainer().appendChild(t)),t},ym.Css={collection:"accessible-indicator-collection-container"},ym);function ym(t){this.map=t,this.indicators=new Set}var mm,gm,q=window&&window.__extends||(mm=function(t,e){return(mm=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function o(){this.constructor=t}mm(t,e),t.prototype=null===e?Object.create(e):(o.prototype=e.prototype,new o)}),vm=window&&window.__assign||function(){return(vm=Object.assign||function(t){for(var e,o=1,n=arguments.length;o<n;o++)for(var r in e=arguments[o])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)},wm=window&&window.__awaiter||function(t,s,a,c){return new(a=a||Promise)(function(o,e){function n(t){try{i(c.next(t))}catch(t){e(t)}}function r(t){try{i(c.throw(t))}catch(t){e(t)}}function i(t){var e;t.done?o(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}i((c=c.apply(t,s||[])).next())})},_m=window&&window.__generator||function(n,r){var i,s,a,c={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},l={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(l[Symbol.iterator]=function(){return this}),l;function t(o){return function(t){var e=[o,t];if(i)throw new TypeError("Generator is already executing.");for(;c=l&&e[l=0]?0:c;)try{if(i=1,s&&(a=2&e[0]?s.return:e[0]?s.throw||((a=s.return)&&a.call(s),0):s.next)&&!(a=a.call(s,e[1])).done)return a;switch(s=0,(e=a?[2&e[0],a.value]:e)[0]){case 0:case 1:a=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,s=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(a=0<(a=c.trys).length&&a[a.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!a||e[1]>a[0]&&e[1]<a[3]))c.label=e[1];else if(6===e[0]&&c.label<a[1])c.label=a[1],a=e;else{if(!(a&&c.label<a[2])){a[2]&&c.ops.pop(),c.trys.pop();continue}c.label=a[2],c.ops.push(e)}}e=r.call(n,c)}catch(t){e=[6,t],s=0}finally{i=a=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}}},bm=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},xm=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},Om=window&&window.__values||function(t){var e="function"==typeof Symbol&&Symbol.iterator,o=e&&t[e],n=0;if(o)return o.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},jn=(q(T,gm=Ze),Object.defineProperty(T.prototype,"isDisposed",{get:function(){return this.removed},enumerable:!1,configurable:!0}),T.prototype.getCanvas=function(){return this.map.getCanvas()},T.prototype.getCanvasContainer=function(){return this.map.getCanvasContainer()},T.prototype.getMapContainer=function(){return this.map.getContainer()},T.prototype.getServiceOptions=function(){return L(this.serviceOptions,Xy._cloneCustomizer)},T.prototype.setServiceOptions=function(t){this.serviceOptions=(new Xy).merge(this.serviceOptions,t),this.serviceOptions["enable-accessibility"]?this.accessibleMapDelegate.addToMap():this.accessibleMapDelegate.removeFromMap();t=this.styles.serviceOptions.mapConfiguration!==this.serviceOptions.mapConfiguration||this.styles.serviceOptions.staticAssetsDomain!==this.serviceOptions.staticAssetsDomain||this.styles.serviceOptions.styleDefinitionsVersion!==this.serviceOptions.styleDefinitionsVersion||this.styles.serviceOptions.domain!==this.serviceOptions.domain||this.styles.serviceOptions.styleAPIVersion!==this.serviceOptions.styleAPIVersion;this.styles.serviceOptions=this.serviceOptions,t&&(this.styles.initPromise=null,this.setStyle({}))},T.prototype.addRequestTransformer=function(t){this.serviceOptions.addTransformer(t)},T.prototype.removeRequestTransformer=function(t){this.serviceOptions.removeTransformer(t)},T.prototype.setCamera=function(t,e){if(void 0===e&&(e=!1),"padding"in t||"offset"in t||"bounds"in t){var o,n=(new iy).merge({maxZoom:this.getCamera().maxZoom},t),r=this._generateSafeBounds(n.bounds),i={padding:n.padding,offset:n.offset,maxZoom:n.maxZoom};if(!(o=this.map.cameraForBounds(r,i)))throw s={message:"The map cannot be fit to the current canvas with the given CameraBoundsOptions.",containerWidth:null==(s=null==(s=this.map)?void 0:s.getContainer())?void 0:s.clientWidth,containerHeight:null==s?void 0:s.clientHeight,safeBounds:r,cameraForBoundsOptions:i},new Error(JSON.stringify(s));"pitch"in t&&(o.pitch=t.pitch),"bearing"in t&&(o.bearing=t.bearing),"minPitch"in t&&this.map.setMinPitch(t.minPitch),"maxPitch"in t&&this.map.setMaxPitch(t.maxPitch),"minZoom"in t&&this.map.setMinZoom(t.minZoom),r=this._generateSafeBounds(n.maxBounds)}else{i=(new ly).merge(this.getCamera(),t);i.centerOffset&&2<=i.centerOffset.length&&(s=i.centerOffset,(n=Ll([i.center],i.zoom))[0][0]+=s[0],n[0][1]+=s[1],i.center=Pl(n,i.zoom)[0]),o={center:i.center,zoom:i.zoom,bearing:i.bearing,pitch:i.pitch,around:void 0},i.minZoom<1&&console.warn("Setting minZoom below 1 may result in an empty map when the zoom level is less than 1."),this.map.setMinZoom(i.minZoom),this.map.setMaxZoom(i.maxZoom),i.minPitch&&this.map.setMinPitch(i.minPitch),i.maxPitch&&this.map.setMaxPitch(i.maxPitch),this._invokeEvent("minzoomchanged",this.map.getMinZoom()),this._invokeEvent("maxzoomchanged",this.map.getMaxZoom()),r=this._generateSafeBounds(i.maxBounds)}r?this.map.setMaxBounds(r):this.map.setMaxBounds(null);var s=(new Kf).merge(t),n={duration:s.duration,easing:function(t){return t},offset:[0,0],animate:!0},i={fromControl:e};"jump"===s.type?this.map.jumpTo(o,i):"ease"===s.type?this.map.easeTo(vm(vm({},o),n),i):"fly"===s.type&&this.map.flyTo(vm(vm({},o),n),i)},T.prototype.setCameraBounds=function(t){this.setCamera(t)},T.prototype.getCamera=function(){var t=this.map.getBounds().getSouthWest().toArray(),e=this.map.getBounds().getNorthEast().toArray();return{zoom:this.map.getZoom(),center:this.map.getCenter().toArray(),bearing:this.map.getBearing(),pitch:this.map.getPitch(),bounds:new S(t,e),minZoom:this.map.getMinZoom(),maxZoom:this.map.getMaxZoom(),maxBounds:null==(t=this.map.getMaxBounds())?void 0:t.toArray().flat()}},T.prototype.setStyle=function(t,e){void 0===e&&(e=!0),delete t.preserveDrawingBuffer;t=(new Hy).merge(this.styleOptions,t),t.autoResize!==this.styleOptions.autoResize&&this._setAutoResize(t.autoResize),t.language!==this.styleOptions.language&&(this.localizedStringsPromise=Ct.getStrings(t.language)),t.renderWorldCopies!==this.styleOptions.renderWorldCopies&&this.map.setRenderWorldCopies(t.renderWorldCopies),t.showFeedbackLink!==this.styleOptions.showFeedbackLink&&this.copyrightControl.setOptions({showFeedbackLink:t.showFeedbackLink}),t.customAttribution!==this.styleOptions.customAttribution&&this.copyrightControl.setOptions({customAttribution:t.customAttribution}),t.showLogo!==this.styleOptions.showLogo&&(this.copyrightControl.setOptions({showLogo:t.showLogo}),this.logoControl.setOptions({showLogo:t.showLogo})),t.showTileBoundaries!==this.styleOptions.showTileBoundaries&&(this.map.showTileBoundaries=t.showTileBoundaries),t.showBuildingModels&&console.warn("showBuildingModels is deprecated."),e=e&&this.styleOptions.language===t.language&&this.styleOptions.view===t.view;this.styleOptions=t,this._setStyleComponents(t,e)},T.prototype.getStyle=function(){return c(this.styleOptions)},T.prototype.addIcon=function(t,e){this.imageSprite.add(t,e)},T.prototype.addPins=function(t,e){var e=(new Sy).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new Gh("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,iconOptions:{anchor:"center",size:e.iconSize,image:["case",["has","icon"],["get","icon"],e.icon],ignorePlacement:!e.cluster,opacity:e.opacity},textOptions:{anchor:"center",textField:["case",["has","point_count"],["to-string",["get","point_count"]],["has","title"],["to-string",["get","title"]],e.title],font:["case",["has","point_count"],["literal",["StandardFontCondensed-Bold"]],["literal",[e.textFont]]],size:["case",["has","point_count"],20,e.fontSize],ignorePlacement:!e.cluster,opacity:e.opacity,offset:["case",["has","point_count"],["literal",[.5,-.45]],["literal",[e.textOffset[0]/16,e.textOffset[1]/16]]],color:e.fontColor}})),!(o instanceof Gh))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a SymbolLayer.")+"A SymbolLayer should be used for rendering pins.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s,{cluster:e.cluster})),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addCircles=function(t,e){var e=(new my).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new Rp("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,opacity:e.opacity,radius:["case",["has","radius"],["get","radius"],e.radius],color:["case",["has","color"],["get","color"],e.color],strokeColor:["case",["has","outlineColor"],["get","outlineColor"],e.outlineColor],strokeWidth:["case",["has","outlineWidth"],["get","outlineWidth"],e.outlineWidth]})),!(o instanceof Rp))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a BubbleLayer.")+"A BubbleLayer should be used for rendering circles.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s)),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addLinestrings=function(t,e){var e=(new _y).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new dh("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,lineCap:e.cap,lineJoin:e.join,strokeOpacity:e.opacity,strokeColor:["case",["has","color"],["get","color"],e.color],strokeWidth:["case",["has","width"],["get","width"],e.width]})),!(o instanceof dh))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a LineLayer.")+"A LineLayer should be used for rendering linestrings.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s)),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addPolygons=function(t,e){var e=(new ky).merge(e),o=this.layers.getLayerById(e.name),n=!1;if(o||(n=!0,o=new Ah("".concat(e.name,"-source"),e.name,{source:"".concat(e.name,"-source"),minZoom:e.minZoom,maxZoom:e.maxZoom,fillOpacity:e.opacity,fillColor:["case",["has","color"],["get","color"],e.color]})),!(o instanceof Ah))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a PolygonLayer.")+"A PolygonLayer should be used for rendering linestrings.");var r=o.getSource(),i=("string"==typeof r?(s=r,r=this.sources.getById(s)):s=r.getId(),!1);if(r||(i=!0,r=new Nu(s)),!(r instanceof Nu))throw new Error("The source with name '".concat(s,"' already exists but it is not a DataSource.")+"New data can only be added to a DataSource.");i&&this.sources.add(r),n&&this.layers.add(o,e.before);var s=new $l(t);e.overwrite?r.setShapes(s):r.add(s)},T.prototype.addRaster=function(t,e){var o,e=(new jy).merge(e),n=this.layers.getLayerById(e.name);if(!((n=n||new ad({maxZoom:e.maxZoom,minZoom:e.minZoom,opacity:e.opacity,tileSize:256,tileUrl:"{subdomain}"},e.name))instanceof ad))throw new Error("A layer with name '".concat(e.name,"' already exists but it is not a TileLayer.")+"A TileLayer should be used for rendering raster images.");if("{subdomain}"!==n.getOptions().tileUrl)throw new Error("A TileLayer with name '".concat(e.name,"' already exists but was configured ")+"for a single tile url [default for new TileLayer(...)].");(o=!e.overwrite&&n.getOptions().subdomains||[]).push.apply(o,xm([],bm(t),!1)),n._setOptionsNoUpdate({subdomains:o}),this.layers.add(n,e.before)},T.prototype.getLayers=function(){return this.layers.getLayers().map(function(t){return t.getId()})},T.prototype.removeLayers=function(t){var e,o;try{for(var n=Om(t),r=n.next();!r.done;r=n.next()){var i,s=r.value;this.layers.getLayerById(s)&&(this.layers.remove(s),i="".concat(s,"-source"),this.sources.getById(i))&&this.sources.remove(i)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(o=n.return)&&o.call(n)}finally{if(e)throw e.error}}},T.prototype.addHtml=function(t,e){t.id||(t.id="marker_".concat(J()));var o=new Dd({htmlContent:t});return this.markers.add(o,e),t.id},T.prototype.removeHtml=function(t){this.markers.remove(t)},T.prototype.addEventListener=function(t,e,o){this.events._addLegacy(t,e,o)},T.prototype.removeEventListener=function(t,e,o){this.events._removeLegacy(t,e,o)},T.prototype.setUserInteraction=function(t){this.userInteractionDelegate.setOptions(t)},T.prototype.getUserInteraction=function(){return this.userInteractionDelegate.getOptions()},T.prototype.addControl=function(t,e){this.controls.add(t,e)},T.prototype.removeControl=function(t){this.controls.remove(t)},T.prototype.setTraffic=function(t){var e=this.trafficOptions.incidents,o=this.trafficOptions.flow;if(this.trafficOptions=(new Ka).merge(this.trafficOptions,t),this.controls.getControls().filter(function(t){return t instanceof oc}).forEach(function(t){return t.updateButtonState()}),this.incidentDelegate&&(this.trafficOptions.incidents?e||this.incidentDelegate.addToMap():this.incidentDelegate.removeFromMap()),this.trafficOptions.flow&&"none"!==this.trafficOptions.flow){["absolute","relative-delay"].includes(this.trafficOptions.flow)&&console.warn("The 'absolute' and 'relative-delay' flow options are deprecated. Please use 'relative' instead.");try{this.trafficOptions.flow!==o&&this.flowDelegate.addToMap()}catch(t){throw this.trafficOptions.flow=o,t}}else this.flowDelegate.removeFromMap()},T.prototype.getTraffic=function(){return c(this.trafficOptions)},T.prototype.remove=function(){this.dispose()},T.prototype.clear=function(){this.popups.clear(),this.layers.clear(),this.sources.clear(),this.markers.clear(),this.indicators.clear()},T.prototype.dispose=function(){var t;for(this.clear(),this.map.remove(),null!=(t=this.authentication)&&t.dispose(),this.removed=!0,null!=(t=this.resizeObserver)&&t.disconnect(),this.resizeObserver=null;this.getMapContainer().firstChild;){var e=this.getMapContainer().firstChild;this.getMapContainer().removeChild(e)}},T.prototype.resize=function(t,e,o){"number"!=typeof t&&"string"!=typeof t||"number"!=typeof e&&"string"!=typeof e?o=t:(t=t,this.getMapContainer().style.height="number"==typeof t?"".concat(t,"px"):t,this.getMapContainer().style.width="number"==typeof e?"".concat(e,"px"):e);t=this.getMapContainer().style.overflow;this.getMapContainer().style.overflow="hidden",this.map.resize(o),this.getMapContainer().style.overflow=t},T.prototype.pixelsToPositions=function(t){var e,o,n=[];try{for(var r=Om(t),i=r.next();!i.done;i=r.next()){var s=i.value,a=this.map.unproject(s);n.push(new Zl(a.lng,a.lat))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}return n},T.prototype.positionsToPixels=function(t){var e,o,n=[];try{for(var r=Om(t),i=r.next();!i.done;i=r.next()){var s=i.value,a=this.map.project(s);n.push(new Hc(a.x,a.y))}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}return n},T.prototype.areTilesLoaded=function(){return this.map.areTilesLoaded()},T.prototype.stop=function(){this.map.stop()},T.prototype.triggerRepaint=function(){this.map.triggerRepaint()},T.prototype.enableElevation=function(t,e){this.map.setTerrain("string"==typeof t?{source:t,exaggeration:e}:{source:t.getId(),exaggeration:e})},T.prototype.disableElevation=function(){this.map.setTerrain(null)},T.prototype._getMap=function(){return this.map},T.prototype._rebuildStyle=function(e){return void 0===e&&(e=!0),wm(this,void 0,void 0,function(){return _m(this,function(t){return this.styles.setStyle(this.styleOptions,e),this.imageSprite._restoreImages(),[2]})})},T.prototype._isLoaded=function(){return this.loaded},T.prototype._isReady=function(){return this.ready},T.prototype._getLocalizedStrings=function(){return this.localizedStringsPromise},T.prototype._sendRequest=function(t,e,o){var n;return(n="function"==typeof this.serviceOptions.transformRequest?this.serviceOptions.transformRequest(t,e):n)?fetch(n.url||t,{credentials:n.credentials,headers:vm(vm({},o),n.headers),method:"GET",mode:"cors"}):fetch(t,{headers:o,method:"GET",mode:"cors"})},T.prototype._substituteDomainLanguageViewAndSignInRequest=function(t,e){var o;(t.includes(ot)||t.includes(et))&&(o=new RegExp("[^{]".concat(ot,"[^}]")),t.match(o)&&(e.url=e.url.replace(ot,et)),wt.protoRegEx.test(this.serviceOptions.domain)?(o=e.url.indexOf(et),e.url=this.serviceOptions.domain+e.url.substring(o+et.length)):e.url=e.url.replace(et,this.serviceOptions.domain)),(e.url.toLocaleLowerCase().includes(this.serviceOptions.domain.toLocaleLowerCase())||e.url.toLocaleLowerCase().includes(this.serviceOptions.staticAssetsDomain.toLocaleLowerCase()))&&null!=(o=this.authentication)&&o.signRequest(e),t.includes(it)&&(e.url=e.url.replace(it,this.styleOptions.language)),t.includes(nt)&&(e.url=this.styleOptions.view?e.url.replace(nt,this.styleOptions.view):e.url.replace(nt,"").replace("&".concat(rt,"="),""))},T.prototype._setAutoResize=function(t){t?(this.resizeObserver||(this.resizeObserver=new ResizeObserver(this._resizeCallback)),this.resizeObserver.observe(this.map.getContainer())):this.resizeObserver&&this.resizeObserver.unobserve(this.map.getContainer())},T.prototype._setStyleComponents=function(a,c){var l=this;void 0===c&&(c=!0),this.removed||this.styles.definitions().then(function(t){var e,o,n=!0;if(l.styleOptions.style)try{for(var r=Om(t.configurations),i=r.next();!i.done;i=r.next()){var s=i.value;if(l.styleOptions.style===s.name){n=!1;break}}}catch(t){e={error:t}}finally{try{i&&!i.done&&(o=r.return)&&o.call(r)}finally{if(e)throw e.error}}n&&(l.styleOptions.style=t.defaultConfiguration),l.styleOptions=a,l._rebuildStyle(c)})},T.prototype._updateGlobalDefaults=function(t){t&&(t.authOptions&&!ee&&fe(t.authOptions),t.domain&&!Kt&&ye(t.domain),t.styleDefinitionsPath&&!Yt&&me(t.styleDefinitionsPath),t.workerCount&&!$t&&ge(t.workerCount),t.maxParallelImageRequests&&!Xt&&ve(t.maxParallelImageRequests),!t.subscriptionKey&&!t["subscription-key"]||ee||be(t.subscriptionKey||t["subscription-key"]),!t.sessionId&&!t["session-id"]||te||_e(t.sessionId||t["session-id"]),t.language&&!Qt&&we(t.language),!t.userRegion&&!t.view||Vt||xe(t.userRegion||t.view))},T.prototype._generateSafeBounds=function(t){if(t){var e=S.getSouth(t),o=S.getWest(t),n=S.getNorth(t),r=S.getEast(t);if(!(isFinite(e)&&isFinite(o)&&isFinite(n)&&isFinite(r)))throw new Error("The bounds specified are invalid: [".concat(t,"]"));for(;r<o;)r+=360;return new S([o,e,r,n])}return t},T.prototype._detectHighContrast=function(){var t,e;switch(Rd.getHighContrastMode()){case"invert":case"light":t=T.Css.hcLight,e="high_contrast_light";break;case"dark":t=T.Css.hcDark,e="high_contrast_dark"}t&&this.map.getContainer().classList.add(t),e&&"road"===this.styleOptions.style&&(this.styleOptions.style=e)},T.Css={canvasContainer:"atlas-map-canvas-container",canvas:"atlas-map-canvas",container:"atlas-map",hcDark:"high-contrast-dark",hcLight:"high-contrast-light"},T);function T(t,e){var o,n,r=gm.call(this)||this;r.removed=!1,r.loaded=!1,r.ready=!1,r._resizeCallback=function(){return r.resize()},r._updateGlobalDefaults(e),r.serviceOptions=(new Xy).merge(e),r.styleOptions=(new Hy).merge(e),r.trafficOptions=new Ka,r.styles=new hm(r,r.serviceOptions),r.serviceOptions.authOptions.subscriptionKey&&(r.serviceOptions.authOptions.subscriptionKey=encodeURIComponent(r.serviceOptions.authOptions.subscriptionKey)),o=r.serviceOptions.authOptions.clientId||(r.serviceOptions.authOptions.subscriptionKey?r.serviceOptions.authOptions.subscriptionKey.replace(/.(?=.{3,}$)/g,"*"):"invalid-setting"),r.insights&&r.insights.setAuthenticatedUserContext(r.serviceOptions.sessionId,o),arguments[2]&&"ENVIRONMENT"in window&&window.ENVIRONMENT.hmr?(n=arguments[2],r.ready=!0,r.loaded=!0):(o={antialias:r.styleOptions.antialias,attributionControl:!1,container:t,fadeDuration:r.serviceOptions.fadeDuration,localIdeographFontFamily:r.serviceOptions.localIdeographFontFamily,preserveDrawingBuffer:r.styleOptions.preserveDrawingBuffer,refreshExpiredTiles:r.serviceOptions.refreshExpiredTiles,renderWorldCopies:r.styleOptions.renderWorldCopies,trackResize:!1,transformRequest:function(t,e){var o={url:t};return"Tile"===e||"Source"===e?(t.includes(ot)&&r.insights&&r.insights.trackEvent({name:"TileLoad"}),r._substituteDomainLanguageViewAndSignInRequest(t,o)):"Style"!==e&&"SpriteJSON"!==e&&"SpriteImage"!==e&&"Glyphs"!==e||r.styles._transformStyleRequest(t,o),r.serviceOptions.transformRequest&&Ba(o,r.serviceOptions.transformRequest(o.url,e)),o}},n=new D.Map(o));try{r.map=n,r.controls=new yf(r),r.events=new Of(r),r.imageSprite=new kf(r),r.layers=new Bf(r),r.markers=new Pf(r),r.sources=new Uf(r),r.popups=new Zf(r),r.indicators=new fm(r),r.map.getContainer().classList.add(T.Css.container),r.map.getCanvasContainer().classList.add(T.Css.canvasContainer),r.map.getCanvas().classList.add(T.Css.canvas),r._detectHighContrast(),r.copyrightControl=new Wd({showFeedbackLink:r.styleOptions.showFeedbackLink,showLogo:r.styleOptions.showLogo,customAttribution:r.styleOptions.customAttribution}),r.controls.add(r.copyrightControl,{position:u.ControlPosition.NonFixed}),r.logoControl=new Qd({showLogo:r.styleOptions.showLogo}),r.controls.add(r.logoControl,{position:u.ControlPosition.BottomLeft});var i=r.authentication?r.authentication.initialize():Promise.resolve();if(r.removed)return r;var s=function(){r.loaded=!0,r.map.off("load",s)},a=(r.map.on("load",s),function(){r.ready=!0,r.map.off("styledata",a),r.events.invoke("ready",{map:r,type:"ready"})});r.map.on("styledata",a),r._setAutoResize(r.styleOptions.autoResize),r.map.showTileBoundaries=r.styleOptions.showTileBoundaries,r.localizedStringsPromise=Ct.getStrings(r.styleOptions.language),i.then(function(){return r.styles.definitions()}).then(function(t){if(!r.removed){if(r.authentication&&!r.authentication.getToken())throw new Error("AuthenticationManager finished initializing, but no token is available");r.serviceOptions["enable-accessibility"]&&r.accessibleMapDelegate.addToMap(),r._setStyleComponents(r.styleOptions),r.copyrightDelegate&&r.copyrightDelegate.addToMap()}}).catch(function(t){t=t instanceof Error?t:new Error(t);r.events.invoke("error",{map:r,type:"error",error:t})}),r.setCamera(vm(vm({minZoom:1},e),{type:"jump",duration:0})),r.flowDelegate=new rf(r),r.accessibleMapDelegate=new nf(r),r.userInteractionDelegate=new hf(r,e),r.userInteractionDelegate.addToMap(),r.copyrightControl.setOptions({copyrightMessage:r.copyrightControl.getDefaultAttributions().join(", ")})}catch(t){throw t}return r}var Sm=window&&window.__read||function(t,e){var o="function"==typeof Symbol&&t[Symbol.iterator];if(!o)return t;var n,r,i=o.call(t),s=[];try{for(;(void 0===e||0<e--)&&!(n=i.next()).done;)s.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}return s},Cm=window&&window.__spreadArray||function(t,e,o){if(o||2===arguments.length)for(var n,r=0,i=e.length;r<i;r++)!n&&r in e||((n=n||Array.prototype.slice.call(e,0,r))[r]=e[r]);return t.concat(n||Array.prototype.slice.call(e))},ze=(z.applyTemplate=function(e,o){var n,r,t,i=this,s=document.createElement("div");return s.classList.add(z.Css.template),e&&("boolean"!=typeof(o=o||{}).singleDescription&&(o.singleDescription=!0),o.sandboxContent="boolean"!=typeof o.sandboxContent||o.sandboxContent,o.title&&"string"==typeof o.content&&(o.content.includes("{title}")||o.content.includes("{name}"))||(e.title?o.title="{title}":e.name&&(o.title="{name}")),"boolean"!=typeof o.detectHyperlinks&&(o.detectHyperlinks=!0),"boolean"!=typeof o.parsePropertyPaths&&(o.parsePropertyPaths=!0),o.textColor&&(s.style.color=o.textColor),o.fillColor&&(s.style.backgroundColor=o.fillColor),o.title&&((t=this._applyStringTemplate(e,o.title,o)).innerText=t.textContent||t.innerText||"",this._appendChild(s,t,z.Css.title)),(n=document.createElement("div")).classList.add(z.Css.content),Array.isArray(o.content)?0<o.content.length&&o.content[0].propertyPath?this._appendChild(n,this._generateContent(e,o.content,o),z.Css.item):o.content.forEach(function(t){i._appendChild(n,i._generateContent(e,t,o),z.Css.item)}):(r=0,t=void(e.description&&Object.keys(e).forEach(function(t){i._ignoreProperty(t,e[t])||r++})),1===r||o.singleDescription&&e.description||2===r&&e.Snippet?(t=document.createElement("div")).innerHTML=e.description:t=this._generateContent(e,o.content,o),this._appendChild(n,t,z.Css.item)),""!==n.innerHTML)&&(o.sandboxContent?s.appendChild(z._createSandboxedIframe(n,o)):s.appendChild(n)),s},z._createSandboxedIframe=function(t,e){var o=document.createElement("iframe"),t=(o.sandbox.add("allow-popups"),t.innerHTML),n=!1,r=100,i=550,s=10,a=(document.body.scrollWidth<=340&&(i=300,r=50),t.split(/<(tr|div|br|li|h[0-9]|p>)/)),c=Math.max.apply(Math,Cm([],Sm(a.map(function(t){return t.replace(/<[a-zA-Z0-9\s=\/]+>/g,"").length})),!1))-1,l=Math.ceil(3.5*c),c=(l<i&&(i=l,r=c),t.includes("<img")||t.includes("<video")?(n=!0,o.width="550px"):(l=-1<t.indexOf(z.Css.table)?25:20,s+=Math.max(.5*a.length*l,Math.ceil(t.replace(/<[a-zA-Z0-9\s=\/]+>/g,"").length/r)*l)),o.width=i+"px",o.height=n||280<s?"280px":s+"px",e.textColor?"color:".concat(e.textColor,";"):""),a=e.fillColor?"background-color:".concat(e.fillColor,";"):"",r='<html><head><title></title><meta charset="utf-8" /><meta http-equiv="x-ua-compatible" content="IE=Edge" />'+'<link rel="stylesheet" href="'.concat(z._cssUrl,'" type="text/css"/>')+"<style>html, body{margin:0;padding:0;".concat(c).concat(a,"}</style></head>")+'<body><div class="'.concat(z.Css.template,'" style="padding:0;width:').concat(i-20,'px">').concat(t,"</div></body></html>");return void 0===o.srcdoc?o.src="data:text/html;charset=utf-8,"+encodeURI(r):o.srcdoc=r,o},z._appendChild=function(t,e,o){e&&(o&&(e.className=(e.className?e.className+" ":"")+o),t.appendChild(e))},z._generateContent=function(t,e,o){return e?Array.isArray(e)?this._generatePropertyInfoTable(t,e,o):this._applyStringTemplate(t,e,o):(e=this._generateDynamicTableHtml(t,null,o))?((t=document.createElement("div")).innerHTML=e,t):null},z._applyStringTemplate=function(t,e,o){if(e){for(var n,r,i=e,s=this._placeholderRx.exec(e);s;)2<=s.length&&(n=this._getPropertyValue(t,s[1],o),i=i.replace(s[0],n)),s=this._placeholderRx.exec(e);if(i)return(i=i.trim()).includes("<")&&(i=i.replace(/[\r\n]+/g,"<br/>")),(r=document.createElement("div")).innerHTML=i,r}return null},z._getPropertyValue=function(t,e,o,n){var r=o.parsePropertyPaths?e.split("/"):[e],i=r.length;if(0<i&&t){var s=r[0],a=t[s];if(o.detectHyperlinks&&"link"===e&&(!n||n.hyperlinkFormat)){var c,l,u,p=[];if(Array.isArray(a)?a.forEach(function(t){t.href?p.push(t):"string"==typeof t&&p.push({href:t})}):a.href&&p.push(a),0<p.length)return n&&n.hyperlinkFormat?c=n.hyperlinkFormat:o&&o.hyperlinkFormat&&(c=o.hyperlinkFormat),l=c&&c.target?c.target:"_blank",u=[],p.forEach(function(t){t.title||c&&c.label||!t.rel||u.push(t.rel," - "),u.push('<a href="',t.href,'" target="',l,'">'),t.title?u.push(t.title):c&&c.label?u.push(c.label):u.push(t.href),u.push("</a>","<br/>")}),u.pop(),u.join("")}if(null!=a){for(var h=void 0,h=1;h<i&&(a=a[r[h]],s=r[h],null!=a);h++);if(h===i&&null!=a){t=void 0;if((t=void 0!==a.value?a.value:a)instanceof Date)return n&&n.dateFormat?t.toLocaleString(void 0,n.dateFormat):o.dateFormat?t.toLocaleString(void 0,o.dateFormat):t.toISOString();if("object"==typeof t)return(d=this._generateDynamicTableHtml(t,r.slice(1),o))||"";if("number"==typeof t){if(n){if(n.dateFormat)return new Date(t).toLocaleString(void 0,n.dateFormat);if(n.numberFormat)return t.toLocaleString(void 0,n.numberFormat)}else if(/(timestamp|date)/gi.test(s))return new Date(t).toISOString();return t.toLocaleString(void 0,o.numberFormat)}if("string"==typeof t&&""!==t&&!/[\n\r<>\s]/g.test(t)&&(o.detectHyperlinks||n&&n.hyperlinkFormat)){var d,t=t.trim(),e=this._isUrlRx.test(t)||n&&n.hyperlinkFormat,f=this._isImageUrlRx.test(t)&&(e||t.startsWith("data:image")),y=this._emailRx.test(t);if(e||f||y)return e=void 0,d=void(n&&n.hyperlinkFormat?e=n.hyperlinkFormat:o&&o.hyperlinkFormat&&(e=o.hyperlinkFormat)),d=e&&e.target?' target="'.concat(e.target,'"'):' target="_blank"',n="".concat(e&&e.label?e.label:t),e&&e.scheme?t=e.scheme+t:y&&(t="mailto:"+t),o=e&&e.label?' alt="'.concat(e.label,'"'):"",(e&&e.isImage||f)&&(n='<img src="'.concat(t,'" style="max-width:100%"').concat(o,'"/>')),'<a href="'.concat(t,'"').concat(d,">").concat(n,"</a>")}return t.toString()}}}return""},z._generatePropertyInfoTable=function(o,t,n){var r,i;return o&&t&&0<t.length?((r=[]).push('<table class="'.concat((i=this).Css.table,'">')),t.forEach(function(t){var e=i._getPropertyValue(o,t.propertyPath,n,t);t.hideLabel?r.push('<tr><td colspan="2">',e,"</td></tr>"):(t=t.label||t.propertyPath.split("/")[0],r.push("<tr><th>",t,"</th><td>",e,"</td></tr>"))}),r.push("</table>"),(t=document.createElement("div")).innerHTML=r.join(""),t):null},z._generateDynamicTableHtml=function(e,t,o){var n,r,i,s,a=this;return!e||((n=[]).push('<table class="'.concat((r=this).Css.table,'">')),i=t&&0<t.length?t.join("/")+"/":"",s=0,Object.keys(e).forEach(function(t){a._ignoreProperty(t,e[t])||(n.push("<tr><th>",t,"</th><td>",r._getPropertyValue(e,i+t,o),"</td></tr>"),s++)}),0===s)?null:(n.push("</table>"),n.join(""))},z._ignoreProperty=function(t,e){switch(t){case"title":case"name":case"base":case"popupTemplate":case"anchor":case"icon":case"image":case"imageUrl":case"rotation":case"color":case"size":case"offset":case"strokeColor":case"strokeWidth":case"strokeOpacity":case"subType":case"fillColor":case"fillOpacity":case"visibility":case"visible":return!0;default:if(0===t.indexOf("_")||null==e||""===e)return!0}return!1},z._placeholderRx=/\{([a-zA-Z0-9_\/\s]+)\}/gi,z._isUrlRx=/^(http|https|ftp|tel|mailto):\/\//i,z._isImageUrlRx=/(^data:image|.png$|.jpg$|.jpeg$|.gif$|.bmp$|.svg|.tif|.tiff$)/i,z._emailRx=/^[^\.\s@:](?:[^\s@:]*[^\s@:\.])?@[^\.\s@]+(?:\.[^\.\s@]+)*$/,z._cssUrl=new wt({domain:X,path:"sdk/javascript/mapcontrol/".concat(Mt.getEndpointVersion(),"/atlas.min.css")}).toString(),z.Css={template:"azure-maps-control-popup-template",title:"azure-maps-control-popup-template-title",content:"azure-maps-control-popup-template-content",item:"azure-maps-control-popup-template-content-item",table:"azure-maps-control-popup-template-table"},z);function z(){this.detectHyperlinks=!0,this.parsePropertyPaths=!0}u.HtmlMarker=Dd,u.Map=jn,u.Pixel=Hc,u.Popup=Ad,u.PopupTemplate=ze,u.Shape=x,u._enableRTLTextPlugin=function(){var t=new wt({domain:X,path:"sdk/javascript/mapcontrol/".concat(Mt.getEndpointVersion(),"/mapbox-gl-rtl-text.min.js")});D.setRTLTextPlugin(t.toString(),!0).catch(function(t){t&&console.warn(t)})},u._getAssetDomain=function(){return $},u._getDomain=function(){return Zt},u._hasMaxParallelImageRequests=ke,u._hasSetAuthenticationOptions=Se,u._hasSetDomain=Ce,u._hasSetLanguage=Ae,u._hasSetSessionId=Me,u._hasSetStyleDefinitionsPath=Pe,u._hasSetStyleDefinitionsVersion=function(){return Jt},u._hasSetView=Ee,u._hasWorkerCount=Le,u.addImageTemplate=function(t,e,o){!o&&Te[t.toLowerCase()]||(Te[t.toLowerCase()]=e)},u.addProtocol=function(t,e){D.addProtocol(t,e)},u.clearPrewarmedResources=function(){D.clearPrewarmedResources()},u.control=o,u.data=Kr,u.getAllImageTemplateNames=function(){return Object.keys(Te)},u.getAuthenticationOptions=oe,u.getDomain=re,u.getImageTemplate=Oe,u.getLanguage=ue,u.getMaxParallelImageRequests=le,u.getSessionId=pe,u.getStaticAssetsDomain=ne,u.getStyleAPIVersion=ae,u.getStyleDefinitionsPath=ie,u.getStyleDefinitionsVersion=se,u.getSubscriptionKey=he,u.getUserRegion=function(){return Bt},u.getVersion=function(){return Mt.getFullVersion()},u.getView=de,u.getWorkerCount=ce,u.internal=U,u.isSupported=function(t){return!Lt.isIE()},u.layer=xi,u.math=$n,u.prewarm=function(){D.prewarm()},u.removeProtocol=function(t){D.removeProtocol(t)},u.setAuthenticationOptions=fe,u.setDomain=ye,u.setLanguage=we,u.setMaxParallelImageRequests=ve,u.setSessionId=_e,u.setStyleAPIVersion=function(t){Wt=t},u.setStyleDefinitionsPath=me,u.setStyleDefinitionsVersion=function(t){Ut=t,Jt=!0},u.setSubscriptionKey=be,u.setUserRegion=xe,u.setView=function(t){Bt=t,Vt=!0},u.setWorkerCount=ge,u.source=Ao});
|