mirror of
https://github.com/maputnik/editor.git
synced 2026-07-16 10:57:38 +00:00
821 lines
3.2 MiB
Plaintext
821 lines
3.2 MiB
Plaintext
var i$=Object.defineProperty;var o$=(e,n,t)=>n in e?i$(e,n,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[n]=t;var nn=(e,n,t)=>(o$(e,typeof n!="symbol"?n+"":n,t),t);(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const o of i)if(o.type==="childList")for(const s of o.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&r(s)}).observe(document,{childList:!0,subtree:!0});function t(i){const o={};return i.integrity&&(o.integrity=i.integrity),i.referrerPolicy&&(o.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?o.credentials="include":i.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(i){if(i.ep)return;i.ep=!0;const o=t(i);fetch(i.href,o)}})();var mf=typeof globalThis<"u"?globalThis:typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{};function ga(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function fO(e){if(e.__esModule)return e;var n=e.default;if(typeof n=="function"){var t=function r(){return this instanceof r?Reflect.construct(n,arguments,this.constructor):n.apply(this,arguments)};t.prototype=n.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),t}var aF={exports:{}},k_={},sF={exports:{}},ya={};/*
|
||
object-assign
|
||
(c) Sindre Sorhus
|
||
@license MIT
|
||
*/var fk=Object.getOwnPropertySymbols,a$=Object.prototype.hasOwnProperty,s$=Object.prototype.propertyIsEnumerable;function l$(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function u$(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var n={},t=0;t<10;t++)n["_"+String.fromCharCode(t)]=t;var r=Object.getOwnPropertyNames(n).map(function(o){return n[o]});if(r.join("")!=="0123456789")return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach(function(o){i[o]=o}),Object.keys(Object.assign({},i)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}var lF=u$()?Object.assign:function(e,n){for(var t,r=l$(e),i,o=1;o<arguments.length;o++){t=Object(arguments[o]);for(var s in t)a$.call(t,s)&&(r[s]=t[s]);if(fk){i=fk(t);for(var a=0;a<i.length;a++)s$.call(t,i[a])&&(r[i[a]]=t[i[a]])}}return r};/** @license React v16.14.0
|
||
* react.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var pO=lF,fh=typeof Symbol=="function"&&Symbol.for,I_=fh?Symbol.for("react.element"):60103,A$=fh?Symbol.for("react.portal"):60106,c$=fh?Symbol.for("react.fragment"):60107,d$=fh?Symbol.for("react.strict_mode"):60108,h$=fh?Symbol.for("react.profiler"):60114,f$=fh?Symbol.for("react.provider"):60109,p$=fh?Symbol.for("react.context"):60110,m$=fh?Symbol.for("react.forward_ref"):60112,g$=fh?Symbol.for("react.suspense"):60113,y$=fh?Symbol.for("react.memo"):60115,v$=fh?Symbol.for("react.lazy"):60116,pk=typeof Symbol=="function"&&Symbol.iterator;function T_(e){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+e,t=1;t<arguments.length;t++)n+="&args[]="+encodeURIComponent(arguments[t]);return"Minified React error #"+e+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var uF={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},AF={};function Ty(e,n,t){this.props=e,this.context=n,this.refs=AF,this.updater=t||uF}Ty.prototype.isReactComponent={};Ty.prototype.setState=function(e,n){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error(T_(85));this.updater.enqueueSetState(this,e,n,"setState")};Ty.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function cF(){}cF.prototype=Ty.prototype;function mO(e,n,t){this.props=e,this.context=n,this.refs=AF,this.updater=t||uF}var gO=mO.prototype=new cF;gO.constructor=mO;pO(gO,Ty.prototype);gO.isPureReactComponent=!0;var yO={current:null},dF=Object.prototype.hasOwnProperty,hF={key:!0,ref:!0,__self:!0,__source:!0};function fF(e,n,t){var r,i={},o=null,s=null;if(n!=null)for(r in n.ref!==void 0&&(s=n.ref),n.key!==void 0&&(o=""+n.key),n)dF.call(n,r)&&!hF.hasOwnProperty(r)&&(i[r]=n[r]);var a=arguments.length-2;if(a===1)i.children=t;else if(1<a){for(var f=Array(a),g=0;g<a;g++)f[g]=arguments[g+2];i.children=f}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)i[r]===void 0&&(i[r]=a[r]);return{$$typeof:I_,type:e,key:o,ref:s,props:i,_owner:yO.current}}function C$(e,n){return{$$typeof:I_,type:e.type,key:n,ref:e.ref,props:e.props,_owner:e._owner}}function vO(e){return typeof e=="object"&&e!==null&&e.$$typeof===I_}function _$(e){var n={"=":"=0",":":"=2"};return"$"+(""+e).replace(/[=:]/g,function(t){return n[t]})}var pF=/\/+/g,O2=[];function mF(e,n,t,r){if(O2.length){var i=O2.pop();return i.result=e,i.keyPrefix=n,i.func=t,i.context=r,i.count=0,i}return{result:e,keyPrefix:n,func:t,context:r,count:0}}function gF(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,10>O2.length&&O2.push(e)}function _S(e,n,t,r){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(i){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case I_:case A$:o=!0}}if(o)return t(r,e,n===""?"."+Kw(e,0):n),1;if(o=0,n=n===""?".":n+":",Array.isArray(e))for(var s=0;s<e.length;s++){i=e[s];var a=n+Kw(i,s);o+=_S(i,a,t,r)}else if(e===null||typeof e!="object"?a=null:(a=pk&&e[pk]||e["@@iterator"],a=typeof a=="function"?a:null),typeof a=="function")for(e=a.call(e),s=0;!(i=e.next()).done;)i=i.value,a=n+Kw(i,s++),o+=_S(i,a,t,r);else if(i==="object")throw t=""+e,Error(T_(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t,""));return o}function bS(e,n,t){return e==null?0:_S(e,"",n,t)}function Kw(e,n){return typeof e=="object"&&e!==null&&e.key!=null?_$(e.key):n.toString(36)}function b$(e,n){e.func.call(e.context,n,e.count++)}function x$(e,n,t){var r=e.result,i=e.keyPrefix;e=e.func.call(e.context,n,e.count++),Array.isArray(e)?xS(e,r,t,function(o){return o}):e!=null&&(vO(e)&&(e=C$(e,i+(!e.key||n&&n.key===e.key?"":(""+e.key).replace(pF,"$&/")+"/")+t)),r.push(e))}function xS(e,n,t,r,i){var o="";t!=null&&(o=(""+t).replace(pF,"$&/")+"/"),n=mF(n,o,r,i),bS(e,x$,n),gF(n)}var yF={current:null};function Sp(){var e=yF.current;if(e===null)throw Error(T_(321));return e}var w$={ReactCurrentDispatcher:yF,ReactCurrentBatchConfig:{suspense:null},ReactCurrentOwner:yO,IsSomeRendererActing:{current:!1},assign:pO};ya.Children={map:function(e,n,t){if(e==null)return e;var r=[];return xS(e,r,null,n,t),r},forEach:function(e,n,t){if(e==null)return e;n=mF(null,null,n,t),bS(e,b$,n),gF(n)},count:function(e){return bS(e,function(){return null},null)},toArray:function(e){var n=[];return xS(e,n,null,function(t){return t}),n},only:function(e){if(!vO(e))throw Error(T_(143));return e}};ya.Component=Ty;ya.Fragment=c$;ya.Profiler=h$;ya.PureComponent=mO;ya.StrictMode=d$;ya.Suspense=g$;ya.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=w$;ya.cloneElement=function(e,n,t){if(e==null)throw Error(T_(267,e));var r=pO({},e.props),i=e.key,o=e.ref,s=e._owner;if(n!=null){if(n.ref!==void 0&&(o=n.ref,s=yO.current),n.key!==void 0&&(i=""+n.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(f in n)dF.call(n,f)&&!hF.hasOwnProperty(f)&&(r[f]=n[f]===void 0&&a!==void 0?a[f]:n[f])}var f=arguments.length-2;if(f===1)r.children=t;else if(1<f){a=Array(f);for(var g=0;g<f;g++)a[g]=arguments[g+2];r.children=a}return{$$typeof:I_,type:e.type,key:i,ref:o,props:r,_owner:s}};ya.createContext=function(e,n){return n===void 0&&(n=null),e={$$typeof:p$,_calculateChangedBits:n,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider={$$typeof:f$,_context:e},e.Consumer=e};ya.createElement=fF;ya.createFactory=function(e){var n=fF.bind(null,e);return n.type=e,n};ya.createRef=function(){return{current:null}};ya.forwardRef=function(e){return{$$typeof:m$,render:e}};ya.isValidElement=vO;ya.lazy=function(e){return{$$typeof:v$,_ctor:e,_status:-1,_result:null}};ya.memo=function(e,n){return{$$typeof:y$,type:e,compare:n===void 0?null:n}};ya.useCallback=function(e,n){return Sp().useCallback(e,n)};ya.useContext=function(e,n){return Sp().useContext(e,n)};ya.useDebugValue=function(){};ya.useEffect=function(e,n){return Sp().useEffect(e,n)};ya.useImperativeHandle=function(e,n,t){return Sp().useImperativeHandle(e,n,t)};ya.useLayoutEffect=function(e,n){return Sp().useLayoutEffect(e,n)};ya.useMemo=function(e,n){return Sp().useMemo(e,n)};ya.useReducer=function(e,n,t){return Sp().useReducer(e,n,t)};ya.useRef=function(e){return Sp().useRef(e)};ya.useState=function(e){return Sp().useState(e)};ya.version="16.14.0";sF.exports=ya;var kr=sF.exports;const bn=ga(kr);/** @license React v16.14.0
|
||
* react-jsx-runtime.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var M$=kr,vF=60103;k_.Fragment=60107;if(typeof Symbol=="function"&&Symbol.for){var mk=Symbol.for;vF=mk("react.element"),k_.Fragment=mk("react.fragment")}var S$=M$.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,E$=Object.prototype.hasOwnProperty,O$={key:!0,ref:!0,__self:!0,__source:!0};function CF(e,n,t){var r,i={},o=null,s=null;t!==void 0&&(o=""+t),n.key!==void 0&&(o=""+n.key),n.ref!==void 0&&(s=n.ref);for(r in n)E$.call(n,r)&&!O$.hasOwnProperty(r)&&(i[r]=n[r]);if(e&&e.defaultProps)for(r in n=e.defaultProps,n)i[r]===void 0&&(i[r]=n[r]);return{$$typeof:vF,type:e,key:o,ref:s,props:i,_owner:S$.current}}k_.jsx=CF;k_.jsxs=CF;aF.exports=k_;var N=aF.exports,_F={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},wS=bn.createContext&&bn.createContext(_F),gm=function(){return gm=Object.assign||function(e){for(var n,t=1,r=arguments.length;t<r;t++){n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},gm.apply(this,arguments)},B$=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)n.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(t[r[i]]=e[r[i]]);return t};function bF(e){return e&&e.map(function(n,t){return bn.createElement(n.tag,gm({key:t},n.attr),bF(n.child))})}function Ys(e){return function(n){return bn.createElement(k$,gm({attr:gm({},e.attr)},n),bF(e.child))}}function k$(e){var n=function(t){var r=e.attr,i=e.size,o=e.title,s=B$(e,["attr","size","title"]),a=i||t.size||"1em",f;return t.className&&(f=t.className),e.className&&(f=(f?f+" ":"")+e.className),bn.createElement("svg",gm({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,r,s,{className:f,style:gm(gm({color:e.color||t.color},t.style),e.style),height:a,width:a,xmlns:"http://www.w3.org/2000/svg"}),o&&bn.createElement("title",null,o),e.children)};return wS!==void 0?bn.createElement(wS.Consumer,null,function(t){return n(t)}):n(_F)}var xF={exports:{}},Od={},wF={exports:{}},MF={};/** @license React v0.19.1
|
||
* scheduler.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/(function(e){var n,t,r,i,o;if(typeof window>"u"||typeof MessageChannel!="function"){var s=null,a=null,f=function(){if(s!==null)try{var pt=e.unstable_now();s(!0,pt),s=null}catch(dt){throw setTimeout(f,0),dt}},g=Date.now();e.unstable_now=function(){return Date.now()-g},n=function(pt){s!==null?setTimeout(n,0,pt):(s=pt,setTimeout(f,0))},t=function(pt,dt){a=setTimeout(pt,dt)},r=function(){clearTimeout(a)},i=function(){return!1},o=e.unstable_forceFrameRate=function(){}}else{var x=window.performance,k=window.Date,B=window.setTimeout,P=window.clearTimeout;if(typeof console<"u"){var R=window.cancelAnimationFrame;typeof window.requestAnimationFrame!="function"&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://fb.me/react-polyfills"),typeof R!="function"&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://fb.me/react-polyfills")}if(typeof x=="object"&&typeof x.now=="function")e.unstable_now=function(){return x.now()};else{var H=k.now();e.unstable_now=function(){return k.now()-H}}var W=!1,$=null,q=-1,oe=5,ne=0;i=function(){return e.unstable_now()>=ne},o=function(){},e.unstable_forceFrameRate=function(pt){0>pt||125<pt?console.error("forceFrameRate takes a positive int between 0 and 125, forcing framerates higher than 125 fps is not unsupported"):oe=0<pt?Math.floor(1e3/pt):5};var ce=new MessageChannel,ae=ce.port2;ce.port1.onmessage=function(){if($!==null){var pt=e.unstable_now();ne=pt+oe;try{$(!0,pt)?ae.postMessage(null):(W=!1,$=null)}catch(dt){throw ae.postMessage(null),dt}}else W=!1},n=function(pt){$=pt,W||(W=!0,ae.postMessage(null))},t=function(pt,dt){q=B(function(){pt(e.unstable_now())},dt)},r=function(){P(q),q=-1}}function ue(pt,dt){var kt=pt.length;pt.push(dt);e:for(;;){var Dt=kt-1>>>1,Se=pt[Dt];if(Se!==void 0&&0<Ne(Se,dt))pt[Dt]=dt,pt[kt]=Se,kt=Dt;else break e}}function ye(pt){return pt=pt[0],pt===void 0?null:pt}function Re(pt){var dt=pt[0];if(dt!==void 0){var kt=pt.pop();if(kt!==dt){pt[0]=kt;e:for(var Dt=0,Se=pt.length;Dt<Se;){var de=2*(Dt+1)-1,xe=pt[de],Pe=de+1,Ze=pt[Pe];if(xe!==void 0&&0>Ne(xe,kt))Ze!==void 0&&0>Ne(Ze,xe)?(pt[Dt]=Ze,pt[Pe]=kt,Dt=Pe):(pt[Dt]=xe,pt[de]=kt,Dt=de);else if(Ze!==void 0&&0>Ne(Ze,kt))pt[Dt]=Ze,pt[Pe]=kt,Dt=Pe;else break e}}return dt}return null}function Ne(pt,dt){var kt=pt.sortIndex-dt.sortIndex;return kt!==0?kt:pt.id-dt.id}var rt=[],ct=[],Fe=1,He=null,Ce=3,jt=!1,Ft=!1,Jt=!1;function Nt(pt){for(var dt=ye(ct);dt!==null;){if(dt.callback===null)Re(ct);else if(dt.startTime<=pt)Re(ct),dt.sortIndex=dt.expirationTime,ue(rt,dt);else break;dt=ye(ct)}}function Ve(pt){if(Jt=!1,Nt(pt),!Ft)if(ye(rt)!==null)Ft=!0,n(nt);else{var dt=ye(ct);dt!==null&&t(Ve,dt.startTime-pt)}}function nt(pt,dt){Ft=!1,Jt&&(Jt=!1,r()),jt=!0;var kt=Ce;try{for(Nt(dt),He=ye(rt);He!==null&&(!(He.expirationTime>dt)||pt&&!i());){var Dt=He.callback;if(Dt!==null){He.callback=null,Ce=He.priorityLevel;var Se=Dt(He.expirationTime<=dt);dt=e.unstable_now(),typeof Se=="function"?He.callback=Se:He===ye(rt)&&Re(rt),Nt(dt)}else Re(rt);He=ye(rt)}if(He!==null)var de=!0;else{var xe=ye(ct);xe!==null&&t(Ve,xe.startTime-dt),de=!1}return de}finally{He=null,Ce=kt,jt=!1}}function Je(pt){switch(pt){case 1:return-1;case 2:return 250;case 5:return 1073741823;case 4:return 1e4;default:return 5e3}}var Vt=o;e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(pt){pt.callback=null},e.unstable_continueExecution=function(){Ft||jt||(Ft=!0,n(nt))},e.unstable_getCurrentPriorityLevel=function(){return Ce},e.unstable_getFirstCallbackNode=function(){return ye(rt)},e.unstable_next=function(pt){switch(Ce){case 1:case 2:case 3:var dt=3;break;default:dt=Ce}var kt=Ce;Ce=dt;try{return pt()}finally{Ce=kt}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=Vt,e.unstable_runWithPriority=function(pt,dt){switch(pt){case 1:case 2:case 3:case 4:case 5:break;default:pt=3}var kt=Ce;Ce=pt;try{return dt()}finally{Ce=kt}},e.unstable_scheduleCallback=function(pt,dt,kt){var Dt=e.unstable_now();if(typeof kt=="object"&&kt!==null){var Se=kt.delay;Se=typeof Se=="number"&&0<Se?Dt+Se:Dt,kt=typeof kt.timeout=="number"?kt.timeout:Je(pt)}else kt=Je(pt),Se=Dt;return kt=Se+kt,pt={id:Fe++,callback:dt,priorityLevel:pt,startTime:Se,expirationTime:kt,sortIndex:-1},Se>Dt?(pt.sortIndex=Se,ue(ct,pt),ye(rt)===null&&pt===ye(ct)&&(Jt?r():Jt=!0,t(Ve,Se-Dt))):(pt.sortIndex=kt,ue(rt,pt),Ft||jt||(Ft=!0,n(nt))),pt},e.unstable_shouldYield=function(){var pt=e.unstable_now();Nt(pt);var dt=ye(rt);return dt!==He&&He!==null&&dt!==null&&dt.callback!==null&&dt.startTime<=pt&&dt.expirationTime<He.expirationTime||i()},e.unstable_wrapCallback=function(pt){var dt=Ce;return function(){var kt=Ce;Ce=dt;try{return pt.apply(this,arguments)}finally{Ce=kt}}}})(MF);wF.exports=MF;var I$=wF.exports;/** @license React v16.14.0
|
||
* react-dom.production.min.js
|
||
*
|
||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
*
|
||
* This source code is licensed under the MIT license found in the
|
||
* LICENSE file in the root directory of this source tree.
|
||
*/var O4=kr,yA=lF,_u=I$;function Ln(e){for(var n="https://reactjs.org/docs/error-decoder.html?invariant="+e,t=1;t<arguments.length;t++)n+="&args[]="+encodeURIComponent(arguments[t]);return"Minified React error #"+e+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!O4)throw Error(Ln(227));function T$(e,n,t,r,i,o,s,a,f){var g=Array.prototype.slice.call(arguments,3);try{n.apply(t,g)}catch(x){this.onError(x)}}var yC=!1,B2=null,k2=!1,MS=null,K$={onError:function(e){yC=!0,B2=e}};function P$(e,n,t,r,i,o,s,a,f){yC=!1,B2=null,T$.apply(K$,arguments)}function F$(e,n,t,r,i,o,s,a,f){if(P$.apply(this,arguments),yC){if(yC){var g=B2;yC=!1,B2=null}else throw Error(Ln(198));k2||(k2=!0,MS=g)}}var CO=null,SF=null,EF=null;function gk(e,n,t){var r=e.type||"unknown-event";e.currentTarget=EF(t),F$(r,n,void 0,e),e.currentTarget=null}var I2=null,Og={};function OF(){if(I2)for(var e in Og){var n=Og[e],t=I2.indexOf(e);if(!(-1<t))throw Error(Ln(96,e));if(!T2[t]){if(!n.extractEvents)throw Error(Ln(97,e));T2[t]=n,t=n.eventTypes;for(var r in t){var i=void 0,o=t[r],s=n,a=r;if(SS.hasOwnProperty(a))throw Error(Ln(99,a));SS[a]=o;var f=o.phasedRegistrationNames;if(f){for(i in f)f.hasOwnProperty(i)&&yk(f[i],s,a);i=!0}else o.registrationName?(yk(o.registrationName,s,a),i=!0):i=!1;if(!i)throw Error(Ln(98,r,e))}}}}function yk(e,n,t){if(py[e])throw Error(Ln(100,e));py[e]=n,_O[e]=n.eventTypes[t].dependencies}var T2=[],SS={},py={},_O={};function BF(e){var n=!1,t;for(t in e)if(e.hasOwnProperty(t)){var r=e[t];if(!Og.hasOwnProperty(t)||Og[t]!==r){if(Og[t])throw Error(Ln(102,t));Og[t]=r,n=!0}}n&&OF()}var Um=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ES=null,Qg=null,$g=null;function vk(e){if(e=SF(e)){if(typeof ES!="function")throw Error(Ln(280));var n=e.stateNode;n&&(n=CO(n),ES(e.stateNode,e.type,n))}}function kF(e){Qg?$g?$g.push(e):$g=[e]:Qg=e}function IF(){if(Qg){var e=Qg,n=$g;if($g=Qg=null,vk(e),n)for(e=0;e<n.length;e++)vk(n[e])}}function bO(e,n){return e(n)}function TF(e,n,t,r,i){return e(n,t,r,i)}function xO(){}var KF=bO,D0=!1,Pw=!1;function wO(){(Qg!==null||$g!==null)&&(xO(),IF())}function PF(e,n,t){if(Pw)return e(n,t);Pw=!0;try{return KF(e,n,t)}finally{Pw=!1,wO()}}var D$=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Ck=Object.prototype.hasOwnProperty,_k={},bk={};function U$(e){return Ck.call(bk,e)?!0:Ck.call(_k,e)?!1:D$.test(e)?bk[e]=!0:(_k[e]=!0,!1)}function R$(e,n,t,r){if(t!==null&&t.type===0)return!1;switch(typeof n){case"function":case"symbol":return!0;case"boolean":return r?!1:t!==null?!t.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function L$(e,n,t,r){if(n===null||typeof n>"u"||R$(e,n,t,r))return!0;if(r)return!1;if(t!==null)switch(t.type){case 3:return!n;case 4:return n===!1;case 5:return isNaN(n);case 6:return isNaN(n)||1>n}return!1}function vA(e,n,t,r,i,o){this.acceptsBooleans=n===2||n===3||n===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=t,this.propertyName=e,this.type=n,this.sanitizeURL=o}var bu={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){bu[e]=new vA(e,0,!1,e,null,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var n=e[0];bu[n]=new vA(n,1,!1,e[1],null,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){bu[e]=new vA(e,2,!1,e.toLowerCase(),null,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){bu[e]=new vA(e,2,!1,e,null,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){bu[e]=new vA(e,3,!1,e.toLowerCase(),null,!1)});["checked","multiple","muted","selected"].forEach(function(e){bu[e]=new vA(e,3,!0,e,null,!1)});["capture","download"].forEach(function(e){bu[e]=new vA(e,4,!1,e,null,!1)});["cols","rows","size","span"].forEach(function(e){bu[e]=new vA(e,6,!1,e,null,!1)});["rowSpan","start"].forEach(function(e){bu[e]=new vA(e,5,!1,e.toLowerCase(),null,!1)});var MO=/[\-:]([a-z])/g;function SO(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var n=e.replace(MO,SO);bu[n]=new vA(n,1,!1,e,null,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var n=e.replace(MO,SO);bu[n]=new vA(n,1,!1,e,"http://www.w3.org/1999/xlink",!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var n=e.replace(MO,SO);bu[n]=new vA(n,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1)});["tabIndex","crossOrigin"].forEach(function(e){bu[e]=new vA(e,1,!1,e.toLowerCase(),null,!1)});bu.xlinkHref=new vA("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0);["src","href","action","formAction"].forEach(function(e){bu[e]=new vA(e,1,!1,e.toLowerCase(),null,!0)});var dh=O4.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;dh.hasOwnProperty("ReactCurrentDispatcher")||(dh.ReactCurrentDispatcher={current:null});dh.hasOwnProperty("ReactCurrentBatchConfig")||(dh.ReactCurrentBatchConfig={suspense:null});function EO(e,n,t,r){var i=bu.hasOwnProperty(n)?bu[n]:null,o=i!==null?i.type===0:r?!1:!(!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N");o||(L$(n,t,i,r)&&(t=null),r||i===null?U$(n)&&(t===null?e.removeAttribute(n):e.setAttribute(n,""+t)):i.mustUseProperty?e[i.propertyName]=t===null?i.type===3?!1:"":t:(n=i.attributeName,r=i.attributeNamespace,t===null?e.removeAttribute(n):(i=i.type,t=i===3||i===4&&t===!0?"":""+t,r?e.setAttributeNS(r,n,t):e.setAttribute(n,t))))}var z$=/^(.*)[\\\/]/,VA=typeof Symbol=="function"&&Symbol.for,rx=VA?Symbol.for("react.element"):60103,Bg=VA?Symbol.for("react.portal"):60106,k0=VA?Symbol.for("react.fragment"):60107,FF=VA?Symbol.for("react.strict_mode"):60108,Jx=VA?Symbol.for("react.profiler"):60114,DF=VA?Symbol.for("react.provider"):60109,UF=VA?Symbol.for("react.context"):60110,j$=VA?Symbol.for("react.concurrent_mode"):60111,OO=VA?Symbol.for("react.forward_ref"):60112,e2=VA?Symbol.for("react.suspense"):60113,OS=VA?Symbol.for("react.suspense_list"):60120,BO=VA?Symbol.for("react.memo"):60115,RF=VA?Symbol.for("react.lazy"):60116,LF=VA?Symbol.for("react.block"):60121,xk=typeof Symbol=="function"&&Symbol.iterator;function Kv(e){return e===null||typeof e!="object"?null:(e=xk&&e[xk]||e["@@iterator"],typeof e=="function"?e:null)}function W$(e){if(e._status===-1){e._status=0;var n=e._ctor;n=n(),e._result=n,n.then(function(t){e._status===0&&(t=t.default,e._status=1,e._result=t)},function(t){e._status===0&&(e._status=2,e._result=t)})}}function vp(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case k0:return"Fragment";case Bg:return"Portal";case Jx:return"Profiler";case FF:return"StrictMode";case e2:return"Suspense";case OS:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case UF:return"Context.Consumer";case DF:return"Context.Provider";case OO:var n=e.render;return n=n.displayName||n.name||"",e.displayName||(n!==""?"ForwardRef("+n+")":"ForwardRef");case BO:return vp(e.type);case LF:return vp(e.render);case RF:if(e=e._status===1?e._result:null)return vp(e)}return null}function kO(e){var n="";do{e:switch(e.tag){case 3:case 4:case 6:case 7:case 10:case 9:var t="";break e;default:var r=e._debugOwner,i=e._debugSource,o=vp(e.type);t=null,r&&(t=vp(r.type)),r=o,o="",i?o=" (at "+i.fileName.replace(z$,"")+":"+i.lineNumber+")":t&&(o=" (created by "+t+")"),t=`
|
||
in `+(r||"Unknown")+o}n+=t,e=e.return}while(e);return n}function Im(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function zF(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function N$(e){var n=zF(e)?"checked":"value",t=Object.getOwnPropertyDescriptor(e.constructor.prototype,n),r=""+e[n];if(!e.hasOwnProperty(n)&&typeof t<"u"&&typeof t.get=="function"&&typeof t.set=="function"){var i=t.get,o=t.set;return Object.defineProperty(e,n,{configurable:!0,get:function(){return i.call(this)},set:function(s){r=""+s,o.call(this,s)}}),Object.defineProperty(e,n,{enumerable:t.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[n]}}}}function ix(e){e._valueTracker||(e._valueTracker=N$(e))}function jF(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var t=n.getValue(),r="";return e&&(r=zF(e)?e.checked?"true":"false":e.value),e=r,e!==t?(n.setValue(e),!0):!1}function BS(e,n){var t=n.checked;return yA({},n,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:t??e._wrapperState.initialChecked})}function wk(e,n){var t=n.defaultValue==null?"":n.defaultValue,r=n.checked!=null?n.checked:n.defaultChecked;t=Im(n.value!=null?n.value:t),e._wrapperState={initialChecked:r,initialValue:t,controlled:n.type==="checkbox"||n.type==="radio"?n.checked!=null:n.value!=null}}function WF(e,n){n=n.checked,n!=null&&EO(e,"checked",n,!1)}function kS(e,n){WF(e,n);var t=Im(n.value),r=n.type;if(t!=null)r==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+t):e.value!==""+t&&(e.value=""+t);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}n.hasOwnProperty("value")?IS(e,n.type,t):n.hasOwnProperty("defaultValue")&&IS(e,n.type,Im(n.defaultValue)),n.checked==null&&n.defaultChecked!=null&&(e.defaultChecked=!!n.defaultChecked)}function Mk(e,n,t){if(n.hasOwnProperty("value")||n.hasOwnProperty("defaultValue")){var r=n.type;if(!(r!=="submit"&&r!=="reset"||n.value!==void 0&&n.value!==null))return;n=""+e._wrapperState.initialValue,t||n===e.value||(e.value=n),e.defaultValue=n}t=e.name,t!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,t!==""&&(e.name=t)}function IS(e,n,t){(n!=="number"||e.ownerDocument.activeElement!==e)&&(t==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+t&&(e.defaultValue=""+t))}function G$(e){var n="";return O4.Children.forEach(e,function(t){t!=null&&(n+=t)}),n}function TS(e,n){return e=yA({children:void 0},n),(n=G$(n.children))&&(e.children=n),e}function Yg(e,n,t,r){if(e=e.options,n){n={};for(var i=0;i<t.length;i++)n["$"+t[i]]=!0;for(t=0;t<e.length;t++)i=n.hasOwnProperty("$"+e[t].value),e[t].selected!==i&&(e[t].selected=i),i&&r&&(e[t].defaultSelected=!0)}else{for(t=""+Im(t),n=null,i=0;i<e.length;i++){if(e[i].value===t){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}n!==null||e[i].disabled||(n=e[i])}n!==null&&(n.selected=!0)}}function KS(e,n){if(n.dangerouslySetInnerHTML!=null)throw Error(Ln(91));return yA({},n,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Sk(e,n){var t=n.value;if(t==null){if(t=n.children,n=n.defaultValue,t!=null){if(n!=null)throw Error(Ln(92));if(Array.isArray(t)){if(!(1>=t.length))throw Error(Ln(93));t=t[0]}n=t}n==null&&(n=""),t=n}e._wrapperState={initialValue:Im(t)}}function NF(e,n){var t=Im(n.value),r=Im(n.defaultValue);t!=null&&(t=""+t,t!==e.value&&(e.value=t),n.defaultValue==null&&e.defaultValue!==t&&(e.defaultValue=t)),r!=null&&(e.defaultValue=""+r)}function Ek(e){var n=e.textContent;n===e._wrapperState.initialValue&&n!==""&&n!==null&&(e.value=n)}var GF={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function QF(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function PS(e,n){return e==null||e==="http://www.w3.org/1999/xhtml"?QF(n):e==="http://www.w3.org/2000/svg"&&n==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var ox,$F=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(n,t,r,i){MSApp.execUnsafeLocalFunction(function(){return e(n,t,r,i)})}:e}(function(e,n){if(e.namespaceURI!==GF.svg||"innerHTML"in e)e.innerHTML=n;else{for(ox=ox||document.createElement("div"),ox.innerHTML="<svg>"+n.valueOf().toString()+"</svg>",n=ox.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;n.firstChild;)e.appendChild(n.firstChild)}});function QC(e,n){if(n){var t=e.firstChild;if(t&&t===e.lastChild&&t.nodeType===3){t.nodeValue=n;return}}e.textContent=n}function ax(e,n){var t={};return t[e.toLowerCase()]=n.toLowerCase(),t["Webkit"+e]="webkit"+n,t["Moz"+e]="moz"+n,t}var kg={animationend:ax("Animation","AnimationEnd"),animationiteration:ax("Animation","AnimationIteration"),animationstart:ax("Animation","AnimationStart"),transitionend:ax("Transition","TransitionEnd")},Fw={},YF={};Um&&(YF=document.createElement("div").style,"AnimationEvent"in window||(delete kg.animationend.animation,delete kg.animationiteration.animation,delete kg.animationstart.animation),"TransitionEvent"in window||delete kg.transitionend.transition);function B4(e){if(Fw[e])return Fw[e];if(!kg[e])return e;var n=kg[e],t;for(t in n)if(n.hasOwnProperty(t)&&t in YF)return Fw[e]=n[t];return e}var qF=B4("animationend"),VF=B4("animationiteration"),HF=B4("animationstart"),ZF=B4("transitionend"),nC="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Ok=new(typeof WeakMap=="function"?WeakMap:Map);function IO(e){var n=Ok.get(e);return n===void 0&&(n=new Map,Ok.set(e,n)),n}function y1(e){var n=e,t=e;if(e.alternate)for(;n.return;)n=n.return;else{e=n;do n=e,n.effectTag&1026&&(t=n.return),e=n.return;while(e)}return n.tag===3?t:null}function XF(e){if(e.tag===13){var n=e.memoizedState;if(n===null&&(e=e.alternate,e!==null&&(n=e.memoizedState)),n!==null)return n.dehydrated}return null}function Bk(e){if(y1(e)!==e)throw Error(Ln(188))}function Q$(e){var n=e.alternate;if(!n){if(n=y1(e),n===null)throw Error(Ln(188));return n!==e?null:e}for(var t=e,r=n;;){var i=t.return;if(i===null)break;var o=i.alternate;if(o===null){if(r=i.return,r!==null){t=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===t)return Bk(i),e;if(o===r)return Bk(i),n;o=o.sibling}throw Error(Ln(188))}if(t.return!==r.return)t=i,r=o;else{for(var s=!1,a=i.child;a;){if(a===t){s=!0,t=i,r=o;break}if(a===r){s=!0,r=i,t=o;break}a=a.sibling}if(!s){for(a=o.child;a;){if(a===t){s=!0,t=o,r=i;break}if(a===r){s=!0,r=o,t=i;break}a=a.sibling}if(!s)throw Error(Ln(189))}}if(t.alternate!==r)throw Error(Ln(190))}if(t.tag!==3)throw Error(Ln(188));return t.stateNode.current===t?e:n}function JF(e){if(e=Q$(e),!e)return null;for(var n=e;;){if(n.tag===5||n.tag===6)return n;if(n.child)n.child.return=n,n=n.child;else{if(n===e)break;for(;!n.sibling;){if(!n.return||n.return===e)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}}return null}function my(e,n){if(n==null)throw Error(Ln(30));return e==null?n:Array.isArray(e)?Array.isArray(n)?(e.push.apply(e,n),e):(e.push(n),e):Array.isArray(n)?[e].concat(n):[e,n]}function TO(e,n,t){Array.isArray(e)?e.forEach(n,t):e&&n.call(t,e)}var Pv=null;function $$(e){if(e){var n=e._dispatchListeners,t=e._dispatchInstances;if(Array.isArray(n))for(var r=0;r<n.length&&!e.isPropagationStopped();r++)gk(e,n[r],t[r]);else n&&gk(e,n,t);e._dispatchListeners=null,e._dispatchInstances=null,e.isPersistent()||e.constructor.release(e)}}function k4(e){if(e!==null&&(Pv=my(Pv,e)),e=Pv,Pv=null,e){if(TO(e,$$),Pv)throw Error(Ln(95));if(k2)throw e=MS,k2=!1,MS=null,e}}function KO(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}function eD(e){if(!Um)return!1;e="on"+e;var n=e in document;return n||(n=document.createElement("div"),n.setAttribute(e,"return;"),n=typeof n[e]=="function"),n}var K2=[];function tD(e){e.topLevelType=null,e.nativeEvent=null,e.targetInst=null,e.ancestors.length=0,10>K2.length&&K2.push(e)}function nD(e,n,t,r){if(K2.length){var i=K2.pop();return i.topLevelType=e,i.eventSystemFlags=r,i.nativeEvent=n,i.targetInst=t,i}return{topLevelType:e,eventSystemFlags:r,nativeEvent:n,targetInst:t,ancestors:[]}}function rD(e){var n=e.targetInst,t=n;do{if(!t){e.ancestors.push(t);break}var r=t;if(r.tag===3)r=r.stateNode.containerInfo;else{for(;r.return;)r=r.return;r=r.tag!==3?null:r.stateNode.containerInfo}if(!r)break;n=t.tag,n!==5&&n!==6||e.ancestors.push(t),t=P_(r)}while(t);for(t=0;t<e.ancestors.length;t++){n=e.ancestors[t];var i=KO(e.nativeEvent);r=e.topLevelType;var o=e.nativeEvent,s=e.eventSystemFlags;t===0&&(s|=64);for(var a=null,f=0;f<T2.length;f++){var g=T2[f];g&&(g=g.extractEvents(r,n,o,i,s))&&(a=my(a,g))}k4(a)}}function FS(e,n,t){if(!t.has(e)){switch(e){case"scroll":rC(n,"scroll",!0);break;case"focus":case"blur":rC(n,"focus",!0),rC(n,"blur",!0),t.set("blur",null),t.set("focus",null);break;case"cancel":case"close":eD(e)&&rC(n,e,!0);break;case"invalid":case"submit":case"reset":break;default:nC.indexOf(e)===-1&&Ks(e,n)}t.set(e,null)}}var iD,PO,oD,DS=!1,Xh=[],ym=null,vm=null,Cm=null,$C=new Map,YC=new Map,Fv=[],US="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput close cancel copy cut paste click change contextmenu reset submit".split(" "),Y$="focus blur dragenter dragleave mouseover mouseout pointerover pointerout gotpointercapture lostpointercapture".split(" ");function q$(e,n){var t=IO(n);US.forEach(function(r){FS(r,n,t)}),Y$.forEach(function(r){FS(r,n,t)})}function RS(e,n,t,r,i){return{blockedOn:e,topLevelType:n,eventSystemFlags:t|32,nativeEvent:i,container:r}}function kk(e,n){switch(e){case"focus":case"blur":ym=null;break;case"dragenter":case"dragleave":vm=null;break;case"mouseover":case"mouseout":Cm=null;break;case"pointerover":case"pointerout":$C.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":YC.delete(n.pointerId)}}function Dv(e,n,t,r,i,o){return e===null||e.nativeEvent!==o?(e=RS(n,t,r,i,o),n!==null&&(n=F_(n),n!==null&&PO(n)),e):(e.eventSystemFlags|=r,e)}function V$(e,n,t,r,i){switch(n){case"focus":return ym=Dv(ym,e,n,t,r,i),!0;case"dragenter":return vm=Dv(vm,e,n,t,r,i),!0;case"mouseover":return Cm=Dv(Cm,e,n,t,r,i),!0;case"pointerover":var o=i.pointerId;return $C.set(o,Dv($C.get(o)||null,e,n,t,r,i)),!0;case"gotpointercapture":return o=i.pointerId,YC.set(o,Dv(YC.get(o)||null,e,n,t,r,i)),!0}return!1}function H$(e){var n=P_(e.target);if(n!==null){var t=y1(n);if(t!==null){if(n=t.tag,n===13){if(n=XF(t),n!==null){e.blockedOn=n,_u.unstable_runWithPriority(e.priority,function(){oD(t)});return}}else if(n===3&&t.stateNode.hydrate){e.blockedOn=t.tag===3?t.stateNode.containerInfo:null;return}}}e.blockedOn=null}function t2(e){if(e.blockedOn!==null)return!1;var n=UO(e.topLevelType,e.eventSystemFlags,e.container,e.nativeEvent);if(n!==null){var t=F_(n);return t!==null&&PO(t),e.blockedOn=n,!1}return!0}function Ik(e,n,t){t2(e)&&t.delete(n)}function Z$(){for(DS=!1;0<Xh.length;){var e=Xh[0];if(e.blockedOn!==null){e=F_(e.blockedOn),e!==null&&iD(e);break}var n=UO(e.topLevelType,e.eventSystemFlags,e.container,e.nativeEvent);n!==null?e.blockedOn=n:Xh.shift()}ym!==null&&t2(ym)&&(ym=null),vm!==null&&t2(vm)&&(vm=null),Cm!==null&&t2(Cm)&&(Cm=null),$C.forEach(Ik),YC.forEach(Ik)}function Uv(e,n){e.blockedOn===n&&(e.blockedOn=null,DS||(DS=!0,_u.unstable_scheduleCallback(_u.unstable_NormalPriority,Z$)))}function aD(e){function n(i){return Uv(i,e)}if(0<Xh.length){Uv(Xh[0],e);for(var t=1;t<Xh.length;t++){var r=Xh[t];r.blockedOn===e&&(r.blockedOn=null)}}for(ym!==null&&Uv(ym,e),vm!==null&&Uv(vm,e),Cm!==null&&Uv(Cm,e),$C.forEach(n),YC.forEach(n),t=0;t<Fv.length;t++)r=Fv[t],r.blockedOn===e&&(r.blockedOn=null);for(;0<Fv.length&&(t=Fv[0],t.blockedOn===null);)H$(t),t.blockedOn===null&&Fv.shift()}var sD={},lD=new Map,FO=new Map,X$=["abort","abort",qF,"animationEnd",VF,"animationIteration",HF,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",ZF,"transitionEnd","waiting","waiting"];function DO(e,n){for(var t=0;t<e.length;t+=2){var r=e[t],i=e[t+1],o="on"+(i[0].toUpperCase()+i.slice(1));o={phasedRegistrationNames:{bubbled:o,captured:o+"Capture"},dependencies:[r],eventPriority:n},FO.set(r,n),lD.set(r,o),sD[i]=o}}DO("blur blur cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focus focus input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0);DO("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1);DO(X$,2);for(var Tk="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),Dw=0;Dw<Tk.length;Dw++)FO.set(Tk[Dw],0);var J$=_u.unstable_UserBlockingPriority,eY=_u.unstable_runWithPriority,n2=!0;function Ks(e,n){rC(n,e,!1)}function rC(e,n,t){var r=FO.get(n);switch(r===void 0?2:r){case 0:r=tY.bind(null,n,1,e);break;case 1:r=nY.bind(null,n,1,e);break;default:r=I4.bind(null,n,1,e)}t?e.addEventListener(n,r,!0):e.addEventListener(n,r,!1)}function tY(e,n,t,r){D0||xO();var i=I4,o=D0;D0=!0;try{TF(i,e,n,t,r)}finally{(D0=o)||wO()}}function nY(e,n,t,r){eY(J$,I4.bind(null,e,n,t,r))}function I4(e,n,t,r){if(n2)if(0<Xh.length&&-1<US.indexOf(e))e=RS(null,e,n,t,r),Xh.push(e);else{var i=UO(e,n,t,r);if(i===null)kk(e,r);else if(-1<US.indexOf(e))e=RS(i,e,n,t,r),Xh.push(e);else if(!V$(i,e,n,t,r)){kk(e,r),e=nD(e,r,null,n);try{PF(rD,e)}finally{tD(e)}}}}function UO(e,n,t,r){if(t=KO(r),t=P_(t),t!==null){var i=y1(t);if(i===null)t=null;else{var o=i.tag;if(o===13){if(t=XF(i),t!==null)return t;t=null}else if(o===3){if(i.stateNode.hydrate)return i.tag===3?i.stateNode.containerInfo:null;t=null}else i!==t&&(t=null)}}e=nD(e,r,t,n);try{PF(rD,e)}finally{tD(e)}return null}var vC={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},rY=["Webkit","ms","Moz","O"];Object.keys(vC).forEach(function(e){rY.forEach(function(n){n=n+e.charAt(0).toUpperCase()+e.substring(1),vC[n]=vC[e]})});function uD(e,n,t){return n==null||typeof n=="boolean"||n===""?"":t||typeof n!="number"||n===0||vC.hasOwnProperty(e)&&vC[e]?(""+n).trim():n+"px"}function AD(e,n){e=e.style;for(var t in n)if(n.hasOwnProperty(t)){var r=t.indexOf("--")===0,i=uD(t,n[t],r);t==="float"&&(t="cssFloat"),r?e.setProperty(t,i):e[t]=i}}var iY=yA({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function LS(e,n){if(n){if(iY[e]&&(n.children!=null||n.dangerouslySetInnerHTML!=null))throw Error(Ln(137,e,""));if(n.dangerouslySetInnerHTML!=null){if(n.children!=null)throw Error(Ln(60));if(!(typeof n.dangerouslySetInnerHTML=="object"&&"__html"in n.dangerouslySetInnerHTML))throw Error(Ln(61))}if(n.style!=null&&typeof n.style!="object")throw Error(Ln(62,""))}}function zS(e,n){if(e.indexOf("-")===-1)return typeof n.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Kk=GF.html;function tp(e,n){e=e.nodeType===9||e.nodeType===11?e:e.ownerDocument;var t=IO(e);n=_O[n];for(var r=0;r<n.length;r++)FS(n[r],e,t)}function P2(){}function jS(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Pk(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Fk(e,n){var t=Pk(e);e=0;for(var r;t;){if(t.nodeType===3){if(r=e+t.textContent.length,e<=n&&r>=n)return{node:t,offset:n-e};e=r}e:{for(;t;){if(t.nextSibling){t=t.nextSibling;break e}t=t.parentNode}t=void 0}t=Pk(t)}}function cD(e,n){return e&&n?e===n?!0:e&&e.nodeType===3?!1:n&&n.nodeType===3?cD(e,n.parentNode):"contains"in e?e.contains(n):e.compareDocumentPosition?!!(e.compareDocumentPosition(n)&16):!1:!1}function Dk(){for(var e=window,n=jS();n instanceof e.HTMLIFrameElement;){try{var t=typeof n.contentWindow.location.href=="string"}catch{t=!1}if(t)e=n.contentWindow;else break;n=jS(e.document)}return n}function WS(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n&&(n==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||n==="textarea"||e.contentEditable==="true")}var dD="$",hD="/$",RO="$?",LO="$!",Uw=null,Rw=null;function fD(e,n){switch(e){case"button":case"input":case"select":case"textarea":return!!n.autoFocus}return!1}function NS(e,n){return e==="textarea"||e==="option"||e==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var Lw=typeof setTimeout=="function"?setTimeout:void 0,oY=typeof clearTimeout=="function"?clearTimeout:void 0;function qg(e){for(;e!=null;e=e.nextSibling){var n=e.nodeType;if(n===1||n===3)break}return e}function Uk(e){e=e.previousSibling;for(var n=0;e;){if(e.nodeType===8){var t=e.data;if(t===dD||t===LO||t===RO){if(n===0)return e;n--}else t===hD&&n++}e=e.previousSibling}return null}var zO=Math.random().toString(36).slice(2),am="__reactInternalInstance$"+zO,F2="__reactEventHandlers$"+zO,K_="__reactContainere$"+zO;function P_(e){var n=e[am];if(n)return n;for(var t=e.parentNode;t;){if(n=t[K_]||t[am]){if(t=n.alternate,n.child!==null||t!==null&&t.child!==null)for(e=Uk(e);e!==null;){if(t=e[am])return t;e=Uk(e)}return n}e=t,t=e.parentNode}return null}function F_(e){return e=e[am]||e[K_],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function i1(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(Ln(33))}function jO(e){return e[F2]||null}function np(e){do e=e.return;while(e&&e.tag!==5);return e||null}function pD(e,n){var t=e.stateNode;if(!t)return null;var r=CO(t);if(!r)return null;t=r[n];e:switch(n){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(t&&typeof t!="function")throw Error(Ln(231,n,typeof t));return t}function Rk(e,n,t){(n=pD(e,t.dispatchConfig.phasedRegistrationNames[n]))&&(t._dispatchListeners=my(t._dispatchListeners,n),t._dispatchInstances=my(t._dispatchInstances,e))}function aY(e){if(e&&e.dispatchConfig.phasedRegistrationNames){for(var n=e._targetInst,t=[];n;)t.push(n),n=np(n);for(n=t.length;0<n--;)Rk(t[n],"captured",e);for(n=0;n<t.length;n++)Rk(t[n],"bubbled",e)}}function GS(e,n,t){e&&t&&t.dispatchConfig.registrationName&&(n=pD(e,t.dispatchConfig.registrationName))&&(t._dispatchListeners=my(t._dispatchListeners,n),t._dispatchInstances=my(t._dispatchInstances,e))}function sY(e){e&&e.dispatchConfig.registrationName&&GS(e._targetInst,null,e)}function gy(e){TO(e,aY)}var sm=null,WO=null,r2=null;function mD(){if(r2)return r2;var e,n=WO,t=n.length,r,i="value"in sm?sm.value:sm.textContent,o=i.length;for(e=0;e<t&&n[e]===i[e];e++);var s=t-e;for(r=1;r<=s&&n[t-r]===i[o-r];r++);return r2=i.slice(e,1<r?1-r:void 0)}function i2(){return!0}function D2(){return!1}function Wc(e,n,t,r){this.dispatchConfig=e,this._targetInst=n,this.nativeEvent=t,e=this.constructor.Interface;for(var i in e)e.hasOwnProperty(i)&&((n=e[i])?this[i]=n(t):i==="target"?this.target=r:this[i]=t[i]);return this.isDefaultPrevented=(t.defaultPrevented!=null?t.defaultPrevented:t.returnValue===!1)?i2:D2,this.isPropagationStopped=D2,this}yA(Wc.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!="unknown"&&(e.returnValue=!1),this.isDefaultPrevented=i2)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!="unknown"&&(e.cancelBubble=!0),this.isPropagationStopped=i2)},persist:function(){this.isPersistent=i2},isPersistent:D2,destructor:function(){var e=this.constructor.Interface,n;for(n in e)this[n]=null;this.nativeEvent=this._targetInst=this.dispatchConfig=null,this.isPropagationStopped=this.isDefaultPrevented=D2,this._dispatchInstances=this._dispatchListeners=null}});Wc.Interface={type:null,target:null,currentTarget:function(){return null},eventPhase:null,bubbles:null,cancelable:null,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:null,isTrusted:null};Wc.extend=function(e){function n(){}function t(){return r.apply(this,arguments)}var r=this;n.prototype=r.prototype;var i=new n;return yA(i,t.prototype),t.prototype=i,t.prototype.constructor=t,t.Interface=yA({},r.Interface,e),t.extend=r.extend,gD(t),t};gD(Wc);function lY(e,n,t,r){if(this.eventPool.length){var i=this.eventPool.pop();return this.call(i,e,n,t,r),i}return new this(e,n,t,r)}function uY(e){if(!(e instanceof this))throw Error(Ln(279));e.destructor(),10>this.eventPool.length&&this.eventPool.push(e)}function gD(e){e.eventPool=[],e.getPooled=lY,e.release=uY}var AY=Wc.extend({data:null}),cY=Wc.extend({data:null}),dY=[9,13,27,32],NO=Um&&"CompositionEvent"in window,CC=null;Um&&"documentMode"in document&&(CC=document.documentMode);var hY=Um&&"TextEvent"in window&&!CC,yD=Um&&(!NO||CC&&8<CC&&11>=CC),Lk=" ",Vf={beforeInput:{phasedRegistrationNames:{bubbled:"onBeforeInput",captured:"onBeforeInputCapture"},dependencies:["compositionend","keypress","textInput","paste"]},compositionEnd:{phasedRegistrationNames:{bubbled:"onCompositionEnd",captured:"onCompositionEndCapture"},dependencies:"blur compositionend keydown keypress keyup mousedown".split(" ")},compositionStart:{phasedRegistrationNames:{bubbled:"onCompositionStart",captured:"onCompositionStartCapture"},dependencies:"blur compositionstart keydown keypress keyup mousedown".split(" ")},compositionUpdate:{phasedRegistrationNames:{bubbled:"onCompositionUpdate",captured:"onCompositionUpdateCapture"},dependencies:"blur compositionupdate keydown keypress keyup mousedown".split(" ")}},zk=!1;function vD(e,n){switch(e){case"keyup":return dY.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"blur":return!0;default:return!1}}function CD(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ig=!1;function fY(e,n){switch(e){case"compositionend":return CD(n);case"keypress":return n.which!==32?null:(zk=!0,Lk);case"textInput":return e=n.data,e===Lk&&zk?null:e;default:return null}}function pY(e,n){if(Ig)return e==="compositionend"||!NO&&vD(e,n)?(e=mD(),r2=WO=sm=null,Ig=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return yD&&n.locale!=="ko"?null:n.data;default:return null}}var mY={eventTypes:Vf,extractEvents:function(e,n,t,r){var i;if(NO)e:{switch(e){case"compositionstart":var o=Vf.compositionStart;break e;case"compositionend":o=Vf.compositionEnd;break e;case"compositionupdate":o=Vf.compositionUpdate;break e}o=void 0}else Ig?vD(e,t)&&(o=Vf.compositionEnd):e==="keydown"&&t.keyCode===229&&(o=Vf.compositionStart);return o?(yD&&t.locale!=="ko"&&(Ig||o!==Vf.compositionStart?o===Vf.compositionEnd&&Ig&&(i=mD()):(sm=r,WO="value"in sm?sm.value:sm.textContent,Ig=!0)),o=AY.getPooled(o,n,t,r),i?o.data=i:(i=CD(t),i!==null&&(o.data=i)),gy(o),i=o):i=null,(e=hY?fY(e,t):pY(e,t))?(n=cY.getPooled(Vf.beforeInput,n,t,r),n.data=e,gy(n)):n=null,i===null?n:n===null?i:[i,n]}},gY={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function _D(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n==="input"?!!gY[e.type]:n==="textarea"}var bD={change:{phasedRegistrationNames:{bubbled:"onChange",captured:"onChangeCapture"},dependencies:"blur change click focus input keydown keyup selectionchange".split(" ")}};function xD(e,n,t){return e=Wc.getPooled(bD.change,e,n,t),e.type="change",kF(t),gy(e),e}var _C=null,qC=null;function yY(e){k4(e)}function T4(e){var n=i1(e);if(jF(n))return e}function vY(e,n){if(e==="change")return n}var QS=!1;Um&&(QS=eD("input")&&(!document.documentMode||9<document.documentMode));function jk(){_C&&(_C.detachEvent("onpropertychange",wD),qC=_C=null)}function wD(e){if(e.propertyName==="value"&&T4(qC))if(e=xD(qC,e,KO(e)),D0)k4(e);else{D0=!0;try{bO(yY,e)}finally{D0=!1,wO()}}}function CY(e,n,t){e==="focus"?(jk(),_C=n,qC=t,_C.attachEvent("onpropertychange",wD)):e==="blur"&&jk()}function _Y(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return T4(qC)}function bY(e,n){if(e==="click")return T4(n)}function xY(e,n){if(e==="input"||e==="change")return T4(n)}var wY={eventTypes:bD,_isInputEventSupported:QS,extractEvents:function(e,n,t,r){var i=n?i1(n):window,o=i.nodeName&&i.nodeName.toLowerCase();if(o==="select"||o==="input"&&i.type==="file")var s=vY;else if(_D(i))if(QS)s=xY;else{s=_Y;var a=CY}else(o=i.nodeName)&&o.toLowerCase()==="input"&&(i.type==="checkbox"||i.type==="radio")&&(s=bY);if(s&&(s=s(e,n)))return xD(s,t,r);a&&a(e,i,n),e==="blur"&&(e=i._wrapperState)&&e.controlled&&i.type==="number"&&IS(i,"number",i.value)}},D_=Wc.extend({view:null,detail:null}),MY={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function SY(e){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(e):(e=MY[e])?!!n[e]:!1}function GO(){return SY}var Wk=0,Nk=0,Gk=!1,Qk=!1,U_=D_.extend({screenX:null,screenY:null,clientX:null,clientY:null,pageX:null,pageY:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,getModifierState:GO,button:null,buttons:null,relatedTarget:function(e){return e.relatedTarget||(e.fromElement===e.srcElement?e.toElement:e.fromElement)},movementX:function(e){if("movementX"in e)return e.movementX;var n=Wk;return Wk=e.screenX,Gk?e.type==="mousemove"?e.screenX-n:0:(Gk=!0,0)},movementY:function(e){if("movementY"in e)return e.movementY;var n=Nk;return Nk=e.screenY,Qk?e.type==="mousemove"?e.screenY-n:0:(Qk=!0,0)}}),MD=U_.extend({pointerId:null,width:null,height:null,pressure:null,tangentialPressure:null,tiltX:null,tiltY:null,twist:null,pointerType:null,isPrimary:null}),Rv={mouseEnter:{registrationName:"onMouseEnter",dependencies:["mouseout","mouseover"]},mouseLeave:{registrationName:"onMouseLeave",dependencies:["mouseout","mouseover"]},pointerEnter:{registrationName:"onPointerEnter",dependencies:["pointerout","pointerover"]},pointerLeave:{registrationName:"onPointerLeave",dependencies:["pointerout","pointerover"]}},EY={eventTypes:Rv,extractEvents:function(e,n,t,r,i){var o=e==="mouseover"||e==="pointerover",s=e==="mouseout"||e==="pointerout";if(o&&!(i&32)&&(t.relatedTarget||t.fromElement)||!s&&!o)return null;if(o=r.window===r?r:(o=r.ownerDocument)?o.defaultView||o.parentWindow:window,s){if(s=n,n=(n=t.relatedTarget||t.toElement)?P_(n):null,n!==null){var a=y1(n);(n!==a||n.tag!==5&&n.tag!==6)&&(n=null)}}else s=null;if(s===n)return null;if(e==="mouseout"||e==="mouseover")var f=U_,g=Rv.mouseLeave,x=Rv.mouseEnter,k="mouse";else(e==="pointerout"||e==="pointerover")&&(f=MD,g=Rv.pointerLeave,x=Rv.pointerEnter,k="pointer");if(e=s==null?o:i1(s),o=n==null?o:i1(n),g=f.getPooled(g,s,t,r),g.type=k+"leave",g.target=e,g.relatedTarget=o,t=f.getPooled(x,n,t,r),t.type=k+"enter",t.target=o,t.relatedTarget=e,r=s,k=n,r&&k)e:{for(f=r,x=k,s=0,e=f;e;e=np(e))s++;for(e=0,n=x;n;n=np(n))e++;for(;0<s-e;)f=np(f),s--;for(;0<e-s;)x=np(x),e--;for(;s--;){if(f===x||f===x.alternate)break e;f=np(f),x=np(x)}f=null}else f=null;for(x=f,f=[];r&&r!==x&&(s=r.alternate,!(s!==null&&s===x));)f.push(r),r=np(r);for(r=[];k&&k!==x&&(s=k.alternate,!(s!==null&&s===x));)r.push(k),k=np(k);for(k=0;k<f.length;k++)GS(f[k],"bubbled",g);for(k=r.length;0<k--;)GS(r[k],"captured",t);return i&64?[g,t]:[g]}};function OY(e,n){return e===n&&(e!==0||1/e===1/n)||e!==e&&n!==n}var o1=typeof Object.is=="function"?Object.is:OY,BY=Object.prototype.hasOwnProperty;function VC(e,n){if(o1(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;var t=Object.keys(e),r=Object.keys(n);if(t.length!==r.length)return!1;for(r=0;r<t.length;r++)if(!BY.call(n,t[r])||!o1(e[t[r]],n[t[r]]))return!1;return!0}var kY=Um&&"documentMode"in document&&11>=document.documentMode,SD={select:{phasedRegistrationNames:{bubbled:"onSelect",captured:"onSelectCapture"},dependencies:"blur contextmenu dragend focus keydown keyup mousedown mouseup selectionchange".split(" ")}},Tg=null,$S=null,bC=null,YS=!1;function $k(e,n){var t=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;return YS||Tg==null||Tg!==jS(t)?null:(t=Tg,"selectionStart"in t&&WS(t)?t={start:t.selectionStart,end:t.selectionEnd}:(t=(t.ownerDocument&&t.ownerDocument.defaultView||window).getSelection(),t={anchorNode:t.anchorNode,anchorOffset:t.anchorOffset,focusNode:t.focusNode,focusOffset:t.focusOffset}),bC&&VC(bC,t)?null:(bC=t,e=Wc.getPooled(SD.select,$S,e,n),e.type="select",e.target=Tg,gy(e),e))}var IY={eventTypes:SD,extractEvents:function(e,n,t,r,i,o){if(i=o||(r.window===r?r.document:r.nodeType===9?r:r.ownerDocument),!(o=!i)){e:{i=IO(i),o=_O.onSelect;for(var s=0;s<o.length;s++)if(!i.has(o[s])){i=!1;break e}i=!0}o=!i}if(o)return null;switch(i=n?i1(n):window,e){case"focus":(_D(i)||i.contentEditable==="true")&&(Tg=i,$S=n,bC=null);break;case"blur":bC=$S=Tg=null;break;case"mousedown":YS=!0;break;case"contextmenu":case"mouseup":case"dragend":return YS=!1,$k(t,r);case"selectionchange":if(kY)break;case"keydown":case"keyup":return $k(t,r)}return null}},TY=Wc.extend({animationName:null,elapsedTime:null,pseudoElement:null}),KY=Wc.extend({clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),PY=D_.extend({relatedTarget:null});function o2(e){var n=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&n===13&&(e=13)):e=n,e===10&&(e=13),32<=e||e===13?e:0}var FY={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},DY={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},UY=D_.extend({key:function(e){if(e.key){var n=FY[e.key]||e.key;if(n!=="Unidentified")return n}return e.type==="keypress"?(e=o2(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?DY[e.keyCode]||"Unidentified":""},location:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,repeat:null,locale:null,getModifierState:GO,charCode:function(e){return e.type==="keypress"?o2(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?o2(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),RY=U_.extend({dataTransfer:null}),LY=D_.extend({touches:null,targetTouches:null,changedTouches:null,altKey:null,metaKey:null,ctrlKey:null,shiftKey:null,getModifierState:GO}),zY=Wc.extend({propertyName:null,elapsedTime:null,pseudoElement:null}),jY=U_.extend({deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:null,deltaMode:null}),WY={eventTypes:sD,extractEvents:function(e,n,t,r){var i=lD.get(e);if(!i)return null;switch(e){case"keypress":if(o2(t)===0)return null;case"keydown":case"keyup":e=UY;break;case"blur":case"focus":e=PY;break;case"click":if(t.button===2)return null;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":e=U_;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":e=RY;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":e=LY;break;case qF:case VF:case HF:e=TY;break;case ZF:e=zY;break;case"scroll":e=D_;break;case"wheel":e=jY;break;case"copy":case"cut":case"paste":e=KY;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":e=MD;break;default:e=Wc}return n=e.getPooled(i,n,t,r),gy(n),n}};if(I2)throw Error(Ln(101));I2=Array.prototype.slice.call("ResponderEventPlugin SimpleEventPlugin EnterLeaveEventPlugin ChangeEventPlugin SelectEventPlugin BeforeInputEventPlugin".split(" "));OF();var NY=F_;CO=jO;SF=NY;EF=i1;BF({SimpleEventPlugin:WY,EnterLeaveEventPlugin:EY,ChangeEventPlugin:wY,SelectEventPlugin:IY,BeforeInputEventPlugin:mY});var qS=[],Kg=-1;function hs(e){0>Kg||(e.current=qS[Kg],qS[Kg]=null,Kg--)}function ol(e,n){Kg++,qS[Kg]=e.current,e.current=n}var Tm={},qu={current:Tm},NA={current:!1},a1=Tm;function yy(e,n){var t=e.type.contextTypes;if(!t)return Tm;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===n)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in t)i[o]=n[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=n,e.__reactInternalMemoizedMaskedChildContext=i),i}function GA(e){return e=e.childContextTypes,e!=null}function U2(){hs(NA),hs(qu)}function Yk(e,n,t){if(qu.current!==Tm)throw Error(Ln(168));ol(qu,n),ol(NA,t)}function ED(e,n,t){var r=e.stateNode;if(e=n.childContextTypes,typeof r.getChildContext!="function")return t;r=r.getChildContext();for(var i in r)if(!(i in e))throw Error(Ln(108,vp(n)||"Unknown",i));return yA({},t,{},r)}function a2(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Tm,a1=qu.current,ol(qu,e),ol(NA,NA.current),!0}function qk(e,n,t){var r=e.stateNode;if(!r)throw Error(Ln(169));t?(e=ED(e,n,a1),r.__reactInternalMemoizedMergedChildContext=e,hs(NA),hs(qu),ol(qu,e)):hs(NA),ol(NA,t)}var GY=_u.unstable_runWithPriority,QO=_u.unstable_scheduleCallback,OD=_u.unstable_cancelCallback,Vk=_u.unstable_requestPaint,VS=_u.unstable_now,QY=_u.unstable_getCurrentPriorityLevel,K4=_u.unstable_ImmediatePriority,BD=_u.unstable_UserBlockingPriority,kD=_u.unstable_NormalPriority,ID=_u.unstable_LowPriority,TD=_u.unstable_IdlePriority,KD={},$Y=_u.unstable_shouldYield,YY=Vk!==void 0?Vk:function(){},up=null,s2=null,zw=!1,Hk=VS(),vd=1e4>Hk?VS:function(){return VS()-Hk};function P4(){switch(QY()){case K4:return 99;case BD:return 98;case kD:return 97;case ID:return 96;case TD:return 95;default:throw Error(Ln(332))}}function PD(e){switch(e){case 99:return K4;case 98:return BD;case 97:return kD;case 96:return ID;case 95:return TD;default:throw Error(Ln(332))}}function Km(e,n){return e=PD(e),GY(e,n)}function FD(e,n,t){return e=PD(e),QO(e,n,t)}function Zk(e){return up===null?(up=[e],s2=QO(K4,DD)):up.push(e),KD}function gf(){if(s2!==null){var e=s2;s2=null,OD(e)}DD()}function DD(){if(!zw&&up!==null){zw=!0;var e=0;try{var n=up;Km(99,function(){for(;e<n.length;e++){var t=n[e];do t=t(!0);while(t!==null)}}),up=null}catch(t){throw up!==null&&(up=up.slice(e+1)),QO(K4,gf),t}finally{zw=!1}}}function l2(e,n,t){return t/=10,1073741821-(((1073741821-e+n/10)/t|0)+1)*t}function sh(e,n){if(e&&e.defaultProps){n=yA({},n),e=e.defaultProps;for(var t in e)n[t]===void 0&&(n[t]=e[t])}return n}var R2={current:null},L2=null,Pg=null,z2=null;function $O(){z2=Pg=L2=null}function YO(e){var n=R2.current;hs(R2),e.type._context._currentValue=n}function UD(e,n){for(;e!==null;){var t=e.alternate;if(e.childExpirationTime<n)e.childExpirationTime=n,t!==null&&t.childExpirationTime<n&&(t.childExpirationTime=n);else if(t!==null&&t.childExpirationTime<n)t.childExpirationTime=n;else break;e=e.return}}function Vg(e,n){L2=e,z2=Pg=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.expirationTime>=n&&(Jh=!0),e.firstContext=null)}function Md(e,n){if(z2!==e&&n!==!1&&n!==0)if((typeof n!="number"||n===1073741823)&&(z2=e,n=1073741823),n={context:e,observedBits:n,next:null},Pg===null){if(L2===null)throw Error(Ln(308));Pg=n,L2.dependencies={expirationTime:0,firstContext:n,responders:null}}else Pg=Pg.next=n;return e._currentValue}var Jp=!1;function qO(e){e.updateQueue={baseState:e.memoizedState,baseQueue:null,shared:{pending:null},effects:null}}function VO(e,n){e=e.updateQueue,n.updateQueue===e&&(n.updateQueue={baseState:e.baseState,baseQueue:e.baseQueue,shared:e.shared,effects:e.effects})}function _m(e,n){return e={expirationTime:e,suspenseConfig:n,tag:0,payload:null,callback:null,next:null},e.next=e}function bm(e,n){if(e=e.updateQueue,e!==null){e=e.shared;var t=e.pending;t===null?n.next=n:(n.next=t.next,t.next=n),e.pending=n}}function Xk(e,n){var t=e.alternate;t!==null&&VO(t,e),e=e.updateQueue,t=e.baseQueue,t===null?(e.baseQueue=n.next=n,n.next=n):(n.next=t.next,t.next=n)}function HC(e,n,t,r){var i=e.updateQueue;Jp=!1;var o=i.baseQueue,s=i.shared.pending;if(s!==null){if(o!==null){var a=o.next;o.next=s.next,s.next=a}o=s,i.shared.pending=null,a=e.alternate,a!==null&&(a=a.updateQueue,a!==null&&(a.baseQueue=s))}if(o!==null){a=o.next;var f=i.baseState,g=0,x=null,k=null,B=null;if(a!==null){var P=a;do{if(s=P.expirationTime,s<r){var R={expirationTime:P.expirationTime,suspenseConfig:P.suspenseConfig,tag:P.tag,payload:P.payload,callback:P.callback,next:null};B===null?(k=B=R,x=f):B=B.next=R,s>g&&(g=s)}else{B!==null&&(B=B.next={expirationTime:1073741823,suspenseConfig:P.suspenseConfig,tag:P.tag,payload:P.payload,callback:P.callback,next:null}),hU(s,P.suspenseConfig);e:{var H=e,W=P;switch(s=n,R=t,W.tag){case 1:if(H=W.payload,typeof H=="function"){f=H.call(R,f,s);break e}f=H;break e;case 3:H.effectTag=H.effectTag&-4097|64;case 0:if(H=W.payload,s=typeof H=="function"?H.call(R,f,s):H,s==null)break e;f=yA({},f,s);break e;case 2:Jp=!0}}P.callback!==null&&(e.effectTag|=32,s=i.effects,s===null?i.effects=[P]:s.push(P))}if(P=P.next,P===null||P===a){if(s=i.shared.pending,s===null)break;P=o.next=s.next,s.next=a,i.baseQueue=o=s,i.shared.pending=null}}while(!0)}B===null?x=f:B.next=k,i.baseState=x,i.baseQueue=B,L4(g),e.expirationTime=g,e.memoizedState=f}}function Jk(e,n,t){if(e=n.effects,n.effects=null,e!==null)for(n=0;n<e.length;n++){var r=e[n],i=r.callback;if(i!==null){if(r.callback=null,r=i,i=t,typeof r!="function")throw Error(Ln(191,r));r.call(i)}}}var xC=dh.ReactCurrentBatchConfig,RD=new O4.Component().refs;function j2(e,n,t,r){n=e.memoizedState,t=t(r,n),t=t==null?n:yA({},n,t),e.memoizedState=t,e.expirationTime===0&&(e.updateQueue.baseState=t)}var F4={isMounted:function(e){return(e=e._reactInternalFiber)?y1(e)===e:!1},enqueueSetState:function(e,n,t){e=e._reactInternalFiber;var r=of(),i=xC.suspense;r=V0(r,e,i),i=_m(r,i),i.payload=n,t!=null&&(i.callback=t),bm(e,i),wm(e,r)},enqueueReplaceState:function(e,n,t){e=e._reactInternalFiber;var r=of(),i=xC.suspense;r=V0(r,e,i),i=_m(r,i),i.tag=1,i.payload=n,t!=null&&(i.callback=t),bm(e,i),wm(e,r)},enqueueForceUpdate:function(e,n){e=e._reactInternalFiber;var t=of(),r=xC.suspense;t=V0(t,e,r),r=_m(t,r),r.tag=2,n!=null&&(r.callback=n),bm(e,r),wm(e,t)}};function eI(e,n,t,r,i,o,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,o,s):n.prototype&&n.prototype.isPureReactComponent?!VC(t,r)||!VC(i,o):!0}function LD(e,n,t){var r=!1,i=Tm,o=n.contextType;return typeof o=="object"&&o!==null?o=Md(o):(i=GA(n)?a1:qu.current,r=n.contextTypes,o=(r=r!=null)?yy(e,i):Tm),n=new n(t,o),e.memoizedState=n.state!==null&&n.state!==void 0?n.state:null,n.updater=F4,e.stateNode=n,n._reactInternalFiber=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),n}function tI(e,n,t,r){e=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(t,r),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(t,r),n.state!==e&&F4.enqueueReplaceState(n,n.state,null)}function HS(e,n,t,r){var i=e.stateNode;i.props=t,i.state=e.memoizedState,i.refs=RD,qO(e);var o=n.contextType;typeof o=="object"&&o!==null?i.context=Md(o):(o=GA(n)?a1:qu.current,i.context=yy(e,o)),HC(e,t,i,r),i.state=e.memoizedState,o=n.getDerivedStateFromProps,typeof o=="function"&&(j2(e,n,o,t),i.state=e.memoizedState),typeof n.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(n=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),n!==i.state&&F4.enqueueReplaceState(i,i.state,null),HC(e,t,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.effectTag|=4)}var sx=Array.isArray;function Lv(e,n,t){if(e=t.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(t._owner){if(t=t._owner,t){if(t.tag!==1)throw Error(Ln(309));var r=t.stateNode}if(!r)throw Error(Ln(147,e));var i=""+e;return n!==null&&n.ref!==null&&typeof n.ref=="function"&&n.ref._stringRef===i?n.ref:(n=function(o){var s=r.refs;s===RD&&(s=r.refs={}),o===null?delete s[i]:s[i]=o},n._stringRef=i,n)}if(typeof e!="string")throw Error(Ln(284));if(!t._owner)throw Error(Ln(290,e))}return e}function lx(e,n){if(e.type!=="textarea")throw Error(Ln(31,Object.prototype.toString.call(n)==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":n,""))}function zD(e){function n(W,$){if(e){var q=W.lastEffect;q!==null?(q.nextEffect=$,W.lastEffect=$):W.firstEffect=W.lastEffect=$,$.nextEffect=null,$.effectTag=8}}function t(W,$){if(!e)return null;for(;$!==null;)n(W,$),$=$.sibling;return null}function r(W,$){for(W=new Map;$!==null;)$.key!==null?W.set($.key,$):W.set($.index,$),$=$.sibling;return W}function i(W,$){return W=s1(W,$),W.index=0,W.sibling=null,W}function o(W,$,q){return W.index=q,e?(q=W.alternate,q!==null?(q=q.index,q<$?(W.effectTag=2,$):q):(W.effectTag=2,$)):$}function s(W){return e&&W.alternate===null&&(W.effectTag=2),W}function a(W,$,q,oe){return $===null||$.tag!==6?($=$w(q,W.mode,oe),$.return=W,$):($=i($,q),$.return=W,$)}function f(W,$,q,oe){return $!==null&&$.elementType===q.type?(oe=i($,q.props),oe.ref=Lv(W,$,q),oe.return=W,oe):(oe=d2(q.type,q.key,q.props,null,W.mode,oe),oe.ref=Lv(W,$,q),oe.return=W,oe)}function g(W,$,q,oe){return $===null||$.tag!==4||$.stateNode.containerInfo!==q.containerInfo||$.stateNode.implementation!==q.implementation?($=Yw(q,W.mode,oe),$.return=W,$):($=i($,q.children||[]),$.return=W,$)}function x(W,$,q,oe,ne){return $===null||$.tag!==7?($=Am(q,W.mode,oe,ne),$.return=W,$):($=i($,q),$.return=W,$)}function k(W,$,q){if(typeof $=="string"||typeof $=="number")return $=$w(""+$,W.mode,q),$.return=W,$;if(typeof $=="object"&&$!==null){switch($.$$typeof){case rx:return q=d2($.type,$.key,$.props,null,W.mode,q),q.ref=Lv(W,null,$),q.return=W,q;case Bg:return $=Yw($,W.mode,q),$.return=W,$}if(sx($)||Kv($))return $=Am($,W.mode,q,null),$.return=W,$;lx(W,$)}return null}function B(W,$,q,oe){var ne=$!==null?$.key:null;if(typeof q=="string"||typeof q=="number")return ne!==null?null:a(W,$,""+q,oe);if(typeof q=="object"&&q!==null){switch(q.$$typeof){case rx:return q.key===ne?q.type===k0?x(W,$,q.props.children,oe,ne):f(W,$,q,oe):null;case Bg:return q.key===ne?g(W,$,q,oe):null}if(sx(q)||Kv(q))return ne!==null?null:x(W,$,q,oe,null);lx(W,q)}return null}function P(W,$,q,oe,ne){if(typeof oe=="string"||typeof oe=="number")return W=W.get(q)||null,a($,W,""+oe,ne);if(typeof oe=="object"&&oe!==null){switch(oe.$$typeof){case rx:return W=W.get(oe.key===null?q:oe.key)||null,oe.type===k0?x($,W,oe.props.children,ne,oe.key):f($,W,oe,ne);case Bg:return W=W.get(oe.key===null?q:oe.key)||null,g($,W,oe,ne)}if(sx(oe)||Kv(oe))return W=W.get(q)||null,x($,W,oe,ne,null);lx($,oe)}return null}function R(W,$,q,oe){for(var ne=null,ce=null,ae=$,ue=$=0,ye=null;ae!==null&&ue<q.length;ue++){ae.index>ue?(ye=ae,ae=null):ye=ae.sibling;var Re=B(W,ae,q[ue],oe);if(Re===null){ae===null&&(ae=ye);break}e&&ae&&Re.alternate===null&&n(W,ae),$=o(Re,$,ue),ce===null?ne=Re:ce.sibling=Re,ce=Re,ae=ye}if(ue===q.length)return t(W,ae),ne;if(ae===null){for(;ue<q.length;ue++)ae=k(W,q[ue],oe),ae!==null&&($=o(ae,$,ue),ce===null?ne=ae:ce.sibling=ae,ce=ae);return ne}for(ae=r(W,ae);ue<q.length;ue++)ye=P(ae,W,ue,q[ue],oe),ye!==null&&(e&&ye.alternate!==null&&ae.delete(ye.key===null?ue:ye.key),$=o(ye,$,ue),ce===null?ne=ye:ce.sibling=ye,ce=ye);return e&&ae.forEach(function(Ne){return n(W,Ne)}),ne}function H(W,$,q,oe){var ne=Kv(q);if(typeof ne!="function")throw Error(Ln(150));if(q=ne.call(q),q==null)throw Error(Ln(151));for(var ce=ne=null,ae=$,ue=$=0,ye=null,Re=q.next();ae!==null&&!Re.done;ue++,Re=q.next()){ae.index>ue?(ye=ae,ae=null):ye=ae.sibling;var Ne=B(W,ae,Re.value,oe);if(Ne===null){ae===null&&(ae=ye);break}e&&ae&&Ne.alternate===null&&n(W,ae),$=o(Ne,$,ue),ce===null?ne=Ne:ce.sibling=Ne,ce=Ne,ae=ye}if(Re.done)return t(W,ae),ne;if(ae===null){for(;!Re.done;ue++,Re=q.next())Re=k(W,Re.value,oe),Re!==null&&($=o(Re,$,ue),ce===null?ne=Re:ce.sibling=Re,ce=Re);return ne}for(ae=r(W,ae);!Re.done;ue++,Re=q.next())Re=P(ae,W,ue,Re.value,oe),Re!==null&&(e&&Re.alternate!==null&&ae.delete(Re.key===null?ue:Re.key),$=o(Re,$,ue),ce===null?ne=Re:ce.sibling=Re,ce=Re);return e&&ae.forEach(function(rt){return n(W,rt)}),ne}return function(W,$,q,oe){var ne=typeof q=="object"&&q!==null&&q.type===k0&&q.key===null;ne&&(q=q.props.children);var ce=typeof q=="object"&&q!==null;if(ce)switch(q.$$typeof){case rx:e:{for(ce=q.key,ne=$;ne!==null;){if(ne.key===ce){switch(ne.tag){case 7:if(q.type===k0){t(W,ne.sibling),$=i(ne,q.props.children),$.return=W,W=$;break e}break;default:if(ne.elementType===q.type){t(W,ne.sibling),$=i(ne,q.props),$.ref=Lv(W,ne,q),$.return=W,W=$;break e}}t(W,ne);break}else n(W,ne);ne=ne.sibling}q.type===k0?($=Am(q.props.children,W.mode,oe,q.key),$.return=W,W=$):(oe=d2(q.type,q.key,q.props,null,W.mode,oe),oe.ref=Lv(W,$,q),oe.return=W,W=oe)}return s(W);case Bg:e:{for(ne=q.key;$!==null;){if($.key===ne)if($.tag===4&&$.stateNode.containerInfo===q.containerInfo&&$.stateNode.implementation===q.implementation){t(W,$.sibling),$=i($,q.children||[]),$.return=W,W=$;break e}else{t(W,$);break}else n(W,$);$=$.sibling}$=Yw(q,W.mode,oe),$.return=W,W=$}return s(W)}if(typeof q=="string"||typeof q=="number")return q=""+q,$!==null&&$.tag===6?(t(W,$.sibling),$=i($,q),$.return=W,W=$):(t(W,$),$=$w(q,W.mode,oe),$.return=W,W=$),s(W);if(sx(q))return R(W,$,q,oe);if(Kv(q))return H(W,$,q,oe);if(ce&&lx(W,q),typeof q>"u"&&!ne)switch(W.tag){case 1:case 0:throw W=W.type,Error(Ln(152,W.displayName||W.name||"Component"))}return t(W,$)}}var vy=zD(!0),HO=zD(!1),R_={},rf={current:R_},ZC={current:R_},XC={current:R_};function U0(e){if(e===R_)throw Error(Ln(174));return e}function ZS(e,n){switch(ol(XC,n),ol(ZC,e),ol(rf,R_),e=n.nodeType,e){case 9:case 11:n=(n=n.documentElement)?n.namespaceURI:PS(null,"");break;default:e=e===8?n.parentNode:n,n=e.namespaceURI||null,e=e.tagName,n=PS(n,e)}hs(rf),ol(rf,n)}function Cy(){hs(rf),hs(ZC),hs(XC)}function nI(e){U0(XC.current);var n=U0(rf.current),t=PS(n,e.type);n!==t&&(ol(ZC,e),ol(rf,t))}function ZO(e){ZC.current===e&&(hs(rf),hs(ZC))}var Qs={current:0};function W2(e){for(var n=e;n!==null;){if(n.tag===13){var t=n.memoizedState;if(t!==null&&(t=t.dehydrated,t===null||t.data===RO||t.data===LO))return n}else if(n.tag===19&&n.memoizedProps.revealOrder!==void 0){if(n.effectTag&64)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}function XO(e,n){return{responder:e,props:n}}var u2=dh.ReactCurrentDispatcher,bd=dh.ReactCurrentBatchConfig,lm=0,Nl=null,$u=null,Yu=null,N2=!1;function Ic(){throw Error(Ln(321))}function JO(e,n){if(n===null)return!1;for(var t=0;t<n.length&&t<e.length;t++)if(!o1(e[t],n[t]))return!1;return!0}function eB(e,n,t,r,i,o){if(lm=o,Nl=n,n.memoizedState=null,n.updateQueue=null,n.expirationTime=0,u2.current=e===null||e.memoizedState===null?qY:VY,e=t(r,i),n.expirationTime===lm){o=0;do{if(n.expirationTime=0,!(25>o))throw Error(Ln(301));o+=1,Yu=$u=null,n.updateQueue=null,u2.current=HY,e=t(r,i)}while(n.expirationTime===lm)}if(u2.current=$2,n=$u!==null&&$u.next!==null,lm=0,Yu=$u=Nl=null,N2=!1,n)throw Error(Ln(300));return e}function Hg(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Yu===null?Nl.memoizedState=Yu=e:Yu=Yu.next=e,Yu}function Ky(){if($u===null){var e=Nl.alternate;e=e!==null?e.memoizedState:null}else e=$u.next;var n=Yu===null?Nl.memoizedState:Yu.next;if(n!==null)Yu=n,$u=e;else{if(e===null)throw Error(Ln(310));$u=e,e={memoizedState:$u.memoizedState,baseState:$u.baseState,baseQueue:$u.baseQueue,queue:$u.queue,next:null},Yu===null?Nl.memoizedState=Yu=e:Yu=Yu.next=e}return Yu}function $0(e,n){return typeof n=="function"?n(e):n}function ux(e){var n=Ky(),t=n.queue;if(t===null)throw Error(Ln(311));t.lastRenderedReducer=e;var r=$u,i=r.baseQueue,o=t.pending;if(o!==null){if(i!==null){var s=i.next;i.next=o.next,o.next=s}r.baseQueue=i=o,t.pending=null}if(i!==null){i=i.next,r=r.baseState;var a=s=o=null,f=i;do{var g=f.expirationTime;if(g<lm){var x={expirationTime:f.expirationTime,suspenseConfig:f.suspenseConfig,action:f.action,eagerReducer:f.eagerReducer,eagerState:f.eagerState,next:null};a===null?(s=a=x,o=r):a=a.next=x,g>Nl.expirationTime&&(Nl.expirationTime=g,L4(g))}else a!==null&&(a=a.next={expirationTime:1073741823,suspenseConfig:f.suspenseConfig,action:f.action,eagerReducer:f.eagerReducer,eagerState:f.eagerState,next:null}),hU(g,f.suspenseConfig),r=f.eagerReducer===e?f.eagerState:e(r,f.action);f=f.next}while(f!==null&&f!==i);a===null?o=r:a.next=s,o1(r,n.memoizedState)||(Jh=!0),n.memoizedState=r,n.baseState=o,n.baseQueue=a,t.lastRenderedState=r}return[n.memoizedState,t.dispatch]}function Ax(e){var n=Ky(),t=n.queue;if(t===null)throw Error(Ln(311));t.lastRenderedReducer=e;var r=t.dispatch,i=t.pending,o=n.memoizedState;if(i!==null){t.pending=null;var s=i=i.next;do o=e(o,s.action),s=s.next;while(s!==i);o1(o,n.memoizedState)||(Jh=!0),n.memoizedState=o,n.baseQueue===null&&(n.baseState=o),t.lastRenderedState=o}return[o,r]}function jw(e){var n=Hg();return typeof e=="function"&&(e=e()),n.memoizedState=n.baseState=e,e=n.queue={pending:null,dispatch:null,lastRenderedReducer:$0,lastRenderedState:e},e=e.dispatch=$D.bind(null,Nl,e),[n.memoizedState,e]}function XS(e,n,t,r){return e={tag:e,create:n,destroy:t,deps:r,next:null},n=Nl.updateQueue,n===null?(n={lastEffect:null},Nl.updateQueue=n,n.lastEffect=e.next=e):(t=n.lastEffect,t===null?n.lastEffect=e.next=e:(r=t.next,t.next=e,e.next=r,n.lastEffect=e)),e}function jD(){return Ky().memoizedState}function JS(e,n,t,r){var i=Hg();Nl.effectTag|=e,i.memoizedState=XS(1|n,t,void 0,r===void 0?null:r)}function tB(e,n,t,r){var i=Ky();r=r===void 0?null:r;var o=void 0;if($u!==null){var s=$u.memoizedState;if(o=s.destroy,r!==null&&JO(r,s.deps)){XS(n,t,o,r);return}}Nl.effectTag|=e,i.memoizedState=XS(1|n,t,o,r)}function rI(e,n){return JS(516,4,e,n)}function G2(e,n){return tB(516,4,e,n)}function WD(e,n){return tB(4,2,e,n)}function ND(e,n){if(typeof n=="function")return e=e(),n(e),function(){n(null)};if(n!=null)return e=e(),n.current=e,function(){n.current=null}}function GD(e,n,t){return t=t!=null?t.concat([e]):null,tB(4,2,ND.bind(null,n,e),t)}function nB(){}function iI(e,n){return Hg().memoizedState=[e,n===void 0?null:n],e}function Q2(e,n){var t=Ky();n=n===void 0?null:n;var r=t.memoizedState;return r!==null&&n!==null&&JO(n,r[1])?r[0]:(t.memoizedState=[e,n],e)}function QD(e,n){var t=Ky();n=n===void 0?null:n;var r=t.memoizedState;return r!==null&&n!==null&&JO(n,r[1])?r[0]:(e=e(),t.memoizedState=[e,n],e)}function rB(e,n,t){var r=P4();Km(98>r?98:r,function(){e(!0)}),Km(97<r?97:r,function(){var i=bd.suspense;bd.suspense=n===void 0?null:n;try{e(!1),t()}finally{bd.suspense=i}})}function $D(e,n,t){var r=of(),i=xC.suspense;r=V0(r,e,i),i={expirationTime:r,suspenseConfig:i,action:t,eagerReducer:null,eagerState:null,next:null};var o=n.pending;if(o===null?i.next=i:(i.next=o.next,o.next=i),n.pending=i,o=e.alternate,e===Nl||o!==null&&o===Nl)N2=!0,i.expirationTime=lm,Nl.expirationTime=lm;else{if(e.expirationTime===0&&(o===null||o.expirationTime===0)&&(o=n.lastRenderedReducer,o!==null))try{var s=n.lastRenderedState,a=o(s,t);if(i.eagerReducer=o,i.eagerState=a,o1(a,s))return}catch{}finally{}wm(e,r)}}var $2={readContext:Md,useCallback:Ic,useContext:Ic,useEffect:Ic,useImperativeHandle:Ic,useLayoutEffect:Ic,useMemo:Ic,useReducer:Ic,useRef:Ic,useState:Ic,useDebugValue:Ic,useResponder:Ic,useDeferredValue:Ic,useTransition:Ic},qY={readContext:Md,useCallback:iI,useContext:Md,useEffect:rI,useImperativeHandle:function(e,n,t){return t=t!=null?t.concat([e]):null,JS(4,2,ND.bind(null,n,e),t)},useLayoutEffect:function(e,n){return JS(4,2,e,n)},useMemo:function(e,n){var t=Hg();return n=n===void 0?null:n,e=e(),t.memoizedState=[e,n],e},useReducer:function(e,n,t){var r=Hg();return n=t!==void 0?t(n):n,r.memoizedState=r.baseState=n,e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:n},e=e.dispatch=$D.bind(null,Nl,e),[r.memoizedState,e]},useRef:function(e){var n=Hg();return e={current:e},n.memoizedState=e},useState:jw,useDebugValue:nB,useResponder:XO,useDeferredValue:function(e,n){var t=jw(e),r=t[0],i=t[1];return rI(function(){var o=bd.suspense;bd.suspense=n===void 0?null:n;try{i(e)}finally{bd.suspense=o}},[e,n]),r},useTransition:function(e){var n=jw(!1),t=n[0];return n=n[1],[iI(rB.bind(null,n,e),[n,e]),t]}},VY={readContext:Md,useCallback:Q2,useContext:Md,useEffect:G2,useImperativeHandle:GD,useLayoutEffect:WD,useMemo:QD,useReducer:ux,useRef:jD,useState:function(){return ux($0)},useDebugValue:nB,useResponder:XO,useDeferredValue:function(e,n){var t=ux($0),r=t[0],i=t[1];return G2(function(){var o=bd.suspense;bd.suspense=n===void 0?null:n;try{i(e)}finally{bd.suspense=o}},[e,n]),r},useTransition:function(e){var n=ux($0),t=n[0];return n=n[1],[Q2(rB.bind(null,n,e),[n,e]),t]}},HY={readContext:Md,useCallback:Q2,useContext:Md,useEffect:G2,useImperativeHandle:GD,useLayoutEffect:WD,useMemo:QD,useReducer:Ax,useRef:jD,useState:function(){return Ax($0)},useDebugValue:nB,useResponder:XO,useDeferredValue:function(e,n){var t=Ax($0),r=t[0],i=t[1];return G2(function(){var o=bd.suspense;bd.suspense=n===void 0?null:n;try{i(e)}finally{bd.suspense=o}},[e,n]),r},useTransition:function(e){var n=Ax($0),t=n[0];return n=n[1],[Q2(rB.bind(null,n,e),[n,e]),t]}},gp=null,um=null,Y0=!1;function YD(e,n){var t=ef(5,null,null,0);t.elementType="DELETED",t.type="DELETED",t.stateNode=n,t.return=e,t.effectTag=8,e.lastEffect!==null?(e.lastEffect.nextEffect=t,e.lastEffect=t):e.firstEffect=e.lastEffect=t}function oI(e,n){switch(e.tag){case 5:var t=e.type;return n=n.nodeType!==1||t.toLowerCase()!==n.nodeName.toLowerCase()?null:n,n!==null?(e.stateNode=n,!0):!1;case 6:return n=e.pendingProps===""||n.nodeType!==3?null:n,n!==null?(e.stateNode=n,!0):!1;case 13:return!1;default:return!1}}function e6(e){if(Y0){var n=um;if(n){var t=n;if(!oI(e,n)){if(n=qg(t.nextSibling),!n||!oI(e,n)){e.effectTag=e.effectTag&-1025|2,Y0=!1,gp=e;return}YD(gp,t)}gp=e,um=qg(n.firstChild)}else e.effectTag=e.effectTag&-1025|2,Y0=!1,gp=e}}function aI(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;gp=e}function cx(e){if(e!==gp)return!1;if(!Y0)return aI(e),Y0=!0,!1;var n=e.type;if(e.tag!==5||n!=="head"&&n!=="body"&&!NS(n,e.memoizedProps))for(n=um;n;)YD(e,n),n=qg(n.nextSibling);if(aI(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Ln(317));e:{for(e=e.nextSibling,n=0;e;){if(e.nodeType===8){var t=e.data;if(t===hD){if(n===0){um=qg(e.nextSibling);break e}n--}else t!==dD&&t!==LO&&t!==RO||n++}e=e.nextSibling}um=null}}else um=gp?qg(e.stateNode.nextSibling):null;return!0}function Ww(){um=gp=null,Y0=!1}var ZY=dh.ReactCurrentOwner,Jh=!1;function Tc(e,n,t,r){n.child=e===null?HO(n,null,t,r):vy(n,e.child,t,r)}function sI(e,n,t,r,i){t=t.render;var o=n.ref;return Vg(n,i),r=eB(e,n,t,r,o,i),e!==null&&!Jh?(n.updateQueue=e.updateQueue,n.effectTag&=-517,e.expirationTime<=i&&(e.expirationTime=0),yp(e,n,i)):(n.effectTag|=1,Tc(e,n,r,i),n.child)}function lI(e,n,t,r,i,o){if(e===null){var s=t.type;return typeof s=="function"&&!lB(s)&&s.defaultProps===void 0&&t.compare===null&&t.defaultProps===void 0?(n.tag=15,n.type=s,qD(e,n,s,r,i,o)):(e=d2(t.type,null,r,null,n.mode,o),e.ref=n.ref,e.return=n,n.child=e)}return s=e.child,i<o&&(i=s.memoizedProps,t=t.compare,t=t!==null?t:VC,t(i,r)&&e.ref===n.ref)?yp(e,n,o):(n.effectTag|=1,e=s1(s,r),e.ref=n.ref,e.return=n,n.child=e)}function qD(e,n,t,r,i,o){return e!==null&&VC(e.memoizedProps,r)&&e.ref===n.ref&&(Jh=!1,i<o)?(n.expirationTime=e.expirationTime,yp(e,n,o)):t6(e,n,t,r,o)}function VD(e,n){var t=n.ref;(e===null&&t!==null||e!==null&&e.ref!==t)&&(n.effectTag|=128)}function t6(e,n,t,r,i){var o=GA(t)?a1:qu.current;return o=yy(n,o),Vg(n,i),t=eB(e,n,t,r,o,i),e!==null&&!Jh?(n.updateQueue=e.updateQueue,n.effectTag&=-517,e.expirationTime<=i&&(e.expirationTime=0),yp(e,n,i)):(n.effectTag|=1,Tc(e,n,t,i),n.child)}function uI(e,n,t,r,i){if(GA(t)){var o=!0;a2(n)}else o=!1;if(Vg(n,i),n.stateNode===null)e!==null&&(e.alternate=null,n.alternate=null,n.effectTag|=2),LD(n,t,r),HS(n,t,r,i),r=!0;else if(e===null){var s=n.stateNode,a=n.memoizedProps;s.props=a;var f=s.context,g=t.contextType;typeof g=="object"&&g!==null?g=Md(g):(g=GA(t)?a1:qu.current,g=yy(n,g));var x=t.getDerivedStateFromProps,k=typeof x=="function"||typeof s.getSnapshotBeforeUpdate=="function";k||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(a!==r||f!==g)&&tI(n,s,r,g),Jp=!1;var B=n.memoizedState;s.state=B,HC(n,r,s,i),f=n.memoizedState,a!==r||B!==f||NA.current||Jp?(typeof x=="function"&&(j2(n,t,x,r),f=n.memoizedState),(a=Jp||eI(n,t,a,r,B,f,g))?(k||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(n.effectTag|=4)):(typeof s.componentDidMount=="function"&&(n.effectTag|=4),n.memoizedProps=r,n.memoizedState=f),s.props=r,s.state=f,s.context=g,r=a):(typeof s.componentDidMount=="function"&&(n.effectTag|=4),r=!1)}else s=n.stateNode,VO(e,n),a=n.memoizedProps,s.props=n.type===n.elementType?a:sh(n.type,a),f=s.context,g=t.contextType,typeof g=="object"&&g!==null?g=Md(g):(g=GA(t)?a1:qu.current,g=yy(n,g)),x=t.getDerivedStateFromProps,(k=typeof x=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(a!==r||f!==g)&&tI(n,s,r,g),Jp=!1,f=n.memoizedState,s.state=f,HC(n,r,s,i),B=n.memoizedState,a!==r||f!==B||NA.current||Jp?(typeof x=="function"&&(j2(n,t,x,r),B=n.memoizedState),(x=Jp||eI(n,t,a,r,f,B,g))?(k||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(r,B,g),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(r,B,g)),typeof s.componentDidUpdate=="function"&&(n.effectTag|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(n.effectTag|=256)):(typeof s.componentDidUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(n.effectTag|=4),typeof s.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(n.effectTag|=256),n.memoizedProps=r,n.memoizedState=B),s.props=r,s.state=B,s.context=g,r=x):(typeof s.componentDidUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(n.effectTag|=4),typeof s.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(n.effectTag|=256),r=!1);return n6(e,n,t,r,o,i)}function n6(e,n,t,r,i,o){VD(e,n);var s=(n.effectTag&64)!==0;if(!r&&!s)return i&&qk(n,t,!1),yp(e,n,o);r=n.stateNode,ZY.current=n;var a=s&&typeof t.getDerivedStateFromError!="function"?null:r.render();return n.effectTag|=1,e!==null&&s?(n.child=vy(n,e.child,null,o),n.child=vy(n,null,a,o)):Tc(e,n,a,o),n.memoizedState=r.state,i&&qk(n,t,!0),n.child}function AI(e){var n=e.stateNode;n.pendingContext?Yk(e,n.pendingContext,n.pendingContext!==n.context):n.context&&Yk(e,n.context,!1),ZS(e,n.containerInfo)}var Nw={dehydrated:null,retryTime:0};function cI(e,n,t){var r=n.mode,i=n.pendingProps,o=Qs.current,s=!1,a;if((a=(n.effectTag&64)!==0)||(a=(o&2)!==0&&(e===null||e.memoizedState!==null)),a?(s=!0,n.effectTag&=-65):e!==null&&e.memoizedState===null||i.fallback===void 0||i.unstable_avoidThisFallback===!0||(o|=1),ol(Qs,o&1),e===null){if(i.fallback!==void 0&&e6(n),s){if(s=i.fallback,i=Am(null,r,0,null),i.return=n,!(n.mode&2))for(e=n.memoizedState!==null?n.child.child:n.child,i.child=e;e!==null;)e.return=i,e=e.sibling;return t=Am(s,r,t,null),t.return=n,i.sibling=t,n.memoizedState=Nw,n.child=i,t}return r=i.children,n.memoizedState=null,n.child=HO(n,null,r,t)}if(e.memoizedState!==null){if(e=e.child,r=e.sibling,s){if(i=i.fallback,t=s1(e,e.pendingProps),t.return=n,!(n.mode&2)&&(s=n.memoizedState!==null?n.child.child:n.child,s!==e.child))for(t.child=s;s!==null;)s.return=t,s=s.sibling;return r=s1(r,i),r.return=n,t.sibling=r,t.childExpirationTime=0,n.memoizedState=Nw,n.child=t,r}return t=vy(n,e.child,i.children,t),n.memoizedState=null,n.child=t}if(e=e.child,s){if(s=i.fallback,i=Am(null,r,0,null),i.return=n,i.child=e,e!==null&&(e.return=i),!(n.mode&2))for(e=n.memoizedState!==null?n.child.child:n.child,i.child=e;e!==null;)e.return=i,e=e.sibling;return t=Am(s,r,t,null),t.return=n,i.sibling=t,t.effectTag|=2,i.childExpirationTime=0,n.memoizedState=Nw,n.child=i,t}return n.memoizedState=null,n.child=vy(n,e,i.children,t)}function dI(e,n){e.expirationTime<n&&(e.expirationTime=n);var t=e.alternate;t!==null&&t.expirationTime<n&&(t.expirationTime=n),UD(e.return,n)}function Gw(e,n,t,r,i,o){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:r,tail:t,tailExpiration:0,tailMode:i,lastEffect:o}:(s.isBackwards=n,s.rendering=null,s.renderingStartTime=0,s.last=r,s.tail=t,s.tailExpiration=0,s.tailMode=i,s.lastEffect=o)}function hI(e,n,t){var r=n.pendingProps,i=r.revealOrder,o=r.tail;if(Tc(e,n,r.children,t),r=Qs.current,r&2)r=r&1|2,n.effectTag|=64;else{if(e!==null&&e.effectTag&64)e:for(e=n.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&dI(e,t);else if(e.tag===19)dI(e,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===n)break e;for(;e.sibling===null;){if(e.return===null||e.return===n)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(ol(Qs,r),!(n.mode&2))n.memoizedState=null;else switch(i){case"forwards":for(t=n.child,i=null;t!==null;)e=t.alternate,e!==null&&W2(e)===null&&(i=t),t=t.sibling;t=i,t===null?(i=n.child,n.child=null):(i=t.sibling,t.sibling=null),Gw(n,!1,i,t,o,n.lastEffect);break;case"backwards":for(t=null,i=n.child,n.child=null;i!==null;){if(e=i.alternate,e!==null&&W2(e)===null){n.child=i;break}e=i.sibling,i.sibling=t,t=i,i=e}Gw(n,!0,t,null,o,n.lastEffect);break;case"together":Gw(n,!1,null,null,void 0,n.lastEffect);break;default:n.memoizedState=null}return n.child}function yp(e,n,t){e!==null&&(n.dependencies=e.dependencies);var r=n.expirationTime;if(r!==0&&L4(r),n.childExpirationTime<t)return null;if(e!==null&&n.child!==e.child)throw Error(Ln(153));if(n.child!==null){for(e=n.child,t=s1(e,e.pendingProps),n.child=t,t.return=n;e.sibling!==null;)e=e.sibling,t=t.sibling=s1(e,e.pendingProps),t.return=n;t.sibling=null}return n.child}var HD,r6,ZD,XD;HD=function(e,n){for(var t=n.child;t!==null;){if(t.tag===5||t.tag===6)e.appendChild(t.stateNode);else if(t.tag!==4&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===n)break;for(;t.sibling===null;){if(t.return===null||t.return===n)return;t=t.return}t.sibling.return=t.return,t=t.sibling}};r6=function(){};ZD=function(e,n,t,r,i){var o=e.memoizedProps;if(o!==r){var s=n.stateNode;switch(U0(rf.current),e=null,t){case"input":o=BS(s,o),r=BS(s,r),e=[];break;case"option":o=TS(s,o),r=TS(s,r),e=[];break;case"select":o=yA({},o,{value:void 0}),r=yA({},r,{value:void 0}),e=[];break;case"textarea":o=KS(s,o),r=KS(s,r),e=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(s.onclick=P2)}LS(t,r);var a,f;t=null;for(a in o)if(!r.hasOwnProperty(a)&&o.hasOwnProperty(a)&&o[a]!=null)if(a==="style")for(f in s=o[a],s)s.hasOwnProperty(f)&&(t||(t={}),t[f]="");else a!=="dangerouslySetInnerHTML"&&a!=="children"&&a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(py.hasOwnProperty(a)?e||(e=[]):(e=e||[]).push(a,null));for(a in r){var g=r[a];if(s=o!=null?o[a]:void 0,r.hasOwnProperty(a)&&g!==s&&(g!=null||s!=null))if(a==="style")if(s){for(f in s)!s.hasOwnProperty(f)||g&&g.hasOwnProperty(f)||(t||(t={}),t[f]="");for(f in g)g.hasOwnProperty(f)&&s[f]!==g[f]&&(t||(t={}),t[f]=g[f])}else t||(e||(e=[]),e.push(a,t)),t=g;else a==="dangerouslySetInnerHTML"?(g=g?g.__html:void 0,s=s?s.__html:void 0,g!=null&&s!==g&&(e=e||[]).push(a,g)):a==="children"?s===g||typeof g!="string"&&typeof g!="number"||(e=e||[]).push(a,""+g):a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&(py.hasOwnProperty(a)?(g!=null&&tp(i,a),e||s===g||(e=[])):(e=e||[]).push(a,g))}t&&(e=e||[]).push("style",t),i=e,(n.updateQueue=i)&&(n.effectTag|=4)}};XD=function(e,n,t,r){t!==r&&(n.effectTag|=4)};function dx(e,n){switch(e.tailMode){case"hidden":n=e.tail;for(var t=null;n!==null;)n.alternate!==null&&(t=n),n=n.sibling;t===null?e.tail=null:t.sibling=null;break;case"collapsed":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?n||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function XY(e,n,t){var r=n.pendingProps;switch(n.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return GA(n.type)&&U2(),null;case 3:return Cy(),hs(NA),hs(qu),t=n.stateNode,t.pendingContext&&(t.context=t.pendingContext,t.pendingContext=null),e!==null&&e.child!==null||!cx(n)||(n.effectTag|=4),r6(n),null;case 5:ZO(n),t=U0(XC.current);var i=n.type;if(e!==null&&n.stateNode!=null)ZD(e,n,i,r,t),e.ref!==n.ref&&(n.effectTag|=128);else{if(!r){if(n.stateNode===null)throw Error(Ln(166));return null}if(e=U0(rf.current),cx(n)){r=n.stateNode,i=n.type;var o=n.memoizedProps;switch(r[am]=n,r[F2]=o,i){case"iframe":case"object":case"embed":Ks("load",r);break;case"video":case"audio":for(e=0;e<nC.length;e++)Ks(nC[e],r);break;case"source":Ks("error",r);break;case"img":case"image":case"link":Ks("error",r),Ks("load",r);break;case"form":Ks("reset",r),Ks("submit",r);break;case"details":Ks("toggle",r);break;case"input":wk(r,o),Ks("invalid",r),tp(t,"onChange");break;case"select":r._wrapperState={wasMultiple:!!o.multiple},Ks("invalid",r),tp(t,"onChange");break;case"textarea":Sk(r,o),Ks("invalid",r),tp(t,"onChange")}LS(i,o),e=null;for(var s in o)if(o.hasOwnProperty(s)){var a=o[s];s==="children"?typeof a=="string"?r.textContent!==a&&(e=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(e=["children",""+a]):py.hasOwnProperty(s)&&a!=null&&tp(t,s)}switch(i){case"input":ix(r),Mk(r,o,!0);break;case"textarea":ix(r),Ek(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=P2)}t=e,n.updateQueue=t,t!==null&&(n.effectTag|=4)}else{switch(s=t.nodeType===9?t:t.ownerDocument,e===Kk&&(e=QF(i)),e===Kk?i==="script"?(e=s.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(i,{is:r.is}):(e=s.createElement(i),i==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,i),e[am]=n,e[F2]=r,HD(e,n,!1,!1),n.stateNode=e,s=zS(i,r),i){case"iframe":case"object":case"embed":Ks("load",e),a=r;break;case"video":case"audio":for(a=0;a<nC.length;a++)Ks(nC[a],e);a=r;break;case"source":Ks("error",e),a=r;break;case"img":case"image":case"link":Ks("error",e),Ks("load",e),a=r;break;case"form":Ks("reset",e),Ks("submit",e),a=r;break;case"details":Ks("toggle",e),a=r;break;case"input":wk(e,r),a=BS(e,r),Ks("invalid",e),tp(t,"onChange");break;case"option":a=TS(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},a=yA({},r,{value:void 0}),Ks("invalid",e),tp(t,"onChange");break;case"textarea":Sk(e,r),a=KS(e,r),Ks("invalid",e),tp(t,"onChange");break;default:a=r}LS(i,a);var f=a;for(o in f)if(f.hasOwnProperty(o)){var g=f[o];o==="style"?AD(e,g):o==="dangerouslySetInnerHTML"?(g=g?g.__html:void 0,g!=null&&$F(e,g)):o==="children"?typeof g=="string"?(i!=="textarea"||g!=="")&&QC(e,g):typeof g=="number"&&QC(e,""+g):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(py.hasOwnProperty(o)?g!=null&&tp(t,o):g!=null&&EO(e,o,g,s))}switch(i){case"input":ix(e),Mk(e,r,!1);break;case"textarea":ix(e),Ek(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Im(r.value));break;case"select":e.multiple=!!r.multiple,t=r.value,t!=null?Yg(e,!!r.multiple,t,!1):r.defaultValue!=null&&Yg(e,!!r.multiple,r.defaultValue,!0);break;default:typeof a.onClick=="function"&&(e.onclick=P2)}fD(i,r)&&(n.effectTag|=4)}n.ref!==null&&(n.effectTag|=128)}return null;case 6:if(e&&n.stateNode!=null)XD(e,n,e.memoizedProps,r);else{if(typeof r!="string"&&n.stateNode===null)throw Error(Ln(166));t=U0(XC.current),U0(rf.current),cx(n)?(t=n.stateNode,r=n.memoizedProps,t[am]=n,t.nodeValue!==r&&(n.effectTag|=4)):(t=(t.nodeType===9?t:t.ownerDocument).createTextNode(r),t[am]=n,n.stateNode=t)}return null;case 13:return hs(Qs),r=n.memoizedState,n.effectTag&64?(n.expirationTime=t,n):(t=r!==null,r=!1,e===null?n.memoizedProps.fallback!==void 0&&cx(n):(i=e.memoizedState,r=i!==null,t||i===null||(i=e.child.sibling,i!==null&&(o=n.firstEffect,o!==null?(n.firstEffect=i,i.nextEffect=o):(n.firstEffect=n.lastEffect=i,i.nextEffect=null),i.effectTag=8))),t&&!r&&n.mode&2&&(e===null&&n.memoizedProps.unstable_avoidThisFallback!==!0||Qs.current&1?au===q0&&(au=V2):((au===q0||au===V2)&&(au=D4),e_!==0&&Lc!==null&&(z0(Lc,QA),yU(Lc,e_)))),(t||r)&&(n.effectTag|=4),null);case 4:return Cy(),r6(n),null;case 10:return YO(n),null;case 17:return GA(n.type)&&U2(),null;case 19:if(hs(Qs),r=n.memoizedState,r===null)return null;if(i=(n.effectTag&64)!==0,o=r.rendering,o===null){if(i)dx(r,!1);else if(au!==q0||e!==null&&e.effectTag&64)for(o=n.child;o!==null;){if(e=W2(o),e!==null){for(n.effectTag|=64,dx(r,!1),i=e.updateQueue,i!==null&&(n.updateQueue=i,n.effectTag|=4),r.lastEffect===null&&(n.firstEffect=null),n.lastEffect=r.lastEffect,r=n.child;r!==null;)i=r,o=t,i.effectTag&=2,i.nextEffect=null,i.firstEffect=null,i.lastEffect=null,e=i.alternate,e===null?(i.childExpirationTime=0,i.expirationTime=o,i.child=null,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null):(i.childExpirationTime=e.childExpirationTime,i.expirationTime=e.expirationTime,i.child=e.child,i.memoizedProps=e.memoizedProps,i.memoizedState=e.memoizedState,i.updateQueue=e.updateQueue,o=e.dependencies,i.dependencies=o===null?null:{expirationTime:o.expirationTime,firstContext:o.firstContext,responders:o.responders}),r=r.sibling;return ol(Qs,Qs.current&1|2),n.child}o=o.sibling}}else{if(!i)if(e=W2(o),e!==null){if(n.effectTag|=64,i=!0,t=e.updateQueue,t!==null&&(n.updateQueue=t,n.effectTag|=4),dx(r,!0),r.tail===null&&r.tailMode==="hidden"&&!o.alternate)return n=n.lastEffect=r.lastEffect,n!==null&&(n.nextEffect=null),null}else 2*vd()-r.renderingStartTime>r.tailExpiration&&1<t&&(n.effectTag|=64,i=!0,dx(r,!1),n.expirationTime=n.childExpirationTime=t-1);r.isBackwards?(o.sibling=n.child,n.child=o):(t=r.last,t!==null?t.sibling=o:n.child=o,r.last=o)}return r.tail!==null?(r.tailExpiration===0&&(r.tailExpiration=vd()+500),t=r.tail,r.rendering=t,r.tail=t.sibling,r.lastEffect=n.lastEffect,r.renderingStartTime=vd(),t.sibling=null,n=Qs.current,ol(Qs,i?n&1|2:n&1),t):null}throw Error(Ln(156,n.tag))}function JY(e){switch(e.tag){case 1:GA(e.type)&&U2();var n=e.effectTag;return n&4096?(e.effectTag=n&-4097|64,e):null;case 3:if(Cy(),hs(NA),hs(qu),n=e.effectTag,n&64)throw Error(Ln(285));return e.effectTag=n&-4097|64,e;case 5:return ZO(e),null;case 13:return hs(Qs),n=e.effectTag,n&4096?(e.effectTag=n&-4097|64,e):null;case 19:return hs(Qs),null;case 4:return Cy(),null;case 10:return YO(e),null;default:return null}}function iB(e,n){return{value:e,source:n,stack:kO(n)}}var eq=typeof WeakSet=="function"?WeakSet:Set;function i6(e,n){var t=n.source,r=n.stack;r===null&&t!==null&&(r=kO(t)),t!==null&&vp(t.type),n=n.value,e!==null&&e.tag===1&&vp(e.type);try{console.error(n)}catch(i){setTimeout(function(){throw i})}}function tq(e,n){try{n.props=e.memoizedProps,n.state=e.memoizedState,n.componentWillUnmount()}catch(t){H0(e,t)}}function fI(e){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(t){H0(e,t)}else n.current=null}function nq(e,n){switch(n.tag){case 0:case 11:case 15:case 22:return;case 1:if(n.effectTag&256&&e!==null){var t=e.memoizedProps,r=e.memoizedState;e=n.stateNode,n=e.getSnapshotBeforeUpdate(n.elementType===n.type?t:sh(n.type,t),r),e.__reactInternalSnapshotBeforeUpdate=n}return;case 3:case 5:case 6:case 4:case 17:return}throw Error(Ln(163))}function JD(e,n){if(n=n.updateQueue,n=n!==null?n.lastEffect:null,n!==null){var t=n=n.next;do{if((t.tag&e)===e){var r=t.destroy;t.destroy=void 0,r!==void 0&&r()}t=t.next}while(t!==n)}}function eU(e,n){if(n=n.updateQueue,n=n!==null?n.lastEffect:null,n!==null){var t=n=n.next;do{if((t.tag&e)===e){var r=t.create;t.destroy=r()}t=t.next}while(t!==n)}}function rq(e,n,t){switch(t.tag){case 0:case 11:case 15:case 22:eU(3,t);return;case 1:if(e=t.stateNode,t.effectTag&4)if(n===null)e.componentDidMount();else{var r=t.elementType===t.type?n.memoizedProps:sh(t.type,n.memoizedProps);e.componentDidUpdate(r,n.memoizedState,e.__reactInternalSnapshotBeforeUpdate)}n=t.updateQueue,n!==null&&Jk(t,n,e);return;case 3:if(n=t.updateQueue,n!==null){if(e=null,t.child!==null)switch(t.child.tag){case 5:e=t.child.stateNode;break;case 1:e=t.child.stateNode}Jk(t,n,e)}return;case 5:e=t.stateNode,n===null&&t.effectTag&4&&fD(t.type,t.memoizedProps)&&e.focus();return;case 6:return;case 4:return;case 12:return;case 13:t.memoizedState===null&&(t=t.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&aD(t))));return;case 19:case 17:case 20:case 21:return}throw Error(Ln(163))}function pI(e,n,t){switch(typeof d6=="function"&&d6(n),n.tag){case 0:case 11:case 14:case 15:case 22:if(e=n.updateQueue,e!==null&&(e=e.lastEffect,e!==null)){var r=e.next;Km(97<t?97:t,function(){var i=r;do{var o=i.destroy;if(o!==void 0){var s=n;try{o()}catch(a){H0(s,a)}}i=i.next}while(i!==r)})}break;case 1:fI(n),t=n.stateNode,typeof t.componentWillUnmount=="function"&&tq(n,t);break;case 5:fI(n);break;case 4:nU(e,n,t)}}function tU(e){var n=e.alternate;e.return=null,e.child=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.alternate=null,e.firstEffect=null,e.lastEffect=null,e.pendingProps=null,e.memoizedProps=null,e.stateNode=null,n!==null&&tU(n)}function mI(e){return e.tag===5||e.tag===3||e.tag===4}function gI(e){e:{for(var n=e.return;n!==null;){if(mI(n)){var t=n;break e}n=n.return}throw Error(Ln(160))}switch(n=t.stateNode,t.tag){case 5:var r=!1;break;case 3:n=n.containerInfo,r=!0;break;case 4:n=n.containerInfo,r=!0;break;default:throw Error(Ln(161))}t.effectTag&16&&(QC(n,""),t.effectTag&=-17);e:t:for(t=e;;){for(;t.sibling===null;){if(t.return===null||mI(t.return)){t=null;break e}t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.effectTag&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.effectTag&2)){t=t.stateNode;break e}}r?o6(e,t,n):a6(e,t,n)}function o6(e,n,t){var r=e.tag,i=r===5||r===6;if(i)e=i?e.stateNode:e.stateNode.instance,n?t.nodeType===8?t.parentNode.insertBefore(e,n):t.insertBefore(e,n):(t.nodeType===8?(n=t.parentNode,n.insertBefore(e,t)):(n=t,n.appendChild(e)),t=t._reactRootContainer,t!=null||n.onclick!==null||(n.onclick=P2));else if(r!==4&&(e=e.child,e!==null))for(o6(e,n,t),e=e.sibling;e!==null;)o6(e,n,t),e=e.sibling}function a6(e,n,t){var r=e.tag,i=r===5||r===6;if(i)e=i?e.stateNode:e.stateNode.instance,n?t.insertBefore(e,n):t.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(a6(e,n,t),e=e.sibling;e!==null;)a6(e,n,t),e=e.sibling}function nU(e,n,t){for(var r=n,i=!1,o,s;;){if(!i){i=r.return;e:for(;;){if(i===null)throw Error(Ln(160));switch(o=i.stateNode,i.tag){case 5:s=!1;break e;case 3:o=o.containerInfo,s=!0;break e;case 4:o=o.containerInfo,s=!0;break e}i=i.return}i=!0}if(r.tag===5||r.tag===6){e:for(var a=e,f=r,g=t,x=f;;)if(pI(a,x,g),x.child!==null&&x.tag!==4)x.child.return=x,x=x.child;else{if(x===f)break e;for(;x.sibling===null;){if(x.return===null||x.return===f)break e;x=x.return}x.sibling.return=x.return,x=x.sibling}s?(a=o,f=r.stateNode,a.nodeType===8?a.parentNode.removeChild(f):a.removeChild(f)):o.removeChild(r.stateNode)}else if(r.tag===4){if(r.child!==null){o=r.stateNode.containerInfo,s=!0,r.child.return=r,r=r.child;continue}}else if(pI(e,r,t),r.child!==null){r.child.return=r,r=r.child;continue}if(r===n)break;for(;r.sibling===null;){if(r.return===null||r.return===n)return;r=r.return,r.tag===4&&(i=!1)}r.sibling.return=r.return,r=r.sibling}}function Qw(e,n){switch(n.tag){case 0:case 11:case 14:case 15:case 22:JD(3,n);return;case 1:return;case 5:var t=n.stateNode;if(t!=null){var r=n.memoizedProps,i=e!==null?e.memoizedProps:r;e=n.type;var o=n.updateQueue;if(n.updateQueue=null,o!==null){for(t[F2]=r,e==="input"&&r.type==="radio"&&r.name!=null&&WF(t,r),zS(e,i),n=zS(e,r),i=0;i<o.length;i+=2){var s=o[i],a=o[i+1];s==="style"?AD(t,a):s==="dangerouslySetInnerHTML"?$F(t,a):s==="children"?QC(t,a):EO(t,s,a,n)}switch(e){case"input":kS(t,r);break;case"textarea":NF(t,r);break;case"select":n=t._wrapperState.wasMultiple,t._wrapperState.wasMultiple=!!r.multiple,e=r.value,e!=null?Yg(t,!!r.multiple,e,!1):n!==!!r.multiple&&(r.defaultValue!=null?Yg(t,!!r.multiple,r.defaultValue,!0):Yg(t,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(n.stateNode===null)throw Error(Ln(162));n.stateNode.nodeValue=n.memoizedProps;return;case 3:n=n.stateNode,n.hydrate&&(n.hydrate=!1,aD(n.containerInfo));return;case 12:return;case 13:if(t=n,n.memoizedState===null?r=!1:(r=!0,t=n.child,sB=vd()),t!==null)e:for(e=t;;){if(e.tag===5)o=e.stateNode,r?(o=o.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(o=e.stateNode,i=e.memoizedProps.style,i=i!=null&&i.hasOwnProperty("display")?i.display:null,o.style.display=uD("display",i));else if(e.tag===6)e.stateNode.nodeValue=r?"":e.memoizedProps;else if(e.tag===13&&e.memoizedState!==null&&e.memoizedState.dehydrated===null){o=e.child.sibling,o.return=e,e=o;continue}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}yI(n);return;case 19:yI(n);return;case 17:return}throw Error(Ln(163))}function yI(e){var n=e.updateQueue;if(n!==null){e.updateQueue=null;var t=e.stateNode;t===null&&(t=e.stateNode=new eq),n.forEach(function(r){var i=hq.bind(null,e,r);t.has(r)||(t.add(r),r.then(i,i))})}}var iq=typeof WeakMap=="function"?WeakMap:Map;function rU(e,n,t){t=_m(t,null),t.tag=3,t.payload={element:null};var r=n.value;return t.callback=function(){X2||(X2=!0,s6=r),i6(e,n)},t}function iU(e,n,t){t=_m(t,null),t.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=n.value;t.payload=function(){return i6(e,n),r(i)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(t.callback=function(){typeof r!="function"&&(xm===null?xm=new Set([this]):xm.add(this),i6(e,n));var s=n.stack;this.componentDidCatch(n.value,{componentStack:s!==null?s:""})}),t}var oq=Math.ceil,Y2=dh.ReactCurrentDispatcher,oU=dh.ReactCurrentOwner,su=0,oB=8,hh=16,lf=32,q0=0,q2=1,aU=2,V2=3,D4=4,aB=5,Ri=su,Lc=null,eo=null,QA=0,au=q0,U4=null,hp=1073741823,JC=1073741823,H2=null,e_=0,Z2=!1,sB=0,sU=500,$r=null,X2=!1,s6=null,xm=null,J2=!1,wC=null,iC=90,R0=null,MC=0,l6=null,A2=0;function of(){return(Ri&(hh|lf))!==su?1073741821-(vd()/10|0):A2!==0?A2:A2=1073741821-(vd()/10|0)}function V0(e,n,t){if(n=n.mode,!(n&2))return 1073741823;var r=P4();if(!(n&4))return r===99?1073741823:1073741822;if((Ri&hh)!==su)return QA;if(t!==null)e=l2(e,t.timeoutMs|0||5e3,250);else switch(r){case 99:e=1073741823;break;case 98:e=l2(e,150,100);break;case 97:case 96:e=l2(e,5e3,250);break;case 95:e=2;break;default:throw Error(Ln(326))}return Lc!==null&&e===QA&&--e,e}function wm(e,n){if(50<MC)throw MC=0,l6=null,Error(Ln(185));if(e=R4(e,n),e!==null){var t=P4();n===1073741823?(Ri&oB)!==su&&(Ri&(hh|lf))===su?u6(e):(zc(e),Ri===su&&gf()):zc(e),(Ri&4)===su||t!==98&&t!==99||(R0===null?R0=new Map([[e,n]]):(t=R0.get(e),(t===void 0||t>n)&&R0.set(e,n)))}}function R4(e,n){e.expirationTime<n&&(e.expirationTime=n);var t=e.alternate;t!==null&&t.expirationTime<n&&(t.expirationTime=n);var r=e.return,i=null;if(r===null&&e.tag===3)i=e.stateNode;else for(;r!==null;){if(t=r.alternate,r.childExpirationTime<n&&(r.childExpirationTime=n),t!==null&&t.childExpirationTime<n&&(t.childExpirationTime=n),r.return===null&&r.tag===3){i=r.stateNode;break}r=r.return}return i!==null&&(Lc===i&&(L4(n),au===D4&&z0(i,QA)),yU(i,n)),i}function c2(e){var n=e.lastExpiredTime;if(n!==0||(n=e.firstPendingTime,!gU(e,n)))return n;var t=e.lastPingedTime;return e=e.nextKnownPendingLevel,e=t>e?t:e,2>=e&&n!==e?0:e}function zc(e){if(e.lastExpiredTime!==0)e.callbackExpirationTime=1073741823,e.callbackPriority=99,e.callbackNode=Zk(u6.bind(null,e));else{var n=c2(e),t=e.callbackNode;if(n===0)t!==null&&(e.callbackNode=null,e.callbackExpirationTime=0,e.callbackPriority=90);else{var r=of();if(n===1073741823?r=99:n===1||n===2?r=95:(r=10*(1073741821-n)-10*(1073741821-r),r=0>=r?99:250>=r?98:5250>=r?97:95),t!==null){var i=e.callbackPriority;if(e.callbackExpirationTime===n&&i>=r)return;t!==KD&&OD(t)}e.callbackExpirationTime=n,e.callbackPriority=r,n=n===1073741823?Zk(u6.bind(null,e)):FD(r,lU.bind(null,e),{timeout:10*(1073741821-n)-vd()}),e.callbackNode=n}}}function lU(e,n){if(A2=0,n)return n=of(),h6(e,n),zc(e),null;var t=c2(e);if(t!==0){if(n=e.callbackNode,(Ri&(hh|lf))!==su)throw Error(Ln(327));if(Py(),e===Lc&&t===QA||L0(e,t),eo!==null){var r=Ri;Ri|=hh;var i=dU();do try{lq();break}catch(a){cU(e,a)}while(!0);if($O(),Ri=r,Y2.current=i,au===q2)throw n=U4,L0(e,t),z0(e,t),zc(e),n;if(eo===null)switch(i=e.finishedWork=e.current.alternate,e.finishedExpirationTime=t,r=au,Lc=null,r){case q0:case q2:throw Error(Ln(345));case aU:h6(e,2<t?2:t);break;case V2:if(z0(e,t),r=e.lastSuspendedTime,t===r&&(e.nextKnownPendingLevel=A6(i)),hp===1073741823&&(i=sB+sU-vd(),10<i)){if(Z2){var o=e.lastPingedTime;if(o===0||o>=t){e.lastPingedTime=t,L0(e,t);break}}if(o=c2(e),o!==0&&o!==t)break;if(r!==0&&r!==t){e.lastPingedTime=r;break}e.timeoutHandle=Lw(M0.bind(null,e),i);break}M0(e);break;case D4:if(z0(e,t),r=e.lastSuspendedTime,t===r&&(e.nextKnownPendingLevel=A6(i)),Z2&&(i=e.lastPingedTime,i===0||i>=t)){e.lastPingedTime=t,L0(e,t);break}if(i=c2(e),i!==0&&i!==t)break;if(r!==0&&r!==t){e.lastPingedTime=r;break}if(JC!==1073741823?r=10*(1073741821-JC)-vd():hp===1073741823?r=0:(r=10*(1073741821-hp)-5e3,i=vd(),t=10*(1073741821-t)-i,r=i-r,0>r&&(r=0),r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*oq(r/1960))-r,t<r&&(r=t)),10<r){e.timeoutHandle=Lw(M0.bind(null,e),r);break}M0(e);break;case aB:if(hp!==1073741823&&H2!==null){o=hp;var s=H2;if(r=s.busyMinDurationMs|0,0>=r?r=0:(i=s.busyDelayMs|0,o=vd()-(10*(1073741821-o)-(s.timeoutMs|0||5e3)),r=o<=i?0:i+r-o),10<r){z0(e,t),e.timeoutHandle=Lw(M0.bind(null,e),r);break}}M0(e);break;default:throw Error(Ln(329))}if(zc(e),e.callbackNode===n)return lU.bind(null,e)}}return null}function u6(e){var n=e.lastExpiredTime;if(n=n!==0?n:1073741823,(Ri&(hh|lf))!==su)throw Error(Ln(327));if(Py(),e===Lc&&n===QA||L0(e,n),eo!==null){var t=Ri;Ri|=hh;var r=dU();do try{sq();break}catch(i){cU(e,i)}while(!0);if($O(),Ri=t,Y2.current=r,au===q2)throw t=U4,L0(e,n),z0(e,n),zc(e),t;if(eo!==null)throw Error(Ln(261));e.finishedWork=e.current.alternate,e.finishedExpirationTime=n,Lc=null,M0(e),zc(e)}return null}function aq(){if(R0!==null){var e=R0;R0=null,e.forEach(function(n,t){h6(t,n),zc(t)}),gf()}}function uU(e,n){var t=Ri;Ri|=1;try{return e(n)}finally{Ri=t,Ri===su&&gf()}}function AU(e,n){var t=Ri;Ri&=-2,Ri|=oB;try{return e(n)}finally{Ri=t,Ri===su&&gf()}}function L0(e,n){e.finishedWork=null,e.finishedExpirationTime=0;var t=e.timeoutHandle;if(t!==-1&&(e.timeoutHandle=-1,oY(t)),eo!==null)for(t=eo.return;t!==null;){var r=t;switch(r.tag){case 1:r=r.type.childContextTypes,r!=null&&U2();break;case 3:Cy(),hs(NA),hs(qu);break;case 5:ZO(r);break;case 4:Cy();break;case 13:hs(Qs);break;case 19:hs(Qs);break;case 10:YO(r)}t=t.return}Lc=e,eo=s1(e.current,null),QA=n,au=q0,U4=null,JC=hp=1073741823,H2=null,e_=0,Z2=!1}function cU(e,n){do{try{if($O(),u2.current=$2,N2)for(var t=Nl.memoizedState;t!==null;){var r=t.queue;r!==null&&(r.pending=null),t=t.next}if(lm=0,Yu=$u=Nl=null,N2=!1,eo===null||eo.return===null)return au=q2,U4=n,eo=null;e:{var i=e,o=eo.return,s=eo,a=n;if(n=QA,s.effectTag|=2048,s.firstEffect=s.lastEffect=null,a!==null&&typeof a=="object"&&typeof a.then=="function"){var f=a;if(!(s.mode&2)){var g=s.alternate;g?(s.updateQueue=g.updateQueue,s.memoizedState=g.memoizedState,s.expirationTime=g.expirationTime):(s.updateQueue=null,s.memoizedState=null)}var x=(Qs.current&1)!==0,k=o;do{var B;if(B=k.tag===13){var P=k.memoizedState;if(P!==null)B=P.dehydrated!==null;else{var R=k.memoizedProps;B=R.fallback===void 0?!1:R.unstable_avoidThisFallback!==!0?!0:!x}}if(B){var H=k.updateQueue;if(H===null){var W=new Set;W.add(f),k.updateQueue=W}else H.add(f);if(!(k.mode&2)){if(k.effectTag|=64,s.effectTag&=-2981,s.tag===1)if(s.alternate===null)s.tag=17;else{var $=_m(1073741823,null);$.tag=2,bm(s,$)}s.expirationTime=1073741823;break e}a=void 0,s=n;var q=i.pingCache;if(q===null?(q=i.pingCache=new iq,a=new Set,q.set(f,a)):(a=q.get(f),a===void 0&&(a=new Set,q.set(f,a))),!a.has(s)){a.add(s);var oe=dq.bind(null,i,f,s);f.then(oe,oe)}k.effectTag|=4096,k.expirationTime=n;break e}k=k.return}while(k!==null);a=Error((vp(s.type)||"A React component")+` suspended while rendering, but no fallback UI was specified.
|
||
|
||
Add a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.`+kO(s))}au!==aB&&(au=aU),a=iB(a,s),k=o;do{switch(k.tag){case 3:f=a,k.effectTag|=4096,k.expirationTime=n;var ne=rU(k,f,n);Xk(k,ne);break e;case 1:f=a;var ce=k.type,ae=k.stateNode;if(!(k.effectTag&64)&&(typeof ce.getDerivedStateFromError=="function"||ae!==null&&typeof ae.componentDidCatch=="function"&&(xm===null||!xm.has(ae)))){k.effectTag|=4096,k.expirationTime=n;var ue=iU(k,f,n);Xk(k,ue);break e}}k=k.return}while(k!==null)}eo=pU(eo)}catch(ye){n=ye;continue}break}while(!0)}function dU(){var e=Y2.current;return Y2.current=$2,e===null?$2:e}function hU(e,n){e<hp&&2<e&&(hp=e),n!==null&&e<JC&&2<e&&(JC=e,H2=n)}function L4(e){e>e_&&(e_=e)}function sq(){for(;eo!==null;)eo=fU(eo)}function lq(){for(;eo!==null&&!$Y();)eo=fU(eo)}function fU(e){var n=mU(e.alternate,e,QA);return e.memoizedProps=e.pendingProps,n===null&&(n=pU(e)),oU.current=null,n}function pU(e){eo=e;do{var n=eo.alternate;if(e=eo.return,eo.effectTag&2048){if(n=JY(eo),n!==null)return n.effectTag&=2047,n;e!==null&&(e.firstEffect=e.lastEffect=null,e.effectTag|=2048)}else{if(n=XY(n,eo,QA),QA===1||eo.childExpirationTime!==1){for(var t=0,r=eo.child;r!==null;){var i=r.expirationTime,o=r.childExpirationTime;i>t&&(t=i),o>t&&(t=o),r=r.sibling}eo.childExpirationTime=t}if(n!==null)return n;e!==null&&!(e.effectTag&2048)&&(e.firstEffect===null&&(e.firstEffect=eo.firstEffect),eo.lastEffect!==null&&(e.lastEffect!==null&&(e.lastEffect.nextEffect=eo.firstEffect),e.lastEffect=eo.lastEffect),1<eo.effectTag&&(e.lastEffect!==null?e.lastEffect.nextEffect=eo:e.firstEffect=eo,e.lastEffect=eo))}if(n=eo.sibling,n!==null)return n;eo=e}while(eo!==null);return au===q0&&(au=aB),null}function A6(e){var n=e.expirationTime;return e=e.childExpirationTime,n>e?n:e}function M0(e){var n=P4();return Km(99,uq.bind(null,e,n)),null}function uq(e,n){do Py();while(wC!==null);if((Ri&(hh|lf))!==su)throw Error(Ln(327));var t=e.finishedWork,r=e.finishedExpirationTime;if(t===null)return null;if(e.finishedWork=null,e.finishedExpirationTime=0,t===e.current)throw Error(Ln(177));e.callbackNode=null,e.callbackExpirationTime=0,e.callbackPriority=90,e.nextKnownPendingLevel=0;var i=A6(t);if(e.firstPendingTime=i,r<=e.lastSuspendedTime?e.firstSuspendedTime=e.lastSuspendedTime=e.nextKnownPendingLevel=0:r<=e.firstSuspendedTime&&(e.firstSuspendedTime=r-1),r<=e.lastPingedTime&&(e.lastPingedTime=0),r<=e.lastExpiredTime&&(e.lastExpiredTime=0),e===Lc&&(eo=Lc=null,QA=0),1<t.effectTag?t.lastEffect!==null?(t.lastEffect.nextEffect=t,i=t.firstEffect):i=t:i=t.firstEffect,i!==null){var o=Ri;Ri|=lf,oU.current=null,Uw=n2;var s=Dk();if(WS(s)){if("selectionStart"in s)var a={start:s.selectionStart,end:s.selectionEnd};else e:{a=(a=s.ownerDocument)&&a.defaultView||window;var f=a.getSelection&&a.getSelection();if(f&&f.rangeCount!==0){a=f.anchorNode;var g=f.anchorOffset,x=f.focusNode;f=f.focusOffset;try{a.nodeType,x.nodeType}catch{a=null;break e}var k=0,B=-1,P=-1,R=0,H=0,W=s,$=null;t:for(;;){for(var q;W!==a||g!==0&&W.nodeType!==3||(B=k+g),W!==x||f!==0&&W.nodeType!==3||(P=k+f),W.nodeType===3&&(k+=W.nodeValue.length),(q=W.firstChild)!==null;)$=W,W=q;for(;;){if(W===s)break t;if($===a&&++R===g&&(B=k),$===x&&++H===f&&(P=k),(q=W.nextSibling)!==null)break;W=$,$=W.parentNode}W=q}a=B===-1||P===-1?null:{start:B,end:P}}else a=null}a=a||{start:0,end:0}}else a=null;Rw={activeElementDetached:null,focusedElem:s,selectionRange:a},n2=!1,$r=i;do try{Aq()}catch(Re){if($r===null)throw Error(Ln(330));H0($r,Re),$r=$r.nextEffect}while($r!==null);$r=i;do try{for(s=e,a=n;$r!==null;){var oe=$r.effectTag;if(oe&16&&QC($r.stateNode,""),oe&128){var ne=$r.alternate;if(ne!==null){var ce=ne.ref;ce!==null&&(typeof ce=="function"?ce(null):ce.current=null)}}switch(oe&1038){case 2:gI($r),$r.effectTag&=-3;break;case 6:gI($r),$r.effectTag&=-3,Qw($r.alternate,$r);break;case 1024:$r.effectTag&=-1025;break;case 1028:$r.effectTag&=-1025,Qw($r.alternate,$r);break;case 4:Qw($r.alternate,$r);break;case 8:g=$r,nU(s,g,a),tU(g)}$r=$r.nextEffect}}catch(Re){if($r===null)throw Error(Ln(330));H0($r,Re),$r=$r.nextEffect}while($r!==null);if(ce=Rw,ne=Dk(),oe=ce.focusedElem,a=ce.selectionRange,ne!==oe&&oe&&oe.ownerDocument&&cD(oe.ownerDocument.documentElement,oe)){for(a!==null&&WS(oe)&&(ne=a.start,ce=a.end,ce===void 0&&(ce=ne),"selectionStart"in oe?(oe.selectionStart=ne,oe.selectionEnd=Math.min(ce,oe.value.length)):(ce=(ne=oe.ownerDocument||document)&&ne.defaultView||window,ce.getSelection&&(ce=ce.getSelection(),g=oe.textContent.length,s=Math.min(a.start,g),a=a.end===void 0?s:Math.min(a.end,g),!ce.extend&&s>a&&(g=a,a=s,s=g),g=Fk(oe,s),x=Fk(oe,a),g&&x&&(ce.rangeCount!==1||ce.anchorNode!==g.node||ce.anchorOffset!==g.offset||ce.focusNode!==x.node||ce.focusOffset!==x.offset)&&(ne=ne.createRange(),ne.setStart(g.node,g.offset),ce.removeAllRanges(),s>a?(ce.addRange(ne),ce.extend(x.node,x.offset)):(ne.setEnd(x.node,x.offset),ce.addRange(ne)))))),ne=[],ce=oe;ce=ce.parentNode;)ce.nodeType===1&&ne.push({element:ce,left:ce.scrollLeft,top:ce.scrollTop});for(typeof oe.focus=="function"&&oe.focus(),oe=0;oe<ne.length;oe++)ce=ne[oe],ce.element.scrollLeft=ce.left,ce.element.scrollTop=ce.top}n2=!!Uw,Rw=Uw=null,e.current=t,$r=i;do try{for(oe=e;$r!==null;){var ae=$r.effectTag;if(ae&36&&rq(oe,$r.alternate,$r),ae&128){ne=void 0;var ue=$r.ref;if(ue!==null){var ye=$r.stateNode;switch($r.tag){case 5:ne=ye;break;default:ne=ye}typeof ue=="function"?ue(ne):ue.current=ne}}$r=$r.nextEffect}}catch(Re){if($r===null)throw Error(Ln(330));H0($r,Re),$r=$r.nextEffect}while($r!==null);$r=null,YY(),Ri=o}else e.current=t;if(J2)J2=!1,wC=e,iC=n;else for($r=i;$r!==null;)n=$r.nextEffect,$r.nextEffect=null,$r=n;if(n=e.firstPendingTime,n===0&&(xm=null),n===1073741823?e===l6?MC++:(MC=0,l6=e):MC=0,typeof c6=="function"&&c6(t.stateNode,r),zc(e),X2)throw X2=!1,e=s6,s6=null,e;return(Ri&oB)!==su||gf(),null}function Aq(){for(;$r!==null;){var e=$r.effectTag;e&256&&nq($r.alternate,$r),!(e&512)||J2||(J2=!0,FD(97,function(){return Py(),null})),$r=$r.nextEffect}}function Py(){if(iC!==90){var e=97<iC?97:iC;return iC=90,Km(e,cq)}}function cq(){if(wC===null)return!1;var e=wC;if(wC=null,(Ri&(hh|lf))!==su)throw Error(Ln(331));var n=Ri;for(Ri|=lf,e=e.current.firstEffect;e!==null;){try{var t=e;if(t.effectTag&512)switch(t.tag){case 0:case 11:case 15:case 22:JD(5,t),eU(5,t)}}catch(r){if(e===null)throw Error(Ln(330));H0(e,r)}t=e.nextEffect,e.nextEffect=null,e=t}return Ri=n,gf(),!0}function vI(e,n,t){n=iB(t,n),n=rU(e,n,1073741823),bm(e,n),e=R4(e,1073741823),e!==null&&zc(e)}function H0(e,n){if(e.tag===3)vI(e,e,n);else for(var t=e.return;t!==null;){if(t.tag===3){vI(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(xm===null||!xm.has(r))){e=iB(n,e),e=iU(t,e,1073741823),bm(t,e),t=R4(t,1073741823),t!==null&&zc(t);break}}t=t.return}}function dq(e,n,t){var r=e.pingCache;r!==null&&r.delete(n),Lc===e&&QA===t?au===D4||au===V2&&hp===1073741823&&vd()-sB<sU?L0(e,QA):Z2=!0:gU(e,t)&&(n=e.lastPingedTime,n!==0&&n<t||(e.lastPingedTime=t,zc(e)))}function hq(e,n){var t=e.stateNode;t!==null&&t.delete(n),n=0,n===0&&(n=of(),n=V0(n,e,null)),e=R4(e,n),e!==null&&zc(e)}var mU;mU=function(e,n,t){var r=n.expirationTime;if(e!==null){var i=n.pendingProps;if(e.memoizedProps!==i||NA.current)Jh=!0;else{if(r<t){switch(Jh=!1,n.tag){case 3:AI(n),Ww();break;case 5:if(nI(n),n.mode&4&&t!==1&&i.hidden)return n.expirationTime=n.childExpirationTime=1,null;break;case 1:GA(n.type)&&a2(n);break;case 4:ZS(n,n.stateNode.containerInfo);break;case 10:r=n.memoizedProps.value,i=n.type._context,ol(R2,i._currentValue),i._currentValue=r;break;case 13:if(n.memoizedState!==null)return r=n.child.childExpirationTime,r!==0&&r>=t?cI(e,n,t):(ol(Qs,Qs.current&1),n=yp(e,n,t),n!==null?n.sibling:null);ol(Qs,Qs.current&1);break;case 19:if(r=n.childExpirationTime>=t,e.effectTag&64){if(r)return hI(e,n,t);n.effectTag|=64}if(i=n.memoizedState,i!==null&&(i.rendering=null,i.tail=null),ol(Qs,Qs.current),!r)return null}return yp(e,n,t)}Jh=!1}}else Jh=!1;switch(n.expirationTime=0,n.tag){case 2:if(r=n.type,e!==null&&(e.alternate=null,n.alternate=null,n.effectTag|=2),e=n.pendingProps,i=yy(n,qu.current),Vg(n,t),i=eB(null,n,r,e,i,t),n.effectTag|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0){if(n.tag=1,n.memoizedState=null,n.updateQueue=null,GA(r)){var o=!0;a2(n)}else o=!1;n.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,qO(n);var s=r.getDerivedStateFromProps;typeof s=="function"&&j2(n,r,s,e),i.updater=F4,n.stateNode=i,i._reactInternalFiber=n,HS(n,r,e,t),n=n6(null,n,r,!0,o,t)}else n.tag=0,Tc(null,n,i,t),n=n.child;return n;case 16:e:{if(i=n.elementType,e!==null&&(e.alternate=null,n.alternate=null,n.effectTag|=2),e=n.pendingProps,W$(i),i._status!==1)throw i._result;switch(i=i._result,n.type=i,o=n.tag=mq(i),e=sh(i,e),o){case 0:n=t6(null,n,i,e,t);break e;case 1:n=uI(null,n,i,e,t);break e;case 11:n=sI(null,n,i,e,t);break e;case 14:n=lI(null,n,i,sh(i.type,e),r,t);break e}throw Error(Ln(306,i,""))}return n;case 0:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:sh(r,i),t6(e,n,r,i,t);case 1:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:sh(r,i),uI(e,n,r,i,t);case 3:if(AI(n),r=n.updateQueue,e===null||r===null)throw Error(Ln(282));if(r=n.pendingProps,i=n.memoizedState,i=i!==null?i.element:null,VO(e,n),HC(n,r,null,t),r=n.memoizedState.element,r===i)Ww(),n=yp(e,n,t);else{if((i=n.stateNode.hydrate)&&(um=qg(n.stateNode.containerInfo.firstChild),gp=n,i=Y0=!0),i)for(t=HO(n,null,r,t),n.child=t;t;)t.effectTag=t.effectTag&-3|1024,t=t.sibling;else Tc(e,n,r,t),Ww();n=n.child}return n;case 5:return nI(n),e===null&&e6(n),r=n.type,i=n.pendingProps,o=e!==null?e.memoizedProps:null,s=i.children,NS(r,i)?s=null:o!==null&&NS(r,o)&&(n.effectTag|=16),VD(e,n),n.mode&4&&t!==1&&i.hidden?(n.expirationTime=n.childExpirationTime=1,n=null):(Tc(e,n,s,t),n=n.child),n;case 6:return e===null&&e6(n),null;case 13:return cI(e,n,t);case 4:return ZS(n,n.stateNode.containerInfo),r=n.pendingProps,e===null?n.child=vy(n,null,r,t):Tc(e,n,r,t),n.child;case 11:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:sh(r,i),sI(e,n,r,i,t);case 7:return Tc(e,n,n.pendingProps,t),n.child;case 8:return Tc(e,n,n.pendingProps.children,t),n.child;case 12:return Tc(e,n,n.pendingProps.children,t),n.child;case 10:e:{r=n.type._context,i=n.pendingProps,s=n.memoizedProps,o=i.value;var a=n.type._context;if(ol(R2,a._currentValue),a._currentValue=o,s!==null)if(a=s.value,o=o1(a,o)?0:(typeof r._calculateChangedBits=="function"?r._calculateChangedBits(a,o):1073741823)|0,o===0){if(s.children===i.children&&!NA.current){n=yp(e,n,t);break e}}else for(a=n.child,a!==null&&(a.return=n);a!==null;){var f=a.dependencies;if(f!==null){s=a.child;for(var g=f.firstContext;g!==null;){if(g.context===r&&g.observedBits&o){a.tag===1&&(g=_m(t,null),g.tag=2,bm(a,g)),a.expirationTime<t&&(a.expirationTime=t),g=a.alternate,g!==null&&g.expirationTime<t&&(g.expirationTime=t),UD(a.return,t),f.expirationTime<t&&(f.expirationTime=t);break}g=g.next}}else s=a.tag===10&&a.type===n.type?null:a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===n){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}Tc(e,n,i.children,t),n=n.child}return n;case 9:return i=n.type,o=n.pendingProps,r=o.children,Vg(n,t),i=Md(i,o.unstable_observedBits),r=r(i),n.effectTag|=1,Tc(e,n,r,t),n.child;case 14:return i=n.type,o=sh(i,n.pendingProps),o=sh(i.type,o),lI(e,n,i,o,r,t);case 15:return qD(e,n,n.type,n.pendingProps,r,t);case 17:return r=n.type,i=n.pendingProps,i=n.elementType===r?i:sh(r,i),e!==null&&(e.alternate=null,n.alternate=null,n.effectTag|=2),n.tag=1,GA(r)?(e=!0,a2(n)):e=!1,Vg(n,t),LD(n,r,i),HS(n,r,i,t),n6(null,n,r,!0,e,t);case 19:return hI(e,n,t)}throw Error(Ln(156,n.tag))};var c6=null,d6=null;function fq(e){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u")return!1;var n=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(n.isDisabled||!n.supportsFiber)return!0;try{var t=n.inject(e);c6=function(r){try{n.onCommitFiberRoot(t,r,void 0,(r.current.effectTag&64)===64)}catch{}},d6=function(r){try{n.onCommitFiberUnmount(t,r)}catch{}}}catch{}return!0}function pq(e,n,t,r){this.tag=e,this.key=t,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=n,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.effectTag=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childExpirationTime=this.expirationTime=0,this.alternate=null}function ef(e,n,t,r){return new pq(e,n,t,r)}function lB(e){return e=e.prototype,!(!e||!e.isReactComponent)}function mq(e){if(typeof e=="function")return lB(e)?1:0;if(e!=null){if(e=e.$$typeof,e===OO)return 11;if(e===BO)return 14}return 2}function s1(e,n){var t=e.alternate;return t===null?(t=ef(e.tag,n,e.key,e.mode),t.elementType=e.elementType,t.type=e.type,t.stateNode=e.stateNode,t.alternate=e,e.alternate=t):(t.pendingProps=n,t.effectTag=0,t.nextEffect=null,t.firstEffect=null,t.lastEffect=null),t.childExpirationTime=e.childExpirationTime,t.expirationTime=e.expirationTime,t.child=e.child,t.memoizedProps=e.memoizedProps,t.memoizedState=e.memoizedState,t.updateQueue=e.updateQueue,n=e.dependencies,t.dependencies=n===null?null:{expirationTime:n.expirationTime,firstContext:n.firstContext,responders:n.responders},t.sibling=e.sibling,t.index=e.index,t.ref=e.ref,t}function d2(e,n,t,r,i,o){var s=2;if(r=e,typeof e=="function")lB(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case k0:return Am(t.children,i,o,n);case j$:s=8,i|=7;break;case FF:s=8,i|=1;break;case Jx:return e=ef(12,t,n,i|8),e.elementType=Jx,e.type=Jx,e.expirationTime=o,e;case e2:return e=ef(13,t,n,i),e.type=e2,e.elementType=e2,e.expirationTime=o,e;case OS:return e=ef(19,t,n,i),e.elementType=OS,e.expirationTime=o,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case DF:s=10;break e;case UF:s=9;break e;case OO:s=11;break e;case BO:s=14;break e;case RF:s=16,r=null;break e;case LF:s=22;break e}throw Error(Ln(130,e==null?e:typeof e,""))}return n=ef(s,t,n,i),n.elementType=e,n.type=r,n.expirationTime=o,n}function Am(e,n,t,r){return e=ef(7,e,r,n),e.expirationTime=t,e}function $w(e,n,t){return e=ef(6,e,null,n),e.expirationTime=t,e}function Yw(e,n,t){return n=ef(4,e.children!==null?e.children:[],e.key,n),n.expirationTime=t,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}function gq(e,n,t){this.tag=n,this.current=null,this.containerInfo=e,this.pingCache=this.pendingChildren=null,this.finishedExpirationTime=0,this.finishedWork=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=t,this.callbackNode=null,this.callbackPriority=90,this.lastExpiredTime=this.lastPingedTime=this.nextKnownPendingLevel=this.lastSuspendedTime=this.firstSuspendedTime=this.firstPendingTime=0}function gU(e,n){var t=e.firstSuspendedTime;return e=e.lastSuspendedTime,t!==0&&t>=n&&e<=n}function z0(e,n){var t=e.firstSuspendedTime,r=e.lastSuspendedTime;t<n&&(e.firstSuspendedTime=n),(r>n||t===0)&&(e.lastSuspendedTime=n),n<=e.lastPingedTime&&(e.lastPingedTime=0),n<=e.lastExpiredTime&&(e.lastExpiredTime=0)}function yU(e,n){n>e.firstPendingTime&&(e.firstPendingTime=n);var t=e.firstSuspendedTime;t!==0&&(n>=t?e.firstSuspendedTime=e.lastSuspendedTime=e.nextKnownPendingLevel=0:n>=e.lastSuspendedTime&&(e.lastSuspendedTime=n+1),n>e.nextKnownPendingLevel&&(e.nextKnownPendingLevel=n))}function h6(e,n){var t=e.lastExpiredTime;(t===0||t>n)&&(e.lastExpiredTime=n)}function e3(e,n,t,r){var i=n.current,o=of(),s=xC.suspense;o=V0(o,i,s);e:if(t){t=t._reactInternalFiber;t:{if(y1(t)!==t||t.tag!==1)throw Error(Ln(170));var a=t;do{switch(a.tag){case 3:a=a.stateNode.context;break t;case 1:if(GA(a.type)){a=a.stateNode.__reactInternalMemoizedMergedChildContext;break t}}a=a.return}while(a!==null);throw Error(Ln(171))}if(t.tag===1){var f=t.type;if(GA(f)){t=ED(t,f,a);break e}}t=a}else t=Tm;return n.context===null?n.context=t:n.pendingContext=t,n=_m(o,s),n.payload={element:e},r=r===void 0?null:r,r!==null&&(n.callback=r),bm(i,n),wm(i,o),o}function qw(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function CI(e,n){e=e.memoizedState,e!==null&&e.dehydrated!==null&&e.retryTime<n&&(e.retryTime=n)}function uB(e,n){CI(e,n),(e=e.alternate)&&CI(e,n)}function AB(e,n,t){t=t!=null&&t.hydrate===!0;var r=new gq(e,n,t),i=ef(3,null,null,n===2?7:n===1?3:0);r.current=i,i.stateNode=r,qO(i),e[K_]=r.current,t&&n!==0&&q$(e,e.nodeType===9?e:e.ownerDocument),this._internalRoot=r}AB.prototype.render=function(e){e3(e,this._internalRoot,null,null)};AB.prototype.unmount=function(){var e=this._internalRoot,n=e.containerInfo;e3(null,e,null,function(){n[K_]=null})};function L_(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function yq(e,n){if(n||(n=e?e.nodeType===9?e.documentElement:e.firstChild:null,n=!(!n||n.nodeType!==1||!n.hasAttribute("data-reactroot"))),!n)for(var t;t=e.lastChild;)e.removeChild(t);return new AB(e,0,n?{hydrate:!0}:void 0)}function z4(e,n,t,r,i){var o=t._reactRootContainer;if(o){var s=o._internalRoot;if(typeof i=="function"){var a=i;i=function(){var g=qw(s);a.call(g)}}e3(n,s,e,i)}else{if(o=t._reactRootContainer=yq(t,r),s=o._internalRoot,typeof i=="function"){var f=i;i=function(){var g=qw(s);f.call(g)}}AU(function(){e3(n,s,e,i)})}return qw(s)}function vq(e,n,t){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Bg,key:r==null?null:""+r,children:e,containerInfo:n,implementation:t}}iD=function(e){if(e.tag===13){var n=l2(of(),150,100);wm(e,n),uB(e,n)}};PO=function(e){e.tag===13&&(wm(e,3),uB(e,3))};oD=function(e){if(e.tag===13){var n=of();n=V0(n,e,null),wm(e,n),uB(e,n)}};ES=function(e,n,t){switch(n){case"input":if(kS(e,t),n=t.name,t.type==="radio"&&n!=null){for(t=e;t.parentNode;)t=t.parentNode;for(t=t.querySelectorAll("input[name="+JSON.stringify(""+n)+'][type="radio"]'),n=0;n<t.length;n++){var r=t[n];if(r!==e&&r.form===e.form){var i=jO(r);if(!i)throw Error(Ln(90));jF(r),kS(r,i)}}}break;case"textarea":NF(e,t);break;case"select":n=t.value,n!=null&&Yg(e,!!t.multiple,n,!1)}};bO=uU;TF=function(e,n,t,r,i){var o=Ri;Ri|=4;try{return Km(98,e.bind(null,n,t,r,i))}finally{Ri=o,Ri===su&&gf()}};xO=function(){(Ri&(1|hh|lf))===su&&(aq(),Py())};KF=function(e,n){var t=Ri;Ri|=2;try{return e(n)}finally{Ri=t,Ri===su&&gf()}};function vU(e,n){var t=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!L_(n))throw Error(Ln(200));return vq(e,n,null,t)}var Cq={Events:[F_,i1,jO,BF,SS,gy,function(e){TO(e,sY)},kF,IF,I4,k4,Py,{current:!1}]};(function(e){var n=e.findFiberByHostInstance;return fq(yA({},e,{overrideHookState:null,overrideProps:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:dh.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=JF(t),t===null?null:t.stateNode},findFiberByHostInstance:function(t){return n?n(t):null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null}))})({findFiberByHostInstance:P_,bundleType:0,version:"16.14.0",rendererPackageName:"react-dom"});Od.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Cq;Od.createPortal=vU;Od.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var n=e._reactInternalFiber;if(n===void 0)throw typeof e.render=="function"?Error(Ln(188)):Error(Ln(268,Object.keys(e)));return e=JF(n),e=e===null?null:e.stateNode,e};Od.flushSync=function(e,n){if((Ri&(hh|lf))!==su)throw Error(Ln(187));var t=Ri;Ri|=1;try{return Km(99,e.bind(null,n))}finally{Ri=t,gf()}};Od.hydrate=function(e,n,t){if(!L_(n))throw Error(Ln(200));return z4(null,e,n,!0,t)};Od.render=function(e,n,t){if(!L_(n))throw Error(Ln(200));return z4(null,e,n,!1,t)};Od.unmountComponentAtNode=function(e){if(!L_(e))throw Error(Ln(40));return e._reactRootContainer?(AU(function(){z4(null,null,e,!1,function(){e._reactRootContainer=null,e[K_]=null})}),!0):!1};Od.unstable_batchedUpdates=uU;Od.unstable_createPortal=function(e,n){return vU(e,n,2<arguments.length&&arguments[2]!==void 0?arguments[2]:null)};Od.unstable_renderSubtreeIntoContainer=function(e,n,t,r){if(!L_(t))throw Error(Ln(200));if(e==null||e._reactInternalFiber===void 0)throw Error(Ln(38));return z4(e,n,t,!1,r)};Od.version="16.14.0";function CU(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(CU)}catch(e){console.error(e)}}CU(),xF.exports=Od;var Rm=xF.exports;const _U=ga(Rm);var f6={exports:{}};(function(e,n){Object.defineProperty(n,"__esModule",{value:!0}),n.default=i;var t=["constructor","render","componentWillMount","componentDidMount","componentWillReceiveProps","shouldComponentUpdate","componentWillUpdate","componentDidUpdate","componentWillUnmount"],r=[];function i(s){if(s===void 0){console.error("Autobind error: No context provided.");return}var a=Object.getPrototypeOf(s);arguments.length>1?r=Array.prototype.slice.call(arguments,1):r=Object.getOwnPropertyNames(a),r.forEach(function(f){var g=Object.getOwnPropertyDescriptor(a,f);if(g===void 0){console.warn('Autobind: "'+f+'" method not found in class.');return}t.indexOf(f)!==-1||typeof g.value!="function"||Object.defineProperty(a,f,o(a,f,g))})}function o(s,a,f){var g=f.value;return{configurable:!0,get:function(){if(this===s||this.hasOwnProperty(a))return g;var k=g.bind(this);return Object.defineProperty(this,a,{value:k,configurable:!0,writable:!0}),k}}}e.exports=n.default})(f6,f6.exports);var _q=f6.exports,bq=_q;const xq=ga(bq);var t3={exports:{}};t3.exports;(function(e,n){var t=200,r="__lodash_hash_undefined__",i=9007199254740991,o="[object Arguments]",s="[object Array]",a="[object Boolean]",f="[object Date]",g="[object Error]",x="[object Function]",k="[object GeneratorFunction]",B="[object Map]",P="[object Number]",R="[object Object]",H="[object Promise]",W="[object RegExp]",$="[object Set]",q="[object String]",oe="[object Symbol]",ne="[object WeakMap]",ce="[object ArrayBuffer]",ae="[object DataView]",ue="[object Float32Array]",ye="[object Float64Array]",Re="[object Int8Array]",Ne="[object Int16Array]",rt="[object Int32Array]",ct="[object Uint8Array]",Fe="[object Uint8ClampedArray]",He="[object Uint16Array]",Ce="[object Uint32Array]",jt=/[\\^$.*+?()[\]{}|]/g,Ft=/\w*$/,Jt=/^\[object .+?Constructor\]$/,Nt=/^(?:0|[1-9]\d*)$/,Ve={};Ve[o]=Ve[s]=Ve[ce]=Ve[ae]=Ve[a]=Ve[f]=Ve[ue]=Ve[ye]=Ve[Re]=Ve[Ne]=Ve[rt]=Ve[B]=Ve[P]=Ve[R]=Ve[W]=Ve[$]=Ve[q]=Ve[oe]=Ve[ct]=Ve[Fe]=Ve[He]=Ve[Ce]=!0,Ve[g]=Ve[x]=Ve[ne]=!1;var nt=typeof window=="object"&&window&&window.Object===Object&&window,Je=typeof self=="object"&&self&&self.Object===Object&&self,Vt=nt||Je||Function("return this")(),pt=n&&!n.nodeType&&n,dt=pt&&!0&&e&&!e.nodeType&&e,kt=dt&&dt.exports===pt;function Dt(ee,Ie){return ee.set(Ie[0],Ie[1]),ee}function Se(ee,Ie){return ee.add(Ie),ee}function de(ee,Ie){for(var st=-1,Xt=ee?ee.length:0;++st<Xt&&Ie(ee[st],st,ee)!==!1;);return ee}function xe(ee,Ie){for(var st=-1,Xt=Ie.length,Sr=ee.length;++st<Xt;)ee[Sr+st]=Ie[st];return ee}function Pe(ee,Ie,st,Xt){var Sr=-1,_n=ee?ee.length:0;for(Xt&&_n&&(st=ee[++Sr]);++Sr<_n;)st=Ie(st,ee[Sr],Sr,ee);return st}function Ze(ee,Ie){for(var st=-1,Xt=Array(ee);++st<ee;)Xt[st]=Ie(st);return Xt}function Xe(ee,Ie){return ee==null?void 0:ee[Ie]}function wt(ee){var Ie=!1;if(ee!=null&&typeof ee.toString!="function")try{Ie=!!(ee+"")}catch{}return Ie}function Kt(ee){var Ie=-1,st=Array(ee.size);return ee.forEach(function(Xt,Sr){st[++Ie]=[Sr,Xt]}),st}function Pt(ee,Ie){return function(st){return ee(Ie(st))}}function zn(ee){var Ie=-1,st=Array(ee.size);return ee.forEach(function(Xt){st[++Ie]=Xt}),st}var mt=Array.prototype,pn=Function.prototype,ir=Object.prototype,Sn=Vt["__core-js_shared__"],nr=function(){var ee=/[^.]+$/.exec(Sn&&Sn.keys&&Sn.keys.IE_PROTO||"");return ee?"Symbol(src)_1."+ee:""}(),Mr=pn.toString,Qr=ir.hasOwnProperty,_r=ir.toString,vi=RegExp("^"+Mr.call(Qr).replace(jt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),we=kt?Vt.Buffer:void 0,V=Vt.Symbol,X=Vt.Uint8Array,me=Pt(Object.getPrototypeOf,Object),At=Object.create,bt=ir.propertyIsEnumerable,Et=mt.splice,sr=Object.getOwnPropertySymbols,Lt=we?we.isBuffer:void 0,Fn=Pt(Object.keys,Object),on=va(Vt,"DataView"),m=va(Vt,"Map"),un=va(Vt,"Promise"),In=va(Vt,"Set"),Gn=va(Vt,"WeakMap"),Zn=va(Object,"create"),Ke=Ya(on),fe=Ya(m),_e=Ya(un),Ee=Ya(In),Te=Ya(Gn),at=V?V.prototype:void 0,it=at?at.valueOf:void 0;function ht(ee){var Ie=-1,st=ee?ee.length:0;for(this.clear();++Ie<st;){var Xt=ee[Ie];this.set(Xt[0],Xt[1])}}function et(){this.__data__=Zn?Zn(null):{}}function Ct(ee){return this.has(ee)&&delete this.__data__[ee]}function rn(ee){var Ie=this.__data__;if(Zn){var st=Ie[ee];return st===r?void 0:st}return Qr.call(Ie,ee)?Ie[ee]:void 0}function Gt(ee){var Ie=this.__data__;return Zn?Ie[ee]!==void 0:Qr.call(Ie,ee)}function $t(ee,Ie){var st=this.__data__;return st[ee]=Zn&&Ie===void 0?r:Ie,this}ht.prototype.clear=et,ht.prototype.delete=Ct,ht.prototype.get=rn,ht.prototype.has=Gt,ht.prototype.set=$t;function gn(ee){var Ie=-1,st=ee?ee.length:0;for(this.clear();++Ie<st;){var Xt=ee[Ie];this.set(Xt[0],Xt[1])}}function Jn(){this.__data__=[]}function qn(ee){var Ie=this.__data__,st=lo(Ie,ee);if(st<0)return!1;var Xt=Ie.length-1;return st==Xt?Ie.pop():Et.call(Ie,st,1),!0}function Tr(ee){var Ie=this.__data__,st=lo(Ie,ee);return st<0?void 0:Ie[st][1]}function vr(ee){return lo(this.__data__,ee)>-1}function Dr(ee,Ie){var st=this.__data__,Xt=lo(st,ee);return Xt<0?st.push([ee,Ie]):st[Xt][1]=Ie,this}gn.prototype.clear=Jn,gn.prototype.delete=qn,gn.prototype.get=Tr,gn.prototype.has=vr,gn.prototype.set=Dr;function Yr(ee){var Ie=-1,st=ee?ee.length:0;for(this.clear();++Ie<st;){var Xt=ee[Ie];this.set(Xt[0],Xt[1])}}function Zr(){this.__data__={hash:new ht,map:new(m||gn),string:new ht}}function Cr(ee){return Vs(this,ee).delete(ee)}function ui(ee){return Vs(this,ee).get(ee)}function Ii(ee){return Vs(this,ee).has(ee)}function Io(ee,Ie){return Vs(this,ee).set(ee,Ie),this}Yr.prototype.clear=Zr,Yr.prototype.delete=Cr,Yr.prototype.get=ui,Yr.prototype.has=Ii,Yr.prototype.set=Io;function Ci(ee){this.__data__=new gn(ee)}function so(){this.__data__=new gn}function Yo(ee){return this.__data__.delete(ee)}function ba(ee){return this.__data__.get(ee)}function Ql(ee){return this.__data__.has(ee)}function Ai(ee,Ie){var st=this.__data__;if(st instanceof gn){var Xt=st.__data__;if(!m||Xt.length<t-1)return Xt.push([ee,Ie]),this;st=this.__data__=new Yr(Xt)}return st.set(ee,Ie),this}Ci.prototype.clear=so,Ci.prototype.delete=Yo,Ci.prototype.get=ba,Ci.prototype.has=Ql,Ci.prototype.set=Ai;function Mi(ee,Ie){var st=Ds(ee)||Zu(ee)?Ze(ee.length,String):[],Xt=st.length,Sr=!!Xt;for(var _n in ee)(Ie||Qr.call(ee,_n))&&!(Sr&&(_n=="length"||HA(_n,Xt)))&&st.push(_n);return st}function rr(ee,Ie,st){var Xt=ee[Ie];(!(Qr.call(ee,Ie)&&bA(Xt,st))||st===void 0&&!(Ie in ee))&&(ee[Ie]=st)}function lo(ee,Ie){for(var st=ee.length;st--;)if(bA(ee[st][0],Ie))return st;return-1}function Gi(ee,Ie){return ee&&Qa(Ie,Au(Ie),ee)}function la(ee,Ie,st,Xt,Sr,_n,Si){var Ki;if(Xt&&(Ki=_n?Xt(ee,Sr,_n,Si):Xt(ee)),Ki!==void 0)return Ki;if(!as(ee))return ee;var qr=Ds(ee);if(qr){if(Ki=xu(ee),!Ie)return _l(ee,Ki)}else{var Yi=ll(ee),qo=Yi==x||Yi==k;if(lu(ee))return En(ee,Ie);if(Yi==R||Yi==o||qo&&!_n){if(wt(ee))return _n?ee:{};if(Ki=bl(qo?{}:ee),!Ie)return ys(ee,Gi(Ki,ee))}else{if(!Ve[Yi])return _n?ee:{};Ki=CA(ee,Yi,la,Ie)}}Si||(Si=new Ci);var Ca=Si.get(ee);if(Ca)return Ca;if(Si.set(ee,Ki),!qr)var Vo=st?qs(ee):Au(ee);return de(Vo||ee,function(Li,Xo){Vo&&(Xo=Li,Li=ee[Xo]),rr(Ki,Xo,la(Li,Ie,st,Xt,Xo,ee,Si))}),Ki}function ve(ee){return as(ee)?At(ee):{}}function Ge(ee,Ie,st){var Xt=Ie(ee);return Ds(ee)?Xt:xe(Xt,st(ee))}function Ht(ee){return _r.call(ee)}function mn(ee){if(!as(ee)||ZA(ee))return!1;var Ie=wu(ee)||wt(ee)?vi:Jt;return Ie.test(Ya(ee))}function Ot(ee){if(!_A(ee))return Fn(ee);var Ie=[];for(var st in Object(ee))Qr.call(ee,st)&&st!="constructor"&&Ie.push(st);return Ie}function En(ee,Ie){if(Ie)return ee.slice();var st=new ee.constructor(ee.length);return ee.copy(st),st}function zr(ee){var Ie=new ee.constructor(ee.byteLength);return new X(Ie).set(new X(ee)),Ie}function Lr(ee,Ie){var st=Ie?zr(ee.buffer):ee.buffer;return new ee.constructor(st,ee.byteOffset,ee.byteLength)}function Ti(ee,Ie,st){var Xt=Ie?st(Kt(ee),!0):Kt(ee);return Pe(Xt,Dt,new ee.constructor)}function po(ee){var Ie=new ee.constructor(ee.source,Ft.exec(ee));return Ie.lastIndex=ee.lastIndex,Ie}function Cl(ee,Ie,st){var Xt=Ie?st(zn(ee),!0):zn(ee);return Pe(Xt,Se,new ee.constructor)}function br(ee){return it?Object(it.call(ee)):{}}function _i(ee,Ie){var st=Ie?zr(ee.buffer):ee.buffer;return new ee.constructor(st,ee.byteOffset,ee.length)}function _l(ee,Ie){var st=-1,Xt=ee.length;for(Ie||(Ie=Array(Xt));++st<Xt;)Ie[st]=ee[st];return Ie}function Qa(ee,Ie,st,Xt){st||(st={});for(var Sr=-1,_n=Ie.length;++Sr<_n;){var Si=Ie[Sr],Ki=Xt?Xt(st[Si],ee[Si],Si,st,ee):void 0;rr(st,Si,Ki===void 0?ee[Si]:Ki)}return st}function ys(ee,Ie){return Qa(ee,$a(ee),Ie)}function qs(ee){return Ge(ee,Au,$a)}function Vs(ee,Ie){var st=ee.__data__;return Hu(Ie)?st[typeof Ie=="string"?"string":"hash"]:st.map}function va(ee,Ie){var st=Xe(ee,Ie);return mn(st)?st:void 0}var $a=sr?Pt(sr,Object):bo,ll=Ht;(on&&ll(new on(new ArrayBuffer(1)))!=ae||m&&ll(new m)!=B||un&&ll(un.resolve())!=H||In&&ll(new In)!=$||Gn&&ll(new Gn)!=ne)&&(ll=function(ee){var Ie=_r.call(ee),st=Ie==R?ee.constructor:void 0,Xt=st?Ya(st):void 0;if(Xt)switch(Xt){case Ke:return ae;case fe:return B;case _e:return H;case Ee:return $;case Te:return ne}return Ie});function xu(ee){var Ie=ee.length,st=ee.constructor(Ie);return Ie&&typeof ee[0]=="string"&&Qr.call(ee,"index")&&(st.index=ee.index,st.input=ee.input),st}function bl(ee){return typeof ee.constructor=="function"&&!_A(ee)?ve(me(ee)):{}}function CA(ee,Ie,st,Xt){var Sr=ee.constructor;switch(Ie){case ce:return zr(ee);case a:case f:return new Sr(+ee);case ae:return Lr(ee,Xt);case ue:case ye:case Re:case Ne:case rt:case ct:case Fe:case He:case Ce:return _i(ee,Xt);case B:return Ti(ee,Xt,st);case P:case q:return new Sr(ee);case W:return po(ee);case $:return Cl(ee,Xt,st);case oe:return br(ee)}}function HA(ee,Ie){return Ie=Ie??i,!!Ie&&(typeof ee=="number"||Nt.test(ee))&&ee>-1&&ee%1==0&&ee<Ie}function Hu(ee){var Ie=typeof ee;return Ie=="string"||Ie=="number"||Ie=="symbol"||Ie=="boolean"?ee!=="__proto__":ee===null}function ZA(ee){return!!nr&&nr in ee}function _A(ee){var Ie=ee&&ee.constructor,st=typeof Ie=="function"&&Ie.prototype||ir;return ee===st}function Ya(ee){if(ee!=null){try{return Mr.call(ee)}catch{}try{return ee+""}catch{}}return""}function vs(ee){return la(ee,!0,!0)}function bA(ee,Ie){return ee===Ie||ee!==ee&&Ie!==Ie}function Zu(ee){return Cs(ee)&&Qr.call(ee,"callee")&&(!bt.call(ee,"callee")||_r.call(ee)==o)}var Ds=Array.isArray;function Us(ee){return ee!=null&&uu(ee.length)&&!wu(ee)}function Cs(ee){return Mu(ee)&&Us(ee)}var lu=Lt||mo;function wu(ee){var Ie=as(ee)?_r.call(ee):"";return Ie==x||Ie==k}function uu(ee){return typeof ee=="number"&&ee>-1&&ee%1==0&&ee<=i}function as(ee){var Ie=typeof ee;return!!ee&&(Ie=="object"||Ie=="function")}function Mu(ee){return!!ee&&typeof ee=="object"}function Au(ee){return Us(ee)?Mi(ee):Ot(ee)}function bo(){return[]}function mo(){return!1}e.exports=vs})(t3,t3.exports);var wq=t3.exports;const _I=ga(wq);var bI=NaN,Mq="[object Symbol]",Sq=/^\s+|\s+$/g,Eq=/^[-+]0x[0-9a-f]+$/i,Oq=/^0b[01]+$/i,Bq=/^0o[0-7]+$/i,kq=parseInt,Iq=Object.prototype,Tq=Iq.toString;function Kq(e,n,t){return e===e&&(t!==void 0&&(e=e<=t?e:t),n!==void 0&&(e=e>=n?e:n)),e}function xI(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function Pq(e){return!!e&&typeof e=="object"}function Fq(e){return typeof e=="symbol"||Pq(e)&&Tq.call(e)==Mq}function Vw(e){if(typeof e=="number")return e;if(Fq(e))return bI;if(xI(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=xI(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=e.replace(Sq,"");var t=Oq.test(e);return t||Bq.test(e)?kq(e.slice(2),t?2:8):Eq.test(e)?bI:+e}function Dq(e,n,t){return t===void 0&&(t=n,n=void 0),t!==void 0&&(t=Vw(t),t=t===t?t:0),n!==void 0&&(n=Vw(n),n=n===n?n:0),Kq(Vw(e),n,t)}var Uq=Dq;const wI=ga(Uq);var bU={},j4={};j4.byteLength=zq;j4.toByteArray=Wq;j4.fromByteArray=Qq;var Vh=[],md=[],Rq=typeof Uint8Array<"u"?Uint8Array:Array,Hw="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var rg=0,Lq=Hw.length;rg<Lq;++rg)Vh[rg]=Hw[rg],md[Hw.charCodeAt(rg)]=rg;md[45]=62;md[95]=63;function xU(e){var n=e.length;if(n%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var t=e.indexOf("=");t===-1&&(t=n);var r=t===n?0:4-t%4;return[t,r]}function zq(e){var n=xU(e),t=n[0],r=n[1];return(t+r)*3/4-r}function jq(e,n,t){return(n+t)*3/4-t}function Wq(e){var n,t=xU(e),r=t[0],i=t[1],o=new Rq(jq(e,r,i)),s=0,a=i>0?r-4:r,f;for(f=0;f<a;f+=4)n=md[e.charCodeAt(f)]<<18|md[e.charCodeAt(f+1)]<<12|md[e.charCodeAt(f+2)]<<6|md[e.charCodeAt(f+3)],o[s++]=n>>16&255,o[s++]=n>>8&255,o[s++]=n&255;return i===2&&(n=md[e.charCodeAt(f)]<<2|md[e.charCodeAt(f+1)]>>4,o[s++]=n&255),i===1&&(n=md[e.charCodeAt(f)]<<10|md[e.charCodeAt(f+1)]<<4|md[e.charCodeAt(f+2)]>>2,o[s++]=n>>8&255,o[s++]=n&255),o}function Nq(e){return Vh[e>>18&63]+Vh[e>>12&63]+Vh[e>>6&63]+Vh[e&63]}function Gq(e,n,t){for(var r,i=[],o=n;o<t;o+=3)r=(e[o]<<16&16711680)+(e[o+1]<<8&65280)+(e[o+2]&255),i.push(Nq(r));return i.join("")}function Qq(e){for(var n,t=e.length,r=t%3,i=[],o=16383,s=0,a=t-r;s<a;s+=o)i.push(Gq(e,s,s+o>a?a:s+o));return r===1?(n=e[t-1],i.push(Vh[n>>2]+Vh[n<<4&63]+"==")):r===2&&(n=(e[t-2]<<8)+e[t-1],i.push(Vh[n>>10]+Vh[n>>4&63]+Vh[n<<2&63]+"=")),i.join("")}var W4={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */W4.read=function(e,n,t,r,i){var o,s,a=i*8-r-1,f=(1<<a)-1,g=f>>1,x=-7,k=t?i-1:0,B=t?-1:1,P=e[n+k];for(k+=B,o=P&(1<<-x)-1,P>>=-x,x+=a;x>0;o=o*256+e[n+k],k+=B,x-=8);for(s=o&(1<<-x)-1,o>>=-x,x+=r;x>0;s=s*256+e[n+k],k+=B,x-=8);if(o===0)o=1-g;else{if(o===f)return s?NaN:(P?-1:1)*(1/0);s=s+Math.pow(2,r),o=o-g}return(P?-1:1)*s*Math.pow(2,o-r)};W4.write=function(e,n,t,r,i,o){var s,a,f,g=o*8-i-1,x=(1<<g)-1,k=x>>1,B=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,P=r?0:o-1,R=r?1:-1,H=n<0||n===0&&1/n<0?1:0;for(n=Math.abs(n),isNaN(n)||n===1/0?(a=isNaN(n)?1:0,s=x):(s=Math.floor(Math.log(n)/Math.LN2),n*(f=Math.pow(2,-s))<1&&(s--,f*=2),s+k>=1?n+=B/f:n+=B*Math.pow(2,1-k),n*f>=2&&(s++,f/=2),s+k>=x?(a=0,s=x):s+k>=1?(a=(n*f-1)*Math.pow(2,i),s=s+k):(a=n*Math.pow(2,k-1)*Math.pow(2,i),s=0));i>=8;e[t+P]=a&255,P+=R,a/=256,i-=8);for(s=s<<i|a,g+=i;g>0;e[t+P]=s&255,P+=R,s/=256,g-=8);e[t+P-R]|=H*128};/*!
|
||
* The buffer module from node.js, for the browser.
|
||
*
|
||
* @author Feross Aboukhadijeh <https://feross.org>
|
||
* @license MIT
|
||
*/(function(e){const n=j4,t=W4,r=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=a,e.SlowBuffer=q,e.INSPECT_MAX_BYTES=50;const i=2147483647;e.kMaxLength=i,a.TYPED_ARRAY_SUPPORT=o(),!a.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function o(){try{const we=new Uint8Array(1),V={foo:function(){return 42}};return Object.setPrototypeOf(V,Uint8Array.prototype),Object.setPrototypeOf(we,V),we.foo()===42}catch{return!1}}Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}});function s(we){if(we>i)throw new RangeError('The value "'+we+'" is invalid for option "size"');const V=new Uint8Array(we);return Object.setPrototypeOf(V,a.prototype),V}function a(we,V,X){if(typeof we=="number"){if(typeof V=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return k(we)}return f(we,V,X)}a.poolSize=8192;function f(we,V,X){if(typeof we=="string")return B(we,V);if(ArrayBuffer.isView(we))return R(we);if(we==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof we);if(nr(we,ArrayBuffer)||we&&nr(we.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(nr(we,SharedArrayBuffer)||we&&nr(we.buffer,SharedArrayBuffer)))return H(we,V,X);if(typeof we=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const me=we.valueOf&&we.valueOf();if(me!=null&&me!==we)return a.from(me,V,X);const At=W(we);if(At)return At;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof we[Symbol.toPrimitive]=="function")return a.from(we[Symbol.toPrimitive]("string"),V,X);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof we)}a.from=function(we,V,X){return f(we,V,X)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array);function g(we){if(typeof we!="number")throw new TypeError('"size" argument must be of type number');if(we<0)throw new RangeError('The value "'+we+'" is invalid for option "size"')}function x(we,V,X){return g(we),we<=0?s(we):V!==void 0?typeof X=="string"?s(we).fill(V,X):s(we).fill(V):s(we)}a.alloc=function(we,V,X){return x(we,V,X)};function k(we){return g(we),s(we<0?0:$(we)|0)}a.allocUnsafe=function(we){return k(we)},a.allocUnsafeSlow=function(we){return k(we)};function B(we,V){if((typeof V!="string"||V==="")&&(V="utf8"),!a.isEncoding(V))throw new TypeError("Unknown encoding: "+V);const X=oe(we,V)|0;let me=s(X);const At=me.write(we,V);return At!==X&&(me=me.slice(0,At)),me}function P(we){const V=we.length<0?0:$(we.length)|0,X=s(V);for(let me=0;me<V;me+=1)X[me]=we[me]&255;return X}function R(we){if(nr(we,Uint8Array)){const V=new Uint8Array(we);return H(V.buffer,V.byteOffset,V.byteLength)}return P(we)}function H(we,V,X){if(V<0||we.byteLength<V)throw new RangeError('"offset" is outside of buffer bounds');if(we.byteLength<V+(X||0))throw new RangeError('"length" is outside of buffer bounds');let me;return V===void 0&&X===void 0?me=new Uint8Array(we):X===void 0?me=new Uint8Array(we,V):me=new Uint8Array(we,V,X),Object.setPrototypeOf(me,a.prototype),me}function W(we){if(a.isBuffer(we)){const V=$(we.length)|0,X=s(V);return X.length===0||we.copy(X,0,0,V),X}if(we.length!==void 0)return typeof we.length!="number"||Mr(we.length)?s(0):P(we);if(we.type==="Buffer"&&Array.isArray(we.data))return P(we.data)}function $(we){if(we>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return we|0}function q(we){return+we!=we&&(we=0),a.alloc(+we)}a.isBuffer=function(V){return V!=null&&V._isBuffer===!0&&V!==a.prototype},a.compare=function(V,X){if(nr(V,Uint8Array)&&(V=a.from(V,V.offset,V.byteLength)),nr(X,Uint8Array)&&(X=a.from(X,X.offset,X.byteLength)),!a.isBuffer(V)||!a.isBuffer(X))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(V===X)return 0;let me=V.length,At=X.length;for(let bt=0,Et=Math.min(me,At);bt<Et;++bt)if(V[bt]!==X[bt]){me=V[bt],At=X[bt];break}return me<At?-1:At<me?1:0},a.isEncoding=function(V){switch(String(V).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},a.concat=function(V,X){if(!Array.isArray(V))throw new TypeError('"list" argument must be an Array of Buffers');if(V.length===0)return a.alloc(0);let me;if(X===void 0)for(X=0,me=0;me<V.length;++me)X+=V[me].length;const At=a.allocUnsafe(X);let bt=0;for(me=0;me<V.length;++me){let Et=V[me];if(nr(Et,Uint8Array))bt+Et.length>At.length?(a.isBuffer(Et)||(Et=a.from(Et)),Et.copy(At,bt)):Uint8Array.prototype.set.call(At,Et,bt);else if(a.isBuffer(Et))Et.copy(At,bt);else throw new TypeError('"list" argument must be an Array of Buffers');bt+=Et.length}return At};function oe(we,V){if(a.isBuffer(we))return we.length;if(ArrayBuffer.isView(we)||nr(we,ArrayBuffer))return we.byteLength;if(typeof we!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof we);const X=we.length,me=arguments.length>2&&arguments[2]===!0;if(!me&&X===0)return 0;let At=!1;for(;;)switch(V){case"ascii":case"latin1":case"binary":return X;case"utf8":case"utf-8":return zn(we).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return X*2;case"hex":return X>>>1;case"base64":return ir(we).length;default:if(At)return me?-1:zn(we).length;V=(""+V).toLowerCase(),At=!0}}a.byteLength=oe;function ne(we,V,X){let me=!1;if((V===void 0||V<0)&&(V=0),V>this.length||((X===void 0||X>this.length)&&(X=this.length),X<=0)||(X>>>=0,V>>>=0,X<=V))return"";for(we||(we="utf8");;)switch(we){case"hex":return Nt(this,V,X);case"utf8":case"utf-8":return He(this,V,X);case"ascii":return Ft(this,V,X);case"latin1":case"binary":return Jt(this,V,X);case"base64":return Fe(this,V,X);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Ve(this,V,X);default:if(me)throw new TypeError("Unknown encoding: "+we);we=(we+"").toLowerCase(),me=!0}}a.prototype._isBuffer=!0;function ce(we,V,X){const me=we[V];we[V]=we[X],we[X]=me}a.prototype.swap16=function(){const V=this.length;if(V%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let X=0;X<V;X+=2)ce(this,X,X+1);return this},a.prototype.swap32=function(){const V=this.length;if(V%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let X=0;X<V;X+=4)ce(this,X,X+3),ce(this,X+1,X+2);return this},a.prototype.swap64=function(){const V=this.length;if(V%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let X=0;X<V;X+=8)ce(this,X,X+7),ce(this,X+1,X+6),ce(this,X+2,X+5),ce(this,X+3,X+4);return this},a.prototype.toString=function(){const V=this.length;return V===0?"":arguments.length===0?He(this,0,V):ne.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(V){if(!a.isBuffer(V))throw new TypeError("Argument must be a Buffer");return this===V?!0:a.compare(this,V)===0},a.prototype.inspect=function(){let V="";const X=e.INSPECT_MAX_BYTES;return V=this.toString("hex",0,X).replace(/(.{2})/g,"$1 ").trim(),this.length>X&&(V+=" ... "),"<Buffer "+V+">"},r&&(a.prototype[r]=a.prototype.inspect),a.prototype.compare=function(V,X,me,At,bt){if(nr(V,Uint8Array)&&(V=a.from(V,V.offset,V.byteLength)),!a.isBuffer(V))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof V);if(X===void 0&&(X=0),me===void 0&&(me=V?V.length:0),At===void 0&&(At=0),bt===void 0&&(bt=this.length),X<0||me>V.length||At<0||bt>this.length)throw new RangeError("out of range index");if(At>=bt&&X>=me)return 0;if(At>=bt)return-1;if(X>=me)return 1;if(X>>>=0,me>>>=0,At>>>=0,bt>>>=0,this===V)return 0;let Et=bt-At,sr=me-X;const Lt=Math.min(Et,sr),Fn=this.slice(At,bt),on=V.slice(X,me);for(let m=0;m<Lt;++m)if(Fn[m]!==on[m]){Et=Fn[m],sr=on[m];break}return Et<sr?-1:sr<Et?1:0};function ae(we,V,X,me,At){if(we.length===0)return-1;if(typeof X=="string"?(me=X,X=0):X>2147483647?X=2147483647:X<-2147483648&&(X=-2147483648),X=+X,Mr(X)&&(X=At?0:we.length-1),X<0&&(X=we.length+X),X>=we.length){if(At)return-1;X=we.length-1}else if(X<0)if(At)X=0;else return-1;if(typeof V=="string"&&(V=a.from(V,me)),a.isBuffer(V))return V.length===0?-1:ue(we,V,X,me,At);if(typeof V=="number")return V=V&255,typeof Uint8Array.prototype.indexOf=="function"?At?Uint8Array.prototype.indexOf.call(we,V,X):Uint8Array.prototype.lastIndexOf.call(we,V,X):ue(we,[V],X,me,At);throw new TypeError("val must be string, number or Buffer")}function ue(we,V,X,me,At){let bt=1,Et=we.length,sr=V.length;if(me!==void 0&&(me=String(me).toLowerCase(),me==="ucs2"||me==="ucs-2"||me==="utf16le"||me==="utf-16le")){if(we.length<2||V.length<2)return-1;bt=2,Et/=2,sr/=2,X/=2}function Lt(on,m){return bt===1?on[m]:on.readUInt16BE(m*bt)}let Fn;if(At){let on=-1;for(Fn=X;Fn<Et;Fn++)if(Lt(we,Fn)===Lt(V,on===-1?0:Fn-on)){if(on===-1&&(on=Fn),Fn-on+1===sr)return on*bt}else on!==-1&&(Fn-=Fn-on),on=-1}else for(X+sr>Et&&(X=Et-sr),Fn=X;Fn>=0;Fn--){let on=!0;for(let m=0;m<sr;m++)if(Lt(we,Fn+m)!==Lt(V,m)){on=!1;break}if(on)return Fn}return-1}a.prototype.includes=function(V,X,me){return this.indexOf(V,X,me)!==-1},a.prototype.indexOf=function(V,X,me){return ae(this,V,X,me,!0)},a.prototype.lastIndexOf=function(V,X,me){return ae(this,V,X,me,!1)};function ye(we,V,X,me){X=Number(X)||0;const At=we.length-X;me?(me=Number(me),me>At&&(me=At)):me=At;const bt=V.length;me>bt/2&&(me=bt/2);let Et;for(Et=0;Et<me;++Et){const sr=parseInt(V.substr(Et*2,2),16);if(Mr(sr))return Et;we[X+Et]=sr}return Et}function Re(we,V,X,me){return Sn(zn(V,we.length-X),we,X,me)}function Ne(we,V,X,me){return Sn(mt(V),we,X,me)}function rt(we,V,X,me){return Sn(ir(V),we,X,me)}function ct(we,V,X,me){return Sn(pn(V,we.length-X),we,X,me)}a.prototype.write=function(V,X,me,At){if(X===void 0)At="utf8",me=this.length,X=0;else if(me===void 0&&typeof X=="string")At=X,me=this.length,X=0;else if(isFinite(X))X=X>>>0,isFinite(me)?(me=me>>>0,At===void 0&&(At="utf8")):(At=me,me=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const bt=this.length-X;if((me===void 0||me>bt)&&(me=bt),V.length>0&&(me<0||X<0)||X>this.length)throw new RangeError("Attempt to write outside buffer bounds");At||(At="utf8");let Et=!1;for(;;)switch(At){case"hex":return ye(this,V,X,me);case"utf8":case"utf-8":return Re(this,V,X,me);case"ascii":case"latin1":case"binary":return Ne(this,V,X,me);case"base64":return rt(this,V,X,me);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ct(this,V,X,me);default:if(Et)throw new TypeError("Unknown encoding: "+At);At=(""+At).toLowerCase(),Et=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function Fe(we,V,X){return V===0&&X===we.length?n.fromByteArray(we):n.fromByteArray(we.slice(V,X))}function He(we,V,X){X=Math.min(we.length,X);const me=[];let At=V;for(;At<X;){const bt=we[At];let Et=null,sr=bt>239?4:bt>223?3:bt>191?2:1;if(At+sr<=X){let Lt,Fn,on,m;switch(sr){case 1:bt<128&&(Et=bt);break;case 2:Lt=we[At+1],(Lt&192)===128&&(m=(bt&31)<<6|Lt&63,m>127&&(Et=m));break;case 3:Lt=we[At+1],Fn=we[At+2],(Lt&192)===128&&(Fn&192)===128&&(m=(bt&15)<<12|(Lt&63)<<6|Fn&63,m>2047&&(m<55296||m>57343)&&(Et=m));break;case 4:Lt=we[At+1],Fn=we[At+2],on=we[At+3],(Lt&192)===128&&(Fn&192)===128&&(on&192)===128&&(m=(bt&15)<<18|(Lt&63)<<12|(Fn&63)<<6|on&63,m>65535&&m<1114112&&(Et=m))}}Et===null?(Et=65533,sr=1):Et>65535&&(Et-=65536,me.push(Et>>>10&1023|55296),Et=56320|Et&1023),me.push(Et),At+=sr}return jt(me)}const Ce=4096;function jt(we){const V=we.length;if(V<=Ce)return String.fromCharCode.apply(String,we);let X="",me=0;for(;me<V;)X+=String.fromCharCode.apply(String,we.slice(me,me+=Ce));return X}function Ft(we,V,X){let me="";X=Math.min(we.length,X);for(let At=V;At<X;++At)me+=String.fromCharCode(we[At]&127);return me}function Jt(we,V,X){let me="";X=Math.min(we.length,X);for(let At=V;At<X;++At)me+=String.fromCharCode(we[At]);return me}function Nt(we,V,X){const me=we.length;(!V||V<0)&&(V=0),(!X||X<0||X>me)&&(X=me);let At="";for(let bt=V;bt<X;++bt)At+=Qr[we[bt]];return At}function Ve(we,V,X){const me=we.slice(V,X);let At="";for(let bt=0;bt<me.length-1;bt+=2)At+=String.fromCharCode(me[bt]+me[bt+1]*256);return At}a.prototype.slice=function(V,X){const me=this.length;V=~~V,X=X===void 0?me:~~X,V<0?(V+=me,V<0&&(V=0)):V>me&&(V=me),X<0?(X+=me,X<0&&(X=0)):X>me&&(X=me),X<V&&(X=V);const At=this.subarray(V,X);return Object.setPrototypeOf(At,a.prototype),At};function nt(we,V,X){if(we%1!==0||we<0)throw new RangeError("offset is not uint");if(we+V>X)throw new RangeError("Trying to access beyond buffer length")}a.prototype.readUintLE=a.prototype.readUIntLE=function(V,X,me){V=V>>>0,X=X>>>0,me||nt(V,X,this.length);let At=this[V],bt=1,Et=0;for(;++Et<X&&(bt*=256);)At+=this[V+Et]*bt;return At},a.prototype.readUintBE=a.prototype.readUIntBE=function(V,X,me){V=V>>>0,X=X>>>0,me||nt(V,X,this.length);let At=this[V+--X],bt=1;for(;X>0&&(bt*=256);)At+=this[V+--X]*bt;return At},a.prototype.readUint8=a.prototype.readUInt8=function(V,X){return V=V>>>0,X||nt(V,1,this.length),this[V]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(V,X){return V=V>>>0,X||nt(V,2,this.length),this[V]|this[V+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(V,X){return V=V>>>0,X||nt(V,2,this.length),this[V]<<8|this[V+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(V,X){return V=V>>>0,X||nt(V,4,this.length),(this[V]|this[V+1]<<8|this[V+2]<<16)+this[V+3]*16777216},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(V,X){return V=V>>>0,X||nt(V,4,this.length),this[V]*16777216+(this[V+1]<<16|this[V+2]<<8|this[V+3])},a.prototype.readBigUInt64LE=_r(function(V){V=V>>>0,Xe(V,"offset");const X=this[V],me=this[V+7];(X===void 0||me===void 0)&&wt(V,this.length-8);const At=X+this[++V]*2**8+this[++V]*2**16+this[++V]*2**24,bt=this[++V]+this[++V]*2**8+this[++V]*2**16+me*2**24;return BigInt(At)+(BigInt(bt)<<BigInt(32))}),a.prototype.readBigUInt64BE=_r(function(V){V=V>>>0,Xe(V,"offset");const X=this[V],me=this[V+7];(X===void 0||me===void 0)&&wt(V,this.length-8);const At=X*2**24+this[++V]*2**16+this[++V]*2**8+this[++V],bt=this[++V]*2**24+this[++V]*2**16+this[++V]*2**8+me;return(BigInt(At)<<BigInt(32))+BigInt(bt)}),a.prototype.readIntLE=function(V,X,me){V=V>>>0,X=X>>>0,me||nt(V,X,this.length);let At=this[V],bt=1,Et=0;for(;++Et<X&&(bt*=256);)At+=this[V+Et]*bt;return bt*=128,At>=bt&&(At-=Math.pow(2,8*X)),At},a.prototype.readIntBE=function(V,X,me){V=V>>>0,X=X>>>0,me||nt(V,X,this.length);let At=X,bt=1,Et=this[V+--At];for(;At>0&&(bt*=256);)Et+=this[V+--At]*bt;return bt*=128,Et>=bt&&(Et-=Math.pow(2,8*X)),Et},a.prototype.readInt8=function(V,X){return V=V>>>0,X||nt(V,1,this.length),this[V]&128?(255-this[V]+1)*-1:this[V]},a.prototype.readInt16LE=function(V,X){V=V>>>0,X||nt(V,2,this.length);const me=this[V]|this[V+1]<<8;return me&32768?me|4294901760:me},a.prototype.readInt16BE=function(V,X){V=V>>>0,X||nt(V,2,this.length);const me=this[V+1]|this[V]<<8;return me&32768?me|4294901760:me},a.prototype.readInt32LE=function(V,X){return V=V>>>0,X||nt(V,4,this.length),this[V]|this[V+1]<<8|this[V+2]<<16|this[V+3]<<24},a.prototype.readInt32BE=function(V,X){return V=V>>>0,X||nt(V,4,this.length),this[V]<<24|this[V+1]<<16|this[V+2]<<8|this[V+3]},a.prototype.readBigInt64LE=_r(function(V){V=V>>>0,Xe(V,"offset");const X=this[V],me=this[V+7];(X===void 0||me===void 0)&&wt(V,this.length-8);const At=this[V+4]+this[V+5]*2**8+this[V+6]*2**16+(me<<24);return(BigInt(At)<<BigInt(32))+BigInt(X+this[++V]*2**8+this[++V]*2**16+this[++V]*2**24)}),a.prototype.readBigInt64BE=_r(function(V){V=V>>>0,Xe(V,"offset");const X=this[V],me=this[V+7];(X===void 0||me===void 0)&&wt(V,this.length-8);const At=(X<<24)+this[++V]*2**16+this[++V]*2**8+this[++V];return(BigInt(At)<<BigInt(32))+BigInt(this[++V]*2**24+this[++V]*2**16+this[++V]*2**8+me)}),a.prototype.readFloatLE=function(V,X){return V=V>>>0,X||nt(V,4,this.length),t.read(this,V,!0,23,4)},a.prototype.readFloatBE=function(V,X){return V=V>>>0,X||nt(V,4,this.length),t.read(this,V,!1,23,4)},a.prototype.readDoubleLE=function(V,X){return V=V>>>0,X||nt(V,8,this.length),t.read(this,V,!0,52,8)},a.prototype.readDoubleBE=function(V,X){return V=V>>>0,X||nt(V,8,this.length),t.read(this,V,!1,52,8)};function Je(we,V,X,me,At,bt){if(!a.isBuffer(we))throw new TypeError('"buffer" argument must be a Buffer instance');if(V>At||V<bt)throw new RangeError('"value" argument is out of bounds');if(X+me>we.length)throw new RangeError("Index out of range")}a.prototype.writeUintLE=a.prototype.writeUIntLE=function(V,X,me,At){if(V=+V,X=X>>>0,me=me>>>0,!At){const sr=Math.pow(2,8*me)-1;Je(this,V,X,me,sr,0)}let bt=1,Et=0;for(this[X]=V&255;++Et<me&&(bt*=256);)this[X+Et]=V/bt&255;return X+me},a.prototype.writeUintBE=a.prototype.writeUIntBE=function(V,X,me,At){if(V=+V,X=X>>>0,me=me>>>0,!At){const sr=Math.pow(2,8*me)-1;Je(this,V,X,me,sr,0)}let bt=me-1,Et=1;for(this[X+bt]=V&255;--bt>=0&&(Et*=256);)this[X+bt]=V/Et&255;return X+me},a.prototype.writeUint8=a.prototype.writeUInt8=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,1,255,0),this[X]=V&255,X+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,2,65535,0),this[X]=V&255,this[X+1]=V>>>8,X+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,2,65535,0),this[X]=V>>>8,this[X+1]=V&255,X+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,4,4294967295,0),this[X+3]=V>>>24,this[X+2]=V>>>16,this[X+1]=V>>>8,this[X]=V&255,X+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,4,4294967295,0),this[X]=V>>>24,this[X+1]=V>>>16,this[X+2]=V>>>8,this[X+3]=V&255,X+4};function Vt(we,V,X,me,At){Ze(V,me,At,we,X,7);let bt=Number(V&BigInt(4294967295));we[X++]=bt,bt=bt>>8,we[X++]=bt,bt=bt>>8,we[X++]=bt,bt=bt>>8,we[X++]=bt;let Et=Number(V>>BigInt(32)&BigInt(4294967295));return we[X++]=Et,Et=Et>>8,we[X++]=Et,Et=Et>>8,we[X++]=Et,Et=Et>>8,we[X++]=Et,X}function pt(we,V,X,me,At){Ze(V,me,At,we,X,7);let bt=Number(V&BigInt(4294967295));we[X+7]=bt,bt=bt>>8,we[X+6]=bt,bt=bt>>8,we[X+5]=bt,bt=bt>>8,we[X+4]=bt;let Et=Number(V>>BigInt(32)&BigInt(4294967295));return we[X+3]=Et,Et=Et>>8,we[X+2]=Et,Et=Et>>8,we[X+1]=Et,Et=Et>>8,we[X]=Et,X+8}a.prototype.writeBigUInt64LE=_r(function(V,X=0){return Vt(this,V,X,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeBigUInt64BE=_r(function(V,X=0){return pt(this,V,X,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeIntLE=function(V,X,me,At){if(V=+V,X=X>>>0,!At){const Lt=Math.pow(2,8*me-1);Je(this,V,X,me,Lt-1,-Lt)}let bt=0,Et=1,sr=0;for(this[X]=V&255;++bt<me&&(Et*=256);)V<0&&sr===0&&this[X+bt-1]!==0&&(sr=1),this[X+bt]=(V/Et>>0)-sr&255;return X+me},a.prototype.writeIntBE=function(V,X,me,At){if(V=+V,X=X>>>0,!At){const Lt=Math.pow(2,8*me-1);Je(this,V,X,me,Lt-1,-Lt)}let bt=me-1,Et=1,sr=0;for(this[X+bt]=V&255;--bt>=0&&(Et*=256);)V<0&&sr===0&&this[X+bt+1]!==0&&(sr=1),this[X+bt]=(V/Et>>0)-sr&255;return X+me},a.prototype.writeInt8=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,1,127,-128),V<0&&(V=255+V+1),this[X]=V&255,X+1},a.prototype.writeInt16LE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,2,32767,-32768),this[X]=V&255,this[X+1]=V>>>8,X+2},a.prototype.writeInt16BE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,2,32767,-32768),this[X]=V>>>8,this[X+1]=V&255,X+2},a.prototype.writeInt32LE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,4,2147483647,-2147483648),this[X]=V&255,this[X+1]=V>>>8,this[X+2]=V>>>16,this[X+3]=V>>>24,X+4},a.prototype.writeInt32BE=function(V,X,me){return V=+V,X=X>>>0,me||Je(this,V,X,4,2147483647,-2147483648),V<0&&(V=4294967295+V+1),this[X]=V>>>24,this[X+1]=V>>>16,this[X+2]=V>>>8,this[X+3]=V&255,X+4},a.prototype.writeBigInt64LE=_r(function(V,X=0){return Vt(this,V,X,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),a.prototype.writeBigInt64BE=_r(function(V,X=0){return pt(this,V,X,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function dt(we,V,X,me,At,bt){if(X+me>we.length)throw new RangeError("Index out of range");if(X<0)throw new RangeError("Index out of range")}function kt(we,V,X,me,At){return V=+V,X=X>>>0,At||dt(we,V,X,4),t.write(we,V,X,me,23,4),X+4}a.prototype.writeFloatLE=function(V,X,me){return kt(this,V,X,!0,me)},a.prototype.writeFloatBE=function(V,X,me){return kt(this,V,X,!1,me)};function Dt(we,V,X,me,At){return V=+V,X=X>>>0,At||dt(we,V,X,8),t.write(we,V,X,me,52,8),X+8}a.prototype.writeDoubleLE=function(V,X,me){return Dt(this,V,X,!0,me)},a.prototype.writeDoubleBE=function(V,X,me){return Dt(this,V,X,!1,me)},a.prototype.copy=function(V,X,me,At){if(!a.isBuffer(V))throw new TypeError("argument should be a Buffer");if(me||(me=0),!At&&At!==0&&(At=this.length),X>=V.length&&(X=V.length),X||(X=0),At>0&&At<me&&(At=me),At===me||V.length===0||this.length===0)return 0;if(X<0)throw new RangeError("targetStart out of bounds");if(me<0||me>=this.length)throw new RangeError("Index out of range");if(At<0)throw new RangeError("sourceEnd out of bounds");At>this.length&&(At=this.length),V.length-X<At-me&&(At=V.length-X+me);const bt=At-me;return this===V&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(X,me,At):Uint8Array.prototype.set.call(V,this.subarray(me,At),X),bt},a.prototype.fill=function(V,X,me,At){if(typeof V=="string"){if(typeof X=="string"?(At=X,X=0,me=this.length):typeof me=="string"&&(At=me,me=this.length),At!==void 0&&typeof At!="string")throw new TypeError("encoding must be a string");if(typeof At=="string"&&!a.isEncoding(At))throw new TypeError("Unknown encoding: "+At);if(V.length===1){const Et=V.charCodeAt(0);(At==="utf8"&&Et<128||At==="latin1")&&(V=Et)}}else typeof V=="number"?V=V&255:typeof V=="boolean"&&(V=Number(V));if(X<0||this.length<X||this.length<me)throw new RangeError("Out of range index");if(me<=X)return this;X=X>>>0,me=me===void 0?this.length:me>>>0,V||(V=0);let bt;if(typeof V=="number")for(bt=X;bt<me;++bt)this[bt]=V;else{const Et=a.isBuffer(V)?V:a.from(V,At),sr=Et.length;if(sr===0)throw new TypeError('The value "'+V+'" is invalid for argument "value"');for(bt=0;bt<me-X;++bt)this[bt+X]=Et[bt%sr]}return this};const Se={};function de(we,V,X){Se[we]=class extends X{constructor(){super(),Object.defineProperty(this,"message",{value:V.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${we}]`,this.stack,delete this.name}get code(){return we}set code(At){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:At,writable:!0})}toString(){return`${this.name} [${we}]: ${this.message}`}}}de("ERR_BUFFER_OUT_OF_BOUNDS",function(we){return we?`${we} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),de("ERR_INVALID_ARG_TYPE",function(we,V){return`The "${we}" argument must be of type number. Received type ${typeof V}`},TypeError),de("ERR_OUT_OF_RANGE",function(we,V,X){let me=`The value of "${we}" is out of range.`,At=X;return Number.isInteger(X)&&Math.abs(X)>2**32?At=xe(String(X)):typeof X=="bigint"&&(At=String(X),(X>BigInt(2)**BigInt(32)||X<-(BigInt(2)**BigInt(32)))&&(At=xe(At)),At+="n"),me+=` It must be ${V}. Received ${At}`,me},RangeError);function xe(we){let V="",X=we.length;const me=we[0]==="-"?1:0;for(;X>=me+4;X-=3)V=`_${we.slice(X-3,X)}${V}`;return`${we.slice(0,X)}${V}`}function Pe(we,V,X){Xe(V,"offset"),(we[V]===void 0||we[V+X]===void 0)&&wt(V,we.length-(X+1))}function Ze(we,V,X,me,At,bt){if(we>X||we<V){const Et=typeof V=="bigint"?"n":"";let sr;throw bt>3?V===0||V===BigInt(0)?sr=`>= 0${Et} and < 2${Et} ** ${(bt+1)*8}${Et}`:sr=`>= -(2${Et} ** ${(bt+1)*8-1}${Et}) and < 2 ** ${(bt+1)*8-1}${Et}`:sr=`>= ${V}${Et} and <= ${X}${Et}`,new Se.ERR_OUT_OF_RANGE("value",sr,we)}Pe(me,At,bt)}function Xe(we,V){if(typeof we!="number")throw new Se.ERR_INVALID_ARG_TYPE(V,"number",we)}function wt(we,V,X){throw Math.floor(we)!==we?(Xe(we,X),new Se.ERR_OUT_OF_RANGE(X||"offset","an integer",we)):V<0?new Se.ERR_BUFFER_OUT_OF_BOUNDS:new Se.ERR_OUT_OF_RANGE(X||"offset",`>= ${X?1:0} and <= ${V}`,we)}const Kt=/[^+/0-9A-Za-z-_]/g;function Pt(we){if(we=we.split("=")[0],we=we.trim().replace(Kt,""),we.length<2)return"";for(;we.length%4!==0;)we=we+"=";return we}function zn(we,V){V=V||1/0;let X;const me=we.length;let At=null;const bt=[];for(let Et=0;Et<me;++Et){if(X=we.charCodeAt(Et),X>55295&&X<57344){if(!At){if(X>56319){(V-=3)>-1&&bt.push(239,191,189);continue}else if(Et+1===me){(V-=3)>-1&&bt.push(239,191,189);continue}At=X;continue}if(X<56320){(V-=3)>-1&&bt.push(239,191,189),At=X;continue}X=(At-55296<<10|X-56320)+65536}else At&&(V-=3)>-1&&bt.push(239,191,189);if(At=null,X<128){if((V-=1)<0)break;bt.push(X)}else if(X<2048){if((V-=2)<0)break;bt.push(X>>6|192,X&63|128)}else if(X<65536){if((V-=3)<0)break;bt.push(X>>12|224,X>>6&63|128,X&63|128)}else if(X<1114112){if((V-=4)<0)break;bt.push(X>>18|240,X>>12&63|128,X>>6&63|128,X&63|128)}else throw new Error("Invalid code point")}return bt}function mt(we){const V=[];for(let X=0;X<we.length;++X)V.push(we.charCodeAt(X)&255);return V}function pn(we,V){let X,me,At;const bt=[];for(let Et=0;Et<we.length&&!((V-=2)<0);++Et)X=we.charCodeAt(Et),me=X>>8,At=X%256,bt.push(At),bt.push(me);return bt}function ir(we){return n.toByteArray(Pt(we))}function Sn(we,V,X,me){let At;for(At=0;At<me&&!(At+X>=V.length||At>=we.length);++At)V[At+X]=we[At];return At}function nr(we,V){return we instanceof V||we!=null&&we.constructor!=null&&we.constructor.name!=null&&we.constructor.name===V.name}function Mr(we){return we!==we}const Qr=function(){const we="0123456789abcdef",V=new Array(256);for(let X=0;X<16;++X){const me=X*16;for(let At=0;At<16;++At)V[me+At]=we[X]+we[At]}return V}();function _r(we){return typeof BigInt>"u"?vi:we}function vi(){throw new Error("BigInt not supported")}})(bU);const $q=ga(bU);var Yq="Expected a function",wU="__lodash_hash_undefined__",MU=1/0,qq="[object Function]",Vq="[object GeneratorFunction]",Hq="[object Symbol]",Zq=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Xq=/^\w*$/,Jq=/^\./,eV=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,tV=/[\\^$.*+?()[\]{}|]/g,nV=/\\(\\)?/g,rV=/^\[object .+?Constructor\]$/,iV=typeof window=="object"&&window&&window.Object===Object&&window,oV=typeof self=="object"&&self&&self.Object===Object&&self,cB=iV||oV||Function("return this")();function aV(e,n){return e==null?void 0:e[n]}function sV(e){var n=!1;if(e!=null&&typeof e.toString!="function")try{n=!!(e+"")}catch{}return n}var lV=Array.prototype,uV=Function.prototype,SU=Object.prototype,Zw=cB["__core-js_shared__"],MI=function(){var e=/[^.]+$/.exec(Zw&&Zw.keys&&Zw.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),EU=uV.toString,dB=SU.hasOwnProperty,OU=SU.toString,AV=RegExp("^"+EU.call(dB).replace(tV,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),SI=cB.Symbol,cV=lV.splice,dV=BU(cB,"Map"),t_=BU(Object,"create"),EI=SI?SI.prototype:void 0,OI=EI?EI.toString:void 0;function l1(e){var n=-1,t=e?e.length:0;for(this.clear();++n<t;){var r=e[n];this.set(r[0],r[1])}}function hV(){this.__data__=t_?t_(null):{}}function fV(e){return this.has(e)&&delete this.__data__[e]}function pV(e){var n=this.__data__;if(t_){var t=n[e];return t===wU?void 0:t}return dB.call(n,e)?n[e]:void 0}function mV(e){var n=this.__data__;return t_?n[e]!==void 0:dB.call(n,e)}function gV(e,n){var t=this.__data__;return t[e]=t_&&n===void 0?wU:n,this}l1.prototype.clear=hV;l1.prototype.delete=fV;l1.prototype.get=pV;l1.prototype.has=mV;l1.prototype.set=gV;function Fy(e){var n=-1,t=e?e.length:0;for(this.clear();++n<t;){var r=e[n];this.set(r[0],r[1])}}function yV(){this.__data__=[]}function vV(e){var n=this.__data__,t=N4(n,e);if(t<0)return!1;var r=n.length-1;return t==r?n.pop():cV.call(n,t,1),!0}function CV(e){var n=this.__data__,t=N4(n,e);return t<0?void 0:n[t][1]}function _V(e){return N4(this.__data__,e)>-1}function bV(e,n){var t=this.__data__,r=N4(t,e);return r<0?t.push([e,n]):t[r][1]=n,this}Fy.prototype.clear=yV;Fy.prototype.delete=vV;Fy.prototype.get=CV;Fy.prototype.has=_V;Fy.prototype.set=bV;function v1(e){var n=-1,t=e?e.length:0;for(this.clear();++n<t;){var r=e[n];this.set(r[0],r[1])}}function xV(){this.__data__={hash:new l1,map:new(dV||Fy),string:new l1}}function wV(e){return G4(this,e).delete(e)}function MV(e){return G4(this,e).get(e)}function SV(e){return G4(this,e).has(e)}function EV(e,n){return G4(this,e).set(e,n),this}v1.prototype.clear=xV;v1.prototype.delete=wV;v1.prototype.get=MV;v1.prototype.has=SV;v1.prototype.set=EV;function N4(e,n){for(var t=e.length;t--;)if(RV(e[t][0],n))return t;return-1}function OV(e,n){n=TV(n,e)?[n]:IV(n);for(var t=0,r=n.length;e!=null&&t<r;)e=e[DV(n[t++])];return t&&t==r?e:void 0}function BV(e){if(!IU(e)||PV(e))return!1;var n=LV(e)||sV(e)?AV:rV;return n.test(UV(e))}function kV(e){if(typeof e=="string")return e;if(fB(e))return OI?OI.call(e):"";var n=e+"";return n=="0"&&1/e==-MU?"-0":n}function IV(e){return kU(e)?e:FV(e)}function G4(e,n){var t=e.__data__;return KV(n)?t[typeof n=="string"?"string":"hash"]:t.map}function BU(e,n){var t=aV(e,n);return BV(t)?t:void 0}function TV(e,n){if(kU(e))return!1;var t=typeof e;return t=="number"||t=="symbol"||t=="boolean"||e==null||fB(e)?!0:Xq.test(e)||!Zq.test(e)||n!=null&&e in Object(n)}function KV(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}function PV(e){return!!MI&&MI in e}var FV=hB(function(e){e=jV(e);var n=[];return Jq.test(e)&&n.push(""),e.replace(eV,function(t,r,i,o){n.push(i?o.replace(nV,"$1"):r||t)}),n});function DV(e){if(typeof e=="string"||fB(e))return e;var n=e+"";return n=="0"&&1/e==-MU?"-0":n}function UV(e){if(e!=null){try{return EU.call(e)}catch{}try{return e+""}catch{}}return""}function hB(e,n){if(typeof e!="function"||n&&typeof n!="function")throw new TypeError(Yq);var t=function(){var r=arguments,i=n?n.apply(this,r):r[0],o=t.cache;if(o.has(i))return o.get(i);var s=e.apply(this,r);return t.cache=o.set(i,s),s};return t.cache=new(hB.Cache||v1),t}hB.Cache=v1;function RV(e,n){return e===n||e!==e&&n!==n}var kU=Array.isArray;function LV(e){var n=IU(e)?OU.call(e):"";return n==qq||n==Vq}function IU(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function zV(e){return!!e&&typeof e=="object"}function fB(e){return typeof e=="symbol"||zV(e)&&OU.call(e)==Hq}function jV(e){return e==null?"":kV(e)}function WV(e,n,t){var r=e==null?void 0:OV(e,n);return r===void 0?t:r}var NV=WV;const GV=ga(NV);var n3={exports:{}};/**
|
||
* @license
|
||
* Lodash <https://lodash.com/>
|
||
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
||
* Released under MIT license <https://lodash.com/license>
|
||
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
||
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
||
*/n3.exports;(function(e,n){(function(){var t,r="4.17.21",i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",a="Invalid `variable` option passed into `_.template`",f="__lodash_hash_undefined__",g=500,x="__lodash_placeholder__",k=1,B=2,P=4,R=1,H=2,W=1,$=2,q=4,oe=8,ne=16,ce=32,ae=64,ue=128,ye=256,Re=512,Ne=30,rt="...",ct=800,Fe=16,He=1,Ce=2,jt=3,Ft=1/0,Jt=9007199254740991,Nt=17976931348623157e292,Ve=NaN,nt=4294967295,Je=nt-1,Vt=nt>>>1,pt=[["ary",ue],["bind",W],["bindKey",$],["curry",oe],["curryRight",ne],["flip",Re],["partial",ce],["partialRight",ae],["rearg",ye]],dt="[object Arguments]",kt="[object Array]",Dt="[object AsyncFunction]",Se="[object Boolean]",de="[object Date]",xe="[object DOMException]",Pe="[object Error]",Ze="[object Function]",Xe="[object GeneratorFunction]",wt="[object Map]",Kt="[object Number]",Pt="[object Null]",zn="[object Object]",mt="[object Promise]",pn="[object Proxy]",ir="[object RegExp]",Sn="[object Set]",nr="[object String]",Mr="[object Symbol]",Qr="[object Undefined]",_r="[object WeakMap]",vi="[object WeakSet]",we="[object ArrayBuffer]",V="[object DataView]",X="[object Float32Array]",me="[object Float64Array]",At="[object Int8Array]",bt="[object Int16Array]",Et="[object Int32Array]",sr="[object Uint8Array]",Lt="[object Uint8ClampedArray]",Fn="[object Uint16Array]",on="[object Uint32Array]",m=/\b__p \+= '';/g,un=/\b(__p \+=) '' \+/g,In=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Gn=/&(?:amp|lt|gt|quot|#39);/g,Zn=/[&<>"']/g,Ke=RegExp(Gn.source),fe=RegExp(Zn.source),_e=/<%-([\s\S]+?)%>/g,Ee=/<%([\s\S]+?)%>/g,Te=/<%=([\s\S]+?)%>/g,at=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,it=/^\w*$/,ht=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,et=/[\\^$.*+?()[\]{}|]/g,Ct=RegExp(et.source),rn=/^\s+/,Gt=/\s/,$t=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,gn=/\{\n\/\* \[wrapped with (.+)\] \*/,Jn=/,? & /,qn=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Tr=/[()=,{}\[\]\/\s]/,vr=/\\(\\)?/g,Dr=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Yr=/\w*$/,Zr=/^[-+]0x[0-9a-f]+$/i,Cr=/^0b[01]+$/i,ui=/^\[object .+?Constructor\]$/,Ii=/^0o[0-7]+$/i,Io=/^(?:0|[1-9]\d*)$/,Ci=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,so=/($^)/,Yo=/['\n\r\u2028\u2029\\]/g,ba="\\ud800-\\udfff",Ql="\\u0300-\\u036f",Ai="\\ufe20-\\ufe2f",Mi="\\u20d0-\\u20ff",rr=Ql+Ai+Mi,lo="\\u2700-\\u27bf",Gi="a-z\\xdf-\\xf6\\xf8-\\xff",la="\\xac\\xb1\\xd7\\xf7",ve="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Ge="\\u2000-\\u206f",Ht=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",mn="A-Z\\xc0-\\xd6\\xd8-\\xde",Ot="\\ufe0e\\ufe0f",En=la+ve+Ge+Ht,zr="['’]",Lr="["+ba+"]",Ti="["+En+"]",po="["+rr+"]",Cl="\\d+",br="["+lo+"]",_i="["+Gi+"]",_l="[^"+ba+En+Cl+lo+Gi+mn+"]",Qa="\\ud83c[\\udffb-\\udfff]",ys="(?:"+po+"|"+Qa+")",qs="[^"+ba+"]",Vs="(?:\\ud83c[\\udde6-\\uddff]){2}",va="[\\ud800-\\udbff][\\udc00-\\udfff]",$a="["+mn+"]",ll="\\u200d",xu="(?:"+_i+"|"+_l+")",bl="(?:"+$a+"|"+_l+")",CA="(?:"+zr+"(?:d|ll|m|re|s|t|ve))?",HA="(?:"+zr+"(?:D|LL|M|RE|S|T|VE))?",Hu=ys+"?",ZA="["+Ot+"]?",_A="(?:"+ll+"(?:"+[qs,Vs,va].join("|")+")"+ZA+Hu+")*",Ya="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",vs="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",bA=ZA+Hu+_A,Zu="(?:"+[br,Vs,va].join("|")+")"+bA,Ds="(?:"+[qs+po+"?",po,Vs,va,Lr].join("|")+")",Us=RegExp(zr,"g"),Cs=RegExp(po,"g"),lu=RegExp(Qa+"(?="+Qa+")|"+Ds+bA,"g"),wu=RegExp([$a+"?"+_i+"+"+CA+"(?="+[Ti,$a,"$"].join("|")+")",bl+"+"+HA+"(?="+[Ti,$a+xu,"$"].join("|")+")",$a+"?"+xu+"+"+CA,$a+"+"+HA,vs,Ya,Cl,Zu].join("|"),"g"),uu=RegExp("["+ll+ba+rr+Ot+"]"),as=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Mu=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Au=-1,bo={};bo[X]=bo[me]=bo[At]=bo[bt]=bo[Et]=bo[sr]=bo[Lt]=bo[Fn]=bo[on]=!0,bo[dt]=bo[kt]=bo[we]=bo[Se]=bo[V]=bo[de]=bo[Pe]=bo[Ze]=bo[wt]=bo[Kt]=bo[zn]=bo[ir]=bo[Sn]=bo[nr]=bo[_r]=!1;var mo={};mo[dt]=mo[kt]=mo[we]=mo[V]=mo[Se]=mo[de]=mo[X]=mo[me]=mo[At]=mo[bt]=mo[Et]=mo[wt]=mo[Kt]=mo[zn]=mo[ir]=mo[Sn]=mo[nr]=mo[Mr]=mo[sr]=mo[Lt]=mo[Fn]=mo[on]=!0,mo[Pe]=mo[Ze]=mo[_r]=!1;var ee={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Ie={"&":"&","<":"<",">":">",'"':""","'":"'"},st={"&":"&","<":"<",">":">",""":'"',"'":"'"},Xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Sr=parseFloat,_n=parseInt,Si=typeof window=="object"&&window&&window.Object===Object&&window,Ki=typeof self=="object"&&self&&self.Object===Object&&self,qr=Si||Ki||Function("return this")(),Yi=n&&!n.nodeType&&n,qo=Yi&&!0&&e&&!e.nodeType&&e,Ca=qo&&qo.exports===Yi,Vo=Ca&&Si.process,Li=function(){try{var xt=qo&&qo.require&&qo.require("util").types;return xt||Vo&&Vo.binding&&Vo.binding("util")}catch{}}(),Xo=Li&&Li.isArrayBuffer,Pa=Li&&Li.isDate,Rs=Li&&Li.isMap,_s=Li&&Li.isRegExp,Su=Li&&Li.isSet,XA=Li&&Li.isTypedArray;function ss(xt,sn,Wt){switch(Wt.length){case 0:return xt.call(sn);case 1:return xt.call(sn,Wt[0]);case 2:return xt.call(sn,Wt[0],Wt[1]);case 3:return xt.call(sn,Wt[0],Wt[1],Wt[2])}return xt.apply(sn,Wt)}function jm(xt,sn,Wt,or){for(var ri=-1,to=xt==null?0:xt.length;++ri<to;){var ia=xt[ri];sn(or,ia,Wt(ia),xt)}return or}function $l(xt,sn){for(var Wt=-1,or=xt==null?0:xt.length;++Wt<or&&sn(xt[Wt],Wt,xt)!==!1;);return xt}function Bp(xt,sn){for(var Wt=xt==null?0:xt.length;Wt--&&sn(xt[Wt],Wt,xt)!==!1;);return xt}function Id(xt,sn){for(var Wt=-1,or=xt==null?0:xt.length;++Wt<or;)if(!sn(xt[Wt],Wt,xt))return!1;return!0}function cu(xt,sn){for(var Wt=-1,or=xt==null?0:xt.length,ri=0,to=[];++Wt<or;){var ia=xt[Wt];sn(ia,Wt,xt)&&(to[ri++]=ia)}return to}function Gc(xt,sn){var Wt=xt==null?0:xt.length;return!!Wt&&Ur(xt,sn,0)>-1}function Td(xt,sn,Wt){for(var or=-1,ri=xt==null?0:xt.length;++or<ri;)if(Wt(sn,xt[or]))return!0;return!1}function Mo(xt,sn){for(var Wt=-1,or=xt==null?0:xt.length,ri=Array(or);++Wt<or;)ri[Wt]=sn(xt[Wt],Wt,xt);return ri}function Eu(xt,sn){for(var Wt=-1,or=sn.length,ri=xt.length;++Wt<or;)xt[ri+Wt]=sn[Wt];return xt}function yh(xt,sn,Wt,or){var ri=-1,to=xt==null?0:xt.length;for(or&&to&&(Wt=xt[++ri]);++ri<to;)Wt=sn(Wt,xt[ri],ri,xt);return Wt}function vh(xt,sn,Wt,or){var ri=xt==null?0:xt.length;for(or&&ri&&(Wt=xt[--ri]);ri--;)Wt=sn(Wt,xt[ri],ri,xt);return Wt}function Yl(xt,sn){for(var Wt=-1,or=xt==null?0:xt.length;++Wt<or;)if(sn(xt[Wt],Wt,xt))return!0;return!1}var JA=Ro("length");function Qc(xt){return xt.split("")}function $c(xt){return xt.match(qn)||[]}function xf(xt,sn,Wt){var or;return Wt(xt,function(ri,to,ia){if(sn(ri,to,ia))return or=to,!1}),or}function ql(xt,sn,Wt,or){for(var ri=xt.length,to=Wt+(or?1:-1);or?to--:++to<ri;)if(sn(xt[to],to,xt))return to;return-1}function Ur(xt,sn,Wt){return sn===sn?ra(xt,sn,Wt):ql(xt,wf,Wt)}function Ch(xt,sn,Wt,or){for(var ri=Wt-1,to=xt.length;++ri<to;)if(or(xt[ri],sn))return ri;return-1}function wf(xt){return xt!==xt}function ec(xt,sn){var Wt=xt==null?0:xt.length;return Wt?Lo(xt,sn)/Wt:Ve}function Ro(xt){return function(sn){return sn==null?t:sn[xt]}}function _h(xt){return function(sn){return xt==null?t:xt[sn]}}function zi(xt,sn,Wt,or,ri){return ri(xt,function(to,ia,ho){Wt=or?(or=!1,to):sn(Wt,to,ia,ho)}),Wt}function Yc(xt,sn){var Wt=xt.length;for(xt.sort(sn);Wt--;)xt[Wt]=xt[Wt].value;return xt}function Lo(xt,sn){for(var Wt,or=-1,ri=xt.length;++or<ri;){var to=sn(xt[or]);to!==t&&(Wt=Wt===t?to:Wt+to)}return Wt}function So(xt,sn){for(var Wt=-1,or=Array(xt);++Wt<xt;)or[Wt]=sn(Wt);return or}function tc(xt,sn){return Mo(sn,function(Wt){return[Wt,xt[Wt]]})}function nc(xt){return xt&&xt.slice(0,Fd(xt)+1).replace(rn,"")}function Ls(xt){return function(sn){return xt(sn)}}function Kd(xt,sn){return Mo(sn,function(Wt){return xt[Wt]})}function Ou(xt,sn){return xt.has(sn)}function xl(xt,sn){for(var Wt=-1,or=xt.length;++Wt<or&&Ur(sn,xt[Wt],0)>-1;);return Wt}function Xu(xt,sn){for(var Wt=xt.length;Wt--&&Ur(sn,xt[Wt],0)>-1;);return Wt}function qc(xt,sn){for(var Wt=xt.length,or=0;Wt--;)xt[Wt]===sn&&++or;return or}var Mf=_h(ee),wl=_h(Ie);function Ju(xt){return"\\"+Xt[xt]}function bh(xt,sn){return xt==null?t:xt[sn]}function eA(xt){return uu.test(xt)}function xh(xt){return as.test(xt)}function kp(xt){for(var sn,Wt=[];!(sn=xt.next()).done;)Wt.push(sn.value);return Wt}function Pd(xt){var sn=-1,Wt=Array(xt.size);return xt.forEach(function(or,ri){Wt[++sn]=[ri,or]}),Wt}function rc(xt,sn){return function(Wt){return xt(sn(Wt))}}function Hs(xt,sn){for(var Wt=-1,or=xt.length,ri=0,to=[];++Wt<or;){var ia=xt[Wt];(ia===sn||ia===x)&&(xt[Wt]=x,to[ri++]=Wt)}return to}function Ml(xt){var sn=-1,Wt=Array(xt.size);return xt.forEach(function(or){Wt[++sn]=or}),Wt}function wh(xt){var sn=-1,Wt=Array(xt.size);return xt.forEach(function(or){Wt[++sn]=[or,or]}),Wt}function ra(xt,sn,Wt){for(var or=Wt-1,ri=xt.length;++or<ri;)if(xt[or]===sn)return or;return-1}function Bu(xt,sn,Wt){for(var or=Wt+1;or--;)if(xt[or]===sn)return or;return or}function bs(xt){return eA(xt)?Sl(xt):JA(xt)}function ul(xt){return eA(xt)?xA(xt):Qc(xt)}function Fd(xt){for(var sn=xt.length;sn--&&Gt.test(xt.charAt(sn)););return sn}var Dd=_h(st);function Sl(xt){for(var sn=lu.lastIndex=0;lu.test(xt);)++sn;return sn}function xA(xt){return xt.match(lu)||[]}function Vc(xt){return xt.match(wu)||[]}var Ud=function xt(sn){sn=sn==null?qr:ku.defaults(qr.Object(),sn,ku.pick(qr,Mu));var Wt=sn.Array,or=sn.Date,ri=sn.Error,to=sn.Function,ia=sn.Math,ho=sn.Object,xs=sn.RegExp,Rd=sn.String,El=sn.TypeError,tA=Wt.prototype,wA=to.prototype,Jo=ho.prototype,ls=sn["__core-js_shared__"],nA=wA.toString,Ei=Jo.hasOwnProperty,MA=0,Mh=function(){var v=/[^.]+$/.exec(ls&&ls.keys&&ls.keys.IE_PROTO||"");return v?"Symbol(src)_1."+v:""}(),Al=Jo.toString,ic=nA.call(ho),us=qr._,Ol=xs("^"+nA.call(Ei).replace(et,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Fa=Ca?sn.Buffer:t,jn=sn.Symbol,Hc=sn.Uint8Array,oc=Fa?Fa.allocUnsafe:t,cl=rc(ho.getPrototypeOf,ho),ac=ho.create,Nn=Jo.propertyIsEnumerable,rA=tA.splice,Sf=jn?jn.isConcatSpreadable:t,sc=jn?jn.iterator:t,Vl=jn?jn.toStringTag:t,lc=function(){try{var v=Ad(ho,"defineProperty");return v({},"",{}),v}catch{}}(),Sh=sn.clearTimeout!==qr.clearTimeout&&sn.clearTimeout,Zc=or&&or.now!==qr.Date.now&&or.now,Eh=sn.setTimeout!==qr.setTimeout&&sn.setTimeout,Hl=ia.ceil,go=ia.floor,Xc=ho.getOwnPropertySymbols,Ef=Fa?Fa.isBuffer:t,Of=sn.isFinite,Oh=tA.join,Bh=rc(ho.keys,ho),oa=ia.max,Eo=ia.min,uc=or.now,gr=sn.parseInt,Or=ia.random,SA=tA.reverse,Jc=Ad(sn,"DataView"),dl=Ad(sn,"Map"),xa=Ad(sn,"Promise"),Bl=Ad(sn,"Set"),As=Ad(sn,"WeakMap"),Iu=Ad(ho,"create"),iA=As&&new As,Oo={},zo=Va(Jc),Ip=Va(dl),du=Va(xa),Tu=Va(Bl),Bf=Va(As),Ac=jn?jn.prototype:t,cc=Ac?Ac.valueOf:t,ed=Ac?Ac.toString:t;function ke(v){if(Cn(v)&&!Q(v)&&!(v instanceof jr)){if(v instanceof uo)return v;if(Ei.call(v,"__wrapped__"))return fl(v)}return new uo(v)}var oA=function(){function v(){}return function(S){if(!xn(S))return{};if(ac)return ac(S);v.prototype=S;var F=new v;return v.prototype=t,F}}();function wa(){}function uo(v,S){this.__wrapped__=v,this.__actions__=[],this.__chain__=!!S,this.__index__=0,this.__values__=t}ke.templateSettings={escape:_e,evaluate:Ee,interpolate:Te,variable:"",imports:{_:ke}},ke.prototype=wa.prototype,ke.prototype.constructor=ke,uo.prototype=oA(wa.prototype),uo.prototype.constructor=uo;function jr(v){this.__wrapped__=v,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=nt,this.__views__=[]}function Ma(){var v=new jr(this.__wrapped__);return v.__actions__=el(this.__actions__),v.__dir__=this.__dir__,v.__filtered__=this.__filtered__,v.__iteratees__=el(this.__iteratees__),v.__takeCount__=this.__takeCount__,v.__views__=el(this.__views__),v}function Ku(){if(this.__filtered__){var v=new jr(this);v.__dir__=-1,v.__filtered__=!0}else v=this.clone(),v.__dir__*=-1;return v}function dc(){var v=this.__wrapped__.value(),S=this.__dir__,F=Q(v),Z=S<0,be=F?v.length:0,Ue=iv(0,be,this.__views__),ot=Ue.start,gt=Ue.end,It=gt-ot,yn=Z?gt:ot-1,vn=this.__iteratees__,kn=vn.length,fr=0,Gr=Eo(It,this.__takeCount__);if(!F||!Z&&be==It&&Gr==It)return ad(v,this.__actions__);var ci=[];e:for(;It--&&fr<Gr;){yn+=S;for(var ro=-1,di=v[yn];++ro<kn;){var _o=vn[ro],Bo=_o.iteratee,Bc=_o.type,dA=Bo(di);if(Bc==Ce)di=dA;else if(!dA){if(Bc==He)continue e;break e}}ci[fr++]=di}return ci}jr.prototype=oA(wa.prototype),jr.prototype.constructor=jr;function kl(v){var S=-1,F=v==null?0:v.length;for(this.clear();++S<F;){var Z=v[S];this.set(Z[0],Z[1])}}function kh(){this.__data__=Iu?Iu(null):{},this.size=0}function hc(v){var S=this.has(v)&&delete this.__data__[v];return this.size-=S?1:0,S}function Ih(v){var S=this.__data__;if(Iu){var F=S[v];return F===f?t:F}return Ei.call(S,v)?S[v]:t}function Ld(v){var S=this.__data__;return Iu?S[v]!==t:Ei.call(S,v)}function zd(v,S){var F=this.__data__;return this.size+=this.has(v)?0:1,F[v]=Iu&&S===t?f:S,this}kl.prototype.clear=kh,kl.prototype.delete=hc,kl.prototype.get=Ih,kl.prototype.has=Ld,kl.prototype.set=zd;function Il(v){var S=-1,F=v==null?0:v.length;for(this.clear();++S<F;){var Z=v[S];this.set(Z[0],Z[1])}}function kf(){this.__data__=[],this.size=0}function Pi(v){var S=this.__data__,F=hn(S,v);if(F<0)return!1;var Z=S.length-1;return F==Z?S.pop():rA.call(S,F,1),--this.size,!0}function O(v){var S=this.__data__,F=hn(S,v);return F<0?t:S[F][1]}function u(v){return hn(this.__data__,v)>-1}function p(v,S){var F=this.__data__,Z=hn(F,v);return Z<0?(++this.size,F.push([v,S])):F[Z][1]=S,this}Il.prototype.clear=kf,Il.prototype.delete=Pi,Il.prototype.get=O,Il.prototype.has=u,Il.prototype.set=p;function C(v){var S=-1,F=v==null?0:v.length;for(this.clear();++S<F;){var Z=v[S];this.set(Z[0],Z[1])}}function M(){this.size=0,this.__data__={hash:new kl,map:new(dl||Il),string:new kl}}function I(v){var S=Gf(this,v).delete(v);return this.size-=S?1:0,S}function L(v){return Gf(this,v).get(v)}function j(v){return Gf(this,v).has(v)}function G(v,S){var F=Gf(this,v),Z=F.size;return F.set(v,S),this.size+=F.size==Z?0:1,this}C.prototype.clear=M,C.prototype.delete=I,C.prototype.get=L,C.prototype.has=j,C.prototype.set=G;function te(v){var S=-1,F=v==null?0:v.length;for(this.__data__=new C;++S<F;)this.add(v[S])}function Ae(v){return this.__data__.set(v,f),this}function he(v){return this.__data__.has(v)}te.prototype.add=te.prototype.push=Ae,te.prototype.has=he;function Me(v){var S=this.__data__=new Il(v);this.size=S.size}function De(){this.__data__=new Il,this.size=0}function je(v){var S=this.__data__,F=S.delete(v);return this.size=S.size,F}function Qe(v){return this.__data__.get(v)}function Le(v){return this.__data__.has(v)}function ft(v,S){var F=this.__data__;if(F instanceof Il){var Z=F.__data__;if(!dl||Z.length<i-1)return Z.push([v,S]),this.size=++F.size,this;F=this.__data__=new C(Z)}return F.set(v,S),this.size=F.size,this}Me.prototype.clear=De,Me.prototype.delete=je,Me.prototype.get=Qe,Me.prototype.has=Le,Me.prototype.set=ft;function Bt(v,S){var F=Q(v),Z=!F&&z(v),be=!F&&!Z&&Be(v),Ue=!F&&!Z&&!be&&Ja(v),ot=F||Z||be||Ue,gt=ot?So(v.length,Rd):[],It=gt.length;for(var yn in v)(S||Ei.call(v,yn))&&!(ot&&(yn=="length"||be&&(yn=="offset"||yn=="parent")||Ue&&(yn=="buffer"||yn=="byteLength"||yn=="byteOffset")||b(yn,It)))&>.push(yn);return gt}function qe(v){var S=v.length;return S?v[id(0,S-1)]:t}function _t(v,S){return Ea(el(v),yr(S,0,v.length))}function Ut(v){return Ea(el(v))}function Tt(v,S,F){(F!==t&&!T(v[S],F)||F===t&&!(S in v))&&xr(v,S,F)}function en(v,S,F){var Z=v[S];(!(Ei.call(v,S)&&T(Z,F))||F===t&&!(S in v))&&xr(v,S,F)}function hn(v,S){for(var F=v.length;F--;)if(T(v[F][0],S))return F;return-1}function An(v,S,F,Z){return yo(v,function(be,Ue,ot){S(Z,be,F(be),ot)}),Z}function On(v,S){return v&&Tl(S,ml(S),v)}function lr(v,S){return v&&Tl(S,ju(S),v)}function xr(v,S,F){S=="__proto__"&&lc?lc(v,S,{configurable:!0,enumerable:!0,value:F,writable:!0}):v[S]=F}function Tn(v,S){for(var F=-1,Z=S.length,be=Wt(Z),Ue=v==null;++F<Z;)be[F]=Ue?t:Iv(v,S[F]);return be}function yr(v,S,F){return v===v&&(F!==t&&(v=v<=F?v:F),S!==t&&(v=v>=S?v:S)),v}function Qn(v,S,F,Z,be,Ue){var ot,gt=S&k,It=S&B,yn=S&P;if(F&&(ot=be?F(v,Z,be,Ue):F(v)),ot!==t)return ot;if(!xn(v))return v;var vn=Q(v);if(vn){if(ot=ov(v),!gt)return el(v,ot)}else{var kn=Es(v),fr=kn==Ze||kn==Xe;if(Be(v))return qm(v,gt);if(kn==zn||kn==dt||fr&&!be){if(ot=It||fr?{}:z1(v),!gt)return It?F1(v,lr(ot,v)):Zm(v,On(ot,v))}else{if(!mo[kn])return be?v:{};ot=Qf(v,kn,gt)}}Ue||(Ue=new Me);var Gr=Ue.get(v);if(Gr)return Gr;Ue.set(v,ot),Kl(v)?v.forEach(function(di){ot.add(Qn(di,S,F,di,v,Ue))}):Kn(v)&&v.forEach(function(di,_o){ot.set(_o,Qn(di,S,F,_o,v,Ue))});var ci=yn?It?Rp:Up:It?ju:ml,ro=vn?t:ci(v);return $l(ro||v,function(di,_o){ro&&(_o=di,di=v[_o]),en(ot,_o,Qn(di,S,F,_o,v,Ue))}),ot}function Ho(v){var S=ml(v);return function(F){return pi(F,v,S)}}function pi(v,S,F){var Z=F.length;if(v==null)return!Z;for(v=ho(v);Z--;){var be=F[Z],Ue=S[be],ot=v[be];if(ot===t&&!(be in v)||!Ue(ot))return!1}return!0}function ii(v,S,F){if(typeof v!="function")throw new El(s);return Ir(function(){v.apply(t,F)},S)}function si(v,S,F,Z){var be=-1,Ue=Gc,ot=!0,gt=v.length,It=[],yn=S.length;if(!gt)return It;F&&(S=Mo(S,Ls(F))),Z?(Ue=Td,ot=!1):S.length>=i&&(Ue=Ou,ot=!1,S=new te(S));e:for(;++be<gt;){var vn=v[be],kn=F==null?vn:F(vn);if(vn=Z||vn!==0?vn:0,ot&&kn===kn){for(var fr=yn;fr--;)if(S[fr]===kn)continue e;It.push(vn)}else Ue(S,kn,Z)||It.push(vn)}return It}var yo=ld(Ms),vo=ld(aA,!0);function Zs(v,S){var F=!0;return yo(v,function(Z,be,Ue){return F=!!S(Z,be,Ue),F}),F}function Sa(v,S,F){for(var Z=-1,be=v.length;++Z<be;){var Ue=v[Z],ot=S(Ue);if(ot!=null&&(gt===t?ot===ot&&!Go(ot):F(ot,gt)))var gt=ot,It=Ue}return It}function aa(v,S,F,Z){var be=v.length;for(F=Hr(F),F<0&&(F=-F>be?0:be+F),Z=Z===t||Z>be?be:Hr(Z),Z<0&&(Z+=be),Z=F>Z?0:eu(Z);F<Z;)v[F++]=S;return v}function _a(v,S){var F=[];return yo(v,function(Z,be,Ue){S(Z,be,Ue)&&F.push(Z)}),F}function no(v,S,F,Z,be){var Ue=-1,ot=v.length;for(F||(F=h),be||(be=[]);++Ue<ot;){var gt=v[Ue];S>0&&F(gt)?S>1?no(gt,S-1,F,Z,be):Eu(be,gt):Z||(be[be.length]=gt)}return be}var ws=Xm(),Pu=Xm(!0);function Ms(v,S){return v&&ws(v,S,ml)}function aA(v,S){return v&&Pu(v,S,ml)}function hu(v,S){return cu(S,function(F){return an(v[F])})}function Zo(v,S){S=sd(S,v);for(var F=0,Z=S.length;v!=null&&F<Z;)v=v[Oa(S[F++])];return F&&F==Z?v:t}function ji(v,S,F){var Z=S(v);return Q(v)?Z:Eu(Z,F(v))}function Oi(v){return v==null?v===t?Qr:Pt:Vl&&Vl in ho(v)?rv(v):Zt(v)}function cs(v,S){return v>S}function jo(v,S){return v!=null&&Ei.call(v,S)}function Da(v,S){return v!=null&&S in ho(v)}function ua(v,S,F){return v>=Eo(S,F)&&v<oa(S,F)}function sa(v,S,F){for(var Z=F?Td:Gc,be=v[0].length,Ue=v.length,ot=Ue,gt=Wt(Ue),It=1/0,yn=[];ot--;){var vn=v[ot];ot&&S&&(vn=Mo(vn,Ls(S))),It=Eo(vn.length,It),gt[ot]=!F&&(S||be>=120&&vn.length>=120)?new te(ot&&vn):t}vn=v[0];var kn=-1,fr=gt[0];e:for(;++kn<be&&yn.length<It;){var Gr=vn[kn],ci=S?S(Gr):Gr;if(Gr=F||Gr!==0?Gr:0,!(fr?Ou(fr,ci):Z(yn,ci,F))){for(ot=Ue;--ot;){var ro=gt[ot];if(!(ro?Ou(ro,ci):Z(v[ot],ci,F)))continue e}fr&&fr.push(ci),yn.push(Gr)}}return yn}function If(v,S,F,Z){return Ms(v,function(be,Ue,ot){S(Z,F(be),Ue,ot)}),Z}function Wo(v,S,F){S=sd(S,v),v=Wn(v,S);var Z=v==null?v:v[Oa(lA(S))];return Z==null?t:ss(Z,v,F)}function jd(v){return Cn(v)&&Oi(v)==dt}function fc(v){return Cn(v)&&Oi(v)==we}function EA(v){return Cn(v)&&Oi(v)==de}function hl(v,S,F,Z,be){return v===S?!0:v==null||S==null||!Cn(v)&&!Cn(S)?v!==v&&S!==S:Fu(v,S,F,Z,hl,be)}function Fu(v,S,F,Z,be,Ue){var ot=Q(v),gt=Q(S),It=ot?kt:Es(v),yn=gt?kt:Es(S);It=It==dt?zn:It,yn=yn==dt?zn:yn;var vn=It==zn,kn=yn==zn,fr=It==yn;if(fr&&Be(v)){if(!Be(S))return!1;ot=!0,vn=!1}if(fr&&!vn)return Ue||(Ue=new Me),ot||Ja(v)?mu(v,S,F,Z,be,Ue):Nf(v,S,It,F,Z,be,Ue);if(!(F&R)){var Gr=vn&&Ei.call(v,"__wrapped__"),ci=kn&&Ei.call(S,"__wrapped__");if(Gr||ci){var ro=Gr?v.value():v,di=ci?S.value():S;return Ue||(Ue=new Me),be(ro,di,F,Z,Ue)}}return fr?(Ue||(Ue=new Me),r0(v,S,F,Z,be,Ue)):!1}function OA(v){return Cn(v)&&Es(v)==wt}function Wd(v,S,F,Z){var be=F.length,Ue=be,ot=!Z;if(v==null)return!Ue;for(v=ho(v);be--;){var gt=F[be];if(ot&>[2]?gt[1]!==v[gt[0]]:!(gt[0]in v))return!1}for(;++be<Ue;){gt=F[be];var It=gt[0],yn=v[It],vn=gt[1];if(ot&>[2]){if(yn===t&&!(It in v))return!1}else{var kn=new Me;if(Z)var fr=Z(yn,vn,It,v,S,kn);if(!(fr===t?hl(vn,yn,R|H,Z,kn):fr))return!1}}return!0}function BA(v){if(!xn(v)||J(v))return!1;var S=an(v)?Ol:ui;return S.test(Va(v))}function Nd(v){return Cn(v)&&Oi(v)==ir}function Tf(v){return Cn(v)&&Es(v)==Sn}function td(v){return Cn(v)&&cr(v.length)&&!!bo[Oi(v)]}function Th(v){return typeof v=="function"?v:v==null?LA:typeof v=="object"?Q(v)?Gd(v[0],v[1]):k1(v):dk(v)}function pc(v){if(!pe(v))return Bh(v);var S=[];for(var F in ho(v))Ei.call(v,F)&&F!="constructor"&&S.push(F);return S}function Kh(v){if(!xn(v))return qt(v);var S=pe(v),F=[];for(var Z in v)Z=="constructor"&&(S||!Ei.call(v,Z))||F.push(Z);return F}function nd(v,S){return v<S}function rd(v,S){var F=-1,Z=le(v)?Wt(v.length):[];return yo(v,function(be,Ue,ot){Z[++F]=S(be,Ue,ot)}),Z}function k1(v){var S=Co(v);return S.length==1&&S[0][2]?Ye(S[0][0],S[0][1]):function(F){return F===v||Wd(F,v,S)}}function Gd(v,S){return E(v)&&We(S)?Ye(Oa(v),S):function(F){var Z=Iv(F,v);return Z===t&&Z===S?Tv(F,v):hl(S,Z,R|H)}}function Zl(v,S,F,Z,be){v!==S&&ws(S,function(Ue,ot){if(be||(be=new Me),xn(Ue))mc(v,S,ot,F,Zl,Z,be);else{var gt=Z?Z(fn(v,ot),Ue,ot+"",v,S,be):t;gt===t&&(gt=Ue),Tt(v,ot,gt)}},ju)}function mc(v,S,F,Z,be,Ue,ot){var gt=fn(v,F),It=fn(S,F),yn=ot.get(It);if(yn){Tt(v,F,yn);return}var vn=Ue?Ue(gt,It,F+"",v,S,ot):t,kn=vn===t;if(kn){var fr=Q(It),Gr=!fr&&Be(It),ci=!fr&&!Gr&&Ja(It);vn=It,fr||Gr||ci?Q(gt)?vn=gt:ge(gt)?vn=el(gt):Gr?(kn=!1,vn=qm(It,!0)):ci?(kn=!1,vn=Hm(It,!0)):vn=[]:No(It)||z(It)?(vn=gt,z(gt)?vn=Wi(gt):(!xn(gt)||an(gt))&&(vn=z1(It))):kn=!1}kn&&(ot.set(It,vn),be(vn,It,Z,Ue,ot),ot.delete(It)),Tt(v,F,vn)}function Qd(v,S){var F=v.length;if(F)return S+=S<0?F:0,b(S,F)?v[S]:t}function Wm(v,S,F){S.length?S=Mo(S,function(Ue){return Q(Ue)?function(ot){return Zo(ot,Ue.length===1?Ue[0]:Ue)}:Ue}):S=[LA];var Z=-1;S=Mo(S,Ls(Vr()));var be=rd(v,function(Ue,ot,gt){var It=Mo(S,function(yn){return yn(Ue)});return{criteria:It,index:++Z,value:Ue}});return Yc(be,function(Ue,ot){return Kp(Ue,ot,F)})}function I1(v,S){return Xs(v,S,function(F,Z){return Tv(v,Z)})}function Xs(v,S,F){for(var Z=-1,be=S.length,Ue={};++Z<be;){var ot=S[Z],gt=Zo(v,ot);F(gt,ot)&&$d(Ue,sd(ot,v),gt)}return Ue}function Ph(v){return function(S){return Zo(S,v)}}function Kf(v,S,F,Z){var be=Z?Ch:Ur,Ue=-1,ot=S.length,gt=v;for(v===S&&(S=el(S)),F&&(gt=Mo(v,Ls(F)));++Ue<ot;)for(var It=0,yn=S[Ue],vn=F?F(yn):yn;(It=be(gt,vn,It,Z))>-1;)gt!==v&&rA.call(gt,It,1),rA.call(v,It,1);return v}function Js(v,S){for(var F=v?S.length:0,Z=F-1;F--;){var be=S[F];if(F==Z||be!==Ue){var Ue=be;b(be)?rA.call(v,be,1):Tp(v,be)}}return v}function id(v,S){return v+go(Or()*(S-v+1))}function ev(v,S,F,Z){for(var be=-1,Ue=oa(Hl((S-v)/(F||1)),0),ot=Wt(Ue);Ue--;)ot[Z?Ue:++be]=v,v+=F;return ot}function Fh(v,S){var F="";if(!v||S<1||S>Jt)return F;do S%2&&(F+=v),S=go(S/2),S&&(v+=v);while(S);return F}function Qi(v,S){return Br(Bn(v,S,LA),v+"")}function Nm(v){return qe(ng(v))}function Gm(v,S){var F=ng(v);return Ea(F,yr(S,0,F.length))}function $d(v,S,F,Z){if(!xn(v))return v;S=sd(S,v);for(var be=-1,Ue=S.length,ot=Ue-1,gt=v;gt!=null&&++be<Ue;){var It=Oa(S[be]),yn=F;if(It==="__proto__"||It==="constructor"||It==="prototype")return v;if(be!=ot){var vn=gt[It];yn=Z?Z(vn,It,gt):t,yn===t&&(yn=xn(vn)?vn:b(S[be+1])?[]:{})}en(gt,It,yn),gt=gt[It]}return v}var T1=iA?function(v,S){return iA.set(v,S),v}:LA,Qm=lc?function(v,S){return lc(v,"toString",{configurable:!0,enumerable:!1,value:Ew(S),writable:!0})}:LA;function K1(v){return Ea(ng(v))}function qa(v,S,F){var Z=-1,be=v.length;S<0&&(S=-S>be?0:be+S),F=F>be?be:F,F<0&&(F+=be),be=S>F?0:F-S>>>0,S>>>=0;for(var Ue=Wt(be);++Z<be;)Ue[Z]=v[Z+S];return Ue}function gc(v,S){var F;return yo(v,function(Z,be,Ue){return F=S(Z,be,Ue),!F}),!!F}function Ss(v,S,F){var Z=0,be=v==null?Z:v.length;if(typeof S=="number"&&S===S&&be<=Vt){for(;Z<be;){var Ue=Z+be>>>1,ot=v[Ue];ot!==null&&!Go(ot)&&(F?ot<=S:ot<S)?Z=Ue+1:be=Ue}return be}return od(v,S,LA,F)}function od(v,S,F,Z){var be=0,Ue=v==null?0:v.length;if(Ue===0)return 0;S=F(S);for(var ot=S!==S,gt=S===null,It=Go(S),yn=S===t;be<Ue;){var vn=go((be+Ue)/2),kn=F(v[vn]),fr=kn!==t,Gr=kn===null,ci=kn===kn,ro=Go(kn);if(ot)var di=Z||ci;else yn?di=ci&&(Z||fr):gt?di=ci&&fr&&(Z||!Gr):It?di=ci&&fr&&!Gr&&(Z||!ro):Gr||ro?di=!1:di=Z?kn<=S:kn<S;di?be=vn+1:Ue=vn}return Eo(Ue,Je)}function kA(v,S){for(var F=-1,Z=v.length,be=0,Ue=[];++F<Z;){var ot=v[F],gt=S?S(ot):ot;if(!F||!T(gt,It)){var It=gt;Ue[be++]=ot===0?0:ot}}return Ue}function $m(v){return typeof v=="number"?v:Go(v)?Ve:+v}function fu(v){if(typeof v=="string")return v;if(Q(v))return Mo(v,fu)+"";if(Go(v))return ed?ed.call(v):"";var S=v+"";return S=="0"&&1/v==-Ft?"-0":S}function pu(v,S,F){var Z=-1,be=Gc,Ue=v.length,ot=!0,gt=[],It=gt;if(F)ot=!1,be=Td;else if(Ue>=i){var yn=S?null:nv(v);if(yn)return Ml(yn);ot=!1,be=Ou,It=new te}else It=S?[]:gt;e:for(;++Z<Ue;){var vn=v[Z],kn=S?S(vn):vn;if(vn=F||vn!==0?vn:0,ot&&kn===kn){for(var fr=It.length;fr--;)if(It[fr]===kn)continue e;S&&It.push(kn),gt.push(vn)}else be(It,kn,F)||(It!==gt&&It.push(kn),gt.push(vn))}return gt}function Tp(v,S){return S=sd(S,v),v=Wn(v,S),v==null||delete v[Oa(lA(S))]}function Ym(v,S,F,Z){return $d(v,S,F(Zo(v,S)),Z)}function Yd(v,S,F,Z){for(var be=v.length,Ue=Z?be:-1;(Z?Ue--:++Ue<be)&&S(v[Ue],Ue,v););return F?qa(v,Z?0:Ue,Z?Ue+1:be):qa(v,Z?Ue+1:0,Z?be:Ue)}function ad(v,S){var F=v;return F instanceof jr&&(F=F.value()),yh(S,function(Z,be){return be.func.apply(be.thisArg,Eu([Z],be.args))},F)}function yc(v,S,F){var Z=v.length;if(Z<2)return Z?pu(v[0]):[];for(var be=-1,Ue=Wt(Z);++be<Z;)for(var ot=v[be],gt=-1;++gt<Z;)gt!=be&&(Ue[be]=si(Ue[be]||ot,v[gt],S,F));return pu(no(Ue,1),S,F)}function IA(v,S,F){for(var Z=-1,be=v.length,Ue=S.length,ot={};++Z<be;){var gt=Z<Ue?S[Z]:t;F(ot,v[Z],gt)}return ot}function vc(v){return ge(v)?v:[]}function Pf(v){return typeof v=="function"?v:LA}function sd(v,S){return Q(v)?v:E(v,S)?[v]:ca(mi(v))}var Ff=Qi;function Cc(v,S,F){var Z=v.length;return F=F===t?Z:F,!S&&F>=Z?v:qa(v,S,F)}var P1=Sh||function(v){return qr.clearTimeout(v)};function qm(v,S){if(S)return v.slice();var F=v.length,Z=oc?oc(F):new v.constructor(F);return v.copy(Z),Z}function Dh(v){var S=new v.constructor(v.byteLength);return new Hc(S).set(new Hc(v)),S}function Vm(v,S){var F=S?Dh(v.buffer):v.buffer;return new v.constructor(F,v.byteOffset,v.byteLength)}function tv(v){var S=new v.constructor(v.source,Yr.exec(v));return S.lastIndex=v.lastIndex,S}function TA(v){return cc?ho(cc.call(v)):{}}function Hm(v,S){var F=S?Dh(v.buffer):v.buffer;return new v.constructor(F,v.byteOffset,v.length)}function Aa(v,S){if(v!==S){var F=v!==t,Z=v===null,be=v===v,Ue=Go(v),ot=S!==t,gt=S===null,It=S===S,yn=Go(S);if(!gt&&!yn&&!Ue&&v>S||Ue&&ot&&It&&!gt&&!yn||Z&&ot&&It||!F&&It||!be)return 1;if(!Z&&!Ue&&!yn&&v<S||yn&&F&&be&&!Z&&!Ue||gt&&F&&be||!ot&&be||!It)return-1}return 0}function Kp(v,S,F){for(var Z=-1,be=v.criteria,Ue=S.criteria,ot=be.length,gt=F.length;++Z<ot;){var It=Aa(be[Z],Ue[Z]);if(It){if(Z>=gt)return It;var yn=F[Z];return It*(yn=="desc"?-1:1)}}return v.index-S.index}function Df(v,S,F,Z){for(var be=-1,Ue=v.length,ot=F.length,gt=-1,It=S.length,yn=oa(Ue-ot,0),vn=Wt(It+yn),kn=!Z;++gt<It;)vn[gt]=S[gt];for(;++be<ot;)(kn||be<Ue)&&(vn[F[be]]=v[be]);for(;yn--;)vn[gt++]=v[be++];return vn}function Uh(v,S,F,Z){for(var be=-1,Ue=v.length,ot=-1,gt=F.length,It=-1,yn=S.length,vn=oa(Ue-gt,0),kn=Wt(vn+yn),fr=!Z;++be<vn;)kn[be]=v[be];for(var Gr=be;++It<yn;)kn[Gr+It]=S[It];for(;++ot<gt;)(fr||be<Ue)&&(kn[Gr+F[ot]]=v[be++]);return kn}function el(v,S){var F=-1,Z=v.length;for(S||(S=Wt(Z));++F<Z;)S[F]=v[F];return S}function Tl(v,S,F,Z){var be=!F;F||(F={});for(var Ue=-1,ot=S.length;++Ue<ot;){var gt=S[Ue],It=Z?Z(F[gt],v[gt],gt,F,v):t;It===t&&(It=v[gt]),be?xr(F,gt,It):en(F,gt,It)}return F}function Zm(v,S){return Tl(v,Uu(v),S)}function F1(v,S){return Tl(v,i0(v),S)}function KA(v,S){return function(F,Z){var be=Q(F)?jm:An,Ue=S?S():{};return be(F,v,Vr(Z,2),Ue)}}function Du(v){return Qi(function(S,F){var Z=-1,be=F.length,Ue=be>1?F[be-1]:t,ot=be>2?F[2]:t;for(Ue=v.length>3&&typeof Ue=="function"?(be--,Ue):t,ot&&_(F[0],F[1],ot)&&(Ue=be<3?t:Ue,be=1),S=ho(S);++Z<be;){var gt=F[Z];gt&&v(S,gt,Z,Ue)}return S})}function ld(v,S){return function(F,Z){if(F==null)return F;if(!le(F))return v(F,Z);for(var be=F.length,Ue=S?be:-1,ot=ho(F);(S?Ue--:++Ue<be)&&Z(ot[Ue],Ue,ot)!==!1;);return F}}function Xm(v){return function(S,F,Z){for(var be=-1,Ue=ho(S),ot=Z(S),gt=ot.length;gt--;){var It=ot[v?gt:++be];if(F(Ue[It],It,Ue)===!1)break}return S}}function D1(v,S,F){var Z=S&W,be=Uf(v);function Ue(){var ot=this&&this!==qr&&this instanceof Ue?be:v;return ot.apply(Z?F:this,arguments)}return Ue}function Jm(v){return function(S){S=mi(S);var F=eA(S)?ul(S):t,Z=F?F[0]:S.charAt(0),be=F?Cc(F,1).join(""):S.slice(1);return Z[v]()+be}}function PA(v){return function(S){return yh(Ak(uk(S).replace(Us,"")),v,"")}}function Uf(v){return function(){var S=arguments;switch(S.length){case 0:return new v;case 1:return new v(S[0]);case 2:return new v(S[0],S[1]);case 3:return new v(S[0],S[1],S[2]);case 4:return new v(S[0],S[1],S[2],S[3]);case 5:return new v(S[0],S[1],S[2],S[3],S[4]);case 6:return new v(S[0],S[1],S[2],S[3],S[4],S[5]);case 7:return new v(S[0],S[1],S[2],S[3],S[4],S[5],S[6])}var F=oA(v.prototype),Z=v.apply(F,S);return xn(Z)?Z:F}}function e0(v,S,F){var Z=Uf(v);function be(){for(var Ue=arguments.length,ot=Wt(Ue),gt=Ue,It=ud(be);gt--;)ot[gt]=arguments[gt];var yn=Ue<3&&ot[0]!==It&&ot[Ue-1]!==It?[]:Hs(ot,It);if(Ue-=yn.length,Ue<F)return jf(v,S,Rh,be.placeholder,t,ot,yn,t,t,F-Ue);var vn=this&&this!==qr&&this instanceof be?Z:v;return ss(vn,this,ot)}return be}function t0(v){return function(S,F,Z){var be=ho(S);if(!le(S)){var Ue=Vr(F,3);S=ml(S),F=function(gt){return Ue(be[gt],gt,be)}}var ot=v(S,F,Z);return ot>-1?be[Ue?S[ot]:ot]:t}}function Pp(v){return DA(function(S){var F=S.length,Z=F,be=uo.prototype.thru;for(v&&S.reverse();Z--;){var Ue=S[Z];if(typeof Ue!="function")throw new El(s);if(be&&!ot&&_c(Ue)=="wrapper")var ot=new uo([],!0)}for(Z=ot?Z:F;++Z<F;){Ue=S[Z];var gt=_c(Ue),It=gt=="wrapper"?Hd(Ue):t;It&&Y(It[0])&&It[1]==(ue|oe|ce|ye)&&!It[4].length&&It[9]==1?ot=ot[_c(It[0])].apply(ot,It[3]):ot=Ue.length==1&&Y(Ue)?ot[gt]():ot.thru(Ue)}return function(){var yn=arguments,vn=yn[0];if(ot&&yn.length==1&&Q(vn))return ot.plant(vn).value();for(var kn=0,fr=F?S[kn].apply(this,yn):vn;++kn<F;)fr=S[kn].call(this,fr);return fr}})}function Rh(v,S,F,Z,be,Ue,ot,gt,It,yn){var vn=S&ue,kn=S&W,fr=S&$,Gr=S&(oe|ne),ci=S&Re,ro=fr?t:Uf(v);function di(){for(var _o=arguments.length,Bo=Wt(_o),Bc=_o;Bc--;)Bo[Bc]=arguments[Bc];if(Gr)var dA=ud(di),kc=qc(Bo,dA);if(Z&&(Bo=Df(Bo,Z,be,Gr)),Ue&&(Bo=Uh(Bo,Ue,ot,Gr)),_o-=kc,Gr&&_o<yn){var tl=Hs(Bo,dA);return jf(v,S,Rh,di.placeholder,F,Bo,tl,gt,It,yn-_o)}var rh=kn?F:this,qf=fr?rh[v]:v;return _o=Bo.length,gt?Bo=er(Bo,gt):ci&&_o>1&&Bo.reverse(),vn&&It<_o&&(Bo.length=It),this&&this!==qr&&this instanceof di&&(qf=ro||Uf(qf)),qf.apply(rh,Bo)}return di}function Rf(v,S){return function(F,Z){return If(F,v,S(Z),{})}}function qd(v,S){return function(F,Z){var be;if(F===t&&Z===t)return S;if(F!==t&&(be=F),Z!==t){if(be===t)return Z;typeof F=="string"||typeof Z=="string"?(F=fu(F),Z=fu(Z)):(F=$m(F),Z=$m(Z)),be=v(F,Z)}return be}}function Lf(v){return DA(function(S){return S=Mo(S,Ls(Vr())),Qi(function(F){var Z=this;return v(S,function(be){return ss(be,Z,F)})})})}function Fp(v,S){S=S===t?" ":fu(S);var F=S.length;if(F<2)return F?Fh(S,v):S;var Z=Fh(S,Hl(v/bs(S)));return eA(S)?Cc(ul(Z),0,v).join(""):Z.slice(0,v)}function U1(v,S,F,Z){var be=S&W,Ue=Uf(v);function ot(){for(var gt=-1,It=arguments.length,yn=-1,vn=Z.length,kn=Wt(vn+It),fr=this&&this!==qr&&this instanceof ot?Ue:v;++yn<vn;)kn[yn]=Z[yn];for(;It--;)kn[yn++]=arguments[++gt];return ss(fr,be?F:this,kn)}return ot}function Vd(v){return function(S,F,Z){return Z&&typeof Z!="number"&&_(S,F,Z)&&(F=Z=t),S=Ia(S),F===t?(F=S,S=0):F=Ia(F),Z=Z===t?S<F?1:-1:Ia(Z),ev(S,F,Z,v)}}function zf(v){return function(S,F){return typeof S=="string"&&typeof F=="string"||(S=Ko(S),F=Ko(F)),v(S,F)}}function jf(v,S,F,Z,be,Ue,ot,gt,It,yn){var vn=S&oe,kn=vn?ot:t,fr=vn?t:ot,Gr=vn?Ue:t,ci=vn?t:Ue;S|=vn?ce:ae,S&=~(vn?ae:ce),S&q||(S&=~(W|$));var ro=[v,S,be,Gr,kn,ci,fr,gt,It,yn],di=F.apply(t,ro);return Y(v)&&ar(di,ro),di.placeholder=Z,Xr(di,v,S)}function FA(v){var S=ia[v];return function(F,Z){if(F=Ko(F),Z=Z==null?0:Eo(Hr(Z),292),Z&&Of(F)){var be=(mi(F)+"e").split("e"),Ue=S(be[0]+"e"+(+be[1]+Z));return be=(mi(Ue)+"e").split("e"),+(be[0]+"e"+(+be[1]-Z))}return S(F)}}var nv=Bl&&1/Ml(new Bl([,-0]))[1]==Ft?function(v){return new Bl(v)}:kw;function n0(v){return function(S){var F=Es(S);return F==wt?Pd(S):F==Sn?wh(S):tc(S,v(S))}}function qi(v,S,F,Z,be,Ue,ot,gt){var It=S&$;if(!It&&typeof v!="function")throw new El(s);var yn=Z?Z.length:0;if(yn||(S&=~(ce|ae),Z=be=t),ot=ot===t?ot:oa(Hr(ot),0),gt=gt===t?gt:Hr(gt),yn-=be?be.length:0,S&ae){var vn=Z,kn=be;Z=be=t}var fr=It?t:Hd(v),Gr=[v,S,F,Z,be,vn,kn,Ue,ot,gt];if(fr&&yt(Gr,fr),v=Gr[0],S=Gr[1],F=Gr[2],Z=Gr[3],be=Gr[4],gt=Gr[9]=Gr[9]===t?It?0:v.length:oa(Gr[9]-yn,0),!gt&&S&(oe|ne)&&(S&=~(oe|ne)),!S||S==W)var ci=D1(v,S,F);else S==oe||S==ne?ci=e0(v,S,gt):(S==ce||S==(W|ce))&&!be.length?ci=U1(v,S,F,Z):ci=Rh.apply(t,Gr);var ro=fr?T1:ar;return Xr(ro(ci,Gr),v,S)}function R1(v,S,F,Z){return v===t||T(v,Jo[F])&&!Ei.call(Z,F)?S:v}function Dp(v,S,F,Z,be,Ue){return xn(v)&&xn(S)&&(Ue.set(S,v),Zl(v,S,t,Dp,Ue),Ue.delete(S)),v}function Wf(v){return No(v)?t:v}function mu(v,S,F,Z,be,Ue){var ot=F&R,gt=v.length,It=S.length;if(gt!=It&&!(ot&&It>gt))return!1;var yn=Ue.get(v),vn=Ue.get(S);if(yn&&vn)return yn==S&&vn==v;var kn=-1,fr=!0,Gr=F&H?new te:t;for(Ue.set(v,S),Ue.set(S,v);++kn<gt;){var ci=v[kn],ro=S[kn];if(Z)var di=ot?Z(ro,ci,kn,S,v,Ue):Z(ci,ro,kn,v,S,Ue);if(di!==t){if(di)continue;fr=!1;break}if(Gr){if(!Yl(S,function(_o,Bo){if(!Ou(Gr,Bo)&&(ci===_o||be(ci,_o,F,Z,Ue)))return Gr.push(Bo)})){fr=!1;break}}else if(!(ci===ro||be(ci,ro,F,Z,Ue))){fr=!1;break}}return Ue.delete(v),Ue.delete(S),fr}function Nf(v,S,F,Z,be,Ue,ot){switch(F){case V:if(v.byteLength!=S.byteLength||v.byteOffset!=S.byteOffset)return!1;v=v.buffer,S=S.buffer;case we:return!(v.byteLength!=S.byteLength||!Ue(new Hc(v),new Hc(S)));case Se:case de:case Kt:return T(+v,+S);case Pe:return v.name==S.name&&v.message==S.message;case ir:case nr:return v==S+"";case wt:var gt=Pd;case Sn:var It=Z&R;if(gt||(gt=Ml),v.size!=S.size&&!It)return!1;var yn=ot.get(v);if(yn)return yn==S;Z|=H,ot.set(v,S);var vn=mu(gt(v),gt(S),Z,be,Ue,ot);return ot.delete(v),vn;case Mr:if(cc)return cc.call(v)==cc.call(S)}return!1}function r0(v,S,F,Z,be,Ue){var ot=F&R,gt=Up(v),It=gt.length,yn=Up(S),vn=yn.length;if(It!=vn&&!ot)return!1;for(var kn=It;kn--;){var fr=gt[kn];if(!(ot?fr in S:Ei.call(S,fr)))return!1}var Gr=Ue.get(v),ci=Ue.get(S);if(Gr&&ci)return Gr==S&&ci==v;var ro=!0;Ue.set(v,S),Ue.set(S,v);for(var di=ot;++kn<It;){fr=gt[kn];var _o=v[fr],Bo=S[fr];if(Z)var Bc=ot?Z(Bo,_o,fr,S,v,Ue):Z(_o,Bo,fr,v,S,Ue);if(!(Bc===t?_o===Bo||be(_o,Bo,F,Z,Ue):Bc)){ro=!1;break}di||(di=fr=="constructor")}if(ro&&!di){var dA=v.constructor,kc=S.constructor;dA!=kc&&"constructor"in v&&"constructor"in S&&!(typeof dA=="function"&&dA instanceof dA&&typeof kc=="function"&&kc instanceof kc)&&(ro=!1)}return Ue.delete(v),Ue.delete(S),ro}function DA(v){return Br(Bn(v,t,wc),v+"")}function Up(v){return ji(v,ml,Uu)}function Rp(v){return ji(v,ju,i0)}var Hd=iA?function(v){return iA.get(v)}:kw;function _c(v){for(var S=v.name+"",F=Oo[S],Z=Ei.call(Oo,S)?F.length:0;Z--;){var be=F[Z],Ue=be.func;if(Ue==null||Ue==v)return be.name}return S}function ud(v){var S=Ei.call(ke,"placeholder")?ke:v;return S.placeholder}function Vr(){var v=ke.iteratee||Ow;return v=v===Ow?Th:v,arguments.length?v(arguments[0],arguments[1]):v}function Gf(v,S){var F=v.__data__;return U(S)?F[typeof S=="string"?"string":"hash"]:F.map}function Co(v){for(var S=ml(v),F=S.length;F--;){var Z=S[F],be=v[Z];S[F]=[Z,be,We(be)]}return S}function Ad(v,S){var F=bh(v,S);return BA(F)?F:t}function rv(v){var S=Ei.call(v,Vl),F=v[Vl];try{v[Vl]=t;var Z=!0}catch{}var be=Al.call(v);return Z&&(S?v[Vl]=F:delete v[Vl]),be}var Uu=Xc?function(v){return v==null?[]:(v=ho(v),cu(Xc(v),function(S){return Nn.call(v,S)}))}:Iw,i0=Xc?function(v){for(var S=[];v;)Eu(S,Uu(v)),v=cl(v);return S}:Iw,Es=Oi;(Jc&&Es(new Jc(new ArrayBuffer(1)))!=V||dl&&Es(new dl)!=wt||xa&&Es(xa.resolve())!=mt||Bl&&Es(new Bl)!=Sn||As&&Es(new As)!=_r)&&(Es=function(v){var S=Oi(v),F=S==zn?v.constructor:t,Z=F?Va(F):"";if(Z)switch(Z){case zo:return V;case Ip:return wt;case du:return mt;case Tu:return Sn;case Bf:return _r}return S});function iv(v,S,F){for(var Z=-1,be=F.length;++Z<be;){var Ue=F[Z],ot=Ue.size;switch(Ue.type){case"drop":v+=ot;break;case"dropRight":S-=ot;break;case"take":S=Eo(S,v+ot);break;case"takeRight":v=oa(v,S-ot);break}}return{start:v,end:S}}function Ua(v){var S=v.match(gn);return S?S[1].split(Jn):[]}function L1(v,S,F){S=sd(S,v);for(var Z=-1,be=S.length,Ue=!1;++Z<be;){var ot=Oa(S[Z]);if(!(Ue=v!=null&&F(v,ot)))break;v=v[ot]}return Ue||++Z!=be?Ue:(be=v==null?0:v.length,!!be&&cr(be)&&b(ot,be)&&(Q(v)||z(v)))}function ov(v){var S=v.length,F=new v.constructor(S);return S&&typeof v[0]=="string"&&Ei.call(v,"index")&&(F.index=v.index,F.input=v.input),F}function z1(v){return typeof v.constructor=="function"&&!pe(v)?oA(cl(v)):{}}function Qf(v,S,F){var Z=v.constructor;switch(S){case we:return Dh(v);case Se:case de:return new Z(+v);case V:return Vm(v,F);case X:case me:case At:case bt:case Et:case sr:case Lt:case Fn:case on:return Hm(v,F);case wt:return new Z;case Kt:case nr:return new Z(v);case ir:return tv(v);case Sn:return new Z;case Mr:return TA(v)}}function A(v,S){var F=S.length;if(!F)return v;var Z=F-1;return S[Z]=(F>1?"& ":"")+S[Z],S=S.join(F>2?", ":" "),v.replace($t,`{
|
||
/* [wrapped with `+S+`] */
|
||
`)}function h(v){return Q(v)||z(v)||!!(Sf&&v&&v[Sf])}function b(v,S){var F=typeof v;return S=S??Jt,!!S&&(F=="number"||F!="symbol"&&Io.test(v))&&v>-1&&v%1==0&&v<S}function _(v,S,F){if(!xn(F))return!1;var Z=typeof S;return(Z=="number"?le(F)&&b(S,F.length):Z=="string"&&S in F)?T(F[S],v):!1}function E(v,S){if(Q(v))return!1;var F=typeof v;return F=="number"||F=="symbol"||F=="boolean"||v==null||Go(v)?!0:it.test(v)||!at.test(v)||S!=null&&v in ho(S)}function U(v){var S=typeof v;return S=="string"||S=="number"||S=="symbol"||S=="boolean"?v!=="__proto__":v===null}function Y(v){var S=_c(v),F=ke[S];if(typeof F!="function"||!(S in jr.prototype))return!1;if(v===F)return!0;var Z=Hd(F);return!!Z&&v===Z[0]}function J(v){return!!Mh&&Mh in v}var se=ls?an:Tw;function pe(v){var S=v&&v.constructor,F=typeof S=="function"&&S.prototype||Jo;return v===F}function We(v){return v===v&&!xn(v)}function Ye(v,S){return function(F){return F==null?!1:F[v]===S&&(S!==t||v in ho(F))}}function Mt(v){var S=Np(v,function(Z){return F.size===g&&F.clear(),Z}),F=S.cache;return S}function yt(v,S){var F=v[1],Z=S[1],be=F|Z,Ue=be<(W|$|ue),ot=Z==ue&&F==oe||Z==ue&&F==ye&&v[7].length<=S[8]||Z==(ue|ye)&&S[7].length<=S[8]&&F==oe;if(!(Ue||ot))return v;Z&W&&(v[2]=S[2],be|=F&W?0:q);var gt=S[3];if(gt){var It=v[3];v[3]=It?Df(It,gt,S[4]):gt,v[4]=It?Hs(v[3],x):S[4]}return gt=S[5],gt&&(It=v[5],v[5]=It?Uh(It,gt,S[6]):gt,v[6]=It?Hs(v[5],x):S[6]),gt=S[7],gt&&(v[7]=gt),Z&ue&&(v[8]=v[8]==null?S[8]:Eo(v[8],S[8])),v[9]==null&&(v[9]=S[9]),v[0]=S[0],v[1]=be,v}function qt(v){var S=[];if(v!=null)for(var F in ho(v))S.push(F);return S}function Zt(v){return Al.call(v)}function Bn(v,S,F){return S=oa(S===t?v.length-1:S,0),function(){for(var Z=arguments,be=-1,Ue=oa(Z.length-S,0),ot=Wt(Ue);++be<Ue;)ot[be]=Z[S+be];be=-1;for(var gt=Wt(S+1);++be<S;)gt[be]=Z[be];return gt[S]=F(ot),ss(v,this,gt)}}function Wn(v,S){return S.length<2?v:Zo(v,qa(S,0,-1))}function er(v,S){for(var F=v.length,Z=Eo(S.length,F),be=el(v);Z--;){var Ue=S[Z];v[Z]=b(Ue,F)?be[Ue]:t}return v}function fn(v,S){if(!(S==="constructor"&&typeof v[S]=="function")&&S!="__proto__")return v[S]}var ar=fo(T1),Ir=Eh||function(v,S){return qr.setTimeout(v,S)},Br=fo(Qm);function Xr(v,S,F){var Z=S+"";return Br(v,A(Z,Ha(Ua(Z),F)))}function fo(v){var S=0,F=0;return function(){var Z=uc(),be=Fe-(Z-F);if(F=Z,be>0){if(++S>=ct)return arguments[0]}else S=0;return v.apply(t,arguments)}}function Ea(v,S){var F=-1,Z=v.length,be=Z-1;for(S=S===t?Z:S;++F<S;){var Ue=id(F,be),ot=v[Ue];v[Ue]=v[F],v[F]=ot}return v.length=S,v}var ca=Mt(function(v){var S=[];return v.charCodeAt(0)===46&&S.push(""),v.replace(ht,function(F,Z,be,Ue){S.push(be?Ue.replace(vr,"$1"):Z||F)}),S});function Oa(v){if(typeof v=="string"||Go(v))return v;var S=v+"";return S=="0"&&1/v==-Ft?"-0":S}function Va(v){if(v!=null){try{return nA.call(v)}catch{}try{return v+""}catch{}}return""}function Ha(v,S){return $l(pt,function(F){var Z="_."+F[0];S&F[1]&&!Gc(v,Z)&&v.push(Z)}),v.sort()}function fl(v){if(v instanceof jr)return v.clone();var S=new uo(v.__wrapped__,v.__chain__);return S.__actions__=el(v.__actions__),S.__index__=v.__index__,S.__values__=v.__values__,S}function zs(v,S,F){(F?_(v,S,F):S===t)?S=1:S=oa(Hr(S),0);var Z=v==null?0:v.length;if(!Z||S<1)return[];for(var be=0,Ue=0,ot=Wt(Hl(Z/S));be<Z;)ot[Ue++]=qa(v,be,be+=S);return ot}function ds(v){for(var S=-1,F=v==null?0:v.length,Z=0,be=[];++S<F;){var Ue=v[S];Ue&&(be[Z++]=Ue)}return be}function Za(){var v=arguments.length;if(!v)return[];for(var S=Wt(v-1),F=arguments[0],Z=v;Z--;)S[Z-1]=arguments[Z];return Eu(Q(F)?el(F):[F],no(S,1))}var Ba=Qi(function(v,S){return ge(v)?si(v,no(S,1,ge,!0)):[]}),js=Qi(function(v,S){var F=lA(S);return ge(F)&&(F=t),ge(v)?si(v,no(S,1,ge,!0),Vr(F,2)):[]}),sA=Qi(function(v,S){var F=lA(S);return ge(F)&&(F=t),ge(v)?si(v,no(S,1,ge,!0),t,F):[]});function bc(v,S,F){var Z=v==null?0:v.length;return Z?(S=F||S===t?1:Hr(S),qa(v,S<0?0:S,Z)):[]}function Os(v,S,F){var Z=v==null?0:v.length;return Z?(S=F||S===t?1:Hr(S),S=Z-S,qa(v,0,S<0?0:S)):[]}function Ru(v,S){return v&&v.length?Yd(v,Vr(S,3),!0,!0):[]}function Bs(v,S){return v&&v.length?Yd(v,Vr(S,3),!0):[]}function o0(v,S,F,Z){var be=v==null?0:v.length;return be?(F&&typeof F!="number"&&_(v,S,F)&&(F=0,Z=be),aa(v,S,F,Z)):[]}function UA(v,S,F){var Z=v==null?0:v.length;if(!Z)return-1;var be=F==null?0:Hr(F);return be<0&&(be=oa(Z+be,0)),ql(v,Vr(S,3),be)}function xc(v,S,F){var Z=v==null?0:v.length;if(!Z)return-1;var be=Z-1;return F!==t&&(be=Hr(F),be=F<0?oa(Z+be,0):Eo(be,Z-1)),ql(v,Vr(S,3),be,!0)}function wc(v){var S=v==null?0:v.length;return S?no(v,1):[]}function To(v){var S=v==null?0:v.length;return S?no(v,Ft):[]}function cd(v,S){var F=v==null?0:v.length;return F?(S=S===t?1:Hr(S),no(v,S)):[]}function Lp(v){for(var S=-1,F=v==null?0:v.length,Z={};++S<F;){var be=v[S];Z[be[0]]=be[1]}return Z}function Zd(v){return v&&v.length?v[0]:t}function a0(v,S,F){var Z=v==null?0:v.length;if(!Z)return-1;var be=F==null?0:Hr(F);return be<0&&(be=oa(Z+be,0)),Ur(v,S,be)}function s0(v){var S=v==null?0:v.length;return S?qa(v,0,-1):[]}var zp=Qi(function(v){var S=Mo(v,vc);return S.length&&S[0]===v[0]?sa(S):[]}),j1=Qi(function(v){var S=lA(v),F=Mo(v,vc);return S===lA(F)?S=t:F.pop(),F.length&&F[0]===v[0]?sa(F,Vr(S,2)):[]}),W1=Qi(function(v){var S=lA(v),F=Mo(v,vc);return S=typeof S=="function"?S:t,S&&F.pop(),F.length&&F[0]===v[0]?sa(F,t,S):[]});function J5(v,S){return v==null?"":Oh.call(v,S)}function lA(v){var S=v==null?0:v.length;return S?v[S-1]:t}function Mb(v,S,F){var Z=v==null?0:v.length;if(!Z)return-1;var be=Z;return F!==t&&(be=Hr(F),be=be<0?oa(Z+be,0):Eo(be,Z-1)),S===S?Bu(v,S,be):ql(v,wf,be,!0)}function ew(v,S){return v&&v.length?Qd(v,Hr(S)):t}var Sb=Qi(av);function av(v,S){return v&&v.length&&S&&S.length?Kf(v,S):v}function sv(v,S,F){return v&&v.length&&S&&S.length?Kf(v,S,Vr(F,2)):v}function lv(v,S,F){return v&&v.length&&S&&S.length?Kf(v,S,t,F):v}var tw=DA(function(v,S){var F=v==null?0:v.length,Z=Tn(v,S);return Js(v,Mo(S,function(be){return b(be,F)?+be:be}).sort(Aa)),Z});function nw(v,S){var F=[];if(!(v&&v.length))return F;var Z=-1,be=[],Ue=v.length;for(S=Vr(S,3);++Z<Ue;){var ot=v[Z];S(ot,Z,v)&&(F.push(ot),be.push(Z))}return Js(v,be),F}function N1(v){return v==null?v:SA.call(v)}function l0(v,S,F){var Z=v==null?0:v.length;return Z?(F&&typeof F!="number"&&_(v,S,F)?(S=0,F=Z):(S=S==null?0:Hr(S),F=F===t?Z:Hr(F)),qa(v,S,F)):[]}function dd(v,S){return Ss(v,S)}function Lh(v,S,F){return od(v,S,Vr(F,2))}function Eb(v,S){var F=v==null?0:v.length;if(F){var Z=Ss(v,S);if(Z<F&&T(v[Z],S))return Z}return-1}function uv(v,S){return Ss(v,S,!0)}function rw(v,S,F){return od(v,S,Vr(F,2),!0)}function iw(v,S){var F=v==null?0:v.length;if(F){var Z=Ss(v,S,!0)-1;if(T(v[Z],S))return Z}return-1}function G1(v){return v&&v.length?kA(v):[]}function Av(v,S){return v&&v.length?kA(v,Vr(S,2)):[]}function ow(v){var S=v==null?0:v.length;return S?qa(v,1,S):[]}function cv(v,S,F){return v&&v.length?(S=F||S===t?1:Hr(S),qa(v,0,S<0?0:S)):[]}function dv(v,S,F){var Z=v==null?0:v.length;return Z?(S=F||S===t?1:Hr(S),S=Z-S,qa(v,S<0?0:S,Z)):[]}function jp(v,S){return v&&v.length?Yd(v,Vr(S,3),!1,!0):[]}function Ob(v,S){return v&&v.length?Yd(v,Vr(S,3)):[]}var Bb=Qi(function(v){return pu(no(v,1,ge,!0))}),hv=Qi(function(v){var S=lA(v);return ge(S)&&(S=t),pu(no(v,1,ge,!0),Vr(S,2))}),kb=Qi(function(v){var S=lA(v);return S=typeof S=="function"?S:t,pu(no(v,1,ge,!0),t,S)});function Q1(v){return v&&v.length?pu(v):[]}function Ib(v,S){return v&&v.length?pu(v,Vr(S,2)):[]}function aw(v,S){return S=typeof S=="function"?S:t,v&&v.length?pu(v,t,S):[]}function fv(v){if(!(v&&v.length))return[];var S=0;return v=cu(v,function(F){if(ge(F))return S=oa(F.length,S),!0}),So(S,function(F){return Mo(v,Ro(F))})}function pv(v,S){if(!(v&&v.length))return[];var F=fv(v);return S==null?F:Mo(F,function(Z){return ss(S,t,Z)})}var sw=Qi(function(v,S){return ge(v)?si(v,S):[]}),lw=Qi(function(v){return yc(cu(v,ge))}),uw=Qi(function(v){var S=lA(v);return ge(S)&&(S=t),yc(cu(v,ge),Vr(S,2))}),Aw=Qi(function(v){var S=lA(v);return S=typeof S=="function"?S:t,yc(cu(v,ge),t,S)}),mv=Qi(fv);function zh(v,S){return IA(v||[],S||[],en)}function Tb(v,S){return IA(v||[],S||[],$d)}var Kb=Qi(function(v){var S=v.length,F=S>1?v[S-1]:t;return F=typeof F=="function"?(v.pop(),F):t,pv(v,F)});function gv(v){var S=ke(v);return S.__chain__=!0,S}function Pb(v,S){return S(v),v}function u0(v,S){return S(v)}var yv=DA(function(v){var S=v.length,F=S?v[0]:0,Z=this.__wrapped__,be=function(Ue){return Tn(Ue,v)};return S>1||this.__actions__.length||!(Z instanceof jr)||!b(F)?this.thru(be):(Z=Z.slice(F,+F+(S?1:0)),Z.__actions__.push({func:u0,args:[be],thisArg:t}),new uo(Z,this.__chain__).thru(function(Ue){return S&&!Ue.length&&Ue.push(t),Ue}))});function $1(){return gv(this)}function Fb(){return new uo(this.value(),this.__chain__)}function vv(){this.__values__===t&&(this.__values__=Fl(this.value()));var v=this.__index__>=this.__values__.length,S=v?t:this.__values__[this.__index__++];return{done:v,value:S}}function Db(){return this}function uA(v){for(var S,F=this;F instanceof wa;){var Z=fl(F);Z.__index__=0,Z.__values__=t,S?be.__wrapped__=Z:S=Z;var be=Z;F=F.__wrapped__}return be.__wrapped__=v,S}function A0(){var v=this.__wrapped__;if(v instanceof jr){var S=v;return this.__actions__.length&&(S=new jr(this)),S=S.reverse(),S.__actions__.push({func:u0,args:[N1],thisArg:t}),new uo(S,this.__chain__)}return this.thru(N1)}function Ub(){return ad(this.__wrapped__,this.__actions__)}var Rb=KA(function(v,S,F){Ei.call(v,F)?++v[F]:xr(v,F,1)});function Lb(v,S,F){var Z=Q(v)?Id:Zs;return F&&_(v,S,F)&&(S=t),Z(v,Vr(S,3))}function zb(v,S){var F=Q(v)?cu:_a;return F(v,Vr(S,3))}var jb=t0(UA),Wb=t0(xc);function cw(v,S){return no(c0(v,S),1)}function Nb(v,S){return no(c0(v,S),Ft)}function jh(v,S,F){return F=F===t?1:Hr(F),no(c0(v,S),F)}function Cv(v,S){var F=Q(v)?$l:yo;return F(v,Vr(S,3))}function _v(v,S){var F=Q(v)?Bp:vo;return F(v,Vr(S,3))}var Gb=KA(function(v,S,F){Ei.call(v,F)?v[F].push(S):xr(v,F,[S])});function Qb(v,S,F,Z){v=le(v)?v:ng(v),F=F&&!Z?Hr(F):0;var be=v.length;return F<0&&(F=oa(be+F,0)),ka(v)?F<=be&&v.indexOf(S,F)>-1:!!be&&Ur(v,S,F)>-1}var dw=Qi(function(v,S,F){var Z=-1,be=typeof S=="function",Ue=le(v)?Wt(v.length):[];return yo(v,function(ot){Ue[++Z]=be?ss(S,ot,F):Wo(ot,S,F)}),Ue}),hw=KA(function(v,S,F){xr(v,F,S)});function c0(v,S){var F=Q(v)?Mo:rd;return F(v,Vr(S,3))}function Wp(v,S,F,Z){return v==null?[]:(Q(S)||(S=S==null?[]:[S]),F=Z?t:F,Q(F)||(F=F==null?[]:[F]),Wm(v,S,F))}var $b=KA(function(v,S,F){v[F?0:1].push(S)},function(){return[[],[]]});function Y1(v,S,F){var Z=Q(v)?yh:zi,be=arguments.length<3;return Z(v,Vr(S,4),F,be,yo)}function Yb(v,S,F){var Z=Q(v)?vh:zi,be=arguments.length<3;return Z(v,Vr(S,4),F,be,vo)}function q1(v,S){var F=Q(v)?cu:_a;return F(v,Gp(Vr(S,3)))}function V1(v){var S=Q(v)?qe:Nm;return S(v)}function H1(v,S,F){(F?_(v,S,F):S===t)?S=1:S=Hr(S);var Z=Q(v)?_t:Gm;return Z(v,S)}function fw(v){var S=Q(v)?Ut:K1;return S(v)}function pw(v){if(v==null)return 0;if(le(v))return ka(v)?bs(v):v.length;var S=Es(v);return S==wt||S==Sn?v.size:pc(v).length}function mw(v,S,F){var Z=Q(v)?Yl:gc;return F&&_(v,S,F)&&(S=t),Z(v,Vr(S,3))}var gw=Qi(function(v,S){if(v==null)return[];var F=S.length;return F>1&&_(v,S[0],S[1])?S=[]:F>2&&_(S[0],S[1],S[2])&&(S=[S[0]]),Wm(v,no(S,1),[])}),Xd=Zc||function(){return qr.Date.now()};function pl(v,S){if(typeof S!="function")throw new El(s);return v=Hr(v),function(){if(--v<1)return S.apply(this,arguments)}}function Jd(v,S,F){return S=F?t:S,S=v&&S==null?v.length:S,qi(v,ue,t,t,t,t,S)}function Z1(v,S){var F;if(typeof S!="function")throw new El(s);return v=Hr(v),function(){return--v>0&&(F=S.apply(this,arguments)),v<=1&&(S=t),F}}var X1=Qi(function(v,S,F){var Z=W;if(F.length){var be=Hs(F,ud(X1));Z|=ce}return qi(v,Z,S,F,be)}),bv=Qi(function(v,S,F){var Z=W|$;if(F.length){var be=Hs(F,ud(bv));Z|=ce}return qi(S,Z,v,F,be)});function J1(v,S,F){S=F?t:S;var Z=qi(v,oe,t,t,t,t,t,S);return Z.placeholder=J1.placeholder,Z}function qb(v,S,F){S=F?t:S;var Z=qi(v,ne,t,t,t,t,t,S);return Z.placeholder=qb.placeholder,Z}function xv(v,S,F){var Z,be,Ue,ot,gt,It,yn=0,vn=!1,kn=!1,fr=!0;if(typeof v!="function")throw new El(s);S=Ko(S)||0,xn(F)&&(vn=!!F.leading,kn="maxWait"in F,Ue=kn?oa(Ko(F.maxWait)||0,S):Ue,fr="trailing"in F?!!F.trailing:fr);function Gr(tl){var rh=Z,qf=be;return Z=be=t,yn=tl,ot=v.apply(qf,rh),ot}function ci(tl){return yn=tl,gt=Ir(_o,S),vn?Gr(tl):ot}function ro(tl){var rh=tl-It,qf=tl-yn,hk=S-rh;return kn?Eo(hk,Ue-qf):hk}function di(tl){var rh=tl-It,qf=tl-yn;return It===t||rh>=S||rh<0||kn&&qf>=Ue}function _o(){var tl=Xd();if(di(tl))return Bo(tl);gt=Ir(_o,ro(tl))}function Bo(tl){return gt=t,fr&&Z?Gr(tl):(Z=be=t,ot)}function Bc(){gt!==t&&P1(gt),yn=0,Z=It=be=gt=t}function dA(){return gt===t?ot:Bo(Xd())}function kc(){var tl=Xd(),rh=di(tl);if(Z=arguments,be=this,It=tl,rh){if(gt===t)return ci(It);if(kn)return P1(gt),gt=Ir(_o,S),Gr(It)}return gt===t&&(gt=Ir(_o,S)),ot}return kc.cancel=Bc,kc.flush=dA,kc}var Vb=Qi(function(v,S){return ii(v,1,S)}),yw=Qi(function(v,S,F){return ii(v,Ko(S)||0,F)});function Hb(v){return qi(v,Re)}function Np(v,S){if(typeof v!="function"||S!=null&&typeof S!="function")throw new El(s);var F=function(){var Z=arguments,be=S?S.apply(this,Z):Z[0],Ue=F.cache;if(Ue.has(be))return Ue.get(be);var ot=v.apply(this,Z);return F.cache=Ue.set(be,ot)||Ue,ot};return F.cache=new(Np.Cache||C),F}Np.Cache=C;function Gp(v){if(typeof v!="function")throw new El(s);return function(){var S=arguments;switch(S.length){case 0:return!v.call(this);case 1:return!v.call(this,S[0]);case 2:return!v.call(this,S[0],S[1]);case 3:return!v.call(this,S[0],S[1],S[2])}return!v.apply(this,S)}}function Zb(v){return Z1(2,v)}var d0=Ff(function(v,S){S=S.length==1&&Q(S[0])?Mo(S[0],Ls(Vr())):Mo(no(S,1),Ls(Vr()));var F=S.length;return Qi(function(Z){for(var be=-1,Ue=Eo(Z.length,F);++be<Ue;)Z[be]=S[be].call(this,Z[be]);return ss(v,this,Z)})}),h0=Qi(function(v,S){var F=Hs(S,ud(h0));return qi(v,ce,t,S,F)}),wv=Qi(function(v,S){var F=Hs(S,ud(wv));return qi(v,ae,t,S,F)}),Mv=DA(function(v,S){return qi(v,ye,t,t,t,S)});function eg(v,S){if(typeof v!="function")throw new El(s);return S=S===t?S:Hr(S),Qi(v,S)}function f0(v,S){if(typeof v!="function")throw new El(s);return S=S==null?0:oa(Hr(S),0),Qi(function(F){var Z=F[S],be=Cc(F,0,S);return Z&&Eu(be,Z),ss(v,this,be)})}function Sv(v,S,F){var Z=!0,be=!0;if(typeof v!="function")throw new El(s);return xn(F)&&(Z="leading"in F?!!F.leading:Z,be="trailing"in F?!!F.trailing:be),xv(v,S,{leading:Z,maxWait:S,trailing:be})}function Ev(v){return Jd(v,1)}function Ov(v,S){return h0(Pf(S),v)}function vw(){if(!arguments.length)return[];var v=arguments[0];return Q(v)?v:[v]}function c(v){return Qn(v,P)}function l(v,S){return S=typeof S=="function"?S:t,Qn(v,P,S)}function d(v){return Qn(v,k|P)}function y(v,S){return S=typeof S=="function"?S:t,Qn(v,k|P,S)}function w(v,S){return S==null||pi(v,S,ml(S))}function T(v,S){return v===S||v!==v&&S!==S}var K=zf(cs),D=zf(function(v,S){return v>=S}),z=jd(function(){return arguments}())?jd:function(v){return Cn(v)&&Ei.call(v,"callee")&&!Nn.call(v,"callee")},Q=Wt.isArray,ie=Xo?Ls(Xo):fc;function le(v){return v!=null&&cr(v.length)&&!an(v)}function ge(v){return Cn(v)&&le(v)}function Oe(v){return v===!0||v===!1||Cn(v)&&Oi(v)==Se}var Be=Ef||Tw,ze=Pa?Ls(Pa):EA;function $e(v){return Cn(v)&&v.nodeType===1&&!No(v)}function tt(v){if(v==null)return!0;if(le(v)&&(Q(v)||typeof v=="string"||typeof v.splice=="function"||Be(v)||Ja(v)||z(v)))return!v.length;var S=Es(v);if(S==wt||S==Sn)return!v.size;if(pe(v))return!pc(v).length;for(var F in v)if(Ei.call(v,F))return!1;return!0}function St(v,S){return hl(v,S)}function lt(v,S,F){F=typeof F=="function"?F:t;var Z=F?F(v,S):t;return Z===t?hl(v,S,t,F):!!Z}function vt(v){if(!Cn(v))return!1;var S=Oi(v);return S==Pe||S==xe||typeof v.message=="string"&&typeof v.name=="string"&&!No(v)}function tn(v){return typeof v=="number"&&Of(v)}function an(v){if(!xn(v))return!1;var S=Oi(v);return S==Ze||S==Xe||S==Dt||S==pn}function Vn(v){return typeof v=="number"&&v==Hr(v)}function cr(v){return typeof v=="number"&&v>-1&&v%1==0&&v<=Jt}function xn(v){var S=typeof v;return v!=null&&(S=="object"||S=="function")}function Cn(v){return v!=null&&typeof v=="object"}var Kn=Rs?Ls(Rs):OA;function ur(v,S){return v===S||Wd(v,S,Co(S))}function Dn(v,S,F){return F=typeof F=="function"?F:t,Wd(v,S,Co(S),F)}function wn(v){return ea(v)&&v!=+v}function Kr(v){if(se(v))throw new ri(o);return BA(v)}function wr(v){return v===null}function Bi(v){return v==null}function ea(v){return typeof v=="number"||Cn(v)&&Oi(v)==Kt}function No(v){if(!Cn(v)||Oi(v)!=zn)return!1;var S=cl(v);if(S===null)return!0;var F=Ei.call(S,"constructor")&&S.constructor;return typeof F=="function"&&F instanceof F&&nA.call(F)==ic}var Xa=_s?Ls(_s):Nd;function Lu(v){return Vn(v)&&v>=-Jt&&v<=Jt}var Kl=Su?Ls(Su):Tf;function ka(v){return typeof v=="string"||!Q(v)&&Cn(v)&&Oi(v)==nr}function Go(v){return typeof v=="symbol"||Cn(v)&&Oi(v)==Mr}var Ja=XA?Ls(XA):td;function Xl(v){return v===t}function Jl(v){return Cn(v)&&Es(v)==_r}function ks(v){return Cn(v)&&Oi(v)==vi}var Is=zf(nd),Pl=zf(function(v,S){return v<=S});function Fl(v){if(!v)return[];if(le(v))return ka(v)?ul(v):el(v);if(sc&&v[sc])return kp(v[sc]());var S=Es(v),F=S==wt?Pd:S==Sn?Ml:ng;return F(v)}function Ia(v){if(!v)return v===0?v:0;if(v=Ko(v),v===Ft||v===-Ft){var S=v<0?-1:1;return S*Nt}return v===v?v:0}function Hr(v){var S=Ia(v),F=S%1;return S===S?F?S-F:S:0}function eu(v){return v?yr(Hr(v),0,nt):0}function Ko(v){if(typeof v=="number")return v;if(Go(v))return Ve;if(xn(v)){var S=typeof v.valueOf=="function"?v.valueOf():v;v=xn(S)?S+"":S}if(typeof v!="string")return v===0?v:+v;v=nc(v);var F=Cr.test(v);return F||Ii.test(v)?_n(v.slice(2),F?2:8):Zr.test(v)?Ve:+v}function Wi(v){return Tl(v,ju(v))}function Dl(v){return v?yr(Hr(v),-Jt,Jt):v===0?v:0}function mi(v){return v==null?"":fu(v)}var Ts=Du(function(v,S){if(pe(S)||le(S)){Tl(S,ml(S),v);return}for(var F in S)Ei.call(S,F)&&en(v,F,S[F])}),AA=Du(function(v,S){Tl(S,ju(S),v)}),zu=Du(function(v,S,F,Z){Tl(S,ju(S),v,Z)}),Mc=Du(function(v,S,F,Z){Tl(S,ml(S),v,Z)}),eh=DA(Tn);function RA(v,S){var F=oA(v);return S==null?F:On(F,S)}var cA=Qi(function(v,S){v=ho(v);var F=-1,Z=S.length,be=Z>2?S[2]:t;for(be&&_(S[0],S[1],be)&&(Z=1);++F<Z;)for(var Ue=S[F],ot=ju(Ue),gt=-1,It=ot.length;++gt<It;){var yn=ot[gt],vn=v[yn];(vn===t||T(vn,Jo[yn])&&!Ei.call(v,yn))&&(v[yn]=Ue[yn])}return v}),gu=Qi(function(v){return v.push(t,Dp),ss(nx,t,v)});function th(v,S){return xf(v,Vr(S,3),Ms)}function p0(v,S){return xf(v,Vr(S,3),aA)}function Xb(v,S){return v==null?v:ws(v,Vr(S,3),ju)}function Bv(v,S){return v==null?v:Pu(v,Vr(S,3),ju)}function kv(v,S){return v&&Ms(v,Vr(S,3))}function nh(v,S){return v&&aA(v,Vr(S,3))}function Jb(v){return v==null?[]:hu(v,ml(v))}function ex(v){return v==null?[]:hu(v,ju(v))}function Iv(v,S,F){var Z=v==null?t:Zo(v,S);return Z===t?F:Z}function Cw(v,S){return v!=null&&L1(v,S,jo)}function Tv(v,S){return v!=null&&L1(v,S,Da)}var _w=Rf(function(v,S,F){S!=null&&typeof S.toString!="function"&&(S=Al.call(S)),v[S]=F},Ew(LA)),bw=Rf(function(v,S,F){S!=null&&typeof S.toString!="function"&&(S=Al.call(S)),Ei.call(v,S)?v[S].push(F):v[S]=[F]},Vr),xw=Qi(Wo);function ml(v){return le(v)?Bt(v):pc(v)}function ju(v){return le(v)?Bt(v,!0):Kh(v)}function Sc(v,S){var F={};return S=Vr(S,3),Ms(v,function(Z,be,Ue){xr(F,S(Z,be,Ue),Z)}),F}function tg(v,S){var F={};return S=Vr(S,3),Ms(v,function(Z,be,Ue){xr(F,be,S(Z,be,Ue))}),F}var tx=Du(function(v,S,F){Zl(v,S,F)}),nx=Du(function(v,S,F,Z){Zl(v,S,F,Z)}),ww=DA(function(v,S){var F={};if(v==null)return F;var Z=!1;S=Mo(S,function(Ue){return Ue=sd(Ue,v),Z||(Z=Ue.length>1),Ue}),Tl(v,Rp(v),F),Z&&(F=Qn(F,k|B|P,Wf));for(var be=S.length;be--;)Tp(F,S[be]);return F});function Mw(v,S){return Wu(v,Gp(Vr(S)))}var Ul=DA(function(v,S){return v==null?{}:I1(v,S)});function Wu(v,S){if(v==null)return{};var F=Mo(Rp(v),function(Z){return[Z]});return S=Vr(S),Xs(v,F,function(Z,be){return S(Z,be[0])})}function $f(v,S,F){S=sd(S,v);var Z=-1,be=S.length;for(be||(be=1,v=t);++Z<be;){var Ue=v==null?t:v[Oa(S[Z])];Ue===t&&(Z=be,Ue=F),v=an(Ue)?Ue.call(v):Ue}return v}function Ec(v,S,F){return v==null?v:$d(v,S,F)}function Yf(v,S,F,Z){return Z=typeof Z=="function"?Z:t,v==null?v:$d(v,S,F,Z)}var Oc=n0(ml),sk=n0(ju);function LG(v,S,F){var Z=Q(v),be=Z||Be(v)||Ja(v);if(S=Vr(S,4),F==null){var Ue=v&&v.constructor;be?F=Z?new Ue:[]:xn(v)?F=an(Ue)?oA(cl(v)):{}:F={}}return(be?$l:Ms)(v,function(ot,gt,It){return S(F,ot,gt,It)}),F}function zG(v,S){return v==null?!0:Tp(v,S)}function jG(v,S,F){return v==null?v:Ym(v,S,Pf(F))}function WG(v,S,F,Z){return Z=typeof Z=="function"?Z:t,v==null?v:Ym(v,S,Pf(F),Z)}function ng(v){return v==null?[]:Kd(v,ml(v))}function NG(v){return v==null?[]:Kd(v,ju(v))}function GG(v,S,F){return F===t&&(F=S,S=t),F!==t&&(F=Ko(F),F=F===F?F:0),S!==t&&(S=Ko(S),S=S===S?S:0),yr(Ko(v),S,F)}function QG(v,S,F){return S=Ia(S),F===t?(F=S,S=0):F=Ia(F),v=Ko(v),ua(v,S,F)}function $G(v,S,F){if(F&&typeof F!="boolean"&&_(v,S,F)&&(S=F=t),F===t&&(typeof S=="boolean"?(F=S,S=t):typeof v=="boolean"&&(F=v,v=t)),v===t&&S===t?(v=0,S=1):(v=Ia(v),S===t?(S=v,v=0):S=Ia(S)),v>S){var Z=v;v=S,S=Z}if(F||v%1||S%1){var be=Or();return Eo(v+be*(S-v+Sr("1e-"+((be+"").length-1))),S)}return id(v,S)}var YG=PA(function(v,S,F){return S=S.toLowerCase(),v+(F?lk(S):S)});function lk(v){return Sw(mi(v).toLowerCase())}function uk(v){return v=mi(v),v&&v.replace(Ci,Mf).replace(Cs,"")}function qG(v,S,F){v=mi(v),S=fu(S);var Z=v.length;F=F===t?Z:yr(Hr(F),0,Z);var be=F;return F-=S.length,F>=0&&v.slice(F,be)==S}function VG(v){return v=mi(v),v&&fe.test(v)?v.replace(Zn,wl):v}function HG(v){return v=mi(v),v&&Ct.test(v)?v.replace(et,"\\$&"):v}var ZG=PA(function(v,S,F){return v+(F?"-":"")+S.toLowerCase()}),XG=PA(function(v,S,F){return v+(F?" ":"")+S.toLowerCase()}),JG=Jm("toLowerCase");function eQ(v,S,F){v=mi(v),S=Hr(S);var Z=S?bs(v):0;if(!S||Z>=S)return v;var be=(S-Z)/2;return Fp(go(be),F)+v+Fp(Hl(be),F)}function tQ(v,S,F){v=mi(v),S=Hr(S);var Z=S?bs(v):0;return S&&Z<S?v+Fp(S-Z,F):v}function nQ(v,S,F){v=mi(v),S=Hr(S);var Z=S?bs(v):0;return S&&Z<S?Fp(S-Z,F)+v:v}function rQ(v,S,F){return F||S==null?S=0:S&&(S=+S),gr(mi(v).replace(rn,""),S||0)}function iQ(v,S,F){return(F?_(v,S,F):S===t)?S=1:S=Hr(S),Fh(mi(v),S)}function oQ(){var v=arguments,S=mi(v[0]);return v.length<3?S:S.replace(v[1],v[2])}var aQ=PA(function(v,S,F){return v+(F?"_":"")+S.toLowerCase()});function sQ(v,S,F){return F&&typeof F!="number"&&_(v,S,F)&&(S=F=t),F=F===t?nt:F>>>0,F?(v=mi(v),v&&(typeof S=="string"||S!=null&&!Xa(S))&&(S=fu(S),!S&&eA(v))?Cc(ul(v),0,F):v.split(S,F)):[]}var lQ=PA(function(v,S,F){return v+(F?" ":"")+Sw(S)});function uQ(v,S,F){return v=mi(v),F=F==null?0:yr(Hr(F),0,v.length),S=fu(S),v.slice(F,F+S.length)==S}function AQ(v,S,F){var Z=ke.templateSettings;F&&_(v,S,F)&&(S=t),v=mi(v),S=zu({},S,Z,R1);var be=zu({},S.imports,Z.imports,R1),Ue=ml(be),ot=Kd(be,Ue),gt,It,yn=0,vn=S.interpolate||so,kn="__p += '",fr=xs((S.escape||so).source+"|"+vn.source+"|"+(vn===Te?Dr:so).source+"|"+(S.evaluate||so).source+"|$","g"),Gr="//# sourceURL="+(Ei.call(S,"sourceURL")?(S.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Au+"]")+`
|
||
`;v.replace(fr,function(di,_o,Bo,Bc,dA,kc){return Bo||(Bo=Bc),kn+=v.slice(yn,kc).replace(Yo,Ju),_o&&(gt=!0,kn+=`' +
|
||
__e(`+_o+`) +
|
||
'`),dA&&(It=!0,kn+=`';
|
||
`+dA+`;
|
||
__p += '`),Bo&&(kn+=`' +
|
||
((__t = (`+Bo+`)) == null ? '' : __t) +
|
||
'`),yn=kc+di.length,di}),kn+=`';
|
||
`;var ci=Ei.call(S,"variable")&&S.variable;if(!ci)kn=`with (obj) {
|
||
`+kn+`
|
||
}
|
||
`;else if(Tr.test(ci))throw new ri(a);kn=(It?kn.replace(m,""):kn).replace(un,"$1").replace(In,"$1;"),kn="function("+(ci||"obj")+`) {
|
||
`+(ci?"":`obj || (obj = {});
|
||
`)+"var __t, __p = ''"+(gt?", __e = _.escape":"")+(It?`, __j = Array.prototype.join;
|
||
function print() { __p += __j.call(arguments, '') }
|
||
`:`;
|
||
`)+kn+`return __p
|
||
}`;var ro=ck(function(){return to(Ue,Gr+"return "+kn).apply(t,ot)});if(ro.source=kn,vt(ro))throw ro;return ro}function cQ(v){return mi(v).toLowerCase()}function dQ(v){return mi(v).toUpperCase()}function hQ(v,S,F){if(v=mi(v),v&&(F||S===t))return nc(v);if(!v||!(S=fu(S)))return v;var Z=ul(v),be=ul(S),Ue=xl(Z,be),ot=Xu(Z,be)+1;return Cc(Z,Ue,ot).join("")}function fQ(v,S,F){if(v=mi(v),v&&(F||S===t))return v.slice(0,Fd(v)+1);if(!v||!(S=fu(S)))return v;var Z=ul(v),be=Xu(Z,ul(S))+1;return Cc(Z,0,be).join("")}function pQ(v,S,F){if(v=mi(v),v&&(F||S===t))return v.replace(rn,"");if(!v||!(S=fu(S)))return v;var Z=ul(v),be=xl(Z,ul(S));return Cc(Z,be).join("")}function mQ(v,S){var F=Ne,Z=rt;if(xn(S)){var be="separator"in S?S.separator:be;F="length"in S?Hr(S.length):F,Z="omission"in S?fu(S.omission):Z}v=mi(v);var Ue=v.length;if(eA(v)){var ot=ul(v);Ue=ot.length}if(F>=Ue)return v;var gt=F-bs(Z);if(gt<1)return Z;var It=ot?Cc(ot,0,gt).join(""):v.slice(0,gt);if(be===t)return It+Z;if(ot&&(gt+=It.length-gt),Xa(be)){if(v.slice(gt).search(be)){var yn,vn=It;for(be.global||(be=xs(be.source,mi(Yr.exec(be))+"g")),be.lastIndex=0;yn=be.exec(vn);)var kn=yn.index;It=It.slice(0,kn===t?gt:kn)}}else if(v.indexOf(fu(be),gt)!=gt){var fr=It.lastIndexOf(be);fr>-1&&(It=It.slice(0,fr))}return It+Z}function gQ(v){return v=mi(v),v&&Ke.test(v)?v.replace(Gn,Dd):v}var yQ=PA(function(v,S,F){return v+(F?" ":"")+S.toUpperCase()}),Sw=Jm("toUpperCase");function Ak(v,S,F){return v=mi(v),S=F?t:S,S===t?xh(v)?Vc(v):$c(v):v.match(S)||[]}var ck=Qi(function(v,S){try{return ss(v,t,S)}catch(F){return vt(F)?F:new ri(F)}}),vQ=DA(function(v,S){return $l(S,function(F){F=Oa(F),xr(v,F,X1(v[F],v))}),v});function CQ(v){var S=v==null?0:v.length,F=Vr();return v=S?Mo(v,function(Z){if(typeof Z[1]!="function")throw new El(s);return[F(Z[0]),Z[1]]}):[],Qi(function(Z){for(var be=-1;++be<S;){var Ue=v[be];if(ss(Ue[0],this,Z))return ss(Ue[1],this,Z)}})}function _Q(v){return Ho(Qn(v,k))}function Ew(v){return function(){return v}}function bQ(v,S){return v==null||v!==v?S:v}var xQ=Pp(),wQ=Pp(!0);function LA(v){return v}function Ow(v){return Th(typeof v=="function"?v:Qn(v,k))}function MQ(v){return k1(Qn(v,k))}function SQ(v,S){return Gd(v,Qn(S,k))}var EQ=Qi(function(v,S){return function(F){return Wo(F,v,S)}}),OQ=Qi(function(v,S){return function(F){return Wo(v,F,S)}});function Bw(v,S,F){var Z=ml(S),be=hu(S,Z);F==null&&!(xn(S)&&(be.length||!Z.length))&&(F=S,S=v,v=this,be=hu(S,ml(S)));var Ue=!(xn(F)&&"chain"in F)||!!F.chain,ot=an(v);return $l(be,function(gt){var It=S[gt];v[gt]=It,ot&&(v.prototype[gt]=function(){var yn=this.__chain__;if(Ue||yn){var vn=v(this.__wrapped__),kn=vn.__actions__=el(this.__actions__);return kn.push({func:It,args:arguments,thisArg:v}),vn.__chain__=yn,vn}return It.apply(v,Eu([this.value()],arguments))})}),v}function BQ(){return qr._===this&&(qr._=us),this}function kw(){}function kQ(v){return v=Hr(v),Qi(function(S){return Qd(S,v)})}var IQ=Lf(Mo),TQ=Lf(Id),KQ=Lf(Yl);function dk(v){return E(v)?Ro(Oa(v)):Ph(v)}function PQ(v){return function(S){return v==null?t:Zo(v,S)}}var FQ=Vd(),DQ=Vd(!0);function Iw(){return[]}function Tw(){return!1}function UQ(){return{}}function RQ(){return""}function LQ(){return!0}function zQ(v,S){if(v=Hr(v),v<1||v>Jt)return[];var F=nt,Z=Eo(v,nt);S=Vr(S),v-=nt;for(var be=So(Z,S);++F<v;)S(F);return be}function jQ(v){return Q(v)?Mo(v,Oa):Go(v)?[v]:el(ca(mi(v)))}function WQ(v){var S=++MA;return mi(v)+S}var NQ=qd(function(v,S){return v+S},0),GQ=FA("ceil"),QQ=qd(function(v,S){return v/S},1),$Q=FA("floor");function YQ(v){return v&&v.length?Sa(v,LA,cs):t}function qQ(v,S){return v&&v.length?Sa(v,Vr(S,2),cs):t}function VQ(v){return ec(v,LA)}function HQ(v,S){return ec(v,Vr(S,2))}function ZQ(v){return v&&v.length?Sa(v,LA,nd):t}function XQ(v,S){return v&&v.length?Sa(v,Vr(S,2),nd):t}var JQ=qd(function(v,S){return v*S},1),e$=FA("round"),t$=qd(function(v,S){return v-S},0);function n$(v){return v&&v.length?Lo(v,LA):0}function r$(v,S){return v&&v.length?Lo(v,Vr(S,2)):0}return ke.after=pl,ke.ary=Jd,ke.assign=Ts,ke.assignIn=AA,ke.assignInWith=zu,ke.assignWith=Mc,ke.at=eh,ke.before=Z1,ke.bind=X1,ke.bindAll=vQ,ke.bindKey=bv,ke.castArray=vw,ke.chain=gv,ke.chunk=zs,ke.compact=ds,ke.concat=Za,ke.cond=CQ,ke.conforms=_Q,ke.constant=Ew,ke.countBy=Rb,ke.create=RA,ke.curry=J1,ke.curryRight=qb,ke.debounce=xv,ke.defaults=cA,ke.defaultsDeep=gu,ke.defer=Vb,ke.delay=yw,ke.difference=Ba,ke.differenceBy=js,ke.differenceWith=sA,ke.drop=bc,ke.dropRight=Os,ke.dropRightWhile=Ru,ke.dropWhile=Bs,ke.fill=o0,ke.filter=zb,ke.flatMap=cw,ke.flatMapDeep=Nb,ke.flatMapDepth=jh,ke.flatten=wc,ke.flattenDeep=To,ke.flattenDepth=cd,ke.flip=Hb,ke.flow=xQ,ke.flowRight=wQ,ke.fromPairs=Lp,ke.functions=Jb,ke.functionsIn=ex,ke.groupBy=Gb,ke.initial=s0,ke.intersection=zp,ke.intersectionBy=j1,ke.intersectionWith=W1,ke.invert=_w,ke.invertBy=bw,ke.invokeMap=dw,ke.iteratee=Ow,ke.keyBy=hw,ke.keys=ml,ke.keysIn=ju,ke.map=c0,ke.mapKeys=Sc,ke.mapValues=tg,ke.matches=MQ,ke.matchesProperty=SQ,ke.memoize=Np,ke.merge=tx,ke.mergeWith=nx,ke.method=EQ,ke.methodOf=OQ,ke.mixin=Bw,ke.negate=Gp,ke.nthArg=kQ,ke.omit=ww,ke.omitBy=Mw,ke.once=Zb,ke.orderBy=Wp,ke.over=IQ,ke.overArgs=d0,ke.overEvery=TQ,ke.overSome=KQ,ke.partial=h0,ke.partialRight=wv,ke.partition=$b,ke.pick=Ul,ke.pickBy=Wu,ke.property=dk,ke.propertyOf=PQ,ke.pull=Sb,ke.pullAll=av,ke.pullAllBy=sv,ke.pullAllWith=lv,ke.pullAt=tw,ke.range=FQ,ke.rangeRight=DQ,ke.rearg=Mv,ke.reject=q1,ke.remove=nw,ke.rest=eg,ke.reverse=N1,ke.sampleSize=H1,ke.set=Ec,ke.setWith=Yf,ke.shuffle=fw,ke.slice=l0,ke.sortBy=gw,ke.sortedUniq=G1,ke.sortedUniqBy=Av,ke.split=sQ,ke.spread=f0,ke.tail=ow,ke.take=cv,ke.takeRight=dv,ke.takeRightWhile=jp,ke.takeWhile=Ob,ke.tap=Pb,ke.throttle=Sv,ke.thru=u0,ke.toArray=Fl,ke.toPairs=Oc,ke.toPairsIn=sk,ke.toPath=jQ,ke.toPlainObject=Wi,ke.transform=LG,ke.unary=Ev,ke.union=Bb,ke.unionBy=hv,ke.unionWith=kb,ke.uniq=Q1,ke.uniqBy=Ib,ke.uniqWith=aw,ke.unset=zG,ke.unzip=fv,ke.unzipWith=pv,ke.update=jG,ke.updateWith=WG,ke.values=ng,ke.valuesIn=NG,ke.without=sw,ke.words=Ak,ke.wrap=Ov,ke.xor=lw,ke.xorBy=uw,ke.xorWith=Aw,ke.zip=mv,ke.zipObject=zh,ke.zipObjectDeep=Tb,ke.zipWith=Kb,ke.entries=Oc,ke.entriesIn=sk,ke.extend=AA,ke.extendWith=zu,Bw(ke,ke),ke.add=NQ,ke.attempt=ck,ke.camelCase=YG,ke.capitalize=lk,ke.ceil=GQ,ke.clamp=GG,ke.clone=c,ke.cloneDeep=d,ke.cloneDeepWith=y,ke.cloneWith=l,ke.conformsTo=w,ke.deburr=uk,ke.defaultTo=bQ,ke.divide=QQ,ke.endsWith=qG,ke.eq=T,ke.escape=VG,ke.escapeRegExp=HG,ke.every=Lb,ke.find=jb,ke.findIndex=UA,ke.findKey=th,ke.findLast=Wb,ke.findLastIndex=xc,ke.findLastKey=p0,ke.floor=$Q,ke.forEach=Cv,ke.forEachRight=_v,ke.forIn=Xb,ke.forInRight=Bv,ke.forOwn=kv,ke.forOwnRight=nh,ke.get=Iv,ke.gt=K,ke.gte=D,ke.has=Cw,ke.hasIn=Tv,ke.head=Zd,ke.identity=LA,ke.includes=Qb,ke.indexOf=a0,ke.inRange=QG,ke.invoke=xw,ke.isArguments=z,ke.isArray=Q,ke.isArrayBuffer=ie,ke.isArrayLike=le,ke.isArrayLikeObject=ge,ke.isBoolean=Oe,ke.isBuffer=Be,ke.isDate=ze,ke.isElement=$e,ke.isEmpty=tt,ke.isEqual=St,ke.isEqualWith=lt,ke.isError=vt,ke.isFinite=tn,ke.isFunction=an,ke.isInteger=Vn,ke.isLength=cr,ke.isMap=Kn,ke.isMatch=ur,ke.isMatchWith=Dn,ke.isNaN=wn,ke.isNative=Kr,ke.isNil=Bi,ke.isNull=wr,ke.isNumber=ea,ke.isObject=xn,ke.isObjectLike=Cn,ke.isPlainObject=No,ke.isRegExp=Xa,ke.isSafeInteger=Lu,ke.isSet=Kl,ke.isString=ka,ke.isSymbol=Go,ke.isTypedArray=Ja,ke.isUndefined=Xl,ke.isWeakMap=Jl,ke.isWeakSet=ks,ke.join=J5,ke.kebabCase=ZG,ke.last=lA,ke.lastIndexOf=Mb,ke.lowerCase=XG,ke.lowerFirst=JG,ke.lt=Is,ke.lte=Pl,ke.max=YQ,ke.maxBy=qQ,ke.mean=VQ,ke.meanBy=HQ,ke.min=ZQ,ke.minBy=XQ,ke.stubArray=Iw,ke.stubFalse=Tw,ke.stubObject=UQ,ke.stubString=RQ,ke.stubTrue=LQ,ke.multiply=JQ,ke.nth=ew,ke.noConflict=BQ,ke.noop=kw,ke.now=Xd,ke.pad=eQ,ke.padEnd=tQ,ke.padStart=nQ,ke.parseInt=rQ,ke.random=$G,ke.reduce=Y1,ke.reduceRight=Yb,ke.repeat=iQ,ke.replace=oQ,ke.result=$f,ke.round=e$,ke.runInContext=xt,ke.sample=V1,ke.size=pw,ke.snakeCase=aQ,ke.some=mw,ke.sortedIndex=dd,ke.sortedIndexBy=Lh,ke.sortedIndexOf=Eb,ke.sortedLastIndex=uv,ke.sortedLastIndexBy=rw,ke.sortedLastIndexOf=iw,ke.startCase=lQ,ke.startsWith=uQ,ke.subtract=t$,ke.sum=n$,ke.sumBy=r$,ke.template=AQ,ke.times=zQ,ke.toFinite=Ia,ke.toInteger=Hr,ke.toLength=eu,ke.toLower=cQ,ke.toNumber=Ko,ke.toSafeInteger=Dl,ke.toString=mi,ke.toUpper=dQ,ke.trim=hQ,ke.trimEnd=fQ,ke.trimStart=pQ,ke.truncate=mQ,ke.unescape=gQ,ke.uniqueId=WQ,ke.upperCase=yQ,ke.upperFirst=Sw,ke.each=Cv,ke.eachRight=_v,ke.first=Zd,Bw(ke,function(){var v={};return Ms(ke,function(S,F){Ei.call(ke.prototype,F)||(v[F]=S)}),v}(),{chain:!1}),ke.VERSION=r,$l(["bind","bindKey","curry","curryRight","partial","partialRight"],function(v){ke[v].placeholder=ke}),$l(["drop","take"],function(v,S){jr.prototype[v]=function(F){F=F===t?1:oa(Hr(F),0);var Z=this.__filtered__&&!S?new jr(this):this.clone();return Z.__filtered__?Z.__takeCount__=Eo(F,Z.__takeCount__):Z.__views__.push({size:Eo(F,nt),type:v+(Z.__dir__<0?"Right":"")}),Z},jr.prototype[v+"Right"]=function(F){return this.reverse()[v](F).reverse()}}),$l(["filter","map","takeWhile"],function(v,S){var F=S+1,Z=F==He||F==jt;jr.prototype[v]=function(be){var Ue=this.clone();return Ue.__iteratees__.push({iteratee:Vr(be,3),type:F}),Ue.__filtered__=Ue.__filtered__||Z,Ue}}),$l(["head","last"],function(v,S){var F="take"+(S?"Right":"");jr.prototype[v]=function(){return this[F](1).value()[0]}}),$l(["initial","tail"],function(v,S){var F="drop"+(S?"":"Right");jr.prototype[v]=function(){return this.__filtered__?new jr(this):this[F](1)}}),jr.prototype.compact=function(){return this.filter(LA)},jr.prototype.find=function(v){return this.filter(v).head()},jr.prototype.findLast=function(v){return this.reverse().find(v)},jr.prototype.invokeMap=Qi(function(v,S){return typeof v=="function"?new jr(this):this.map(function(F){return Wo(F,v,S)})}),jr.prototype.reject=function(v){return this.filter(Gp(Vr(v)))},jr.prototype.slice=function(v,S){v=Hr(v);var F=this;return F.__filtered__&&(v>0||S<0)?new jr(F):(v<0?F=F.takeRight(-v):v&&(F=F.drop(v)),S!==t&&(S=Hr(S),F=S<0?F.dropRight(-S):F.take(S-v)),F)},jr.prototype.takeRightWhile=function(v){return this.reverse().takeWhile(v).reverse()},jr.prototype.toArray=function(){return this.take(nt)},Ms(jr.prototype,function(v,S){var F=/^(?:filter|find|map|reject)|While$/.test(S),Z=/^(?:head|last)$/.test(S),be=ke[Z?"take"+(S=="last"?"Right":""):S],Ue=Z||/^find/.test(S);be&&(ke.prototype[S]=function(){var ot=this.__wrapped__,gt=Z?[1]:arguments,It=ot instanceof jr,yn=gt[0],vn=It||Q(ot),kn=function(_o){var Bo=be.apply(ke,Eu([_o],gt));return Z&&fr?Bo[0]:Bo};vn&&F&&typeof yn=="function"&&yn.length!=1&&(It=vn=!1);var fr=this.__chain__,Gr=!!this.__actions__.length,ci=Ue&&!fr,ro=It&&!Gr;if(!Ue&&vn){ot=ro?ot:new jr(this);var di=v.apply(ot,gt);return di.__actions__.push({func:u0,args:[kn],thisArg:t}),new uo(di,fr)}return ci&&ro?v.apply(this,gt):(di=this.thru(kn),ci?Z?di.value()[0]:di.value():di)})}),$l(["pop","push","shift","sort","splice","unshift"],function(v){var S=tA[v],F=/^(?:push|sort|unshift)$/.test(v)?"tap":"thru",Z=/^(?:pop|shift)$/.test(v);ke.prototype[v]=function(){var be=arguments;if(Z&&!this.__chain__){var Ue=this.value();return S.apply(Q(Ue)?Ue:[],be)}return this[F](function(ot){return S.apply(Q(ot)?ot:[],be)})}}),Ms(jr.prototype,function(v,S){var F=ke[S];if(F){var Z=F.name+"";Ei.call(Oo,Z)||(Oo[Z]=[]),Oo[Z].push({name:S,func:F})}}),Oo[Rh(t,$).name]=[{name:"wrapper",func:t}],jr.prototype.clone=Ma,jr.prototype.reverse=Ku,jr.prototype.value=dc,ke.prototype.at=yv,ke.prototype.chain=$1,ke.prototype.commit=Fb,ke.prototype.next=vv,ke.prototype.plant=uA,ke.prototype.reverse=A0,ke.prototype.toJSON=ke.prototype.valueOf=ke.prototype.value=Ub,ke.prototype.first=ke.prototype.head,sc&&(ke.prototype[sc]=Db),ke},ku=Ud();qo?((qo.exports=ku)._=ku,Yi._=ku):qr._=ku}).call(mf)})(n3,n3.exports);var Q4=n3.exports;const p6=ga(Q4);function QV(e,n,t){const r=n<0?e.length+n:n;if(r>=0&&r<e.length){const i=t<0?e.length+t:t,[o]=e.splice(n,1);e.splice(i,0,o)}}function $V(e){for(var n=5381,t=e.length;t;)n=n*33^e.charCodeAt(--t);return n>>>0}var YV=$V;const BI=ga(YV);var qV=8,VV={version:{required:!0,type:"enum",values:[8]},name:{type:"string"},metadata:{type:"*"},center:{type:"array",value:"number"},zoom:{type:"number"},bearing:{type:"number",default:0,period:360,units:"degrees"},pitch:{type:"number",default:0,units:"degrees"},light:{type:"light"},sky:{type:"sky"},terrain:{type:"terrain"},sources:{required:!0,type:"sources"},sprite:{type:"sprite"},glyphs:{type:"string"},transition:{type:"transition"},layers:{required:!0,type:"array",value:"layer"}},HV={"*":{type:"source"}},ZV=["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],XV={type:{required:!0,type:"enum",values:{vector:{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},scheme:{type:"enum",values:{xyz:{},tms:{}},default:"xyz"},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},attribution:{type:"string"},promoteId:{type:"promoteId"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},JV={type:{required:!0,type:"enum",values:{raster:{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},tileSize:{type:"number",default:512,units:"pixels"},scheme:{type:"enum",values:{xyz:{},tms:{}},default:"xyz"},attribution:{type:"string"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},eH={type:{required:!0,type:"enum",values:{"raster-dem":{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},tileSize:{type:"number",default:512,units:"pixels"},attribution:{type:"string"},encoding:{type:"enum",values:{terrarium:{},mapbox:{},custom:{}},default:"mapbox"},redFactor:{type:"number",default:1},blueFactor:{type:"number",default:1},greenFactor:{type:"number",default:1},baseShift:{type:"number",default:0},volatile:{type:"boolean",default:!1},"*":{type:"*"}},tH={type:{required:!0,type:"enum",values:{geojson:{}}},data:{required:!0,type:"*"},maxzoom:{type:"number",default:18},attribution:{type:"string"},buffer:{type:"number",default:128,maximum:512,minimum:0},filter:{type:"*"},tolerance:{type:"number",default:.375},cluster:{type:"boolean",default:!1},clusterRadius:{type:"number",default:50,minimum:0},clusterMaxZoom:{type:"number"},clusterMinPoints:{type:"number"},clusterProperties:{type:"*"},lineMetrics:{type:"boolean",default:!1},generateId:{type:"boolean",default:!1},promoteId:{type:"promoteId"}},nH={type:{required:!0,type:"enum",values:{video:{}}},urls:{required:!0,type:"array",value:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},rH={type:{required:!0,type:"enum",values:{image:{}}},url:{required:!0,type:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},iH={id:{type:"string",required:!0},type:{type:"enum",values:{fill:{},line:{},symbol:{},circle:{},heatmap:{},"fill-extrusion":{},raster:{},hillshade:{},background:{}},required:!0},metadata:{type:"*"},source:{type:"string"},"source-layer":{type:"string"},minzoom:{type:"number",minimum:0,maximum:24},maxzoom:{type:"number",minimum:0,maximum:24},filter:{type:"filter"},layout:{type:"layout"},paint:{type:"paint"}},oH=["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background"],aH={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},sH={"fill-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},lH={"circle-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},uH={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},AH={"line-cap":{type:"enum",values:{butt:{},round:{},square:{}},default:"butt",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-join":{type:"enum",values:{bevel:{},round:{},miter:{}},default:"miter",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{type:"number",default:2,requires:[{"line-join":"miter"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-round-limit":{type:"number",default:1.05,requires:[{"line-join":"round"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},cH={"symbol-placement":{type:"enum",values:{point:{},line:{},"line-center":{}},default:"point",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-spacing":{type:"number",default:250,minimum:1,units:"pixels",requires:[{"symbol-placement":"line"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{type:"boolean",default:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{type:"enum",values:{auto:{},"viewport-y":{},source:{}},default:"auto",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{type:"boolean",default:!1,requires:["icon-image",{"!":"icon-overlap"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-overlap":{type:"enum",values:{never:{},always:{},cooperative:{}},requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{type:"boolean",default:!1,requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-optional":{type:"boolean",default:!1,requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-size":{type:"number",default:1,minimum:0,units:"factor of the original icon size",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{type:"enum",values:{none:{},width:{},height:{},both:{}},default:"none",requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",requires:["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-image":{type:"resolvedImage",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{type:"padding",default:[2],units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-keep-upright":{type:"boolean",default:!1,requires:["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{type:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},default:"center",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{type:"enum",values:{map:{},viewport:{},"viewport-glyph":{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-field":{type:"formatted",default:"",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-font":{type:"array",value:"string",default:["Open Sans Regular","Arial Unicode MS Regular"],requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-size":{type:"number",default:16,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{type:"number",default:1.2,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-letter-spacing":{type:"number",default:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-justify":{type:"enum",values:{auto:{},left:{},center:{},right:{}},default:"center",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{type:"number",units:"ems",default:0,requires:["text-field"],"property-type":"data-driven",expression:{interpolated:!0,parameters:["zoom","feature"]}},"text-variable-anchor":{type:"array",value:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-variable-anchor-offset":{type:"variableAnchorOffsetCollection",requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-anchor":{type:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},default:"center",requires:["text-field",{"!":"text-variable-anchor"}],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{type:"number",default:45,units:"degrees",requires:["text-field",{"symbol-placement":["line","line-center"]}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-writing-mode":{type:"array",value:"enum",values:{horizontal:{},vertical:{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-keep-upright":{type:"boolean",default:!0,requires:["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-transform":{type:"enum",values:{none:{},uppercase:{},lowercase:{}},default:"none",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-offset":{type:"array",value:"number",units:"ems",length:2,default:[0,0],requires:["text-field",{"!":"text-radial-offset"}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{type:"boolean",default:!1,requires:["text-field",{"!":"text-overlap"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-overlap":{type:"enum",values:{never:{},always:{},cooperative:{}},requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{type:"boolean",default:!1,requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-optional":{type:"boolean",default:!1,requires:["text-field","icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},dH={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},hH={visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},fH={type:"array",value:"*"},pH={type:"enum",values:{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},in:{},"!in":{},all:{},any:{},none:{},has:{},"!has":{},within:{}}},mH={type:"enum",values:{Point:{},LineString:{},Polygon:{}}},gH={type:"array",minimum:0,maximum:24,value:["number","color"],length:2},yH={type:"array",value:"*",minimum:1},vH={anchor:{type:"enum",default:"viewport",values:{map:{},viewport:{}},"property-type":"data-constant",transition:!1,expression:{interpolated:!1,parameters:["zoom"]}},position:{type:"array",default:[1.15,210,30],length:3,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},intensity:{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},CH={"sky-color":{type:"color","property-type":"data-constant",default:"#88C6FC",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"fog-color":{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"fog-blend":{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"horizon-blend":{type:"number","property-type":"data-constant",default:.8,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},_H={source:{type:"string",required:!0},exaggeration:{type:"number",minimum:0,default:1}},bH=["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background"],xH={"fill-antialias":{type:"boolean",default:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{type:"color",transition:!0,requires:[{"!":"fill-pattern"},{"fill-antialias":!0}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"}},wH={"line-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"line-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["line-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-width":{type:"number",default:1,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{type:"number",default:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{type:"array",value:"number",minimum:0,transition:!0,units:"line widths",requires:[{"!":"line-pattern"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"line-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-gradient":{type:"color",transition:!1,requires:[{"!":"line-dasharray"},{"!":"line-pattern"},{source:"geojson",has:{lineMetrics:!0}}],expression:{interpolated:!0,parameters:["line-progress"]},"property-type":"color-ramp"}},MH={"circle-radius":{type:"number",default:5,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{type:"number",default:0,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["circle-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{type:"enum",values:{map:{},viewport:{}},default:"map",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"}},SH={"heatmap-radius":{type:"number",default:30,minimum:1,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{type:"number",default:1,minimum:0,transition:!1,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{type:"number",default:1,minimum:0,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"heatmap-color":{type:"color",default:["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],transition:!1,expression:{interpolated:!0,parameters:["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},EH={"icon-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{type:"color",default:"#000000",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["icon-image","icon-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{type:"color",default:"#000000",transition:!0,overridable:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["text-field","text-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},OH={"raster-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{type:"number",default:0,period:360,transition:!0,units:"degrees",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{type:"number",default:0,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-saturation":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-contrast":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-resampling":{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{type:"number",default:300,minimum:0,transition:!1,units:"milliseconds",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},BH={"hillshade-illumination-direction":{type:"number",default:335,minimum:0,maximum:359,transition:!1,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{type:"number",default:.5,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},kH={"background-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"background-pattern"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"background-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},IH={duration:{type:"number",default:300,minimum:0,units:"milliseconds"},delay:{type:"number",default:0,minimum:0,units:"milliseconds"}},TH={"*":{type:"string"}},ma={$version:qV,$root:VV,sources:HV,source:ZV,source_vector:XV,source_raster:JV,source_raster_dem:eH,source_geojson:tH,source_video:nH,source_image:rH,layer:iH,layout:oH,layout_background:aH,layout_fill:sH,layout_circle:lH,layout_heatmap:uH,"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_line:AH,layout_symbol:cH,layout_raster:dH,layout_hillshade:hH,filter:fH,filter_operator:pH,geometry_type:mH,function:{expression:{type:"expression"},stops:{type:"array",value:"function_stop"},base:{type:"number",default:1,minimum:0},property:{type:"string",default:"$zoom"},type:{type:"enum",values:{identity:{},exponential:{},interval:{},categorical:{}},default:"exponential"},colorSpace:{type:"enum",values:{rgb:{},lab:{},hcl:{}},default:"rgb"},default:{type:"*",required:!1}},function_stop:gH,expression:yH,light:vH,sky:CH,terrain:_H,paint:bH,paint_fill:xH,"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-extrusion-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-extrusion-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"fill-extrusion-height":{type:"number",default:0,minimum:0,units:"meters",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{type:"number",default:0,minimum:0,units:"meters",transition:!0,requires:["fill-extrusion-height"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{type:"boolean",default:!0,transition:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_line:wH,paint_circle:MH,paint_heatmap:SH,paint_symbol:EH,paint_raster:OH,paint_hillshade:BH,paint_background:kH,transition:IH,"property-type":{"data-driven":{type:"property-type"},"cross-faded":{type:"property-type"},"cross-faded-data-driven":{type:"property-type"},"color-ramp":{type:"property-type"},"data-constant":{type:"property-type"},constant:{type:"property-type"}},promoteId:TH};const KH=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function PH(e,n){const t={};for(const r in e)r!=="ref"&&(t[r]=e[r]);return KH.forEach(r=>{r in n&&(t[r]=n[r])}),t}function FH(e){e=e.slice();const n=Object.create(null);for(let t=0;t<e.length;t++)n[e[t].id]=e[t];for(let t=0;t<e.length;t++)"ref"in e[t]&&(e[t]=PH(e[t],n[e[t].ref]));return e}function Wa(e,n){if(Array.isArray(e)){if(!Array.isArray(n)||e.length!==n.length)return!1;for(let t=0;t<e.length;t++)if(!Wa(e[t],n[t]))return!1;return!0}if(typeof e=="object"&&e!==null&&n!==null){if(typeof n!="object"||Object.keys(e).length!==Object.keys(n).length)return!1;for(const r in e)if(!Wa(e[r],n[r]))return!1;return!0}return e===n}function gd(e,n){e.push(n)}function TU(e,n,t){gd(t,{command:"addSource",args:[e,n[e]]})}function KU(e,n,t){gd(n,{command:"removeSource",args:[e]}),t[e]=!0}function DH(e,n,t,r){KU(e,t,r),TU(e,n,t)}function UH(e,n,t){let r;for(r in e[t])if(Object.prototype.hasOwnProperty.call(e[t],r)&&r!=="data"&&!Wa(e[t][r],n[t][r]))return!1;for(r in n[t])if(Object.prototype.hasOwnProperty.call(n[t],r)&&r!=="data"&&!Wa(e[t][r],n[t][r]))return!1;return!0}function RH(e,n,t,r){e=e||{},n=n||{};let i;for(i in e)Object.prototype.hasOwnProperty.call(e,i)&&(Object.prototype.hasOwnProperty.call(n,i)||KU(i,t,r));for(i in n)Object.prototype.hasOwnProperty.call(n,i)&&(Object.prototype.hasOwnProperty.call(e,i)?Wa(e[i],n[i])||(e[i].type==="geojson"&&n[i].type==="geojson"&&UH(e,n,i)?gd(t,{command:"setGeoJSONSourceData",args:[i,n[i].data]}):DH(i,n,t,r)):TU(i,n,t))}function hx(e,n,t,r,i,o){e=e||{},n=n||{};for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(Wa(e[s],n[s])||t.push({command:o,args:[r,s,n[s],i]}));for(const s in n)!Object.prototype.hasOwnProperty.call(n,s)||Object.prototype.hasOwnProperty.call(e,s)||Wa(e[s],n[s])||t.push({command:o,args:[r,s,n[s],i]})}function kI(e){return e.id}function II(e,n){return e[n.id]=n,e}function LH(e,n,t){e=e||[],n=n||[];const r=e.map(kI),i=n.map(kI),o=e.reduce(II,{}),s=n.reduce(II,{}),a=r.slice(),f=Object.create(null);let g,x,k,B,P;for(let R=0,H=0;R<r.length;R++)g=r[R],Object.prototype.hasOwnProperty.call(s,g)?H++:(gd(t,{command:"removeLayer",args:[g]}),a.splice(a.indexOf(g,H),1));for(let R=0,H=0;R<i.length;R++)g=i[i.length-1-R],a[a.length-1-R]!==g&&(Object.prototype.hasOwnProperty.call(o,g)?(gd(t,{command:"removeLayer",args:[g]}),a.splice(a.lastIndexOf(g,a.length-H),1)):H++,B=a[a.length-R],gd(t,{command:"addLayer",args:[s[g],B]}),a.splice(a.length-R,0,g),f[g]=!0);for(let R=0;R<i.length;R++)if(g=i[R],x=o[g],k=s[g],!(f[g]||Wa(x,k))){if(!Wa(x.source,k.source)||!Wa(x["source-layer"],k["source-layer"])||!Wa(x.type,k.type)){gd(t,{command:"removeLayer",args:[g]}),B=a[a.lastIndexOf(g)+1],gd(t,{command:"addLayer",args:[k,B]});continue}hx(x.layout,k.layout,t,g,null,"setLayoutProperty"),hx(x.paint,k.paint,t,g,null,"setPaintProperty"),Wa(x.filter,k.filter)||gd(t,{command:"setFilter",args:[g,k.filter]}),(!Wa(x.minzoom,k.minzoom)||!Wa(x.maxzoom,k.maxzoom))&&gd(t,{command:"setLayerZoomRange",args:[g,k.minzoom,k.maxzoom]});for(P in x)Object.prototype.hasOwnProperty.call(x,P)&&(P==="layout"||P==="paint"||P==="filter"||P==="metadata"||P==="minzoom"||P==="maxzoom"||(P.indexOf("paint.")===0?hx(x[P],k[P],t,g,P.slice(6),"setPaintProperty"):Wa(x[P],k[P])||gd(t,{command:"setLayerProperty",args:[g,P,k[P]]})));for(P in k)!Object.prototype.hasOwnProperty.call(k,P)||Object.prototype.hasOwnProperty.call(x,P)||P==="layout"||P==="paint"||P==="filter"||P==="metadata"||P==="minzoom"||P==="maxzoom"||(P.indexOf("paint.")===0?hx(x[P],k[P],t,g,P.slice(6),"setPaintProperty"):Wa(x[P],k[P])||gd(t,{command:"setLayerProperty",args:[g,P,k[P]]}))}}function zH(e,n){if(!e)return[{command:"setStyle",args:[n]}];let t=[];try{if(!Wa(e.version,n.version))return[{command:"setStyle",args:[n]}];Wa(e.center,n.center)||t.push({command:"setCenter",args:[n.center]}),Wa(e.zoom,n.zoom)||t.push({command:"setZoom",args:[n.zoom]}),Wa(e.bearing,n.bearing)||t.push({command:"setBearing",args:[n.bearing]}),Wa(e.pitch,n.pitch)||t.push({command:"setPitch",args:[n.pitch]}),Wa(e.sprite,n.sprite)||t.push({command:"setSprite",args:[n.sprite]}),Wa(e.glyphs,n.glyphs)||t.push({command:"setGlyphs",args:[n.glyphs]}),Wa(e.transition,n.transition)||t.push({command:"setTransition",args:[n.transition]}),Wa(e.light,n.light)||t.push({command:"setLight",args:[n.light]}),Wa(e.terrain,n.terrain)||t.push({command:"setTerrain",args:[n.terrain]});const r={},i=[];RH(e.sources,n.sources,i,r);const o=[];e.layers&&e.layers.forEach(s=>{"source"in s&&r[s.source]?t.push({command:"removeLayer",args:[s.id]}):o.push(s)}),t=t.concat(i),LH(o,n.layers,t)}catch(r){console.warn("Unable to compute style diff:",r),t=[{command:"setStyle",args:[n]}]}return t}class Hn{constructor(n,t,r,i){this.message=(n?`${n}: `:"")+r,i&&(this.identifier=i),t!=null&&t.__line__&&(this.line=t.__line__)}}function _y(e,...n){for(const t of n)for(const r in t)e[r]=t[r];return e}class Hh extends Error{constructor(n,t){super(t),this.message=t,this.key=n}}let jH=class PU{constructor(n,t=[]){this.parent=n,this.bindings={};for(const[r,i]of t)this.bindings[r]=i}concat(n){return new PU(this,n)}get(n){if(this.bindings[n])return this.bindings[n];if(this.parent)return this.parent.get(n);throw new Error(`${n} not found in scope.`)}has(n){return this.bindings[n]?!0:this.parent?this.parent.has(n):!1}};const $4={kind:"null"},tr={kind:"number"},co={kind:"string"},Vi={kind:"boolean"},af={kind:"color"},Zg={kind:"object"},Zi={kind:"value"},WH={kind:"error"},Y4={kind:"collator"},q4={kind:"formatted"},V4={kind:"padding"},z_={kind:"resolvedImage"},H4={kind:"variableAnchorOffsetCollection"};function Pc(e,n){return{kind:"array",itemType:e,N:n}}function fs(e){if(e.kind==="array"){const n=fs(e.itemType);return typeof e.N=="number"?`array<${n}, ${e.N}>`:e.itemType.kind==="value"?"array":`array<${n}>`}else return e.kind}const NH=[$4,tr,co,Vi,af,q4,Zg,Pc(Zi),V4,z_,H4];function n_(e,n){if(n.kind==="error")return null;if(e.kind==="array"){if(n.kind==="array"&&(n.N===0&&n.itemType.kind==="value"||!n_(e.itemType,n.itemType))&&(typeof e.N!="number"||e.N===n.N))return null}else{if(e.kind===n.kind)return null;if(e.kind==="value"){for(const t of NH)if(!n_(t,n))return null}}return`Expected ${fs(e)} but found ${fs(n)} instead.`}function pB(e,n){return n.some(t=>t.kind===e.kind)}function r_(e,n){return n.some(t=>t==="null"?e===null:t==="array"?Array.isArray(e):t==="object"?e&&!Array.isArray(e)&&typeof e=="object":t===typeof e)}function zv(e,n){return e.kind==="array"&&n.kind==="array"?e.itemType.kind===n.itemType.kind&&typeof e.N=="number":e.kind===n.kind}const FU=.96422,DU=1,UU=.82521,RU=4/29,Xg=6/29,LU=3*Xg*Xg,GH=Xg*Xg*Xg,QH=Math.PI/180,$H=180/Math.PI;function zU(e){return e=e%360,e<0&&(e+=360),e}function jU([e,n,t,r]){e=Xw(e),n=Xw(n),t=Xw(t);let i,o;const s=Jw((.2225045*e+.7168786*n+.0606169*t)/DU);e===n&&n===t?i=o=s:(i=Jw((.4360747*e+.3850649*n+.1430804*t)/FU),o=Jw((.0139322*e+.0971045*n+.7141733*t)/UU));const a=116*s-16;return[a<0?0:a,500*(i-s),200*(s-o),r]}function Xw(e){return e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function Jw(e){return e>GH?Math.pow(e,1/3):e/LU+RU}function WU([e,n,t,r]){let i=(e+16)/116,o=isNaN(n)?i:i+n/500,s=isNaN(t)?i:i-t/200;return i=DU*tM(i),o=FU*tM(o),s=UU*tM(s),[eM(3.1338561*o-1.6168667*i-.4906146*s),eM(-.9787684*o+1.9161415*i+.033454*s),eM(.0719453*o-.2289914*i+1.4052427*s),r]}function eM(e){return e=e<=.00304?12.92*e:1.055*Math.pow(e,1/2.4)-.055,e<0?0:e>1?1:e}function tM(e){return e>Xg?e*e*e:LU*(e-RU)}function YH(e){const[n,t,r,i]=jU(e),o=Math.sqrt(t*t+r*r);return[Math.round(o*1e4)?zU(Math.atan2(r,t)*$H):NaN,o,n,i]}function qH([e,n,t,r]){return e=isNaN(e)?0:e*QH,WU([t,Math.cos(e)*n,Math.sin(e)*n,r])}function VH([e,n,t,r]){e=zU(e),n/=100,t/=100;function i(o){const s=(o+e/30)%12,a=n*Math.min(t,1-t);return t-a*Math.max(-1,Math.min(s-3,9-s,1))}return[i(0),i(8),i(4),r]}function HH(e){if(e=e.toLowerCase().trim(),e==="transparent")return[0,0,0,0];const n=ZH[e];if(n){const[i,o,s]=n;return[i/255,o/255,s/255,1]}if(e.startsWith("#")&&/^#(?:[0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/.test(e)){const o=e.length<6?1:2;let s=1;return[fx(e.slice(s,s+=o)),fx(e.slice(s,s+=o)),fx(e.slice(s,s+=o)),fx(e.slice(s,s+o)||"ff")]}if(e.startsWith("rgb")){const i=/^rgba?\(\s*([\de.+-]+)(%)?(?:\s+|\s*(,)\s*)([\de.+-]+)(%)?(?:\s+|\s*(,)\s*)([\de.+-]+)(%)?(?:\s*([,\/])\s*([\de.+-]+)(%)?)?\s*\)$/,o=e.match(i);if(o){const[s,a,f,g,x,k,B,P,R,H,W,$]=o,q=[g||" ",B||" ",H].join("");if(q===" "||q===" /"||q===",,"||q===",,,"){const oe=[f,k,R].join(""),ne=oe==="%%%"?100:oe===""?255:0;if(ne){const ce=[gg(+a/ne,0,1),gg(+x/ne,0,1),gg(+P/ne,0,1),W?TI(+W,$):1];if(KI(ce))return ce}}return}}const t=/^hsla?\(\s*([\de.+-]+)(?:deg)?(?:\s+|\s*(,)\s*)([\de.+-]+)%(?:\s+|\s*(,)\s*)([\de.+-]+)%(?:\s*([,\/])\s*([\de.+-]+)(%)?)?\s*\)$/,r=e.match(t);if(r){const[i,o,s,a,f,g,x,k,B]=r,P=[s||" ",f||" ",x].join("");if(P===" "||P===" /"||P===",,"||P===",,,"){const R=[+o,gg(+a,0,100),gg(+g,0,100),k?TI(+k,B):1];if(KI(R))return VH(R)}}}function fx(e){return parseInt(e.padEnd(2,e),16)/255}function TI(e,n){return gg(n?e/100:e,0,1)}function gg(e,n,t){return Math.min(Math.max(n,e),t)}function KI(e){return!e.some(Number.isNaN)}const ZH={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};let ms=class m6{constructor(n,t,r,i=1,o=!0){this.r=n,this.g=t,this.b=r,this.a=i,o||(this.r*=i,this.g*=i,this.b*=i,i||this.overwriteGetter("rgb",[n,t,r,i]))}static parse(n){if(n instanceof m6)return n;if(typeof n!="string")return;const t=HH(n);if(t)return new m6(...t,!1)}get rgb(){const{r:n,g:t,b:r,a:i}=this,o=i||1/0;return this.overwriteGetter("rgb",[n/o,t/o,r/o,i])}get hcl(){return this.overwriteGetter("hcl",YH(this.rgb))}get lab(){return this.overwriteGetter("lab",jU(this.rgb))}overwriteGetter(n,t){return Object.defineProperty(this,n,{value:t}),t}toString(){const[n,t,r,i]=this.rgb;return`rgba(${[n,t,r].map(o=>Math.round(o*255)).join(",")},${i})`}};ms.black=new ms(0,0,0,1);ms.white=new ms(1,1,1,1);ms.transparent=new ms(0,0,0,0);ms.red=new ms(1,0,0,1);let mB=class{constructor(n,t,r){n?this.sensitivity=t?"variant":"case":this.sensitivity=t?"accent":"base",this.locale=r,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})}compare(n,t){return this.collator.compare(n,t)}resolvedLocale(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale}},g6=class{constructor(n,t,r,i,o){this.text=n,this.image=t,this.scale=r,this.fontStack=i,this.textColor=o}},Dy=class h2{constructor(n){this.sections=n}static fromString(n){return new h2([new g6(n,null,null,null,null)])}isEmpty(){return this.sections.length===0?!0:!this.sections.some(n=>n.text.length!==0||n.image&&n.image.name.length!==0)}static factory(n){return n instanceof h2?n:h2.fromString(n)}toString(){return this.sections.length===0?"":this.sections.map(n=>n.text).join("")}};class jc{constructor(n){this.values=n.slice()}static parse(n){if(n instanceof jc)return n;if(typeof n=="number")return new jc([n,n,n,n]);if(Array.isArray(n)&&!(n.length<1||n.length>4)){for(const t of n)if(typeof t!="number")return;switch(n.length){case 1:n=[n[0],n[0],n[0],n[0]];break;case 2:n=[n[0],n[1],n[0],n[1]];break;case 3:n=[n[0],n[1],n[2],n[1]];break}return new jc(n)}}toString(){return JSON.stringify(this.values)}}const XH=new Set(["center","left","right","top","bottom","top-left","top-right","bottom-left","bottom-right"]);class uf{constructor(n){this.values=n.slice()}static parse(n){if(n instanceof uf)return n;if(!(!Array.isArray(n)||n.length<1||n.length%2!==0)){for(let t=0;t<n.length;t+=2){const r=n[t],i=n[t+1];if(typeof r!="string"||!XH.has(r)||!Array.isArray(i)||i.length!==2||typeof i[0]!="number"||typeof i[1]!="number")return}return new uf(n)}}toString(){return JSON.stringify(this.values)}}let C1=class NU{constructor(n){this.name=n.name,this.available=n.available}toString(){return this.name}static fromString(n){return n?new NU({name:n,available:!1}):null}};function GU(e,n,t,r){return typeof e=="number"&&e>=0&&e<=255&&typeof n=="number"&&n>=0&&n<=255&&typeof t=="number"&&t>=0&&t<=255?typeof r>"u"||typeof r=="number"&&r>=0&&r<=1?null:`Invalid rgba value [${[e,n,t,r].join(", ")}]: 'a' must be between 0 and 1.`:`Invalid rgba value [${(typeof r=="number"?[e,n,t,r]:[e,n,t]).join(", ")}]: 'r', 'g', and 'b' must be between 0 and 255.`}function r3(e){if(e===null||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||e instanceof ms||e instanceof mB||e instanceof Dy||e instanceof jc||e instanceof uf||e instanceof C1)return!0;if(Array.isArray(e)){for(const n of e)if(!r3(n))return!1;return!0}else if(typeof e=="object"){for(const n in e)if(!r3(e[n]))return!1;return!0}else return!1}function jl(e){if(e===null)return $4;if(typeof e=="string")return co;if(typeof e=="boolean")return Vi;if(typeof e=="number")return tr;if(e instanceof ms)return af;if(e instanceof mB)return Y4;if(e instanceof Dy)return q4;if(e instanceof jc)return V4;if(e instanceof uf)return H4;if(e instanceof C1)return z_;if(Array.isArray(e)){const n=e.length;let t;for(const r of e){const i=jl(r);if(!t)t=i;else{if(t===i)continue;t=Zi;break}}return Pc(t||Zi,n)}else return Zg}function SC(e){const n=typeof e;return e===null?"":n==="string"||n==="number"||n==="boolean"?String(e):e instanceof ms||e instanceof Dy||e instanceof jc||e instanceof uf||e instanceof C1?e.toString():JSON.stringify(e)}let i3=class QU{constructor(n,t){this.type=n,this.value=t}static parse(n,t){if(n.length!==2)return t.error(`'literal' expression requires exactly one argument, but found ${n.length-1} instead.`);if(!r3(n[1]))return t.error("invalid value");const r=n[1];let i=jl(r);const o=t.expectedType;return i.kind==="array"&&i.N===0&&o&&o.kind==="array"&&(typeof o.N!="number"||o.N===0)&&(i=o),new QU(i,r)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}},sl=class{constructor(n){this.name="ExpressionEvaluationError",this.message=n}toJSON(){return this.message}};const px={string:co,number:tr,boolean:Vi,object:Zg};let fp=class $U{constructor(n,t){this.type=n,this.args=t}static parse(n,t){if(n.length<2)return t.error("Expected at least one argument.");let r=1,i;const o=n[0];if(o==="array"){let a;if(n.length>2){const g=n[1];if(typeof g!="string"||!(g in px)||g==="object")return t.error('The item type argument of "array" must be one of string, number, boolean',1);a=px[g],r++}else a=Zi;let f;if(n.length>3){if(n[2]!==null&&(typeof n[2]!="number"||n[2]<0||n[2]!==Math.floor(n[2])))return t.error('The length argument to "array" must be a positive integer literal',2);f=n[2],r++}i=Pc(a,f)}else{if(!px[o])throw new Error(`Types doesn't contain name = ${o}`);i=px[o]}const s=[];for(;r<n.length;r++){const a=t.parse(n[r],r,Zi);if(!a)return null;s.push(a)}return new $U(i,s)}evaluate(n){for(let t=0;t<this.args.length;t++){const r=this.args[t].evaluate(n);if(n_(this.type,jl(r))){if(t===this.args.length-1)throw new sl(`Expected value to be of type ${fs(this.type)}, but found ${fs(jl(r))} instead.`)}else return r}throw new Error}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}};const PI={"to-boolean":Vi,"to-color":af,"to-number":tr,"to-string":co};let Fg=class YU{constructor(n,t){this.type=n,this.args=t}static parse(n,t){if(n.length<2)return t.error("Expected at least one argument.");const r=n[0];if(!PI[r])throw new Error(`Can't parse ${r} as it is not part of the known types`);if((r==="to-boolean"||r==="to-string")&&n.length!==2)return t.error("Expected one argument.");const i=PI[r],o=[];for(let s=1;s<n.length;s++){const a=t.parse(n[s],s,Zi);if(!a)return null;o.push(a)}return new YU(i,o)}evaluate(n){switch(this.type.kind){case"boolean":return!!this.args[0].evaluate(n);case"color":{let t,r;for(const i of this.args){if(t=i.evaluate(n),r=null,t instanceof ms)return t;if(typeof t=="string"){const o=n.parseColor(t);if(o)return o}else if(Array.isArray(t)&&(t.length<3||t.length>4?r=`Invalid rbga value ${JSON.stringify(t)}: expected an array containing either three or four numeric values.`:r=GU(t[0],t[1],t[2],t[3]),!r))return new ms(t[0]/255,t[1]/255,t[2]/255,t[3])}throw new sl(r||`Could not parse color from value '${typeof t=="string"?t:JSON.stringify(t)}'`)}case"padding":{let t;for(const r of this.args){t=r.evaluate(n);const i=jc.parse(t);if(i)return i}throw new sl(`Could not parse padding from value '${typeof t=="string"?t:JSON.stringify(t)}'`)}case"variableAnchorOffsetCollection":{let t;for(const r of this.args){t=r.evaluate(n);const i=uf.parse(t);if(i)return i}throw new sl(`Could not parse variableAnchorOffsetCollection from value '${typeof t=="string"?t:JSON.stringify(t)}'`)}case"number":{let t=null;for(const r of this.args){if(t=r.evaluate(n),t===null)return 0;const i=Number(t);if(!isNaN(i))return i}throw new sl(`Could not convert ${JSON.stringify(t)} to number.`)}case"formatted":return Dy.fromString(SC(this.args[0].evaluate(n)));case"resolvedImage":return C1.fromString(SC(this.args[0].evaluate(n)));default:return SC(this.args[0].evaluate(n))}}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}};const JH=["Unknown","Point","LineString","Polygon"];let qU=class{constructor(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache={},this.availableImages=null,this.canonical=null}id(){return this.feature&&"id"in this.feature?this.feature.id:null}geometryType(){return this.feature?typeof this.feature.type=="number"?JH[this.feature.type]:this.feature.type:null}geometry(){return this.feature&&"geometry"in this.feature?this.feature.geometry:null}canonicalID(){return this.canonical}properties(){return this.feature&&this.feature.properties||{}}parseColor(n){let t=this._parseColorCache[n];return t||(t=this._parseColorCache[n]=ms.parse(n)),t}},VU=class HU{constructor(n,t,r=[],i,o=new jH,s=[]){this.registry=n,this.path=r,this.key=r.map(a=>`[${a}]`).join(""),this.scope=o,this.errors=s,this.expectedType=i,this._isConstant=t}parse(n,t,r,i,o={}){return t?this.concat(t,r,i)._parse(n,o):this._parse(n,o)}_parse(n,t){(n===null||typeof n=="string"||typeof n=="boolean"||typeof n=="number")&&(n=["literal",n]);function r(i,o,s){return s==="assert"?new fp(o,[i]):s==="coerce"?new Fg(o,[i]):i}if(Array.isArray(n)){if(n.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');const i=n[0];if(typeof i!="string")return this.error(`Expression name must be a string, but found ${typeof i} instead. If you wanted a literal array, use ["literal", [...]].`,0),null;const o=this.registry[i];if(o){let s=o.parse(n,this);if(!s)return null;if(this.expectedType){const a=this.expectedType,f=s.type;if((a.kind==="string"||a.kind==="number"||a.kind==="boolean"||a.kind==="object"||a.kind==="array")&&f.kind==="value")s=r(s,a,t.typeAnnotation||"assert");else if((a.kind==="color"||a.kind==="formatted"||a.kind==="resolvedImage")&&(f.kind==="value"||f.kind==="string"))s=r(s,a,t.typeAnnotation||"coerce");else if(a.kind==="padding"&&(f.kind==="value"||f.kind==="number"||f.kind==="array"))s=r(s,a,t.typeAnnotation||"coerce");else if(a.kind==="variableAnchorOffsetCollection"&&(f.kind==="value"||f.kind==="array"))s=r(s,a,t.typeAnnotation||"coerce");else if(this.checkSubtype(a,f))return null}if(!(s instanceof i3)&&s.type.kind!=="resolvedImage"&&this._isConstant(s)){const a=new qU;try{s=new i3(s.type,s.evaluate(a))}catch(f){return this.error(f.message),null}}return s}return this.error(`Unknown expression "${i}". If you wanted a literal array, use ["literal", [...]].`,0)}else return typeof n>"u"?this.error("'undefined' value invalid. Use null instead."):typeof n=="object"?this.error('Bare objects invalid. Use ["literal", {...}] instead.'):this.error(`Expected an array, but found ${typeof n} instead.`)}concat(n,t,r){const i=typeof n=="number"?this.path.concat(n):this.path,o=r?this.scope.concat(r):this.scope;return new HU(this.registry,this._isConstant,i,t||null,o,this.errors)}error(n,...t){const r=`${this.key}${t.map(i=>`[${i}]`).join("")}`;this.errors.push(new Hh(r,n))}checkSubtype(n,t){const r=n_(n,t);return r&&this.error(r),r}},ZU=class XU{constructor(n,t,r){this.type=Y4,this.locale=r,this.caseSensitive=n,this.diacriticSensitive=t}static parse(n,t){if(n.length!==2)return t.error("Expected one argument.");const r=n[1];if(typeof r!="object"||Array.isArray(r))return t.error("Collator options argument must be an object.");const i=t.parse(r["case-sensitive"]===void 0?!1:r["case-sensitive"],1,Vi);if(!i)return null;const o=t.parse(r["diacritic-sensitive"]===void 0?!1:r["diacritic-sensitive"],1,Vi);if(!o)return null;let s=null;return r.locale&&(s=t.parse(r.locale,1,co),!s)?null:new XU(i,o,s)}evaluate(n){return new mB(this.caseSensitive.evaluate(n),this.diacriticSensitive.evaluate(n),this.locale?this.locale.evaluate(n):null)}eachChild(n){n(this.caseSensitive),n(this.diacriticSensitive),this.locale&&n(this.locale)}outputDefined(){return!1}};const Mm=8192;function gB(e,n){e[0]=Math.min(e[0],n[0]),e[1]=Math.min(e[1],n[1]),e[2]=Math.max(e[2],n[0]),e[3]=Math.max(e[3],n[1])}function eZ(e){return(180+e)/360}function tZ(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function o3(e,n){return!(e[0]<=n[0]||e[2]>=n[2]||e[1]<=n[1]||e[3]>=n[3])}function nZ(e,n){const t=eZ(e[0]),r=tZ(e[1]),i=Math.pow(2,n.z);return[Math.round(t*i*Mm),Math.round(r*i*Mm)]}function rZ(e,n,t){const r=e[0]-n[0],i=e[1]-n[1],o=e[0]-t[0],s=e[1]-t[1];return r*s-o*i===0&&r*o<=0&&i*s<=0}function iZ(e,n,t){return n[1]>e[1]!=t[1]>e[1]&&e[0]<(t[0]-n[0])*(e[1]-n[1])/(t[1]-n[1])+n[0]}function yB(e,n){let t=!1;for(let r=0,i=n.length;r<i;r++){const o=n[r];for(let s=0,a=o.length;s<a-1;s++){if(rZ(e,o[s],o[s+1]))return!1;iZ(e,o[s],o[s+1])&&(t=!t)}}return t}function oZ(e,n){for(let t=0;t<n.length;t++)if(yB(e,n[t]))return!0;return!1}function aZ(e,n){return e[0]*n[1]-e[1]*n[0]}function FI(e,n,t,r){const i=e[0]-t[0],o=e[1]-t[1],s=n[0]-t[0],a=n[1]-t[1],f=r[0]-t[0],g=r[1]-t[1],x=i*g-f*o,k=s*g-f*a;return x>0&&k<0||x<0&&k>0}function sZ(e,n,t,r){const i=[n[0]-e[0],n[1]-e[1]],o=[r[0]-t[0],r[1]-t[1]];return aZ(o,i)===0?!1:!!(FI(e,n,t,r)&&FI(t,r,e,n))}function lZ(e,n,t){for(const r of t)for(let i=0;i<r.length-1;++i)if(sZ(e,n,r[i],r[i+1]))return!0;return!1}function JU(e,n){for(let t=0;t<e.length;++t)if(!yB(e[t],n))return!1;for(let t=0;t<e.length-1;++t)if(lZ(e[t],e[t+1],n))return!1;return!0}function uZ(e,n){for(let t=0;t<n.length;t++)if(JU(e,n[t]))return!0;return!1}function vB(e,n,t){const r=[];for(let i=0;i<e.length;i++){const o=[];for(let s=0;s<e[i].length;s++){const a=nZ(e[i][s],t);gB(n,a),o.push(a)}r.push(o)}return r}function eR(e,n,t){const r=[];for(let i=0;i<e.length;i++){const o=vB(e[i],n,t);r.push(o)}return r}function tR(e,n,t,r){if(e[0]<t[0]||e[0]>t[2]){const i=r*.5;let o=e[0]-t[0]>i?-r:t[0]-e[0]>i?r:0;o===0&&(o=e[0]-t[2]>i?-r:t[2]-e[0]>i?r:0),e[0]+=o}gB(n,e)}function AZ(e){e[0]=e[1]=1/0,e[2]=e[3]=-1/0}function DI(e,n,t,r){const i=Math.pow(2,r.z)*Mm,o=[r.x*Mm,r.y*Mm],s=[];for(const a of e)for(const f of a){const g=[f.x+o[0],f.y+o[1]];tR(g,n,t,i),s.push(g)}return s}function UI(e,n,t,r){const i=Math.pow(2,r.z)*Mm,o=[r.x*Mm,r.y*Mm],s=[];for(const a of e){const f=[];for(const g of a){const x=[g.x+o[0],g.y+o[1]];gB(n,x),f.push(x)}s.push(f)}if(n[2]-n[0]<=i/2){AZ(n);for(const a of s)for(const f of a)tR(f,n,t,i)}return s}function cZ(e,n){const t=[1/0,1/0,-1/0,-1/0],r=[1/0,1/0,-1/0,-1/0],i=e.canonicalID();if(n.type==="Polygon"){const o=vB(n.coordinates,r,i),s=DI(e.geometry(),t,r,i);if(!o3(t,r))return!1;for(const a of s)if(!yB(a,o))return!1}if(n.type==="MultiPolygon"){const o=eR(n.coordinates,r,i),s=DI(e.geometry(),t,r,i);if(!o3(t,r))return!1;for(const a of s)if(!oZ(a,o))return!1}return!0}function dZ(e,n){const t=[1/0,1/0,-1/0,-1/0],r=[1/0,1/0,-1/0,-1/0],i=e.canonicalID();if(n.type==="Polygon"){const o=vB(n.coordinates,r,i),s=UI(e.geometry(),t,r,i);if(!o3(t,r))return!1;for(const a of s)if(!JU(a,o))return!1}if(n.type==="MultiPolygon"){const o=eR(n.coordinates,r,i),s=UI(e.geometry(),t,r,i);if(!o3(t,r))return!1;for(const a of s)if(!uZ(a,o))return!1}return!0}let CB=class f2{constructor(n,t){this.type=Vi,this.geojson=n,this.geometries=t}static parse(n,t){if(n.length!==2)return t.error(`'within' expression requires exactly one argument, but found ${n.length-1} instead.`);if(r3(n[1])){const r=n[1];if(r.type==="FeatureCollection"){const i=[];for(const o of r.features){const{type:s,coordinates:a}=o.geometry;s==="Polygon"&&i.push(a),s==="MultiPolygon"&&i.push(...a)}if(i.length){const o={type:"MultiPolygon",coordinates:i};return new f2(r,o)}}else if(r.type==="Feature"){const i=r.geometry.type;if(i==="Polygon"||i==="MultiPolygon")return new f2(r,r.geometry)}else if(r.type==="Polygon"||r.type==="MultiPolygon")return new f2(r,r)}return t.error("'within' expression requires valid geojson object that contains polygon geometry type.")}evaluate(n){if(n.geometry()!=null&&n.canonicalID()!=null){if(n.geometryType()==="Point")return cZ(n,this.geometries);if(n.geometryType()==="LineString")return dZ(n,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}},nR=class rR{constructor(n,t){this.type=t.type,this.name=n,this.boundExpression=t}static parse(n,t){if(n.length!==2||typeof n[1]!="string")return t.error("'var' expression requires exactly one string literal argument.");const r=n[1];return t.scope.has(r)?new rR(r,t.scope.get(r)):t.error(`Unknown variable "${r}". Make sure "${r}" has been bound in an enclosing "let" expression before using it.`,1)}evaluate(n){return this.boundExpression.evaluate(n)}eachChild(){}outputDefined(){return!1}},Uy=class oC{constructor(n,t,r,i){this.name=n,this.type=t,this._evaluate=r,this.args=i}evaluate(n){return this._evaluate(n,this.args)}eachChild(n){this.args.forEach(n)}outputDefined(){return!1}static parse(n,t){const r=n[0],i=oC.definitions[r];if(!i)return t.error(`Unknown expression "${r}". If you wanted a literal array, use ["literal", [...]].`,0);const o=Array.isArray(i)?i[0]:i.type,s=Array.isArray(i)?[[i[1],i[2]]]:i.overloads,a=s.filter(([g])=>!Array.isArray(g)||g.length===n.length-1);let f=null;for(const[g,x]of a){f=new VU(t.registry,a3,t.path,null,t.scope);const k=[];let B=!1;for(let P=1;P<n.length;P++){const R=n[P],H=Array.isArray(g)?g[P-1]:g.type,W=f.parse(R,1+k.length,H);if(!W){B=!0;break}k.push(W)}if(!B){if(Array.isArray(g)&&g.length!==k.length){f.error(`Expected ${g.length} arguments, but found ${k.length} instead.`);continue}for(let P=0;P<k.length;P++){const R=Array.isArray(g)?g[P]:g.type,H=k[P];f.concat(P+1).checkSubtype(R,H.type)}if(f.errors.length===0)return new oC(r,o,x,k)}}if(a.length===1)t.errors.push(...f.errors);else{const x=(a.length?a:s).map(([B])=>hZ(B)).join(" | "),k=[];for(let B=1;B<n.length;B++){const P=t.parse(n[B],1+k.length);if(!P)return null;k.push(fs(P.type))}t.error(`Expected arguments of type ${x}, but found (${k.join(", ")}) instead.`)}return null}static register(n,t){oC.definitions=t;for(const r in t)n[r]=oC}};function hZ(e){return Array.isArray(e)?`(${e.map(fs).join(", ")})`:`(${fs(e.type)}...)`}function a3(e){if(e instanceof nR)return a3(e.boundExpression);if(e instanceof Uy&&e.name==="error")return!1;if(e instanceof ZU)return!1;if(e instanceof CB)return!1;const n=e instanceof Fg||e instanceof fp;let t=!0;return e.eachChild(r=>{n?t=t&&a3(r):t=t&&r instanceof i3}),t?Z4(e)&&X4(e,["zoom","heatmap-density","line-progress","accumulated","is-supported-script"]):!1}function Z4(e){if(e instanceof Uy){if(e.name==="get"&&e.args.length===1)return!1;if(e.name==="feature-state")return!1;if(e.name==="has"&&e.args.length===1)return!1;if(e.name==="properties"||e.name==="geometry-type"||e.name==="id")return!1;if(/^filter-/.test(e.name))return!1}if(e instanceof CB)return!1;let n=!0;return e.eachChild(t=>{n&&!Z4(t)&&(n=!1)}),n}function i_(e){if(e instanceof Uy&&e.name==="feature-state")return!1;let n=!0;return e.eachChild(t=>{n&&!i_(t)&&(n=!1)}),n}function X4(e,n){if(e instanceof Uy&&n.indexOf(e.name)>=0)return!1;let t=!0;return e.eachChild(r=>{t&&!X4(r,n)&&(t=!1)}),t}function J4(e,n){const t=e.length-1;let r=0,i=t,o=0,s,a;for(;r<=i;)if(o=Math.floor((r+i)/2),s=e[o],a=e[o+1],s<=n){if(o===t||n<a)return o;r=o+1}else if(s>n)i=o-1;else throw new sl("Input is not a number.");return 0}let iR=class oR{constructor(n,t,r){this.type=n,this.input=t,this.labels=[],this.outputs=[];for(const[i,o]of r)this.labels.push(i),this.outputs.push(o)}static parse(n,t){if(n.length-1<4)return t.error(`Expected at least 4 arguments, but found only ${n.length-1}.`);if((n.length-1)%2!==0)return t.error("Expected an even number of arguments.");const r=t.parse(n[1],1,tr);if(!r)return null;const i=[];let o=null;t.expectedType&&t.expectedType.kind!=="value"&&(o=t.expectedType);for(let s=1;s<n.length;s+=2){const a=s===1?-1/0:n[s],f=n[s+1],g=s,x=s+1;if(typeof a!="number")return t.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',g);if(i.length&&i[i.length-1][0]>=a)return t.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',g);const k=t.parse(f,x,o);if(!k)return null;o=o||k.type,i.push([a,k])}return new oR(o,r,i)}evaluate(n){const t=this.labels,r=this.outputs;if(t.length===1)return r[0].evaluate(n);const i=this.input.evaluate(n);if(i<=t[0])return r[0].evaluate(n);const o=t.length;if(i>=t[o-1])return r[o-1].evaluate(n);const s=J4(t,i);return r[s].evaluate(n)}eachChild(n){n(this.input);for(const t of this.outputs)n(t)}outputDefined(){return this.outputs.every(n=>n.outputDefined())}};function fZ(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var pZ=aR;function aR(e,n,t,r){this.cx=3*e,this.bx=3*(t-e)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*n,this.by=3*(r-n)-this.cy,this.ay=1-this.cy-this.by,this.p1x=e,this.p1y=n,this.p2x=t,this.p2y=r}aR.prototype={sampleCurveX:function(e){return((this.ax*e+this.bx)*e+this.cx)*e},sampleCurveY:function(e){return((this.ay*e+this.by)*e+this.cy)*e},sampleCurveDerivativeX:function(e){return(3*this.ax*e+2*this.bx)*e+this.cx},solveCurveX:function(e,n){if(n===void 0&&(n=1e-6),e<0)return 0;if(e>1)return 1;for(var t=e,r=0;r<8;r++){var i=this.sampleCurveX(t)-e;if(Math.abs(i)<n)return t;var o=this.sampleCurveDerivativeX(t);if(Math.abs(o)<1e-6)break;t=t-i/o}var s=0,a=1;for(t=e,r=0;r<20&&(i=this.sampleCurveX(t),!(Math.abs(i-e)<n));r++)e>i?s=t:a=t,t=(a-s)*.5+s;return t},solve:function(e,n){return this.sampleCurveY(this.solveCurveX(e,n))}};var mZ=fZ(pZ);function gZ(e){return e==="rgb"||e==="hcl"||e==="lab"}function Z0(e,n,t){return e+t*(n-e)}function yZ(e,n,t,r="rgb"){switch(r){case"rgb":{const[i,o,s,a]=s3(e.rgb,n.rgb,t);return new ms(i,o,s,a,!1)}case"hcl":{const[i,o,s,a]=e.hcl,[f,g,x,k]=n.hcl;let B,P;if(!isNaN(i)&&!isNaN(f)){let q=f-i;f>i&&q>180?q-=360:f<i&&i-f>180&&(q+=360),B=i+t*q}else isNaN(i)?isNaN(f)?B=NaN:(B=f,(s===1||s===0)&&(P=g)):(B=i,(x===1||x===0)&&(P=o));const[R,H,W,$]=qH([B,P??Z0(o,g,t),Z0(s,x,t),Z0(a,k,t)]);return new ms(R,H,W,$,!1)}case"lab":{const[i,o,s,a]=WU(s3(e.lab,n.lab,t));return new ms(i,o,s,a,!1)}}}function s3(e,n,t){return e.map((r,i)=>Z0(r,n[i],t))}function vZ(e,n,t){return new jc(s3(e.values,n.values,t))}function CZ(e,n,t){const r=e.values,i=n.values;if(r.length!==i.length)throw new sl(`Cannot interpolate values of different length. from: ${e.toString()}, to: ${n.toString()}`);const o=[];for(let s=0;s<r.length;s+=2){if(r[s]!==i[s])throw new sl(`Cannot interpolate values containing mismatched anchors. from[${s}]: ${r[s]}, to[${s}]: ${i[s]}`);o.push(r[s]);const[a,f]=r[s+1],[g,x]=i[s+1];o.push([Z0(a,g,t),Z0(f,x,t)])}return new uf(o)}const p2={number:Z0,color:yZ,array:s3,padding:vZ,variableAnchorOffsetCollection:CZ};let Cp=class y6{constructor(n,t,r,i,o){this.type=n,this.operator=t,this.interpolation=r,this.input=i,this.labels=[],this.outputs=[];for(const[s,a]of o)this.labels.push(s),this.outputs.push(a)}static interpolationFactor(n,t,r,i){let o=0;if(n.name==="exponential")o=nM(t,n.base,r,i);else if(n.name==="linear")o=nM(t,1,r,i);else if(n.name==="cubic-bezier"){const s=n.controlPoints;o=new mZ(s[0],s[1],s[2],s[3]).solve(nM(t,1,r,i))}return o}static parse(n,t){let[r,i,o,...s]=n;if(!Array.isArray(i)||i.length===0)return t.error("Expected an interpolation type expression.",1);if(i[0]==="linear")i={name:"linear"};else if(i[0]==="exponential"){const g=i[1];if(typeof g!="number")return t.error("Exponential interpolation requires a numeric base.",1,1);i={name:"exponential",base:g}}else if(i[0]==="cubic-bezier"){const g=i.slice(1);if(g.length!==4||g.some(x=>typeof x!="number"||x<0||x>1))return t.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);i={name:"cubic-bezier",controlPoints:g}}else return t.error(`Unknown interpolation type ${String(i[0])}`,1,0);if(n.length-1<4)return t.error(`Expected at least 4 arguments, but found only ${n.length-1}.`);if((n.length-1)%2!==0)return t.error("Expected an even number of arguments.");if(o=t.parse(o,2,tr),!o)return null;const a=[];let f=null;r==="interpolate-hcl"||r==="interpolate-lab"?f=af:t.expectedType&&t.expectedType.kind!=="value"&&(f=t.expectedType);for(let g=0;g<s.length;g+=2){const x=s[g],k=s[g+1],B=g+3,P=g+4;if(typeof x!="number")return t.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',B);if(a.length&&a[a.length-1][0]>=x)return t.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',B);const R=t.parse(k,P,f);if(!R)return null;f=f||R.type,a.push([x,R])}return!zv(f,tr)&&!zv(f,af)&&!zv(f,V4)&&!zv(f,H4)&&!zv(f,Pc(tr))?t.error(`Type ${fs(f)} is not interpolatable.`):new y6(f,r,i,o,a)}evaluate(n){const t=this.labels,r=this.outputs;if(t.length===1)return r[0].evaluate(n);const i=this.input.evaluate(n);if(i<=t[0])return r[0].evaluate(n);const o=t.length;if(i>=t[o-1])return r[o-1].evaluate(n);const s=J4(t,i),a=t[s],f=t[s+1],g=y6.interpolationFactor(this.interpolation,i,a,f),x=r[s].evaluate(n),k=r[s+1].evaluate(n);switch(this.operator){case"interpolate":return p2[this.type.kind](x,k,g);case"interpolate-hcl":return p2.color(x,k,g,"hcl");case"interpolate-lab":return p2.color(x,k,g,"lab")}}eachChild(n){n(this.input);for(const t of this.outputs)n(t)}outputDefined(){return this.outputs.every(n=>n.outputDefined())}};function nM(e,n,t,r){const i=r-t,o=e-t;return i===0?0:n===1?o/i:(Math.pow(n,o)-1)/(Math.pow(n,i)-1)}let sR=class v6{constructor(n,t){this.type=n,this.args=t}static parse(n,t){if(n.length<2)return t.error("Expectected at least one argument.");let r=null;const i=t.expectedType;i&&i.kind!=="value"&&(r=i);const o=[];for(const a of n.slice(1)){const f=t.parse(a,1+o.length,r,void 0,{typeAnnotation:"omit"});if(!f)return null;r=r||f.type,o.push(f)}if(!r)throw new Error("No output type");return i&&o.some(a=>n_(i,a.type))?new v6(Zi,o):new v6(r,o)}evaluate(n){let t=null,r=0,i;for(const o of this.args)if(r++,t=o.evaluate(n),t&&t instanceof C1&&!t.available&&(i||(i=t.name),t=null,r===this.args.length&&(t=i)),t!==null)break;return t}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}},lR=class uR{constructor(n,t){this.type=t.type,this.bindings=[].concat(n),this.result=t}evaluate(n){return this.result.evaluate(n)}eachChild(n){for(const t of this.bindings)n(t[1]);n(this.result)}static parse(n,t){if(n.length<4)return t.error(`Expected at least 3 arguments, but found ${n.length-1} instead.`);const r=[];for(let o=1;o<n.length-1;o+=2){const s=n[o];if(typeof s!="string")return t.error(`Expected string, but found ${typeof s} instead.`,o);if(/[^a-zA-Z0-9_]/.test(s))return t.error("Variable names must contain only alphanumeric characters or '_'.",o);const a=t.parse(n[o+1],o+1);if(!a)return null;r.push([s,a])}const i=t.parse(n[n.length-1],n.length-1,t.expectedType,r);return i?new uR(r,i):null}outputDefined(){return this.result.outputDefined()}},_Z=class AR{constructor(n,t,r){this.type=n,this.index=t,this.input=r}static parse(n,t){if(n.length!==3)return t.error(`Expected 2 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,tr),i=t.parse(n[2],2,Pc(t.expectedType||Zi));if(!r||!i)return null;const o=i.type;return new AR(o.itemType,r,i)}evaluate(n){const t=this.index.evaluate(n),r=this.input.evaluate(n);if(t<0)throw new sl(`Array index out of bounds: ${t} < 0.`);if(t>=r.length)throw new sl(`Array index out of bounds: ${t} > ${r.length-1}.`);if(t!==Math.floor(t))throw new sl(`Array index must be an integer, but found ${t} instead.`);return r[t]}eachChild(n){n(this.index),n(this.input)}outputDefined(){return!1}},bZ=class cR{constructor(n,t){this.type=Vi,this.needle=n,this.haystack=t}static parse(n,t){if(n.length!==3)return t.error(`Expected 2 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Zi),i=t.parse(n[2],2,Zi);return!r||!i?null:pB(r.type,[Vi,co,tr,$4,Zi])?new cR(r,i):t.error(`Expected first argument to be of type boolean, string, number or null, but found ${fs(r.type)} instead`)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(!r)return!1;if(!r_(t,["boolean","string","number","null"]))throw new sl(`Expected first argument to be of type boolean, string, number or null, but found ${fs(jl(t))} instead.`);if(!r_(r,["string","array"]))throw new sl(`Expected second argument to be of type array or string, but found ${fs(jl(r))} instead.`);return r.indexOf(t)>=0}eachChild(n){n(this.needle),n(this.haystack)}outputDefined(){return!0}},xZ=class C6{constructor(n,t,r){this.type=tr,this.needle=n,this.haystack=t,this.fromIndex=r}static parse(n,t){if(n.length<=2||n.length>=5)return t.error(`Expected 3 or 4 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Zi),i=t.parse(n[2],2,Zi);if(!r||!i)return null;if(!pB(r.type,[Vi,co,tr,$4,Zi]))return t.error(`Expected first argument to be of type boolean, string, number or null, but found ${fs(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,tr);return o?new C6(r,i,o):null}else return new C6(r,i)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(!r_(t,["boolean","string","number","null"]))throw new sl(`Expected first argument to be of type boolean, string, number or null, but found ${fs(jl(t))} instead.`);if(!r_(r,["string","array"]))throw new sl(`Expected second argument to be of type array or string, but found ${fs(jl(r))} instead.`);if(this.fromIndex){const i=this.fromIndex.evaluate(n);return r.indexOf(t,i)}return r.indexOf(t)}eachChild(n){n(this.needle),n(this.haystack),this.fromIndex&&n(this.fromIndex)}outputDefined(){return!1}},wZ=class dR{constructor(n,t,r,i,o,s){this.inputType=n,this.type=t,this.input=r,this.cases=i,this.outputs=o,this.otherwise=s}static parse(n,t){if(n.length<5)return t.error(`Expected at least 4 arguments, but found only ${n.length-1}.`);if(n.length%2!==1)return t.error("Expected an even number of arguments.");let r,i;t.expectedType&&t.expectedType.kind!=="value"&&(i=t.expectedType);const o={},s=[];for(let g=2;g<n.length-1;g+=2){let x=n[g];const k=n[g+1];Array.isArray(x)||(x=[x]);const B=t.concat(g);if(x.length===0)return B.error("Expected at least one branch label.");for(const R of x){if(typeof R!="number"&&typeof R!="string")return B.error("Branch labels must be numbers or strings.");if(typeof R=="number"&&Math.abs(R)>Number.MAX_SAFE_INTEGER)return B.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof R=="number"&&Math.floor(R)!==R)return B.error("Numeric branch labels must be integer values.");if(!r)r=jl(R);else if(B.checkSubtype(r,jl(R)))return null;if(typeof o[String(R)]<"u")return B.error("Branch labels must be unique.");o[String(R)]=s.length}const P=t.parse(k,g,i);if(!P)return null;i=i||P.type,s.push(P)}const a=t.parse(n[1],1,Zi);if(!a)return null;const f=t.parse(n[n.length-1],n.length-1,i);return!f||a.type.kind!=="value"&&t.concat(1).checkSubtype(r,a.type)?null:new dR(r,i,a,o,s,f)}evaluate(n){const t=this.input.evaluate(n);return(jl(t)===this.inputType&&this.outputs[this.cases[t]]||this.otherwise).evaluate(n)}eachChild(n){n(this.input),this.outputs.forEach(n),n(this.otherwise)}outputDefined(){return this.outputs.every(n=>n.outputDefined())&&this.otherwise.outputDefined()}},MZ=class hR{constructor(n,t,r){this.type=n,this.branches=t,this.otherwise=r}static parse(n,t){if(n.length<4)return t.error(`Expected at least 3 arguments, but found only ${n.length-1}.`);if(n.length%2!==0)return t.error("Expected an odd number of arguments.");let r;t.expectedType&&t.expectedType.kind!=="value"&&(r=t.expectedType);const i=[];for(let s=1;s<n.length-1;s+=2){const a=t.parse(n[s],s,Vi);if(!a)return null;const f=t.parse(n[s+1],s+1,r);if(!f)return null;i.push([a,f]),r=r||f.type}const o=t.parse(n[n.length-1],n.length-1,r);if(!o)return null;if(!r)throw new Error("Can't infer output type");return new hR(r,i,o)}evaluate(n){for(const[t,r]of this.branches)if(t.evaluate(n))return r.evaluate(n);return this.otherwise.evaluate(n)}eachChild(n){for(const[t,r]of this.branches)n(t),n(r);n(this.otherwise)}outputDefined(){return this.branches.every(([n,t])=>t.outputDefined())&&this.otherwise.outputDefined()}},SZ=class _6{constructor(n,t,r,i){this.type=n,this.input=t,this.beginIndex=r,this.endIndex=i}static parse(n,t){if(n.length<=2||n.length>=5)return t.error(`Expected 3 or 4 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Zi),i=t.parse(n[2],2,tr);if(!r||!i)return null;if(!pB(r.type,[Pc(Zi),co,Zi]))return t.error(`Expected first argument to be of type array or string, but found ${fs(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,tr);return o?new _6(r.type,r,i,o):null}else return new _6(r.type,r,i)}evaluate(n){const t=this.input.evaluate(n),r=this.beginIndex.evaluate(n);if(!r_(t,["string","array"]))throw new sl(`Expected first argument to be of type array or string, but found ${fs(jl(t))} instead.`);if(this.endIndex){const i=this.endIndex.evaluate(n);return t.slice(r,i)}return t.slice(r)}eachChild(n){n(this.input),n(this.beginIndex),this.endIndex&&n(this.endIndex)}outputDefined(){return!1}};function RI(e,n){return e==="=="||e==="!="?n.kind==="boolean"||n.kind==="string"||n.kind==="number"||n.kind==="null"||n.kind==="value":n.kind==="string"||n.kind==="number"||n.kind==="value"}function EZ(e,n,t){return n===t}function OZ(e,n,t){return n!==t}function BZ(e,n,t){return n<t}function kZ(e,n,t){return n>t}function IZ(e,n,t){return n<=t}function TZ(e,n,t){return n>=t}function fR(e,n,t,r){return r.compare(n,t)===0}function KZ(e,n,t,r){return!fR(e,n,t,r)}function PZ(e,n,t,r){return r.compare(n,t)<0}function FZ(e,n,t,r){return r.compare(n,t)>0}function DZ(e,n,t,r){return r.compare(n,t)<=0}function UZ(e,n,t,r){return r.compare(n,t)>=0}function Ry(e,n,t){const r=e!=="=="&&e!=="!=";return class pR{constructor(o,s,a){this.type=Vi,this.lhs=o,this.rhs=s,this.collator=a,this.hasUntypedArgument=o.type.kind==="value"||s.type.kind==="value"}static parse(o,s){if(o.length!==3&&o.length!==4)return s.error("Expected two or three arguments.");const a=o[0];let f=s.parse(o[1],1,Zi);if(!f)return null;if(!RI(a,f.type))return s.concat(1).error(`"${a}" comparisons are not supported for type '${fs(f.type)}'.`);let g=s.parse(o[2],2,Zi);if(!g)return null;if(!RI(a,g.type))return s.concat(2).error(`"${a}" comparisons are not supported for type '${fs(g.type)}'.`);if(f.type.kind!==g.type.kind&&f.type.kind!=="value"&&g.type.kind!=="value")return s.error(`Cannot compare types '${fs(f.type)}' and '${fs(g.type)}'.`);r&&(f.type.kind==="value"&&g.type.kind!=="value"?f=new fp(g.type,[f]):f.type.kind!=="value"&&g.type.kind==="value"&&(g=new fp(f.type,[g])));let x=null;if(o.length===4){if(f.type.kind!=="string"&&g.type.kind!=="string"&&f.type.kind!=="value"&&g.type.kind!=="value")return s.error("Cannot use collator to compare non-string types.");if(x=s.parse(o[3],3,Y4),!x)return null}return new pR(f,g,x)}evaluate(o){const s=this.lhs.evaluate(o),a=this.rhs.evaluate(o);if(r&&this.hasUntypedArgument){const f=jl(s),g=jl(a);if(f.kind!==g.kind||!(f.kind==="string"||f.kind==="number"))throw new sl(`Expected arguments for "${e}" to be (string, string) or (number, number), but found (${f.kind}, ${g.kind}) instead.`)}if(this.collator&&!r&&this.hasUntypedArgument){const f=jl(s),g=jl(a);if(f.kind!=="string"||g.kind!=="string")return n(o,s,a)}return this.collator?t(o,s,a,this.collator.evaluate(o)):n(o,s,a)}eachChild(o){o(this.lhs),o(this.rhs),this.collator&&o(this.collator)}outputDefined(){return!0}}}const RZ=Ry("==",EZ,fR),LZ=Ry("!=",OZ,KZ),zZ=Ry("<",BZ,PZ),jZ=Ry(">",kZ,FZ),WZ=Ry("<=",IZ,DZ),NZ=Ry(">=",TZ,UZ);let GZ=class mR{constructor(n,t,r,i,o){this.type=co,this.number=n,this.locale=t,this.currency=r,this.minFractionDigits=i,this.maxFractionDigits=o}static parse(n,t){if(n.length!==3)return t.error("Expected two arguments.");const r=t.parse(n[1],1,tr);if(!r)return null;const i=n[2];if(typeof i!="object"||Array.isArray(i))return t.error("NumberFormat options argument must be an object.");let o=null;if(i.locale&&(o=t.parse(i.locale,1,co),!o))return null;let s=null;if(i.currency&&(s=t.parse(i.currency,1,co),!s))return null;let a=null;if(i["min-fraction-digits"]&&(a=t.parse(i["min-fraction-digits"],1,tr),!a))return null;let f=null;return i["max-fraction-digits"]&&(f=t.parse(i["max-fraction-digits"],1,tr),!f)?null:new mR(r,o,s,a,f)}evaluate(n){return new Intl.NumberFormat(this.locale?this.locale.evaluate(n):[],{style:this.currency?"currency":"decimal",currency:this.currency?this.currency.evaluate(n):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(n):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(n):void 0}).format(this.number.evaluate(n))}eachChild(n){n(this.number),this.locale&&n(this.locale),this.currency&&n(this.currency),this.minFractionDigits&&n(this.minFractionDigits),this.maxFractionDigits&&n(this.maxFractionDigits)}outputDefined(){return!1}},QZ=class gR{constructor(n){this.type=q4,this.sections=n}static parse(n,t){if(n.length<2)return t.error("Expected at least one argument.");const r=n[1];if(!Array.isArray(r)&&typeof r=="object")return t.error("First argument must be an image or text section.");const i=[];let o=!1;for(let s=1;s<=n.length-1;++s){const a=n[s];if(o&&typeof a=="object"&&!Array.isArray(a)){o=!1;let f=null;if(a["font-scale"]&&(f=t.parse(a["font-scale"],1,tr),!f))return null;let g=null;if(a["text-font"]&&(g=t.parse(a["text-font"],1,Pc(co)),!g))return null;let x=null;if(a["text-color"]&&(x=t.parse(a["text-color"],1,af),!x))return null;const k=i[i.length-1];k.scale=f,k.font=g,k.textColor=x}else{const f=t.parse(n[s],1,Zi);if(!f)return null;const g=f.type.kind;if(g!=="string"&&g!=="value"&&g!=="null"&&g!=="resolvedImage")return t.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");o=!0,i.push({content:f,scale:null,font:null,textColor:null})}}return new gR(i)}evaluate(n){const t=r=>{const i=r.content.evaluate(n);return jl(i)===z_?new g6("",i,null,null,null):new g6(SC(i),null,r.scale?r.scale.evaluate(n):null,r.font?r.font.evaluate(n).join(","):null,r.textColor?r.textColor.evaluate(n):null)};return new Dy(this.sections.map(t))}eachChild(n){for(const t of this.sections)n(t.content),t.scale&&n(t.scale),t.font&&n(t.font),t.textColor&&n(t.textColor)}outputDefined(){return!1}},$Z=class yR{constructor(n){this.type=z_,this.input=n}static parse(n,t){if(n.length!==2)return t.error("Expected two arguments.");const r=t.parse(n[1],1,co);return r?new yR(r):t.error("No image name provided.")}evaluate(n){const t=this.input.evaluate(n),r=C1.fromString(t);return r&&n.availableImages&&(r.available=n.availableImages.indexOf(t)>-1),r}eachChild(n){n(this.input)}outputDefined(){return!1}},YZ=class vR{constructor(n){this.type=tr,this.input=n}static parse(n,t){if(n.length!==2)return t.error(`Expected 1 argument, but found ${n.length-1} instead.`);const r=t.parse(n[1],1);return r?r.type.kind!=="array"&&r.type.kind!=="string"&&r.type.kind!=="value"?t.error(`Expected argument of type string or array, but found ${fs(r.type)} instead.`):new vR(r):null}evaluate(n){const t=this.input.evaluate(n);if(typeof t=="string")return t.length;if(Array.isArray(t))return t.length;throw new sl(`Expected value to be of type string or array, but found ${fs(jl(t))} instead.`)}eachChild(n){n(this.input)}outputDefined(){return!1}};const _B={"==":RZ,"!=":LZ,">":jZ,"<":zZ,">=":NZ,"<=":WZ,array:fp,at:_Z,boolean:fp,case:MZ,coalesce:sR,collator:ZU,format:QZ,image:$Z,in:bZ,"index-of":xZ,interpolate:Cp,"interpolate-hcl":Cp,"interpolate-lab":Cp,length:YZ,let:lR,literal:i3,match:wZ,number:fp,"number-format":GZ,object:fp,slice:SZ,step:iR,string:fp,"to-boolean":Fg,"to-color":Fg,"to-number":Fg,"to-string":Fg,var:nR,within:CB};function LI(e,[n,t,r,i]){n=n.evaluate(e),t=t.evaluate(e),r=r.evaluate(e);const o=i?i.evaluate(e):1,s=GU(n,t,r,o);if(s)throw new sl(s);return new ms(n/255,t/255,r/255,o,!1)}function zI(e,n){return e in n}function rM(e,n){const t=n[e];return typeof t>"u"?null:t}function qZ(e,n,t,r){for(;t<=r;){const i=t+r>>1;if(n[i]===e)return!0;n[i]>e?r=i-1:t=i+1}return!1}function m0(e){return{type:e}}Uy.register(_B,{error:[WH,[co],(e,[n])=>{throw new sl(n.evaluate(e))}],typeof:[co,[Zi],(e,[n])=>fs(jl(n.evaluate(e)))],"to-rgba":[Pc(tr,4),[af],(e,[n])=>{const[t,r,i,o]=n.evaluate(e).rgb;return[t*255,r*255,i*255,o]}],rgb:[af,[tr,tr,tr],LI],rgba:[af,[tr,tr,tr,tr],LI],has:{type:Vi,overloads:[[[co],(e,[n])=>zI(n.evaluate(e),e.properties())],[[co,Zg],(e,[n,t])=>zI(n.evaluate(e),t.evaluate(e))]]},get:{type:Zi,overloads:[[[co],(e,[n])=>rM(n.evaluate(e),e.properties())],[[co,Zg],(e,[n,t])=>rM(n.evaluate(e),t.evaluate(e))]]},"feature-state":[Zi,[co],(e,[n])=>rM(n.evaluate(e),e.featureState||{})],properties:[Zg,[],e=>e.properties()],"geometry-type":[co,[],e=>e.geometryType()],id:[Zi,[],e=>e.id()],zoom:[tr,[],e=>e.globals.zoom],"heatmap-density":[tr,[],e=>e.globals.heatmapDensity||0],"line-progress":[tr,[],e=>e.globals.lineProgress||0],accumulated:[Zi,[],e=>e.globals.accumulated===void 0?null:e.globals.accumulated],"+":[tr,m0(tr),(e,n)=>{let t=0;for(const r of n)t+=r.evaluate(e);return t}],"*":[tr,m0(tr),(e,n)=>{let t=1;for(const r of n)t*=r.evaluate(e);return t}],"-":{type:tr,overloads:[[[tr,tr],(e,[n,t])=>n.evaluate(e)-t.evaluate(e)],[[tr],(e,[n])=>-n.evaluate(e)]]},"/":[tr,[tr,tr],(e,[n,t])=>n.evaluate(e)/t.evaluate(e)],"%":[tr,[tr,tr],(e,[n,t])=>n.evaluate(e)%t.evaluate(e)],ln2:[tr,[],()=>Math.LN2],pi:[tr,[],()=>Math.PI],e:[tr,[],()=>Math.E],"^":[tr,[tr,tr],(e,[n,t])=>Math.pow(n.evaluate(e),t.evaluate(e))],sqrt:[tr,[tr],(e,[n])=>Math.sqrt(n.evaluate(e))],log10:[tr,[tr],(e,[n])=>Math.log(n.evaluate(e))/Math.LN10],ln:[tr,[tr],(e,[n])=>Math.log(n.evaluate(e))],log2:[tr,[tr],(e,[n])=>Math.log(n.evaluate(e))/Math.LN2],sin:[tr,[tr],(e,[n])=>Math.sin(n.evaluate(e))],cos:[tr,[tr],(e,[n])=>Math.cos(n.evaluate(e))],tan:[tr,[tr],(e,[n])=>Math.tan(n.evaluate(e))],asin:[tr,[tr],(e,[n])=>Math.asin(n.evaluate(e))],acos:[tr,[tr],(e,[n])=>Math.acos(n.evaluate(e))],atan:[tr,[tr],(e,[n])=>Math.atan(n.evaluate(e))],min:[tr,m0(tr),(e,n)=>Math.min(...n.map(t=>t.evaluate(e)))],max:[tr,m0(tr),(e,n)=>Math.max(...n.map(t=>t.evaluate(e)))],abs:[tr,[tr],(e,[n])=>Math.abs(n.evaluate(e))],round:[tr,[tr],(e,[n])=>{const t=n.evaluate(e);return t<0?-Math.round(-t):Math.round(t)}],floor:[tr,[tr],(e,[n])=>Math.floor(n.evaluate(e))],ceil:[tr,[tr],(e,[n])=>Math.ceil(n.evaluate(e))],"filter-==":[Vi,[co,Zi],(e,[n,t])=>e.properties()[n.value]===t.value],"filter-id-==":[Vi,[Zi],(e,[n])=>e.id()===n.value],"filter-type-==":[Vi,[co],(e,[n])=>e.geometryType()===n.value],"filter-<":[Vi,[co,Zi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<i}],"filter-id-<":[Vi,[Zi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<r}],"filter->":[Vi,[co,Zi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>i}],"filter-id->":[Vi,[Zi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>r}],"filter-<=":[Vi,[co,Zi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<=i}],"filter-id-<=":[Vi,[Zi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<=r}],"filter->=":[Vi,[co,Zi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>=i}],"filter-id->=":[Vi,[Zi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>=r}],"filter-has":[Vi,[Zi],(e,[n])=>n.value in e.properties()],"filter-has-id":[Vi,[],e=>e.id()!==null&&e.id()!==void 0],"filter-type-in":[Vi,[Pc(co)],(e,[n])=>n.value.indexOf(e.geometryType())>=0],"filter-id-in":[Vi,[Pc(Zi)],(e,[n])=>n.value.indexOf(e.id())>=0],"filter-in-small":[Vi,[co,Pc(Zi)],(e,[n,t])=>t.value.indexOf(e.properties()[n.value])>=0],"filter-in-large":[Vi,[co,Pc(Zi)],(e,[n,t])=>qZ(e.properties()[n.value],t.value,0,t.value.length-1)],all:{type:Vi,overloads:[[[Vi,Vi],(e,[n,t])=>n.evaluate(e)&&t.evaluate(e)],[m0(Vi),(e,n)=>{for(const t of n)if(!t.evaluate(e))return!1;return!0}]]},any:{type:Vi,overloads:[[[Vi,Vi],(e,[n,t])=>n.evaluate(e)||t.evaluate(e)],[m0(Vi),(e,n)=>{for(const t of n)if(t.evaluate(e))return!0;return!1}]]},"!":[Vi,[Vi],(e,[n])=>!n.evaluate(e)],"is-supported-script":[Vi,[co],(e,[n])=>{const t=e.globals&&e.globals.isSupportedScript;return t?t(n.evaluate(e)):!0}],upcase:[co,[co],(e,[n])=>n.evaluate(e).toUpperCase()],downcase:[co,[co],(e,[n])=>n.evaluate(e).toLowerCase()],concat:[co,m0(Zi),(e,n)=>n.map(t=>SC(t.evaluate(e))).join("")],"resolved-locale":[co,[Y4],(e,[n])=>n.evaluate(e).resolvedLocale()]});function b6(e){return{result:"success",value:e}}function yg(e){return{result:"error",value:e}}function l3(e){return e["property-type"]==="data-driven"||e["property-type"]==="cross-faded-data-driven"}function CR(e){return!!e.expression&&e.expression.parameters.indexOf("zoom")>-1}function bB(e){return!!e.expression&&e.expression.interpolated}function Do(e){return e instanceof Number?"number":e instanceof String?"string":e instanceof Boolean?"boolean":Array.isArray(e)?"array":e===null?"null":typeof e}function j_(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function VZ(e){return e}function xB(e,n){const t=n.type==="color",r=e.stops&&typeof e.stops[0][0]=="object",i=r||e.property!==void 0,o=r||!i,s=e.type||(bB(n)?"exponential":"interval");if(t||n.type==="padding"){const x=t?ms.parse:jc.parse;e=_y({},e),e.stops&&(e.stops=e.stops.map(k=>[k[0],x(k[1])])),e.default?e.default=x(e.default):e.default=x(n.default)}if(e.colorSpace&&!gZ(e.colorSpace))throw new Error(`Unknown color space: "${e.colorSpace}"`);let a,f,g;if(s==="exponential")a=jI;else if(s==="interval")a=ZZ;else if(s==="categorical"){a=HZ,f=Object.create(null);for(const x of e.stops)f[x[0]]=x[1];g=typeof e.stops[0][0]}else if(s==="identity")a=XZ;else throw new Error(`Unknown function type "${s}"`);if(r){const x={},k=[];for(let R=0;R<e.stops.length;R++){const H=e.stops[R],W=H[0].zoom;x[W]===void 0&&(x[W]={zoom:W,type:e.type,property:e.property,default:e.default,stops:[]},k.push(W)),x[W].stops.push([H[0].value,H[1]])}const B=[];for(const R of k)B.push([x[R].zoom,xB(x[R],n)]);const P={name:"linear"};return{kind:"composite",interpolationType:P,interpolationFactor:Cp.interpolationFactor.bind(void 0,P),zoomStops:B.map(R=>R[0]),evaluate({zoom:R},H){return jI({stops:B,base:e.base},n,R).evaluate(R,H)}}}else if(o){const x=s==="exponential"?{name:"exponential",base:e.base!==void 0?e.base:1}:null;return{kind:"camera",interpolationType:x,interpolationFactor:Cp.interpolationFactor.bind(void 0,x),zoomStops:e.stops.map(k=>k[0]),evaluate:({zoom:k})=>a(e,n,k,f,g)}}else return{kind:"source",evaluate(x,k){const B=k&&k.properties?k.properties[e.property]:void 0;return B===void 0?W_(e.default,n.default):a(e,n,B,f,g)}}}function W_(e,n,t){if(e!==void 0)return e;if(n!==void 0)return n;if(t!==void 0)return t}function HZ(e,n,t,r,i){const o=typeof t===i?r[t]:void 0;return W_(o,e.default,n.default)}function ZZ(e,n,t){if(Do(t)!=="number")return W_(e.default,n.default);const r=e.stops.length;if(r===1||t<=e.stops[0][0])return e.stops[0][1];if(t>=e.stops[r-1][0])return e.stops[r-1][1];const i=J4(e.stops.map(o=>o[0]),t);return e.stops[i][1]}function jI(e,n,t){const r=e.base!==void 0?e.base:1;if(Do(t)!=="number")return W_(e.default,n.default);const i=e.stops.length;if(i===1||t<=e.stops[0][0])return e.stops[0][1];if(t>=e.stops[i-1][0])return e.stops[i-1][1];const o=J4(e.stops.map(x=>x[0]),t),s=JZ(t,r,e.stops[o][0],e.stops[o+1][0]),a=e.stops[o][1],f=e.stops[o+1][1],g=p2[n.type]||VZ;return typeof a.evaluate=="function"?{evaluate(...x){const k=a.evaluate.apply(void 0,x),B=f.evaluate.apply(void 0,x);if(!(k===void 0||B===void 0))return g(k,B,s,e.colorSpace)}}:g(a,f,s,e.colorSpace)}function XZ(e,n,t){switch(n.type){case"color":t=ms.parse(t);break;case"formatted":t=Dy.fromString(t.toString());break;case"resolvedImage":t=C1.fromString(t.toString());break;case"padding":t=jc.parse(t);break;default:Do(t)!==n.type&&(n.type!=="enum"||!n.values[t])&&(t=void 0)}return W_(t,e.default,n.default)}function JZ(e,n,t,r){const i=r-t,o=e-t;return i===0?0:n===1?o/i:(Math.pow(n,o)-1)/(Math.pow(n,i)-1)}let _R=class{constructor(n,t){this.expression=n,this._warningHistory={},this._evaluator=new qU,this._defaultValue=t?rX(t):null,this._enumValues=t&&t.type==="enum"?t.values:null}evaluateWithoutErrorHandling(n,t,r,i,o,s){return this._evaluator.globals=n,this._evaluator.feature=t,this._evaluator.featureState=r,this._evaluator.canonical=i,this._evaluator.availableImages=o||null,this._evaluator.formattedSection=s,this.expression.evaluate(this._evaluator)}evaluate(n,t,r,i,o,s){this._evaluator.globals=n,this._evaluator.feature=t||null,this._evaluator.featureState=r||null,this._evaluator.canonical=i,this._evaluator.availableImages=o||null,this._evaluator.formattedSection=s||null;try{const a=this.expression.evaluate(this._evaluator);if(a==null||typeof a=="number"&&a!==a)return this._defaultValue;if(this._enumValues&&!(a in this._enumValues))throw new sl(`Expected value to be one of ${Object.keys(this._enumValues).map(f=>JSON.stringify(f)).join(", ")}, but found ${JSON.stringify(a)} instead.`);return a}catch(a){return this._warningHistory[a.message]||(this._warningHistory[a.message]=!0,typeof console<"u"&&console.warn(a.message)),this._defaultValue}}};function N_(e){return Array.isArray(e)&&e.length>0&&typeof e[0]=="string"&&e[0]in _B}function wB(e,n){const t=new VU(_B,a3,[],n?nX(n):void 0),r=t.parse(e,void 0,void 0,void 0,n&&n.type==="string"?{typeAnnotation:"coerce"}:void 0);return r?b6(new _R(r,n)):yg(t.errors)}let x6=class{constructor(n,t){this.kind=n,this._styleExpression=t,this.isStateDependent=n!=="constant"&&!i_(t.expression)}evaluateWithoutErrorHandling(n,t,r,i,o,s){return this._styleExpression.evaluateWithoutErrorHandling(n,t,r,i,o,s)}evaluate(n,t,r,i,o,s){return this._styleExpression.evaluate(n,t,r,i,o,s)}},w6=class{constructor(n,t,r,i){this.kind=n,this.zoomStops=r,this._styleExpression=t,this.isStateDependent=n!=="camera"&&!i_(t.expression),this.interpolationType=i}evaluateWithoutErrorHandling(n,t,r,i,o,s){return this._styleExpression.evaluateWithoutErrorHandling(n,t,r,i,o,s)}evaluate(n,t,r,i,o,s){return this._styleExpression.evaluate(n,t,r,i,o,s)}interpolationFactor(n,t,r){return this.interpolationType?Cp.interpolationFactor(this.interpolationType,n,t,r):0}};function eX(e){return e._styleExpression!==void 0}function MB(e,n){const t=wB(e,n);if(t.result==="error")return t;const r=t.value.expression,i=Z4(r);if(!i&&!l3(n))return yg([new Hh("","data expressions not supported")]);const o=X4(r,["zoom"]);if(!o&&!CR(n))return yg([new Hh("","zoom expressions not supported")]);const s=m2(r);if(!s&&!o)return yg([new Hh("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')]);if(s instanceof Hh)return yg([s]);if(s instanceof Cp&&!bB(n))return yg([new Hh("",'"interpolate" expressions cannot be used with this property')]);if(!s)return b6(i?new x6("constant",t.value):new x6("source",t.value));const a=s instanceof Cp?s.interpolation:void 0;return b6(i?new w6("camera",t.value,s.labels,a):new w6("composite",t.value,s.labels,a))}let bR=class xR{constructor(n,t){this._parameters=n,this._specification=t,_y(this,xB(this._parameters,this._specification))}static deserialize(n){return new xR(n._parameters,n._specification)}static serialize(n){return{_parameters:n._parameters,_specification:n._specification}}};function tX(e,n){if(j_(e))return new bR(e,n);if(N_(e)){const t=MB(e,n);if(t.result==="error")throw new Error(t.value.map(r=>`${r.key}: ${r.message}`).join(", "));return t.value}else{let t=e;return n.type==="color"&&typeof e=="string"?t=ms.parse(e):n.type==="padding"&&(typeof e=="number"||Array.isArray(e))?t=jc.parse(e):n.type==="variableAnchorOffsetCollection"&&Array.isArray(e)&&(t=uf.parse(e)),{kind:"constant",evaluate:()=>t}}}function m2(e){let n=null;if(e instanceof lR)n=m2(e.result);else if(e instanceof sR){for(const t of e.args)if(n=m2(t),n)break}else(e instanceof iR||e instanceof Cp)&&e.input instanceof Uy&&e.input.name==="zoom"&&(n=e);return n instanceof Hh||e.eachChild(t=>{const r=m2(t);r instanceof Hh?n=r:!n&&r?n=new Hh("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):n&&r&&n!==r&&(n=new Hh("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),n}function nX(e){const n={color:af,string:co,number:tr,enum:co,boolean:Vi,formatted:q4,padding:V4,resolvedImage:z_,variableAnchorOffsetCollection:H4};return e.type==="array"?Pc(n[e.value]||Zi,e.length):n[e.type]}function rX(e){return e.type==="color"&&j_(e.default)?new ms(0,0,0,0):e.type==="color"?ms.parse(e.default)||null:e.type==="padding"?jc.parse(e.default)||null:e.type==="variableAnchorOffsetCollection"?uf.parse(e.default)||null:e.default===void 0?null:e.default}function e5(e){if(e===!0||e===!1)return!0;if(!Array.isArray(e)||e.length===0)return!1;switch(e[0]){case"has":return e.length>=2&&e[1]!=="$id"&&e[1]!=="$type";case"in":return e.length>=3&&(typeof e[1]!="string"||Array.isArray(e[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return e.length!==3||Array.isArray(e[1])||Array.isArray(e[2]);case"any":case"all":for(const n of e.slice(1))if(!e5(n)&&typeof n!="boolean")return!1;return!0;default:return!0}}function EC(e,n={}){if(e5(e))return e;if(!e)return!0;const t=e,r=t[0];if(e.length<=1)return r!=="any";switch(r){case"==":case"!=":case"<":case">":case"<=":case">=":{const[,i,o]=e;return oX(i,o,r,n)}case"any":{const[,...i]=t;return["any",...i.map(s=>{const a={},f=EC(s,a),g=iX(a);return g===!0?f:["case",g,f,!1]})]}case"all":{const[,...i]=t,o=i.map(s=>EC(s,n));return o.length>1?["all",...o]:o[0]}case"none":{const[,...i]=t;return["!",EC(["any",...i],{})]}case"in":{const[,i,...o]=t;return WI(i,o)}case"!in":{const[,i,...o]=t;return WI(i,o,!0)}case"has":return NI(t[1]);case"!has":return["!",NI(t[1])];default:return!0}}function iX(e){const n=[];for(const t in e){const r=t==="$id"?["id"]:["get",t];n.push(["==",["typeof",r],e[t]])}return n.length===0?!0:n.length===1?n[0]:["all",...n]}function oX(e,n,t,r){let i;if(e==="$type")return[t,["geometry-type"],n];if(e==="$id"?i=["id"]:i=["get",e],r&&n!==null){const o=typeof n;r[e]=o}return t==="=="&&e!=="$id"&&n===null?["all",["has",e],["==",i,null]]:t==="!="&&e!=="$id"&&n===null?["any",["!",["has",e]],["!=",i,null]]:[t,i,n]}function WI(e,n,t=!1){if(n.length===0)return t;let r;e==="$type"?r=["geometry-type"]:e==="$id"?r=["id"]:r=["get",e];let i=!0;const o=typeof n[0];for(const s of n)if(typeof s!==o){i=!1;break}if(i&&(o==="string"||o==="number")){const s=n.sort().filter((a,f)=>f===0||n[f-1]!==a);return["match",r,s,!t,t]}return t?["all",...n.map(s=>["!=",r,s])]:["any",...n.map(s=>["==",r,s])]}function NI(e){return e==="$type"?!0:e==="$id"?["!=",["id"],null]:["has",e]}function o_(e){return typeof e=="object"?["literal",e]:e}function wR(e,n){let t=e.stops;if(!t)return aX(e,n);const r=t&&typeof t[0][0]=="object",i=r||e.property!==void 0,o=r||!i;return t=t.map(s=>!i&&n.tokens&&typeof s[1]=="string"?[s[0],MR(s[1])]:[s[0],o_(s[1])]),r?sX(e,n,t):o?uX(e,n,t):M6(e,n,t)}function aX(e,n){const t=["get",e.property];if(e.default===void 0)return n.type==="string"?["string",t]:t;if(n.type==="enum")return["match",t,Object.keys(n.values),t,e.default];{const r=[n.type==="color"?"to-color":n.type,t,o_(e.default)];return n.type==="array"&&r.splice(1,0,n.value,n.length||null),r}}function SB(e){switch(e.colorSpace){case"hcl":return"interpolate-hcl";case"lab":return"interpolate-lab";default:return"interpolate"}}function sX(e,n,t){const r={},i={},o=[];for(let a=0;a<t.length;a++){const f=t[a],g=f[0].zoom;r[g]===void 0&&(r[g]={zoom:g,type:e.type,property:e.property,default:e.default},i[g]=[],o.push(g)),i[g].push([f[0].value,f[1]])}if(OB({},n)==="exponential"){const a=[SB(e),["linear"],["zoom"]];for(const f of o){const g=M6(r[f],n,i[f]);Jg(a,f,g,!1)}return a}else{const a=["step",["zoom"]];for(const f of o){const g=M6(r[f],n,i[f]);Jg(a,f,g,!0)}return EB(a),a}}function lX(e,n){if(e!==void 0)return e;if(n!==void 0)return n}function GI(e,n){const t=o_(lX(e.default,n.default));return t===void 0&&n.type==="resolvedImage"?"":t}function M6(e,n,t){const r=OB(e,n),i=["get",e.property];if(r==="categorical"&&typeof t[0][0]=="boolean"){const o=["case"];for(const s of t)o.push(["==",i,s[0]],s[1]);return o.push(GI(e,n)),o}else if(r==="categorical"){const o=["match",i];for(const s of t)Jg(o,s[0],s[1],!1);return o.push(GI(e,n)),o}else if(r==="interval"){const o=["step",["number",i]];for(const s of t)Jg(o,s[0],s[1],!0);return EB(o),e.default===void 0?o:["case",["==",["typeof",i],"number"],o,o_(e.default)]}else if(r==="exponential"){const o=e.base!==void 0?e.base:1,s=[SB(e),o===1?["linear"]:["exponential",o],["number",i]];for(const a of t)Jg(s,a[0],a[1],!1);return e.default===void 0?s:["case",["==",["typeof",i],"number"],s,o_(e.default)]}else throw new Error(`Unknown property function type ${r}`)}function uX(e,n,t,r=["zoom"]){const i=OB(e,n);let o,s=!1;if(i==="interval")o=["step",r],s=!0;else if(i==="exponential"){const a=e.base!==void 0?e.base:1;o=[SB(e),a===1?["linear"]:["exponential",a],r]}else throw new Error(`Unknown zoom function type "${i}"`);for(const a of t)Jg(o,a[0],a[1],s);return EB(o),o}function EB(e){e[0]==="step"&&e.length===3&&(e.push(0),e.push(e[3]))}function Jg(e,n,t,r){e.length>3&&n===e[e.length-2]||(r&&e.length===2||e.push(n),e.push(t))}function OB(e,n){return e.type?e.type:n.expression.interpolated?"exponential":"interval"}function MR(e){const n=["concat"],t=/{([^{}]+)}/g;let r=0;for(let i=t.exec(e);i!==null;i=t.exec(e)){const o=e.slice(r,t.lastIndex-i[0].length);r=t.lastIndex,o.length>0&&n.push(o),n.push(["get",i[1]])}if(n.length===1)return e;if(r<e.length)n.push(e.slice(r));else if(n.length===2)return["to-string",n[1]];return n}function AX(e){for(let n=0;n<ma.layout.length;n++)for(const t in ma[ma.layout[n]])if(t===e)return ma[ma.layout[n]][t];for(let n=0;n<ma.paint.length;n++)for(const t in ma[ma.paint[n]])if(t===e)return ma[ma.paint[n]][t];return null}function cX(e,n){for(const t in e.sources)n(e.sources[t])}function OC(e,n){for(const t of e.layers)n(t)}function BB(e,n,t){function r(i,o){const s=i[o];s&&Object.keys(s).forEach(a=>{t({path:[i.id,o,a],key:a,value:s[a],reference:AX(a),set(f){s[a]=f}})})}OC(e,i=>{n.paint&&r(i,"paint"),n.layout&&r(i,"layout")})}function SR(e){const n=e.key,t=e.value;return t?[new Hn(n,t,"constants have been deprecated as of v8")]:[]}function $s(e){return e instanceof Number||e instanceof String||e instanceof Boolean?e.valueOf():e}function u1(e){if(Array.isArray(e))return e.map(u1);if(e instanceof Object&&!(e instanceof Number||e instanceof String||e instanceof Boolean)){const n={};for(const t in e)n[t]=u1(e[t]);return n}return $s(e)}function Cd(e){const n=e.key,t=e.value,r=e.valueSpec||{},i=e.objectElementValidators||{},o=e.style,s=e.styleSpec,a=e.validateSpec;let f=[];const g=Do(t);if(g!=="object")return[new Hn(n,t,`object expected, ${g} found`)];for(const x in t){const k=x.split(".")[0],B=r[k]||r["*"];let P;if(i[k])P=i[k];else if(r[k])P=a;else if(i["*"])P=i["*"];else if(r["*"])P=a;else{f.push(new Hn(n,t[x],`unknown property "${x}"`));continue}f=f.concat(P({key:(n&&`${n}.`)+x,value:t[x],valueSpec:B,style:o,styleSpec:s,object:t,objectKey:x,validateSpec:a},t))}for(const x in r)i[x]||r[x].required&&r[x].default===void 0&&t[x]===void 0&&f.push(new Hn(n,t,`missing required property "${x}"`));return f}function kB(e){const n=e.value,t=e.valueSpec,r=e.validateSpec,i=e.style,o=e.styleSpec,s=e.key,a=e.arrayElementValidator||r;if(Do(n)!=="array")return[new Hn(s,n,`array expected, ${Do(n)} found`)];if(t.length&&n.length!==t.length)return[new Hn(s,n,`array length ${t.length} expected, length ${n.length} found`)];if(t["min-length"]&&n.length<t["min-length"])return[new Hn(s,n,`array length at least ${t["min-length"]} expected, length ${n.length} found`)];let f={type:t.value,values:t.values};o.$version<7&&(f.function=t.function),Do(t.value)==="object"&&(f=t.value);let g=[];for(let x=0;x<n.length;x++)g=g.concat(a({array:n,arrayIndex:x,value:n[x],valueSpec:f,validateSpec:e.validateSpec,style:i,styleSpec:o,key:`${s}[${x}]`}));return g}function IB(e){const n=e.key,t=e.value,r=e.valueSpec;let i=Do(t);return i==="number"&&t!==t&&(i="NaN"),i!=="number"?[new Hn(n,t,`number expected, ${i} found`)]:"minimum"in r&&t<r.minimum?[new Hn(n,t,`${t} is less than the minimum value ${r.minimum}`)]:"maximum"in r&&t>r.maximum?[new Hn(n,t,`${t} is greater than the maximum value ${r.maximum}`)]:[]}function ER(e){const n=e.valueSpec,t=$s(e.value.type);let r,i={},o,s;const a=t!=="categorical"&&e.value.property===void 0,f=!a,g=Do(e.value.stops)==="array"&&Do(e.value.stops[0])==="array"&&Do(e.value.stops[0][0])==="object",x=Cd({key:e.key,value:e.value,valueSpec:e.styleSpec.function,validateSpec:e.validateSpec,style:e.style,styleSpec:e.styleSpec,objectElementValidators:{stops:k,default:R}});return t==="identity"&&a&&x.push(new Hn(e.key,e.value,'missing required property "property"')),t!=="identity"&&!e.value.stops&&x.push(new Hn(e.key,e.value,'missing required property "stops"')),t==="exponential"&&e.valueSpec.expression&&!bB(e.valueSpec)&&x.push(new Hn(e.key,e.value,"exponential functions not supported")),e.styleSpec.$version>=8&&(f&&!l3(e.valueSpec)?x.push(new Hn(e.key,e.value,"property functions not supported")):a&&!CR(e.valueSpec)&&x.push(new Hn(e.key,e.value,"zoom functions not supported"))),(t==="categorical"||g)&&e.value.property===void 0&&x.push(new Hn(e.key,e.value,'"property" property is required')),x;function k(H){if(t==="identity")return[new Hn(H.key,H.value,'identity function may not have a "stops" property')];let W=[];const $=H.value;return W=W.concat(kB({key:H.key,value:$,valueSpec:H.valueSpec,validateSpec:H.validateSpec,style:H.style,styleSpec:H.styleSpec,arrayElementValidator:B})),Do($)==="array"&&$.length===0&&W.push(new Hn(H.key,$,"array must have at least one stop")),W}function B(H){let W=[];const $=H.value,q=H.key;if(Do($)!=="array")return[new Hn(q,$,`array expected, ${Do($)} found`)];if($.length!==2)return[new Hn(q,$,`array length 2 expected, length ${$.length} found`)];if(g){if(Do($[0])!=="object")return[new Hn(q,$,`object expected, ${Do($[0])} found`)];if($[0].zoom===void 0)return[new Hn(q,$,"object stop key must have zoom")];if($[0].value===void 0)return[new Hn(q,$,"object stop key must have value")];if(s&&s>$s($[0].zoom))return[new Hn(q,$[0].zoom,"stop zoom values must appear in ascending order")];$s($[0].zoom)!==s&&(s=$s($[0].zoom),o=void 0,i={}),W=W.concat(Cd({key:`${q}[0]`,value:$[0],valueSpec:{zoom:{}},validateSpec:H.validateSpec,style:H.style,styleSpec:H.styleSpec,objectElementValidators:{zoom:IB,value:P}}))}else W=W.concat(P({key:`${q}[0]`,value:$[0],valueSpec:{},validateSpec:H.validateSpec,style:H.style,styleSpec:H.styleSpec},$));return N_(u1($[1]))?W.concat([new Hn(`${q}[1]`,$[1],"expressions are not allowed in function stops.")]):W.concat(H.validateSpec({key:`${q}[1]`,value:$[1],valueSpec:n,validateSpec:H.validateSpec,style:H.style,styleSpec:H.styleSpec}))}function P(H,W){const $=Do(H.value),q=$s(H.value),oe=H.value!==null?H.value:W;if(!r)r=$;else if($!==r)return[new Hn(H.key,oe,`${$} stop domain type must match previous stop domain type ${r}`)];if($!=="number"&&$!=="string"&&$!=="boolean")return[new Hn(H.key,oe,"stop domain value must be a number, string, or boolean")];if($!=="number"&&t!=="categorical"){let ne=`number expected, ${$} found`;return l3(n)&&t===void 0&&(ne+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new Hn(H.key,oe,ne)]}return t==="categorical"&&$==="number"&&(!isFinite(q)||Math.floor(q)!==q)?[new Hn(H.key,oe,`integer expected, found ${q}`)]:t!=="categorical"&&$==="number"&&o!==void 0&&q<o?[new Hn(H.key,oe,"stop domain values must appear in ascending order")]:(o=q,t==="categorical"&&q in i?[new Hn(H.key,oe,"stop domain values must be unique")]:(i[q]=!0,[]))}function R(H){return H.validateSpec({key:H.key,value:H.value,valueSpec:n,validateSpec:H.validateSpec,style:H.style,styleSpec:H.styleSpec})}}function by(e){const n=(e.expressionContext==="property"?MB:wB)(u1(e.value),e.valueSpec);if(n.result==="error")return n.value.map(r=>new Hn(`${e.key}${r.key}`,e.value,r.message));const t=n.value.expression||n.value._styleExpression.expression;if(e.expressionContext==="property"&&e.propertyKey==="text-font"&&!t.outputDefined())return[new Hn(e.key,e.value,`Invalid data expression for "${e.propertyKey}". Output values must be contained as literals within the expression.`)];if(e.expressionContext==="property"&&e.propertyType==="layout"&&!i_(t))return[new Hn(e.key,e.value,'"feature-state" data expressions are not supported with layout properties.')];if(e.expressionContext==="filter"&&!i_(t))return[new Hn(e.key,e.value,'"feature-state" data expressions are not supported with filters.')];if(e.expressionContext&&e.expressionContext.indexOf("cluster")===0){if(!X4(t,["zoom","feature-state"]))return[new Hn(e.key,e.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(e.expressionContext==="cluster-initial"&&!Z4(t))return[new Hn(e.key,e.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function dX(e){const n=e.value,t=e.key,r=Do(n);return r!=="boolean"?[new Hn(t,n,`boolean expected, ${r} found`)]:[]}function hX(e){const n=e.key,t=e.value,r=Do(t);return r!=="string"?[new Hn(n,t,`color expected, ${r} found`)]:ms.parse(String(t))?[]:[new Hn(n,t,`color expected, "${t}" found`)]}function a_(e){const n=e.key,t=e.value,r=e.valueSpec,i=[];return Array.isArray(r.values)?r.values.indexOf($s(t))===-1&&i.push(new Hn(n,t,`expected one of [${r.values.join(", ")}], ${JSON.stringify(t)} found`)):Object.keys(r.values).indexOf($s(t))===-1&&i.push(new Hn(n,t,`expected one of [${Object.keys(r.values).join(", ")}], ${JSON.stringify(t)} found`)),i}function TB(e){return e5(u1(e.value))?by(_y({},e,{expressionContext:"filter",valueSpec:{value:"boolean"}})):OR(e)}function OR(e){const n=e.value,t=e.key;if(Do(n)!=="array")return[new Hn(t,n,`array expected, ${Do(n)} found`)];const r=e.styleSpec;let i,o=[];if(n.length<1)return[new Hn(t,n,"filter array must have at least 1 element")];switch(o=o.concat(a_({key:`${t}[0]`,value:n[0],valueSpec:r.filter_operator,style:e.style,styleSpec:e.styleSpec})),$s(n[0])){case"<":case"<=":case">":case">=":n.length>=2&&$s(n[1])==="$type"&&o.push(new Hn(t,n,`"$type" cannot be use with operator "${n[0]}"`));case"==":case"!=":n.length!==3&&o.push(new Hn(t,n,`filter array for operator "${n[0]}" must have 3 elements`));case"in":case"!in":n.length>=2&&(i=Do(n[1]),i!=="string"&&o.push(new Hn(`${t}[1]`,n[1],`string expected, ${i} found`)));for(let s=2;s<n.length;s++)i=Do(n[s]),$s(n[1])==="$type"?o=o.concat(a_({key:`${t}[${s}]`,value:n[s],valueSpec:r.geometry_type,style:e.style,styleSpec:e.styleSpec})):i!=="string"&&i!=="number"&&i!=="boolean"&&o.push(new Hn(`${t}[${s}]`,n[s],`string, number, or boolean expected, ${i} found`));break;case"any":case"all":case"none":for(let s=1;s<n.length;s++)o=o.concat(OR({key:`${t}[${s}]`,value:n[s],style:e.style,styleSpec:e.styleSpec}));break;case"has":case"!has":i=Do(n[1]),n.length!==2?o.push(new Hn(t,n,`filter array for "${n[0]}" operator must have 2 elements`)):i!=="string"&&o.push(new Hn(`${t}[1]`,n[1],`string expected, ${i} found`));break;case"within":i=Do(n[1]),n.length!==2?o.push(new Hn(t,n,`filter array for "${n[0]}" operator must have 2 elements`)):i!=="object"&&o.push(new Hn(`${t}[1]`,n[1],`object expected, ${i} found`));break}return o}function BR(e,n){const t=e.key,r=e.validateSpec,i=e.style,o=e.styleSpec,s=e.value,a=e.objectKey,f=o[`${n}_${e.layerType}`];if(!f)return[];const g=a.match(/^(.*)-transition$/);if(n==="paint"&&g&&f[g[1]]&&f[g[1]].transition)return r({key:t,value:s,valueSpec:o.transition,style:i,styleSpec:o});const x=e.valueSpec||f[a];if(!x)return[new Hn(t,s,`unknown property "${a}"`)];let k;if(Do(s)==="string"&&l3(x)&&!x.tokens&&(k=/^{([^}]+)}$/.exec(s)))return[new Hn(t,s,`"${a}" does not support interpolation syntax
|
||
Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(k[1])} }\`.`)];const B=[];return e.layerType==="symbol"&&(a==="text-field"&&i&&!i.glyphs&&B.push(new Hn(t,s,'use of "text-field" requires a style "glyphs" property')),a==="text-font"&&j_(u1(s))&&$s(s.type)==="identity"&&B.push(new Hn(t,s,'"text-font" does not support identity functions'))),B.concat(r({key:e.key,value:s,valueSpec:x,style:i,styleSpec:o,expressionContext:"property",propertyType:n,propertyKey:a}))}function kR(e){return BR(e,"paint")}function IR(e){return BR(e,"layout")}function TR(e){let n=[];const t=e.value,r=e.key,i=e.style,o=e.styleSpec;!t.type&&!t.ref&&n.push(new Hn(r,t,'either "type" or "ref" is required'));let s=$s(t.type);const a=$s(t.ref);if(t.id){const f=$s(t.id);for(let g=0;g<e.arrayIndex;g++){const x=i.layers[g];$s(x.id)===f&&n.push(new Hn(r,t.id,`duplicate layer id "${t.id}", previously used at line ${x.id.__line__}`))}}if("ref"in t){["type","source","source-layer","filter","layout"].forEach(g=>{g in t&&n.push(new Hn(r,t[g],`"${g}" is prohibited for ref layers`))});let f;i.layers.forEach(g=>{$s(g.id)===a&&(f=g)}),f?f.ref?n.push(new Hn(r,t.ref,"ref cannot reference another ref layer")):s=$s(f.type):n.push(new Hn(r,t.ref,`ref layer "${a}" not found`))}else if(s!=="background")if(!t.source)n.push(new Hn(r,t,'missing required property "source"'));else{const f=i.sources&&i.sources[t.source],g=f&&$s(f.type);f?g==="vector"&&s==="raster"?n.push(new Hn(r,t.source,`layer "${t.id}" requires a raster source`)):g!=="raster-dem"&&s==="hillshade"?n.push(new Hn(r,t.source,`layer "${t.id}" requires a raster-dem source`)):g==="raster"&&s!=="raster"?n.push(new Hn(r,t.source,`layer "${t.id}" requires a vector source`)):g==="vector"&&!t["source-layer"]?n.push(new Hn(r,t,`layer "${t.id}" must specify a "source-layer"`)):g==="raster-dem"&&s!=="hillshade"?n.push(new Hn(r,t.source,"raster-dem source can only be used with layer type 'hillshade'.")):s==="line"&&t.paint&&t.paint["line-gradient"]&&(g!=="geojson"||!f.lineMetrics)&&n.push(new Hn(r,t,`layer "${t.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):n.push(new Hn(r,t.source,`source "${t.source}" not found`))}return n=n.concat(Cd({key:r,value:t,valueSpec:o.layer,style:e.style,styleSpec:e.styleSpec,validateSpec:e.validateSpec,objectElementValidators:{"*"(){return[]},type(){return e.validateSpec({key:`${r}.type`,value:t.type,valueSpec:o.layer.type,style:e.style,styleSpec:e.styleSpec,validateSpec:e.validateSpec,object:t,objectKey:"type"})},filter:TB,layout(f){return Cd({layer:t,key:f.key,value:f.value,style:f.style,styleSpec:f.styleSpec,validateSpec:f.validateSpec,objectElementValidators:{"*"(g){return IR(_y({layerType:s},g))}}})},paint(f){return Cd({layer:t,key:f.key,value:f.value,style:f.style,styleSpec:f.styleSpec,validateSpec:f.validateSpec,objectElementValidators:{"*"(g){return kR(_y({layerType:s},g))}}})}}})),n}function A1(e){const n=e.value,t=e.key,r=Do(n);return r!=="string"?[new Hn(t,n,`string expected, ${r} found`)]:[]}function fX(e){var n;const t=(n=e.sourceName)!==null&&n!==void 0?n:"",r=e.value,i=e.styleSpec,o=i.source_raster_dem,s=e.style;let a=[];const f=Do(r);if(r===void 0)return a;if(f!=="object")return a.push(new Hn("source_raster_dem",r,`object expected, ${f} found`)),a;const x=$s(r.encoding)==="custom",k=["redFactor","greenFactor","blueFactor","baseShift"],B=e.value.encoding?`"${e.value.encoding}"`:"Default";for(const P in r)!x&&k.includes(P)?a.push(new Hn(P,r[P],`In "${t}": "${P}" is only valid when "encoding" is set to "custom". ${B} encoding found`)):o[P]?a=a.concat(e.validateSpec({key:P,value:r[P],valueSpec:o[P],validateSpec:e.validateSpec,style:s,styleSpec:i})):a.push(new Hn(P,r[P],`unknown property "${P}"`));return a}const QI={promoteId:pX};function KR(e){const n=e.value,t=e.key,r=e.styleSpec,i=e.style,o=e.validateSpec;if(!n.type)return[new Hn(t,n,'"type" is required')];const s=$s(n.type);let a;switch(s){case"vector":case"raster":return a=Cd({key:t,value:n,valueSpec:r[`source_${s.replace("-","_")}`],style:e.style,styleSpec:r,objectElementValidators:QI,validateSpec:o}),a;case"raster-dem":return a=fX({sourceName:t,value:n,style:e.style,styleSpec:r,validateSpec:o}),a;case"geojson":if(a=Cd({key:t,value:n,valueSpec:r.source_geojson,style:i,styleSpec:r,validateSpec:o,objectElementValidators:QI}),n.cluster)for(const f in n.clusterProperties){const[g,x]=n.clusterProperties[f],k=typeof g=="string"?[g,["accumulated"],["get",f]]:g;a.push(...by({key:`${t}.${f}.map`,value:x,validateSpec:o,expressionContext:"cluster-map"})),a.push(...by({key:`${t}.${f}.reduce`,value:k,validateSpec:o,expressionContext:"cluster-reduce"}))}return a;case"video":return Cd({key:t,value:n,valueSpec:r.source_video,style:i,validateSpec:o,styleSpec:r});case"image":return Cd({key:t,value:n,valueSpec:r.source_image,style:i,validateSpec:o,styleSpec:r});case"canvas":return[new Hn(t,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return a_({key:`${t}.type`,value:n.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]},style:i,validateSpec:o,styleSpec:r})}}function pX({key:e,value:n}){if(Do(n)==="string")return A1({key:e,value:n});{const t=[];for(const r in n)t.push(...A1({key:`${e}.${r}`,value:n[r]}));return t}}function PR(e){const n=e.value,t=e.styleSpec,r=t.light,i=e.style;let o=[];const s=Do(n);if(n===void 0)return o;if(s!=="object")return o=o.concat([new Hn("light",n,`object expected, ${s} found`)]),o;for(const a in n){const f=a.match(/^(.*)-transition$/);f&&r[f[1]]&&r[f[1]].transition?o=o.concat(e.validateSpec({key:a,value:n[a],valueSpec:t.transition,validateSpec:e.validateSpec,style:i,styleSpec:t})):r[a]?o=o.concat(e.validateSpec({key:a,value:n[a],valueSpec:r[a],validateSpec:e.validateSpec,style:i,styleSpec:t})):o=o.concat([new Hn(a,n[a],`unknown property "${a}"`)])}return o}function FR(e){const n=e.value,t=e.styleSpec,r=t.sky,i=e.style,o=Do(n);if(n===void 0)return[];if(o!=="object")return[new Hn("sky",n,`object expected, ${o} found`)];let s=[];for(const a in n)r[a]?s=s.concat(ey({key:a,value:n[a],valueSpec:r[a],style:i,styleSpec:t})):s=s.concat([new Hn(a,n[a],`unknown property "${a}"`)]);return s}function DR(e){const n=e.value,t=e.styleSpec,r=t.terrain,i=e.style;let o=[];const s=Do(n);if(n===void 0)return o;if(s!=="object")return o=o.concat([new Hn("terrain",n,`object expected, ${s} found`)]),o;for(const a in n)r[a]?o=o.concat(e.validateSpec({key:a,value:n[a],valueSpec:r[a],validateSpec:e.validateSpec,style:i,styleSpec:t})):o=o.concat([new Hn(a,n[a],`unknown property "${a}"`)]);return o}function mX(e){return A1(e).length===0?[]:by(e)}function gX(e){return A1(e).length===0?[]:by(e)}function yX(e){const n=e.key,t=e.value;if(Do(t)==="array"){if(t.length<1||t.length>4)return[new Hn(n,t,`padding requires 1 to 4 values; ${t.length} values found`)];const i={type:"number"};let o=[];for(let s=0;s<t.length;s++)o=o.concat(e.validateSpec({key:`${n}[${s}]`,value:t[s],validateSpec:e.validateSpec,valueSpec:i}));return o}else return IB({key:n,value:t,valueSpec:{}})}function vX(e){const n=e.key,t=e.value,r=Do(t),i=e.styleSpec;if(r!=="array"||t.length<1||t.length%2!==0)return[new Hn(n,t,"variableAnchorOffsetCollection requires a non-empty array of even length")];let o=[];for(let s=0;s<t.length;s+=2)o=o.concat(a_({key:`${n}[${s}]`,value:t[s],valueSpec:i.layout_symbol["text-anchor"]})),o=o.concat(kB({key:`${n}[${s+1}]`,value:t[s+1],valueSpec:{length:2,value:"number"},validateSpec:e.validateSpec,style:e.style,styleSpec:i}));return o}function UR(e){let n=[];const t=e.value,r=e.key;if(Array.isArray(t)){const i=[],o=[];for(const s in t){t[s].id&&i.includes(t[s].id)&&n.push(new Hn(r,t,`all the sprites' ids must be unique, but ${t[s].id} is duplicated`)),i.push(t[s].id),t[s].url&&o.includes(t[s].url)&&n.push(new Hn(r,t,`all the sprites' URLs must be unique, but ${t[s].url} is duplicated`)),o.push(t[s].url);const a={id:{type:"string",required:!0},url:{type:"string",required:!0}};n=n.concat(Cd({key:`${r}[${s}]`,value:t[s],valueSpec:a,validateSpec:e.validateSpec}))}return n}else return A1({key:r,value:t})}const $I={"*"(){return[]},array:kB,boolean:dX,number:IB,color:hX,constants:SR,enum:a_,filter:TB,function:ER,layer:TR,object:Cd,source:KR,light:PR,sky:FR,terrain:DR,string:A1,formatted:mX,resolvedImage:gX,padding:yX,variableAnchorOffsetCollection:vX,sprite:UR};function ey(e){const n=e.value,t=e.valueSpec,r=e.styleSpec;return e.validateSpec=ey,t.expression&&j_($s(n))?ER(e):t.expression&&N_(u1(n))?by(e):t.type&&$I[t.type]?$I[t.type](e):Cd(_y({},e,{valueSpec:t.type?r[t.type]:t}))}function RR(e){const n=e.value,t=e.key,r=A1(e);return r.length||(n.indexOf("{fontstack}")===-1&&r.push(new Hn(t,n,'"glyphs" url must include a "{fontstack}" token')),n.indexOf("{range}")===-1&&r.push(new Hn(t,n,'"glyphs" url must include a "{range}" token'))),r}function Bd(e,n=ma){let t=[];return t=t.concat(ey({key:"",value:e,valueSpec:n.$root,styleSpec:n,style:e,validateSpec:ey,objectElementValidators:{glyphs:RR,"*"(){return[]}}})),e.constants&&(t=t.concat(SR({key:"constants",value:e.constants,style:e,styleSpec:n,validateSpec:ey}))),LR(t)}Bd.source=vf(yf(KR));Bd.sprite=vf(yf(UR));Bd.glyphs=vf(yf(RR));Bd.light=vf(yf(PR));Bd.sky=vf(yf(FR));Bd.terrain=vf(yf(DR));Bd.layer=vf(yf(TR));Bd.filter=vf(yf(TB));Bd.paintProperty=vf(yf(kR));Bd.layoutProperty=vf(yf(IR));function yf(e){return function(n){return e({...n,validateSpec:ey})}}function LR(e){return[].concat(e).sort((n,t)=>n.line-t.line)}function vf(e){return function(...n){return LR(e.apply(this,n))}}const CX=/("(?:[^\\"]|\\.)*")|[:,]/g;function _X(e,n={}){const t=JSON.stringify([1],void 0,n.indent===void 0?2:n.indent).slice(2,-3),r=t===""?1/0:n.maxLength===void 0?80:n.maxLength;let{replacer:i}=n;return function o(s,a,f){s&&typeof s.toJSON=="function"&&(s=s.toJSON());const g=JSON.stringify(s,i);if(g===void 0)return g;const x=r-a.length-f;if(g.length<=x){const k=g.replace(CX,(B,P)=>P||`${B} `);if(k.length<=x)return k}if(i!=null&&(s=JSON.parse(g),i=void 0),typeof s=="object"&&s!==null){const k=a+t,B=[];let P=0,R,H;if(Array.isArray(s)){R="[",H="]";const{length:W}=s;for(;P<W;P++)B.push(o(s[P],k,P===W-1?0:1)||"null")}else{R="{",H="}";const W=Object.keys(s),{length:$}=W;for(;P<$;P++){const q=W[P],oe=`${JSON.stringify(q)}: `,ne=o(s[q],k,oe.length+(P===$-1?0:1));ne!==void 0&&B.push(oe+ne)}}if(B.length>0)return[R,t+B.join(`,
|
||
${k}`),H].join(`
|
||
${a}`)}return g}(e,"",0)}function YI(e,n){const t={};for(const r in n)e[r]!==void 0&&(t[r]=e[r]);for(const r in e)t[r]===void 0&&(t[r]=e[r]);return t}function zR(e,n=2){return e=YI(e,ma.$root),e.layers&&(e.layers=e.layers.map(t=>YI(t,ma.layer))),_X(e,{indent:n})}function iM(e,n){for(const t in e)t.indexOf("layout")===0&&n(e[t],t)}function qI(e,n){for(const t in e)t.indexOf("paint")===0&&n(e[t],t)}function S6(e,n){return typeof n=="string"&&n[0]==="@"?S6(e,e.constants[n]):n}function bX(e){return Array.isArray(e.stops)}function jv(e,n,t){e[t]=e[n],delete e[n]}function xX(e){e.version=8,cX(e,i=>{i.type==="video"&&i.url!==void 0&&jv(i,"url","urls"),i.type==="video"&&i.coordinates.forEach(o=>o.reverse())}),OC(e,i=>{iM(i,o=>{o["symbol-min-distance"]!==void 0&&jv(o,"symbol-min-distance","symbol-spacing")}),qI(i,o=>{o["background-image"]!==void 0&&jv(o,"background-image","background-pattern"),o["line-image"]!==void 0&&jv(o,"line-image","line-pattern"),o["fill-image"]!==void 0&&jv(o,"fill-image","fill-pattern")})}),BB(e,{paint:!0,layout:!0},i=>{const o=S6(e,i.value);bX(o)&&o.stops.forEach(s=>{s[1]=S6(e,s[1])}),i.set(o)}),delete e.constants,OC(e,i=>{iM(i,o=>{delete o["text-max-size"],delete o["icon-max-size"]}),qI(i,o=>{o["text-size"]&&(i.layout||(i.layout={}),i.layout["text-size"]=o["text-size"],delete o["text-size"]),o["icon-size"]&&(i.layout||(i.layout={}),i.layout["icon-size"]=o["icon-size"],delete o["icon-size"])})});function n(i){function o(s){return s.split(",").map(a=>a.trim())}if(Array.isArray(i))return i;if(typeof i=="string")return o(i);if(typeof i=="object")return i.stops.forEach(s=>{s[1]=o(s[1])}),i;throw new Error("unexpected font value")}OC(e,i=>{iM(i,o=>{o["text-font"]&&(o["text-font"]=n(o["text-font"]))})});let t=0;for(let i=e.layers.length-1;i>=0;i--)if(e.layers[i].type!=="symbol"){t=i+1;break}const r=e.layers.splice(t);return r.reverse(),e.layers=e.layers.concat(r),e}function wX(e){const n=[];return OC(e,t=>{t.filter&&(t.filter=EC(t.filter))}),BB(e,{paint:!0,layout:!0},({path:t,value:r,reference:i,set:o})=>{N_(r)||(typeof r=="object"&&!Array.isArray(r)?(o(wR(r,i)),n.push(t.join("."))):i.tokens&&typeof r=="string"&&o(MR(r)))}),e}function MX(e){return JSON.parse(SX(JSON.stringify(e)))}function SX(e){return e.replace(/"hsla?\((.+?)\)"/gi,(n,t)=>{const r=t.match(/^(.+?)\s*,\s*(.+?)\s*,\s*(.+?)(?:\s*,\s*(.+))?$/i);if(r){let[i,o,s,a]=r.slice(1);return[o,s]=[o,s].map(f=>f.endsWith("%")?f:`${parseFloat(f)*100}%`),`"hsl${typeof a=="string"?"a":""}(${[i,o,s,a].filter(Boolean).join(",")})"`}return n})}function EX(e){let n=!1;if(e.version===7&&(e=xX(e),n=!0),e.version===8&&(n=!!wX(e),n=!0),BB(e,{paint:!0,layout:!0},({value:t,reference:r,set:i})=>{r.type==="color"&&i(MX(t))}),!n)throw new Error(`Cannot migrate from ${e.version}`);return e}const OX={StyleExpression:_R,StylePropertyFunction:bR,ZoomConstantExpression:x6,ZoomDependentExpression:w6,createExpression:wB,createPropertyExpression:MB,isExpression:N_,isExpressionFilter:e5,isZoomExpression:eX,normalizePropertyExpression:tX},BX={convertFunction:wR,createFunction:xB,isFunction:j_};var jR={exports:{}};(function(e,n){(function(t,r){e.exports=r()})(mf,function(){var t,r,i;function o(a,f){if(!t)t=f;else if(!r)r=f;else{var g="var sharedChunk = {}; ("+t+")(sharedChunk); ("+r+")(sharedChunk);",x={};t(x),i=f(x),typeof window<"u"&&(i.workerUrl=window.URL.createObjectURL(new Blob([g],{type:"text/javascript"})))}}o(["exports"],function(a){function f(c,l,d,y){return new(d||(d=Promise))(function(w,T){function K(Q){try{z(y.next(Q))}catch(ie){T(ie)}}function D(Q){try{z(y.throw(Q))}catch(ie){T(ie)}}function z(Q){var ie;Q.done?w(Q.value):(ie=Q.value,ie instanceof d?ie:new d(function(le){le(ie)})).then(K,D)}z((y=y.apply(c,l||[])).next())})}function g(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}typeof SuppressedError=="function"&&SuppressedError;var x=k;function k(c,l){this.x=c,this.y=l}k.prototype={clone:function(){return new k(this.x,this.y)},add:function(c){return this.clone()._add(c)},sub:function(c){return this.clone()._sub(c)},multByPoint:function(c){return this.clone()._multByPoint(c)},divByPoint:function(c){return this.clone()._divByPoint(c)},mult:function(c){return this.clone()._mult(c)},div:function(c){return this.clone()._div(c)},rotate:function(c){return this.clone()._rotate(c)},rotateAround:function(c,l){return this.clone()._rotateAround(c,l)},matMult:function(c){return this.clone()._matMult(c)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(c){return this.x===c.x&&this.y===c.y},dist:function(c){return Math.sqrt(this.distSqr(c))},distSqr:function(c){var l=c.x-this.x,d=c.y-this.y;return l*l+d*d},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(c){return Math.atan2(this.y-c.y,this.x-c.x)},angleWith:function(c){return this.angleWithSep(c.x,c.y)},angleWithSep:function(c,l){return Math.atan2(this.x*l-this.y*c,this.x*c+this.y*l)},_matMult:function(c){var l=c[2]*this.x+c[3]*this.y;return this.x=c[0]*this.x+c[1]*this.y,this.y=l,this},_add:function(c){return this.x+=c.x,this.y+=c.y,this},_sub:function(c){return this.x-=c.x,this.y-=c.y,this},_mult:function(c){return this.x*=c,this.y*=c,this},_div:function(c){return this.x/=c,this.y/=c,this},_multByPoint:function(c){return this.x*=c.x,this.y*=c.y,this},_divByPoint:function(c){return this.x/=c.x,this.y/=c.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var c=this.y;return this.y=this.x,this.x=-c,this},_rotate:function(c){var l=Math.cos(c),d=Math.sin(c),y=d*this.x+l*this.y;return this.x=l*this.x-d*this.y,this.y=y,this},_rotateAround:function(c,l){var d=Math.cos(c),y=Math.sin(c),w=l.y+y*(this.x-l.x)+d*(this.y-l.y);return this.x=l.x+d*(this.x-l.x)-y*(this.y-l.y),this.y=w,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},k.convert=function(c){return c instanceof k?c:Array.isArray(c)?new k(c[0],c[1]):c};var B=g(x),P=R;function R(c,l,d,y){this.cx=3*c,this.bx=3*(d-c)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*l,this.by=3*(y-l)-this.cy,this.ay=1-this.cy-this.by,this.p1x=c,this.p1y=l,this.p2x=d,this.p2y=y}R.prototype={sampleCurveX:function(c){return((this.ax*c+this.bx)*c+this.cx)*c},sampleCurveY:function(c){return((this.ay*c+this.by)*c+this.cy)*c},sampleCurveDerivativeX:function(c){return(3*this.ax*c+2*this.bx)*c+this.cx},solveCurveX:function(c,l){if(l===void 0&&(l=1e-6),c<0)return 0;if(c>1)return 1;for(var d=c,y=0;y<8;y++){var w=this.sampleCurveX(d)-c;if(Math.abs(w)<l)return d;var T=this.sampleCurveDerivativeX(d);if(Math.abs(T)<1e-6)break;d-=w/T}var K=0,D=1;for(d=c,y=0;y<20&&(w=this.sampleCurveX(d),!(Math.abs(w-c)<l));y++)c>w?K=d:D=d,d=.5*(D-K)+K;return d},solve:function(c,l){return this.sampleCurveY(this.solveCurveX(c,l))}};var H=g(P);let W,$;function q(){return W==null&&(W=typeof OffscreenCanvas<"u"&&new OffscreenCanvas(1,1).getContext("2d")&&typeof createImageBitmap=="function"),W}function oe(){if($==null&&($=!1,q())){const l=new OffscreenCanvas(5,5).getContext("2d",{willReadFrequently:!0});if(l){for(let y=0;y<5*5;y++){const w=4*y;l.fillStyle=`rgb(${w},${w+1},${w+2})`,l.fillRect(y%5,Math.floor(y/5),1,1)}const d=l.getImageData(0,0,5,5).data;for(let y=0;y<5*5*4;y++)if(y%4!=3&&d[y]!==y){$=!0;break}}}return $||!1}function ne(c,l,d,y){const w=new H(c,l,d,y);return function(T){return w.solve(T)}}const ce=ne(.25,.1,.25,1);function ae(c,l,d){return Math.min(d,Math.max(l,c))}function ue(c,l,d){const y=d-l,w=((c-l)%y+y)%y+l;return w===l?d:w}function ye(c,...l){for(const d of l)for(const y in d)c[y]=d[y];return c}let Re=1;function Ne(c,l,d){const y={};for(const w in c)y[w]=l.call(d||this,c[w],w,c);return y}function rt(c,l,d){const y={};for(const w in c)l.call(d||this,c[w],w,c)&&(y[w]=c[w]);return y}function ct(c){return Array.isArray(c)?c.map(ct):typeof c=="object"&&c?Ne(c,ct):c}const Fe={};function He(c){Fe[c]||(typeof console<"u"&&console.warn(c),Fe[c]=!0)}function Ce(c,l,d){return(d.y-c.y)*(l.x-c.x)>(l.y-c.y)*(d.x-c.x)}function jt(c){let l=0;for(let d,y,w=0,T=c.length,K=T-1;w<T;K=w++)d=c[w],y=c[K],l+=(y.x-d.x)*(d.y+y.y);return l}function Ft(c){return typeof WorkerGlobalScope<"u"&&c!==void 0&&c instanceof WorkerGlobalScope}let Jt=null;function Nt(c){return typeof ImageBitmap<"u"&&c instanceof ImageBitmap}const Ve="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";function nt(c,l,d,y,w){return f(this,void 0,void 0,function*(){if(typeof VideoFrame>"u")throw new Error("VideoFrame not supported");const T=new VideoFrame(c,{timestamp:0});try{const K=T==null?void 0:T.format;if(!K||!K.startsWith("BGR")&&!K.startsWith("RGB"))throw new Error(`Unrecognized format ${K}`);const D=K.startsWith("BGR"),z=new Uint8ClampedArray(y*w*4);if(yield T.copyTo(z,function(Q,ie,le,ge,Oe){const Be=4*Math.max(-ie,0),ze=(Math.max(0,le)-le)*ge*4+Be,$e=4*ge,tt=Math.max(0,ie),St=Math.max(0,le);return{rect:{x:tt,y:St,width:Math.min(Q.width,ie+ge)-tt,height:Math.min(Q.height,le+Oe)-St},layout:[{offset:ze,stride:$e}]}}(c,l,d,y,w)),D)for(let Q=0;Q<z.length;Q+=4){const ie=z[Q];z[Q]=z[Q+2],z[Q+2]=ie}return z}finally{T.close()}})}let Je,Vt;const pt="AbortError";function dt(){return new Error(pt)}const kt={MAX_PARALLEL_IMAGE_REQUESTS:16,MAX_PARALLEL_IMAGE_REQUESTS_PER_FRAME:8,MAX_TILE_CACHE_ZOOM_LEVELS:5,REGISTERED_PROTOCOLS:{},WORKER_URL:""};function Dt(c){return kt.REGISTERED_PROTOCOLS[c.substring(0,c.indexOf("://"))]}const Se="global-dispatcher";class de extends Error{constructor(l,d,y,w){super(`AJAXError: ${d} (${l}): ${y}`),this.status=l,this.statusText=d,this.url=y,this.body=w}}const xe=()=>Ft(self)?self.worker&&self.worker.referrer:(window.location.protocol==="blob:"?window.parent:window).location.href,Pe=function(c,l){if(/:\/\//.test(c.url)&&!/^https?:|^file:/.test(c.url)){const y=Dt(c.url);if(y)return y(c,l);if(Ft(self)&&self.worker&&self.worker.actor)return self.worker.actor.sendAsync({type:"getResource",data:c,targetMapId:Se},l)}if(!(/^file:/.test(d=c.url)||/^file:/.test(xe())&&!/^\w+:/.test(d))){if(fetch&&Request&&AbortController&&Object.prototype.hasOwnProperty.call(Request.prototype,"signal"))return function(y,w){return f(this,void 0,void 0,function*(){const T=new Request(y.url,{method:y.method||"GET",body:y.body,credentials:y.credentials,headers:y.headers,cache:y.cache,referrer:xe(),signal:w.signal});y.type==="json"&&T.headers.set("Accept","application/json");const K=yield fetch(T);if(!K.ok){const Q=yield K.blob();throw new de(K.status,K.statusText,y.url,Q)}const D=y.type==="arrayBuffer"||y.type==="image"?K.arrayBuffer():y.type==="json"?K.json():K.text(),z=yield D;if(w.signal.aborted)throw dt();return{data:z,cacheControl:K.headers.get("Cache-Control"),expires:K.headers.get("Expires")}})}(c,l);if(Ft(self)&&self.worker&&self.worker.actor)return self.worker.actor.sendAsync({type:"getResource",data:c,mustQueue:!0,targetMapId:Se},l)}var d;return function(y,w){return new Promise((T,K)=>{const D=new XMLHttpRequest;D.open(y.method||"GET",y.url,!0),y.type!=="arrayBuffer"&&y.type!=="image"||(D.responseType="arraybuffer");for(const z in y.headers)D.setRequestHeader(z,y.headers[z]);y.type==="json"&&(D.responseType="text",D.setRequestHeader("Accept","application/json")),D.withCredentials=y.credentials==="include",D.onerror=()=>{K(new Error(D.statusText))},D.onload=()=>{if(!w.signal.aborted)if((D.status>=200&&D.status<300||D.status===0)&&D.response!==null){let z=D.response;if(y.type==="json")try{z=JSON.parse(D.response)}catch(Q){return void K(Q)}T({data:z,cacheControl:D.getResponseHeader("Cache-Control"),expires:D.getResponseHeader("Expires")})}else{const z=new Blob([D.response],{type:D.getResponseHeader("Content-Type")});K(new de(D.status,D.statusText,y.url,z))}},w.signal.addEventListener("abort",()=>{D.abort(),K(dt())}),D.send(y.body)})}(c,l)};function Ze(c){if(!c||c.indexOf("://")<=0||c.indexOf("data:image/")===0||c.indexOf("blob:")===0)return!0;const l=new URL(c),d=window.location;return l.protocol===d.protocol&&l.host===d.host}function Xe(c,l,d){d[c]&&d[c].indexOf(l)!==-1||(d[c]=d[c]||[],d[c].push(l))}function wt(c,l,d){if(d&&d[c]){const y=d[c].indexOf(l);y!==-1&&d[c].splice(y,1)}}class Kt{constructor(l,d={}){ye(this,d),this.type=l}}class Pt extends Kt{constructor(l,d={}){super("error",ye({error:l},d))}}class zn{on(l,d){return this._listeners=this._listeners||{},Xe(l,d,this._listeners),this}off(l,d){return wt(l,d,this._listeners),wt(l,d,this._oneTimeListeners),this}once(l,d){return d?(this._oneTimeListeners=this._oneTimeListeners||{},Xe(l,d,this._oneTimeListeners),this):new Promise(y=>this.once(l,y))}fire(l,d){typeof l=="string"&&(l=new Kt(l,d||{}));const y=l.type;if(this.listens(y)){l.target=this;const w=this._listeners&&this._listeners[y]?this._listeners[y].slice():[];for(const D of w)D.call(this,l);const T=this._oneTimeListeners&&this._oneTimeListeners[y]?this._oneTimeListeners[y].slice():[];for(const D of T)wt(y,D,this._oneTimeListeners),D.call(this,l);const K=this._eventedParent;K&&(ye(l,typeof this._eventedParentData=="function"?this._eventedParentData():this._eventedParentData),K.fire(l))}else l instanceof Pt&&console.error(l.error);return this}listens(l){return this._listeners&&this._listeners[l]&&this._listeners[l].length>0||this._oneTimeListeners&&this._oneTimeListeners[l]&&this._oneTimeListeners[l].length>0||this._eventedParent&&this._eventedParent.listens(l)}setEventedParent(l,d){return this._eventedParent=l,this._eventedParentData=d,this}}var mt={$version:8,$root:{version:{required:!0,type:"enum",values:[8]},name:{type:"string"},metadata:{type:"*"},center:{type:"array",value:"number"},zoom:{type:"number"},bearing:{type:"number",default:0,period:360,units:"degrees"},pitch:{type:"number",default:0,units:"degrees"},light:{type:"light"},sky:{type:"sky"},terrain:{type:"terrain"},sources:{required:!0,type:"sources"},sprite:{type:"sprite"},glyphs:{type:"string"},transition:{type:"transition"},layers:{required:!0,type:"array",value:"layer"}},sources:{"*":{type:"source"}},source:["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],source_vector:{type:{required:!0,type:"enum",values:{vector:{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},scheme:{type:"enum",values:{xyz:{},tms:{}},default:"xyz"},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},attribution:{type:"string"},promoteId:{type:"promoteId"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_raster:{type:{required:!0,type:"enum",values:{raster:{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},tileSize:{type:"number",default:512,units:"pixels"},scheme:{type:"enum",values:{xyz:{},tms:{}},default:"xyz"},attribution:{type:"string"},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_raster_dem:{type:{required:!0,type:"enum",values:{"raster-dem":{}}},url:{type:"string"},tiles:{type:"array",value:"string"},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129]},minzoom:{type:"number",default:0},maxzoom:{type:"number",default:22},tileSize:{type:"number",default:512,units:"pixels"},attribution:{type:"string"},encoding:{type:"enum",values:{terrarium:{},mapbox:{},custom:{}},default:"mapbox"},redFactor:{type:"number",default:1},blueFactor:{type:"number",default:1},greenFactor:{type:"number",default:1},baseShift:{type:"number",default:0},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_geojson:{type:{required:!0,type:"enum",values:{geojson:{}}},data:{required:!0,type:"*"},maxzoom:{type:"number",default:18},attribution:{type:"string"},buffer:{type:"number",default:128,maximum:512,minimum:0},filter:{type:"*"},tolerance:{type:"number",default:.375},cluster:{type:"boolean",default:!1},clusterRadius:{type:"number",default:50,minimum:0},clusterMaxZoom:{type:"number"},clusterMinPoints:{type:"number"},clusterProperties:{type:"*"},lineMetrics:{type:"boolean",default:!1},generateId:{type:"boolean",default:!1},promoteId:{type:"promoteId"}},source_video:{type:{required:!0,type:"enum",values:{video:{}}},urls:{required:!0,type:"array",value:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},source_image:{type:{required:!0,type:"enum",values:{image:{}}},url:{required:!0,type:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},layer:{id:{type:"string",required:!0},type:{type:"enum",values:{fill:{},line:{},symbol:{},circle:{},heatmap:{},"fill-extrusion":{},raster:{},hillshade:{},background:{}},required:!0},metadata:{type:"*"},source:{type:"string"},"source-layer":{type:"string"},minzoom:{type:"number",minimum:0,maximum:24},maxzoom:{type:"number",minimum:0,maximum:24},filter:{type:"filter"},layout:{type:"layout"},paint:{type:"paint"}},layout:["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background"],layout_background:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_fill:{"fill-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_circle:{"circle-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_heatmap:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_line:{"line-cap":{type:"enum",values:{butt:{},round:{},square:{}},default:"butt",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-join":{type:"enum",values:{bevel:{},round:{},miter:{}},default:"miter",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{type:"number",default:2,requires:[{"line-join":"miter"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-round-limit":{type:"number",default:1.05,requires:[{"line-join":"round"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_symbol:{"symbol-placement":{type:"enum",values:{point:{},line:{},"line-center":{}},default:"point",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-spacing":{type:"number",default:250,minimum:1,units:"pixels",requires:[{"symbol-placement":"line"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{type:"boolean",default:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{type:"enum",values:{auto:{},"viewport-y":{},source:{}},default:"auto",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{type:"boolean",default:!1,requires:["icon-image",{"!":"icon-overlap"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-overlap":{type:"enum",values:{never:{},always:{},cooperative:{}},requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{type:"boolean",default:!1,requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-optional":{type:"boolean",default:!1,requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-size":{type:"number",default:1,minimum:0,units:"factor of the original icon size",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{type:"enum",values:{none:{},width:{},height:{},both:{}},default:"none",requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",requires:["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-image":{type:"resolvedImage",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{type:"padding",default:[2],units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-keep-upright":{type:"boolean",default:!1,requires:["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{type:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},default:"center",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{type:"enum",values:{map:{},viewport:{},"viewport-glyph":{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-field":{type:"formatted",default:"",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-font":{type:"array",value:"string",default:["Open Sans Regular","Arial Unicode MS Regular"],requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-size":{type:"number",default:16,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{type:"number",default:1.2,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-letter-spacing":{type:"number",default:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-justify":{type:"enum",values:{auto:{},left:{},center:{},right:{}},default:"center",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{type:"number",units:"ems",default:0,requires:["text-field"],"property-type":"data-driven",expression:{interpolated:!0,parameters:["zoom","feature"]}},"text-variable-anchor":{type:"array",value:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-variable-anchor-offset":{type:"variableAnchorOffsetCollection",requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-anchor":{type:"enum",values:{center:{},left:{},right:{},top:{},bottom:{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},default:"center",requires:["text-field",{"!":"text-variable-anchor"}],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{type:"number",default:45,units:"degrees",requires:["text-field",{"symbol-placement":["line","line-center"]}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-writing-mode":{type:"array",value:"enum",values:{horizontal:{},vertical:{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-keep-upright":{type:"boolean",default:!0,requires:["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-transform":{type:"enum",values:{none:{},uppercase:{},lowercase:{}},default:"none",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-offset":{type:"array",value:"number",units:"ems",length:2,default:[0,0],requires:["text-field",{"!":"text-radial-offset"}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{type:"boolean",default:!1,requires:["text-field",{"!":"text-overlap"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-overlap":{type:"enum",values:{never:{},always:{},cooperative:{}},requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{type:"boolean",default:!1,requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-optional":{type:"boolean",default:!1,requires:["text-field","icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_raster:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},layout_hillshade:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible","property-type":"constant"}},filter:{type:"array",value:"*"},filter_operator:{type:"enum",values:{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},in:{},"!in":{},all:{},any:{},none:{},has:{},"!has":{},within:{}}},geometry_type:{type:"enum",values:{Point:{},LineString:{},Polygon:{}}},function:{expression:{type:"expression"},stops:{type:"array",value:"function_stop"},base:{type:"number",default:1,minimum:0},property:{type:"string",default:"$zoom"},type:{type:"enum",values:{identity:{},exponential:{},interval:{},categorical:{}},default:"exponential"},colorSpace:{type:"enum",values:{rgb:{},lab:{},hcl:{}},default:"rgb"},default:{type:"*",required:!1}},function_stop:{type:"array",minimum:0,maximum:24,value:["number","color"],length:2},expression:{type:"array",value:"*",minimum:1},light:{anchor:{type:"enum",default:"viewport",values:{map:{},viewport:{}},"property-type":"data-constant",transition:!1,expression:{interpolated:!1,parameters:["zoom"]}},position:{type:"array",default:[1.15,210,30],length:3,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},intensity:{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},sky:{"sky-color":{type:"color","property-type":"data-constant",default:"#88C6FC",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"fog-color":{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"fog-blend":{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"horizon-blend":{type:"number","property-type":"data-constant",default:.8,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},terrain:{source:{type:"string",required:!0},exaggeration:{type:"number",minimum:0,default:1}},paint:["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background"],paint_fill:{"fill-antialias":{type:"boolean",default:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{type:"color",transition:!0,requires:[{"!":"fill-pattern"},{"fill-antialias":!0}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"}},"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-extrusion-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-extrusion-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"fill-extrusion-height":{type:"number",default:0,minimum:0,units:"meters",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{type:"number",default:0,minimum:0,units:"meters",transition:!0,requires:["fill-extrusion-height"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{type:"boolean",default:!0,transition:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_line:{"line-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"line-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["line-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-width":{type:"number",default:1,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{type:"number",default:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{type:"array",value:"number",minimum:0,transition:!0,units:"line widths",requires:[{"!":"line-pattern"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"line-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-gradient":{type:"color",transition:!1,requires:[{"!":"line-dasharray"},{"!":"line-pattern"},{source:"geojson",has:{lineMetrics:!0}}],expression:{interpolated:!0,parameters:["line-progress"]},"property-type":"color-ramp"}},paint_circle:{"circle-radius":{type:"number",default:5,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{type:"number",default:0,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["circle-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{type:"enum",values:{map:{},viewport:{}},default:"map",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"}},paint_heatmap:{"heatmap-radius":{type:"number",default:30,minimum:1,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{type:"number",default:1,minimum:0,transition:!1,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{type:"number",default:1,minimum:0,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"heatmap-color":{type:"color",default:["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],transition:!1,expression:{interpolated:!0,parameters:["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_symbol:{"icon-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{type:"color",default:"#000000",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["icon-image","icon-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{type:"color",default:"#000000",transition:!0,overridable:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["text-field","text-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_raster:{"raster-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{type:"number",default:0,period:360,transition:!0,units:"degrees",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{type:"number",default:0,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-saturation":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-contrast":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-resampling":{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{type:"number",default:300,minimum:0,transition:!1,units:"milliseconds",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_hillshade:{"hillshade-illumination-direction":{type:"number",default:335,minimum:0,maximum:359,transition:!1,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{type:"number",default:.5,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_background:{"background-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"background-pattern"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"background-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},transition:{duration:{type:"number",default:300,minimum:0,units:"milliseconds"},delay:{type:"number",default:0,minimum:0,units:"milliseconds"}},"property-type":{"data-driven":{type:"property-type"},"cross-faded":{type:"property-type"},"cross-faded-data-driven":{type:"property-type"},"color-ramp":{type:"property-type"},"data-constant":{type:"property-type"},constant:{type:"property-type"}},promoteId:{"*":{type:"string"}}};const pn=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function ir(c,l){const d={};for(const y in c)y!=="ref"&&(d[y]=c[y]);return pn.forEach(y=>{y in l&&(d[y]=l[y])}),d}function Sn(c,l){if(Array.isArray(c)){if(!Array.isArray(l)||c.length!==l.length)return!1;for(let d=0;d<c.length;d++)if(!Sn(c[d],l[d]))return!1;return!0}if(typeof c=="object"&&c!==null&&l!==null){if(typeof l!="object"||Object.keys(c).length!==Object.keys(l).length)return!1;for(const d in c)if(!Sn(c[d],l[d]))return!1;return!0}return c===l}function nr(c,l){c.push(l)}function Mr(c,l,d){nr(d,{command:"addSource",args:[c,l[c]]})}function Qr(c,l,d){nr(l,{command:"removeSource",args:[c]}),d[c]=!0}function _r(c,l,d,y){Qr(c,d,y),Mr(c,l,d)}function vi(c,l,d){let y;for(y in c[d])if(Object.prototype.hasOwnProperty.call(c[d],y)&&y!=="data"&&!Sn(c[d][y],l[d][y]))return!1;for(y in l[d])if(Object.prototype.hasOwnProperty.call(l[d],y)&&y!=="data"&&!Sn(c[d][y],l[d][y]))return!1;return!0}function we(c,l,d,y,w,T){c=c||{},l=l||{};for(const K in c)Object.prototype.hasOwnProperty.call(c,K)&&(Sn(c[K],l[K])||d.push({command:T,args:[y,K,l[K],w]}));for(const K in l)Object.prototype.hasOwnProperty.call(l,K)&&!Object.prototype.hasOwnProperty.call(c,K)&&(Sn(c[K],l[K])||d.push({command:T,args:[y,K,l[K],w]}))}function V(c){return c.id}function X(c,l){return c[l.id]=l,c}class me{constructor(l,d,y,w){this.message=(l?`${l}: `:"")+y,w&&(this.identifier=w),d!=null&&d.__line__&&(this.line=d.__line__)}}function At(c,...l){for(const d of l)for(const y in d)c[y]=d[y];return c}class bt extends Error{constructor(l,d){super(d),this.message=d,this.key=l}}class Et{constructor(l,d=[]){this.parent=l,this.bindings={};for(const[y,w]of d)this.bindings[y]=w}concat(l){return new Et(this,l)}get(l){if(this.bindings[l])return this.bindings[l];if(this.parent)return this.parent.get(l);throw new Error(`${l} not found in scope.`)}has(l){return!!this.bindings[l]||!!this.parent&&this.parent.has(l)}}const sr={kind:"null"},Lt={kind:"number"},Fn={kind:"string"},on={kind:"boolean"},m={kind:"color"},un={kind:"object"},In={kind:"value"},Gn={kind:"collator"},Zn={kind:"formatted"},Ke={kind:"padding"},fe={kind:"resolvedImage"},_e={kind:"variableAnchorOffsetCollection"};function Ee(c,l){return{kind:"array",itemType:c,N:l}}function Te(c){if(c.kind==="array"){const l=Te(c.itemType);return typeof c.N=="number"?`array<${l}, ${c.N}>`:c.itemType.kind==="value"?"array":`array<${l}>`}return c.kind}const at=[sr,Lt,Fn,on,m,Zn,un,Ee(In),Ke,fe,_e];function it(c,l){if(l.kind==="error")return null;if(c.kind==="array"){if(l.kind==="array"&&(l.N===0&&l.itemType.kind==="value"||!it(c.itemType,l.itemType))&&(typeof c.N!="number"||c.N===l.N))return null}else{if(c.kind===l.kind)return null;if(c.kind==="value"){for(const d of at)if(!it(d,l))return null}}return`Expected ${Te(c)} but found ${Te(l)} instead.`}function ht(c,l){return l.some(d=>d.kind===c.kind)}function et(c,l){return l.some(d=>d==="null"?c===null:d==="array"?Array.isArray(c):d==="object"?c&&!Array.isArray(c)&&typeof c=="object":d===typeof c)}function Ct(c,l){return c.kind==="array"&&l.kind==="array"?c.itemType.kind===l.itemType.kind&&typeof c.N=="number":c.kind===l.kind}const rn=.96422,Gt=.82521,$t=4/29,gn=6/29,Jn=3*gn*gn,qn=gn*gn*gn,Tr=Math.PI/180,vr=180/Math.PI;function Dr(c){return(c%=360)<0&&(c+=360),c}function Yr([c,l,d,y]){let w,T;const K=Cr((.2225045*(c=Zr(c))+.7168786*(l=Zr(l))+.0606169*(d=Zr(d)))/1);c===l&&l===d?w=T=K:(w=Cr((.4360747*c+.3850649*l+.1430804*d)/rn),T=Cr((.0139322*c+.0971045*l+.7141733*d)/Gt));const D=116*K-16;return[D<0?0:D,500*(w-K),200*(K-T),y]}function Zr(c){return c<=.04045?c/12.92:Math.pow((c+.055)/1.055,2.4)}function Cr(c){return c>qn?Math.pow(c,1/3):c/Jn+$t}function ui([c,l,d,y]){let w=(c+16)/116,T=isNaN(l)?w:w+l/500,K=isNaN(d)?w:w-d/200;return w=1*Io(w),T=rn*Io(T),K=Gt*Io(K),[Ii(3.1338561*T-1.6168667*w-.4906146*K),Ii(-.9787684*T+1.9161415*w+.033454*K),Ii(.0719453*T-.2289914*w+1.4052427*K),y]}function Ii(c){return(c=c<=.00304?12.92*c:1.055*Math.pow(c,1/2.4)-.055)<0?0:c>1?1:c}function Io(c){return c>gn?c*c*c:Jn*(c-$t)}function Ci(c){return parseInt(c.padEnd(2,c),16)/255}function so(c,l){return Yo(l?c/100:c,0,1)}function Yo(c,l,d){return Math.min(Math.max(l,c),d)}function ba(c){return!c.some(Number.isNaN)}const Ql={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};class Ai{constructor(l,d,y,w=1,T=!0){this.r=l,this.g=d,this.b=y,this.a=w,T||(this.r*=w,this.g*=w,this.b*=w,w||this.overwriteGetter("rgb",[l,d,y,w]))}static parse(l){if(l instanceof Ai)return l;if(typeof l!="string")return;const d=function(y){if((y=y.toLowerCase().trim())==="transparent")return[0,0,0,0];const w=Ql[y];if(w){const[K,D,z]=w;return[K/255,D/255,z/255,1]}if(y.startsWith("#")&&/^#(?:[0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/.test(y)){const K=y.length<6?1:2;let D=1;return[Ci(y.slice(D,D+=K)),Ci(y.slice(D,D+=K)),Ci(y.slice(D,D+=K)),Ci(y.slice(D,D+K)||"ff")]}if(y.startsWith("rgb")){const K=y.match(/^rgba?\(\s*([\de.+-]+)(%)?(?:\s+|\s*(,)\s*)([\de.+-]+)(%)?(?:\s+|\s*(,)\s*)([\de.+-]+)(%)?(?:\s*([,\/])\s*([\de.+-]+)(%)?)?\s*\)$/);if(K){const[D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt,St]=K,lt=[ie||" ",Oe||" ",$e].join("");if(lt===" "||lt===" /"||lt===",,"||lt===",,,"){const vt=[Q,ge,ze].join(""),tn=vt==="%%%"?100:vt===""?255:0;if(tn){const an=[Yo(+z/tn,0,1),Yo(+le/tn,0,1),Yo(+Be/tn,0,1),tt?so(+tt,St):1];if(ba(an))return an}}return}}const T=y.match(/^hsla?\(\s*([\de.+-]+)(?:deg)?(?:\s+|\s*(,)\s*)([\de.+-]+)%(?:\s+|\s*(,)\s*)([\de.+-]+)%(?:\s*([,\/])\s*([\de.+-]+)(%)?)?\s*\)$/);if(T){const[K,D,z,Q,ie,le,ge,Oe,Be]=T,ze=[z||" ",ie||" ",ge].join("");if(ze===" "||ze===" /"||ze===",,"||ze===",,,"){const $e=[+D,Yo(+Q,0,100),Yo(+le,0,100),Oe?so(+Oe,Be):1];if(ba($e))return function([tt,St,lt,vt]){function tn(an){const Vn=(an+tt/30)%12,cr=St*Math.min(lt,1-lt);return lt-cr*Math.max(-1,Math.min(Vn-3,9-Vn,1))}return tt=Dr(tt),St/=100,lt/=100,[tn(0),tn(8),tn(4),vt]}($e)}}}(l);return d?new Ai(...d,!1):void 0}get rgb(){const{r:l,g:d,b:y,a:w}=this,T=w||1/0;return this.overwriteGetter("rgb",[l/T,d/T,y/T,w])}get hcl(){return this.overwriteGetter("hcl",function(l){const[d,y,w,T]=Yr(l),K=Math.sqrt(y*y+w*w);return[Math.round(1e4*K)?Dr(Math.atan2(w,y)*vr):NaN,K,d,T]}(this.rgb))}get lab(){return this.overwriteGetter("lab",Yr(this.rgb))}overwriteGetter(l,d){return Object.defineProperty(this,l,{value:d}),d}toString(){const[l,d,y,w]=this.rgb;return`rgba(${[l,d,y].map(T=>Math.round(255*T)).join(",")},${w})`}}Ai.black=new Ai(0,0,0,1),Ai.white=new Ai(1,1,1,1),Ai.transparent=new Ai(0,0,0,0),Ai.red=new Ai(1,0,0,1);class Mi{constructor(l,d,y){this.sensitivity=l?d?"variant":"case":d?"accent":"base",this.locale=y,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})}compare(l,d){return this.collator.compare(l,d)}resolvedLocale(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale}}class rr{constructor(l,d,y,w,T){this.text=l,this.image=d,this.scale=y,this.fontStack=w,this.textColor=T}}class lo{constructor(l){this.sections=l}static fromString(l){return new lo([new rr(l,null,null,null,null)])}isEmpty(){return this.sections.length===0||!this.sections.some(l=>l.text.length!==0||l.image&&l.image.name.length!==0)}static factory(l){return l instanceof lo?l:lo.fromString(l)}toString(){return this.sections.length===0?"":this.sections.map(l=>l.text).join("")}}class Gi{constructor(l){this.values=l.slice()}static parse(l){if(l instanceof Gi)return l;if(typeof l=="number")return new Gi([l,l,l,l]);if(Array.isArray(l)&&!(l.length<1||l.length>4)){for(const d of l)if(typeof d!="number")return;switch(l.length){case 1:l=[l[0],l[0],l[0],l[0]];break;case 2:l=[l[0],l[1],l[0],l[1]];break;case 3:l=[l[0],l[1],l[2],l[1]]}return new Gi(l)}}toString(){return JSON.stringify(this.values)}}const la=new Set(["center","left","right","top","bottom","top-left","top-right","bottom-left","bottom-right"]);class ve{constructor(l){this.values=l.slice()}static parse(l){if(l instanceof ve)return l;if(Array.isArray(l)&&!(l.length<1)&&l.length%2==0){for(let d=0;d<l.length;d+=2){const y=l[d],w=l[d+1];if(typeof y!="string"||!la.has(y)||!Array.isArray(w)||w.length!==2||typeof w[0]!="number"||typeof w[1]!="number")return}return new ve(l)}}toString(){return JSON.stringify(this.values)}}class Ge{constructor(l){this.name=l.name,this.available=l.available}toString(){return this.name}static fromString(l){return l?new Ge({name:l,available:!1}):null}}function Ht(c,l,d,y){return typeof c=="number"&&c>=0&&c<=255&&typeof l=="number"&&l>=0&&l<=255&&typeof d=="number"&&d>=0&&d<=255?y===void 0||typeof y=="number"&&y>=0&&y<=1?null:`Invalid rgba value [${[c,l,d,y].join(", ")}]: 'a' must be between 0 and 1.`:`Invalid rgba value [${(typeof y=="number"?[c,l,d,y]:[c,l,d]).join(", ")}]: 'r', 'g', and 'b' must be between 0 and 255.`}function mn(c){if(c===null||typeof c=="string"||typeof c=="boolean"||typeof c=="number"||c instanceof Ai||c instanceof Mi||c instanceof lo||c instanceof Gi||c instanceof ve||c instanceof Ge)return!0;if(Array.isArray(c)){for(const l of c)if(!mn(l))return!1;return!0}if(typeof c=="object"){for(const l in c)if(!mn(c[l]))return!1;return!0}return!1}function Ot(c){if(c===null)return sr;if(typeof c=="string")return Fn;if(typeof c=="boolean")return on;if(typeof c=="number")return Lt;if(c instanceof Ai)return m;if(c instanceof Mi)return Gn;if(c instanceof lo)return Zn;if(c instanceof Gi)return Ke;if(c instanceof ve)return _e;if(c instanceof Ge)return fe;if(Array.isArray(c)){const l=c.length;let d;for(const y of c){const w=Ot(y);if(d){if(d===w)continue;d=In;break}d=w}return Ee(d||In,l)}return un}function En(c){const l=typeof c;return c===null?"":l==="string"||l==="number"||l==="boolean"?String(c):c instanceof Ai||c instanceof lo||c instanceof Gi||c instanceof ve||c instanceof Ge?c.toString():JSON.stringify(c)}class zr{constructor(l,d){this.type=l,this.value=d}static parse(l,d){if(l.length!==2)return d.error(`'literal' expression requires exactly one argument, but found ${l.length-1} instead.`);if(!mn(l[1]))return d.error("invalid value");const y=l[1];let w=Ot(y);const T=d.expectedType;return w.kind!=="array"||w.N!==0||!T||T.kind!=="array"||typeof T.N=="number"&&T.N!==0||(w=T),new zr(w,y)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}}class Lr{constructor(l){this.name="ExpressionEvaluationError",this.message=l}toJSON(){return this.message}}const Ti={string:Fn,number:Lt,boolean:on,object:un};class po{constructor(l,d){this.type=l,this.args=d}static parse(l,d){if(l.length<2)return d.error("Expected at least one argument.");let y,w=1;const T=l[0];if(T==="array"){let D,z;if(l.length>2){const Q=l[1];if(typeof Q!="string"||!(Q in Ti)||Q==="object")return d.error('The item type argument of "array" must be one of string, number, boolean',1);D=Ti[Q],w++}else D=In;if(l.length>3){if(l[2]!==null&&(typeof l[2]!="number"||l[2]<0||l[2]!==Math.floor(l[2])))return d.error('The length argument to "array" must be a positive integer literal',2);z=l[2],w++}y=Ee(D,z)}else{if(!Ti[T])throw new Error(`Types doesn't contain name = ${T}`);y=Ti[T]}const K=[];for(;w<l.length;w++){const D=d.parse(l[w],w,In);if(!D)return null;K.push(D)}return new po(y,K)}evaluate(l){for(let d=0;d<this.args.length;d++){const y=this.args[d].evaluate(l);if(!it(this.type,Ot(y)))return y;if(d===this.args.length-1)throw new Lr(`Expected value to be of type ${Te(this.type)}, but found ${Te(Ot(y))} instead.`)}throw new Error}eachChild(l){this.args.forEach(l)}outputDefined(){return this.args.every(l=>l.outputDefined())}}const Cl={"to-boolean":on,"to-color":m,"to-number":Lt,"to-string":Fn};class br{constructor(l,d){this.type=l,this.args=d}static parse(l,d){if(l.length<2)return d.error("Expected at least one argument.");const y=l[0];if(!Cl[y])throw new Error(`Can't parse ${y} as it is not part of the known types`);if((y==="to-boolean"||y==="to-string")&&l.length!==2)return d.error("Expected one argument.");const w=Cl[y],T=[];for(let K=1;K<l.length;K++){const D=d.parse(l[K],K,In);if(!D)return null;T.push(D)}return new br(w,T)}evaluate(l){switch(this.type.kind){case"boolean":return!!this.args[0].evaluate(l);case"color":{let d,y;for(const w of this.args){if(d=w.evaluate(l),y=null,d instanceof Ai)return d;if(typeof d=="string"){const T=l.parseColor(d);if(T)return T}else if(Array.isArray(d)&&(y=d.length<3||d.length>4?`Invalid rbga value ${JSON.stringify(d)}: expected an array containing either three or four numeric values.`:Ht(d[0],d[1],d[2],d[3]),!y))return new Ai(d[0]/255,d[1]/255,d[2]/255,d[3])}throw new Lr(y||`Could not parse color from value '${typeof d=="string"?d:JSON.stringify(d)}'`)}case"padding":{let d;for(const y of this.args){d=y.evaluate(l);const w=Gi.parse(d);if(w)return w}throw new Lr(`Could not parse padding from value '${typeof d=="string"?d:JSON.stringify(d)}'`)}case"variableAnchorOffsetCollection":{let d;for(const y of this.args){d=y.evaluate(l);const w=ve.parse(d);if(w)return w}throw new Lr(`Could not parse variableAnchorOffsetCollection from value '${typeof d=="string"?d:JSON.stringify(d)}'`)}case"number":{let d=null;for(const y of this.args){if(d=y.evaluate(l),d===null)return 0;const w=Number(d);if(!isNaN(w))return w}throw new Lr(`Could not convert ${JSON.stringify(d)} to number.`)}case"formatted":return lo.fromString(En(this.args[0].evaluate(l)));case"resolvedImage":return Ge.fromString(En(this.args[0].evaluate(l)));default:return En(this.args[0].evaluate(l))}}eachChild(l){this.args.forEach(l)}outputDefined(){return this.args.every(l=>l.outputDefined())}}const _i=["Unknown","Point","LineString","Polygon"];class _l{constructor(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache={},this.availableImages=null,this.canonical=null}id(){return this.feature&&"id"in this.feature?this.feature.id:null}geometryType(){return this.feature?typeof this.feature.type=="number"?_i[this.feature.type]:this.feature.type:null}geometry(){return this.feature&&"geometry"in this.feature?this.feature.geometry:null}canonicalID(){return this.canonical}properties(){return this.feature&&this.feature.properties||{}}parseColor(l){let d=this._parseColorCache[l];return d||(d=this._parseColorCache[l]=Ai.parse(l)),d}}class Qa{constructor(l,d,y=[],w,T=new Et,K=[]){this.registry=l,this.path=y,this.key=y.map(D=>`[${D}]`).join(""),this.scope=T,this.errors=K,this.expectedType=w,this._isConstant=d}parse(l,d,y,w,T={}){return d?this.concat(d,y,w)._parse(l,T):this._parse(l,T)}_parse(l,d){function y(w,T,K){return K==="assert"?new po(T,[w]):K==="coerce"?new br(T,[w]):w}if(l!==null&&typeof l!="string"&&typeof l!="boolean"&&typeof l!="number"||(l=["literal",l]),Array.isArray(l)){if(l.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');const w=l[0];if(typeof w!="string")return this.error(`Expression name must be a string, but found ${typeof w} instead. If you wanted a literal array, use ["literal", [...]].`,0),null;const T=this.registry[w];if(T){let K=T.parse(l,this);if(!K)return null;if(this.expectedType){const D=this.expectedType,z=K.type;if(D.kind!=="string"&&D.kind!=="number"&&D.kind!=="boolean"&&D.kind!=="object"&&D.kind!=="array"||z.kind!=="value")if(D.kind!=="color"&&D.kind!=="formatted"&&D.kind!=="resolvedImage"||z.kind!=="value"&&z.kind!=="string")if(D.kind!=="padding"||z.kind!=="value"&&z.kind!=="number"&&z.kind!=="array")if(D.kind!=="variableAnchorOffsetCollection"||z.kind!=="value"&&z.kind!=="array"){if(this.checkSubtype(D,z))return null}else K=y(K,D,d.typeAnnotation||"coerce");else K=y(K,D,d.typeAnnotation||"coerce");else K=y(K,D,d.typeAnnotation||"coerce");else K=y(K,D,d.typeAnnotation||"assert")}if(!(K instanceof zr)&&K.type.kind!=="resolvedImage"&&this._isConstant(K)){const D=new _l;try{K=new zr(K.type,K.evaluate(D))}catch(z){return this.error(z.message),null}}return K}return this.error(`Unknown expression "${w}". If you wanted a literal array, use ["literal", [...]].`,0)}return this.error(l===void 0?"'undefined' value invalid. Use null instead.":typeof l=="object"?'Bare objects invalid. Use ["literal", {...}] instead.':`Expected an array, but found ${typeof l} instead.`)}concat(l,d,y){const w=typeof l=="number"?this.path.concat(l):this.path,T=y?this.scope.concat(y):this.scope;return new Qa(this.registry,this._isConstant,w,d||null,T,this.errors)}error(l,...d){const y=`${this.key}${d.map(w=>`[${w}]`).join("")}`;this.errors.push(new bt(y,l))}checkSubtype(l,d){const y=it(l,d);return y&&this.error(y),y}}class ys{constructor(l,d,y){this.type=Gn,this.locale=y,this.caseSensitive=l,this.diacriticSensitive=d}static parse(l,d){if(l.length!==2)return d.error("Expected one argument.");const y=l[1];if(typeof y!="object"||Array.isArray(y))return d.error("Collator options argument must be an object.");const w=d.parse(y["case-sensitive"]!==void 0&&y["case-sensitive"],1,on);if(!w)return null;const T=d.parse(y["diacritic-sensitive"]!==void 0&&y["diacritic-sensitive"],1,on);if(!T)return null;let K=null;return y.locale&&(K=d.parse(y.locale,1,Fn),!K)?null:new ys(w,T,K)}evaluate(l){return new Mi(this.caseSensitive.evaluate(l),this.diacriticSensitive.evaluate(l),this.locale?this.locale.evaluate(l):null)}eachChild(l){l(this.caseSensitive),l(this.diacriticSensitive),this.locale&&l(this.locale)}outputDefined(){return!1}}const qs=8192;function Vs(c,l){c[0]=Math.min(c[0],l[0]),c[1]=Math.min(c[1],l[1]),c[2]=Math.max(c[2],l[0]),c[3]=Math.max(c[3],l[1])}function va(c,l){return!(c[0]<=l[0]||c[2]>=l[2]||c[1]<=l[1]||c[3]>=l[3])}function $a(c,l){const d=(180+c[0])/360,y=(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+c[1]*Math.PI/360)))/360,w=Math.pow(2,l.z);return[Math.round(d*w*qs),Math.round(y*w*qs)]}function ll(c,l,d){const y=c[0]-l[0],w=c[1]-l[1],T=c[0]-d[0],K=c[1]-d[1];return y*K-T*w==0&&y*T<=0&&w*K<=0}function xu(c,l){let d=!1;for(let K=0,D=l.length;K<D;K++){const z=l[K];for(let Q=0,ie=z.length;Q<ie-1;Q++){if(ll(c,z[Q],z[Q+1]))return!1;(w=z[Q])[1]>(y=c)[1]!=(T=z[Q+1])[1]>y[1]&&y[0]<(T[0]-w[0])*(y[1]-w[1])/(T[1]-w[1])+w[0]&&(d=!d)}}var y,w,T;return d}function bl(c,l){for(let d=0;d<l.length;d++)if(xu(c,l[d]))return!0;return!1}function CA(c,l,d,y){const w=y[0]-d[0],T=y[1]-d[1],K=(c[0]-d[0])*T-w*(c[1]-d[1]),D=(l[0]-d[0])*T-w*(l[1]-d[1]);return K>0&&D<0||K<0&&D>0}function HA(c,l,d){for(const Q of d)for(let ie=0;ie<Q.length-1;++ie)if((D=[(K=Q[ie+1])[0]-(T=Q[ie])[0],K[1]-T[1]])[0]*(z=[(w=l)[0]-(y=c)[0],w[1]-y[1]])[1]-D[1]*z[0]!=0&&CA(y,w,T,K)&&CA(T,K,y,w))return!0;var y,w,T,K,D,z;return!1}function Hu(c,l){for(let d=0;d<c.length;++d)if(!xu(c[d],l))return!1;for(let d=0;d<c.length-1;++d)if(HA(c[d],c[d+1],l))return!1;return!0}function ZA(c,l){for(let d=0;d<l.length;d++)if(Hu(c,l[d]))return!0;return!1}function _A(c,l,d){const y=[];for(let w=0;w<c.length;w++){const T=[];for(let K=0;K<c[w].length;K++){const D=$a(c[w][K],d);Vs(l,D),T.push(D)}y.push(T)}return y}function Ya(c,l,d){const y=[];for(let w=0;w<c.length;w++){const T=_A(c[w],l,d);y.push(T)}return y}function vs(c,l,d,y){if(c[0]<d[0]||c[0]>d[2]){const w=.5*y;let T=c[0]-d[0]>w?-y:d[0]-c[0]>w?y:0;T===0&&(T=c[0]-d[2]>w?-y:d[2]-c[0]>w?y:0),c[0]+=T}Vs(l,c)}function bA(c,l,d,y){const w=Math.pow(2,y.z)*qs,T=[y.x*qs,y.y*qs],K=[];for(const D of c)for(const z of D){const Q=[z.x+T[0],z.y+T[1]];vs(Q,l,d,w),K.push(Q)}return K}function Zu(c,l,d,y){const w=Math.pow(2,y.z)*qs,T=[y.x*qs,y.y*qs],K=[];for(const z of c){const Q=[];for(const ie of z){const le=[ie.x+T[0],ie.y+T[1]];Vs(l,le),Q.push(le)}K.push(Q)}if(l[2]-l[0]<=w/2){(D=l)[0]=D[1]=1/0,D[2]=D[3]=-1/0;for(const z of K)for(const Q of z)vs(Q,l,d,w)}var D;return K}class Ds{constructor(l,d){this.type=on,this.geojson=l,this.geometries=d}static parse(l,d){if(l.length!==2)return d.error(`'within' expression requires exactly one argument, but found ${l.length-1} instead.`);if(mn(l[1])){const y=l[1];if(y.type==="FeatureCollection"){const w=[];for(const T of y.features){const{type:K,coordinates:D}=T.geometry;K==="Polygon"&&w.push(D),K==="MultiPolygon"&&w.push(...D)}if(w.length)return new Ds(y,{type:"MultiPolygon",coordinates:w})}else if(y.type==="Feature"){const w=y.geometry.type;if(w==="Polygon"||w==="MultiPolygon")return new Ds(y,y.geometry)}else if(y.type==="Polygon"||y.type==="MultiPolygon")return new Ds(y,y)}return d.error("'within' expression requires valid geojson object that contains polygon geometry type.")}evaluate(l){if(l.geometry()!=null&&l.canonicalID()!=null){if(l.geometryType()==="Point")return function(d,y){const w=[1/0,1/0,-1/0,-1/0],T=[1/0,1/0,-1/0,-1/0],K=d.canonicalID();if(y.type==="Polygon"){const D=_A(y.coordinates,T,K),z=bA(d.geometry(),w,T,K);if(!va(w,T))return!1;for(const Q of z)if(!xu(Q,D))return!1}if(y.type==="MultiPolygon"){const D=Ya(y.coordinates,T,K),z=bA(d.geometry(),w,T,K);if(!va(w,T))return!1;for(const Q of z)if(!bl(Q,D))return!1}return!0}(l,this.geometries);if(l.geometryType()==="LineString")return function(d,y){const w=[1/0,1/0,-1/0,-1/0],T=[1/0,1/0,-1/0,-1/0],K=d.canonicalID();if(y.type==="Polygon"){const D=_A(y.coordinates,T,K),z=Zu(d.geometry(),w,T,K);if(!va(w,T))return!1;for(const Q of z)if(!Hu(Q,D))return!1}if(y.type==="MultiPolygon"){const D=Ya(y.coordinates,T,K),z=Zu(d.geometry(),w,T,K);if(!va(w,T))return!1;for(const Q of z)if(!ZA(Q,D))return!1}return!0}(l,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}}class Us{constructor(l,d){this.type=d.type,this.name=l,this.boundExpression=d}static parse(l,d){if(l.length!==2||typeof l[1]!="string")return d.error("'var' expression requires exactly one string literal argument.");const y=l[1];return d.scope.has(y)?new Us(y,d.scope.get(y)):d.error(`Unknown variable "${y}". Make sure "${y}" has been bound in an enclosing "let" expression before using it.`,1)}evaluate(l){return this.boundExpression.evaluate(l)}eachChild(){}outputDefined(){return!1}}class Cs{constructor(l,d,y,w){this.name=l,this.type=d,this._evaluate=y,this.args=w}evaluate(l){return this._evaluate(l,this.args)}eachChild(l){this.args.forEach(l)}outputDefined(){return!1}static parse(l,d){const y=l[0],w=Cs.definitions[y];if(!w)return d.error(`Unknown expression "${y}". If you wanted a literal array, use ["literal", [...]].`,0);const T=Array.isArray(w)?w[0]:w.type,K=Array.isArray(w)?[[w[1],w[2]]]:w.overloads,D=K.filter(([Q])=>!Array.isArray(Q)||Q.length===l.length-1);let z=null;for(const[Q,ie]of D){z=new Qa(d.registry,lu,d.path,null,d.scope);const le=[];let ge=!1;for(let Oe=1;Oe<l.length;Oe++){const Be=l[Oe],ze=Array.isArray(Q)?Q[Oe-1]:Q.type,$e=z.parse(Be,1+le.length,ze);if(!$e){ge=!0;break}le.push($e)}if(!ge)if(Array.isArray(Q)&&Q.length!==le.length)z.error(`Expected ${Q.length} arguments, but found ${le.length} instead.`);else{for(let Oe=0;Oe<le.length;Oe++){const Be=Array.isArray(Q)?Q[Oe]:Q.type,ze=le[Oe];z.concat(Oe+1).checkSubtype(Be,ze.type)}if(z.errors.length===0)return new Cs(y,T,ie,le)}}if(D.length===1)d.errors.push(...z.errors);else{const Q=(D.length?D:K).map(([le])=>{return ge=le,Array.isArray(ge)?`(${ge.map(Te).join(", ")})`:`(${Te(ge.type)}...)`;var ge}).join(" | "),ie=[];for(let le=1;le<l.length;le++){const ge=d.parse(l[le],1+ie.length);if(!ge)return null;ie.push(Te(ge.type))}d.error(`Expected arguments of type ${Q}, but found (${ie.join(", ")}) instead.`)}return null}static register(l,d){Cs.definitions=d;for(const y in d)l[y]=Cs}}function lu(c){if(c instanceof Us)return lu(c.boundExpression);if(c instanceof Cs&&c.name==="error"||c instanceof ys||c instanceof Ds)return!1;const l=c instanceof br||c instanceof po;let d=!0;return c.eachChild(y=>{d=l?d&&lu(y):d&&y instanceof zr}),!!d&&wu(c)&&as(c,["zoom","heatmap-density","line-progress","accumulated","is-supported-script"])}function wu(c){if(c instanceof Cs&&(c.name==="get"&&c.args.length===1||c.name==="feature-state"||c.name==="has"&&c.args.length===1||c.name==="properties"||c.name==="geometry-type"||c.name==="id"||/^filter-/.test(c.name))||c instanceof Ds)return!1;let l=!0;return c.eachChild(d=>{l&&!wu(d)&&(l=!1)}),l}function uu(c){if(c instanceof Cs&&c.name==="feature-state")return!1;let l=!0;return c.eachChild(d=>{l&&!uu(d)&&(l=!1)}),l}function as(c,l){if(c instanceof Cs&&l.indexOf(c.name)>=0)return!1;let d=!0;return c.eachChild(y=>{d&&!as(y,l)&&(d=!1)}),d}function Mu(c,l){const d=c.length-1;let y,w,T=0,K=d,D=0;for(;T<=K;)if(D=Math.floor((T+K)/2),y=c[D],w=c[D+1],y<=l){if(D===d||l<w)return D;T=D+1}else{if(!(y>l))throw new Lr("Input is not a number.");K=D-1}return 0}class Au{constructor(l,d,y){this.type=l,this.input=d,this.labels=[],this.outputs=[];for(const[w,T]of y)this.labels.push(w),this.outputs.push(T)}static parse(l,d){if(l.length-1<4)return d.error(`Expected at least 4 arguments, but found only ${l.length-1}.`);if((l.length-1)%2!=0)return d.error("Expected an even number of arguments.");const y=d.parse(l[1],1,Lt);if(!y)return null;const w=[];let T=null;d.expectedType&&d.expectedType.kind!=="value"&&(T=d.expectedType);for(let K=1;K<l.length;K+=2){const D=K===1?-1/0:l[K],z=l[K+1],Q=K,ie=K+1;if(typeof D!="number")return d.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',Q);if(w.length&&w[w.length-1][0]>=D)return d.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',Q);const le=d.parse(z,ie,T);if(!le)return null;T=T||le.type,w.push([D,le])}return new Au(T,y,w)}evaluate(l){const d=this.labels,y=this.outputs;if(d.length===1)return y[0].evaluate(l);const w=this.input.evaluate(l);if(w<=d[0])return y[0].evaluate(l);const T=d.length;return w>=d[T-1]?y[T-1].evaluate(l):y[Mu(d,w)].evaluate(l)}eachChild(l){l(this.input);for(const d of this.outputs)l(d)}outputDefined(){return this.outputs.every(l=>l.outputDefined())}}function bo(c){return c&&c.__esModule&&Object.prototype.hasOwnProperty.call(c,"default")?c.default:c}var mo=ee;function ee(c,l,d,y){this.cx=3*c,this.bx=3*(d-c)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*l,this.by=3*(y-l)-this.cy,this.ay=1-this.cy-this.by,this.p1x=c,this.p1y=l,this.p2x=d,this.p2y=y}ee.prototype={sampleCurveX:function(c){return((this.ax*c+this.bx)*c+this.cx)*c},sampleCurveY:function(c){return((this.ay*c+this.by)*c+this.cy)*c},sampleCurveDerivativeX:function(c){return(3*this.ax*c+2*this.bx)*c+this.cx},solveCurveX:function(c,l){if(l===void 0&&(l=1e-6),c<0)return 0;if(c>1)return 1;for(var d=c,y=0;y<8;y++){var w=this.sampleCurveX(d)-c;if(Math.abs(w)<l)return d;var T=this.sampleCurveDerivativeX(d);if(Math.abs(T)<1e-6)break;d-=w/T}var K=0,D=1;for(d=c,y=0;y<20&&(w=this.sampleCurveX(d),!(Math.abs(w-c)<l));y++)c>w?K=d:D=d,d=.5*(D-K)+K;return d},solve:function(c,l){return this.sampleCurveY(this.solveCurveX(c,l))}};var Ie=bo(mo);function st(c,l,d){return c+d*(l-c)}function Xt(c,l,d){return c.map((y,w)=>st(y,l[w],d))}const Sr={number:st,color:function(c,l,d,y="rgb"){switch(y){case"rgb":{const[w,T,K,D]=Xt(c.rgb,l.rgb,d);return new Ai(w,T,K,D,!1)}case"hcl":{const[w,T,K,D]=c.hcl,[z,Q,ie,le]=l.hcl;let ge,Oe;if(isNaN(w)||isNaN(z))isNaN(w)?isNaN(z)?ge=NaN:(ge=z,K!==1&&K!==0||(Oe=Q)):(ge=w,ie!==1&&ie!==0||(Oe=T));else{let St=z-w;z>w&&St>180?St-=360:z<w&&w-z>180&&(St+=360),ge=w+d*St}const[Be,ze,$e,tt]=function([St,lt,vt,tn]){return St=isNaN(St)?0:St*Tr,ui([vt,Math.cos(St)*lt,Math.sin(St)*lt,tn])}([ge,Oe??st(T,Q,d),st(K,ie,d),st(D,le,d)]);return new Ai(Be,ze,$e,tt,!1)}case"lab":{const[w,T,K,D]=ui(Xt(c.lab,l.lab,d));return new Ai(w,T,K,D,!1)}}},array:Xt,padding:function(c,l,d){return new Gi(Xt(c.values,l.values,d))},variableAnchorOffsetCollection:function(c,l,d){const y=c.values,w=l.values;if(y.length!==w.length)throw new Lr(`Cannot interpolate values of different length. from: ${c.toString()}, to: ${l.toString()}`);const T=[];for(let K=0;K<y.length;K+=2){if(y[K]!==w[K])throw new Lr(`Cannot interpolate values containing mismatched anchors. from[${K}]: ${y[K]}, to[${K}]: ${w[K]}`);T.push(y[K]);const[D,z]=y[K+1],[Q,ie]=w[K+1];T.push([st(D,Q,d),st(z,ie,d)])}return new ve(T)}};class _n{constructor(l,d,y,w,T){this.type=l,this.operator=d,this.interpolation=y,this.input=w,this.labels=[],this.outputs=[];for(const[K,D]of T)this.labels.push(K),this.outputs.push(D)}static interpolationFactor(l,d,y,w){let T=0;if(l.name==="exponential")T=Si(d,l.base,y,w);else if(l.name==="linear")T=Si(d,1,y,w);else if(l.name==="cubic-bezier"){const K=l.controlPoints;T=new Ie(K[0],K[1],K[2],K[3]).solve(Si(d,1,y,w))}return T}static parse(l,d){let[y,w,T,...K]=l;if(!Array.isArray(w)||w.length===0)return d.error("Expected an interpolation type expression.",1);if(w[0]==="linear")w={name:"linear"};else if(w[0]==="exponential"){const Q=w[1];if(typeof Q!="number")return d.error("Exponential interpolation requires a numeric base.",1,1);w={name:"exponential",base:Q}}else{if(w[0]!=="cubic-bezier")return d.error(`Unknown interpolation type ${String(w[0])}`,1,0);{const Q=w.slice(1);if(Q.length!==4||Q.some(ie=>typeof ie!="number"||ie<0||ie>1))return d.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);w={name:"cubic-bezier",controlPoints:Q}}}if(l.length-1<4)return d.error(`Expected at least 4 arguments, but found only ${l.length-1}.`);if((l.length-1)%2!=0)return d.error("Expected an even number of arguments.");if(T=d.parse(T,2,Lt),!T)return null;const D=[];let z=null;y==="interpolate-hcl"||y==="interpolate-lab"?z=m:d.expectedType&&d.expectedType.kind!=="value"&&(z=d.expectedType);for(let Q=0;Q<K.length;Q+=2){const ie=K[Q],le=K[Q+1],ge=Q+3,Oe=Q+4;if(typeof ie!="number")return d.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',ge);if(D.length&&D[D.length-1][0]>=ie)return d.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',ge);const Be=d.parse(le,Oe,z);if(!Be)return null;z=z||Be.type,D.push([ie,Be])}return Ct(z,Lt)||Ct(z,m)||Ct(z,Ke)||Ct(z,_e)||Ct(z,Ee(Lt))?new _n(z,y,w,T,D):d.error(`Type ${Te(z)} is not interpolatable.`)}evaluate(l){const d=this.labels,y=this.outputs;if(d.length===1)return y[0].evaluate(l);const w=this.input.evaluate(l);if(w<=d[0])return y[0].evaluate(l);const T=d.length;if(w>=d[T-1])return y[T-1].evaluate(l);const K=Mu(d,w),D=_n.interpolationFactor(this.interpolation,w,d[K],d[K+1]),z=y[K].evaluate(l),Q=y[K+1].evaluate(l);switch(this.operator){case"interpolate":return Sr[this.type.kind](z,Q,D);case"interpolate-hcl":return Sr.color(z,Q,D,"hcl");case"interpolate-lab":return Sr.color(z,Q,D,"lab")}}eachChild(l){l(this.input);for(const d of this.outputs)l(d)}outputDefined(){return this.outputs.every(l=>l.outputDefined())}}function Si(c,l,d,y){const w=y-d,T=c-d;return w===0?0:l===1?T/w:(Math.pow(l,T)-1)/(Math.pow(l,w)-1)}class Ki{constructor(l,d){this.type=l,this.args=d}static parse(l,d){if(l.length<2)return d.error("Expectected at least one argument.");let y=null;const w=d.expectedType;w&&w.kind!=="value"&&(y=w);const T=[];for(const D of l.slice(1)){const z=d.parse(D,1+T.length,y,void 0,{typeAnnotation:"omit"});if(!z)return null;y=y||z.type,T.push(z)}if(!y)throw new Error("No output type");const K=w&&T.some(D=>it(w,D.type));return new Ki(K?In:y,T)}evaluate(l){let d,y=null,w=0;for(const T of this.args)if(w++,y=T.evaluate(l),y&&y instanceof Ge&&!y.available&&(d||(d=y.name),y=null,w===this.args.length&&(y=d)),y!==null)break;return y}eachChild(l){this.args.forEach(l)}outputDefined(){return this.args.every(l=>l.outputDefined())}}class qr{constructor(l,d){this.type=d.type,this.bindings=[].concat(l),this.result=d}evaluate(l){return this.result.evaluate(l)}eachChild(l){for(const d of this.bindings)l(d[1]);l(this.result)}static parse(l,d){if(l.length<4)return d.error(`Expected at least 3 arguments, but found ${l.length-1} instead.`);const y=[];for(let T=1;T<l.length-1;T+=2){const K=l[T];if(typeof K!="string")return d.error(`Expected string, but found ${typeof K} instead.`,T);if(/[^a-zA-Z0-9_]/.test(K))return d.error("Variable names must contain only alphanumeric characters or '_'.",T);const D=d.parse(l[T+1],T+1);if(!D)return null;y.push([K,D])}const w=d.parse(l[l.length-1],l.length-1,d.expectedType,y);return w?new qr(y,w):null}outputDefined(){return this.result.outputDefined()}}class Yi{constructor(l,d,y){this.type=l,this.index=d,this.input=y}static parse(l,d){if(l.length!==3)return d.error(`Expected 2 arguments, but found ${l.length-1} instead.`);const y=d.parse(l[1],1,Lt),w=d.parse(l[2],2,Ee(d.expectedType||In));return y&&w?new Yi(w.type.itemType,y,w):null}evaluate(l){const d=this.index.evaluate(l),y=this.input.evaluate(l);if(d<0)throw new Lr(`Array index out of bounds: ${d} < 0.`);if(d>=y.length)throw new Lr(`Array index out of bounds: ${d} > ${y.length-1}.`);if(d!==Math.floor(d))throw new Lr(`Array index must be an integer, but found ${d} instead.`);return y[d]}eachChild(l){l(this.index),l(this.input)}outputDefined(){return!1}}class qo{constructor(l,d){this.type=on,this.needle=l,this.haystack=d}static parse(l,d){if(l.length!==3)return d.error(`Expected 2 arguments, but found ${l.length-1} instead.`);const y=d.parse(l[1],1,In),w=d.parse(l[2],2,In);return y&&w?ht(y.type,[on,Fn,Lt,sr,In])?new qo(y,w):d.error(`Expected first argument to be of type boolean, string, number or null, but found ${Te(y.type)} instead`):null}evaluate(l){const d=this.needle.evaluate(l),y=this.haystack.evaluate(l);if(!y)return!1;if(!et(d,["boolean","string","number","null"]))throw new Lr(`Expected first argument to be of type boolean, string, number or null, but found ${Te(Ot(d))} instead.`);if(!et(y,["string","array"]))throw new Lr(`Expected second argument to be of type array or string, but found ${Te(Ot(y))} instead.`);return y.indexOf(d)>=0}eachChild(l){l(this.needle),l(this.haystack)}outputDefined(){return!0}}class Ca{constructor(l,d,y){this.type=Lt,this.needle=l,this.haystack=d,this.fromIndex=y}static parse(l,d){if(l.length<=2||l.length>=5)return d.error(`Expected 3 or 4 arguments, but found ${l.length-1} instead.`);const y=d.parse(l[1],1,In),w=d.parse(l[2],2,In);if(!y||!w)return null;if(!ht(y.type,[on,Fn,Lt,sr,In]))return d.error(`Expected first argument to be of type boolean, string, number or null, but found ${Te(y.type)} instead`);if(l.length===4){const T=d.parse(l[3],3,Lt);return T?new Ca(y,w,T):null}return new Ca(y,w)}evaluate(l){const d=this.needle.evaluate(l),y=this.haystack.evaluate(l);if(!et(d,["boolean","string","number","null"]))throw new Lr(`Expected first argument to be of type boolean, string, number or null, but found ${Te(Ot(d))} instead.`);if(!et(y,["string","array"]))throw new Lr(`Expected second argument to be of type array or string, but found ${Te(Ot(y))} instead.`);if(this.fromIndex){const w=this.fromIndex.evaluate(l);return y.indexOf(d,w)}return y.indexOf(d)}eachChild(l){l(this.needle),l(this.haystack),this.fromIndex&&l(this.fromIndex)}outputDefined(){return!1}}class Vo{constructor(l,d,y,w,T,K){this.inputType=l,this.type=d,this.input=y,this.cases=w,this.outputs=T,this.otherwise=K}static parse(l,d){if(l.length<5)return d.error(`Expected at least 4 arguments, but found only ${l.length-1}.`);if(l.length%2!=1)return d.error("Expected an even number of arguments.");let y,w;d.expectedType&&d.expectedType.kind!=="value"&&(w=d.expectedType);const T={},K=[];for(let Q=2;Q<l.length-1;Q+=2){let ie=l[Q];const le=l[Q+1];Array.isArray(ie)||(ie=[ie]);const ge=d.concat(Q);if(ie.length===0)return ge.error("Expected at least one branch label.");for(const Be of ie){if(typeof Be!="number"&&typeof Be!="string")return ge.error("Branch labels must be numbers or strings.");if(typeof Be=="number"&&Math.abs(Be)>Number.MAX_SAFE_INTEGER)return ge.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof Be=="number"&&Math.floor(Be)!==Be)return ge.error("Numeric branch labels must be integer values.");if(y){if(ge.checkSubtype(y,Ot(Be)))return null}else y=Ot(Be);if(T[String(Be)]!==void 0)return ge.error("Branch labels must be unique.");T[String(Be)]=K.length}const Oe=d.parse(le,Q,w);if(!Oe)return null;w=w||Oe.type,K.push(Oe)}const D=d.parse(l[1],1,In);if(!D)return null;const z=d.parse(l[l.length-1],l.length-1,w);return z?D.type.kind!=="value"&&d.concat(1).checkSubtype(y,D.type)?null:new Vo(y,w,D,T,K,z):null}evaluate(l){const d=this.input.evaluate(l);return(Ot(d)===this.inputType&&this.outputs[this.cases[d]]||this.otherwise).evaluate(l)}eachChild(l){l(this.input),this.outputs.forEach(l),l(this.otherwise)}outputDefined(){return this.outputs.every(l=>l.outputDefined())&&this.otherwise.outputDefined()}}class Li{constructor(l,d,y){this.type=l,this.branches=d,this.otherwise=y}static parse(l,d){if(l.length<4)return d.error(`Expected at least 3 arguments, but found only ${l.length-1}.`);if(l.length%2!=0)return d.error("Expected an odd number of arguments.");let y;d.expectedType&&d.expectedType.kind!=="value"&&(y=d.expectedType);const w=[];for(let K=1;K<l.length-1;K+=2){const D=d.parse(l[K],K,on);if(!D)return null;const z=d.parse(l[K+1],K+1,y);if(!z)return null;w.push([D,z]),y=y||z.type}const T=d.parse(l[l.length-1],l.length-1,y);if(!T)return null;if(!y)throw new Error("Can't infer output type");return new Li(y,w,T)}evaluate(l){for(const[d,y]of this.branches)if(d.evaluate(l))return y.evaluate(l);return this.otherwise.evaluate(l)}eachChild(l){for(const[d,y]of this.branches)l(d),l(y);l(this.otherwise)}outputDefined(){return this.branches.every(([l,d])=>d.outputDefined())&&this.otherwise.outputDefined()}}class Xo{constructor(l,d,y,w){this.type=l,this.input=d,this.beginIndex=y,this.endIndex=w}static parse(l,d){if(l.length<=2||l.length>=5)return d.error(`Expected 3 or 4 arguments, but found ${l.length-1} instead.`);const y=d.parse(l[1],1,In),w=d.parse(l[2],2,Lt);if(!y||!w)return null;if(!ht(y.type,[Ee(In),Fn,In]))return d.error(`Expected first argument to be of type array or string, but found ${Te(y.type)} instead`);if(l.length===4){const T=d.parse(l[3],3,Lt);return T?new Xo(y.type,y,w,T):null}return new Xo(y.type,y,w)}evaluate(l){const d=this.input.evaluate(l),y=this.beginIndex.evaluate(l);if(!et(d,["string","array"]))throw new Lr(`Expected first argument to be of type array or string, but found ${Te(Ot(d))} instead.`);if(this.endIndex){const w=this.endIndex.evaluate(l);return d.slice(y,w)}return d.slice(y)}eachChild(l){l(this.input),l(this.beginIndex),this.endIndex&&l(this.endIndex)}outputDefined(){return!1}}function Pa(c,l){return c==="=="||c==="!="?l.kind==="boolean"||l.kind==="string"||l.kind==="number"||l.kind==="null"||l.kind==="value":l.kind==="string"||l.kind==="number"||l.kind==="value"}function Rs(c,l,d,y){return y.compare(l,d)===0}function _s(c,l,d){const y=c!=="=="&&c!=="!=";return class WR{constructor(T,K,D){this.type=on,this.lhs=T,this.rhs=K,this.collator=D,this.hasUntypedArgument=T.type.kind==="value"||K.type.kind==="value"}static parse(T,K){if(T.length!==3&&T.length!==4)return K.error("Expected two or three arguments.");const D=T[0];let z=K.parse(T[1],1,In);if(!z)return null;if(!Pa(D,z.type))return K.concat(1).error(`"${D}" comparisons are not supported for type '${Te(z.type)}'.`);let Q=K.parse(T[2],2,In);if(!Q)return null;if(!Pa(D,Q.type))return K.concat(2).error(`"${D}" comparisons are not supported for type '${Te(Q.type)}'.`);if(z.type.kind!==Q.type.kind&&z.type.kind!=="value"&&Q.type.kind!=="value")return K.error(`Cannot compare types '${Te(z.type)}' and '${Te(Q.type)}'.`);y&&(z.type.kind==="value"&&Q.type.kind!=="value"?z=new po(Q.type,[z]):z.type.kind!=="value"&&Q.type.kind==="value"&&(Q=new po(z.type,[Q])));let ie=null;if(T.length===4){if(z.type.kind!=="string"&&Q.type.kind!=="string"&&z.type.kind!=="value"&&Q.type.kind!=="value")return K.error("Cannot use collator to compare non-string types.");if(ie=K.parse(T[3],3,Gn),!ie)return null}return new WR(z,Q,ie)}evaluate(T){const K=this.lhs.evaluate(T),D=this.rhs.evaluate(T);if(y&&this.hasUntypedArgument){const z=Ot(K),Q=Ot(D);if(z.kind!==Q.kind||z.kind!=="string"&&z.kind!=="number")throw new Lr(`Expected arguments for "${c}" to be (string, string) or (number, number), but found (${z.kind}, ${Q.kind}) instead.`)}if(this.collator&&!y&&this.hasUntypedArgument){const z=Ot(K),Q=Ot(D);if(z.kind!=="string"||Q.kind!=="string")return l(T,K,D)}return this.collator?d(T,K,D,this.collator.evaluate(T)):l(T,K,D)}eachChild(T){T(this.lhs),T(this.rhs),this.collator&&T(this.collator)}outputDefined(){return!0}}}const Su=_s("==",function(c,l,d){return l===d},Rs),XA=_s("!=",function(c,l,d){return l!==d},function(c,l,d,y){return!Rs(0,l,d,y)}),ss=_s("<",function(c,l,d){return l<d},function(c,l,d,y){return y.compare(l,d)<0}),jm=_s(">",function(c,l,d){return l>d},function(c,l,d,y){return y.compare(l,d)>0}),$l=_s("<=",function(c,l,d){return l<=d},function(c,l,d,y){return y.compare(l,d)<=0}),Bp=_s(">=",function(c,l,d){return l>=d},function(c,l,d,y){return y.compare(l,d)>=0});class Id{constructor(l,d,y,w,T){this.type=Fn,this.number=l,this.locale=d,this.currency=y,this.minFractionDigits=w,this.maxFractionDigits=T}static parse(l,d){if(l.length!==3)return d.error("Expected two arguments.");const y=d.parse(l[1],1,Lt);if(!y)return null;const w=l[2];if(typeof w!="object"||Array.isArray(w))return d.error("NumberFormat options argument must be an object.");let T=null;if(w.locale&&(T=d.parse(w.locale,1,Fn),!T))return null;let K=null;if(w.currency&&(K=d.parse(w.currency,1,Fn),!K))return null;let D=null;if(w["min-fraction-digits"]&&(D=d.parse(w["min-fraction-digits"],1,Lt),!D))return null;let z=null;return w["max-fraction-digits"]&&(z=d.parse(w["max-fraction-digits"],1,Lt),!z)?null:new Id(y,T,K,D,z)}evaluate(l){return new Intl.NumberFormat(this.locale?this.locale.evaluate(l):[],{style:this.currency?"currency":"decimal",currency:this.currency?this.currency.evaluate(l):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(l):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(l):void 0}).format(this.number.evaluate(l))}eachChild(l){l(this.number),this.locale&&l(this.locale),this.currency&&l(this.currency),this.minFractionDigits&&l(this.minFractionDigits),this.maxFractionDigits&&l(this.maxFractionDigits)}outputDefined(){return!1}}class cu{constructor(l){this.type=Zn,this.sections=l}static parse(l,d){if(l.length<2)return d.error("Expected at least one argument.");const y=l[1];if(!Array.isArray(y)&&typeof y=="object")return d.error("First argument must be an image or text section.");const w=[];let T=!1;for(let K=1;K<=l.length-1;++K){const D=l[K];if(T&&typeof D=="object"&&!Array.isArray(D)){T=!1;let z=null;if(D["font-scale"]&&(z=d.parse(D["font-scale"],1,Lt),!z))return null;let Q=null;if(D["text-font"]&&(Q=d.parse(D["text-font"],1,Ee(Fn)),!Q))return null;let ie=null;if(D["text-color"]&&(ie=d.parse(D["text-color"],1,m),!ie))return null;const le=w[w.length-1];le.scale=z,le.font=Q,le.textColor=ie}else{const z=d.parse(l[K],1,In);if(!z)return null;const Q=z.type.kind;if(Q!=="string"&&Q!=="value"&&Q!=="null"&&Q!=="resolvedImage")return d.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");T=!0,w.push({content:z,scale:null,font:null,textColor:null})}}return new cu(w)}evaluate(l){return new lo(this.sections.map(d=>{const y=d.content.evaluate(l);return Ot(y)===fe?new rr("",y,null,null,null):new rr(En(y),null,d.scale?d.scale.evaluate(l):null,d.font?d.font.evaluate(l).join(","):null,d.textColor?d.textColor.evaluate(l):null)}))}eachChild(l){for(const d of this.sections)l(d.content),d.scale&&l(d.scale),d.font&&l(d.font),d.textColor&&l(d.textColor)}outputDefined(){return!1}}class Gc{constructor(l){this.type=fe,this.input=l}static parse(l,d){if(l.length!==2)return d.error("Expected two arguments.");const y=d.parse(l[1],1,Fn);return y?new Gc(y):d.error("No image name provided.")}evaluate(l){const d=this.input.evaluate(l),y=Ge.fromString(d);return y&&l.availableImages&&(y.available=l.availableImages.indexOf(d)>-1),y}eachChild(l){l(this.input)}outputDefined(){return!1}}class Td{constructor(l){this.type=Lt,this.input=l}static parse(l,d){if(l.length!==2)return d.error(`Expected 1 argument, but found ${l.length-1} instead.`);const y=d.parse(l[1],1);return y?y.type.kind!=="array"&&y.type.kind!=="string"&&y.type.kind!=="value"?d.error(`Expected argument of type string or array, but found ${Te(y.type)} instead.`):new Td(y):null}evaluate(l){const d=this.input.evaluate(l);if(typeof d=="string"||Array.isArray(d))return d.length;throw new Lr(`Expected value to be of type string or array, but found ${Te(Ot(d))} instead.`)}eachChild(l){l(this.input)}outputDefined(){return!1}}const Mo={"==":Su,"!=":XA,">":jm,"<":ss,">=":Bp,"<=":$l,array:po,at:Yi,boolean:po,case:Li,coalesce:Ki,collator:ys,format:cu,image:Gc,in:qo,"index-of":Ca,interpolate:_n,"interpolate-hcl":_n,"interpolate-lab":_n,length:Td,let:qr,literal:zr,match:Vo,number:po,"number-format":Id,object:po,slice:Xo,step:Au,string:po,"to-boolean":br,"to-color":br,"to-number":br,"to-string":br,var:Us,within:Ds};function Eu(c,[l,d,y,w]){l=l.evaluate(c),d=d.evaluate(c),y=y.evaluate(c);const T=w?w.evaluate(c):1,K=Ht(l,d,y,T);if(K)throw new Lr(K);return new Ai(l/255,d/255,y/255,T,!1)}function yh(c,l){return c in l}function vh(c,l){const d=l[c];return d===void 0?null:d}function Yl(c){return{type:c}}function JA(c){return{result:"success",value:c}}function Qc(c){return{result:"error",value:c}}function $c(c){return c["property-type"]==="data-driven"||c["property-type"]==="cross-faded-data-driven"}function xf(c){return!!c.expression&&c.expression.parameters.indexOf("zoom")>-1}function ql(c){return!!c.expression&&c.expression.interpolated}function Ur(c){return c instanceof Number?"number":c instanceof String?"string":c instanceof Boolean?"boolean":Array.isArray(c)?"array":c===null?"null":typeof c}function Ch(c){return typeof c=="object"&&c!==null&&!Array.isArray(c)}function wf(c){return c}function ec(c,l){const d=l.type==="color",y=c.stops&&typeof c.stops[0][0]=="object",w=y||!(y||c.property!==void 0),T=c.type||(ql(l)?"exponential":"interval");if(d||l.type==="padding"){const ie=d?Ai.parse:Gi.parse;(c=At({},c)).stops&&(c.stops=c.stops.map(le=>[le[0],ie(le[1])])),c.default=ie(c.default?c.default:l.default)}if(c.colorSpace&&(K=c.colorSpace)!=="rgb"&&K!=="hcl"&&K!=="lab")throw new Error(`Unknown color space: "${c.colorSpace}"`);var K;let D,z,Q;if(T==="exponential")D=Yc;else if(T==="interval")D=zi;else if(T==="categorical"){D=_h,z=Object.create(null);for(const ie of c.stops)z[ie[0]]=ie[1];Q=typeof c.stops[0][0]}else{if(T!=="identity")throw new Error(`Unknown function type "${T}"`);D=Lo}if(y){const ie={},le=[];for(let Be=0;Be<c.stops.length;Be++){const ze=c.stops[Be],$e=ze[0].zoom;ie[$e]===void 0&&(ie[$e]={zoom:$e,type:c.type,property:c.property,default:c.default,stops:[]},le.push($e)),ie[$e].stops.push([ze[0].value,ze[1]])}const ge=[];for(const Be of le)ge.push([ie[Be].zoom,ec(ie[Be],l)]);const Oe={name:"linear"};return{kind:"composite",interpolationType:Oe,interpolationFactor:_n.interpolationFactor.bind(void 0,Oe),zoomStops:ge.map(Be=>Be[0]),evaluate:({zoom:Be},ze)=>Yc({stops:ge,base:c.base},l,Be).evaluate(Be,ze)}}if(w){const ie=T==="exponential"?{name:"exponential",base:c.base!==void 0?c.base:1}:null;return{kind:"camera",interpolationType:ie,interpolationFactor:_n.interpolationFactor.bind(void 0,ie),zoomStops:c.stops.map(le=>le[0]),evaluate:({zoom:le})=>D(c,l,le,z,Q)}}return{kind:"source",evaluate(ie,le){const ge=le&&le.properties?le.properties[c.property]:void 0;return ge===void 0?Ro(c.default,l.default):D(c,l,ge,z,Q)}}}function Ro(c,l,d){return c!==void 0?c:l!==void 0?l:d!==void 0?d:void 0}function _h(c,l,d,y,w){return Ro(typeof d===w?y[d]:void 0,c.default,l.default)}function zi(c,l,d){if(Ur(d)!=="number")return Ro(c.default,l.default);const y=c.stops.length;if(y===1||d<=c.stops[0][0])return c.stops[0][1];if(d>=c.stops[y-1][0])return c.stops[y-1][1];const w=Mu(c.stops.map(T=>T[0]),d);return c.stops[w][1]}function Yc(c,l,d){const y=c.base!==void 0?c.base:1;if(Ur(d)!=="number")return Ro(c.default,l.default);const w=c.stops.length;if(w===1||d<=c.stops[0][0])return c.stops[0][1];if(d>=c.stops[w-1][0])return c.stops[w-1][1];const T=Mu(c.stops.map(ie=>ie[0]),d),K=function(ie,le,ge,Oe){const Be=Oe-ge,ze=ie-ge;return Be===0?0:le===1?ze/Be:(Math.pow(le,ze)-1)/(Math.pow(le,Be)-1)}(d,y,c.stops[T][0],c.stops[T+1][0]),D=c.stops[T][1],z=c.stops[T+1][1],Q=Sr[l.type]||wf;return typeof D.evaluate=="function"?{evaluate(...ie){const le=D.evaluate.apply(void 0,ie),ge=z.evaluate.apply(void 0,ie);if(le!==void 0&&ge!==void 0)return Q(le,ge,K,c.colorSpace)}}:Q(D,z,K,c.colorSpace)}function Lo(c,l,d){switch(l.type){case"color":d=Ai.parse(d);break;case"formatted":d=lo.fromString(d.toString());break;case"resolvedImage":d=Ge.fromString(d.toString());break;case"padding":d=Gi.parse(d);break;default:Ur(d)===l.type||l.type==="enum"&&l.values[d]||(d=void 0)}return Ro(d,c.default,l.default)}Cs.register(Mo,{error:[{kind:"error"},[Fn],(c,[l])=>{throw new Lr(l.evaluate(c))}],typeof:[Fn,[In],(c,[l])=>Te(Ot(l.evaluate(c)))],"to-rgba":[Ee(Lt,4),[m],(c,[l])=>{const[d,y,w,T]=l.evaluate(c).rgb;return[255*d,255*y,255*w,T]}],rgb:[m,[Lt,Lt,Lt],Eu],rgba:[m,[Lt,Lt,Lt,Lt],Eu],has:{type:on,overloads:[[[Fn],(c,[l])=>yh(l.evaluate(c),c.properties())],[[Fn,un],(c,[l,d])=>yh(l.evaluate(c),d.evaluate(c))]]},get:{type:In,overloads:[[[Fn],(c,[l])=>vh(l.evaluate(c),c.properties())],[[Fn,un],(c,[l,d])=>vh(l.evaluate(c),d.evaluate(c))]]},"feature-state":[In,[Fn],(c,[l])=>vh(l.evaluate(c),c.featureState||{})],properties:[un,[],c=>c.properties()],"geometry-type":[Fn,[],c=>c.geometryType()],id:[In,[],c=>c.id()],zoom:[Lt,[],c=>c.globals.zoom],"heatmap-density":[Lt,[],c=>c.globals.heatmapDensity||0],"line-progress":[Lt,[],c=>c.globals.lineProgress||0],accumulated:[In,[],c=>c.globals.accumulated===void 0?null:c.globals.accumulated],"+":[Lt,Yl(Lt),(c,l)=>{let d=0;for(const y of l)d+=y.evaluate(c);return d}],"*":[Lt,Yl(Lt),(c,l)=>{let d=1;for(const y of l)d*=y.evaluate(c);return d}],"-":{type:Lt,overloads:[[[Lt,Lt],(c,[l,d])=>l.evaluate(c)-d.evaluate(c)],[[Lt],(c,[l])=>-l.evaluate(c)]]},"/":[Lt,[Lt,Lt],(c,[l,d])=>l.evaluate(c)/d.evaluate(c)],"%":[Lt,[Lt,Lt],(c,[l,d])=>l.evaluate(c)%d.evaluate(c)],ln2:[Lt,[],()=>Math.LN2],pi:[Lt,[],()=>Math.PI],e:[Lt,[],()=>Math.E],"^":[Lt,[Lt,Lt],(c,[l,d])=>Math.pow(l.evaluate(c),d.evaluate(c))],sqrt:[Lt,[Lt],(c,[l])=>Math.sqrt(l.evaluate(c))],log10:[Lt,[Lt],(c,[l])=>Math.log(l.evaluate(c))/Math.LN10],ln:[Lt,[Lt],(c,[l])=>Math.log(l.evaluate(c))],log2:[Lt,[Lt],(c,[l])=>Math.log(l.evaluate(c))/Math.LN2],sin:[Lt,[Lt],(c,[l])=>Math.sin(l.evaluate(c))],cos:[Lt,[Lt],(c,[l])=>Math.cos(l.evaluate(c))],tan:[Lt,[Lt],(c,[l])=>Math.tan(l.evaluate(c))],asin:[Lt,[Lt],(c,[l])=>Math.asin(l.evaluate(c))],acos:[Lt,[Lt],(c,[l])=>Math.acos(l.evaluate(c))],atan:[Lt,[Lt],(c,[l])=>Math.atan(l.evaluate(c))],min:[Lt,Yl(Lt),(c,l)=>Math.min(...l.map(d=>d.evaluate(c)))],max:[Lt,Yl(Lt),(c,l)=>Math.max(...l.map(d=>d.evaluate(c)))],abs:[Lt,[Lt],(c,[l])=>Math.abs(l.evaluate(c))],round:[Lt,[Lt],(c,[l])=>{const d=l.evaluate(c);return d<0?-Math.round(-d):Math.round(d)}],floor:[Lt,[Lt],(c,[l])=>Math.floor(l.evaluate(c))],ceil:[Lt,[Lt],(c,[l])=>Math.ceil(l.evaluate(c))],"filter-==":[on,[Fn,In],(c,[l,d])=>c.properties()[l.value]===d.value],"filter-id-==":[on,[In],(c,[l])=>c.id()===l.value],"filter-type-==":[on,[Fn],(c,[l])=>c.geometryType()===l.value],"filter-<":[on,[Fn,In],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y<w}],"filter-id-<":[on,[In],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d<y}],"filter->":[on,[Fn,In],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y>w}],"filter-id->":[on,[In],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d>y}],"filter-<=":[on,[Fn,In],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y<=w}],"filter-id-<=":[on,[In],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d<=y}],"filter->=":[on,[Fn,In],(c,[l,d])=>{const y=c.properties()[l.value],w=d.value;return typeof y==typeof w&&y>=w}],"filter-id->=":[on,[In],(c,[l])=>{const d=c.id(),y=l.value;return typeof d==typeof y&&d>=y}],"filter-has":[on,[In],(c,[l])=>l.value in c.properties()],"filter-has-id":[on,[],c=>c.id()!==null&&c.id()!==void 0],"filter-type-in":[on,[Ee(Fn)],(c,[l])=>l.value.indexOf(c.geometryType())>=0],"filter-id-in":[on,[Ee(In)],(c,[l])=>l.value.indexOf(c.id())>=0],"filter-in-small":[on,[Fn,Ee(In)],(c,[l,d])=>d.value.indexOf(c.properties()[l.value])>=0],"filter-in-large":[on,[Fn,Ee(In)],(c,[l,d])=>function(y,w,T,K){for(;T<=K;){const D=T+K>>1;if(w[D]===y)return!0;w[D]>y?K=D-1:T=D+1}return!1}(c.properties()[l.value],d.value,0,d.value.length-1)],all:{type:on,overloads:[[[on,on],(c,[l,d])=>l.evaluate(c)&&d.evaluate(c)],[Yl(on),(c,l)=>{for(const d of l)if(!d.evaluate(c))return!1;return!0}]]},any:{type:on,overloads:[[[on,on],(c,[l,d])=>l.evaluate(c)||d.evaluate(c)],[Yl(on),(c,l)=>{for(const d of l)if(d.evaluate(c))return!0;return!1}]]},"!":[on,[on],(c,[l])=>!l.evaluate(c)],"is-supported-script":[on,[Fn],(c,[l])=>{const d=c.globals&&c.globals.isSupportedScript;return!d||d(l.evaluate(c))}],upcase:[Fn,[Fn],(c,[l])=>l.evaluate(c).toUpperCase()],downcase:[Fn,[Fn],(c,[l])=>l.evaluate(c).toLowerCase()],concat:[Fn,Yl(In),(c,l)=>l.map(d=>En(d.evaluate(c))).join("")],"resolved-locale":[Fn,[Gn],(c,[l])=>l.evaluate(c).resolvedLocale()]});class So{constructor(l,d){var y;this.expression=l,this._warningHistory={},this._evaluator=new _l,this._defaultValue=d?(y=d).type==="color"&&Ch(y.default)?new Ai(0,0,0,0):y.type==="color"?Ai.parse(y.default)||null:y.type==="padding"?Gi.parse(y.default)||null:y.type==="variableAnchorOffsetCollection"?ve.parse(y.default)||null:y.default===void 0?null:y.default:null,this._enumValues=d&&d.type==="enum"?d.values:null}evaluateWithoutErrorHandling(l,d,y,w,T,K){return this._evaluator.globals=l,this._evaluator.feature=d,this._evaluator.featureState=y,this._evaluator.canonical=w,this._evaluator.availableImages=T||null,this._evaluator.formattedSection=K,this.expression.evaluate(this._evaluator)}evaluate(l,d,y,w,T,K){this._evaluator.globals=l,this._evaluator.feature=d||null,this._evaluator.featureState=y||null,this._evaluator.canonical=w,this._evaluator.availableImages=T||null,this._evaluator.formattedSection=K||null;try{const D=this.expression.evaluate(this._evaluator);if(D==null||typeof D=="number"&&D!=D)return this._defaultValue;if(this._enumValues&&!(D in this._enumValues))throw new Lr(`Expected value to be one of ${Object.keys(this._enumValues).map(z=>JSON.stringify(z)).join(", ")}, but found ${JSON.stringify(D)} instead.`);return D}catch(D){return this._warningHistory[D.message]||(this._warningHistory[D.message]=!0,typeof console<"u"&&console.warn(D.message)),this._defaultValue}}}function tc(c){return Array.isArray(c)&&c.length>0&&typeof c[0]=="string"&&c[0]in Mo}function nc(c,l){const d=new Qa(Mo,lu,[],l?function(w){const T={color:m,string:Fn,number:Lt,enum:Fn,boolean:on,formatted:Zn,padding:Ke,resolvedImage:fe,variableAnchorOffsetCollection:_e};return w.type==="array"?Ee(T[w.value]||In,w.length):T[w.type]}(l):void 0),y=d.parse(c,void 0,void 0,void 0,l&&l.type==="string"?{typeAnnotation:"coerce"}:void 0);return y?JA(new So(y,l)):Qc(d.errors)}class Ls{constructor(l,d){this.kind=l,this._styleExpression=d,this.isStateDependent=l!=="constant"&&!uu(d.expression)}evaluateWithoutErrorHandling(l,d,y,w,T,K){return this._styleExpression.evaluateWithoutErrorHandling(l,d,y,w,T,K)}evaluate(l,d,y,w,T,K){return this._styleExpression.evaluate(l,d,y,w,T,K)}}class Kd{constructor(l,d,y,w){this.kind=l,this.zoomStops=y,this._styleExpression=d,this.isStateDependent=l!=="camera"&&!uu(d.expression),this.interpolationType=w}evaluateWithoutErrorHandling(l,d,y,w,T,K){return this._styleExpression.evaluateWithoutErrorHandling(l,d,y,w,T,K)}evaluate(l,d,y,w,T,K){return this._styleExpression.evaluate(l,d,y,w,T,K)}interpolationFactor(l,d,y){return this.interpolationType?_n.interpolationFactor(this.interpolationType,l,d,y):0}}function Ou(c,l){const d=nc(c,l);if(d.result==="error")return d;const y=d.value.expression,w=wu(y);if(!w&&!$c(l))return Qc([new bt("","data expressions not supported")]);const T=as(y,["zoom"]);if(!T&&!xf(l))return Qc([new bt("","zoom expressions not supported")]);const K=Xu(y);return K||T?K instanceof bt?Qc([K]):K instanceof _n&&!ql(l)?Qc([new bt("",'"interpolate" expressions cannot be used with this property')]):JA(K?new Kd(w?"camera":"composite",d.value,K.labels,K instanceof _n?K.interpolation:void 0):new Ls(w?"constant":"source",d.value)):Qc([new bt("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')])}class xl{constructor(l,d){this._parameters=l,this._specification=d,At(this,ec(this._parameters,this._specification))}static deserialize(l){return new xl(l._parameters,l._specification)}static serialize(l){return{_parameters:l._parameters,_specification:l._specification}}}function Xu(c){let l=null;if(c instanceof qr)l=Xu(c.result);else if(c instanceof Ki){for(const d of c.args)if(l=Xu(d),l)break}else(c instanceof Au||c instanceof _n)&&c.input instanceof Cs&&c.input.name==="zoom"&&(l=c);return l instanceof bt||c.eachChild(d=>{const y=Xu(d);y instanceof bt?l=y:!l&&y?l=new bt("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):l&&y&&l!==y&&(l=new bt("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),l}function qc(c){if(c===!0||c===!1)return!0;if(!Array.isArray(c)||c.length===0)return!1;switch(c[0]){case"has":return c.length>=2&&c[1]!=="$id"&&c[1]!=="$type";case"in":return c.length>=3&&(typeof c[1]!="string"||Array.isArray(c[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return c.length!==3||Array.isArray(c[1])||Array.isArray(c[2]);case"any":case"all":for(const l of c.slice(1))if(!qc(l)&&typeof l!="boolean")return!1;return!0;default:return!0}}const Mf={type:"boolean",default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}};function wl(c){if(c==null)return{filter:()=>!0,needGeometry:!1};qc(c)||(c=eA(c));const l=nc(c,Mf);if(l.result==="error")throw new Error(l.value.map(d=>`${d.key}: ${d.message}`).join(", "));return{filter:(d,y,w)=>l.value.evaluate(d,y,{},w),needGeometry:bh(c)}}function Ju(c,l){return c<l?-1:c>l?1:0}function bh(c){if(!Array.isArray(c))return!1;if(c[0]==="within")return!0;for(let l=1;l<c.length;l++)if(bh(c[l]))return!0;return!1}function eA(c){if(!c)return!0;const l=c[0];return c.length<=1?l!=="any":l==="=="?xh(c[1],c[2],"=="):l==="!="?rc(xh(c[1],c[2],"==")):l==="<"||l===">"||l==="<="||l===">="?xh(c[1],c[2],l):l==="any"?(d=c.slice(1),["any"].concat(d.map(eA))):l==="all"?["all"].concat(c.slice(1).map(eA)):l==="none"?["all"].concat(c.slice(1).map(eA).map(rc)):l==="in"?kp(c[1],c.slice(2)):l==="!in"?rc(kp(c[1],c.slice(2))):l==="has"?Pd(c[1]):l==="!has"?rc(Pd(c[1])):l!=="within"||c;var d}function xh(c,l,d){switch(c){case"$type":return[`filter-type-${d}`,l];case"$id":return[`filter-id-${d}`,l];default:return[`filter-${d}`,c,l]}}function kp(c,l){if(l.length===0)return!1;switch(c){case"$type":return["filter-type-in",["literal",l]];case"$id":return["filter-id-in",["literal",l]];default:return l.length>200&&!l.some(d=>typeof d!=typeof l[0])?["filter-in-large",c,["literal",l.sort(Ju)]]:["filter-in-small",c,["literal",l]]}}function Pd(c){switch(c){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",c]}}function rc(c){return["!",c]}function Hs(c){const l=typeof c;if(l==="number"||l==="boolean"||l==="string"||c==null)return JSON.stringify(c);if(Array.isArray(c)){let w="[";for(const T of c)w+=`${Hs(T)},`;return`${w}]`}const d=Object.keys(c).sort();let y="{";for(let w=0;w<d.length;w++)y+=`${JSON.stringify(d[w])}:${Hs(c[d[w]])},`;return`${y}}`}function Ml(c){let l="";for(const d of pn)l+=`/${Hs(c[d])}`;return l}function wh(c){const l=c.value;return l?[new me(c.key,l,"constants have been deprecated as of v8")]:[]}function ra(c){return c instanceof Number||c instanceof String||c instanceof Boolean?c.valueOf():c}function Bu(c){if(Array.isArray(c))return c.map(Bu);if(c instanceof Object&&!(c instanceof Number||c instanceof String||c instanceof Boolean)){const l={};for(const d in c)l[d]=Bu(c[d]);return l}return ra(c)}function bs(c){const l=c.key,d=c.value,y=c.valueSpec||{},w=c.objectElementValidators||{},T=c.style,K=c.styleSpec,D=c.validateSpec;let z=[];const Q=Ur(d);if(Q!=="object")return[new me(l,d,`object expected, ${Q} found`)];for(const ie in d){const le=ie.split(".")[0],ge=y[le]||y["*"];let Oe;if(w[le])Oe=w[le];else if(y[le])Oe=D;else if(w["*"])Oe=w["*"];else{if(!y["*"]){z.push(new me(l,d[ie],`unknown property "${ie}"`));continue}Oe=D}z=z.concat(Oe({key:(l&&`${l}.`)+ie,value:d[ie],valueSpec:ge,style:T,styleSpec:K,object:d,objectKey:ie,validateSpec:D},d))}for(const ie in y)w[ie]||y[ie].required&&y[ie].default===void 0&&d[ie]===void 0&&z.push(new me(l,d,`missing required property "${ie}"`));return z}function ul(c){const l=c.value,d=c.valueSpec,y=c.style,w=c.styleSpec,T=c.key,K=c.arrayElementValidator||c.validateSpec;if(Ur(l)!=="array")return[new me(T,l,`array expected, ${Ur(l)} found`)];if(d.length&&l.length!==d.length)return[new me(T,l,`array length ${d.length} expected, length ${l.length} found`)];if(d["min-length"]&&l.length<d["min-length"])return[new me(T,l,`array length at least ${d["min-length"]} expected, length ${l.length} found`)];let D={type:d.value,values:d.values};w.$version<7&&(D.function=d.function),Ur(d.value)==="object"&&(D=d.value);let z=[];for(let Q=0;Q<l.length;Q++)z=z.concat(K({array:l,arrayIndex:Q,value:l[Q],valueSpec:D,validateSpec:c.validateSpec,style:y,styleSpec:w,key:`${T}[${Q}]`}));return z}function Fd(c){const l=c.key,d=c.value,y=c.valueSpec;let w=Ur(d);return w==="number"&&d!=d&&(w="NaN"),w!=="number"?[new me(l,d,`number expected, ${w} found`)]:"minimum"in y&&d<y.minimum?[new me(l,d,`${d} is less than the minimum value ${y.minimum}`)]:"maximum"in y&&d>y.maximum?[new me(l,d,`${d} is greater than the maximum value ${y.maximum}`)]:[]}function Dd(c){const l=c.valueSpec,d=ra(c.value.type);let y,w,T,K={};const D=d!=="categorical"&&c.value.property===void 0,z=!D,Q=Ur(c.value.stops)==="array"&&Ur(c.value.stops[0])==="array"&&Ur(c.value.stops[0][0])==="object",ie=bs({key:c.key,value:c.value,valueSpec:c.styleSpec.function,validateSpec:c.validateSpec,style:c.style,styleSpec:c.styleSpec,objectElementValidators:{stops:function(Oe){if(d==="identity")return[new me(Oe.key,Oe.value,'identity function may not have a "stops" property')];let Be=[];const ze=Oe.value;return Be=Be.concat(ul({key:Oe.key,value:ze,valueSpec:Oe.valueSpec,validateSpec:Oe.validateSpec,style:Oe.style,styleSpec:Oe.styleSpec,arrayElementValidator:le})),Ur(ze)==="array"&&ze.length===0&&Be.push(new me(Oe.key,ze,"array must have at least one stop")),Be},default:function(Oe){return Oe.validateSpec({key:Oe.key,value:Oe.value,valueSpec:l,validateSpec:Oe.validateSpec,style:Oe.style,styleSpec:Oe.styleSpec})}}});return d==="identity"&&D&&ie.push(new me(c.key,c.value,'missing required property "property"')),d==="identity"||c.value.stops||ie.push(new me(c.key,c.value,'missing required property "stops"')),d==="exponential"&&c.valueSpec.expression&&!ql(c.valueSpec)&&ie.push(new me(c.key,c.value,"exponential functions not supported")),c.styleSpec.$version>=8&&(z&&!$c(c.valueSpec)?ie.push(new me(c.key,c.value,"property functions not supported")):D&&!xf(c.valueSpec)&&ie.push(new me(c.key,c.value,"zoom functions not supported"))),d!=="categorical"&&!Q||c.value.property!==void 0||ie.push(new me(c.key,c.value,'"property" property is required')),ie;function le(Oe){let Be=[];const ze=Oe.value,$e=Oe.key;if(Ur(ze)!=="array")return[new me($e,ze,`array expected, ${Ur(ze)} found`)];if(ze.length!==2)return[new me($e,ze,`array length 2 expected, length ${ze.length} found`)];if(Q){if(Ur(ze[0])!=="object")return[new me($e,ze,`object expected, ${Ur(ze[0])} found`)];if(ze[0].zoom===void 0)return[new me($e,ze,"object stop key must have zoom")];if(ze[0].value===void 0)return[new me($e,ze,"object stop key must have value")];if(T&&T>ra(ze[0].zoom))return[new me($e,ze[0].zoom,"stop zoom values must appear in ascending order")];ra(ze[0].zoom)!==T&&(T=ra(ze[0].zoom),w=void 0,K={}),Be=Be.concat(bs({key:`${$e}[0]`,value:ze[0],valueSpec:{zoom:{}},validateSpec:Oe.validateSpec,style:Oe.style,styleSpec:Oe.styleSpec,objectElementValidators:{zoom:Fd,value:ge}}))}else Be=Be.concat(ge({key:`${$e}[0]`,value:ze[0],valueSpec:{},validateSpec:Oe.validateSpec,style:Oe.style,styleSpec:Oe.styleSpec},ze));return tc(Bu(ze[1]))?Be.concat([new me(`${$e}[1]`,ze[1],"expressions are not allowed in function stops.")]):Be.concat(Oe.validateSpec({key:`${$e}[1]`,value:ze[1],valueSpec:l,validateSpec:Oe.validateSpec,style:Oe.style,styleSpec:Oe.styleSpec}))}function ge(Oe,Be){const ze=Ur(Oe.value),$e=ra(Oe.value),tt=Oe.value!==null?Oe.value:Be;if(y){if(ze!==y)return[new me(Oe.key,tt,`${ze} stop domain type must match previous stop domain type ${y}`)]}else y=ze;if(ze!=="number"&&ze!=="string"&&ze!=="boolean")return[new me(Oe.key,tt,"stop domain value must be a number, string, or boolean")];if(ze!=="number"&&d!=="categorical"){let St=`number expected, ${ze} found`;return $c(l)&&d===void 0&&(St+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new me(Oe.key,tt,St)]}return d!=="categorical"||ze!=="number"||isFinite($e)&&Math.floor($e)===$e?d!=="categorical"&&ze==="number"&&w!==void 0&&$e<w?[new me(Oe.key,tt,"stop domain values must appear in ascending order")]:(w=$e,d==="categorical"&&$e in K?[new me(Oe.key,tt,"stop domain values must be unique")]:(K[$e]=!0,[])):[new me(Oe.key,tt,`integer expected, found ${$e}`)]}}function Sl(c){const l=(c.expressionContext==="property"?Ou:nc)(Bu(c.value),c.valueSpec);if(l.result==="error")return l.value.map(y=>new me(`${c.key}${y.key}`,c.value,y.message));const d=l.value.expression||l.value._styleExpression.expression;if(c.expressionContext==="property"&&c.propertyKey==="text-font"&&!d.outputDefined())return[new me(c.key,c.value,`Invalid data expression for "${c.propertyKey}". Output values must be contained as literals within the expression.`)];if(c.expressionContext==="property"&&c.propertyType==="layout"&&!uu(d))return[new me(c.key,c.value,'"feature-state" data expressions are not supported with layout properties.')];if(c.expressionContext==="filter"&&!uu(d))return[new me(c.key,c.value,'"feature-state" data expressions are not supported with filters.')];if(c.expressionContext&&c.expressionContext.indexOf("cluster")===0){if(!as(d,["zoom","feature-state"]))return[new me(c.key,c.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(c.expressionContext==="cluster-initial"&&!wu(d))return[new me(c.key,c.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function xA(c){const l=c.key,d=c.value,y=c.valueSpec,w=[];return Array.isArray(y.values)?y.values.indexOf(ra(d))===-1&&w.push(new me(l,d,`expected one of [${y.values.join(", ")}], ${JSON.stringify(d)} found`)):Object.keys(y.values).indexOf(ra(d))===-1&&w.push(new me(l,d,`expected one of [${Object.keys(y.values).join(", ")}], ${JSON.stringify(d)} found`)),w}function Vc(c){return qc(Bu(c.value))?Sl(At({},c,{expressionContext:"filter",valueSpec:{value:"boolean"}})):Ud(c)}function Ud(c){const l=c.value,d=c.key;if(Ur(l)!=="array")return[new me(d,l,`array expected, ${Ur(l)} found`)];const y=c.styleSpec;let w,T=[];if(l.length<1)return[new me(d,l,"filter array must have at least 1 element")];switch(T=T.concat(xA({key:`${d}[0]`,value:l[0],valueSpec:y.filter_operator,style:c.style,styleSpec:c.styleSpec})),ra(l[0])){case"<":case"<=":case">":case">=":l.length>=2&&ra(l[1])==="$type"&&T.push(new me(d,l,`"$type" cannot be use with operator "${l[0]}"`));case"==":case"!=":l.length!==3&&T.push(new me(d,l,`filter array for operator "${l[0]}" must have 3 elements`));case"in":case"!in":l.length>=2&&(w=Ur(l[1]),w!=="string"&&T.push(new me(`${d}[1]`,l[1],`string expected, ${w} found`)));for(let K=2;K<l.length;K++)w=Ur(l[K]),ra(l[1])==="$type"?T=T.concat(xA({key:`${d}[${K}]`,value:l[K],valueSpec:y.geometry_type,style:c.style,styleSpec:c.styleSpec})):w!=="string"&&w!=="number"&&w!=="boolean"&&T.push(new me(`${d}[${K}]`,l[K],`string, number, or boolean expected, ${w} found`));break;case"any":case"all":case"none":for(let K=1;K<l.length;K++)T=T.concat(Ud({key:`${d}[${K}]`,value:l[K],style:c.style,styleSpec:c.styleSpec}));break;case"has":case"!has":w=Ur(l[1]),l.length!==2?T.push(new me(d,l,`filter array for "${l[0]}" operator must have 2 elements`)):w!=="string"&&T.push(new me(`${d}[1]`,l[1],`string expected, ${w} found`));break;case"within":w=Ur(l[1]),l.length!==2?T.push(new me(d,l,`filter array for "${l[0]}" operator must have 2 elements`)):w!=="object"&&T.push(new me(`${d}[1]`,l[1],`object expected, ${w} found`))}return T}function ku(c,l){const d=c.key,y=c.validateSpec,w=c.style,T=c.styleSpec,K=c.value,D=c.objectKey,z=T[`${l}_${c.layerType}`];if(!z)return[];const Q=D.match(/^(.*)-transition$/);if(l==="paint"&&Q&&z[Q[1]]&&z[Q[1]].transition)return y({key:d,value:K,valueSpec:T.transition,style:w,styleSpec:T});const ie=c.valueSpec||z[D];if(!ie)return[new me(d,K,`unknown property "${D}"`)];let le;if(Ur(K)==="string"&&$c(ie)&&!ie.tokens&&(le=/^{([^}]+)}$/.exec(K)))return[new me(d,K,`"${D}" does not support interpolation syntax
|
||
Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(le[1])} }\`.`)];const ge=[];return c.layerType==="symbol"&&(D==="text-field"&&w&&!w.glyphs&&ge.push(new me(d,K,'use of "text-field" requires a style "glyphs" property')),D==="text-font"&&Ch(Bu(K))&&ra(K.type)==="identity"&&ge.push(new me(d,K,'"text-font" does not support identity functions'))),ge.concat(y({key:c.key,value:K,valueSpec:ie,style:w,styleSpec:T,expressionContext:"property",propertyType:l,propertyKey:D}))}function xt(c){return ku(c,"paint")}function sn(c){return ku(c,"layout")}function Wt(c){let l=[];const d=c.value,y=c.key,w=c.style,T=c.styleSpec;d.type||d.ref||l.push(new me(y,d,'either "type" or "ref" is required'));let K=ra(d.type);const D=ra(d.ref);if(d.id){const z=ra(d.id);for(let Q=0;Q<c.arrayIndex;Q++){const ie=w.layers[Q];ra(ie.id)===z&&l.push(new me(y,d.id,`duplicate layer id "${d.id}", previously used at line ${ie.id.__line__}`))}}if("ref"in d){let z;["type","source","source-layer","filter","layout"].forEach(Q=>{Q in d&&l.push(new me(y,d[Q],`"${Q}" is prohibited for ref layers`))}),w.layers.forEach(Q=>{ra(Q.id)===D&&(z=Q)}),z?z.ref?l.push(new me(y,d.ref,"ref cannot reference another ref layer")):K=ra(z.type):l.push(new me(y,d.ref,`ref layer "${D}" not found`))}else if(K!=="background")if(d.source){const z=w.sources&&w.sources[d.source],Q=z&&ra(z.type);z?Q==="vector"&&K==="raster"?l.push(new me(y,d.source,`layer "${d.id}" requires a raster source`)):Q!=="raster-dem"&&K==="hillshade"?l.push(new me(y,d.source,`layer "${d.id}" requires a raster-dem source`)):Q==="raster"&&K!=="raster"?l.push(new me(y,d.source,`layer "${d.id}" requires a vector source`)):Q!=="vector"||d["source-layer"]?Q==="raster-dem"&&K!=="hillshade"?l.push(new me(y,d.source,"raster-dem source can only be used with layer type 'hillshade'.")):K!=="line"||!d.paint||!d.paint["line-gradient"]||Q==="geojson"&&z.lineMetrics||l.push(new me(y,d,`layer "${d.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):l.push(new me(y,d,`layer "${d.id}" must specify a "source-layer"`)):l.push(new me(y,d.source,`source "${d.source}" not found`))}else l.push(new me(y,d,'missing required property "source"'));return l=l.concat(bs({key:y,value:d,valueSpec:T.layer,style:c.style,styleSpec:c.styleSpec,validateSpec:c.validateSpec,objectElementValidators:{"*":()=>[],type:()=>c.validateSpec({key:`${y}.type`,value:d.type,valueSpec:T.layer.type,style:c.style,styleSpec:c.styleSpec,validateSpec:c.validateSpec,object:d,objectKey:"type"}),filter:Vc,layout:z=>bs({layer:d,key:z.key,value:z.value,style:z.style,styleSpec:z.styleSpec,validateSpec:z.validateSpec,objectElementValidators:{"*":Q=>sn(At({layerType:K},Q))}}),paint:z=>bs({layer:d,key:z.key,value:z.value,style:z.style,styleSpec:z.styleSpec,validateSpec:z.validateSpec,objectElementValidators:{"*":Q=>xt(At({layerType:K},Q))}})}})),l}function or(c){const l=c.value,d=c.key,y=Ur(l);return y!=="string"?[new me(d,l,`string expected, ${y} found`)]:[]}const ri={promoteId:function({key:c,value:l}){if(Ur(l)==="string")return or({key:c,value:l});{const d=[];for(const y in l)d.push(...or({key:`${c}.${y}`,value:l[y]}));return d}}};function to(c){const l=c.value,d=c.key,y=c.styleSpec,w=c.style,T=c.validateSpec;if(!l.type)return[new me(d,l,'"type" is required')];const K=ra(l.type);let D;switch(K){case"vector":case"raster":return D=bs({key:d,value:l,valueSpec:y[`source_${K.replace("-","_")}`],style:c.style,styleSpec:y,objectElementValidators:ri,validateSpec:T}),D;case"raster-dem":return D=function(z){var Q;const ie=(Q=z.sourceName)!==null&&Q!==void 0?Q:"",le=z.value,ge=z.styleSpec,Oe=ge.source_raster_dem,Be=z.style;let ze=[];const $e=Ur(le);if(le===void 0)return ze;if($e!=="object")return ze.push(new me("source_raster_dem",le,`object expected, ${$e} found`)),ze;const tt=ra(le.encoding)==="custom",St=["redFactor","greenFactor","blueFactor","baseShift"],lt=z.value.encoding?`"${z.value.encoding}"`:"Default";for(const vt in le)!tt&&St.includes(vt)?ze.push(new me(vt,le[vt],`In "${ie}": "${vt}" is only valid when "encoding" is set to "custom". ${lt} encoding found`)):Oe[vt]?ze=ze.concat(z.validateSpec({key:vt,value:le[vt],valueSpec:Oe[vt],validateSpec:z.validateSpec,style:Be,styleSpec:ge})):ze.push(new me(vt,le[vt],`unknown property "${vt}"`));return ze}({sourceName:d,value:l,style:c.style,styleSpec:y,validateSpec:T}),D;case"geojson":if(D=bs({key:d,value:l,valueSpec:y.source_geojson,style:w,styleSpec:y,validateSpec:T,objectElementValidators:ri}),l.cluster)for(const z in l.clusterProperties){const[Q,ie]=l.clusterProperties[z],le=typeof Q=="string"?[Q,["accumulated"],["get",z]]:Q;D.push(...Sl({key:`${d}.${z}.map`,value:ie,validateSpec:T,expressionContext:"cluster-map"})),D.push(...Sl({key:`${d}.${z}.reduce`,value:le,validateSpec:T,expressionContext:"cluster-reduce"}))}return D;case"video":return bs({key:d,value:l,valueSpec:y.source_video,style:w,validateSpec:T,styleSpec:y});case"image":return bs({key:d,value:l,valueSpec:y.source_image,style:w,validateSpec:T,styleSpec:y});case"canvas":return[new me(d,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return xA({key:`${d}.type`,value:l.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]},style:w,validateSpec:T,styleSpec:y})}}function ia(c){const l=c.value,d=c.styleSpec,y=d.light,w=c.style;let T=[];const K=Ur(l);if(l===void 0)return T;if(K!=="object")return T=T.concat([new me("light",l,`object expected, ${K} found`)]),T;for(const D in l){const z=D.match(/^(.*)-transition$/);T=T.concat(z&&y[z[1]]&&y[z[1]].transition?c.validateSpec({key:D,value:l[D],valueSpec:d.transition,validateSpec:c.validateSpec,style:w,styleSpec:d}):y[D]?c.validateSpec({key:D,value:l[D],valueSpec:y[D],validateSpec:c.validateSpec,style:w,styleSpec:d}):[new me(D,l[D],`unknown property "${D}"`)])}return T}function ho(c){const l=c.value,d=c.styleSpec,y=d.sky,w=c.style,T=Ur(l);if(l===void 0)return[];if(T!=="object")return[new me("sky",l,`object expected, ${T} found`)];let K=[];for(const D in l)K=K.concat(y[D]?tA({key:D,value:l[D],valueSpec:y[D],style:w,styleSpec:d}):[new me(D,l[D],`unknown property "${D}"`)]);return K}function xs(c){const l=c.value,d=c.styleSpec,y=d.terrain,w=c.style;let T=[];const K=Ur(l);if(l===void 0)return T;if(K!=="object")return T=T.concat([new me("terrain",l,`object expected, ${K} found`)]),T;for(const D in l)T=T.concat(y[D]?c.validateSpec({key:D,value:l[D],valueSpec:y[D],validateSpec:c.validateSpec,style:w,styleSpec:d}):[new me(D,l[D],`unknown property "${D}"`)]);return T}function Rd(c){let l=[];const d=c.value,y=c.key;if(Array.isArray(d)){const w=[],T=[];for(const K in d)d[K].id&&w.includes(d[K].id)&&l.push(new me(y,d,`all the sprites' ids must be unique, but ${d[K].id} is duplicated`)),w.push(d[K].id),d[K].url&&T.includes(d[K].url)&&l.push(new me(y,d,`all the sprites' URLs must be unique, but ${d[K].url} is duplicated`)),T.push(d[K].url),l=l.concat(bs({key:`${y}[${K}]`,value:d[K],valueSpec:{id:{type:"string",required:!0},url:{type:"string",required:!0}},validateSpec:c.validateSpec}));return l}return or({key:y,value:d})}const El={"*":()=>[],array:ul,boolean:function(c){const l=c.value,d=c.key,y=Ur(l);return y!=="boolean"?[new me(d,l,`boolean expected, ${y} found`)]:[]},number:Fd,color:function(c){const l=c.key,d=c.value,y=Ur(d);return y!=="string"?[new me(l,d,`color expected, ${y} found`)]:Ai.parse(String(d))?[]:[new me(l,d,`color expected, "${d}" found`)]},constants:wh,enum:xA,filter:Vc,function:Dd,layer:Wt,object:bs,source:to,light:ia,sky:ho,terrain:xs,string:or,formatted:function(c){return or(c).length===0?[]:Sl(c)},resolvedImage:function(c){return or(c).length===0?[]:Sl(c)},padding:function(c){const l=c.key,d=c.value;if(Ur(d)==="array"){if(d.length<1||d.length>4)return[new me(l,d,`padding requires 1 to 4 values; ${d.length} values found`)];const y={type:"number"};let w=[];for(let T=0;T<d.length;T++)w=w.concat(c.validateSpec({key:`${l}[${T}]`,value:d[T],validateSpec:c.validateSpec,valueSpec:y}));return w}return Fd({key:l,value:d,valueSpec:{}})},variableAnchorOffsetCollection:function(c){const l=c.key,d=c.value,y=Ur(d),w=c.styleSpec;if(y!=="array"||d.length<1||d.length%2!=0)return[new me(l,d,"variableAnchorOffsetCollection requires a non-empty array of even length")];let T=[];for(let K=0;K<d.length;K+=2)T=T.concat(xA({key:`${l}[${K}]`,value:d[K],valueSpec:w.layout_symbol["text-anchor"]})),T=T.concat(ul({key:`${l}[${K+1}]`,value:d[K+1],valueSpec:{length:2,value:"number"},validateSpec:c.validateSpec,style:c.style,styleSpec:w}));return T},sprite:Rd};function tA(c){const l=c.value,d=c.valueSpec,y=c.styleSpec;return c.validateSpec=tA,d.expression&&Ch(ra(l))?Dd(c):d.expression&&tc(Bu(l))?Sl(c):d.type&&El[d.type]?El[d.type](c):bs(At({},c,{valueSpec:d.type?y[d.type]:d}))}function wA(c){const l=c.value,d=c.key,y=or(c);return y.length||(l.indexOf("{fontstack}")===-1&&y.push(new me(d,l,'"glyphs" url must include a "{fontstack}" token')),l.indexOf("{range}")===-1&&y.push(new me(d,l,'"glyphs" url must include a "{range}" token'))),y}function Jo(c,l=mt){let d=[];return d=d.concat(tA({key:"",value:c,valueSpec:l.$root,styleSpec:l,style:c,validateSpec:tA,objectElementValidators:{glyphs:wA,"*":()=>[]}})),c.constants&&(d=d.concat(wh({key:"constants",value:c.constants,style:c,styleSpec:l,validateSpec:tA}))),nA(d)}function ls(c){return function(l){return c({...l,validateSpec:tA})}}function nA(c){return[].concat(c).sort((l,d)=>l.line-d.line)}function Ei(c){return function(...l){return nA(c.apply(this,l))}}Jo.source=Ei(ls(to)),Jo.sprite=Ei(ls(Rd)),Jo.glyphs=Ei(ls(wA)),Jo.light=Ei(ls(ia)),Jo.sky=Ei(ls(ho)),Jo.terrain=Ei(ls(xs)),Jo.layer=Ei(ls(Wt)),Jo.filter=Ei(ls(Vc)),Jo.paintProperty=Ei(ls(xt)),Jo.layoutProperty=Ei(ls(sn));const MA=Jo,Mh=MA.light,Al=MA.paintProperty,ic=MA.layoutProperty;function us(c,l){let d=!1;if(l&&l.length)for(const y of l)c.fire(new Pt(new Error(y.message))),d=!0;return d}class Ol{constructor(l,d,y){const w=this.cells=[];if(l instanceof ArrayBuffer){this.arrayBuffer=l;const K=new Int32Array(this.arrayBuffer);l=K[0],this.d=(d=K[1])+2*(y=K[2]);for(let z=0;z<this.d*this.d;z++){const Q=K[3+z],ie=K[3+z+1];w.push(Q===ie?null:K.subarray(Q,ie))}const D=K[3+w.length+1];this.keys=K.subarray(K[3+w.length],D),this.bboxes=K.subarray(D),this.insert=this._insertReadonly}else{this.d=d+2*y;for(let K=0;K<this.d*this.d;K++)w.push([]);this.keys=[],this.bboxes=[]}this.n=d,this.extent=l,this.padding=y,this.scale=d/l,this.uid=0;const T=y/d*l;this.min=-T,this.max=l+T}insert(l,d,y,w,T){this._forEachCell(d,y,w,T,this._insertCell,this.uid++,void 0,void 0),this.keys.push(l),this.bboxes.push(d),this.bboxes.push(y),this.bboxes.push(w),this.bboxes.push(T)}_insertReadonly(){throw new Error("Cannot insert into a GridIndex created from an ArrayBuffer.")}_insertCell(l,d,y,w,T,K){this.cells[T].push(K)}query(l,d,y,w,T){const K=this.min,D=this.max;if(l<=K&&d<=K&&D<=y&&D<=w&&!T)return Array.prototype.slice.call(this.keys);{const z=[];return this._forEachCell(l,d,y,w,this._queryCell,z,{},T),z}}_queryCell(l,d,y,w,T,K,D,z){const Q=this.cells[T];if(Q!==null){const ie=this.keys,le=this.bboxes;for(let ge=0;ge<Q.length;ge++){const Oe=Q[ge];if(D[Oe]===void 0){const Be=4*Oe;(z?z(le[Be+0],le[Be+1],le[Be+2],le[Be+3]):l<=le[Be+2]&&d<=le[Be+3]&&y>=le[Be+0]&&w>=le[Be+1])?(D[Oe]=!0,K.push(ie[Oe])):D[Oe]=!1}}}}_forEachCell(l,d,y,w,T,K,D,z){const Q=this._convertToCellCoord(l),ie=this._convertToCellCoord(d),le=this._convertToCellCoord(y),ge=this._convertToCellCoord(w);for(let Oe=Q;Oe<=le;Oe++)for(let Be=ie;Be<=ge;Be++){const ze=this.d*Be+Oe;if((!z||z(this._convertFromCellCoord(Oe),this._convertFromCellCoord(Be),this._convertFromCellCoord(Oe+1),this._convertFromCellCoord(Be+1)))&&T.call(this,l,d,y,w,ze,K,D,z))return}}_convertFromCellCoord(l){return(l-this.padding)/this.scale}_convertToCellCoord(l){return Math.max(0,Math.min(this.d-1,Math.floor(l*this.scale)+this.padding))}toArrayBuffer(){if(this.arrayBuffer)return this.arrayBuffer;const l=this.cells,d=3+this.cells.length+1+1;let y=0;for(let K=0;K<this.cells.length;K++)y+=this.cells[K].length;const w=new Int32Array(d+y+this.keys.length+this.bboxes.length);w[0]=this.extent,w[1]=this.n,w[2]=this.padding;let T=d;for(let K=0;K<l.length;K++){const D=l[K];w[3+K]=T,w.set(D,T),T+=D.length}return w[3+l.length]=T,w.set(this.keys,T),T+=this.keys.length,w[3+l.length+1]=T,w.set(this.bboxes,T),T+=this.bboxes.length,w.buffer}static serialize(l,d){const y=l.toArrayBuffer();return d&&d.push(y),{buffer:y}}static deserialize(l){return new Ol(l.buffer)}}const Fa={};function jn(c,l,d={}){if(Fa[c])throw new Error(`${c} is already registered.`);Object.defineProperty(l,"_classRegistryKey",{value:c,writeable:!1}),Fa[c]={klass:l,omit:d.omit||[],shallow:d.shallow||[]}}jn("Object",Object),jn("TransferableGridIndex",Ol),jn("Color",Ai),jn("Error",Error),jn("AJAXError",de),jn("ResolvedImage",Ge),jn("StylePropertyFunction",xl),jn("StyleExpression",So,{omit:["_evaluator"]}),jn("ZoomDependentExpression",Kd),jn("ZoomConstantExpression",Ls),jn("CompoundExpression",Cs,{omit:["_evaluate"]});for(const c in Mo)Mo[c]._classRegistryKey||jn(`Expression_${c}`,Mo[c]);function Hc(c){return c&&typeof ArrayBuffer<"u"&&(c instanceof ArrayBuffer||c.constructor&&c.constructor.name==="ArrayBuffer")}function oc(c,l){if(c==null||typeof c=="boolean"||typeof c=="number"||typeof c=="string"||c instanceof Boolean||c instanceof Number||c instanceof String||c instanceof Date||c instanceof RegExp||c instanceof Blob||c instanceof Error)return c;if(Hc(c)||Nt(c))return l&&l.push(c),c;if(ArrayBuffer.isView(c)){const d=c;return l&&l.push(d.buffer),d}if(c instanceof ImageData)return l&&l.push(c.data.buffer),c;if(Array.isArray(c)){const d=[];for(const y of c)d.push(oc(y,l));return d}if(typeof c=="object"){const d=c.constructor,y=d._classRegistryKey;if(!y)throw new Error(`can't serialize object of unregistered class ${d.name}`);if(!Fa[y])throw new Error(`${y} is not registered.`);const w=d.serialize?d.serialize(c,l):{};if(d.serialize){if(l&&w===l[l.length-1])throw new Error("statically serialized object won't survive transfer of $name property")}else{for(const T in c){if(!c.hasOwnProperty(T)||Fa[y].omit.indexOf(T)>=0)continue;const K=c[T];w[T]=Fa[y].shallow.indexOf(T)>=0?K:oc(K,l)}c instanceof Error&&(w.message=c.message)}if(w.$name)throw new Error("$name property is reserved for worker serialization logic.");return y!=="Object"&&(w.$name=y),w}throw new Error("can't serialize object of type "+typeof c)}function cl(c){if(c==null||typeof c=="boolean"||typeof c=="number"||typeof c=="string"||c instanceof Boolean||c instanceof Number||c instanceof String||c instanceof Date||c instanceof RegExp||c instanceof Blob||c instanceof Error||Hc(c)||Nt(c)||ArrayBuffer.isView(c)||c instanceof ImageData)return c;if(Array.isArray(c))return c.map(cl);if(typeof c=="object"){const l=c.$name||"Object";if(!Fa[l])throw new Error(`can't deserialize unregistered class ${l}`);const{klass:d}=Fa[l];if(!d)throw new Error(`can't deserialize unregistered class ${l}`);if(d.deserialize)return d.deserialize(c);const y=Object.create(d.prototype);for(const w of Object.keys(c)){if(w==="$name")continue;const T=c[w];y[w]=Fa[l].shallow.indexOf(w)>=0?T:cl(T)}return y}throw new Error("can't deserialize object of type "+typeof c)}class ac{constructor(){this.first=!0}update(l,d){const y=Math.floor(l);return this.first?(this.first=!1,this.lastIntegerZoom=y,this.lastIntegerZoomTime=0,this.lastZoom=l,this.lastFloorZoom=y,!0):(this.lastFloorZoom>y?(this.lastIntegerZoom=y+1,this.lastIntegerZoomTime=d):this.lastFloorZoom<y&&(this.lastIntegerZoom=y,this.lastIntegerZoomTime=d),l!==this.lastZoom&&(this.lastZoom=l,this.lastFloorZoom=y,!0))}}const Nn={"Latin-1 Supplement":c=>c>=128&&c<=255,Arabic:c=>c>=1536&&c<=1791,"Arabic Supplement":c=>c>=1872&&c<=1919,"Arabic Extended-A":c=>c>=2208&&c<=2303,"Hangul Jamo":c=>c>=4352&&c<=4607,"Unified Canadian Aboriginal Syllabics":c=>c>=5120&&c<=5759,Khmer:c=>c>=6016&&c<=6143,"Unified Canadian Aboriginal Syllabics Extended":c=>c>=6320&&c<=6399,"General Punctuation":c=>c>=8192&&c<=8303,"Letterlike Symbols":c=>c>=8448&&c<=8527,"Number Forms":c=>c>=8528&&c<=8591,"Miscellaneous Technical":c=>c>=8960&&c<=9215,"Control Pictures":c=>c>=9216&&c<=9279,"Optical Character Recognition":c=>c>=9280&&c<=9311,"Enclosed Alphanumerics":c=>c>=9312&&c<=9471,"Geometric Shapes":c=>c>=9632&&c<=9727,"Miscellaneous Symbols":c=>c>=9728&&c<=9983,"Miscellaneous Symbols and Arrows":c=>c>=11008&&c<=11263,"CJK Radicals Supplement":c=>c>=11904&&c<=12031,"Kangxi Radicals":c=>c>=12032&&c<=12255,"Ideographic Description Characters":c=>c>=12272&&c<=12287,"CJK Symbols and Punctuation":c=>c>=12288&&c<=12351,Hiragana:c=>c>=12352&&c<=12447,Katakana:c=>c>=12448&&c<=12543,Bopomofo:c=>c>=12544&&c<=12591,"Hangul Compatibility Jamo":c=>c>=12592&&c<=12687,Kanbun:c=>c>=12688&&c<=12703,"Bopomofo Extended":c=>c>=12704&&c<=12735,"CJK Strokes":c=>c>=12736&&c<=12783,"Katakana Phonetic Extensions":c=>c>=12784&&c<=12799,"Enclosed CJK Letters and Months":c=>c>=12800&&c<=13055,"CJK Compatibility":c=>c>=13056&&c<=13311,"CJK Unified Ideographs Extension A":c=>c>=13312&&c<=19903,"Yijing Hexagram Symbols":c=>c>=19904&&c<=19967,"CJK Unified Ideographs":c=>c>=19968&&c<=40959,"Yi Syllables":c=>c>=40960&&c<=42127,"Yi Radicals":c=>c>=42128&&c<=42191,"Hangul Jamo Extended-A":c=>c>=43360&&c<=43391,"Hangul Syllables":c=>c>=44032&&c<=55215,"Hangul Jamo Extended-B":c=>c>=55216&&c<=55295,"Private Use Area":c=>c>=57344&&c<=63743,"CJK Compatibility Ideographs":c=>c>=63744&&c<=64255,"Arabic Presentation Forms-A":c=>c>=64336&&c<=65023,"Vertical Forms":c=>c>=65040&&c<=65055,"CJK Compatibility Forms":c=>c>=65072&&c<=65103,"Small Form Variants":c=>c>=65104&&c<=65135,"Arabic Presentation Forms-B":c=>c>=65136&&c<=65279,"Halfwidth and Fullwidth Forms":c=>c>=65280&&c<=65519};function rA(c){for(const l of c)if(Vl(l.charCodeAt(0)))return!0;return!1}function Sf(c){for(const l of c)if(!sc(l.charCodeAt(0)))return!1;return!0}function sc(c){return!(Nn.Arabic(c)||Nn["Arabic Supplement"](c)||Nn["Arabic Extended-A"](c)||Nn["Arabic Presentation Forms-A"](c)||Nn["Arabic Presentation Forms-B"](c))}function Vl(c){return!(c!==746&&c!==747&&(c<4352||!(Nn["Bopomofo Extended"](c)||Nn.Bopomofo(c)||Nn["CJK Compatibility Forms"](c)&&!(c>=65097&&c<=65103)||Nn["CJK Compatibility Ideographs"](c)||Nn["CJK Compatibility"](c)||Nn["CJK Radicals Supplement"](c)||Nn["CJK Strokes"](c)||!(!Nn["CJK Symbols and Punctuation"](c)||c>=12296&&c<=12305||c>=12308&&c<=12319||c===12336)||Nn["CJK Unified Ideographs Extension A"](c)||Nn["CJK Unified Ideographs"](c)||Nn["Enclosed CJK Letters and Months"](c)||Nn["Hangul Compatibility Jamo"](c)||Nn["Hangul Jamo Extended-A"](c)||Nn["Hangul Jamo Extended-B"](c)||Nn["Hangul Jamo"](c)||Nn["Hangul Syllables"](c)||Nn.Hiragana(c)||Nn["Ideographic Description Characters"](c)||Nn.Kanbun(c)||Nn["Kangxi Radicals"](c)||Nn["Katakana Phonetic Extensions"](c)||Nn.Katakana(c)&&c!==12540||!(!Nn["Halfwidth and Fullwidth Forms"](c)||c===65288||c===65289||c===65293||c>=65306&&c<=65310||c===65339||c===65341||c===65343||c>=65371&&c<=65503||c===65507||c>=65512&&c<=65519)||!(!Nn["Small Form Variants"](c)||c>=65112&&c<=65118||c>=65123&&c<=65126)||Nn["Unified Canadian Aboriginal Syllabics"](c)||Nn["Unified Canadian Aboriginal Syllabics Extended"](c)||Nn["Vertical Forms"](c)||Nn["Yijing Hexagram Symbols"](c)||Nn["Yi Syllables"](c)||Nn["Yi Radicals"](c))))}function lc(c){return!(Vl(c)||function(l){return!!(Nn["Latin-1 Supplement"](l)&&(l===167||l===169||l===174||l===177||l===188||l===189||l===190||l===215||l===247)||Nn["General Punctuation"](l)&&(l===8214||l===8224||l===8225||l===8240||l===8241||l===8251||l===8252||l===8258||l===8263||l===8264||l===8265||l===8273)||Nn["Letterlike Symbols"](l)||Nn["Number Forms"](l)||Nn["Miscellaneous Technical"](l)&&(l>=8960&&l<=8967||l>=8972&&l<=8991||l>=8996&&l<=9e3||l===9003||l>=9085&&l<=9114||l>=9150&&l<=9165||l===9167||l>=9169&&l<=9179||l>=9186&&l<=9215)||Nn["Control Pictures"](l)&&l!==9251||Nn["Optical Character Recognition"](l)||Nn["Enclosed Alphanumerics"](l)||Nn["Geometric Shapes"](l)||Nn["Miscellaneous Symbols"](l)&&!(l>=9754&&l<=9759)||Nn["Miscellaneous Symbols and Arrows"](l)&&(l>=11026&&l<=11055||l>=11088&&l<=11097||l>=11192&&l<=11243)||Nn["CJK Symbols and Punctuation"](l)||Nn.Katakana(l)||Nn["Private Use Area"](l)||Nn["CJK Compatibility Forms"](l)||Nn["Small Form Variants"](l)||Nn["Halfwidth and Fullwidth Forms"](l)||l===8734||l===8756||l===8757||l>=9984&&l<=10087||l>=10102&&l<=10131||l===65532||l===65533)}(c))}function Sh(c){return c>=1424&&c<=2303||Nn["Arabic Presentation Forms-A"](c)||Nn["Arabic Presentation Forms-B"](c)}function Zc(c,l){return!(!l&&Sh(c)||c>=2304&&c<=3583||c>=3840&&c<=4255||Nn.Khmer(c))}function Eh(c){for(const l of c)if(Sh(l.charCodeAt(0)))return!0;return!1}const Hl=new class{constructor(){this.applyArabicShaping=null,this.processBidirectionalText=null,this.processStyledBidirectionalText=null,this.pluginStatus="unavailable",this.pluginURL=null}setState(c){this.pluginStatus=c.pluginStatus,this.pluginURL=c.pluginURL}setMethods(c){this.applyArabicShaping=c.applyArabicShaping,this.processBidirectionalText=c.processBidirectionalText,this.processStyledBidirectionalText=c.processStyledBidirectionalText}isParsed(){return this.applyArabicShaping!=null&&this.processBidirectionalText!=null&&this.processStyledBidirectionalText!=null}getPluginURL(){return this.pluginURL}getRTLTextPluginStatus(){return this.pluginStatus}};class go{constructor(l,d){this.zoom=l,d?(this.now=d.now,this.fadeDuration=d.fadeDuration,this.zoomHistory=d.zoomHistory,this.transition=d.transition):(this.now=0,this.fadeDuration=0,this.zoomHistory=new ac,this.transition={})}isSupportedScript(l){return function(d,y){for(const w of d)if(!Zc(w.charCodeAt(0),y))return!1;return!0}(l,Hl.getRTLTextPluginStatus()==="loaded")}crossFadingFactor(){return this.fadeDuration===0?1:Math.min((this.now-this.zoomHistory.lastIntegerZoomTime)/this.fadeDuration,1)}getCrossfadeParameters(){const l=this.zoom,d=l-Math.floor(l),y=this.crossFadingFactor();return l>this.zoomHistory.lastIntegerZoom?{fromScale:2,toScale:1,t:d+(1-d)*y}:{fromScale:.5,toScale:1,t:1-(1-y)*d}}}class Xc{constructor(l,d){this.property=l,this.value=d,this.expression=function(y,w){if(Ch(y))return new xl(y,w);if(tc(y)){const T=Ou(y,w);if(T.result==="error")throw new Error(T.value.map(K=>`${K.key}: ${K.message}`).join(", "));return T.value}{let T=y;return w.type==="color"&&typeof y=="string"?T=Ai.parse(y):w.type!=="padding"||typeof y!="number"&&!Array.isArray(y)?w.type==="variableAnchorOffsetCollection"&&Array.isArray(y)&&(T=ve.parse(y)):T=Gi.parse(y),{kind:"constant",evaluate:()=>T}}}(d===void 0?l.specification.default:d,l.specification)}isDataDriven(){return this.expression.kind==="source"||this.expression.kind==="composite"}possiblyEvaluate(l,d,y){return this.property.possiblyEvaluate(this,l,d,y)}}class Ef{constructor(l){this.property=l,this.value=new Xc(l,void 0)}transitioned(l,d){return new Oh(this.property,this.value,d,ye({},l.transition,this.transition),l.now)}untransitioned(){return new Oh(this.property,this.value,null,{},0)}}class Of{constructor(l){this._properties=l,this._values=Object.create(l.defaultTransitionablePropertyValues)}getValue(l){return ct(this._values[l].value.value)}setValue(l,d){Object.prototype.hasOwnProperty.call(this._values,l)||(this._values[l]=new Ef(this._values[l].property)),this._values[l].value=new Xc(this._values[l].property,d===null?void 0:ct(d))}getTransition(l){return ct(this._values[l].transition)}setTransition(l,d){Object.prototype.hasOwnProperty.call(this._values,l)||(this._values[l]=new Ef(this._values[l].property)),this._values[l].transition=ct(d)||void 0}serialize(){const l={};for(const d of Object.keys(this._values)){const y=this.getValue(d);y!==void 0&&(l[d]=y);const w=this.getTransition(d);w!==void 0&&(l[`${d}-transition`]=w)}return l}transitioned(l,d){const y=new Bh(this._properties);for(const w of Object.keys(this._values))y._values[w]=this._values[w].transitioned(l,d._values[w]);return y}untransitioned(){const l=new Bh(this._properties);for(const d of Object.keys(this._values))l._values[d]=this._values[d].untransitioned();return l}}class Oh{constructor(l,d,y,w,T){this.property=l,this.value=d,this.begin=T+w.delay||0,this.end=this.begin+w.duration||0,l.specification.transition&&(w.delay||w.duration)&&(this.prior=y)}possiblyEvaluate(l,d,y){const w=l.now||0,T=this.value.possiblyEvaluate(l,d,y),K=this.prior;if(K){if(w>this.end)return this.prior=null,T;if(this.value.isDataDriven())return this.prior=null,T;if(w<this.begin)return K.possiblyEvaluate(l,d,y);{const D=(w-this.begin)/(this.end-this.begin);return this.property.interpolate(K.possiblyEvaluate(l,d,y),T,function(z){if(z<=0)return 0;if(z>=1)return 1;const Q=z*z,ie=Q*z;return 4*(z<.5?ie:3*(z-Q)+ie-.75)}(D))}}return T}}class Bh{constructor(l){this._properties=l,this._values=Object.create(l.defaultTransitioningPropertyValues)}possiblyEvaluate(l,d,y){const w=new uc(this._properties);for(const T of Object.keys(this._values))w._values[T]=this._values[T].possiblyEvaluate(l,d,y);return w}hasTransition(){for(const l of Object.keys(this._values))if(this._values[l].prior)return!0;return!1}}class oa{constructor(l){this._properties=l,this._values=Object.create(l.defaultPropertyValues)}hasValue(l){return this._values[l].value!==void 0}getValue(l){return ct(this._values[l].value)}setValue(l,d){this._values[l]=new Xc(this._values[l].property,d===null?void 0:ct(d))}serialize(){const l={};for(const d of Object.keys(this._values)){const y=this.getValue(d);y!==void 0&&(l[d]=y)}return l}possiblyEvaluate(l,d,y){const w=new uc(this._properties);for(const T of Object.keys(this._values))w._values[T]=this._values[T].possiblyEvaluate(l,d,y);return w}}class Eo{constructor(l,d,y){this.property=l,this.value=d,this.parameters=y}isConstant(){return this.value.kind==="constant"}constantOr(l){return this.value.kind==="constant"?this.value.value:l}evaluate(l,d,y,w){return this.property.evaluate(this.value,this.parameters,l,d,y,w)}}class uc{constructor(l){this._properties=l,this._values=Object.create(l.defaultPossiblyEvaluatedValues)}get(l){return this._values[l]}}class gr{constructor(l){this.specification=l}possiblyEvaluate(l,d){if(l.isDataDriven())throw new Error("Value should not be data driven");return l.expression.evaluate(d)}interpolate(l,d,y){const w=Sr[this.specification.type];return w?w(l,d,y):l}}class Or{constructor(l,d){this.specification=l,this.overrides=d}possiblyEvaluate(l,d,y,w){return new Eo(this,l.expression.kind==="constant"||l.expression.kind==="camera"?{kind:"constant",value:l.expression.evaluate(d,null,{},y,w)}:l.expression,d)}interpolate(l,d,y){if(l.value.kind!=="constant"||d.value.kind!=="constant")return l;if(l.value.value===void 0||d.value.value===void 0)return new Eo(this,{kind:"constant",value:void 0},l.parameters);const w=Sr[this.specification.type];if(w){const T=w(l.value.value,d.value.value,y);return new Eo(this,{kind:"constant",value:T},l.parameters)}return l}evaluate(l,d,y,w,T,K){return l.kind==="constant"?l.value:l.evaluate(d,y,w,T,K)}}class SA extends Or{possiblyEvaluate(l,d,y,w){if(l.value===void 0)return new Eo(this,{kind:"constant",value:void 0},d);if(l.expression.kind==="constant"){const T=l.expression.evaluate(d,null,{},y,w),K=l.property.specification.type==="resolvedImage"&&typeof T!="string"?T.name:T,D=this._calculate(K,K,K,d);return new Eo(this,{kind:"constant",value:D},d)}if(l.expression.kind==="camera"){const T=this._calculate(l.expression.evaluate({zoom:d.zoom-1}),l.expression.evaluate({zoom:d.zoom}),l.expression.evaluate({zoom:d.zoom+1}),d);return new Eo(this,{kind:"constant",value:T},d)}return new Eo(this,l.expression,d)}evaluate(l,d,y,w,T,K){if(l.kind==="source"){const D=l.evaluate(d,y,w,T,K);return this._calculate(D,D,D,d)}return l.kind==="composite"?this._calculate(l.evaluate({zoom:Math.floor(d.zoom)-1},y,w),l.evaluate({zoom:Math.floor(d.zoom)},y,w),l.evaluate({zoom:Math.floor(d.zoom)+1},y,w),d):l.value}_calculate(l,d,y,w){return w.zoom>w.zoomHistory.lastIntegerZoom?{from:l,to:d}:{from:y,to:d}}interpolate(l){return l}}class Jc{constructor(l){this.specification=l}possiblyEvaluate(l,d,y,w){if(l.value!==void 0){if(l.expression.kind==="constant"){const T=l.expression.evaluate(d,null,{},y,w);return this._calculate(T,T,T,d)}return this._calculate(l.expression.evaluate(new go(Math.floor(d.zoom-1),d)),l.expression.evaluate(new go(Math.floor(d.zoom),d)),l.expression.evaluate(new go(Math.floor(d.zoom+1),d)),d)}}_calculate(l,d,y,w){return w.zoom>w.zoomHistory.lastIntegerZoom?{from:l,to:d}:{from:y,to:d}}interpolate(l){return l}}class dl{constructor(l){this.specification=l}possiblyEvaluate(l,d,y,w){return!!l.expression.evaluate(d,null,{},y,w)}interpolate(){return!1}}class xa{constructor(l){this.properties=l,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},this.overridableProperties=[];for(const d in l){const y=l[d];y.specification.overridable&&this.overridableProperties.push(d);const w=this.defaultPropertyValues[d]=new Xc(y,void 0),T=this.defaultTransitionablePropertyValues[d]=new Ef(y);this.defaultTransitioningPropertyValues[d]=T.untransitioned(),this.defaultPossiblyEvaluatedValues[d]=w.possiblyEvaluate({})}}}jn("DataDrivenProperty",Or),jn("DataConstantProperty",gr),jn("CrossFadedDataDrivenProperty",SA),jn("CrossFadedProperty",Jc),jn("ColorRampProperty",dl);const Bl="-transition";class As extends zn{constructor(l,d){if(super(),this.id=l.id,this.type=l.type,this._featureFilter={filter:()=>!0,needGeometry:!1},l.type!=="custom"&&(this.metadata=l.metadata,this.minzoom=l.minzoom,this.maxzoom=l.maxzoom,l.type!=="background"&&(this.source=l.source,this.sourceLayer=l["source-layer"],this.filter=l.filter),d.layout&&(this._unevaluatedLayout=new oa(d.layout)),d.paint)){this._transitionablePaint=new Of(d.paint);for(const y in l.paint)this.setPaintProperty(y,l.paint[y],{validate:!1});for(const y in l.layout)this.setLayoutProperty(y,l.layout[y],{validate:!1});this._transitioningPaint=this._transitionablePaint.untransitioned(),this.paint=new uc(d.paint)}}getCrossfadeParameters(){return this._crossfadeParameters}getLayoutProperty(l){return l==="visibility"?this.visibility:this._unevaluatedLayout.getValue(l)}setLayoutProperty(l,d,y={}){d!=null&&this._validate(ic,`layers.${this.id}.layout.${l}`,l,d,y)||(l!=="visibility"?this._unevaluatedLayout.setValue(l,d):this.visibility=d)}getPaintProperty(l){return l.endsWith(Bl)?this._transitionablePaint.getTransition(l.slice(0,-11)):this._transitionablePaint.getValue(l)}setPaintProperty(l,d,y={}){if(d!=null&&this._validate(Al,`layers.${this.id}.paint.${l}`,l,d,y))return!1;if(l.endsWith(Bl))return this._transitionablePaint.setTransition(l.slice(0,-11),d||void 0),!1;{const w=this._transitionablePaint._values[l],T=w.property.specification["property-type"]==="cross-faded-data-driven",K=w.value.isDataDriven(),D=w.value;this._transitionablePaint.setValue(l,d),this._handleSpecialPaintPropertyUpdate(l);const z=this._transitionablePaint._values[l].value;return z.isDataDriven()||K||T||this._handleOverridablePaintPropertyUpdate(l,D,z)}}_handleSpecialPaintPropertyUpdate(l){}_handleOverridablePaintPropertyUpdate(l,d,y){return!1}isHidden(l){return!!(this.minzoom&&l<this.minzoom)||!!(this.maxzoom&&l>=this.maxzoom)||this.visibility==="none"}updateTransitions(l){this._transitioningPaint=this._transitionablePaint.transitioned(l,this._transitioningPaint)}hasTransition(){return this._transitioningPaint.hasTransition()}recalculate(l,d){l.getCrossfadeParameters&&(this._crossfadeParameters=l.getCrossfadeParameters()),this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(l,void 0,d)),this.paint=this._transitioningPaint.possiblyEvaluate(l,void 0,d)}serialize(){const l={id:this.id,type:this.type,source:this.source,"source-layer":this.sourceLayer,metadata:this.metadata,minzoom:this.minzoom,maxzoom:this.maxzoom,filter:this.filter,layout:this._unevaluatedLayout&&this._unevaluatedLayout.serialize(),paint:this._transitionablePaint&&this._transitionablePaint.serialize()};return this.visibility&&(l.layout=l.layout||{},l.layout.visibility=this.visibility),rt(l,(d,y)=>!(d===void 0||y==="layout"&&!Object.keys(d).length||y==="paint"&&!Object.keys(d).length))}_validate(l,d,y,w,T={}){return(!T||T.validate!==!1)&&us(this,l.call(MA,{key:d,layerType:this.type,objectKey:y,value:w,styleSpec:mt,style:{glyphs:!0,sprite:!0}}))}is3D(){return!1}isTileClipped(){return!1}hasOffscreenPass(){return!1}resize(){}isStateDependent(){for(const l in this.paint._values){const d=this.paint.get(l);if(d instanceof Eo&&$c(d.property.specification)&&(d.value.kind==="source"||d.value.kind==="composite")&&d.value.isStateDependent)return!0}return!1}}const Iu={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array};class iA{constructor(l,d){this._structArray=l,this._pos1=d*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8}}class Oo{constructor(){this.isTransferred=!1,this.capacity=-1,this.resize(0)}static serialize(l,d){return l._trim(),d&&(l.isTransferred=!0,d.push(l.arrayBuffer)),{length:l.length,arrayBuffer:l.arrayBuffer}}static deserialize(l){const d=Object.create(this.prototype);return d.arrayBuffer=l.arrayBuffer,d.length=l.length,d.capacity=l.arrayBuffer.byteLength/d.bytesPerElement,d._refreshViews(),d}_trim(){this.length!==this.capacity&&(this.capacity=this.length,this.arrayBuffer=this.arrayBuffer.slice(0,this.length*this.bytesPerElement),this._refreshViews())}clear(){this.length=0}resize(l){this.reserve(l),this.length=l}reserve(l){if(l>this.capacity){this.capacity=Math.max(l,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);const d=this.uint8;this._refreshViews(),d&&this.uint8.set(d)}}_refreshViews(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")}}function zo(c,l=1){let d=0,y=0;return{members:c.map(w=>{const T=Iu[w.type].BYTES_PER_ELEMENT,K=d=Ip(d,Math.max(l,T)),D=w.components||1;return y=Math.max(y,T),d+=T*D,{name:w.name,type:w.type,components:D,offset:K}}),size:Ip(d,Math.max(y,l)),alignment:l}}function Ip(c,l){return Math.ceil(c/l)*l}class du extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d){const y=this.length;return this.resize(y+1),this.emplace(y,l,d)}emplace(l,d,y){const w=2*l;return this.int16[w+0]=d,this.int16[w+1]=y,l}}du.prototype.bytesPerElement=4,jn("StructArrayLayout2i4",du);class Tu extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d,y){const w=this.length;return this.resize(w+1),this.emplace(w,l,d,y)}emplace(l,d,y,w){const T=3*l;return this.int16[T+0]=d,this.int16[T+1]=y,this.int16[T+2]=w,l}}Tu.prototype.bytesPerElement=6,jn("StructArrayLayout3i6",Tu);class Bf extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d,y,w){const T=this.length;return this.resize(T+1),this.emplace(T,l,d,y,w)}emplace(l,d,y,w,T){const K=4*l;return this.int16[K+0]=d,this.int16[K+1]=y,this.int16[K+2]=w,this.int16[K+3]=T,l}}Bf.prototype.bytesPerElement=8,jn("StructArrayLayout4i8",Bf);class Ac extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K){const D=this.length;return this.resize(D+1),this.emplace(D,l,d,y,w,T,K)}emplace(l,d,y,w,T,K,D){const z=6*l;return this.int16[z+0]=d,this.int16[z+1]=y,this.int16[z+2]=w,this.int16[z+3]=T,this.int16[z+4]=K,this.int16[z+5]=D,l}}Ac.prototype.bytesPerElement=12,jn("StructArrayLayout2i4i12",Ac);class cc extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K){const D=this.length;return this.resize(D+1),this.emplace(D,l,d,y,w,T,K)}emplace(l,d,y,w,T,K,D){const z=4*l,Q=8*l;return this.int16[z+0]=d,this.int16[z+1]=y,this.uint8[Q+4]=w,this.uint8[Q+5]=T,this.uint8[Q+6]=K,this.uint8[Q+7]=D,l}}cc.prototype.bytesPerElement=8,jn("StructArrayLayout2i4ub8",cc);class ed extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d){const y=this.length;return this.resize(y+1),this.emplace(y,l,d)}emplace(l,d,y){const w=2*l;return this.float32[w+0]=d,this.float32[w+1]=y,l}}ed.prototype.bytesPerElement=8,jn("StructArrayLayout2f8",ed);class ke extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K,D,z,Q,ie){const le=this.length;return this.resize(le+1),this.emplace(le,l,d,y,w,T,K,D,z,Q,ie)}emplace(l,d,y,w,T,K,D,z,Q,ie,le){const ge=10*l;return this.uint16[ge+0]=d,this.uint16[ge+1]=y,this.uint16[ge+2]=w,this.uint16[ge+3]=T,this.uint16[ge+4]=K,this.uint16[ge+5]=D,this.uint16[ge+6]=z,this.uint16[ge+7]=Q,this.uint16[ge+8]=ie,this.uint16[ge+9]=le,l}}ke.prototype.bytesPerElement=20,jn("StructArrayLayout10ui20",ke);class oA extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K,D,z,Q,ie,le,ge){const Oe=this.length;return this.resize(Oe+1),this.emplace(Oe,l,d,y,w,T,K,D,z,Q,ie,le,ge)}emplace(l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe){const Be=12*l;return this.int16[Be+0]=d,this.int16[Be+1]=y,this.int16[Be+2]=w,this.int16[Be+3]=T,this.uint16[Be+4]=K,this.uint16[Be+5]=D,this.uint16[Be+6]=z,this.uint16[Be+7]=Q,this.int16[Be+8]=ie,this.int16[Be+9]=le,this.int16[Be+10]=ge,this.int16[Be+11]=Oe,l}}oA.prototype.bytesPerElement=24,jn("StructArrayLayout4i4ui4i24",oA);class wa extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d,y){const w=this.length;return this.resize(w+1),this.emplace(w,l,d,y)}emplace(l,d,y,w){const T=3*l;return this.float32[T+0]=d,this.float32[T+1]=y,this.float32[T+2]=w,l}}wa.prototype.bytesPerElement=12,jn("StructArrayLayout3f12",wa);class uo extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(l){const d=this.length;return this.resize(d+1),this.emplace(d,l)}emplace(l,d){return this.uint32[1*l+0]=d,l}}uo.prototype.bytesPerElement=4,jn("StructArrayLayout1ul4",uo);class jr extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K,D,z,Q){const ie=this.length;return this.resize(ie+1),this.emplace(ie,l,d,y,w,T,K,D,z,Q)}emplace(l,d,y,w,T,K,D,z,Q,ie){const le=10*l,ge=5*l;return this.int16[le+0]=d,this.int16[le+1]=y,this.int16[le+2]=w,this.int16[le+3]=T,this.int16[le+4]=K,this.int16[le+5]=D,this.uint32[ge+3]=z,this.uint16[le+8]=Q,this.uint16[le+9]=ie,l}}jr.prototype.bytesPerElement=20,jn("StructArrayLayout6i1ul2ui20",jr);class Ma extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K){const D=this.length;return this.resize(D+1),this.emplace(D,l,d,y,w,T,K)}emplace(l,d,y,w,T,K,D){const z=6*l;return this.int16[z+0]=d,this.int16[z+1]=y,this.int16[z+2]=w,this.int16[z+3]=T,this.int16[z+4]=K,this.int16[z+5]=D,l}}Ma.prototype.bytesPerElement=12,jn("StructArrayLayout2i2i2i12",Ma);class Ku extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T){const K=this.length;return this.resize(K+1),this.emplace(K,l,d,y,w,T)}emplace(l,d,y,w,T,K){const D=4*l,z=8*l;return this.float32[D+0]=d,this.float32[D+1]=y,this.float32[D+2]=w,this.int16[z+6]=T,this.int16[z+7]=K,l}}Ku.prototype.bytesPerElement=16,jn("StructArrayLayout2f1f2i16",Ku);class dc extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d,y,w){const T=this.length;return this.resize(T+1),this.emplace(T,l,d,y,w)}emplace(l,d,y,w,T){const K=12*l,D=3*l;return this.uint8[K+0]=d,this.uint8[K+1]=y,this.float32[D+1]=w,this.float32[D+2]=T,l}}dc.prototype.bytesPerElement=12,jn("StructArrayLayout2ub2f12",dc);class kl extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d,y){const w=this.length;return this.resize(w+1),this.emplace(w,l,d,y)}emplace(l,d,y,w){const T=3*l;return this.uint16[T+0]=d,this.uint16[T+1]=y,this.uint16[T+2]=w,l}}kl.prototype.bytesPerElement=6,jn("StructArrayLayout3ui6",kl);class kh extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt){const St=this.length;return this.resize(St+1),this.emplace(St,l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt)}emplace(l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt,St){const lt=24*l,vt=12*l,tn=48*l;return this.int16[lt+0]=d,this.int16[lt+1]=y,this.uint16[lt+2]=w,this.uint16[lt+3]=T,this.uint32[vt+2]=K,this.uint32[vt+3]=D,this.uint32[vt+4]=z,this.uint16[lt+10]=Q,this.uint16[lt+11]=ie,this.uint16[lt+12]=le,this.float32[vt+7]=ge,this.float32[vt+8]=Oe,this.uint8[tn+36]=Be,this.uint8[tn+37]=ze,this.uint8[tn+38]=$e,this.uint32[vt+10]=tt,this.int16[lt+22]=St,l}}kh.prototype.bytesPerElement=48,jn("StructArrayLayout2i2ui3ul3ui2f3ub1ul1i48",kh);class hc extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt,St,lt,vt,tn,an,Vn,cr,xn,Cn,Kn,ur){const Dn=this.length;return this.resize(Dn+1),this.emplace(Dn,l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt,St,lt,vt,tn,an,Vn,cr,xn,Cn,Kn,ur)}emplace(l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze,$e,tt,St,lt,vt,tn,an,Vn,cr,xn,Cn,Kn,ur,Dn){const wn=32*l,Kr=16*l;return this.int16[wn+0]=d,this.int16[wn+1]=y,this.int16[wn+2]=w,this.int16[wn+3]=T,this.int16[wn+4]=K,this.int16[wn+5]=D,this.int16[wn+6]=z,this.int16[wn+7]=Q,this.uint16[wn+8]=ie,this.uint16[wn+9]=le,this.uint16[wn+10]=ge,this.uint16[wn+11]=Oe,this.uint16[wn+12]=Be,this.uint16[wn+13]=ze,this.uint16[wn+14]=$e,this.uint16[wn+15]=tt,this.uint16[wn+16]=St,this.uint16[wn+17]=lt,this.uint16[wn+18]=vt,this.uint16[wn+19]=tn,this.uint16[wn+20]=an,this.uint16[wn+21]=Vn,this.uint16[wn+22]=cr,this.uint32[Kr+12]=xn,this.float32[Kr+13]=Cn,this.float32[Kr+14]=Kn,this.uint16[wn+30]=ur,this.uint16[wn+31]=Dn,l}}hc.prototype.bytesPerElement=64,jn("StructArrayLayout8i15ui1ul2f2ui64",hc);class Ih extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l){const d=this.length;return this.resize(d+1),this.emplace(d,l)}emplace(l,d){return this.float32[1*l+0]=d,l}}Ih.prototype.bytesPerElement=4,jn("StructArrayLayout1f4",Ih);class Ld extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d,y){const w=this.length;return this.resize(w+1),this.emplace(w,l,d,y)}emplace(l,d,y,w){const T=3*l;return this.uint16[6*l+0]=d,this.float32[T+1]=y,this.float32[T+2]=w,l}}Ld.prototype.bytesPerElement=12,jn("StructArrayLayout1ui2f12",Ld);class zd extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d,y){const w=this.length;return this.resize(w+1),this.emplace(w,l,d,y)}emplace(l,d,y,w){const T=4*l;return this.uint32[2*l+0]=d,this.uint16[T+2]=y,this.uint16[T+3]=w,l}}zd.prototype.bytesPerElement=8,jn("StructArrayLayout1ul2ui8",zd);class Il extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l,d){const y=this.length;return this.resize(y+1),this.emplace(y,l,d)}emplace(l,d,y){const w=2*l;return this.uint16[w+0]=d,this.uint16[w+1]=y,l}}Il.prototype.bytesPerElement=4,jn("StructArrayLayout2ui4",Il);class kf extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(l){const d=this.length;return this.resize(d+1),this.emplace(d,l)}emplace(l,d){return this.uint16[1*l+0]=d,l}}kf.prototype.bytesPerElement=2,jn("StructArrayLayout1ui2",kf);class Pi extends Oo{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(l,d,y,w){const T=this.length;return this.resize(T+1),this.emplace(T,l,d,y,w)}emplace(l,d,y,w,T){const K=4*l;return this.float32[K+0]=d,this.float32[K+1]=y,this.float32[K+2]=w,this.float32[K+3]=T,l}}Pi.prototype.bytesPerElement=16,jn("StructArrayLayout4f16",Pi);class O extends iA{get anchorPointX(){return this._structArray.int16[this._pos2+0]}get anchorPointY(){return this._structArray.int16[this._pos2+1]}get x1(){return this._structArray.int16[this._pos2+2]}get y1(){return this._structArray.int16[this._pos2+3]}get x2(){return this._structArray.int16[this._pos2+4]}get y2(){return this._structArray.int16[this._pos2+5]}get featureIndex(){return this._structArray.uint32[this._pos4+3]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+8]}get bucketIndex(){return this._structArray.uint16[this._pos2+9]}get anchorPoint(){return new B(this.anchorPointX,this.anchorPointY)}}O.prototype.size=20;class u extends jr{get(l){return new O(this,l)}}jn("CollisionBoxArray",u);class p extends iA{get anchorX(){return this._structArray.int16[this._pos2+0]}get anchorY(){return this._structArray.int16[this._pos2+1]}get glyphStartIndex(){return this._structArray.uint16[this._pos2+2]}get numGlyphs(){return this._structArray.uint16[this._pos2+3]}get vertexStartIndex(){return this._structArray.uint32[this._pos4+2]}get lineStartIndex(){return this._structArray.uint32[this._pos4+3]}get lineLength(){return this._structArray.uint32[this._pos4+4]}get segment(){return this._structArray.uint16[this._pos2+10]}get lowerSize(){return this._structArray.uint16[this._pos2+11]}get upperSize(){return this._structArray.uint16[this._pos2+12]}get lineOffsetX(){return this._structArray.float32[this._pos4+7]}get lineOffsetY(){return this._structArray.float32[this._pos4+8]}get writingMode(){return this._structArray.uint8[this._pos1+36]}get placedOrientation(){return this._structArray.uint8[this._pos1+37]}set placedOrientation(l){this._structArray.uint8[this._pos1+37]=l}get hidden(){return this._structArray.uint8[this._pos1+38]}set hidden(l){this._structArray.uint8[this._pos1+38]=l}get crossTileID(){return this._structArray.uint32[this._pos4+10]}set crossTileID(l){this._structArray.uint32[this._pos4+10]=l}get associatedIconIndex(){return this._structArray.int16[this._pos2+22]}}p.prototype.size=48;class C extends kh{get(l){return new p(this,l)}}jn("PlacedSymbolArray",C);class M extends iA{get anchorX(){return this._structArray.int16[this._pos2+0]}get anchorY(){return this._structArray.int16[this._pos2+1]}get rightJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+2]}get centerJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+3]}get leftJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+4]}get verticalPlacedTextSymbolIndex(){return this._structArray.int16[this._pos2+5]}get placedIconSymbolIndex(){return this._structArray.int16[this._pos2+6]}get verticalPlacedIconSymbolIndex(){return this._structArray.int16[this._pos2+7]}get key(){return this._structArray.uint16[this._pos2+8]}get textBoxStartIndex(){return this._structArray.uint16[this._pos2+9]}get textBoxEndIndex(){return this._structArray.uint16[this._pos2+10]}get verticalTextBoxStartIndex(){return this._structArray.uint16[this._pos2+11]}get verticalTextBoxEndIndex(){return this._structArray.uint16[this._pos2+12]}get iconBoxStartIndex(){return this._structArray.uint16[this._pos2+13]}get iconBoxEndIndex(){return this._structArray.uint16[this._pos2+14]}get verticalIconBoxStartIndex(){return this._structArray.uint16[this._pos2+15]}get verticalIconBoxEndIndex(){return this._structArray.uint16[this._pos2+16]}get featureIndex(){return this._structArray.uint16[this._pos2+17]}get numHorizontalGlyphVertices(){return this._structArray.uint16[this._pos2+18]}get numVerticalGlyphVertices(){return this._structArray.uint16[this._pos2+19]}get numIconVertices(){return this._structArray.uint16[this._pos2+20]}get numVerticalIconVertices(){return this._structArray.uint16[this._pos2+21]}get useRuntimeCollisionCircles(){return this._structArray.uint16[this._pos2+22]}get crossTileID(){return this._structArray.uint32[this._pos4+12]}set crossTileID(l){this._structArray.uint32[this._pos4+12]=l}get textBoxScale(){return this._structArray.float32[this._pos4+13]}get collisionCircleDiameter(){return this._structArray.float32[this._pos4+14]}get textAnchorOffsetStartIndex(){return this._structArray.uint16[this._pos2+30]}get textAnchorOffsetEndIndex(){return this._structArray.uint16[this._pos2+31]}}M.prototype.size=64;class I extends hc{get(l){return new M(this,l)}}jn("SymbolInstanceArray",I);class L extends Ih{getoffsetX(l){return this.float32[1*l+0]}}jn("GlyphOffsetArray",L);class j extends Tu{getx(l){return this.int16[3*l+0]}gety(l){return this.int16[3*l+1]}gettileUnitDistanceFromAnchor(l){return this.int16[3*l+2]}}jn("SymbolLineVertexArray",j);class G extends iA{get textAnchor(){return this._structArray.uint16[this._pos2+0]}get textOffset0(){return this._structArray.float32[this._pos4+1]}get textOffset1(){return this._structArray.float32[this._pos4+2]}}G.prototype.size=12;class te extends Ld{get(l){return new G(this,l)}}jn("TextAnchorOffsetArray",te);class Ae extends iA{get featureIndex(){return this._structArray.uint32[this._pos4+0]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+2]}get bucketIndex(){return this._structArray.uint16[this._pos2+3]}}Ae.prototype.size=8;class he extends zd{get(l){return new Ae(this,l)}}jn("FeatureIndexArray",he);class Me extends du{}class De extends du{}class je extends du{}class Qe extends Ac{}class Le extends cc{}class ft extends ed{}class Bt extends ke{}class qe extends oA{}class _t extends wa{}class Ut extends uo{}class Tt extends Ma{}class en extends dc{}class hn extends kl{}class An extends Il{}const On=zo([{name:"a_pos",components:2,type:"Int16"}],4),{members:lr}=On;class xr{constructor(l=[]){this.segments=l}prepareSegment(l,d,y,w){let T=this.segments[this.segments.length-1];return l>xr.MAX_VERTEX_ARRAY_LENGTH&&He(`Max vertices per segment is ${xr.MAX_VERTEX_ARRAY_LENGTH}: bucket requested ${l}`),(!T||T.vertexLength+l>xr.MAX_VERTEX_ARRAY_LENGTH||T.sortKey!==w)&&(T={vertexOffset:d.length,primitiveOffset:y.length,vertexLength:0,primitiveLength:0},w!==void 0&&(T.sortKey=w),this.segments.push(T)),T}get(){return this.segments}destroy(){for(const l of this.segments)for(const d in l.vaos)l.vaos[d].destroy()}static simpleSegment(l,d,y,w){return new xr([{vertexOffset:l,primitiveOffset:d,vertexLength:y,primitiveLength:w,vaos:{},sortKey:0}])}}function Tn(c,l){return 256*(c=ae(Math.floor(c),0,255))+ae(Math.floor(l),0,255)}xr.MAX_VERTEX_ARRAY_LENGTH=Math.pow(2,16)-1,jn("SegmentVector",xr);const yr=zo([{name:"a_pattern_from",components:4,type:"Uint16"},{name:"a_pattern_to",components:4,type:"Uint16"},{name:"a_pixel_ratio_from",components:1,type:"Uint16"},{name:"a_pixel_ratio_to",components:1,type:"Uint16"}]);var Qn={exports:{}},Ho={exports:{}};Ho.exports=function(c,l){var d,y,w,T,K,D,z,Q;for(y=c.length-(d=3&c.length),w=l,K=3432918353,D=461845907,Q=0;Q<y;)z=255&c.charCodeAt(Q)|(255&c.charCodeAt(++Q))<<8|(255&c.charCodeAt(++Q))<<16|(255&c.charCodeAt(++Q))<<24,++Q,w=27492+(65535&(T=5*(65535&(w=(w^=z=(65535&(z=(z=(65535&z)*K+(((z>>>16)*K&65535)<<16)&4294967295)<<15|z>>>17))*D+(((z>>>16)*D&65535)<<16)&4294967295)<<13|w>>>19))+((5*(w>>>16)&65535)<<16)&4294967295))+((58964+(T>>>16)&65535)<<16);switch(z=0,d){case 3:z^=(255&c.charCodeAt(Q+2))<<16;case 2:z^=(255&c.charCodeAt(Q+1))<<8;case 1:w^=z=(65535&(z=(z=(65535&(z^=255&c.charCodeAt(Q)))*K+(((z>>>16)*K&65535)<<16)&4294967295)<<15|z>>>17))*D+(((z>>>16)*D&65535)<<16)&4294967295}return w^=c.length,w=2246822507*(65535&(w^=w>>>16))+((2246822507*(w>>>16)&65535)<<16)&4294967295,w=3266489909*(65535&(w^=w>>>13))+((3266489909*(w>>>16)&65535)<<16)&4294967295,(w^=w>>>16)>>>0};var pi=Ho.exports,ii={exports:{}};ii.exports=function(c,l){for(var d,y=c.length,w=l^y,T=0;y>=4;)d=1540483477*(65535&(d=255&c.charCodeAt(T)|(255&c.charCodeAt(++T))<<8|(255&c.charCodeAt(++T))<<16|(255&c.charCodeAt(++T))<<24))+((1540483477*(d>>>16)&65535)<<16),w=1540483477*(65535&w)+((1540483477*(w>>>16)&65535)<<16)^(d=1540483477*(65535&(d^=d>>>24))+((1540483477*(d>>>16)&65535)<<16)),y-=4,++T;switch(y){case 3:w^=(255&c.charCodeAt(T+2))<<16;case 2:w^=(255&c.charCodeAt(T+1))<<8;case 1:w=1540483477*(65535&(w^=255&c.charCodeAt(T)))+((1540483477*(w>>>16)&65535)<<16)}return w=1540483477*(65535&(w^=w>>>13))+((1540483477*(w>>>16)&65535)<<16),(w^=w>>>15)>>>0};var si=pi,yo=ii.exports;Qn.exports=si,Qn.exports.murmur3=si,Qn.exports.murmur2=yo;var vo=g(Qn.exports);class Zs{constructor(){this.ids=[],this.positions=[],this.indexed=!1}add(l,d,y,w){this.ids.push(Sa(l)),this.positions.push(d,y,w)}getPositions(l){if(!this.indexed)throw new Error("Trying to get index, but feature positions are not indexed");const d=Sa(l);let y=0,w=this.ids.length-1;for(;y<w;){const K=y+w>>1;this.ids[K]>=d?w=K:y=K+1}const T=[];for(;this.ids[y]===d;)T.push({index:this.positions[3*y],start:this.positions[3*y+1],end:this.positions[3*y+2]}),y++;return T}static serialize(l,d){const y=new Float64Array(l.ids),w=new Uint32Array(l.positions);return aa(y,w,0,y.length-1),d&&d.push(y.buffer,w.buffer),{ids:y,positions:w}}static deserialize(l){const d=new Zs;return d.ids=l.ids,d.positions=l.positions,d.indexed=!0,d}}function Sa(c){const l=+c;return!isNaN(l)&&l<=Number.MAX_SAFE_INTEGER?l:vo(String(c))}function aa(c,l,d,y){for(;d<y;){const w=c[d+y>>1];let T=d-1,K=y+1;for(;;){do T++;while(c[T]<w);do K--;while(c[K]>w);if(T>=K)break;_a(c,T,K),_a(l,3*T,3*K),_a(l,3*T+1,3*K+1),_a(l,3*T+2,3*K+2)}K-d<y-K?(aa(c,l,d,K),d=K+1):(aa(c,l,K+1,y),y=K)}}function _a(c,l,d){const y=c[l];c[l]=c[d],c[d]=y}jn("FeaturePositionMap",Zs);class no{constructor(l,d){this.gl=l.gl,this.location=d}}class ws extends no{constructor(l,d){super(l,d),this.current=0}set(l){this.current!==l&&(this.current=l,this.gl.uniform1f(this.location,l))}}class Pu extends no{constructor(l,d){super(l,d),this.current=[0,0,0,0]}set(l){l[0]===this.current[0]&&l[1]===this.current[1]&&l[2]===this.current[2]&&l[3]===this.current[3]||(this.current=l,this.gl.uniform4f(this.location,l[0],l[1],l[2],l[3]))}}class Ms extends no{constructor(l,d){super(l,d),this.current=Ai.transparent}set(l){l.r===this.current.r&&l.g===this.current.g&&l.b===this.current.b&&l.a===this.current.a||(this.current=l,this.gl.uniform4f(this.location,l.r,l.g,l.b,l.a))}}const aA=new Float32Array(16);function hu(c){return[Tn(255*c.r,255*c.g),Tn(255*c.b,255*c.a)]}class Zo{constructor(l,d,y){this.value=l,this.uniformNames=d.map(w=>`u_${w}`),this.type=y}setUniform(l,d,y){l.set(y.constantOr(this.value))}getBinding(l,d,y){return this.type==="color"?new Ms(l,d):new ws(l,d)}}class ji{constructor(l,d){this.uniformNames=d.map(y=>`u_${y}`),this.patternFrom=null,this.patternTo=null,this.pixelRatioFrom=1,this.pixelRatioTo=1}setConstantPatternPositions(l,d){this.pixelRatioFrom=d.pixelRatio,this.pixelRatioTo=l.pixelRatio,this.patternFrom=d.tlbr,this.patternTo=l.tlbr}setUniform(l,d,y,w){const T=w==="u_pattern_to"?this.patternTo:w==="u_pattern_from"?this.patternFrom:w==="u_pixel_ratio_to"?this.pixelRatioTo:w==="u_pixel_ratio_from"?this.pixelRatioFrom:null;T&&l.set(T)}getBinding(l,d,y){return y.substr(0,9)==="u_pattern"?new Pu(l,d):new ws(l,d)}}class Oi{constructor(l,d,y,w){this.expression=l,this.type=y,this.maxValue=0,this.paintVertexAttributes=d.map(T=>({name:`a_${T}`,type:"Float32",components:y==="color"?2:1,offset:0})),this.paintVertexArray=new w}populatePaintArray(l,d,y,w,T){const K=this.paintVertexArray.length,D=this.expression.evaluate(new go(0),d,{},w,[],T);this.paintVertexArray.resize(l),this._setPaintValue(K,l,D)}updatePaintArray(l,d,y,w){const T=this.expression.evaluate({zoom:0},y,w);this._setPaintValue(l,d,T)}_setPaintValue(l,d,y){if(this.type==="color"){const w=hu(y);for(let T=l;T<d;T++)this.paintVertexArray.emplace(T,w[0],w[1])}else{for(let w=l;w<d;w++)this.paintVertexArray.emplace(w,y);this.maxValue=Math.max(this.maxValue,Math.abs(y))}}upload(l){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=l.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}}class cs{constructor(l,d,y,w,T,K){this.expression=l,this.uniformNames=d.map(D=>`u_${D}_t`),this.type=y,this.useIntegerZoom=w,this.zoom=T,this.maxValue=0,this.paintVertexAttributes=d.map(D=>({name:`a_${D}`,type:"Float32",components:y==="color"?4:2,offset:0})),this.paintVertexArray=new K}populatePaintArray(l,d,y,w,T){const K=this.expression.evaluate(new go(this.zoom),d,{},w,[],T),D=this.expression.evaluate(new go(this.zoom+1),d,{},w,[],T),z=this.paintVertexArray.length;this.paintVertexArray.resize(l),this._setPaintValue(z,l,K,D)}updatePaintArray(l,d,y,w){const T=this.expression.evaluate({zoom:this.zoom},y,w),K=this.expression.evaluate({zoom:this.zoom+1},y,w);this._setPaintValue(l,d,T,K)}_setPaintValue(l,d,y,w){if(this.type==="color"){const T=hu(y),K=hu(w);for(let D=l;D<d;D++)this.paintVertexArray.emplace(D,T[0],T[1],K[0],K[1])}else{for(let T=l;T<d;T++)this.paintVertexArray.emplace(T,y,w);this.maxValue=Math.max(this.maxValue,Math.abs(y),Math.abs(w))}}upload(l){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=l.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}setUniform(l,d){const y=this.useIntegerZoom?Math.floor(d.zoom):d.zoom,w=ae(this.expression.interpolationFactor(y,this.zoom,this.zoom+1),0,1);l.set(w)}getBinding(l,d,y){return new ws(l,d)}}class jo{constructor(l,d,y,w,T,K){this.expression=l,this.type=d,this.useIntegerZoom=y,this.zoom=w,this.layerId=K,this.zoomInPaintVertexArray=new T,this.zoomOutPaintVertexArray=new T}populatePaintArray(l,d,y){const w=this.zoomInPaintVertexArray.length;this.zoomInPaintVertexArray.resize(l),this.zoomOutPaintVertexArray.resize(l),this._setPaintValues(w,l,d.patterns&&d.patterns[this.layerId],y)}updatePaintArray(l,d,y,w,T){this._setPaintValues(l,d,y.patterns&&y.patterns[this.layerId],T)}_setPaintValues(l,d,y,w){if(!w||!y)return;const{min:T,mid:K,max:D}=y,z=w[T],Q=w[K],ie=w[D];if(z&&Q&&ie)for(let le=l;le<d;le++)this.zoomInPaintVertexArray.emplace(le,Q.tl[0],Q.tl[1],Q.br[0],Q.br[1],z.tl[0],z.tl[1],z.br[0],z.br[1],Q.pixelRatio,z.pixelRatio),this.zoomOutPaintVertexArray.emplace(le,Q.tl[0],Q.tl[1],Q.br[0],Q.br[1],ie.tl[0],ie.tl[1],ie.br[0],ie.br[1],Q.pixelRatio,ie.pixelRatio)}upload(l){this.zoomInPaintVertexArray&&this.zoomInPaintVertexArray.arrayBuffer&&this.zoomOutPaintVertexArray&&this.zoomOutPaintVertexArray.arrayBuffer&&(this.zoomInPaintVertexBuffer=l.createVertexBuffer(this.zoomInPaintVertexArray,yr.members,this.expression.isStateDependent),this.zoomOutPaintVertexBuffer=l.createVertexBuffer(this.zoomOutPaintVertexArray,yr.members,this.expression.isStateDependent))}destroy(){this.zoomOutPaintVertexBuffer&&this.zoomOutPaintVertexBuffer.destroy(),this.zoomInPaintVertexBuffer&&this.zoomInPaintVertexBuffer.destroy()}}class Da{constructor(l,d,y){this.binders={},this._buffers=[];const w=[];for(const T in l.paint._values){if(!y(T))continue;const K=l.paint.get(T);if(!(K instanceof Eo&&$c(K.property.specification)))continue;const D=sa(T,l.type),z=K.value,Q=K.property.specification.type,ie=K.property.useIntegerZoom,le=K.property.specification["property-type"],ge=le==="cross-faded"||le==="cross-faded-data-driven";if(z.kind==="constant")this.binders[T]=ge?new ji(z.value,D):new Zo(z.value,D,Q),w.push(`/u_${T}`);else if(z.kind==="source"||ge){const Oe=If(T,Q,"source");this.binders[T]=ge?new jo(z,Q,ie,d,Oe,l.id):new Oi(z,D,Q,Oe),w.push(`/a_${T}`)}else{const Oe=If(T,Q,"composite");this.binders[T]=new cs(z,D,Q,ie,d,Oe),w.push(`/z_${T}`)}}this.cacheKey=w.sort().join("")}getMaxValue(l){const d=this.binders[l];return d instanceof Oi||d instanceof cs?d.maxValue:0}populatePaintArrays(l,d,y,w,T){for(const K in this.binders){const D=this.binders[K];(D instanceof Oi||D instanceof cs||D instanceof jo)&&D.populatePaintArray(l,d,y,w,T)}}setConstantPatternPositions(l,d){for(const y in this.binders){const w=this.binders[y];w instanceof ji&&w.setConstantPatternPositions(l,d)}}updatePaintArrays(l,d,y,w,T){let K=!1;for(const D in l){const z=d.getPositions(D);for(const Q of z){const ie=y.feature(Q.index);for(const le in this.binders){const ge=this.binders[le];if((ge instanceof Oi||ge instanceof cs||ge instanceof jo)&&ge.expression.isStateDependent===!0){const Oe=w.paint.get(le);ge.expression=Oe.value,ge.updatePaintArray(Q.start,Q.end,ie,l[D],T),K=!0}}}}return K}defines(){const l=[];for(const d in this.binders){const y=this.binders[d];(y instanceof Zo||y instanceof ji)&&l.push(...y.uniformNames.map(w=>`#define HAS_UNIFORM_${w}`))}return l}getBinderAttributes(){const l=[];for(const d in this.binders){const y=this.binders[d];if(y instanceof Oi||y instanceof cs)for(let w=0;w<y.paintVertexAttributes.length;w++)l.push(y.paintVertexAttributes[w].name);else if(y instanceof jo)for(let w=0;w<yr.members.length;w++)l.push(yr.members[w].name)}return l}getBinderUniforms(){const l=[];for(const d in this.binders){const y=this.binders[d];if(y instanceof Zo||y instanceof ji||y instanceof cs)for(const w of y.uniformNames)l.push(w)}return l}getPaintVertexBuffers(){return this._buffers}getUniforms(l,d){const y=[];for(const w in this.binders){const T=this.binders[w];if(T instanceof Zo||T instanceof ji||T instanceof cs){for(const K of T.uniformNames)if(d[K]){const D=T.getBinding(l,d[K],K);y.push({name:K,property:w,binding:D})}}}return y}setUniforms(l,d,y,w){for(const{name:T,property:K,binding:D}of d)this.binders[K].setUniform(D,w,y.get(K),T)}updatePaintBuffers(l){this._buffers=[];for(const d in this.binders){const y=this.binders[d];if(l&&y instanceof jo){const w=l.fromScale===2?y.zoomInPaintVertexBuffer:y.zoomOutPaintVertexBuffer;w&&this._buffers.push(w)}else(y instanceof Oi||y instanceof cs)&&y.paintVertexBuffer&&this._buffers.push(y.paintVertexBuffer)}}upload(l){for(const d in this.binders){const y=this.binders[d];(y instanceof Oi||y instanceof cs||y instanceof jo)&&y.upload(l)}this.updatePaintBuffers()}destroy(){for(const l in this.binders){const d=this.binders[l];(d instanceof Oi||d instanceof cs||d instanceof jo)&&d.destroy()}}}class ua{constructor(l,d,y=()=>!0){this.programConfigurations={};for(const w of l)this.programConfigurations[w.id]=new Da(w,d,y);this.needsUpload=!1,this._featureMap=new Zs,this._bufferOffset=0}populatePaintArrays(l,d,y,w,T,K){for(const D in this.programConfigurations)this.programConfigurations[D].populatePaintArrays(l,d,w,T,K);d.id!==void 0&&this._featureMap.add(d.id,y,this._bufferOffset,l),this._bufferOffset=l,this.needsUpload=!0}updatePaintArrays(l,d,y,w){for(const T of y)this.needsUpload=this.programConfigurations[T.id].updatePaintArrays(l,this._featureMap,d,T,w)||this.needsUpload}get(l){return this.programConfigurations[l]}upload(l){if(this.needsUpload){for(const d in this.programConfigurations)this.programConfigurations[d].upload(l);this.needsUpload=!1}}destroy(){for(const l in this.programConfigurations)this.programConfigurations[l].destroy()}}function sa(c,l){return{"text-opacity":["opacity"],"icon-opacity":["opacity"],"text-color":["fill_color"],"icon-color":["fill_color"],"text-halo-color":["halo_color"],"icon-halo-color":["halo_color"],"text-halo-blur":["halo_blur"],"icon-halo-blur":["halo_blur"],"text-halo-width":["halo_width"],"icon-halo-width":["halo_width"],"line-gap-width":["gapwidth"],"line-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-extrusion-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"]}[c]||[c.replace(`${l}-`,"").replace(/-/g,"_")]}function If(c,l,d){const y={color:{source:ed,composite:Pi},number:{source:Ih,composite:ed}},w=function(T){return{"line-pattern":{source:Bt,composite:Bt},"fill-pattern":{source:Bt,composite:Bt},"fill-extrusion-pattern":{source:Bt,composite:Bt}}[T]}(c);return w&&w[d]||y[l][d]}jn("ConstantBinder",Zo),jn("CrossFadedConstantBinder",ji),jn("SourceExpressionBinder",Oi),jn("CrossFadedCompositeBinder",jo),jn("CompositeExpressionBinder",cs),jn("ProgramConfiguration",Da,{omit:["_buffers"]}),jn("ProgramConfigurationSet",ua);const Wo=8192,jd=Math.pow(2,14)-1,fc=-jd-1;function EA(c){const l=Wo/c.extent,d=c.loadGeometry();for(let y=0;y<d.length;y++){const w=d[y];for(let T=0;T<w.length;T++){const K=w[T],D=Math.round(K.x*l),z=Math.round(K.y*l);K.x=ae(D,fc,jd),K.y=ae(z,fc,jd),(D<K.x||D>K.x+1||z<K.y||z>K.y+1)&&He("Geometry exceeds allowed extent, reduce your vector tile buffer size")}}return d}function hl(c,l){return{type:c.type,id:c.id,properties:c.properties,geometry:l?EA(c):[]}}function Fu(c,l,d,y,w){c.emplaceBack(2*l+(y+1)/2,2*d+(w+1)/2)}class OA{constructor(l){this.zoom=l.zoom,this.overscaling=l.overscaling,this.layers=l.layers,this.layerIds=this.layers.map(d=>d.id),this.index=l.index,this.hasPattern=!1,this.layoutVertexArray=new De,this.indexArray=new hn,this.segments=new xr,this.programConfigurations=new ua(l.layers,l.zoom),this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){const w=this.layers[0],T=[];let K=null,D=!1;w.type==="circle"&&(K=w.layout.get("circle-sort-key"),D=!K.isConstant());for(const{feature:z,id:Q,index:ie,sourceLayerIndex:le}of l){const ge=this.layers[0]._featureFilter.needGeometry,Oe=hl(z,ge);if(!this.layers[0]._featureFilter.filter(new go(this.zoom),Oe,y))continue;const Be=D?K.evaluate(Oe,{},y):void 0,ze={id:Q,properties:z.properties,type:z.type,sourceLayerIndex:le,index:ie,geometry:ge?Oe.geometry:EA(z),patterns:{},sortKey:Be};T.push(ze)}D&&T.sort((z,Q)=>z.sortKey-Q.sortKey);for(const z of T){const{geometry:Q,index:ie,sourceLayerIndex:le}=z,ge=l[ie].feature;this.addFeature(z,Q,ie,y),d.featureIndex.insert(ge,Q,ie,le,this.index)}}update(l,d,y){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(l,d,this.stateDependentLayers,y)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(l){this.uploaded||(this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,lr),this.indexBuffer=l.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(l),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}addFeature(l,d,y,w){for(const T of d)for(const K of T){const D=K.x,z=K.y;if(D<0||D>=Wo||z<0||z>=Wo)continue;const Q=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray,l.sortKey),ie=Q.vertexLength;Fu(this.layoutVertexArray,D,z,-1,-1),Fu(this.layoutVertexArray,D,z,1,-1),Fu(this.layoutVertexArray,D,z,1,1),Fu(this.layoutVertexArray,D,z,-1,1),this.indexArray.emplaceBack(ie,ie+1,ie+2),this.indexArray.emplaceBack(ie,ie+3,ie+2),Q.vertexLength+=4,Q.primitiveLength+=2}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,l,y,{},w)}}function Wd(c,l){for(let d=0;d<c.length;d++)if(rd(l,c[d]))return!0;for(let d=0;d<l.length;d++)if(rd(c,l[d]))return!0;return!!td(c,l)}function BA(c,l,d){return!!rd(c,l)||!!pc(l,c,d)}function Nd(c,l){if(c.length===1)return nd(l,c[0]);for(let d=0;d<l.length;d++){const y=l[d];for(let w=0;w<y.length;w++)if(rd(c,y[w]))return!0}for(let d=0;d<c.length;d++)if(nd(l,c[d]))return!0;for(let d=0;d<l.length;d++)if(td(c,l[d]))return!0;return!1}function Tf(c,l,d){if(c.length>1){if(td(c,l))return!0;for(let y=0;y<l.length;y++)if(pc(l[y],c,d))return!0}for(let y=0;y<c.length;y++)if(pc(c[y],l,d))return!0;return!1}function td(c,l){if(c.length===0||l.length===0)return!1;for(let d=0;d<c.length-1;d++){const y=c[d],w=c[d+1];for(let T=0;T<l.length-1;T++)if(Th(y,w,l[T],l[T+1]))return!0}return!1}function Th(c,l,d,y){return Ce(c,d,y)!==Ce(l,d,y)&&Ce(c,l,d)!==Ce(c,l,y)}function pc(c,l,d){const y=d*d;if(l.length===1)return c.distSqr(l[0])<y;for(let w=1;w<l.length;w++)if(Kh(c,l[w-1],l[w])<y)return!0;return!1}function Kh(c,l,d){const y=l.distSqr(d);if(y===0)return c.distSqr(l);const w=((c.x-l.x)*(d.x-l.x)+(c.y-l.y)*(d.y-l.y))/y;return c.distSqr(w<0?l:w>1?d:d.sub(l)._mult(w)._add(l))}function nd(c,l){let d,y,w,T=!1;for(let K=0;K<c.length;K++){d=c[K];for(let D=0,z=d.length-1;D<d.length;z=D++)y=d[D],w=d[z],y.y>l.y!=w.y>l.y&&l.x<(w.x-y.x)*(l.y-y.y)/(w.y-y.y)+y.x&&(T=!T)}return T}function rd(c,l){let d=!1;for(let y=0,w=c.length-1;y<c.length;w=y++){const T=c[y],K=c[w];T.y>l.y!=K.y>l.y&&l.x<(K.x-T.x)*(l.y-T.y)/(K.y-T.y)+T.x&&(d=!d)}return d}function k1(c,l,d){const y=d[0],w=d[2];if(c.x<y.x&&l.x<y.x||c.x>w.x&&l.x>w.x||c.y<y.y&&l.y<y.y||c.y>w.y&&l.y>w.y)return!1;const T=Ce(c,l,d[0]);return T!==Ce(c,l,d[1])||T!==Ce(c,l,d[2])||T!==Ce(c,l,d[3])}function Gd(c,l,d){const y=l.paint.get(c).value;return y.kind==="constant"?y.value:d.programConfigurations.get(l.id).getMaxValue(c)}function Zl(c){return Math.sqrt(c[0]*c[0]+c[1]*c[1])}function mc(c,l,d,y,w){if(!l[0]&&!l[1])return c;const T=B.convert(l)._mult(w);d==="viewport"&&T._rotate(-y);const K=[];for(let D=0;D<c.length;D++)K.push(c[D].sub(T));return K}let Qd,Wm;jn("CircleBucket",OA,{omit:["layers"]});var I1={get paint(){return Wm=Wm||new xa({"circle-radius":new Or(mt.paint_circle["circle-radius"]),"circle-color":new Or(mt.paint_circle["circle-color"]),"circle-blur":new Or(mt.paint_circle["circle-blur"]),"circle-opacity":new Or(mt.paint_circle["circle-opacity"]),"circle-translate":new gr(mt.paint_circle["circle-translate"]),"circle-translate-anchor":new gr(mt.paint_circle["circle-translate-anchor"]),"circle-pitch-scale":new gr(mt.paint_circle["circle-pitch-scale"]),"circle-pitch-alignment":new gr(mt.paint_circle["circle-pitch-alignment"]),"circle-stroke-width":new Or(mt.paint_circle["circle-stroke-width"]),"circle-stroke-color":new Or(mt.paint_circle["circle-stroke-color"]),"circle-stroke-opacity":new Or(mt.paint_circle["circle-stroke-opacity"])})},get layout(){return Qd=Qd||new xa({"circle-sort-key":new Or(mt.layout_circle["circle-sort-key"])})}},Xs=1e-6,Ph=typeof Float32Array<"u"?Float32Array:Array;function Kf(c){return c[0]=1,c[1]=0,c[2]=0,c[3]=0,c[4]=0,c[5]=1,c[6]=0,c[7]=0,c[8]=0,c[9]=0,c[10]=1,c[11]=0,c[12]=0,c[13]=0,c[14]=0,c[15]=1,c}function Js(c,l,d){var y=l[0],w=l[1],T=l[2],K=l[3],D=l[4],z=l[5],Q=l[6],ie=l[7],le=l[8],ge=l[9],Oe=l[10],Be=l[11],ze=l[12],$e=l[13],tt=l[14],St=l[15],lt=d[0],vt=d[1],tn=d[2],an=d[3];return c[0]=lt*y+vt*D+tn*le+an*ze,c[1]=lt*w+vt*z+tn*ge+an*$e,c[2]=lt*T+vt*Q+tn*Oe+an*tt,c[3]=lt*K+vt*ie+tn*Be+an*St,c[4]=(lt=d[4])*y+(vt=d[5])*D+(tn=d[6])*le+(an=d[7])*ze,c[5]=lt*w+vt*z+tn*ge+an*$e,c[6]=lt*T+vt*Q+tn*Oe+an*tt,c[7]=lt*K+vt*ie+tn*Be+an*St,c[8]=(lt=d[8])*y+(vt=d[9])*D+(tn=d[10])*le+(an=d[11])*ze,c[9]=lt*w+vt*z+tn*ge+an*$e,c[10]=lt*T+vt*Q+tn*Oe+an*tt,c[11]=lt*K+vt*ie+tn*Be+an*St,c[12]=(lt=d[12])*y+(vt=d[13])*D+(tn=d[14])*le+(an=d[15])*ze,c[13]=lt*w+vt*z+tn*ge+an*$e,c[14]=lt*T+vt*Q+tn*Oe+an*tt,c[15]=lt*K+vt*ie+tn*Be+an*St,c}Math.hypot||(Math.hypot=function(){for(var c=0,l=arguments.length;l--;)c+=arguments[l]*arguments[l];return Math.sqrt(c)});var id,ev=Js;function Fh(c,l,d){var y=l[0],w=l[1],T=l[2],K=l[3];return c[0]=d[0]*y+d[4]*w+d[8]*T+d[12]*K,c[1]=d[1]*y+d[5]*w+d[9]*T+d[13]*K,c[2]=d[2]*y+d[6]*w+d[10]*T+d[14]*K,c[3]=d[3]*y+d[7]*w+d[11]*T+d[15]*K,c}id=new Ph(4),Ph!=Float32Array&&(id[0]=0,id[1]=0,id[2]=0,id[3]=0);class Qi extends As{constructor(l){super(l,I1)}createBucket(l){return new OA(l)}queryRadius(l){const d=l;return Gd("circle-radius",this,d)+Gd("circle-stroke-width",this,d)+Zl(this.paint.get("circle-translate"))}queryIntersectsFeature(l,d,y,w,T,K,D,z){const Q=mc(l,this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),K.angle,D),ie=this.paint.get("circle-radius").evaluate(d,y)+this.paint.get("circle-stroke-width").evaluate(d,y),le=this.paint.get("circle-pitch-alignment")==="map",ge=le?Q:function(Be,ze){return Be.map($e=>Nm($e,ze))}(Q,z),Oe=le?ie*D:ie;for(const Be of w)for(const ze of Be){const $e=le?ze:Nm(ze,z);let tt=Oe;const St=Fh([],[ze.x,ze.y,0,1],z);if(this.paint.get("circle-pitch-scale")==="viewport"&&this.paint.get("circle-pitch-alignment")==="map"?tt*=St[3]/K.cameraToCenterDistance:this.paint.get("circle-pitch-scale")==="map"&&this.paint.get("circle-pitch-alignment")==="viewport"&&(tt*=K.cameraToCenterDistance/St[3]),BA(ge,$e,tt))return!0}return!1}}function Nm(c,l){const d=Fh([],[c.x,c.y,0,1],l);return new B(d[0]/d[3],d[1]/d[3])}class Gm extends OA{}let $d;jn("HeatmapBucket",Gm,{omit:["layers"]});var T1={get paint(){return $d=$d||new xa({"heatmap-radius":new Or(mt.paint_heatmap["heatmap-radius"]),"heatmap-weight":new Or(mt.paint_heatmap["heatmap-weight"]),"heatmap-intensity":new gr(mt.paint_heatmap["heatmap-intensity"]),"heatmap-color":new dl(mt.paint_heatmap["heatmap-color"]),"heatmap-opacity":new gr(mt.paint_heatmap["heatmap-opacity"])})}};function Qm(c,{width:l,height:d},y,w){if(w){if(w instanceof Uint8ClampedArray)w=new Uint8Array(w.buffer);else if(w.length!==l*d*y)throw new RangeError(`mismatched image size. expected: ${w.length} but got: ${l*d*y}`)}else w=new Uint8Array(l*d*y);return c.width=l,c.height=d,c.data=w,c}function K1(c,{width:l,height:d},y){if(l===c.width&&d===c.height)return;const w=Qm({},{width:l,height:d},y);qa(c,w,{x:0,y:0},{x:0,y:0},{width:Math.min(c.width,l),height:Math.min(c.height,d)},y),c.width=l,c.height=d,c.data=w.data}function qa(c,l,d,y,w,T){if(w.width===0||w.height===0)return l;if(w.width>c.width||w.height>c.height||d.x>c.width-w.width||d.y>c.height-w.height)throw new RangeError("out of range source coordinates for image copy");if(w.width>l.width||w.height>l.height||y.x>l.width-w.width||y.y>l.height-w.height)throw new RangeError("out of range destination coordinates for image copy");const K=c.data,D=l.data;if(K===D)throw new Error("srcData equals dstData, so image is already copied");for(let z=0;z<w.height;z++){const Q=((d.y+z)*c.width+d.x)*T,ie=((y.y+z)*l.width+y.x)*T;for(let le=0;le<w.width*T;le++)D[ie+le]=K[Q+le]}return l}class gc{constructor(l,d){Qm(this,l,1,d)}resize(l){K1(this,l,1)}clone(){return new gc({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(l,d,y,w,T){qa(l,d,y,w,T,1)}}class Ss{constructor(l,d){Qm(this,l,4,d)}resize(l){K1(this,l,4)}replace(l,d){d?this.data.set(l):this.data=l instanceof Uint8ClampedArray?new Uint8Array(l.buffer):l}clone(){return new Ss({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(l,d,y,w,T){qa(l,d,y,w,T,4)}}function od(c){const l={},d=c.resolution||256,y=c.clips?c.clips.length:1,w=c.image||new Ss({width:d,height:y});if(Math.log(d)/Math.LN2%1!=0)throw new Error(`width is not a power of 2 - ${d}`);const T=(K,D,z)=>{l[c.evaluationKey]=z;const Q=c.expression.evaluate(l);w.data[K+D+0]=Math.floor(255*Q.r/Q.a),w.data[K+D+1]=Math.floor(255*Q.g/Q.a),w.data[K+D+2]=Math.floor(255*Q.b/Q.a),w.data[K+D+3]=Math.floor(255*Q.a)};if(c.clips)for(let K=0,D=0;K<y;++K,D+=4*d)for(let z=0,Q=0;z<d;z++,Q+=4){const ie=z/(d-1),{start:le,end:ge}=c.clips[K];T(D,Q,le*(1-ie)+ge*ie)}else for(let K=0,D=0;K<d;K++,D+=4)T(0,D,K/(d-1));return w}jn("AlphaImage",gc),jn("RGBAImage",Ss);class kA extends As{createBucket(l){return new Gm(l)}constructor(l){super(l,T1),this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(l){l==="heatmap-color"&&this._updateColorRamp()}_updateColorRamp(){this.colorRamp=od({expression:this._transitionablePaint._values["heatmap-color"].value.expression,evaluationKey:"heatmapDensity",image:this.colorRamp}),this.colorRampTexture=null}resize(){this.heatmapFbo&&(this.heatmapFbo.destroy(),this.heatmapFbo=null)}queryRadius(){return 0}queryIntersectsFeature(){return!1}hasOffscreenPass(){return this.paint.get("heatmap-opacity")!==0&&this.visibility!=="none"}}let $m;var fu={get paint(){return $m=$m||new xa({"hillshade-illumination-direction":new gr(mt.paint_hillshade["hillshade-illumination-direction"]),"hillshade-illumination-anchor":new gr(mt.paint_hillshade["hillshade-illumination-anchor"]),"hillshade-exaggeration":new gr(mt.paint_hillshade["hillshade-exaggeration"]),"hillshade-shadow-color":new gr(mt.paint_hillshade["hillshade-shadow-color"]),"hillshade-highlight-color":new gr(mt.paint_hillshade["hillshade-highlight-color"]),"hillshade-accent-color":new gr(mt.paint_hillshade["hillshade-accent-color"])})}};class pu extends As{constructor(l){super(l,fu)}hasOffscreenPass(){return this.paint.get("hillshade-exaggeration")!==0&&this.visibility!=="none"}}const Tp=zo([{name:"a_pos",components:2,type:"Int16"}],4),{members:Ym}=Tp;var Yd={exports:{}};function ad(c,l,d){d=d||2;var y,w,T,K,D,z,Q,ie=l&&l.length,le=ie?l[0]*d:c.length,ge=yc(c,0,le,d,!0),Oe=[];if(!ge||ge.next===ge.prev)return Oe;if(ie&&(ge=function(ze,$e,tt,St){var lt,vt,tn,an=[];for(lt=0,vt=$e.length;lt<vt;lt++)(tn=yc(ze,$e[lt]*St,lt<vt-1?$e[lt+1]*St:ze.length,St,!1))===tn.next&&(tn.steiner=!0),an.push(tv(tn));for(an.sort(P1),lt=0;lt<an.length;lt++)tt=qm(an[lt],tt);return tt}(c,l,ge,d)),c.length>80*d){y=T=c[0],w=K=c[1];for(var Be=d;Be<le;Be+=d)(D=c[Be])<y&&(y=D),(z=c[Be+1])<w&&(w=z),D>T&&(T=D),z>K&&(K=z);Q=(Q=Math.max(T-y,K-w))!==0?32767/Q:0}return vc(ge,Oe,d,y,w,Q,0),Oe}function yc(c,l,d,y,w){var T,K;if(w===ld(c,l,d,y)>0)for(T=l;T<d;T+=y)K=F1(T,c[T],c[T+1],K);else for(T=d-y;T>=l;T-=y)K=F1(T,c[T],c[T+1],K);return K&&Kp(K,K.next)&&(KA(K),K=K.next),K}function IA(c,l){if(!c)return c;l||(l=c);var d,y=c;do if(d=!1,y.steiner||!Kp(y,y.next)&&Aa(y.prev,y,y.next)!==0)y=y.next;else{if(KA(y),(y=l=y.prev)===y.next)break;d=!0}while(d||y!==l);return l}function vc(c,l,d,y,w,T,K){if(c){!K&&T&&function(ie,le,ge,Oe){var Be=ie;do Be.z===0&&(Be.z=Vm(Be.x,Be.y,le,ge,Oe)),Be.prevZ=Be.prev,Be.nextZ=Be.next,Be=Be.next;while(Be!==ie);Be.prevZ.nextZ=null,Be.prevZ=null,function(ze){var $e,tt,St,lt,vt,tn,an,Vn,cr=1;do{for(tt=ze,ze=null,vt=null,tn=0;tt;){for(tn++,St=tt,an=0,$e=0;$e<cr&&(an++,St=St.nextZ);$e++);for(Vn=cr;an>0||Vn>0&&St;)an!==0&&(Vn===0||!St||tt.z<=St.z)?(lt=tt,tt=tt.nextZ,an--):(lt=St,St=St.nextZ,Vn--),vt?vt.nextZ=lt:ze=lt,lt.prevZ=vt,vt=lt;tt=St}vt.nextZ=null,cr*=2}while(tn>1)}(Be)}(c,y,w,T);for(var D,z,Q=c;c.prev!==c.next;)if(D=c.prev,z=c.next,T?sd(c,y,w,T):Pf(c))l.push(D.i/d|0),l.push(c.i/d|0),l.push(z.i/d|0),KA(c),c=z.next,Q=z.next;else if((c=z)===Q){K?K===1?vc(c=Ff(IA(c),l,d),l,d,y,w,T,2):K===2&&Cc(c,l,d,y,w,T):vc(IA(c),l,d,y,w,T,1);break}}}function Pf(c){var l=c.prev,d=c,y=c.next;if(Aa(l,d,y)>=0)return!1;for(var w=l.x,T=d.x,K=y.x,D=l.y,z=d.y,Q=y.y,ie=w<T?w<K?w:K:T<K?T:K,le=D<z?D<Q?D:Q:z<Q?z:Q,ge=w>T?w>K?w:K:T>K?T:K,Oe=D>z?D>Q?D:Q:z>Q?z:Q,Be=y.next;Be!==l;){if(Be.x>=ie&&Be.x<=ge&&Be.y>=le&&Be.y<=Oe&&TA(w,D,T,z,K,Q,Be.x,Be.y)&&Aa(Be.prev,Be,Be.next)>=0)return!1;Be=Be.next}return!0}function sd(c,l,d,y){var w=c.prev,T=c,K=c.next;if(Aa(w,T,K)>=0)return!1;for(var D=w.x,z=T.x,Q=K.x,ie=w.y,le=T.y,ge=K.y,Oe=D<z?D<Q?D:Q:z<Q?z:Q,Be=ie<le?ie<ge?ie:ge:le<ge?le:ge,ze=D>z?D>Q?D:Q:z>Q?z:Q,$e=ie>le?ie>ge?ie:ge:le>ge?le:ge,tt=Vm(Oe,Be,l,d,y),St=Vm(ze,$e,l,d,y),lt=c.prevZ,vt=c.nextZ;lt&<.z>=tt&&vt&&vt.z<=St;){if(lt.x>=Oe&<.x<=ze&<.y>=Be&<.y<=$e&<!==w&<!==K&&TA(D,ie,z,le,Q,ge,lt.x,lt.y)&&Aa(lt.prev,lt,lt.next)>=0||(lt=lt.prevZ,vt.x>=Oe&&vt.x<=ze&&vt.y>=Be&&vt.y<=$e&&vt!==w&&vt!==K&&TA(D,ie,z,le,Q,ge,vt.x,vt.y)&&Aa(vt.prev,vt,vt.next)>=0))return!1;vt=vt.nextZ}for(;lt&<.z>=tt;){if(lt.x>=Oe&<.x<=ze&<.y>=Be&<.y<=$e&<!==w&<!==K&&TA(D,ie,z,le,Q,ge,lt.x,lt.y)&&Aa(lt.prev,lt,lt.next)>=0)return!1;lt=lt.prevZ}for(;vt&&vt.z<=St;){if(vt.x>=Oe&&vt.x<=ze&&vt.y>=Be&&vt.y<=$e&&vt!==w&&vt!==K&&TA(D,ie,z,le,Q,ge,vt.x,vt.y)&&Aa(vt.prev,vt,vt.next)>=0)return!1;vt=vt.nextZ}return!0}function Ff(c,l,d){var y=c;do{var w=y.prev,T=y.next.next;!Kp(w,T)&&Df(w,y,y.next,T)&&Tl(w,T)&&Tl(T,w)&&(l.push(w.i/d|0),l.push(y.i/d|0),l.push(T.i/d|0),KA(y),KA(y.next),y=c=T),y=y.next}while(y!==c);return IA(y)}function Cc(c,l,d,y,w,T){var K=c;do{for(var D=K.next.next;D!==K.prev;){if(K.i!==D.i&&Hm(K,D)){var z=Zm(K,D);return K=IA(K,K.next),z=IA(z,z.next),vc(K,l,d,y,w,T,0),void vc(z,l,d,y,w,T,0)}D=D.next}K=K.next}while(K!==c)}function P1(c,l){return c.x-l.x}function qm(c,l){var d=function(w,T){var K,D=T,z=w.x,Q=w.y,ie=-1/0;do{if(Q<=D.y&&Q>=D.next.y&&D.next.y!==D.y){var le=D.x+(Q-D.y)*(D.next.x-D.x)/(D.next.y-D.y);if(le<=z&&le>ie&&(ie=le,K=D.x<D.next.x?D:D.next,le===z))return K}D=D.next}while(D!==T);if(!K)return null;var ge,Oe=K,Be=K.x,ze=K.y,$e=1/0;D=K;do z>=D.x&&D.x>=Be&&z!==D.x&&TA(Q<ze?z:ie,Q,Be,ze,Q<ze?ie:z,Q,D.x,D.y)&&(ge=Math.abs(Q-D.y)/(z-D.x),Tl(D,w)&&(ge<$e||ge===$e&&(D.x>K.x||D.x===K.x&&Dh(K,D)))&&(K=D,$e=ge)),D=D.next;while(D!==Oe);return K}(c,l);if(!d)return l;var y=Zm(d,c);return IA(y,y.next),IA(d,d.next)}function Dh(c,l){return Aa(c.prev,c,l.prev)<0&&Aa(l.next,c,c.next)<0}function Vm(c,l,d,y,w){return(c=1431655765&((c=858993459&((c=252645135&((c=16711935&((c=(c-d)*w|0)|c<<8))|c<<4))|c<<2))|c<<1))|(l=1431655765&((l=858993459&((l=252645135&((l=16711935&((l=(l-y)*w|0)|l<<8))|l<<4))|l<<2))|l<<1))<<1}function tv(c){var l=c,d=c;do(l.x<d.x||l.x===d.x&&l.y<d.y)&&(d=l),l=l.next;while(l!==c);return d}function TA(c,l,d,y,w,T,K,D){return(w-K)*(l-D)>=(c-K)*(T-D)&&(c-K)*(y-D)>=(d-K)*(l-D)&&(d-K)*(T-D)>=(w-K)*(y-D)}function Hm(c,l){return c.next.i!==l.i&&c.prev.i!==l.i&&!function(d,y){var w=d;do{if(w.i!==d.i&&w.next.i!==d.i&&w.i!==y.i&&w.next.i!==y.i&&Df(w,w.next,d,y))return!0;w=w.next}while(w!==d);return!1}(c,l)&&(Tl(c,l)&&Tl(l,c)&&function(d,y){var w=d,T=!1,K=(d.x+y.x)/2,D=(d.y+y.y)/2;do w.y>D!=w.next.y>D&&w.next.y!==w.y&&K<(w.next.x-w.x)*(D-w.y)/(w.next.y-w.y)+w.x&&(T=!T),w=w.next;while(w!==d);return T}(c,l)&&(Aa(c.prev,c,l.prev)||Aa(c,l.prev,l))||Kp(c,l)&&Aa(c.prev,c,c.next)>0&&Aa(l.prev,l,l.next)>0)}function Aa(c,l,d){return(l.y-c.y)*(d.x-l.x)-(l.x-c.x)*(d.y-l.y)}function Kp(c,l){return c.x===l.x&&c.y===l.y}function Df(c,l,d,y){var w=el(Aa(c,l,d)),T=el(Aa(c,l,y)),K=el(Aa(d,y,c)),D=el(Aa(d,y,l));return w!==T&&K!==D||!(w!==0||!Uh(c,d,l))||!(T!==0||!Uh(c,y,l))||!(K!==0||!Uh(d,c,y))||!(D!==0||!Uh(d,l,y))}function Uh(c,l,d){return l.x<=Math.max(c.x,d.x)&&l.x>=Math.min(c.x,d.x)&&l.y<=Math.max(c.y,d.y)&&l.y>=Math.min(c.y,d.y)}function el(c){return c>0?1:c<0?-1:0}function Tl(c,l){return Aa(c.prev,c,c.next)<0?Aa(c,l,c.next)>=0&&Aa(c,c.prev,l)>=0:Aa(c,l,c.prev)<0||Aa(c,c.next,l)<0}function Zm(c,l){var d=new Du(c.i,c.x,c.y),y=new Du(l.i,l.x,l.y),w=c.next,T=l.prev;return c.next=l,l.prev=c,d.next=w,w.prev=d,y.next=d,d.prev=y,T.next=y,y.prev=T,y}function F1(c,l,d,y){var w=new Du(c,l,d);return y?(w.next=y.next,w.prev=y,y.next.prev=w,y.next=w):(w.prev=w,w.next=w),w}function KA(c){c.next.prev=c.prev,c.prev.next=c.next,c.prevZ&&(c.prevZ.nextZ=c.nextZ),c.nextZ&&(c.nextZ.prevZ=c.prevZ)}function Du(c,l,d){this.i=c,this.x=l,this.y=d,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}function ld(c,l,d,y){for(var w=0,T=l,K=d-y;T<d;T+=y)w+=(c[K]-c[T])*(c[T+1]+c[K+1]),K=T;return w}Yd.exports=ad,Yd.exports.default=ad,ad.deviation=function(c,l,d,y){var w=l&&l.length,T=Math.abs(ld(c,0,w?l[0]*d:c.length,d));if(w)for(var K=0,D=l.length;K<D;K++)T-=Math.abs(ld(c,l[K]*d,K<D-1?l[K+1]*d:c.length,d));var z=0;for(K=0;K<y.length;K+=3){var Q=y[K]*d,ie=y[K+1]*d,le=y[K+2]*d;z+=Math.abs((c[Q]-c[le])*(c[ie+1]-c[Q+1])-(c[Q]-c[ie])*(c[le+1]-c[Q+1]))}return T===0&&z===0?0:Math.abs((z-T)/T)},ad.flatten=function(c){for(var l=c[0][0].length,d={vertices:[],holes:[],dimensions:l},y=0,w=0;w<c.length;w++){for(var T=0;T<c[w].length;T++)for(var K=0;K<l;K++)d.vertices.push(c[w][T][K]);w>0&&d.holes.push(y+=c[w-1].length)}return d};var Xm=g(Yd.exports);function D1(c,l,d,y,w){Jm(c,l,d||0,y||c.length-1,w||Uf)}function Jm(c,l,d,y,w){for(;y>d;){if(y-d>600){var T=y-d+1,K=l-d+1,D=Math.log(T),z=.5*Math.exp(2*D/3),Q=.5*Math.sqrt(D*z*(T-z)/T)*(K-T/2<0?-1:1);Jm(c,l,Math.max(d,Math.floor(l-K*z/T+Q)),Math.min(y,Math.floor(l+(T-K)*z/T+Q)),w)}var ie=c[l],le=d,ge=y;for(PA(c,d,l),w(c[y],ie)>0&&PA(c,d,y);le<ge;){for(PA(c,le,ge),le++,ge--;w(c[le],ie)<0;)le++;for(;w(c[ge],ie)>0;)ge--}w(c[d],ie)===0?PA(c,d,ge):PA(c,++ge,y),ge<=l&&(d=ge+1),l<=ge&&(y=ge-1)}}function PA(c,l,d){var y=c[l];c[l]=c[d],c[d]=y}function Uf(c,l){return c<l?-1:c>l?1:0}function e0(c,l){const d=c.length;if(d<=1)return[c];const y=[];let w,T;for(let K=0;K<d;K++){const D=jt(c[K]);D!==0&&(c[K].area=Math.abs(D),T===void 0&&(T=D<0),T===D<0?(w&&y.push(w),w=[c[K]]):w.push(c[K]))}if(w&&y.push(w),l>1)for(let K=0;K<y.length;K++)y[K].length<=l||(D1(y[K],l,1,y[K].length-1,t0),y[K]=y[K].slice(0,l));return y}function t0(c,l){return l.area-c.area}function Pp(c,l,d){const y=d.patternDependencies;let w=!1;for(const T of l){const K=T.paint.get(`${c}-pattern`);K.isConstant()||(w=!0);const D=K.constantOr(null);D&&(w=!0,y[D.to]=!0,y[D.from]=!0)}return w}function Rh(c,l,d,y,w){const T=w.patternDependencies;for(const K of l){const D=K.paint.get(`${c}-pattern`).value;if(D.kind!=="constant"){let z=D.evaluate({zoom:y-1},d,{},w.availableImages),Q=D.evaluate({zoom:y},d,{},w.availableImages),ie=D.evaluate({zoom:y+1},d,{},w.availableImages);z=z&&z.name?z.name:z,Q=Q&&Q.name?Q.name:Q,ie=ie&&ie.name?ie.name:ie,T[z]=!0,T[Q]=!0,T[ie]=!0,d.patterns[K.id]={min:z,mid:Q,max:ie}}}return d}class Rf{constructor(l){this.zoom=l.zoom,this.overscaling=l.overscaling,this.layers=l.layers,this.layerIds=this.layers.map(d=>d.id),this.index=l.index,this.hasPattern=!1,this.patternFeatures=[],this.layoutVertexArray=new je,this.indexArray=new hn,this.indexArray2=new An,this.programConfigurations=new ua(l.layers,l.zoom),this.segments=new xr,this.segments2=new xr,this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){this.hasPattern=Pp("fill",this.layers,d);const w=this.layers[0].layout.get("fill-sort-key"),T=!w.isConstant(),K=[];for(const{feature:D,id:z,index:Q,sourceLayerIndex:ie}of l){const le=this.layers[0]._featureFilter.needGeometry,ge=hl(D,le);if(!this.layers[0]._featureFilter.filter(new go(this.zoom),ge,y))continue;const Oe=T?w.evaluate(ge,{},y,d.availableImages):void 0,Be={id:z,properties:D.properties,type:D.type,sourceLayerIndex:ie,index:Q,geometry:le?ge.geometry:EA(D),patterns:{},sortKey:Oe};K.push(Be)}T&&K.sort((D,z)=>D.sortKey-z.sortKey);for(const D of K){const{geometry:z,index:Q,sourceLayerIndex:ie}=D;if(this.hasPattern){const le=Rh("fill",this.layers,D,this.zoom,d);this.patternFeatures.push(le)}else this.addFeature(D,z,Q,y,{});d.featureIndex.insert(l[Q].feature,z,Q,ie,this.index)}}update(l,d,y){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(l,d,this.stateDependentLayers,y)}addFeatures(l,d,y){for(const w of this.patternFeatures)this.addFeature(w,w.geometry,w.index,d,y)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(l){this.uploaded||(this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,Ym),this.indexBuffer=l.createIndexBuffer(this.indexArray),this.indexBuffer2=l.createIndexBuffer(this.indexArray2)),this.programConfigurations.upload(l),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.indexBuffer2.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.segments2.destroy())}addFeature(l,d,y,w,T){for(const K of e0(d,500)){let D=0;for(const Oe of K)D+=Oe.length;const z=this.segments.prepareSegment(D,this.layoutVertexArray,this.indexArray),Q=z.vertexLength,ie=[],le=[];for(const Oe of K){if(Oe.length===0)continue;Oe!==K[0]&&le.push(ie.length/2);const Be=this.segments2.prepareSegment(Oe.length,this.layoutVertexArray,this.indexArray2),ze=Be.vertexLength;this.layoutVertexArray.emplaceBack(Oe[0].x,Oe[0].y),this.indexArray2.emplaceBack(ze+Oe.length-1,ze),ie.push(Oe[0].x),ie.push(Oe[0].y);for(let $e=1;$e<Oe.length;$e++)this.layoutVertexArray.emplaceBack(Oe[$e].x,Oe[$e].y),this.indexArray2.emplaceBack(ze+$e-1,ze+$e),ie.push(Oe[$e].x),ie.push(Oe[$e].y);Be.vertexLength+=Oe.length,Be.primitiveLength+=Oe.length}const ge=Xm(ie,le);for(let Oe=0;Oe<ge.length;Oe+=3)this.indexArray.emplaceBack(Q+ge[Oe],Q+ge[Oe+1],Q+ge[Oe+2]);z.vertexLength+=D,z.primitiveLength+=ge.length/3}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,l,y,T,w)}}let qd,Lf;jn("FillBucket",Rf,{omit:["layers","patternFeatures"]});var Fp={get paint(){return Lf=Lf||new xa({"fill-antialias":new gr(mt.paint_fill["fill-antialias"]),"fill-opacity":new Or(mt.paint_fill["fill-opacity"]),"fill-color":new Or(mt.paint_fill["fill-color"]),"fill-outline-color":new Or(mt.paint_fill["fill-outline-color"]),"fill-translate":new gr(mt.paint_fill["fill-translate"]),"fill-translate-anchor":new gr(mt.paint_fill["fill-translate-anchor"]),"fill-pattern":new SA(mt.paint_fill["fill-pattern"])})},get layout(){return qd=qd||new xa({"fill-sort-key":new Or(mt.layout_fill["fill-sort-key"])})}};class U1 extends As{constructor(l){super(l,Fp)}recalculate(l,d){super.recalculate(l,d);const y=this.paint._values["fill-outline-color"];y.value.kind==="constant"&&y.value.value===void 0&&(this.paint._values["fill-outline-color"]=this.paint._values["fill-color"])}createBucket(l){return new Rf(l)}queryRadius(){return Zl(this.paint.get("fill-translate"))}queryIntersectsFeature(l,d,y,w,T,K,D){return Nd(mc(l,this.paint.get("fill-translate"),this.paint.get("fill-translate-anchor"),K.angle,D),w)}isTileClipped(){return!0}}const Vd=zo([{name:"a_pos",components:2,type:"Int16"},{name:"a_normal_ed",components:4,type:"Int16"}],4),zf=zo([{name:"a_centroid",components:2,type:"Int16"}],4),{members:jf}=Vd;var FA={},nv=x,n0=qi;function qi(c,l,d,y,w){this.properties={},this.extent=d,this.type=0,this._pbf=c,this._geometry=-1,this._keys=y,this._values=w,c.readFields(R1,this,l)}function R1(c,l,d){c==1?l.id=d.readVarint():c==2?function(y,w){for(var T=y.readVarint()+y.pos;y.pos<T;){var K=w._keys[y.readVarint()],D=w._values[y.readVarint()];w.properties[K]=D}}(d,l):c==3?l.type=d.readVarint():c==4&&(l._geometry=d.pos)}function Dp(c){for(var l,d,y=0,w=0,T=c.length,K=T-1;w<T;K=w++)y+=((d=c[K]).x-(l=c[w]).x)*(l.y+d.y);return y}qi.types=["Unknown","Point","LineString","Polygon"],qi.prototype.loadGeometry=function(){var c=this._pbf;c.pos=this._geometry;for(var l,d=c.readVarint()+c.pos,y=1,w=0,T=0,K=0,D=[];c.pos<d;){if(w<=0){var z=c.readVarint();y=7&z,w=z>>3}if(w--,y===1||y===2)T+=c.readSVarint(),K+=c.readSVarint(),y===1&&(l&&D.push(l),l=[]),l.push(new nv(T,K));else{if(y!==7)throw new Error("unknown command "+y);l&&l.push(l[0].clone())}}return l&&D.push(l),D},qi.prototype.bbox=function(){var c=this._pbf;c.pos=this._geometry;for(var l=c.readVarint()+c.pos,d=1,y=0,w=0,T=0,K=1/0,D=-1/0,z=1/0,Q=-1/0;c.pos<l;){if(y<=0){var ie=c.readVarint();d=7&ie,y=ie>>3}if(y--,d===1||d===2)(w+=c.readSVarint())<K&&(K=w),w>D&&(D=w),(T+=c.readSVarint())<z&&(z=T),T>Q&&(Q=T);else if(d!==7)throw new Error("unknown command "+d)}return[K,z,D,Q]},qi.prototype.toGeoJSON=function(c,l,d){var y,w,T=this.extent*Math.pow(2,d),K=this.extent*c,D=this.extent*l,z=this.loadGeometry(),Q=qi.types[this.type];function ie(Oe){for(var Be=0;Be<Oe.length;Be++){var ze=Oe[Be];Oe[Be]=[360*(ze.x+K)/T-180,360/Math.PI*Math.atan(Math.exp((180-360*(ze.y+D)/T)*Math.PI/180))-90]}}switch(this.type){case 1:var le=[];for(y=0;y<z.length;y++)le[y]=z[y][0];ie(z=le);break;case 2:for(y=0;y<z.length;y++)ie(z[y]);break;case 3:for(z=function(Oe){var Be=Oe.length;if(Be<=1)return[Oe];for(var ze,$e,tt=[],St=0;St<Be;St++){var lt=Dp(Oe[St]);lt!==0&&($e===void 0&&($e=lt<0),$e===lt<0?(ze&&tt.push(ze),ze=[Oe[St]]):ze.push(Oe[St]))}return ze&&tt.push(ze),tt}(z),y=0;y<z.length;y++)for(w=0;w<z[y].length;w++)ie(z[y][w])}z.length===1?z=z[0]:Q="Multi"+Q;var ge={type:"Feature",geometry:{type:Q,coordinates:z},properties:this.properties};return"id"in this&&(ge.id=this.id),ge};var Wf=n0,mu=Nf;function Nf(c,l){this.version=1,this.name=null,this.extent=4096,this.length=0,this._pbf=c,this._keys=[],this._values=[],this._features=[],c.readFields(r0,this,l),this.length=this._features.length}function r0(c,l,d){c===15?l.version=d.readVarint():c===1?l.name=d.readString():c===5?l.extent=d.readVarint():c===2?l._features.push(d.pos):c===3?l._keys.push(d.readString()):c===4&&l._values.push(function(y){for(var w=null,T=y.readVarint()+y.pos;y.pos<T;){var K=y.readVarint()>>3;w=K===1?y.readString():K===2?y.readFloat():K===3?y.readDouble():K===4?y.readVarint64():K===5?y.readVarint():K===6?y.readSVarint():K===7?y.readBoolean():null}return w}(d))}Nf.prototype.feature=function(c){if(c<0||c>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[c];var l=this._pbf.readVarint()+this._pbf.pos;return new Wf(this._pbf,l,this.extent,this._keys,this._values)};var DA=mu;function Up(c,l,d){if(c===3){var y=new DA(d,d.readVarint()+d.pos);y.length&&(l[y.name]=y)}}FA.VectorTile=function(c,l){this.layers=c.readFields(Up,{},l)},FA.VectorTileFeature=n0,FA.VectorTileLayer=mu;const Rp=FA.VectorTileFeature.types,Hd=Math.pow(2,13);function _c(c,l,d,y,w,T,K,D){c.emplaceBack(l,d,2*Math.floor(y*Hd)+K,w*Hd*2,T*Hd*2,Math.round(D))}class ud{constructor(l){this.zoom=l.zoom,this.overscaling=l.overscaling,this.layers=l.layers,this.layerIds=this.layers.map(d=>d.id),this.index=l.index,this.hasPattern=!1,this.layoutVertexArray=new Qe,this.centroidVertexArray=new Me,this.indexArray=new hn,this.programConfigurations=new ua(l.layers,l.zoom),this.segments=new xr,this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){this.features=[],this.hasPattern=Pp("fill-extrusion",this.layers,d);for(const{feature:w,id:T,index:K,sourceLayerIndex:D}of l){const z=this.layers[0]._featureFilter.needGeometry,Q=hl(w,z);if(!this.layers[0]._featureFilter.filter(new go(this.zoom),Q,y))continue;const ie={id:T,sourceLayerIndex:D,index:K,geometry:z?Q.geometry:EA(w),properties:w.properties,type:w.type,patterns:{}};this.hasPattern?this.features.push(Rh("fill-extrusion",this.layers,ie,this.zoom,d)):this.addFeature(ie,ie.geometry,K,y,{}),d.featureIndex.insert(w,ie.geometry,K,D,this.index,!0)}}addFeatures(l,d,y){for(const w of this.features){const{geometry:T}=w;this.addFeature(w,T,w.index,d,y)}}update(l,d,y){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(l,d,this.stateDependentLayers,y)}isEmpty(){return this.layoutVertexArray.length===0&&this.centroidVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(l){this.uploaded||(this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,jf),this.centroidVertexBuffer=l.createVertexBuffer(this.centroidVertexArray,zf.members,!0),this.indexBuffer=l.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(l),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.centroidVertexBuffer.destroy())}addFeature(l,d,y,w,T){const K={x:0,y:0,vertexCount:0};for(const D of e0(d,500)){let z=0;for(const Be of D)z+=Be.length;let Q=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray);for(const Be of D){if(Be.length===0||Gf(Be))continue;let ze=0;for(let $e=0;$e<Be.length;$e++){const tt=Be[$e];if($e>=1){const St=Be[$e-1];if(!Vr(tt,St)){Q.vertexLength+4>xr.MAX_VERTEX_ARRAY_LENGTH&&(Q=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));const lt=tt.sub(St)._perp()._unit(),vt=St.dist(tt);ze+vt>32768&&(ze=0),_c(this.layoutVertexArray,tt.x,tt.y,lt.x,lt.y,0,0,ze),_c(this.layoutVertexArray,tt.x,tt.y,lt.x,lt.y,0,1,ze),K.x+=2*tt.x,K.y+=2*tt.y,K.vertexCount+=2,ze+=vt,_c(this.layoutVertexArray,St.x,St.y,lt.x,lt.y,0,0,ze),_c(this.layoutVertexArray,St.x,St.y,lt.x,lt.y,0,1,ze),K.x+=2*St.x,K.y+=2*St.y,K.vertexCount+=2;const tn=Q.vertexLength;this.indexArray.emplaceBack(tn,tn+2,tn+1),this.indexArray.emplaceBack(tn+1,tn+2,tn+3),Q.vertexLength+=4,Q.primitiveLength+=2}}}}if(Q.vertexLength+z>xr.MAX_VERTEX_ARRAY_LENGTH&&(Q=this.segments.prepareSegment(z,this.layoutVertexArray,this.indexArray)),Rp[l.type]!=="Polygon")continue;const ie=[],le=[],ge=Q.vertexLength;for(const Be of D)if(Be.length!==0){Be!==D[0]&&le.push(ie.length/2);for(let ze=0;ze<Be.length;ze++){const $e=Be[ze];_c(this.layoutVertexArray,$e.x,$e.y,0,0,1,1,0),K.x+=$e.x,K.y+=$e.y,K.vertexCount+=1,ie.push($e.x),ie.push($e.y)}}const Oe=Xm(ie,le);for(let Be=0;Be<Oe.length;Be+=3)this.indexArray.emplaceBack(ge+Oe[Be],ge+Oe[Be+2],ge+Oe[Be+1]);Q.primitiveLength+=Oe.length/3,Q.vertexLength+=z}for(let D=0;D<K.vertexCount;D++)this.centroidVertexArray.emplaceBack(Math.floor(K.x/K.vertexCount),Math.floor(K.y/K.vertexCount));this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,l,y,T,w)}}function Vr(c,l){return c.x===l.x&&(c.x<0||c.x>Wo)||c.y===l.y&&(c.y<0||c.y>Wo)}function Gf(c){return c.every(l=>l.x<0)||c.every(l=>l.x>Wo)||c.every(l=>l.y<0)||c.every(l=>l.y>Wo)}let Co;jn("FillExtrusionBucket",ud,{omit:["layers","features"]});var Ad={get paint(){return Co=Co||new xa({"fill-extrusion-opacity":new gr(mt["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new Or(mt["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new gr(mt["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new gr(mt["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new SA(mt["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new Or(mt["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new Or(mt["paint_fill-extrusion"]["fill-extrusion-base"]),"fill-extrusion-vertical-gradient":new gr(mt["paint_fill-extrusion"]["fill-extrusion-vertical-gradient"])})}};class rv extends As{constructor(l){super(l,Ad)}createBucket(l){return new ud(l)}queryRadius(){return Zl(this.paint.get("fill-extrusion-translate"))}is3D(){return!0}queryIntersectsFeature(l,d,y,w,T,K,D,z){const Q=mc(l,this.paint.get("fill-extrusion-translate"),this.paint.get("fill-extrusion-translate-anchor"),K.angle,D),ie=this.paint.get("fill-extrusion-height").evaluate(d,y),le=this.paint.get("fill-extrusion-base").evaluate(d,y),ge=function(Be,ze,$e,tt){const St=[];for(const lt of Be){const vt=[lt.x,lt.y,0,1];Fh(vt,vt,ze),St.push(new B(vt[0]/vt[3],vt[1]/vt[3]))}return St}(Q,z),Oe=function(Be,ze,$e,tt){const St=[],lt=[],vt=tt[8]*ze,tn=tt[9]*ze,an=tt[10]*ze,Vn=tt[11]*ze,cr=tt[8]*$e,xn=tt[9]*$e,Cn=tt[10]*$e,Kn=tt[11]*$e;for(const ur of Be){const Dn=[],wn=[];for(const Kr of ur){const wr=Kr.x,Bi=Kr.y,ea=tt[0]*wr+tt[4]*Bi+tt[12],No=tt[1]*wr+tt[5]*Bi+tt[13],Xa=tt[2]*wr+tt[6]*Bi+tt[14],Lu=tt[3]*wr+tt[7]*Bi+tt[15],Kl=Xa+an,ka=Lu+Vn,Go=ea+cr,Ja=No+xn,Xl=Xa+Cn,Jl=Lu+Kn,ks=new B((ea+vt)/ka,(No+tn)/ka);ks.z=Kl/ka,Dn.push(ks);const Is=new B(Go/Jl,Ja/Jl);Is.z=Xl/Jl,wn.push(Is)}St.push(Dn),lt.push(wn)}return[St,lt]}(w,le,ie,z);return function(Be,ze,$e){let tt=1/0;Nd($e,ze)&&(tt=i0($e,ze[0]));for(let St=0;St<ze.length;St++){const lt=ze[St],vt=Be[St];for(let tn=0;tn<lt.length-1;tn++){const an=lt[tn],Vn=[an,lt[tn+1],vt[tn+1],vt[tn],an];Wd($e,Vn)&&(tt=Math.min(tt,i0($e,Vn)))}}return tt!==1/0&&tt}(Oe[0],Oe[1],ge)}}function Uu(c,l){return c.x*l.x+c.y*l.y}function i0(c,l){if(c.length===1){let d=0;const y=l[d++];let w;for(;!w||y.equals(w);)if(w=l[d++],!w)return 1/0;for(;d<l.length;d++){const T=l[d],K=c[0],D=w.sub(y),z=T.sub(y),Q=K.sub(y),ie=Uu(D,D),le=Uu(D,z),ge=Uu(z,z),Oe=Uu(Q,D),Be=Uu(Q,z),ze=ie*ge-le*le,$e=(ge*Oe-le*Be)/ze,tt=(ie*Be-le*Oe)/ze,St=y.z*(1-$e-tt)+w.z*$e+T.z*tt;if(isFinite(St))return St}return 1/0}{let d=1/0;for(const y of l)d=Math.min(d,y.z);return d}}const Es=zo([{name:"a_pos_normal",components:2,type:"Int16"},{name:"a_data",components:4,type:"Uint8"}],4),{members:iv}=Es,Ua=zo([{name:"a_uv_x",components:1,type:"Float32"},{name:"a_split_index",components:1,type:"Float32"}]),{members:L1}=Ua,ov=FA.VectorTileFeature.types,z1=Math.cos(Math.PI/180*37.5),Qf=Math.pow(2,14)/.5;class A{constructor(l){this.zoom=l.zoom,this.overscaling=l.overscaling,this.layers=l.layers,this.layerIds=this.layers.map(d=>d.id),this.index=l.index,this.hasPattern=!1,this.patternFeatures=[],this.lineClipsArray=[],this.gradients={},this.layers.forEach(d=>{this.gradients[d.id]={}}),this.layoutVertexArray=new Le,this.layoutVertexArray2=new ft,this.indexArray=new hn,this.programConfigurations=new ua(l.layers,l.zoom),this.segments=new xr,this.maxLineLength=0,this.stateDependentLayerIds=this.layers.filter(d=>d.isStateDependent()).map(d=>d.id)}populate(l,d,y){this.hasPattern=Pp("line",this.layers,d);const w=this.layers[0].layout.get("line-sort-key"),T=!w.isConstant(),K=[];for(const{feature:D,id:z,index:Q,sourceLayerIndex:ie}of l){const le=this.layers[0]._featureFilter.needGeometry,ge=hl(D,le);if(!this.layers[0]._featureFilter.filter(new go(this.zoom),ge,y))continue;const Oe=T?w.evaluate(ge,{},y):void 0,Be={id:z,properties:D.properties,type:D.type,sourceLayerIndex:ie,index:Q,geometry:le?ge.geometry:EA(D),patterns:{},sortKey:Oe};K.push(Be)}T&&K.sort((D,z)=>D.sortKey-z.sortKey);for(const D of K){const{geometry:z,index:Q,sourceLayerIndex:ie}=D;if(this.hasPattern){const le=Rh("line",this.layers,D,this.zoom,d);this.patternFeatures.push(le)}else this.addFeature(D,z,Q,y,{});d.featureIndex.insert(l[Q].feature,z,Q,ie,this.index)}}update(l,d,y){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(l,d,this.stateDependentLayers,y)}addFeatures(l,d,y){for(const w of this.patternFeatures)this.addFeature(w,w.geometry,w.index,d,y)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(l){this.uploaded||(this.layoutVertexArray2.length!==0&&(this.layoutVertexBuffer2=l.createVertexBuffer(this.layoutVertexArray2,L1)),this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,iv),this.indexBuffer=l.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(l),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}lineFeatureClips(l){if(l.properties&&Object.prototype.hasOwnProperty.call(l.properties,"mapbox_clip_start")&&Object.prototype.hasOwnProperty.call(l.properties,"mapbox_clip_end"))return{start:+l.properties.mapbox_clip_start,end:+l.properties.mapbox_clip_end}}addFeature(l,d,y,w,T){const K=this.layers[0].layout,D=K.get("line-join").evaluate(l,{}),z=K.get("line-cap"),Q=K.get("line-miter-limit"),ie=K.get("line-round-limit");this.lineClips=this.lineFeatureClips(l);for(const le of d)this.addLine(le,l,D,z,Q,ie);this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,l,y,T,w)}addLine(l,d,y,w,T,K){if(this.distance=0,this.scaledDistance=0,this.totalDistance=0,this.lineClips){this.lineClipsArray.push(this.lineClips);for(let tt=0;tt<l.length-1;tt++)this.totalDistance+=l[tt].dist(l[tt+1]);this.updateScaledDistance(),this.maxLineLength=Math.max(this.maxLineLength,this.totalDistance)}const D=ov[d.type]==="Polygon";let z=l.length;for(;z>=2&&l[z-1].equals(l[z-2]);)z--;let Q=0;for(;Q<z-1&&l[Q].equals(l[Q+1]);)Q++;if(z<(D?3:2))return;y==="bevel"&&(T=1.05);const ie=this.overscaling<=16?15*Wo/(512*this.overscaling):0,le=this.segments.prepareSegment(10*z,this.layoutVertexArray,this.indexArray);let ge,Oe,Be,ze,$e;this.e1=this.e2=-1,D&&(ge=l[z-2],$e=l[Q].sub(ge)._unit()._perp());for(let tt=Q;tt<z;tt++){if(Be=tt===z-1?D?l[Q+1]:void 0:l[tt+1],Be&&l[tt].equals(Be))continue;$e&&(ze=$e),ge&&(Oe=ge),ge=l[tt],$e=Be?Be.sub(ge)._unit()._perp():ze,ze=ze||$e;let St=ze.add($e);St.x===0&&St.y===0||St._unit();const lt=ze.x*$e.x+ze.y*$e.y,vt=St.x*$e.x+St.y*$e.y,tn=vt!==0?1/vt:1/0,an=2*Math.sqrt(2-2*vt),Vn=vt<z1&&Oe&&Be,cr=ze.x*$e.y-ze.y*$e.x>0;if(Vn&&tt>Q){const Kn=ge.dist(Oe);if(Kn>2*ie){const ur=ge.sub(ge.sub(Oe)._mult(ie/Kn)._round());this.updateDistance(Oe,ur),this.addCurrentVertex(ur,ze,0,0,le),Oe=ur}}const xn=Oe&&Be;let Cn=xn?y:D?"butt":w;if(xn&&Cn==="round"&&(tn<K?Cn="miter":tn<=2&&(Cn="fakeround")),Cn==="miter"&&tn>T&&(Cn="bevel"),Cn==="bevel"&&(tn>2&&(Cn="flipbevel"),tn<T&&(Cn="miter")),Oe&&this.updateDistance(Oe,ge),Cn==="miter")St._mult(tn),this.addCurrentVertex(ge,St,0,0,le);else if(Cn==="flipbevel"){if(tn>100)St=$e.mult(-1);else{const Kn=tn*ze.add($e).mag()/ze.sub($e).mag();St._perp()._mult(Kn*(cr?-1:1))}this.addCurrentVertex(ge,St,0,0,le),this.addCurrentVertex(ge,St.mult(-1),0,0,le)}else if(Cn==="bevel"||Cn==="fakeround"){const Kn=-Math.sqrt(tn*tn-1),ur=cr?Kn:0,Dn=cr?0:Kn;if(Oe&&this.addCurrentVertex(ge,ze,ur,Dn,le),Cn==="fakeround"){const wn=Math.round(180*an/Math.PI/20);for(let Kr=1;Kr<wn;Kr++){let wr=Kr/wn;if(wr!==.5){const ea=wr-.5;wr+=wr*ea*(wr-1)*((1.0904+lt*(lt*(3.55645-1.43519*lt)-3.2452))*ea*ea+(.848013+lt*(.215638*lt-1.06021)))}const Bi=$e.sub(ze)._mult(wr)._add(ze)._unit()._mult(cr?-1:1);this.addHalfVertex(ge,Bi.x,Bi.y,!1,cr,0,le)}}Be&&this.addCurrentVertex(ge,$e,-ur,-Dn,le)}else if(Cn==="butt")this.addCurrentVertex(ge,St,0,0,le);else if(Cn==="square"){const Kn=Oe?1:-1;this.addCurrentVertex(ge,St,Kn,Kn,le)}else Cn==="round"&&(Oe&&(this.addCurrentVertex(ge,ze,0,0,le),this.addCurrentVertex(ge,ze,1,1,le,!0)),Be&&(this.addCurrentVertex(ge,$e,-1,-1,le,!0),this.addCurrentVertex(ge,$e,0,0,le)));if(Vn&&tt<z-1){const Kn=ge.dist(Be);if(Kn>2*ie){const ur=ge.add(Be.sub(ge)._mult(ie/Kn)._round());this.updateDistance(ge,ur),this.addCurrentVertex(ur,$e,0,0,le),ge=ur}}}}addCurrentVertex(l,d,y,w,T,K=!1){const D=d.y*w-d.x,z=-d.y-d.x*w;this.addHalfVertex(l,d.x+d.y*y,d.y-d.x*y,K,!1,y,T),this.addHalfVertex(l,D,z,K,!0,-w,T),this.distance>Qf/2&&this.totalDistance===0&&(this.distance=0,this.updateScaledDistance(),this.addCurrentVertex(l,d,y,w,T,K))}addHalfVertex({x:l,y:d},y,w,T,K,D,z){const Q=.5*(this.lineClips?this.scaledDistance*(Qf-1):this.scaledDistance);this.layoutVertexArray.emplaceBack((l<<1)+(T?1:0),(d<<1)+(K?1:0),Math.round(63*y)+128,Math.round(63*w)+128,1+(D===0?0:D<0?-1:1)|(63&Q)<<2,Q>>6),this.lineClips&&this.layoutVertexArray2.emplaceBack((this.scaledDistance-this.lineClips.start)/(this.lineClips.end-this.lineClips.start),this.lineClipsArray.length);const ie=z.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,this.e2,ie),z.primitiveLength++),K?this.e2=ie:this.e1=ie}updateScaledDistance(){this.scaledDistance=this.lineClips?this.lineClips.start+(this.lineClips.end-this.lineClips.start)*this.distance/this.totalDistance:this.distance}updateDistance(l,d){this.distance+=l.dist(d),this.updateScaledDistance()}}let h,b;jn("LineBucket",A,{omit:["layers","patternFeatures"]});var _={get paint(){return b=b||new xa({"line-opacity":new Or(mt.paint_line["line-opacity"]),"line-color":new Or(mt.paint_line["line-color"]),"line-translate":new gr(mt.paint_line["line-translate"]),"line-translate-anchor":new gr(mt.paint_line["line-translate-anchor"]),"line-width":new Or(mt.paint_line["line-width"]),"line-gap-width":new Or(mt.paint_line["line-gap-width"]),"line-offset":new Or(mt.paint_line["line-offset"]),"line-blur":new Or(mt.paint_line["line-blur"]),"line-dasharray":new Jc(mt.paint_line["line-dasharray"]),"line-pattern":new SA(mt.paint_line["line-pattern"]),"line-gradient":new dl(mt.paint_line["line-gradient"])})},get layout(){return h=h||new xa({"line-cap":new gr(mt.layout_line["line-cap"]),"line-join":new Or(mt.layout_line["line-join"]),"line-miter-limit":new gr(mt.layout_line["line-miter-limit"]),"line-round-limit":new gr(mt.layout_line["line-round-limit"]),"line-sort-key":new Or(mt.layout_line["line-sort-key"])})}};class E extends Or{possiblyEvaluate(l,d){return d=new go(Math.floor(d.zoom),{now:d.now,fadeDuration:d.fadeDuration,zoomHistory:d.zoomHistory,transition:d.transition}),super.possiblyEvaluate(l,d)}evaluate(l,d,y,w){return d=ye({},d,{zoom:Math.floor(d.zoom)}),super.evaluate(l,d,y,w)}}let U;class Y extends As{constructor(l){super(l,_),this.gradientVersion=0,U||(U=new E(_.paint.properties["line-width"].specification),U.useIntegerZoom=!0)}_handleSpecialPaintPropertyUpdate(l){if(l==="line-gradient"){const d=this.gradientExpression();this.stepInterpolant=!!function(y){return y._styleExpression!==void 0}(d)&&d._styleExpression.expression instanceof Au,this.gradientVersion=(this.gradientVersion+1)%Number.MAX_SAFE_INTEGER}}gradientExpression(){return this._transitionablePaint._values["line-gradient"].value.expression}recalculate(l,d){super.recalculate(l,d),this.paint._values["line-floorwidth"]=U.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,l)}createBucket(l){return new A(l)}queryRadius(l){const d=l,y=J(Gd("line-width",this,d),Gd("line-gap-width",this,d)),w=Gd("line-offset",this,d);return y/2+Math.abs(w)+Zl(this.paint.get("line-translate"))}queryIntersectsFeature(l,d,y,w,T,K,D){const z=mc(l,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),K.angle,D),Q=D/2*J(this.paint.get("line-width").evaluate(d,y),this.paint.get("line-gap-width").evaluate(d,y)),ie=this.paint.get("line-offset").evaluate(d,y);return ie&&(w=function(le,ge){const Oe=[];for(let Be=0;Be<le.length;Be++){const ze=le[Be],$e=[];for(let tt=0;tt<ze.length;tt++){const St=ze[tt-1],lt=ze[tt],vt=ze[tt+1],tn=tt===0?new B(0,0):lt.sub(St)._unit()._perp(),an=tt===ze.length-1?new B(0,0):vt.sub(lt)._unit()._perp(),Vn=tn._add(an)._unit(),cr=Vn.x*an.x+Vn.y*an.y;cr!==0&&Vn._mult(1/cr),$e.push(Vn._mult(ge)._add(lt))}Oe.push($e)}return Oe}(w,ie*D)),function(le,ge,Oe){for(let Be=0;Be<ge.length;Be++){const ze=ge[Be];if(le.length>=3){for(let $e=0;$e<ze.length;$e++)if(rd(le,ze[$e]))return!0}if(Tf(le,ze,Oe))return!0}return!1}(z,w,Q)}isTileClipped(){return!0}}function J(c,l){return l>0?l+2*c:c}const se=zo([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"}],4),pe=zo([{name:"a_projected_pos",components:3,type:"Float32"}],4);zo([{name:"a_fade_opacity",components:1,type:"Uint32"}],4);const We=zo([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"}]);zo([{type:"Int16",name:"anchorPointX"},{type:"Int16",name:"anchorPointY"},{type:"Int16",name:"x1"},{type:"Int16",name:"y1"},{type:"Int16",name:"x2"},{type:"Int16",name:"y2"},{type:"Uint32",name:"featureIndex"},{type:"Uint16",name:"sourceLayerIndex"},{type:"Uint16",name:"bucketIndex"}]);const Ye=zo([{name:"a_pos",components:2,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4),Mt=zo([{name:"a_pos",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);function yt(c,l,d){return c.sections.forEach(y=>{y.text=function(w,T,K){const D=T.layout.get("text-transform").evaluate(K,{});return D==="uppercase"?w=w.toLocaleUpperCase():D==="lowercase"&&(w=w.toLocaleLowerCase()),Hl.applyArabicShaping&&(w=Hl.applyArabicShaping(w)),w}(y.text,l,d)}),c}zo([{name:"triangle",components:3,type:"Uint16"}]),zo([{type:"Int16",name:"anchorX"},{type:"Int16",name:"anchorY"},{type:"Uint16",name:"glyphStartIndex"},{type:"Uint16",name:"numGlyphs"},{type:"Uint32",name:"vertexStartIndex"},{type:"Uint32",name:"lineStartIndex"},{type:"Uint32",name:"lineLength"},{type:"Uint16",name:"segment"},{type:"Uint16",name:"lowerSize"},{type:"Uint16",name:"upperSize"},{type:"Float32",name:"lineOffsetX"},{type:"Float32",name:"lineOffsetY"},{type:"Uint8",name:"writingMode"},{type:"Uint8",name:"placedOrientation"},{type:"Uint8",name:"hidden"},{type:"Uint32",name:"crossTileID"},{type:"Int16",name:"associatedIconIndex"}]),zo([{type:"Int16",name:"anchorX"},{type:"Int16",name:"anchorY"},{type:"Int16",name:"rightJustifiedTextSymbolIndex"},{type:"Int16",name:"centerJustifiedTextSymbolIndex"},{type:"Int16",name:"leftJustifiedTextSymbolIndex"},{type:"Int16",name:"verticalPlacedTextSymbolIndex"},{type:"Int16",name:"placedIconSymbolIndex"},{type:"Int16",name:"verticalPlacedIconSymbolIndex"},{type:"Uint16",name:"key"},{type:"Uint16",name:"textBoxStartIndex"},{type:"Uint16",name:"textBoxEndIndex"},{type:"Uint16",name:"verticalTextBoxStartIndex"},{type:"Uint16",name:"verticalTextBoxEndIndex"},{type:"Uint16",name:"iconBoxStartIndex"},{type:"Uint16",name:"iconBoxEndIndex"},{type:"Uint16",name:"verticalIconBoxStartIndex"},{type:"Uint16",name:"verticalIconBoxEndIndex"},{type:"Uint16",name:"featureIndex"},{type:"Uint16",name:"numHorizontalGlyphVertices"},{type:"Uint16",name:"numVerticalGlyphVertices"},{type:"Uint16",name:"numIconVertices"},{type:"Uint16",name:"numVerticalIconVertices"},{type:"Uint16",name:"useRuntimeCollisionCircles"},{type:"Uint32",name:"crossTileID"},{type:"Float32",name:"textBoxScale"},{type:"Float32",name:"collisionCircleDiameter"},{type:"Uint16",name:"textAnchorOffsetStartIndex"},{type:"Uint16",name:"textAnchorOffsetEndIndex"}]),zo([{type:"Float32",name:"offsetX"}]),zo([{type:"Int16",name:"x"},{type:"Int16",name:"y"},{type:"Int16",name:"tileUnitDistanceFromAnchor"}]),zo([{type:"Uint16",name:"textAnchor"},{type:"Float32",components:2,name:"textOffset"}]);const qt={"!":"︕","#":"#",$:"$","%":"%","&":"&","(":"︵",")":"︶","*":"*","+":"+",",":"︐","-":"︲",".":"・","/":"/",":":"︓",";":"︔","<":"︿","=":"=",">":"﹀","?":"︖","@":"@","[":"﹇","\\":"\","]":"﹈","^":"^",_:"︳","`":"`","{":"︷","|":"―","}":"︸","~":"~","¢":"¢","£":"£","¥":"¥","¦":"¦","¬":"¬","¯":" ̄","–":"︲","—":"︱","‘":"﹃","’":"﹄","“":"﹁","”":"﹂","…":"︙","‧":"・","₩":"₩","、":"︑","。":"︒","〈":"︿","〉":"﹀","《":"︽","》":"︾","「":"﹁","」":"﹂","『":"﹃","』":"﹄","【":"︻","】":"︼","〔":"︹","〕":"︺","〖":"︗","〗":"︘","!":"︕","(":"︵",")":"︶",",":"︐","-":"︲",".":"・",":":"︓",";":"︔","<":"︿",">":"﹀","?":"︖","[":"﹇","]":"﹈","_":"︳","{":"︷","|":"―","}":"︸","⦅":"︵","⦆":"︶","。":"︒","「":"﹁","」":"﹂"};var Zt=24,Bn=fn,Wn=function(c,l,d,y,w){var T,K,D=8*w-y-1,z=(1<<D)-1,Q=z>>1,ie=-7,le=d?w-1:0,ge=d?-1:1,Oe=c[l+le];for(le+=ge,T=Oe&(1<<-ie)-1,Oe>>=-ie,ie+=D;ie>0;T=256*T+c[l+le],le+=ge,ie-=8);for(K=T&(1<<-ie)-1,T>>=-ie,ie+=y;ie>0;K=256*K+c[l+le],le+=ge,ie-=8);if(T===0)T=1-Q;else{if(T===z)return K?NaN:1/0*(Oe?-1:1);K+=Math.pow(2,y),T-=Q}return(Oe?-1:1)*K*Math.pow(2,T-y)},er=function(c,l,d,y,w,T){var K,D,z,Q=8*T-w-1,ie=(1<<Q)-1,le=ie>>1,ge=w===23?Math.pow(2,-24)-Math.pow(2,-77):0,Oe=y?0:T-1,Be=y?1:-1,ze=l<0||l===0&&1/l<0?1:0;for(l=Math.abs(l),isNaN(l)||l===1/0?(D=isNaN(l)?1:0,K=ie):(K=Math.floor(Math.log(l)/Math.LN2),l*(z=Math.pow(2,-K))<1&&(K--,z*=2),(l+=K+le>=1?ge/z:ge*Math.pow(2,1-le))*z>=2&&(K++,z/=2),K+le>=ie?(D=0,K=ie):K+le>=1?(D=(l*z-1)*Math.pow(2,w),K+=le):(D=l*Math.pow(2,le-1)*Math.pow(2,w),K=0));w>=8;c[d+Oe]=255&D,Oe+=Be,D/=256,w-=8);for(K=K<<w|D,Q+=w;Q>0;c[d+Oe]=255&K,Oe+=Be,K/=256,Q-=8);c[d+Oe-Be]|=128*ze};function fn(c){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(c)?c:new Uint8Array(c||0),this.pos=0,this.type=0,this.length=this.buf.length}fn.Varint=0,fn.Fixed64=1,fn.Bytes=2,fn.Fixed32=5;var ar=4294967296,Ir=1/ar,Br=typeof TextDecoder>"u"?null:new TextDecoder("utf8");function Xr(c){return c.type===fn.Bytes?c.readVarint()+c.pos:c.pos+1}function fo(c,l,d){return d?4294967296*l+(c>>>0):4294967296*(l>>>0)+(c>>>0)}function Ea(c,l,d){var y=l<=16383?1:l<=2097151?2:l<=268435455?3:Math.floor(Math.log(l)/(7*Math.LN2));d.realloc(y);for(var w=d.pos-1;w>=c;w--)d.buf[w+y]=d.buf[w]}function ca(c,l){for(var d=0;d<c.length;d++)l.writeVarint(c[d])}function Oa(c,l){for(var d=0;d<c.length;d++)l.writeSVarint(c[d])}function Va(c,l){for(var d=0;d<c.length;d++)l.writeFloat(c[d])}function Ha(c,l){for(var d=0;d<c.length;d++)l.writeDouble(c[d])}function fl(c,l){for(var d=0;d<c.length;d++)l.writeBoolean(c[d])}function zs(c,l){for(var d=0;d<c.length;d++)l.writeFixed32(c[d])}function ds(c,l){for(var d=0;d<c.length;d++)l.writeSFixed32(c[d])}function Za(c,l){for(var d=0;d<c.length;d++)l.writeFixed64(c[d])}function Ba(c,l){for(var d=0;d<c.length;d++)l.writeSFixed64(c[d])}function js(c,l){return(c[l]|c[l+1]<<8|c[l+2]<<16)+16777216*c[l+3]}function sA(c,l,d){c[d]=l,c[d+1]=l>>>8,c[d+2]=l>>>16,c[d+3]=l>>>24}function bc(c,l){return(c[l]|c[l+1]<<8|c[l+2]<<16)+(c[l+3]<<24)}fn.prototype={destroy:function(){this.buf=null},readFields:function(c,l,d){for(d=d||this.length;this.pos<d;){var y=this.readVarint(),w=y>>3,T=this.pos;this.type=7&y,c(w,l,this),this.pos===T&&this.skip(y)}return l},readMessage:function(c,l){return this.readFields(c,l,this.readVarint()+this.pos)},readFixed32:function(){var c=js(this.buf,this.pos);return this.pos+=4,c},readSFixed32:function(){var c=bc(this.buf,this.pos);return this.pos+=4,c},readFixed64:function(){var c=js(this.buf,this.pos)+js(this.buf,this.pos+4)*ar;return this.pos+=8,c},readSFixed64:function(){var c=js(this.buf,this.pos)+bc(this.buf,this.pos+4)*ar;return this.pos+=8,c},readFloat:function(){var c=Wn(this.buf,this.pos,!0,23,4);return this.pos+=4,c},readDouble:function(){var c=Wn(this.buf,this.pos,!0,52,8);return this.pos+=8,c},readVarint:function(c){var l,d,y=this.buf;return l=127&(d=y[this.pos++]),d<128?l:(l|=(127&(d=y[this.pos++]))<<7,d<128?l:(l|=(127&(d=y[this.pos++]))<<14,d<128?l:(l|=(127&(d=y[this.pos++]))<<21,d<128?l:function(w,T,K){var D,z,Q=K.buf;if(D=(112&(z=Q[K.pos++]))>>4,z<128||(D|=(127&(z=Q[K.pos++]))<<3,z<128)||(D|=(127&(z=Q[K.pos++]))<<10,z<128)||(D|=(127&(z=Q[K.pos++]))<<17,z<128)||(D|=(127&(z=Q[K.pos++]))<<24,z<128)||(D|=(1&(z=Q[K.pos++]))<<31,z<128))return fo(w,D,T);throw new Error("Expected varint not more than 10 bytes")}(l|=(15&(d=y[this.pos]))<<28,c,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var c=this.readVarint();return c%2==1?(c+1)/-2:c/2},readBoolean:function(){return!!this.readVarint()},readString:function(){var c=this.readVarint()+this.pos,l=this.pos;return this.pos=c,c-l>=12&&Br?function(d,y,w){return Br.decode(d.subarray(y,w))}(this.buf,l,c):function(d,y,w){for(var T="",K=y;K<w;){var D,z,Q,ie=d[K],le=null,ge=ie>239?4:ie>223?3:ie>191?2:1;if(K+ge>w)break;ge===1?ie<128&&(le=ie):ge===2?(192&(D=d[K+1]))==128&&(le=(31&ie)<<6|63&D)<=127&&(le=null):ge===3?(z=d[K+2],(192&(D=d[K+1]))==128&&(192&z)==128&&((le=(15&ie)<<12|(63&D)<<6|63&z)<=2047||le>=55296&&le<=57343)&&(le=null)):ge===4&&(z=d[K+2],Q=d[K+3],(192&(D=d[K+1]))==128&&(192&z)==128&&(192&Q)==128&&((le=(15&ie)<<18|(63&D)<<12|(63&z)<<6|63&Q)<=65535||le>=1114112)&&(le=null)),le===null?(le=65533,ge=1):le>65535&&(le-=65536,T+=String.fromCharCode(le>>>10&1023|55296),le=56320|1023&le),T+=String.fromCharCode(le),K+=ge}return T}(this.buf,l,c)},readBytes:function(){var c=this.readVarint()+this.pos,l=this.buf.subarray(this.pos,c);return this.pos=c,l},readPackedVarint:function(c,l){if(this.type!==fn.Bytes)return c.push(this.readVarint(l));var d=Xr(this);for(c=c||[];this.pos<d;)c.push(this.readVarint(l));return c},readPackedSVarint:function(c){if(this.type!==fn.Bytes)return c.push(this.readSVarint());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readSVarint());return c},readPackedBoolean:function(c){if(this.type!==fn.Bytes)return c.push(this.readBoolean());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readBoolean());return c},readPackedFloat:function(c){if(this.type!==fn.Bytes)return c.push(this.readFloat());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readFloat());return c},readPackedDouble:function(c){if(this.type!==fn.Bytes)return c.push(this.readDouble());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readDouble());return c},readPackedFixed32:function(c){if(this.type!==fn.Bytes)return c.push(this.readFixed32());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readFixed32());return c},readPackedSFixed32:function(c){if(this.type!==fn.Bytes)return c.push(this.readSFixed32());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readSFixed32());return c},readPackedFixed64:function(c){if(this.type!==fn.Bytes)return c.push(this.readFixed64());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readFixed64());return c},readPackedSFixed64:function(c){if(this.type!==fn.Bytes)return c.push(this.readSFixed64());var l=Xr(this);for(c=c||[];this.pos<l;)c.push(this.readSFixed64());return c},skip:function(c){var l=7&c;if(l===fn.Varint)for(;this.buf[this.pos++]>127;);else if(l===fn.Bytes)this.pos=this.readVarint()+this.pos;else if(l===fn.Fixed32)this.pos+=4;else{if(l!==fn.Fixed64)throw new Error("Unimplemented type: "+l);this.pos+=8}},writeTag:function(c,l){this.writeVarint(c<<3|l)},realloc:function(c){for(var l=this.length||16;l<this.pos+c;)l*=2;if(l!==this.length){var d=new Uint8Array(l);d.set(this.buf),this.buf=d,this.length=l}},finish:function(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)},writeFixed32:function(c){this.realloc(4),sA(this.buf,c,this.pos),this.pos+=4},writeSFixed32:function(c){this.realloc(4),sA(this.buf,c,this.pos),this.pos+=4},writeFixed64:function(c){this.realloc(8),sA(this.buf,-1&c,this.pos),sA(this.buf,Math.floor(c*Ir),this.pos+4),this.pos+=8},writeSFixed64:function(c){this.realloc(8),sA(this.buf,-1&c,this.pos),sA(this.buf,Math.floor(c*Ir),this.pos+4),this.pos+=8},writeVarint:function(c){(c=+c||0)>268435455||c<0?function(l,d){var y,w;if(l>=0?(y=l%4294967296|0,w=l/4294967296|0):(w=~(-l/4294967296),4294967295^(y=~(-l%4294967296))?y=y+1|0:(y=0,w=w+1|0)),l>=18446744073709552e3||l<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");d.realloc(10),function(T,K,D){D.buf[D.pos++]=127&T|128,T>>>=7,D.buf[D.pos++]=127&T|128,T>>>=7,D.buf[D.pos++]=127&T|128,T>>>=7,D.buf[D.pos++]=127&T|128,D.buf[D.pos]=127&(T>>>=7)}(y,0,d),function(T,K){var D=(7&T)<<4;K.buf[K.pos++]|=D|((T>>>=3)?128:0),T&&(K.buf[K.pos++]=127&T|((T>>>=7)?128:0),T&&(K.buf[K.pos++]=127&T|((T>>>=7)?128:0),T&&(K.buf[K.pos++]=127&T|((T>>>=7)?128:0),T&&(K.buf[K.pos++]=127&T|((T>>>=7)?128:0),T&&(K.buf[K.pos++]=127&T)))))}(w,d)}(c,this):(this.realloc(4),this.buf[this.pos++]=127&c|(c>127?128:0),c<=127||(this.buf[this.pos++]=127&(c>>>=7)|(c>127?128:0),c<=127||(this.buf[this.pos++]=127&(c>>>=7)|(c>127?128:0),c<=127||(this.buf[this.pos++]=c>>>7&127))))},writeSVarint:function(c){this.writeVarint(c<0?2*-c-1:2*c)},writeBoolean:function(c){this.writeVarint(!!c)},writeString:function(c){c=String(c),this.realloc(4*c.length),this.pos++;var l=this.pos;this.pos=function(y,w,T){for(var K,D,z=0;z<w.length;z++){if((K=w.charCodeAt(z))>55295&&K<57344){if(!D){K>56319||z+1===w.length?(y[T++]=239,y[T++]=191,y[T++]=189):D=K;continue}if(K<56320){y[T++]=239,y[T++]=191,y[T++]=189,D=K;continue}K=D-55296<<10|K-56320|65536,D=null}else D&&(y[T++]=239,y[T++]=191,y[T++]=189,D=null);K<128?y[T++]=K:(K<2048?y[T++]=K>>6|192:(K<65536?y[T++]=K>>12|224:(y[T++]=K>>18|240,y[T++]=K>>12&63|128),y[T++]=K>>6&63|128),y[T++]=63&K|128)}return T}(this.buf,c,this.pos);var d=this.pos-l;d>=128&&Ea(l,d,this),this.pos=l-1,this.writeVarint(d),this.pos+=d},writeFloat:function(c){this.realloc(4),er(this.buf,c,this.pos,!0,23,4),this.pos+=4},writeDouble:function(c){this.realloc(8),er(this.buf,c,this.pos,!0,52,8),this.pos+=8},writeBytes:function(c){var l=c.length;this.writeVarint(l),this.realloc(l);for(var d=0;d<l;d++)this.buf[this.pos++]=c[d]},writeRawMessage:function(c,l){this.pos++;var d=this.pos;c(l,this);var y=this.pos-d;y>=128&&Ea(d,y,this),this.pos=d-1,this.writeVarint(y),this.pos+=y},writeMessage:function(c,l,d){this.writeTag(c,fn.Bytes),this.writeRawMessage(l,d)},writePackedVarint:function(c,l){l.length&&this.writeMessage(c,ca,l)},writePackedSVarint:function(c,l){l.length&&this.writeMessage(c,Oa,l)},writePackedBoolean:function(c,l){l.length&&this.writeMessage(c,fl,l)},writePackedFloat:function(c,l){l.length&&this.writeMessage(c,Va,l)},writePackedDouble:function(c,l){l.length&&this.writeMessage(c,Ha,l)},writePackedFixed32:function(c,l){l.length&&this.writeMessage(c,zs,l)},writePackedSFixed32:function(c,l){l.length&&this.writeMessage(c,ds,l)},writePackedFixed64:function(c,l){l.length&&this.writeMessage(c,Za,l)},writePackedSFixed64:function(c,l){l.length&&this.writeMessage(c,Ba,l)},writeBytesField:function(c,l){this.writeTag(c,fn.Bytes),this.writeBytes(l)},writeFixed32Field:function(c,l){this.writeTag(c,fn.Fixed32),this.writeFixed32(l)},writeSFixed32Field:function(c,l){this.writeTag(c,fn.Fixed32),this.writeSFixed32(l)},writeFixed64Field:function(c,l){this.writeTag(c,fn.Fixed64),this.writeFixed64(l)},writeSFixed64Field:function(c,l){this.writeTag(c,fn.Fixed64),this.writeSFixed64(l)},writeVarintField:function(c,l){this.writeTag(c,fn.Varint),this.writeVarint(l)},writeSVarintField:function(c,l){this.writeTag(c,fn.Varint),this.writeSVarint(l)},writeStringField:function(c,l){this.writeTag(c,fn.Bytes),this.writeString(l)},writeFloatField:function(c,l){this.writeTag(c,fn.Fixed32),this.writeFloat(l)},writeDoubleField:function(c,l){this.writeTag(c,fn.Fixed64),this.writeDouble(l)},writeBooleanField:function(c,l){this.writeVarintField(c,!!l)}};var Os=g(Bn);const Ru=3;function Bs(c,l,d){c===1&&d.readMessage(o0,l)}function o0(c,l,d){if(c===3){const{id:y,bitmap:w,width:T,height:K,left:D,top:z,advance:Q}=d.readMessage(UA,{});l.push({id:y,bitmap:new gc({width:T+2*Ru,height:K+2*Ru},w),metrics:{width:T,height:K,left:D,top:z,advance:Q}})}}function UA(c,l,d){c===1?l.id=d.readVarint():c===2?l.bitmap=d.readBytes():c===3?l.width=d.readVarint():c===4?l.height=d.readVarint():c===5?l.left=d.readSVarint():c===6?l.top=d.readSVarint():c===7&&(l.advance=d.readVarint())}const xc=Ru;function wc(c){let l=0,d=0;for(const K of c)l+=K.w*K.h,d=Math.max(d,K.w);c.sort((K,D)=>D.h-K.h);const y=[{x:0,y:0,w:Math.max(Math.ceil(Math.sqrt(l/.95)),d),h:1/0}];let w=0,T=0;for(const K of c)for(let D=y.length-1;D>=0;D--){const z=y[D];if(!(K.w>z.w||K.h>z.h)){if(K.x=z.x,K.y=z.y,T=Math.max(T,K.y+K.h),w=Math.max(w,K.x+K.w),K.w===z.w&&K.h===z.h){const Q=y.pop();D<y.length&&(y[D]=Q)}else K.h===z.h?(z.x+=K.w,z.w-=K.w):K.w===z.w?(z.y+=K.h,z.h-=K.h):(y.push({x:z.x+K.w,y:z.y,w:z.w-K.w,h:K.h}),z.y+=K.h,z.h-=K.h);break}}return{w,h:T,fill:l/(w*T)||0}}const To=1;class cd{constructor(l,{pixelRatio:d,version:y,stretchX:w,stretchY:T,content:K}){this.paddedRect=l,this.pixelRatio=d,this.stretchX=w,this.stretchY=T,this.content=K,this.version=y}get tl(){return[this.paddedRect.x+To,this.paddedRect.y+To]}get br(){return[this.paddedRect.x+this.paddedRect.w-To,this.paddedRect.y+this.paddedRect.h-To]}get tlbr(){return this.tl.concat(this.br)}get displaySize(){return[(this.paddedRect.w-2*To)/this.pixelRatio,(this.paddedRect.h-2*To)/this.pixelRatio]}}class Lp{constructor(l,d){const y={},w={};this.haveRenderCallbacks=[];const T=[];this.addImages(l,y,T),this.addImages(d,w,T);const{w:K,h:D}=wc(T),z=new Ss({width:K||1,height:D||1});for(const Q in l){const ie=l[Q],le=y[Q].paddedRect;Ss.copy(ie.data,z,{x:0,y:0},{x:le.x+To,y:le.y+To},ie.data)}for(const Q in d){const ie=d[Q],le=w[Q].paddedRect,ge=le.x+To,Oe=le.y+To,Be=ie.data.width,ze=ie.data.height;Ss.copy(ie.data,z,{x:0,y:0},{x:ge,y:Oe},ie.data),Ss.copy(ie.data,z,{x:0,y:ze-1},{x:ge,y:Oe-1},{width:Be,height:1}),Ss.copy(ie.data,z,{x:0,y:0},{x:ge,y:Oe+ze},{width:Be,height:1}),Ss.copy(ie.data,z,{x:Be-1,y:0},{x:ge-1,y:Oe},{width:1,height:ze}),Ss.copy(ie.data,z,{x:0,y:0},{x:ge+Be,y:Oe},{width:1,height:ze})}this.image=z,this.iconPositions=y,this.patternPositions=w}addImages(l,d,y){for(const w in l){const T=l[w],K={x:0,y:0,w:T.data.width+2*To,h:T.data.height+2*To};y.push(K),d[w]=new cd(K,T),T.hasRenderCallback&&this.haveRenderCallbacks.push(w)}}patchUpdatedImages(l,d){l.dispatchRenderCallbacks(this.haveRenderCallbacks);for(const y in l.updatedImages)this.patchUpdatedImage(this.iconPositions[y],l.getImage(y),d),this.patchUpdatedImage(this.patternPositions[y],l.getImage(y),d)}patchUpdatedImage(l,d,y){if(!l||!d||l.version===d.version)return;l.version=d.version;const[w,T]=l.tl;y.update(d.data,void 0,{x:w,y:T})}}var Zd;jn("ImagePosition",cd),jn("ImageAtlas",Lp),a.ah=void 0,(Zd=a.ah||(a.ah={}))[Zd.none=0]="none",Zd[Zd.horizontal=1]="horizontal",Zd[Zd.vertical=2]="vertical",Zd[Zd.horizontalOnly=3]="horizontalOnly";const a0=-17;class s0{constructor(){this.scale=1,this.fontStack="",this.imageName=null}static forText(l,d){const y=new s0;return y.scale=l||1,y.fontStack=d,y}static forImage(l){const d=new s0;return d.imageName=l,d}}class zp{constructor(){this.text="",this.sectionIndex=[],this.sections=[],this.imageSectionID=null}static fromFeature(l,d){const y=new zp;for(let w=0;w<l.sections.length;w++){const T=l.sections[w];T.image?y.addImageSection(T):y.addTextSection(T,d)}return y}length(){return this.text.length}getSection(l){return this.sections[this.sectionIndex[l]]}getSectionIndex(l){return this.sectionIndex[l]}getCharCode(l){return this.text.charCodeAt(l)}verticalizePunctuation(){this.text=function(l){let d="";for(let y=0;y<l.length;y++){const w=l.charCodeAt(y+1)||null,T=l.charCodeAt(y-1)||null;d+=w&&lc(w)&&!qt[l[y+1]]||T&&lc(T)&&!qt[l[y-1]]||!qt[l[y]]?l[y]:qt[l[y]]}return d}(this.text)}trim(){let l=0;for(let y=0;y<this.text.length&&W1[this.text.charCodeAt(y)];y++)l++;let d=this.text.length;for(let y=this.text.length-1;y>=0&&y>=l&&W1[this.text.charCodeAt(y)];y--)d--;this.text=this.text.substring(l,d),this.sectionIndex=this.sectionIndex.slice(l,d)}substring(l,d){const y=new zp;return y.text=this.text.substring(l,d),y.sectionIndex=this.sectionIndex.slice(l,d),y.sections=this.sections,y}toString(){return this.text}getMaxScale(){return this.sectionIndex.reduce((l,d)=>Math.max(l,this.sections[d].scale),0)}addTextSection(l,d){this.text+=l.text,this.sections.push(s0.forText(l.scale,l.fontStack||d));const y=this.sections.length-1;for(let w=0;w<l.text.length;++w)this.sectionIndex.push(y)}addImageSection(l){const d=l.image?l.image.name:"";if(d.length===0)return void He("Can't add FormattedSection with an empty image.");const y=this.getNextImageSectionCharCode();y?(this.text+=String.fromCharCode(y),this.sections.push(s0.forImage(d)),this.sectionIndex.push(this.sections.length-1)):He("Reached maximum number of images 6401")}getNextImageSectionCharCode(){return this.imageSectionID?this.imageSectionID>=63743?null:++this.imageSectionID:(this.imageSectionID=57344,this.imageSectionID)}}function j1(c,l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze){const $e=zp.fromFeature(c,w);let tt;le===a.ah.vertical&&$e.verticalizePunctuation();const{processBidirectionalText:St,processStyledBidirectionalText:lt}=Hl;if(St&&$e.sections.length===1){tt=[];const an=St($e.toString(),sv($e,Q,T,l,y,Oe,Be));for(const Vn of an){const cr=new zp;cr.text=Vn,cr.sections=$e.sections;for(let xn=0;xn<Vn.length;xn++)cr.sectionIndex.push(0);tt.push(cr)}}else if(lt){tt=[];const an=lt($e.text,$e.sectionIndex,sv($e,Q,T,l,y,Oe,Be));for(const Vn of an){const cr=new zp;cr.text=Vn[0],cr.sectionIndex=Vn[1],cr.sections=$e.sections,tt.push(cr)}}else tt=function(an,Vn){const cr=[],xn=an.text;let Cn=0;for(const Kn of Vn)cr.push(an.substring(Cn,Kn)),Cn=Kn;return Cn<xn.length&&cr.push(an.substring(Cn,xn.length)),cr}($e,sv($e,Q,T,l,y,Oe,Be));const vt=[],tn={positionedLines:vt,text:$e.toString(),top:ie[1],bottom:ie[1],left:ie[0],right:ie[0],writingMode:le,iconsInText:!1,verticalizable:!1};return function(an,Vn,cr,xn,Cn,Kn,ur,Dn,wn,Kr,wr,Bi){let ea=0,No=a0,Xa=0,Lu=0;const Kl=Dn==="right"?1:Dn==="left"?0:.5;let ka=0;for(const ks of Cn){ks.trim();const Is=ks.getMaxScale(),Pl=(Is-1)*Zt,Fl={positionedGlyphs:[],lineOffset:0};an.positionedLines[ka]=Fl;const Ia=Fl.positionedGlyphs;let Hr=0;if(!ks.length()){No+=Kn,++ka;continue}for(let Ko=0;Ko<ks.length();Ko++){const Wi=ks.getSection(Ko),Dl=ks.getSectionIndex(Ko),mi=ks.getCharCode(Ko);let Ts=0,AA=null,zu=null,Mc=null,eh=Zt;const RA=!(wn===a.ah.horizontal||!wr&&!Vl(mi)||wr&&(W1[mi]||(Go=mi,Nn.Arabic(Go)||Nn["Arabic Supplement"](Go)||Nn["Arabic Extended-A"](Go)||Nn["Arabic Presentation Forms-A"](Go)||Nn["Arabic Presentation Forms-B"](Go))));if(Wi.imageName){const cA=xn[Wi.imageName];if(!cA)continue;Mc=Wi.imageName,an.iconsInText=an.iconsInText||!0,zu=cA.paddedRect;const gu=cA.displaySize;Wi.scale=Wi.scale*Zt/Bi,AA={width:gu[0],height:gu[1],left:To,top:-xc,advance:RA?gu[1]:gu[0]},Ts=Pl+(Zt-gu[1]*Wi.scale),eh=AA.advance;const th=RA?gu[0]*Wi.scale-Zt*Is:gu[1]*Wi.scale-Zt*Is;th>0&&th>Hr&&(Hr=th)}else{const cA=cr[Wi.fontStack],gu=cA&&cA[mi];if(gu&&gu.rect)zu=gu.rect,AA=gu.metrics;else{const th=Vn[Wi.fontStack],p0=th&&th[mi];if(!p0)continue;AA=p0.metrics}Ts=(Is-Wi.scale)*Zt}RA?(an.verticalizable=!0,Ia.push({glyph:mi,imageName:Mc,x:ea,y:No+Ts,vertical:RA,scale:Wi.scale,fontStack:Wi.fontStack,sectionIndex:Dl,metrics:AA,rect:zu}),ea+=eh*Wi.scale+Kr):(Ia.push({glyph:mi,imageName:Mc,x:ea,y:No+Ts,vertical:RA,scale:Wi.scale,fontStack:Wi.fontStack,sectionIndex:Dl,metrics:AA,rect:zu}),ea+=AA.advance*Wi.scale+Kr)}Ia.length!==0&&(Xa=Math.max(ea-Kr,Xa),tw(Ia,0,Ia.length-1,Kl,Hr)),ea=0;const eu=Kn*Is+Hr;Fl.lineOffset=Math.max(Hr,Pl),No+=eu,Lu=Math.max(eu,Lu),++ka}var Go;const Ja=No-a0,{horizontalAlign:Xl,verticalAlign:Jl}=lv(ur);(function(ks,Is,Pl,Fl,Ia,Hr,eu,Ko,Wi){const Dl=(Is-Pl)*Ia;let mi=0;mi=Hr!==eu?-Ko*Fl-a0:(-Fl*Wi+.5)*eu;for(const Ts of ks)for(const AA of Ts.positionedGlyphs)AA.x+=Dl,AA.y+=mi})(an.positionedLines,Kl,Xl,Jl,Xa,Lu,Kn,Ja,Cn.length),an.top+=-Jl*Ja,an.bottom=an.top+Ja,an.left+=-Xl*Xa,an.right=an.left+Xa}(tn,l,d,y,tt,K,D,z,le,Q,ge,ze),!function(an){for(const Vn of an)if(Vn.positionedGlyphs.length!==0)return!1;return!0}(vt)&&tn}const W1={9:!0,10:!0,11:!0,12:!0,13:!0,32:!0},J5={10:!0,32:!0,38:!0,40:!0,41:!0,43:!0,45:!0,47:!0,173:!0,183:!0,8203:!0,8208:!0,8211:!0,8231:!0};function lA(c,l,d,y,w,T){if(l.imageName){const K=y[l.imageName];return K?K.displaySize[0]*l.scale*Zt/T+w:0}{const K=d[l.fontStack],D=K&&K[c];return D?D.metrics.advance*l.scale+w:0}}function Mb(c,l,d,y){const w=Math.pow(c-l,2);return y?c<l?w/2:2*w:w+Math.abs(d)*d}function ew(c,l,d){let y=0;return c===10&&(y-=1e4),d&&(y+=150),c!==40&&c!==65288||(y+=50),l!==41&&l!==65289||(y+=50),y}function Sb(c,l,d,y,w,T){let K=null,D=Mb(l,d,w,T);for(const z of y){const Q=Mb(l-z.x,d,w,T)+z.badness;Q<=D&&(K=z,D=Q)}return{index:c,x:l,priorBreak:K,badness:D}}function av(c){return c?av(c.priorBreak).concat(c.index):[]}function sv(c,l,d,y,w,T,K){if(T!=="point")return[];if(!c)return[];const D=[],z=function(ge,Oe,Be,ze,$e,tt){let St=0;for(let lt=0;lt<ge.length();lt++){const vt=ge.getSection(lt);St+=lA(ge.getCharCode(lt),vt,ze,$e,Oe,tt)}return St/Math.max(1,Math.ceil(St/Be))}(c,l,d,y,w,K),Q=c.text.indexOf("")>=0;let ie=0;for(let ge=0;ge<c.length();ge++){const Oe=c.getSection(ge),Be=c.getCharCode(ge);if(W1[Be]||(ie+=lA(Be,Oe,y,w,l,K)),ge<c.length()-1){const ze=!((le=Be)<11904||!(Nn["Bopomofo Extended"](le)||Nn.Bopomofo(le)||Nn["CJK Compatibility Forms"](le)||Nn["CJK Compatibility Ideographs"](le)||Nn["CJK Compatibility"](le)||Nn["CJK Radicals Supplement"](le)||Nn["CJK Strokes"](le)||Nn["CJK Symbols and Punctuation"](le)||Nn["CJK Unified Ideographs Extension A"](le)||Nn["CJK Unified Ideographs"](le)||Nn["Enclosed CJK Letters and Months"](le)||Nn["Halfwidth and Fullwidth Forms"](le)||Nn.Hiragana(le)||Nn["Ideographic Description Characters"](le)||Nn["Kangxi Radicals"](le)||Nn["Katakana Phonetic Extensions"](le)||Nn.Katakana(le)||Nn["Vertical Forms"](le)||Nn["Yi Radicals"](le)||Nn["Yi Syllables"](le)));(J5[Be]||ze||Oe.imageName)&&D.push(Sb(ge+1,ie,z,D,ew(Be,c.getCharCode(ge+1),ze&&Q),!1))}}var le;return av(Sb(c.length(),ie,z,D,0,!0))}function lv(c){let l=.5,d=.5;switch(c){case"right":case"top-right":case"bottom-right":l=1;break;case"left":case"top-left":case"bottom-left":l=0}switch(c){case"bottom":case"bottom-right":case"bottom-left":d=1;break;case"top":case"top-right":case"top-left":d=0}return{horizontalAlign:l,verticalAlign:d}}function tw(c,l,d,y,w){if(!y&&!w)return;const T=c[d],K=(c[d].x+T.metrics.advance*T.scale)*y;for(let D=l;D<=d;D++)c[D].x-=K,c[D].y+=w}function nw(c,l,d){const{horizontalAlign:y,verticalAlign:w}=lv(d),T=l[0]-c.displaySize[0]*y,K=l[1]-c.displaySize[1]*w;return{image:c,top:K,bottom:K+c.displaySize[1],left:T,right:T+c.displaySize[0]}}function N1(c,l,d,y,w,T){const K=c.image;let D;if(K.content){const $e=K.content,tt=K.pixelRatio||1;D=[$e[0]/tt,$e[1]/tt,K.displaySize[0]-$e[2]/tt,K.displaySize[1]-$e[3]/tt]}const z=l.left*T,Q=l.right*T;let ie,le,ge,Oe;d==="width"||d==="both"?(Oe=w[0]+z-y[3],le=w[0]+Q+y[1]):(Oe=w[0]+(z+Q-K.displaySize[0])/2,le=Oe+K.displaySize[0]);const Be=l.top*T,ze=l.bottom*T;return d==="height"||d==="both"?(ie=w[1]+Be-y[0],ge=w[1]+ze+y[2]):(ie=w[1]+(Be+ze-K.displaySize[1])/2,ge=ie+K.displaySize[1]),{image:K,top:ie,right:le,bottom:ge,left:Oe,collisionPadding:D}}const l0=255,dd=128,Lh=l0*dd;function Eb(c,l){const{expression:d}=l;if(d.kind==="constant")return{kind:"constant",layoutSize:d.evaluate(new go(c+1))};if(d.kind==="source")return{kind:"source"};{const{zoomStops:y,interpolationType:w}=d;let T=0;for(;T<y.length&&y[T]<=c;)T++;T=Math.max(0,T-1);let K=T;for(;K<y.length&&y[K]<c+1;)K++;K=Math.min(y.length-1,K);const D=y[T],z=y[K];return d.kind==="composite"?{kind:"composite",minZoom:D,maxZoom:z,interpolationType:w}:{kind:"camera",minZoom:D,maxZoom:z,minSize:d.evaluate(new go(D)),maxSize:d.evaluate(new go(z)),interpolationType:w}}}function uv(c,l,d){let y="never";const w=c.get(l);return w?y=w:c.get(d)&&(y="always"),y}const rw=FA.VectorTileFeature.types,iw=[{name:"a_fade_opacity",components:1,type:"Uint8",offset:0}];function G1(c,l,d,y,w,T,K,D,z,Q,ie,le,ge){const Oe=D?Math.min(Lh,Math.round(D[0])):0,Be=D?Math.min(Lh,Math.round(D[1])):0;c.emplaceBack(l,d,Math.round(32*y),Math.round(32*w),T,K,(Oe<<1)+(z?1:0),Be,16*Q,16*ie,256*le,256*ge)}function Av(c,l,d){c.emplaceBack(l.x,l.y,d),c.emplaceBack(l.x,l.y,d),c.emplaceBack(l.x,l.y,d),c.emplaceBack(l.x,l.y,d)}function ow(c){for(const l of c.sections)if(Eh(l.text))return!0;return!1}class cv{constructor(l){this.layoutVertexArray=new qe,this.indexArray=new hn,this.programConfigurations=l,this.segments=new xr,this.dynamicLayoutVertexArray=new _t,this.opacityVertexArray=new Ut,this.hasVisibleVertices=!1,this.placedSymbolArray=new C}isEmpty(){return this.layoutVertexArray.length===0&&this.indexArray.length===0&&this.dynamicLayoutVertexArray.length===0&&this.opacityVertexArray.length===0}upload(l,d,y,w){this.isEmpty()||(y&&(this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,se.members),this.indexBuffer=l.createIndexBuffer(this.indexArray,d),this.dynamicLayoutVertexBuffer=l.createVertexBuffer(this.dynamicLayoutVertexArray,pe.members,!0),this.opacityVertexBuffer=l.createVertexBuffer(this.opacityVertexArray,iw,!0),this.opacityVertexBuffer.itemSize=1),(y||w)&&this.programConfigurations.upload(l))}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.dynamicLayoutVertexBuffer.destroy(),this.opacityVertexBuffer.destroy())}}jn("SymbolBuffers",cv);class dv{constructor(l,d,y){this.layoutVertexArray=new l,this.layoutAttributes=d,this.indexArray=new y,this.segments=new xr,this.collisionVertexArray=new en}upload(l){this.layoutVertexBuffer=l.createVertexBuffer(this.layoutVertexArray,this.layoutAttributes),this.indexBuffer=l.createIndexBuffer(this.indexArray),this.collisionVertexBuffer=l.createVertexBuffer(this.collisionVertexArray,We.members,!0)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.collisionVertexBuffer.destroy())}}jn("CollisionBuffers",dv);class jp{constructor(l){this.collisionBoxArray=l.collisionBoxArray,this.zoom=l.zoom,this.overscaling=l.overscaling,this.layers=l.layers,this.layerIds=this.layers.map(K=>K.id),this.index=l.index,this.pixelRatio=l.pixelRatio,this.sourceLayerIndex=l.sourceLayerIndex,this.hasPattern=!1,this.hasRTLText=!1,this.sortKeyRanges=[],this.collisionCircleArray=[],this.placementInvProjMatrix=Kf([]),this.placementViewportMatrix=Kf([]);const d=this.layers[0]._unevaluatedLayout._values;this.textSizeData=Eb(this.zoom,d["text-size"]),this.iconSizeData=Eb(this.zoom,d["icon-size"]);const y=this.layers[0].layout,w=y.get("symbol-sort-key"),T=y.get("symbol-z-order");this.canOverlap=uv(y,"text-overlap","text-allow-overlap")!=="never"||uv(y,"icon-overlap","icon-allow-overlap")!=="never"||y.get("text-ignore-placement")||y.get("icon-ignore-placement"),this.sortFeaturesByKey=T!=="viewport-y"&&!w.isConstant(),this.sortFeaturesByY=(T==="viewport-y"||T==="auto"&&!this.sortFeaturesByKey)&&this.canOverlap,y.get("symbol-placement")==="point"&&(this.writingModes=y.get("text-writing-mode").map(K=>a.ah[K])),this.stateDependentLayerIds=this.layers.filter(K=>K.isStateDependent()).map(K=>K.id),this.sourceID=l.sourceID}createArrays(){this.text=new cv(new ua(this.layers,this.zoom,l=>/^text/.test(l))),this.icon=new cv(new ua(this.layers,this.zoom,l=>/^icon/.test(l))),this.glyphOffsetArray=new L,this.lineVertexArray=new j,this.symbolInstances=new I,this.textAnchorOffsets=new te}calculateGlyphDependencies(l,d,y,w,T){for(let K=0;K<l.length;K++)if(d[l.charCodeAt(K)]=!0,(y||w)&&T){const D=qt[l.charAt(K)];D&&(d[D.charCodeAt(0)]=!0)}}populate(l,d,y){const w=this.layers[0],T=w.layout,K=T.get("text-font"),D=T.get("text-field"),z=T.get("icon-image"),Q=(D.value.kind!=="constant"||D.value.value instanceof lo&&!D.value.value.isEmpty()||D.value.value.toString().length>0)&&(K.value.kind!=="constant"||K.value.value.length>0),ie=z.value.kind!=="constant"||!!z.value.value||Object.keys(z.parameters).length>0,le=T.get("symbol-sort-key");if(this.features=[],!Q&&!ie)return;const ge=d.iconDependencies,Oe=d.glyphDependencies,Be=d.availableImages,ze=new go(this.zoom);for(const{feature:$e,id:tt,index:St,sourceLayerIndex:lt}of l){const vt=w._featureFilter.needGeometry,tn=hl($e,vt);if(!w._featureFilter.filter(ze,tn,y))continue;let an,Vn;if(vt||(tn.geometry=EA($e)),Q){const xn=w.getValueAndResolveTokens("text-field",tn,y,Be),Cn=lo.factory(xn);ow(Cn)&&(this.hasRTLText=!0),(!this.hasRTLText||Hl.getRTLTextPluginStatus()==="unavailable"||this.hasRTLText&&Hl.isParsed())&&(an=yt(Cn,w,tn))}if(ie){const xn=w.getValueAndResolveTokens("icon-image",tn,y,Be);Vn=xn instanceof Ge?xn:Ge.fromString(xn)}if(!an&&!Vn)continue;const cr=this.sortFeaturesByKey?le.evaluate(tn,{},y):void 0;if(this.features.push({id:tt,text:an,icon:Vn,index:St,sourceLayerIndex:lt,geometry:tn.geometry,properties:$e.properties,type:rw[$e.type],sortKey:cr}),Vn&&(ge[Vn.name]=!0),an){const xn=K.evaluate(tn,{},y).join(","),Cn=T.get("text-rotation-alignment")!=="viewport"&&T.get("symbol-placement")!=="point";this.allowVerticalPlacement=this.writingModes&&this.writingModes.indexOf(a.ah.vertical)>=0;for(const Kn of an.sections)if(Kn.image)ge[Kn.image.name]=!0;else{const ur=rA(an.toString()),Dn=Kn.fontStack||xn,wn=Oe[Dn]=Oe[Dn]||{};this.calculateGlyphDependencies(Kn.text,wn,Cn,this.allowVerticalPlacement,ur)}}}T.get("symbol-placement")==="line"&&(this.features=function($e){const tt={},St={},lt=[];let vt=0;function tn(xn){lt.push($e[xn]),vt++}function an(xn,Cn,Kn){const ur=St[xn];return delete St[xn],St[Cn]=ur,lt[ur].geometry[0].pop(),lt[ur].geometry[0]=lt[ur].geometry[0].concat(Kn[0]),ur}function Vn(xn,Cn,Kn){const ur=tt[Cn];return delete tt[Cn],tt[xn]=ur,lt[ur].geometry[0].shift(),lt[ur].geometry[0]=Kn[0].concat(lt[ur].geometry[0]),ur}function cr(xn,Cn,Kn){const ur=Kn?Cn[0][Cn[0].length-1]:Cn[0][0];return`${xn}:${ur.x}:${ur.y}`}for(let xn=0;xn<$e.length;xn++){const Cn=$e[xn],Kn=Cn.geometry,ur=Cn.text?Cn.text.toString():null;if(!ur){tn(xn);continue}const Dn=cr(ur,Kn),wn=cr(ur,Kn,!0);if(Dn in St&&wn in tt&&St[Dn]!==tt[wn]){const Kr=Vn(Dn,wn,Kn),wr=an(Dn,wn,lt[Kr].geometry);delete tt[Dn],delete St[wn],St[cr(ur,lt[wr].geometry,!0)]=wr,lt[Kr].geometry=null}else Dn in St?an(Dn,wn,Kn):wn in tt?Vn(Dn,wn,Kn):(tn(xn),tt[Dn]=vt-1,St[wn]=vt-1)}return lt.filter(xn=>xn.geometry)}(this.features)),this.sortFeaturesByKey&&this.features.sort(($e,tt)=>$e.sortKey-tt.sortKey)}update(l,d,y){this.stateDependentLayers.length&&(this.text.programConfigurations.updatePaintArrays(l,d,this.layers,y),this.icon.programConfigurations.updatePaintArrays(l,d,this.layers,y))}isEmpty(){return this.symbolInstances.length===0&&!this.hasRTLText}uploadPending(){return!this.uploaded||this.text.programConfigurations.needsUpload||this.icon.programConfigurations.needsUpload}upload(l){!this.uploaded&&this.hasDebugData()&&(this.textCollisionBox.upload(l),this.iconCollisionBox.upload(l)),this.text.upload(l,this.sortFeaturesByY,!this.uploaded,this.text.programConfigurations.needsUpload),this.icon.upload(l,this.sortFeaturesByY,!this.uploaded,this.icon.programConfigurations.needsUpload),this.uploaded=!0}destroyDebugData(){this.textCollisionBox.destroy(),this.iconCollisionBox.destroy()}destroy(){this.text.destroy(),this.icon.destroy(),this.hasDebugData()&&this.destroyDebugData()}addToLineVertexArray(l,d){const y=this.lineVertexArray.length;if(l.segment!==void 0){let w=l.dist(d[l.segment+1]),T=l.dist(d[l.segment]);const K={};for(let D=l.segment+1;D<d.length;D++)K[D]={x:d[D].x,y:d[D].y,tileUnitDistanceFromAnchor:w},D<d.length-1&&(w+=d[D+1].dist(d[D]));for(let D=l.segment||0;D>=0;D--)K[D]={x:d[D].x,y:d[D].y,tileUnitDistanceFromAnchor:T},D>0&&(T+=d[D-1].dist(d[D]));for(let D=0;D<d.length;D++){const z=K[D];this.lineVertexArray.emplaceBack(z.x,z.y,z.tileUnitDistanceFromAnchor)}}return{lineStartIndex:y,lineLength:this.lineVertexArray.length-y}}addSymbols(l,d,y,w,T,K,D,z,Q,ie,le,ge){const Oe=l.indexArray,Be=l.layoutVertexArray,ze=l.segments.prepareSegment(4*d.length,Be,Oe,this.canOverlap?K.sortKey:void 0),$e=this.glyphOffsetArray.length,tt=ze.vertexLength,St=this.allowVerticalPlacement&&D===a.ah.vertical?Math.PI/2:0,lt=K.text&&K.text.sections;for(let vt=0;vt<d.length;vt++){const{tl:tn,tr:an,bl:Vn,br:cr,tex:xn,pixelOffsetTL:Cn,pixelOffsetBR:Kn,minFontScaleX:ur,minFontScaleY:Dn,glyphOffset:wn,isSDF:Kr,sectionIndex:wr}=d[vt],Bi=ze.vertexLength,ea=wn[1];G1(Be,z.x,z.y,tn.x,ea+tn.y,xn.x,xn.y,y,Kr,Cn.x,Cn.y,ur,Dn),G1(Be,z.x,z.y,an.x,ea+an.y,xn.x+xn.w,xn.y,y,Kr,Kn.x,Cn.y,ur,Dn),G1(Be,z.x,z.y,Vn.x,ea+Vn.y,xn.x,xn.y+xn.h,y,Kr,Cn.x,Kn.y,ur,Dn),G1(Be,z.x,z.y,cr.x,ea+cr.y,xn.x+xn.w,xn.y+xn.h,y,Kr,Kn.x,Kn.y,ur,Dn),Av(l.dynamicLayoutVertexArray,z,St),Oe.emplaceBack(Bi,Bi+1,Bi+2),Oe.emplaceBack(Bi+1,Bi+2,Bi+3),ze.vertexLength+=4,ze.primitiveLength+=2,this.glyphOffsetArray.emplaceBack(wn[0]),vt!==d.length-1&&wr===d[vt+1].sectionIndex||l.programConfigurations.populatePaintArrays(Be.length,K,K.index,{},ge,lt&<[wr])}l.placedSymbolArray.emplaceBack(z.x,z.y,$e,this.glyphOffsetArray.length-$e,tt,Q,ie,z.segment,y?y[0]:0,y?y[1]:0,w[0],w[1],D,0,!1,0,le)}_addCollisionDebugVertex(l,d,y,w,T,K){return d.emplaceBack(0,0),l.emplaceBack(y.x,y.y,w,T,Math.round(K.x),Math.round(K.y))}addCollisionDebugVertices(l,d,y,w,T,K,D){const z=T.segments.prepareSegment(4,T.layoutVertexArray,T.indexArray),Q=z.vertexLength,ie=T.layoutVertexArray,le=T.collisionVertexArray,ge=D.anchorX,Oe=D.anchorY;this._addCollisionDebugVertex(ie,le,K,ge,Oe,new B(l,d)),this._addCollisionDebugVertex(ie,le,K,ge,Oe,new B(y,d)),this._addCollisionDebugVertex(ie,le,K,ge,Oe,new B(y,w)),this._addCollisionDebugVertex(ie,le,K,ge,Oe,new B(l,w)),z.vertexLength+=4;const Be=T.indexArray;Be.emplaceBack(Q,Q+1),Be.emplaceBack(Q+1,Q+2),Be.emplaceBack(Q+2,Q+3),Be.emplaceBack(Q+3,Q),z.primitiveLength+=4}addDebugCollisionBoxes(l,d,y,w){for(let T=l;T<d;T++){const K=this.collisionBoxArray.get(T);this.addCollisionDebugVertices(K.x1,K.y1,K.x2,K.y2,w?this.textCollisionBox:this.iconCollisionBox,K.anchorPoint,y)}}generateCollisionDebugBuffers(){this.hasDebugData()&&this.destroyDebugData(),this.textCollisionBox=new dv(Tt,Ye.members,An),this.iconCollisionBox=new dv(Tt,Ye.members,An);for(let l=0;l<this.symbolInstances.length;l++){const d=this.symbolInstances.get(l);this.addDebugCollisionBoxes(d.textBoxStartIndex,d.textBoxEndIndex,d,!0),this.addDebugCollisionBoxes(d.verticalTextBoxStartIndex,d.verticalTextBoxEndIndex,d,!0),this.addDebugCollisionBoxes(d.iconBoxStartIndex,d.iconBoxEndIndex,d,!1),this.addDebugCollisionBoxes(d.verticalIconBoxStartIndex,d.verticalIconBoxEndIndex,d,!1)}}_deserializeCollisionBoxesForSymbol(l,d,y,w,T,K,D,z,Q){const ie={};for(let le=d;le<y;le++){const ge=l.get(le);ie.textBox={x1:ge.x1,y1:ge.y1,x2:ge.x2,y2:ge.y2,anchorPointX:ge.anchorPointX,anchorPointY:ge.anchorPointY},ie.textFeatureIndex=ge.featureIndex;break}for(let le=w;le<T;le++){const ge=l.get(le);ie.verticalTextBox={x1:ge.x1,y1:ge.y1,x2:ge.x2,y2:ge.y2,anchorPointX:ge.anchorPointX,anchorPointY:ge.anchorPointY},ie.verticalTextFeatureIndex=ge.featureIndex;break}for(let le=K;le<D;le++){const ge=l.get(le);ie.iconBox={x1:ge.x1,y1:ge.y1,x2:ge.x2,y2:ge.y2,anchorPointX:ge.anchorPointX,anchorPointY:ge.anchorPointY},ie.iconFeatureIndex=ge.featureIndex;break}for(let le=z;le<Q;le++){const ge=l.get(le);ie.verticalIconBox={x1:ge.x1,y1:ge.y1,x2:ge.x2,y2:ge.y2,anchorPointX:ge.anchorPointX,anchorPointY:ge.anchorPointY},ie.verticalIconFeatureIndex=ge.featureIndex;break}return ie}deserializeCollisionBoxes(l){this.collisionArrays=[];for(let d=0;d<this.symbolInstances.length;d++){const y=this.symbolInstances.get(d);this.collisionArrays.push(this._deserializeCollisionBoxesForSymbol(l,y.textBoxStartIndex,y.textBoxEndIndex,y.verticalTextBoxStartIndex,y.verticalTextBoxEndIndex,y.iconBoxStartIndex,y.iconBoxEndIndex,y.verticalIconBoxStartIndex,y.verticalIconBoxEndIndex))}}hasTextData(){return this.text.segments.get().length>0}hasIconData(){return this.icon.segments.get().length>0}hasDebugData(){return this.textCollisionBox&&this.iconCollisionBox}hasTextCollisionBoxData(){return this.hasDebugData()&&this.textCollisionBox.segments.get().length>0}hasIconCollisionBoxData(){return this.hasDebugData()&&this.iconCollisionBox.segments.get().length>0}addIndicesForPlacedSymbol(l,d){const y=l.placedSymbolArray.get(d),w=y.vertexStartIndex+4*y.numGlyphs;for(let T=y.vertexStartIndex;T<w;T+=4)l.indexArray.emplaceBack(T,T+1,T+2),l.indexArray.emplaceBack(T+1,T+2,T+3)}getSortedSymbolIndexes(l){if(this.sortedAngle===l&&this.symbolInstanceIndexes!==void 0)return this.symbolInstanceIndexes;const d=Math.sin(l),y=Math.cos(l),w=[],T=[],K=[];for(let D=0;D<this.symbolInstances.length;++D){K.push(D);const z=this.symbolInstances.get(D);w.push(0|Math.round(d*z.anchorX+y*z.anchorY)),T.push(z.featureIndex)}return K.sort((D,z)=>w[D]-w[z]||T[z]-T[D]),K}addToSortKeyRanges(l,d){const y=this.sortKeyRanges[this.sortKeyRanges.length-1];y&&y.sortKey===d?y.symbolInstanceEnd=l+1:this.sortKeyRanges.push({sortKey:d,symbolInstanceStart:l,symbolInstanceEnd:l+1})}sortFeatures(l){if(this.sortFeaturesByY&&this.sortedAngle!==l&&!(this.text.segments.get().length>1||this.icon.segments.get().length>1)){this.symbolInstanceIndexes=this.getSortedSymbolIndexes(l),this.sortedAngle=l,this.text.indexArray.clear(),this.icon.indexArray.clear(),this.featureSortOrder=[];for(const d of this.symbolInstanceIndexes){const y=this.symbolInstances.get(d);this.featureSortOrder.push(y.featureIndex),[y.rightJustifiedTextSymbolIndex,y.centerJustifiedTextSymbolIndex,y.leftJustifiedTextSymbolIndex].forEach((w,T,K)=>{w>=0&&K.indexOf(w)===T&&this.addIndicesForPlacedSymbol(this.text,w)}),y.verticalPlacedTextSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.text,y.verticalPlacedTextSymbolIndex),y.placedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,y.placedIconSymbolIndex),y.verticalPlacedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,y.verticalPlacedIconSymbolIndex)}this.text.indexBuffer&&this.text.indexBuffer.updateData(this.text.indexArray),this.icon.indexBuffer&&this.icon.indexBuffer.updateData(this.icon.indexArray)}}}let Ob,Bb;jn("SymbolBucket",jp,{omit:["layers","collisionBoxArray","features","compareText"]}),jp.MAX_GLYPHS=65535,jp.addDynamicAttributes=Av;var hv={get paint(){return Bb=Bb||new xa({"icon-opacity":new Or(mt.paint_symbol["icon-opacity"]),"icon-color":new Or(mt.paint_symbol["icon-color"]),"icon-halo-color":new Or(mt.paint_symbol["icon-halo-color"]),"icon-halo-width":new Or(mt.paint_symbol["icon-halo-width"]),"icon-halo-blur":new Or(mt.paint_symbol["icon-halo-blur"]),"icon-translate":new gr(mt.paint_symbol["icon-translate"]),"icon-translate-anchor":new gr(mt.paint_symbol["icon-translate-anchor"]),"text-opacity":new Or(mt.paint_symbol["text-opacity"]),"text-color":new Or(mt.paint_symbol["text-color"],{runtimeType:m,getOverride:c=>c.textColor,hasOverride:c=>!!c.textColor}),"text-halo-color":new Or(mt.paint_symbol["text-halo-color"]),"text-halo-width":new Or(mt.paint_symbol["text-halo-width"]),"text-halo-blur":new Or(mt.paint_symbol["text-halo-blur"]),"text-translate":new gr(mt.paint_symbol["text-translate"]),"text-translate-anchor":new gr(mt.paint_symbol["text-translate-anchor"])})},get layout(){return Ob=Ob||new xa({"symbol-placement":new gr(mt.layout_symbol["symbol-placement"]),"symbol-spacing":new gr(mt.layout_symbol["symbol-spacing"]),"symbol-avoid-edges":new gr(mt.layout_symbol["symbol-avoid-edges"]),"symbol-sort-key":new Or(mt.layout_symbol["symbol-sort-key"]),"symbol-z-order":new gr(mt.layout_symbol["symbol-z-order"]),"icon-allow-overlap":new gr(mt.layout_symbol["icon-allow-overlap"]),"icon-overlap":new gr(mt.layout_symbol["icon-overlap"]),"icon-ignore-placement":new gr(mt.layout_symbol["icon-ignore-placement"]),"icon-optional":new gr(mt.layout_symbol["icon-optional"]),"icon-rotation-alignment":new gr(mt.layout_symbol["icon-rotation-alignment"]),"icon-size":new Or(mt.layout_symbol["icon-size"]),"icon-text-fit":new gr(mt.layout_symbol["icon-text-fit"]),"icon-text-fit-padding":new gr(mt.layout_symbol["icon-text-fit-padding"]),"icon-image":new Or(mt.layout_symbol["icon-image"]),"icon-rotate":new Or(mt.layout_symbol["icon-rotate"]),"icon-padding":new Or(mt.layout_symbol["icon-padding"]),"icon-keep-upright":new gr(mt.layout_symbol["icon-keep-upright"]),"icon-offset":new Or(mt.layout_symbol["icon-offset"]),"icon-anchor":new Or(mt.layout_symbol["icon-anchor"]),"icon-pitch-alignment":new gr(mt.layout_symbol["icon-pitch-alignment"]),"text-pitch-alignment":new gr(mt.layout_symbol["text-pitch-alignment"]),"text-rotation-alignment":new gr(mt.layout_symbol["text-rotation-alignment"]),"text-field":new Or(mt.layout_symbol["text-field"]),"text-font":new Or(mt.layout_symbol["text-font"]),"text-size":new Or(mt.layout_symbol["text-size"]),"text-max-width":new Or(mt.layout_symbol["text-max-width"]),"text-line-height":new gr(mt.layout_symbol["text-line-height"]),"text-letter-spacing":new Or(mt.layout_symbol["text-letter-spacing"]),"text-justify":new Or(mt.layout_symbol["text-justify"]),"text-radial-offset":new Or(mt.layout_symbol["text-radial-offset"]),"text-variable-anchor":new gr(mt.layout_symbol["text-variable-anchor"]),"text-variable-anchor-offset":new Or(mt.layout_symbol["text-variable-anchor-offset"]),"text-anchor":new Or(mt.layout_symbol["text-anchor"]),"text-max-angle":new gr(mt.layout_symbol["text-max-angle"]),"text-writing-mode":new gr(mt.layout_symbol["text-writing-mode"]),"text-rotate":new Or(mt.layout_symbol["text-rotate"]),"text-padding":new gr(mt.layout_symbol["text-padding"]),"text-keep-upright":new gr(mt.layout_symbol["text-keep-upright"]),"text-transform":new Or(mt.layout_symbol["text-transform"]),"text-offset":new Or(mt.layout_symbol["text-offset"]),"text-allow-overlap":new gr(mt.layout_symbol["text-allow-overlap"]),"text-overlap":new gr(mt.layout_symbol["text-overlap"]),"text-ignore-placement":new gr(mt.layout_symbol["text-ignore-placement"]),"text-optional":new gr(mt.layout_symbol["text-optional"])})}};class kb{constructor(l){if(l.property.overrides===void 0)throw new Error("overrides must be provided to instantiate FormatSectionOverride class");this.type=l.property.overrides?l.property.overrides.runtimeType:sr,this.defaultValue=l}evaluate(l){if(l.formattedSection){const d=this.defaultValue.property.overrides;if(d&&d.hasOverride(l.formattedSection))return d.getOverride(l.formattedSection)}return l.feature&&l.featureState?this.defaultValue.evaluate(l.feature,l.featureState):this.defaultValue.property.specification.default}eachChild(l){this.defaultValue.isConstant()||l(this.defaultValue.value._styleExpression.expression)}outputDefined(){return!1}serialize(){return null}}jn("FormatSectionOverride",kb,{omit:["defaultValue"]});class Q1 extends As{constructor(l){super(l,hv)}recalculate(l,d){if(super.recalculate(l,d),this.layout.get("icon-rotation-alignment")==="auto"&&(this.layout._values["icon-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-rotation-alignment")==="auto"&&(this.layout._values["text-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-pitch-alignment")==="auto"&&(this.layout._values["text-pitch-alignment"]=this.layout.get("text-rotation-alignment")==="map"?"map":"viewport"),this.layout.get("icon-pitch-alignment")==="auto"&&(this.layout._values["icon-pitch-alignment"]=this.layout.get("icon-rotation-alignment")),this.layout.get("symbol-placement")==="point"){const y=this.layout.get("text-writing-mode");if(y){const w=[];for(const T of y)w.indexOf(T)<0&&w.push(T);this.layout._values["text-writing-mode"]=w}else this.layout._values["text-writing-mode"]=["horizontal"]}this._setPaintOverrides()}getValueAndResolveTokens(l,d,y,w){const T=this.layout.get(l).evaluate(d,{},y,w),K=this._unevaluatedLayout._values[l];return K.isDataDriven()||tc(K.value)||!T?T:function(D,z){return z.replace(/{([^{}]+)}/g,(Q,ie)=>D&&ie in D?String(D[ie]):"")}(d.properties,T)}createBucket(l){return new jp(l)}queryRadius(){return 0}queryIntersectsFeature(){throw new Error("Should take a different path in FeatureIndex")}_setPaintOverrides(){for(const l of hv.paint.overridableProperties){if(!Q1.hasPaintOverride(this.layout,l))continue;const d=this.paint.get(l),y=new kb(d),w=new So(y,d.property.specification);let T=null;T=d.value.kind==="constant"||d.value.kind==="source"?new Ls("source",w):new Kd("composite",w,d.value.zoomStops),this.paint._values[l]=new Eo(d.property,T,d.parameters)}}_handleOverridablePaintPropertyUpdate(l,d,y){return!(!this.layout||d.isDataDriven()||y.isDataDriven())&&Q1.hasPaintOverride(this.layout,l)}static hasPaintOverride(l,d){const y=l.get("text-field"),w=hv.paint.properties[d];let T=!1;const K=D=>{for(const z of D)if(w.overrides&&w.overrides.hasOverride(z))return void(T=!0)};if(y.value.kind==="constant"&&y.value.value instanceof lo)K(y.value.value.sections);else if(y.value.kind==="source"){const D=Q=>{T||(Q instanceof zr&&Ot(Q.value)===Zn?K(Q.value.sections):Q instanceof cu?K(Q.sections):Q.eachChild(D))},z=y.value;z._styleExpression&&D(z._styleExpression.expression)}return T}}let Ib;var aw={get paint(){return Ib=Ib||new xa({"background-color":new gr(mt.paint_background["background-color"]),"background-pattern":new Jc(mt.paint_background["background-pattern"]),"background-opacity":new gr(mt.paint_background["background-opacity"])})}};class fv extends As{constructor(l){super(l,aw)}}let pv;var sw={get paint(){return pv=pv||new xa({"raster-opacity":new gr(mt.paint_raster["raster-opacity"]),"raster-hue-rotate":new gr(mt.paint_raster["raster-hue-rotate"]),"raster-brightness-min":new gr(mt.paint_raster["raster-brightness-min"]),"raster-brightness-max":new gr(mt.paint_raster["raster-brightness-max"]),"raster-saturation":new gr(mt.paint_raster["raster-saturation"]),"raster-contrast":new gr(mt.paint_raster["raster-contrast"]),"raster-resampling":new gr(mt.paint_raster["raster-resampling"]),"raster-fade-duration":new gr(mt.paint_raster["raster-fade-duration"])})}};class lw extends As{constructor(l){super(l,sw)}}class uw extends As{constructor(l){super(l,{}),this.onAdd=d=>{this.implementation.onAdd&&this.implementation.onAdd(d,d.painter.context.gl)},this.onRemove=d=>{this.implementation.onRemove&&this.implementation.onRemove(d,d.painter.context.gl)},this.implementation=l}is3D(){return this.implementation.renderingMode==="3d"}hasOffscreenPass(){return this.implementation.prerender!==void 0}recalculate(){}updateTransitions(){}hasTransition(){return!1}serialize(){throw new Error("Custom layers cannot be serialized")}}class Aw{constructor(l){this._methodToThrottle=l,this._triggered=!1,typeof MessageChannel<"u"&&(this._channel=new MessageChannel,this._channel.port2.onmessage=()=>{this._triggered=!1,this._methodToThrottle()})}trigger(){this._triggered||(this._triggered=!0,this._channel?this._channel.port1.postMessage(!0):setTimeout(()=>{this._triggered=!1,this._methodToThrottle()},0))}remove(){delete this._channel,this._methodToThrottle=()=>{}}}const mv=63710088e-1;class zh{constructor(l,d){if(isNaN(l)||isNaN(d))throw new Error(`Invalid LngLat object: (${l}, ${d})`);if(this.lng=+l,this.lat=+d,this.lat>90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")}wrap(){return new zh(ue(this.lng,-180,180),this.lat)}toArray(){return[this.lng,this.lat]}toString(){return`LngLat(${this.lng}, ${this.lat})`}distanceTo(l){const d=Math.PI/180,y=this.lat*d,w=l.lat*d,T=Math.sin(y)*Math.sin(w)+Math.cos(y)*Math.cos(w)*Math.cos((l.lng-this.lng)*d);return mv*Math.acos(Math.min(T,1))}static convert(l){if(l instanceof zh)return l;if(Array.isArray(l)&&(l.length===2||l.length===3))return new zh(Number(l[0]),Number(l[1]));if(!Array.isArray(l)&&typeof l=="object"&&l!==null)return new zh(Number("lng"in l?l.lng:l.lon),Number(l.lat));throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: <lng>, lat: <lat>}, an object {lon: <lng>, lat: <lat>}, or an array of [<lng>, <lat>]")}}const Tb=2*Math.PI*mv;function Kb(c){return Tb*Math.cos(c*Math.PI/180)}function gv(c){return(180+c)/360}function Pb(c){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+c*Math.PI/360)))/360}function u0(c,l){return c/Kb(l)}function yv(c){return 360/Math.PI*Math.atan(Math.exp((180-360*c)*Math.PI/180))-90}class $1{constructor(l,d,y=0){this.x=+l,this.y=+d,this.z=+y}static fromLngLat(l,d=0){const y=zh.convert(l);return new $1(gv(y.lng),Pb(y.lat),u0(d,y.lat))}toLngLat(){return new zh(360*this.x-180,yv(this.y))}toAltitude(){return this.z*Kb(yv(this.y))}meterInMercatorCoordinateUnits(){return 1/Tb*(l=yv(this.y),1/Math.cos(l*Math.PI/180));var l}}function Fb(c,l,d){var y=2*Math.PI*6378137/256/Math.pow(2,d);return[c*y-2*Math.PI*6378137/2,l*y-2*Math.PI*6378137/2]}class vv{constructor(l,d,y){if(l<0||l>25||y<0||y>=Math.pow(2,l)||d<0||d>=Math.pow(2,l))throw new Error(`x=${d}, y=${y}, z=${l} outside of bounds. 0<=x<${Math.pow(2,l)}, 0<=y<${Math.pow(2,l)} 0<=z<=25 `);this.z=l,this.x=d,this.y=y,this.key=A0(0,l,l,d,y)}equals(l){return this.z===l.z&&this.x===l.x&&this.y===l.y}url(l,d,y){const w=(K=this.y,D=this.z,z=Fb(256*(T=this.x),256*(K=Math.pow(2,D)-K-1),D),Q=Fb(256*(T+1),256*(K+1),D),z[0]+","+z[1]+","+Q[0]+","+Q[1]);var T,K,D,z,Q;const ie=function(le,ge,Oe){let Be,ze="";for(let $e=le;$e>0;$e--)Be=1<<$e-1,ze+=(ge&Be?1:0)+(Oe&Be?2:0);return ze}(this.z,this.x,this.y);return l[(this.x+this.y)%l.length].replace(/{prefix}/g,(this.x%16).toString(16)+(this.y%16).toString(16)).replace(/{z}/g,String(this.z)).replace(/{x}/g,String(this.x)).replace(/{y}/g,String(y==="tms"?Math.pow(2,this.z)-this.y-1:this.y)).replace(/{ratio}/g,d>1?"@2x":"").replace(/{quadkey}/g,ie).replace(/{bbox-epsg-3857}/g,w)}isChildOf(l){const d=this.z-l.z;return d>0&&l.x===this.x>>d&&l.y===this.y>>d}getTilePoint(l){const d=Math.pow(2,this.z);return new B((l.x*d-this.x)*Wo,(l.y*d-this.y)*Wo)}toString(){return`${this.z}/${this.x}/${this.y}`}}class Db{constructor(l,d){this.wrap=l,this.canonical=d,this.key=A0(l,d.z,d.z,d.x,d.y)}}class uA{constructor(l,d,y,w,T){if(l<y)throw new Error(`overscaledZ should be >= z; overscaledZ = ${l}; z = ${y}`);this.overscaledZ=l,this.wrap=d,this.canonical=new vv(y,+w,+T),this.key=A0(d,l,y,w,T)}clone(){return new uA(this.overscaledZ,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)}equals(l){return this.overscaledZ===l.overscaledZ&&this.wrap===l.wrap&&this.canonical.equals(l.canonical)}scaledTo(l){if(l>this.overscaledZ)throw new Error(`targetZ > this.overscaledZ; targetZ = ${l}; overscaledZ = ${this.overscaledZ}`);const d=this.canonical.z-l;return l>this.canonical.z?new uA(l,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new uA(l,this.wrap,l,this.canonical.x>>d,this.canonical.y>>d)}calculateScaledKey(l,d){if(l>this.overscaledZ)throw new Error(`targetZ > this.overscaledZ; targetZ = ${l}; overscaledZ = ${this.overscaledZ}`);const y=this.canonical.z-l;return l>this.canonical.z?A0(this.wrap*+d,l,this.canonical.z,this.canonical.x,this.canonical.y):A0(this.wrap*+d,l,l,this.canonical.x>>y,this.canonical.y>>y)}isChildOf(l){if(l.wrap!==this.wrap)return!1;const d=this.canonical.z-l.canonical.z;return l.overscaledZ===0||l.overscaledZ<this.overscaledZ&&l.canonical.x===this.canonical.x>>d&&l.canonical.y===this.canonical.y>>d}children(l){if(this.overscaledZ>=l)return[new uA(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];const d=this.canonical.z+1,y=2*this.canonical.x,w=2*this.canonical.y;return[new uA(d,this.wrap,d,y,w),new uA(d,this.wrap,d,y+1,w),new uA(d,this.wrap,d,y,w+1),new uA(d,this.wrap,d,y+1,w+1)]}isLessThan(l){return this.wrap<l.wrap||!(this.wrap>l.wrap)&&(this.overscaledZ<l.overscaledZ||!(this.overscaledZ>l.overscaledZ)&&(this.canonical.x<l.canonical.x||!(this.canonical.x>l.canonical.x)&&this.canonical.y<l.canonical.y))}wrapped(){return new uA(this.overscaledZ,0,this.canonical.z,this.canonical.x,this.canonical.y)}unwrapTo(l){return new uA(this.overscaledZ,l,this.canonical.z,this.canonical.x,this.canonical.y)}overscaleFactor(){return Math.pow(2,this.overscaledZ-this.canonical.z)}toUnwrapped(){return new Db(this.wrap,this.canonical)}toString(){return`${this.overscaledZ}/${this.canonical.x}/${this.canonical.y}`}getTilePoint(l){return this.canonical.getTilePoint(new $1(l.x-this.wrap,l.y))}}function A0(c,l,d,y,w){(c*=2)<0&&(c=-1*c-1);const T=1<<d;return(T*T*c+T*w+y).toString(36)+d.toString(36)+l.toString(36)}jn("CanonicalTileID",vv),jn("OverscaledTileID",uA,{omit:["posMatrix"]});class Ub{constructor(l,d,y,w=1,T=1,K=1,D=0){if(this.uid=l,d.height!==d.width)throw new RangeError("DEM tiles must be square");if(y&&!["mapbox","terrarium","custom"].includes(y))return void He(`"${y}" is not a valid encoding type. Valid types include "mapbox", "terrarium" and "custom".`);this.stride=d.height;const z=this.dim=d.height-2;switch(this.data=new Uint32Array(d.data.buffer),y){case"terrarium":this.redFactor=256,this.greenFactor=1,this.blueFactor=1/256,this.baseShift=32768;break;case"custom":this.redFactor=w,this.greenFactor=T,this.blueFactor=K,this.baseShift=D;break;default:this.redFactor=6553.6,this.greenFactor=25.6,this.blueFactor=.1,this.baseShift=1e4}for(let Q=0;Q<z;Q++)this.data[this._idx(-1,Q)]=this.data[this._idx(0,Q)],this.data[this._idx(z,Q)]=this.data[this._idx(z-1,Q)],this.data[this._idx(Q,-1)]=this.data[this._idx(Q,0)],this.data[this._idx(Q,z)]=this.data[this._idx(Q,z-1)];this.data[this._idx(-1,-1)]=this.data[this._idx(0,0)],this.data[this._idx(z,-1)]=this.data[this._idx(z-1,0)],this.data[this._idx(-1,z)]=this.data[this._idx(0,z-1)],this.data[this._idx(z,z)]=this.data[this._idx(z-1,z-1)],this.min=Number.MAX_SAFE_INTEGER,this.max=Number.MIN_SAFE_INTEGER;for(let Q=0;Q<z;Q++)for(let ie=0;ie<z;ie++){const le=this.get(Q,ie);le>this.max&&(this.max=le),le<this.min&&(this.min=le)}}get(l,d){const y=new Uint8Array(this.data.buffer),w=4*this._idx(l,d);return this.unpack(y[w],y[w+1],y[w+2])}getUnpackVector(){return[this.redFactor,this.greenFactor,this.blueFactor,this.baseShift]}_idx(l,d){if(l<-1||l>=this.dim+1||d<-1||d>=this.dim+1)throw new RangeError("out of range source coordinates for DEM data");return(d+1)*this.stride+(l+1)}unpack(l,d,y){return l*this.redFactor+d*this.greenFactor+y*this.blueFactor-this.baseShift}getPixels(){return new Ss({width:this.stride,height:this.stride},new Uint8Array(this.data.buffer))}backfillBorder(l,d,y){if(this.dim!==l.dim)throw new Error("dem dimension mismatch");let w=d*this.dim,T=d*this.dim+this.dim,K=y*this.dim,D=y*this.dim+this.dim;switch(d){case-1:w=T-1;break;case 1:T=w+1}switch(y){case-1:K=D-1;break;case 1:D=K+1}const z=-d*this.dim,Q=-y*this.dim;for(let ie=K;ie<D;ie++)for(let le=w;le<T;le++)this.data[this._idx(le,ie)]=l.data[this._idx(le+z,ie+Q)]}}jn("DEMData",Ub);class Rb{constructor(l){this._stringToNumber={},this._numberToString=[];for(let d=0;d<l.length;d++){const y=l[d];this._stringToNumber[y]=d,this._numberToString[d]=y}}encode(l){return this._stringToNumber[l]}decode(l){if(l>=this._numberToString.length)throw new Error(`Out of bounds. Index requested n=${l} can't be >= this._numberToString.length ${this._numberToString.length}`);return this._numberToString[l]}}class Lb{constructor(l,d,y,w,T){this.type="Feature",this._vectorTileFeature=l,l._z=d,l._x=y,l._y=w,this.properties=l.properties,this.id=T}get geometry(){return this._geometry===void 0&&(this._geometry=this._vectorTileFeature.toGeoJSON(this._vectorTileFeature._x,this._vectorTileFeature._y,this._vectorTileFeature._z).geometry),this._geometry}set geometry(l){this._geometry=l}toJSON(){const l={geometry:this.geometry};for(const d in this)d!=="_geometry"&&d!=="_vectorTileFeature"&&(l[d]=this[d]);return l}}class zb{constructor(l,d){this.tileID=l,this.x=l.canonical.x,this.y=l.canonical.y,this.z=l.canonical.z,this.grid=new Ol(Wo,16,0),this.grid3D=new Ol(Wo,16,0),this.featureIndexArray=new he,this.promoteId=d}insert(l,d,y,w,T,K){const D=this.featureIndexArray.length;this.featureIndexArray.emplaceBack(y,w,T);const z=K?this.grid3D:this.grid;for(let Q=0;Q<d.length;Q++){const ie=d[Q],le=[1/0,1/0,-1/0,-1/0];for(let ge=0;ge<ie.length;ge++){const Oe=ie[ge];le[0]=Math.min(le[0],Oe.x),le[1]=Math.min(le[1],Oe.y),le[2]=Math.max(le[2],Oe.x),le[3]=Math.max(le[3],Oe.y)}le[0]<Wo&&le[1]<Wo&&le[2]>=0&&le[3]>=0&&z.insert(D,le[0],le[1],le[2],le[3])}}loadVTLayers(){return this.vtLayers||(this.vtLayers=new FA.VectorTile(new Os(this.rawTileData)).layers,this.sourceLayerCoder=new Rb(this.vtLayers?Object.keys(this.vtLayers).sort():["_geojsonTileLayer"])),this.vtLayers}query(l,d,y,w){this.loadVTLayers();const T=l.params||{},K=Wo/l.tileSize/l.scale,D=wl(T.filter),z=l.queryGeometry,Q=l.queryPadding*K,ie=Wb(z),le=this.grid.query(ie.minX-Q,ie.minY-Q,ie.maxX+Q,ie.maxY+Q),ge=Wb(l.cameraQueryGeometry),Oe=this.grid3D.query(ge.minX-Q,ge.minY-Q,ge.maxX+Q,ge.maxY+Q,($e,tt,St,lt)=>function(vt,tn,an,Vn,cr){for(const Cn of vt)if(tn<=Cn.x&&an<=Cn.y&&Vn>=Cn.x&&cr>=Cn.y)return!0;const xn=[new B(tn,an),new B(tn,cr),new B(Vn,cr),new B(Vn,an)];if(vt.length>2){for(const Cn of xn)if(rd(vt,Cn))return!0}for(let Cn=0;Cn<vt.length-1;Cn++)if(k1(vt[Cn],vt[Cn+1],xn))return!0;return!1}(l.cameraQueryGeometry,$e-Q,tt-Q,St+Q,lt+Q));for(const $e of Oe)le.push($e);le.sort(cw);const Be={};let ze;for(let $e=0;$e<le.length;$e++){const tt=le[$e];if(tt===ze)continue;ze=tt;const St=this.featureIndexArray.get(tt);let lt=null;this.loadMatchingFeature(Be,St.bucketIndex,St.sourceLayerIndex,St.featureIndex,D,T.layers,T.availableImages,d,y,w,(vt,tn,an)=>(lt||(lt=EA(vt)),tn.queryIntersectsFeature(z,vt,an,lt,this.z,l.transform,K,l.pixelPosMatrix)))}return Be}loadMatchingFeature(l,d,y,w,T,K,D,z,Q,ie,le){const ge=this.bucketLayerIDs[d];if(K&&!function($e,tt){for(let St=0;St<$e.length;St++)if(tt.indexOf($e[St])>=0)return!0;return!1}(K,ge))return;const Oe=this.sourceLayerCoder.decode(y),Be=this.vtLayers[Oe].feature(w);if(T.needGeometry){const $e=hl(Be,!0);if(!T.filter(new go(this.tileID.overscaledZ),$e,this.tileID.canonical))return}else if(!T.filter(new go(this.tileID.overscaledZ),Be))return;const ze=this.getId(Be,Oe);for(let $e=0;$e<ge.length;$e++){const tt=ge[$e];if(K&&K.indexOf(tt)<0)continue;const St=z[tt];if(!St)continue;let lt={};ze&&ie&&(lt=ie.getState(St.sourceLayer||"_geojsonTileLayer",ze));const vt=ye({},Q[tt]);vt.paint=jb(vt.paint,St.paint,Be,lt,D),vt.layout=jb(vt.layout,St.layout,Be,lt,D);const tn=!le||le(Be,St,lt);if(!tn)continue;const an=new Lb(Be,this.z,this.x,this.y,ze);an.layer=vt;let Vn=l[tt];Vn===void 0&&(Vn=l[tt]=[]),Vn.push({featureIndex:w,feature:an,intersectionZ:tn})}}lookupSymbolFeatures(l,d,y,w,T,K,D,z){const Q={};this.loadVTLayers();const ie=wl(T);for(const le of l)this.loadMatchingFeature(Q,y,w,le,ie,K,D,z,d);return Q}hasLayer(l){for(const d of this.bucketLayerIDs)for(const y of d)if(l===y)return!0;return!1}getId(l,d){let y=l.id;return this.promoteId&&(y=l.properties[typeof this.promoteId=="string"?this.promoteId:this.promoteId[d]],typeof y=="boolean"&&(y=Number(y))),y}}function jb(c,l,d,y,w){return Ne(c,(T,K)=>{const D=l instanceof uc?l.get(K):null;return D&&D.evaluate?D.evaluate(d,y,w):D})}function Wb(c){let l=1/0,d=1/0,y=-1/0,w=-1/0;for(const T of c)l=Math.min(l,T.x),d=Math.min(d,T.y),y=Math.max(y,T.x),w=Math.max(w,T.y);return{minX:l,minY:d,maxX:y,maxY:w}}function cw(c,l){return l-c}function Nb(c,l,d,y,w){const T=[];for(let K=0;K<c.length;K++){const D=c[K];let z;for(let Q=0;Q<D.length-1;Q++){let ie=D[Q],le=D[Q+1];ie.x<l&&le.x<l||(ie.x<l?ie=new B(l,ie.y+(l-ie.x)/(le.x-ie.x)*(le.y-ie.y))._round():le.x<l&&(le=new B(l,ie.y+(l-ie.x)/(le.x-ie.x)*(le.y-ie.y))._round()),ie.y<d&&le.y<d||(ie.y<d?ie=new B(ie.x+(d-ie.y)/(le.y-ie.y)*(le.x-ie.x),d)._round():le.y<d&&(le=new B(ie.x+(d-ie.y)/(le.y-ie.y)*(le.x-ie.x),d)._round()),ie.x>=y&&le.x>=y||(ie.x>=y?ie=new B(y,ie.y+(y-ie.x)/(le.x-ie.x)*(le.y-ie.y))._round():le.x>=y&&(le=new B(y,ie.y+(y-ie.x)/(le.x-ie.x)*(le.y-ie.y))._round()),ie.y>=w&&le.y>=w||(ie.y>=w?ie=new B(ie.x+(w-ie.y)/(le.y-ie.y)*(le.x-ie.x),w)._round():le.y>=w&&(le=new B(ie.x+(w-ie.y)/(le.y-ie.y)*(le.x-ie.x),w)._round()),z&&ie.equals(z[z.length-1])||(z=[ie],T.push(z)),z.push(le)))))}}return T}jn("FeatureIndex",zb,{omit:["rawTileData","sourceLayerCoder"]});class jh extends B{constructor(l,d,y,w){super(l,d),this.angle=y,w!==void 0&&(this.segment=w)}clone(){return new jh(this.x,this.y,this.angle,this.segment)}}function Cv(c,l,d,y,w){if(l.segment===void 0||d===0)return!0;let T=l,K=l.segment+1,D=0;for(;D>-d/2;){if(K--,K<0)return!1;D-=c[K].dist(T),T=c[K]}D+=c[K].dist(c[K+1]),K++;const z=[];let Q=0;for(;D<d/2;){const ie=c[K],le=c[K+1];if(!le)return!1;let ge=c[K-1].angleTo(ie)-ie.angleTo(le);for(ge=Math.abs((ge+3*Math.PI)%(2*Math.PI)-Math.PI),z.push({distance:D,angleDelta:ge}),Q+=ge;D-z[0].distance>y;)Q-=z.shift().angleDelta;if(Q>w)return!1;K++,D+=ie.dist(le)}return!0}function _v(c){let l=0;for(let d=0;d<c.length-1;d++)l+=c[d].dist(c[d+1]);return l}function Gb(c,l,d){return c?.6*l*d:0}function Qb(c,l){return Math.max(c?c.right-c.left:0,l?l.right-l.left:0)}function dw(c,l,d,y,w,T){const K=Gb(d,w,T),D=Qb(d,y)*T;let z=0;const Q=_v(c)/2;for(let ie=0;ie<c.length-1;ie++){const le=c[ie],ge=c[ie+1],Oe=le.dist(ge);if(z+Oe>Q){const Be=(Q-z)/Oe,ze=Sr.number(le.x,ge.x,Be),$e=Sr.number(le.y,ge.y,Be),tt=new jh(ze,$e,ge.angleTo(le),ie);return tt._round(),!K||Cv(c,tt,D,K,l)?tt:void 0}z+=Oe}}function hw(c,l,d,y,w,T,K,D,z){const Q=Gb(y,T,K),ie=Qb(y,w),le=ie*K,ge=c[0].x===0||c[0].x===z||c[0].y===0||c[0].y===z;return l-le<l/4&&(l=le+l/4),c0(c,ge?l/2*D%l:(ie/2+2*T)*K*D%l,l,Q,d,le,ge,!1,z)}function c0(c,l,d,y,w,T,K,D,z){const Q=T/2,ie=_v(c);let le=0,ge=l-d,Oe=[];for(let Be=0;Be<c.length-1;Be++){const ze=c[Be],$e=c[Be+1],tt=ze.dist($e),St=$e.angleTo(ze);for(;ge+d<le+tt;){ge+=d;const lt=(ge-le)/tt,vt=Sr.number(ze.x,$e.x,lt),tn=Sr.number(ze.y,$e.y,lt);if(vt>=0&&vt<z&&tn>=0&&tn<z&&ge-Q>=0&&ge+Q<=ie){const an=new jh(vt,tn,St,Be);an._round(),y&&!Cv(c,an,T,y,w)||Oe.push(an)}}le+=tt}return D||Oe.length||K||(Oe=c0(c,le/2,d,y,w,T,K,!0,z)),Oe}jn("Anchor",jh);const Wp=To;function $b(c,l,d,y){const w=[],T=c.image,K=T.pixelRatio,D=T.paddedRect.w-2*Wp,z=T.paddedRect.h-2*Wp,Q=c.right-c.left,ie=c.bottom-c.top,le=T.stretchX||[[0,D]],ge=T.stretchY||[[0,z]],Oe=(Kn,ur)=>Kn+ur[1]-ur[0],Be=le.reduce(Oe,0),ze=ge.reduce(Oe,0),$e=D-Be,tt=z-ze;let St=0,lt=Be,vt=0,tn=ze,an=0,Vn=$e,cr=0,xn=tt;if(T.content&&y){const Kn=T.content;St=Y1(le,0,Kn[0]),vt=Y1(ge,0,Kn[1]),lt=Y1(le,Kn[0],Kn[2]),tn=Y1(ge,Kn[1],Kn[3]),an=Kn[0]-St,cr=Kn[1]-vt,Vn=Kn[2]-Kn[0]-lt,xn=Kn[3]-Kn[1]-tn}const Cn=(Kn,ur,Dn,wn)=>{const Kr=q1(Kn.stretch-St,lt,Q,c.left),wr=V1(Kn.fixed-an,Vn,Kn.stretch,Be),Bi=q1(ur.stretch-vt,tn,ie,c.top),ea=V1(ur.fixed-cr,xn,ur.stretch,ze),No=q1(Dn.stretch-St,lt,Q,c.left),Xa=V1(Dn.fixed-an,Vn,Dn.stretch,Be),Lu=q1(wn.stretch-vt,tn,ie,c.top),Kl=V1(wn.fixed-cr,xn,wn.stretch,ze),ka=new B(Kr,Bi),Go=new B(No,Bi),Ja=new B(No,Lu),Xl=new B(Kr,Lu),Jl=new B(wr/K,ea/K),ks=new B(Xa/K,Kl/K),Is=l*Math.PI/180;if(Is){const Ia=Math.sin(Is),Hr=Math.cos(Is),eu=[Hr,-Ia,Ia,Hr];ka._matMult(eu),Go._matMult(eu),Xl._matMult(eu),Ja._matMult(eu)}const Pl=Kn.stretch+Kn.fixed,Fl=ur.stretch+ur.fixed;return{tl:ka,tr:Go,bl:Xl,br:Ja,tex:{x:T.paddedRect.x+Wp+Pl,y:T.paddedRect.y+Wp+Fl,w:Dn.stretch+Dn.fixed-Pl,h:wn.stretch+wn.fixed-Fl},writingMode:void 0,glyphOffset:[0,0],sectionIndex:0,pixelOffsetTL:Jl,pixelOffsetBR:ks,minFontScaleX:Vn/K/Q,minFontScaleY:xn/K/ie,isSDF:d}};if(y&&(T.stretchX||T.stretchY)){const Kn=Yb(le,$e,Be),ur=Yb(ge,tt,ze);for(let Dn=0;Dn<Kn.length-1;Dn++){const wn=Kn[Dn],Kr=Kn[Dn+1];for(let wr=0;wr<ur.length-1;wr++)w.push(Cn(wn,ur[wr],Kr,ur[wr+1]))}}else w.push(Cn({fixed:0,stretch:-1},{fixed:0,stretch:-1},{fixed:0,stretch:D+1},{fixed:0,stretch:z+1}));return w}function Y1(c,l,d){let y=0;for(const w of c)y+=Math.max(l,Math.min(d,w[1]))-Math.max(l,Math.min(d,w[0]));return y}function Yb(c,l,d){const y=[{fixed:-Wp,stretch:0}];for(const[w,T]of c){const K=y[y.length-1];y.push({fixed:w-K.stretch,stretch:K.stretch}),y.push({fixed:w-K.stretch,stretch:K.stretch+(T-w)})}return y.push({fixed:l+Wp,stretch:d}),y}function q1(c,l,d,y){return c/l*d+y}function V1(c,l,d,y){return c-l*d/y}class H1{constructor(l,d,y,w,T,K,D,z,Q,ie){if(this.boxStartIndex=l.length,Q){let le=K.top,ge=K.bottom;const Oe=K.collisionPadding;Oe&&(le-=Oe[1],ge+=Oe[3]);let Be=ge-le;Be>0&&(Be=Math.max(10,Be),this.circleDiameter=Be)}else{let le=K.top*D-z[0],ge=K.bottom*D+z[2],Oe=K.left*D-z[3],Be=K.right*D+z[1];const ze=K.collisionPadding;if(ze&&(Oe-=ze[0]*D,le-=ze[1]*D,Be+=ze[2]*D,ge+=ze[3]*D),ie){const $e=new B(Oe,le),tt=new B(Be,le),St=new B(Oe,ge),lt=new B(Be,ge),vt=ie*Math.PI/180;$e._rotate(vt),tt._rotate(vt),St._rotate(vt),lt._rotate(vt),Oe=Math.min($e.x,tt.x,St.x,lt.x),Be=Math.max($e.x,tt.x,St.x,lt.x),le=Math.min($e.y,tt.y,St.y,lt.y),ge=Math.max($e.y,tt.y,St.y,lt.y)}l.emplaceBack(d.x,d.y,Oe,le,Be,ge,y,w,T)}this.boxEndIndex=l.length}}class fw{constructor(l=[],d=pw){if(this.data=l,this.length=this.data.length,this.compare=d,this.length>0)for(let y=(this.length>>1)-1;y>=0;y--)this._down(y)}push(l){this.data.push(l),this.length++,this._up(this.length-1)}pop(){if(this.length===0)return;const l=this.data[0],d=this.data.pop();return this.length--,this.length>0&&(this.data[0]=d,this._down(0)),l}peek(){return this.data[0]}_up(l){const{data:d,compare:y}=this,w=d[l];for(;l>0;){const T=l-1>>1,K=d[T];if(y(w,K)>=0)break;d[l]=K,l=T}d[l]=w}_down(l){const{data:d,compare:y}=this,w=this.length>>1,T=d[l];for(;l<w;){let K=1+(l<<1),D=d[K];const z=K+1;if(z<this.length&&y(d[z],D)<0&&(K=z,D=d[z]),y(D,T)>=0)break;d[l]=D,l=K}d[l]=T}}function pw(c,l){return c<l?-1:c>l?1:0}function mw(c,l=1,d=!1){let y=1/0,w=1/0,T=-1/0,K=-1/0;const D=c[0];for(let Oe=0;Oe<D.length;Oe++){const Be=D[Oe];(!Oe||Be.x<y)&&(y=Be.x),(!Oe||Be.y<w)&&(w=Be.y),(!Oe||Be.x>T)&&(T=Be.x),(!Oe||Be.y>K)&&(K=Be.y)}const z=Math.min(T-y,K-w);let Q=z/2;const ie=new fw([],gw);if(z===0)return new B(y,w);for(let Oe=y;Oe<T;Oe+=z)for(let Be=w;Be<K;Be+=z)ie.push(new Xd(Oe+Q,Be+Q,Q,c));let le=function(Oe){let Be=0,ze=0,$e=0;const tt=Oe[0];for(let St=0,lt=tt.length,vt=lt-1;St<lt;vt=St++){const tn=tt[St],an=tt[vt],Vn=tn.x*an.y-an.x*tn.y;ze+=(tn.x+an.x)*Vn,$e+=(tn.y+an.y)*Vn,Be+=3*Vn}return new Xd(ze/Be,$e/Be,0,Oe)}(c),ge=ie.length;for(;ie.length;){const Oe=ie.pop();(Oe.d>le.d||!le.d)&&(le=Oe,d&&console.log("found best %d after %d probes",Math.round(1e4*Oe.d)/1e4,ge)),Oe.max-le.d<=l||(Q=Oe.h/2,ie.push(new Xd(Oe.p.x-Q,Oe.p.y-Q,Q,c)),ie.push(new Xd(Oe.p.x+Q,Oe.p.y-Q,Q,c)),ie.push(new Xd(Oe.p.x-Q,Oe.p.y+Q,Q,c)),ie.push(new Xd(Oe.p.x+Q,Oe.p.y+Q,Q,c)),ge+=4)}return d&&(console.log(`num probes: ${ge}`),console.log(`best distance: ${le.d}`)),le.p}function gw(c,l){return l.max-c.max}function Xd(c,l,d,y){this.p=new B(c,l),this.h=d,this.d=function(w,T){let K=!1,D=1/0;for(let z=0;z<T.length;z++){const Q=T[z];for(let ie=0,le=Q.length,ge=le-1;ie<le;ge=ie++){const Oe=Q[ie],Be=Q[ge];Oe.y>w.y!=Be.y>w.y&&w.x<(Be.x-Oe.x)*(w.y-Oe.y)/(Be.y-Oe.y)+Oe.x&&(K=!K),D=Math.min(D,Kh(w,Oe,Be))}}return(K?1:-1)*Math.sqrt(D)}(this.p,y),this.max=this.d+this.h*Math.SQRT2}var pl;a.ap=void 0,(pl=a.ap||(a.ap={}))[pl.center=1]="center",pl[pl.left=2]="left",pl[pl.right=3]="right",pl[pl.top=4]="top",pl[pl.bottom=5]="bottom",pl[pl["top-left"]=6]="top-left",pl[pl["top-right"]=7]="top-right",pl[pl["bottom-left"]=8]="bottom-left",pl[pl["bottom-right"]=9]="bottom-right";const Jd=7,Z1=Number.POSITIVE_INFINITY;function X1(c,l){return l[1]!==Z1?function(d,y,w){let T=0,K=0;switch(y=Math.abs(y),w=Math.abs(w),d){case"top-right":case"top-left":case"top":K=w-Jd;break;case"bottom-right":case"bottom-left":case"bottom":K=-w+Jd}switch(d){case"top-right":case"bottom-right":case"right":T=-y;break;case"top-left":case"bottom-left":case"left":T=y}return[T,K]}(c,l[0],l[1]):function(d,y){let w=0,T=0;y<0&&(y=0);const K=y/Math.SQRT2;switch(d){case"top-right":case"top-left":T=K-Jd;break;case"bottom-right":case"bottom-left":T=-K+Jd;break;case"bottom":T=-y+Jd;break;case"top":T=y-Jd}switch(d){case"top-right":case"bottom-right":w=-K;break;case"top-left":case"bottom-left":w=K;break;case"left":w=y;break;case"right":w=-y}return[w,T]}(c,l[0])}function bv(c,l,d){var y;const w=c.layout,T=(y=w.get("text-variable-anchor-offset"))===null||y===void 0?void 0:y.evaluate(l,{},d);if(T){const D=T.values,z=[];for(let Q=0;Q<D.length;Q+=2){const ie=z[Q]=D[Q],le=D[Q+1].map(ge=>ge*Zt);ie.startsWith("top")?le[1]-=Jd:ie.startsWith("bottom")&&(le[1]+=Jd),z[Q+1]=le}return new ve(z)}const K=w.get("text-variable-anchor");if(K){let D;D=c._unevaluatedLayout.getValue("text-radial-offset")!==void 0?[w.get("text-radial-offset").evaluate(l,{},d)*Zt,Z1]:w.get("text-offset").evaluate(l,{},d).map(Q=>Q*Zt);const z=[];for(const Q of K)z.push(Q,X1(Q,D));return new ve(z)}return null}function J1(c){switch(c){case"right":case"top-right":case"bottom-right":return"right";case"left":case"top-left":case"bottom-left":return"left"}return"center"}function qb(c,l,d,y,w,T,K,D,z,Q,ie){let le=T.textMaxSize.evaluate(l,{});le===void 0&&(le=K);const ge=c.layers[0].layout,Oe=ge.get("icon-offset").evaluate(l,{},ie),Be=Vb(d.horizontal),ze=K/24,$e=c.tilePixelRatio*ze,tt=c.tilePixelRatio*le/24,St=c.tilePixelRatio*D,lt=c.tilePixelRatio*ge.get("symbol-spacing"),vt=ge.get("text-padding")*c.tilePixelRatio,tn=function(wn,Kr,wr,Bi=1){const ea=wn.get("icon-padding").evaluate(Kr,{},wr),No=ea&&ea.values;return[No[0]*Bi,No[1]*Bi,No[2]*Bi,No[3]*Bi]}(ge,l,ie,c.tilePixelRatio),an=ge.get("text-max-angle")/180*Math.PI,Vn=ge.get("text-rotation-alignment")!=="viewport"&&ge.get("symbol-placement")!=="point",cr=ge.get("icon-rotation-alignment")==="map"&&ge.get("symbol-placement")!=="point",xn=ge.get("symbol-placement"),Cn=lt/2,Kn=ge.get("icon-text-fit");let ur;y&&Kn!=="none"&&(c.allowVerticalPlacement&&d.vertical&&(ur=N1(y,d.vertical,Kn,ge.get("icon-text-fit-padding"),Oe,ze)),Be&&(y=N1(y,Be,Kn,ge.get("icon-text-fit-padding"),Oe,ze)));const Dn=(wn,Kr)=>{Kr.x<0||Kr.x>=Wo||Kr.y<0||Kr.y>=Wo||function(wr,Bi,ea,No,Xa,Lu,Kl,ka,Go,Ja,Xl,Jl,ks,Is,Pl,Fl,Ia,Hr,eu,Ko,Wi,Dl,mi,Ts,AA){const zu=wr.addToLineVertexArray(Bi,ea);let Mc,eh,RA,cA,gu=0,th=0,p0=0,Xb=0,Bv=-1,kv=-1;const nh={};let Jb=vo("");if(wr.allowVerticalPlacement&&No.vertical){const Ul=ka.layout.get("text-rotate").evaluate(Wi,{},Ts)+90;RA=new H1(Go,Bi,Ja,Xl,Jl,No.vertical,ks,Is,Pl,Ul),Kl&&(cA=new H1(Go,Bi,Ja,Xl,Jl,Kl,Ia,Hr,Pl,Ul))}if(Xa){const Ul=ka.layout.get("icon-rotate").evaluate(Wi,{}),Wu=ka.layout.get("icon-text-fit")!=="none",$f=$b(Xa,Ul,mi,Wu),Ec=Kl?$b(Kl,Ul,mi,Wu):void 0;eh=new H1(Go,Bi,Ja,Xl,Jl,Xa,Ia,Hr,!1,Ul),gu=4*$f.length;const Yf=wr.iconSizeData;let Oc=null;Yf.kind==="source"?(Oc=[dd*ka.layout.get("icon-size").evaluate(Wi,{})],Oc[0]>Lh&&He(`${wr.layerIds[0]}: Value for "icon-size" is >= ${l0}. Reduce your "icon-size".`)):Yf.kind==="composite"&&(Oc=[dd*Dl.compositeIconSizes[0].evaluate(Wi,{},Ts),dd*Dl.compositeIconSizes[1].evaluate(Wi,{},Ts)],(Oc[0]>Lh||Oc[1]>Lh)&&He(`${wr.layerIds[0]}: Value for "icon-size" is >= ${l0}. Reduce your "icon-size".`)),wr.addSymbols(wr.icon,$f,Oc,Ko,eu,Wi,a.ah.none,Bi,zu.lineStartIndex,zu.lineLength,-1,Ts),Bv=wr.icon.placedSymbolArray.length-1,Ec&&(th=4*Ec.length,wr.addSymbols(wr.icon,Ec,Oc,Ko,eu,Wi,a.ah.vertical,Bi,zu.lineStartIndex,zu.lineLength,-1,Ts),kv=wr.icon.placedSymbolArray.length-1)}const ex=Object.keys(No.horizontal);for(const Ul of ex){const Wu=No.horizontal[Ul];if(!Mc){Jb=vo(Wu.text);const Ec=ka.layout.get("text-rotate").evaluate(Wi,{},Ts);Mc=new H1(Go,Bi,Ja,Xl,Jl,Wu,ks,Is,Pl,Ec)}const $f=Wu.positionedLines.length===1;if(p0+=xv(wr,Bi,Wu,Lu,ka,Pl,Wi,Fl,zu,No.vertical?a.ah.horizontal:a.ah.horizontalOnly,$f?ex:[Ul],nh,Bv,Dl,Ts),$f)break}No.vertical&&(Xb+=xv(wr,Bi,No.vertical,Lu,ka,Pl,Wi,Fl,zu,a.ah.vertical,["vertical"],nh,kv,Dl,Ts));const Iv=Mc?Mc.boxStartIndex:wr.collisionBoxArray.length,Cw=Mc?Mc.boxEndIndex:wr.collisionBoxArray.length,Tv=RA?RA.boxStartIndex:wr.collisionBoxArray.length,_w=RA?RA.boxEndIndex:wr.collisionBoxArray.length,bw=eh?eh.boxStartIndex:wr.collisionBoxArray.length,xw=eh?eh.boxEndIndex:wr.collisionBoxArray.length,ml=cA?cA.boxStartIndex:wr.collisionBoxArray.length,ju=cA?cA.boxEndIndex:wr.collisionBoxArray.length;let Sc=-1;const tg=(Ul,Wu)=>Ul&&Ul.circleDiameter?Math.max(Ul.circleDiameter,Wu):Wu;Sc=tg(Mc,Sc),Sc=tg(RA,Sc),Sc=tg(eh,Sc),Sc=tg(cA,Sc);const tx=Sc>-1?1:0;tx&&(Sc*=AA/Zt),wr.glyphOffsetArray.length>=jp.MAX_GLYPHS&&He("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907"),Wi.sortKey!==void 0&&wr.addToSortKeyRanges(wr.symbolInstances.length,Wi.sortKey);const nx=bv(ka,Wi,Ts),[ww,Mw]=function(Ul,Wu){const $f=Ul.length,Ec=Wu==null?void 0:Wu.values;if((Ec==null?void 0:Ec.length)>0)for(let Yf=0;Yf<Ec.length;Yf+=2){const Oc=Ec[Yf+1];Ul.emplaceBack(a.ap[Ec[Yf]],Oc[0],Oc[1])}return[$f,Ul.length]}(wr.textAnchorOffsets,nx);wr.symbolInstances.emplaceBack(Bi.x,Bi.y,nh.right>=0?nh.right:-1,nh.center>=0?nh.center:-1,nh.left>=0?nh.left:-1,nh.vertical||-1,Bv,kv,Jb,Iv,Cw,Tv,_w,bw,xw,ml,ju,Ja,p0,Xb,gu,th,tx,0,ks,Sc,ww,Mw)}(c,Kr,wn,d,y,w,ur,c.layers[0],c.collisionBoxArray,l.index,l.sourceLayerIndex,c.index,$e,[vt,vt,vt,vt],Vn,z,St,tn,cr,Oe,l,T,Q,ie,K)};if(xn==="line")for(const wn of Nb(l.geometry,0,0,Wo,Wo)){const Kr=hw(wn,lt,an,d.vertical||Be,y,24,tt,c.overscaling,Wo);for(const wr of Kr)Be&&yw(c,Be.text,Cn,wr)||Dn(wn,wr)}else if(xn==="line-center"){for(const wn of l.geometry)if(wn.length>1){const Kr=dw(wn,an,d.vertical||Be,y,24,tt);Kr&&Dn(wn,Kr)}}else if(l.type==="Polygon")for(const wn of e0(l.geometry,0)){const Kr=mw(wn,16);Dn(wn[0],new jh(Kr.x,Kr.y,0))}else if(l.type==="LineString")for(const wn of l.geometry)Dn(wn,new jh(wn[0].x,wn[0].y,0));else if(l.type==="Point")for(const wn of l.geometry)for(const Kr of wn)Dn([Kr],new jh(Kr.x,Kr.y,0))}function xv(c,l,d,y,w,T,K,D,z,Q,ie,le,ge,Oe,Be){const ze=function(St,lt,vt,tn,an,Vn,cr,xn){const Cn=tn.layout.get("text-rotate").evaluate(Vn,{})*Math.PI/180,Kn=[];for(const ur of lt.positionedLines)for(const Dn of ur.positionedGlyphs){if(!Dn.rect)continue;const wn=Dn.rect||{};let Kr=xc+1,wr=!0,Bi=1,ea=0;const No=(an||xn)&&Dn.vertical,Xa=Dn.metrics.advance*Dn.scale/2;if(xn&<.verticalizable&&(ea=ur.lineOffset/2-(Dn.imageName?-(Zt-Dn.metrics.width*Dn.scale)/2:(Dn.scale-1)*Zt)),Dn.imageName){const Ko=cr[Dn.imageName];wr=Ko.sdf,Bi=Ko.pixelRatio,Kr=To/Bi}const Lu=an?[Dn.x+Xa,Dn.y]:[0,0];let Kl=an?[0,0]:[Dn.x+Xa+vt[0],Dn.y+vt[1]-ea],ka=[0,0];No&&(ka=Kl,Kl=[0,0]);const Go=Dn.metrics.isDoubleResolution?2:1,Ja=(Dn.metrics.left-Kr)*Dn.scale-Xa+Kl[0],Xl=(-Dn.metrics.top-Kr)*Dn.scale+Kl[1],Jl=Ja+wn.w/Go*Dn.scale/Bi,ks=Xl+wn.h/Go*Dn.scale/Bi,Is=new B(Ja,Xl),Pl=new B(Jl,Xl),Fl=new B(Ja,ks),Ia=new B(Jl,ks);if(No){const Ko=new B(-Xa,Xa-a0),Wi=-Math.PI/2,Dl=Zt/2-Xa,mi=new B(5-a0-Dl,-(Dn.imageName?Dl:0)),Ts=new B(...ka);Is._rotateAround(Wi,Ko)._add(mi)._add(Ts),Pl._rotateAround(Wi,Ko)._add(mi)._add(Ts),Fl._rotateAround(Wi,Ko)._add(mi)._add(Ts),Ia._rotateAround(Wi,Ko)._add(mi)._add(Ts)}if(Cn){const Ko=Math.sin(Cn),Wi=Math.cos(Cn),Dl=[Wi,-Ko,Ko,Wi];Is._matMult(Dl),Pl._matMult(Dl),Fl._matMult(Dl),Ia._matMult(Dl)}const Hr=new B(0,0),eu=new B(0,0);Kn.push({tl:Is,tr:Pl,bl:Fl,br:Ia,tex:wn,writingMode:lt.writingMode,glyphOffset:Lu,sectionIndex:Dn.sectionIndex,isSDF:wr,pixelOffsetTL:Hr,pixelOffsetBR:eu,minFontScaleX:0,minFontScaleY:0})}return Kn}(0,d,D,w,T,K,y,c.allowVerticalPlacement),$e=c.textSizeData;let tt=null;$e.kind==="source"?(tt=[dd*w.layout.get("text-size").evaluate(K,{})],tt[0]>Lh&&He(`${c.layerIds[0]}: Value for "text-size" is >= ${l0}. Reduce your "text-size".`)):$e.kind==="composite"&&(tt=[dd*Oe.compositeTextSizes[0].evaluate(K,{},Be),dd*Oe.compositeTextSizes[1].evaluate(K,{},Be)],(tt[0]>Lh||tt[1]>Lh)&&He(`${c.layerIds[0]}: Value for "text-size" is >= ${l0}. Reduce your "text-size".`)),c.addSymbols(c.text,ze,tt,D,T,K,Q,l,z.lineStartIndex,z.lineLength,ge,Be);for(const St of ie)le[St]=c.text.placedSymbolArray.length-1;return 4*ze.length}function Vb(c){for(const l in c)return c[l];return null}function yw(c,l,d,y){const w=c.compareText;if(l in w){const T=w[l];for(let K=T.length-1;K>=0;K--)if(y.dist(T[K])<d)return!0}else w[l]=[];return w[l].push(y),!1}const Hb=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];class Np{static from(l){if(!(l instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");const[d,y]=new Uint8Array(l,0,2);if(d!==219)throw new Error("Data does not appear to be in a KDBush format.");const w=y>>4;if(w!==1)throw new Error(`Got v${w} data when expected v1.`);const T=Hb[15&y];if(!T)throw new Error("Unrecognized array type.");const[K]=new Uint16Array(l,2,1),[D]=new Uint32Array(l,4,1);return new Np(D,K,T,l)}constructor(l,d=64,y=Float64Array,w){if(isNaN(l)||l<0)throw new Error(`Unpexpected numItems value: ${l}.`);this.numItems=+l,this.nodeSize=Math.min(Math.max(+d,2),65535),this.ArrayType=y,this.IndexArrayType=l<65536?Uint16Array:Uint32Array;const T=Hb.indexOf(this.ArrayType),K=2*l*this.ArrayType.BYTES_PER_ELEMENT,D=l*this.IndexArrayType.BYTES_PER_ELEMENT,z=(8-D%8)%8;if(T<0)throw new Error(`Unexpected typed array class: ${y}.`);w&&w instanceof ArrayBuffer?(this.data=w,this.ids=new this.IndexArrayType(this.data,8,l),this.coords=new this.ArrayType(this.data,8+D+z,2*l),this._pos=2*l,this._finished=!0):(this.data=new ArrayBuffer(8+K+D+z),this.ids=new this.IndexArrayType(this.data,8,l),this.coords=new this.ArrayType(this.data,8+D+z,2*l),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,16+T]),new Uint16Array(this.data,2,1)[0]=d,new Uint32Array(this.data,4,1)[0]=l)}add(l,d){const y=this._pos>>1;return this.ids[y]=y,this.coords[this._pos++]=l,this.coords[this._pos++]=d,y}finish(){const l=this._pos>>1;if(l!==this.numItems)throw new Error(`Added ${l} items when expected ${this.numItems}.`);return Gp(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(l,d,y,w){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:T,coords:K,nodeSize:D}=this,z=[0,T.length-1,0],Q=[];for(;z.length;){const ie=z.pop()||0,le=z.pop()||0,ge=z.pop()||0;if(le-ge<=D){for(let $e=ge;$e<=le;$e++){const tt=K[2*$e],St=K[2*$e+1];tt>=l&&tt<=y&&St>=d&&St<=w&&Q.push(T[$e])}continue}const Oe=ge+le>>1,Be=K[2*Oe],ze=K[2*Oe+1];Be>=l&&Be<=y&&ze>=d&&ze<=w&&Q.push(T[Oe]),(ie===0?l<=Be:d<=ze)&&(z.push(ge),z.push(Oe-1),z.push(1-ie)),(ie===0?y>=Be:w>=ze)&&(z.push(Oe+1),z.push(le),z.push(1-ie))}return Q}within(l,d,y){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:w,coords:T,nodeSize:K}=this,D=[0,w.length-1,0],z=[],Q=y*y;for(;D.length;){const ie=D.pop()||0,le=D.pop()||0,ge=D.pop()||0;if(le-ge<=K){for(let $e=ge;$e<=le;$e++)wv(T[2*$e],T[2*$e+1],l,d)<=Q&&z.push(w[$e]);continue}const Oe=ge+le>>1,Be=T[2*Oe],ze=T[2*Oe+1];wv(Be,ze,l,d)<=Q&&z.push(w[Oe]),(ie===0?l-y<=Be:d-y<=ze)&&(D.push(ge),D.push(Oe-1),D.push(1-ie)),(ie===0?l+y>=Be:d+y>=ze)&&(D.push(Oe+1),D.push(le),D.push(1-ie))}return z}}function Gp(c,l,d,y,w,T){if(w-y<=d)return;const K=y+w>>1;Zb(c,l,K,y,w,T),Gp(c,l,d,y,K-1,1-T),Gp(c,l,d,K+1,w,1-T)}function Zb(c,l,d,y,w,T){for(;w>y;){if(w-y>600){const Q=w-y+1,ie=d-y+1,le=Math.log(Q),ge=.5*Math.exp(2*le/3),Oe=.5*Math.sqrt(le*ge*(Q-ge)/Q)*(ie-Q/2<0?-1:1);Zb(c,l,d,Math.max(y,Math.floor(d-ie*ge/Q+Oe)),Math.min(w,Math.floor(d+(Q-ie)*ge/Q+Oe)),T)}const K=l[2*d+T];let D=y,z=w;for(d0(c,l,y,d),l[2*w+T]>K&&d0(c,l,y,w);D<z;){for(d0(c,l,D,z),D++,z--;l[2*D+T]<K;)D++;for(;l[2*z+T]>K;)z--}l[2*y+T]===K?d0(c,l,y,z):(z++,d0(c,l,z,w)),z<=d&&(y=z+1),d<=z&&(w=z-1)}}function d0(c,l,d,y){h0(c,d,y),h0(l,2*d,2*y),h0(l,2*d+1,2*y+1)}function h0(c,l,d){const y=c[l];c[l]=c[d],c[d]=y}function wv(c,l,d,y){const w=c-d,T=l-y;return w*w+T*T}var Mv;a.bb=void 0,(Mv=a.bb||(a.bb={})).create="create",Mv.load="load",Mv.fullLoad="fullLoad";let eg=null,f0=[];const Sv=1e3/60,Ev="loadTime",Ov="fullLoadTime",vw={mark(c){performance.mark(c)},frame(c){const l=c;eg!=null&&f0.push(l-eg),eg=l},clearMetrics(){eg=null,f0=[],performance.clearMeasures(Ev),performance.clearMeasures(Ov);for(const c in a.bb)performance.clearMarks(a.bb[c])},getPerformanceMetrics(){performance.measure(Ev,a.bb.create,a.bb.load),performance.measure(Ov,a.bb.create,a.bb.fullLoad);const c=performance.getEntriesByName(Ev)[0].duration,l=performance.getEntriesByName(Ov)[0].duration,d=f0.length,y=1/(f0.reduce((T,K)=>T+K,0)/d/1e3),w=f0.filter(T=>T>Sv).reduce((T,K)=>T+(K-Sv)/Sv,0);return{loadTime:c,fullLoadTime:l,fps:y,percentDroppedFrames:w/(d+w)*100,totalFrames:d}}};a.$=xr,a.A=Ph,a.B=function(c){if(Jt==null){const l=c.navigator?c.navigator.userAgent:null;Jt=!!c.safari||!(!l||!(/\b(iPad|iPhone|iPod)\b/.test(l)||l.match("Safari")&&!l.match("Chrome")))}return Jt},a.C=class{constructor(c,l){this.target=c,this.mapId=l,this.resolveRejects={},this.tasks={},this.taskQueue=[],this.abortControllers={},this.messageHandlers={},this.invoker=new Aw(()=>this.process()),this.subscription=function(d,y,w,T){return d.addEventListener(y,w,!1),{unsubscribe:()=>{d.removeEventListener(y,w,!1)}}}(this.target,"message",d=>this.receive(d)),this.globalScope=Ft(self)?c:window}registerMessageHandler(c,l){this.messageHandlers[c]=l}sendAsync(c,l){return new Promise((d,y)=>{const w=Math.round(1e18*Math.random()).toString(36).substring(0,10);this.resolveRejects[w]={resolve:d,reject:y},l&&l.signal.addEventListener("abort",()=>{delete this.resolveRejects[w];const D={id:w,type:"<cancel>",origin:location.origin,targetMapId:c.targetMapId,sourceMapId:this.mapId};this.target.postMessage(D)},{once:!0});const T=[],K=Object.assign(Object.assign({},c),{id:w,sourceMapId:this.mapId,origin:location.origin,data:oc(c.data,T)});this.target.postMessage(K,{transfer:T})})}receive(c){const l=c.data,d=l.id;if(l.origin===location.origin&&(!l.targetMapId||this.mapId===l.targetMapId)){if(l.type==="<cancel>"){delete this.tasks[d];const y=this.abortControllers[d];return delete this.abortControllers[d],void(y&&y.abort())}if(Ft(self)||l.mustQueue)return this.tasks[d]=l,this.taskQueue.push(d),void this.invoker.trigger();this.processTask(d,l)}}process(){if(this.taskQueue.length===0)return;const c=this.taskQueue.shift(),l=this.tasks[c];delete this.tasks[c],this.taskQueue.length>0&&this.invoker.trigger(),l&&this.processTask(c,l)}processTask(c,l){return f(this,void 0,void 0,function*(){if(l.type==="<response>"){const w=this.resolveRejects[c];return delete this.resolveRejects[c],w?void(l.error?w.reject(cl(l.error)):w.resolve(cl(l.data))):void 0}if(!this.messageHandlers[l.type])return void this.completeTask(c,new Error(`Could not find a registered handler for ${l.type}, map ID: ${this.mapId}, available handlers: ${Object.keys(this.messageHandlers).join(", ")}`));const d=cl(l.data),y=new AbortController;this.abortControllers[c]=y;try{const w=yield this.messageHandlers[l.type](l.sourceMapId,d,y);this.completeTask(c,null,w)}catch(w){this.completeTask(c,w)}})}completeTask(c,l,d){const y=[];delete this.abortControllers[c];const w={id:c,type:"<response>",sourceMapId:this.mapId,origin:location.origin,error:l?oc(l):null,data:oc(d,y)};this.target.postMessage(w,{transfer:y})}remove(){this.invoker.remove(),this.subscription.unsubscribe()}},a.D=gr,a.E=zn,a.F=function(){var c=new Ph(16);return Ph!=Float32Array&&(c[1]=0,c[2]=0,c[3]=0,c[4]=0,c[6]=0,c[7]=0,c[8]=0,c[9]=0,c[11]=0,c[12]=0,c[13]=0,c[14]=0),c[0]=1,c[5]=1,c[10]=1,c[15]=1,c},a.G=Se,a.H=function(c,l,d){var y,w,T,K,D,z,Q,ie,le,ge,Oe,Be,ze=d[0],$e=d[1],tt=d[2];return l===c?(c[12]=l[0]*ze+l[4]*$e+l[8]*tt+l[12],c[13]=l[1]*ze+l[5]*$e+l[9]*tt+l[13],c[14]=l[2]*ze+l[6]*$e+l[10]*tt+l[14],c[15]=l[3]*ze+l[7]*$e+l[11]*tt+l[15]):(w=l[1],T=l[2],K=l[3],D=l[4],z=l[5],Q=l[6],ie=l[7],le=l[8],ge=l[9],Oe=l[10],Be=l[11],c[0]=y=l[0],c[1]=w,c[2]=T,c[3]=K,c[4]=D,c[5]=z,c[6]=Q,c[7]=ie,c[8]=le,c[9]=ge,c[10]=Oe,c[11]=Be,c[12]=y*ze+D*$e+le*tt+l[12],c[13]=w*ze+z*$e+ge*tt+l[13],c[14]=T*ze+Q*$e+Oe*tt+l[14],c[15]=K*ze+ie*$e+Be*tt+l[15]),c},a.I=cd,a.J=function(c,l,d){var y=d[0],w=d[1],T=d[2];return c[0]=l[0]*y,c[1]=l[1]*y,c[2]=l[2]*y,c[3]=l[3]*y,c[4]=l[4]*w,c[5]=l[5]*w,c[6]=l[6]*w,c[7]=l[7]*w,c[8]=l[8]*T,c[9]=l[9]*T,c[10]=l[10]*T,c[11]=l[11]*T,c[12]=l[12],c[13]=l[13],c[14]=l[14],c[15]=l[15],c},a.K=Js,a.L=function(c,l){const d={};for(let y=0;y<l.length;y++){const w=l[y];w in c&&(d[w]=c[w])}return d},a.M=zh,a.N=gv,a.O=Pb,a.P=B,a.Q=uA,a.R=Ss,a.S=q,a.T=Of,a.U=oe,a.V=nt,a.W=Wo,a.X=zo,a.Y=$1,a.Z=class extends Bf{},a._=f,a.a=kt,a.a$=function(c,l){return c[0]*l[0]+c[1]*l[1]+c[2]*l[2]+c[3]*l[3]},a.a0=vv,a.a1=me,a.a2=c=>{const l=window.document.createElement("video");return l.muted=!0,new Promise(d=>{l.onloadstart=()=>{d(l)};for(const y of c){const w=window.document.createElement("source");Ze(y)||(l.crossOrigin="Anonymous"),w.src=y,l.appendChild(w)}})},a.a3=function(){return Re++},a.a4=u,a.a5=jp,a.a6=wl,a.a7=hl,a.a8=go,a.a9=Lb,a.aA=ct,a.aB=function(c,l){if(!c)return[{command:"setStyle",args:[l]}];let d=[];try{if(!Sn(c.version,l.version))return[{command:"setStyle",args:[l]}];Sn(c.center,l.center)||d.push({command:"setCenter",args:[l.center]}),Sn(c.zoom,l.zoom)||d.push({command:"setZoom",args:[l.zoom]}),Sn(c.bearing,l.bearing)||d.push({command:"setBearing",args:[l.bearing]}),Sn(c.pitch,l.pitch)||d.push({command:"setPitch",args:[l.pitch]}),Sn(c.sprite,l.sprite)||d.push({command:"setSprite",args:[l.sprite]}),Sn(c.glyphs,l.glyphs)||d.push({command:"setGlyphs",args:[l.glyphs]}),Sn(c.transition,l.transition)||d.push({command:"setTransition",args:[l.transition]}),Sn(c.light,l.light)||d.push({command:"setLight",args:[l.light]}),Sn(c.terrain,l.terrain)||d.push({command:"setTerrain",args:[l.terrain]});const y={},w=[];(function(K,D,z,Q){let ie;for(ie in D=D||{},K=K||{})Object.prototype.hasOwnProperty.call(K,ie)&&(Object.prototype.hasOwnProperty.call(D,ie)||Qr(ie,z,Q));for(ie in D)Object.prototype.hasOwnProperty.call(D,ie)&&(Object.prototype.hasOwnProperty.call(K,ie)?Sn(K[ie],D[ie])||(K[ie].type==="geojson"&&D[ie].type==="geojson"&&vi(K,D,ie)?nr(z,{command:"setGeoJSONSourceData",args:[ie,D[ie].data]}):_r(ie,D,z,Q)):Mr(ie,D,z))})(c.sources,l.sources,w,y);const T=[];c.layers&&c.layers.forEach(K=>{"source"in K&&y[K.source]?d.push({command:"removeLayer",args:[K.id]}):T.push(K)}),d=d.concat(w),function(K,D,z){D=D||[];const Q=(K=K||[]).map(V),ie=D.map(V),le=K.reduce(X,{}),ge=D.reduce(X,{}),Oe=Q.slice(),Be=Object.create(null);let ze,$e,tt,St,lt;for(let vt=0,tn=0;vt<Q.length;vt++)ze=Q[vt],Object.prototype.hasOwnProperty.call(ge,ze)?tn++:(nr(z,{command:"removeLayer",args:[ze]}),Oe.splice(Oe.indexOf(ze,tn),1));for(let vt=0,tn=0;vt<ie.length;vt++)ze=ie[ie.length-1-vt],Oe[Oe.length-1-vt]!==ze&&(Object.prototype.hasOwnProperty.call(le,ze)?(nr(z,{command:"removeLayer",args:[ze]}),Oe.splice(Oe.lastIndexOf(ze,Oe.length-tn),1)):tn++,St=Oe[Oe.length-vt],nr(z,{command:"addLayer",args:[ge[ze],St]}),Oe.splice(Oe.length-vt,0,ze),Be[ze]=!0);for(let vt=0;vt<ie.length;vt++)if(ze=ie[vt],$e=le[ze],tt=ge[ze],!Be[ze]&&!Sn($e,tt))if(Sn($e.source,tt.source)&&Sn($e["source-layer"],tt["source-layer"])&&Sn($e.type,tt.type)){for(lt in we($e.layout,tt.layout,z,ze,null,"setLayoutProperty"),we($e.paint,tt.paint,z,ze,null,"setPaintProperty"),Sn($e.filter,tt.filter)||nr(z,{command:"setFilter",args:[ze,tt.filter]}),Sn($e.minzoom,tt.minzoom)&&Sn($e.maxzoom,tt.maxzoom)||nr(z,{command:"setLayerZoomRange",args:[ze,tt.minzoom,tt.maxzoom]}),$e)Object.prototype.hasOwnProperty.call($e,lt)&<!=="layout"&<!=="paint"&<!=="filter"&<!=="metadata"&<!=="minzoom"&<!=="maxzoom"&&(lt.indexOf("paint.")===0?we($e[lt],tt[lt],z,ze,lt.slice(6),"setPaintProperty"):Sn($e[lt],tt[lt])||nr(z,{command:"setLayerProperty",args:[ze,lt,tt[lt]]}));for(lt in tt)Object.prototype.hasOwnProperty.call(tt,lt)&&!Object.prototype.hasOwnProperty.call($e,lt)&<!=="layout"&<!=="paint"&<!=="filter"&<!=="metadata"&<!=="minzoom"&<!=="maxzoom"&&(lt.indexOf("paint.")===0?we($e[lt],tt[lt],z,ze,lt.slice(6),"setPaintProperty"):Sn($e[lt],tt[lt])||nr(z,{command:"setLayerProperty",args:[ze,lt,tt[lt]]}))}else nr(z,{command:"removeLayer",args:[ze]}),St=Oe[Oe.lastIndexOf(ze)+1],nr(z,{command:"addLayer",args:[tt,St]})}(T,l.layers,d)}catch(y){console.warn("Unable to compute style diff:",y),d=[{command:"setStyle",args:[l]}]}return d},a.aC=function(c){const l=[],d=c.id;return d===void 0&&l.push({message:`layers.${d}: missing required property "id"`}),c.render===void 0&&l.push({message:`layers.${d}: missing required method "render"`}),c.renderingMode&&c.renderingMode!=="2d"&&c.renderingMode!=="3d"&&l.push({message:`layers.${d}: property "renderingMode" must be either "2d" or "3d"`}),l},a.aD=function c(l,d){if(Array.isArray(l)){if(!Array.isArray(d)||l.length!==d.length)return!1;for(let y=0;y<l.length;y++)if(!c(l[y],d[y]))return!1;return!0}if(typeof l=="object"&&l!==null&&d!==null){if(typeof d!="object"||Object.keys(l).length!==Object.keys(d).length)return!1;for(const y in l)if(!c(l[y],d[y]))return!1;return!0}return l===d},a.aE=Ne,a.aF=rt,a.aG=class extends no{constructor(c,l){super(c,l),this.current=0}set(c){this.current!==c&&(this.current=c,this.gl.uniform1i(this.location,c))}},a.aH=ws,a.aI=class extends no{constructor(c,l){super(c,l),this.current=aA}set(c){if(c[12]!==this.current[12]||c[0]!==this.current[0])return this.current=c,void this.gl.uniformMatrix4fv(this.location,!1,c);for(let l=1;l<16;l++)if(c[l]!==this.current[l]){this.current=c,this.gl.uniformMatrix4fv(this.location,!1,c);break}}},a.aJ=Pu,a.aK=class extends no{constructor(c,l){super(c,l),this.current=[0,0,0]}set(c){c[0]===this.current[0]&&c[1]===this.current[1]&&c[2]===this.current[2]||(this.current=c,this.gl.uniform3f(this.location,c[0],c[1],c[2]))}},a.aL=class extends no{constructor(c,l){super(c,l),this.current=[0,0]}set(c){c[0]===this.current[0]&&c[1]===this.current[1]||(this.current=c,this.gl.uniform2f(this.location,c[0],c[1]))}},a.aM=Ms,a.aN=function(c,l,d,y,w,T,K){var D=1/(l-d),z=1/(y-w),Q=1/(T-K);return c[0]=-2*D,c[1]=0,c[2]=0,c[3]=0,c[4]=0,c[5]=-2*z,c[6]=0,c[7]=0,c[8]=0,c[9]=0,c[10]=2*Q,c[11]=0,c[12]=(l+d)*D,c[13]=(w+y)*z,c[14]=(K+T)*Q,c[15]=1,c},a.aO=Ai,a.aP=ev,a.aQ=class extends Ku{},a.aR=Mt,a.aS=class extends kl{},a.aT=function(c){return c<=1?1:Math.pow(2,Math.ceil(Math.log(c)/Math.LN2))},a.aU=od,a.aV=Me,a.aW=class extends kf{},a.aX=hn,a.aY=function(c,l){var d=c[0],y=c[1],w=c[2],T=c[3],K=c[4],D=c[5],z=c[6],Q=c[7],ie=c[8],le=c[9],ge=c[10],Oe=c[11],Be=c[12],ze=c[13],$e=c[14],tt=c[15],St=l[0],lt=l[1],vt=l[2],tn=l[3],an=l[4],Vn=l[5],cr=l[6],xn=l[7],Cn=l[8],Kn=l[9],ur=l[10],Dn=l[11],wn=l[12],Kr=l[13],wr=l[14],Bi=l[15];return Math.abs(d-St)<=Xs*Math.max(1,Math.abs(d),Math.abs(St))&&Math.abs(y-lt)<=Xs*Math.max(1,Math.abs(y),Math.abs(lt))&&Math.abs(w-vt)<=Xs*Math.max(1,Math.abs(w),Math.abs(vt))&&Math.abs(T-tn)<=Xs*Math.max(1,Math.abs(T),Math.abs(tn))&&Math.abs(K-an)<=Xs*Math.max(1,Math.abs(K),Math.abs(an))&&Math.abs(D-Vn)<=Xs*Math.max(1,Math.abs(D),Math.abs(Vn))&&Math.abs(z-cr)<=Xs*Math.max(1,Math.abs(z),Math.abs(cr))&&Math.abs(Q-xn)<=Xs*Math.max(1,Math.abs(Q),Math.abs(xn))&&Math.abs(ie-Cn)<=Xs*Math.max(1,Math.abs(ie),Math.abs(Cn))&&Math.abs(le-Kn)<=Xs*Math.max(1,Math.abs(le),Math.abs(Kn))&&Math.abs(ge-ur)<=Xs*Math.max(1,Math.abs(ge),Math.abs(ur))&&Math.abs(Oe-Dn)<=Xs*Math.max(1,Math.abs(Oe),Math.abs(Dn))&&Math.abs(Be-wn)<=Xs*Math.max(1,Math.abs(Be),Math.abs(wn))&&Math.abs(ze-Kr)<=Xs*Math.max(1,Math.abs(ze),Math.abs(Kr))&&Math.abs($e-wr)<=Xs*Math.max(1,Math.abs($e),Math.abs(wr))&&Math.abs(tt-Bi)<=Xs*Math.max(1,Math.abs(tt),Math.abs(Bi))},a.aZ=function(c,l){return c[0]=l[0],c[1]=l[1],c[2]=l[2],c[3]=l[3],c[4]=l[4],c[5]=l[5],c[6]=l[6],c[7]=l[7],c[8]=l[8],c[9]=l[9],c[10]=l[10],c[11]=l[11],c[12]=l[12],c[13]=l[13],c[14]=l[14],c[15]=l[15],c},a.a_=function(c,l,d){return c[0]=l[0]*d[0],c[1]=l[1]*d[1],c[2]=l[2]*d[2],c[3]=l[3]*d[3],c},a.aa=function(c){const l={};if(c.replace(/(?:^|(?:\s*\,\s*))([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,(d,y,w,T)=>{const K=w||T;return l[y]=!K||K.toLowerCase(),""}),l["max-age"]){const d=parseInt(l["max-age"],10);isNaN(d)?delete l["max-age"]:l["max-age"]=d}return l},a.ab=function(c,l){const d=[];for(const y in c)y in l||d.push(y);return d},a.ac=ae,a.ad=function(c,l,d){var y=Math.sin(d),w=Math.cos(d),T=l[0],K=l[1],D=l[2],z=l[3],Q=l[4],ie=l[5],le=l[6],ge=l[7];return l!==c&&(c[8]=l[8],c[9]=l[9],c[10]=l[10],c[11]=l[11],c[12]=l[12],c[13]=l[13],c[14]=l[14],c[15]=l[15]),c[0]=T*w+Q*y,c[1]=K*w+ie*y,c[2]=D*w+le*y,c[3]=z*w+ge*y,c[4]=Q*w-T*y,c[5]=ie*w-K*y,c[6]=le*w-D*y,c[7]=ge*w-z*y,c},a.ae=function(c){var l=new Ph(16);return l[0]=c[0],l[1]=c[1],l[2]=c[2],l[3]=c[3],l[4]=c[4],l[5]=c[5],l[6]=c[6],l[7]=c[7],l[8]=c[8],l[9]=c[9],l[10]=c[10],l[11]=c[11],l[12]=c[12],l[13]=c[13],l[14]=c[14],l[15]=c[15],l},a.af=Fh,a.ag=function(c,l){let d=0,y=0;if(c.kind==="constant")y=c.layoutSize;else if(c.kind!=="source"){const{interpolationType:w,minZoom:T,maxZoom:K}=c,D=w?ae(_n.interpolationFactor(w,l,T,K),0,1):0;c.kind==="camera"?y=Sr.number(c.minSize,c.maxSize,D):d=D}return{uSizeT:d,uSize:y}},a.ai=function(c,{uSize:l,uSizeT:d},{lowerSize:y,upperSize:w}){return c.kind==="source"?y/dd:c.kind==="composite"?Sr.number(y/dd,w/dd,d):l},a.aj=Av,a.ak=function(c,l,d,y){const w=l.y-c.y,T=l.x-c.x,K=y.y-d.y,D=y.x-d.x,z=K*T-D*w;if(z===0)return null;const Q=(D*(c.y-d.y)-K*(c.x-d.x))/z;return new B(c.x+Q*T,c.y+Q*w)},a.al=Nb,a.am=Wd,a.an=Kf,a.ao=Zt,a.aq=uv,a.ar=function(c,l){var d=l[0],y=l[1],w=l[2],T=l[3],K=l[4],D=l[5],z=l[6],Q=l[7],ie=l[8],le=l[9],ge=l[10],Oe=l[11],Be=l[12],ze=l[13],$e=l[14],tt=l[15],St=d*D-y*K,lt=d*z-w*K,vt=d*Q-T*K,tn=y*z-w*D,an=y*Q-T*D,Vn=w*Q-T*z,cr=ie*ze-le*Be,xn=ie*$e-ge*Be,Cn=ie*tt-Oe*Be,Kn=le*$e-ge*ze,ur=le*tt-Oe*ze,Dn=ge*tt-Oe*$e,wn=St*Dn-lt*ur+vt*Kn+tn*Cn-an*xn+Vn*cr;return wn?(c[0]=(D*Dn-z*ur+Q*Kn)*(wn=1/wn),c[1]=(w*ur-y*Dn-T*Kn)*wn,c[2]=(ze*Vn-$e*an+tt*tn)*wn,c[3]=(ge*an-le*Vn-Oe*tn)*wn,c[4]=(z*Cn-K*Dn-Q*xn)*wn,c[5]=(d*Dn-w*Cn+T*xn)*wn,c[6]=($e*vt-Be*Vn-tt*lt)*wn,c[7]=(ie*Vn-ge*vt+Oe*lt)*wn,c[8]=(K*ur-D*Cn+Q*cr)*wn,c[9]=(y*Cn-d*ur-T*cr)*wn,c[10]=(Be*an-ze*vt+tt*St)*wn,c[11]=(le*vt-ie*an-Oe*St)*wn,c[12]=(D*xn-K*Kn-z*cr)*wn,c[13]=(d*Kn-y*xn+w*cr)*wn,c[14]=(ze*lt-Be*tn-$e*St)*wn,c[15]=(ie*tn-le*lt+ge*St)*wn,c):null},a.as=J1,a.at=lv,a.au=Np,a.av=function(){const c={},l=mt.$version;for(const d in mt.$root){const y=mt.$root[d];if(y.required){let w=null;w=d==="version"?l:y.type==="array"?[]:{},w!=null&&(c[d]=w)}}return c},a.aw=ac,a.ax=xe,a.ay=function(c){c=c.slice();const l=Object.create(null);for(let d=0;d<c.length;d++)l[c[d].id]=c[d];for(let d=0;d<c.length;d++)"ref"in c[d]&&(c[d]=ir(c[d],l[c[d].ref]));return c},a.az=function(c){if(c.type==="custom")return new uw(c);switch(c.type){case"background":return new fv(c);case"circle":return new Qi(c);case"fill":return new U1(c);case"fill-extrusion":return new rv(c);case"heatmap":return new kA(c);case"hillshade":return new pu(c);case"line":return new Y(c);case"raster":return new lw(c);case"symbol":return new Q1(c)}},a.b=Nt,a.b0=ue,a.b1=Db,a.b2=u0,a.b3=function(c,l,d,y,w){var T,K=1/Math.tan(l/2);return c[0]=K/d,c[1]=0,c[2]=0,c[3]=0,c[4]=0,c[5]=K,c[6]=0,c[7]=0,c[8]=0,c[9]=0,c[11]=-1,c[12]=0,c[13]=0,c[15]=0,w!=null&&w!==1/0?(c[10]=(w+y)*(T=1/(y-w)),c[14]=2*w*y*T):(c[10]=-1,c[14]=-2*y),c},a.b4=function(c,l,d){var y=Math.sin(d),w=Math.cos(d),T=l[4],K=l[5],D=l[6],z=l[7],Q=l[8],ie=l[9],le=l[10],ge=l[11];return l!==c&&(c[0]=l[0],c[1]=l[1],c[2]=l[2],c[3]=l[3],c[12]=l[12],c[13]=l[13],c[14]=l[14],c[15]=l[15]),c[4]=T*w+Q*y,c[5]=K*w+ie*y,c[6]=D*w+le*y,c[7]=z*w+ge*y,c[8]=Q*w-T*y,c[9]=ie*w-K*y,c[10]=le*w-D*y,c[11]=ge*w-z*y,c},a.b5=ne,a.b6=ce,a.b7=function(c,l){return c[0]=l[0],c[1]=0,c[2]=0,c[3]=0,c[4]=0,c[5]=l[1],c[6]=0,c[7]=0,c[8]=0,c[9]=0,c[10]=l[2],c[11]=0,c[12]=0,c[13]=0,c[14]=0,c[15]=1,c},a.b8=class extends Tu{},a.b9=mv,a.ba=vw,a.bc=de,a.bd=function(c,l){kt.REGISTERED_PROTOCOLS[c]=l},a.be=function(c){delete kt.REGISTERED_PROTOCOLS[c]},a.bf=function(c,l){const d={};for(let w=0;w<c.length;w++){const T=l&&l[c[w].id]||Ml(c[w]);l&&(l[c[w].id]=T);let K=d[T];K||(K=d[T]=[]),K.push(c[w])}const y=[];for(const w in d)y.push(d[w]);return y},a.bg=jn,a.bh=Rb,a.bi=zb,a.bj=Lp,a.bk=function(c){c.bucket.createArrays(),c.bucket.tilePixelRatio=Wo/(512*c.bucket.overscaling),c.bucket.compareText={},c.bucket.iconsNeedLinear=!1;const l=c.bucket.layers[0],d=l.layout,y=l._unevaluatedLayout._values,w={layoutIconSize:y["icon-size"].possiblyEvaluate(new go(c.bucket.zoom+1),c.canonical),layoutTextSize:y["text-size"].possiblyEvaluate(new go(c.bucket.zoom+1),c.canonical),textMaxSize:y["text-size"].possiblyEvaluate(new go(18))};if(c.bucket.textSizeData.kind==="composite"){const{minZoom:Q,maxZoom:ie}=c.bucket.textSizeData;w.compositeTextSizes=[y["text-size"].possiblyEvaluate(new go(Q),c.canonical),y["text-size"].possiblyEvaluate(new go(ie),c.canonical)]}if(c.bucket.iconSizeData.kind==="composite"){const{minZoom:Q,maxZoom:ie}=c.bucket.iconSizeData;w.compositeIconSizes=[y["icon-size"].possiblyEvaluate(new go(Q),c.canonical),y["icon-size"].possiblyEvaluate(new go(ie),c.canonical)]}const T=d.get("text-line-height")*Zt,K=d.get("text-rotation-alignment")!=="viewport"&&d.get("symbol-placement")!=="point",D=d.get("text-keep-upright"),z=d.get("text-size");for(const Q of c.bucket.features){const ie=d.get("text-font").evaluate(Q,{},c.canonical).join(","),le=z.evaluate(Q,{},c.canonical),ge=w.layoutTextSize.evaluate(Q,{},c.canonical),Oe=w.layoutIconSize.evaluate(Q,{},c.canonical),Be={horizontal:{},vertical:void 0},ze=Q.text;let $e,tt=[0,0];if(ze){const vt=ze.toString(),tn=d.get("text-letter-spacing").evaluate(Q,{},c.canonical)*Zt,an=Sf(vt)?tn:0,Vn=d.get("text-anchor").evaluate(Q,{},c.canonical),cr=bv(l,Q,c.canonical);if(!cr){const Dn=d.get("text-radial-offset").evaluate(Q,{},c.canonical);tt=Dn?X1(Vn,[Dn*Zt,Z1]):d.get("text-offset").evaluate(Q,{},c.canonical).map(wn=>wn*Zt)}let xn=K?"center":d.get("text-justify").evaluate(Q,{},c.canonical);const Cn=d.get("symbol-placement"),Kn=Cn==="point"?d.get("text-max-width").evaluate(Q,{},c.canonical)*Zt:0,ur=()=>{c.bucket.allowVerticalPlacement&&rA(vt)&&(Be.vertical=j1(ze,c.glyphMap,c.glyphPositions,c.imagePositions,ie,Kn,T,Vn,"left",an,tt,a.ah.vertical,!0,Cn,ge,le))};if(!K&&cr){const Dn=new Set;if(xn==="auto")for(let Kr=0;Kr<cr.values.length;Kr+=2)Dn.add(J1(cr.values[Kr]));else Dn.add(xn);let wn=!1;for(const Kr of Dn)if(!Be.horizontal[Kr])if(wn)Be.horizontal[Kr]=Be.horizontal[0];else{const wr=j1(ze,c.glyphMap,c.glyphPositions,c.imagePositions,ie,Kn,T,"center",Kr,an,tt,a.ah.horizontal,!1,Cn,ge,le);wr&&(Be.horizontal[Kr]=wr,wn=wr.positionedLines.length===1)}ur()}else{xn==="auto"&&(xn=J1(Vn));const Dn=j1(ze,c.glyphMap,c.glyphPositions,c.imagePositions,ie,Kn,T,Vn,xn,an,tt,a.ah.horizontal,!1,Cn,ge,le);Dn&&(Be.horizontal[xn]=Dn),ur(),rA(vt)&&K&&D&&(Be.vertical=j1(ze,c.glyphMap,c.glyphPositions,c.imagePositions,ie,Kn,T,Vn,xn,an,tt,a.ah.vertical,!1,Cn,ge,le))}}let St=!1;if(Q.icon&&Q.icon.name){const vt=c.imageMap[Q.icon.name];vt&&($e=nw(c.imagePositions[Q.icon.name],d.get("icon-offset").evaluate(Q,{},c.canonical),d.get("icon-anchor").evaluate(Q,{},c.canonical)),St=!!vt.sdf,c.bucket.sdfIcons===void 0?c.bucket.sdfIcons=St:c.bucket.sdfIcons!==St&&He("Style sheet warning: Cannot mix SDF and non-SDF icons in one buffer"),(vt.pixelRatio!==c.bucket.pixelRatio||d.get("icon-rotate").constantOr(1)!==0)&&(c.bucket.iconsNeedLinear=!0))}const lt=Vb(Be.horizontal)||Be.vertical;c.bucket.iconsInText=!!lt&<.iconsInText,(lt||$e)&&qb(c.bucket,Q,Be,$e,c.imageMap,w,ge,Oe,tt,St,c.canonical)}c.showCollisionBoxes&&c.bucket.generateCollisionDebugBuffers()},a.bl=A,a.bm=Rf,a.bn=ud,a.bo=Os,a.bp=FA,a.bq=class{constructor(c){this._marks={start:[c.url,"start"].join("#"),end:[c.url,"end"].join("#"),measure:c.url.toString()},performance.mark(this._marks.start)}finish(){performance.mark(this._marks.end);let c=performance.getEntriesByName(this._marks.measure);return c.length===0&&(performance.measure(this._marks.measure,this._marks.start,this._marks.end),c=performance.getEntriesByName(this._marks.measure),performance.clearMarks(this._marks.start),performance.clearMarks(this._marks.end),performance.clearMeasures(this._marks.measure)),c}},a.br=function(c,l,d,y,w){return f(this,void 0,void 0,function*(){if(oe())try{return yield nt(c,l,d,y,w)}catch{}return function(T,K,D,z,Q){const ie=T.width,le=T.height;Je&&Vt||(Je=new OffscreenCanvas(ie,le),Vt=Je.getContext("2d",{willReadFrequently:!0})),Je.width=ie,Je.height=le,Vt.drawImage(T,0,0,ie,le);const ge=Vt.getImageData(K,D,z,Q);return Vt.clearRect(0,0,ie,le),ge.data}(c,l,d,y,w)})},a.bs=Ub,a.bt=g,a.bu=x,a.bv=Bn,a.bw=nc,a.bx=function(c){return c.message===pt},a.by=Hl,a.c=dt,a.d=c=>f(void 0,void 0,void 0,function*(){if(c.byteLength===0)return createImageBitmap(new ImageData(1,1));const l=new Blob([new Uint8Array(c)],{type:"image/png"});try{return createImageBitmap(l)}catch(d){throw new Error(`Could not load image because of ${d.message}. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported.`)}}),a.e=ye,a.f=c=>new Promise((l,d)=>{const y=new Image;y.onload=()=>{l(y),URL.revokeObjectURL(y.src),y.onload=null,window.requestAnimationFrame(()=>{y.src=Ve})},y.onerror=()=>d(new Error("Could not load image. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."));const w=new Blob([new Uint8Array(c)],{type:"image/png"});y.src=c.byteLength?URL.createObjectURL(w):Ve}),a.g=Dt,a.h=(c,l)=>Pe(ye(c,{type:"json"}),l),a.i=Ft,a.j=Pt,a.k=Kt,a.l=(c,l)=>Pe(ye(c,{type:"arrayBuffer"}),l),a.m=Pe,a.n=function(c){return new Os(c).readFields(Bs,[])},a.o=gc,a.p=wc,a.q=xa,a.r=Mh,a.s=Ze,a.t=us,a.u=Nn,a.v=mt,a.w=He,a.x=MA,a.y=function([c,l,d]){return l+=90,l*=Math.PI/180,d*=Math.PI/180,{x:c*Math.cos(l)*Math.sin(d),y:c*Math.sin(l)*Math.sin(d),z:c*Math.cos(d)}},a.z=Sr}),o(["./shared"],function(a){class f{constructor(fe){this.keyCache={},fe&&this.replace(fe)}replace(fe){this._layerConfigs={},this._layers={},this.update(fe,[])}update(fe,_e){for(const Te of fe){this._layerConfigs[Te.id]=Te;const at=this._layers[Te.id]=a.az(Te);at._featureFilter=a.a6(at.filter),this.keyCache[Te.id]&&delete this.keyCache[Te.id]}for(const Te of _e)delete this.keyCache[Te],delete this._layerConfigs[Te],delete this._layers[Te];this.familiesBySource={};const Ee=a.bf(Object.values(this._layerConfigs),this.keyCache);for(const Te of Ee){const at=Te.map(Gt=>this._layers[Gt.id]),it=at[0];if(it.visibility==="none")continue;const ht=it.source||"";let et=this.familiesBySource[ht];et||(et=this.familiesBySource[ht]={});const Ct=it.sourceLayer||"_geojsonTileLayer";let rn=et[Ct];rn||(rn=et[Ct]=[]),rn.push(at)}}}class g{constructor(fe){const _e={},Ee=[];for(const ht in fe){const et=fe[ht],Ct=_e[ht]={};for(const rn in et){const Gt=et[+rn];if(!Gt||Gt.bitmap.width===0||Gt.bitmap.height===0)continue;const $t={x:0,y:0,w:Gt.bitmap.width+2,h:Gt.bitmap.height+2};Ee.push($t),Ct[rn]={rect:$t,metrics:Gt.metrics}}}const{w:Te,h:at}=a.p(Ee),it=new a.o({width:Te||1,height:at||1});for(const ht in fe){const et=fe[ht];for(const Ct in et){const rn=et[+Ct];if(!rn||rn.bitmap.width===0||rn.bitmap.height===0)continue;const Gt=_e[ht][Ct].rect;a.o.copy(rn.bitmap,it,{x:0,y:0},{x:Gt.x+1,y:Gt.y+1},rn.bitmap)}}this.image=it,this.positions=_e}}a.bg("GlyphAtlas",g);class x{constructor(fe){this.tileID=new a.Q(fe.tileID.overscaledZ,fe.tileID.wrap,fe.tileID.canonical.z,fe.tileID.canonical.x,fe.tileID.canonical.y),this.uid=fe.uid,this.zoom=fe.zoom,this.pixelRatio=fe.pixelRatio,this.tileSize=fe.tileSize,this.source=fe.source,this.overscaling=this.tileID.overscaleFactor(),this.showCollisionBoxes=fe.showCollisionBoxes,this.collectResourceTiming=!!fe.collectResourceTiming,this.returnDependencies=!!fe.returnDependencies,this.promoteId=fe.promoteId,this.inFlightDependencies=[]}parse(fe,_e,Ee,Te){return a._(this,void 0,void 0,function*(){this.status="parsing",this.data=fe,this.collisionBoxArray=new a.a4;const at=new a.bh(Object.keys(fe.layers).sort()),it=new a.bi(this.tileID,this.promoteId);it.bucketLayerIDs=[];const ht={},et={featureIndex:it,iconDependencies:{},patternDependencies:{},glyphDependencies:{},availableImages:Ee},Ct=_e.familiesBySource[this.source];for(const Cr in Ct){const ui=fe.layers[Cr];if(!ui)continue;ui.version===1&&a.w(`Vector tile source "${this.source}" layer "${Cr}" does not use vector tile spec v2 and therefore may have some rendering errors.`);const Ii=at.encode(Cr),Io=[];for(let Ci=0;Ci<ui.length;Ci++){const so=ui.feature(Ci),Yo=it.getId(so,Cr);Io.push({feature:so,id:Yo,index:Ci,sourceLayerIndex:Ii})}for(const Ci of Ct[Cr]){const so=Ci[0];so.source!==this.source&&a.w(`layer.source = ${so.source} does not equal this.source = ${this.source}`),so.minzoom&&this.zoom<Math.floor(so.minzoom)||so.maxzoom&&this.zoom>=so.maxzoom||so.visibility!=="none"&&(k(Ci,this.zoom,Ee),(ht[so.id]=so.createBucket({index:it.bucketLayerIDs.length,layers:Ci,zoom:this.zoom,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray,sourceLayerIndex:Ii,sourceID:this.source})).populate(Io,et,this.tileID.canonical),it.bucketLayerIDs.push(Ci.map(Yo=>Yo.id)))}}const rn=a.aE(et.glyphDependencies,Cr=>Object.keys(Cr).map(Number));this.inFlightDependencies.forEach(Cr=>Cr==null?void 0:Cr.abort()),this.inFlightDependencies=[];let Gt=Promise.resolve({});if(Object.keys(rn).length){const Cr=new AbortController;this.inFlightDependencies.push(Cr),Gt=Te.sendAsync({type:"getGlyphs",data:{stacks:rn,source:this.source,tileID:this.tileID,type:"glyphs"}},Cr)}const $t=Object.keys(et.iconDependencies);let gn=Promise.resolve({});if($t.length){const Cr=new AbortController;this.inFlightDependencies.push(Cr),gn=Te.sendAsync({type:"getImages",data:{icons:$t,source:this.source,tileID:this.tileID,type:"icons"}},Cr)}const Jn=Object.keys(et.patternDependencies);let qn=Promise.resolve({});if(Jn.length){const Cr=new AbortController;this.inFlightDependencies.push(Cr),qn=Te.sendAsync({type:"getImages",data:{icons:Jn,source:this.source,tileID:this.tileID,type:"patterns"}},Cr)}const[Tr,vr,Dr]=yield Promise.all([Gt,gn,qn]),Yr=new g(Tr),Zr=new a.bj(vr,Dr);for(const Cr in ht){const ui=ht[Cr];ui instanceof a.a5?(k(ui.layers,this.zoom,Ee),a.bk({bucket:ui,glyphMap:Tr,glyphPositions:Yr.positions,imageMap:vr,imagePositions:Zr.iconPositions,showCollisionBoxes:this.showCollisionBoxes,canonical:this.tileID.canonical})):ui.hasPattern&&(ui instanceof a.bl||ui instanceof a.bm||ui instanceof a.bn)&&(k(ui.layers,this.zoom,Ee),ui.addFeatures(et,this.tileID.canonical,Zr.patternPositions))}return this.status="done",{buckets:Object.values(ht).filter(Cr=>!Cr.isEmpty()),featureIndex:it,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:Yr.image,imageAtlas:Zr,glyphMap:this.returnDependencies?Tr:null,iconMap:this.returnDependencies?vr:null,glyphPositions:this.returnDependencies?Yr.positions:null}})}}function k(Ke,fe,_e){const Ee=new a.a8(fe);for(const Te of Ke)Te.recalculate(Ee,_e)}class B{constructor(fe,_e,Ee){this.actor=fe,this.layerIndex=_e,this.availableImages=Ee,this.fetching={},this.loading={},this.loaded={}}loadVectorTile(fe,_e){return a._(this,void 0,void 0,function*(){const Ee=yield a.l(fe.request,_e);try{return{vectorTile:new a.bp.VectorTile(new a.bo(Ee.data)),rawData:Ee.data,cacheControl:Ee.cacheControl,expires:Ee.expires}}catch(Te){const at=new Uint8Array(Ee.data);let it=`Unable to parse the tile at ${fe.request.url}, `;throw it+=at[0]===31&&at[1]===139?"please make sure the data is not gzipped and that you have configured the relevant header in the server":`got error: ${Te.messge}`,new Error(it)}})}loadTile(fe){return a._(this,void 0,void 0,function*(){const _e=fe.uid,Ee=!!(fe&&fe.request&&fe.request.collectResourceTiming)&&new a.bq(fe.request),Te=new x(fe);this.loading[_e]=Te;const at=new AbortController;Te.abort=at;try{const it=yield this.loadVectorTile(fe,at);if(delete this.loading[_e],!it)return null;const ht=it.rawData,et={};it.expires&&(et.expires=it.expires),it.cacheControl&&(et.cacheControl=it.cacheControl);const Ct={};if(Ee){const Gt=Ee.finish();Gt&&(Ct.resourceTiming=JSON.parse(JSON.stringify(Gt)))}Te.vectorTile=it.vectorTile;const rn=Te.parse(it.vectorTile,this.layerIndex,this.availableImages,this.actor);this.loaded[_e]=Te,this.fetching[_e]={rawTileData:ht,cacheControl:et,resourceTiming:Ct};try{const Gt=yield rn;return a.e({rawTileData:ht.slice(0)},Gt,et,Ct)}finally{delete this.fetching[_e]}}catch(it){throw delete this.loading[_e],Te.status="done",this.loaded[_e]=Te,it}})}reloadTile(fe){return a._(this,void 0,void 0,function*(){const _e=fe.uid;if(!this.loaded||!this.loaded[_e])throw new Error("Should not be trying to reload a tile that was never loaded or has been removed");const Ee=this.loaded[_e];if(Ee.showCollisionBoxes=fe.showCollisionBoxes,Ee.status==="parsing"){const Te=yield Ee.parse(Ee.vectorTile,this.layerIndex,this.availableImages,this.actor);let at;if(this.fetching[_e]){const{rawTileData:it,cacheControl:ht,resourceTiming:et}=this.fetching[_e];delete this.fetching[_e],at=a.e({rawTileData:it.slice(0)},Te,ht,et)}else at=Te;return at}if(Ee.status==="done"&&Ee.vectorTile)return Ee.parse(Ee.vectorTile,this.layerIndex,this.availableImages,this.actor)})}abortTile(fe){return a._(this,void 0,void 0,function*(){const _e=this.loading,Ee=fe.uid;_e&&_e[Ee]&&_e[Ee].abort&&(_e[Ee].abort.abort(),delete _e[Ee])})}removeTile(fe){return a._(this,void 0,void 0,function*(){this.loaded&&this.loaded[fe.uid]&&delete this.loaded[fe.uid]})}}class P{constructor(){this.loaded={}}loadTile(fe){return a._(this,void 0,void 0,function*(){const{uid:_e,encoding:Ee,rawImageData:Te,redFactor:at,greenFactor:it,blueFactor:ht,baseShift:et}=fe,Ct=Te.width+2,rn=Te.height+2,Gt=a.b(Te)?new a.R({width:Ct,height:rn},yield a.br(Te,-1,-1,Ct,rn)):Te,$t=new a.bs(_e,Gt,Ee,at,it,ht,et);return this.loaded=this.loaded||{},this.loaded[_e]=$t,$t})}removeTile(fe){const _e=this.loaded,Ee=fe.uid;_e&&_e[Ee]&&delete _e[Ee]}}function R(Ke,fe){if(Ke.length!==0){H(Ke[0],fe);for(var _e=1;_e<Ke.length;_e++)H(Ke[_e],!fe)}}function H(Ke,fe){for(var _e=0,Ee=0,Te=0,at=Ke.length,it=at-1;Te<at;it=Te++){var ht=(Ke[Te][0]-Ke[it][0])*(Ke[it][1]+Ke[Te][1]),et=_e+ht;Ee+=Math.abs(_e)>=Math.abs(ht)?_e-et+ht:ht-et+_e,_e=et}_e+Ee>=0!=!!fe&&Ke.reverse()}var W=a.bt(function Ke(fe,_e){var Ee,Te=fe&&fe.type;if(Te==="FeatureCollection")for(Ee=0;Ee<fe.features.length;Ee++)Ke(fe.features[Ee],_e);else if(Te==="GeometryCollection")for(Ee=0;Ee<fe.geometries.length;Ee++)Ke(fe.geometries[Ee],_e);else if(Te==="Feature")Ke(fe.geometry,_e);else if(Te==="Polygon")R(fe.coordinates,_e);else if(Te==="MultiPolygon")for(Ee=0;Ee<fe.coordinates.length;Ee++)R(fe.coordinates[Ee],_e);return fe});const $=a.bp.VectorTileFeature.prototype.toGeoJSON;var q={exports:{}},oe=a.bu,ne=a.bp.VectorTileFeature,ce=ae;function ae(Ke,fe){this.options=fe||{},this.features=Ke,this.length=Ke.length}function ue(Ke,fe){this.id=typeof Ke.id=="number"?Ke.id:void 0,this.type=Ke.type,this.rawGeometry=Ke.type===1?[Ke.geometry]:Ke.geometry,this.properties=Ke.tags,this.extent=fe||4096}ae.prototype.feature=function(Ke){return new ue(this.features[Ke],this.options.extent)},ue.prototype.loadGeometry=function(){var Ke=this.rawGeometry;this.geometry=[];for(var fe=0;fe<Ke.length;fe++){for(var _e=Ke[fe],Ee=[],Te=0;Te<_e.length;Te++)Ee.push(new oe(_e[Te][0],_e[Te][1]));this.geometry.push(Ee)}return this.geometry},ue.prototype.bbox=function(){this.geometry||this.loadGeometry();for(var Ke=this.geometry,fe=1/0,_e=-1/0,Ee=1/0,Te=-1/0,at=0;at<Ke.length;at++)for(var it=Ke[at],ht=0;ht<it.length;ht++){var et=it[ht];fe=Math.min(fe,et.x),_e=Math.max(_e,et.x),Ee=Math.min(Ee,et.y),Te=Math.max(Te,et.y)}return[fe,Ee,_e,Te]},ue.prototype.toGeoJSON=ne.prototype.toGeoJSON;var ye=a.bv,Re=ce;function Ne(Ke){var fe=new ye;return function(_e,Ee){for(var Te in _e.layers)Ee.writeMessage(3,rt,_e.layers[Te])}(Ke,fe),fe.finish()}function rt(Ke,fe){var _e;fe.writeVarintField(15,Ke.version||1),fe.writeStringField(1,Ke.name||""),fe.writeVarintField(5,Ke.extent||4096);var Ee={keys:[],values:[],keycache:{},valuecache:{}};for(_e=0;_e<Ke.length;_e++)Ee.feature=Ke.feature(_e),fe.writeMessage(2,ct,Ee);var Te=Ee.keys;for(_e=0;_e<Te.length;_e++)fe.writeStringField(3,Te[_e]);var at=Ee.values;for(_e=0;_e<at.length;_e++)fe.writeMessage(4,Ft,at[_e])}function ct(Ke,fe){var _e=Ke.feature;_e.id!==void 0&&fe.writeVarintField(1,_e.id),fe.writeMessage(2,Fe,Ke),fe.writeVarintField(3,_e.type),fe.writeMessage(4,jt,_e)}function Fe(Ke,fe){var _e=Ke.feature,Ee=Ke.keys,Te=Ke.values,at=Ke.keycache,it=Ke.valuecache;for(var ht in _e.properties){var et=_e.properties[ht],Ct=at[ht];if(et!==null){Ct===void 0&&(Ee.push(ht),at[ht]=Ct=Ee.length-1),fe.writeVarint(Ct);var rn=typeof et;rn!=="string"&&rn!=="boolean"&&rn!=="number"&&(et=JSON.stringify(et));var Gt=rn+":"+et,$t=it[Gt];$t===void 0&&(Te.push(et),it[Gt]=$t=Te.length-1),fe.writeVarint($t)}}}function He(Ke,fe){return(fe<<3)+(7&Ke)}function Ce(Ke){return Ke<<1^Ke>>31}function jt(Ke,fe){for(var _e=Ke.loadGeometry(),Ee=Ke.type,Te=0,at=0,it=_e.length,ht=0;ht<it;ht++){var et=_e[ht],Ct=1;Ee===1&&(Ct=et.length),fe.writeVarint(He(1,Ct));for(var rn=Ee===3?et.length-1:et.length,Gt=0;Gt<rn;Gt++){Gt===1&&Ee!==1&&fe.writeVarint(He(2,rn-1));var $t=et[Gt].x-Te,gn=et[Gt].y-at;fe.writeVarint(Ce($t)),fe.writeVarint(Ce(gn)),Te+=$t,at+=gn}Ee===3&&fe.writeVarint(He(7,1))}}function Ft(Ke,fe){var _e=typeof Ke;_e==="string"?fe.writeStringField(1,Ke):_e==="boolean"?fe.writeBooleanField(7,Ke):_e==="number"&&(Ke%1!=0?fe.writeDoubleField(3,Ke):Ke<0?fe.writeSVarintField(6,Ke):fe.writeVarintField(5,Ke))}q.exports=Ne,q.exports.fromVectorTileJs=Ne,q.exports.fromGeojsonVt=function(Ke,fe){fe=fe||{};var _e={};for(var Ee in Ke)_e[Ee]=new Re(Ke[Ee].features,fe),_e[Ee].name=Ee,_e[Ee].version=fe.version,_e[Ee].extent=fe.extent;return Ne({layers:_e})},q.exports.GeoJSONWrapper=Re;var Jt=a.bt(q.exports);const Nt={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:Ke=>Ke},Ve=Math.fround||(nt=new Float32Array(1),Ke=>(nt[0]=+Ke,nt[0]));var nt;const Je=3,Vt=5,pt=6;class dt{constructor(fe){this.options=Object.assign(Object.create(Nt),fe),this.trees=new Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(fe){const{log:_e,minZoom:Ee,maxZoom:Te}=this.options;_e&&console.time("total time");const at=`prepare ${fe.length} points`;_e&&console.time(at),this.points=fe;const it=[];for(let et=0;et<fe.length;et++){const Ct=fe[et];if(!Ct.geometry)continue;const[rn,Gt]=Ct.geometry.coordinates,$t=Ve(Se(rn)),gn=Ve(de(Gt));it.push($t,gn,1/0,et,-1,1),this.options.reduce&&it.push(0)}let ht=this.trees[Te+1]=this._createTree(it);_e&&console.timeEnd(at);for(let et=Te;et>=Ee;et--){const Ct=+Date.now();ht=this.trees[et]=this._createTree(this._cluster(ht,et)),_e&&console.log("z%d: %d clusters in %dms",et,ht.numItems,+Date.now()-Ct)}return _e&&console.timeEnd("total time"),this}getClusters(fe,_e){let Ee=((fe[0]+180)%360+360)%360-180;const Te=Math.max(-90,Math.min(90,fe[1]));let at=fe[2]===180?180:((fe[2]+180)%360+360)%360-180;const it=Math.max(-90,Math.min(90,fe[3]));if(fe[2]-fe[0]>=360)Ee=-180,at=180;else if(Ee>at){const Gt=this.getClusters([Ee,Te,180,it],_e),$t=this.getClusters([-180,Te,at,it],_e);return Gt.concat($t)}const ht=this.trees[this._limitZoom(_e)],et=ht.range(Se(Ee),de(it),Se(at),de(Te)),Ct=ht.data,rn=[];for(const Gt of et){const $t=this.stride*Gt;rn.push(Ct[$t+Vt]>1?kt(Ct,$t,this.clusterProps):this.points[Ct[$t+Je]])}return rn}getChildren(fe){const _e=this._getOriginId(fe),Ee=this._getOriginZoom(fe),Te="No cluster with the specified id.",at=this.trees[Ee];if(!at)throw new Error(Te);const it=at.data;if(_e*this.stride>=it.length)throw new Error(Te);const ht=this.options.radius/(this.options.extent*Math.pow(2,Ee-1)),et=at.within(it[_e*this.stride],it[_e*this.stride+1],ht),Ct=[];for(const rn of et){const Gt=rn*this.stride;it[Gt+4]===fe&&Ct.push(it[Gt+Vt]>1?kt(it,Gt,this.clusterProps):this.points[it[Gt+Je]])}if(Ct.length===0)throw new Error(Te);return Ct}getLeaves(fe,_e,Ee){const Te=[];return this._appendLeaves(Te,fe,_e=_e||10,Ee=Ee||0,0),Te}getTile(fe,_e,Ee){const Te=this.trees[this._limitZoom(fe)],at=Math.pow(2,fe),{extent:it,radius:ht}=this.options,et=ht/it,Ct=(Ee-et)/at,rn=(Ee+1+et)/at,Gt={features:[]};return this._addTileFeatures(Te.range((_e-et)/at,Ct,(_e+1+et)/at,rn),Te.data,_e,Ee,at,Gt),_e===0&&this._addTileFeatures(Te.range(1-et/at,Ct,1,rn),Te.data,at,Ee,at,Gt),_e===at-1&&this._addTileFeatures(Te.range(0,Ct,et/at,rn),Te.data,-1,Ee,at,Gt),Gt.features.length?Gt:null}getClusterExpansionZoom(fe){let _e=this._getOriginZoom(fe)-1;for(;_e<=this.options.maxZoom;){const Ee=this.getChildren(fe);if(_e++,Ee.length!==1)break;fe=Ee[0].properties.cluster_id}return _e}_appendLeaves(fe,_e,Ee,Te,at){const it=this.getChildren(_e);for(const ht of it){const et=ht.properties;if(et&&et.cluster?at+et.point_count<=Te?at+=et.point_count:at=this._appendLeaves(fe,et.cluster_id,Ee,Te,at):at<Te?at++:fe.push(ht),fe.length===Ee)break}return at}_createTree(fe){const _e=new a.au(fe.length/this.stride|0,this.options.nodeSize,Float32Array);for(let Ee=0;Ee<fe.length;Ee+=this.stride)_e.add(fe[Ee],fe[Ee+1]);return _e.finish(),_e.data=fe,_e}_addTileFeatures(fe,_e,Ee,Te,at,it){for(const ht of fe){const et=ht*this.stride,Ct=_e[et+Vt]>1;let rn,Gt,$t;if(Ct)rn=Dt(_e,et,this.clusterProps),Gt=_e[et],$t=_e[et+1];else{const qn=this.points[_e[et+Je]];rn=qn.properties;const[Tr,vr]=qn.geometry.coordinates;Gt=Se(Tr),$t=de(vr)}const gn={type:1,geometry:[[Math.round(this.options.extent*(Gt*at-Ee)),Math.round(this.options.extent*($t*at-Te))]],tags:rn};let Jn;Jn=Ct||this.options.generateId?_e[et+Je]:this.points[_e[et+Je]].id,Jn!==void 0&&(gn.id=Jn),it.features.push(gn)}}_limitZoom(fe){return Math.max(this.options.minZoom,Math.min(Math.floor(+fe),this.options.maxZoom+1))}_cluster(fe,_e){const{radius:Ee,extent:Te,reduce:at,minPoints:it}=this.options,ht=Ee/(Te*Math.pow(2,_e)),et=fe.data,Ct=[],rn=this.stride;for(let Gt=0;Gt<et.length;Gt+=rn){if(et[Gt+2]<=_e)continue;et[Gt+2]=_e;const $t=et[Gt],gn=et[Gt+1],Jn=fe.within(et[Gt],et[Gt+1],ht),qn=et[Gt+Vt];let Tr=qn;for(const vr of Jn){const Dr=vr*rn;et[Dr+2]>_e&&(Tr+=et[Dr+Vt])}if(Tr>qn&&Tr>=it){let vr,Dr=$t*qn,Yr=gn*qn,Zr=-1;const Cr=((Gt/rn|0)<<5)+(_e+1)+this.points.length;for(const ui of Jn){const Ii=ui*rn;if(et[Ii+2]<=_e)continue;et[Ii+2]=_e;const Io=et[Ii+Vt];Dr+=et[Ii]*Io,Yr+=et[Ii+1]*Io,et[Ii+4]=Cr,at&&(vr||(vr=this._map(et,Gt,!0),Zr=this.clusterProps.length,this.clusterProps.push(vr)),at(vr,this._map(et,Ii)))}et[Gt+4]=Cr,Ct.push(Dr/Tr,Yr/Tr,1/0,Cr,-1,Tr),at&&Ct.push(Zr)}else{for(let vr=0;vr<rn;vr++)Ct.push(et[Gt+vr]);if(Tr>1)for(const vr of Jn){const Dr=vr*rn;if(!(et[Dr+2]<=_e)){et[Dr+2]=_e;for(let Yr=0;Yr<rn;Yr++)Ct.push(et[Dr+Yr])}}}}return Ct}_getOriginId(fe){return fe-this.points.length>>5}_getOriginZoom(fe){return(fe-this.points.length)%32}_map(fe,_e,Ee){if(fe[_e+Vt]>1){const it=this.clusterProps[fe[_e+pt]];return Ee?Object.assign({},it):it}const Te=this.points[fe[_e+Je]].properties,at=this.options.map(Te);return Ee&&at===Te?Object.assign({},at):at}}function kt(Ke,fe,_e){return{type:"Feature",id:Ke[fe+Je],properties:Dt(Ke,fe,_e),geometry:{type:"Point",coordinates:[(Ee=Ke[fe],360*(Ee-.5)),xe(Ke[fe+1])]}};var Ee}function Dt(Ke,fe,_e){const Ee=Ke[fe+Vt],Te=Ee>=1e4?`${Math.round(Ee/1e3)}k`:Ee>=1e3?Math.round(Ee/100)/10+"k":Ee,at=Ke[fe+pt],it=at===-1?{}:Object.assign({},_e[at]);return Object.assign(it,{cluster:!0,cluster_id:Ke[fe+Je],point_count:Ee,point_count_abbreviated:Te})}function Se(Ke){return Ke/360+.5}function de(Ke){const fe=Math.sin(Ke*Math.PI/180),_e=.5-.25*Math.log((1+fe)/(1-fe))/Math.PI;return _e<0?0:_e>1?1:_e}function xe(Ke){const fe=(180-360*Ke)*Math.PI/180;return 360*Math.atan(Math.exp(fe))/Math.PI-90}function Pe(Ke,fe,_e,Ee){for(var Te,at=Ee,it=_e-fe>>1,ht=_e-fe,et=Ke[fe],Ct=Ke[fe+1],rn=Ke[_e],Gt=Ke[_e+1],$t=fe+3;$t<_e;$t+=3){var gn=Ze(Ke[$t],Ke[$t+1],et,Ct,rn,Gt);if(gn>at)Te=$t,at=gn;else if(gn===at){var Jn=Math.abs($t-it);Jn<ht&&(Te=$t,ht=Jn)}}at>Ee&&(Te-fe>3&&Pe(Ke,fe,Te,Ee),Ke[Te+2]=at,_e-Te>3&&Pe(Ke,Te,_e,Ee))}function Ze(Ke,fe,_e,Ee,Te,at){var it=Te-_e,ht=at-Ee;if(it!==0||ht!==0){var et=((Ke-_e)*it+(fe-Ee)*ht)/(it*it+ht*ht);et>1?(_e=Te,Ee=at):et>0&&(_e+=it*et,Ee+=ht*et)}return(it=Ke-_e)*it+(ht=fe-Ee)*ht}function Xe(Ke,fe,_e,Ee){var Te={id:Ke===void 0?null:Ke,type:fe,geometry:_e,tags:Ee,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(at){var it=at.geometry,ht=at.type;if(ht==="Point"||ht==="MultiPoint"||ht==="LineString")wt(at,it);else if(ht==="Polygon"||ht==="MultiLineString")for(var et=0;et<it.length;et++)wt(at,it[et]);else if(ht==="MultiPolygon")for(et=0;et<it.length;et++)for(var Ct=0;Ct<it[et].length;Ct++)wt(at,it[et][Ct])}(Te),Te}function wt(Ke,fe){for(var _e=0;_e<fe.length;_e+=3)Ke.minX=Math.min(Ke.minX,fe[_e]),Ke.minY=Math.min(Ke.minY,fe[_e+1]),Ke.maxX=Math.max(Ke.maxX,fe[_e]),Ke.maxY=Math.max(Ke.maxY,fe[_e+1])}function Kt(Ke,fe,_e,Ee){if(fe.geometry){var Te=fe.geometry.coordinates,at=fe.geometry.type,it=Math.pow(_e.tolerance/((1<<_e.maxZoom)*_e.extent),2),ht=[],et=fe.id;if(_e.promoteId?et=fe.properties[_e.promoteId]:_e.generateId&&(et=Ee||0),at==="Point")Pt(Te,ht);else if(at==="MultiPoint")for(var Ct=0;Ct<Te.length;Ct++)Pt(Te[Ct],ht);else if(at==="LineString")zn(Te,ht,it,!1);else if(at==="MultiLineString"){if(_e.lineMetrics){for(Ct=0;Ct<Te.length;Ct++)zn(Te[Ct],ht=[],it,!1),Ke.push(Xe(et,"LineString",ht,fe.properties));return}mt(Te,ht,it,!1)}else if(at==="Polygon")mt(Te,ht,it,!0);else{if(at!=="MultiPolygon"){if(at==="GeometryCollection"){for(Ct=0;Ct<fe.geometry.geometries.length;Ct++)Kt(Ke,{id:et,geometry:fe.geometry.geometries[Ct],properties:fe.properties},_e,Ee);return}throw new Error("Input data is not a valid GeoJSON object.")}for(Ct=0;Ct<Te.length;Ct++){var rn=[];mt(Te[Ct],rn,it,!0),ht.push(rn)}}Ke.push(Xe(et,at,ht,fe.properties))}}function Pt(Ke,fe){fe.push(pn(Ke[0])),fe.push(ir(Ke[1])),fe.push(0)}function zn(Ke,fe,_e,Ee){for(var Te,at,it=0,ht=0;ht<Ke.length;ht++){var et=pn(Ke[ht][0]),Ct=ir(Ke[ht][1]);fe.push(et),fe.push(Ct),fe.push(0),ht>0&&(it+=Ee?(Te*Ct-et*at)/2:Math.sqrt(Math.pow(et-Te,2)+Math.pow(Ct-at,2))),Te=et,at=Ct}var rn=fe.length-3;fe[2]=1,Pe(fe,0,rn,_e),fe[rn+2]=1,fe.size=Math.abs(it),fe.start=0,fe.end=fe.size}function mt(Ke,fe,_e,Ee){for(var Te=0;Te<Ke.length;Te++){var at=[];zn(Ke[Te],at,_e,Ee),fe.push(at)}}function pn(Ke){return Ke/360+.5}function ir(Ke){var fe=Math.sin(Ke*Math.PI/180),_e=.5-.25*Math.log((1+fe)/(1-fe))/Math.PI;return _e<0?0:_e>1?1:_e}function Sn(Ke,fe,_e,Ee,Te,at,it,ht){if(Ee/=fe,at>=(_e/=fe)&&it<Ee)return Ke;if(it<_e||at>=Ee)return null;for(var et=[],Ct=0;Ct<Ke.length;Ct++){var rn=Ke[Ct],Gt=rn.geometry,$t=rn.type,gn=Te===0?rn.minX:rn.minY,Jn=Te===0?rn.maxX:rn.maxY;if(gn>=_e&&Jn<Ee)et.push(rn);else if(!(Jn<_e||gn>=Ee)){var qn=[];if($t==="Point"||$t==="MultiPoint")nr(Gt,qn,_e,Ee,Te);else if($t==="LineString")Mr(Gt,qn,_e,Ee,Te,!1,ht.lineMetrics);else if($t==="MultiLineString")_r(Gt,qn,_e,Ee,Te,!1);else if($t==="Polygon")_r(Gt,qn,_e,Ee,Te,!0);else if($t==="MultiPolygon")for(var Tr=0;Tr<Gt.length;Tr++){var vr=[];_r(Gt[Tr],vr,_e,Ee,Te,!0),vr.length&&qn.push(vr)}if(qn.length){if(ht.lineMetrics&&$t==="LineString"){for(Tr=0;Tr<qn.length;Tr++)et.push(Xe(rn.id,$t,qn[Tr],rn.tags));continue}$t!=="LineString"&&$t!=="MultiLineString"||(qn.length===1?($t="LineString",qn=qn[0]):$t="MultiLineString"),$t!=="Point"&&$t!=="MultiPoint"||($t=qn.length===3?"Point":"MultiPoint"),et.push(Xe(rn.id,$t,qn,rn.tags))}}}return et.length?et:null}function nr(Ke,fe,_e,Ee,Te){for(var at=0;at<Ke.length;at+=3){var it=Ke[at+Te];it>=_e&&it<=Ee&&(fe.push(Ke[at]),fe.push(Ke[at+1]),fe.push(Ke[at+2]))}}function Mr(Ke,fe,_e,Ee,Te,at,it){for(var ht,et,Ct=Qr(Ke),rn=Te===0?we:V,Gt=Ke.start,$t=0;$t<Ke.length-3;$t+=3){var gn=Ke[$t],Jn=Ke[$t+1],qn=Ke[$t+2],Tr=Ke[$t+3],vr=Ke[$t+4],Dr=Te===0?gn:Jn,Yr=Te===0?Tr:vr,Zr=!1;it&&(ht=Math.sqrt(Math.pow(gn-Tr,2)+Math.pow(Jn-vr,2))),Dr<_e?Yr>_e&&(et=rn(Ct,gn,Jn,Tr,vr,_e),it&&(Ct.start=Gt+ht*et)):Dr>Ee?Yr<Ee&&(et=rn(Ct,gn,Jn,Tr,vr,Ee),it&&(Ct.start=Gt+ht*et)):vi(Ct,gn,Jn,qn),Yr<_e&&Dr>=_e&&(et=rn(Ct,gn,Jn,Tr,vr,_e),Zr=!0),Yr>Ee&&Dr<=Ee&&(et=rn(Ct,gn,Jn,Tr,vr,Ee),Zr=!0),!at&&Zr&&(it&&(Ct.end=Gt+ht*et),fe.push(Ct),Ct=Qr(Ke)),it&&(Gt+=ht)}var Cr=Ke.length-3;gn=Ke[Cr],Jn=Ke[Cr+1],qn=Ke[Cr+2],(Dr=Te===0?gn:Jn)>=_e&&Dr<=Ee&&vi(Ct,gn,Jn,qn),Cr=Ct.length-3,at&&Cr>=3&&(Ct[Cr]!==Ct[0]||Ct[Cr+1]!==Ct[1])&&vi(Ct,Ct[0],Ct[1],Ct[2]),Ct.length&&fe.push(Ct)}function Qr(Ke){var fe=[];return fe.size=Ke.size,fe.start=Ke.start,fe.end=Ke.end,fe}function _r(Ke,fe,_e,Ee,Te,at){for(var it=0;it<Ke.length;it++)Mr(Ke[it],fe,_e,Ee,Te,at,!1)}function vi(Ke,fe,_e,Ee){Ke.push(fe),Ke.push(_e),Ke.push(Ee)}function we(Ke,fe,_e,Ee,Te,at){var it=(at-fe)/(Ee-fe);return Ke.push(at),Ke.push(_e+(Te-_e)*it),Ke.push(1),it}function V(Ke,fe,_e,Ee,Te,at){var it=(at-_e)/(Te-_e);return Ke.push(fe+(Ee-fe)*it),Ke.push(at),Ke.push(1),it}function X(Ke,fe){for(var _e=[],Ee=0;Ee<Ke.length;Ee++){var Te,at=Ke[Ee],it=at.type;if(it==="Point"||it==="MultiPoint"||it==="LineString")Te=me(at.geometry,fe);else if(it==="MultiLineString"||it==="Polygon"){Te=[];for(var ht=0;ht<at.geometry.length;ht++)Te.push(me(at.geometry[ht],fe))}else if(it==="MultiPolygon")for(Te=[],ht=0;ht<at.geometry.length;ht++){for(var et=[],Ct=0;Ct<at.geometry[ht].length;Ct++)et.push(me(at.geometry[ht][Ct],fe));Te.push(et)}_e.push(Xe(at.id,it,Te,at.tags))}return _e}function me(Ke,fe){var _e=[];_e.size=Ke.size,Ke.start!==void 0&&(_e.start=Ke.start,_e.end=Ke.end);for(var Ee=0;Ee<Ke.length;Ee+=3)_e.push(Ke[Ee]+fe,Ke[Ee+1],Ke[Ee+2]);return _e}function At(Ke,fe){if(Ke.transformed)return Ke;var _e,Ee,Te,at=1<<Ke.z,it=Ke.x,ht=Ke.y;for(_e=0;_e<Ke.features.length;_e++){var et=Ke.features[_e],Ct=et.geometry,rn=et.type;if(et.geometry=[],rn===1)for(Ee=0;Ee<Ct.length;Ee+=2)et.geometry.push(bt(Ct[Ee],Ct[Ee+1],fe,at,it,ht));else for(Ee=0;Ee<Ct.length;Ee++){var Gt=[];for(Te=0;Te<Ct[Ee].length;Te+=2)Gt.push(bt(Ct[Ee][Te],Ct[Ee][Te+1],fe,at,it,ht));et.geometry.push(Gt)}}return Ke.transformed=!0,Ke}function bt(Ke,fe,_e,Ee,Te,at){return[Math.round(_e*(Ke*Ee-Te)),Math.round(_e*(fe*Ee-at))]}function Et(Ke,fe,_e,Ee,Te){for(var at=fe===Te.maxZoom?0:Te.tolerance/((1<<fe)*Te.extent),it={features:[],numPoints:0,numSimplified:0,numFeatures:0,source:null,x:_e,y:Ee,z:fe,transformed:!1,minX:2,minY:1,maxX:-1,maxY:0},ht=0;ht<Ke.length;ht++){it.numFeatures++,sr(it,Ke[ht],at,Te);var et=Ke[ht].minX,Ct=Ke[ht].minY,rn=Ke[ht].maxX,Gt=Ke[ht].maxY;et<it.minX&&(it.minX=et),Ct<it.minY&&(it.minY=Ct),rn>it.maxX&&(it.maxX=rn),Gt>it.maxY&&(it.maxY=Gt)}return it}function sr(Ke,fe,_e,Ee){var Te=fe.geometry,at=fe.type,it=[];if(at==="Point"||at==="MultiPoint")for(var ht=0;ht<Te.length;ht+=3)it.push(Te[ht]),it.push(Te[ht+1]),Ke.numPoints++,Ke.numSimplified++;else if(at==="LineString")Lt(it,Te,Ke,_e,!1,!1);else if(at==="MultiLineString"||at==="Polygon")for(ht=0;ht<Te.length;ht++)Lt(it,Te[ht],Ke,_e,at==="Polygon",ht===0);else if(at==="MultiPolygon")for(var et=0;et<Te.length;et++){var Ct=Te[et];for(ht=0;ht<Ct.length;ht++)Lt(it,Ct[ht],Ke,_e,!0,ht===0)}if(it.length){var rn=fe.tags||null;if(at==="LineString"&&Ee.lineMetrics){for(var Gt in rn={},fe.tags)rn[Gt]=fe.tags[Gt];rn.mapbox_clip_start=Te.start/Te.size,rn.mapbox_clip_end=Te.end/Te.size}var $t={geometry:it,type:at==="Polygon"||at==="MultiPolygon"?3:at==="LineString"||at==="MultiLineString"?2:1,tags:rn};fe.id!==null&&($t.id=fe.id),Ke.features.push($t)}}function Lt(Ke,fe,_e,Ee,Te,at){var it=Ee*Ee;if(Ee>0&&fe.size<(Te?it:Ee))_e.numPoints+=fe.length/3;else{for(var ht=[],et=0;et<fe.length;et+=3)(Ee===0||fe[et+2]>it)&&(_e.numSimplified++,ht.push(fe[et]),ht.push(fe[et+1])),_e.numPoints++;Te&&function(Ct,rn){for(var Gt=0,$t=0,gn=Ct.length,Jn=gn-2;$t<gn;Jn=$t,$t+=2)Gt+=(Ct[$t]-Ct[Jn])*(Ct[$t+1]+Ct[Jn+1]);if(Gt>0===rn)for($t=0,gn=Ct.length;$t<gn/2;$t+=2){var qn=Ct[$t],Tr=Ct[$t+1];Ct[$t]=Ct[gn-2-$t],Ct[$t+1]=Ct[gn-1-$t],Ct[gn-2-$t]=qn,Ct[gn-1-$t]=Tr}}(ht,at),Ke.push(ht)}}function Fn(Ke,fe){var _e=(fe=this.options=function(Te,at){for(var it in at)Te[it]=at[it];return Te}(Object.create(this.options),fe)).debug;if(_e&&console.time("preprocess data"),fe.maxZoom<0||fe.maxZoom>24)throw new Error("maxZoom should be in the 0-24 range");if(fe.promoteId&&fe.generateId)throw new Error("promoteId and generateId cannot be used together.");var Ee=function(Te,at){var it=[];if(Te.type==="FeatureCollection")for(var ht=0;ht<Te.features.length;ht++)Kt(it,Te.features[ht],at,ht);else Kt(it,Te.type==="Feature"?Te:{geometry:Te},at);return it}(Ke,fe);this.tiles={},this.tileCoords=[],_e&&(console.timeEnd("preprocess data"),console.log("index: maxZoom: %d, maxPoints: %d",fe.indexMaxZoom,fe.indexMaxPoints),console.time("generate tiles"),this.stats={},this.total=0),Ee=function(Te,at){var it=at.buffer/at.extent,ht=Te,et=Sn(Te,1,-1-it,it,0,-1,2,at),Ct=Sn(Te,1,1-it,2+it,0,-1,2,at);return(et||Ct)&&(ht=Sn(Te,1,-it,1+it,0,-1,2,at)||[],et&&(ht=X(et,1).concat(ht)),Ct&&(ht=ht.concat(X(Ct,-1)))),ht}(Ee,fe),Ee.length&&this.splitTile(Ee,0,0,0),_e&&(Ee.length&&console.log("features: %d, points: %d",this.tiles[0].numFeatures,this.tiles[0].numPoints),console.timeEnd("generate tiles"),console.log("tiles generated:",this.total,JSON.stringify(this.stats)))}function on(Ke,fe,_e){return 32*((1<<Ke)*_e+fe)+Ke}function m(Ke,fe){return fe?Ke.properties[fe]:Ke.id}function un(Ke,fe){if(Ke==null)return!0;if(Ke.type==="Feature")return m(Ke,fe)!=null;if(Ke.type==="FeatureCollection"){const _e=new Set;for(const Ee of Ke.features){const Te=m(Ee,fe);if(Te==null||_e.has(Te))return!1;_e.add(Te)}return!0}return!1}function In(Ke,fe){const _e=new Map;if(Ke!=null)if(Ke.type==="Feature")_e.set(m(Ke,fe),Ke);else for(const Ee of Ke.features)_e.set(m(Ee,fe),Ee);return _e}Fn.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},Fn.prototype.splitTile=function(Ke,fe,_e,Ee,Te,at,it){for(var ht=[Ke,fe,_e,Ee],et=this.options,Ct=et.debug;ht.length;){Ee=ht.pop(),_e=ht.pop(),fe=ht.pop(),Ke=ht.pop();var rn=1<<fe,Gt=on(fe,_e,Ee),$t=this.tiles[Gt];if(!$t&&(Ct>1&&console.time("creation"),$t=this.tiles[Gt]=Et(Ke,fe,_e,Ee,et),this.tileCoords.push({z:fe,x:_e,y:Ee}),Ct)){Ct>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",fe,_e,Ee,$t.numFeatures,$t.numPoints,$t.numSimplified),console.timeEnd("creation"));var gn="z"+fe;this.stats[gn]=(this.stats[gn]||0)+1,this.total++}if($t.source=Ke,Te){if(fe===et.maxZoom||fe===Te)continue;var Jn=1<<Te-fe;if(_e!==Math.floor(at/Jn)||Ee!==Math.floor(it/Jn))continue}else if(fe===et.indexMaxZoom||$t.numPoints<=et.indexMaxPoints)continue;if($t.source=null,Ke.length!==0){Ct>1&&console.time("clipping");var qn,Tr,vr,Dr,Yr,Zr,Cr=.5*et.buffer/et.extent,ui=.5-Cr,Ii=.5+Cr,Io=1+Cr;qn=Tr=vr=Dr=null,Yr=Sn(Ke,rn,_e-Cr,_e+Ii,0,$t.minX,$t.maxX,et),Zr=Sn(Ke,rn,_e+ui,_e+Io,0,$t.minX,$t.maxX,et),Ke=null,Yr&&(qn=Sn(Yr,rn,Ee-Cr,Ee+Ii,1,$t.minY,$t.maxY,et),Tr=Sn(Yr,rn,Ee+ui,Ee+Io,1,$t.minY,$t.maxY,et),Yr=null),Zr&&(vr=Sn(Zr,rn,Ee-Cr,Ee+Ii,1,$t.minY,$t.maxY,et),Dr=Sn(Zr,rn,Ee+ui,Ee+Io,1,$t.minY,$t.maxY,et),Zr=null),Ct>1&&console.timeEnd("clipping"),ht.push(qn||[],fe+1,2*_e,2*Ee),ht.push(Tr||[],fe+1,2*_e,2*Ee+1),ht.push(vr||[],fe+1,2*_e+1,2*Ee),ht.push(Dr||[],fe+1,2*_e+1,2*Ee+1)}}},Fn.prototype.getTile=function(Ke,fe,_e){var Ee=this.options,Te=Ee.extent,at=Ee.debug;if(Ke<0||Ke>24)return null;var it=1<<Ke,ht=on(Ke,fe=(fe%it+it)%it,_e);if(this.tiles[ht])return At(this.tiles[ht],Te);at>1&&console.log("drilling down to z%d-%d-%d",Ke,fe,_e);for(var et,Ct=Ke,rn=fe,Gt=_e;!et&&Ct>0;)Ct--,rn=Math.floor(rn/2),Gt=Math.floor(Gt/2),et=this.tiles[on(Ct,rn,Gt)];return et&&et.source?(at>1&&console.log("found parent tile z%d-%d-%d",Ct,rn,Gt),at>1&&console.time("drilling down"),this.splitTile(et.source,Ct,rn,Gt,Ke,fe,_e),at>1&&console.timeEnd("drilling down"),this.tiles[ht]?At(this.tiles[ht],Te):null):null};class Gn extends B{constructor(){super(...arguments),this._dataUpdateable=new Map}loadVectorTile(fe,_e){return a._(this,void 0,void 0,function*(){const Ee=fe.tileID.canonical;if(!this._geoJSONIndex)throw new Error("Unable to parse the data into a cluster or geojson");const Te=this._geoJSONIndex.getTile(Ee.z,Ee.x,Ee.y);if(!Te)return null;const at=new class{constructor(ht){this.layers={_geojsonTileLayer:this},this.name="_geojsonTileLayer",this.extent=a.W,this.length=ht.length,this._features=ht}feature(ht){return new class{constructor(et){this._feature=et,this.extent=a.W,this.type=et.type,this.properties=et.tags,"id"in et&&!isNaN(et.id)&&(this.id=parseInt(et.id,10))}loadGeometry(){if(this._feature.type===1){const et=[];for(const Ct of this._feature.geometry)et.push([new a.P(Ct[0],Ct[1])]);return et}{const et=[];for(const Ct of this._feature.geometry){const rn=[];for(const Gt of Ct)rn.push(new a.P(Gt[0],Gt[1]));et.push(rn)}return et}}toGeoJSON(et,Ct,rn){return $.call(this,et,Ct,rn)}}(this._features[ht])}}(Te.features);let it=Jt(at);return it.byteOffset===0&&it.byteLength===it.buffer.byteLength||(it=new Uint8Array(it)),{vectorTile:at,rawData:it.buffer}})}loadData(fe){var _e;return a._(this,void 0,void 0,function*(){(_e=this._pendingRequest)===null||_e===void 0||_e.abort();const Ee=!!(fe&&fe.request&&fe.request.collectResourceTiming)&&new a.bq(fe.request);this._pendingRequest=new AbortController;try{let Te=yield this.loadGeoJSON(fe,this._pendingRequest);if(delete this._pendingRequest,typeof Te!="object")throw new Error(`Input data given to '${fe.source}' is not a valid GeoJSON object.`);if(W(Te,!0),fe.filter){const it=a.bw(fe.filter,{type:"boolean","property-type":"data-driven",overridable:!1,transition:!1});if(it.result==="error")throw new Error(it.value.map(et=>`${et.key}: ${et.message}`).join(", "));Te={type:"FeatureCollection",features:Te.features.filter(et=>it.value.evaluate({zoom:0},et))}}this._geoJSONIndex=fe.cluster?new dt(function({superclusterOptions:it,clusterProperties:ht}){if(!ht||!it)return it;const et={},Ct={},rn={accumulated:null,zoom:0},Gt={properties:null},$t=Object.keys(ht);for(const gn of $t){const[Jn,qn]=ht[gn],Tr=a.bw(qn),vr=a.bw(typeof Jn=="string"?[Jn,["accumulated"],["get",gn]]:Jn);et[gn]=Tr.value,Ct[gn]=vr.value}return it.map=gn=>{Gt.properties=gn;const Jn={};for(const qn of $t)Jn[qn]=et[qn].evaluate(rn,Gt);return Jn},it.reduce=(gn,Jn)=>{Gt.properties=Jn;for(const qn of $t)rn.accumulated=gn[qn],gn[qn]=Ct[qn].evaluate(rn,Gt)},it}(fe)).load(Te.features):function(it,ht){return new Fn(it,ht)}(Te,fe.geojsonVtOptions),this.loaded={};const at={};if(Ee){const it=Ee.finish();it&&(at.resourceTiming={},at.resourceTiming[fe.source]=JSON.parse(JSON.stringify(it)))}return at}catch(Te){if(delete this._pendingRequest,a.bx(Te))return{abandoned:!0};throw Te}})}reloadTile(fe){const _e=this.loaded;return _e&&_e[fe.uid]?super.reloadTile(fe):this.loadTile(fe)}loadGeoJSON(fe,_e){return a._(this,void 0,void 0,function*(){const{promoteId:Ee}=fe;if(fe.request){const Te=yield a.h(fe.request,_e);return this._dataUpdateable=un(Te.data,Ee)?In(Te.data,Ee):void 0,Te.data}if(typeof fe.data=="string")try{const Te=JSON.parse(fe.data);return this._dataUpdateable=un(Te,Ee)?In(Te,Ee):void 0,Te}catch{throw new Error(`Input data given to '${fe.source}' is not a valid GeoJSON object.`)}if(!fe.dataDiff)throw new Error(`Input data given to '${fe.source}' is not a valid GeoJSON object.`);if(!this._dataUpdateable)throw new Error(`Cannot update existing geojson data in ${fe.source}`);return function(Te,at,it){var ht,et,Ct,rn;if(at.removeAll&&Te.clear(),at.remove)for(const Gt of at.remove)Te.delete(Gt);if(at.add)for(const Gt of at.add){const $t=m(Gt,it);$t!=null&&Te.set($t,Gt)}if(at.update)for(const Gt of at.update){let $t=Te.get(Gt.id);if($t==null)continue;const gn=!Gt.removeAllProperties&&(((ht=Gt.removeProperties)===null||ht===void 0?void 0:ht.length)>0||((et=Gt.addOrUpdateProperties)===null||et===void 0?void 0:et.length)>0);if((Gt.newGeometry||Gt.removeAllProperties||gn)&&($t=Object.assign({},$t),Te.set(Gt.id,$t),gn&&($t.properties=Object.assign({},$t.properties))),Gt.newGeometry&&($t.geometry=Gt.newGeometry),Gt.removeAllProperties)$t.properties={};else if(((Ct=Gt.removeProperties)===null||Ct===void 0?void 0:Ct.length)>0)for(const Jn of Gt.removeProperties)Object.prototype.hasOwnProperty.call($t.properties,Jn)&&delete $t.properties[Jn];if(((rn=Gt.addOrUpdateProperties)===null||rn===void 0?void 0:rn.length)>0)for(const{key:Jn,value:qn}of Gt.addOrUpdateProperties)$t.properties[Jn]=qn}}(this._dataUpdateable,fe.dataDiff,Ee),{type:"FeatureCollection",features:Array.from(this._dataUpdateable.values())}})}removeSource(fe){return a._(this,void 0,void 0,function*(){this._pendingRequest&&this._pendingRequest.abort()})}getClusterExpansionZoom(fe){return this._geoJSONIndex.getClusterExpansionZoom(fe.clusterId)}getClusterChildren(fe){return this._geoJSONIndex.getChildren(fe.clusterId)}getClusterLeaves(fe){return this._geoJSONIndex.getLeaves(fe.clusterId,fe.limit,fe.offset)}}class Zn{constructor(fe){this.self=fe,this.actor=new a.C(fe),this.layerIndexes={},this.availableImages={},this.workerSources={},this.demWorkerSources={},this.externalWorkerSourceTypes={},this.self.registerWorkerSource=(_e,Ee)=>{if(this.externalWorkerSourceTypes[_e])throw new Error(`Worker source with name "${_e}" already registered.`);this.externalWorkerSourceTypes[_e]=Ee},this.self.addProtocol=a.bd,this.self.removeProtocol=a.be,this.self.registerRTLTextPlugin=_e=>{if(a.by.isParsed())throw new Error("RTL text plugin already registered.");a.by.setMethods(_e)},this.actor.registerMessageHandler("loadDEMTile",(_e,Ee)=>this._getDEMWorkerSource(_e,Ee.source).loadTile(Ee)),this.actor.registerMessageHandler("removeDEMTile",(_e,Ee)=>a._(this,void 0,void 0,function*(){this._getDEMWorkerSource(_e,Ee.source).removeTile(Ee)})),this.actor.registerMessageHandler("getClusterExpansionZoom",(_e,Ee)=>a._(this,void 0,void 0,function*(){return this._getWorkerSource(_e,Ee.type,Ee.source).getClusterExpansionZoom(Ee)})),this.actor.registerMessageHandler("getClusterChildren",(_e,Ee)=>a._(this,void 0,void 0,function*(){return this._getWorkerSource(_e,Ee.type,Ee.source).getClusterChildren(Ee)})),this.actor.registerMessageHandler("getClusterLeaves",(_e,Ee)=>a._(this,void 0,void 0,function*(){return this._getWorkerSource(_e,Ee.type,Ee.source).getClusterLeaves(Ee)})),this.actor.registerMessageHandler("loadData",(_e,Ee)=>this._getWorkerSource(_e,Ee.type,Ee.source).loadData(Ee)),this.actor.registerMessageHandler("loadTile",(_e,Ee)=>this._getWorkerSource(_e,Ee.type,Ee.source).loadTile(Ee)),this.actor.registerMessageHandler("reloadTile",(_e,Ee)=>this._getWorkerSource(_e,Ee.type,Ee.source).reloadTile(Ee)),this.actor.registerMessageHandler("abortTile",(_e,Ee)=>this._getWorkerSource(_e,Ee.type,Ee.source).abortTile(Ee)),this.actor.registerMessageHandler("removeTile",(_e,Ee)=>this._getWorkerSource(_e,Ee.type,Ee.source).removeTile(Ee)),this.actor.registerMessageHandler("removeSource",(_e,Ee)=>a._(this,void 0,void 0,function*(){if(!this.workerSources[_e]||!this.workerSources[_e][Ee.type]||!this.workerSources[_e][Ee.type][Ee.source])return;const Te=this.workerSources[_e][Ee.type][Ee.source];delete this.workerSources[_e][Ee.type][Ee.source],Te.removeSource!==void 0&&Te.removeSource(Ee)})),this.actor.registerMessageHandler("setReferrer",(_e,Ee)=>a._(this,void 0,void 0,function*(){this.referrer=Ee})),this.actor.registerMessageHandler("syncRTLPluginState",(_e,Ee)=>this._syncRTLPluginState(_e,Ee)),this.actor.registerMessageHandler("importScript",(_e,Ee)=>a._(this,void 0,void 0,function*(){this.self.importScripts(Ee)})),this.actor.registerMessageHandler("setImages",(_e,Ee)=>this._setImages(_e,Ee)),this.actor.registerMessageHandler("updateLayers",(_e,Ee)=>a._(this,void 0,void 0,function*(){this._getLayerIndex(_e).update(Ee.layers,Ee.removedIds)})),this.actor.registerMessageHandler("setLayers",(_e,Ee)=>a._(this,void 0,void 0,function*(){this._getLayerIndex(_e).replace(Ee)}))}_setImages(fe,_e){return a._(this,void 0,void 0,function*(){this.availableImages[fe]=_e;for(const Ee in this.workerSources[fe]){const Te=this.workerSources[fe][Ee];for(const at in Te)Te[at].availableImages=_e}})}_syncRTLPluginState(fe,_e){return a._(this,void 0,void 0,function*(){a.by.setState(_e);const Ee=a.by.getPluginURL();if(_e.pluginStatus==="loaded"&&!a.by.isParsed()&&Ee!=null){this.self.importScripts(Ee);const Te=a.by.isParsed();if(Te)return Te;throw new Error(`RTL Text Plugin failed to import scripts from ${Ee}`)}return!1})}_getAvailableImages(fe){let _e=this.availableImages[fe];return _e||(_e=[]),_e}_getLayerIndex(fe){let _e=this.layerIndexes[fe];return _e||(_e=this.layerIndexes[fe]=new f),_e}_getWorkerSource(fe,_e,Ee){if(this.workerSources[fe]||(this.workerSources[fe]={}),this.workerSources[fe][_e]||(this.workerSources[fe][_e]={}),!this.workerSources[fe][_e][Ee]){const Te={sendAsync:(at,it)=>(at.targetMapId=fe,this.actor.sendAsync(at,it))};switch(_e){case"vector":this.workerSources[fe][_e][Ee]=new B(Te,this._getLayerIndex(fe),this._getAvailableImages(fe));break;case"geojson":this.workerSources[fe][_e][Ee]=new Gn(Te,this._getLayerIndex(fe),this._getAvailableImages(fe));break;default:this.workerSources[fe][_e][Ee]=new this.externalWorkerSourceTypes[_e](Te,this._getLayerIndex(fe),this._getAvailableImages(fe))}}return this.workerSources[fe][_e][Ee]}_getDEMWorkerSource(fe,_e){return this.demWorkerSources[fe]||(this.demWorkerSources[fe]={}),this.demWorkerSources[fe][_e]||(this.demWorkerSources[fe][_e]=new P),this.demWorkerSources[fe][_e]}}return a.i(self)&&(self.worker=new Zn(self)),Zn}),o(["./shared"],function(a){var f="4.0.0-pre.4";let g,x;const k={now:typeof performance<"u"&&performance&&performance.now?performance.now.bind(performance):Date.now.bind(Date),frameAsync:O=>new Promise((u,p)=>{const C=requestAnimationFrame(u);O.signal.addEventListener("abort",()=>{cancelAnimationFrame(C),p(a.c())})}),getImageData(O,u=0){return this.getImageCanvasContext(O).getImageData(-u,-u,O.width+2*u,O.height+2*u)},getImageCanvasContext(O){const u=window.document.createElement("canvas"),p=u.getContext("2d",{willReadFrequently:!0});if(!p)throw new Error("failed to create canvas 2d context");return u.width=O.width,u.height=O.height,p.drawImage(O,0,0,O.width,O.height),p},resolveURL:O=>(g||(g=document.createElement("a")),g.href=O,g.href),hardwareConcurrency:typeof navigator<"u"&&navigator.hardwareConcurrency||4,get prefersReducedMotion(){return!!matchMedia&&(x==null&&(x=matchMedia("(prefers-reduced-motion: reduce)")),x.matches)}};class B{static testProp(u){if(!B.docStyle)return u[0];for(let p=0;p<u.length;p++)if(u[p]in B.docStyle)return u[p];return u[0]}static create(u,p,C){const M=window.document.createElement(u);return p!==void 0&&(M.className=p),C&&C.appendChild(M),M}static createNS(u,p){return window.document.createElementNS(u,p)}static disableDrag(){B.docStyle&&B.selectProp&&(B.userSelect=B.docStyle[B.selectProp],B.docStyle[B.selectProp]="none")}static enableDrag(){B.docStyle&&B.selectProp&&(B.docStyle[B.selectProp]=B.userSelect)}static setTransform(u,p){u.style[B.transformProp]=p}static addEventListener(u,p,C,M={}){u.addEventListener(p,C,"passive"in M?M:M.capture)}static removeEventListener(u,p,C,M={}){u.removeEventListener(p,C,"passive"in M?M:M.capture)}static suppressClickInternal(u){u.preventDefault(),u.stopPropagation(),window.removeEventListener("click",B.suppressClickInternal,!0)}static suppressClick(){window.addEventListener("click",B.suppressClickInternal,!0),window.setTimeout(()=>{window.removeEventListener("click",B.suppressClickInternal,!0)},0)}static getScale(u){const p=u.getBoundingClientRect();return{x:p.width/u.offsetWidth||1,y:p.height/u.offsetHeight||1,boundingClientRect:p}}static getPoint(u,p,C){const M=p.boundingClientRect;return new a.P((C.clientX-M.left)/p.x-u.clientLeft,(C.clientY-M.top)/p.y-u.clientTop)}static mousePos(u,p){const C=B.getScale(u);return B.getPoint(u,C,p)}static touchPos(u,p){const C=[],M=B.getScale(u);for(let I=0;I<p.length;I++)C.push(B.getPoint(u,M,p[I]));return C}static mouseButton(u){return u.button}static remove(u){u.parentNode&&u.parentNode.removeChild(u)}}B.docStyle=typeof window<"u"&&window.document&&window.document.documentElement.style,B.selectProp=B.testProp(["userSelect","MozUserSelect","WebkitUserSelect","msUserSelect"]),B.transformProp=B.testProp(["transform","WebkitTransform"]);const P={supported:!1,testSupport:function(O){!W&&H&&($?q(O):R=O)}};let R,H,W=!1,$=!1;function q(O){const u=O.createTexture();O.bindTexture(O.TEXTURE_2D,u);try{if(O.texImage2D(O.TEXTURE_2D,0,O.RGBA,O.RGBA,O.UNSIGNED_BYTE,H),O.isContextLost())return;P.supported=!0}catch{}O.deleteTexture(u),W=!0}var oe,ne;typeof document<"u"&&(H=document.createElement("img"),H.onload=function(){R&&q(R),R=null,$=!0},H.onerror=function(){W=!0,R=null},H.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA="),function(O){let u,p,C,M;O.resetRequestQueue=()=>{u=[],p=0,C=0,M={}},O.addThrottleControl=G=>{const te=C++;return M[te]=G,te},O.removeThrottleControl=G=>{delete M[G],L()},O.getImage=(G,te,Ae=!0)=>new Promise((he,Me)=>{P.supported&&(G.headers||(G.headers={}),G.headers.accept="image/webp,*/*"),a.e(G,{type:"image"}),u.push({abortController:te,requestParameters:G,supportImageRefresh:Ae,state:"queued",onError:De=>{Me(De)},onSuccess:De=>{he(De)}}),L()});const I=G=>a._(this,void 0,void 0,function*(){G.state="running";const{requestParameters:te,supportImageRefresh:Ae,onError:he,onSuccess:Me,abortController:De}=G,je=Ae===!1&&!a.i(self)&&!a.g(te.url)&&(!te.headers||Object.keys(te.headers).reduce((ft,Bt)=>ft&&Bt==="accept",!0));p++;const Qe=je?j(te,De):a.m(te,De);try{const ft=yield Qe;delete G.abortController,G.state="completed",ft.data instanceof HTMLImageElement||a.b(ft.data)?Me(ft):ft.data&&Me({data:yield(Le=ft.data,typeof createImageBitmap=="function"?a.d(Le):a.f(Le)),cacheControl:ft.cacheControl,expires:ft.expires})}catch(ft){delete G.abortController,he(ft)}finally{p--,L()}var Le}),L=()=>{const G=(()=>{for(const te of Object.keys(M))if(M[te]())return!0;return!1})()?a.a.MAX_PARALLEL_IMAGE_REQUESTS_PER_FRAME:a.a.MAX_PARALLEL_IMAGE_REQUESTS;for(let te=p;te<G&&u.length>0;te++){const Ae=u.shift();Ae.abortController.signal.aborted?te--:I(Ae)}},j=(G,te)=>new Promise((Ae,he)=>{const Me=new Image,De=G.url,je=G.credentials;je&&je==="include"?Me.crossOrigin="use-credentials":(je&&je==="same-origin"||!a.s(De))&&(Me.crossOrigin="anonymous"),te.signal.addEventListener("abort",()=>{Me.src="",he(a.c())}),Me.fetchPriority="high",Me.onload=()=>{Me.onerror=Me.onload=null,Ae({data:Me})},Me.onerror=()=>{Me.onerror=Me.onload=null,te.signal.aborted||he(new Error("Could not load image. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."))},Me.src=De})}(oe||(oe={})),oe.resetRequestQueue(),function(O){O.Glyphs="Glyphs",O.Image="Image",O.Source="Source",O.SpriteImage="SpriteImage",O.SpriteJSON="SpriteJSON",O.Style="Style",O.Tile="Tile",O.Unknown="Unknown"}(ne||(ne={}));class ce{constructor(u){this._transformRequestFn=u}transformRequest(u,p){return this._transformRequestFn&&this._transformRequestFn(u,p)||{url:u}}normalizeSpriteURL(u,p,C){const M=function(I){const L=I.match(ae);if(!L)throw new Error(`Unable to parse URL "${I}"`);return{protocol:L[1],authority:L[2],path:L[3]||"/",params:L[4]?L[4].split("&"):[]}}(u);return M.path+=`${p}${C}`,function(I){const L=I.params.length?`?${I.params.join("&")}`:"";return`${I.protocol}://${I.authority}${I.path}${L}`}(M)}setTransformRequest(u){this._transformRequestFn=u}}const ae=/^(\w+):\/\/([^/?]*)(\/[^?]+)?\??(.+)?/;function ue(O){var u=new a.A(3);return u[0]=O[0],u[1]=O[1],u[2]=O[2],u}var ye,Re=function(O,u,p){return O[0]=u[0]-p[0],O[1]=u[1]-p[1],O[2]=u[2]-p[2],O};ye=new a.A(3),a.A!=Float32Array&&(ye[0]=0,ye[1]=0,ye[2]=0);var Ne=function(O){var u=O[0],p=O[1];return u*u+p*p};function rt(O){const u=[];if(typeof O=="string")u.push({id:"default",url:O});else if(O&&O.length>0){const p=[];for(const{id:C,url:M}of O){const I=`${C}${M}`;p.indexOf(I)===-1&&(p.push(I),u.push({id:C,url:M}))}}return u}(function(){var O=new a.A(2);a.A!=Float32Array&&(O[0]=0,O[1]=0)})();class ct{constructor(u,p,C,M){this.context=u,this.format=C,this.texture=u.gl.createTexture(),this.update(p,M)}update(u,p,C){const{width:M,height:I}=u,L=!(this.size&&this.size[0]===M&&this.size[1]===I||C),{context:j}=this,{gl:G}=j;if(this.useMipmap=!!(p&&p.useMipmap),G.bindTexture(G.TEXTURE_2D,this.texture),j.pixelStoreUnpackFlipY.set(!1),j.pixelStoreUnpack.set(1),j.pixelStoreUnpackPremultiplyAlpha.set(this.format===G.RGBA&&(!p||p.premultiply!==!1)),L)this.size=[M,I],u instanceof HTMLImageElement||u instanceof HTMLCanvasElement||u instanceof HTMLVideoElement||u instanceof ImageData||a.b(u)?G.texImage2D(G.TEXTURE_2D,0,this.format,this.format,G.UNSIGNED_BYTE,u):G.texImage2D(G.TEXTURE_2D,0,this.format,M,I,0,this.format,G.UNSIGNED_BYTE,u.data);else{const{x:te,y:Ae}=C||{x:0,y:0};u instanceof HTMLImageElement||u instanceof HTMLCanvasElement||u instanceof HTMLVideoElement||u instanceof ImageData||a.b(u)?G.texSubImage2D(G.TEXTURE_2D,0,te,Ae,G.RGBA,G.UNSIGNED_BYTE,u):G.texSubImage2D(G.TEXTURE_2D,0,te,Ae,M,I,G.RGBA,G.UNSIGNED_BYTE,u.data)}this.useMipmap&&this.isSizePowerOfTwo()&&G.generateMipmap(G.TEXTURE_2D)}bind(u,p,C){const{context:M}=this,{gl:I}=M;I.bindTexture(I.TEXTURE_2D,this.texture),C!==I.LINEAR_MIPMAP_NEAREST||this.isSizePowerOfTwo()||(C=I.LINEAR),u!==this.filter&&(I.texParameteri(I.TEXTURE_2D,I.TEXTURE_MAG_FILTER,u),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_MIN_FILTER,C||u),this.filter=u),p!==this.wrap&&(I.texParameteri(I.TEXTURE_2D,I.TEXTURE_WRAP_S,p),I.texParameteri(I.TEXTURE_2D,I.TEXTURE_WRAP_T,p),this.wrap=p)}isSizePowerOfTwo(){return this.size[0]===this.size[1]&&Math.log(this.size[0])/Math.LN2%1==0}destroy(){const{gl:u}=this.context;u.deleteTexture(this.texture),this.texture=null}}function Fe(O){const{userImage:u}=O;return!!(u&&u.render&&u.render())&&(O.data.replace(new Uint8Array(u.data.buffer)),!0)}class He extends a.E{constructor(){super(),this.images={},this.updatedImages={},this.callbackDispatchedThisFrame={},this.loaded=!1,this.requestors=[],this.patterns={},this.atlasImage=new a.R({width:1,height:1}),this.dirty=!0}isLoaded(){return this.loaded}setLoaded(u){if(this.loaded!==u&&(this.loaded=u,u)){for(const{ids:p,promiseResolve:C}of this.requestors)C(this._getImagesForIds(p));this.requestors=[]}}getImage(u){const p=this.images[u];if(p&&!p.data&&p.spriteData){const C=p.spriteData;p.data=new a.R({width:C.width,height:C.height},C.context.getImageData(C.x,C.y,C.width,C.height).data),p.spriteData=null}return p}addImage(u,p){if(this.images[u])throw new Error(`Image id ${u} already exist, use updateImage instead`);this._validate(u,p)&&(this.images[u]=p)}_validate(u,p){let C=!0;const M=p.data||p.spriteData;return this._validateStretch(p.stretchX,M&&M.width)||(this.fire(new a.j(new Error(`Image "${u}" has invalid "stretchX" value`))),C=!1),this._validateStretch(p.stretchY,M&&M.height)||(this.fire(new a.j(new Error(`Image "${u}" has invalid "stretchY" value`))),C=!1),this._validateContent(p.content,p)||(this.fire(new a.j(new Error(`Image "${u}" has invalid "content" value`))),C=!1),C}_validateStretch(u,p){if(!u)return!0;let C=0;for(const M of u){if(M[0]<C||M[1]<M[0]||p<M[1])return!1;C=M[1]}return!0}_validateContent(u,p){if(!u)return!0;if(u.length!==4)return!1;const C=p.spriteData,M=C&&C.width||p.data.width,I=C&&C.height||p.data.height;return!(u[0]<0||M<u[0]||u[1]<0||I<u[1]||u[2]<0||M<u[2]||u[3]<0||I<u[3]||u[2]<u[0]||u[3]<u[1])}updateImage(u,p,C=!0){const M=this.getImage(u);if(C&&(M.data.width!==p.data.width||M.data.height!==p.data.height))throw new Error(`size mismatch between old image (${M.data.width}x${M.data.height}) and new image (${p.data.width}x${p.data.height}).`);p.version=M.version+1,this.images[u]=p,this.updatedImages[u]=!0}removeImage(u){const p=this.images[u];delete this.images[u],delete this.patterns[u],p.userImage&&p.userImage.onRemove&&p.userImage.onRemove()}listImages(){return Object.keys(this.images)}getImages(u){return new Promise((p,C)=>{let M=!0;if(!this.isLoaded())for(const I of u)this.images[I]||(M=!1);this.isLoaded()||M?p(this._getImagesForIds(u)):this.requestors.push({ids:u,promiseResolve:p})})}_getImagesForIds(u){const p={};for(const C of u){let M=this.getImage(C);M||(this.fire(new a.k("styleimagemissing",{id:C})),M=this.getImage(C)),M?p[C]={data:M.data.clone(),pixelRatio:M.pixelRatio,sdf:M.sdf,version:M.version,stretchX:M.stretchX,stretchY:M.stretchY,content:M.content,hasRenderCallback:!!(M.userImage&&M.userImage.render)}:a.w(`Image "${C}" could not be loaded. Please make sure you have added the image with map.addImage() or a "sprite" property in your style. You can provide missing images by listening for the "styleimagemissing" map event.`)}return p}getPixelSize(){const{width:u,height:p}=this.atlasImage;return{width:u,height:p}}getPattern(u){const p=this.patterns[u],C=this.getImage(u);if(!C)return null;if(p&&p.position.version===C.version)return p.position;if(p)p.position.version=C.version;else{const M={w:C.data.width+2,h:C.data.height+2,x:0,y:0},I=new a.I(M,C);this.patterns[u]={bin:M,position:I}}return this._updatePatternAtlas(),this.patterns[u].position}bind(u){const p=u.gl;this.atlasTexture?this.dirty&&(this.atlasTexture.update(this.atlasImage),this.dirty=!1):this.atlasTexture=new ct(u,this.atlasImage,p.RGBA),this.atlasTexture.bind(p.LINEAR,p.CLAMP_TO_EDGE)}_updatePatternAtlas(){const u=[];for(const I in this.patterns)u.push(this.patterns[I].bin);const{w:p,h:C}=a.p(u),M=this.atlasImage;M.resize({width:p||1,height:C||1});for(const I in this.patterns){const{bin:L}=this.patterns[I],j=L.x+1,G=L.y+1,te=this.getImage(I).data,Ae=te.width,he=te.height;a.R.copy(te,M,{x:0,y:0},{x:j,y:G},{width:Ae,height:he}),a.R.copy(te,M,{x:0,y:he-1},{x:j,y:G-1},{width:Ae,height:1}),a.R.copy(te,M,{x:0,y:0},{x:j,y:G+he},{width:Ae,height:1}),a.R.copy(te,M,{x:Ae-1,y:0},{x:j-1,y:G},{width:1,height:he}),a.R.copy(te,M,{x:0,y:0},{x:j+Ae,y:G},{width:1,height:he})}this.dirty=!0}beginFrame(){this.callbackDispatchedThisFrame={}}dispatchRenderCallbacks(u){for(const p of u){if(this.callbackDispatchedThisFrame[p])continue;this.callbackDispatchedThisFrame[p]=!0;const C=this.getImage(p);C||a.w(`Image with ID: "${p}" was not found`),Fe(C)&&this.updateImage(p,C)}}}const Ce=1e20;function jt(O,u,p,C,M,I,L,j,G){for(let te=u;te<u+C;te++)Ft(O,p*I+te,I,M,L,j,G);for(let te=p;te<p+M;te++)Ft(O,te*I+u,1,C,L,j,G)}function Ft(O,u,p,C,M,I,L){I[0]=0,L[0]=-Ce,L[1]=Ce,M[0]=O[u];for(let j=1,G=0,te=0;j<C;j++){M[j]=O[u+j*p];const Ae=j*j;do{const he=I[G];te=(M[j]-M[he]+Ae-he*he)/(j-he)/2}while(te<=L[G]&&--G>-1);G++,I[G]=j,L[G]=te,L[G+1]=Ce}for(let j=0,G=0;j<C;j++){for(;L[G+1]<j;)G++;const te=I[G],Ae=j-te;O[u+j*p]=M[te]+Ae*Ae}}class Jt{constructor(u,p){this.requestManager=u,this.localIdeographFontFamily=p,this.entries={}}setURL(u){this.url=u}getGlyphs(u){return a._(this,void 0,void 0,function*(){const p=[];for(const I in u)for(const L of u[I])p.push(this._getAndCacheGlyphsPromise(I,L));const C=yield Promise.all(p),M={};for(const{stack:I,id:L,glyph:j}of C)M[I]||(M[I]={}),M[I][L]=j&&{id:j.id,bitmap:j.bitmap.clone(),metrics:j.metrics};return M})}_getAndCacheGlyphsPromise(u,p){return a._(this,void 0,void 0,function*(){let C=this.entries[u];C||(C=this.entries[u]={glyphs:{},requests:{},ranges:{}});let M=C.glyphs[p];if(M!==void 0)return{stack:u,id:p,glyph:M};if(M=this._tinySDF(C,u,p),M)return C.glyphs[p]=M,{stack:u,id:p,glyph:M};const I=Math.floor(p/256);if(256*I>65535)throw new Error("glyphs > 65535 not supported");if(C.ranges[I])return{stack:u,id:p,glyph:M};if(!this.url)throw new Error("glyphsUrl is not set");if(!C.requests[I]){const j=Jt.loadGlyphRange(u,I,this.url,this.requestManager);C.requests[I]=j}const L=yield C.requests[I];for(const j in L)this._doesCharSupportLocalGlyph(+j)||(C.glyphs[+j]=L[+j]);return C.ranges[I]=!0,{stack:u,id:p,glyph:L[p]||null}})}_doesCharSupportLocalGlyph(u){return!!this.localIdeographFontFamily&&(a.u["CJK Unified Ideographs"](u)||a.u["Hangul Syllables"](u)||a.u.Hiragana(u)||a.u.Katakana(u))}_tinySDF(u,p,C){const M=this.localIdeographFontFamily;if(!M||!this._doesCharSupportLocalGlyph(C))return;let I=u.tinySDF;if(!I){let j="400";/bold/i.test(p)?j="900":/medium/i.test(p)?j="500":/light/i.test(p)&&(j="200"),I=u.tinySDF=new Jt.TinySDF({fontSize:48,buffer:6,radius:16,cutoff:.25,fontFamily:M,fontWeight:j})}const L=I.draw(String.fromCharCode(C));return{id:C,bitmap:new a.o({width:L.width||60,height:L.height||60},L.data),metrics:{width:L.glyphWidth/2||24,height:L.glyphHeight/2||24,left:L.glyphLeft/2+.5||0,top:L.glyphTop/2-27.5||-8,advance:L.glyphAdvance/2||24,isDoubleResolution:!0}}}}Jt.loadGlyphRange=function(O,u,p,C){return a._(this,void 0,void 0,function*(){const M=256*u,I=M+255,L=C.transformRequest(p.replace("{fontstack}",O).replace("{range}",`${M}-${I}`),ne.Glyphs),j=yield a.l(L,new AbortController);if(!j||!j.data)throw new Error(`Could not load glyph range. range: ${u}, ${M}-${I}`);const G={};for(const te of a.n(j.data))G[te.id]=te;return G})},Jt.TinySDF=class{constructor({fontSize:O=24,buffer:u=3,radius:p=8,cutoff:C=.25,fontFamily:M="sans-serif",fontWeight:I="normal",fontStyle:L="normal"}={}){this.buffer=u,this.cutoff=C,this.radius=p;const j=this.size=O+4*u,G=this._createCanvas(j),te=this.ctx=G.getContext("2d",{willReadFrequently:!0});te.font=`${L} ${I} ${O}px ${M}`,te.textBaseline="alphabetic",te.textAlign="left",te.fillStyle="black",this.gridOuter=new Float64Array(j*j),this.gridInner=new Float64Array(j*j),this.f=new Float64Array(j),this.z=new Float64Array(j+1),this.v=new Uint16Array(j)}_createCanvas(O){const u=document.createElement("canvas");return u.width=u.height=O,u}draw(O){const{width:u,actualBoundingBoxAscent:p,actualBoundingBoxDescent:C,actualBoundingBoxLeft:M,actualBoundingBoxRight:I}=this.ctx.measureText(O),L=Math.ceil(p),j=Math.max(0,Math.min(this.size-this.buffer,Math.ceil(I-M))),G=Math.min(this.size-this.buffer,L+Math.ceil(C)),te=j+2*this.buffer,Ae=G+2*this.buffer,he=Math.max(te*Ae,0),Me=new Uint8ClampedArray(he),De={data:Me,width:te,height:Ae,glyphWidth:j,glyphHeight:G,glyphTop:L,glyphLeft:0,glyphAdvance:u};if(j===0||G===0)return De;const{ctx:je,buffer:Qe,gridInner:Le,gridOuter:ft}=this;je.clearRect(Qe,Qe,j,G),je.fillText(O,Qe,Qe+L);const Bt=je.getImageData(Qe,Qe,j,G);ft.fill(Ce,0,he),Le.fill(0,0,he);for(let qe=0;qe<G;qe++)for(let _t=0;_t<j;_t++){const Ut=Bt.data[4*(qe*j+_t)+3]/255;if(Ut===0)continue;const Tt=(qe+Qe)*te+_t+Qe;if(Ut===1)ft[Tt]=0,Le[Tt]=Ce;else{const en=.5-Ut;ft[Tt]=en>0?en*en:0,Le[Tt]=en<0?en*en:0}}jt(ft,0,0,te,Ae,te,this.f,this.v,this.z),jt(Le,Qe,Qe,j,G,te,this.f,this.v,this.z);for(let qe=0;qe<he;qe++){const _t=Math.sqrt(ft[qe])-Math.sqrt(Le[qe]);Me[qe]=Math.round(255-255*(_t/this.radius+this.cutoff))}return De}};class Nt{constructor(){this.specification=a.v.light.position}possiblyEvaluate(u,p){return a.y(u.expression.evaluate(p))}interpolate(u,p,C){return{x:a.z.number(u.x,p.x,C),y:a.z.number(u.y,p.y,C),z:a.z.number(u.z,p.z,C)}}}let Ve;class nt extends a.E{constructor(u){super(),Ve=Ve||new a.q({anchor:new a.D(a.v.light.anchor),position:new Nt,color:new a.D(a.v.light.color),intensity:new a.D(a.v.light.intensity)}),this._transitionable=new a.T(Ve),this.setLight(u),this._transitioning=this._transitionable.untransitioned()}getLight(){return this._transitionable.serialize()}setLight(u,p={}){if(!this._validate(a.r,u,p))for(const C in u){const M=u[C];C.endsWith("-transition")?this._transitionable.setTransition(C.slice(0,-11),M):this._transitionable.setValue(C,M)}}updateTransitions(u){this._transitioning=this._transitionable.transitioned(u,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(u){this.properties=this._transitioning.possiblyEvaluate(u)}_validate(u,p,C){return(!C||C.validate!==!1)&&a.t(this,u.call(a.x,{value:p,style:{glyphs:!0,sprite:!0},styleSpec:a.v}))}}class Je{constructor(u,p){this.width=u,this.height=p,this.nextRow=0,this.data=new Uint8Array(this.width*this.height),this.dashEntry={}}getDash(u,p){const C=u.join(",")+String(p);return this.dashEntry[C]||(this.dashEntry[C]=this.addDash(u,p)),this.dashEntry[C]}getDashRanges(u,p,C){const M=[];let I=u.length%2==1?-u[u.length-1]*C:0,L=u[0]*C,j=!0;M.push({left:I,right:L,isDash:j,zeroLength:u[0]===0});let G=u[0];for(let te=1;te<u.length;te++){j=!j;const Ae=u[te];I=G*C,G+=Ae,L=G*C,M.push({left:I,right:L,isDash:j,zeroLength:Ae===0})}return M}addRoundDash(u,p,C){const M=p/2;for(let I=-C;I<=C;I++){const L=this.width*(this.nextRow+C+I);let j=0,G=u[j];for(let te=0;te<this.width;te++){te/G.right>1&&(G=u[++j]);const Ae=Math.abs(te-G.left),he=Math.abs(te-G.right),Me=Math.min(Ae,he);let De;const je=I/C*(M+1);if(G.isDash){const Qe=M-Math.abs(je);De=Math.sqrt(Me*Me+Qe*Qe)}else De=M-Math.sqrt(Me*Me+je*je);this.data[L+te]=Math.max(0,Math.min(255,De+128))}}}addRegularDash(u){for(let j=u.length-1;j>=0;--j){const G=u[j],te=u[j+1];G.zeroLength?u.splice(j,1):te&&te.isDash===G.isDash&&(te.left=G.left,u.splice(j,1))}const p=u[0],C=u[u.length-1];p.isDash===C.isDash&&(p.left=C.left-this.width,C.right=p.right+this.width);const M=this.width*this.nextRow;let I=0,L=u[I];for(let j=0;j<this.width;j++){j/L.right>1&&(L=u[++I]);const G=Math.abs(j-L.left),te=Math.abs(j-L.right),Ae=Math.min(G,te);this.data[M+j]=Math.max(0,Math.min(255,(L.isDash?Ae:-Ae)+128))}}addDash(u,p){const C=p?7:0,M=2*C+1;if(this.nextRow+M>this.height)return a.w("LineAtlas out of space"),null;let I=0;for(let j=0;j<u.length;j++)I+=u[j];if(I!==0){const j=this.width/I,G=this.getDashRanges(u,this.width,j);p?this.addRoundDash(G,j,C):this.addRegularDash(G)}const L={y:(this.nextRow+C+.5)/this.height,height:2*C/this.height,width:I};return this.nextRow+=M,this.dirty=!0,L}bind(u){const p=u.gl;this.texture?(p.bindTexture(p.TEXTURE_2D,this.texture),this.dirty&&(this.dirty=!1,p.texSubImage2D(p.TEXTURE_2D,0,0,0,this.width,this.height,p.ALPHA,p.UNSIGNED_BYTE,this.data))):(this.texture=p.createTexture(),p.bindTexture(p.TEXTURE_2D,this.texture),p.texParameteri(p.TEXTURE_2D,p.TEXTURE_WRAP_S,p.REPEAT),p.texParameteri(p.TEXTURE_2D,p.TEXTURE_WRAP_T,p.REPEAT),p.texParameteri(p.TEXTURE_2D,p.TEXTURE_MIN_FILTER,p.LINEAR),p.texParameteri(p.TEXTURE_2D,p.TEXTURE_MAG_FILTER,p.LINEAR),p.texImage2D(p.TEXTURE_2D,0,p.ALPHA,this.width,this.height,0,p.ALPHA,p.UNSIGNED_BYTE,this.data))}}const Vt="maplibre_preloaded_worker_pool";class pt{constructor(){this.active={}}acquire(u){if(!this.workers)for(this.workers=[];this.workers.length<pt.workerCount;)this.workers.push(new Worker(a.a.WORKER_URL));return this.active[u]=!0,this.workers.slice()}release(u){delete this.active[u],this.numActive()===0&&(this.workers.forEach(p=>{p.terminate()}),this.workers=null)}isPreloaded(){return!!this.active[Vt]}numActive(){return Object.keys(this.active).length}}const dt=Math.floor(k.hardwareConcurrency/2);let kt,Dt;function Se(){return kt||(kt=new pt),kt}pt.workerCount=a.B(globalThis)?Math.max(Math.min(dt,3),1):1;class de{constructor(u,p){this.workerPool=u,this.actors=[],this.currentActor=0,this.id=p;const C=this.workerPool.acquire(p);for(let M=0;M<C.length;M++){const I=new a.C(C[M],p);I.name=`Worker ${M}`,this.actors.push(I)}if(!this.actors.length)throw new Error("No actors found")}broadcast(u,p){const C=[];for(const M of this.actors)C.push(M.sendAsync({type:u,data:p}));return Promise.all(C)}getActor(){return this.currentActor=(this.currentActor+1)%this.actors.length,this.actors[this.currentActor]}remove(u=!0){this.actors.forEach(p=>{p.remove()}),this.actors=[],u&&this.workerPool.release(this.id)}registerMessageHandler(u,p){for(const C of this.actors)C.registerMessageHandler(u,p)}}function xe(){return Dt||(Dt=new de(Se(),a.G),Dt.registerMessageHandler("getResource",(O,u,p)=>a.m(u,p))),Dt}function Pe(O,u){const p=a.F();return a.H(p,p,[1,1,0]),a.J(p,p,[.5*O.width,.5*O.height,1]),a.K(p,p,O.calculatePosMatrix(u.toUnwrapped()))}function Ze(O,u,p,C,M,I){const L=function(he,Me,De){if(he)for(const je of he){const Qe=Me[je];if(Qe&&Qe.source===De&&Qe.type==="fill-extrusion")return!0}else for(const je in Me){const Qe=Me[je];if(Qe.source===De&&Qe.type==="fill-extrusion")return!0}return!1}(M&&M.layers,u,O.id),j=I.maxPitchScaleFactor(),G=O.tilesIn(C,j,L);G.sort(Xe);const te=[];for(const he of G)te.push({wrappedTileID:he.tileID.wrapped().key,queryResults:he.tile.queryRenderedFeatures(u,p,O._state,he.queryGeometry,he.cameraQueryGeometry,he.scale,M,I,j,Pe(O.transform,he.tileID))});const Ae=function(he){const Me={},De={};for(const je of he){const Qe=je.queryResults,Le=je.wrappedTileID,ft=De[Le]=De[Le]||{};for(const Bt in Qe){const qe=Qe[Bt],_t=ft[Bt]=ft[Bt]||{},Ut=Me[Bt]=Me[Bt]||[];for(const Tt of qe)_t[Tt.featureIndex]||(_t[Tt.featureIndex]=!0,Ut.push(Tt))}}return Me}(te);for(const he in Ae)Ae[he].forEach(Me=>{const De=Me.feature,je=O.getFeatureState(De.layer["source-layer"],De.id);De.source=De.layer.source,De.layer["source-layer"]&&(De.sourceLayer=De.layer["source-layer"]),De.state=je});return Ae}function Xe(O,u){const p=O.tileID,C=u.tileID;return p.overscaledZ-C.overscaledZ||p.canonical.y-C.canonical.y||p.wrap-C.wrap||p.canonical.x-C.canonical.x}function wt(O,u,p){return a._(this,void 0,void 0,function*(){let C=O;if(O.url?C=(yield a.h(u.transformRequest(O.url,ne.Source),p)).data:yield k.frameAsync(p),!C)return null;const M=a.L(a.e(C,O),["tiles","minzoom","maxzoom","attribution","bounds","scheme","tileSize","encoding"]);return"vector_layers"in C&&C.vector_layers&&(M.vectorLayerIds=C.vector_layers.map(I=>I.id)),M})}class Kt{constructor(u,p){u&&(p?this.setSouthWest(u).setNorthEast(p):Array.isArray(u)&&(u.length===4?this.setSouthWest([u[0],u[1]]).setNorthEast([u[2],u[3]]):this.setSouthWest(u[0]).setNorthEast(u[1])))}setNorthEast(u){return this._ne=u instanceof a.M?new a.M(u.lng,u.lat):a.M.convert(u),this}setSouthWest(u){return this._sw=u instanceof a.M?new a.M(u.lng,u.lat):a.M.convert(u),this}extend(u){const p=this._sw,C=this._ne;let M,I;if(u instanceof a.M)M=u,I=u;else{if(!(u instanceof Kt))return Array.isArray(u)?u.length===4||u.every(Array.isArray)?this.extend(Kt.convert(u)):this.extend(a.M.convert(u)):u&&("lng"in u||"lon"in u)&&"lat"in u?this.extend(a.M.convert(u)):this;if(M=u._sw,I=u._ne,!M||!I)return this}return p||C?(p.lng=Math.min(M.lng,p.lng),p.lat=Math.min(M.lat,p.lat),C.lng=Math.max(I.lng,C.lng),C.lat=Math.max(I.lat,C.lat)):(this._sw=new a.M(M.lng,M.lat),this._ne=new a.M(I.lng,I.lat)),this}getCenter(){return new a.M((this._sw.lng+this._ne.lng)/2,(this._sw.lat+this._ne.lat)/2)}getSouthWest(){return this._sw}getNorthEast(){return this._ne}getNorthWest(){return new a.M(this.getWest(),this.getNorth())}getSouthEast(){return new a.M(this.getEast(),this.getSouth())}getWest(){return this._sw.lng}getSouth(){return this._sw.lat}getEast(){return this._ne.lng}getNorth(){return this._ne.lat}toArray(){return[this._sw.toArray(),this._ne.toArray()]}toString(){return`LngLatBounds(${this._sw.toString()}, ${this._ne.toString()})`}isEmpty(){return!(this._sw&&this._ne)}contains(u){const{lng:p,lat:C}=a.M.convert(u);let M=this._sw.lng<=p&&p<=this._ne.lng;return this._sw.lng>this._ne.lng&&(M=this._sw.lng>=p&&p>=this._ne.lng),this._sw.lat<=C&&C<=this._ne.lat&&M}static convert(u){return u instanceof Kt?u:u&&new Kt(u)}static fromLngLat(u,p=0){const C=360*p/40075017,M=C/Math.cos(Math.PI/180*u.lat);return new Kt(new a.M(u.lng-M,u.lat-C),new a.M(u.lng+M,u.lat+C))}}class Pt{constructor(u,p,C){this.bounds=Kt.convert(this.validateBounds(u)),this.minzoom=p||0,this.maxzoom=C||24}validateBounds(u){return Array.isArray(u)&&u.length===4?[Math.max(-180,u[0]),Math.max(-90,u[1]),Math.min(180,u[2]),Math.min(90,u[3])]:[-180,-90,180,90]}contains(u){const p=Math.pow(2,u.z),C=Math.floor(a.N(this.bounds.getWest())*p),M=Math.floor(a.O(this.bounds.getNorth())*p),I=Math.ceil(a.N(this.bounds.getEast())*p),L=Math.ceil(a.O(this.bounds.getSouth())*p);return u.x>=C&&u.x<I&&u.y>=M&&u.y<L}}class zn extends a.E{constructor(u,p,C,M){if(super(),this.id=u,this.dispatcher=C,this.type="vector",this.minzoom=0,this.maxzoom=22,this.scheme="xyz",this.tileSize=512,this.reparseOverscaled=!0,this.isTileClipped=!0,this._loaded=!1,a.e(this,a.L(p,["url","scheme","tileSize","promoteId"])),this._options=a.e({type:"vector"},p),this._collectResourceTiming=p.collectResourceTiming,this.tileSize!==512)throw new Error("vector tile sources must have a tileSize of 512");this.setEventedParent(M)}load(){return a._(this,void 0,void 0,function*(){this._loaded=!1,this.fire(new a.k("dataloading",{dataType:"source"})),this._tileJSONRequest=new AbortController;try{const u=yield wt(this._options,this.map._requestManager,this._tileJSONRequest);this._tileJSONRequest=null,this._loaded=!0,this.map.style.sourceCaches[this.id].clearTiles(),u&&(a.e(this,u),u.bounds&&(this.tileBounds=new Pt(u.bounds,this.minzoom,this.maxzoom)),this.fire(new a.k("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new a.k("data",{dataType:"source",sourceDataType:"content"})))}catch(u){this._tileJSONRequest=null,this.fire(new a.j(u))}})}loaded(){return this._loaded}hasTile(u){return!this.tileBounds||this.tileBounds.contains(u.canonical)}onAdd(u){this.map=u,this.load()}setSourceProperty(u){this._tileJSONRequest&&this._tileJSONRequest.abort(),u(),this.load()}setTiles(u){return this.setSourceProperty(()=>{this._options.tiles=u}),this}setUrl(u){return this.setSourceProperty(()=>{this.url=u,this._options.url=u}),this}onRemove(){this._tileJSONRequest&&(this._tileJSONRequest.abort(),this._tileJSONRequest=null)}serialize(){return a.e({},this._options)}loadTile(u){return a._(this,void 0,void 0,function*(){const p=u.tileID.canonical.url(this.tiles,this.map.getPixelRatio(),this.scheme),C={request:this.map._requestManager.transformRequest(p,ne.Tile),uid:u.uid,tileID:u.tileID,zoom:u.tileID.overscaledZ,tileSize:this.tileSize*u.tileID.overscaleFactor(),type:this.type,source:this.id,pixelRatio:this.map.getPixelRatio(),showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId};C.request.collectResourceTiming=this._collectResourceTiming;let M="reloadTile";if(u.actor&&u.state!=="expired"){if(u.state==="loading")return new Promise((I,L)=>{u.reloadPromise={resolve:I,reject:L}})}else u.actor=this.dispatcher.getActor(),M="loadTile";u.abortController=new AbortController;try{const I=yield u.actor.sendAsync({type:M,data:C},u.abortController);if(delete u.abortController,u.aborted)return;this._afterTileLoadWorkerResponse(u,I)}catch(I){if(delete u.abortController,u.aborted)return;if(I&&I.status!==404)throw I;this._afterTileLoadWorkerResponse(u,null)}})}_afterTileLoadWorkerResponse(u,p){if(p&&p.resourceTiming&&(u.resourceTiming=p.resourceTiming),p&&this.map._refreshExpiredTiles&&u.setExpiryData(p),u.loadVectorData(p,this.map.painter),u.reloadPromise){const C=u.reloadPromise;u.reloadPromise=null,this.loadTile(u).then(C.resolve).catch(C.reject)}}abortTile(u){return a._(this,void 0,void 0,function*(){u.abortController&&(u.abortController.abort(),delete u.abortController),u.actor&&(yield u.actor.sendAsync({type:"abortTile",data:{uid:u.uid,type:this.type,source:this.id}}))})}unloadTile(u){return a._(this,void 0,void 0,function*(){u.unloadVectorData(),u.actor&&(yield u.actor.sendAsync({type:"removeTile",data:{uid:u.uid,type:this.type,source:this.id}}))})}hasTransition(){return!1}}class mt extends a.E{constructor(u,p,C,M){super(),this.id=u,this.dispatcher=C,this.setEventedParent(M),this.type="raster",this.minzoom=0,this.maxzoom=22,this.roundZoom=!0,this.scheme="xyz",this.tileSize=512,this._loaded=!1,this._options=a.e({type:"raster"},p),a.e(this,a.L(p,["url","scheme","tileSize"]))}load(){return a._(this,void 0,void 0,function*(){this._loaded=!1,this.fire(new a.k("dataloading",{dataType:"source"})),this._tileJSONRequest=new AbortController;try{const u=yield wt(this._options,this.map._requestManager,this._tileJSONRequest);this._tileJSONRequest=null,this._loaded=!0,u&&(a.e(this,u),u.bounds&&(this.tileBounds=new Pt(u.bounds,this.minzoom,this.maxzoom)),this.fire(new a.k("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new a.k("data",{dataType:"source",sourceDataType:"content"})))}catch(u){this._tileJSONRequest=null,this.fire(new a.j(u))}})}loaded(){return this._loaded}onAdd(u){this.map=u,this.load()}onRemove(){this._tileJSONRequest&&(this._tileJSONRequest.abort(),this._tileJSONRequest=null)}setSourceProperty(u){this._tileJSONRequest&&(this._tileJSONRequest.abort(),this._tileJSONRequest=null),u(),this.load()}setTiles(u){return this.setSourceProperty(()=>{this._options.tiles=u}),this}serialize(){return a.e({},this._options)}hasTile(u){return!this.tileBounds||this.tileBounds.contains(u.canonical)}loadTile(u){return a._(this,void 0,void 0,function*(){const p=u.tileID.canonical.url(this.tiles,this.map.getPixelRatio(),this.scheme);u.abortController=new AbortController;try{const C=yield oe.getImage(this.map._requestManager.transformRequest(p,ne.Tile),u.abortController,this.map._refreshExpiredTiles);if(delete u.abortController,u.aborted)return void(u.state="unloaded");if(C&&C.data){this.map._refreshExpiredTiles&&C.cacheControl&&C.expires&&u.setExpiryData({cacheControl:C.cacheControl,expires:C.expires});const M=this.map.painter.context,I=M.gl,L=C.data;u.texture=this.map.painter.getTileTexture(L.width),u.texture?u.texture.update(L,{useMipmap:!0}):(u.texture=new ct(M,L,I.RGBA,{useMipmap:!0}),u.texture.bind(I.LINEAR,I.CLAMP_TO_EDGE,I.LINEAR_MIPMAP_NEAREST),M.extTextureFilterAnisotropic&&I.texParameterf(I.TEXTURE_2D,M.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,M.extTextureFilterAnisotropicMax)),u.state="loaded"}}catch(C){if(delete u.abortController,u.aborted)u.state="unloaded";else if(C)throw u.state="errored",C}})}abortTile(u){return a._(this,void 0,void 0,function*(){u.abortController&&(u.abortController.abort(),delete u.abortController)})}unloadTile(u){return a._(this,void 0,void 0,function*(){u.texture&&this.map.painter.saveTileTexture(u.texture)})}hasTransition(){return!1}}class pn extends mt{constructor(u,p,C,M){super(u,p,C,M),this.type="raster-dem",this.maxzoom=22,this._options=a.e({type:"raster-dem"},p),this.encoding=p.encoding||"mapbox",this.redFactor=p.redFactor,this.greenFactor=p.greenFactor,this.blueFactor=p.blueFactor,this.baseShift=p.baseShift}loadTile(u){return a._(this,void 0,void 0,function*(){const p=u.tileID.canonical.url(this.tiles,this.map.getPixelRatio(),this.scheme),C=this.map._requestManager.transformRequest(p,ne.Tile);u.neighboringTiles=this._getNeighboringTiles(u.tileID),u.abortController=new AbortController;try{const M=yield oe.getImage(C,u.abortController,this.map._refreshExpiredTiles);if(delete u.abortController,u.aborted)return void(u.state="unloaded");if(M&&M.data){const I=M.data;this.map._refreshExpiredTiles&&M.cacheControl&&M.expires&&u.setExpiryData({cacheControl:M.cacheControl,expires:M.expires});const L=a.b(I)&&a.S()?I:yield this.readImageNow(I),j={type:this.type,uid:u.uid,source:this.id,rawImageData:L,encoding:this.encoding,redFactor:this.redFactor,greenFactor:this.greenFactor,blueFactor:this.blueFactor,baseShift:this.baseShift};if(!u.actor||u.state==="expired"){u.actor=this.dispatcher.getActor();const G=yield u.actor.sendAsync({type:"loadDEMTile",data:j});u.dem=G,u.needsHillshadePrepare=!0,u.needsTerrainPrepare=!0,u.state="loaded"}}}catch(M){if(delete u.abortController,u.aborted)u.state="unloaded";else if(M)throw u.state="errored",M}})}readImageNow(u){return a._(this,void 0,void 0,function*(){if(typeof VideoFrame<"u"&&a.U()){const p=u.width+2,C=u.height+2;try{return new a.R({width:p,height:C},yield a.V(u,-1,-1,p,C))}catch{}}return k.getImageData(u,1)})}_getNeighboringTiles(u){const p=u.canonical,C=Math.pow(2,p.z),M=(p.x-1+C)%C,I=p.x===0?u.wrap-1:u.wrap,L=(p.x+1+C)%C,j=p.x+1===C?u.wrap+1:u.wrap,G={};return G[new a.Q(u.overscaledZ,I,p.z,M,p.y).key]={backfilled:!1},G[new a.Q(u.overscaledZ,j,p.z,L,p.y).key]={backfilled:!1},p.y>0&&(G[new a.Q(u.overscaledZ,I,p.z,M,p.y-1).key]={backfilled:!1},G[new a.Q(u.overscaledZ,u.wrap,p.z,p.x,p.y-1).key]={backfilled:!1},G[new a.Q(u.overscaledZ,j,p.z,L,p.y-1).key]={backfilled:!1}),p.y+1<C&&(G[new a.Q(u.overscaledZ,I,p.z,M,p.y+1).key]={backfilled:!1},G[new a.Q(u.overscaledZ,u.wrap,p.z,p.x,p.y+1).key]={backfilled:!1},G[new a.Q(u.overscaledZ,j,p.z,L,p.y+1).key]={backfilled:!1}),G}unloadTile(u){return a._(this,void 0,void 0,function*(){u.demTexture&&this.map.painter.saveTileTexture(u.demTexture),u.fbo&&(u.fbo.destroy(),delete u.fbo),u.dem&&delete u.dem,delete u.neighboringTiles,u.state="unloaded",u.actor&&(yield u.actor.sendAsync({type:"removeDEMTile",data:{type:this.type,uid:u.uid,source:this.id}}))})}}class ir extends a.E{constructor(u,p,C,M){super(),this.id=u,this.type="geojson",this.minzoom=0,this.maxzoom=18,this.tileSize=512,this.isTileClipped=!0,this.reparseOverscaled=!0,this._removed=!1,this._pendingLoads=0,this.actor=C.getActor(),this.setEventedParent(M),this._data=p.data,this._options=a.e({},p),this._collectResourceTiming=p.collectResourceTiming,p.maxzoom!==void 0&&(this.maxzoom=p.maxzoom),p.type&&(this.type=p.type),p.attribution&&(this.attribution=p.attribution),this.promoteId=p.promoteId;const I=a.W/this.tileSize;this.workerOptions=a.e({source:this.id,cluster:p.cluster||!1,geojsonVtOptions:{buffer:(p.buffer!==void 0?p.buffer:128)*I,tolerance:(p.tolerance!==void 0?p.tolerance:.375)*I,extent:a.W,maxZoom:this.maxzoom,lineMetrics:p.lineMetrics||!1,generateId:p.generateId||!1},superclusterOptions:{maxZoom:p.clusterMaxZoom!==void 0?p.clusterMaxZoom:this.maxzoom-1,minPoints:Math.max(2,p.clusterMinPoints||2),extent:a.W,radius:(p.clusterRadius||50)*I,log:!1,generateId:p.generateId||!1},clusterProperties:p.clusterProperties,filter:p.filter},p.workerOptions),typeof this.promoteId=="string"&&(this.workerOptions.promoteId=this.promoteId)}load(){return a._(this,void 0,void 0,function*(){yield this._updateWorkerData()})}onAdd(u){this.map=u,this.load()}setData(u){return this._data=u,this._updateWorkerData(),this}updateData(u){return this._updateWorkerData(u),this}setClusterOptions(u){return this.workerOptions.cluster=u.cluster,u&&(u.clusterRadius!==void 0&&(this.workerOptions.superclusterOptions.radius=u.clusterRadius),u.clusterMaxZoom!==void 0&&(this.workerOptions.superclusterOptions.maxZoom=u.clusterMaxZoom)),this._updateWorkerData(),this}getClusterExpansionZoom(u){return this.actor.sendAsync({type:"getClusterExpansionZoom",data:{type:this.type,clusterId:u,source:this.id}})}getClusterChildren(u){return this.actor.sendAsync({type:"getClusterChildren",data:{type:this.type,clusterId:u,source:this.id}})}getClusterLeaves(u,p,C){return this.actor.sendAsync({type:"getClusterLeaves",data:{type:this.type,source:this.id,clusterId:u,limit:p,offset:C}})}_updateWorkerData(u){return a._(this,void 0,void 0,function*(){const p=a.e({type:this.type},this.workerOptions);u?p.dataDiff=u:typeof this._data=="string"?(p.request=this.map._requestManager.transformRequest(k.resolveURL(this._data),ne.Source),p.request.collectResourceTiming=this._collectResourceTiming):p.data=JSON.stringify(this._data),this._pendingLoads++,this.fire(new a.k("dataloading",{dataType:"source"}));try{const C=yield this.actor.sendAsync({type:"loadData",data:p});if(this._pendingLoads--,this._removed||C.abandoned)return void this.fire(new a.k("dataabort",{dataType:"source"}));let M=null;C.resourceTiming&&C.resourceTiming[this.id]&&(M=C.resourceTiming[this.id].slice(0));const I={dataType:"source"};this._collectResourceTiming&&M&&M.length>0&&a.e(I,{resourceTiming:M}),this.fire(new a.k("data",Object.assign(Object.assign({},I),{sourceDataType:"metadata"}))),this.fire(new a.k("data",Object.assign(Object.assign({},I),{sourceDataType:"content"})))}catch(C){if(this._pendingLoads--,this._removed)return void this.fire(new a.k("dataabort",{dataType:"source"}));this.fire(new a.j(C))}})}loaded(){return this._pendingLoads===0}loadTile(u){return a._(this,void 0,void 0,function*(){const p=u.actor?"reloadTile":"loadTile";u.actor=this.actor;const C={type:this.type,uid:u.uid,tileID:u.tileID,zoom:u.tileID.overscaledZ,maxZoom:this.maxzoom,tileSize:this.tileSize,source:this.id,pixelRatio:this.map.getPixelRatio(),showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId};u.abortController=new AbortController;const M=yield this.actor.sendAsync({type:p,data:C},u.abortController);delete u.abortController,u.unloadVectorData(),u.aborted||u.loadVectorData(M,this.map.painter,p==="reloadTile")})}abortTile(u){return a._(this,void 0,void 0,function*(){u.abortController&&(u.abortController.abort(),delete u.abortController),u.aborted=!0})}unloadTile(u){return a._(this,void 0,void 0,function*(){u.unloadVectorData(),yield this.actor.sendAsync({type:"removeTile",data:{uid:u.uid,type:this.type,source:this.id}})})}onRemove(){this._removed=!0,this.actor.sendAsync({type:"removeSource",data:{type:this.type,source:this.id}})}serialize(){return a.e({},this._options,{type:this.type,data:this._data})}hasTransition(){return!1}}var Sn=a.X([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]);class nr extends a.E{constructor(u,p,C,M){super(),this.id=u,this.dispatcher=C,this.coordinates=p.coordinates,this.type="image",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.tiles={},this._loaded=!1,this.setEventedParent(M),this.options=p}load(u){return a._(this,void 0,void 0,function*(){this._loaded=!1,this.fire(new a.k("dataloading",{dataType:"source"})),this.url=this.options.url,this._request=new AbortController;try{const p=yield oe.getImage(this.map._requestManager.transformRequest(this.url,ne.Image),this._request);this._request=null,this._loaded=!0,p&&p.data&&(this.image=p.data,u&&(this.coordinates=u),this._finishLoading())}catch(p){this._request=null,this.fire(new a.j(p))}})}loaded(){return this._loaded}updateImage(u){return u.url?(this._request&&(this._request.abort(),this._request=null),this.options.url=u.url,this.load(u.coordinates).finally(()=>{this.texture=null}),this):this}_finishLoading(){this.map&&(this.setCoordinates(this.coordinates),this.fire(new a.k("data",{dataType:"source",sourceDataType:"metadata"})))}onAdd(u){this.map=u,this.load()}onRemove(){this._request&&(this._request.abort(),this._request=null)}setCoordinates(u){this.coordinates=u;const p=u.map(a.Y.fromLngLat);this.tileID=function(M){let I=1/0,L=1/0,j=-1/0,G=-1/0;for(const Me of M)I=Math.min(I,Me.x),L=Math.min(L,Me.y),j=Math.max(j,Me.x),G=Math.max(G,Me.y);const te=Math.max(j-I,G-L),Ae=Math.max(0,Math.floor(-Math.log(te)/Math.LN2)),he=Math.pow(2,Ae);return new a.a0(Ae,Math.floor((I+j)/2*he),Math.floor((L+G)/2*he))}(p),this.minzoom=this.maxzoom=this.tileID.z;const C=p.map(M=>this.tileID.getTilePoint(M)._round());return this._boundsArray=new a.Z,this._boundsArray.emplaceBack(C[0].x,C[0].y,0,0),this._boundsArray.emplaceBack(C[1].x,C[1].y,a.W,0),this._boundsArray.emplaceBack(C[3].x,C[3].y,0,a.W),this._boundsArray.emplaceBack(C[2].x,C[2].y,a.W,a.W),this.boundsBuffer&&(this.boundsBuffer.destroy(),delete this.boundsBuffer),this.fire(new a.k("data",{dataType:"source",sourceDataType:"content"})),this}prepare(){if(Object.keys(this.tiles).length===0||!this.image)return;const u=this.map.painter.context,p=u.gl;this.boundsBuffer||(this.boundsBuffer=u.createVertexBuffer(this._boundsArray,Sn.members)),this.boundsSegments||(this.boundsSegments=a.$.simpleSegment(0,0,4,2)),this.texture||(this.texture=new ct(u,this.image,p.RGBA),this.texture.bind(p.LINEAR,p.CLAMP_TO_EDGE));let C=!1;for(const M in this.tiles){const I=this.tiles[M];I.state!=="loaded"&&(I.state="loaded",I.texture=this.texture,C=!0)}C&&this.fire(new a.k("data",{dataType:"source",sourceDataType:"idle",sourceId:this.id}))}loadTile(u){return a._(this,void 0,void 0,function*(){this.tileID&&this.tileID.equals(u.tileID.canonical)?(this.tiles[String(u.tileID.wrap)]=u,u.buckets={}):u.state="errored"})}serialize(){return{type:"image",url:this.options.url,coordinates:this.coordinates}}hasTransition(){return!1}}class Mr extends nr{constructor(u,p,C,M){super(u,p,C,M),this.roundZoom=!0,this.type="video",this.options=p}load(){return a._(this,void 0,void 0,function*(){this._loaded=!1;const u=this.options;this.urls=[];for(const p of u.urls)this.urls.push(this.map._requestManager.transformRequest(p,ne.Source).url);try{const p=yield a.a2(this.urls);if(this._loaded=!0,!p)return;this.video=p,this.video.loop=!0,this.video.addEventListener("playing",()=>{this.map.triggerRepaint()}),this.map&&this.video.play(),this._finishLoading()}catch(p){this.fire(new a.j(p))}})}pause(){this.video&&this.video.pause()}play(){this.video&&this.video.play()}seek(u){if(this.video){const p=this.video.seekable;u<p.start(0)||u>p.end(0)?this.fire(new a.j(new a.a1(`sources.${this.id}`,null,`Playback for this video can be set only between the ${p.start(0)} and ${p.end(0)}-second mark.`))):this.video.currentTime=u}}getVideo(){return this.video}onAdd(u){this.map||(this.map=u,this.load(),this.video&&(this.video.play(),this.setCoordinates(this.coordinates)))}prepare(){if(Object.keys(this.tiles).length===0||this.video.readyState<2)return;const u=this.map.painter.context,p=u.gl;this.boundsBuffer||(this.boundsBuffer=u.createVertexBuffer(this._boundsArray,Sn.members)),this.boundsSegments||(this.boundsSegments=a.$.simpleSegment(0,0,4,2)),this.texture?this.video.paused||(this.texture.bind(p.LINEAR,p.CLAMP_TO_EDGE),p.texSubImage2D(p.TEXTURE_2D,0,0,0,p.RGBA,p.UNSIGNED_BYTE,this.video)):(this.texture=new ct(u,this.video,p.RGBA),this.texture.bind(p.LINEAR,p.CLAMP_TO_EDGE));let C=!1;for(const M in this.tiles){const I=this.tiles[M];I.state!=="loaded"&&(I.state="loaded",I.texture=this.texture,C=!0)}C&&this.fire(new a.k("data",{dataType:"source",sourceDataType:"idle",sourceId:this.id}))}serialize(){return{type:"video",urls:this.urls,coordinates:this.coordinates}}hasTransition(){return this.video&&!this.video.paused}}class Qr extends nr{constructor(u,p,C,M){super(u,p,C,M),p.coordinates?Array.isArray(p.coordinates)&&p.coordinates.length===4&&!p.coordinates.some(I=>!Array.isArray(I)||I.length!==2||I.some(L=>typeof L!="number"))||this.fire(new a.j(new a.a1(`sources.${u}`,null,'"coordinates" property must be an array of 4 longitude/latitude array pairs'))):this.fire(new a.j(new a.a1(`sources.${u}`,null,'missing required property "coordinates"'))),p.animate&&typeof p.animate!="boolean"&&this.fire(new a.j(new a.a1(`sources.${u}`,null,'optional "animate" property must be a boolean value'))),p.canvas?typeof p.canvas=="string"||p.canvas instanceof HTMLCanvasElement||this.fire(new a.j(new a.a1(`sources.${u}`,null,'"canvas" must be either a string representing the ID of the canvas element from which to read, or an HTMLCanvasElement instance'))):this.fire(new a.j(new a.a1(`sources.${u}`,null,'missing required property "canvas"'))),this.options=p,this.animate=p.animate===void 0||p.animate}load(){return a._(this,void 0,void 0,function*(){this._loaded=!0,this.canvas||(this.canvas=this.options.canvas instanceof HTMLCanvasElement?this.options.canvas:document.getElementById(this.options.canvas)),this.width=this.canvas.width,this.height=this.canvas.height,this._hasInvalidDimensions()?this.fire(new a.j(new Error("Canvas dimensions cannot be less than or equal to zero."))):(this.play=function(){this._playing=!0,this.map.triggerRepaint()},this.pause=function(){this._playing&&(this.prepare(),this._playing=!1)},this._finishLoading())})}getCanvas(){return this.canvas}onAdd(u){this.map=u,this.load(),this.canvas&&this.animate&&this.play()}onRemove(){this.pause()}prepare(){let u=!1;if(this.canvas.width!==this.width&&(this.width=this.canvas.width,u=!0),this.canvas.height!==this.height&&(this.height=this.canvas.height,u=!0),this._hasInvalidDimensions()||Object.keys(this.tiles).length===0)return;const p=this.map.painter.context,C=p.gl;this.boundsBuffer||(this.boundsBuffer=p.createVertexBuffer(this._boundsArray,Sn.members)),this.boundsSegments||(this.boundsSegments=a.$.simpleSegment(0,0,4,2)),this.texture?(u||this._playing)&&this.texture.update(this.canvas,{premultiply:!0}):this.texture=new ct(p,this.canvas,C.RGBA,{premultiply:!0});let M=!1;for(const I in this.tiles){const L=this.tiles[I];L.state!=="loaded"&&(L.state="loaded",L.texture=this.texture,M=!0)}M&&this.fire(new a.k("data",{dataType:"source",sourceDataType:"idle",sourceId:this.id}))}serialize(){return{type:"canvas",coordinates:this.coordinates}}hasTransition(){return this._playing}_hasInvalidDimensions(){for(const u of[this.canvas.width,this.canvas.height])if(isNaN(u)||u<=0)return!0;return!1}}const _r={},vi=O=>{switch(O){case"geojson":return ir;case"image":return nr;case"raster":return mt;case"raster-dem":return pn;case"vector":return zn;case"video":return Mr;case"canvas":return Qr}return _r[O]};class we extends a.E{constructor(){super(...arguments),this.pluginStatus="unavailable",this.pluginURL=null,this.dispatcher=xe(),this.queue=[]}_sendPluginStateToWorker(){return a._(this,void 0,void 0,function*(){yield this.dispatcher.broadcast("syncRTLPluginState",{pluginStatus:this.pluginStatus,pluginURL:this.pluginURL}),this.fire(new a.k("pluginStateChange",{pluginStatus:this.pluginStatus,pluginURL:this.pluginURL}))})}getRTLTextPluginStatus(){return this.pluginStatus}clearRTLTextPlugin(){this.pluginStatus="unavailable",this.pluginURL=null}setRTLTextPlugin(u,p=!1){return a._(this,void 0,void 0,function*(){if(this.pluginStatus==="deferred"||this.pluginStatus==="loading"||this.pluginStatus==="loaded")throw new Error("setRTLTextPlugin cannot be called multiple times.");this.pluginURL=k.resolveURL(u),this.pluginStatus="deferred",yield this._sendPluginStateToWorker(),p||(yield this._downloadRTLTextPlugin())})}_downloadRTLTextPlugin(){return a._(this,void 0,void 0,function*(){if(this.pluginStatus!=="deferred"||!this.pluginURL)throw new Error("rtl-text-plugin cannot be downloaded unless a pluginURL is specified");try{this.pluginStatus="loading",yield this._sendPluginStateToWorker(),yield a.l({url:this.pluginURL},new AbortController),this.pluginStatus="loaded"}catch{this.pluginStatus="error"}yield this._sendPluginStateToWorker()})}lazyLoadRTLTextPlugin(){return a._(this,void 0,void 0,function*(){this.pluginStatus==="deferred"&&(yield this._downloadRTLTextPlugin())})}}let V=null;function X(){return V||(V=new we),V}class me{constructor(u,p){this.timeAdded=0,this.fadeEndTime=0,this.tileID=u,this.uid=a.a3(),this.uses=0,this.tileSize=p,this.buckets={},this.expirationTime=null,this.queryPadding=0,this.hasSymbolBuckets=!1,this.hasRTLText=!1,this.dependencies={},this.rtt=[],this.rttCoords={},this.expiredRequestCount=0,this.state="loading"}registerFadeDuration(u){const p=u+this.timeAdded;p<this.fadeEndTime||(this.fadeEndTime=p)}wasRequested(){return this.state==="errored"||this.state==="loaded"||this.state==="reloading"}clearTextures(u){this.demTexture&&u.saveTileTexture(this.demTexture),this.demTexture=null}loadVectorData(u,p,C){if(this.hasData()&&this.unloadVectorData(),this.state="loaded",u){u.featureIndex&&(this.latestFeatureIndex=u.featureIndex,u.rawTileData?(this.latestRawTileData=u.rawTileData,this.latestFeatureIndex.rawTileData=u.rawTileData):this.latestRawTileData&&(this.latestFeatureIndex.rawTileData=this.latestRawTileData)),this.collisionBoxArray=u.collisionBoxArray,this.buckets=function(M,I){const L={};if(!I)return L;for(const j of M){const G=j.layerIds.map(te=>I.getLayer(te)).filter(Boolean);if(G.length!==0){j.layers=G,j.stateDependentLayerIds&&(j.stateDependentLayers=j.stateDependentLayerIds.map(te=>G.filter(Ae=>Ae.id===te)[0]));for(const te of G)L[te.id]=j}}return L}(u.buckets,p.style),this.hasSymbolBuckets=!1;for(const M in this.buckets){const I=this.buckets[M];if(I instanceof a.a5){if(this.hasSymbolBuckets=!0,!C)break;I.justReloaded=!0}}if(this.hasRTLText=!1,this.hasSymbolBuckets)for(const M in this.buckets){const I=this.buckets[M];if(I instanceof a.a5&&I.hasRTLText){this.hasRTLText=!0,X().lazyLoadRTLTextPlugin();break}}this.queryPadding=0;for(const M in this.buckets){const I=this.buckets[M];this.queryPadding=Math.max(this.queryPadding,p.style.getLayer(M).queryRadius(I))}u.imageAtlas&&(this.imageAtlas=u.imageAtlas),u.glyphAtlasImage&&(this.glyphAtlasImage=u.glyphAtlasImage)}else this.collisionBoxArray=new a.a4}unloadVectorData(){for(const u in this.buckets)this.buckets[u].destroy();this.buckets={},this.imageAtlasTexture&&this.imageAtlasTexture.destroy(),this.imageAtlas&&(this.imageAtlas=null),this.glyphAtlasTexture&&this.glyphAtlasTexture.destroy(),this.latestFeatureIndex=null,this.state="unloaded"}getBucket(u){return this.buckets[u.id]}upload(u){for(const C in this.buckets){const M=this.buckets[C];M.uploadPending()&&M.upload(u)}const p=u.gl;this.imageAtlas&&!this.imageAtlas.uploaded&&(this.imageAtlasTexture=new ct(u,this.imageAtlas.image,p.RGBA),this.imageAtlas.uploaded=!0),this.glyphAtlasImage&&(this.glyphAtlasTexture=new ct(u,this.glyphAtlasImage,p.ALPHA),this.glyphAtlasImage=null)}prepare(u){this.imageAtlas&&this.imageAtlas.patchUpdatedImages(u,this.imageAtlasTexture)}queryRenderedFeatures(u,p,C,M,I,L,j,G,te,Ae){return this.latestFeatureIndex&&this.latestFeatureIndex.rawTileData?this.latestFeatureIndex.query({queryGeometry:M,cameraQueryGeometry:I,scale:L,tileSize:this.tileSize,pixelPosMatrix:Ae,transform:G,params:j,queryPadding:this.queryPadding*te},u,p,C):{}}querySourceFeatures(u,p){const C=this.latestFeatureIndex;if(!C||!C.rawTileData)return;const M=C.loadVTLayers(),I=p&&p.sourceLayer?p.sourceLayer:"",L=M._geojsonTileLayer||M[I];if(!L)return;const j=a.a6(p&&p.filter),{z:G,x:te,y:Ae}=this.tileID.canonical,he={z:G,x:te,y:Ae};for(let Me=0;Me<L.length;Me++){const De=L.feature(Me);if(j.needGeometry){const Le=a.a7(De,!0);if(!j.filter(new a.a8(this.tileID.overscaledZ),Le,this.tileID.canonical))continue}else if(!j.filter(new a.a8(this.tileID.overscaledZ),De))continue;const je=C.getId(De,I),Qe=new a.a9(De,G,te,Ae,je);Qe.tile=he,u.push(Qe)}}hasData(){return this.state==="loaded"||this.state==="reloading"||this.state==="expired"}patternsLoaded(){return this.imageAtlas&&!!Object.keys(this.imageAtlas.patternPositions).length}setExpiryData(u){const p=this.expirationTime;if(u.cacheControl){const C=a.aa(u.cacheControl);C["max-age"]&&(this.expirationTime=Date.now()+1e3*C["max-age"])}else u.expires&&(this.expirationTime=new Date(u.expires).getTime());if(this.expirationTime){const C=Date.now();let M=!1;if(this.expirationTime>C)M=!1;else if(p)if(this.expirationTime<p)M=!0;else{const I=this.expirationTime-p;I?this.expirationTime=C+Math.max(I,3e4):M=!0}else M=!0;M?(this.expiredRequestCount++,this.state="expired"):this.expiredRequestCount=0}}getExpiryTimeout(){if(this.expirationTime)return this.expiredRequestCount?1e3*(1<<Math.min(this.expiredRequestCount-1,31)):Math.min(this.expirationTime-new Date().getTime(),Math.pow(2,31)-1)}setFeatureState(u,p){if(!this.latestFeatureIndex||!this.latestFeatureIndex.rawTileData||Object.keys(u).length===0)return;const C=this.latestFeatureIndex.loadVTLayers();for(const M in this.buckets){if(!p.style.hasLayer(M))continue;const I=this.buckets[M],L=I.layers[0].sourceLayer||"_geojsonTileLayer",j=C[L],G=u[L];if(!j||!G||Object.keys(G).length===0)continue;I.update(G,j,this.imageAtlas&&this.imageAtlas.patternPositions||{});const te=p&&p.style&&p.style.getLayer(M);te&&(this.queryPadding=Math.max(this.queryPadding,te.queryRadius(I)))}}holdingForFade(){return this.symbolFadeHoldUntil!==void 0}symbolFadeFinished(){return!this.symbolFadeHoldUntil||this.symbolFadeHoldUntil<k.now()}clearFadeHold(){this.symbolFadeHoldUntil=void 0}setHoldDuration(u){this.symbolFadeHoldUntil=k.now()+u}setDependencies(u,p){const C={};for(const M of p)C[M]=!0;this.dependencies[u]=C}hasDependency(u,p){for(const C of u){const M=this.dependencies[C];if(M){for(const I of p)if(M[I])return!0}}return!1}}class At{constructor(u,p){this.max=u,this.onRemove=p,this.reset()}reset(){for(const u in this.data)for(const p of this.data[u])p.timeout&&clearTimeout(p.timeout),this.onRemove(p.value);return this.data={},this.order=[],this}add(u,p,C){const M=u.wrapped().key;this.data[M]===void 0&&(this.data[M]=[]);const I={value:p,timeout:void 0};if(C!==void 0&&(I.timeout=setTimeout(()=>{this.remove(u,I)},C)),this.data[M].push(I),this.order.push(M),this.order.length>this.max){const L=this._getAndRemoveByKey(this.order[0]);L&&this.onRemove(L)}return this}has(u){return u.wrapped().key in this.data}getAndRemove(u){return this.has(u)?this._getAndRemoveByKey(u.wrapped().key):null}_getAndRemoveByKey(u){const p=this.data[u].shift();return p.timeout&&clearTimeout(p.timeout),this.data[u].length===0&&delete this.data[u],this.order.splice(this.order.indexOf(u),1),p.value}getByKey(u){const p=this.data[u];return p?p[0].value:null}get(u){return this.has(u)?this.data[u.wrapped().key][0].value:null}remove(u,p){if(!this.has(u))return this;const C=u.wrapped().key,M=p===void 0?0:this.data[C].indexOf(p),I=this.data[C][M];return this.data[C].splice(M,1),I.timeout&&clearTimeout(I.timeout),this.data[C].length===0&&delete this.data[C],this.onRemove(I.value),this.order.splice(this.order.indexOf(C),1),this}setMaxSize(u){for(this.max=u;this.order.length>this.max;){const p=this._getAndRemoveByKey(this.order[0]);p&&this.onRemove(p)}return this}filter(u){const p=[];for(const C in this.data)for(const M of this.data[C])u(M.value)||p.push(M);for(const C of p)this.remove(C.value.tileID,C)}}class bt{constructor(){this.state={},this.stateChanges={},this.deletedStates={}}updateState(u,p,C){const M=String(p);if(this.stateChanges[u]=this.stateChanges[u]||{},this.stateChanges[u][M]=this.stateChanges[u][M]||{},a.e(this.stateChanges[u][M],C),this.deletedStates[u]===null){this.deletedStates[u]={};for(const I in this.state[u])I!==M&&(this.deletedStates[u][I]=null)}else if(this.deletedStates[u]&&this.deletedStates[u][M]===null){this.deletedStates[u][M]={};for(const I in this.state[u][M])C[I]||(this.deletedStates[u][M][I]=null)}else for(const I in C)this.deletedStates[u]&&this.deletedStates[u][M]&&this.deletedStates[u][M][I]===null&&delete this.deletedStates[u][M][I]}removeFeatureState(u,p,C){if(this.deletedStates[u]===null)return;const M=String(p);if(this.deletedStates[u]=this.deletedStates[u]||{},C&&p!==void 0)this.deletedStates[u][M]!==null&&(this.deletedStates[u][M]=this.deletedStates[u][M]||{},this.deletedStates[u][M][C]=null);else if(p!==void 0)if(this.stateChanges[u]&&this.stateChanges[u][M])for(C in this.deletedStates[u][M]={},this.stateChanges[u][M])this.deletedStates[u][M][C]=null;else this.deletedStates[u][M]=null;else this.deletedStates[u]=null}getState(u,p){const C=String(p),M=a.e({},(this.state[u]||{})[C],(this.stateChanges[u]||{})[C]);if(this.deletedStates[u]===null)return{};if(this.deletedStates[u]){const I=this.deletedStates[u][p];if(I===null)return{};for(const L in I)delete M[L]}return M}initializeTileState(u,p){u.setFeatureState(this.state,p)}coalesceChanges(u,p){const C={};for(const M in this.stateChanges){this.state[M]=this.state[M]||{};const I={};for(const L in this.stateChanges[M])this.state[M][L]||(this.state[M][L]={}),a.e(this.state[M][L],this.stateChanges[M][L]),I[L]=this.state[M][L];C[M]=I}for(const M in this.deletedStates){this.state[M]=this.state[M]||{};const I={};if(this.deletedStates[M]===null)for(const L in this.state[M])I[L]={},this.state[M][L]={};else for(const L in this.deletedStates[M]){if(this.deletedStates[M][L]===null)this.state[M][L]={};else for(const j of Object.keys(this.deletedStates[M][L]))delete this.state[M][L][j];I[L]=this.state[M][L]}C[M]=C[M]||{},a.e(C[M],I)}if(this.stateChanges={},this.deletedStates={},Object.keys(C).length!==0)for(const M in u)u[M].setFeatureState(C,p)}}class Et extends a.E{constructor(u,p,C){super(),this.id=u,this.dispatcher=C,this.on("data",M=>{M.dataType==="source"&&M.sourceDataType==="metadata"&&(this._sourceLoaded=!0),this._sourceLoaded&&!this._paused&&M.dataType==="source"&&M.sourceDataType==="content"&&(this.reload(),this.transform&&this.update(this.transform,this.terrain),this._didEmitContent=!0)}),this.on("dataloading",()=>{this._sourceErrored=!1}),this.on("error",()=>{this._sourceErrored=this._source.loaded()}),this._source=((M,I,L,j)=>{const G=new(vi(I.type))(M,I,L,j);if(G.id!==M)throw new Error(`Expected Source id to be ${M} instead of ${G.id}`);return G})(u,p,C,this),this._tiles={},this._cache=new At(0,M=>this._unloadTile(M)),this._timers={},this._cacheTimers={},this._maxTileCacheSize=null,this._maxTileCacheZoomLevels=null,this._loadedParentTiles={},this._coveredTiles={},this._state=new bt,this._didEmitContent=!1,this._updated=!1}onAdd(u){this.map=u,this._maxTileCacheSize=u?u._maxTileCacheSize:null,this._maxTileCacheZoomLevels=u?u._maxTileCacheZoomLevels:null,this._source&&this._source.onAdd&&this._source.onAdd(u)}onRemove(u){this.clearTiles(),this._source&&this._source.onRemove&&this._source.onRemove(u)}loaded(){if(this._sourceErrored)return!0;if(!this._sourceLoaded||!this._source.loaded())return!1;if(!(this.used===void 0&&this.usedForTerrain===void 0||this.used||this.usedForTerrain))return!0;if(!this._updated)return!1;for(const u in this._tiles){const p=this._tiles[u];if(p.state!=="loaded"&&p.state!=="errored")return!1}return!0}getSource(){return this._source}pause(){this._paused=!0}resume(){if(!this._paused)return;const u=this._shouldReloadOnResume;this._paused=!1,this._shouldReloadOnResume=!1,u&&this.reload(),this.transform&&this.update(this.transform,this.terrain)}_loadTile(u,p,C){return a._(this,void 0,void 0,function*(){try{yield this._source.loadTile(u),this._tileLoaded(u,p,C)}catch(M){u.state="errored",M.status!==404?this._source.fire(new a.j(M,{tile:u})):this.update(this.transform,this.terrain)}})}_unloadTile(u){this._source.unloadTile&&this._source.unloadTile(u)}_abortTile(u){this._source.abortTile&&this._source.abortTile(u),this._source.fire(new a.k("dataabort",{tile:u,coord:u.tileID,dataType:"source"}))}serialize(){return this._source.serialize()}prepare(u){this._source.prepare&&this._source.prepare(),this._state.coalesceChanges(this._tiles,this.map?this.map.painter:null);for(const p in this._tiles){const C=this._tiles[p];C.upload(u),C.prepare(this.map.style.imageManager)}}getIds(){return Object.values(this._tiles).map(u=>u.tileID).sort(sr).map(u=>u.key)}getRenderableIds(u){const p=[];for(const C in this._tiles)this._isIdRenderable(C,u)&&p.push(this._tiles[C]);return u?p.sort((C,M)=>{const I=C.tileID,L=M.tileID,j=new a.P(I.canonical.x,I.canonical.y)._rotate(this.transform.angle),G=new a.P(L.canonical.x,L.canonical.y)._rotate(this.transform.angle);return I.overscaledZ-L.overscaledZ||G.y-j.y||G.x-j.x}).map(C=>C.tileID.key):p.map(C=>C.tileID).sort(sr).map(C=>C.key)}hasRenderableParent(u){const p=this.findLoadedParent(u,0);return!!p&&this._isIdRenderable(p.tileID.key)}_isIdRenderable(u,p){return this._tiles[u]&&this._tiles[u].hasData()&&!this._coveredTiles[u]&&(p||!this._tiles[u].holdingForFade())}reload(){if(this._paused)this._shouldReloadOnResume=!0;else{this._cache.reset();for(const u in this._tiles)this._tiles[u].state!=="errored"&&this._reloadTile(u,"reloading")}}_reloadTile(u,p){return a._(this,void 0,void 0,function*(){const C=this._tiles[u];C&&(C.state!=="loading"&&(C.state=p),yield this._loadTile(C,u,p))})}_tileLoaded(u,p,C){u.timeAdded=k.now(),C==="expired"&&(u.refreshedUponExpiration=!0),this._setTileReloadTimer(p,u),this.getSource().type==="raster-dem"&&u.dem&&this._backfillDEM(u),this._state.initializeTileState(u,this.map?this.map.painter:null),u.aborted||this._source.fire(new a.k("data",{dataType:"source",tile:u,coord:u.tileID}))}_backfillDEM(u){const p=this.getRenderableIds();for(let M=0;M<p.length;M++){const I=p[M];if(u.neighboringTiles&&u.neighboringTiles[I]){const L=this.getTileByID(I);C(u,L),C(L,u)}}function C(M,I){M.needsHillshadePrepare=!0,M.needsTerrainPrepare=!0;let L=I.tileID.canonical.x-M.tileID.canonical.x;const j=I.tileID.canonical.y-M.tileID.canonical.y,G=Math.pow(2,M.tileID.canonical.z),te=I.tileID.key;L===0&&j===0||Math.abs(j)>1||(Math.abs(L)>1&&(Math.abs(L+G)===1?L+=G:Math.abs(L-G)===1&&(L-=G)),I.dem&&M.dem&&(M.dem.backfillBorder(I.dem,L,j),M.neighboringTiles&&M.neighboringTiles[te]&&(M.neighboringTiles[te].backfilled=!0)))}}getTile(u){return this.getTileByID(u.key)}getTileByID(u){return this._tiles[u]}_retainLoadedChildren(u,p,C,M){for(const I in this._tiles){let L=this._tiles[I];if(M[I]||!L.hasData()||L.tileID.overscaledZ<=p||L.tileID.overscaledZ>C)continue;let j=L.tileID;for(;L&&L.tileID.overscaledZ>p+1;){const te=L.tileID.scaledTo(L.tileID.overscaledZ-1);L=this._tiles[te.key],L&&L.hasData()&&(j=te)}let G=j;for(;G.overscaledZ>p;)if(G=G.scaledTo(G.overscaledZ-1),u[G.key]){M[j.key]=j;break}}}findLoadedParent(u,p){if(u.key in this._loadedParentTiles){const C=this._loadedParentTiles[u.key];return C&&C.tileID.overscaledZ>=p?C:null}for(let C=u.overscaledZ-1;C>=p;C--){const M=u.scaledTo(C),I=this._getLoadedTile(M);if(I)return I}}_getLoadedTile(u){const p=this._tiles[u.key];return p&&p.hasData()?p:this._cache.getByKey(u.wrapped().key)}updateCacheSize(u){const p=Math.ceil(u.width/this._source.tileSize)+1,C=Math.ceil(u.height/this._source.tileSize)+1,M=Math.floor(p*C*(this._maxTileCacheZoomLevels===null?a.a.MAX_TILE_CACHE_ZOOM_LEVELS:this._maxTileCacheZoomLevels)),I=typeof this._maxTileCacheSize=="number"?Math.min(this._maxTileCacheSize,M):M;this._cache.setMaxSize(I)}handleWrapJump(u){const p=Math.round((u-(this._prevLng===void 0?u:this._prevLng))/360);if(this._prevLng=u,p){const C={};for(const M in this._tiles){const I=this._tiles[M];I.tileID=I.tileID.unwrapTo(I.tileID.wrap+p),C[I.tileID.key]=I}this._tiles=C;for(const M in this._timers)clearTimeout(this._timers[M]),delete this._timers[M];for(const M in this._tiles)this._setTileReloadTimer(M,this._tiles[M])}}update(u,p){if(this.transform=u,this.terrain=p,!this._sourceLoaded||this._paused)return;let C;this.updateCacheSize(u),this.handleWrapJump(this.transform.center.lng),this._coveredTiles={},this.used||this.usedForTerrain?this._source.tileID?C=u.getVisibleUnwrappedCoordinates(this._source.tileID).map(Ae=>new a.Q(Ae.canonical.z,Ae.wrap,Ae.canonical.z,Ae.canonical.x,Ae.canonical.y)):(C=u.coveringTiles({tileSize:this.usedForTerrain?this.tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:!this.usedForTerrain&&this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled,terrain:p}),this._source.hasTile&&(C=C.filter(Ae=>this._source.hasTile(Ae)))):C=[];const M=u.coveringZoomLevel(this._source),I=Math.max(M-Et.maxOverzooming,this._source.minzoom),L=Math.max(M+Et.maxUnderzooming,this._source.minzoom);if(this.usedForTerrain){const Ae={};for(const he of C)if(he.canonical.z>this._source.minzoom){const Me=he.scaledTo(he.canonical.z-1);Ae[Me.key]=Me;const De=he.scaledTo(Math.max(this._source.minzoom,Math.min(he.canonical.z,5)));Ae[De.key]=De}C=C.concat(Object.values(Ae))}const j=C.length===0&&!this._updated&&this._didEmitContent;this._updated=!0,j&&this.fire(new a.k("data",{sourceDataType:"idle",dataType:"source",sourceId:this.id}));const G=this._updateRetainedTiles(C,M);if(Lt(this._source.type)){const Ae={},he={},Me=Object.keys(G),De=k.now();for(const je of Me){const Qe=G[je],Le=this._tiles[je];if(!Le||Le.fadeEndTime!==0&&Le.fadeEndTime<=De)continue;const ft=this.findLoadedParent(Qe,I);ft&&(this._addTile(ft.tileID),Ae[ft.tileID.key]=ft.tileID),he[je]=Qe}this._retainLoadedChildren(he,M,L,G);for(const je in Ae)G[je]||(this._coveredTiles[je]=!0,G[je]=Ae[je]);if(p){const je={},Qe={};for(const Le of C)this._tiles[Le.key].hasData()?je[Le.key]=Le:Qe[Le.key]=Le;for(const Le in Qe){const ft=Qe[Le].children(this._source.maxzoom);this._tiles[ft[0].key]&&this._tiles[ft[1].key]&&this._tiles[ft[2].key]&&this._tiles[ft[3].key]&&(je[ft[0].key]=G[ft[0].key]=ft[0],je[ft[1].key]=G[ft[1].key]=ft[1],je[ft[2].key]=G[ft[2].key]=ft[2],je[ft[3].key]=G[ft[3].key]=ft[3],delete Qe[Le])}for(const Le in Qe){const ft=this.findLoadedParent(Qe[Le],this._source.minzoom);if(ft){je[ft.tileID.key]=G[ft.tileID.key]=ft.tileID;for(const Bt in je)je[Bt].isChildOf(ft.tileID)&&delete je[Bt]}}for(const Le in this._tiles)je[Le]||(this._coveredTiles[Le]=!0)}}for(const Ae in G)this._tiles[Ae].clearFadeHold();const te=a.ab(this._tiles,G);for(const Ae of te){const he=this._tiles[Ae];he.hasSymbolBuckets&&!he.holdingForFade()?he.setHoldDuration(this.map._fadeDuration):he.hasSymbolBuckets&&!he.symbolFadeFinished()||this._removeTile(Ae)}this._updateLoadedParentTileCache()}releaseSymbolFadeTiles(){for(const u in this._tiles)this._tiles[u].holdingForFade()&&this._removeTile(u)}_updateRetainedTiles(u,p){const C={},M={},I=Math.max(p-Et.maxOverzooming,this._source.minzoom),L=Math.max(p+Et.maxUnderzooming,this._source.minzoom),j={};for(const G of u){const te=this._addTile(G);C[G.key]=G,te.hasData()||p<this._source.maxzoom&&(j[G.key]=G)}this._retainLoadedChildren(j,p,L,C);for(const G of u){let te=this._tiles[G.key];if(te.hasData())continue;if(p+1>this._source.maxzoom){const he=G.children(this._source.maxzoom)[0],Me=this.getTile(he);if(Me&&Me.hasData()){C[he.key]=he;continue}}else{const he=G.children(this._source.maxzoom);if(C[he[0].key]&&C[he[1].key]&&C[he[2].key]&&C[he[3].key])continue}let Ae=te.wasRequested();for(let he=G.overscaledZ-1;he>=I;--he){const Me=G.scaledTo(he);if(M[Me.key])break;if(M[Me.key]=!0,te=this.getTile(Me),!te&&Ae&&(te=this._addTile(Me)),te){const De=te.hasData();if((Ae||De)&&(C[Me.key]=Me),Ae=te.wasRequested(),De)break}}}return C}_updateLoadedParentTileCache(){this._loadedParentTiles={};for(const u in this._tiles){const p=[];let C,M=this._tiles[u].tileID;for(;M.overscaledZ>0;){if(M.key in this._loadedParentTiles){C=this._loadedParentTiles[M.key];break}p.push(M.key);const I=M.scaledTo(M.overscaledZ-1);if(C=this._getLoadedTile(I),C)break;M=I}for(const I of p)this._loadedParentTiles[I]=C}}_addTile(u){let p=this._tiles[u.key];if(p)return p;p=this._cache.getAndRemove(u),p&&(this._setTileReloadTimer(u.key,p),p.tileID=u,this._state.initializeTileState(p,this.map?this.map.painter:null),this._cacheTimers[u.key]&&(clearTimeout(this._cacheTimers[u.key]),delete this._cacheTimers[u.key],this._setTileReloadTimer(u.key,p)));const C=p;return p||(p=new me(u,this._source.tileSize*u.overscaleFactor()),this._loadTile(p,u.key,p.state)),p.uses++,this._tiles[u.key]=p,C||this._source.fire(new a.k("dataloading",{tile:p,coord:p.tileID,dataType:"source"})),p}_setTileReloadTimer(u,p){u in this._timers&&(clearTimeout(this._timers[u]),delete this._timers[u]);const C=p.getExpiryTimeout();C&&(this._timers[u]=setTimeout(()=>{this._reloadTile(u,"expired"),delete this._timers[u]},C))}_removeTile(u){const p=this._tiles[u];p&&(p.uses--,delete this._tiles[u],this._timers[u]&&(clearTimeout(this._timers[u]),delete this._timers[u]),p.uses>0||(p.hasData()&&p.state!=="reloading"?this._cache.add(p.tileID,p,p.getExpiryTimeout()):(p.aborted=!0,this._abortTile(p),this._unloadTile(p))))}clearTiles(){this._shouldReloadOnResume=!1,this._paused=!1;for(const u in this._tiles)this._removeTile(u);this._cache.reset()}tilesIn(u,p,C){const M=[],I=this.transform;if(!I)return M;const L=C?I.getCameraQueryGeometry(u):u,j=u.map(je=>I.pointCoordinate(je,this.terrain)),G=L.map(je=>I.pointCoordinate(je,this.terrain)),te=this.getIds();let Ae=1/0,he=1/0,Me=-1/0,De=-1/0;for(const je of G)Ae=Math.min(Ae,je.x),he=Math.min(he,je.y),Me=Math.max(Me,je.x),De=Math.max(De,je.y);for(let je=0;je<te.length;je++){const Qe=this._tiles[te[je]];if(Qe.holdingForFade())continue;const Le=Qe.tileID,ft=Math.pow(2,I.zoom-Qe.tileID.overscaledZ),Bt=p*Qe.queryPadding*a.W/Qe.tileSize/ft,qe=[Le.getTilePoint(new a.Y(Ae,he)),Le.getTilePoint(new a.Y(Me,De))];if(qe[0].x-Bt<a.W&&qe[0].y-Bt<a.W&&qe[1].x+Bt>=0&&qe[1].y+Bt>=0){const _t=j.map(Tt=>Le.getTilePoint(Tt)),Ut=G.map(Tt=>Le.getTilePoint(Tt));M.push({tile:Qe,tileID:Le,queryGeometry:_t,cameraQueryGeometry:Ut,scale:ft})}}return M}getVisibleCoordinates(u){const p=this.getRenderableIds(u).map(C=>this._tiles[C].tileID);for(const C of p)C.posMatrix=this.transform.calculatePosMatrix(C.toUnwrapped());return p}hasTransition(){if(this._source.hasTransition())return!0;if(Lt(this._source.type)){const u=k.now();for(const p in this._tiles)if(this._tiles[p].fadeEndTime>=u)return!0}return!1}setFeatureState(u,p,C){this._state.updateState(u=u||"_geojsonTileLayer",p,C)}removeFeatureState(u,p,C){this._state.removeFeatureState(u=u||"_geojsonTileLayer",p,C)}getFeatureState(u,p){return this._state.getState(u=u||"_geojsonTileLayer",p)}setDependencies(u,p,C){const M=this._tiles[u];M&&M.setDependencies(p,C)}reloadTilesForDependencies(u,p){for(const C in this._tiles)this._tiles[C].hasDependency(u,p)&&this._reloadTile(C,"reloading");this._cache.filter(C=>!C.hasDependency(u,p))}}function sr(O,u){const p=Math.abs(2*O.wrap)-+(O.wrap<0),C=Math.abs(2*u.wrap)-+(u.wrap<0);return O.overscaledZ-u.overscaledZ||C-p||u.canonical.y-O.canonical.y||u.canonical.x-O.canonical.x}function Lt(O){return O==="raster"||O==="image"||O==="video"}Et.maxOverzooming=10,Et.maxUnderzooming=3;class Fn{constructor(u,p){this.reset(u,p)}reset(u,p){this.points=u||[],this._distances=[0];for(let C=1;C<this.points.length;C++)this._distances[C]=this._distances[C-1]+this.points[C].dist(this.points[C-1]);this.length=this._distances[this._distances.length-1],this.padding=Math.min(p||0,.5*this.length),this.paddedLength=this.length-2*this.padding}lerp(u){if(this.points.length===1)return this.points[0];u=a.ac(u,0,1);let p=1,C=this._distances[p];const M=u*this.paddedLength+this.padding;for(;C<M&&p<this._distances.length;)C=this._distances[++p];const I=p-1,L=this._distances[I],j=C-L,G=j>0?(M-L)/j:0;return this.points[I].mult(1-G).add(this.points[p].mult(G))}}function on(O,u){let p=!0;return O==="always"||O!=="never"&&u!=="never"||(p=!1),p}class m{constructor(u,p,C){const M=this.boxCells=[],I=this.circleCells=[];this.xCellCount=Math.ceil(u/C),this.yCellCount=Math.ceil(p/C);for(let L=0;L<this.xCellCount*this.yCellCount;L++)M.push([]),I.push([]);this.circleKeys=[],this.boxKeys=[],this.bboxes=[],this.circles=[],this.width=u,this.height=p,this.xScale=this.xCellCount/u,this.yScale=this.yCellCount/p,this.boxUid=0,this.circleUid=0}keysLength(){return this.boxKeys.length+this.circleKeys.length}insert(u,p,C,M,I){this._forEachCell(p,C,M,I,this._insertBoxCell,this.boxUid++),this.boxKeys.push(u),this.bboxes.push(p),this.bboxes.push(C),this.bboxes.push(M),this.bboxes.push(I)}insertCircle(u,p,C,M){this._forEachCell(p-M,C-M,p+M,C+M,this._insertCircleCell,this.circleUid++),this.circleKeys.push(u),this.circles.push(p),this.circles.push(C),this.circles.push(M)}_insertBoxCell(u,p,C,M,I,L){this.boxCells[I].push(L)}_insertCircleCell(u,p,C,M,I,L){this.circleCells[I].push(L)}_query(u,p,C,M,I,L,j){if(C<0||u>this.width||M<0||p>this.height)return[];const G=[];if(u<=0&&p<=0&&this.width<=C&&this.height<=M){if(I)return[{key:null,x1:u,y1:p,x2:C,y2:M}];for(let te=0;te<this.boxKeys.length;te++)G.push({key:this.boxKeys[te],x1:this.bboxes[4*te],y1:this.bboxes[4*te+1],x2:this.bboxes[4*te+2],y2:this.bboxes[4*te+3]});for(let te=0;te<this.circleKeys.length;te++){const Ae=this.circles[3*te],he=this.circles[3*te+1],Me=this.circles[3*te+2];G.push({key:this.circleKeys[te],x1:Ae-Me,y1:he-Me,x2:Ae+Me,y2:he+Me})}}else this._forEachCell(u,p,C,M,this._queryCell,G,{hitTest:I,overlapMode:L,seenUids:{box:{},circle:{}}},j);return G}query(u,p,C,M){return this._query(u,p,C,M,!1,null)}hitTest(u,p,C,M,I,L){return this._query(u,p,C,M,!0,I,L).length>0}hitTestCircle(u,p,C,M,I){const L=u-C,j=u+C,G=p-C,te=p+C;if(j<0||L>this.width||te<0||G>this.height)return!1;const Ae=[];return this._forEachCell(L,G,j,te,this._queryCellCircle,Ae,{hitTest:!0,overlapMode:M,circle:{x:u,y:p,radius:C},seenUids:{box:{},circle:{}}},I),Ae.length>0}_queryCell(u,p,C,M,I,L,j,G){const{seenUids:te,hitTest:Ae,overlapMode:he}=j,Me=this.boxCells[I];if(Me!==null){const je=this.bboxes;for(const Qe of Me)if(!te.box[Qe]){te.box[Qe]=!0;const Le=4*Qe,ft=this.boxKeys[Qe];if(u<=je[Le+2]&&p<=je[Le+3]&&C>=je[Le+0]&&M>=je[Le+1]&&(!G||G(ft))&&(!Ae||!on(he,ft.overlapMode))&&(L.push({key:ft,x1:je[Le],y1:je[Le+1],x2:je[Le+2],y2:je[Le+3]}),Ae))return!0}}const De=this.circleCells[I];if(De!==null){const je=this.circles;for(const Qe of De)if(!te.circle[Qe]){te.circle[Qe]=!0;const Le=3*Qe,ft=this.circleKeys[Qe];if(this._circleAndRectCollide(je[Le],je[Le+1],je[Le+2],u,p,C,M)&&(!G||G(ft))&&(!Ae||!on(he,ft.overlapMode))){const Bt=je[Le],qe=je[Le+1],_t=je[Le+2];if(L.push({key:ft,x1:Bt-_t,y1:qe-_t,x2:Bt+_t,y2:qe+_t}),Ae)return!0}}}return!1}_queryCellCircle(u,p,C,M,I,L,j,G){const{circle:te,seenUids:Ae,overlapMode:he}=j,Me=this.boxCells[I];if(Me!==null){const je=this.bboxes;for(const Qe of Me)if(!Ae.box[Qe]){Ae.box[Qe]=!0;const Le=4*Qe,ft=this.boxKeys[Qe];if(this._circleAndRectCollide(te.x,te.y,te.radius,je[Le+0],je[Le+1],je[Le+2],je[Le+3])&&(!G||G(ft))&&!on(he,ft.overlapMode))return L.push(!0),!0}}const De=this.circleCells[I];if(De!==null){const je=this.circles;for(const Qe of De)if(!Ae.circle[Qe]){Ae.circle[Qe]=!0;const Le=3*Qe,ft=this.circleKeys[Qe];if(this._circlesCollide(je[Le],je[Le+1],je[Le+2],te.x,te.y,te.radius)&&(!G||G(ft))&&!on(he,ft.overlapMode))return L.push(!0),!0}}}_forEachCell(u,p,C,M,I,L,j,G){const te=this._convertToXCellCoord(u),Ae=this._convertToYCellCoord(p),he=this._convertToXCellCoord(C),Me=this._convertToYCellCoord(M);for(let De=te;De<=he;De++)for(let je=Ae;je<=Me;je++)if(I.call(this,u,p,C,M,this.xCellCount*je+De,L,j,G))return}_convertToXCellCoord(u){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(u*this.xScale)))}_convertToYCellCoord(u){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(u*this.yScale)))}_circlesCollide(u,p,C,M,I,L){const j=M-u,G=I-p,te=C+L;return te*te>j*j+G*G}_circleAndRectCollide(u,p,C,M,I,L,j){const G=(L-M)/2,te=Math.abs(u-(M+G));if(te>G+C)return!1;const Ae=(j-I)/2,he=Math.abs(p-(I+Ae));if(he>Ae+C)return!1;if(te<=G||he<=Ae)return!0;const Me=te-G,De=he-Ae;return Me*Me+De*De<=C*C}}function un(O,u,p,C,M){const I=a.F();return u?(a.J(I,I,[1/M,1/M,1]),p||a.ad(I,I,C.angle)):a.K(I,C.labelPlaneMatrix,O),I}function In(O,u,p,C,M){if(u){const I=a.ae(O);return a.J(I,I,[M,M,1]),p||a.ad(I,I,-C.angle),I}return C.glCoordMatrix}function Gn(O,u,p){let C;p?(C=[O.x,O.y,p(O.x,O.y),1],a.af(C,C,u)):(C=[O.x,O.y,0,1],$t(C,C,u));const M=C[3];return{point:new a.P(C[0]/M,C[1]/M),signedDistanceFromCamera:M}}function Zn(O,u){return .5+O/u*.5}function Ke(O,u){const p=O[0]/O[3],C=O[1]/O[3];return p>=-u[0]&&p<=u[0]&&C>=-u[1]&&C<=u[1]}function fe(O,u,p,C,M,I,L,j,G,te){const Ae=C?O.textSizeData:O.iconSizeData,he=a.ag(Ae,p.transform.zoom),Me=[256/p.width*2+1,256/p.height*2+1],De=C?O.text.dynamicLayoutVertexArray:O.icon.dynamicLayoutVertexArray;De.clear();const je=O.lineVertexArray,Qe=C?O.text.placedSymbolArray:O.icon.placedSymbolArray,Le=p.transform.width/p.transform.height;let ft=!1;for(let Bt=0;Bt<Qe.length;Bt++){const qe=Qe.get(Bt);if(qe.hidden||qe.writingMode===a.ah.vertical&&!ft){Gt(qe.numGlyphs,De);continue}let _t;if(ft=!1,te?(_t=[qe.anchorX,qe.anchorY,te(qe.anchorX,qe.anchorY),1],a.af(_t,_t,u)):(_t=[qe.anchorX,qe.anchorY,0,1],$t(_t,_t,u)),!Ke(_t,Me)){Gt(qe.numGlyphs,De);continue}const Ut=Zn(p.transform.cameraToCenterDistance,_t[3]),Tt=a.ai(Ae,he,qe),en=L?Tt/Ut:Tt*Ut,hn=new a.P(qe.anchorX,qe.anchorY),An=Gn(hn,M,te).point,On={projections:{},offsets:{}},lr=Te(qe,en,!1,j,u,M,I,O.glyphOffsetArray,je,De,An,hn,On,Le,G,te);ft=lr.useVertical,(lr.notEnoughRoom||ft||lr.needsFlipping&&Te(qe,en,!0,j,u,M,I,O.glyphOffsetArray,je,De,An,hn,On,Le,G,te).notEnoughRoom)&&Gt(qe.numGlyphs,De)}C?O.text.dynamicLayoutVertexBuffer.updateData(De):O.icon.dynamicLayoutVertexBuffer.updateData(De)}function _e(O,u,p,C,M,I,L,j,G,te,Ae,he,Me){const De=j.glyphStartIndex+j.numGlyphs,je=j.lineStartIndex,Qe=j.lineStartIndex+j.lineLength,Le=u.getoffsetX(j.glyphStartIndex),ft=u.getoffsetX(De-1),Bt=Ct(O*Le,p,C,M,I,L,j.segment,je,Qe,G,te,Ae,he,Me);if(!Bt)return null;const qe=Ct(O*ft,p,C,M,I,L,j.segment,je,Qe,G,te,Ae,he,Me);return qe?{first:Bt,last:qe}:null}function Ee(O,u,p,C){return O===a.ah.horizontal&&Math.abs(p.y-u.y)>Math.abs(p.x-u.x)*C?{useVertical:!0}:(O===a.ah.vertical?u.y<p.y:u.x>p.x)?{needsFlipping:!0}:null}function Te(O,u,p,C,M,I,L,j,G,te,Ae,he,Me,De,je,Qe){const Le=u/24,ft=O.lineOffsetX*Le,Bt=O.lineOffsetY*Le;let qe;if(O.numGlyphs>1){const _t=O.glyphStartIndex+O.numGlyphs,Ut=O.lineStartIndex,Tt=O.lineStartIndex+O.lineLength,en=_e(Le,j,ft,Bt,p,Ae,he,O,G,I,Me,je,Qe);if(!en)return{notEnoughRoom:!0};const hn=Gn(en.first.point,L,Qe).point,An=Gn(en.last.point,L,Qe).point;if(C&&!p){const On=Ee(O.writingMode,hn,An,De);if(On)return On}qe=[en.first];for(let On=O.glyphStartIndex+1;On<_t-1;On++)qe.push(Ct(Le*j.getoffsetX(On),ft,Bt,p,Ae,he,O.segment,Ut,Tt,G,I,Me,je,Qe));qe.push(en.last)}else{if(C&&!p){const Ut=Gn(he,M,Qe).point,Tt=O.lineStartIndex+O.segment+1,en=new a.P(G.getx(Tt),G.gety(Tt)),hn=Gn(en,M,Qe),An=hn.signedDistanceFromCamera>0?hn.point:at(he,en,Ut,1,M,Qe),On=Ee(O.writingMode,Ut,An,De);if(On)return On}const _t=Ct(Le*j.getoffsetX(O.glyphStartIndex),ft,Bt,p,Ae,he,O.segment,O.lineStartIndex,O.lineStartIndex+O.lineLength,G,I,Me,je,Qe);if(!_t)return{notEnoughRoom:!0};qe=[_t]}for(const _t of qe)a.aj(te,_t.point,_t.angle);return{}}function at(O,u,p,C,M,I){const L=Gn(O.add(O.sub(u)._unit()),M,I).point,j=p.sub(L);return p.add(j._mult(C/j.mag()))}function it(O,u){const{projectionCache:p,lineVertexArray:C,labelPlaneMatrix:M,tileAnchorPoint:I,distanceFromAnchor:L,getElevation:j,previousVertex:G,direction:te,absOffsetX:Ae}=u;if(p.projections[O])return p.projections[O];const he=new a.P(C.getx(O),C.gety(O)),Me=Gn(he,M,j);if(Me.signedDistanceFromCamera>0)return p.projections[O]=Me.point,Me.point;const De=O-te;return at(L===0?I:new a.P(C.getx(De),C.gety(De)),he,G,Ae-L+1,M,j)}function ht(O,u,p){return O._unit()._perp()._mult(u*p)}function et(O,u,p,C,M,I,L,j){const{projectionCache:G,direction:te}=j;if(G.offsets[O])return G.offsets[O];const Ae=p.add(u);if(O+te<C||O+te>=M)return G.offsets[O]=Ae,Ae;const he=it(O+te,j),Me=ht(he.sub(p),L,te),De=p.add(Me),je=he.add(Me);return G.offsets[O]=a.ak(I,Ae,De,je)||Ae,G.offsets[O]}function Ct(O,u,p,C,M,I,L,j,G,te,Ae,he,Me,De){const je=C?O-u:O+u;let Qe=je>0?1:-1,Le=0;C&&(Qe*=-1,Le=Math.PI),Qe<0&&(Le+=Math.PI);let ft,Bt,qe=Qe>0?j+L:j+L+1,_t=M,Ut=M,Tt=0,en=0;const hn=Math.abs(je),An=[];let On;for(;Tt+en<=hn;){if(qe+=Qe,qe<j||qe>=G)return null;Tt+=en,Ut=_t,Bt=ft;const Tn={projectionCache:he,lineVertexArray:te,labelPlaneMatrix:Ae,tileAnchorPoint:I,distanceFromAnchor:Tt,getElevation:De,previousVertex:Ut,direction:Qe,absOffsetX:hn};if(_t=it(qe,Tn),p===0)An.push(Ut),On=_t.sub(Ut);else{let yr;const Qn=_t.sub(Ut);yr=Qn.mag()===0?ht(it(qe+Qe,Tn).sub(_t),p,Qe):ht(Qn,p,Qe),Bt||(Bt=Ut.add(yr)),ft=et(qe,yr,_t,j,G,Bt,p,Tn),An.push(Bt),On=ft.sub(Bt)}en=On.mag()}const lr=On._mult((hn-Tt)/en)._add(Bt||Ut),xr=Le+Math.atan2(_t.y-Ut.y,_t.x-Ut.x);return An.push(lr),{point:lr,angle:Me?xr:0,path:An}}const rn=new Float32Array([-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0]);function Gt(O,u){for(let p=0;p<O;p++){const C=u.length;u.resize(C+4),u.float32.set(rn,3*C)}}function $t(O,u,p){const C=u[0],M=u[1];return O[0]=p[0]*C+p[4]*M+p[12],O[1]=p[1]*C+p[5]*M+p[13],O[3]=p[3]*C+p[7]*M+p[15],O}const gn=100;class Jn{constructor(u,p=new m(u.width+200,u.height+200,25),C=new m(u.width+200,u.height+200,25)){this.transform=u,this.grid=p,this.ignoredGrid=C,this.pitchfactor=Math.cos(u._pitch)*u.cameraToCenterDistance,this.screenRightBoundary=u.width+gn,this.screenBottomBoundary=u.height+gn,this.gridRightBoundary=u.width+200,this.gridBottomBoundary=u.height+200,this.perspectiveRatioCutoff=.6}placeCollisionBox(u,p,C,M,I,L){const j=this.projectAndGetPerspectiveRatio(M,u.anchorPointX,u.anchorPointY,L),G=C*j.perspectiveRatio,te=u.x1*G+j.point.x,Ae=u.y1*G+j.point.y,he=u.x2*G+j.point.x,Me=u.y2*G+j.point.y;return!this.isInsideGrid(te,Ae,he,Me)||p!=="always"&&this.grid.hitTest(te,Ae,he,Me,p,I)||j.perspectiveRatio<this.perspectiveRatioCutoff?{box:[],offscreen:!1}:{box:[te,Ae,he,Me],offscreen:this.isOffscreen(te,Ae,he,Me)}}placeCollisionCircles(u,p,C,M,I,L,j,G,te,Ae,he,Me,De,je){const Qe=[],Le=new a.P(p.anchorX,p.anchorY),ft=Gn(Le,L,je),Bt=Zn(this.transform.cameraToCenterDistance,ft.signedDistanceFromCamera),qe=(Ae?I/Bt:I*Bt)/a.ao,_t=Gn(Le,j,je).point,Ut=_e(qe,M,p.lineOffsetX*qe,p.lineOffsetY*qe,!1,_t,Le,p,C,j,{projections:{},offsets:{}},!1,je);let Tt=!1,en=!1,hn=!0;if(Ut){const An=.5*Me*Bt+De,On=new a.P(-100,-100),lr=new a.P(this.screenRightBoundary,this.screenBottomBoundary),xr=new Fn,Tn=Ut.first,yr=Ut.last;let Qn=[];for(let ii=Tn.path.length-1;ii>=1;ii--)Qn.push(Tn.path[ii]);for(let ii=1;ii<yr.path.length;ii++)Qn.push(yr.path[ii]);const Ho=2.5*An;if(G){const ii=Qn.map(si=>Gn(si,G,je));Qn=ii.some(si=>si.signedDistanceFromCamera<=0)?[]:ii.map(si=>si.point)}let pi=[];if(Qn.length>0){const ii=Qn[0].clone(),si=Qn[0].clone();for(let yo=1;yo<Qn.length;yo++)ii.x=Math.min(ii.x,Qn[yo].x),ii.y=Math.min(ii.y,Qn[yo].y),si.x=Math.max(si.x,Qn[yo].x),si.y=Math.max(si.y,Qn[yo].y);pi=ii.x>=On.x&&si.x<=lr.x&&ii.y>=On.y&&si.y<=lr.y?[Qn]:si.x<On.x||ii.x>lr.x||si.y<On.y||ii.y>lr.y?[]:a.al([Qn],On.x,On.y,lr.x,lr.y)}for(const ii of pi){xr.reset(ii,.25*An);let si=0;si=xr.length<=.5*An?1:Math.ceil(xr.paddedLength/Ho)+1;for(let yo=0;yo<si;yo++){const vo=yo/Math.max(si-1,1),Zs=xr.lerp(vo),Sa=Zs.x+gn,aa=Zs.y+gn;Qe.push(Sa,aa,An,0);const _a=Sa-An,no=aa-An,ws=Sa+An,Pu=aa+An;if(hn=hn&&this.isOffscreen(_a,no,ws,Pu),en=en||this.isInsideGrid(_a,no,ws,Pu),u!=="always"&&this.grid.hitTestCircle(Sa,aa,An,u,he)&&(Tt=!0,!te))return{circles:[],offscreen:!1,collisionDetected:Tt}}}}return{circles:!te&&Tt||!en||Bt<this.perspectiveRatioCutoff?[]:Qe,offscreen:hn,collisionDetected:Tt}}queryRenderedSymbols(u){if(u.length===0||this.grid.keysLength()===0&&this.ignoredGrid.keysLength()===0)return{};const p=[];let C=1/0,M=1/0,I=-1/0,L=-1/0;for(const Ae of u){const he=new a.P(Ae.x+gn,Ae.y+gn);C=Math.min(C,he.x),M=Math.min(M,he.y),I=Math.max(I,he.x),L=Math.max(L,he.y),p.push(he)}const j=this.grid.query(C,M,I,L).concat(this.ignoredGrid.query(C,M,I,L)),G={},te={};for(const Ae of j){const he=Ae.key;if(G[he.bucketInstanceId]===void 0&&(G[he.bucketInstanceId]={}),G[he.bucketInstanceId][he.featureIndex])continue;const Me=[new a.P(Ae.x1,Ae.y1),new a.P(Ae.x2,Ae.y1),new a.P(Ae.x2,Ae.y2),new a.P(Ae.x1,Ae.y2)];a.am(p,Me)&&(G[he.bucketInstanceId][he.featureIndex]=!0,te[he.bucketInstanceId]===void 0&&(te[he.bucketInstanceId]=[]),te[he.bucketInstanceId].push(he.featureIndex))}return te}insertCollisionBox(u,p,C,M,I,L){(C?this.ignoredGrid:this.grid).insert({bucketInstanceId:M,featureIndex:I,collisionGroupID:L,overlapMode:p},u[0],u[1],u[2],u[3])}insertCollisionCircles(u,p,C,M,I,L){const j=C?this.ignoredGrid:this.grid,G={bucketInstanceId:M,featureIndex:I,collisionGroupID:L,overlapMode:p};for(let te=0;te<u.length;te+=4)j.insertCircle(G,u[te],u[te+1],u[te+2])}projectAndGetPerspectiveRatio(u,p,C,M){let I;return M?(I=[p,C,M(p,C),1],a.af(I,I,u)):(I=[p,C,0,1],$t(I,I,u)),{point:new a.P((I[0]/I[3]+1)/2*this.transform.width+gn,(-I[1]/I[3]+1)/2*this.transform.height+gn),perspectiveRatio:.5+this.transform.cameraToCenterDistance/I[3]*.5}}isOffscreen(u,p,C,M){return C<gn||u>=this.screenRightBoundary||M<gn||p>this.screenBottomBoundary}isInsideGrid(u,p,C,M){return C>=0&&u<this.gridRightBoundary&&M>=0&&p<this.gridBottomBoundary}getViewportMatrix(){const u=a.an([]);return a.H(u,u,[-100,-100,0]),u}}function qn(O,u,p){return u*(a.W/(O.tileSize*Math.pow(2,p-O.tileID.overscaledZ)))}class Tr{constructor(u,p,C,M){this.opacity=u?Math.max(0,Math.min(1,u.opacity+(u.placed?p:-p))):M&&C?1:0,this.placed=C}isHidden(){return this.opacity===0&&!this.placed}}class vr{constructor(u,p,C,M,I){this.text=new Tr(u?u.text:null,p,C,I),this.icon=new Tr(u?u.icon:null,p,M,I)}isHidden(){return this.text.isHidden()&&this.icon.isHidden()}}class Dr{constructor(u,p,C){this.text=u,this.icon=p,this.skipFade=C}}class Yr{constructor(){this.invProjMatrix=a.F(),this.viewportMatrix=a.F(),this.circles=[]}}class Zr{constructor(u,p,C,M,I){this.bucketInstanceId=u,this.featureIndex=p,this.sourceLayerIndex=C,this.bucketIndex=M,this.tileID=I}}class Cr{constructor(u){this.crossSourceCollisions=u,this.maxGroupID=0,this.collisionGroups={}}get(u){if(this.crossSourceCollisions)return{ID:0,predicate:null};if(!this.collisionGroups[u]){const p=++this.maxGroupID;this.collisionGroups[u]={ID:p,predicate:C=>C.collisionGroupID===p}}return this.collisionGroups[u]}}function ui(O,u,p,C,M){const{horizontalAlign:I,verticalAlign:L}=a.at(O);return new a.P(-(I-.5)*u+C[0]*M,-(L-.5)*p+C[1]*M)}function Ii(O,u,p,C,M,I){const{x1:L,x2:j,y1:G,y2:te,anchorPointX:Ae,anchorPointY:he}=O,Me=new a.P(u,p);return C&&Me._rotate(M?I:-I),{x1:L+Me.x,y1:G+Me.y,x2:j+Me.x,y2:te+Me.y,anchorPointX:Ae,anchorPointY:he}}class Io{constructor(u,p,C,M,I){this.transform=u.clone(),this.terrain=p,this.collisionIndex=new Jn(this.transform),this.placements={},this.opacities={},this.variableOffsets={},this.stale=!1,this.commitTime=0,this.fadeDuration=C,this.retainedQueryData={},this.collisionGroups=new Cr(M),this.collisionCircleArrays={},this.prevPlacement=I,I&&(I.prevPlacement=void 0),this.placedOrientations={}}getBucketParts(u,p,C,M){const I=C.getBucket(p),L=C.latestFeatureIndex;if(!I||!L||p.id!==I.layerIds[0])return;const j=C.collisionBoxArray,G=I.layers[0].layout,te=Math.pow(2,this.transform.zoom-C.tileID.overscaledZ),Ae=C.tileSize/a.W,he=this.transform.calculatePosMatrix(C.tileID.toUnwrapped()),Me=G.get("text-pitch-alignment")==="map",De=G.get("text-rotation-alignment")==="map",je=qn(C,1,this.transform.zoom),Qe=un(he,Me,De,this.transform,je);let Le=null;if(Me){const Bt=In(he,Me,De,this.transform,je);Le=a.K([],this.transform.labelPlaneMatrix,Bt)}this.retainedQueryData[I.bucketInstanceId]=new Zr(I.bucketInstanceId,L,I.sourceLayerIndex,I.index,C.tileID);const ft={bucket:I,layout:G,posMatrix:he,textLabelPlaneMatrix:Qe,labelToScreenMatrix:Le,scale:te,textPixelRatio:Ae,holdingForFade:C.holdingForFade(),collisionBoxArray:j,partiallyEvaluatedTextSize:a.ag(I.textSizeData,this.transform.zoom),collisionGroup:this.collisionGroups.get(I.sourceID)};if(M)for(const Bt of I.sortKeyRanges){const{sortKey:qe,symbolInstanceStart:_t,symbolInstanceEnd:Ut}=Bt;u.push({sortKey:qe,symbolInstanceStart:_t,symbolInstanceEnd:Ut,parameters:ft})}else u.push({symbolInstanceStart:0,symbolInstanceEnd:I.symbolInstances.length,parameters:ft})}attemptAnchorPlacement(u,p,C,M,I,L,j,G,te,Ae,he,Me,De,je,Qe,Le){const ft=a.ap[u.textAnchor],Bt=[u.textOffset0,u.textOffset1],qe=ui(ft,C,M,Bt,I),_t=this.collisionIndex.placeCollisionBox(Ii(p,qe.x,qe.y,L,j,this.transform.angle),he,G,te,Ae.predicate,Le);if((!Qe||this.collisionIndex.placeCollisionBox(Ii(Qe,qe.x,qe.y,L,j,this.transform.angle),he,G,te,Ae.predicate,Le).box.length!==0)&&_t.box.length>0){let Ut;if(this.prevPlacement&&this.prevPlacement.variableOffsets[Me.crossTileID]&&this.prevPlacement.placements[Me.crossTileID]&&this.prevPlacement.placements[Me.crossTileID].text&&(Ut=this.prevPlacement.variableOffsets[Me.crossTileID].anchor),Me.crossTileID===0)throw new Error("symbolInstance.crossTileID can't be 0");return this.variableOffsets[Me.crossTileID]={textOffset:Bt,width:C,height:M,anchor:ft,textBoxScale:I,prevAnchor:Ut},this.markUsedJustification(De,ft,Me,je),De.allowVerticalPlacement&&(this.markUsedOrientation(De,je,Me),this.placedOrientations[Me.crossTileID]=je),{shift:qe,placedGlyphBoxes:_t}}}placeLayerBucketPart(u,p,C){const{bucket:M,layout:I,posMatrix:L,textLabelPlaneMatrix:j,labelToScreenMatrix:G,textPixelRatio:te,holdingForFade:Ae,collisionBoxArray:he,partiallyEvaluatedTextSize:Me,collisionGroup:De}=u.parameters,je=I.get("text-optional"),Qe=I.get("icon-optional"),Le=a.aq(I,"text-overlap","text-allow-overlap"),ft=Le==="always",Bt=a.aq(I,"icon-overlap","icon-allow-overlap"),qe=Bt==="always",_t=I.get("text-rotation-alignment")==="map",Ut=I.get("text-pitch-alignment")==="map",Tt=I.get("icon-text-fit")!=="none",en=I.get("symbol-z-order")==="viewport-y",hn=ft&&(qe||!M.hasIconData()||Qe),An=qe&&(ft||!M.hasTextData()||je);!M.collisionArrays&&he&&M.deserializeCollisionBoxes(he);const On=this.retainedQueryData[M.bucketInstanceId].tileID,lr=this.terrain?(Tn,yr)=>this.terrain.getElevation(On,Tn,yr):null,xr=(Tn,yr)=>{var Qn,Ho;if(p[Tn.crossTileID])return;if(Ae)return void(this.placements[Tn.crossTileID]=new Dr(!1,!1,!1));let pi=!1,ii=!1,si=!0,yo=null,vo={box:null,offscreen:null},Zs={box:null,offscreen:null},Sa=null,aa=null,_a=null,no=0,ws=0,Pu=0;yr.textFeatureIndex?no=yr.textFeatureIndex:Tn.useRuntimeCollisionCircles&&(no=Tn.featureIndex),yr.verticalTextFeatureIndex&&(ws=yr.verticalTextFeatureIndex);const Ms=yr.textBox;if(Ms){const Zo=jo=>{let Da=a.ah.horizontal;if(M.allowVerticalPlacement&&!jo&&this.prevPlacement){const ua=this.prevPlacement.placedOrientations[Tn.crossTileID];ua&&(this.placedOrientations[Tn.crossTileID]=ua,Da=ua,this.markUsedOrientation(M,Da,Tn))}return Da},ji=(jo,Da)=>{if(M.allowVerticalPlacement&&Tn.numVerticalGlyphVertices>0&&yr.verticalTextBox){for(const ua of M.writingModes)if(ua===a.ah.vertical?(vo=Da(),Zs=vo):vo=jo(),vo&&vo.box&&vo.box.length)break}else vo=jo()},Oi=Tn.textAnchorOffsetStartIndex,cs=Tn.textAnchorOffsetEndIndex;if(cs===Oi){const jo=(Da,ua)=>{const sa=this.collisionIndex.placeCollisionBox(Da,Le,te,L,De.predicate,lr);return sa&&sa.box&&sa.box.length&&(this.markUsedOrientation(M,ua,Tn),this.placedOrientations[Tn.crossTileID]=ua),sa};ji(()=>jo(Ms,a.ah.horizontal),()=>{const Da=yr.verticalTextBox;return M.allowVerticalPlacement&&Tn.numVerticalGlyphVertices>0&&Da?jo(Da,a.ah.vertical):{box:null,offscreen:null}}),Zo(vo&&vo.box&&vo.box.length)}else{let jo=a.ap[(Ho=(Qn=this.prevPlacement)===null||Qn===void 0?void 0:Qn.variableOffsets[Tn.crossTileID])===null||Ho===void 0?void 0:Ho.anchor];const Da=(sa,If,Wo)=>{const jd=sa.x2-sa.x1,fc=sa.y2-sa.y1,EA=Tn.textBoxScale,hl=Tt&&Bt==="never"?If:null;let Fu={box:[],offscreen:!1},OA=Le==="never"?1:2,Wd="never";jo&&OA++;for(let BA=0;BA<OA;BA++){for(let Nd=Oi;Nd<cs;Nd++){const Tf=M.textAnchorOffsets.get(Nd);if(jo&&Tf.textAnchor!==jo)continue;const td=this.attemptAnchorPlacement(Tf,sa,jd,fc,EA,_t,Ut,te,L,De,Wd,Tn,M,Wo,hl,lr);if(td&&(Fu=td.placedGlyphBoxes,Fu&&Fu.box&&Fu.box.length))return pi=!0,yo=td.shift,Fu}jo?jo=null:Wd=Le}return Fu};ji(()=>Da(Ms,yr.iconBox,a.ah.horizontal),()=>{const sa=yr.verticalTextBox;return M.allowVerticalPlacement&&!(vo&&vo.box&&vo.box.length)&&Tn.numVerticalGlyphVertices>0&&sa?Da(sa,yr.verticalIconBox,a.ah.vertical):{box:null,offscreen:null}}),vo&&(pi=vo.box,si=vo.offscreen);const ua=Zo(vo&&vo.box);if(!pi&&this.prevPlacement){const sa=this.prevPlacement.variableOffsets[Tn.crossTileID];sa&&(this.variableOffsets[Tn.crossTileID]=sa,this.markUsedJustification(M,sa.anchor,Tn,ua))}}}if(Sa=vo,pi=Sa&&Sa.box&&Sa.box.length>0,si=Sa&&Sa.offscreen,Tn.useRuntimeCollisionCircles){const Zo=M.text.placedSymbolArray.get(Tn.centerJustifiedTextSymbolIndex),ji=a.ai(M.textSizeData,Me,Zo),Oi=I.get("text-padding");aa=this.collisionIndex.placeCollisionCircles(Le,Zo,M.lineVertexArray,M.glyphOffsetArray,ji,L,j,G,C,Ut,De.predicate,Tn.collisionCircleDiameter,Oi,lr),aa.circles.length&&aa.collisionDetected&&!C&&a.w("Collisions detected, but collision boxes are not shown"),pi=ft||aa.circles.length>0&&!aa.collisionDetected,si=si&&aa.offscreen}if(yr.iconFeatureIndex&&(Pu=yr.iconFeatureIndex),yr.iconBox){const Zo=ji=>{const Oi=Tt&&yo?Ii(ji,yo.x,yo.y,_t,Ut,this.transform.angle):ji;return this.collisionIndex.placeCollisionBox(Oi,Bt,te,L,De.predicate,lr)};Zs&&Zs.box&&Zs.box.length&&yr.verticalIconBox?(_a=Zo(yr.verticalIconBox),ii=_a.box.length>0):(_a=Zo(yr.iconBox),ii=_a.box.length>0),si=si&&_a.offscreen}const aA=je||Tn.numHorizontalGlyphVertices===0&&Tn.numVerticalGlyphVertices===0,hu=Qe||Tn.numIconVertices===0;if(aA||hu?hu?aA||(ii=ii&&pi):pi=ii&&pi:ii=pi=ii&&pi,pi&&Sa&&Sa.box&&this.collisionIndex.insertCollisionBox(Sa.box,Le,I.get("text-ignore-placement"),M.bucketInstanceId,Zs&&Zs.box&&ws?ws:no,De.ID),ii&&_a&&this.collisionIndex.insertCollisionBox(_a.box,Bt,I.get("icon-ignore-placement"),M.bucketInstanceId,Pu,De.ID),aa&&(pi&&this.collisionIndex.insertCollisionCircles(aa.circles,Le,I.get("text-ignore-placement"),M.bucketInstanceId,no,De.ID),C)){const Zo=M.bucketInstanceId;let ji=this.collisionCircleArrays[Zo];ji===void 0&&(ji=this.collisionCircleArrays[Zo]=new Yr);for(let Oi=0;Oi<aa.circles.length;Oi+=4)ji.circles.push(aa.circles[Oi+0]),ji.circles.push(aa.circles[Oi+1]),ji.circles.push(aa.circles[Oi+2]),ji.circles.push(aa.collisionDetected?1:0)}if(Tn.crossTileID===0)throw new Error("symbolInstance.crossTileID can't be 0");if(M.bucketInstanceId===0)throw new Error("bucket.bucketInstanceId can't be 0");this.placements[Tn.crossTileID]=new Dr(pi||hn,ii||An,si||M.justReloaded),p[Tn.crossTileID]=!0};if(en){if(u.symbolInstanceStart!==0)throw new Error("bucket.bucketInstanceId should be 0");const Tn=M.getSortedSymbolIndexes(this.transform.angle);for(let yr=Tn.length-1;yr>=0;--yr){const Qn=Tn[yr];xr(M.symbolInstances.get(Qn),M.collisionArrays[Qn])}}else for(let Tn=u.symbolInstanceStart;Tn<u.symbolInstanceEnd;Tn++)xr(M.symbolInstances.get(Tn),M.collisionArrays[Tn]);if(C&&M.bucketInstanceId in this.collisionCircleArrays){const Tn=this.collisionCircleArrays[M.bucketInstanceId];a.ar(Tn.invProjMatrix,L),Tn.viewportMatrix=this.collisionIndex.getViewportMatrix()}M.justReloaded=!1}markUsedJustification(u,p,C,M){let I;I=M===a.ah.vertical?C.verticalPlacedTextSymbolIndex:{left:C.leftJustifiedTextSymbolIndex,center:C.centerJustifiedTextSymbolIndex,right:C.rightJustifiedTextSymbolIndex}[a.as(p)];const L=[C.leftJustifiedTextSymbolIndex,C.centerJustifiedTextSymbolIndex,C.rightJustifiedTextSymbolIndex,C.verticalPlacedTextSymbolIndex];for(const j of L)j>=0&&(u.text.placedSymbolArray.get(j).crossTileID=I>=0&&j!==I?0:C.crossTileID)}markUsedOrientation(u,p,C){const M=p===a.ah.horizontal||p===a.ah.horizontalOnly?p:0,I=p===a.ah.vertical?p:0,L=[C.leftJustifiedTextSymbolIndex,C.centerJustifiedTextSymbolIndex,C.rightJustifiedTextSymbolIndex];for(const j of L)u.text.placedSymbolArray.get(j).placedOrientation=M;C.verticalPlacedTextSymbolIndex&&(u.text.placedSymbolArray.get(C.verticalPlacedTextSymbolIndex).placedOrientation=I)}commit(u){this.commitTime=u,this.zoomAtLastRecencyCheck=this.transform.zoom;const p=this.prevPlacement;let C=!1;this.prevZoomAdjustment=p?p.zoomAdjustment(this.transform.zoom):0;const M=p?p.symbolFadeChange(u):1,I=p?p.opacities:{},L=p?p.variableOffsets:{},j=p?p.placedOrientations:{};for(const G in this.placements){const te=this.placements[G],Ae=I[G];Ae?(this.opacities[G]=new vr(Ae,M,te.text,te.icon),C=C||te.text!==Ae.text.placed||te.icon!==Ae.icon.placed):(this.opacities[G]=new vr(null,M,te.text,te.icon,te.skipFade),C=C||te.text||te.icon)}for(const G in I){const te=I[G];if(!this.opacities[G]){const Ae=new vr(te,M,!1,!1);Ae.isHidden()||(this.opacities[G]=Ae,C=C||te.text.placed||te.icon.placed)}}for(const G in L)this.variableOffsets[G]||!this.opacities[G]||this.opacities[G].isHidden()||(this.variableOffsets[G]=L[G]);for(const G in j)this.placedOrientations[G]||!this.opacities[G]||this.opacities[G].isHidden()||(this.placedOrientations[G]=j[G]);if(p&&p.lastPlacementChangeTime===void 0)throw new Error("Last placement time for previous placement is not defined");C?this.lastPlacementChangeTime=u:typeof this.lastPlacementChangeTime!="number"&&(this.lastPlacementChangeTime=p?p.lastPlacementChangeTime:u)}updateLayerOpacities(u,p){const C={};for(const M of p){const I=M.getBucket(u);I&&M.latestFeatureIndex&&u.id===I.layerIds[0]&&this.updateBucketOpacities(I,C,M.collisionBoxArray)}}updateBucketOpacities(u,p,C){u.hasTextData()&&(u.text.opacityVertexArray.clear(),u.text.hasVisibleVertices=!1),u.hasIconData()&&(u.icon.opacityVertexArray.clear(),u.icon.hasVisibleVertices=!1),u.hasIconCollisionBoxData()&&u.iconCollisionBox.collisionVertexArray.clear(),u.hasTextCollisionBoxData()&&u.textCollisionBox.collisionVertexArray.clear();const M=u.layers[0],I=M.layout,L=new vr(null,0,!1,!1,!0),j=I.get("text-allow-overlap"),G=I.get("icon-allow-overlap"),te=M._unevaluatedLayout.hasValue("text-variable-anchor")||M._unevaluatedLayout.hasValue("text-variable-anchor-offset"),Ae=I.get("text-rotation-alignment")==="map",he=I.get("text-pitch-alignment")==="map",Me=I.get("icon-text-fit")!=="none",De=new vr(null,0,j&&(G||!u.hasIconData()||I.get("icon-optional")),G&&(j||!u.hasTextData()||I.get("text-optional")),!0);!u.collisionArrays&&C&&(u.hasIconCollisionBoxData()||u.hasTextCollisionBoxData())&&u.deserializeCollisionBoxes(C);const je=(Qe,Le,ft)=>{for(let Bt=0;Bt<Le/4;Bt++)Qe.opacityVertexArray.emplaceBack(ft);Qe.hasVisibleVertices=Qe.hasVisibleVertices||ft!==Gi};for(let Qe=0;Qe<u.symbolInstances.length;Qe++){const Le=u.symbolInstances.get(Qe),{numHorizontalGlyphVertices:ft,numVerticalGlyphVertices:Bt,crossTileID:qe}=Le;let _t=this.opacities[qe];p[qe]?_t=L:_t||(_t=De,this.opacities[qe]=_t),p[qe]=!0;const Ut=Le.numIconVertices>0,Tt=this.placedOrientations[Le.crossTileID],en=Tt===a.ah.vertical,hn=Tt===a.ah.horizontal||Tt===a.ah.horizontalOnly;if(ft>0||Bt>0){const An=lo(_t.text);je(u.text,ft,en?Gi:An),je(u.text,Bt,hn?Gi:An);const On=_t.text.isHidden();[Le.rightJustifiedTextSymbolIndex,Le.centerJustifiedTextSymbolIndex,Le.leftJustifiedTextSymbolIndex].forEach(Tn=>{Tn>=0&&(u.text.placedSymbolArray.get(Tn).hidden=On||en?1:0)}),Le.verticalPlacedTextSymbolIndex>=0&&(u.text.placedSymbolArray.get(Le.verticalPlacedTextSymbolIndex).hidden=On||hn?1:0);const lr=this.variableOffsets[Le.crossTileID];lr&&this.markUsedJustification(u,lr.anchor,Le,Tt);const xr=this.placedOrientations[Le.crossTileID];xr&&(this.markUsedJustification(u,"left",Le,xr),this.markUsedOrientation(u,xr,Le))}if(Ut){const An=lo(_t.icon),On=!(Me&&Le.verticalPlacedIconSymbolIndex&&en);Le.placedIconSymbolIndex>=0&&(je(u.icon,Le.numIconVertices,On?An:Gi),u.icon.placedSymbolArray.get(Le.placedIconSymbolIndex).hidden=_t.icon.isHidden()),Le.verticalPlacedIconSymbolIndex>=0&&(je(u.icon,Le.numVerticalIconVertices,On?Gi:An),u.icon.placedSymbolArray.get(Le.verticalPlacedIconSymbolIndex).hidden=_t.icon.isHidden())}if(u.hasIconCollisionBoxData()||u.hasTextCollisionBoxData()){const An=u.collisionArrays[Qe];if(An){let On=new a.P(0,0);if(An.textBox||An.verticalTextBox){let xr=!0;if(te){const Tn=this.variableOffsets[qe];Tn?(On=ui(Tn.anchor,Tn.width,Tn.height,Tn.textOffset,Tn.textBoxScale),Ae&&On._rotate(he?this.transform.angle:-this.transform.angle)):xr=!1}An.textBox&&Ci(u.textCollisionBox.collisionVertexArray,_t.text.placed,!xr||en,On.x,On.y),An.verticalTextBox&&Ci(u.textCollisionBox.collisionVertexArray,_t.text.placed,!xr||hn,On.x,On.y)}const lr=!!(!hn&&An.verticalIconBox);An.iconBox&&Ci(u.iconCollisionBox.collisionVertexArray,_t.icon.placed,lr,Me?On.x:0,Me?On.y:0),An.verticalIconBox&&Ci(u.iconCollisionBox.collisionVertexArray,_t.icon.placed,!lr,Me?On.x:0,Me?On.y:0)}}}if(u.sortFeatures(this.transform.angle),this.retainedQueryData[u.bucketInstanceId]&&(this.retainedQueryData[u.bucketInstanceId].featureSortOrder=u.featureSortOrder),u.hasTextData()&&u.text.opacityVertexBuffer&&u.text.opacityVertexBuffer.updateData(u.text.opacityVertexArray),u.hasIconData()&&u.icon.opacityVertexBuffer&&u.icon.opacityVertexBuffer.updateData(u.icon.opacityVertexArray),u.hasIconCollisionBoxData()&&u.iconCollisionBox.collisionVertexBuffer&&u.iconCollisionBox.collisionVertexBuffer.updateData(u.iconCollisionBox.collisionVertexArray),u.hasTextCollisionBoxData()&&u.textCollisionBox.collisionVertexBuffer&&u.textCollisionBox.collisionVertexBuffer.updateData(u.textCollisionBox.collisionVertexArray),u.text.opacityVertexArray.length!==u.text.layoutVertexArray.length/4)throw new Error(`bucket.text.opacityVertexArray.length (= ${u.text.opacityVertexArray.length}) !== bucket.text.layoutVertexArray.length (= ${u.text.layoutVertexArray.length}) / 4`);if(u.icon.opacityVertexArray.length!==u.icon.layoutVertexArray.length/4)throw new Error(`bucket.icon.opacityVertexArray.length (= ${u.icon.opacityVertexArray.length}) !== bucket.icon.layoutVertexArray.length (= ${u.icon.layoutVertexArray.length}) / 4`);if(u.bucketInstanceId in this.collisionCircleArrays){const Qe=this.collisionCircleArrays[u.bucketInstanceId];u.placementInvProjMatrix=Qe.invProjMatrix,u.placementViewportMatrix=Qe.viewportMatrix,u.collisionCircleArray=Qe.circles,delete this.collisionCircleArrays[u.bucketInstanceId]}}symbolFadeChange(u){return this.fadeDuration===0?1:(u-this.commitTime)/this.fadeDuration+this.prevZoomAdjustment}zoomAdjustment(u){return Math.max(0,(this.transform.zoom-u)/1.5)}hasTransitions(u){return this.stale||u-this.lastPlacementChangeTime<this.fadeDuration}stillRecent(u,p){const C=this.zoomAtLastRecencyCheck===p?1-this.zoomAdjustment(p):1;return this.zoomAtLastRecencyCheck=p,this.commitTime+this.fadeDuration*C>u}setStale(){this.stale=!0}}function Ci(O,u,p,C,M){O.emplaceBack(u?1:0,p?1:0,C||0,M||0),O.emplaceBack(u?1:0,p?1:0,C||0,M||0),O.emplaceBack(u?1:0,p?1:0,C||0,M||0),O.emplaceBack(u?1:0,p?1:0,C||0,M||0)}const so=Math.pow(2,25),Yo=Math.pow(2,24),ba=Math.pow(2,17),Ql=Math.pow(2,16),Ai=Math.pow(2,9),Mi=Math.pow(2,8),rr=Math.pow(2,1);function lo(O){if(O.opacity===0&&!O.placed)return 0;if(O.opacity===1&&O.placed)return 4294967295;const u=O.placed?1:0,p=Math.floor(127*O.opacity);return p*so+u*Yo+p*ba+u*Ql+p*Ai+u*Mi+p*rr+u}const Gi=0;class la{constructor(u){this._sortAcrossTiles=u.layout.get("symbol-z-order")!=="viewport-y"&&!u.layout.get("symbol-sort-key").isConstant(),this._currentTileIndex=0,this._currentPartIndex=0,this._seenCrossTileIDs={},this._bucketParts=[]}continuePlacement(u,p,C,M,I){const L=this._bucketParts;for(;this._currentTileIndex<u.length;)if(p.getBucketParts(L,M,u[this._currentTileIndex],this._sortAcrossTiles),this._currentTileIndex++,I())return!0;for(this._sortAcrossTiles&&(this._sortAcrossTiles=!1,L.sort((j,G)=>j.sortKey-G.sortKey));this._currentPartIndex<L.length;)if(p.placeLayerBucketPart(L[this._currentPartIndex],this._seenCrossTileIDs,C),this._currentPartIndex++,I())return!0;return!1}}class ve{constructor(u,p,C,M,I,L,j,G){this.placement=new Io(u,p,L,j,G),this._currentPlacementIndex=C.length-1,this._forceFullPlacement=M,this._showCollisionBoxes=I,this._done=!1}isDone(){return this._done}continuePlacement(u,p,C){const M=k.now(),I=()=>!this._forceFullPlacement&&k.now()-M>2;for(;this._currentPlacementIndex>=0;){const L=p[u[this._currentPlacementIndex]],j=this.placement.collisionIndex.transform.zoom;if(L.type==="symbol"&&(!L.minzoom||L.minzoom<=j)&&(!L.maxzoom||L.maxzoom>j)){if(this._inProgressLayer||(this._inProgressLayer=new la(L)),this._inProgressLayer.continuePlacement(C[L.source],this.placement,this._showCollisionBoxes,L,I))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0}commit(u){return this.placement.commit(u),this.placement}}const Ge=512/a.W/2;class Ht{constructor(u,p,C){this.tileID=u,this.bucketInstanceId=C,this._symbolsByKey={};const M=new Map;for(let I=0;I<p.length;I++){const L=p.get(I),j=L.key,G=M.get(j);G?G.push(L):M.set(j,[L])}for(const[I,L]of M){const j={positions:L.map(G=>({x:Math.floor(G.anchorX*Ge),y:Math.floor(G.anchorY*Ge)})),crossTileIDs:L.map(G=>G.crossTileID)};if(j.positions.length>128){const G=new a.au(j.positions.length,16,Uint16Array);for(const{x:te,y:Ae}of j.positions)G.add(te,Ae);G.finish(),delete j.positions,j.index=G}this._symbolsByKey[I]=j}}getScaledCoordinates(u,p){const{x:C,y:M,z:I}=this.tileID.canonical,{x:L,y:j,z:G}=p.canonical,te=Ge/Math.pow(2,G-I),Ae=(j*a.W+u.anchorY)*te,he=M*a.W*Ge;return{x:Math.floor((L*a.W+u.anchorX)*te-C*a.W*Ge),y:Math.floor(Ae-he)}}findMatches(u,p,C){const M=this.tileID.canonical.z<p.canonical.z?1:Math.pow(2,this.tileID.canonical.z-p.canonical.z);for(let I=0;I<u.length;I++){const L=u.get(I);if(L.crossTileID)continue;const j=this._symbolsByKey[L.key];if(!j)continue;const G=this.getScaledCoordinates(L,p);if(j.index){const te=j.index.range(G.x-M,G.y-M,G.x+M,G.y+M).sort();for(const Ae of te){const he=j.crossTileIDs[Ae];if(!C[he]){C[he]=!0,L.crossTileID=he;break}}}else if(j.positions)for(let te=0;te<j.positions.length;te++){const Ae=j.positions[te],he=j.crossTileIDs[te];if(Math.abs(Ae.x-G.x)<=M&&Math.abs(Ae.y-G.y)<=M&&!C[he]){C[he]=!0,L.crossTileID=he;break}}}}getCrossTileIDsLists(){return Object.values(this._symbolsByKey).map(({crossTileIDs:u})=>u)}}class mn{constructor(){this.maxCrossTileID=0}generate(){return++this.maxCrossTileID}}class Ot{constructor(){this.indexes={},this.usedCrossTileIDs={},this.lng=0}handleWrapJump(u){const p=Math.round((u-this.lng)/360);if(p!==0)for(const C in this.indexes){const M=this.indexes[C],I={};for(const L in M){const j=M[L];j.tileID=j.tileID.unwrapTo(j.tileID.wrap+p),I[j.tileID.key]=j}this.indexes[C]=I}this.lng=u}addBucket(u,p,C){if(this.indexes[u.overscaledZ]&&this.indexes[u.overscaledZ][u.key]){if(this.indexes[u.overscaledZ][u.key].bucketInstanceId===p.bucketInstanceId)return!1;this.removeBucketCrossTileIDs(u.overscaledZ,this.indexes[u.overscaledZ][u.key])}for(let I=0;I<p.symbolInstances.length;I++)p.symbolInstances.get(I).crossTileID=0;this.usedCrossTileIDs[u.overscaledZ]||(this.usedCrossTileIDs[u.overscaledZ]={});const M=this.usedCrossTileIDs[u.overscaledZ];for(const I in this.indexes){const L=this.indexes[I];if(Number(I)>u.overscaledZ)for(const j in L){const G=L[j];G.tileID.isChildOf(u)&&G.findMatches(p.symbolInstances,u,M)}else{const j=L[u.scaledTo(Number(I)).key];j&&j.findMatches(p.symbolInstances,u,M)}}for(let I=0;I<p.symbolInstances.length;I++){const L=p.symbolInstances.get(I);L.crossTileID||(L.crossTileID=C.generate(),M[L.crossTileID]=!0)}return this.indexes[u.overscaledZ]===void 0&&(this.indexes[u.overscaledZ]={}),this.indexes[u.overscaledZ][u.key]=new Ht(u,p.symbolInstances,p.bucketInstanceId),!0}removeBucketCrossTileIDs(u,p){for(const C of p.getCrossTileIDsLists())for(const M of C)delete this.usedCrossTileIDs[u][M]}removeStaleBuckets(u){let p=!1;for(const C in this.indexes){const M=this.indexes[C];for(const I in M)u[M[I].bucketInstanceId]||(this.removeBucketCrossTileIDs(C,M[I]),delete M[I],p=!0)}return p}}class En{constructor(){this.layerIndexes={},this.crossTileIDs=new mn,this.maxBucketInstanceId=0,this.bucketsInCurrentPlacement={}}addLayer(u,p,C){let M=this.layerIndexes[u.id];M===void 0&&(M=this.layerIndexes[u.id]=new Ot);let I=!1;const L={};M.handleWrapJump(C);for(const j of p){const G=j.getBucket(u);G&&u.id===G.layerIds[0]&&(G.bucketInstanceId||(G.bucketInstanceId=++this.maxBucketInstanceId),M.addBucket(j.tileID,G,this.crossTileIDs)&&(I=!0),L[G.bucketInstanceId]=!0)}return M.removeStaleBuckets(L)&&(I=!0),I}pruneUnusedLayers(u){const p={};u.forEach(C=>{p[C]=!0});for(const C in this.layerIndexes)p[C]||delete this.layerIndexes[C]}}const zr=(O,u)=>a.t(O,u&&u.filter(p=>p.identifier!=="source.canvas")),Lr=a.av();class Ti extends a.E{constructor(u,p={}){super(),this._rtlTextPluginStateChange=()=>{for(const C in this.sourceCaches){const M=this.sourceCaches[C].getSource().type;M!=="vector"&&M!=="geojson"||this.sourceCaches[C].reload()}},this.map=u,this.dispatcher=new de(Se(),u._getMapId()),this.dispatcher.registerMessageHandler("getGlyphs",(C,M)=>this.getGlyphs(C,M)),this.dispatcher.registerMessageHandler("getImages",(C,M)=>this.getImages(C,M)),this.imageManager=new He,this.imageManager.setEventedParent(this),this.glyphManager=new Jt(u._requestManager,p.localIdeographFontFamily),this.lineAtlas=new Je(256,512),this.crossTileSymbolIndex=new En,this._spritesImagesIds={},this._layers={},this._order=[],this.sourceCaches={},this.zoomHistory=new a.aw,this._loaded=!1,this._availableImages=[],this._resetUpdates(),this.dispatcher.broadcast("setReferrer",a.ax()),X().on("pluginStateChange",this._rtlTextPluginStateChange),this.on("data",C=>{if(C.dataType!=="source"||C.sourceDataType!=="metadata")return;const M=this.sourceCaches[C.sourceId];if(!M)return;const I=M.getSource();if(I&&I.vectorLayerIds)for(const L in this._layers){const j=this._layers[L];j.source===I.id&&this._validateLayer(j)}})}loadURL(u,p={},C){this.fire(new a.k("dataloading",{dataType:"style"})),p.validate=typeof p.validate!="boolean"||p.validate;const M=this.map._requestManager.transformRequest(u,ne.Style);this._loadStyleRequest=new AbortController,a.h(M,this._loadStyleRequest).then(I=>{this._loadStyleRequest=null,this._load(I.data,p,C)}).catch(I=>{this._loadStyleRequest=null,I&&this.fire(new a.j(I))})}loadJSON(u,p={},C){this.fire(new a.k("dataloading",{dataType:"style"})),this._frameRequest=new AbortController,k.frameAsync(this._frameRequest).then(()=>{this._frameRequest=null,p.validate=p.validate!==!1,this._load(u,p,C)}).catch(()=>{})}loadEmpty(){this.fire(new a.k("dataloading",{dataType:"style"})),this._load(Lr,{validate:!1})}_load(u,p,C){var M;const I=p.transformStyle?p.transformStyle(C,u):u;if(!p.validate||!zr(this,a.x(I))){this._loaded=!0,this.stylesheet=I;for(const L in I.sources)this.addSource(L,I.sources[L],{validate:!1});I.sprite?this._loadSprite(I.sprite):this.imageManager.setLoaded(!0),this.glyphManager.setURL(I.glyphs),this._createLayers(),this.light=new nt(this.stylesheet.light),this.map.setTerrain((M=this.stylesheet.terrain)!==null&&M!==void 0?M:null),this.fire(new a.k("data",{dataType:"style"})),this.fire(new a.k("style.load"))}}_createLayers(){const u=a.ay(this.stylesheet.layers);this.dispatcher.broadcast("setLayers",u),this._order=u.map(p=>p.id),this._layers={},this._serializedLayers=null;for(const p of u){const C=a.az(p);C.setEventedParent(this,{layer:{id:p.id}}),this._layers[p.id]=C}}_loadSprite(u,p=!1,C=void 0){let M;this.imageManager.setLoaded(!1),this._spriteRequest=new AbortController,function(I,L,j,G){return a._(this,void 0,void 0,function*(){const te=rt(I),Ae=j>1?"@2x":"",he={},Me={};for(const{id:De,url:je}of te){const Qe=L.transformRequest(L.normalizeSpriteURL(je,Ae,".json"),ne.SpriteJSON);he[De]=a.h(Qe,G);const Le=L.transformRequest(L.normalizeSpriteURL(je,Ae,".png"),ne.SpriteImage);Me[De]=oe.getImage(Le,G)}return yield Promise.all([...Object.values(he),...Object.values(Me)]),function(De,je){return a._(this,void 0,void 0,function*(){const Qe={};for(const Le in De){Qe[Le]={};const ft=k.getImageCanvasContext((yield je[Le]).data),Bt=(yield De[Le]).data;for(const qe in Bt){const{width:_t,height:Ut,x:Tt,y:en,sdf:hn,pixelRatio:An,stretchX:On,stretchY:lr,content:xr}=Bt[qe];Qe[Le][qe]={data:null,pixelRatio:An,sdf:hn,stretchX:On,stretchY:lr,content:xr,spriteData:{width:_t,height:Ut,x:Tt,y:en,context:ft}}}}return Qe})}(he,Me)})}(u,this.map._requestManager,this.map.getPixelRatio(),this._spriteRequest).then(I=>{if(this._spriteRequest=null,I)for(const L in I){this._spritesImagesIds[L]=[];const j=this._spritesImagesIds[L]?this._spritesImagesIds[L].filter(G=>!(G in I)):[];for(const G of j)this.imageManager.removeImage(G),this._changedImages[G]=!0;for(const G in I[L]){const te=L==="default"?G:`${L}:${G}`;this._spritesImagesIds[L].push(te),te in this.imageManager.images?this.imageManager.updateImage(te,I[L][G],!1):this.imageManager.addImage(te,I[L][G]),p&&(this._changedImages[te]=!0)}}}).catch(I=>{this._spriteRequest=null,M=I,this.fire(new a.j(M))}).finally(()=>{this.imageManager.setLoaded(!0),this._availableImages=this.imageManager.listImages(),p&&(this._changed=!0),this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new a.k("data",{dataType:"style"})),C&&C(M)})}_unloadSprite(){for(const u of Object.values(this._spritesImagesIds).flat())this.imageManager.removeImage(u),this._changedImages[u]=!0;this._spritesImagesIds={},this._availableImages=this.imageManager.listImages(),this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new a.k("data",{dataType:"style"}))}_validateLayer(u){const p=this.sourceCaches[u.source];if(!p)return;const C=u.sourceLayer;if(!C)return;const M=p.getSource();(M.type==="geojson"||M.vectorLayerIds&&M.vectorLayerIds.indexOf(C)===-1)&&this.fire(new a.j(new Error(`Source layer "${C}" does not exist on source "${M.id}" as specified by style layer "${u.id}".`)))}loaded(){if(!this._loaded||Object.keys(this._updatedSources).length)return!1;for(const u in this.sourceCaches)if(!this.sourceCaches[u].loaded())return!1;return!!this.imageManager.isLoaded()}_serializeByIds(u){const p=this._serializedAllLayers();if(!u||u.length===0)return Object.values(p);const C=[];for(const M of u)p[M]&&C.push(p[M]);return C}_serializedAllLayers(){let u=this._serializedLayers;if(u)return u;u=this._serializedLayers={};const p=Object.keys(this._layers);for(const C of p){const M=this._layers[C];M.type!=="custom"&&(u[C]=M.serialize())}return u}hasTransitions(){if(this.light&&this.light.hasTransition())return!0;for(const u in this.sourceCaches)if(this.sourceCaches[u].hasTransition())return!0;for(const u in this._layers)if(this._layers[u].hasTransition())return!0;return!1}_checkLoaded(){if(!this._loaded)throw new Error("Style is not done loading.")}update(u){if(!this._loaded)return;const p=this._changed;if(this._changed){const M=Object.keys(this._updatedLayers),I=Object.keys(this._removedLayers);(M.length||I.length)&&this._updateWorkerLayers(M,I);for(const L in this._updatedSources){const j=this._updatedSources[L];if(j==="reload")this._reloadSource(L);else{if(j!=="clear")throw new Error(`Invalid action ${j}`);this._clearSource(L)}}this._updateTilesForChangedImages(),this._updateTilesForChangedGlyphs();for(const L in this._updatedPaintProps)this._layers[L].updateTransitions(u);this.light.updateTransitions(u),this._resetUpdates()}const C={};for(const M in this.sourceCaches){const I=this.sourceCaches[M];C[M]=I.used,I.used=!1}for(const M of this._order){const I=this._layers[M];I.recalculate(u,this._availableImages),!I.isHidden(u.zoom)&&I.source&&(this.sourceCaches[I.source].used=!0)}for(const M in C){const I=this.sourceCaches[M];C[M]!==I.used&&I.fire(new a.k("data",{sourceDataType:"visibility",dataType:"source",sourceId:M}))}this.light.recalculate(u),this.z=u.zoom,p&&this.fire(new a.k("data",{dataType:"style"}))}_updateTilesForChangedImages(){const u=Object.keys(this._changedImages);if(u.length){for(const p in this.sourceCaches)this.sourceCaches[p].reloadTilesForDependencies(["icons","patterns"],u);this._changedImages={}}}_updateTilesForChangedGlyphs(){if(this._glyphsDidChange){for(const u in this.sourceCaches)this.sourceCaches[u].reloadTilesForDependencies(["glyphs"],[""]);this._glyphsDidChange=!1}}_updateWorkerLayers(u,p){this.dispatcher.broadcast("updateLayers",{layers:this._serializeByIds(u),removedIds:p})}_resetUpdates(){this._changed=!1,this._updatedLayers={},this._removedLayers={},this._updatedSources={},this._updatedPaintProps={},this._changedImages={},this._glyphsDidChange=!1}setState(u,p={}){this._checkLoaded();const C=this.serialize();if(u=p.transformStyle?p.transformStyle(C,u):u,zr(this,a.x(u)))return!1;(u=a.aA(u)).layers=a.ay(u.layers);const M=a.aB(C,u),I=this._getOperationsToPerform(M);if(I.unimplemented.length>0)throw new Error(`Unimplemented: ${I.unimplemented.join(", ")}.`);if(I.operations.length===0)return!1;for(const L of I.operations)L();return this.stylesheet=u,this._serializedLayers=null,!0}_getOperationsToPerform(u){const p=[],C=[];for(const M of u)switch(M.command){case"setCenter":case"setZoom":case"setBearing":case"setPitch":continue;case"addLayer":p.push(()=>this.addLayer.apply(this,M.args));break;case"removeLayer":p.push(()=>this.removeLayer.apply(this,M.args));break;case"setPaintProperty":p.push(()=>this.setPaintProperty.apply(this,M.args));break;case"setLayoutProperty":p.push(()=>this.setLayoutProperty.apply(this,M.args));break;case"setFilter":p.push(()=>this.setFilter.apply(this,M.args));break;case"addSource":p.push(()=>this.addSource.apply(this,M.args));break;case"removeSource":p.push(()=>this.removeSource.apply(this,M.args));break;case"setLayerZoomRange":p.push(()=>this.setLayerZoomRange.apply(this,M.args));break;case"setLight":p.push(()=>this.setLight.apply(this,M.args));break;case"setGeoJSONSourceData":p.push(()=>this.setGeoJSONSourceData.apply(this,M.args));break;case"setGlyphs":p.push(()=>this.setGlyphs.apply(this,M.args));break;case"setSprite":p.push(()=>this.setSprite.apply(this,M.args));break;case"setTerrain":p.push(()=>this.map.setTerrain.apply(this,M.args));break;case"setTransition":p.push(()=>{});break;default:C.push(M.command)}return{operations:p,unimplemented:C}}addImage(u,p){if(this.getImage(u))return this.fire(new a.j(new Error(`An image named "${u}" already exists.`)));this.imageManager.addImage(u,p),this._afterImageUpdated(u)}updateImage(u,p){this.imageManager.updateImage(u,p)}getImage(u){return this.imageManager.getImage(u)}removeImage(u){if(!this.getImage(u))return this.fire(new a.j(new Error(`An image named "${u}" does not exist.`)));this.imageManager.removeImage(u),this._afterImageUpdated(u)}_afterImageUpdated(u){this._availableImages=this.imageManager.listImages(),this._changedImages[u]=!0,this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new a.k("data",{dataType:"style"}))}listImages(){return this._checkLoaded(),this.imageManager.listImages()}addSource(u,p,C={}){if(this._checkLoaded(),this.sourceCaches[u]!==void 0)throw new Error(`Source "${u}" already exists.`);if(!p.type)throw new Error(`The type property must be defined, but only the following properties were given: ${Object.keys(p).join(", ")}.`);if(["vector","raster","geojson","video","image"].indexOf(p.type)>=0&&this._validate(a.x.source,`sources.${u}`,p,null,C))return;this.map&&this.map._collectResourceTiming&&(p.collectResourceTiming=!0);const M=this.sourceCaches[u]=new Et(u,p,this.dispatcher);M.style=this,M.setEventedParent(this,()=>({isSourceLoaded:M.loaded(),source:M.serialize(),sourceId:u})),M.onAdd(this.map),this._changed=!0}removeSource(u){if(this._checkLoaded(),this.sourceCaches[u]===void 0)throw new Error("There is no source with this ID");for(const C in this._layers)if(this._layers[C].source===u)return this.fire(new a.j(new Error(`Source "${u}" cannot be removed while layer "${C}" is using it.`)));const p=this.sourceCaches[u];delete this.sourceCaches[u],delete this._updatedSources[u],p.fire(new a.k("data",{sourceDataType:"metadata",dataType:"source",sourceId:u})),p.setEventedParent(null),p.onRemove(this.map),this._changed=!0}setGeoJSONSourceData(u,p){if(this._checkLoaded(),this.sourceCaches[u]===void 0)throw new Error(`There is no source with this ID=${u}`);const C=this.sourceCaches[u].getSource();if(C.type!=="geojson")throw new Error(`geojsonSource.type is ${C.type}, which is !== 'geojson`);C.setData(p),this._changed=!0}getSource(u){return this.sourceCaches[u]&&this.sourceCaches[u].getSource()}addLayer(u,p,C={}){this._checkLoaded();const M=u.id;if(this.getLayer(M))return void this.fire(new a.j(new Error(`Layer "${M}" already exists on this map.`)));let I;if(u.type==="custom"){if(zr(this,a.aC(u)))return;I=a.az(u)}else{if("source"in u&&typeof u.source=="object"&&(this.addSource(M,u.source),u=a.aA(u),u=a.e(u,{source:M})),this._validate(a.x.layer,`layers.${M}`,u,{arrayIndex:-1},C))return;I=a.az(u),this._validateLayer(I),I.setEventedParent(this,{layer:{id:M}})}const L=p?this._order.indexOf(p):this._order.length;if(p&&L===-1)this.fire(new a.j(new Error(`Cannot add layer "${M}" before non-existing layer "${p}".`)));else{if(this._order.splice(L,0,M),this._layerOrderChanged=!0,this._layers[M]=I,this._removedLayers[M]&&I.source&&I.type!=="custom"){const j=this._removedLayers[M];delete this._removedLayers[M],j.type!==I.type?this._updatedSources[I.source]="clear":(this._updatedSources[I.source]="reload",this.sourceCaches[I.source].pause())}this._updateLayer(I),I.onAdd&&I.onAdd(this.map)}}moveLayer(u,p){if(this._checkLoaded(),this._changed=!0,!this._layers[u])return void this.fire(new a.j(new Error(`The layer '${u}' does not exist in the map's style and cannot be moved.`)));if(u===p)return;const C=this._order.indexOf(u);this._order.splice(C,1);const M=p?this._order.indexOf(p):this._order.length;p&&M===-1?this.fire(new a.j(new Error(`Cannot move layer "${u}" before non-existing layer "${p}".`))):(this._order.splice(M,0,u),this._layerOrderChanged=!0)}removeLayer(u){this._checkLoaded();const p=this._layers[u];if(!p)return void this.fire(new a.j(new Error(`Cannot remove non-existing layer "${u}".`)));p.setEventedParent(null);const C=this._order.indexOf(u);this._order.splice(C,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[u]=p,delete this._layers[u],this._serializedLayers&&delete this._serializedLayers[u],delete this._updatedLayers[u],delete this._updatedPaintProps[u],p.onRemove&&p.onRemove(this.map)}getLayer(u){return this._layers[u]}getLayersOrder(){return[...this._order]}hasLayer(u){return u in this._layers}setLayerZoomRange(u,p,C){this._checkLoaded();const M=this.getLayer(u);M?M.minzoom===p&&M.maxzoom===C||(p!=null&&(M.minzoom=p),C!=null&&(M.maxzoom=C),this._updateLayer(M)):this.fire(new a.j(new Error(`Cannot set the zoom range of non-existing layer "${u}".`)))}setFilter(u,p,C={}){this._checkLoaded();const M=this.getLayer(u);if(M){if(!a.aD(M.filter,p))return p==null?(M.filter=void 0,void this._updateLayer(M)):void(this._validate(a.x.filter,`layers.${M.id}.filter`,p,null,C)||(M.filter=a.aA(p),this._updateLayer(M)))}else this.fire(new a.j(new Error(`Cannot filter non-existing layer "${u}".`)))}getFilter(u){return a.aA(this.getLayer(u).filter)}setLayoutProperty(u,p,C,M={}){this._checkLoaded();const I=this.getLayer(u);I?a.aD(I.getLayoutProperty(p),C)||(I.setLayoutProperty(p,C,M),this._updateLayer(I)):this.fire(new a.j(new Error(`Cannot style non-existing layer "${u}".`)))}getLayoutProperty(u,p){const C=this.getLayer(u);if(C)return C.getLayoutProperty(p);this.fire(new a.j(new Error(`Cannot get style of non-existing layer "${u}".`)))}setPaintProperty(u,p,C,M={}){this._checkLoaded();const I=this.getLayer(u);I?a.aD(I.getPaintProperty(p),C)||(I.setPaintProperty(p,C,M)&&this._updateLayer(I),this._changed=!0,this._updatedPaintProps[u]=!0):this.fire(new a.j(new Error(`Cannot style non-existing layer "${u}".`)))}getPaintProperty(u,p){return this.getLayer(u).getPaintProperty(p)}setFeatureState(u,p){this._checkLoaded();const C=u.source,M=u.sourceLayer,I=this.sourceCaches[C];if(I===void 0)return void this.fire(new a.j(new Error(`The source '${C}' does not exist in the map's style.`)));const L=I.getSource().type;L==="geojson"&&M?this.fire(new a.j(new Error("GeoJSON sources cannot have a sourceLayer parameter."))):L!=="vector"||M?(u.id===void 0&&this.fire(new a.j(new Error("The feature id parameter must be provided."))),I.setFeatureState(M,u.id,p)):this.fire(new a.j(new Error("The sourceLayer parameter must be provided for vector source types.")))}removeFeatureState(u,p){this._checkLoaded();const C=u.source,M=this.sourceCaches[C];if(M===void 0)return void this.fire(new a.j(new Error(`The source '${C}' does not exist in the map's style.`)));const I=M.getSource().type,L=I==="vector"?u.sourceLayer:void 0;I!=="vector"||L?p&&typeof u.id!="string"&&typeof u.id!="number"?this.fire(new a.j(new Error("A feature id is required to remove its specific state property."))):M.removeFeatureState(L,u.id,p):this.fire(new a.j(new Error("The sourceLayer parameter must be provided for vector source types.")))}getFeatureState(u){this._checkLoaded();const p=u.source,C=u.sourceLayer,M=this.sourceCaches[p];if(M!==void 0)return M.getSource().type!=="vector"||C?(u.id===void 0&&this.fire(new a.j(new Error("The feature id parameter must be provided."))),M.getFeatureState(C,u.id)):void this.fire(new a.j(new Error("The sourceLayer parameter must be provided for vector source types.")));this.fire(new a.j(new Error(`The source '${p}' does not exist in the map's style.`)))}getTransition(){return a.e({duration:300,delay:0},this.stylesheet&&this.stylesheet.transition)}serialize(){if(!this._loaded)return;const u=a.aE(this.sourceCaches,I=>I.serialize()),p=this._serializeByIds(this._order),C=this.map.getTerrain()||void 0,M=this.stylesheet;return a.aF({version:M.version,name:M.name,metadata:M.metadata,light:M.light,center:M.center,zoom:M.zoom,bearing:M.bearing,pitch:M.pitch,sprite:M.sprite,glyphs:M.glyphs,transition:M.transition,sources:u,layers:p,terrain:C},I=>I!==void 0)}_updateLayer(u){this._updatedLayers[u.id]=!0,u.source&&!this._updatedSources[u.source]&&this.sourceCaches[u.source].getSource().type!=="raster"&&(this._updatedSources[u.source]="reload",this.sourceCaches[u.source].pause()),this._serializedLayers=null,this._changed=!0}_flattenAndSortRenderedFeatures(u){const p=L=>this._layers[L].type==="fill-extrusion",C={},M=[];for(let L=this._order.length-1;L>=0;L--){const j=this._order[L];if(p(j)){C[j]=L;for(const G of u){const te=G[j];if(te)for(const Ae of te)M.push(Ae)}}}M.sort((L,j)=>j.intersectionZ-L.intersectionZ);const I=[];for(let L=this._order.length-1;L>=0;L--){const j=this._order[L];if(p(j))for(let G=M.length-1;G>=0;G--){const te=M[G].feature;if(C[te.layer.id]<L)break;I.push(te),M.pop()}else for(const G of u){const te=G[j];if(te)for(const Ae of te)I.push(Ae.feature)}}return I}queryRenderedFeatures(u,p,C){p&&p.filter&&this._validate(a.x.filter,"queryRenderedFeatures.filter",p.filter,null,p);const M={};if(p&&p.layers){if(!Array.isArray(p.layers))return this.fire(new a.j(new Error("parameters.layers must be an Array."))),[];for(const j of p.layers){const G=this._layers[j];if(!G)return this.fire(new a.j(new Error(`The layer '${j}' does not exist in the map's style and cannot be queried for features.`))),[];M[G.source]=!0}}const I=[];p.availableImages=this._availableImages;const L=this._serializedAllLayers();for(const j in this.sourceCaches)p.layers&&!M[j]||I.push(Ze(this.sourceCaches[j],this._layers,L,u,p,C));return this.placement&&I.push(function(j,G,te,Ae,he,Me,De){const je={},Qe=Me.queryRenderedSymbols(Ae),Le=[];for(const ft of Object.keys(Qe).map(Number))Le.push(De[ft]);Le.sort(Xe);for(const ft of Le){const Bt=ft.featureIndex.lookupSymbolFeatures(Qe[ft.bucketInstanceId],G,ft.bucketIndex,ft.sourceLayerIndex,he.filter,he.layers,he.availableImages,j);for(const qe in Bt){const _t=je[qe]=je[qe]||[],Ut=Bt[qe];Ut.sort((Tt,en)=>{const hn=ft.featureSortOrder;if(hn){const An=hn.indexOf(Tt.featureIndex);return hn.indexOf(en.featureIndex)-An}return en.featureIndex-Tt.featureIndex});for(const Tt of Ut)_t.push(Tt)}}for(const ft in je)je[ft].forEach(Bt=>{const qe=Bt.feature,_t=te[j[ft].source].getFeatureState(qe.layer["source-layer"],qe.id);qe.source=qe.layer.source,qe.layer["source-layer"]&&(qe.sourceLayer=qe.layer["source-layer"]),qe.state=_t});return je}(this._layers,L,this.sourceCaches,u,p,this.placement.collisionIndex,this.placement.retainedQueryData)),this._flattenAndSortRenderedFeatures(I)}querySourceFeatures(u,p){p&&p.filter&&this._validate(a.x.filter,"querySourceFeatures.filter",p.filter,null,p);const C=this.sourceCaches[u];return C?function(M,I){const L=M.getRenderableIds().map(te=>M.getTileByID(te)),j=[],G={};for(let te=0;te<L.length;te++){const Ae=L[te],he=Ae.tileID.canonical.key;G[he]||(G[he]=!0,Ae.querySourceFeatures(j,I))}return j}(C,p):[]}getLight(){return this.light.getLight()}setLight(u,p={}){this._checkLoaded();const C=this.light.getLight();let M=!1;for(const L in u)if(!a.aD(u[L],C[L])){M=!0;break}if(!M)return;const I={now:k.now(),transition:a.e({duration:300,delay:0},this.stylesheet.transition)};this.light.setLight(u,p),this.light.updateTransitions(I)}_validate(u,p,C,M,I={}){return(!I||I.validate!==!1)&&zr(this,u.call(a.x,a.e({key:p,style:this.serialize(),value:C,styleSpec:a.v},M)))}_remove(u=!0){this._frameRequest&&(this._frameRequest.abort(),this._frameRequest=null),this._loadStyleRequest&&(this._loadStyleRequest.abort(),this._loadStyleRequest=null),this._spriteRequest&&(this._spriteRequest.abort(),this._spriteRequest=null),X().off("pluginStateChange",this._rtlTextPluginStateChange);for(const p in this._layers)this._layers[p].setEventedParent(null);for(const p in this.sourceCaches){const C=this.sourceCaches[p];C.setEventedParent(null),C.onRemove(this.map)}this.imageManager.setEventedParent(null),this.setEventedParent(null),this.dispatcher.remove(u)}_clearSource(u){this.sourceCaches[u].clearTiles()}_reloadSource(u){this.sourceCaches[u].resume(),this.sourceCaches[u].reload()}_updateSources(u){for(const p in this.sourceCaches)this.sourceCaches[p].update(u,this.map.terrain)}_generateCollisionBoxes(){for(const u in this.sourceCaches)this._reloadSource(u)}_updatePlacement(u,p,C,M,I=!1){let L=!1,j=!1;const G={};for(const te of this._order){const Ae=this._layers[te];if(Ae.type!=="symbol")continue;if(!G[Ae.source]){const Me=this.sourceCaches[Ae.source];G[Ae.source]=Me.getRenderableIds(!0).map(De=>Me.getTileByID(De)).sort((De,je)=>je.tileID.overscaledZ-De.tileID.overscaledZ||(De.tileID.isLessThan(je.tileID)?-1:1))}const he=this.crossTileSymbolIndex.addLayer(Ae,G[Ae.source],u.center.lng);L=L||he}if(this.crossTileSymbolIndex.pruneUnusedLayers(this._order),((I=I||this._layerOrderChanged||C===0)||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(k.now(),u.zoom))&&(this.pauseablePlacement=new ve(u,this.map.terrain,this._order,I,p,C,M,this.placement),this._layerOrderChanged=!1),this.pauseablePlacement.isDone()?this.placement.setStale():(this.pauseablePlacement.continuePlacement(this._order,this._layers,G),this.pauseablePlacement.isDone()&&(this.placement=this.pauseablePlacement.commit(k.now()),j=!0),L&&this.pauseablePlacement.placement.setStale()),j||L)for(const te of this._order){const Ae=this._layers[te];Ae.type==="symbol"&&this.placement.updateLayerOpacities(Ae,G[Ae.source])}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(k.now())}_releaseSymbolFadeTiles(){for(const u in this.sourceCaches)this.sourceCaches[u].releaseSymbolFadeTiles()}getImages(u,p){return a._(this,void 0,void 0,function*(){const C=yield this.imageManager.getImages(p.icons);this._updateTilesForChangedImages();const M=this.sourceCaches[p.source];return M&&M.setDependencies(p.tileID.key,p.type,p.icons),C})}getGlyphs(u,p){return a._(this,void 0,void 0,function*(){const C=yield this.glyphManager.getGlyphs(p.stacks),M=this.sourceCaches[p.source];return M&&M.setDependencies(p.tileID.key,p.type,[""]),C})}getGlyphsUrl(){return this.stylesheet.glyphs||null}setGlyphs(u,p={}){this._checkLoaded(),u&&this._validate(a.x.glyphs,"glyphs",u,null,p)||(this._glyphsDidChange=!0,this.stylesheet.glyphs=u,this.glyphManager.entries={},this.glyphManager.setURL(u))}addSprite(u,p,C={},M){this._checkLoaded();const I=[{id:u,url:p}],L=[...rt(this.stylesheet.sprite),...I];this._validate(a.x.sprite,"sprite",L,null,C)||(this.stylesheet.sprite=L,this._loadSprite(I,!0,M))}removeSprite(u){this._checkLoaded();const p=rt(this.stylesheet.sprite);if(p.find(C=>C.id===u)){if(this._spritesImagesIds[u])for(const C of this._spritesImagesIds[u])this.imageManager.removeImage(C),this._changedImages[C]=!0;p.splice(p.findIndex(C=>C.id===u),1),this.stylesheet.sprite=p.length>0?p:void 0,delete this._spritesImagesIds[u],this._availableImages=this.imageManager.listImages(),this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new a.k("data",{dataType:"style"}))}else this.fire(new a.j(new Error(`Sprite "${u}" doesn't exists on this map.`)))}getSprite(){return rt(this.stylesheet.sprite)}setSprite(u,p={},C){this._checkLoaded(),u&&this._validate(a.x.sprite,"sprite",u,null,p)||(this.stylesheet.sprite=u,u?this._loadSprite(u,!0,C):(this._unloadSprite(),C&&C(null)))}}var po=a.X([{name:"a_pos",type:"Int16",components:2}]),Cl="attribute vec3 a_pos3d;uniform mat4 u_matrix;uniform float u_ele_delta;varying vec2 v_texture_pos;varying float v_depth;void main() {float extent=8192.0;float ele_delta=a_pos3d.z==1.0 ? u_ele_delta : 0.0;v_texture_pos=a_pos3d.xy/extent;gl_Position=u_matrix*vec4(a_pos3d.xy,get_elevation(a_pos3d.xy)-ele_delta,1.0);v_depth=gl_Position.z/gl_Position.w;}";const br={prelude:_i(`#ifdef GL_ES
|
||
precision mediump float;
|
||
#else
|
||
#if !defined(lowp)
|
||
#define lowp
|
||
#endif
|
||
#if !defined(mediump)
|
||
#define mediump
|
||
#endif
|
||
#if !defined(highp)
|
||
#define highp
|
||
#endif
|
||
#endif
|
||
`,`#ifdef GL_ES
|
||
precision highp float;
|
||
#else
|
||
#if !defined(lowp)
|
||
#define lowp
|
||
#endif
|
||
#if !defined(mediump)
|
||
#define mediump
|
||
#endif
|
||
#if !defined(highp)
|
||
#define highp
|
||
#endif
|
||
#endif
|
||
vec2 unpack_float(const float packedValue) {int packedIntValue=int(packedValue);int v0=packedIntValue/256;return vec2(v0,packedIntValue-v0*256);}vec2 unpack_opacity(const float packedOpacity) {int intOpacity=int(packedOpacity)/2;return vec2(float(intOpacity)/127.0,mod(packedOpacity,2.0));}vec4 decode_color(const vec2 encodedColor) {return vec4(unpack_float(encodedColor[0])/255.0,unpack_float(encodedColor[1])/255.0
|
||
);}float unpack_mix_vec2(const vec2 packedValue,const float t) {return mix(packedValue[0],packedValue[1],t);}vec4 unpack_mix_color(const vec4 packedColors,const float t) {vec4 minColor=decode_color(vec2(packedColors[0],packedColors[1]));vec4 maxColor=decode_color(vec2(packedColors[2],packedColors[3]));return mix(minColor,maxColor,t);}vec2 get_pattern_pos(const vec2 pixel_coord_upper,const vec2 pixel_coord_lower,const vec2 pattern_size,const float tile_units_to_pixels,const vec2 pos) {vec2 offset=mod(mod(mod(pixel_coord_upper,pattern_size)*256.0,pattern_size)*256.0+pixel_coord_lower,pattern_size);return (tile_units_to_pixels*pos+offset)/pattern_size;}
|
||
#ifdef TERRAIN3D
|
||
uniform sampler2D u_terrain;uniform float u_terrain_dim;uniform mat4 u_terrain_matrix;uniform vec4 u_terrain_unpack;uniform float u_terrain_exaggeration;uniform highp sampler2D u_depth;
|
||
#endif
|
||
const highp vec4 bitSh=vec4(256.*256.*256.,256.*256.,256.,1.);const highp vec4 bitShifts=vec4(1.)/bitSh;highp float unpack(highp vec4 color) {return dot(color,bitShifts);}highp float depthOpacity(vec3 frag) {
|
||
#ifdef TERRAIN3D
|
||
highp float d=unpack(texture2D(u_depth,frag.xy*0.5+0.5))+0.0001-frag.z;return 1.0-max(0.0,min(1.0,-d*500.0));
|
||
#else
|
||
return 1.0;
|
||
#endif
|
||
}float calculate_visibility(vec4 pos) {
|
||
#ifdef TERRAIN3D
|
||
vec3 frag=pos.xyz/pos.w;highp float d=depthOpacity(frag);if (d > 0.95) return 1.0;return (d+depthOpacity(frag+vec3(0.0,0.01,0.0)))/2.0;
|
||
#else
|
||
return 1.0;
|
||
#endif
|
||
}float ele(vec2 pos) {
|
||
#ifdef TERRAIN3D
|
||
vec4 rgb=(texture2D(u_terrain,pos)*255.0)*u_terrain_unpack;return rgb.r+rgb.g+rgb.b-u_terrain_unpack.a;
|
||
#else
|
||
return 0.0;
|
||
#endif
|
||
}float get_elevation(vec2 pos) {
|
||
#ifdef TERRAIN3D
|
||
vec2 coord=(u_terrain_matrix*vec4(pos,0.0,1.0)).xy*u_terrain_dim+1.0;vec2 f=fract(coord);vec2 c=(floor(coord)+0.5)/(u_terrain_dim+2.0);float d=1.0/(u_terrain_dim+2.0);float tl=ele(c);float tr=ele(c+vec2(d,0.0));float bl=ele(c+vec2(0.0,d));float br=ele(c+vec2(d,d));float elevation=mix(mix(tl,tr,f.x),mix(bl,br,f.x),f.y);return elevation*u_terrain_exaggeration;
|
||
#else
|
||
return 0.0;
|
||
#endif
|
||
}`),background:_i(`uniform vec4 u_color;uniform float u_opacity;void main() {gl_FragColor=u_color*u_opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,"attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);}"),backgroundPattern:_i(`uniform vec2 u_pattern_tl_a;uniform vec2 u_pattern_br_a;uniform vec2 u_pattern_tl_b;uniform vec2 u_pattern_br_b;uniform vec2 u_texsize;uniform float u_mix;uniform float u_opacity;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;void main() {vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(u_pattern_tl_a/u_texsize,u_pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(u_pattern_tl_b/u_texsize,u_pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);gl_FragColor=mix(color1,color2,u_mix)*u_opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,"uniform mat4 u_matrix;uniform vec2 u_pattern_size_a;uniform vec2 u_pattern_size_b;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_scale_a;uniform float u_scale_b;uniform float u_tile_units_to_pixels;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_a*u_pattern_size_a,u_tile_units_to_pixels,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_b*u_pattern_size_b,u_tile_units_to_pixels,a_pos);}"),circle:_i(`varying vec3 v_data;varying float v_visibility;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define mediump float radius
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define highp vec4 stroke_color
|
||
#pragma mapbox: define mediump float stroke_width
|
||
#pragma mapbox: define lowp float stroke_opacity
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize mediump float radius
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize highp vec4 stroke_color
|
||
#pragma mapbox: initialize mediump float stroke_width
|
||
#pragma mapbox: initialize lowp float stroke_opacity
|
||
vec2 extrude=v_data.xy;float extrude_length=length(extrude);lowp float antialiasblur=v_data.z;float antialiased_blur=-max(blur,antialiasblur);float opacity_t=smoothstep(0.0,antialiased_blur,extrude_length-1.0);float color_t=stroke_width < 0.01 ? 0.0 : smoothstep(antialiased_blur,0.0,extrude_length-radius/(radius+stroke_width));gl_FragColor=v_visibility*opacity_t*mix(color*opacity,stroke_color*stroke_opacity,color_t);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`uniform mat4 u_matrix;uniform bool u_scale_with_map;uniform bool u_pitch_with_map;uniform vec2 u_extrude_scale;uniform lowp float u_device_pixel_ratio;uniform highp float u_camera_to_center_distance;attribute vec2 a_pos;varying vec3 v_data;varying float v_visibility;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define mediump float radius
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define highp vec4 stroke_color
|
||
#pragma mapbox: define mediump float stroke_width
|
||
#pragma mapbox: define lowp float stroke_opacity
|
||
void main(void) {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize mediump float radius
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize highp vec4 stroke_color
|
||
#pragma mapbox: initialize mediump float stroke_width
|
||
#pragma mapbox: initialize lowp float stroke_opacity
|
||
vec2 extrude=vec2(mod(a_pos,2.0)*2.0-1.0);vec2 circle_center=floor(a_pos*0.5);float ele=get_elevation(circle_center);v_visibility=calculate_visibility(u_matrix*vec4(circle_center,ele,1.0));if (u_pitch_with_map) {vec2 corner_position=circle_center;if (u_scale_with_map) {corner_position+=extrude*(radius+stroke_width)*u_extrude_scale;} else {vec4 projected_center=u_matrix*vec4(circle_center,0,1);corner_position+=extrude*(radius+stroke_width)*u_extrude_scale*(projected_center.w/u_camera_to_center_distance);}gl_Position=u_matrix*vec4(corner_position,ele,1);} else {gl_Position=u_matrix*vec4(circle_center,ele,1);if (u_scale_with_map) {gl_Position.xy+=extrude*(radius+stroke_width)*u_extrude_scale*u_camera_to_center_distance;} else {gl_Position.xy+=extrude*(radius+stroke_width)*u_extrude_scale*gl_Position.w;}}lowp float antialiasblur=1.0/u_device_pixel_ratio/(radius+stroke_width);v_data=vec3(extrude.x,extrude.y,antialiasblur);}`),clippingMask:_i("void main() {gl_FragColor=vec4(1.0);}","attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);}"),heatmap:_i(`uniform highp float u_intensity;varying vec2 v_extrude;
|
||
#pragma mapbox: define highp float weight
|
||
#define GAUSS_COEF 0.3989422804014327
|
||
void main() {
|
||
#pragma mapbox: initialize highp float weight
|
||
float d=-0.5*3.0*3.0*dot(v_extrude,v_extrude);float val=weight*u_intensity*GAUSS_COEF*exp(d);gl_FragColor=vec4(val,1.0,1.0,1.0);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`uniform mat4 u_matrix;uniform float u_extrude_scale;uniform float u_opacity;uniform float u_intensity;attribute vec2 a_pos;varying vec2 v_extrude;
|
||
#pragma mapbox: define highp float weight
|
||
#pragma mapbox: define mediump float radius
|
||
const highp float ZERO=1.0/255.0/16.0;
|
||
#define GAUSS_COEF 0.3989422804014327
|
||
void main(void) {
|
||
#pragma mapbox: initialize highp float weight
|
||
#pragma mapbox: initialize mediump float radius
|
||
vec2 unscaled_extrude=vec2(mod(a_pos,2.0)*2.0-1.0);float S=sqrt(-2.0*log(ZERO/weight/u_intensity/GAUSS_COEF))/3.0;v_extrude=S*unscaled_extrude;vec2 extrude=v_extrude*radius*u_extrude_scale;vec4 pos=vec4(floor(a_pos*0.5)+extrude,0,1);gl_Position=u_matrix*pos;}`),heatmapTexture:_i(`uniform sampler2D u_image;uniform sampler2D u_color_ramp;uniform float u_opacity;varying vec2 v_pos;void main() {float t=texture2D(u_image,v_pos).r;vec4 color=texture2D(u_color_ramp,vec2(t,0.5));gl_FragColor=color*u_opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(0.0);
|
||
#endif
|
||
}`,"uniform mat4 u_matrix;uniform vec2 u_world;attribute vec2 a_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos*u_world,0,1);v_pos.x=a_pos.x;v_pos.y=1.0-a_pos.y;}"),collisionBox:_i("varying float v_placed;varying float v_notUsed;void main() {float alpha=0.5;gl_FragColor=vec4(1.0,0.0,0.0,1.0)*alpha;if (v_placed > 0.5) {gl_FragColor=vec4(0.0,0.0,1.0,0.5)*alpha;}if (v_notUsed > 0.5) {gl_FragColor*=.1;}}","attribute vec2 a_pos;attribute vec2 a_anchor_pos;attribute vec2 a_extrude;attribute vec2 a_placed;attribute vec2 a_shift;uniform mat4 u_matrix;uniform vec2 u_extrude_scale;uniform float u_camera_to_center_distance;varying float v_placed;varying float v_notUsed;void main() {vec4 projectedPoint=u_matrix*vec4(a_anchor_pos,0,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float collision_perspective_ratio=clamp(0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);gl_Position=u_matrix*vec4(a_pos,get_elevation(a_pos),1.0);gl_Position.xy+=(a_extrude+a_shift)*u_extrude_scale*gl_Position.w*collision_perspective_ratio;v_placed=a_placed.x;v_notUsed=a_placed.y;}"),collisionCircle:_i("varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;void main() {float alpha=0.5*min(v_perspective_ratio,1.0);float stroke_radius=0.9*max(v_perspective_ratio,1.0);float distance_to_center=length(v_extrude);float distance_to_edge=abs(distance_to_center-v_radius);float opacity_t=smoothstep(-stroke_radius,0.0,-distance_to_edge);vec4 color=mix(vec4(0.0,0.0,1.0,0.5),vec4(1.0,0.0,0.0,1.0),v_collision);gl_FragColor=color*alpha*opacity_t;}","attribute vec2 a_pos;attribute float a_radius;attribute vec2 a_flags;uniform mat4 u_matrix;uniform mat4 u_inv_matrix;uniform vec2 u_viewport_size;uniform float u_camera_to_center_distance;varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;vec3 toTilePosition(vec2 screenPos) {vec4 rayStart=u_inv_matrix*vec4(screenPos,-1.0,1.0);vec4 rayEnd =u_inv_matrix*vec4(screenPos, 1.0,1.0);rayStart.xyz/=rayStart.w;rayEnd.xyz /=rayEnd.w;highp float t=(0.0-rayStart.z)/(rayEnd.z-rayStart.z);return mix(rayStart.xyz,rayEnd.xyz,t);}void main() {vec2 quadCenterPos=a_pos;float radius=a_radius;float collision=a_flags.x;float vertexIdx=a_flags.y;vec2 quadVertexOffset=vec2(mix(-1.0,1.0,float(vertexIdx >=2.0)),mix(-1.0,1.0,float(vertexIdx >=1.0 && vertexIdx <=2.0)));vec2 quadVertexExtent=quadVertexOffset*radius;vec3 tilePos=toTilePosition(quadCenterPos);vec4 clipPos=u_matrix*vec4(tilePos,1.0);highp float camera_to_anchor_distance=clipPos.w;highp float collision_perspective_ratio=clamp(0.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);float padding_factor=1.2;v_radius=radius;v_extrude=quadVertexExtent*padding_factor;v_perspective_ratio=collision_perspective_ratio;v_collision=collision;gl_Position=vec4(clipPos.xyz/clipPos.w,1.0)+vec4(quadVertexExtent*padding_factor/u_viewport_size*2.0,0.0,0.0);}"),debug:_i("uniform highp vec4 u_color;uniform sampler2D u_overlay;varying vec2 v_uv;void main() {vec4 overlay_color=texture2D(u_overlay,v_uv);gl_FragColor=mix(u_color,overlay_color,overlay_color.a);}","attribute vec2 a_pos;varying vec2 v_uv;uniform mat4 u_matrix;uniform float u_overlay_scale;void main() {v_uv=a_pos/8192.0;gl_Position=u_matrix*vec4(a_pos*u_overlay_scale,get_elevation(a_pos),1);}"),fill:_i(`#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
gl_FragColor=color*opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`attribute vec2 a_pos;uniform mat4 u_matrix;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
gl_Position=u_matrix*vec4(a_pos,0,1);}`),fillOutline:_i(`varying vec2 v_pos;
|
||
#pragma mapbox: define highp vec4 outline_color
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 outline_color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);gl_FragColor=outline_color*(alpha*opacity);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`attribute vec2 a_pos;uniform mat4 u_matrix;uniform vec2 u_world;varying vec2 v_pos;
|
||
#pragma mapbox: define highp vec4 outline_color
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 outline_color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;}`),fillOutlinePattern:_i(`uniform vec2 u_texsize;uniform sampler2D u_image;uniform float u_fade;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos;
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);gl_FragColor=mix(color1,color2,u_fade)*alpha*opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`uniform mat4 u_matrix;uniform vec2 u_world;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec2 v_pos;
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
#pragma mapbox: define lowp float pixel_ratio_from
|
||
#pragma mapbox: define lowp float pixel_ratio_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
#pragma mapbox: initialize lowp float pixel_ratio_from
|
||
#pragma mapbox: initialize lowp float pixel_ratio_to
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;gl_Position=u_matrix*vec4(a_pos,0,1);vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,a_pos);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;}`),fillPattern:_i(`#ifdef GL_ES
|
||
precision highp float;
|
||
#endif
|
||
uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);gl_FragColor=mix(color1,color2,u_fade)*opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;attribute vec2 a_pos;varying vec2 v_pos_a;varying vec2 v_pos_b;
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
#pragma mapbox: define lowp float pixel_ratio_from
|
||
#pragma mapbox: define lowp float pixel_ratio_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
#pragma mapbox: initialize lowp float pixel_ratio_from
|
||
#pragma mapbox: initialize lowp float pixel_ratio_to
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;gl_Position=u_matrix*vec4(a_pos,0,1);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileZoomRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileZoomRatio,a_pos);}`),fillExtrusion:_i(`varying vec4 v_color;void main() {gl_FragColor=v_color;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`uniform mat4 u_matrix;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;uniform float u_vertical_gradient;uniform lowp float u_opacity;attribute vec2 a_pos;attribute vec4 a_normal_ed;
|
||
#ifdef TERRAIN3D
|
||
attribute vec2 a_centroid;
|
||
#endif
|
||
varying vec4 v_color;
|
||
#pragma mapbox: define highp float base
|
||
#pragma mapbox: define highp float height
|
||
#pragma mapbox: define highp vec4 color
|
||
void main() {
|
||
#pragma mapbox: initialize highp float base
|
||
#pragma mapbox: initialize highp float height
|
||
#pragma mapbox: initialize highp vec4 color
|
||
vec3 normal=a_normal_ed.xyz;
|
||
#ifdef TERRAIN3D
|
||
float height_terrain3d_offset=get_elevation(a_centroid);float base_terrain3d_offset=height_terrain3d_offset-(base > 0.0 ? 0.0 : 10.0);
|
||
#else
|
||
float height_terrain3d_offset=0.0;float base_terrain3d_offset=0.0;
|
||
#endif
|
||
base=max(0.0,base)+base_terrain3d_offset;height=max(0.0,height)+height_terrain3d_offset;float t=mod(normal.x,2.0);gl_Position=u_matrix*vec4(a_pos,t > 0.0 ? height : base,1);float colorvalue=color.r*0.2126+color.g*0.7152+color.b*0.0722;v_color=vec4(0.0,0.0,0.0,1.0);vec4 ambientlight=vec4(0.03,0.03,0.03,1.0);color+=ambientlight;float directional=clamp(dot(normal/16384.0,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((1.0-colorvalue+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=((1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_color.r+=clamp(color.r*directional*u_lightcolor.r,mix(0.0,0.3,1.0-u_lightcolor.r),1.0);v_color.g+=clamp(color.g*directional*u_lightcolor.g,mix(0.0,0.3,1.0-u_lightcolor.g),1.0);v_color.b+=clamp(color.b*directional*u_lightcolor.b,mix(0.0,0.3,1.0-u_lightcolor.b),1.0);v_color*=u_opacity;}`),fillExtrusionPattern:_i(`uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting;
|
||
#pragma mapbox: define lowp float base
|
||
#pragma mapbox: define lowp float height
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
#pragma mapbox: define lowp float pixel_ratio_from
|
||
#pragma mapbox: define lowp float pixel_ratio_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float base
|
||
#pragma mapbox: initialize lowp float height
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
#pragma mapbox: initialize lowp float pixel_ratio_from
|
||
#pragma mapbox: initialize lowp float pixel_ratio_to
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture2D(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture2D(u_image,pos2);vec4 mixedColor=mix(color1,color2,u_fade);gl_FragColor=mixedColor*v_lighting;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_height_factor;uniform vec3 u_scale;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;attribute vec2 a_pos;attribute vec4 a_normal_ed;
|
||
#ifdef TERRAIN3D
|
||
attribute vec2 a_centroid;
|
||
#endif
|
||
varying vec2 v_pos_a;varying vec2 v_pos_b;varying vec4 v_lighting;
|
||
#pragma mapbox: define lowp float base
|
||
#pragma mapbox: define lowp float height
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
#pragma mapbox: define lowp float pixel_ratio_from
|
||
#pragma mapbox: define lowp float pixel_ratio_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float base
|
||
#pragma mapbox: initialize lowp float height
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
#pragma mapbox: initialize lowp float pixel_ratio_from
|
||
#pragma mapbox: initialize lowp float pixel_ratio_to
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec3 normal=a_normal_ed.xyz;float edgedistance=a_normal_ed.w;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;
|
||
#ifdef TERRAIN3D
|
||
float height_terrain3d_offset=get_elevation(a_centroid);float base_terrain3d_offset=height_terrain3d_offset-(base > 0.0 ? 0.0 : 10.0);
|
||
#else
|
||
float height_terrain3d_offset=0.0;float base_terrain3d_offset=0.0;
|
||
#endif
|
||
base=max(0.0,base)+base_terrain3d_offset;height=max(0.0,height)+height_terrain3d_offset;float t=mod(normal.x,2.0);float z=t > 0.0 ? height : base;gl_Position=u_matrix*vec4(a_pos,z,1);vec2 pos=normal.x==1.0 && normal.y==0.0 && normal.z==16384.0
|
||
? a_pos
|
||
: vec2(edgedistance,z*u_height_factor);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,pos);v_lighting=vec4(0.0,0.0,0.0,1.0);float directional=clamp(dot(normal/16383.0,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((0.5+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=((1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_lighting.rgb+=clamp(directional*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));v_lighting*=u_opacity;}`),hillshadePrepare:_i(`#ifdef GL_ES
|
||
precision highp float;
|
||
#endif
|
||
uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_dimension;uniform float u_zoom;uniform vec4 u_unpack;float getElevation(vec2 coord,float bias) {vec4 data=texture2D(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack)/4.0;}void main() {vec2 epsilon=1.0/u_dimension;float a=getElevation(v_pos+vec2(-epsilon.x,-epsilon.y),0.0);float b=getElevation(v_pos+vec2(0,-epsilon.y),0.0);float c=getElevation(v_pos+vec2(epsilon.x,-epsilon.y),0.0);float d=getElevation(v_pos+vec2(-epsilon.x,0),0.0);float e=getElevation(v_pos,0.0);float f=getElevation(v_pos+vec2(epsilon.x,0),0.0);float g=getElevation(v_pos+vec2(-epsilon.x,epsilon.y),0.0);float h=getElevation(v_pos+vec2(0,epsilon.y),0.0);float i=getElevation(v_pos+vec2(epsilon.x,epsilon.y),0.0);float exaggerationFactor=u_zoom < 2.0 ? 0.4 : u_zoom < 4.5 ? 0.35 : 0.3;float exaggeration=u_zoom < 15.0 ? (u_zoom-15.0)*exaggerationFactor : 0.0;vec2 deriv=vec2((c+f+f+i)-(a+d+d+g),(g+h+h+i)-(a+b+b+c))/pow(2.0,exaggeration+(19.2562-u_zoom));gl_FragColor=clamp(vec4(deriv.x/2.0+0.5,deriv.y/2.0+0.5,1.0,1.0),0.0,1.0);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,"uniform mat4 u_matrix;uniform vec2 u_dimension;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);highp vec2 epsilon=1.0/u_dimension;float scale=(u_dimension.x-2.0)/u_dimension.x;v_pos=(a_texture_pos/8192.0)*scale+epsilon;}"),hillshade:_i(`uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_latrange;uniform vec2 u_light;uniform vec4 u_shadow;uniform vec4 u_highlight;uniform vec4 u_accent;
|
||
#define PI 3.141592653589793
|
||
void main() {vec4 pixel=texture2D(u_image,v_pos);vec2 deriv=((pixel.rg*2.0)-1.0);float scaleFactor=cos(radians((u_latrange[0]-u_latrange[1])*(1.0-v_pos.y)+u_latrange[1]));float slope=atan(1.25*length(deriv)/scaleFactor);float aspect=deriv.x !=0.0 ? atan(deriv.y,-deriv.x) : PI/2.0*(deriv.y > 0.0 ? 1.0 :-1.0);float intensity=u_light.x;float azimuth=u_light.y+PI;float base=1.875-intensity*1.75;float maxValue=0.5*PI;float scaledSlope=intensity !=0.5 ? ((pow(base,slope)-1.0)/(pow(base,maxValue)-1.0))*maxValue : slope;float accent=cos(scaledSlope);vec4 accent_color=(1.0-accent)*u_accent*clamp(intensity*2.0,0.0,1.0);float shade=abs(mod((aspect+azimuth)/PI+0.5,2.0)-1.0);vec4 shade_color=mix(u_shadow,u_highlight,shade)*sin(scaledSlope)*clamp(intensity*2.0,0.0,1.0);gl_FragColor=accent_color*(1.0-shade_color.a)+shade_color;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,"uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=a_texture_pos/8192.0;}"),line:_i(`uniform lowp float u_device_pixel_ratio;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);gl_FragColor=color*(alpha*opacity);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`
|
||
#define scale 0.015873016
|
||
attribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform vec2 u_units_to_pixels;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp float v_linesofar;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define mediump float gapwidth
|
||
#pragma mapbox: define lowp float offset
|
||
#pragma mapbox: define mediump float width
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump float gapwidth
|
||
#pragma mapbox: initialize lowp float offset
|
||
#pragma mapbox: initialize mediump float width
|
||
float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;v_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*2.0;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;
|
||
#ifdef TERRAIN3D
|
||
v_gamma_scale=1.0;
|
||
#else
|
||
float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
|
||
#endif
|
||
v_width2=vec2(outset,inset);}`),lineGradient:_i(`uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;varying highp vec2 v_uv;
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);vec4 color=texture2D(u_image,v_uv);gl_FragColor=color*(alpha*opacity);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`
|
||
#define scale 0.015873016
|
||
attribute vec2 a_pos_normal;attribute vec4 a_data;attribute float a_uv_x;attribute float a_split_index;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_units_to_pixels;uniform float u_image_height;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp vec2 v_uv;
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define mediump float gapwidth
|
||
#pragma mapbox: define lowp float offset
|
||
#pragma mapbox: define mediump float width
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump float gapwidth
|
||
#pragma mapbox: initialize lowp float offset
|
||
#pragma mapbox: initialize mediump float width
|
||
float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;highp float texel_height=1.0/u_image_height;highp float half_texel_height=0.5*texel_height;v_uv=vec2(a_uv_x,a_split_index*texel_height-half_texel_height);vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;
|
||
#ifdef TERRAIN3D
|
||
v_gamma_scale=1.0;
|
||
#else
|
||
float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
|
||
#endif
|
||
v_width2=vec2(outset,inset);}`),linePattern:_i(`#ifdef GL_ES
|
||
precision highp float;
|
||
#endif
|
||
uniform lowp float u_device_pixel_ratio;uniform vec2 u_texsize;uniform float u_fade;uniform mediump vec3 u_scale;uniform sampler2D u_image;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
#pragma mapbox: define lowp float pixel_ratio_from
|
||
#pragma mapbox: define lowp float pixel_ratio_to
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
#pragma mapbox: initialize lowp float pixel_ratio_from
|
||
#pragma mapbox: initialize lowp float pixel_ratio_to
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;vec2 pattern_size_a=vec2(display_size_a.x*fromScale/tileZoomRatio,display_size_a.y);vec2 pattern_size_b=vec2(display_size_b.x*toScale/tileZoomRatio,display_size_b.y);float aspect_a=display_size_a.y/v_width;float aspect_b=display_size_b.y/v_width;float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);float x_a=mod(v_linesofar/pattern_size_a.x*aspect_a,1.0);float x_b=mod(v_linesofar/pattern_size_b.x*aspect_b,1.0);float y=0.5*v_normal.y+0.5;vec2 texel_size=1.0/u_texsize;vec2 pos_a=mix(pattern_tl_a*texel_size-texel_size,pattern_br_a*texel_size+texel_size,vec2(x_a,y));vec2 pos_b=mix(pattern_tl_b*texel_size-texel_size,pattern_br_b*texel_size+texel_size,vec2(x_b,y));vec4 color=mix(texture2D(u_image,pos_a),texture2D(u_image,pos_b),u_fade);gl_FragColor=color*alpha*opacity;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`
|
||
#define scale 0.015873016
|
||
#define LINE_DISTANCE_SCALE 2.0
|
||
attribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform vec2 u_units_to_pixels;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp float offset
|
||
#pragma mapbox: define mediump float gapwidth
|
||
#pragma mapbox: define mediump float width
|
||
#pragma mapbox: define lowp float floorwidth
|
||
#pragma mapbox: define lowp vec4 pattern_from
|
||
#pragma mapbox: define lowp vec4 pattern_to
|
||
#pragma mapbox: define lowp float pixel_ratio_from
|
||
#pragma mapbox: define lowp float pixel_ratio_to
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize lowp float offset
|
||
#pragma mapbox: initialize mediump float gapwidth
|
||
#pragma mapbox: initialize mediump float width
|
||
#pragma mapbox: initialize lowp float floorwidth
|
||
#pragma mapbox: initialize mediump vec4 pattern_from
|
||
#pragma mapbox: initialize mediump vec4 pattern_to
|
||
#pragma mapbox: initialize lowp float pixel_ratio_from
|
||
#pragma mapbox: initialize lowp float pixel_ratio_to
|
||
float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;
|
||
#ifdef TERRAIN3D
|
||
v_gamma_scale=1.0;
|
||
#else
|
||
float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
|
||
#endif
|
||
v_linesofar=a_linesofar;v_width2=vec2(outset,inset);v_width=floorwidth;}`),lineSDF:_i(`uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;uniform float u_sdfgamma;uniform float u_mix;varying vec2 v_normal;varying vec2 v_width2;varying vec2 v_tex_a;varying vec2 v_tex_b;varying float v_gamma_scale;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define mediump float width
|
||
#pragma mapbox: define lowp float floorwidth
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump float width
|
||
#pragma mapbox: initialize lowp float floorwidth
|
||
float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);float sdfdist_a=texture2D(u_image,v_tex_a).a;float sdfdist_b=texture2D(u_image,v_tex_b).a;float sdfdist=mix(sdfdist_a,sdfdist_b,u_mix);alpha*=smoothstep(0.5-u_sdfgamma/floorwidth,0.5+u_sdfgamma/floorwidth,sdfdist);gl_FragColor=color*(alpha*opacity);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`
|
||
#define scale 0.015873016
|
||
#define LINE_DISTANCE_SCALE 2.0
|
||
attribute vec2 a_pos_normal;attribute vec4 a_data;uniform mat4 u_matrix;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_patternscale_a;uniform float u_tex_y_a;uniform vec2 u_patternscale_b;uniform float u_tex_y_b;uniform vec2 u_units_to_pixels;varying vec2 v_normal;varying vec2 v_width2;varying vec2 v_tex_a;varying vec2 v_tex_b;varying float v_gamma_scale;
|
||
#pragma mapbox: define highp vec4 color
|
||
#pragma mapbox: define lowp float blur
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define mediump float gapwidth
|
||
#pragma mapbox: define lowp float offset
|
||
#pragma mapbox: define mediump float width
|
||
#pragma mapbox: define lowp float floorwidth
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 color
|
||
#pragma mapbox: initialize lowp float blur
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize mediump float gapwidth
|
||
#pragma mapbox: initialize lowp float offset
|
||
#pragma mapbox: initialize mediump float width
|
||
#pragma mapbox: initialize lowp float floorwidth
|
||
float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist/u_ratio,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2/u_ratio,0.0,1.0)+projected_extrude;
|
||
#ifdef TERRAIN3D
|
||
v_gamma_scale=1.0;
|
||
#else
|
||
float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
|
||
#endif
|
||
v_tex_a=vec2(a_linesofar*u_patternscale_a.x/floorwidth,normal.y*u_patternscale_a.y+u_tex_y_a);v_tex_b=vec2(a_linesofar*u_patternscale_b.x/floorwidth,normal.y*u_patternscale_b.y+u_tex_y_b);v_width2=vec2(outset,inset);}`),raster:_i(`uniform float u_fade_t;uniform float u_opacity;uniform sampler2D u_image0;uniform sampler2D u_image1;varying vec2 v_pos0;varying vec2 v_pos1;uniform float u_brightness_low;uniform float u_brightness_high;uniform float u_saturation_factor;uniform float u_contrast_factor;uniform vec3 u_spin_weights;void main() {vec4 color0=texture2D(u_image0,v_pos0);vec4 color1=texture2D(u_image1,v_pos1);if (color0.a > 0.0) {color0.rgb=color0.rgb/color0.a;}if (color1.a > 0.0) {color1.rgb=color1.rgb/color1.a;}vec4 color=mix(color0,color1,u_fade_t);color.a*=u_opacity;vec3 rgb=color.rgb;rgb=vec3(dot(rgb,u_spin_weights.xyz),dot(rgb,u_spin_weights.zxy),dot(rgb,u_spin_weights.yzx));float average=(color.r+color.g+color.b)/3.0;rgb+=(average-rgb)*u_saturation_factor;rgb=(rgb-0.5)*u_contrast_factor+0.5;vec3 u_high_vec=vec3(u_brightness_low,u_brightness_low,u_brightness_low);vec3 u_low_vec=vec3(u_brightness_high,u_brightness_high,u_brightness_high);gl_FragColor=vec4(mix(u_high_vec,u_low_vec,rgb)*color.a,color.a);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,"uniform mat4 u_matrix;uniform vec2 u_tl_parent;uniform float u_scale_parent;uniform float u_buffer_scale;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos0;varying vec2 v_pos1;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos0=(((a_texture_pos/8192.0)-0.5)/u_buffer_scale )+0.5;v_pos1=(v_pos0*u_scale_parent)+u_tl_parent;}"),symbolIcon:_i(`uniform sampler2D u_texture;varying vec2 v_tex;varying float v_fade_opacity;
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float opacity
|
||
lowp float alpha=opacity*v_fade_opacity;gl_FragColor=texture2D(u_texture,v_tex)*alpha;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec4 a_pixeloffset;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform highp float u_camera_to_center_distance;uniform highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform float u_fade_change;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform vec2 u_texsize;varying vec2 v_tex;varying float v_fade_opacity;
|
||
#pragma mapbox: define lowp float opacity
|
||
void main() {
|
||
#pragma mapbox: initialize lowp float opacity
|
||
vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;vec2 a_minFontScale=a_pixeloffset.zw/256.0;float ele=get_elevation(a_pos);highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec4 projectedPoint=u_matrix*vec4(a_pos,ele,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ?
|
||
camera_to_anchor_distance/u_camera_to_center_distance :
|
||
u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),ele,1);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);vec4 projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,ele,1.0);float z=float(u_pitch_with_map)*projected_pos.z/projected_pos.w;gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*max(a_minFontScale,fontScale)+a_pxoffset/16.0),z,1.0);v_tex=a_tex/u_texsize;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float visibility=calculate_visibility(projectedPoint);v_fade_opacity=max(0.0,min(visibility,fade_opacity[0]+fade_change));}`),symbolSDF:_i(`#define SDF_PX 8.0
|
||
uniform bool u_is_halo;uniform sampler2D u_texture;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;uniform bool u_is_text;varying vec2 v_data0;varying vec3 v_data1;
|
||
#pragma mapbox: define highp vec4 fill_color
|
||
#pragma mapbox: define highp vec4 halo_color
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp float halo_width
|
||
#pragma mapbox: define lowp float halo_blur
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 fill_color
|
||
#pragma mapbox: initialize highp vec4 halo_color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize lowp float halo_width
|
||
#pragma mapbox: initialize lowp float halo_blur
|
||
float EDGE_GAMMA=0.105/u_device_pixel_ratio;vec2 tex=v_data0.xy;float gamma_scale=v_data1.x;float size=v_data1.y;float fade_opacity=v_data1[2];float fontScale=u_is_text ? size/24.0 : size;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float inner_edge=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);inner_edge=inner_edge+gamma*gamma_scale;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(inner_edge-gamma_scaled,inner_edge+gamma_scaled,dist);if (u_is_halo) {lowp float halo_edge=(6.0-halo_width/fontScale)/SDF_PX;alpha=min(smoothstep(halo_edge-gamma_scaled,halo_edge+gamma_scaled,dist),1.0-alpha);}gl_FragColor=color*(alpha*opacity*fade_opacity);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec4 a_pixeloffset;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;varying vec2 v_data0;varying vec3 v_data1;
|
||
#pragma mapbox: define highp vec4 fill_color
|
||
#pragma mapbox: define highp vec4 halo_color
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp float halo_width
|
||
#pragma mapbox: define lowp float halo_blur
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 fill_color
|
||
#pragma mapbox: initialize highp vec4 halo_color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize lowp float halo_width
|
||
#pragma mapbox: initialize lowp float halo_blur
|
||
vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;float ele=get_elevation(a_pos);highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec4 projectedPoint=u_matrix*vec4(a_pos,ele,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ?
|
||
camera_to_anchor_distance/u_camera_to_center_distance :
|
||
u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),ele,1);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);vec4 projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,ele,1.0);float z=float(u_pitch_with_map)*projected_pos.z/projected_pos.w;gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale+a_pxoffset),z,1.0);float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float visibility=calculate_visibility(projectedPoint);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(visibility,fade_opacity[0]+fade_change));v_data0=a_tex/u_texsize;v_data1=vec3(gamma_scale,size,interpolated_fade_opacity);}`),symbolTextAndIcon:_i(`#define SDF_PX 8.0
|
||
#define SDF 1.0
|
||
#define ICON 0.0
|
||
uniform bool u_is_halo;uniform sampler2D u_texture;uniform sampler2D u_texture_icon;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;varying vec4 v_data0;varying vec4 v_data1;
|
||
#pragma mapbox: define highp vec4 fill_color
|
||
#pragma mapbox: define highp vec4 halo_color
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp float halo_width
|
||
#pragma mapbox: define lowp float halo_blur
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 fill_color
|
||
#pragma mapbox: initialize highp vec4 halo_color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize lowp float halo_width
|
||
#pragma mapbox: initialize lowp float halo_blur
|
||
float fade_opacity=v_data1[2];if (v_data1.w==ICON) {vec2 tex_icon=v_data0.zw;lowp float alpha=opacity*fade_opacity;gl_FragColor=texture2D(u_texture_icon,tex_icon)*alpha;
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
return;}vec2 tex=v_data0.xy;float EDGE_GAMMA=0.105/u_device_pixel_ratio;float gamma_scale=v_data1.x;float size=v_data1.y;float fontScale=size/24.0;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);
|
||
#ifdef OVERDRAW_INSPECTOR
|
||
gl_FragColor=vec4(1.0);
|
||
#endif
|
||
}`,`const float PI=3.141592653589793;attribute vec4 a_pos_offset;attribute vec4 a_data;attribute vec3 a_projected_pos;attribute float a_fade_opacity;uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;uniform vec2 u_texsize_icon;varying vec4 v_data0;varying vec4 v_data1;
|
||
#pragma mapbox: define highp vec4 fill_color
|
||
#pragma mapbox: define highp vec4 halo_color
|
||
#pragma mapbox: define lowp float opacity
|
||
#pragma mapbox: define lowp float halo_width
|
||
#pragma mapbox: define lowp float halo_blur
|
||
void main() {
|
||
#pragma mapbox: initialize highp vec4 fill_color
|
||
#pragma mapbox: initialize highp vec4 halo_color
|
||
#pragma mapbox: initialize lowp float opacity
|
||
#pragma mapbox: initialize lowp float halo_width
|
||
#pragma mapbox: initialize lowp float halo_blur
|
||
vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);float is_sdf=a_size[0]-2.0*a_size_min;float ele=get_elevation(a_pos);highp float segment_angle=-a_projected_pos[2];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec4 projectedPoint=u_matrix*vec4(a_pos,ele,1);highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ?
|
||
camera_to_anchor_distance/u_camera_to_center_distance :
|
||
u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);size*=perspective_ratio;float fontScale=size/24.0;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=u_matrix*vec4(a_pos+vec2(1,0),ele,1);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);vec4 projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,ele,1.0);float z=float(u_pitch_with_map)*projected_pos.z/projected_pos.w;gl_Position=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale),z,1.0);float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float visibility=calculate_visibility(projectedPoint);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(visibility,fade_opacity[0]+fade_change));v_data0.xy=a_tex/u_texsize;v_data0.zw=a_tex/u_texsize_icon;v_data1=vec4(gamma_scale,size,interpolated_fade_opacity,is_sdf);}`),terrain:_i("uniform sampler2D u_texture;varying vec2 v_texture_pos;void main() {gl_FragColor=texture2D(u_texture,v_texture_pos);}",Cl),terrainDepth:_i("varying float v_depth;const highp vec4 bitSh=vec4(256.*256.*256.,256.*256.,256.,1.);const highp vec4 bitMsk=vec4(0.,vec3(1./256.0));highp vec4 pack(highp float value) {highp vec4 comp=fract(value*bitSh);comp-=comp.xxyz*bitMsk;return comp;}void main() {gl_FragColor=pack(v_depth);}",Cl),terrainCoords:_i("precision mediump float;uniform sampler2D u_texture;uniform float u_terrain_coords_id;varying vec2 v_texture_pos;void main() {vec4 rgba=texture2D(u_texture,v_texture_pos);gl_FragColor=vec4(rgba.r,rgba.g,rgba.b,u_terrain_coords_id);}",Cl)};function _i(O,u){const p=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,C=u.match(/attribute ([\w]+) ([\w]+)/g),M=O.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),I=u.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),L=I?I.concat(M):M,j={};return{fragmentSource:O=O.replace(p,(G,te,Ae,he,Me)=>(j[Me]=!0,te==="define"?`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
varying ${Ae} ${he} ${Me};
|
||
#else
|
||
uniform ${Ae} ${he} u_${Me};
|
||
#endif
|
||
`:`
|
||
#ifdef HAS_UNIFORM_u_${Me}
|
||
${Ae} ${he} ${Me} = u_${Me};
|
||
#endif
|
||
`)),vertexSource:u=u.replace(p,(G,te,Ae,he,Me)=>{const De=he==="float"?"vec2":"vec4",je=Me.match(/color/)?"color":De;return j[Me]?te==="define"?`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
uniform lowp float u_${Me}_t;
|
||
attribute ${Ae} ${De} a_${Me};
|
||
varying ${Ae} ${he} ${Me};
|
||
#else
|
||
uniform ${Ae} ${he} u_${Me};
|
||
#endif
|
||
`:je==="vec4"?`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
${Me} = a_${Me};
|
||
#else
|
||
${Ae} ${he} ${Me} = u_${Me};
|
||
#endif
|
||
`:`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
${Me} = unpack_mix_${je}(a_${Me}, u_${Me}_t);
|
||
#else
|
||
${Ae} ${he} ${Me} = u_${Me};
|
||
#endif
|
||
`:te==="define"?`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
uniform lowp float u_${Me}_t;
|
||
attribute ${Ae} ${De} a_${Me};
|
||
#else
|
||
uniform ${Ae} ${he} u_${Me};
|
||
#endif
|
||
`:je==="vec4"?`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
${Ae} ${he} ${Me} = a_${Me};
|
||
#else
|
||
${Ae} ${he} ${Me} = u_${Me};
|
||
#endif
|
||
`:`
|
||
#ifndef HAS_UNIFORM_u_${Me}
|
||
${Ae} ${he} ${Me} = unpack_mix_${je}(a_${Me}, u_${Me}_t);
|
||
#else
|
||
${Ae} ${he} ${Me} = u_${Me};
|
||
#endif
|
||
`}),staticAttributes:C,staticUniforms:L}}class _l{constructor(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffer=null,this.vao=null}bind(u,p,C,M,I,L,j,G,te){this.context=u;let Ae=this.boundPaintVertexBuffers.length!==M.length;for(let he=0;!Ae&&he<M.length;he++)this.boundPaintVertexBuffers[he]!==M[he]&&(Ae=!0);!this.vao||this.boundProgram!==p||this.boundLayoutVertexBuffer!==C||Ae||this.boundIndexBuffer!==I||this.boundVertexOffset!==L||this.boundDynamicVertexBuffer!==j||this.boundDynamicVertexBuffer2!==G||this.boundDynamicVertexBuffer3!==te?this.freshBind(p,C,M,I,L,j,G,te):(u.bindVertexArray.set(this.vao),j&&j.bind(),I&&I.dynamicDraw&&I.bind(),G&&G.bind(),te&&te.bind())}freshBind(u,p,C,M,I,L,j,G){const te=u.numAttributes,Ae=this.context,he=Ae.gl;this.vao&&this.destroy(),this.vao=Ae.createVertexArray(),Ae.bindVertexArray.set(this.vao),this.boundProgram=u,this.boundLayoutVertexBuffer=p,this.boundPaintVertexBuffers=C,this.boundIndexBuffer=M,this.boundVertexOffset=I,this.boundDynamicVertexBuffer=L,this.boundDynamicVertexBuffer2=j,this.boundDynamicVertexBuffer3=G,p.enableAttributes(he,u);for(const Me of C)Me.enableAttributes(he,u);L&&L.enableAttributes(he,u),j&&j.enableAttributes(he,u),G&&G.enableAttributes(he,u),p.bind(),p.setVertexAttribPointers(he,u,I);for(const Me of C)Me.bind(),Me.setVertexAttribPointers(he,u,I);L&&(L.bind(),L.setVertexAttribPointers(he,u,I)),M&&M.bind(),j&&(j.bind(),j.setVertexAttribPointers(he,u,I)),G&&(G.bind(),G.setVertexAttribPointers(he,u,I)),Ae.currentNumAttributes=te}destroy(){this.vao&&(this.context.deleteVertexArray(this.vao),this.vao=null)}}function Qa(O){const u=[];for(let p=0;p<O.length;p++){if(O[p]===null)continue;const C=O[p].split(" ");u.push(C.pop())}return u}class ys{constructor(u,p,C,M,I,L){const j=u.gl;this.program=j.createProgram();const G=Qa(p.staticAttributes),te=C?C.getBinderAttributes():[],Ae=G.concat(te),he=br.prelude.staticUniforms?Qa(br.prelude.staticUniforms):[],Me=p.staticUniforms?Qa(p.staticUniforms):[],De=C?C.getBinderUniforms():[],je=he.concat(Me).concat(De),Qe=[];for(const Tt of je)Qe.indexOf(Tt)<0&&Qe.push(Tt);const Le=C?C.defines():[];I&&Le.push("#define OVERDRAW_INSPECTOR;"),L&&Le.push("#define TERRAIN3D;");const ft=Le.concat(br.prelude.fragmentSource,p.fragmentSource).join(`
|
||
`),Bt=Le.concat(br.prelude.vertexSource,p.vertexSource).join(`
|
||
`),qe=j.createShader(j.FRAGMENT_SHADER);if(j.isContextLost())return void(this.failedToCreate=!0);if(j.shaderSource(qe,ft),j.compileShader(qe),!j.getShaderParameter(qe,j.COMPILE_STATUS))throw new Error(`Could not compile fragment shader: ${j.getShaderInfoLog(qe)}`);j.attachShader(this.program,qe);const _t=j.createShader(j.VERTEX_SHADER);if(j.isContextLost())return void(this.failedToCreate=!0);if(j.shaderSource(_t,Bt),j.compileShader(_t),!j.getShaderParameter(_t,j.COMPILE_STATUS))throw new Error(`Could not compile vertex shader: ${j.getShaderInfoLog(_t)}`);j.attachShader(this.program,_t),this.attributes={};const Ut={};this.numAttributes=Ae.length;for(let Tt=0;Tt<this.numAttributes;Tt++)Ae[Tt]&&(j.bindAttribLocation(this.program,Tt,Ae[Tt]),this.attributes[Ae[Tt]]=Tt);if(j.linkProgram(this.program),!j.getProgramParameter(this.program,j.LINK_STATUS))throw new Error(`Program failed to link: ${j.getProgramInfoLog(this.program)}`);j.deleteShader(_t),j.deleteShader(qe);for(let Tt=0;Tt<Qe.length;Tt++){const en=Qe[Tt];if(en&&!Ut[en]){const hn=j.getUniformLocation(this.program,en);hn&&(Ut[en]=hn)}}this.fixedUniforms=M(u,Ut),this.terrainUniforms=((Tt,en)=>({u_depth:new a.aG(Tt,en.u_depth),u_terrain:new a.aG(Tt,en.u_terrain),u_terrain_dim:new a.aH(Tt,en.u_terrain_dim),u_terrain_matrix:new a.aI(Tt,en.u_terrain_matrix),u_terrain_unpack:new a.aJ(Tt,en.u_terrain_unpack),u_terrain_exaggeration:new a.aH(Tt,en.u_terrain_exaggeration)}))(u,Ut),this.binderUniforms=C?C.getUniforms(u,Ut):[]}draw(u,p,C,M,I,L,j,G,te,Ae,he,Me,De,je,Qe,Le,ft,Bt){const qe=u.gl;if(this.failedToCreate)return;if(u.program.set(this.program),u.setDepthMode(C),u.setStencilMode(M),u.setColorMode(I),u.setCullFace(L),G){u.activeTexture.set(qe.TEXTURE2),qe.bindTexture(qe.TEXTURE_2D,G.depthTexture),u.activeTexture.set(qe.TEXTURE3),qe.bindTexture(qe.TEXTURE_2D,G.texture);for(const Ut in this.terrainUniforms)this.terrainUniforms[Ut].set(G[Ut])}for(const Ut in this.fixedUniforms)this.fixedUniforms[Ut].set(j[Ut]);Qe&&Qe.setUniforms(u,this.binderUniforms,De,{zoom:je});let _t=0;switch(p){case qe.LINES:_t=2;break;case qe.TRIANGLES:_t=3;break;case qe.LINE_STRIP:_t=1}for(const Ut of Me.get()){const Tt=Ut.vaos||(Ut.vaos={});(Tt[te]||(Tt[te]=new _l)).bind(u,this,Ae,Qe?Qe.getPaintVertexBuffers():[],he,Ut.vertexOffset,Le,ft,Bt),qe.drawElements(p,Ut.primitiveLength*_t,qe.UNSIGNED_SHORT,Ut.primitiveOffset*_t*2)}}}function qs(O,u,p){const C=1/qn(p,1,u.transform.tileZoom),M=Math.pow(2,p.tileID.overscaledZ),I=p.tileSize*Math.pow(2,u.transform.tileZoom)/M,L=I*(p.tileID.canonical.x+p.tileID.wrap*M),j=I*p.tileID.canonical.y;return{u_image:0,u_texsize:p.imageAtlasTexture.size,u_scale:[C,O.fromScale,O.toScale],u_fade:O.t,u_pixel_coord_upper:[L>>16,j>>16],u_pixel_coord_lower:[65535&L,65535&j]}}const Vs=(O,u,p,C)=>{const M=u.style.light,I=M.properties.get("position"),L=[I.x,I.y,I.z],j=function(){var te=new a.A(9);return a.A!=Float32Array&&(te[1]=0,te[2]=0,te[3]=0,te[5]=0,te[6]=0,te[7]=0),te[0]=1,te[4]=1,te[8]=1,te}();M.properties.get("anchor")==="viewport"&&function(te,Ae){var he=Math.sin(Ae),Me=Math.cos(Ae);te[0]=Me,te[1]=he,te[2]=0,te[3]=-he,te[4]=Me,te[5]=0,te[6]=0,te[7]=0,te[8]=1}(j,-u.transform.angle),function(te,Ae,he){var Me=Ae[0],De=Ae[1],je=Ae[2];te[0]=Me*he[0]+De*he[3]+je*he[6],te[1]=Me*he[1]+De*he[4]+je*he[7],te[2]=Me*he[2]+De*he[5]+je*he[8]}(L,L,j);const G=M.properties.get("color");return{u_matrix:O,u_lightpos:L,u_lightintensity:M.properties.get("intensity"),u_lightcolor:[G.r,G.g,G.b],u_vertical_gradient:+p,u_opacity:C}},va=(O,u,p,C,M,I,L)=>a.e(Vs(O,u,p,C),qs(I,u,L),{u_height_factor:-Math.pow(2,M.overscaledZ)/L.tileSize/8}),$a=O=>({u_matrix:O}),ll=(O,u,p,C)=>a.e($a(O),qs(p,u,C)),xu=(O,u)=>({u_matrix:O,u_world:u}),bl=(O,u,p,C,M)=>a.e(ll(O,u,p,C),{u_world:M}),CA=(O,u,p,C)=>{const M=O.transform;let I,L;if(C.paint.get("circle-pitch-alignment")==="map"){const j=qn(p,1,M.zoom);I=!0,L=[j,j]}else I=!1,L=M.pixelsToGLUnits;return{u_camera_to_center_distance:M.cameraToCenterDistance,u_scale_with_map:+(C.paint.get("circle-pitch-scale")==="map"),u_matrix:O.translatePosMatrix(u.posMatrix,p,C.paint.get("circle-translate"),C.paint.get("circle-translate-anchor")),u_pitch_with_map:+I,u_device_pixel_ratio:O.pixelRatio,u_extrude_scale:L}},HA=(O,u,p)=>{const C=qn(p,1,u.zoom),M=Math.pow(2,u.zoom-p.tileID.overscaledZ),I=p.tileID.overscaleFactor();return{u_matrix:O,u_camera_to_center_distance:u.cameraToCenterDistance,u_pixels_to_tile_units:C,u_extrude_scale:[u.pixelsToGLUnits[0]/(C*M),u.pixelsToGLUnits[1]/(C*M)],u_overscale_factor:I}},Hu=(O,u,p=1)=>({u_matrix:O,u_color:u,u_overlay:0,u_overlay_scale:p}),ZA=O=>({u_matrix:O}),_A=(O,u,p,C)=>({u_matrix:O,u_extrude_scale:qn(u,1,p),u_intensity:C});function Ya(O,u){const p=Math.pow(2,u.canonical.z),C=u.canonical.y;return[new a.Y(0,C/p).toLngLat().lat,new a.Y(0,(C+1)/p).toLngLat().lat]}const vs=(O,u,p,C)=>{const M=O.transform;return{u_matrix:Cs(O,u,p,C),u_ratio:1/qn(u,1,M.zoom),u_device_pixel_ratio:O.pixelRatio,u_units_to_pixels:[1/M.pixelsToGLUnits[0],1/M.pixelsToGLUnits[1]]}},bA=(O,u,p,C,M)=>a.e(vs(O,u,p,M),{u_image:0,u_image_height:C}),Zu=(O,u,p,C,M)=>{const I=O.transform,L=Us(u,I);return{u_matrix:Cs(O,u,p,M),u_texsize:u.imageAtlasTexture.size,u_ratio:1/qn(u,1,I.zoom),u_device_pixel_ratio:O.pixelRatio,u_image:0,u_scale:[L,C.fromScale,C.toScale],u_fade:C.t,u_units_to_pixels:[1/I.pixelsToGLUnits[0],1/I.pixelsToGLUnits[1]]}},Ds=(O,u,p,C,M,I)=>{const L=O.lineAtlas,j=Us(u,O.transform),G=p.layout.get("line-cap")==="round",te=L.getDash(C.from,G),Ae=L.getDash(C.to,G),he=te.width*M.fromScale,Me=Ae.width*M.toScale;return a.e(vs(O,u,p,I),{u_patternscale_a:[j/he,-te.height/2],u_patternscale_b:[j/Me,-Ae.height/2],u_sdfgamma:L.width/(256*Math.min(he,Me)*O.pixelRatio)/2,u_image:0,u_tex_y_a:te.y,u_tex_y_b:Ae.y,u_mix:M.t})};function Us(O,u){return 1/qn(O,1,u.tileZoom)}function Cs(O,u,p,C){return O.translatePosMatrix(C?C.posMatrix:u.tileID.posMatrix,u,p.paint.get("line-translate"),p.paint.get("line-translate-anchor"))}const lu=(O,u,p,C,M)=>{return{u_matrix:O,u_tl_parent:u,u_scale_parent:p,u_buffer_scale:1,u_fade_t:C.mix,u_opacity:C.opacity*M.paint.get("raster-opacity"),u_image0:0,u_image1:1,u_brightness_low:M.paint.get("raster-brightness-min"),u_brightness_high:M.paint.get("raster-brightness-max"),u_saturation_factor:(L=M.paint.get("raster-saturation"),L>0?1-1/(1.001-L):-L),u_contrast_factor:(I=M.paint.get("raster-contrast"),I>0?1/(1-I):1+I),u_spin_weights:wu(M.paint.get("raster-hue-rotate"))};var I,L};function wu(O){O*=Math.PI/180;const u=Math.sin(O),p=Math.cos(O);return[(2*p+1)/3,(-Math.sqrt(3)*u-p+1)/3,(Math.sqrt(3)*u-p+1)/3]}const uu=(O,u,p,C,M,I,L,j,G,te)=>{const Ae=M.transform;return{u_is_size_zoom_constant:+(O==="constant"||O==="source"),u_is_size_feature_constant:+(O==="constant"||O==="camera"),u_size_t:u?u.uSizeT:0,u_size:u?u.uSize:0,u_camera_to_center_distance:Ae.cameraToCenterDistance,u_pitch:Ae.pitch/360*2*Math.PI,u_rotate_symbol:+p,u_aspect_ratio:Ae.width/Ae.height,u_fade_change:M.options.fadeDuration?M.symbolFadeChange:1,u_matrix:I,u_label_plane_matrix:L,u_coord_matrix:j,u_is_text:+G,u_pitch_with_map:+C,u_texsize:te,u_texture:0}},as=(O,u,p,C,M,I,L,j,G,te,Ae)=>{const he=M.transform;return a.e(uu(O,u,p,C,M,I,L,j,G,te),{u_gamma_scale:C?Math.cos(he._pitch)*he.cameraToCenterDistance:1,u_device_pixel_ratio:M.pixelRatio,u_is_halo:+Ae})},Mu=(O,u,p,C,M,I,L,j,G,te)=>a.e(as(O,u,p,C,M,I,L,j,!0,G,!0),{u_texsize_icon:te,u_texture_icon:1}),Au=(O,u,p)=>({u_matrix:O,u_opacity:u,u_color:p}),bo=(O,u,p,C,M,I)=>a.e(function(L,j,G,te){const Ae=G.imageManager.getPattern(L.from.toString()),he=G.imageManager.getPattern(L.to.toString()),{width:Me,height:De}=G.imageManager.getPixelSize(),je=Math.pow(2,te.tileID.overscaledZ),Qe=te.tileSize*Math.pow(2,G.transform.tileZoom)/je,Le=Qe*(te.tileID.canonical.x+te.tileID.wrap*je),ft=Qe*te.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:Ae.tl,u_pattern_br_a:Ae.br,u_pattern_tl_b:he.tl,u_pattern_br_b:he.br,u_texsize:[Me,De],u_mix:j.t,u_pattern_size_a:Ae.displaySize,u_pattern_size_b:he.displaySize,u_scale_a:j.fromScale,u_scale_b:j.toScale,u_tile_units_to_pixels:1/qn(te,1,G.transform.tileZoom),u_pixel_coord_upper:[Le>>16,ft>>16],u_pixel_coord_lower:[65535&Le,65535&ft]}}(C,I,p,M),{u_matrix:O,u_opacity:u}),mo={fillExtrusion:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_lightpos:new a.aK(O,u.u_lightpos),u_lightintensity:new a.aH(O,u.u_lightintensity),u_lightcolor:new a.aK(O,u.u_lightcolor),u_vertical_gradient:new a.aH(O,u.u_vertical_gradient),u_opacity:new a.aH(O,u.u_opacity)}),fillExtrusionPattern:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_lightpos:new a.aK(O,u.u_lightpos),u_lightintensity:new a.aH(O,u.u_lightintensity),u_lightcolor:new a.aK(O,u.u_lightcolor),u_vertical_gradient:new a.aH(O,u.u_vertical_gradient),u_height_factor:new a.aH(O,u.u_height_factor),u_image:new a.aG(O,u.u_image),u_texsize:new a.aL(O,u.u_texsize),u_pixel_coord_upper:new a.aL(O,u.u_pixel_coord_upper),u_pixel_coord_lower:new a.aL(O,u.u_pixel_coord_lower),u_scale:new a.aK(O,u.u_scale),u_fade:new a.aH(O,u.u_fade),u_opacity:new a.aH(O,u.u_opacity)}),fill:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix)}),fillPattern:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_image:new a.aG(O,u.u_image),u_texsize:new a.aL(O,u.u_texsize),u_pixel_coord_upper:new a.aL(O,u.u_pixel_coord_upper),u_pixel_coord_lower:new a.aL(O,u.u_pixel_coord_lower),u_scale:new a.aK(O,u.u_scale),u_fade:new a.aH(O,u.u_fade)}),fillOutline:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_world:new a.aL(O,u.u_world)}),fillOutlinePattern:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_world:new a.aL(O,u.u_world),u_image:new a.aG(O,u.u_image),u_texsize:new a.aL(O,u.u_texsize),u_pixel_coord_upper:new a.aL(O,u.u_pixel_coord_upper),u_pixel_coord_lower:new a.aL(O,u.u_pixel_coord_lower),u_scale:new a.aK(O,u.u_scale),u_fade:new a.aH(O,u.u_fade)}),circle:(O,u)=>({u_camera_to_center_distance:new a.aH(O,u.u_camera_to_center_distance),u_scale_with_map:new a.aG(O,u.u_scale_with_map),u_pitch_with_map:new a.aG(O,u.u_pitch_with_map),u_extrude_scale:new a.aL(O,u.u_extrude_scale),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_matrix:new a.aI(O,u.u_matrix)}),collisionBox:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_camera_to_center_distance:new a.aH(O,u.u_camera_to_center_distance),u_pixels_to_tile_units:new a.aH(O,u.u_pixels_to_tile_units),u_extrude_scale:new a.aL(O,u.u_extrude_scale),u_overscale_factor:new a.aH(O,u.u_overscale_factor)}),collisionCircle:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_inv_matrix:new a.aI(O,u.u_inv_matrix),u_camera_to_center_distance:new a.aH(O,u.u_camera_to_center_distance),u_viewport_size:new a.aL(O,u.u_viewport_size)}),debug:(O,u)=>({u_color:new a.aM(O,u.u_color),u_matrix:new a.aI(O,u.u_matrix),u_overlay:new a.aG(O,u.u_overlay),u_overlay_scale:new a.aH(O,u.u_overlay_scale)}),clippingMask:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix)}),heatmap:(O,u)=>({u_extrude_scale:new a.aH(O,u.u_extrude_scale),u_intensity:new a.aH(O,u.u_intensity),u_matrix:new a.aI(O,u.u_matrix)}),heatmapTexture:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_world:new a.aL(O,u.u_world),u_image:new a.aG(O,u.u_image),u_color_ramp:new a.aG(O,u.u_color_ramp),u_opacity:new a.aH(O,u.u_opacity)}),hillshade:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_image:new a.aG(O,u.u_image),u_latrange:new a.aL(O,u.u_latrange),u_light:new a.aL(O,u.u_light),u_shadow:new a.aM(O,u.u_shadow),u_highlight:new a.aM(O,u.u_highlight),u_accent:new a.aM(O,u.u_accent)}),hillshadePrepare:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_image:new a.aG(O,u.u_image),u_dimension:new a.aL(O,u.u_dimension),u_zoom:new a.aH(O,u.u_zoom),u_unpack:new a.aJ(O,u.u_unpack)}),line:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_ratio:new a.aH(O,u.u_ratio),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_units_to_pixels:new a.aL(O,u.u_units_to_pixels)}),lineGradient:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_ratio:new a.aH(O,u.u_ratio),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_units_to_pixels:new a.aL(O,u.u_units_to_pixels),u_image:new a.aG(O,u.u_image),u_image_height:new a.aH(O,u.u_image_height)}),linePattern:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_texsize:new a.aL(O,u.u_texsize),u_ratio:new a.aH(O,u.u_ratio),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_image:new a.aG(O,u.u_image),u_units_to_pixels:new a.aL(O,u.u_units_to_pixels),u_scale:new a.aK(O,u.u_scale),u_fade:new a.aH(O,u.u_fade)}),lineSDF:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_ratio:new a.aH(O,u.u_ratio),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_units_to_pixels:new a.aL(O,u.u_units_to_pixels),u_patternscale_a:new a.aL(O,u.u_patternscale_a),u_patternscale_b:new a.aL(O,u.u_patternscale_b),u_sdfgamma:new a.aH(O,u.u_sdfgamma),u_image:new a.aG(O,u.u_image),u_tex_y_a:new a.aH(O,u.u_tex_y_a),u_tex_y_b:new a.aH(O,u.u_tex_y_b),u_mix:new a.aH(O,u.u_mix)}),raster:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_tl_parent:new a.aL(O,u.u_tl_parent),u_scale_parent:new a.aH(O,u.u_scale_parent),u_buffer_scale:new a.aH(O,u.u_buffer_scale),u_fade_t:new a.aH(O,u.u_fade_t),u_opacity:new a.aH(O,u.u_opacity),u_image0:new a.aG(O,u.u_image0),u_image1:new a.aG(O,u.u_image1),u_brightness_low:new a.aH(O,u.u_brightness_low),u_brightness_high:new a.aH(O,u.u_brightness_high),u_saturation_factor:new a.aH(O,u.u_saturation_factor),u_contrast_factor:new a.aH(O,u.u_contrast_factor),u_spin_weights:new a.aK(O,u.u_spin_weights)}),symbolIcon:(O,u)=>({u_is_size_zoom_constant:new a.aG(O,u.u_is_size_zoom_constant),u_is_size_feature_constant:new a.aG(O,u.u_is_size_feature_constant),u_size_t:new a.aH(O,u.u_size_t),u_size:new a.aH(O,u.u_size),u_camera_to_center_distance:new a.aH(O,u.u_camera_to_center_distance),u_pitch:new a.aH(O,u.u_pitch),u_rotate_symbol:new a.aG(O,u.u_rotate_symbol),u_aspect_ratio:new a.aH(O,u.u_aspect_ratio),u_fade_change:new a.aH(O,u.u_fade_change),u_matrix:new a.aI(O,u.u_matrix),u_label_plane_matrix:new a.aI(O,u.u_label_plane_matrix),u_coord_matrix:new a.aI(O,u.u_coord_matrix),u_is_text:new a.aG(O,u.u_is_text),u_pitch_with_map:new a.aG(O,u.u_pitch_with_map),u_texsize:new a.aL(O,u.u_texsize),u_texture:new a.aG(O,u.u_texture)}),symbolSDF:(O,u)=>({u_is_size_zoom_constant:new a.aG(O,u.u_is_size_zoom_constant),u_is_size_feature_constant:new a.aG(O,u.u_is_size_feature_constant),u_size_t:new a.aH(O,u.u_size_t),u_size:new a.aH(O,u.u_size),u_camera_to_center_distance:new a.aH(O,u.u_camera_to_center_distance),u_pitch:new a.aH(O,u.u_pitch),u_rotate_symbol:new a.aG(O,u.u_rotate_symbol),u_aspect_ratio:new a.aH(O,u.u_aspect_ratio),u_fade_change:new a.aH(O,u.u_fade_change),u_matrix:new a.aI(O,u.u_matrix),u_label_plane_matrix:new a.aI(O,u.u_label_plane_matrix),u_coord_matrix:new a.aI(O,u.u_coord_matrix),u_is_text:new a.aG(O,u.u_is_text),u_pitch_with_map:new a.aG(O,u.u_pitch_with_map),u_texsize:new a.aL(O,u.u_texsize),u_texture:new a.aG(O,u.u_texture),u_gamma_scale:new a.aH(O,u.u_gamma_scale),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_is_halo:new a.aG(O,u.u_is_halo)}),symbolTextAndIcon:(O,u)=>({u_is_size_zoom_constant:new a.aG(O,u.u_is_size_zoom_constant),u_is_size_feature_constant:new a.aG(O,u.u_is_size_feature_constant),u_size_t:new a.aH(O,u.u_size_t),u_size:new a.aH(O,u.u_size),u_camera_to_center_distance:new a.aH(O,u.u_camera_to_center_distance),u_pitch:new a.aH(O,u.u_pitch),u_rotate_symbol:new a.aG(O,u.u_rotate_symbol),u_aspect_ratio:new a.aH(O,u.u_aspect_ratio),u_fade_change:new a.aH(O,u.u_fade_change),u_matrix:new a.aI(O,u.u_matrix),u_label_plane_matrix:new a.aI(O,u.u_label_plane_matrix),u_coord_matrix:new a.aI(O,u.u_coord_matrix),u_is_text:new a.aG(O,u.u_is_text),u_pitch_with_map:new a.aG(O,u.u_pitch_with_map),u_texsize:new a.aL(O,u.u_texsize),u_texsize_icon:new a.aL(O,u.u_texsize_icon),u_texture:new a.aG(O,u.u_texture),u_texture_icon:new a.aG(O,u.u_texture_icon),u_gamma_scale:new a.aH(O,u.u_gamma_scale),u_device_pixel_ratio:new a.aH(O,u.u_device_pixel_ratio),u_is_halo:new a.aG(O,u.u_is_halo)}),background:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_opacity:new a.aH(O,u.u_opacity),u_color:new a.aM(O,u.u_color)}),backgroundPattern:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_opacity:new a.aH(O,u.u_opacity),u_image:new a.aG(O,u.u_image),u_pattern_tl_a:new a.aL(O,u.u_pattern_tl_a),u_pattern_br_a:new a.aL(O,u.u_pattern_br_a),u_pattern_tl_b:new a.aL(O,u.u_pattern_tl_b),u_pattern_br_b:new a.aL(O,u.u_pattern_br_b),u_texsize:new a.aL(O,u.u_texsize),u_mix:new a.aH(O,u.u_mix),u_pattern_size_a:new a.aL(O,u.u_pattern_size_a),u_pattern_size_b:new a.aL(O,u.u_pattern_size_b),u_scale_a:new a.aH(O,u.u_scale_a),u_scale_b:new a.aH(O,u.u_scale_b),u_pixel_coord_upper:new a.aL(O,u.u_pixel_coord_upper),u_pixel_coord_lower:new a.aL(O,u.u_pixel_coord_lower),u_tile_units_to_pixels:new a.aH(O,u.u_tile_units_to_pixels)}),terrain:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_texture:new a.aG(O,u.u_texture),u_ele_delta:new a.aH(O,u.u_ele_delta)}),terrainDepth:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_ele_delta:new a.aH(O,u.u_ele_delta)}),terrainCoords:(O,u)=>({u_matrix:new a.aI(O,u.u_matrix),u_texture:new a.aG(O,u.u_texture),u_terrain_coords_id:new a.aH(O,u.u_terrain_coords_id),u_ele_delta:new a.aH(O,u.u_ele_delta)})};class ee{constructor(u,p,C){this.context=u;const M=u.gl;this.buffer=M.createBuffer(),this.dynamicDraw=!!C,this.context.unbindVAO(),u.bindElementBuffer.set(this.buffer),M.bufferData(M.ELEMENT_ARRAY_BUFFER,p.arrayBuffer,this.dynamicDraw?M.DYNAMIC_DRAW:M.STATIC_DRAW),this.dynamicDraw||delete p.arrayBuffer}bind(){this.context.bindElementBuffer.set(this.buffer)}updateData(u){const p=this.context.gl;if(!this.dynamicDraw)throw new Error("Attempted to update data while not in dynamic mode.");this.context.unbindVAO(),this.bind(),p.bufferSubData(p.ELEMENT_ARRAY_BUFFER,0,u.arrayBuffer)}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}const Ie={Int8:"BYTE",Uint8:"UNSIGNED_BYTE",Int16:"SHORT",Uint16:"UNSIGNED_SHORT",Int32:"INT",Uint32:"UNSIGNED_INT",Float32:"FLOAT"};class st{constructor(u,p,C,M){this.length=p.length,this.attributes=C,this.itemSize=p.bytesPerElement,this.dynamicDraw=M,this.context=u;const I=u.gl;this.buffer=I.createBuffer(),u.bindVertexBuffer.set(this.buffer),I.bufferData(I.ARRAY_BUFFER,p.arrayBuffer,this.dynamicDraw?I.DYNAMIC_DRAW:I.STATIC_DRAW),this.dynamicDraw||delete p.arrayBuffer}bind(){this.context.bindVertexBuffer.set(this.buffer)}updateData(u){if(u.length!==this.length)throw new Error(`Length of new data is ${u.length}, which doesn't match current length of ${this.length}`);const p=this.context.gl;this.bind(),p.bufferSubData(p.ARRAY_BUFFER,0,u.arrayBuffer)}enableAttributes(u,p){for(let C=0;C<this.attributes.length;C++){const M=p.attributes[this.attributes[C].name];M!==void 0&&u.enableVertexAttribArray(M)}}setVertexAttribPointers(u,p,C){for(let M=0;M<this.attributes.length;M++){const I=this.attributes[M],L=p.attributes[I.name];L!==void 0&&u.vertexAttribPointer(L,I.components,u[Ie[I.type]],!1,this.itemSize,I.offset+this.itemSize*(C||0))}}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}const Xt=new WeakMap;function Sr(O){var u;if(Xt.has(O))return Xt.get(O);{const p=(u=O.getParameter(O.VERSION))===null||u===void 0?void 0:u.startsWith("WebGL 2.0");return Xt.set(O,p),p}}class _n{constructor(u){this.gl=u.gl,this.default=this.getDefault(),this.current=this.default,this.dirty=!1}get(){return this.current}set(u){}getDefault(){return this.default}setDefault(){this.set(this.default)}}class Si extends _n{getDefault(){return a.aO.transparent}set(u){const p=this.current;(u.r!==p.r||u.g!==p.g||u.b!==p.b||u.a!==p.a||this.dirty)&&(this.gl.clearColor(u.r,u.g,u.b,u.a),this.current=u,this.dirty=!1)}}class Ki extends _n{getDefault(){return 1}set(u){(u!==this.current||this.dirty)&&(this.gl.clearDepth(u),this.current=u,this.dirty=!1)}}class qr extends _n{getDefault(){return 0}set(u){(u!==this.current||this.dirty)&&(this.gl.clearStencil(u),this.current=u,this.dirty=!1)}}class Yi extends _n{getDefault(){return[!0,!0,!0,!0]}set(u){const p=this.current;(u[0]!==p[0]||u[1]!==p[1]||u[2]!==p[2]||u[3]!==p[3]||this.dirty)&&(this.gl.colorMask(u[0],u[1],u[2],u[3]),this.current=u,this.dirty=!1)}}class qo extends _n{getDefault(){return!0}set(u){(u!==this.current||this.dirty)&&(this.gl.depthMask(u),this.current=u,this.dirty=!1)}}class Ca extends _n{getDefault(){return 255}set(u){(u!==this.current||this.dirty)&&(this.gl.stencilMask(u),this.current=u,this.dirty=!1)}}class Vo extends _n{getDefault(){return{func:this.gl.ALWAYS,ref:0,mask:255}}set(u){const p=this.current;(u.func!==p.func||u.ref!==p.ref||u.mask!==p.mask||this.dirty)&&(this.gl.stencilFunc(u.func,u.ref,u.mask),this.current=u,this.dirty=!1)}}class Li extends _n{getDefault(){const u=this.gl;return[u.KEEP,u.KEEP,u.KEEP]}set(u){const p=this.current;(u[0]!==p[0]||u[1]!==p[1]||u[2]!==p[2]||this.dirty)&&(this.gl.stencilOp(u[0],u[1],u[2]),this.current=u,this.dirty=!1)}}class Xo extends _n{getDefault(){return!1}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;u?p.enable(p.STENCIL_TEST):p.disable(p.STENCIL_TEST),this.current=u,this.dirty=!1}}class Pa extends _n{getDefault(){return[0,1]}set(u){const p=this.current;(u[0]!==p[0]||u[1]!==p[1]||this.dirty)&&(this.gl.depthRange(u[0],u[1]),this.current=u,this.dirty=!1)}}class Rs extends _n{getDefault(){return!1}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;u?p.enable(p.DEPTH_TEST):p.disable(p.DEPTH_TEST),this.current=u,this.dirty=!1}}class _s extends _n{getDefault(){return this.gl.LESS}set(u){(u!==this.current||this.dirty)&&(this.gl.depthFunc(u),this.current=u,this.dirty=!1)}}class Su extends _n{getDefault(){return!1}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;u?p.enable(p.BLEND):p.disable(p.BLEND),this.current=u,this.dirty=!1}}class XA extends _n{getDefault(){const u=this.gl;return[u.ONE,u.ZERO]}set(u){const p=this.current;(u[0]!==p[0]||u[1]!==p[1]||this.dirty)&&(this.gl.blendFunc(u[0],u[1]),this.current=u,this.dirty=!1)}}class ss extends _n{getDefault(){return a.aO.transparent}set(u){const p=this.current;(u.r!==p.r||u.g!==p.g||u.b!==p.b||u.a!==p.a||this.dirty)&&(this.gl.blendColor(u.r,u.g,u.b,u.a),this.current=u,this.dirty=!1)}}class jm extends _n{getDefault(){return this.gl.FUNC_ADD}set(u){(u!==this.current||this.dirty)&&(this.gl.blendEquation(u),this.current=u,this.dirty=!1)}}class $l extends _n{getDefault(){return!1}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;u?p.enable(p.CULL_FACE):p.disable(p.CULL_FACE),this.current=u,this.dirty=!1}}class Bp extends _n{getDefault(){return this.gl.BACK}set(u){(u!==this.current||this.dirty)&&(this.gl.cullFace(u),this.current=u,this.dirty=!1)}}class Id extends _n{getDefault(){return this.gl.CCW}set(u){(u!==this.current||this.dirty)&&(this.gl.frontFace(u),this.current=u,this.dirty=!1)}}class cu extends _n{getDefault(){return null}set(u){(u!==this.current||this.dirty)&&(this.gl.useProgram(u),this.current=u,this.dirty=!1)}}class Gc extends _n{getDefault(){return this.gl.TEXTURE0}set(u){(u!==this.current||this.dirty)&&(this.gl.activeTexture(u),this.current=u,this.dirty=!1)}}class Td extends _n{getDefault(){const u=this.gl;return[0,0,u.drawingBufferWidth,u.drawingBufferHeight]}set(u){const p=this.current;(u[0]!==p[0]||u[1]!==p[1]||u[2]!==p[2]||u[3]!==p[3]||this.dirty)&&(this.gl.viewport(u[0],u[1],u[2],u[3]),this.current=u,this.dirty=!1)}}class Mo extends _n{getDefault(){return null}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.bindFramebuffer(p.FRAMEBUFFER,u),this.current=u,this.dirty=!1}}class Eu extends _n{getDefault(){return null}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.bindRenderbuffer(p.RENDERBUFFER,u),this.current=u,this.dirty=!1}}class yh extends _n{getDefault(){return null}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.bindTexture(p.TEXTURE_2D,u),this.current=u,this.dirty=!1}}class vh extends _n{getDefault(){return null}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.bindBuffer(p.ARRAY_BUFFER,u),this.current=u,this.dirty=!1}}class Yl extends _n{getDefault(){return null}set(u){const p=this.gl;p.bindBuffer(p.ELEMENT_ARRAY_BUFFER,u),this.current=u,this.dirty=!1}}class JA extends _n{getDefault(){return null}set(u){var p;if(u===this.current&&!this.dirty)return;const C=this.gl;Sr(C)?C.bindVertexArray(u):(p=C.getExtension("OES_vertex_array_object"))===null||p===void 0||p.bindVertexArrayOES(u),this.current=u,this.dirty=!1}}class Qc extends _n{getDefault(){return 4}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.pixelStorei(p.UNPACK_ALIGNMENT,u),this.current=u,this.dirty=!1}}class $c extends _n{getDefault(){return!1}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.pixelStorei(p.UNPACK_PREMULTIPLY_ALPHA_WEBGL,u),this.current=u,this.dirty=!1}}class xf extends _n{getDefault(){return!1}set(u){if(u===this.current&&!this.dirty)return;const p=this.gl;p.pixelStorei(p.UNPACK_FLIP_Y_WEBGL,u),this.current=u,this.dirty=!1}}class ql extends _n{constructor(u,p){super(u),this.context=u,this.parent=p}getDefault(){return null}}class Ur extends ql{setDirty(){this.dirty=!0}set(u){if(u===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const p=this.gl;p.framebufferTexture2D(p.FRAMEBUFFER,p.COLOR_ATTACHMENT0,p.TEXTURE_2D,u,0),this.current=u,this.dirty=!1}}class Ch extends ql{set(u){if(u===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const p=this.gl;p.framebufferRenderbuffer(p.FRAMEBUFFER,p.DEPTH_ATTACHMENT,p.RENDERBUFFER,u),this.current=u,this.dirty=!1}}class wf extends ql{set(u){if(u===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const p=this.gl;p.framebufferRenderbuffer(p.FRAMEBUFFER,p.DEPTH_STENCIL_ATTACHMENT,p.RENDERBUFFER,u),this.current=u,this.dirty=!1}}class ec{constructor(u,p,C,M,I){this.context=u,this.width=p,this.height=C;const L=u.gl,j=this.framebuffer=L.createFramebuffer();if(this.colorAttachment=new Ur(u,j),M)this.depthAttachment=I?new wf(u,j):new Ch(u,j);else if(I)throw new Error("Stencil cannot be set without depth");if(L.checkFramebufferStatus(L.FRAMEBUFFER)!==L.FRAMEBUFFER_COMPLETE)throw new Error("Framebuffer is not complete")}destroy(){const u=this.context.gl,p=this.colorAttachment.get();if(p&&u.deleteTexture(p),this.depthAttachment){const C=this.depthAttachment.get();C&&u.deleteRenderbuffer(C)}u.deleteFramebuffer(this.framebuffer)}}class Ro{constructor(u,p,C){this.blendFunction=u,this.blendColor=p,this.mask=C}}Ro.Replace=[1,0],Ro.disabled=new Ro(Ro.Replace,a.aO.transparent,[!1,!1,!1,!1]),Ro.unblended=new Ro(Ro.Replace,a.aO.transparent,[!0,!0,!0,!0]),Ro.alphaBlended=new Ro([1,771],a.aO.transparent,[!0,!0,!0,!0]);class _h{constructor(u){var p,C;if(this.gl=u,this.clearColor=new Si(this),this.clearDepth=new Ki(this),this.clearStencil=new qr(this),this.colorMask=new Yi(this),this.depthMask=new qo(this),this.stencilMask=new Ca(this),this.stencilFunc=new Vo(this),this.stencilOp=new Li(this),this.stencilTest=new Xo(this),this.depthRange=new Pa(this),this.depthTest=new Rs(this),this.depthFunc=new _s(this),this.blend=new Su(this),this.blendFunc=new XA(this),this.blendColor=new ss(this),this.blendEquation=new jm(this),this.cullFace=new $l(this),this.cullFaceSide=new Bp(this),this.frontFace=new Id(this),this.program=new cu(this),this.activeTexture=new Gc(this),this.viewport=new Td(this),this.bindFramebuffer=new Mo(this),this.bindRenderbuffer=new Eu(this),this.bindTexture=new yh(this),this.bindVertexBuffer=new vh(this),this.bindElementBuffer=new Yl(this),this.bindVertexArray=new JA(this),this.pixelStoreUnpack=new Qc(this),this.pixelStoreUnpackPremultiplyAlpha=new $c(this),this.pixelStoreUnpackFlipY=new xf(this),this.extTextureFilterAnisotropic=u.getExtension("EXT_texture_filter_anisotropic")||u.getExtension("MOZ_EXT_texture_filter_anisotropic")||u.getExtension("WEBKIT_EXT_texture_filter_anisotropic"),this.extTextureFilterAnisotropic&&(this.extTextureFilterAnisotropicMax=u.getParameter(this.extTextureFilterAnisotropic.MAX_TEXTURE_MAX_ANISOTROPY_EXT)),this.maxTextureSize=u.getParameter(u.MAX_TEXTURE_SIZE),Sr(u)){this.HALF_FLOAT=u.HALF_FLOAT;const M=u.getExtension("EXT_color_buffer_half_float");this.RGBA16F=(p=u.RGBA16F)!==null&&p!==void 0?p:M==null?void 0:M.RGBA16F_EXT,this.RGB16F=(C=u.RGB16F)!==null&&C!==void 0?C:M==null?void 0:M.RGB16F_EXT,u.getExtension("EXT_color_buffer_float")}else{u.getExtension("EXT_color_buffer_half_float"),u.getExtension("OES_texture_half_float_linear");const M=u.getExtension("OES_texture_half_float");this.HALF_FLOAT=M==null?void 0:M.HALF_FLOAT_OES}}setDefault(){this.unbindVAO(),this.clearColor.setDefault(),this.clearDepth.setDefault(),this.clearStencil.setDefault(),this.colorMask.setDefault(),this.depthMask.setDefault(),this.stencilMask.setDefault(),this.stencilFunc.setDefault(),this.stencilOp.setDefault(),this.stencilTest.setDefault(),this.depthRange.setDefault(),this.depthTest.setDefault(),this.depthFunc.setDefault(),this.blend.setDefault(),this.blendFunc.setDefault(),this.blendColor.setDefault(),this.blendEquation.setDefault(),this.cullFace.setDefault(),this.cullFaceSide.setDefault(),this.frontFace.setDefault(),this.program.setDefault(),this.activeTexture.setDefault(),this.bindFramebuffer.setDefault(),this.pixelStoreUnpack.setDefault(),this.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.pixelStoreUnpackFlipY.setDefault()}setDirty(){this.clearColor.dirty=!0,this.clearDepth.dirty=!0,this.clearStencil.dirty=!0,this.colorMask.dirty=!0,this.depthMask.dirty=!0,this.stencilMask.dirty=!0,this.stencilFunc.dirty=!0,this.stencilOp.dirty=!0,this.stencilTest.dirty=!0,this.depthRange.dirty=!0,this.depthTest.dirty=!0,this.depthFunc.dirty=!0,this.blend.dirty=!0,this.blendFunc.dirty=!0,this.blendColor.dirty=!0,this.blendEquation.dirty=!0,this.cullFace.dirty=!0,this.cullFaceSide.dirty=!0,this.frontFace.dirty=!0,this.program.dirty=!0,this.activeTexture.dirty=!0,this.viewport.dirty=!0,this.bindFramebuffer.dirty=!0,this.bindRenderbuffer.dirty=!0,this.bindTexture.dirty=!0,this.bindVertexBuffer.dirty=!0,this.bindElementBuffer.dirty=!0,this.bindVertexArray.dirty=!0,this.pixelStoreUnpack.dirty=!0,this.pixelStoreUnpackPremultiplyAlpha.dirty=!0,this.pixelStoreUnpackFlipY.dirty=!0}createIndexBuffer(u,p){return new ee(this,u,p)}createVertexBuffer(u,p,C){return new st(this,u,p,C)}createRenderbuffer(u,p,C){const M=this.gl,I=M.createRenderbuffer();return this.bindRenderbuffer.set(I),M.renderbufferStorage(M.RENDERBUFFER,u,p,C),this.bindRenderbuffer.set(null),I}createFramebuffer(u,p,C,M){return new ec(this,u,p,C,M)}clear({color:u,depth:p,stencil:C}){const M=this.gl;let I=0;u&&(I|=M.COLOR_BUFFER_BIT,this.clearColor.set(u),this.colorMask.set([!0,!0,!0,!0])),p!==void 0&&(I|=M.DEPTH_BUFFER_BIT,this.depthRange.set([0,1]),this.clearDepth.set(p),this.depthMask.set(!0)),C!==void 0&&(I|=M.STENCIL_BUFFER_BIT,this.clearStencil.set(C),this.stencilMask.set(255)),M.clear(I)}setCullFace(u){u.enable===!1?this.cullFace.set(!1):(this.cullFace.set(!0),this.cullFaceSide.set(u.mode),this.frontFace.set(u.frontFace))}setDepthMode(u){u.func!==this.gl.ALWAYS||u.mask?(this.depthTest.set(!0),this.depthFunc.set(u.func),this.depthMask.set(u.mask),this.depthRange.set(u.range)):this.depthTest.set(!1)}setStencilMode(u){u.test.func!==this.gl.ALWAYS||u.mask?(this.stencilTest.set(!0),this.stencilMask.set(u.mask),this.stencilOp.set([u.fail,u.depthFail,u.pass]),this.stencilFunc.set({func:u.test.func,ref:u.ref,mask:u.test.mask})):this.stencilTest.set(!1)}setColorMode(u){a.aD(u.blendFunction,Ro.Replace)?this.blend.set(!1):(this.blend.set(!0),this.blendFunc.set(u.blendFunction),this.blendColor.set(u.blendColor)),this.colorMask.set(u.mask)}createVertexArray(){var u;return Sr(this.gl)?this.gl.createVertexArray():(u=this.gl.getExtension("OES_vertex_array_object"))===null||u===void 0?void 0:u.createVertexArrayOES()}deleteVertexArray(u){var p;return Sr(this.gl)?this.gl.deleteVertexArray(u):(p=this.gl.getExtension("OES_vertex_array_object"))===null||p===void 0?void 0:p.deleteVertexArrayOES(u)}unbindVAO(){this.bindVertexArray.set(null)}}class zi{constructor(u,p,C){this.func=u,this.mask=p,this.range=C}}zi.ReadOnly=!1,zi.ReadWrite=!0,zi.disabled=new zi(519,zi.ReadOnly,[0,1]);const Yc=7680;class Lo{constructor(u,p,C,M,I,L){this.test=u,this.ref=p,this.mask=C,this.fail=M,this.depthFail=I,this.pass=L}}Lo.disabled=new Lo({func:519,mask:0},0,0,Yc,Yc,Yc);class So{constructor(u,p,C){this.enable=u,this.mode=p,this.frontFace=C}}let tc;function nc(O,u,p,C,M,I,L){const j=O.context,G=j.gl,te=O.useProgram("collisionBox"),Ae=[];let he=0,Me=0;for(let qe=0;qe<C.length;qe++){const _t=C[qe],Ut=u.getTile(_t),Tt=Ut.getBucket(p);if(!Tt)continue;let en=_t.posMatrix;M[0]===0&&M[1]===0||(en=O.translatePosMatrix(_t.posMatrix,Ut,M,I));const hn=L?Tt.textCollisionBox:Tt.iconCollisionBox,An=Tt.collisionCircleArray;if(An.length>0){const On=a.F(),lr=en;a.aP(On,Tt.placementInvProjMatrix,O.transform.glCoordMatrix),a.aP(On,On,Tt.placementViewportMatrix),Ae.push({circleArray:An,circleOffset:Me,transform:lr,invTransform:On,coord:_t}),he+=An.length/4,Me=he}hn&&te.draw(j,G.LINES,zi.disabled,Lo.disabled,O.colorModeForRenderPass(),So.disabled,HA(en,O.transform,Ut),O.style.map.terrain&&O.style.map.terrain.getTerrainData(_t),p.id,hn.layoutVertexBuffer,hn.indexBuffer,hn.segments,null,O.transform.zoom,null,null,hn.collisionVertexBuffer)}if(!L||!Ae.length)return;const De=O.useProgram("collisionCircle"),je=new a.aQ;je.resize(4*he),je._trim();let Qe=0;for(const qe of Ae)for(let _t=0;_t<qe.circleArray.length/4;_t++){const Ut=4*_t,Tt=qe.circleArray[Ut+0],en=qe.circleArray[Ut+1],hn=qe.circleArray[Ut+2],An=qe.circleArray[Ut+3];je.emplace(Qe++,Tt,en,hn,An,0),je.emplace(Qe++,Tt,en,hn,An,1),je.emplace(Qe++,Tt,en,hn,An,2),je.emplace(Qe++,Tt,en,hn,An,3)}(!tc||tc.length<2*he)&&(tc=function(qe){const _t=2*qe,Ut=new a.aS;Ut.resize(_t),Ut._trim();for(let Tt=0;Tt<_t;Tt++){const en=6*Tt;Ut.uint16[en+0]=4*Tt+0,Ut.uint16[en+1]=4*Tt+1,Ut.uint16[en+2]=4*Tt+2,Ut.uint16[en+3]=4*Tt+2,Ut.uint16[en+4]=4*Tt+3,Ut.uint16[en+5]=4*Tt+0}return Ut}(he));const Le=j.createIndexBuffer(tc,!0),ft=j.createVertexBuffer(je,a.aR.members,!0);for(const qe of Ae){const _t={u_matrix:qe.transform,u_inv_matrix:qe.invTransform,u_camera_to_center_distance:(Bt=O.transform).cameraToCenterDistance,u_viewport_size:[Bt.width,Bt.height]};De.draw(j,G.TRIANGLES,zi.disabled,Lo.disabled,O.colorModeForRenderPass(),So.disabled,_t,O.style.map.terrain&&O.style.map.terrain.getTerrainData(qe.coord),p.id,ft,Le,a.$.simpleSegment(0,2*qe.circleOffset,qe.circleArray.length,qe.circleArray.length/2),null,O.transform.zoom,null,null,null)}var Bt;ft.destroy(),Le.destroy()}So.disabled=new So(!1,1029,2305),So.backCCW=new So(!0,1029,2305);const Ls=a.an(new Float32Array(16));function Kd(O,u,p,C,M,I){const{horizontalAlign:L,verticalAlign:j}=a.at(O);return new a.P((-(L-.5)*u/M+C[0])*I,(-(j-.5)*p/M+C[1])*I)}function Ou(O,u,p,C,M,I,L,j,G,te,Ae){const he=O.text.placedSymbolArray,Me=O.text.dynamicLayoutVertexArray,De=O.icon.dynamicLayoutVertexArray,je={};Me.clear();for(let Qe=0;Qe<he.length;Qe++){const Le=he.get(Qe),ft=Le.hidden||!Le.crossTileID||O.allowVerticalPlacement&&!Le.placedOrientation?null:C[Le.crossTileID];if(ft){const Bt=new a.P(Le.anchorX,Le.anchorY),qe=Gn(Bt,p?L:I,Ae),_t=Zn(M.cameraToCenterDistance,qe.signedDistanceFromCamera);let Ut=a.ai(O.textSizeData,G,Le)*_t/a.ao;p&&(Ut*=O.tilePixelRatio/j);const{width:Tt,height:en,anchor:hn,textOffset:An,textBoxScale:On}=ft,lr=Kd(hn,Tt,en,An,On,Ut),xr=p?Gn(Bt.add(lr),I,Ae).point:qe.point.add(u?lr.rotate(-M.angle):lr),Tn=O.allowVerticalPlacement&&Le.placedOrientation===a.ah.vertical?Math.PI/2:0;for(let yr=0;yr<Le.numGlyphs;yr++)a.aj(Me,xr,Tn);te&&Le.associatedIconIndex>=0&&(je[Le.associatedIconIndex]={shiftedAnchor:xr,angle:Tn})}else Gt(Le.numGlyphs,Me)}if(te){De.clear();const Qe=O.icon.placedSymbolArray;for(let Le=0;Le<Qe.length;Le++){const ft=Qe.get(Le);if(ft.hidden)Gt(ft.numGlyphs,De);else{const Bt=je[Le];if(Bt)for(let qe=0;qe<ft.numGlyphs;qe++)a.aj(De,Bt.shiftedAnchor,Bt.angle);else Gt(ft.numGlyphs,De)}}O.icon.dynamicLayoutVertexBuffer.updateData(De)}O.text.dynamicLayoutVertexBuffer.updateData(Me)}function xl(O,u,p){return p.iconsInText&&u?"symbolTextAndIcon":O?"symbolSDF":"symbolIcon"}function Xu(O,u,p,C,M,I,L,j,G,te,Ae,he){const Me=O.context,De=Me.gl,je=O.transform,Qe=j==="map",Le=G==="map",ft=j!=="viewport"&&p.layout.get("symbol-placement")!=="point",Bt=Qe&&!Le&&!ft,qe=!p.layout.get("symbol-sort-key").isConstant();let _t=!1;const Ut=O.depthModeForSublayer(0,zi.ReadOnly),Tt=p._unevaluatedLayout.hasValue("text-variable-anchor")||p._unevaluatedLayout.hasValue("text-variable-anchor-offset"),en=[];for(const hn of C){const An=u.getTile(hn),On=An.getBucket(p);if(!On)continue;const lr=M?On.text:On.icon;if(!lr||!lr.segments.get().length||!lr.hasVisibleVertices)continue;const xr=lr.programConfigurations.get(p.id),Tn=M||On.sdfIcons,yr=M?On.textSizeData:On.iconSizeData,Qn=Le||je.pitch!==0,Ho=O.useProgram(xl(Tn,M,On),xr),pi=a.ag(yr,je.zoom),ii=O.style.map.terrain&&O.style.map.terrain.getTerrainData(hn);let si,yo,vo,Zs,Sa=[0,0],aa=null;if(M)yo=An.glyphAtlasTexture,vo=De.LINEAR,si=An.glyphAtlasTexture.size,On.iconsInText&&(Sa=An.imageAtlasTexture.size,aa=An.imageAtlasTexture,Zs=Qn||O.options.rotating||O.options.zooming||yr.kind==="composite"||yr.kind==="camera"?De.LINEAR:De.NEAREST);else{const jo=p.layout.get("icon-size").constantOr(0)!==1||On.iconsNeedLinear;yo=An.imageAtlasTexture,vo=Tn||O.options.rotating||O.options.zooming||jo||Qn?De.LINEAR:De.NEAREST,si=An.imageAtlasTexture.size}const _a=qn(An,1,O.transform.zoom),no=un(hn.posMatrix,Le,Qe,O.transform,_a),ws=In(hn.posMatrix,Le,Qe,O.transform,_a),Pu=Tt&&On.hasTextData(),Ms=p.layout.get("icon-text-fit")!=="none"&&Pu&&On.hasIconData();if(ft){const jo=O.style.map.terrain?(ua,sa)=>O.style.map.terrain.getElevation(hn,ua,sa):null,Da=p.layout.get("text-rotation-alignment")==="map";fe(On,hn.posMatrix,O,M,no,ws,Le,te,Da,jo)}const aA=O.translatePosMatrix(hn.posMatrix,An,I,L),hu=ft||M&&Tt||Ms?Ls:no,Zo=O.translatePosMatrix(ws,An,I,L,!0),ji=Tn&&p.paint.get(M?"text-halo-width":"icon-halo-width").constantOr(1)!==0;let Oi;Oi=Tn?On.iconsInText?Mu(yr.kind,pi,Bt,Le,O,aA,hu,Zo,si,Sa):as(yr.kind,pi,Bt,Le,O,aA,hu,Zo,M,si,!0):uu(yr.kind,pi,Bt,Le,O,aA,hu,Zo,M,si);const cs={program:Ho,buffers:lr,uniformValues:Oi,atlasTexture:yo,atlasTextureIcon:aa,atlasInterpolation:vo,atlasInterpolationIcon:Zs,isSDF:Tn,hasHalo:ji};if(qe&&On.canOverlap){_t=!0;const jo=lr.segments.get();for(const Da of jo)en.push({segments:new a.$([Da]),sortKey:Da.sortKey,state:cs,terrainData:ii})}else en.push({segments:lr.segments,sortKey:0,state:cs,terrainData:ii})}_t&&en.sort((hn,An)=>hn.sortKey-An.sortKey);for(const hn of en){const An=hn.state;if(Me.activeTexture.set(De.TEXTURE0),An.atlasTexture.bind(An.atlasInterpolation,De.CLAMP_TO_EDGE),An.atlasTextureIcon&&(Me.activeTexture.set(De.TEXTURE1),An.atlasTextureIcon&&An.atlasTextureIcon.bind(An.atlasInterpolationIcon,De.CLAMP_TO_EDGE)),An.isSDF){const On=An.uniformValues;An.hasHalo&&(On.u_is_halo=1,qc(An.buffers,hn.segments,p,O,An.program,Ut,Ae,he,On,hn.terrainData)),On.u_is_halo=0}qc(An.buffers,hn.segments,p,O,An.program,Ut,Ae,he,An.uniformValues,hn.terrainData)}}function qc(O,u,p,C,M,I,L,j,G,te){const Ae=C.context;M.draw(Ae,Ae.gl.TRIANGLES,I,L,j,So.disabled,G,te,p.id,O.layoutVertexBuffer,O.indexBuffer,u,p.paint,C.transform.zoom,O.programConfigurations.get(p.id),O.dynamicLayoutVertexBuffer,O.opacityVertexBuffer)}function Mf(O,u,p,C,M){if(!p||!C||!C.imageAtlas)return;const I=C.imageAtlas.patternPositions;let L=I[p.to.toString()],j=I[p.from.toString()];if(!L&&j&&(L=j),!j&&L&&(j=L),!L||!j){const G=M.getPaintProperty(u);L=I[G],j=I[G]}L&&j&&O.setConstantPatternPositions(L,j)}function wl(O,u,p,C,M,I,L){const j=O.context.gl,G="fill-pattern",te=p.paint.get(G),Ae=te&&te.constantOr(1),he=p.getCrossfadeParameters();let Me,De,je,Qe,Le;L?(De=Ae&&!p.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",Me=j.LINES):(De=Ae?"fillPattern":"fill",Me=j.TRIANGLES);const ft=te.constantOr(null);for(const Bt of C){const qe=u.getTile(Bt);if(Ae&&!qe.patternsLoaded())continue;const _t=qe.getBucket(p);if(!_t)continue;const Ut=_t.programConfigurations.get(p.id),Tt=O.useProgram(De,Ut),en=O.style.map.terrain&&O.style.map.terrain.getTerrainData(Bt);Ae&&(O.context.activeTexture.set(j.TEXTURE0),qe.imageAtlasTexture.bind(j.LINEAR,j.CLAMP_TO_EDGE),Ut.updatePaintBuffers(he)),Mf(Ut,G,ft,qe,p);const hn=en?Bt:null,An=O.translatePosMatrix(hn?hn.posMatrix:Bt.posMatrix,qe,p.paint.get("fill-translate"),p.paint.get("fill-translate-anchor"));if(L){Qe=_t.indexBuffer2,Le=_t.segments2;const On=[j.drawingBufferWidth,j.drawingBufferHeight];je=De==="fillOutlinePattern"&&Ae?bl(An,O,he,qe,On):xu(An,On)}else Qe=_t.indexBuffer,Le=_t.segments,je=Ae?ll(An,O,he,qe):$a(An);Tt.draw(O.context,Me,M,O.stencilModeForClipping(Bt),I,So.disabled,je,en,p.id,_t.layoutVertexBuffer,Qe,Le,p.paint,O.transform.zoom,Ut)}}function Ju(O,u,p,C,M,I,L){const j=O.context,G=j.gl,te="fill-extrusion-pattern",Ae=p.paint.get(te),he=Ae.constantOr(1),Me=p.getCrossfadeParameters(),De=p.paint.get("fill-extrusion-opacity"),je=Ae.constantOr(null);for(const Qe of C){const Le=u.getTile(Qe),ft=Le.getBucket(p);if(!ft)continue;const Bt=O.style.map.terrain&&O.style.map.terrain.getTerrainData(Qe),qe=ft.programConfigurations.get(p.id),_t=O.useProgram(he?"fillExtrusionPattern":"fillExtrusion",qe);he&&(O.context.activeTexture.set(G.TEXTURE0),Le.imageAtlasTexture.bind(G.LINEAR,G.CLAMP_TO_EDGE),qe.updatePaintBuffers(Me)),Mf(qe,te,je,Le,p);const Ut=O.translatePosMatrix(Qe.posMatrix,Le,p.paint.get("fill-extrusion-translate"),p.paint.get("fill-extrusion-translate-anchor")),Tt=p.paint.get("fill-extrusion-vertical-gradient"),en=he?va(Ut,O,Tt,De,Qe,Me,Le):Vs(Ut,O,Tt,De);_t.draw(j,j.gl.TRIANGLES,M,I,L,So.backCCW,en,Bt,p.id,ft.layoutVertexBuffer,ft.indexBuffer,ft.segments,p.paint,O.transform.zoom,qe,O.style.map.terrain&&ft.centroidVertexBuffer)}}function bh(O,u,p,C,M,I,L){const j=O.context,G=j.gl,te=p.fbo;if(!te)return;const Ae=O.useProgram("hillshade"),he=O.style.map.terrain&&O.style.map.terrain.getTerrainData(u);j.activeTexture.set(G.TEXTURE0),G.bindTexture(G.TEXTURE_2D,te.colorAttachment.get()),Ae.draw(j,G.TRIANGLES,M,I,L,So.disabled,((Me,De,je,Qe)=>{const Le=je.paint.get("hillshade-shadow-color"),ft=je.paint.get("hillshade-highlight-color"),Bt=je.paint.get("hillshade-accent-color");let qe=je.paint.get("hillshade-illumination-direction")*(Math.PI/180);je.paint.get("hillshade-illumination-anchor")==="viewport"&&(qe-=Me.transform.angle);const _t=!Me.options.moving;return{u_matrix:Qe?Qe.posMatrix:Me.transform.calculatePosMatrix(De.tileID.toUnwrapped(),_t),u_image:0,u_latrange:Ya(0,De.tileID),u_light:[je.paint.get("hillshade-exaggeration"),qe],u_shadow:Le,u_highlight:ft,u_accent:Bt}})(O,p,C,he?u:null),he,C.id,O.rasterBoundsBuffer,O.quadTriangleIndexBuffer,O.rasterBoundsSegments)}function eA(O,u,p,C,M,I){const L=O.context,j=L.gl,G=u.dem;if(G&&G.data){const te=G.dim,Ae=G.stride,he=G.getPixels();if(L.activeTexture.set(j.TEXTURE1),L.pixelStoreUnpackPremultiplyAlpha.set(!1),u.demTexture=u.demTexture||O.getTileTexture(Ae),u.demTexture){const De=u.demTexture;De.update(he,{premultiply:!1}),De.bind(j.NEAREST,j.CLAMP_TO_EDGE)}else u.demTexture=new ct(L,he,j.RGBA,{premultiply:!1}),u.demTexture.bind(j.NEAREST,j.CLAMP_TO_EDGE);L.activeTexture.set(j.TEXTURE0);let Me=u.fbo;if(!Me){const De=new ct(L,{width:te,height:te,data:null},j.RGBA);De.bind(j.LINEAR,j.CLAMP_TO_EDGE),Me=u.fbo=L.createFramebuffer(te,te,!0,!1),Me.colorAttachment.set(De.texture)}L.bindFramebuffer.set(Me.framebuffer),L.viewport.set([0,0,te,te]),O.useProgram("hillshadePrepare").draw(L,j.TRIANGLES,C,M,I,So.disabled,((De,je)=>{const Qe=je.stride,Le=a.F();return a.aN(Le,0,a.W,-a.W,0,0,1),a.H(Le,Le,[0,-a.W,0]),{u_matrix:Le,u_image:1,u_dimension:[Qe,Qe],u_zoom:De.overscaledZ,u_unpack:je.getUnpackVector()}})(u.tileID,G),null,p.id,O.rasterBoundsBuffer,O.quadTriangleIndexBuffer,O.rasterBoundsSegments),u.needsHillshadePrepare=!1}}function xh(O,u,p,C,M,I){const L=C.paint.get("raster-fade-duration");if(!I&&L>0){const j=k.now(),G=(j-O.timeAdded)/L,te=u?(j-u.timeAdded)/L:-1,Ae=p.getSource(),he=M.coveringZoomLevel({tileSize:Ae.tileSize,roundZoom:Ae.roundZoom}),Me=!u||Math.abs(u.tileID.overscaledZ-he)>Math.abs(O.tileID.overscaledZ-he),De=Me&&O.refreshedUponExpiration?1:a.ac(Me?G:1-te,0,1);return O.refreshedUponExpiration&&G>=1&&(O.refreshedUponExpiration=!1),u?{opacity:1,mix:1-De}:{opacity:De,mix:0}}return{opacity:1,mix:0}}const kp=new a.aO(1,0,0,1),Pd=new a.aO(0,1,0,1),rc=new a.aO(0,0,1,1),Hs=new a.aO(1,0,1,1),Ml=new a.aO(0,1,1,1);function wh(O,u,p,C){Bu(O,0,u+p/2,O.transform.width,p,C)}function ra(O,u,p,C){Bu(O,u-p/2,0,p,O.transform.height,C)}function Bu(O,u,p,C,M,I){const L=O.context,j=L.gl;j.enable(j.SCISSOR_TEST),j.scissor(u*O.pixelRatio,p*O.pixelRatio,C*O.pixelRatio,M*O.pixelRatio),L.clear({color:I}),j.disable(j.SCISSOR_TEST)}function bs(O,u,p){const C=O.context,M=C.gl,I=p.posMatrix,L=O.useProgram("debug"),j=zi.disabled,G=Lo.disabled,te=O.colorModeForRenderPass(),Ae="$debug",he=O.style.map.terrain&&O.style.map.terrain.getTerrainData(p);C.activeTexture.set(M.TEXTURE0);const Me=u.getTileByID(p.key).latestRawTileData,De=Math.floor((Me&&Me.byteLength||0)/1024),je=u.getTile(p).tileSize,Qe=512/Math.min(je,512)*(p.overscaledZ/O.transform.zoom)*.5;let Le=p.canonical.toString();p.overscaledZ!==p.canonical.z&&(Le+=` => ${p.overscaledZ}`),function(ft,Bt){ft.initDebugOverlayCanvas();const qe=ft.debugOverlayCanvas,_t=ft.context.gl,Ut=ft.debugOverlayCanvas.getContext("2d");Ut.clearRect(0,0,qe.width,qe.height),Ut.shadowColor="white",Ut.shadowBlur=2,Ut.lineWidth=1.5,Ut.strokeStyle="white",Ut.textBaseline="top",Ut.font="bold 36px Open Sans, sans-serif",Ut.fillText(Bt,5,5),Ut.strokeText(Bt,5,5),ft.debugOverlayTexture.update(qe),ft.debugOverlayTexture.bind(_t.LINEAR,_t.CLAMP_TO_EDGE)}(O,`${Le} ${De}kB`),L.draw(C,M.TRIANGLES,j,G,Ro.alphaBlended,So.disabled,Hu(I,a.aO.transparent,Qe),null,Ae,O.debugBuffer,O.quadTriangleIndexBuffer,O.debugSegments),L.draw(C,M.LINE_STRIP,j,G,te,So.disabled,Hu(I,a.aO.red),he,Ae,O.debugBuffer,O.tileBorderIndexBuffer,O.debugSegments)}function ul(O,u,p){const C=O.context,M=C.gl,I=O.colorModeForRenderPass(),L=new zi(M.LEQUAL,zi.ReadWrite,O.depthRangeFor3D),j=O.useProgram("terrain"),G=u.getTerrainMesh();C.bindFramebuffer.set(null),C.viewport.set([0,0,O.width,O.height]);for(const te of p){const Ae=O.renderToTexture.getTexture(te),he=u.getTerrainData(te.tileID);C.activeTexture.set(M.TEXTURE0),M.bindTexture(M.TEXTURE_2D,Ae.texture);const Me={u_matrix:O.transform.calculatePosMatrix(te.tileID.toUnwrapped()),u_texture:0,u_ele_delta:u.getMeshFrameDelta(O.transform.zoom)};j.draw(C,M.TRIANGLES,L,Lo.disabled,I,So.backCCW,Me,he,"terrain",G.vertexBuffer,G.indexBuffer,G.segments)}}class Fd{constructor(u,p){this.context=new _h(u),this.transform=p,this._tileTextures={},this.terrainFacilitator={dirty:!0,matrix:a.F(),renderTime:0},this.setup(),this.numSublayers=Et.maxUnderzooming+Et.maxOverzooming+1,this.depthEpsilon=1/Math.pow(2,16),this.crossTileSymbolIndex=new En}resize(u,p,C){if(this.width=Math.floor(u*C),this.height=Math.floor(p*C),this.pixelRatio=C,this.context.viewport.set([0,0,this.width,this.height]),this.style)for(const M of this.style._order)this.style._layers[M].resize()}setup(){const u=this.context,p=new a.aV;p.emplaceBack(0,0),p.emplaceBack(a.W,0),p.emplaceBack(0,a.W),p.emplaceBack(a.W,a.W),this.tileExtentBuffer=u.createVertexBuffer(p,po.members),this.tileExtentSegments=a.$.simpleSegment(0,0,4,2);const C=new a.aV;C.emplaceBack(0,0),C.emplaceBack(a.W,0),C.emplaceBack(0,a.W),C.emplaceBack(a.W,a.W),this.debugBuffer=u.createVertexBuffer(C,po.members),this.debugSegments=a.$.simpleSegment(0,0,4,5);const M=new a.Z;M.emplaceBack(0,0,0,0),M.emplaceBack(a.W,0,a.W,0),M.emplaceBack(0,a.W,0,a.W),M.emplaceBack(a.W,a.W,a.W,a.W),this.rasterBoundsBuffer=u.createVertexBuffer(M,Sn.members),this.rasterBoundsSegments=a.$.simpleSegment(0,0,4,2);const I=new a.aV;I.emplaceBack(0,0),I.emplaceBack(1,0),I.emplaceBack(0,1),I.emplaceBack(1,1),this.viewportBuffer=u.createVertexBuffer(I,po.members),this.viewportSegments=a.$.simpleSegment(0,0,4,2);const L=new a.aW;L.emplaceBack(0),L.emplaceBack(1),L.emplaceBack(3),L.emplaceBack(2),L.emplaceBack(0),this.tileBorderIndexBuffer=u.createIndexBuffer(L);const j=new a.aX;j.emplaceBack(0,1,2),j.emplaceBack(2,1,3),this.quadTriangleIndexBuffer=u.createIndexBuffer(j);const G=this.context.gl;this.stencilClearMode=new Lo({func:G.ALWAYS,mask:0},0,255,G.ZERO,G.ZERO,G.ZERO)}clearStencil(){const u=this.context,p=u.gl;this.nextStencilID=1,this.currentStencilSource=void 0;const C=a.F();a.aN(C,0,this.width,this.height,0,0,1),a.J(C,C,[p.drawingBufferWidth,p.drawingBufferHeight,0]),this.useProgram("clippingMask").draw(u,p.TRIANGLES,zi.disabled,this.stencilClearMode,Ro.disabled,So.disabled,ZA(C),null,"$clipping",this.viewportBuffer,this.quadTriangleIndexBuffer,this.viewportSegments)}_renderTileClippingMasks(u,p){if(this.currentStencilSource===u.source||!u.isTileClipped()||!p||!p.length)return;this.currentStencilSource=u.source;const C=this.context,M=C.gl;this.nextStencilID+p.length>256&&this.clearStencil(),C.setColorMode(Ro.disabled),C.setDepthMode(zi.disabled);const I=this.useProgram("clippingMask");this._tileClippingMaskIDs={};for(const L of p){const j=this._tileClippingMaskIDs[L.key]=this.nextStencilID++,G=this.style.map.terrain&&this.style.map.terrain.getTerrainData(L);I.draw(C,M.TRIANGLES,zi.disabled,new Lo({func:M.ALWAYS,mask:0},j,255,M.KEEP,M.KEEP,M.REPLACE),Ro.disabled,So.disabled,ZA(L.posMatrix),G,"$clipping",this.tileExtentBuffer,this.quadTriangleIndexBuffer,this.tileExtentSegments)}}stencilModeFor3D(){this.currentStencilSource=void 0,this.nextStencilID+1>256&&this.clearStencil();const u=this.nextStencilID++,p=this.context.gl;return new Lo({func:p.NOTEQUAL,mask:255},u,255,p.KEEP,p.KEEP,p.REPLACE)}stencilModeForClipping(u){const p=this.context.gl;return new Lo({func:p.EQUAL,mask:255},this._tileClippingMaskIDs[u.key],0,p.KEEP,p.KEEP,p.REPLACE)}stencilConfigForOverlap(u){const p=this.context.gl,C=u.sort((L,j)=>j.overscaledZ-L.overscaledZ),M=C[C.length-1].overscaledZ,I=C[0].overscaledZ-M+1;if(I>1){this.currentStencilSource=void 0,this.nextStencilID+I>256&&this.clearStencil();const L={};for(let j=0;j<I;j++)L[j+M]=new Lo({func:p.GEQUAL,mask:255},j+this.nextStencilID,255,p.KEEP,p.KEEP,p.REPLACE);return this.nextStencilID+=I,[L,C]}return[{[M]:Lo.disabled},C]}colorModeForRenderPass(){const u=this.context.gl;return this._showOverdrawInspector?new Ro([u.CONSTANT_COLOR,u.ONE],new a.aO(.125,.125,.125,0),[!0,!0,!0,!0]):this.renderPass==="opaque"?Ro.unblended:Ro.alphaBlended}depthModeForSublayer(u,p,C){if(!this.opaquePassEnabledForLayer())return zi.disabled;const M=1-((1+this.currentLayer)*this.numSublayers+u)*this.depthEpsilon;return new zi(C||this.context.gl.LEQUAL,p,[M,M])}opaquePassEnabledForLayer(){return this.currentLayer<this.opaquePassCutoff}render(u,p){this.style=u,this.options=p,this.lineAtlas=u.lineAtlas,this.imageManager=u.imageManager,this.glyphManager=u.glyphManager,this.symbolFadeChange=u.placement.symbolFadeChange(k.now()),this.imageManager.beginFrame();const C=this.style._order,M=this.style.sourceCaches,I={},L={},j={};for(const G in M){const te=M[G];te.used&&te.prepare(this.context),I[G]=te.getVisibleCoordinates(),L[G]=I[G].slice().reverse(),j[G]=te.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(let G=0;G<C.length;G++)if(this.style._layers[C[G]].is3D()){this.opaquePassCutoff=G;break}if(this.renderToTexture){this.renderToTexture.prepareForRender(this.style,this.transform.zoom),this.opaquePassCutoff=0;const G=this.style.map.terrain.sourceCache.tilesAfterTime(this.terrainFacilitator.renderTime);(this.terrainFacilitator.dirty||!a.aY(this.terrainFacilitator.matrix,this.transform.projMatrix)||G.length)&&(a.aZ(this.terrainFacilitator.matrix,this.transform.projMatrix),this.terrainFacilitator.renderTime=Date.now(),this.terrainFacilitator.dirty=!1,function(te,Ae){const he=te.context,Me=he.gl,De=Ro.unblended,je=new zi(Me.LEQUAL,zi.ReadWrite,[0,1]),Qe=Ae.getTerrainMesh(),Le=Ae.sourceCache.getRenderableTiles(),ft=te.useProgram("terrainDepth");he.bindFramebuffer.set(Ae.getFramebuffer("depth").framebuffer),he.viewport.set([0,0,te.width/devicePixelRatio,te.height/devicePixelRatio]),he.clear({color:a.aO.transparent,depth:1});for(const Bt of Le){const qe=Ae.getTerrainData(Bt.tileID),_t={u_matrix:te.transform.calculatePosMatrix(Bt.tileID.toUnwrapped()),u_ele_delta:Ae.getMeshFrameDelta(te.transform.zoom)};ft.draw(he,Me.TRIANGLES,je,Lo.disabled,De,So.backCCW,_t,qe,"terrain",Qe.vertexBuffer,Qe.indexBuffer,Qe.segments)}he.bindFramebuffer.set(null),he.viewport.set([0,0,te.width,te.height])}(this,this.style.map.terrain),function(te,Ae){const he=te.context,Me=he.gl,De=Ro.unblended,je=new zi(Me.LEQUAL,zi.ReadWrite,[0,1]),Qe=Ae.getTerrainMesh(),Le=Ae.getCoordsTexture(),ft=Ae.sourceCache.getRenderableTiles(),Bt=te.useProgram("terrainCoords");he.bindFramebuffer.set(Ae.getFramebuffer("coords").framebuffer),he.viewport.set([0,0,te.width/devicePixelRatio,te.height/devicePixelRatio]),he.clear({color:a.aO.transparent,depth:1}),Ae.coordsIndex=[];for(const qe of ft){const _t=Ae.getTerrainData(qe.tileID);he.activeTexture.set(Me.TEXTURE0),Me.bindTexture(Me.TEXTURE_2D,Le.texture);const Ut={u_matrix:te.transform.calculatePosMatrix(qe.tileID.toUnwrapped()),u_terrain_coords_id:(255-Ae.coordsIndex.length)/255,u_texture:0,u_ele_delta:Ae.getMeshFrameDelta(te.transform.zoom)};Bt.draw(he,Me.TRIANGLES,je,Lo.disabled,De,So.backCCW,Ut,_t,"terrain",Qe.vertexBuffer,Qe.indexBuffer,Qe.segments),Ae.coordsIndex.push(qe.tileID.key)}he.bindFramebuffer.set(null),he.viewport.set([0,0,te.width,te.height])}(this,this.style.map.terrain))}this.renderPass="offscreen";for(const G of C){const te=this.style._layers[G];if(!te.hasOffscreenPass()||te.isHidden(this.transform.zoom))continue;const Ae=L[te.source];(te.type==="custom"||Ae.length)&&this.renderLayer(this,M[te.source],te,Ae)}if(this.context.bindFramebuffer.set(null),this.context.clear({color:p.showOverdrawInspector?a.aO.black:a.aO.transparent,depth:1}),this.clearStencil(),this._showOverdrawInspector=p.showOverdrawInspector,this.depthRangeFor3D=[0,1-(u._order.length+2)*this.numSublayers*this.depthEpsilon],!this.renderToTexture)for(this.renderPass="opaque",this.currentLayer=C.length-1;this.currentLayer>=0;this.currentLayer--){const G=this.style._layers[C[this.currentLayer]],te=M[G.source],Ae=I[G.source];this._renderTileClippingMasks(G,Ae),this.renderLayer(this,te,G,Ae)}for(this.renderPass="translucent",this.currentLayer=0;this.currentLayer<C.length;this.currentLayer++){const G=this.style._layers[C[this.currentLayer]],te=M[G.source];if(this.renderToTexture&&this.renderToTexture.renderLayer(G))continue;const Ae=(G.type==="symbol"?j:L)[G.source];this._renderTileClippingMasks(G,I[G.source]),this.renderLayer(this,te,G,Ae)}if(this.options.showTileBoundaries){const G=function(te,Ae){let he=null;const Me=Object.values(te._layers).flatMap(Le=>Le.source&&!Le.isHidden(Ae)?[te.sourceCaches[Le.source]]:[]),De=Me.filter(Le=>Le.getSource().type==="vector"),je=Me.filter(Le=>Le.getSource().type!=="vector"),Qe=Le=>{(!he||he.getSource().maxzoom<Le.getSource().maxzoom)&&(he=Le)};return De.forEach(Le=>Qe(Le)),he||je.forEach(Le=>Qe(Le)),he}(this.style,this.transform.zoom);G&&function(te,Ae,he){for(let Me=0;Me<he.length;Me++)bs(te,Ae,he[Me])}(this,G,G.getVisibleCoordinates())}this.options.showPadding&&function(G){const te=G.transform.padding;wh(G,G.transform.height-(te.top||0),3,kp),wh(G,te.bottom||0,3,Pd),ra(G,te.left||0,3,rc),ra(G,G.transform.width-(te.right||0),3,Hs);const Ae=G.transform.centerPoint;(function(he,Me,De,je){Bu(he,Me-1,De-10,2,20,je),Bu(he,Me-10,De-1,20,2,je)})(G,Ae.x,G.transform.height-Ae.y,Ml)}(this),this.context.setDefault()}renderLayer(u,p,C,M){if(!C.isHidden(this.transform.zoom)&&(C.type==="background"||C.type==="custom"||(M||[]).length))switch(this.id=C.id,C.type){case"symbol":(function(I,L,j,G,te){if(I.renderPass!=="translucent")return;const Ae=Lo.disabled,he=I.colorModeForRenderPass();(j._unevaluatedLayout.hasValue("text-variable-anchor")||j._unevaluatedLayout.hasValue("text-variable-anchor-offset"))&&function(Me,De,je,Qe,Le,ft,Bt){const qe=De.transform,_t=Le==="map",Ut=ft==="map";for(const Tt of Me){const en=Qe.getTile(Tt),hn=en.getBucket(je);if(!hn||!hn.text||!hn.text.segments.get().length)continue;const An=a.ag(hn.textSizeData,qe.zoom),On=qn(en,1,De.transform.zoom),lr=un(Tt.posMatrix,Ut,_t,De.transform,On),xr=je.layout.get("icon-text-fit")!=="none"&&hn.hasIconData();if(An){const Tn=Math.pow(2,qe.zoom-en.tileID.overscaledZ);Ou(hn,_t,Ut,Bt,qe,lr,Tt.posMatrix,Tn,An,xr,De.style.map.terrain?(yr,Qn)=>De.style.map.terrain.getElevation(Tt,yr,Qn):null)}}}(G,I,j,L,j.layout.get("text-rotation-alignment"),j.layout.get("text-pitch-alignment"),te),j.paint.get("icon-opacity").constantOr(1)!==0&&Xu(I,L,j,G,!1,j.paint.get("icon-translate"),j.paint.get("icon-translate-anchor"),j.layout.get("icon-rotation-alignment"),j.layout.get("icon-pitch-alignment"),j.layout.get("icon-keep-upright"),Ae,he),j.paint.get("text-opacity").constantOr(1)!==0&&Xu(I,L,j,G,!0,j.paint.get("text-translate"),j.paint.get("text-translate-anchor"),j.layout.get("text-rotation-alignment"),j.layout.get("text-pitch-alignment"),j.layout.get("text-keep-upright"),Ae,he),L.map.showCollisionBoxes&&(nc(I,L,j,G,j.paint.get("text-translate"),j.paint.get("text-translate-anchor"),!0),nc(I,L,j,G,j.paint.get("icon-translate"),j.paint.get("icon-translate-anchor"),!1))})(u,p,C,M,this.style.placement.variableOffsets);break;case"circle":(function(I,L,j,G){if(I.renderPass!=="translucent")return;const te=j.paint.get("circle-opacity"),Ae=j.paint.get("circle-stroke-width"),he=j.paint.get("circle-stroke-opacity"),Me=!j.layout.get("circle-sort-key").isConstant();if(te.constantOr(1)===0&&(Ae.constantOr(1)===0||he.constantOr(1)===0))return;const De=I.context,je=De.gl,Qe=I.depthModeForSublayer(0,zi.ReadOnly),Le=Lo.disabled,ft=I.colorModeForRenderPass(),Bt=[];for(let qe=0;qe<G.length;qe++){const _t=G[qe],Ut=L.getTile(_t),Tt=Ut.getBucket(j);if(!Tt)continue;const en=Tt.programConfigurations.get(j.id),hn=I.useProgram("circle",en),An=Tt.layoutVertexBuffer,On=Tt.indexBuffer,lr=I.style.map.terrain&&I.style.map.terrain.getTerrainData(_t),xr={programConfiguration:en,program:hn,layoutVertexBuffer:An,indexBuffer:On,uniformValues:CA(I,_t,Ut,j),terrainData:lr};if(Me){const Tn=Tt.segments.get();for(const yr of Tn)Bt.push({segments:new a.$([yr]),sortKey:yr.sortKey,state:xr})}else Bt.push({segments:Tt.segments,sortKey:0,state:xr})}Me&&Bt.sort((qe,_t)=>qe.sortKey-_t.sortKey);for(const qe of Bt){const{programConfiguration:_t,program:Ut,layoutVertexBuffer:Tt,indexBuffer:en,uniformValues:hn,terrainData:An}=qe.state;Ut.draw(De,je.TRIANGLES,Qe,Le,ft,So.disabled,hn,An,j.id,Tt,en,qe.segments,j.paint,I.transform.zoom,_t)}})(u,p,C,M);break;case"heatmap":(function(I,L,j,G){if(j.paint.get("heatmap-opacity")!==0)if(I.renderPass==="offscreen"){const te=I.context,Ae=te.gl,he=Lo.disabled,Me=new Ro([Ae.ONE,Ae.ONE],a.aO.transparent,[!0,!0,!0,!0]);(function(De,je,Qe){const Le=De.gl;De.activeTexture.set(Le.TEXTURE1),De.viewport.set([0,0,je.width/4,je.height/4]);let ft=Qe.heatmapFbo;if(ft)Le.bindTexture(Le.TEXTURE_2D,ft.colorAttachment.get()),De.bindFramebuffer.set(ft.framebuffer);else{const Bt=Le.createTexture();Le.bindTexture(Le.TEXTURE_2D,Bt),Le.texParameteri(Le.TEXTURE_2D,Le.TEXTURE_WRAP_S,Le.CLAMP_TO_EDGE),Le.texParameteri(Le.TEXTURE_2D,Le.TEXTURE_WRAP_T,Le.CLAMP_TO_EDGE),Le.texParameteri(Le.TEXTURE_2D,Le.TEXTURE_MIN_FILTER,Le.LINEAR),Le.texParameteri(Le.TEXTURE_2D,Le.TEXTURE_MAG_FILTER,Le.LINEAR),ft=Qe.heatmapFbo=De.createFramebuffer(je.width/4,je.height/4,!1,!1),function(qe,_t,Ut,Tt){var en,hn;const An=qe.gl,On=(en=qe.HALF_FLOAT)!==null&&en!==void 0?en:An.UNSIGNED_BYTE,lr=(hn=qe.RGBA16F)!==null&&hn!==void 0?hn:An.RGBA;An.texImage2D(An.TEXTURE_2D,0,lr,_t.width/4,_t.height/4,0,An.RGBA,On,null),Tt.colorAttachment.set(Ut)}(De,je,Bt,ft)}})(te,I,j),te.clear({color:a.aO.transparent});for(let De=0;De<G.length;De++){const je=G[De];if(L.hasRenderableParent(je))continue;const Qe=L.getTile(je),Le=Qe.getBucket(j);if(!Le)continue;const ft=Le.programConfigurations.get(j.id),Bt=I.useProgram("heatmap",ft),{zoom:qe}=I.transform;Bt.draw(te,Ae.TRIANGLES,zi.disabled,he,Me,So.disabled,_A(je.posMatrix,Qe,qe,j.paint.get("heatmap-intensity")),null,j.id,Le.layoutVertexBuffer,Le.indexBuffer,Le.segments,j.paint,I.transform.zoom,ft)}te.viewport.set([0,0,I.width,I.height])}else I.renderPass==="translucent"&&(I.context.setColorMode(I.colorModeForRenderPass()),function(te,Ae){const he=te.context,Me=he.gl,De=Ae.heatmapFbo;if(!De)return;he.activeTexture.set(Me.TEXTURE0),Me.bindTexture(Me.TEXTURE_2D,De.colorAttachment.get()),he.activeTexture.set(Me.TEXTURE1);let je=Ae.colorRampTexture;je||(je=Ae.colorRampTexture=new ct(he,Ae.colorRamp,Me.RGBA)),je.bind(Me.LINEAR,Me.CLAMP_TO_EDGE),te.useProgram("heatmapTexture").draw(he,Me.TRIANGLES,zi.disabled,Lo.disabled,te.colorModeForRenderPass(),So.disabled,((Qe,Le,ft,Bt)=>{const qe=a.F();a.aN(qe,0,Qe.width,Qe.height,0,0,1);const _t=Qe.context.gl;return{u_matrix:qe,u_world:[_t.drawingBufferWidth,_t.drawingBufferHeight],u_image:0,u_color_ramp:1,u_opacity:Le.paint.get("heatmap-opacity")}})(te,Ae),null,Ae.id,te.viewportBuffer,te.quadTriangleIndexBuffer,te.viewportSegments,Ae.paint,te.transform.zoom)}(I,j))})(u,p,C,M);break;case"line":(function(I,L,j,G){if(I.renderPass!=="translucent")return;const te=j.paint.get("line-opacity"),Ae=j.paint.get("line-width");if(te.constantOr(1)===0||Ae.constantOr(1)===0)return;const he=I.depthModeForSublayer(0,zi.ReadOnly),Me=I.colorModeForRenderPass(),De=j.paint.get("line-dasharray"),je=j.paint.get("line-pattern"),Qe=je.constantOr(1),Le=j.paint.get("line-gradient"),ft=j.getCrossfadeParameters(),Bt=Qe?"linePattern":De?"lineSDF":Le?"lineGradient":"line",qe=I.context,_t=qe.gl;let Ut=!0;for(const Tt of G){const en=L.getTile(Tt);if(Qe&&!en.patternsLoaded())continue;const hn=en.getBucket(j);if(!hn)continue;const An=hn.programConfigurations.get(j.id),On=I.context.program.get(),lr=I.useProgram(Bt,An),xr=Ut||lr.program!==On,Tn=I.style.map.terrain&&I.style.map.terrain.getTerrainData(Tt),yr=je.constantOr(null);if(yr&&en.imageAtlas){const pi=en.imageAtlas,ii=pi.patternPositions[yr.to.toString()],si=pi.patternPositions[yr.from.toString()];ii&&si&&An.setConstantPatternPositions(ii,si)}const Qn=Tn?Tt:null,Ho=Qe?Zu(I,en,j,ft,Qn):De?Ds(I,en,j,De,ft,Qn):Le?bA(I,en,j,hn.lineClipsArray.length,Qn):vs(I,en,j,Qn);if(Qe)qe.activeTexture.set(_t.TEXTURE0),en.imageAtlasTexture.bind(_t.LINEAR,_t.CLAMP_TO_EDGE),An.updatePaintBuffers(ft);else if(De&&(xr||I.lineAtlas.dirty))qe.activeTexture.set(_t.TEXTURE0),I.lineAtlas.bind(qe);else if(Le){const pi=hn.gradients[j.id];let ii=pi.texture;if(j.gradientVersion!==pi.version){let si=256;if(j.stepInterpolant){const yo=L.getSource().maxzoom,vo=Tt.canonical.z===yo?Math.ceil(1<<I.transform.maxZoom-Tt.canonical.z):1;si=a.ac(a.aT(hn.maxLineLength/a.W*1024*vo),256,qe.maxTextureSize)}pi.gradient=a.aU({expression:j.gradientExpression(),evaluationKey:"lineProgress",resolution:si,image:pi.gradient||void 0,clips:hn.lineClipsArray}),pi.texture?pi.texture.update(pi.gradient):pi.texture=new ct(qe,pi.gradient,_t.RGBA),pi.version=j.gradientVersion,ii=pi.texture}qe.activeTexture.set(_t.TEXTURE0),ii.bind(j.stepInterpolant?_t.NEAREST:_t.LINEAR,_t.CLAMP_TO_EDGE)}lr.draw(qe,_t.TRIANGLES,he,I.stencilModeForClipping(Tt),Me,So.disabled,Ho,Tn,j.id,hn.layoutVertexBuffer,hn.indexBuffer,hn.segments,j.paint,I.transform.zoom,An,hn.layoutVertexBuffer2),Ut=!1}})(u,p,C,M);break;case"fill":(function(I,L,j,G){const te=j.paint.get("fill-color"),Ae=j.paint.get("fill-opacity");if(Ae.constantOr(1)===0)return;const he=I.colorModeForRenderPass(),Me=j.paint.get("fill-pattern"),De=I.opaquePassEnabledForLayer()&&!Me.constantOr(1)&&te.constantOr(a.aO.transparent).a===1&&Ae.constantOr(0)===1?"opaque":"translucent";if(I.renderPass===De){const je=I.depthModeForSublayer(1,I.renderPass==="opaque"?zi.ReadWrite:zi.ReadOnly);wl(I,L,j,G,je,he,!1)}if(I.renderPass==="translucent"&&j.paint.get("fill-antialias")){const je=I.depthModeForSublayer(j.getPaintProperty("fill-outline-color")?2:0,zi.ReadOnly);wl(I,L,j,G,je,he,!0)}})(u,p,C,M);break;case"fill-extrusion":(function(I,L,j,G){const te=j.paint.get("fill-extrusion-opacity");if(te!==0&&I.renderPass==="translucent"){const Ae=new zi(I.context.gl.LEQUAL,zi.ReadWrite,I.depthRangeFor3D);if(te!==1||j.paint.get("fill-extrusion-pattern").constantOr(1))Ju(I,L,j,G,Ae,Lo.disabled,Ro.disabled),Ju(I,L,j,G,Ae,I.stencilModeFor3D(),I.colorModeForRenderPass());else{const he=I.colorModeForRenderPass();Ju(I,L,j,G,Ae,Lo.disabled,he)}}})(u,p,C,M);break;case"hillshade":(function(I,L,j,G){if(I.renderPass!=="offscreen"&&I.renderPass!=="translucent")return;const te=I.context,Ae=I.depthModeForSublayer(0,zi.ReadOnly),he=I.colorModeForRenderPass(),[Me,De]=I.renderPass==="translucent"?I.stencilConfigForOverlap(G):[{},G];for(const je of De){const Qe=L.getTile(je);Qe.needsHillshadePrepare!==void 0&&Qe.needsHillshadePrepare&&I.renderPass==="offscreen"?eA(I,Qe,j,Ae,Lo.disabled,he):I.renderPass==="translucent"&&bh(I,je,Qe,j,Ae,Me[je.overscaledZ],he)}te.viewport.set([0,0,I.width,I.height])})(u,p,C,M);break;case"raster":(function(I,L,j,G){if(I.renderPass!=="translucent"||j.paint.get("raster-opacity")===0||!G.length)return;const te=I.context,Ae=te.gl,he=L.getSource(),Me=I.useProgram("raster"),De=I.colorModeForRenderPass(),[je,Qe]=he instanceof nr?[{},G]:I.stencilConfigForOverlap(G),Le=Qe[Qe.length-1].overscaledZ,ft=!I.options.moving;for(const Bt of Qe){const qe=I.depthModeForSublayer(Bt.overscaledZ-Le,j.paint.get("raster-opacity")===1?zi.ReadWrite:zi.ReadOnly,Ae.LESS),_t=L.getTile(Bt);_t.registerFadeDuration(j.paint.get("raster-fade-duration"));const Ut=L.findLoadedParent(Bt,0),Tt=xh(_t,Ut,L,j,I.transform,I.style.map.terrain);let en,hn;const An=j.paint.get("raster-resampling")==="nearest"?Ae.NEAREST:Ae.LINEAR;te.activeTexture.set(Ae.TEXTURE0),_t.texture.bind(An,Ae.CLAMP_TO_EDGE,Ae.LINEAR_MIPMAP_NEAREST),te.activeTexture.set(Ae.TEXTURE1),Ut?(Ut.texture.bind(An,Ae.CLAMP_TO_EDGE,Ae.LINEAR_MIPMAP_NEAREST),en=Math.pow(2,Ut.tileID.overscaledZ-_t.tileID.overscaledZ),hn=[_t.tileID.canonical.x*en%1,_t.tileID.canonical.y*en%1]):_t.texture.bind(An,Ae.CLAMP_TO_EDGE,Ae.LINEAR_MIPMAP_NEAREST);const On=I.style.map.terrain&&I.style.map.terrain.getTerrainData(Bt),lr=On?Bt:null,xr=lr?lr.posMatrix:I.transform.calculatePosMatrix(Bt.toUnwrapped(),ft),Tn=lu(xr,hn||[0,0],en||1,Tt,j);he instanceof nr?Me.draw(te,Ae.TRIANGLES,qe,Lo.disabled,De,So.disabled,Tn,On,j.id,he.boundsBuffer,I.quadTriangleIndexBuffer,he.boundsSegments):Me.draw(te,Ae.TRIANGLES,qe,je[Bt.overscaledZ],De,So.disabled,Tn,On,j.id,I.rasterBoundsBuffer,I.quadTriangleIndexBuffer,I.rasterBoundsSegments)}})(u,p,C,M);break;case"background":(function(I,L,j,G){const te=j.paint.get("background-color"),Ae=j.paint.get("background-opacity");if(Ae===0)return;const he=I.context,Me=he.gl,De=I.transform,je=De.tileSize,Qe=j.paint.get("background-pattern");if(I.isPatternMissing(Qe))return;const Le=!Qe&&te.a===1&&Ae===1&&I.opaquePassEnabledForLayer()?"opaque":"translucent";if(I.renderPass!==Le)return;const ft=Lo.disabled,Bt=I.depthModeForSublayer(0,Le==="opaque"?zi.ReadWrite:zi.ReadOnly),qe=I.colorModeForRenderPass(),_t=I.useProgram(Qe?"backgroundPattern":"background"),Ut=G||De.coveringTiles({tileSize:je,terrain:I.style.map.terrain});Qe&&(he.activeTexture.set(Me.TEXTURE0),I.imageManager.bind(I.context));const Tt=j.getCrossfadeParameters();for(const en of Ut){const hn=G?en.posMatrix:I.transform.calculatePosMatrix(en.toUnwrapped()),An=Qe?bo(hn,Ae,I,Qe,{tileID:en,tileSize:je},Tt):Au(hn,Ae,te),On=I.style.map.terrain&&I.style.map.terrain.getTerrainData(en);_t.draw(he,Me.TRIANGLES,Bt,ft,qe,So.disabled,An,On,j.id,I.tileExtentBuffer,I.quadTriangleIndexBuffer,I.tileExtentSegments)}})(u,0,C,M);break;case"custom":(function(I,L,j){const G=I.context,te=j.implementation;if(I.renderPass==="offscreen"){const Ae=te.prerender;Ae&&(I.setCustomLayerDefaults(),G.setColorMode(I.colorModeForRenderPass()),Ae.call(te,G.gl,I.transform.customLayerMatrix()),G.setDirty(),I.setBaseState())}else if(I.renderPass==="translucent"){I.setCustomLayerDefaults(),G.setColorMode(I.colorModeForRenderPass()),G.setStencilMode(Lo.disabled);const Ae=te.renderingMode==="3d"?new zi(I.context.gl.LEQUAL,zi.ReadWrite,I.depthRangeFor3D):I.depthModeForSublayer(0,zi.ReadOnly);G.setDepthMode(Ae),te.render(G.gl,I.transform.customLayerMatrix()),G.setDirty(),I.setBaseState(),G.bindFramebuffer.set(null)}})(u,0,C)}}translatePosMatrix(u,p,C,M,I){if(!C[0]&&!C[1])return u;const L=I?M==="map"?this.transform.angle:0:M==="viewport"?-this.transform.angle:0;if(L){const te=Math.sin(L),Ae=Math.cos(L);C=[C[0]*Ae-C[1]*te,C[0]*te+C[1]*Ae]}const j=[I?C[0]:qn(p,C[0],this.transform.zoom),I?C[1]:qn(p,C[1],this.transform.zoom),0],G=new Float32Array(16);return a.H(G,u,j),G}saveTileTexture(u){const p=this._tileTextures[u.size[0]];p?p.push(u):this._tileTextures[u.size[0]]=[u]}getTileTexture(u){const p=this._tileTextures[u];return p&&p.length>0?p.pop():null}isPatternMissing(u){if(!u)return!1;if(!u.from||!u.to)return!0;const p=this.imageManager.getPattern(u.from.toString()),C=this.imageManager.getPattern(u.to.toString());return!p||!C}useProgram(u,p){this.cache=this.cache||{};const C=u+(p?p.cacheKey:"")+(this._showOverdrawInspector?"/overdraw":"")+(this.style.map.terrain?"/terrain":"");return this.cache[C]||(this.cache[C]=new ys(this.context,br[u],p,mo[u],this._showOverdrawInspector,this.style.map.terrain)),this.cache[C]}setCustomLayerDefaults(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()}setBaseState(){const u=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(u.FUNC_ADD)}initDebugOverlayCanvas(){this.debugOverlayCanvas==null&&(this.debugOverlayCanvas=document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512,this.debugOverlayTexture=new ct(this.context,this.debugOverlayCanvas,this.context.gl.RGBA))}destroy(){this.debugOverlayTexture&&this.debugOverlayTexture.destroy()}overLimit(){const{drawingBufferWidth:u,drawingBufferHeight:p}=this.context.gl;return this.width!==u||this.height!==p}}class Dd{constructor(u,p){this.points=u,this.planes=p}static fromInvProjectionMatrix(u,p,C){const M=Math.pow(2,C),I=[[-1,1,-1,1],[1,1,-1,1],[1,-1,-1,1],[-1,-1,-1,1],[-1,1,1,1],[1,1,1,1],[1,-1,1,1],[-1,-1,1,1]].map(j=>{const G=1/(j=a.af([],j,u))[3]/p*M;return a.a_(j,j,[G,G,1/j[3],G])}),L=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map(j=>{const G=function(Me,De){var je=De[0],Qe=De[1],Le=De[2],ft=je*je+Qe*Qe+Le*Le;return ft>0&&(ft=1/Math.sqrt(ft)),Me[0]=De[0]*ft,Me[1]=De[1]*ft,Me[2]=De[2]*ft,Me}([],function(Me,De,je){var Qe=De[0],Le=De[1],ft=De[2],Bt=je[0],qe=je[1],_t=je[2];return Me[0]=Le*_t-ft*qe,Me[1]=ft*Bt-Qe*_t,Me[2]=Qe*qe-Le*Bt,Me}([],Re([],I[j[0]],I[j[1]]),Re([],I[j[2]],I[j[1]]))),te=-((Ae=G)[0]*(he=I[j[1]])[0]+Ae[1]*he[1]+Ae[2]*he[2]);var Ae,he;return G.concat(te)});return new Dd(I,L)}}class Sl{constructor(u,p){this.min=u,this.max=p,this.center=function(C,M,I){return C[0]=.5*M[0],C[1]=.5*M[1],C[2]=.5*M[2],C}([],function(C,M,I){return C[0]=M[0]+I[0],C[1]=M[1]+I[1],C[2]=M[2]+I[2],C}([],this.min,this.max))}quadrant(u){const p=[u%2==0,u<2],C=ue(this.min),M=ue(this.max);for(let I=0;I<p.length;I++)C[I]=p[I]?this.min[I]:this.center[I],M[I]=p[I]?this.center[I]:this.max[I];return M[2]=this.max[2],new Sl(C,M)}distanceX(u){return Math.max(Math.min(this.max[0],u[0]),this.min[0])-u[0]}distanceY(u){return Math.max(Math.min(this.max[1],u[1]),this.min[1])-u[1]}intersects(u){const p=[[this.min[0],this.min[1],this.min[2],1],[this.max[0],this.min[1],this.min[2],1],[this.max[0],this.max[1],this.min[2],1],[this.min[0],this.max[1],this.min[2],1],[this.min[0],this.min[1],this.max[2],1],[this.max[0],this.min[1],this.max[2],1],[this.max[0],this.max[1],this.max[2],1],[this.min[0],this.max[1],this.max[2],1]];let C=!0;for(let M=0;M<u.planes.length;M++){const I=u.planes[M];let L=0;for(let j=0;j<p.length;j++)a.a$(I,p[j])>=0&&L++;if(L===0)return 0;L!==p.length&&(C=!1)}if(C)return 2;for(let M=0;M<3;M++){let I=Number.MAX_VALUE,L=-Number.MAX_VALUE;for(let j=0;j<u.points.length;j++){const G=u.points[j][M]-this.min[M];I=Math.min(I,G),L=Math.max(L,G)}if(L<0||I>this.max[M]-this.min[M])return 0}return 1}}class xA{constructor(u=0,p=0,C=0,M=0){if(isNaN(u)||u<0||isNaN(p)||p<0||isNaN(C)||C<0||isNaN(M)||M<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=u,this.bottom=p,this.left=C,this.right=M}interpolate(u,p,C){return p.top!=null&&u.top!=null&&(this.top=a.z.number(u.top,p.top,C)),p.bottom!=null&&u.bottom!=null&&(this.bottom=a.z.number(u.bottom,p.bottom,C)),p.left!=null&&u.left!=null&&(this.left=a.z.number(u.left,p.left,C)),p.right!=null&&u.right!=null&&(this.right=a.z.number(u.right,p.right,C)),this}getCenter(u,p){const C=a.ac((this.left+u-this.right)/2,0,u),M=a.ac((this.top+p-this.bottom)/2,0,p);return new a.P(C,M)}equals(u){return this.top===u.top&&this.bottom===u.bottom&&this.left===u.left&&this.right===u.right}clone(){return new xA(this.top,this.bottom,this.left,this.right)}toJSON(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}}}class Vc{constructor(u,p,C,M,I){this.tileSize=512,this.maxValidLatitude=85.051129,this._renderWorldCopies=I===void 0||!!I,this._minZoom=u||0,this._maxZoom=p||22,this._minPitch=C??0,this._maxPitch=M??60,this.setMaxBounds(),this.width=0,this.height=0,this._center=new a.M(0,0),this._elevation=0,this.zoom=0,this.angle=0,this._fov=.6435011087932844,this._pitch=0,this._unmodified=!0,this._edgeInsets=new xA,this._posMatrixCache={},this._alignedPosMatrixCache={},this.minElevationForCurrentTile=0}clone(){const u=new Vc(this._minZoom,this._maxZoom,this._minPitch,this.maxPitch,this._renderWorldCopies);return u.apply(this),u}apply(u){this.tileSize=u.tileSize,this.latRange=u.latRange,this.width=u.width,this.height=u.height,this._center=u._center,this._elevation=u._elevation,this.minElevationForCurrentTile=u.minElevationForCurrentTile,this.zoom=u.zoom,this.angle=u.angle,this._fov=u._fov,this._pitch=u._pitch,this._unmodified=u._unmodified,this._edgeInsets=u._edgeInsets.clone(),this._calcMatrices()}get minZoom(){return this._minZoom}set minZoom(u){this._minZoom!==u&&(this._minZoom=u,this.zoom=Math.max(this.zoom,u))}get maxZoom(){return this._maxZoom}set maxZoom(u){this._maxZoom!==u&&(this._maxZoom=u,this.zoom=Math.min(this.zoom,u))}get minPitch(){return this._minPitch}set minPitch(u){this._minPitch!==u&&(this._minPitch=u,this.pitch=Math.max(this.pitch,u))}get maxPitch(){return this._maxPitch}set maxPitch(u){this._maxPitch!==u&&(this._maxPitch=u,this.pitch=Math.min(this.pitch,u))}get renderWorldCopies(){return this._renderWorldCopies}set renderWorldCopies(u){u===void 0?u=!0:u===null&&(u=!1),this._renderWorldCopies=u}get worldSize(){return this.tileSize*this.scale}get centerOffset(){return this.centerPoint._sub(this.size._div(2))}get size(){return new a.P(this.width,this.height)}get bearing(){return-this.angle/Math.PI*180}set bearing(u){const p=-a.b0(u,-180,180)*Math.PI/180;this.angle!==p&&(this._unmodified=!1,this.angle=p,this._calcMatrices(),this.rotationMatrix=function(){var C=new a.A(4);return a.A!=Float32Array&&(C[1]=0,C[2]=0),C[0]=1,C[3]=1,C}(),function(C,M,I){var L=M[0],j=M[1],G=M[2],te=M[3],Ae=Math.sin(I),he=Math.cos(I);C[0]=L*he+G*Ae,C[1]=j*he+te*Ae,C[2]=L*-Ae+G*he,C[3]=j*-Ae+te*he}(this.rotationMatrix,this.rotationMatrix,this.angle))}get pitch(){return this._pitch/Math.PI*180}set pitch(u){const p=a.ac(u,this.minPitch,this.maxPitch)/180*Math.PI;this._pitch!==p&&(this._unmodified=!1,this._pitch=p,this._calcMatrices())}get fov(){return this._fov/Math.PI*180}set fov(u){u=Math.max(.01,Math.min(60,u)),this._fov!==u&&(this._unmodified=!1,this._fov=u/180*Math.PI,this._calcMatrices())}get zoom(){return this._zoom}set zoom(u){const p=Math.min(Math.max(u,this.minZoom),this.maxZoom);this._zoom!==p&&(this._unmodified=!1,this._zoom=p,this.tileZoom=Math.max(0,Math.floor(p)),this.scale=this.zoomScale(p),this._constrain(),this._calcMatrices())}get center(){return this._center}set center(u){u.lat===this._center.lat&&u.lng===this._center.lng||(this._unmodified=!1,this._center=u,this._constrain(),this._calcMatrices())}get elevation(){return this._elevation}set elevation(u){u!==this._elevation&&(this._elevation=u,this._constrain(),this._calcMatrices())}get padding(){return this._edgeInsets.toJSON()}set padding(u){this._edgeInsets.equals(u)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,u,1),this._calcMatrices())}get centerPoint(){return this._edgeInsets.getCenter(this.width,this.height)}isPaddingEqual(u){return this._edgeInsets.equals(u)}interpolatePadding(u,p,C){this._unmodified=!1,this._edgeInsets.interpolate(u,p,C),this._constrain(),this._calcMatrices()}coveringZoomLevel(u){const p=(u.roundZoom?Math.round:Math.floor)(this.zoom+this.scaleZoom(this.tileSize/u.tileSize));return Math.max(0,p)}getVisibleUnwrappedCoordinates(u){const p=[new a.b1(0,u)];if(this._renderWorldCopies){const C=this.pointCoordinate(new a.P(0,0)),M=this.pointCoordinate(new a.P(this.width,0)),I=this.pointCoordinate(new a.P(this.width,this.height)),L=this.pointCoordinate(new a.P(0,this.height)),j=Math.floor(Math.min(C.x,M.x,I.x,L.x)),G=Math.floor(Math.max(C.x,M.x,I.x,L.x)),te=1;for(let Ae=j-te;Ae<=G+te;Ae++)Ae!==0&&p.push(new a.b1(Ae,u))}return p}coveringTiles(u){var p,C;let M=this.coveringZoomLevel(u);const I=M;if(u.minzoom!==void 0&&M<u.minzoom)return[];u.maxzoom!==void 0&&M>u.maxzoom&&(M=u.maxzoom);const L=this.pointCoordinate(this.getCameraPoint()),j=a.Y.fromLngLat(this.center),G=Math.pow(2,M),te=[G*L.x,G*L.y,0],Ae=[G*j.x,G*j.y,0],he=Dd.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,M);let Me=u.minzoom||0;!u.terrain&&this.pitch<=60&&this._edgeInsets.top<.1&&(Me=M);const De=u.terrain?2/Math.min(this.tileSize,u.tileSize)*this.tileSize:3,je=qe=>({aabb:new Sl([qe*G,0,0],[(qe+1)*G,G,0]),zoom:0,x:0,y:0,wrap:qe,fullyVisible:!1}),Qe=[],Le=[],ft=M,Bt=u.reparseOverscaled?I:M;if(this._renderWorldCopies)for(let qe=1;qe<=3;qe++)Qe.push(je(-qe)),Qe.push(je(qe));for(Qe.push(je(0));Qe.length>0;){const qe=Qe.pop(),_t=qe.x,Ut=qe.y;let Tt=qe.fullyVisible;if(!Tt){const lr=qe.aabb.intersects(he);if(lr===0)continue;Tt=lr===2}const en=u.terrain?te:Ae,hn=qe.aabb.distanceX(en),An=qe.aabb.distanceY(en),On=Math.max(Math.abs(hn),Math.abs(An));if(qe.zoom===ft||On>De+(1<<ft-qe.zoom)-2&&qe.zoom>=Me){const lr=ft-qe.zoom,xr=te[0]-.5-(_t<<lr),Tn=te[1]-.5-(Ut<<lr);Le.push({tileID:new a.Q(qe.zoom===ft?Bt:qe.zoom,qe.wrap,qe.zoom,_t,Ut),distanceSq:Ne([Ae[0]-.5-_t,Ae[1]-.5-Ut]),tileDistanceToCamera:Math.sqrt(xr*xr+Tn*Tn)})}else for(let lr=0;lr<4;lr++){const xr=(_t<<1)+lr%2,Tn=(Ut<<1)+(lr>>1),yr=qe.zoom+1;let Qn=qe.aabb.quadrant(lr);if(u.terrain){const Ho=new a.Q(yr,qe.wrap,yr,xr,Tn),pi=u.terrain.getMinMaxElevation(Ho),ii=(p=pi.minElevation)!==null&&p!==void 0?p:this.elevation,si=(C=pi.maxElevation)!==null&&C!==void 0?C:this.elevation;Qn=new Sl([Qn.min[0],Qn.min[1],ii],[Qn.max[0],Qn.max[1],si])}Qe.push({aabb:Qn,zoom:yr,x:xr,y:Tn,wrap:qe.wrap,fullyVisible:Tt})}}return Le.sort((qe,_t)=>qe.distanceSq-_t.distanceSq).map(qe=>qe.tileID)}resize(u,p){this.width=u,this.height=p,this.pixelsToGLUnits=[2/u,-2/p],this._constrain(),this._calcMatrices()}get unmodified(){return this._unmodified}zoomScale(u){return Math.pow(2,u)}scaleZoom(u){return Math.log(u)/Math.LN2}project(u){const p=a.ac(u.lat,-this.maxValidLatitude,this.maxValidLatitude);return new a.P(a.N(u.lng)*this.worldSize,a.O(p)*this.worldSize)}unproject(u){return new a.Y(u.x/this.worldSize,u.y/this.worldSize).toLngLat()}get point(){return this.project(this.center)}getCameraPosition(){return{lngLat:this.pointLocation(this.getCameraPoint()),altitude:Math.cos(this._pitch)*this.cameraToCenterDistance/this._pixelPerMeter+this.elevation}}recalculateZoom(u){const p=this.pointLocation(this.centerPoint,u),C=u.getElevationForLngLatZoom(p,this.tileZoom);if(!(this.elevation-C))return;const M=this.getCameraPosition(),I=a.Y.fromLngLat(M.lngLat,M.altitude),L=a.Y.fromLngLat(p,C),j=I.x-L.x,G=I.y-L.y,te=I.z-L.z,Ae=Math.sqrt(j*j+G*G+te*te),he=this.scaleZoom(this.cameraToCenterDistance/Ae/this.tileSize);this._elevation=C,this._center=p,this.zoom=he}setLocationAtPoint(u,p){const C=this.pointCoordinate(p),M=this.pointCoordinate(this.centerPoint),I=this.locationCoordinate(u),L=new a.Y(I.x-(C.x-M.x),I.y-(C.y-M.y));this.center=this.coordinateLocation(L),this._renderWorldCopies&&(this.center=this.center.wrap())}locationPoint(u,p){return p?this.coordinatePoint(this.locationCoordinate(u),p.getElevationForLngLatZoom(u,this.tileZoom),this.pixelMatrix3D):this.coordinatePoint(this.locationCoordinate(u))}pointLocation(u,p){return this.coordinateLocation(this.pointCoordinate(u,p))}locationCoordinate(u){return a.Y.fromLngLat(u)}coordinateLocation(u){return u&&u.toLngLat()}pointCoordinate(u,p){if(p){const Me=p.pointCoordinate(u);if(Me!=null)return Me}const C=[u.x,u.y,0,1],M=[u.x,u.y,1,1];a.af(C,C,this.pixelMatrixInverse),a.af(M,M,this.pixelMatrixInverse);const I=C[3],L=M[3],j=C[1]/I,G=M[1]/L,te=C[2]/I,Ae=M[2]/L,he=te===Ae?0:(0-te)/(Ae-te);return new a.Y(a.z.number(C[0]/I,M[0]/L,he)/this.worldSize,a.z.number(j,G,he)/this.worldSize)}coordinatePoint(u,p=0,C=this.pixelMatrix){const M=[u.x*this.worldSize,u.y*this.worldSize,p,1];return a.af(M,M,C),new a.P(M[0]/M[3],M[1]/M[3])}getBounds(){const u=Math.max(0,this.height/2-this.getHorizon());return new Kt().extend(this.pointLocation(new a.P(0,u))).extend(this.pointLocation(new a.P(this.width,u))).extend(this.pointLocation(new a.P(this.width,this.height))).extend(this.pointLocation(new a.P(0,this.height)))}getMaxBounds(){return this.latRange&&this.latRange.length===2&&this.lngRange&&this.lngRange.length===2?new Kt([this.lngRange[0],this.latRange[0]],[this.lngRange[1],this.latRange[1]]):null}getHorizon(){return Math.tan(Math.PI/2-this._pitch)*this.cameraToCenterDistance*.85}setMaxBounds(u){u?(this.lngRange=[u.getWest(),u.getEast()],this.latRange=[u.getSouth(),u.getNorth()],this._constrain()):(this.lngRange=null,this.latRange=[-this.maxValidLatitude,this.maxValidLatitude])}calculatePosMatrix(u,p=!1){const C=u.key,M=p?this._alignedPosMatrixCache:this._posMatrixCache;if(M[C])return M[C];const I=u.canonical,L=this.worldSize/this.zoomScale(I.z),j=I.x+Math.pow(2,I.z)*u.wrap,G=a.an(new Float64Array(16));return a.H(G,G,[j*L,I.y*L,0]),a.J(G,G,[L/a.W,L/a.W,1]),a.K(G,p?this.alignedProjMatrix:this.projMatrix,G),M[C]=new Float32Array(G),M[C]}customLayerMatrix(){return this.mercatorMatrix.slice()}_constrain(){if(!this.center||!this.width||!this.height||this._constraining)return;this._constraining=!0;let u,p,C,M,I=-90,L=90,j=-180,G=180;const te=this.size,Ae=this._unmodified;if(this.latRange){const De=this.latRange;I=a.O(De[1])*this.worldSize,L=a.O(De[0])*this.worldSize,u=L-I<te.y?te.y/(L-I):0}if(this.lngRange){const De=this.lngRange;j=a.b0(a.N(De[0])*this.worldSize,0,this.worldSize),G=a.b0(a.N(De[1])*this.worldSize,0,this.worldSize),G<j&&(G+=this.worldSize),p=G-j<te.x?te.x/(G-j):0}const he=this.point,Me=Math.max(p||0,u||0);if(Me)return this.center=this.unproject(new a.P(p?(G+j)/2:he.x,u?(L+I)/2:he.y)),this.zoom+=this.scaleZoom(Me),this._unmodified=Ae,void(this._constraining=!1);if(this.latRange){const De=he.y,je=te.y/2;De-je<I&&(M=I+je),De+je>L&&(M=L-je)}if(this.lngRange){const De=(j+G)/2,je=a.b0(he.x,De-this.worldSize/2,De+this.worldSize/2),Qe=te.x/2;je-Qe<j&&(C=j+Qe),je+Qe>G&&(C=G-Qe)}C===void 0&&M===void 0||(this.center=this.unproject(new a.P(C!==void 0?C:he.x,M!==void 0?M:he.y)).wrap()),this._unmodified=Ae,this._constraining=!1}_calcMatrices(){if(!this.height)return;const u=this.centerOffset,p=this.point.x,C=this.point.y;this.cameraToCenterDistance=.5/Math.tan(this._fov/2)*this.height,this._pixelPerMeter=a.b2(1,this.center.lat)*this.worldSize;let M=a.an(new Float64Array(16));a.J(M,M,[this.width/2,-this.height/2,1]),a.H(M,M,[1,-1,0]),this.labelPlaneMatrix=M,M=a.an(new Float64Array(16)),a.J(M,M,[1,-1,1]),a.H(M,M,[-1,-1,0]),a.J(M,M,[2/this.width,2/this.height,1]),this.glCoordMatrix=M;const I=this.cameraToCenterDistance+this._elevation*this._pixelPerMeter/Math.cos(this._pitch),L=Math.min(this.elevation,this.minElevationForCurrentTile),j=I-L*this._pixelPerMeter/Math.cos(this._pitch),G=L<0?j:I,te=Math.PI/2+this._pitch,Ae=this._fov*(.5+u.y/this.height),he=Math.sin(Ae)*G/Math.sin(a.ac(Math.PI-te-Ae,.01,Math.PI-.01)),Me=this.getHorizon(),De=2*Math.atan(Me/this.cameraToCenterDistance)*(.5+u.y/(2*Me)),je=Math.sin(De)*G/Math.sin(a.ac(Math.PI-te-De,.01,Math.PI-.01)),Qe=Math.min(he,je),Le=1.01*(Math.cos(Math.PI/2-this._pitch)*Qe+G),ft=this.height/50;M=new Float64Array(16),a.b3(M,this._fov,this.width/this.height,ft,Le),M[8]=2*-u.x/this.width,M[9]=2*u.y/this.height,a.J(M,M,[1,-1,1]),a.H(M,M,[0,0,-this.cameraToCenterDistance]),a.b4(M,M,this._pitch),a.ad(M,M,this.angle),a.H(M,M,[-p,-C,0]),this.mercatorMatrix=a.J([],M,[this.worldSize,this.worldSize,this.worldSize]),a.J(M,M,[1,1,this._pixelPerMeter]),this.pixelMatrix=a.K(new Float64Array(16),this.labelPlaneMatrix,M),a.H(M,M,[0,0,-this.elevation]),this.projMatrix=M,this.invProjMatrix=a.ar([],M),this.pixelMatrix3D=a.K(new Float64Array(16),this.labelPlaneMatrix,M);const Bt=this.width%2/2,qe=this.height%2/2,_t=Math.cos(this.angle),Ut=Math.sin(this.angle),Tt=p-Math.round(p)+_t*Bt+Ut*qe,en=C-Math.round(C)+_t*qe+Ut*Bt,hn=new Float64Array(M);if(a.H(hn,hn,[Tt>.5?Tt-1:Tt,en>.5?en-1:en,0]),this.alignedProjMatrix=hn,M=a.ar(new Float64Array(16),this.pixelMatrix),!M)throw new Error("failed to invert matrix");this.pixelMatrixInverse=M,this._posMatrixCache={},this._alignedPosMatrixCache={}}maxPitchScaleFactor(){if(!this.pixelMatrixInverse)return 1;const u=this.pointCoordinate(new a.P(0,0)),p=[u.x*this.worldSize,u.y*this.worldSize,0,1];return a.af(p,p,this.pixelMatrix)[3]/this.cameraToCenterDistance}getCameraPoint(){const u=Math.tan(this._pitch)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new a.P(0,u))}getCameraQueryGeometry(u){const p=this.getCameraPoint();if(u.length===1)return[u[0],p];{let C=p.x,M=p.y,I=p.x,L=p.y;for(const j of u)C=Math.min(C,j.x),M=Math.min(M,j.y),I=Math.max(I,j.x),L=Math.max(L,j.y);return[new a.P(C,M),new a.P(I,M),new a.P(I,L),new a.P(C,L),new a.P(C,M)]}}lngLatToCameraDepth(u,p){const C=this.locationCoordinate(u),M=[C.x*this.worldSize,C.y*this.worldSize,p,1];return a.af(M,M,this.projMatrix),M[2]/M[3]}}function Ud(O,u){let p,C=!1,M=null,I=null;const L=()=>{M=null,C&&(O.apply(I,p),M=setTimeout(L,u),C=!1)};return(...j)=>(C=!0,I=this,p=j,M||L(),M)}class ku{constructor(u){this._getCurrentHash=()=>{const p=window.location.hash.replace("#","");if(this._hashName){let C;return p.split("&").map(M=>M.split("=")).forEach(M=>{M[0]===this._hashName&&(C=M)}),(C&&C[1]||"").split("/")}return p.split("/")},this._onHashChange=()=>{const p=this._getCurrentHash();if(p.length>=3&&!p.some(C=>isNaN(C))){const C=this._map.dragRotate.isEnabled()&&this._map.touchZoomRotate.isEnabled()?+(p[3]||0):this._map.getBearing();return this._map.jumpTo({center:[+p[2],+p[1]],zoom:+p[0],bearing:C,pitch:+(p[4]||0)}),!0}return!1},this._updateHashUnthrottled=()=>{const p=window.location.href.replace(/(#.+)?$/,this.getHashString());try{window.history.replaceState(window.history.state,null,p)}catch{}},this._updateHash=Ud(this._updateHashUnthrottled,300),this._hashName=u&&encodeURIComponent(u)}addTo(u){return this._map=u,addEventListener("hashchange",this._onHashChange,!1),this._map.on("moveend",this._updateHash),this}remove(){return removeEventListener("hashchange",this._onHashChange,!1),this._map.off("moveend",this._updateHash),clearTimeout(this._updateHash()),delete this._map,this}getHashString(u){const p=this._map.getCenter(),C=Math.round(100*this._map.getZoom())/100,M=Math.ceil((C*Math.LN2+Math.log(512/360/.5))/Math.LN10),I=Math.pow(10,M),L=Math.round(p.lng*I)/I,j=Math.round(p.lat*I)/I,G=this._map.getBearing(),te=this._map.getPitch();let Ae="";if(Ae+=u?`/${L}/${j}/${C}`:`${C}/${j}/${L}`,(G||te)&&(Ae+="/"+Math.round(10*G)/10),te&&(Ae+=`/${Math.round(te)}`),this._hashName){const he=this._hashName;let Me=!1;const De=window.location.hash.slice(1).split("&").map(je=>{const Qe=je.split("=")[0];return Qe===he?(Me=!0,`${Qe}=${Ae}`):je}).filter(je=>je);return Me||De.push(`${he}=${Ae}`),`#${De.join("&")}`}return`#${Ae}`}}const xt={linearity:.3,easing:a.b5(0,0,.3,1)},sn=a.e({deceleration:2500,maxSpeed:1400},xt),Wt=a.e({deceleration:20,maxSpeed:1400},xt),or=a.e({deceleration:1e3,maxSpeed:360},xt),ri=a.e({deceleration:1e3,maxSpeed:90},xt);class to{constructor(u){this._map=u,this.clear()}clear(){this._inertiaBuffer=[]}record(u){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:k.now(),settings:u})}_drainInertiaBuffer(){const u=this._inertiaBuffer,p=k.now();for(;u.length>0&&p-u[0].time>160;)u.shift()}_onMoveEnd(u){if(this._drainInertiaBuffer(),this._inertiaBuffer.length<2)return;const p={zoom:0,bearing:0,pitch:0,pan:new a.P(0,0),pinchAround:void 0,around:void 0};for(const{settings:I}of this._inertiaBuffer)p.zoom+=I.zoomDelta||0,p.bearing+=I.bearingDelta||0,p.pitch+=I.pitchDelta||0,I.panDelta&&p.pan._add(I.panDelta),I.around&&(p.around=I.around),I.pinchAround&&(p.pinchAround=I.pinchAround);const C=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,M={};if(p.pan.mag()){const I=ho(p.pan.mag(),C,a.e({},sn,u||{}));M.offset=p.pan.mult(I.amount/p.pan.mag()),M.center=this._map.transform.center,ia(M,I)}if(p.zoom){const I=ho(p.zoom,C,Wt);M.zoom=this._map.transform.zoom+I.amount,ia(M,I)}if(p.bearing){const I=ho(p.bearing,C,or);M.bearing=this._map.transform.bearing+a.ac(I.amount,-179,179),ia(M,I)}if(p.pitch){const I=ho(p.pitch,C,ri);M.pitch=this._map.transform.pitch+I.amount,ia(M,I)}if(M.zoom||M.bearing){const I=p.pinchAround===void 0?p.around:p.pinchAround;M.around=I?this._map.unproject(I):this._map.getCenter()}return this.clear(),a.e(M,{noMoveStart:!0})}}function ia(O,u){(!O.duration||O.duration<u.duration)&&(O.duration=u.duration,O.easing=u.easing)}function ho(O,u,p){const{maxSpeed:C,linearity:M,deceleration:I}=p,L=a.ac(O*M/(u/1e3),-C,C),j=Math.abs(L)/(I*M);return{easing:p.easing,duration:1e3*j,amount:L*(j/2)}}class xs extends a.k{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(u,p,C,M={}){const I=B.mousePos(p.getCanvas(),C),L=p.unproject(I);super(u,a.e({point:I,lngLat:L,originalEvent:C},M)),this._defaultPrevented=!1,this.target=p}}class Rd extends a.k{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(u,p,C){const M=u==="touchend"?C.changedTouches:C.touches,I=B.touchPos(p.getCanvasContainer(),M),L=I.map(G=>p.unproject(G)),j=I.reduce((G,te,Ae,he)=>G.add(te.div(he.length)),new a.P(0,0));super(u,{points:I,point:j,lngLats:L,lngLat:p.unproject(j),originalEvent:C}),this._defaultPrevented=!1}}class El extends a.k{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(u,p,C){super(u,{originalEvent:C}),this._defaultPrevented=!1}}class tA{constructor(u,p){this._map=u,this._clickTolerance=p.clickTolerance}reset(){delete this._mousedownPos}wheel(u){return this._firePreventable(new El(u.type,this._map,u))}mousedown(u,p){return this._mousedownPos=p,this._firePreventable(new xs(u.type,this._map,u))}mouseup(u){this._map.fire(new xs(u.type,this._map,u))}click(u,p){this._mousedownPos&&this._mousedownPos.dist(p)>=this._clickTolerance||this._map.fire(new xs(u.type,this._map,u))}dblclick(u){return this._firePreventable(new xs(u.type,this._map,u))}mouseover(u){this._map.fire(new xs(u.type,this._map,u))}mouseout(u){this._map.fire(new xs(u.type,this._map,u))}touchstart(u){return this._firePreventable(new Rd(u.type,this._map,u))}touchmove(u){this._map.fire(new Rd(u.type,this._map,u))}touchend(u){this._map.fire(new Rd(u.type,this._map,u))}touchcancel(u){this._map.fire(new Rd(u.type,this._map,u))}_firePreventable(u){if(this._map.fire(u),u.defaultPrevented)return{}}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class wA{constructor(u){this._map=u}reset(){this._delayContextMenu=!1,this._ignoreContextMenu=!0,delete this._contextMenuEvent}mousemove(u){this._map.fire(new xs(u.type,this._map,u))}mousedown(){this._delayContextMenu=!0,this._ignoreContextMenu=!1}mouseup(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new xs("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)}contextmenu(u){this._delayContextMenu?this._contextMenuEvent=u:this._ignoreContextMenu||this._map.fire(new xs(u.type,this._map,u)),this._map.listens("contextmenu")&&u.preventDefault()}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class Jo{constructor(u){this._map=u}get transform(){return this._map._requestedCameraState||this._map.transform}get center(){return{lng:this.transform.center.lng,lat:this.transform.center.lat}}get zoom(){return this.transform.zoom}get pitch(){return this.transform.pitch}get bearing(){return this.transform.bearing}unproject(u){return this.transform.pointLocation(a.P.convert(u),this._map.terrain)}}class ls{constructor(u,p){this._map=u,this._tr=new Jo(u),this._el=u.getCanvasContainer(),this._container=u.getContainer(),this._clickTolerance=p.clickTolerance||1}isEnabled(){return!!this._enabled}isActive(){return!!this._active}enable(){this.isEnabled()||(this._enabled=!0)}disable(){this.isEnabled()&&(this._enabled=!1)}mousedown(u,p){this.isEnabled()&&u.shiftKey&&u.button===0&&(B.disableDrag(),this._startPos=this._lastPos=p,this._active=!0)}mousemoveWindow(u,p){if(!this._active)return;const C=p;if(this._lastPos.equals(C)||!this._box&&C.dist(this._startPos)<this._clickTolerance)return;const M=this._startPos;this._lastPos=C,this._box||(this._box=B.create("div","maplibregl-boxzoom",this._container),this._container.classList.add("maplibregl-crosshair"),this._fireEvent("boxzoomstart",u));const I=Math.min(M.x,C.x),L=Math.max(M.x,C.x),j=Math.min(M.y,C.y),G=Math.max(M.y,C.y);B.setTransform(this._box,`translate(${I}px,${j}px)`),this._box.style.width=L-I+"px",this._box.style.height=G-j+"px"}mouseupWindow(u,p){if(!this._active||u.button!==0)return;const C=this._startPos,M=p;if(this.reset(),B.suppressClick(),C.x!==M.x||C.y!==M.y)return this._map.fire(new a.k("boxzoomend",{originalEvent:u})),{cameraAnimation:I=>I.fitScreenCoordinates(C,M,this._tr.bearing,{linear:!0})};this._fireEvent("boxzoomcancel",u)}keydown(u){this._active&&u.keyCode===27&&(this.reset(),this._fireEvent("boxzoomcancel",u))}reset(){this._active=!1,this._container.classList.remove("maplibregl-crosshair"),this._box&&(B.remove(this._box),this._box=null),B.enableDrag(),delete this._startPos,delete this._lastPos}_fireEvent(u,p){return this._map.fire(new a.k(u,{originalEvent:p}))}}function nA(O,u){if(O.length!==u.length)throw new Error(`The number of touches and points are not equal - touches ${O.length}, points ${u.length}`);const p={};for(let C=0;C<O.length;C++)p[O[C].identifier]=u[C];return p}class Ei{constructor(u){this.reset(),this.numTouches=u.numTouches}reset(){delete this.centroid,delete this.startTime,delete this.touches,this.aborted=!1}touchstart(u,p,C){(this.centroid||C.length>this.numTouches)&&(this.aborted=!0),this.aborted||(this.startTime===void 0&&(this.startTime=u.timeStamp),C.length===this.numTouches&&(this.centroid=function(M){const I=new a.P(0,0);for(const L of M)I._add(L);return I.div(M.length)}(p),this.touches=nA(C,p)))}touchmove(u,p,C){if(this.aborted||!this.centroid)return;const M=nA(C,p);for(const I in this.touches){const L=M[I];(!L||L.dist(this.touches[I])>30)&&(this.aborted=!0)}}touchend(u,p,C){if((!this.centroid||u.timeStamp-this.startTime>500)&&(this.aborted=!0),C.length===0){const M=!this.aborted&&this.centroid;if(this.reset(),M)return M}}}class MA{constructor(u){this.singleTap=new Ei(u),this.numTaps=u.numTaps,this.reset()}reset(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()}touchstart(u,p,C){this.singleTap.touchstart(u,p,C)}touchmove(u,p,C){this.singleTap.touchmove(u,p,C)}touchend(u,p,C){const M=this.singleTap.touchend(u,p,C);if(M){const I=u.timeStamp-this.lastTime<500,L=!this.lastTap||this.lastTap.dist(M)<30;if(I&&L||this.reset(),this.count++,this.lastTime=u.timeStamp,this.lastTap=M,this.count===this.numTaps)return this.reset(),M}}}class Mh{constructor(u){this._tr=new Jo(u),this._zoomIn=new MA({numTouches:1,numTaps:2}),this._zoomOut=new MA({numTouches:2,numTaps:1}),this.reset()}reset(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()}touchstart(u,p,C){this._zoomIn.touchstart(u,p,C),this._zoomOut.touchstart(u,p,C)}touchmove(u,p,C){this._zoomIn.touchmove(u,p,C),this._zoomOut.touchmove(u,p,C)}touchend(u,p,C){const M=this._zoomIn.touchend(u,p,C),I=this._zoomOut.touchend(u,p,C),L=this._tr;return M?(this._active=!0,u.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:j=>j.easeTo({duration:300,zoom:L.zoom+1,around:L.unproject(M)},{originalEvent:u})}):I?(this._active=!0,u.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:j=>j.easeTo({duration:300,zoom:L.zoom-1,around:L.unproject(I)},{originalEvent:u})}):void 0}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Al{constructor(u){this._enabled=!!u.enable,this._moveStateManager=u.moveStateManager,this._clickTolerance=u.clickTolerance||1,this._moveFunction=u.move,this._activateOnStart=!!u.activateOnStart,u.assignEvents(this),this.reset()}reset(u){this._active=!1,this._moved=!1,delete this._lastPoint,this._moveStateManager.endMove(u)}_move(...u){const p=this._moveFunction(...u);if(p.bearingDelta||p.pitchDelta||p.around||p.panDelta)return this._active=!0,p}dragStart(u,p){this.isEnabled()&&!this._lastPoint&&this._moveStateManager.isValidStartEvent(u)&&(this._moveStateManager.startMove(u),this._lastPoint=p.length?p[0]:p,this._activateOnStart&&this._lastPoint&&(this._active=!0))}dragMove(u,p){if(!this.isEnabled())return;const C=this._lastPoint;if(!C)return;if(u.preventDefault(),!this._moveStateManager.isValidMoveEvent(u))return void this.reset(u);const M=p.length?p[0]:p;return!this._moved&&M.dist(C)<this._clickTolerance?void 0:(this._moved=!0,this._lastPoint=M,this._move(C,M))}dragEnd(u){this.isEnabled()&&this._lastPoint&&this._moveStateManager.isValidEndEvent(u)&&(this._moved&&B.suppressClick(),this.reset(u))}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}getClickTolerance(){return this._clickTolerance}}const ic={0:1,2:2};class us{constructor(u){this._correctEvent=u.checkCorrectEvent}startMove(u){const p=B.mouseButton(u);this._eventButton=p}endMove(u){delete this._eventButton}isValidStartEvent(u){return this._correctEvent(u)}isValidMoveEvent(u){return!function(p,C){const M=ic[C];return p.buttons===void 0||(p.buttons&M)!==M}(u,this._eventButton)}isValidEndEvent(u){return B.mouseButton(u)===this._eventButton}}class Ol{constructor(){this._firstTouch=void 0}_isOneFingerTouch(u){return u.targetTouches.length===1}_isSameTouchEvent(u){return u.targetTouches[0].identifier===this._firstTouch}startMove(u){this._firstTouch=u.targetTouches[0].identifier}endMove(u){delete this._firstTouch}isValidStartEvent(u){return this._isOneFingerTouch(u)}isValidMoveEvent(u){return this._isOneFingerTouch(u)&&this._isSameTouchEvent(u)}isValidEndEvent(u){return this._isOneFingerTouch(u)&&this._isSameTouchEvent(u)}}const Fa=O=>{O.mousedown=O.dragStart,O.mousemoveWindow=O.dragMove,O.mouseup=O.dragEnd,O.contextmenu=function(u){u.preventDefault()}},jn=({enable:O,clickTolerance:u,bearingDegreesPerPixelMoved:p=.8})=>{const C=new us({checkCorrectEvent:M=>B.mouseButton(M)===0&&M.ctrlKey||B.mouseButton(M)===2});return new Al({clickTolerance:u,move:(M,I)=>({bearingDelta:(I.x-M.x)*p}),moveStateManager:C,enable:O,assignEvents:Fa})},Hc=({enable:O,clickTolerance:u,pitchDegreesPerPixelMoved:p=-.5})=>{const C=new us({checkCorrectEvent:M=>B.mouseButton(M)===0&&M.ctrlKey||B.mouseButton(M)===2});return new Al({clickTolerance:u,move:(M,I)=>({pitchDelta:(I.y-M.y)*p}),moveStateManager:C,enable:O,assignEvents:Fa})};class oc{constructor(u,p){this._clickTolerance=u.clickTolerance||1,this._map=p,this.reset()}reset(){this._active=!1,this._touches={},this._sum=new a.P(0,0)}minTouchs(){return this._map.cooperativeGestures.isEnabled()?2:1}touchstart(u,p,C){return this._calculateTransform(u,p,C)}touchmove(u,p,C){if(this._active&&!(C.length<this.minTouchs()))return u.preventDefault(),this._calculateTransform(u,p,C)}touchend(u,p,C){this._calculateTransform(u,p,C),this._active&&C.length<this.minTouchs()&&this.reset()}touchcancel(){this.reset()}_calculateTransform(u,p,C){C.length>0&&(this._active=!0);const M=nA(C,p),I=new a.P(0,0),L=new a.P(0,0);let j=0;for(const te in M){const Ae=M[te],he=this._touches[te];he&&(I._add(Ae),L._add(Ae.sub(he)),j++,M[te]=Ae)}if(this._touches=M,j<this.minTouchs()||!L.mag())return;const G=L.div(j);return this._sum._add(G),this._sum.mag()<this._clickTolerance?void 0:{around:I.div(j),panDelta:G}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class cl{constructor(){this.reset()}reset(){this._active=!1,delete this._firstTwoTouches}touchstart(u,p,C){this._firstTwoTouches||C.length<2||(this._firstTwoTouches=[C[0].identifier,C[1].identifier],this._start([p[0],p[1]]))}touchmove(u,p,C){if(!this._firstTwoTouches)return;u.preventDefault();const[M,I]=this._firstTwoTouches,L=ac(C,p,M),j=ac(C,p,I);if(!L||!j)return;const G=this._aroundCenter?null:L.add(j).div(2);return this._move([L,j],G,u)}touchend(u,p,C){if(!this._firstTwoTouches)return;const[M,I]=this._firstTwoTouches,L=ac(C,p,M),j=ac(C,p,I);L&&j||(this._active&&B.suppressClick(),this.reset())}touchcancel(){this.reset()}enable(u){this._enabled=!0,this._aroundCenter=!!u&&u.around==="center"}disable(){this._enabled=!1,this.reset()}isEnabled(){return!!this._enabled}isActive(){return!!this._active}}function ac(O,u,p){for(let C=0;C<O.length;C++)if(O[C].identifier===p)return u[C]}function Nn(O,u){return Math.log(O/u)/Math.LN2}class rA extends cl{reset(){super.reset(),delete this._distance,delete this._startDistance}_start(u){this._startDistance=this._distance=u[0].dist(u[1])}_move(u,p){const C=this._distance;if(this._distance=u[0].dist(u[1]),this._active||!(Math.abs(Nn(this._distance,this._startDistance))<.1))return this._active=!0,{zoomDelta:Nn(this._distance,C),pinchAround:p}}}function Sf(O,u){return 180*O.angleWith(u)/Math.PI}class sc extends cl{reset(){super.reset(),delete this._minDiameter,delete this._startVector,delete this._vector}_start(u){this._startVector=this._vector=u[0].sub(u[1]),this._minDiameter=u[0].dist(u[1])}_move(u,p,C){const M=this._vector;if(this._vector=u[0].sub(u[1]),this._active||!this._isBelowThreshold(this._vector))return this._active=!0,{bearingDelta:Sf(this._vector,M),pinchAround:p}}_isBelowThreshold(u){this._minDiameter=Math.min(this._minDiameter,u.mag());const p=25/(Math.PI*this._minDiameter)*360,C=Sf(u,this._startVector);return Math.abs(C)<p}}function Vl(O){return Math.abs(O.y)>Math.abs(O.x)}class lc extends cl{constructor(u){super(),this._currentTouchCount=0,this._map=u}reset(){super.reset(),this._valid=void 0,delete this._firstMove,delete this._lastPoints}touchstart(u,p,C){super.touchstart(u,p,C),this._currentTouchCount=C.length}_start(u){this._lastPoints=u,Vl(u[0].sub(u[1]))&&(this._valid=!1)}_move(u,p,C){if(this._map.cooperativeGestures.isEnabled()&&this._currentTouchCount<3)return;const M=u[0].sub(this._lastPoints[0]),I=u[1].sub(this._lastPoints[1]);return this._valid=this.gestureBeginsVertically(M,I,C.timeStamp),this._valid?(this._lastPoints=u,this._active=!0,{pitchDelta:(M.y+I.y)/2*-.5}):void 0}gestureBeginsVertically(u,p,C){if(this._valid!==void 0)return this._valid;const M=u.mag()>=2,I=p.mag()>=2;if(!M&&!I)return;if(!M||!I)return this._firstMove===void 0&&(this._firstMove=C),C-this._firstMove<100&&void 0;const L=u.y>0==p.y>0;return Vl(u)&&Vl(p)&&L}}const Sh={panStep:100,bearingStep:15,pitchStep:10};class Zc{constructor(u){this._tr=new Jo(u);const p=Sh;this._panStep=p.panStep,this._bearingStep=p.bearingStep,this._pitchStep=p.pitchStep,this._rotationDisabled=!1}reset(){this._active=!1}keydown(u){if(u.altKey||u.ctrlKey||u.metaKey)return;let p=0,C=0,M=0,I=0,L=0;switch(u.keyCode){case 61:case 107:case 171:case 187:p=1;break;case 189:case 109:case 173:p=-1;break;case 37:u.shiftKey?C=-1:(u.preventDefault(),I=-1);break;case 39:u.shiftKey?C=1:(u.preventDefault(),I=1);break;case 38:u.shiftKey?M=1:(u.preventDefault(),L=-1);break;case 40:u.shiftKey?M=-1:(u.preventDefault(),L=1);break;default:return}return this._rotationDisabled&&(C=0,M=0),{cameraAnimation:j=>{const G=this._tr;j.easeTo({duration:300,easeId:"keyboardHandler",easing:Eh,zoom:p?Math.round(G.zoom)+p*(u.shiftKey?2:1):G.zoom,bearing:G.bearing+C*this._bearingStep,pitch:G.pitch+M*this._pitchStep,offset:[-I*this._panStep,-L*this._panStep],center:G.center},{originalEvent:u})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}disableRotation(){this._rotationDisabled=!0}enableRotation(){this._rotationDisabled=!1}}function Eh(O){return O*(2-O)}const Hl=4.000244140625;class go{constructor(u,p){this._onTimeout=C=>{this._type="wheel",this._delta-=this._lastValue,this._active||this._start(C)},this._map=u,this._tr=new Jo(u),this._triggerRenderFrame=p,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=.0022222222222222222}setZoomRate(u){this._defaultZoomRate=u}setWheelZoomRate(u){this._wheelZoomRate=u}isEnabled(){return!!this._enabled}isActive(){return!!this._active||this._finishTimeout!==void 0}isZooming(){return!!this._zooming}enable(u){this.isEnabled()||(this._enabled=!0,this._aroundCenter=!!u&&u.around==="center")}disable(){this.isEnabled()&&(this._enabled=!1)}wheel(u){if(!this.isEnabled()||this._map.cooperativeGestures.isEnabled()&&!u[this._map.cooperativeGestures._bypassKey])return;let p=u.deltaMode===WheelEvent.DOM_DELTA_LINE?40*u.deltaY:u.deltaY;const C=k.now(),M=C-(this._lastWheelEventTime||0);this._lastWheelEventTime=C,p!==0&&p%Hl==0?this._type="wheel":p!==0&&Math.abs(p)<4?this._type="trackpad":M>400?(this._type=null,this._lastValue=p,this._timeout=setTimeout(this._onTimeout,40,u)):this._type||(this._type=Math.abs(M*p)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,p+=this._lastValue)),u.shiftKey&&p&&(p/=4),this._type&&(this._lastWheelEvent=u,this._delta-=p,this._active||this._start(u)),u.preventDefault()}_start(u){if(!this._delta)return;this._frameId&&(this._frameId=null),this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);const p=B.mousePos(this._map.getCanvas(),u),C=this._tr;this._around=a.M.convert(this._aroundCenter?C.center:C.unproject(p)),this._aroundPoint=C.transform.locationPoint(this._around),this._frameId||(this._frameId=!0,this._triggerRenderFrame())}renderFrame(){if(!this._frameId||(this._frameId=null,!this.isActive()))return;const u=this._tr.transform;if(this._delta!==0){const j=this._type==="wheel"&&Math.abs(this._delta)>Hl?this._wheelZoomRate:this._defaultZoomRate;let G=2/(1+Math.exp(-Math.abs(this._delta*j)));this._delta<0&&G!==0&&(G=1/G);const te=typeof this._targetZoom=="number"?u.zoomScale(this._targetZoom):u.scale;this._targetZoom=Math.min(u.maxZoom,Math.max(u.minZoom,u.scaleZoom(te*G))),this._type==="wheel"&&(this._startZoom=u.zoom,this._easing=this._smoothOutEasing(200)),this._delta=0}const p=typeof this._targetZoom=="number"?this._targetZoom:u.zoom,C=this._startZoom,M=this._easing;let I,L=!1;if(this._type==="wheel"&&C&&M){const j=Math.min((k.now()-this._lastWheelEventTime)/200,1),G=M(j);I=a.z.number(C,p,G),j<1?this._frameId||(this._frameId=!0):L=!0}else I=p,L=!0;return this._active=!0,L&&(this._active=!1,this._finishTimeout=setTimeout(()=>{this._zooming=!1,this._triggerRenderFrame(),delete this._targetZoom,delete this._finishTimeout},200)),{noInertia:!0,needsRenderFrame:!L,zoomDelta:I-u.zoom,around:this._aroundPoint,originalEvent:this._lastWheelEvent}}_smoothOutEasing(u){let p=a.b6;if(this._prevEase){const C=this._prevEase,M=(k.now()-C.start)/C.duration,I=C.easing(M+.01)-C.easing(M),L=.27/Math.sqrt(I*I+1e-4)*.01,j=Math.sqrt(.0729-L*L);p=a.b5(L,j,.25,1)}return this._prevEase={start:k.now(),duration:u,easing:p},p}reset(){this._active=!1,this._zooming=!1,delete this._targetZoom,this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout)}}class Xc{constructor(u,p){this._clickZoom=u,this._tapZoom=p}enable(){this._clickZoom.enable(),this._tapZoom.enable()}disable(){this._clickZoom.disable(),this._tapZoom.disable()}isEnabled(){return this._clickZoom.isEnabled()&&this._tapZoom.isEnabled()}isActive(){return this._clickZoom.isActive()||this._tapZoom.isActive()}}class Ef{constructor(u){this._tr=new Jo(u),this.reset()}reset(){this._active=!1}dblclick(u,p){return u.preventDefault(),{cameraAnimation:C=>{C.easeTo({duration:300,zoom:this._tr.zoom+(u.shiftKey?-1:1),around:this._tr.unproject(p)},{originalEvent:u})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Of{constructor(){this._tap=new MA({numTouches:1,numTaps:1}),this.reset()}reset(){this._active=!1,delete this._swipePoint,delete this._swipeTouch,delete this._tapTime,delete this._tapPoint,this._tap.reset()}touchstart(u,p,C){if(!this._swipePoint)if(this._tapTime){const M=p[0],I=u.timeStamp-this._tapTime<500,L=this._tapPoint.dist(M)<30;I&&L?C.length>0&&(this._swipePoint=M,this._swipeTouch=C[0].identifier):this.reset()}else this._tap.touchstart(u,p,C)}touchmove(u,p,C){if(this._tapTime){if(this._swipePoint){if(C[0].identifier!==this._swipeTouch)return;const M=p[0],I=M.y-this._swipePoint.y;return this._swipePoint=M,u.preventDefault(),this._active=!0,{zoomDelta:I/128}}}else this._tap.touchmove(u,p,C)}touchend(u,p,C){if(this._tapTime)this._swipePoint&&C.length===0&&this.reset();else{const M=this._tap.touchend(u,p,C);M&&(this._tapTime=u.timeStamp,this._tapPoint=M)}}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Oh{constructor(u,p,C){this._el=u,this._mousePan=p,this._touchPan=C}enable(u){this._inertiaOptions=u||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("maplibregl-touch-drag-pan")}disable(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("maplibregl-touch-drag-pan")}isEnabled(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()}isActive(){return this._mousePan.isActive()||this._touchPan.isActive()}}class Bh{constructor(u,p,C){this._pitchWithRotate=u.pitchWithRotate,this._mouseRotate=p,this._mousePitch=C}enable(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable()}disable(){this._mouseRotate.disable(),this._mousePitch.disable()}isEnabled(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())}isActive(){return this._mouseRotate.isActive()||this._mousePitch.isActive()}}class oa{constructor(u,p,C,M){this._el=u,this._touchZoom=p,this._touchRotate=C,this._tapDragZoom=M,this._rotationDisabled=!1,this._enabled=!0}enable(u){this._touchZoom.enable(u),this._rotationDisabled||this._touchRotate.enable(u),this._tapDragZoom.enable(),this._el.classList.add("maplibregl-touch-zoom-rotate")}disable(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("maplibregl-touch-zoom-rotate")}isEnabled(){return this._touchZoom.isEnabled()&&(this._rotationDisabled||this._touchRotate.isEnabled())&&this._tapDragZoom.isEnabled()}isActive(){return this._touchZoom.isActive()||this._touchRotate.isActive()||this._tapDragZoom.isActive()}disableRotation(){this._rotationDisabled=!0,this._touchRotate.disable()}enableRotation(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()}}class Eo{constructor(u,p={}){this._bypassKey=navigator.userAgent.indexOf("Mac")!==-1?"metaKey":"ctrlKey",this._map=u,this._options=p,this._enabled=!1}isActive(){return!1}reset(){}_setupUI(){if(this._container)return;const u=this._map.getCanvasContainer();u.classList.add("maplibregl-cooperative-gestures"),this._container=B.create("div","maplibregl-cooperative-gesture-screen",u);let p=typeof this._options!="boolean"&&this._options.windowsHelpText?this._options.windowsHelpText:"Use Ctrl + scroll to zoom the map";this._bypassKey==="metaKey"&&(p=typeof this._options!="boolean"&&this._options.macHelpText?this._options.macHelpText:"Use ⌘ + scroll to zoom the map");const C=typeof this._options!="boolean"&&this._options.mobileHelpText?this._options.mobileHelpText:"Use two fingers to move the map, three to pitch",M=document.createElement("div");M.className="maplibregl-desktop-message",M.textContent=p,this._container.appendChild(M);const I=document.createElement("div");I.className="maplibregl-mobile-message",I.textContent=C,this._container.appendChild(I),this._container.setAttribute("aria-hidden","true")}_destoryUI(){this._container&&(B.remove(this._container),this._map.getCanvasContainer().classList.remove("maplibregl-cooperative-gestures")),delete this._container}enable(){this._setupUI(),this._enabled=!0}disable(){this._enabled=!1,this._destoryUI()}isEnabled(){return this._enabled}touchmove(u){this._onCooperativeGesture(u.touches.length===1)}wheel(u){this._map.scrollZoom.isEnabled()&&this._onCooperativeGesture(!u[this._bypassKey])}_onCooperativeGesture(u){this._enabled&&u&&(this._container.classList.add("maplibregl-show"),setTimeout(()=>{this._container.classList.remove("maplibregl-show")},100))}}const uc=O=>O.zoom||O.drag||O.pitch||O.rotate;class gr extends a.k{}function Or(O){return O.panDelta&&O.panDelta.mag()||O.zoomDelta||O.bearingDelta||O.pitchDelta}class SA{constructor(u,p){this.handleWindowEvent=M=>{this.handleEvent(M,`${M.type}Window`)},this.handleEvent=(M,I)=>{if(M.type==="blur")return void this.stop(!0);this._updatingCamera=!0;const L=M.type==="renderFrame"?void 0:M,j={needsRenderFrame:!1},G={},te={},Ae=M.touches,he=Ae?this._getMapTouches(Ae):void 0,Me=he?B.touchPos(this._map.getCanvas(),he):B.mousePos(this._map.getCanvas(),M);for(const{handlerName:Qe,handler:Le,allowed:ft}of this._handlers){if(!Le.isEnabled())continue;let Bt;this._blockedByActive(te,ft,Qe)?Le.reset():Le[I||M.type]&&(Bt=Le[I||M.type](M,Me,he),this.mergeHandlerResult(j,G,Bt,Qe,L),Bt&&Bt.needsRenderFrame&&this._triggerRenderFrame()),(Bt||Le.isActive())&&(te[Qe]=Le)}const De={};for(const Qe in this._previousActiveHandlers)te[Qe]||(De[Qe]=L);this._previousActiveHandlers=te,(Object.keys(De).length||Or(j))&&(this._changes.push([j,G,De]),this._triggerRenderFrame()),(Object.keys(te).length||Or(j))&&this._map._stop(!0),this._updatingCamera=!1;const{cameraAnimation:je}=j;je&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],je(this._map))},this._map=u,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new to(u),this._bearingSnap=p.bearingSnap,this._previousActiveHandlers={},this._eventsInProgress={},this._addDefaultHandlers(p);const C=this._el;this._listeners=[[C,"touchstart",{passive:!0}],[C,"touchmove",{passive:!1}],[C,"touchend",void 0],[C,"touchcancel",void 0],[C,"mousedown",void 0],[C,"mousemove",void 0],[C,"mouseup",void 0],[document,"mousemove",{capture:!0}],[document,"mouseup",void 0],[C,"mouseover",void 0],[C,"mouseout",void 0],[C,"dblclick",void 0],[C,"click",void 0],[C,"keydown",{capture:!1}],[C,"keyup",void 0],[C,"wheel",{passive:!1}],[C,"contextmenu",void 0],[window,"blur",void 0]];for(const[M,I,L]of this._listeners)B.addEventListener(M,I,M===document?this.handleWindowEvent:this.handleEvent,L)}destroy(){for(const[u,p,C]of this._listeners)B.removeEventListener(u,p,u===document?this.handleWindowEvent:this.handleEvent,C)}_addDefaultHandlers(u){const p=this._map,C=p.getCanvasContainer();this._add("mapEvent",new tA(p,u));const M=p.boxZoom=new ls(p,u);this._add("boxZoom",M),u.interactive&&u.boxZoom&&M.enable();const I=p.cooperativeGestures=new Eo(p,u.cooperativeGestures);this._add("cooperativeGestures",I),u.cooperativeGestures&&I.enable();const L=new Mh(p),j=new Ef(p);p.doubleClickZoom=new Xc(j,L),this._add("tapZoom",L),this._add("clickZoom",j),u.interactive&&u.doubleClickZoom&&p.doubleClickZoom.enable();const G=new Of;this._add("tapDragZoom",G);const te=p.touchPitch=new lc(p);this._add("touchPitch",te),u.interactive&&u.touchPitch&&p.touchPitch.enable(u.touchPitch);const Ae=jn(u),he=Hc(u);p.dragRotate=new Bh(u,Ae,he),this._add("mouseRotate",Ae,["mousePitch"]),this._add("mousePitch",he,["mouseRotate"]),u.interactive&&u.dragRotate&&p.dragRotate.enable();const Me=(({enable:Bt,clickTolerance:qe})=>{const _t=new us({checkCorrectEvent:Ut=>B.mouseButton(Ut)===0&&!Ut.ctrlKey});return new Al({clickTolerance:qe,move:(Ut,Tt)=>({around:Tt,panDelta:Tt.sub(Ut)}),activateOnStart:!0,moveStateManager:_t,enable:Bt,assignEvents:Fa})})(u),De=new oc(u,p);p.dragPan=new Oh(C,Me,De),this._add("mousePan",Me),this._add("touchPan",De,["touchZoom","touchRotate"]),u.interactive&&u.dragPan&&p.dragPan.enable(u.dragPan);const je=new sc,Qe=new rA;p.touchZoomRotate=new oa(C,Qe,je,G),this._add("touchRotate",je,["touchPan","touchZoom"]),this._add("touchZoom",Qe,["touchPan","touchRotate"]),u.interactive&&u.touchZoomRotate&&p.touchZoomRotate.enable(u.touchZoomRotate);const Le=p.scrollZoom=new go(p,()=>this._triggerRenderFrame());this._add("scrollZoom",Le,["mousePan"]),u.interactive&&u.scrollZoom&&p.scrollZoom.enable(u.scrollZoom);const ft=p.keyboard=new Zc(p);this._add("keyboard",ft),u.interactive&&u.keyboard&&p.keyboard.enable(),this._add("blockableMapEvent",new wA(p))}_add(u,p,C){this._handlers.push({handlerName:u,handler:p,allowed:C}),this._handlersById[u]=p}stop(u){if(!this._updatingCamera){for(const{handler:p}of this._handlers)p.reset();this._inertia.clear(),this._fireEvents({},{},u),this._changes=[]}}isActive(){for(const{handler:u}of this._handlers)if(u.isActive())return!0;return!1}isZooming(){return!!this._eventsInProgress.zoom||this._map.scrollZoom.isZooming()}isRotating(){return!!this._eventsInProgress.rotate}isMoving(){return!!uc(this._eventsInProgress)||this.isZooming()}_blockedByActive(u,p,C){for(const M in u)if(M!==C&&(!p||p.indexOf(M)<0))return!0;return!1}_getMapTouches(u){const p=[];for(const C of u)this._el.contains(C.target)&&p.push(C);return p}mergeHandlerResult(u,p,C,M,I){if(!C)return;a.e(u,C);const L={handlerName:M,originalEvent:C.originalEvent||I};C.zoomDelta!==void 0&&(p.zoom=L),C.panDelta!==void 0&&(p.drag=L),C.pitchDelta!==void 0&&(p.pitch=L),C.bearingDelta!==void 0&&(p.rotate=L)}_applyChanges(){const u={},p={},C={};for(const[M,I,L]of this._changes)M.panDelta&&(u.panDelta=(u.panDelta||new a.P(0,0))._add(M.panDelta)),M.zoomDelta&&(u.zoomDelta=(u.zoomDelta||0)+M.zoomDelta),M.bearingDelta&&(u.bearingDelta=(u.bearingDelta||0)+M.bearingDelta),M.pitchDelta&&(u.pitchDelta=(u.pitchDelta||0)+M.pitchDelta),M.around!==void 0&&(u.around=M.around),M.pinchAround!==void 0&&(u.pinchAround=M.pinchAround),M.noInertia&&(u.noInertia=M.noInertia),a.e(p,I),a.e(C,L);this._updateMapTransform(u,p,C),this._changes=[]}_updateMapTransform(u,p,C){const M=this._map,I=M._getTransformForUpdate(),L=M.terrain;if(!(Or(u)||L&&this._terrainMovement))return this._fireEvents(p,C,!0);let{panDelta:j,zoomDelta:G,bearingDelta:te,pitchDelta:Ae,around:he,pinchAround:Me}=u;Me!==void 0&&(he=Me),M._stop(!0),he=he||M.transform.centerPoint;const De=I.pointLocation(j?he.sub(j):he);te&&(I.bearing+=te),Ae&&(I.pitch+=Ae),G&&(I.zoom+=G),L?this._terrainMovement||!p.drag&&!p.zoom?p.drag&&this._terrainMovement?I.center=I.pointLocation(I.centerPoint.sub(j)):I.setLocationAtPoint(De,he):(this._terrainMovement=!0,this._map._elevationFreeze=!0,I.setLocationAtPoint(De,he),this._map.once("moveend",()=>{this._map._elevationFreeze=!1,this._terrainMovement=!1,I.recalculateZoom(M.terrain)})):I.setLocationAtPoint(De,he),M._applyUpdatedTransform(I),this._map._update(),u.noInertia||this._inertia.record(u),this._fireEvents(p,C,!0)}_fireEvents(u,p,C){const M=uc(this._eventsInProgress),I=uc(u),L={};for(const Ae in u){const{originalEvent:he}=u[Ae];this._eventsInProgress[Ae]||(L[`${Ae}start`]=he),this._eventsInProgress[Ae]=u[Ae]}!M&&I&&this._fireEvent("movestart",I.originalEvent);for(const Ae in L)this._fireEvent(Ae,L[Ae]);I&&this._fireEvent("move",I.originalEvent);for(const Ae in u){const{originalEvent:he}=u[Ae];this._fireEvent(Ae,he)}const j={};let G;for(const Ae in this._eventsInProgress){const{handlerName:he,originalEvent:Me}=this._eventsInProgress[Ae];this._handlersById[he].isActive()||(delete this._eventsInProgress[Ae],G=p[he]||Me,j[`${Ae}end`]=G)}for(const Ae in j)this._fireEvent(Ae,j[Ae]);const te=uc(this._eventsInProgress);if(C&&(M||I)&&!te){this._updatingCamera=!0;const Ae=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),he=Me=>Me!==0&&-this._bearingSnap<Me&&Me<this._bearingSnap;!Ae||!Ae.essential&&k.prefersReducedMotion?(this._map.fire(new a.k("moveend",{originalEvent:G})),he(this._map.getBearing())&&this._map.resetNorth()):(he(Ae.bearing||this._map.getBearing())&&(Ae.bearing=0),Ae.freezeElevation=!0,this._map.easeTo(Ae,{originalEvent:G})),this._updatingCamera=!1}}_fireEvent(u,p){this._map.fire(new a.k(u,p?{originalEvent:p}:{}))}_requestFrame(){return this._map.triggerRepaint(),this._map._renderTaskQueue.add(u=>{delete this._frameId,this.handleEvent(new gr("renderFrame",{timeStamp:u})),this._applyChanges()})}_triggerRenderFrame(){this._frameId===void 0&&(this._frameId=this._requestFrame())}}class Jc extends a.E{constructor(u,p){super(),this._renderFrameCallback=()=>{const C=Math.min((k.now()-this._easeStart)/this._easeOptions.duration,1);this._onEaseFrame(this._easeOptions.easing(C)),C<1&&this._easeFrameId?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()},this._moving=!1,this._zooming=!1,this.transform=u,this._bearingSnap=p.bearingSnap,this.on("moveend",()=>{delete this._requestedCameraState})}getCenter(){return new a.M(this.transform.center.lng,this.transform.center.lat)}setCenter(u,p){return this.jumpTo({center:u},p)}panBy(u,p,C){return u=a.P.convert(u).mult(-1),this.panTo(this.transform.center,a.e({offset:u},p),C)}panTo(u,p,C){return this.easeTo(a.e({center:u},p),C)}getZoom(){return this.transform.zoom}setZoom(u,p){return this.jumpTo({zoom:u},p),this}zoomTo(u,p,C){return this.easeTo(a.e({zoom:u},p),C)}zoomIn(u,p){return this.zoomTo(this.getZoom()+1,u,p),this}zoomOut(u,p){return this.zoomTo(this.getZoom()-1,u,p),this}getBearing(){return this.transform.bearing}setBearing(u,p){return this.jumpTo({bearing:u},p),this}getPadding(){return this.transform.padding}setPadding(u,p){return this.jumpTo({padding:u},p),this}rotateTo(u,p,C){return this.easeTo(a.e({bearing:u},p),C)}resetNorth(u,p){return this.rotateTo(0,a.e({duration:1e3},u),p),this}resetNorthPitch(u,p){return this.easeTo(a.e({bearing:0,pitch:0,duration:1e3},u),p),this}snapToNorth(u,p){return Math.abs(this.getBearing())<this._bearingSnap?this.resetNorth(u,p):this}getPitch(){return this.transform.pitch}setPitch(u,p){return this.jumpTo({pitch:u},p),this}cameraForBounds(u,p){u=Kt.convert(u);const C=p&&p.bearing||0;return this._cameraForBoxAndBearing(u.getNorthWest(),u.getSouthEast(),C,p)}_cameraForBoxAndBearing(u,p,C,M){const I={top:0,bottom:0,right:0,left:0};if(typeof(M=a.e({padding:I,offset:[0,0],maxZoom:this.transform.maxZoom},M)).padding=="number"){const Ut=M.padding;M.padding={top:Ut,bottom:Ut,right:Ut,left:Ut}}M.padding=a.e(I,M.padding);const L=this.transform,j=L.padding,G=L.project(a.M.convert(u)),te=L.project(a.M.convert(p)),Ae=G.rotate(-C*Math.PI/180),he=te.rotate(-C*Math.PI/180),Me=new a.P(Math.max(Ae.x,he.x),Math.max(Ae.y,he.y)),De=new a.P(Math.min(Ae.x,he.x),Math.min(Ae.y,he.y)),je=Me.sub(De),Qe=(L.width-(j.left+j.right+M.padding.left+M.padding.right))/je.x,Le=(L.height-(j.top+j.bottom+M.padding.top+M.padding.bottom))/je.y;if(Le<0||Qe<0)return void a.w("Map cannot fit within canvas with the given bounds, padding, and/or offset.");const ft=Math.min(L.scaleZoom(L.scale*Math.min(Qe,Le)),M.maxZoom),Bt=a.P.convert(M.offset),qe=new a.P((M.padding.left-M.padding.right)/2,(M.padding.top-M.padding.bottom)/2).rotate(C*Math.PI/180),_t=Bt.add(qe).mult(L.scale/L.zoomScale(ft));return{center:L.unproject(G.add(te).div(2).sub(_t)),zoom:ft,bearing:C}}fitBounds(u,p,C){return this._fitInternal(this.cameraForBounds(u,p),p,C)}fitScreenCoordinates(u,p,C,M,I){return this._fitInternal(this._cameraForBoxAndBearing(this.transform.pointLocation(a.P.convert(u)),this.transform.pointLocation(a.P.convert(p)),C,M),M,I)}_fitInternal(u,p,C){return u?(delete(p=a.e(u,p)).padding,p.linear?this.easeTo(p,C):this.flyTo(p,C)):this}jumpTo(u,p){this.stop();const C=this._getTransformForUpdate();let M=!1,I=!1,L=!1;return"zoom"in u&&C.zoom!==+u.zoom&&(M=!0,C.zoom=+u.zoom),u.center!==void 0&&(C.center=a.M.convert(u.center)),"bearing"in u&&C.bearing!==+u.bearing&&(I=!0,C.bearing=+u.bearing),"pitch"in u&&C.pitch!==+u.pitch&&(L=!0,C.pitch=+u.pitch),u.padding==null||C.isPaddingEqual(u.padding)||(C.padding=u.padding),this._applyUpdatedTransform(C),this.fire(new a.k("movestart",p)).fire(new a.k("move",p)),M&&this.fire(new a.k("zoomstart",p)).fire(new a.k("zoom",p)).fire(new a.k("zoomend",p)),I&&this.fire(new a.k("rotatestart",p)).fire(new a.k("rotate",p)).fire(new a.k("rotateend",p)),L&&this.fire(new a.k("pitchstart",p)).fire(new a.k("pitch",p)).fire(new a.k("pitchend",p)),this.fire(new a.k("moveend",p))}calculateCameraOptionsFromTo(u,p,C,M=0){const I=a.Y.fromLngLat(u,p),L=a.Y.fromLngLat(C,M),j=L.x-I.x,G=L.y-I.y,te=L.z-I.z,Ae=Math.hypot(j,G,te);if(Ae===0)throw new Error("Can't calculate camera options with same From and To");const he=Math.hypot(j,G),Me=this.transform.scaleZoom(this.transform.cameraToCenterDistance/Ae/this.transform.tileSize),De=180*Math.atan2(j,-G)/Math.PI;let je=180*Math.acos(he/Ae)/Math.PI;return je=te<0?90-je:90+je,{center:L.toLngLat(),zoom:Me,pitch:je,bearing:De}}easeTo(u,p){this._stop(!1,u.easeId),((u=a.e({offset:[0,0],duration:500,easing:a.b6},u)).animate===!1||!u.essential&&k.prefersReducedMotion)&&(u.duration=0);const C=this._getTransformForUpdate(),M=this.getZoom(),I=this.getBearing(),L=this.getPitch(),j=this.getPadding(),G="zoom"in u?+u.zoom:M,te="bearing"in u?this._normalizeBearing(u.bearing,I):I,Ae="pitch"in u?+u.pitch:L,he="padding"in u?u.padding:C.padding,Me=a.P.convert(u.offset);let De=C.centerPoint.add(Me);const je=C.pointLocation(De),Qe=a.M.convert(u.center||je);this._normalizeCenter(Qe);const Le=C.project(je),ft=C.project(Qe).sub(Le),Bt=C.zoomScale(G-M);let qe,_t;u.around&&(qe=a.M.convert(u.around),_t=C.locationPoint(qe));const Ut={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching};return this._zooming=this._zooming||G!==M,this._rotating=this._rotating||I!==te,this._pitching=this._pitching||Ae!==L,this._padding=!C.isPaddingEqual(he),this._easeId=u.easeId,this._prepareEase(p,u.noMoveStart,Ut),this.terrain&&this._prepareElevation(Qe),this._ease(Tt=>{if(this._zooming&&(C.zoom=a.z.number(M,G,Tt)),this._rotating&&(C.bearing=a.z.number(I,te,Tt)),this._pitching&&(C.pitch=a.z.number(L,Ae,Tt)),this._padding&&(C.interpolatePadding(j,he,Tt),De=C.centerPoint.add(Me)),this.terrain&&!u.freezeElevation&&this._updateElevation(Tt),qe)C.setLocationAtPoint(qe,_t);else{const en=C.zoomScale(C.zoom-M),hn=G>M?Math.min(2,Bt):Math.max(.5,Bt),An=Math.pow(hn,1-Tt),On=C.unproject(Le.add(ft.mult(Tt*An)).mult(en));C.setLocationAtPoint(C.renderWorldCopies?On.wrap():On,De)}this._applyUpdatedTransform(C),this._fireMoveEvents(p)},Tt=>{this.terrain&&this._finalizeElevation(),this._afterEase(p,Tt)},u),this}_prepareEase(u,p,C={}){this._moving=!0,p||C.moving||this.fire(new a.k("movestart",u)),this._zooming&&!C.zooming&&this.fire(new a.k("zoomstart",u)),this._rotating&&!C.rotating&&this.fire(new a.k("rotatestart",u)),this._pitching&&!C.pitching&&this.fire(new a.k("pitchstart",u))}_prepareElevation(u){this._elevationCenter=u,this._elevationStart=this.transform.elevation,this._elevationTarget=this.terrain.getElevationForLngLatZoom(u,this.transform.tileZoom),this._elevationFreeze=!0}_updateElevation(u){this.transform.minElevationForCurrentTile=this.terrain.getMinTileElevationForLngLatZoom(this._elevationCenter,this.transform.tileZoom);const p=this.terrain.getElevationForLngLatZoom(this._elevationCenter,this.transform.tileZoom);if(u<1&&p!==this._elevationTarget){const C=this._elevationTarget-this._elevationStart;this._elevationStart+=u*(C-(p-(C*u+this._elevationStart))/(1-u)),this._elevationTarget=p}this.transform.elevation=a.z.number(this._elevationStart,this._elevationTarget,u)}_finalizeElevation(){this._elevationFreeze=!1,this.transform.recalculateZoom(this.terrain)}_getTransformForUpdate(){return this.transformCameraUpdate?(this._requestedCameraState||(this._requestedCameraState=this.transform.clone()),this._requestedCameraState):this.transform}_applyUpdatedTransform(u){if(!this.transformCameraUpdate)return;const p=u.clone(),{center:C,zoom:M,pitch:I,bearing:L,elevation:j}=this.transformCameraUpdate(p);C&&(p.center=C),M!==void 0&&(p.zoom=M),I!==void 0&&(p.pitch=I),L!==void 0&&(p.bearing=L),j!==void 0&&(p.elevation=j),this.transform.apply(p)}_fireMoveEvents(u){this.fire(new a.k("move",u)),this._zooming&&this.fire(new a.k("zoom",u)),this._rotating&&this.fire(new a.k("rotate",u)),this._pitching&&this.fire(new a.k("pitch",u))}_afterEase(u,p){if(this._easeId&&p&&this._easeId===p)return;delete this._easeId;const C=this._zooming,M=this._rotating,I=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,C&&this.fire(new a.k("zoomend",u)),M&&this.fire(new a.k("rotateend",u)),I&&this.fire(new a.k("pitchend",u)),this.fire(new a.k("moveend",u))}flyTo(u,p){if(!u.essential&&k.prefersReducedMotion){const Qn=a.L(u,["center","zoom","bearing","pitch","around"]);return this.jumpTo(Qn,p)}this.stop(),u=a.e({offset:[0,0],speed:1.2,curve:1.42,easing:a.b6},u);const C=this._getTransformForUpdate(),M=this.getZoom(),I=this.getBearing(),L=this.getPitch(),j=this.getPadding(),G="zoom"in u?a.ac(+u.zoom,C.minZoom,C.maxZoom):M,te="bearing"in u?this._normalizeBearing(u.bearing,I):I,Ae="pitch"in u?+u.pitch:L,he="padding"in u?u.padding:C.padding,Me=C.zoomScale(G-M),De=a.P.convert(u.offset);let je=C.centerPoint.add(De);const Qe=C.pointLocation(je),Le=a.M.convert(u.center||Qe);this._normalizeCenter(Le);const ft=C.project(Qe),Bt=C.project(Le).sub(ft);let qe=u.curve;const _t=Math.max(C.width,C.height),Ut=_t/Me,Tt=Bt.mag();if("minZoom"in u){const Qn=a.ac(Math.min(u.minZoom,M,G),C.minZoom,C.maxZoom),Ho=_t/C.zoomScale(Qn-M);qe=Math.sqrt(Ho/Tt*2)}const en=qe*qe;function hn(Qn){const Ho=(Ut*Ut-_t*_t+(Qn?-1:1)*en*en*Tt*Tt)/(2*(Qn?Ut:_t)*en*Tt);return Math.log(Math.sqrt(Ho*Ho+1)-Ho)}function An(Qn){return(Math.exp(Qn)-Math.exp(-Qn))/2}function On(Qn){return(Math.exp(Qn)+Math.exp(-Qn))/2}const lr=hn(!1);let xr=function(Qn){return On(lr)/On(lr+qe*Qn)},Tn=function(Qn){return _t*((On(lr)*(An(Ho=lr+qe*Qn)/On(Ho))-An(lr))/en)/Tt;var Ho},yr=(hn(!0)-lr)/qe;if(Math.abs(Tt)<1e-6||!isFinite(yr)){if(Math.abs(_t-Ut)<1e-6)return this.easeTo(u,p);const Qn=Ut<_t?-1:1;yr=Math.abs(Math.log(Ut/_t))/qe,Tn=function(){return 0},xr=function(Ho){return Math.exp(Qn*qe*Ho)}}return u.duration="duration"in u?+u.duration:1e3*yr/("screenSpeed"in u?+u.screenSpeed/qe:+u.speed),u.maxDuration&&u.duration>u.maxDuration&&(u.duration=0),this._zooming=!0,this._rotating=I!==te,this._pitching=Ae!==L,this._padding=!C.isPaddingEqual(he),this._prepareEase(p,!1),this.terrain&&this._prepareElevation(Le),this._ease(Qn=>{const Ho=Qn*yr,pi=1/xr(Ho);C.zoom=Qn===1?G:M+C.scaleZoom(pi),this._rotating&&(C.bearing=a.z.number(I,te,Qn)),this._pitching&&(C.pitch=a.z.number(L,Ae,Qn)),this._padding&&(C.interpolatePadding(j,he,Qn),je=C.centerPoint.add(De)),this.terrain&&!u.freezeElevation&&this._updateElevation(Qn);const ii=Qn===1?Le:C.unproject(ft.add(Bt.mult(Tn(Ho))).mult(pi));C.setLocationAtPoint(C.renderWorldCopies?ii.wrap():ii,je),this._applyUpdatedTransform(C),this._fireMoveEvents(p)},()=>{this.terrain&&this._finalizeElevation(),this._afterEase(p)},u),this}isEasing(){return!!this._easeFrameId}stop(){return this._stop()}_stop(u,p){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),delete this._easeFrameId,delete this._onEaseFrame),this._onEaseEnd){const C=this._onEaseEnd;delete this._onEaseEnd,C.call(this,p)}if(!u){const C=this.handlers;C&&C.stop(!1)}return this}_ease(u,p,C){C.animate===!1||C.duration===0?(u(1),p()):(this._easeStart=k.now(),this._easeOptions=C,this._onEaseFrame=u,this._onEaseEnd=p,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))}_normalizeBearing(u,p){u=a.b0(u,-180,180);const C=Math.abs(u-p);return Math.abs(u-360-p)<C&&(u-=360),Math.abs(u+360-p)<C&&(u+=360),u}_normalizeCenter(u){const p=this.transform;if(!p.renderWorldCopies||p.lngRange)return;const C=u.lng-p.center.lng;u.lng+=C>180?-360:C<-180?360:0}queryTerrainElevation(u){return this.terrain?this.terrain.getElevationForLngLatZoom(a.M.convert(u),this.transform.tileZoom)-this.transform.elevation:null}}class dl{constructor(u={}){this._toggleAttribution=()=>{this._container.classList.contains("maplibregl-compact")&&(this._container.classList.contains("maplibregl-compact-show")?(this._container.setAttribute("open",""),this._container.classList.remove("maplibregl-compact-show")):(this._container.classList.add("maplibregl-compact-show"),this._container.removeAttribute("open")))},this._updateData=p=>{!p||p.sourceDataType!=="metadata"&&p.sourceDataType!=="visibility"&&p.dataType!=="style"&&p.type!=="terrain"||this._updateAttributions()},this._updateCompact=()=>{this._map.getCanvasContainer().offsetWidth<=640||this._compact?this._compact===!1?this._container.setAttribute("open",""):this._container.classList.contains("maplibregl-compact")||this._container.classList.contains("maplibregl-attrib-empty")||(this._container.setAttribute("open",""),this._container.classList.add("maplibregl-compact","maplibregl-compact-show")):(this._container.setAttribute("open",""),this._container.classList.contains("maplibregl-compact")&&this._container.classList.remove("maplibregl-compact","maplibregl-compact-show"))},this._updateCompactMinimize=()=>{this._container.classList.contains("maplibregl-compact")&&this._container.classList.contains("maplibregl-compact-show")&&this._container.classList.remove("maplibregl-compact-show")},this.options=u}getDefaultPosition(){return"bottom-right"}onAdd(u){return this._map=u,this._compact=this.options&&this.options.compact,this._container=B.create("details","maplibregl-ctrl maplibregl-ctrl-attrib"),this._compactButton=B.create("summary","maplibregl-ctrl-attrib-button",this._container),this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=B.create("div","maplibregl-ctrl-attrib-inner",this._container),this._updateAttributions(),this._updateCompact(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("terrain",this._updateData),this._map.on("resize",this._updateCompact),this._map.on("drag",this._updateCompactMinimize),this._container}onRemove(){B.remove(this._container),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("terrain",this._updateData),this._map.off("resize",this._updateCompact),this._map.off("drag",this._updateCompactMinimize),this._map=void 0,this._compact=void 0,this._attribHTML=void 0}_setElementTitle(u,p){const C=this._map._getUIString(`AttributionControl.${p}`);u.title=C,u.setAttribute("aria-label",C)}_updateAttributions(){if(!this._map.style)return;let u=[];if(this.options.customAttribution&&(Array.isArray(this.options.customAttribution)?u=u.concat(this.options.customAttribution.map(M=>typeof M!="string"?"":M)):typeof this.options.customAttribution=="string"&&u.push(this.options.customAttribution)),this._map.style.stylesheet){const M=this._map.style.stylesheet;this.styleOwner=M.owner,this.styleId=M.id}const p=this._map.style.sourceCaches;for(const M in p){const I=p[M];if(I.used||I.usedForTerrain){const L=I.getSource();L.attribution&&u.indexOf(L.attribution)<0&&u.push(L.attribution)}}u=u.filter(M=>String(M).trim()),u.sort((M,I)=>M.length-I.length),u=u.filter((M,I)=>{for(let L=I+1;L<u.length;L++)if(u[L].indexOf(M)>=0)return!1;return!0});const C=u.join(" | ");C!==this._attribHTML&&(this._attribHTML=C,u.length?(this._innerContainer.innerHTML=C,this._container.classList.remove("maplibregl-attrib-empty")):this._container.classList.add("maplibregl-attrib-empty"),this._updateCompact(),this._editLink=null)}}class xa{constructor(u={}){this._updateCompact=()=>{const p=this._container.children;if(p.length){const C=p[0];this._map.getCanvasContainer().offsetWidth<=640||this._compact?this._compact!==!1&&C.classList.add("maplibregl-compact"):C.classList.remove("maplibregl-compact")}},this.options=u}getDefaultPosition(){return"bottom-left"}onAdd(u){this._map=u,this._compact=this.options&&this.options.compact,this._container=B.create("div","maplibregl-ctrl");const p=B.create("a","maplibregl-ctrl-logo");return p.target="_blank",p.rel="noopener nofollow",p.href="https://maplibre.org/",p.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),p.setAttribute("rel","noopener nofollow"),this._container.appendChild(p),this._container.style.display="block",this._map.on("resize",this._updateCompact),this._updateCompact(),this._container}onRemove(){B.remove(this._container),this._map.off("resize",this._updateCompact),this._map=void 0,this._compact=void 0}}class Bl{constructor(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1}add(u){const p=++this._id;return this._queue.push({callback:u,id:p,cancelled:!1}),p}remove(u){const p=this._currentlyRunning,C=p?this._queue.concat(p):this._queue;for(const M of C)if(M.id===u)return void(M.cancelled=!0)}run(u=0){if(this._currentlyRunning)throw new Error("Attempting to run(), but is already running.");const p=this._currentlyRunning=this._queue;this._queue=[];for(const C of p)if(!C.cancelled&&(C.callback(u),this._cleared))break;this._cleared=!1,this._currentlyRunning=!1}clear(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]}}var As=a.X([{name:"a_pos3d",type:"Int16",components:3}]);class Iu extends a.E{constructor(u){super(),this.sourceCache=u,this._tiles={},this._renderableTilesKeys=[],this._sourceTileCache={},this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.deltaZoom=1,u.usedForTerrain=!0,u.tileSize=this.tileSize*2**this.deltaZoom}destruct(){this.sourceCache.usedForTerrain=!1,this.sourceCache.tileSize=null}update(u,p){this.sourceCache.update(u,p),this._renderableTilesKeys=[];const C={};for(const M of u.coveringTiles({tileSize:this.tileSize,minzoom:this.minzoom,maxzoom:this.maxzoom,reparseOverscaled:!1,terrain:p}))C[M.key]=!0,this._renderableTilesKeys.push(M.key),this._tiles[M.key]||(M.posMatrix=new Float64Array(16),a.aN(M.posMatrix,0,a.W,0,a.W,0,1),this._tiles[M.key]=new me(M,this.tileSize));for(const M in this._tiles)C[M]||delete this._tiles[M]}freeRtt(u){for(const p in this._tiles){const C=this._tiles[p];(!u||C.tileID.equals(u)||C.tileID.isChildOf(u)||u.isChildOf(C.tileID))&&(C.rtt=[])}}getRenderableTiles(){return this._renderableTilesKeys.map(u=>this.getTileByID(u))}getTileByID(u){return this._tiles[u]}getTerrainCoords(u){const p={};for(const C of this._renderableTilesKeys){const M=this._tiles[C].tileID;if(M.canonical.equals(u.canonical)){const I=u.clone();I.posMatrix=new Float64Array(16),a.aN(I.posMatrix,0,a.W,0,a.W,0,1),p[C]=I}else if(M.canonical.isChildOf(u.canonical)){const I=u.clone();I.posMatrix=new Float64Array(16);const L=M.canonical.z-u.canonical.z,j=M.canonical.x-(M.canonical.x>>L<<L),G=M.canonical.y-(M.canonical.y>>L<<L),te=a.W>>L;a.aN(I.posMatrix,0,te,0,te,0,1),a.H(I.posMatrix,I.posMatrix,[-j*te,-G*te,0]),p[C]=I}else if(u.canonical.isChildOf(M.canonical)){const I=u.clone();I.posMatrix=new Float64Array(16);const L=u.canonical.z-M.canonical.z,j=u.canonical.x-(u.canonical.x>>L<<L),G=u.canonical.y-(u.canonical.y>>L<<L),te=a.W>>L;a.aN(I.posMatrix,0,a.W,0,a.W,0,1),a.H(I.posMatrix,I.posMatrix,[j*te,G*te,0]),a.J(I.posMatrix,I.posMatrix,[1/2**L,1/2**L,0]),p[C]=I}}return p}getSourceTile(u,p){const C=this.sourceCache._source;let M=u.overscaledZ-this.deltaZoom;if(M>C.maxzoom&&(M=C.maxzoom),M<C.minzoom)return null;this._sourceTileCache[u.key]||(this._sourceTileCache[u.key]=u.scaledTo(M).key);let I=this.sourceCache.getTileByID(this._sourceTileCache[u.key]);if((!I||!I.dem)&&p)for(;M>=C.minzoom&&(!I||!I.dem);)I=this.sourceCache.getTileByID(u.scaledTo(M--).key);return I}tilesAfterTime(u=Date.now()){return Object.values(this._tiles).filter(p=>p.timeAdded>=u)}}class iA{constructor(u,p,C){this.painter=u,this.sourceCache=new Iu(p),this.options=C,this.exaggeration=typeof C.exaggeration=="number"?C.exaggeration:1,this.qualityFactor=2,this.meshSize=128,this._demMatrixCache={},this.coordsIndex=[],this._coordsTextureSize=1024}getDEMElevation(u,p,C,M=a.W){var I;if(!(p>=0&&p<M&&C>=0&&C<M))return 0;const L=this.getTerrainData(u),j=(I=L.tile)===null||I===void 0?void 0:I.dem;if(!j)return 0;const G=function(je,Qe,Le){var ft=Qe[0],Bt=Qe[1];return je[0]=Le[0]*ft+Le[4]*Bt+Le[12],je[1]=Le[1]*ft+Le[5]*Bt+Le[13],je}([],[p/M*a.W,C/M*a.W],L.u_terrain_matrix),te=[G[0]*j.dim,G[1]*j.dim],Ae=Math.floor(te[0]),he=Math.floor(te[1]),Me=te[0]-Ae,De=te[1]-he;return j.get(Ae,he)*(1-Me)*(1-De)+j.get(Ae+1,he)*Me*(1-De)+j.get(Ae,he+1)*(1-Me)*De+j.get(Ae+1,he+1)*Me*De}getElevationForLngLatZoom(u,p){const{tileID:C,mercatorX:M,mercatorY:I}=this._getOverscaledTileIDFromLngLatZoom(u,p);return this.getElevation(C,M%a.W,I%a.W,a.W)}getElevation(u,p,C,M=a.W){return this.getDEMElevation(u,p,C,M)*this.exaggeration}getTerrainData(u){if(!this._emptyDemTexture){const M=this.painter.context,I=new a.R({width:1,height:1},new Uint8Array(4));this._emptyDepthTexture=new ct(M,I,M.gl.RGBA,{premultiply:!1}),this._emptyDemUnpack=[0,0,0,0],this._emptyDemTexture=new ct(M,new a.R({width:1,height:1}),M.gl.RGBA,{premultiply:!1}),this._emptyDemTexture.bind(M.gl.NEAREST,M.gl.CLAMP_TO_EDGE),this._emptyDemMatrix=a.an([])}const p=this.sourceCache.getSourceTile(u,!0);if(p&&p.dem&&(!p.demTexture||p.needsTerrainPrepare)){const M=this.painter.context;p.demTexture=this.painter.getTileTexture(p.dem.stride),p.demTexture?p.demTexture.update(p.dem.getPixels(),{premultiply:!1}):p.demTexture=new ct(M,p.dem.getPixels(),M.gl.RGBA,{premultiply:!1}),p.demTexture.bind(M.gl.NEAREST,M.gl.CLAMP_TO_EDGE),p.needsTerrainPrepare=!1}const C=p&&p+p.tileID.key+u.key;if(C&&!this._demMatrixCache[C]){const M=this.sourceCache.sourceCache._source.maxzoom;let I=u.canonical.z-p.tileID.canonical.z;u.overscaledZ>u.canonical.z&&(u.canonical.z>=M?I=u.canonical.z-M:a.w("cannot calculate elevation if elevation maxzoom > source.maxzoom"));const L=u.canonical.x-(u.canonical.x>>I<<I),j=u.canonical.y-(u.canonical.y>>I<<I),G=a.b7(new Float64Array(16),[1/(a.W<<I),1/(a.W<<I),0]);a.H(G,G,[L*a.W,j*a.W,0]),this._demMatrixCache[u.key]={matrix:G,coord:u}}return{u_depth:2,u_terrain:3,u_terrain_dim:p&&p.dem&&p.dem.dim||1,u_terrain_matrix:C?this._demMatrixCache[u.key].matrix:this._emptyDemMatrix,u_terrain_unpack:p&&p.dem&&p.dem.getUnpackVector()||this._emptyDemUnpack,u_terrain_exaggeration:this.exaggeration,texture:(p&&p.demTexture||this._emptyDemTexture).texture,depthTexture:(this._fboDepthTexture||this._emptyDepthTexture).texture,tile:p}}getFramebuffer(u){const p=this.painter,C=p.width/devicePixelRatio,M=p.height/devicePixelRatio;return!this._fbo||this._fbo.width===C&&this._fbo.height===M||(this._fbo.destroy(),this._fboCoordsTexture.destroy(),this._fboDepthTexture.destroy(),delete this._fbo,delete this._fboDepthTexture,delete this._fboCoordsTexture),this._fboCoordsTexture||(this._fboCoordsTexture=new ct(p.context,{width:C,height:M,data:null},p.context.gl.RGBA,{premultiply:!1}),this._fboCoordsTexture.bind(p.context.gl.NEAREST,p.context.gl.CLAMP_TO_EDGE)),this._fboDepthTexture||(this._fboDepthTexture=new ct(p.context,{width:C,height:M,data:null},p.context.gl.RGBA,{premultiply:!1}),this._fboDepthTexture.bind(p.context.gl.NEAREST,p.context.gl.CLAMP_TO_EDGE)),this._fbo||(this._fbo=p.context.createFramebuffer(C,M,!0,!1),this._fbo.depthAttachment.set(p.context.createRenderbuffer(p.context.gl.DEPTH_COMPONENT16,C,M))),this._fbo.colorAttachment.set(u==="coords"?this._fboCoordsTexture.texture:this._fboDepthTexture.texture),this._fbo}getCoordsTexture(){const u=this.painter.context;if(this._coordsTexture)return this._coordsTexture;const p=new Uint8Array(this._coordsTextureSize*this._coordsTextureSize*4);for(let I=0,L=0;I<this._coordsTextureSize;I++)for(let j=0;j<this._coordsTextureSize;j++,L+=4)p[L+0]=255&j,p[L+1]=255&I,p[L+2]=j>>8<<4|I>>8,p[L+3]=0;const C=new a.R({width:this._coordsTextureSize,height:this._coordsTextureSize},new Uint8Array(p.buffer)),M=new ct(u,C,u.gl.RGBA,{premultiply:!1});return M.bind(u.gl.NEAREST,u.gl.CLAMP_TO_EDGE),this._coordsTexture=M,M}pointCoordinate(u){const p=new Uint8Array(4),C=this.painter.context,M=C.gl;C.bindFramebuffer.set(this.getFramebuffer("coords").framebuffer),M.readPixels(u.x,this.painter.height/devicePixelRatio-u.y-1,1,1,M.RGBA,M.UNSIGNED_BYTE,p),C.bindFramebuffer.set(null);const I=p[0]+(p[2]>>4<<8),L=p[1]+((15&p[2])<<8),j=this.coordsIndex[255-p[3]],G=j&&this.sourceCache.getTileByID(j);if(!G)return null;const te=this._coordsTextureSize,Ae=(1<<G.tileID.canonical.z)*te;return new a.Y((G.tileID.canonical.x*te+I)/Ae+G.tileID.wrap,(G.tileID.canonical.y*te+L)/Ae,this.getElevation(G.tileID,I,L,te))}depthAtPoint(u){const p=new Uint8Array(4),C=this.painter.context,M=C.gl;return C.bindFramebuffer.set(this.getFramebuffer("depth").framebuffer),M.readPixels(u.x,this.painter.height/devicePixelRatio-u.y-1,1,1,M.RGBA,M.UNSIGNED_BYTE,p),C.bindFramebuffer.set(null),(p[0]/16777216+p[1]/65536+p[2]/256+p[3])/256}getTerrainMesh(){if(this._mesh)return this._mesh;const u=this.painter.context,p=new a.b8,C=new a.aX,M=this.meshSize,I=a.W/M,L=M*M;for(let he=0;he<=M;he++)for(let Me=0;Me<=M;Me++)p.emplaceBack(Me*I,he*I,0);for(let he=0;he<L;he+=M+1)for(let Me=0;Me<M;Me++)C.emplaceBack(Me+he,M+Me+he+1,M+Me+he+2),C.emplaceBack(Me+he,M+Me+he+2,Me+he+1);const j=p.length,G=j+2*(M+1);for(const he of[0,1])for(let Me=0;Me<=M;Me++)for(const De of[0,1])p.emplaceBack(Me*I,he*a.W,De);for(let he=0;he<2*M;he+=2)C.emplaceBack(G+he,G+he+1,G+he+3),C.emplaceBack(G+he,G+he+3,G+he+2),C.emplaceBack(j+he,j+he+3,j+he+1),C.emplaceBack(j+he,j+he+2,j+he+3);const te=p.length,Ae=te+2*(M+1);for(const he of[0,1])for(let Me=0;Me<=M;Me++)for(const De of[0,1])p.emplaceBack(he*a.W,Me*I,De);for(let he=0;he<2*M;he+=2)C.emplaceBack(te+he,te+he+1,te+he+3),C.emplaceBack(te+he,te+he+3,te+he+2),C.emplaceBack(Ae+he,Ae+he+3,Ae+he+1),C.emplaceBack(Ae+he,Ae+he+2,Ae+he+3);return this._mesh={indexBuffer:u.createIndexBuffer(C),vertexBuffer:u.createVertexBuffer(p,As.members),segments:a.$.simpleSegment(0,0,p.length,C.length)},this._mesh}getMeshFrameDelta(u){return 2*Math.PI*a.b9/Math.pow(2,u)/5}getMinTileElevationForLngLatZoom(u,p){var C;const{tileID:M}=this._getOverscaledTileIDFromLngLatZoom(u,p);return(C=this.getMinMaxElevation(M).minElevation)!==null&&C!==void 0?C:0}getMinMaxElevation(u){const p=this.getTerrainData(u).tile,C={minElevation:null,maxElevation:null};return p&&p.dem&&(C.minElevation=p.dem.min*this.exaggeration,C.maxElevation=p.dem.max*this.exaggeration),C}_getOverscaledTileIDFromLngLatZoom(u,p){const C=a.Y.fromLngLat(u.wrap()),M=(1<<p)*a.W,I=C.x*M,L=C.y*M,j=Math.floor(I/a.W),G=Math.floor(L/a.W);return{tileID:new a.Q(p,0,p,j,G),mercatorX:I,mercatorY:L}}}class Oo{constructor(u,p,C){this._context=u,this._size=p,this._tileSize=C,this._objects=[],this._recentlyUsed=[],this._stamp=0}destruct(){for(const u of this._objects)u.texture.destroy(),u.fbo.destroy()}_createObject(u){const p=this._context.createFramebuffer(this._tileSize,this._tileSize,!0,!0),C=new ct(this._context,{width:this._tileSize,height:this._tileSize,data:null},this._context.gl.RGBA);return C.bind(this._context.gl.LINEAR,this._context.gl.CLAMP_TO_EDGE),p.depthAttachment.set(this._context.createRenderbuffer(this._context.gl.DEPTH_STENCIL,this._tileSize,this._tileSize)),p.colorAttachment.set(C.texture),{id:u,fbo:p,texture:C,stamp:-1,inUse:!1}}getObjectForId(u){return this._objects[u]}useObject(u){u.inUse=!0,this._recentlyUsed=this._recentlyUsed.filter(p=>u.id!==p),this._recentlyUsed.push(u.id)}stampObject(u){u.stamp=++this._stamp}getOrCreateFreeObject(){for(const p of this._recentlyUsed)if(!this._objects[p].inUse)return this._objects[p];if(this._objects.length>=this._size)throw new Error("No free RenderPool available, call freeAllObjects() required!");const u=this._createObject(this._objects.length);return this._objects.push(u),u}freeObject(u){u.inUse=!1}freeAllObjects(){for(const u of this._objects)this.freeObject(u)}isFull(){return!(this._objects.length<this._size)&&this._objects.some(u=>!u.inUse)===!1}}const zo={background:!0,fill:!0,line:!0,raster:!0,hillshade:!0};class Ip{constructor(u,p){this.painter=u,this.terrain=p,this.pool=new Oo(u.context,30,p.sourceCache.tileSize*p.qualityFactor)}destruct(){this.pool.destruct()}getTexture(u){return this.pool.getObjectForId(u.rtt[this._stacks.length-1].id).texture}prepareForRender(u,p){this._stacks=[],this._prevType=null,this._rttTiles=[],this._renderableTiles=this.terrain.sourceCache.getRenderableTiles(),this._renderableLayerIds=u._order.filter(C=>!u._layers[C].isHidden(p)),this._coordsDescendingInv={};for(const C in u.sourceCaches){this._coordsDescendingInv[C]={};const M=u.sourceCaches[C].getVisibleCoordinates();for(const I of M){const L=this.terrain.sourceCache.getTerrainCoords(I);for(const j in L)this._coordsDescendingInv[C][j]||(this._coordsDescendingInv[C][j]=[]),this._coordsDescendingInv[C][j].push(L[j])}}this._coordsDescendingInvStr={};for(const C of u._order){const M=u._layers[C],I=M.source;if(zo[M.type]&&!this._coordsDescendingInvStr[I]){this._coordsDescendingInvStr[I]={};for(const L in this._coordsDescendingInv[I])this._coordsDescendingInvStr[I][L]=this._coordsDescendingInv[I][L].map(j=>j.key).sort().join()}}for(const C of this._renderableTiles)for(const M in this._coordsDescendingInvStr){const I=this._coordsDescendingInvStr[M][C.tileID.key];I&&I!==C.rttCoords[M]&&(C.rtt=[])}}renderLayer(u){if(u.isHidden(this.painter.transform.zoom))return!1;const p=u.type,C=this.painter,M=this._renderableLayerIds[this._renderableLayerIds.length-1]===u.id;if(zo[p]&&(this._prevType&&zo[this._prevType]||this._stacks.push([]),this._prevType=p,this._stacks[this._stacks.length-1].push(u.id),!M))return!0;if(zo[this._prevType]||zo[p]&&M){this._prevType=p;const I=this._stacks.length-1,L=this._stacks[I]||[];for(const j of this._renderableTiles){if(this.pool.isFull()&&(ul(this.painter,this.terrain,this._rttTiles),this._rttTiles=[],this.pool.freeAllObjects()),this._rttTiles.push(j),j.rtt[I]){const te=this.pool.getObjectForId(j.rtt[I].id);if(te.stamp===j.rtt[I].stamp){this.pool.useObject(te);continue}}const G=this.pool.getOrCreateFreeObject();this.pool.useObject(G),this.pool.stampObject(G),j.rtt[I]={id:G.id,stamp:G.stamp},C.context.bindFramebuffer.set(G.fbo.framebuffer),C.context.clear({color:a.aO.transparent,stencil:0}),C.currentStencilSource=void 0;for(let te=0;te<L.length;te++){const Ae=C.style._layers[L[te]],he=Ae.source?this._coordsDescendingInv[Ae.source][j.tileID.key]:[j.tileID];C.context.viewport.set([0,0,G.fbo.width,G.fbo.height]),C._renderTileClippingMasks(Ae,he),C.renderLayer(C,C.style.sourceCaches[Ae.source],Ae,he),Ae.source&&(j.rttCoords[Ae.source]=this._coordsDescendingInvStr[Ae.source][j.tileID.key])}}return ul(this.painter,this.terrain,this._rttTiles),this._rttTiles=[],this.pool.freeAllObjects(),zo[p]}return!1}}const du={"AttributionControl.ToggleAttribution":"Toggle attribution","AttributionControl.MapFeedback":"Map feedback","FullscreenControl.Enter":"Enter fullscreen","FullscreenControl.Exit":"Exit fullscreen","GeolocateControl.FindMyLocation":"Find my location","GeolocateControl.LocationNotAvailable":"Location not available","LogoControl.Title":"Mapbox logo","NavigationControl.ResetBearing":"Reset bearing to north","NavigationControl.ZoomIn":"Zoom in","NavigationControl.ZoomOut":"Zoom out","ScaleControl.Feet":"ft","ScaleControl.Meters":"m","ScaleControl.Kilometers":"km","ScaleControl.Miles":"mi","ScaleControl.NauticalMiles":"nm","TerrainControl.enableTerrain":"Enable terrain","TerrainControl.disableTerrain":"Disable terrain"},Tu=f,Bf={center:[0,0],zoom:0,bearing:0,pitch:0,minZoom:-2,maxZoom:22,minPitch:0,maxPitch:60,interactive:!0,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,cooperativeGestures:!1,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,hash:!1,attributionControl:!0,maplibreLogo:!1,failIfMajorPerformanceCaveat:!1,preserveDrawingBuffer:!1,trackResize:!0,renderWorldCopies:!0,refreshExpiredTiles:!0,maxTileCacheSize:null,maxTileCacheZoomLevels:a.a.MAX_TILE_CACHE_ZOOM_LEVELS,localIdeographFontFamily:"sans-serif",transformRequest:null,transformCameraUpdate:null,fadeDuration:300,crossSourceCollisions:!0,validateStyle:!0,maxCanvasSize:[4096,4096]},Ac=O=>{O.touchstart=O.dragStart,O.touchmoveWindow=O.dragMove,O.touchend=O.dragEnd},cc={showCompass:!0,showZoom:!0,visualizePitch:!1};class ed{constructor(u,p,C=!1){this.mousedown=L=>{this.startMouse(a.e({},L,{ctrlKey:!0,preventDefault:()=>L.preventDefault()}),B.mousePos(this.element,L)),B.addEventListener(window,"mousemove",this.mousemove),B.addEventListener(window,"mouseup",this.mouseup)},this.mousemove=L=>{this.moveMouse(L,B.mousePos(this.element,L))},this.mouseup=L=>{this.mouseRotate.dragEnd(L),this.mousePitch&&this.mousePitch.dragEnd(L),this.offTemp()},this.touchstart=L=>{L.targetTouches.length!==1?this.reset():(this._startPos=this._lastPos=B.touchPos(this.element,L.targetTouches)[0],this.startTouch(L,this._startPos),B.addEventListener(window,"touchmove",this.touchmove,{passive:!1}),B.addEventListener(window,"touchend",this.touchend))},this.touchmove=L=>{L.targetTouches.length!==1?this.reset():(this._lastPos=B.touchPos(this.element,L.targetTouches)[0],this.moveTouch(L,this._lastPos))},this.touchend=L=>{L.targetTouches.length===0&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)<this._clickTolerance&&this.element.click(),delete this._startPos,delete this._lastPos,this.offTemp()},this.reset=()=>{this.mouseRotate.reset(),this.mousePitch&&this.mousePitch.reset(),this.touchRotate.reset(),this.touchPitch&&this.touchPitch.reset(),delete this._startPos,delete this._lastPos,this.offTemp()},this._clickTolerance=10;const M=u.dragRotate._mouseRotate.getClickTolerance(),I=u.dragRotate._mousePitch.getClickTolerance();this.element=p,this.mouseRotate=jn({clickTolerance:M,enable:!0}),this.touchRotate=(({enable:L,clickTolerance:j,bearingDegreesPerPixelMoved:G=.8})=>{const te=new Ol;return new Al({clickTolerance:j,move:(Ae,he)=>({bearingDelta:(he.x-Ae.x)*G}),moveStateManager:te,enable:L,assignEvents:Ac})})({clickTolerance:M,enable:!0}),this.map=u,C&&(this.mousePitch=Hc({clickTolerance:I,enable:!0}),this.touchPitch=(({enable:L,clickTolerance:j,pitchDegreesPerPixelMoved:G=-.5})=>{const te=new Ol;return new Al({clickTolerance:j,move:(Ae,he)=>({pitchDelta:(he.y-Ae.y)*G}),moveStateManager:te,enable:L,assignEvents:Ac})})({clickTolerance:I,enable:!0})),B.addEventListener(p,"mousedown",this.mousedown),B.addEventListener(p,"touchstart",this.touchstart,{passive:!1}),B.addEventListener(p,"touchcancel",this.reset)}startMouse(u,p){this.mouseRotate.dragStart(u,p),this.mousePitch&&this.mousePitch.dragStart(u,p),B.disableDrag()}startTouch(u,p){this.touchRotate.dragStart(u,p),this.touchPitch&&this.touchPitch.dragStart(u,p),B.disableDrag()}moveMouse(u,p){const C=this.map,{bearingDelta:M}=this.mouseRotate.dragMove(u,p)||{};if(M&&C.setBearing(C.getBearing()+M),this.mousePitch){const{pitchDelta:I}=this.mousePitch.dragMove(u,p)||{};I&&C.setPitch(C.getPitch()+I)}}moveTouch(u,p){const C=this.map,{bearingDelta:M}=this.touchRotate.dragMove(u,p)||{};if(M&&C.setBearing(C.getBearing()+M),this.touchPitch){const{pitchDelta:I}=this.touchPitch.dragMove(u,p)||{};I&&C.setPitch(C.getPitch()+I)}}off(){const u=this.element;B.removeEventListener(u,"mousedown",this.mousedown),B.removeEventListener(u,"touchstart",this.touchstart,{passive:!1}),B.removeEventListener(window,"touchmove",this.touchmove,{passive:!1}),B.removeEventListener(window,"touchend",this.touchend),B.removeEventListener(u,"touchcancel",this.reset),this.offTemp()}offTemp(){B.enableDrag(),B.removeEventListener(window,"mousemove",this.mousemove),B.removeEventListener(window,"mouseup",this.mouseup),B.removeEventListener(window,"touchmove",this.touchmove,{passive:!1}),B.removeEventListener(window,"touchend",this.touchend)}}let ke;function oA(O,u,p){if(O=new a.M(O.lng,O.lat),u){const C=new a.M(O.lng-360,O.lat),M=new a.M(O.lng+360,O.lat),I=p.locationPoint(O).distSqr(u);p.locationPoint(C).distSqr(u)<I?O=C:p.locationPoint(M).distSqr(u)<I&&(O=M)}for(;Math.abs(O.lng-p.center.lng)>180;){const C=p.locationPoint(O);if(C.x>=0&&C.y>=0&&C.x<=p.width&&C.y<=p.height)break;O.lng>p.center.lng?O.lng-=360:O.lng+=360}return O}const wa={center:"translate(-50%,-50%)",top:"translate(-50%,0)","top-left":"translate(0,0)","top-right":"translate(-100%,0)",bottom:"translate(-50%,-100%)","bottom-left":"translate(0,-100%)","bottom-right":"translate(-100%,-100%)",left:"translate(0,-50%)",right:"translate(-100%,-50%)"};function uo(O,u,p){const C=O.classList;for(const M in wa)C.remove(`maplibregl-${p}-anchor-${M}`);C.add(`maplibregl-${p}-anchor-${u}`)}class jr extends a.E{constructor(u){if(super(),this._onKeyPress=p=>{const C=p.code,M=p.charCode||p.keyCode;C!=="Space"&&C!=="Enter"&&M!==32&&M!==13||this.togglePopup()},this._onMapClick=p=>{const C=p.originalEvent.target,M=this._element;this._popup&&(C===M||M.contains(C))&&this.togglePopup()},this._update=p=>{if(!this._map)return;const C=this._map.loaded()&&!this._map.isMoving();((p==null?void 0:p.type)==="terrain"||(p==null?void 0:p.type)==="render"&&!C)&&this._map.once("render",this._update),this._map.transform.renderWorldCopies&&(this._lngLat=oA(this._lngLat,this._pos,this._map.transform)),this._pos=this._map.project(this._lngLat)._add(this._offset);let M="";this._rotationAlignment==="viewport"||this._rotationAlignment==="auto"?M=`rotateZ(${this._rotation}deg)`:this._rotationAlignment==="map"&&(M=`rotateZ(${this._rotation-this._map.getBearing()}deg)`);let I="";this._pitchAlignment==="viewport"||this._pitchAlignment==="auto"?I="rotateX(0deg)":this._pitchAlignment==="map"&&(I=`rotateX(${this._map.getPitch()}deg)`),p&&p.type!=="moveend"||(this._pos=this._pos.round()),B.setTransform(this._element,`${wa[this._anchor]} translate(${this._pos.x}px, ${this._pos.y}px) ${I} ${M}`),this._updateOpacity(p&&p.type==="moveend")},this._onMove=p=>{if(!this._isDragging){const C=this._clickTolerance||this._map._clickTolerance;this._isDragging=p.point.dist(this._pointerdownPos)>=C}this._isDragging&&(this._pos=p.point.sub(this._positionDelta),this._lngLat=this._map.unproject(this._pos),this.setLngLat(this._lngLat),this._element.style.pointerEvents="none",this._state==="pending"&&(this._state="active",this.fire(new a.k("dragstart"))),this.fire(new a.k("drag")))},this._onUp=()=>{this._element.style.pointerEvents="auto",this._positionDelta=null,this._pointerdownPos=null,this._isDragging=!1,this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),this._state==="active"&&this.fire(new a.k("dragend")),this._state="inactive"},this._addDragHandler=p=>{this._element.contains(p.originalEvent.target)&&(p.preventDefault(),this._positionDelta=p.point.sub(this._pos).add(this._offset),this._pointerdownPos=p.point,this._state="pending",this._map.on("mousemove",this._onMove),this._map.on("touchmove",this._onMove),this._map.once("mouseup",this._onUp),this._map.once("touchend",this._onUp))},this._anchor=u&&u.anchor||"center",this._color=u&&u.color||"#3FB1CE",this._scale=u&&u.scale||1,this._draggable=u&&u.draggable||!1,this._clickTolerance=u&&u.clickTolerance||0,this._isDragging=!1,this._state="inactive",this._rotation=u&&u.rotation||0,this._rotationAlignment=u&&u.rotationAlignment||"auto",this._pitchAlignment=u&&u.pitchAlignment&&u.pitchAlignment!=="auto"?u.pitchAlignment:this._rotationAlignment,u&&u.element)this._element=u.element,this._offset=a.P.convert(u&&u.offset||[0,0]);else{this._defaultMarker=!0,this._element=B.create("div"),this._element.setAttribute("aria-label","Map marker");const p=B.createNS("http://www.w3.org/2000/svg","svg"),C=41,M=27;p.setAttributeNS(null,"display","block"),p.setAttributeNS(null,"height",`${C}px`),p.setAttributeNS(null,"width",`${M}px`),p.setAttributeNS(null,"viewBox",`0 0 ${M} ${C}`);const I=B.createNS("http://www.w3.org/2000/svg","g");I.setAttributeNS(null,"stroke","none"),I.setAttributeNS(null,"stroke-width","1"),I.setAttributeNS(null,"fill","none"),I.setAttributeNS(null,"fill-rule","evenodd");const L=B.createNS("http://www.w3.org/2000/svg","g");L.setAttributeNS(null,"fill-rule","nonzero");const j=B.createNS("http://www.w3.org/2000/svg","g");j.setAttributeNS(null,"transform","translate(3.0, 29.0)"),j.setAttributeNS(null,"fill","#000000");const G=[{rx:"10.5",ry:"5.25002273"},{rx:"10.5",ry:"5.25002273"},{rx:"9.5",ry:"4.77275007"},{rx:"8.5",ry:"4.29549936"},{rx:"7.5",ry:"3.81822308"},{rx:"6.5",ry:"3.34094679"},{rx:"5.5",ry:"2.86367051"},{rx:"4.5",ry:"2.38636864"}];for(const ft of G){const Bt=B.createNS("http://www.w3.org/2000/svg","ellipse");Bt.setAttributeNS(null,"opacity","0.04"),Bt.setAttributeNS(null,"cx","10.5"),Bt.setAttributeNS(null,"cy","5.80029008"),Bt.setAttributeNS(null,"rx",ft.rx),Bt.setAttributeNS(null,"ry",ft.ry),j.appendChild(Bt)}const te=B.createNS("http://www.w3.org/2000/svg","g");te.setAttributeNS(null,"fill",this._color);const Ae=B.createNS("http://www.w3.org/2000/svg","path");Ae.setAttributeNS(null,"d","M27,13.5 C27,19.074644 20.250001,27.000002 14.75,34.500002 C14.016665,35.500004 12.983335,35.500004 12.25,34.500002 C6.7499993,27.000002 0,19.222562 0,13.5 C0,6.0441559 6.0441559,0 13.5,0 C20.955844,0 27,6.0441559 27,13.5 Z"),te.appendChild(Ae);const he=B.createNS("http://www.w3.org/2000/svg","g");he.setAttributeNS(null,"opacity","0.25"),he.setAttributeNS(null,"fill","#000000");const Me=B.createNS("http://www.w3.org/2000/svg","path");Me.setAttributeNS(null,"d","M13.5,0 C6.0441559,0 0,6.0441559 0,13.5 C0,19.222562 6.7499993,27 12.25,34.5 C13,35.522727 14.016664,35.500004 14.75,34.5 C20.250001,27 27,19.074644 27,13.5 C27,6.0441559 20.955844,0 13.5,0 Z M13.5,1 C20.415404,1 26,6.584596 26,13.5 C26,15.898657 24.495584,19.181431 22.220703,22.738281 C19.945823,26.295132 16.705119,30.142167 13.943359,33.908203 C13.743445,34.180814 13.612715,34.322738 13.5,34.441406 C13.387285,34.322738 13.256555,34.180814 13.056641,33.908203 C10.284481,30.127985 7.4148684,26.314159 5.015625,22.773438 C2.6163816,19.232715 1,15.953538 1,13.5 C1,6.584596 6.584596,1 13.5,1 Z"),he.appendChild(Me);const De=B.createNS("http://www.w3.org/2000/svg","g");De.setAttributeNS(null,"transform","translate(6.0, 7.0)"),De.setAttributeNS(null,"fill","#FFFFFF");const je=B.createNS("http://www.w3.org/2000/svg","g");je.setAttributeNS(null,"transform","translate(8.0, 8.0)");const Qe=B.createNS("http://www.w3.org/2000/svg","circle");Qe.setAttributeNS(null,"fill","#000000"),Qe.setAttributeNS(null,"opacity","0.25"),Qe.setAttributeNS(null,"cx","5.5"),Qe.setAttributeNS(null,"cy","5.5"),Qe.setAttributeNS(null,"r","5.4999962");const Le=B.createNS("http://www.w3.org/2000/svg","circle");Le.setAttributeNS(null,"fill","#FFFFFF"),Le.setAttributeNS(null,"cx","5.5"),Le.setAttributeNS(null,"cy","5.5"),Le.setAttributeNS(null,"r","5.4999962"),je.appendChild(Qe),je.appendChild(Le),L.appendChild(j),L.appendChild(te),L.appendChild(he),L.appendChild(De),L.appendChild(je),p.appendChild(L),p.setAttributeNS(null,"height",C*this._scale+"px"),p.setAttributeNS(null,"width",M*this._scale+"px"),this._element.appendChild(p),this._offset=a.P.convert(u&&u.offset||[0,-14])}if(this._element.classList.add("maplibregl-marker"),this._element.addEventListener("dragstart",p=>{p.preventDefault()}),this._element.addEventListener("mousedown",p=>{p.preventDefault()}),uo(this._element,this._anchor,"marker"),u&&u.className)for(const p of u.className.split(" "))this._element.classList.add(p);this._popup=null}addTo(u){return this.remove(),this._map=u,u.getCanvasContainer().appendChild(this._element),u.on("move",this._update),u.on("moveend",this._update),u.on("terrain",this._update),this.setDraggable(this._draggable),this._update(),this._map.on("click",this._onMapClick),this}remove(){return this._opacityTimeout&&(clearTimeout(this._opacityTimeout),delete this._opacityTimeout),this._map&&(this._map.off("click",this._onMapClick),this._map.off("move",this._update),this._map.off("moveend",this._update),this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler),this._map.off("mouseup",this._onUp),this._map.off("touchend",this._onUp),this._map.off("mousemove",this._onMove),this._map.off("touchmove",this._onMove),delete this._map),B.remove(this._element),this._popup&&this._popup.remove(),this}getLngLat(){return this._lngLat}setLngLat(u){return this._lngLat=a.M.convert(u),this._pos=null,this._popup&&this._popup.setLngLat(this._lngLat),this._update(),this}getElement(){return this._element}setPopup(u){if(this._popup&&(this._popup.remove(),this._popup=null,this._element.removeEventListener("keypress",this._onKeyPress),this._originalTabIndex||this._element.removeAttribute("tabindex")),u){if(!("offset"in u.options)){const M=Math.abs(13.5)/Math.SQRT2;u.options.offset=this._defaultMarker?{top:[0,0],"top-left":[0,0],"top-right":[0,0],bottom:[0,-38.1],"bottom-left":[M,-1*(38.1-13.5+M)],"bottom-right":[-M,-1*(38.1-13.5+M)],left:[13.5,-1*(38.1-13.5)],right:[-13.5,-1*(38.1-13.5)]}:this._offset}this._popup=u,this._lngLat&&this._popup.setLngLat(this._lngLat),this._originalTabIndex=this._element.getAttribute("tabindex"),this._originalTabIndex||this._element.setAttribute("tabindex","0"),this._element.addEventListener("keypress",this._onKeyPress)}return this}getPopup(){return this._popup}togglePopup(){const u=this._popup;return u?(u.isOpen()?u.remove():u.addTo(this._map),this):this}_updateOpacity(u=!1){if(!this._map.terrain)return void(this._element.style.opacity==="0.2"&&(this._element.style.opacity="1"));if(u)this._opacityTimeout=null;else{if(this._opacityTimeout)return;this._opacityTimeout=setTimeout(()=>{this._opacityTimeout=null},100)}const p=this._map,C=p.terrain.depthAtPoint(this._pos),M=p.terrain.getElevationForLngLatZoom(this._lngLat,p.transform.tileZoom);if(p.transform.lngLatToCameraDepth(this._lngLat,M)-C<.006)return void(this._element.style.opacity="1");const I=-this._offset.y/p.transform._pixelPerMeter,L=Math.sin(p.getPitch()*Math.PI/180)*I,j=p.terrain.depthAtPoint(new a.P(this._pos.x,this._pos.y-this._offset.y)),G=p.transform.lngLatToCameraDepth(this._lngLat,M+L);this._element.style.opacity=G-j>.006?"0.2":"1.0"}getOffset(){return this._offset}setOffset(u){return this._offset=a.P.convert(u),this._update(),this}addClassName(u){this._element.classList.add(u)}removeClassName(u){this._element.classList.remove(u)}toggleClassName(u){return this._element.classList.toggle(u)}setDraggable(u){return this._draggable=!!u,this._map&&(u?(this._map.on("mousedown",this._addDragHandler),this._map.on("touchstart",this._addDragHandler)):(this._map.off("mousedown",this._addDragHandler),this._map.off("touchstart",this._addDragHandler))),this}isDraggable(){return this._draggable}setRotation(u){return this._rotation=u||0,this._update(),this}getRotation(){return this._rotation}setRotationAlignment(u){return this._rotationAlignment=u||"auto",this._update(),this}getRotationAlignment(){return this._rotationAlignment}setPitchAlignment(u){return this._pitchAlignment=u&&u!=="auto"?u:this._rotationAlignment,this._update(),this}getPitchAlignment(){return this._pitchAlignment}}const Ma={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0};let Ku=0,dc=!1;const kl={maxWidth:100,unit:"metric"};function kh(O,u,p){const C=p&&p.maxWidth||100,M=O._container.clientHeight/2,I=O.unproject([0,M]),L=O.unproject([C,M]),j=I.distanceTo(L);if(p&&p.unit==="imperial"){const G=3.2808*j;G>5280?hc(u,C,G/5280,O._getUIString("ScaleControl.Miles")):hc(u,C,G,O._getUIString("ScaleControl.Feet"))}else p&&p.unit==="nautical"?hc(u,C,j/1852,O._getUIString("ScaleControl.NauticalMiles")):j>=1e3?hc(u,C,j/1e3,O._getUIString("ScaleControl.Kilometers")):hc(u,C,j,O._getUIString("ScaleControl.Meters"))}function hc(O,u,p,C){const M=function(I){const L=Math.pow(10,`${Math.floor(I)}`.length-1);let j=I/L;return j=j>=10?10:j>=5?5:j>=3?3:j>=2?2:j>=1?1:function(G){const te=Math.pow(10,Math.ceil(-Math.log(G)/Math.LN10));return Math.round(G*te)/te}(j),L*j}(p);O.style.width=u*(M/p)+"px",O.innerHTML=`${M} ${C}`}const Ih={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},Ld=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", ");function zd(O){if(O){if(typeof O=="number"){const u=Math.round(Math.abs(O)/Math.SQRT2);return{center:new a.P(0,0),top:new a.P(0,O),"top-left":new a.P(u,u),"top-right":new a.P(-u,u),bottom:new a.P(0,-O),"bottom-left":new a.P(u,-u),"bottom-right":new a.P(-u,-u),left:new a.P(O,0),right:new a.P(-O,0)}}if(O instanceof a.P||Array.isArray(O)){const u=a.P.convert(O);return{center:u,top:u,"top-left":u,"top-right":u,bottom:u,"bottom-left":u,"bottom-right":u,left:u,right:u}}return{center:a.P.convert(O.center||[0,0]),top:a.P.convert(O.top||[0,0]),"top-left":a.P.convert(O["top-left"]||[0,0]),"top-right":a.P.convert(O["top-right"]||[0,0]),bottom:a.P.convert(O.bottom||[0,0]),"bottom-left":a.P.convert(O["bottom-left"]||[0,0]),"bottom-right":a.P.convert(O["bottom-right"]||[0,0]),left:a.P.convert(O.left||[0,0]),right:a.P.convert(O.right||[0,0])}}return zd(new a.P(0,0))}const Il={extend:(O,...u)=>a.e(O,...u),run(O){O()},logToElement(O,u=!1,p="log"){const C=window.document.getElementById(p);C&&(u&&(C.innerHTML=""),C.innerHTML+=`<br>${O}`)}},kf=f;class Pi{static get version(){return kf}static get workerCount(){return pt.workerCount}static set workerCount(u){pt.workerCount=u}static get maxParallelImageRequests(){return a.a.MAX_PARALLEL_IMAGE_REQUESTS}static set maxParallelImageRequests(u){a.a.MAX_PARALLEL_IMAGE_REQUESTS=u}static get workerUrl(){return a.a.WORKER_URL}static set workerUrl(u){a.a.WORKER_URL=u}}return Pi.Map=class extends Jc{constructor(O){if(a.ba.mark(a.bb.create),(O=a.e({},Bf,O)).minZoom!=null&&O.maxZoom!=null&&O.minZoom>O.maxZoom)throw new Error("maxZoom must be greater than or equal to minZoom");if(O.minPitch!=null&&O.maxPitch!=null&&O.minPitch>O.maxPitch)throw new Error("maxPitch must be greater than or equal to minPitch");if(O.minPitch!=null&&O.minPitch<0)throw new Error("minPitch must be greater than or equal to 0");if(O.maxPitch!=null&&O.maxPitch>85)throw new Error("maxPitch must be less than or equal to 85");if(super(new Vc(O.minZoom,O.maxZoom,O.minPitch,O.maxPitch,O.renderWorldCopies),{bearingSnap:O.bearingSnap}),this._contextLost=u=>{u.preventDefault(),this._frameRequest&&(this._frameRequest.abort(),this._frameRequest=null),this.fire(new a.k("webglcontextlost",{originalEvent:u}))},this._contextRestored=u=>{this._setupPainter(),this.resize(),this._update(),this.fire(new a.k("webglcontextrestored",{originalEvent:u}))},this._onMapScroll=u=>{if(u.target===this._container)return this._container.scrollTop=0,this._container.scrollLeft=0,!1},this._onWindowOnline=()=>{this._update()},this._interactive=O.interactive,this._maxTileCacheSize=O.maxTileCacheSize,this._maxTileCacheZoomLevels=O.maxTileCacheZoomLevels,this._failIfMajorPerformanceCaveat=O.failIfMajorPerformanceCaveat,this._preserveDrawingBuffer=O.preserveDrawingBuffer,this._antialias=O.antialias,this._trackResize=O.trackResize,this._bearingSnap=O.bearingSnap,this._refreshExpiredTiles=O.refreshExpiredTiles,this._fadeDuration=O.fadeDuration,this._crossSourceCollisions=O.crossSourceCollisions,this._crossFadingFactor=1,this._collectResourceTiming=O.collectResourceTiming,this._renderTaskQueue=new Bl,this._controls=[],this._mapId=a.a3(),this._locale=a.e({},du,O.locale),this._clickTolerance=O.clickTolerance,this._overridePixelRatio=O.pixelRatio,this._maxCanvasSize=O.maxCanvasSize,this.transformCameraUpdate=O.transformCameraUpdate,this._imageQueueHandle=oe.addThrottleControl(()=>this.isMoving()),this._requestManager=new ce(O.transformRequest),typeof O.container=="string"){if(this._container=document.getElementById(O.container),!this._container)throw new Error(`Container '${O.container}' not found.`)}else{if(!(O.container instanceof HTMLElement))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");this._container=O.container}if(O.maxBounds&&this.setMaxBounds(O.maxBounds),this._setupContainer(),this._setupPainter(),this.on("move",()=>this._update(!1)),this.on("moveend",()=>this._update(!1)),this.on("zoom",()=>this._update(!0)),this.on("terrain",()=>{this.painter.terrainFacilitator.dirty=!0,this._update(!0)}),this.once("idle",()=>{this._idleTriggered=!0}),typeof window<"u"){addEventListener("online",this._onWindowOnline,!1);let u=!1;const p=Ud(C=>{this._trackResize&&!this._removed&&this.resize(C)._update()},50);this._resizeObserver=new ResizeObserver(C=>{u?p(C):u=!0}),this._resizeObserver.observe(this._container)}this.handlers=new SA(this,O),this._hash=O.hash&&new ku(typeof O.hash=="string"&&O.hash||void 0).addTo(this),this._hash&&this._hash._onHashChange()||(this.jumpTo({center:O.center,zoom:O.zoom,bearing:O.bearing,pitch:O.pitch}),O.bounds&&(this.resize(),this.fitBounds(O.bounds,a.e({},O.fitBoundsOptions,{duration:0})))),this.resize(),this._localIdeographFontFamily=O.localIdeographFontFamily,this._validateStyle=O.validateStyle,O.style&&this.setStyle(O.style,{localIdeographFontFamily:O.localIdeographFontFamily}),O.attributionControl&&this.addControl(new dl({customAttribution:O.customAttribution})),O.maplibreLogo&&this.addControl(new xa,O.logoPosition),this.on("style.load",()=>{this.transform.unmodified&&this.jumpTo(this.style.stylesheet)}),this.on("data",u=>{this._update(u.dataType==="style"),this.fire(new a.k(`${u.dataType}data`,u))}),this.on("dataloading",u=>{this.fire(new a.k(`${u.dataType}dataloading`,u))}),this.on("dataabort",u=>{this.fire(new a.k("sourcedataabort",u))})}_getMapId(){return this._mapId}addControl(O,u){if(u===void 0&&(u=O.getDefaultPosition?O.getDefaultPosition():"top-right"),!O||!O.onAdd)return this.fire(new a.j(new Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));const p=O.onAdd(this);this._controls.push(O);const C=this._controlPositions[u];return u.indexOf("bottom")!==-1?C.insertBefore(p,C.firstChild):C.appendChild(p),this}removeControl(O){if(!O||!O.onRemove)return this.fire(new a.j(new Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));const u=this._controls.indexOf(O);return u>-1&&this._controls.splice(u,1),O.onRemove(this),this}hasControl(O){return this._controls.indexOf(O)>-1}calculateCameraOptionsFromTo(O,u,p,C){return C==null&&this.terrain&&(C=this.terrain.getElevationForLngLatZoom(p,this.transform.tileZoom)),super.calculateCameraOptionsFromTo(O,u,p,C)}resize(O){var u;const p=this._containerDimensions(),C=p[0],M=p[1],I=this._getClampedPixelRatio(C,M);if(this._resizeCanvas(C,M,I),this.painter.resize(C,M,I),this.painter.overLimit()){const j=this.painter.context.gl;this._maxCanvasSize=[j.drawingBufferWidth,j.drawingBufferHeight];const G=this._getClampedPixelRatio(C,M);this._resizeCanvas(C,M,G),this.painter.resize(C,M,G)}this.transform.resize(C,M),(u=this._requestedCameraState)===null||u===void 0||u.resize(C,M);const L=!this._moving;return L&&(this.stop(),this.fire(new a.k("movestart",O)).fire(new a.k("move",O))),this.fire(new a.k("resize",O)),L&&this.fire(new a.k("moveend",O)),this}_getClampedPixelRatio(O,u){const{0:p,1:C}=this._maxCanvasSize,M=this.getPixelRatio(),I=O*M,L=u*M;return Math.min(I>p?p/I:1,L>C?C/L:1)*M}getPixelRatio(){var O;return(O=this._overridePixelRatio)!==null&&O!==void 0?O:devicePixelRatio}setPixelRatio(O){this._overridePixelRatio=O,this.resize()}getBounds(){return this.transform.getBounds()}getMaxBounds(){return this.transform.getMaxBounds()}setMaxBounds(O){return this.transform.setMaxBounds(Kt.convert(O)),this._update()}setMinZoom(O){if((O=O??-2)>=-2&&O<=this.transform.maxZoom)return this.transform.minZoom=O,this._update(),this.getZoom()<O&&this.setZoom(O),this;throw new Error("minZoom must be between -2 and the current maxZoom, inclusive")}getMinZoom(){return this.transform.minZoom}setMaxZoom(O){if((O=O??22)>=this.transform.minZoom)return this.transform.maxZoom=O,this._update(),this.getZoom()>O&&this.setZoom(O),this;throw new Error("maxZoom must be greater than the current minZoom")}getMaxZoom(){return this.transform.maxZoom}setMinPitch(O){if((O=O??0)<0)throw new Error("minPitch must be greater than or equal to 0");if(O>=0&&O<=this.transform.maxPitch)return this.transform.minPitch=O,this._update(),this.getPitch()<O&&this.setPitch(O),this;throw new Error("minPitch must be between 0 and the current maxPitch, inclusive")}getMinPitch(){return this.transform.minPitch}setMaxPitch(O){if((O=O??60)>85)throw new Error("maxPitch must be less than or equal to 85");if(O>=this.transform.minPitch)return this.transform.maxPitch=O,this._update(),this.getPitch()>O&&this.setPitch(O),this;throw new Error("maxPitch must be greater than the current minPitch")}getMaxPitch(){return this.transform.maxPitch}getRenderWorldCopies(){return this.transform.renderWorldCopies}setRenderWorldCopies(O){return this.transform.renderWorldCopies=O,this._update()}project(O){return this.transform.locationPoint(a.M.convert(O),this.style&&this.terrain)}unproject(O){return this.transform.pointLocation(a.P.convert(O),this.terrain)}isMoving(){var O;return this._moving||((O=this.handlers)===null||O===void 0?void 0:O.isMoving())}isZooming(){var O;return this._zooming||((O=this.handlers)===null||O===void 0?void 0:O.isZooming())}isRotating(){var O;return this._rotating||((O=this.handlers)===null||O===void 0?void 0:O.isRotating())}_createDelegatedListener(O,u,p){if(O==="mouseenter"||O==="mouseover"){let C=!1;return{layer:u,listener:p,delegates:{mousemove:I=>{const L=this.getLayer(u)?this.queryRenderedFeatures(I.point,{layers:[u]}):[];L.length?C||(C=!0,p.call(this,new xs(O,this,I.originalEvent,{features:L}))):C=!1},mouseout:()=>{C=!1}}}}if(O==="mouseleave"||O==="mouseout"){let C=!1;return{layer:u,listener:p,delegates:{mousemove:L=>{(this.getLayer(u)?this.queryRenderedFeatures(L.point,{layers:[u]}):[]).length?C=!0:C&&(C=!1,p.call(this,new xs(O,this,L.originalEvent)))},mouseout:L=>{C&&(C=!1,p.call(this,new xs(O,this,L.originalEvent)))}}}}{const C=M=>{const I=this.getLayer(u)?this.queryRenderedFeatures(M.point,{layers:[u]}):[];I.length&&(M.features=I,p.call(this,M),delete M.features)};return{layer:u,listener:p,delegates:{[O]:C}}}}on(O,u,p){if(p===void 0)return super.on(O,u);const C=this._createDelegatedListener(O,u,p);this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[O]=this._delegatedListeners[O]||[],this._delegatedListeners[O].push(C);for(const M in C.delegates)this.on(M,C.delegates[M]);return this}once(O,u,p){if(p===void 0)return super.once(O,u);const C=this._createDelegatedListener(O,u,p);for(const M in C.delegates)this.once(M,C.delegates[M]);return this}off(O,u,p){return p===void 0?super.off(O,u):(this._delegatedListeners&&this._delegatedListeners[O]&&(C=>{const M=this._delegatedListeners[O];for(let I=0;I<M.length;I++){const L=M[I];if(L.layer===u&&L.listener===p){for(const j in L.delegates)this.off(j,L.delegates[j]);return M.splice(I,1),this}}})(),this)}queryRenderedFeatures(O,u){if(!this.style)return[];let p;const C=O instanceof a.P||Array.isArray(O),M=C?O:[[0,0],[this.transform.width,this.transform.height]];if(u=u||(C?{}:O)||{},M instanceof a.P||typeof M[0]=="number")p=[a.P.convert(M)];else{const I=a.P.convert(M[0]),L=a.P.convert(M[1]);p=[I,new a.P(L.x,I.y),L,new a.P(I.x,L.y),I]}return this.style.queryRenderedFeatures(p,u,this.transform)}querySourceFeatures(O,u){return this.style.querySourceFeatures(O,u)}setStyle(O,u){return(u=a.e({},{localIdeographFontFamily:this._localIdeographFontFamily,validate:this._validateStyle},u)).diff!==!1&&u.localIdeographFontFamily===this._localIdeographFontFamily&&this.style&&O?(this._diffStyle(O,u),this):(this._localIdeographFontFamily=u.localIdeographFontFamily,this._updateStyle(O,u))}setTransformRequest(O){return this._requestManager.setTransformRequest(O),this}_getUIString(O){const u=this._locale[O];if(u==null)throw new Error(`Missing UI string '${O}'`);return u}_updateStyle(O,u){if(u.transformStyle&&this.style&&!this.style._loaded)return void this.style.once("style.load",()=>this._updateStyle(O,u));const p=this.style&&u.transformStyle?this.style.serialize():void 0;return this.style&&(this.style.setEventedParent(null),this.style._remove(!O)),O?(this.style=new Ti(this,u||{}),this.style.setEventedParent(this,{style:this.style}),typeof O=="string"?this.style.loadURL(O,u,p):this.style.loadJSON(O,u,p),this):(delete this.style,this)}_lazyInitEmptyStyle(){this.style||(this.style=new Ti(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())}_diffStyle(O,u){if(typeof O=="string"){const p=this._requestManager.transformRequest(O,ne.Style);a.h(p,new AbortController).then(C=>{this._updateDiff(C.data,u)}).catch(C=>{C&&this.fire(new a.j(C))})}else typeof O=="object"&&this._updateDiff(O,u)}_updateDiff(O,u){try{this.style.setState(O,u)&&this._update(!0)}catch(p){a.w(`Unable to perform style diff: ${p.message||p.error||p}. Rebuilding the style from scratch.`),this._updateStyle(O,u)}}getStyle(){if(this.style)return this.style.serialize()}isStyleLoaded(){return this.style?this.style.loaded():a.w("There is no style added to the map.")}addSource(O,u){return this._lazyInitEmptyStyle(),this.style.addSource(O,u),this._update(!0)}isSourceLoaded(O){const u=this.style&&this.style.sourceCaches[O];if(u!==void 0)return u.loaded();this.fire(new a.j(new Error(`There is no source with ID '${O}'`)))}setTerrain(O){if(this.style._checkLoaded(),this._terrainDataCallback&&this.style.off("data",this._terrainDataCallback),O){const u=this.style.sourceCaches[O.source];if(!u)throw new Error(`cannot load terrain, because there exists no source with ID: ${O.source}`);this.terrain===null&&u.reload();for(const p in this.style._layers){const C=this.style._layers[p];C.type==="hillshade"&&C.source===O.source&&a.w("You are using the same source for a hillshade layer and for 3D terrain. Please consider using two separate sources to improve rendering quality.")}this.terrain=new iA(this.painter,u,O),this.painter.renderToTexture=new Ip(this.painter,this.terrain),this.transform.minElevationForCurrentTile=this.terrain.getMinTileElevationForLngLatZoom(this.transform.center,this.transform.tileZoom),this.transform.elevation=this.terrain.getElevationForLngLatZoom(this.transform.center,this.transform.tileZoom),this._terrainDataCallback=p=>{p.dataType==="style"?this.terrain.sourceCache.freeRtt():p.dataType==="source"&&p.tile&&(p.sourceId!==O.source||this._elevationFreeze||(this.transform.minElevationForCurrentTile=this.terrain.getMinTileElevationForLngLatZoom(this.transform.center,this.transform.tileZoom),this.transform.elevation=this.terrain.getElevationForLngLatZoom(this.transform.center,this.transform.tileZoom)),this.terrain.sourceCache.freeRtt(p.tile.tileID))},this.style.on("data",this._terrainDataCallback)}else this.terrain&&this.terrain.sourceCache.destruct(),this.terrain=null,this.painter.renderToTexture&&this.painter.renderToTexture.destruct(),this.painter.renderToTexture=null,this.transform.minElevationForCurrentTile=0,this.transform.elevation=0;return this.fire(new a.k("terrain",{terrain:O})),this}getTerrain(){var O,u;return(u=(O=this.terrain)===null||O===void 0?void 0:O.options)!==null&&u!==void 0?u:null}areTilesLoaded(){const O=this.style&&this.style.sourceCaches;for(const u in O){const p=O[u]._tiles;for(const C in p){const M=p[C];if(M.state!=="loaded"&&M.state!=="errored")return!1}}return!0}removeSource(O){return this.style.removeSource(O),this._update(!0)}getSource(O){return this.style.getSource(O)}addImage(O,u,p={}){const{pixelRatio:C=1,sdf:M=!1,stretchX:I,stretchY:L,content:j}=p;if(this._lazyInitEmptyStyle(),!(u instanceof HTMLImageElement||a.b(u))){if(u.width===void 0||u.height===void 0)return this.fire(new a.j(new Error("Invalid arguments to map.addImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")));{const{width:G,height:te,data:Ae}=u,he=u;return this.style.addImage(O,{data:new a.R({width:G,height:te},new Uint8Array(Ae)),pixelRatio:C,stretchX:I,stretchY:L,content:j,sdf:M,version:0,userImage:he}),he.onAdd&&he.onAdd(this,O),this}}{const{width:G,height:te,data:Ae}=k.getImageData(u);this.style.addImage(O,{data:new a.R({width:G,height:te},Ae),pixelRatio:C,stretchX:I,stretchY:L,content:j,sdf:M,version:0})}}updateImage(O,u){const p=this.style.getImage(O);if(!p)return this.fire(new a.j(new Error("The map has no image with that id. If you are adding a new image use `map.addImage(...)` instead.")));const C=u instanceof HTMLImageElement||a.b(u)?k.getImageData(u):u,{width:M,height:I,data:L}=C;if(M===void 0||I===void 0)return this.fire(new a.j(new Error("Invalid arguments to map.updateImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")));if(M!==p.data.width||I!==p.data.height)return this.fire(new a.j(new Error("The width and height of the updated image must be that same as the previous version of the image")));const j=!(u instanceof HTMLImageElement||a.b(u));return p.data.replace(L,j),this.style.updateImage(O,p),this}getImage(O){return this.style.getImage(O)}hasImage(O){return O?!!this.style.getImage(O):(this.fire(new a.j(new Error("Missing required image id"))),!1)}removeImage(O){this.style.removeImage(O)}loadImage(O){return oe.getImage(this._requestManager.transformRequest(O,ne.Image),new AbortController)}listImages(){return this.style.listImages()}addLayer(O,u){return this._lazyInitEmptyStyle(),this.style.addLayer(O,u),this._update(!0)}moveLayer(O,u){return this.style.moveLayer(O,u),this._update(!0)}removeLayer(O){return this.style.removeLayer(O),this._update(!0)}getLayer(O){return this.style.getLayer(O)}getLayersOrder(){return this.style.getLayersOrder()}setLayerZoomRange(O,u,p){return this.style.setLayerZoomRange(O,u,p),this._update(!0)}setFilter(O,u,p={}){return this.style.setFilter(O,u,p),this._update(!0)}getFilter(O){return this.style.getFilter(O)}setPaintProperty(O,u,p,C={}){return this.style.setPaintProperty(O,u,p,C),this._update(!0)}getPaintProperty(O,u){return this.style.getPaintProperty(O,u)}setLayoutProperty(O,u,p,C={}){return this.style.setLayoutProperty(O,u,p,C),this._update(!0)}getLayoutProperty(O,u){return this.style.getLayoutProperty(O,u)}setGlyphs(O,u={}){return this._lazyInitEmptyStyle(),this.style.setGlyphs(O,u),this._update(!0)}getGlyphs(){return this.style.getGlyphsUrl()}addSprite(O,u,p={}){return this._lazyInitEmptyStyle(),this.style.addSprite(O,u,p,C=>{C||this._update(!0)}),this}removeSprite(O){return this._lazyInitEmptyStyle(),this.style.removeSprite(O),this._update(!0)}getSprite(){return this.style.getSprite()}setSprite(O,u={}){return this._lazyInitEmptyStyle(),this.style.setSprite(O,u,p=>{p||this._update(!0)}),this}setLight(O,u={}){return this._lazyInitEmptyStyle(),this.style.setLight(O,u),this._update(!0)}getLight(){return this.style.getLight()}setFeatureState(O,u){return this.style.setFeatureState(O,u),this._update()}removeFeatureState(O,u){return this.style.removeFeatureState(O,u),this._update()}getFeatureState(O){return this.style.getFeatureState(O)}getContainer(){return this._container}getCanvasContainer(){return this._canvasContainer}getCanvas(){return this._canvas}_containerDimensions(){let O=0,u=0;return this._container&&(O=this._container.clientWidth||400,u=this._container.clientHeight||300),[O,u]}_setupContainer(){const O=this._container;O.classList.add("maplibregl-map");const u=this._canvasContainer=B.create("div","maplibregl-canvas-container",O);this._interactive&&u.classList.add("maplibregl-interactive"),this._canvas=B.create("canvas","maplibregl-canvas",u),this._canvas.addEventListener("webglcontextlost",this._contextLost,!1),this._canvas.addEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.setAttribute("tabindex","0"),this._canvas.setAttribute("aria-label","Map"),this._canvas.setAttribute("role","region");const p=this._containerDimensions(),C=this._getClampedPixelRatio(p[0],p[1]);this._resizeCanvas(p[0],p[1],C);const M=this._controlContainer=B.create("div","maplibregl-control-container",O),I=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach(L=>{I[L]=B.create("div",`maplibregl-ctrl-${L} `,M)}),this._container.addEventListener("scroll",this._onMapScroll,!1)}_resizeCanvas(O,u,p){this._canvas.width=Math.floor(p*O),this._canvas.height=Math.floor(p*u),this._canvas.style.width=`${O}px`,this._canvas.style.height=`${u}px`}_setupPainter(){const O={alpha:!0,stencil:!0,depth:!0,failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer,antialias:this._antialias||!1};let u=null;this._canvas.addEventListener("webglcontextcreationerror",C=>{u={requestedAttributes:O},C&&(u.statusMessage=C.statusMessage,u.type=C.type)},{once:!0});const p=this._canvas.getContext("webgl2",O)||this._canvas.getContext("webgl",O);if(!p){const C="Failed to initialize WebGL";throw u?(u.message=C,new Error(JSON.stringify(u))):new Error(C)}this.painter=new Fd(p,this.transform),P.testSupport(p)}loaded(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()}_update(O){return this.style&&this.style._loaded?(this._styleDirty=this._styleDirty||O,this._sourcesDirty=!0,this.triggerRepaint(),this):this}_requestRenderFrame(O){return this._update(),this._renderTaskQueue.add(O)}_cancelRenderFrame(O){this._renderTaskQueue.remove(O)}_render(O){const u=this._idleTriggered?this._fadeDuration:0;if(this.painter.context.setDirty(),this.painter.setBaseState(),this._renderTaskQueue.run(O),this._removed)return;let p=!1;if(this.style&&this._styleDirty){this._styleDirty=!1;const M=this.transform.zoom,I=k.now();this.style.zoomHistory.update(M,I);const L=new a.a8(M,{now:I,fadeDuration:u,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),j=L.crossFadingFactor();j===1&&j===this._crossFadingFactor||(p=!0,this._crossFadingFactor=j),this.style.update(L)}this.style&&this._sourcesDirty&&(this._sourcesDirty=!1,this.style._updateSources(this.transform)),this.terrain?(this.terrain.sourceCache.update(this.transform,this.terrain),this.transform.minElevationForCurrentTile=this.terrain.getMinTileElevationForLngLatZoom(this.transform.center,this.transform.tileZoom),this._elevationFreeze||(this.transform.elevation=this.terrain.getElevationForLngLatZoom(this.transform.center,this.transform.tileZoom))):(this.transform.minElevationForCurrentTile=0,this.transform.elevation=0),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,u,this._crossSourceCollisions),this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showOverdrawInspector:this._showOverdrawInspector,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:u,showPadding:this.showPadding}),this.fire(new a.k("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,a.ba.mark(a.bb.load),this.fire(new a.k("load"))),this.style&&(this.style.hasTransitions()||p)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles();const C=this._sourcesDirty||this._styleDirty||this._placementDirty;return C||this._repaint?this.triggerRepaint():!this.isMoving()&&this.loaded()&&this.fire(new a.k("idle")),!this._loaded||this._fullyLoaded||C||(this._fullyLoaded=!0,a.ba.mark(a.bb.fullLoad)),this}redraw(){return this.style&&(this._frameRequest&&(this._frameRequest.abort(),this._frameRequest=null),this._render(0)),this}remove(){var O;this._hash&&this._hash.remove();for(const p of this._controls)p.onRemove(this);this._controls=[],this._frameRequest&&(this._frameRequest.abort(),this._frameRequest=null),this._renderTaskQueue.clear(),this.painter.destroy(),this.handlers.destroy(),delete this.handlers,this.setStyle(null),typeof window<"u"&&removeEventListener("online",this._onWindowOnline,!1),oe.removeThrottleControl(this._imageQueueHandle),(O=this._resizeObserver)===null||O===void 0||O.disconnect();const u=this.painter.context.gl.getExtension("WEBGL_lose_context");u&&u.loseContext(),this._canvas.removeEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.removeEventListener("webglcontextlost",this._contextLost,!1),B.remove(this._canvasContainer),B.remove(this._controlContainer),this._container.classList.remove("maplibregl-map"),a.ba.clearMetrics(),this._removed=!0,this.fire(new a.k("remove"))}triggerRepaint(){this.style&&!this._frameRequest&&(this._frameRequest=new AbortController,k.frameAsync(this._frameRequest).then(O=>{a.ba.frame(O),this._frameRequest=null,this._render(O)}).catch(()=>{}))}get showTileBoundaries(){return!!this._showTileBoundaries}set showTileBoundaries(O){this._showTileBoundaries!==O&&(this._showTileBoundaries=O,this._update())}get showPadding(){return!!this._showPadding}set showPadding(O){this._showPadding!==O&&(this._showPadding=O,this._update())}get showCollisionBoxes(){return!!this._showCollisionBoxes}set showCollisionBoxes(O){this._showCollisionBoxes!==O&&(this._showCollisionBoxes=O,O?this.style._generateCollisionBoxes():this._update())}get showOverdrawInspector(){return!!this._showOverdrawInspector}set showOverdrawInspector(O){this._showOverdrawInspector!==O&&(this._showOverdrawInspector=O,this._update())}get repaint(){return!!this._repaint}set repaint(O){this._repaint!==O&&(this._repaint=O,this.triggerRepaint())}get vertices(){return!!this._vertices}set vertices(O){this._vertices=O,this._update()}get version(){return Tu}getCameraTargetElevation(){return this.transform.elevation}},Pi.NavigationControl=class{constructor(O){this._updateZoomButtons=()=>{const u=this._map.getZoom(),p=u===this._map.getMaxZoom(),C=u===this._map.getMinZoom();this._zoomInButton.disabled=p,this._zoomOutButton.disabled=C,this._zoomInButton.setAttribute("aria-disabled",p.toString()),this._zoomOutButton.setAttribute("aria-disabled",C.toString())},this._rotateCompassArrow=()=>{const u=this.options.visualizePitch?`scale(${1/Math.pow(Math.cos(this._map.transform.pitch*(Math.PI/180)),.5)}) rotateX(${this._map.transform.pitch}deg) rotateZ(${this._map.transform.angle*(180/Math.PI)}deg)`:`rotate(${this._map.transform.angle*(180/Math.PI)}deg)`;this._compassIcon.style.transform=u},this._setButtonTitle=(u,p)=>{const C=this._map._getUIString(`NavigationControl.${p}`);u.title=C,u.setAttribute("aria-label",C)},this.options=a.e({},cc,O),this._container=B.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._container.addEventListener("contextmenu",u=>u.preventDefault()),this.options.showZoom&&(this._zoomInButton=this._createButton("maplibregl-ctrl-zoom-in",u=>this._map.zoomIn({},{originalEvent:u})),B.create("span","maplibregl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden","true"),this._zoomOutButton=this._createButton("maplibregl-ctrl-zoom-out",u=>this._map.zoomOut({},{originalEvent:u})),B.create("span","maplibregl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden","true")),this.options.showCompass&&(this._compass=this._createButton("maplibregl-ctrl-compass",u=>{this.options.visualizePitch?this._map.resetNorthPitch({},{originalEvent:u}):this._map.resetNorth({},{originalEvent:u})}),this._compassIcon=B.create("span","maplibregl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden","true"))}onAdd(O){return this._map=O,this.options.showZoom&&(this._setButtonTitle(this._zoomInButton,"ZoomIn"),this._setButtonTitle(this._zoomOutButton,"ZoomOut"),this._map.on("zoom",this._updateZoomButtons),this._updateZoomButtons()),this.options.showCompass&&(this._setButtonTitle(this._compass,"ResetBearing"),this.options.visualizePitch&&this._map.on("pitch",this._rotateCompassArrow),this._map.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new ed(this._map,this._compass,this.options.visualizePitch)),this._container}onRemove(){B.remove(this._container),this.options.showZoom&&this._map.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&this._map.off("pitch",this._rotateCompassArrow),this._map.off("rotate",this._rotateCompassArrow),this._handler.off(),delete this._handler),delete this._map}_createButton(O,u){const p=B.create("button",O,this._container);return p.type="button",p.addEventListener("click",u),p}},Pi.GeolocateControl=class extends a.E{constructor(O){super(),this._onSuccess=u=>{if(this._map){if(this._isOutOfMapMaxBounds(u))return this._setErrorState(),this.fire(new a.k("outofmaxbounds",u)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=u,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-background");break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}this.options.showUserLocation&&this._watchState!=="OFF"&&this._updateMarker(u),this.options.trackUserLocation&&this._watchState!=="ACTIVE_LOCK"||this._updateCamera(u),this.options.showUserLocation&&this._dotElement.classList.remove("maplibregl-user-location-dot-stale"),this.fire(new a.k("geolocate",u)),this._finish()}},this._updateCamera=u=>{const p=new a.M(u.coords.longitude,u.coords.latitude),C=u.coords.accuracy,M=this._map.getBearing(),I=a.e({bearing:M},this.options.fitBoundsOptions),L=Kt.fromLngLat(p,C);this._map.fitBounds(L,I,{geolocateSource:!0})},this._updateMarker=u=>{if(u){const p=new a.M(u.coords.longitude,u.coords.latitude);this._accuracyCircleMarker.setLngLat(p).addTo(this._map),this._userLocationDotMarker.setLngLat(p).addTo(this._map),this._accuracy=u.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()},this._onZoom=()=>{this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()},this._onError=u=>{if(this._map){if(this.options.trackUserLocation)if(u.code===1){this._watchState="OFF",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;const p=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.title=p,this._geolocateButton.setAttribute("aria-label",p),this._geolocationWatchID!==void 0&&this._clearWatch()}else{if(u.code===3&&dc)return;this._setErrorState()}this._watchState!=="OFF"&&this.options.showUserLocation&&this._dotElement.classList.add("maplibregl-user-location-dot-stale"),this.fire(new a.k("error",u)),this._finish()}},this._finish=()=>{this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0},this._setupUI=u=>{if(this._map){if(this._container.addEventListener("contextmenu",p=>p.preventDefault()),this._geolocateButton=B.create("button","maplibregl-ctrl-geolocate",this._container),B.create("span","maplibregl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden","true"),this._geolocateButton.type="button",u===!1){a.w("Geolocation support is not available so the GeolocateControl will be disabled.");const p=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.title=p,this._geolocateButton.setAttribute("aria-label",p)}else{const p=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.title=p,this._geolocateButton.setAttribute("aria-label",p)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","false"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=B.create("div","maplibregl-user-location-dot"),this._userLocationDotMarker=new jr({element:this._dotElement}),this._circleElement=B.create("div","maplibregl-user-location-accuracy-circle"),this._accuracyCircleMarker=new jr({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",()=>this.trigger()),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",p=>{p.geolocateSource||this._watchState!=="ACTIVE_LOCK"||p.originalEvent&&p.originalEvent.type==="resize"||(this._watchState="BACKGROUND",this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this.fire(new a.k("trackuserlocationend")))})}},this.options=a.e({},Ma,O)}onAdd(O){return this._map=O,this._container=B.create("div","maplibregl-ctrl maplibregl-ctrl-group"),function(u=!1){return a._(this,void 0,void 0,function*(){if(ke!==void 0&&!u)return ke;if(window.navigator.permissions===void 0)return ke=!!window.navigator.geolocation,ke;try{ke=(yield window.navigator.permissions.query({name:"geolocation"})).state!=="denied"}catch{ke=!!window.navigator.geolocation}return ke})}().then(u=>this._setupUI(u)),this._container}onRemove(){this._geolocationWatchID!==void 0&&(window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),B.remove(this._container),this._map.off("zoom",this._onZoom),this._map=void 0,Ku=0,dc=!1}_isOutOfMapMaxBounds(O){const u=this._map.getMaxBounds(),p=O.coords;return u&&(p.longitude<u.getWest()||p.longitude>u.getEast()||p.latitude<u.getSouth()||p.latitude>u.getNorth())}_setErrorState(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting");break;case"ACTIVE_ERROR":break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}}_updateCircleRadius(){const O=this._map.getBounds(),u=O.getSouthEast(),p=O.getNorthEast(),C=u.distanceTo(p),M=Math.ceil(this._accuracy/(C/this._map._container.clientHeight)*2);this._circleElement.style.width=`${M}px`,this._circleElement.style.height=`${M}px`}trigger(){if(!this._setup)return a.w("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new a.k("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":Ku--,dc=!1,this._watchState="OFF",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background-error"),this.fire(new a.k("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new a.k("trackuserlocationstart"));break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-active");break;case"OFF":break;default:throw new Error(`Unexpected watchState ${this._watchState}`)}if(this._watchState==="OFF"&&this._geolocationWatchID!==void 0)this._clearWatch();else if(this._geolocationWatchID===void 0){let O;this._geolocateButton.classList.add("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),Ku++,Ku>1?(O={maximumAge:6e5,timeout:0},dc=!0):(O=this.options.positionOptions,dc=!1),this._geolocationWatchID=window.navigator.geolocation.watchPosition(this._onSuccess,this._onError,O)}}else window.navigator.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0}_clearWatch(){window.navigator.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("maplibregl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","false"),this.options.showUserLocation&&this._updateMarker(null)}},Pi.AttributionControl=dl,Pi.LogoControl=xa,Pi.ScaleControl=class{constructor(O){this._onMove=()=>{kh(this._map,this._container,this.options)},this.setUnit=u=>{this.options.unit=u,kh(this._map,this._container,this.options)},this.options=a.e({},kl,O)}getDefaultPosition(){return"bottom-left"}onAdd(O){return this._map=O,this._container=B.create("div","maplibregl-ctrl maplibregl-ctrl-scale",O.getContainer()),this._map.on("move",this._onMove),this._onMove(),this._container}onRemove(){B.remove(this._container),this._map.off("move",this._onMove),this._map=void 0}},Pi.FullscreenControl=class extends a.E{constructor(O={}){super(),this._onFullscreenChange=()=>{(window.document.fullscreenElement||window.document.mozFullScreenElement||window.document.webkitFullscreenElement||window.document.msFullscreenElement)===this._container!==this._fullscreen&&this._handleFullscreenChange()},this._onClickFullscreen=()=>{this._isFullscreen()?this._exitFullscreen():this._requestFullscreen()},this._fullscreen=!1,O&&O.container&&(O.container instanceof HTMLElement?this._container=O.container:a.w("Full screen control 'container' must be a DOM element.")),"onfullscreenchange"in document?this._fullscreenchange="fullscreenchange":"onmozfullscreenchange"in document?this._fullscreenchange="mozfullscreenchange":"onwebkitfullscreenchange"in document?this._fullscreenchange="webkitfullscreenchange":"onmsfullscreenchange"in document&&(this._fullscreenchange="MSFullscreenChange")}onAdd(O){return this._map=O,this._container||(this._container=this._map.getContainer()),this._controlContainer=B.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._setupUI(),this._controlContainer}onRemove(){B.remove(this._controlContainer),this._map=null,window.document.removeEventListener(this._fullscreenchange,this._onFullscreenChange)}_setupUI(){const O=this._fullscreenButton=B.create("button","maplibregl-ctrl-fullscreen",this._controlContainer);B.create("span","maplibregl-ctrl-icon",O).setAttribute("aria-hidden","true"),O.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),window.document.addEventListener(this._fullscreenchange,this._onFullscreenChange)}_updateTitle(){const O=this._getTitle();this._fullscreenButton.setAttribute("aria-label",O),this._fullscreenButton.title=O}_getTitle(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")}_isFullscreen(){return this._fullscreen}_handleFullscreenChange(){this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("maplibregl-ctrl-shrink"),this._fullscreenButton.classList.toggle("maplibregl-ctrl-fullscreen"),this._updateTitle(),this._fullscreen?(this.fire(new a.k("fullscreenstart")),this._prevCooperativeGesturesEnabled=this._map.cooperativeGestures.isEnabled(),this._map.cooperativeGestures.disable()):(this.fire(new a.k("fullscreenend")),this._prevCooperativeGesturesEnabled&&this._map.cooperativeGestures.enable())}_exitFullscreen(){window.document.exitFullscreen?window.document.exitFullscreen():window.document.mozCancelFullScreen?window.document.mozCancelFullScreen():window.document.msExitFullscreen?window.document.msExitFullscreen():window.document.webkitCancelFullScreen?window.document.webkitCancelFullScreen():this._togglePseudoFullScreen()}_requestFullscreen(){this._container.requestFullscreen?this._container.requestFullscreen():this._container.mozRequestFullScreen?this._container.mozRequestFullScreen():this._container.msRequestFullscreen?this._container.msRequestFullscreen():this._container.webkitRequestFullscreen?this._container.webkitRequestFullscreen():this._togglePseudoFullScreen()}_togglePseudoFullScreen(){this._container.classList.toggle("maplibregl-pseudo-fullscreen"),this._handleFullscreenChange(),this._map.resize()}},Pi.TerrainControl=class{constructor(O){this._toggleTerrain=()=>{this._map.getTerrain()?this._map.setTerrain(null):this._map.setTerrain(this.options),this._updateTerrainIcon()},this._updateTerrainIcon=()=>{this._terrainButton.classList.remove("maplibregl-ctrl-terrain"),this._terrainButton.classList.remove("maplibregl-ctrl-terrain-enabled"),this._map.terrain?(this._terrainButton.classList.add("maplibregl-ctrl-terrain-enabled"),this._terrainButton.title=this._map._getUIString("TerrainControl.disableTerrain")):(this._terrainButton.classList.add("maplibregl-ctrl-terrain"),this._terrainButton.title=this._map._getUIString("TerrainControl.enableTerrain"))},this.options=O}onAdd(O){return this._map=O,this._container=B.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._terrainButton=B.create("button","maplibregl-ctrl-terrain",this._container),B.create("span","maplibregl-ctrl-icon",this._terrainButton).setAttribute("aria-hidden","true"),this._terrainButton.type="button",this._terrainButton.addEventListener("click",this._toggleTerrain),this._updateTerrainIcon(),this._map.on("terrain",this._updateTerrainIcon),this._container}onRemove(){B.remove(this._container),this._map.off("terrain",this._updateTerrainIcon),this._map=void 0}},Pi.Popup=class extends a.E{constructor(O){super(),this.remove=()=>(this._content&&B.remove(this._content),this._container&&(B.remove(this._container),delete this._container),this._map&&(this._map.off("move",this._update),this._map.off("move",this._onClose),this._map.off("click",this._onClose),this._map.off("remove",this.remove),this._map.off("mousemove",this._onMouseMove),this._map.off("mouseup",this._onMouseUp),this._map.off("drag",this._onDrag),this._map._canvasContainer.classList.remove("maplibregl-track-pointer"),delete this._map),this.fire(new a.k("close")),this),this._onMouseUp=u=>{this._update(u.point)},this._onMouseMove=u=>{this._update(u.point)},this._onDrag=u=>{this._update(u.point)},this._update=u=>{if(!this._map||!this._lngLat&&!this._trackPointer||!this._content)return;if(!this._container){if(this._container=B.create("div","maplibregl-popup",this._map.getContainer()),this._tip=B.create("div","maplibregl-popup-tip",this._container),this._container.appendChild(this._content),this.options.className)for(const L of this.options.className.split(" "))this._container.classList.add(L);this._trackPointer&&this._container.classList.add("maplibregl-popup-track-pointer")}if(this.options.maxWidth&&this._container.style.maxWidth!==this.options.maxWidth&&(this._container.style.maxWidth=this.options.maxWidth),this._map.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=oA(this._lngLat,this._pos,this._map.transform)),this._trackPointer&&!u)return;const p=this._pos=this._trackPointer&&u?u:this._map.project(this._lngLat);let C=this.options.anchor;const M=zd(this.options.offset);if(!C){const L=this._container.offsetWidth,j=this._container.offsetHeight;let G;G=p.y+M.bottom.y<j?["top"]:p.y>this._map.transform.height-j?["bottom"]:[],p.x<L/2?G.push("left"):p.x>this._map.transform.width-L/2&&G.push("right"),C=G.length===0?"bottom":G.join("-")}const I=p.add(M[C]).round();B.setTransform(this._container,`${wa[C]} translate(${I.x}px,${I.y}px)`),uo(this._container,C,"popup")},this._onClose=()=>{this.remove()},this.options=a.e(Object.create(Ih),O)}addTo(O){return this._map&&this.remove(),this._map=O,this.options.closeOnClick&&this._map.on("click",this._onClose),this.options.closeOnMove&&this._map.on("move",this._onClose),this._map.on("remove",this.remove),this._update(),this._focusFirstElement(),this._trackPointer?(this._map.on("mousemove",this._onMouseMove),this._map.on("mouseup",this._onMouseUp),this._container&&this._container.classList.add("maplibregl-popup-track-pointer"),this._map._canvasContainer.classList.add("maplibregl-track-pointer")):this._map.on("move",this._update),this.fire(new a.k("open")),this}isOpen(){return!!this._map}getLngLat(){return this._lngLat}setLngLat(O){return this._lngLat=a.M.convert(O),this._pos=null,this._trackPointer=!1,this._update(),this._map&&(this._map.on("move",this._update),this._map.off("mousemove",this._onMouseMove),this._container&&this._container.classList.remove("maplibregl-popup-track-pointer"),this._map._canvasContainer.classList.remove("maplibregl-track-pointer")),this}trackPointer(){return this._trackPointer=!0,this._pos=null,this._update(),this._map&&(this._map.off("move",this._update),this._map.on("mousemove",this._onMouseMove),this._map.on("drag",this._onDrag),this._container&&this._container.classList.add("maplibregl-popup-track-pointer"),this._map._canvasContainer.classList.add("maplibregl-track-pointer")),this}getElement(){return this._container}setText(O){return this.setDOMContent(document.createTextNode(O))}setHTML(O){const u=document.createDocumentFragment(),p=document.createElement("body");let C;for(p.innerHTML=O;C=p.firstChild,C;)u.appendChild(C);return this.setDOMContent(u)}getMaxWidth(){var O;return(O=this._container)===null||O===void 0?void 0:O.style.maxWidth}setMaxWidth(O){return this.options.maxWidth=O,this._update(),this}setDOMContent(O){if(this._content)for(;this._content.hasChildNodes();)this._content.firstChild&&this._content.removeChild(this._content.firstChild);else this._content=B.create("div","maplibregl-popup-content",this._container);return this._content.appendChild(O),this._createCloseButton(),this._update(),this._focusFirstElement(),this}addClassName(O){this._container&&this._container.classList.add(O)}removeClassName(O){this._container&&this._container.classList.remove(O)}setOffset(O){return this.options.offset=O,this._update(),this}toggleClassName(O){if(this._container)return this._container.classList.toggle(O)}_createCloseButton(){this.options.closeButton&&(this._closeButton=B.create("button","maplibregl-popup-close-button",this._content),this._closeButton.type="button",this._closeButton.setAttribute("aria-label","Close popup"),this._closeButton.innerHTML="×",this._closeButton.addEventListener("click",this._onClose))}_focusFirstElement(){if(!this.options.focusAfterOpen||!this._container)return;const O=this._container.querySelector(Ld);O&&O.focus()}},Pi.Marker=jr,Pi.Style=Ti,Pi.LngLat=a.M,Pi.LngLatBounds=Kt,Pi.Point=a.P,Pi.MercatorCoordinate=a.Y,Pi.Evented=a.E,Pi.AJAXError=a.bc,Pi.config=a.a,Pi.CanvasSource=Qr,Pi.GeoJSONSource=ir,Pi.ImageSource=nr,Pi.RasterDEMTileSource=pn,Pi.RasterTileSource=mt,Pi.VectorTileSource=zn,Pi.VideoSource=Mr,Pi.setRTLTextPlugin=(O,u)=>X().setRTLTextPlugin(O,u),Pi.getRTLTextPluginStatus=()=>X().getRTLTextPluginStatus(),Pi.prewarm=function(){Se().acquire(Vt)},Pi.clearPrewarmedResources=function(){const O=kt;O&&(O.isPreloaded()&&O.numActive()===1?(O.release(Vt),kt=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},Pi.addProtocol=a.bd,Pi.removeProtocol=a.be,Pi.addSourceType=(O,u)=>((p,C)=>a._(void 0,void 0,void 0,function*(){if(vi(p))throw new Error(`A source type called "${p}" already exists.`);((M,I)=>{_r[M]=I})(p,C)}))(O,u),Pi.importScriptInWorkers=O=>xe().broadcast("importScript",O),Il.extend(Pi,{isSafari:a.B,getPerformanceMetrics:a.ba.getPerformanceMetrics}),Pi});var s=i;return s})})(jR);var kX=jR.exports;const g2=ga(kX);var _p={};function E6(e,n,t){var r={id:[n,t,"circle"].join("_"),source:n,type:"circle",paint:{"circle-color":e,"circle-radius":2},filter:["==","$type","Point"]};return t&&(r["source-layer"]=t),r}function O6(e,n,t,r){var i={id:[t,r,"polygon"].join("_"),source:t,type:"fill",paint:{"fill-color":e,"fill-antialias":!0,"fill-outline-color":e},filter:["==","$type","Polygon"]};return r&&(i["source-layer"]=r),i}function B6(e,n,t){var r={id:[n,t,"line"].join("_"),source:n,layout:{"line-join":"round","line-cap":"round"},type:"line",paint:{"line-color":e},filter:["==","$type","LineString"]};return t&&(r["source-layer"]=t),r}function IX(e,n){var t=[],r=[],i=[];function o(s){var a=n.bind(null,s),f={circle:a(.8),line:a(.6),polygon:a(.3),polygonOutline:a(.6),default:a(1)};return f}return Object.keys(e).forEach(function(s){var a=e[s];if(!a||a.length===0){var f=o(s);r.push(E6(f.circle,s)),i.push(B6(f.line,s)),t.push(O6(f.polygon,f.polygonOutline,s))}else a.forEach(function(g){var x=o(g);r.push(E6(x.circle,s,g)),i.push(B6(x.line,s,g)),t.push(O6(x.polygon,x.polygonOutline,s,g))})}),t.concat(i).concat(r)}function TX(e,n,t){t=Object.assign({backgroundColor:"#fff"},t);var r={id:"background",type:"background",paint:{"background-color":t.backgroundColor}},i={};return Object.keys(e.sources).forEach(function(o){var s=e.sources[o];(s.type==="vector"||s.type==="geojson")&&(i[o]=s)}),Object.assign(e,{layers:[r].concat(n),soources:i})}_p.polygonLayer=O6;_p.lineLayer=B6;_p.circleLayer=E6;_p.generateInspectStyle=TX;_p.generateColoredLayers=IX;function KX(e,n){var t=document.createElement("div");return t.className="mapboxgl-ctrl mapboxgl-ctrl-group",t.appendChild(e),n||(t.style.display="none"),t}function PX(){var e=document.createElement("button");return e.className="mapboxgl-ctrl-icon mapboxgl-ctrl-inspect",e.type="button",e["aria-label"]="Inspect",e}function KB(e){e=Object.assign({show:!0,onToggle:function(){}},e),this._btn=PX(),this._btn.onclick=e.onToggle,this.elem=KX(this._btn,e.show)}KB.prototype.setInspectIcon=function(){this._btn.className="mapboxgl-ctrl-icon mapboxgl-ctrl-inspect"};KB.prototype.setMapIcon=function(){this._btn.className="mapboxgl-ctrl-icon mapboxgl-ctrl-map"};var FX=KB,u3={exports:{}};u3.exports;(function(e,n){var t=200,r="__lodash_hash_undefined__",i=1,o=2,s=9007199254740991,a="[object Arguments]",f="[object Array]",g="[object AsyncFunction]",x="[object Boolean]",k="[object Date]",B="[object Error]",P="[object Function]",R="[object GeneratorFunction]",H="[object Map]",W="[object Number]",$="[object Null]",q="[object Object]",oe="[object Promise]",ne="[object Proxy]",ce="[object RegExp]",ae="[object Set]",ue="[object String]",ye="[object Symbol]",Re="[object Undefined]",Ne="[object WeakMap]",rt="[object ArrayBuffer]",ct="[object DataView]",Fe="[object Float32Array]",He="[object Float64Array]",Ce="[object Int8Array]",jt="[object Int16Array]",Ft="[object Int32Array]",Jt="[object Uint8Array]",Nt="[object Uint8ClampedArray]",Ve="[object Uint16Array]",nt="[object Uint32Array]",Je=/[\\^$.*+?()[\]{}|]/g,Vt=/^\[object .+?Constructor\]$/,pt=/^(?:0|[1-9]\d*)$/,dt={};dt[Fe]=dt[He]=dt[Ce]=dt[jt]=dt[Ft]=dt[Jt]=dt[Nt]=dt[Ve]=dt[nt]=!0,dt[a]=dt[f]=dt[rt]=dt[x]=dt[ct]=dt[k]=dt[B]=dt[P]=dt[H]=dt[W]=dt[q]=dt[ce]=dt[ae]=dt[ue]=dt[Ne]=!1;var kt=typeof window=="object"&&window&&window.Object===Object&&window,Dt=typeof self=="object"&&self&&self.Object===Object&&self,Se=kt||Dt||Function("return this")(),de=n&&!n.nodeType&&n,xe=de&&!0&&e&&!e.nodeType&&e,Pe=xe&&xe.exports===de,Ze=Pe&&kt.process,Xe=function(){try{return Ze&&Ze.binding&&Ze.binding("util")}catch{}}(),wt=Xe&&Xe.isTypedArray;function Kt(ee,Ie){for(var st=-1,Xt=ee==null?0:ee.length,Sr=0,_n=[];++st<Xt;){var Si=ee[st];Ie(Si,st,ee)&&(_n[Sr++]=Si)}return _n}function Pt(ee,Ie){for(var st=-1,Xt=Ie.length,Sr=ee.length;++st<Xt;)ee[Sr+st]=Ie[st];return ee}function zn(ee,Ie){for(var st=-1,Xt=ee==null?0:ee.length;++st<Xt;)if(Ie(ee[st],st,ee))return!0;return!1}function mt(ee,Ie){for(var st=-1,Xt=Array(ee);++st<ee;)Xt[st]=Ie(st);return Xt}function pn(ee){return function(Ie){return ee(Ie)}}function ir(ee,Ie){return ee.has(Ie)}function Sn(ee,Ie){return ee==null?void 0:ee[Ie]}function nr(ee){var Ie=-1,st=Array(ee.size);return ee.forEach(function(Xt,Sr){st[++Ie]=[Sr,Xt]}),st}function Mr(ee,Ie){return function(st){return ee(Ie(st))}}function Qr(ee){var Ie=-1,st=Array(ee.size);return ee.forEach(function(Xt){st[++Ie]=Xt}),st}var _r=Array.prototype,vi=Function.prototype,we=Object.prototype,V=Se["__core-js_shared__"],X=vi.toString,me=we.hasOwnProperty,At=function(){var ee=/[^.]+$/.exec(V&&V.keys&&V.keys.IE_PROTO||"");return ee?"Symbol(src)_1."+ee:""}(),bt=we.toString,Et=RegExp("^"+X.call(me).replace(Je,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),sr=Pe?Se.Buffer:void 0,Lt=Se.Symbol,Fn=Se.Uint8Array,on=we.propertyIsEnumerable,m=_r.splice,un=Lt?Lt.toStringTag:void 0,In=Object.getOwnPropertySymbols,Gn=sr?sr.isBuffer:void 0,Zn=Mr(Object.keys,Object),Ke=$a(Se,"DataView"),fe=$a(Se,"Map"),_e=$a(Se,"Promise"),Ee=$a(Se,"Set"),Te=$a(Se,"WeakMap"),at=$a(Object,"create"),it=Ya(Ke),ht=Ya(fe),et=Ya(_e),Ct=Ya(Ee),rn=Ya(Te),Gt=Lt?Lt.prototype:void 0,$t=Gt?Gt.valueOf:void 0;function gn(ee){var Ie=-1,st=ee==null?0:ee.length;for(this.clear();++Ie<st;){var Xt=ee[Ie];this.set(Xt[0],Xt[1])}}function Jn(){this.__data__=at?at(null):{},this.size=0}function qn(ee){var Ie=this.has(ee)&&delete this.__data__[ee];return this.size-=Ie?1:0,Ie}function Tr(ee){var Ie=this.__data__;if(at){var st=Ie[ee];return st===r?void 0:st}return me.call(Ie,ee)?Ie[ee]:void 0}function vr(ee){var Ie=this.__data__;return at?Ie[ee]!==void 0:me.call(Ie,ee)}function Dr(ee,Ie){var st=this.__data__;return this.size+=this.has(ee)?0:1,st[ee]=at&&Ie===void 0?r:Ie,this}gn.prototype.clear=Jn,gn.prototype.delete=qn,gn.prototype.get=Tr,gn.prototype.has=vr,gn.prototype.set=Dr;function Yr(ee){var Ie=-1,st=ee==null?0:ee.length;for(this.clear();++Ie<st;){var Xt=ee[Ie];this.set(Xt[0],Xt[1])}}function Zr(){this.__data__=[],this.size=0}function Cr(ee){var Ie=this.__data__,st=En(Ie,ee);if(st<0)return!1;var Xt=Ie.length-1;return st==Xt?Ie.pop():m.call(Ie,st,1),--this.size,!0}function ui(ee){var Ie=this.__data__,st=En(Ie,ee);return st<0?void 0:Ie[st][1]}function Ii(ee){return En(this.__data__,ee)>-1}function Io(ee,Ie){var st=this.__data__,Xt=En(st,ee);return Xt<0?(++this.size,st.push([ee,Ie])):st[Xt][1]=Ie,this}Yr.prototype.clear=Zr,Yr.prototype.delete=Cr,Yr.prototype.get=ui,Yr.prototype.has=Ii,Yr.prototype.set=Io;function Ci(ee){var Ie=-1,st=ee==null?0:ee.length;for(this.clear();++Ie<st;){var Xt=ee[Ie];this.set(Xt[0],Xt[1])}}function so(){this.size=0,this.__data__={hash:new gn,map:new(fe||Yr),string:new gn}}function Yo(ee){var Ie=va(this,ee).delete(ee);return this.size-=Ie?1:0,Ie}function ba(ee){return va(this,ee).get(ee)}function Ql(ee){return va(this,ee).has(ee)}function Ai(ee,Ie){var st=va(this,ee),Xt=st.size;return st.set(ee,Ie),this.size+=st.size==Xt?0:1,this}Ci.prototype.clear=so,Ci.prototype.delete=Yo,Ci.prototype.get=ba,Ci.prototype.has=Ql,Ci.prototype.set=Ai;function Mi(ee){var Ie=-1,st=ee==null?0:ee.length;for(this.__data__=new Ci;++Ie<st;)this.add(ee[Ie])}function rr(ee){return this.__data__.set(ee,r),this}function lo(ee){return this.__data__.has(ee)}Mi.prototype.add=Mi.prototype.push=rr,Mi.prototype.has=lo;function Gi(ee){var Ie=this.__data__=new Yr(ee);this.size=Ie.size}function la(){this.__data__=new Yr,this.size=0}function ve(ee){var Ie=this.__data__,st=Ie.delete(ee);return this.size=Ie.size,st}function Ge(ee){return this.__data__.get(ee)}function Ht(ee){return this.__data__.has(ee)}function mn(ee,Ie){var st=this.__data__;if(st instanceof Yr){var Xt=st.__data__;if(!fe||Xt.length<t-1)return Xt.push([ee,Ie]),this.size=++st.size,this;st=this.__data__=new Ci(Xt)}return st.set(ee,Ie),this.size=st.size,this}Gi.prototype.clear=la,Gi.prototype.delete=ve,Gi.prototype.get=Ge,Gi.prototype.has=Ht,Gi.prototype.set=mn;function Ot(ee,Ie){var st=Zu(ee),Xt=!st&&bA(ee),Sr=!st&&!Xt&&Us(ee),_n=!st&&!Xt&&!Sr&&Mu(ee),Si=st||Xt||Sr||_n,Ki=Si?mt(ee.length,String):[],qr=Ki.length;for(var Yi in ee)(Ie||me.call(ee,Yi))&&!(Si&&(Yi=="length"||Sr&&(Yi=="offset"||Yi=="parent")||_n&&(Yi=="buffer"||Yi=="byteLength"||Yi=="byteOffset")||CA(Yi,qr)))&&Ki.push(Yi);return Ki}function En(ee,Ie){for(var st=ee.length;st--;)if(vs(ee[st][0],Ie))return st;return-1}function zr(ee,Ie,st){var Xt=Ie(ee);return Zu(ee)?Xt:Pt(Xt,st(ee))}function Lr(ee){return ee==null?ee===void 0?Re:$:un&&un in Object(ee)?ll(ee):_A(ee)}function Ti(ee){return as(ee)&&Lr(ee)==a}function po(ee,Ie,st,Xt,Sr){return ee===Ie?!0:ee==null||Ie==null||!as(ee)&&!as(Ie)?ee!==ee&&Ie!==Ie:Cl(ee,Ie,st,Xt,po,Sr)}function Cl(ee,Ie,st,Xt,Sr,_n){var Si=Zu(ee),Ki=Zu(Ie),qr=Si?f:bl(ee),Yi=Ki?f:bl(Ie);qr=qr==a?q:qr,Yi=Yi==a?q:Yi;var qo=qr==q,Ca=Yi==q,Vo=qr==Yi;if(Vo&&Us(ee)){if(!Us(Ie))return!1;Si=!0,qo=!1}if(Vo&&!qo)return _n||(_n=new Gi),Si||Mu(ee)?Qa(ee,Ie,st,Xt,Sr,_n):ys(ee,Ie,qr,st,Xt,Sr,_n);if(!(st&i)){var Li=qo&&me.call(ee,"__wrapped__"),Xo=Ca&&me.call(Ie,"__wrapped__");if(Li||Xo){var Pa=Li?ee.value():ee,Rs=Xo?Ie.value():Ie;return _n||(_n=new Gi),Sr(Pa,Rs,st,Xt,_n)}}return Vo?(_n||(_n=new Gi),qs(ee,Ie,st,Xt,Sr,_n)):!1}function br(ee){if(!uu(ee)||Hu(ee))return!1;var Ie=lu(ee)?Et:Vt;return Ie.test(Ya(ee))}function _i(ee){return as(ee)&&wu(ee.length)&&!!dt[Lr(ee)]}function _l(ee){if(!ZA(ee))return Zn(ee);var Ie=[];for(var st in Object(ee))me.call(ee,st)&&st!="constructor"&&Ie.push(st);return Ie}function Qa(ee,Ie,st,Xt,Sr,_n){var Si=st&i,Ki=ee.length,qr=Ie.length;if(Ki!=qr&&!(Si&&qr>Ki))return!1;var Yi=_n.get(ee);if(Yi&&_n.get(Ie))return Yi==Ie;var qo=-1,Ca=!0,Vo=st&o?new Mi:void 0;for(_n.set(ee,Ie),_n.set(Ie,ee);++qo<Ki;){var Li=ee[qo],Xo=Ie[qo];if(Xt)var Pa=Si?Xt(Xo,Li,qo,Ie,ee,_n):Xt(Li,Xo,qo,ee,Ie,_n);if(Pa!==void 0){if(Pa)continue;Ca=!1;break}if(Vo){if(!zn(Ie,function(Rs,_s){if(!ir(Vo,_s)&&(Li===Rs||Sr(Li,Rs,st,Xt,_n)))return Vo.push(_s)})){Ca=!1;break}}else if(!(Li===Xo||Sr(Li,Xo,st,Xt,_n))){Ca=!1;break}}return _n.delete(ee),_n.delete(Ie),Ca}function ys(ee,Ie,st,Xt,Sr,_n,Si){switch(st){case ct:if(ee.byteLength!=Ie.byteLength||ee.byteOffset!=Ie.byteOffset)return!1;ee=ee.buffer,Ie=Ie.buffer;case rt:return!(ee.byteLength!=Ie.byteLength||!_n(new Fn(ee),new Fn(Ie)));case x:case k:case W:return vs(+ee,+Ie);case B:return ee.name==Ie.name&&ee.message==Ie.message;case ce:case ue:return ee==Ie+"";case H:var Ki=nr;case ae:var qr=Xt&i;if(Ki||(Ki=Qr),ee.size!=Ie.size&&!qr)return!1;var Yi=Si.get(ee);if(Yi)return Yi==Ie;Xt|=o,Si.set(ee,Ie);var qo=Qa(Ki(ee),Ki(Ie),Xt,Sr,_n,Si);return Si.delete(ee),qo;case ye:if($t)return $t.call(ee)==$t.call(Ie)}return!1}function qs(ee,Ie,st,Xt,Sr,_n){var Si=st&i,Ki=Vs(ee),qr=Ki.length,Yi=Vs(Ie),qo=Yi.length;if(qr!=qo&&!Si)return!1;for(var Ca=qr;Ca--;){var Vo=Ki[Ca];if(!(Si?Vo in Ie:me.call(Ie,Vo)))return!1}var Li=_n.get(ee);if(Li&&_n.get(Ie))return Li==Ie;var Xo=!0;_n.set(ee,Ie),_n.set(Ie,ee);for(var Pa=Si;++Ca<qr;){Vo=Ki[Ca];var Rs=ee[Vo],_s=Ie[Vo];if(Xt)var Su=Si?Xt(_s,Rs,Vo,Ie,ee,_n):Xt(Rs,_s,Vo,ee,Ie,_n);if(!(Su===void 0?Rs===_s||Sr(Rs,_s,st,Xt,_n):Su)){Xo=!1;break}Pa||(Pa=Vo=="constructor")}if(Xo&&!Pa){var XA=ee.constructor,ss=Ie.constructor;XA!=ss&&"constructor"in ee&&"constructor"in Ie&&!(typeof XA=="function"&&XA instanceof XA&&typeof ss=="function"&&ss instanceof ss)&&(Xo=!1)}return _n.delete(ee),_n.delete(Ie),Xo}function Vs(ee){return zr(ee,Au,xu)}function va(ee,Ie){var st=ee.__data__;return HA(Ie)?st[typeof Ie=="string"?"string":"hash"]:st.map}function $a(ee,Ie){var st=Sn(ee,Ie);return br(st)?st:void 0}function ll(ee){var Ie=me.call(ee,un),st=ee[un];try{ee[un]=void 0;var Xt=!0}catch{}var Sr=bt.call(ee);return Xt&&(Ie?ee[un]=st:delete ee[un]),Sr}var xu=In?function(ee){return ee==null?[]:(ee=Object(ee),Kt(In(ee),function(Ie){return on.call(ee,Ie)}))}:bo,bl=Lr;(Ke&&bl(new Ke(new ArrayBuffer(1)))!=ct||fe&&bl(new fe)!=H||_e&&bl(_e.resolve())!=oe||Ee&&bl(new Ee)!=ae||Te&&bl(new Te)!=Ne)&&(bl=function(ee){var Ie=Lr(ee),st=Ie==q?ee.constructor:void 0,Xt=st?Ya(st):"";if(Xt)switch(Xt){case it:return ct;case ht:return H;case et:return oe;case Ct:return ae;case rn:return Ne}return Ie});function CA(ee,Ie){return Ie=Ie??s,!!Ie&&(typeof ee=="number"||pt.test(ee))&&ee>-1&&ee%1==0&&ee<Ie}function HA(ee){var Ie=typeof ee;return Ie=="string"||Ie=="number"||Ie=="symbol"||Ie=="boolean"?ee!=="__proto__":ee===null}function Hu(ee){return!!At&&At in ee}function ZA(ee){var Ie=ee&&ee.constructor,st=typeof Ie=="function"&&Ie.prototype||we;return ee===st}function _A(ee){return bt.call(ee)}function Ya(ee){if(ee!=null){try{return X.call(ee)}catch{}try{return ee+""}catch{}}return""}function vs(ee,Ie){return ee===Ie||ee!==ee&&Ie!==Ie}var bA=Ti(function(){return arguments}())?Ti:function(ee){return as(ee)&&me.call(ee,"callee")&&!on.call(ee,"callee")},Zu=Array.isArray;function Ds(ee){return ee!=null&&wu(ee.length)&&!lu(ee)}var Us=Gn||mo;function Cs(ee,Ie){return po(ee,Ie)}function lu(ee){if(!uu(ee))return!1;var Ie=Lr(ee);return Ie==P||Ie==R||Ie==g||Ie==ne}function wu(ee){return typeof ee=="number"&&ee>-1&&ee%1==0&&ee<=s}function uu(ee){var Ie=typeof ee;return ee!=null&&(Ie=="object"||Ie=="function")}function as(ee){return ee!=null&&typeof ee=="object"}var Mu=wt?pn(wt):_i;function Au(ee){return Ds(ee)?Ot(ee):_l(ee)}function bo(){return[]}function mo(){return!1}e.exports=Cs})(u3,u3.exports);var NR=u3.exports;const k6=ga(NR);function DX(e){return typeof e>"u"||e===null?e:e instanceof Date?e.toLocaleString():typeof e=="object"||typeof e=="number"||typeof e=="string"?e.toString():e}function VI(e,n){return'<div class="mapbox-gl-inspect_property"><div class="mapbox-gl-inspect_property-name">'+e+'</div><div class="mapbox-gl-inspect_property-value">'+DX(n)+"</div></div>"}function UX(e){return'<div class="mapbox-gl-inspect_layer">'+e+"</div>"}function RX(e){var n=UX(e.layer["source-layer"]||e.layer.source),t=VI("$type",e.geometry.type),r=Object.keys(e.properties).map(function(i){return VI(i,e.properties[i])});return[n,t].concat(r).join("")}function LX(e){return e.map(function(n){return'<div class="mapbox-gl-inspect_feature">'+RX(n)+"</div>"}).join("")}function zX(e){return'<div class="mapbox-gl-inspect_popup">'+LX(e)+"</div>"}var jX=zX,t5={},I6={exports:{}};(function(e,n){(function(t,r){{var i=r();e&&e.exports&&(n=e.exports=i),n.randomColor=i}})(mf,function(){var t=null,r={};W();var i=function(ne){if(ne=ne||{},ne.seed&&ne.seed===parseInt(ne.seed,10))t=ne.seed;else if(typeof ne.seed=="string")t=oe(ne.seed);else{if(ne.seed!==void 0&&ne.seed!==null)throw new TypeError("The seed value must be an integer or string");t=null}var ce,ae,ue;if(ne.count!==null&&ne.count!==void 0){var ye=ne.count,Re=[];for(ne.count=null;ye>Re.length;)t&&ne.seed&&(ne.seed+=1),Re.push(i(ne));return ne.count=ye,Re}return ce=o(ne),ae=s(ce,ne),ue=a(ce,ae,ne),f([ce,ae,ue],ne)};function o(ne){var ce=x(ne.hue),ae=P(ce);return ae<0&&(ae=360+ae),ae}function s(ne,ce){if(ce.luminosity==="random")return P([0,100]);if(ce.hue==="monochrome")return 0;var ae=k(ne),ue=ae[0],ye=ae[1];switch(ce.luminosity){case"bright":ue=55;break;case"dark":ue=ye-10;break;case"light":ye=55;break}return P([ue,ye])}function a(ne,ce,ae){var ue=g(ne,ce),ye=100;switch(ae.luminosity){case"dark":ye=ue+20;break;case"light":ue=(ye+ue)/2;break;case"random":ue=0,ye=100;break}return P([ue,ye])}function f(ne,ce){switch(ce.format){case"hsvArray":return ne;case"hslArray":return q(ne);case"hsl":var ae=q(ne);return"hsl("+ae[0]+", "+ae[1]+"%, "+ae[2]+"%)";case"hsla":var ue=q(ne);return"hsla("+ue[0]+", "+ue[1]+"%, "+ue[2]+"%, "+Math.random()+")";case"rgbArray":return $(ne);case"rgb":var ye=$(ne);return"rgb("+ye.join(", ")+")";case"rgba":var Re=$(ne);return"rgba("+Re.join(", ")+", "+Math.random()+")";default:return R(ne)}}function g(ne,ce){for(var ae=B(ne).lowerBounds,ue=0;ue<ae.length-1;ue++){var ye=ae[ue][0],Re=ae[ue][1],Ne=ae[ue+1][0],rt=ae[ue+1][1];if(ce>=ye&&ce<=Ne){var ct=(rt-Re)/(Ne-ye),Fe=Re-ct*ye;return ct*ce+Fe}}return 0}function x(ne){if(typeof parseInt(ne)=="number"){var ce=parseInt(ne);if(ce<360&&ce>0)return[ce,ce]}if(typeof ne=="string"&&r[ne]){var ae=r[ne];if(ae.hueRange)return ae.hueRange}return[0,360]}function k(ne){return B(ne).saturationRange}function B(ne){ne>=334&&ne<=360&&(ne-=360);for(var ce in r){var ae=r[ce];if(ae.hueRange&&ne>=ae.hueRange[0]&&ne<=ae.hueRange[1])return r[ce]}return"Color not found"}function P(ne){if(t===null)return Math.floor(ne[0]+Math.random()*(ne[1]+1-ne[0]));var ce=ne[1]||1,ae=ne[0]||0;t=(t*9301+49297)%233280;var ue=t/233280;return Math.floor(ae+ue*(ce-ae))}function R(ne){var ce=$(ne);function ae(ye){var Re=ye.toString(16);return Re.length==1?"0"+Re:Re}var ue="#"+ae(ce[0])+ae(ce[1])+ae(ce[2]);return ue}function H(ne,ce,ae){var ue=ae[0][0],ye=ae[ae.length-1][0],Re=ae[ae.length-1][1],Ne=ae[0][1];r[ne]={hueRange:ce,lowerBounds:ae,saturationRange:[ue,ye],brightnessRange:[Re,Ne]}}function W(){H("monochrome",null,[[0,0],[100,0]]),H("red",[-26,18],[[20,100],[30,92],[40,89],[50,85],[60,78],[70,70],[80,60],[90,55],[100,50]]),H("orange",[19,46],[[20,100],[30,93],[40,88],[50,86],[60,85],[70,70],[100,70]]),H("yellow",[47,62],[[25,100],[40,94],[50,89],[60,86],[70,84],[80,82],[90,80],[100,75]]),H("green",[63,178],[[30,100],[40,90],[50,85],[60,81],[70,74],[80,64],[90,50],[100,40]]),H("blue",[179,257],[[20,100],[30,86],[40,80],[50,74],[60,60],[70,52],[80,44],[90,39],[100,35]]),H("purple",[258,282],[[20,100],[30,87],[40,79],[50,70],[60,65],[70,59],[80,52],[90,45],[100,42]]),H("pink",[283,334],[[20,100],[30,90],[40,86],[60,84],[80,80],[90,75],[100,73]])}function $(ne){var ce=ne[0];ce===0&&(ce=1),ce===360&&(ce=359),ce=ce/360;var ae=ne[1]/100,ue=ne[2]/100,ye=Math.floor(ce*6),Re=ce*6-ye,Ne=ue*(1-ae),rt=ue*(1-Re*ae),ct=ue*(1-(1-Re)*ae),Fe=256,He=256,Ce=256;switch(ye){case 0:Fe=ue,He=ct,Ce=Ne;break;case 1:Fe=rt,He=ue,Ce=Ne;break;case 2:Fe=Ne,He=ue,Ce=ct;break;case 3:Fe=Ne,He=rt,Ce=ue;break;case 4:Fe=ct,He=Ne,Ce=ue;break;case 5:Fe=ue,He=Ne,Ce=rt;break}var jt=[Math.floor(Fe*255),Math.floor(He*255),Math.floor(Ce*255)];return jt}function q(ne){var ce=ne[0],ae=ne[1]/100,ue=ne[2]/100,ye=(2-ae)*ue;return[ce,Math.round(ae*ue/(ye<1?ye:2-ye)*1e4)/100,ye/2*100]}function oe(ne){for(var ce=0,ae=0;ae!==ne.length&&!(ce>=Number.MAX_SAFE_INTEGER);ae++)ce+=ne.charCodeAt(ae);return ce}return i})})(I6,I6.exports);var WX=I6.exports,NX=WX;function GX(e,n){var t="bright",r=null;/water|ocean|lake|sea|river/.test(e)&&(r="blue"),/state|country|place/.test(e)&&(r="pink"),/road|highway|transport/.test(e)&&(r="orange"),/contour|building/.test(e)&&(r="monochrome"),/building/.test(e)&&(t="dark"),/contour|landuse/.test(e)&&(r="yellow"),/wood|forest|park|landcover/.test(e)&&(r="green");var i=NX({luminosity:t,hue:r,seed:e,format:"rgbArray"}),o=i.concat([n||1]);return"rgba("+o.join(", ")+")"}t5.brightColor=GX;var GR=_p,QX=FX,$X=NR,YX=jX,qX=t5;function VX(e){return e.metadata&&e.metadata["mapbox-gl-inspect:inspect"]}function HX(e){return Object.assign(e,{metadata:Object.assign({},e.metadata,{"mapbox-gl-inspect:inspect":!0})})}function ZX(e){return(e.type==="raster"||e.type==="raster-dem")&&e.tileSize&&e.tiles?{type:e.type,tileSize:e.tileSize,tiles:e.tiles}:(e.type==="raster"||e.type==="raster-dem")&&e.url?{type:e.type,url:e.url}:e}function HI(e){return Object.keys(e.sources).forEach(function(n){e.sources[n]=ZX(e.sources[n])}),e}function XX(e){var n=e.version.split(".").map(parseFloat);n[0]<1&&n[1]<29&&console.error("MapboxInspect only supports Mapbox GL JS >= v0.29.0. Please upgrade your Mapbox GL JS version.")}function Cf(e){if(!(this instanceof Cf))throw new Error("MapboxInspect needs to be called with the new keyword");var n=null;window.mapboxgl?(XX(window.mapboxgl),n=new window.mapboxgl.Popup({closeButton:!1,closeOnClick:!1})):e.popup||console.error("Mapbox GL JS can not be found. Make sure to include it or pass an initialized MapboxGL Popup to MapboxInspect if you are using moduleis."),this.options=Object.assign({showInspectMap:!1,showInspectButton:!0,showInspectMapPopup:!0,showMapPopup:!1,showMapPopupOnHover:!0,showInspectMapPopupOnHover:!0,blockHoverPopupOnClick:!1,backgroundColor:"#fff",assignLayerColor:qX.brightColor,buildInspectStyle:GR.generateInspectStyle,renderPopup:YX,popup:n,selectThreshold:5,useInspectStyle:!0,queryParameters:{},sources:{}},e),this.sources=this.options.sources,this.assignLayerColor=this.options.assignLayerColor,this.toggleInspector=this.toggleInspector.bind(this),this._popup=this.options.popup,this._popupBlocked=!1,this._showInspectMap=this.options.showInspectMap,this._onSourceChange=this._onSourceChange.bind(this),this._onMousemove=this._onMousemove.bind(this),this._onStyleChange=this._onStyleChange.bind(this),this._originalStyle=null,this._toggle=new QX({show:this.options.showInspectButton,onToggle:this.toggleInspector.bind(this)})}Cf.prototype.toggleInspector=function(){this._showInspectMap=!this._showInspectMap,this.render()};Cf.prototype._inspectStyle=function(){var e=GR.generateColoredLayers(this.sources,this.assignLayerColor);return this.options.buildInspectStyle(this._map.getStyle(),e,{backgroundColor:this.options.backgroundColor})};Cf.prototype.render=function(){this._showInspectMap?(this.options.useInspectStyle&&this._map.setStyle(HI(HX(this._inspectStyle()))),this._toggle.setMapIcon()):this._originalStyle&&(this._popup&&this._popup.remove(),this.options.useInspectStyle&&this._map.setStyle(HI(this._originalStyle)),this._toggle.setInspectIcon())};Cf.prototype._onSourceChange=function(){var e=this.sources,n=this._map,t=n.getStyle(),r=Object.keys(t.sources),i=Object.assign({},e);Object.keys(n.style.sourceCaches).forEach(function(o){var s=n.style.sourceCaches[o]||{_source:{}},a=s._source.vectorLayerIds;a?e[o]=a:s._source.type==="geojson"&&(e[o]=[])}),Object.keys(e).forEach(function(o){r.indexOf(o)===-1&&delete e[o]}),!$X(i,e)&&Object.keys(e).length>0&&this.render()};Cf.prototype._onStyleChange=function(){var e=this._map.getStyle();VX(e)||(this._originalStyle=e)};Cf.prototype._onMousemove=function(e){var n;this.options.selectThreshold===0?n=e.point:n=[[e.point.x-this.options.selectThreshold,e.point.y+this.options.selectThreshold],[e.point.x+this.options.selectThreshold,e.point.y-this.options.selectThreshold]];var t=this._map.queryRenderedFeatures(n,this.options.queryParameters)||[];if(this._map.getCanvas().style.cursor=t.length?"pointer":"",this._showInspectMap){if(!this.options.showInspectMapPopup||e.type==="mousemove"&&!this.options.showInspectMapPopupOnHover)return;e.type==="click"&&this.options.showInspectMapPopupOnHover&&this.options.blockHoverPopupOnClick&&(this._popupBlocked=!this._popupBlocked)}else{if(!this.options.showMapPopup||e.type==="mousemove"&&!this.options.showMapPopupOnHover)return;e.type==="click"&&this.options.showMapPopupOnHover&&this.options.blockHoverPopupOnClick&&(this._popupBlocked=!this._popupBlocked)}if(!this._popupBlocked&&this._popup)if(!t.length)this._popup.remove();else{this._popup.setLngLat(e.lngLat);var r=typeof this.options.renderPopup(t);r==="string"?this._popup.setHTML(this.options.renderPopup(t)):this._popup.setDOMContent(this.options.renderPopup(t)),this._popup.addTo(this._map)}};Cf.prototype.onAdd=function(e){return this._map=e,Object.keys(this.sources).length===0&&(e.on("tiledata",this._onSourceChange),e.on("sourcedata",this._onSourceChange)),e.on("styledata",this._onStyleChange),e.on("load",this._onStyleChange),e.on("mousemove",this._onMousemove),e.on("click",this._onMousemove),this._toggle.elem};Cf.prototype.onRemove=function(){this._map.off("styledata",this._onStyleChange),this._map.off("load",this._onStyleChange),this._map.off("tiledata",this._onSourceChange),this._map.off("sourcedata",this._onSourceChange),this._map.off("mousemove",this._onMousemove),this._map.off("click",this._onMousemove);var e=this._toggle.elem;e.parentNode.removeChild(e),this._map=void 0};var JX=Cf,eJ=JX,tJ=eJ;const nJ=ga(tJ);var QR={exports:{}},rJ="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",iJ=rJ,oJ=iJ;function $R(){}function YR(){}YR.resetWarningCache=$R;var aJ=function(){function e(r,i,o,s,a,f){if(f!==oJ){var g=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw g.name="Invariant Violation",g}}e.isRequired=e;function n(){return e}var t={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:n,element:e,elementType:e,instanceOf:n,node:e,objectOf:n,oneOf:n,oneOfType:n,shape:n,exact:n,checkPropTypes:YR,resetWarningCache:$R};return t.PropTypes=t,t};QR.exports=aJ();var ph=QR.exports;const Pr=ga(ph);var ZI=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e};function sJ(e,n){var t={};for(var r in e)n.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}var Pm=function(n,t){var r=n.children,i=n.color,o=n.size,s=n.style,a=n.width,f=n.height,g=sJ(n,["children","color","size","style","width","height"]),x=t.reactIconBase,k=x===void 0?{}:x,B=o||k.size||"1em";return bn.createElement("svg",ZI({children:r,fill:"currentColor",preserveAspectRatio:"xMidYMid meet",height:f||B,width:a||B},k,g,{style:ZI({verticalAlign:"middle",color:i||k.color},k.style||{},s)}))};Pm.propTypes={color:Pr.string,size:Pr.oneOfType([Pr.string,Pr.number]),width:Pr.oneOfType([Pr.string,Pr.number]),height:Pr.oneOfType([Pr.string,Pr.number]),style:Pr.object};Pm.contextTypes={reactIconBase:Pr.shape(Pm.propTypes)};function A3(){var e="/home/runner/work/maputnik/maputnik/src/components/IconLine.tsx",n="ace6118dd0ae83e2ceb20b70664ae2267741d924",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconLine.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:478}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconLine.tsx"],names:[],mappings:"AAQQ;AARR,OAAO,WAAW;AAClB,OAAO,cAAc;AAGrB,qBAAqB,iBAAiB,MAAM,UAAU;AAAA,EACpD,SAAS;AACP,WACE,oBAAC,YAAS,SAAQ,aAAa,GAAG,KAAK,OACrC,8BAAC,UAAK,GAAE,iUAAgU,WAAU,kBAAiB,GACrW;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"ace6118dd0ae83e2ceb20b70664ae2267741d924"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return A3=function(){return s},s}A3();class lJ extends bn.Component{render(){return A3().f[0]++,A3().s[0]++,N.jsx(Pm,{viewBox:"0 0 20 20",...this.props,children:N.jsx("path",{d:"M 12.34,1.29 C 12.5114,1.1076 12.7497,1.0029 13,1 13.5523,1 14,1.4477 14,2 14.0047,2.2478 13.907,2.4866 13.73,2.66 9.785626,6.5516986 6.6148407,9.7551593 2.65,13.72 2.4793,13.8963 2.2453,13.9971 2,14 1.4477,14 1,13.5523 1,13 0.9953,12.7522 1.093,12.5134 1.27,12.34 4.9761967,8.7018093 9.0356422,4.5930579 12.34,1.29 Z",transform:"translate(2,2)"})})}}function c3(){var e="/home/runner/work/maputnik/maputnik/src/components/IconFill.tsx",n="8b9fc49e8fc93b42e35f3a9b2accdbccf6dcdb84",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconFill.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:562}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconFill.tsx"],names:[],mappings:"AAQQ;AARR,OAAO,WAAW;AAClB,OAAO,cAAc;AAGrB,qBAAqB,iBAAiB,MAAM,UAAU;AAAA,EACpD,SAAS;AACP,WACE,oBAAC,YAAS,SAAQ,aAAa,GAAG,KAAK,OACrC,8BAAC,UAAK,GAAE,kbAAib,GAC3b;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"8b9fc49e8fc93b42e35f3a9b2accdbccf6dcdb84"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return c3=function(){return s},s}c3();class mx extends bn.Component{render(){return c3().f[0]++,c3().s[0]++,N.jsx(Pm,{viewBox:"0 0 20 20",...this.props,children:N.jsx("path",{d:"M 2.84978,9.763512 9.462149,4.7316391 16.47225,9.478015 9.859886,14.509879 2.84978,9.763512 m -1.028761,0.492069 7.414535,5.020197 c 0.372277,0.25206 0.958697,0.239771 1.30985,-0.02745 L 17.539255,9.926162 C 17.89041,9.658941 17.873288,9.238006 17.501015,8.985946 L 10.08648,3.9657402 C 9.714204,3.7136802 9.127782,3.7259703 8.776627,3.9931918 L 1.782775,9.315365 c -0.3511551,0.267221 -0.3340331,0.688156 0.03824,0.940216 l 0,0 z"})})}}function d3(){var e="/home/runner/work/maputnik/maputnik/src/components/IconSymbol.tsx",n="6ac2e596376f8b8c2e117c4345e33d1afb8f583b",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconSymbol.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:535}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconSymbol.tsx"],names:[],mappings:"AASU;AATV,OAAO,WAAW;AAClB,OAAO,cAAc;AAGrB,qBAAqB,mBAAmB,MAAM,UAAU;AAAA,EACtD,SAAS;AACP,WACE,oBAAC,YAAS,SAAQ,aAAa,GAAG,KAAK,OACrC,8BAAC,OAAE,WAAU,wDACX,8BAAC,UAAK,GAAE,4SAA2S,GACrT,GACF;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6ac2e596376f8b8c2e117c4345e33d1afb8f583b"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return d3=function(){return s},s}d3();class uJ extends bn.Component{render(){return d3().f[0]++,d3().s[0]++,N.jsx(Pm,{viewBox:"0 0 20 20",...this.props,children:N.jsx("g",{transform:"matrix(1.2718518,0,0,1.2601269,16.559526,-7.4065264)",children:N.jsx("path",{d:"m -9.7959773,11.060163 c -0.3734787,-0.724437 -0.3580577,-1.2147051 -0.00547,-1.8767873 l 8.6034029,-0.019416 c 0.39670292,0.6865644 0.38365934,1.4750693 -0.011097,1.8864953 l -3.1359613,-0.0033 -0.013695,7.1305 c -0.4055357,0.397083 -1.3146432,0.397083 -1.7769191,-0.02274 l 0.030226,-7.104422 z"})})})}}function h3(){var e="/home/runner/work/maputnik/maputnik/src/components/IconBackground.tsx",n="f8813cd7d4a9138ff3fc7253bc195b86370ed6cf",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconBackground.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:464}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconBackground.tsx"],names:[],mappings:"AAQQ;AARR,OAAO,WAAW;AAClB,OAAO,cAAc;AAGrB,qBAAqB,uBAAuB,MAAM,UAAU;AAAA,EAC1D,SAAS;AACP,WACE,oBAAC,YAAS,SAAQ,aAAa,GAAG,KAAK,OACrC,8BAAC,UAAK,GAAE,gVAA+U,GACzV;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"f8813cd7d4a9138ff3fc7253bc195b86370ed6cf"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return h3=function(){return s},s}h3();class XI extends bn.Component{render(){return h3().f[0]++,h3().s[0]++,N.jsx(Pm,{viewBox:"0 0 20 20",...this.props,children:N.jsx("path",{d:"m 1.821019,10.255581 7.414535,5.020197 c 0.372277,0.25206 0.958697,0.239771 1.30985,-0.02745 L 17.539255,9.926162 C 17.89041,9.658941 17.873288,9.238006 17.501015,8.985946 L 10.08648,3.9657402 C 9.714204,3.7136802 9.127782,3.7259703 8.776627,3.9931918 L 1.782775,9.315365 c -0.3511551,0.267221 -0.3340331,0.688156 0.03824,0.940216 z"})})}}function f3(){var e="/home/runner/work/maputnik/maputnik/src/components/IconCircle.tsx",n="35a8c3687dcdeffeb7f2fe2d9c05ced9e802b5ca",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconCircle.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:378}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconCircle.tsx"],names:[],mappings:"AAQQ;AARR,OAAO,WAAW;AAClB,OAAO,cAAc;AAGrB,qBAAqB,mBAAmB,MAAM,UAAU;AAAA,EACtD,SAAS;AACP,WACE,oBAAC,YAAS,SAAQ,aAAa,GAAG,KAAK,OACrC,8BAAC,UAAK,WAAU,kBAAiB,GAAE,6NAA4N,GACjQ;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"35a8c3687dcdeffeb7f2fe2d9c05ced9e802b5ca"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return f3=function(){return s},s}f3();class AJ extends bn.Component{render(){return f3().f[0]++,f3().s[0]++,N.jsx(Pm,{viewBox:"0 0 20 20",...this.props,children:N.jsx("path",{transform:"translate(2 2)",d:"M7.5,0C11.6422,0,15,3.3578,15,7.5S11.6422,15,7.5,15 S0,11.6422,0,7.5S3.3578,0,7.5,0z M7.5,1.6666c-3.2217,0-5.8333,2.6117-5.8333,5.8334S4.2783,13.3334,7.5,13.3334 s5.8333-2.6117,5.8333-5.8334S10.7217,1.6666,7.5,1.6666z"})})}}function Ly(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"}}]})(e)}function cJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M20 19.59V8l-6-6H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c.45 0 .85-.15 1.19-.4l-4.43-4.43c-.8.52-1.74.83-2.76.83-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5c0 1.02-.31 1.96-.83 2.75L20 19.59zM9 13c0 1.66 1.34 3 3 3s3-1.34 3-3-1.34-3-3-3-3 1.34-3 3z"}}]})(e)}function dJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4z"}}]})(e)}function hJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M14.59 8L12 10.59 9.41 8 8 9.41 10.59 12 8 14.59 9.41 16 12 13.41 14.59 16 16 14.59 13.41 12 16 9.41 14.59 8zM12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"}}]})(e)}function fJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"}},{tag:"path",attr:{d:"M11 7h2v2h-2V7zm0 4h2v6h-2v-6zm1-9C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"}}]})(e)}function pJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M19 4H5a2 2 0 00-2 2v12a2 2 0 002 2h4v-2H5V8h14v10h-4v2h4c1.1 0 2-.9 2-2V6a2 2 0 00-2-2zm-7 6l-4 4h3v6h2v-6h3l-4-4z"}}]})(e)}function mJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0V0z"}},{tag:"path",attr:{d:"M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58a.49.49 0 00.12-.61l-1.92-3.32a.488.488 0 00-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54a.484.484 0 00-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96c-.22-.08-.47 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58a.49.49 0 00-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61l-2.01-1.58zM12 15.6c-1.98 0-3.6-1.62-3.6-3.6s1.62-3.6 3.6-3.6 3.6 1.62 3.6 3.6-1.62 3.6-3.6 3.6z"}}]})(e)}function gJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0zm0 0h24v24H0zm0 0h24v24H0zm0 0h24v24H0z"}},{tag:"path",attr:{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46A11.804 11.804 0 001 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"}}]})(e)}function yJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"}}]})(e)}function qR(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"}}]})(e)}function vJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"}}]})(e)}function CJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"}}]})(e)}function _J(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M18 4H6v2l6.5 6L6 18v2h12v-3h-7l5-5-5-5h7z"}}]})(e)}function bJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"}}]})(e)}function T6(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"}}]})(e)}function xJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M9 16h6v-6h4l-7-7-7 7h4zm-4 2h14v2H5z"}}]})(e)}function wJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M11.99 18.54l-7.37-5.73L3 14.07l9 7 9-7-1.63-1.27-7.38 5.74zM12 16l7.36-5.73L21 9l-9-7-9 7 1.63 1.27L12 16z"}}]})(e)}function MJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M7 10l5 5 5-5z"}}]})(e)}function SJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M7 14l5-5 5 5z"}}]})(e)}function EJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}}]})(e)}function OJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"path",attr:{d:"M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}}]})(e)}function BJ(e){return Ys({tag:"svg",attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{fill:"none",d:"M0 0h24v24H0z"}},{tag:"circle",attr:{cx:"12",cy:"19",r:"2"}},{tag:"path",attr:{d:"M10 3h4v12h-4z"}}]})(e)}function p3(){var e="/home/runner/work/maputnik/maputnik/src/components/IconMissing.tsx",n="90c8ed80956547e1dbbdff164a42850c33eed62e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconMissing.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:66}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconMissing.tsx"],names:[],mappings:"AAOM;AAPN,OAAO,WAAW;AAClB,SAAQ,sBAAqB;AAG7B,qBAAqB,oBAAoB,MAAM,UAAU;AAAA,EACvD,SAAS;AACP,WACE,oBAAC,kBAAgB,GAAG,KAAK,OAAO;AAAA,EAEpC;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"90c8ed80956547e1dbbdff164a42850c33eed62e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return p3=function(){return s},s}p3();class kJ extends bn.Component{render(){return p3().f[0]++,p3().s[0]++,N.jsx(BJ,{...this.props})}}function es(){var e="/home/runner/work/maputnik/maputnik/src/components/IconLayer.tsx",n="89bd7eb08374d10a1476c7cf1e0e39f530ce1ff1",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/IconLayer.tsx",statementMap:{0:{start:{line:11,column:22},end:{line:11,column:49}},1:{start:{line:12,column:4},end:{line:33,column:5}},2:{start:{line:14,column:8},end:{line:14,column:69}},3:{start:{line:16,column:8},end:{line:16,column:63}},4:{start:{line:18,column:8},end:{line:18,column:63}},5:{start:{line:20,column:8},end:{line:20,column:63}},6:{start:{line:22,column:8},end:{line:22,column:63}},7:{start:{line:24,column:8},end:{line:24,column:69}},8:{start:{line:26,column:8},end:{line:26,column:63}},9:{start:{line:28,column:8},end:{line:28,column:65}},10:{start:{line:30,column:8},end:{line:30,column:65}},11:{start:{line:32,column:8},end:{line:32,column:66}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:10,column:2},end:{line:10,column:3}},loc:{start:{line:10,column:11},end:{line:34,column:3}},line:10}},branchMap:{0:{loc:{start:{line:12,column:4},end:{line:33,column:5}},type:"switch",locations:[{start:{line:13,column:6},end:{line:14,column:69}},{start:{line:15,column:6},end:{line:16,column:63}},{start:{line:17,column:6},end:{line:18,column:63}},{start:{line:19,column:6},end:{line:20,column:63}},{start:{line:21,column:6},end:{line:22,column:63}},{start:{line:23,column:6},end:{line:24,column:69}},{start:{line:25,column:6},end:{line:26,column:63}},{start:{line:27,column:6},end:{line:28,column:65}},{start:{line:29,column:6},end:{line:30,column:65}},{start:{line:31,column:6},end:{line:32,column:66}}],line:12}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0},f:{0:0},b:{0:[0,0,0,0,0,0,0,0,0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/IconLayer.tsx"],names:[],mappings:"AAmBkC;AAnBlC,OAAO,WAAW;AAElB,OAAO,cAAc;AACrB,OAAO,cAAc;AACrB,OAAO,gBAAgB;AACvB,OAAO,oBAAoB;AAC3B,OAAO,gBAAgB;AACvB,OAAO,iBAAiB;AAQxB,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,UAAM,YAAY,EAAE,OAAO,KAAK,MAAM,MAAM;AAC5C,YAAO,KAAK,MAAM,MAAM;AAAA,MACxB,KAAK;AAAkB,eAAO,oBAAC,kBAAgB,GAAG,WAAW;AAAA,MAC7D,KAAK;AAAU,eAAO,oBAAC,YAAU,GAAG,WAAW;AAAA,MAC/C,KAAK;AAAa,eAAO,oBAAC,YAAU,GAAG,WAAW;AAAA,MAClD,KAAK;AAAW,eAAO,oBAAC,YAAU,GAAG,WAAW;AAAA,MAChD,KAAK;AAAQ,eAAO,oBAAC,YAAU,GAAG,WAAW;AAAA,MAC7C,KAAK;AAAc,eAAO,oBAAC,kBAAgB,GAAG,WAAW;AAAA,MACzD,KAAK;AAAQ,eAAO,oBAAC,YAAU,GAAG,WAAW;AAAA,MAC7C,KAAK;AAAU,eAAO,oBAAC,cAAY,GAAG,WAAW;AAAA,MACjD,KAAK;AAAU,eAAO,oBAAC,cAAY,GAAG,WAAW;AAAA,MACjD;AAAS,eAAO,oBAAC,eAAa,GAAG,WAAW;AAAA,IAC5C;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"89bd7eb08374d10a1476c7cf1e0e39f530ce1ff1"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return es=function(){return s},s}es();class VR extends bn.Component{render(){es().f[0]++;const n=(es().s[0]++,{style:this.props.style});switch(es().s[1]++,this.props.type){case"fill-extrusion":return es().b[0][0]++,es().s[2]++,N.jsx(XI,{...n});case"raster":return es().b[0][1]++,es().s[3]++,N.jsx(mx,{...n});case"hillshade":return es().b[0][2]++,es().s[4]++,N.jsx(mx,{...n});case"heatmap":return es().b[0][3]++,es().s[5]++,N.jsx(mx,{...n});case"fill":return es().b[0][4]++,es().s[6]++,N.jsx(mx,{...n});case"background":return es().b[0][5]++,es().s[7]++,N.jsx(XI,{...n});case"line":return es().b[0][6]++,es().s[8]++,N.jsx(lJ,{...n});case"symbol":return es().b[0][7]++,es().s[9]++,N.jsx(uJ,{...n});case"circle":return es().b[0][8]++,es().s[10]++,N.jsx(AJ,{...n});default:return es().b[0][9]++,es().s[11]++,N.jsx(kJ,{...n})}}}function hr(){var e="/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlLayerPopup.tsx",n="8ac820d45b409d4d358e8cb1f505fcc4025456db",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlLayerPopup.tsx",statementMap:{0:{start:{line:5,column:18},end:{line:5,column:20}},1:{start:{line:6,column:27},end:{line:6,column:29}},2:{start:{line:7,column:2},end:{line:17,column:5}},3:{start:{line:8,column:4},end:{line:16,column:5}},4:{start:{line:9,column:6},end:{line:9,column:43}},5:{start:{line:10,column:28},end:{line:10,column:111}},6:{start:{line:10,column:79},end:{line:10,column:110}},7:{start:{line:11,column:6},end:{line:11,column:65}},8:{start:{line:13,column:6},end:{line:13,column:92}},9:{start:{line:14,column:6},end:{line:14,column:59}},10:{start:{line:15,column:6},end:{line:15,column:45}},11:{start:{line:18,column:2},end:{line:18,column:17}},12:{start:{line:22,column:4},end:{line:24,column:5}},13:{start:{line:23,column:6},end:{line:23,column:13}},14:{start:{line:25,column:4},end:{line:46,column:5}},15:{start:{line:26,column:25},end:{line:26,column:44}},16:{start:{line:28,column:6},end:{line:36,column:7}},17:{start:{line:29,column:8},end:{line:29,column:32}},18:{start:{line:30,column:13},end:{line:36,column:7}},19:{start:{line:31,column:8},end:{line:31,column:32}},20:{start:{line:32,column:13},end:{line:36,column:7}},21:{start:{line:33,column:8},end:{line:33,column:32}},22:{start:{line:34,column:13},end:{line:36,column:7}},23:{start:{line:35,column:8},end:{line:35,column:42}},24:{start:{line:37,column:6},end:{line:42,column:7}},25:{start:{line:38,column:22},end:{line:38,column:51}},26:{start:{line:39,column:8},end:{line:39,column:29}},27:{start:{line:41,column:8},end:{line:41,column:23}},28:{start:{line:44,column:6},end:{line:44,column:63}},29:{start:{line:45,column:6},end:{line:45,column:21}},30:{start:{line:49,column:20},end:{line:49,column:67}},31:{start:{line:50,column:18},end:{line:95,column:6}},32:{start:{line:51,column:21},end:{line:90,column:8}},33:{start:{line:52,column:29},end:{line:52,column:76}},34:{start:{line:53,column:8},end:{line:89,column:10}},35:{start:{line:70,column:20},end:{line:70,column:63}},36:{start:{line:91,column:6},end:{line:94,column:26}},37:{start:{line:96,column:4},end:{line:96,column:102}}},fnMap:{0:{name:"groupFeaturesBySourceLayer",decl:{start:{line:4,column:9},end:{line:4,column:35}},loc:{start:{line:4,column:46},end:{line:19,column:1}},line:4},1:{name:"(anonymous_1)",decl:{start:{line:7,column:19},end:{line:7,column:20}},loc:{start:{line:7,column:32},end:{line:17,column:3}},line:7},2:{name:"(anonymous_2)",decl:{start:{line:10,column:72},end:{line:10,column:73}},loc:{start:{line:10,column:79},end:{line:10,column:110}},line:10},3:{name:"(anonymous_3)",decl:{start:{line:21,column:2},end:{line:21,column:3}},loc:{start:{line:21,column:35},end:{line:47,column:3}},line:21},4:{name:"(anonymous_4)",decl:{start:{line:48,column:2},end:{line:48,column:3}},loc:{start:{line:48,column:11},end:{line:97,column:3}},line:48},5:{name:"(anonymous_5)",decl:{start:{line:50,column:43},end:{line:50,column:44}},loc:{start:{line:50,column:62},end:{line:95,column:5}},line:50},6:{name:"(anonymous_6)",decl:{start:{line:51,column:48},end:{line:51,column:49}},loc:{start:{line:51,column:66},end:{line:90,column:7}},line:51},7:{name:"(anonymous_7)",decl:{start:{line:69,column:27},end:{line:69,column:28}},loc:{start:{line:69,column:33},end:{line:71,column:19}},line:69}},branchMap:{0:{loc:{start:{line:8,column:4},end:{line:16,column:5}},type:"if",locations:[{start:{line:8,column:4},end:{line:16,column:5}},{start:{line:12,column:11},end:{line:16,column:5}}],line:8},1:{loc:{start:{line:13,column:47},end:{line:13,column:91}},type:"binary-expr",locations:[{start:{line:13,column:47},end:{line:13,column:85}},{start:{line:13,column:89},end:{line:13,column:91}}],line:13},2:{loc:{start:{line:22,column:4},end:{line:24,column:5}},type:"if",locations:[{start:{line:22,column:4},end:{line:24,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:22},3:{loc:{start:{line:28,column:6},end:{line:36,column:7}},type:"if",locations:[{start:{line:28,column:6},end:{line:36,column:7}},{start:{line:30,column:13},end:{line:36,column:7}}],line:28},4:{loc:{start:{line:28,column:10},end:{line:28,column:100}},type:"binary-expr",locations:[{start:{line:28,column:10},end:{line:28,column:72}},{start:{line:28,column:76},end:{line:28,column:100}}],line:28},5:{loc:{start:{line:30,column:13},end:{line:36,column:7}},type:"if",locations:[{start:{line:30,column:13},end:{line:36,column:7}},{start:{line:32,column:13},end:{line:36,column:7}}],line:30},6:{loc:{start:{line:30,column:17},end:{line:30,column:107}},type:"binary-expr",locations:[{start:{line:30,column:17},end:{line:30,column:79}},{start:{line:30,column:83},end:{line:30,column:107}}],line:30},7:{loc:{start:{line:32,column:13},end:{line:36,column:7}},type:"if",locations:[{start:{line:32,column:13},end:{line:36,column:7}},{start:{line:34,column:13},end:{line:36,column:7}}],line:32},8:{loc:{start:{line:32,column:17},end:{line:32,column:107}},type:"binary-expr",locations:[{start:{line:32,column:17},end:{line:32,column:79}},{start:{line:32,column:83},end:{line:32,column:107}}],line:32},9:{loc:{start:{line:34,column:13},end:{line:36,column:7}},type:"if",locations:[{start:{line:34,column:13},end:{line:36,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:34},10:{loc:{start:{line:34,column:17},end:{line:34,column:127}},type:"binary-expr",locations:[{start:{line:34,column:17},end:{line:34,column:89}},{start:{line:34,column:93},end:{line:34,column:127}}],line:34},11:{loc:{start:{line:37,column:6},end:{line:42,column:7}},type:"if",locations:[{start:{line:37,column:6},end:{line:42,column:7}},{start:{line:40,column:13},end:{line:42,column:7}}],line:37},12:{loc:{start:{line:73,column:20},end:{line:77,column:24}},type:"binary-expr",locations:[{start:{line:73,column:20},end:{line:73,column:38}},{start:{line:73,column:58},end:{line:77,column:24}}],line:73},13:{loc:{start:{line:79,column:20},end:{line:82,column:24}},type:"binary-expr",locations:[{start:{line:79,column:20},end:{line:79,column:35}},{start:{line:79,column:55},end:{line:82,column:24}}],line:79}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlLayerPopup.tsx"],names:[],mappings:"AAqFU,cAkBsB,YAlBtB;AArFV,OAAO,WAAW;AAClB,OAAO,eAAe;AAGtB,SAAS,2BAA2B,UAA4B;AAC9D,QAAM,UAA6C,CAAC;AAEpD,QAAM,mBAA4C,CAAC;AAEnD,WAAS,QAAQ,aAAW;AAC1B,QAAG,OAAO,UAAU,eAAe,KAAK,kBAAkB,QAAQ,MAAM,EAAE,GAAG;AAC3E,uBAAiB,QAAQ,MAAM,EAAE;AAEjC,YAAM,gBAAgB,QAAQ,QAAQ,MAAM,cAAc,CAAC,EAAE,KAAK,CAAC,MAAsB,EAAE,MAAM,OAAO,QAAQ,MAAM,EAAE;AAExH,oBAAe,UAAU,iBAAiB,QAAQ,MAAM,EAAE;AAAA,IAC5D,OAAO;AACL,cAAQ,QAAQ,MAAM,cAAc,CAAC,IAAI,QAAQ,QAAQ,MAAM,cAAc,CAAC,KAAK,CAAC;AACpF,cAAQ,QAAQ,MAAM,cAAc,CAAC,EAAE,KAAK,OAAO;AAEnD,uBAAiB,QAAQ,MAAM,EAAE,IAAI;AAAA,IACvC;AAAA,EACF,CAAC;AAED,SAAO;AACT;AAQA,MAAM,0BAA0B,MAAM,UAAkC;AAAA,EACtE,iBAAiB,SAAyB,OAAgB;AAExD,QAAI,CAAC,QAAQ,MAAM,OAAO;AACxB;AAAA,IACF;AAEA,QAAI;AACF,YAAM,aAAa,QAAQ,MAAM;AACjC,UAAI;AAEJ,UAAG,OAAO,UAAU,eAAe,KAAK,YAAY,YAAY,KAAK,WAAW,YAAY,GAAG;AAC7F,mBAAW;AAAA,MACb,WACS,OAAO,UAAU,eAAe,KAAK,YAAY,YAAY,KAAK,WAAW,YAAY,GAAG;AACnG,mBAAW;AAAA,MACb,WACS,OAAO,UAAU,eAAe,KAAK,YAAY,YAAY,KAAK,WAAW,YAAY,GAAG;AACnG,mBAAW;AAAA,MACb,WACS,OAAO,UAAU,eAAe,KAAK,YAAY,sBAAsB,KAAK,WAAW,sBAAsB,GAAG;AACvH,mBAAW;AAAA,MACb;AAEA,UAAG,UAAU;AACX,cAAM,QAAQ,QAAQ,MAAM,MAAM,QAAQ;AAC1C,eAAO,OAAO,KAAK;AAAA,MACrB,OACK;AAEH,eAAO;AAAA,MACT;AAAA,IACF,SAGO,KAAK;AACV,cAAQ,KAAK,uCAAuC,GAAG;AACvD,aAAO;AAAA,IACT;AAAA,EACF;AAAA,EAEA,SAAS;AACP,UAAM,UAAU,2BAA2B,KAAK,MAAM,QAAQ;AAE9D,UAAM,QAAQ,OAAO,KAAK,OAAO,EAAE,IAAI,mBAAiB;AACtD,YAAM,SAAS,QAAQ,aAAa,EAAE,IAAI,CAAC,SAAyB,QAAgB;AAClF,cAAM,eAAe,KAAK,iBAAiB,SAAS,KAAK,MAAM,IAAI;AAEnE,eAAO;AAAA,UAAC;AAAA;AAAA,YAEN,WAAU;AAAA,YAEV;AAAA;AAAA,gBAAC;AAAA;AAAA,kBACC,WAAU;AAAA,kBACV,OAAO,EAAC,YAAY,aAAY;AAAA;AAAA,cACjC;AAAA,cACD;AAAA,gBAAC;AAAA;AAAA,kBACC,WAAU;AAAA,kBACV,SAAS,MAAM;AACb,yBAAK,MAAM,cAAc,QAAQ,MAAM,EAAE;AAAA,kBAC3C;AAAA,kBAEC;AAAA,4BAAQ,MAAM,QACb,oBAAC,aAAU,MAAM,QAAQ,MAAM,MAAM,OAAO;AAAA,sBAC1C,OAAO;AAAA,sBACP,QAAQ;AAAA,sBACR,cAAc;AAAA,oBAChB,GAAE;AAAA,oBAEH,QAAQ,MAAM;AAAA,oBACd,QAAQ,WAAW,qBAAC,UAAK;AAAA;AAAA,sBAAI,QAAQ;AAAA,uBAAQ;AAAA;AAAA;AAAA,cAChD;AAAA;AAAA;AAAA,UAtBK;AAAA,QAuBP;AAAA,MACF,CAAC;AACD,aAAO,qBAAC,SACN;AAAA,4BAAC,SAAI,WAAU,2BAA2B,yBAAc;AAAA,QACvD;AAAA,WAFc,aAGjB;AAAA,IACF,CAAC;AAED,WAAO,oBAAC,SAAI,WAAU,gCACnB,iBACH;AAAA,EACF;AACF;AAGA,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"8ac820d45b409d4d358e8cb1f505fcc4025456db"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return hr=function(){return s},s}hr();function IJ(e){hr().f[0]++;const n=(hr().s[0]++,{}),t=(hr().s[1]++,{});return hr().s[2]++,e.forEach(r=>{if(hr().f[1]++,hr().s[3]++,Object.prototype.hasOwnProperty.call(t,r.layer.id)){hr().b[0][0]++,hr().s[4]++,t[r.layer.id]++;const i=(hr().s[5]++,n[r.layer["source-layer"]].find(o=>(hr().f[2]++,hr().s[6]++,o.layer.id===r.layer.id)));hr().s[7]++,i.counter=t[r.layer.id]}else hr().b[0][1]++,hr().s[8]++,n[r.layer["source-layer"]]=(hr().b[1][0]++,n[r.layer["source-layer"]]||(hr().b[1][1]++,[])),hr().s[9]++,n[r.layer["source-layer"]].push(r),hr().s[10]++,t[r.layer.id]=1}),hr().s[11]++,n}class HR extends bn.Component{_getFeatureColor(n,t){if(hr().f[3]++,hr().s[12]++,n.layer.paint)hr().b[2][1]++;else{hr().b[2][0]++,hr().s[13]++;return}hr().s[14]++;try{const r=(hr().s[15]++,n.layer.paint);let i;if(hr().s[16]++,hr().b[4][0]++,Object.prototype.hasOwnProperty.call(r,"text-color")&&(hr().b[4][1]++,r["text-color"])?(hr().b[3][0]++,hr().s[17]++,i="text-color"):(hr().b[3][1]++,hr().s[18]++,hr().b[6][0]++,Object.prototype.hasOwnProperty.call(r,"fill-color")&&(hr().b[6][1]++,r["fill-color"])?(hr().b[5][0]++,hr().s[19]++,i="fill-color"):(hr().b[5][1]++,hr().s[20]++,hr().b[8][0]++,Object.prototype.hasOwnProperty.call(r,"line-color")&&(hr().b[8][1]++,r["line-color"])?(hr().b[7][0]++,hr().s[21]++,i="line-color"):(hr().b[7][1]++,hr().s[22]++,hr().b[10][0]++,Object.prototype.hasOwnProperty.call(r,"fill-extrusion-color")&&(hr().b[10][1]++,r["fill-extrusion-color"])?(hr().b[9][0]++,hr().s[23]++,i="fill-extrusion-color"):hr().b[9][1]++))),hr().s[24]++,i){hr().b[11][0]++;const o=(hr().s[25]++,n.layer.paint[i]);return hr().s[26]++,String(o)}else return hr().b[11][1]++,hr().s[27]++,"black"}catch(r){return hr().s[28]++,console.warn("Unable to get feature color, error:",r),hr().s[29]++,"black"}}render(){hr().f[4]++;const n=(hr().s[30]++,IJ(this.props.features)),t=(hr().s[31]++,Object.keys(n).map(r=>{hr().f[5]++;const i=(hr().s[32]++,n[r].map((o,s)=>{hr().f[6]++;const a=(hr().s[33]++,this._getFeatureColor(o,this.props.zoom));return hr().s[34]++,N.jsxs("div",{className:"maputnik-popup-layer",children:[N.jsx("div",{className:"maputnik-popup-layer__swatch",style:{background:a}}),N.jsxs("label",{className:"maputnik-popup-layer__label",onClick:()=>{hr().f[7]++,hr().s[35]++,this.props.onLayerSelect(o.layer.id)},children:[(hr().b[12][0]++,o.layer.type&&(hr().b[12][1]++,N.jsx(VR,{type:o.layer.type,style:{width:14,height:14,paddingRight:3}}))),o.layer.id,(hr().b[13][0]++,o.counter&&(hr().b[13][1]++,N.jsxs("span",{children:[" × ",o.counter]})))]})]},s)}));return hr().s[36]++,N.jsxs("div",{children:[N.jsx("div",{className:"maputnik-popup-layer-id",children:r}),i]},r)}));return hr().s[37]++,N.jsx("div",{className:"maputnik-feature-layer-popup",children:t})}}var ZR={exports:{}};/*!
|
||
Copyright (c) 2018 Jed Watson.
|
||
Licensed under the MIT License (MIT), see
|
||
http://jedwatson.github.io/classnames
|
||
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var o="",s=0;s<arguments.length;s++){var a=arguments[s];a&&(o=i(o,r(a)))}return o}function r(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return t.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var s="";for(var a in o)n.call(o,a)&&o[a]&&(s=i(s,a));return s}function i(o,s){return s?o?o+" "+s:o+s:o}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(ZR);var TJ=ZR.exports;const Af=ga(TJ);function ko(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldDocLabel.tsx",n="3158bd93bbefd1bd0e63d26617da070781685c25",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldDocLabel.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:17}},1:{start:{line:7,column:4},end:{line:9,column:6}},2:{start:{line:11,column:16},end:{line:19,column:3}},3:{start:{line:12,column:4},end:{line:18,column:7}},4:{start:{line:15,column:6},end:{line:17,column:7}},5:{start:{line:16,column:8},end:{line:16,column:48}},6:{start:{line:21,column:33},end:{line:21,column:43}},7:{start:{line:22,column:20},end:{line:22,column:35}},8:{start:{line:23,column:4},end:{line:42,column:5}},9:{start:{line:24,column:6},end:{line:37,column:14}},10:{start:{line:32,column:27},end:{line:32,column:61}},11:{start:{line:38,column:11},end:{line:42,column:5}},12:{start:{line:39,column:6},end:{line:39,column:174}},13:{start:{line:41,column:22},end:{line:41,column:37}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:21},end:{line:10,column:3}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:11,column:16},end:{line:11,column:17}},loc:{start:{line:11,column:26},end:{line:19,column:3}},line:11},2:{name:"(anonymous_2)",decl:{start:{line:14,column:7},end:{line:14,column:8}},loc:{start:{line:14,column:13},end:{line:18,column:5}},line:14},3:{name:"(anonymous_3)",decl:{start:{line:20,column:2},end:{line:20,column:3}},loc:{start:{line:20,column:11},end:{line:43,column:3}},line:20},4:{name:"(anonymous_4)",decl:{start:{line:32,column:21},end:{line:32,column:22}},loc:{start:{line:32,column:27},end:{line:32,column:61}},line:32}},branchMap:{0:{loc:{start:{line:15,column:6},end:{line:17,column:7}},type:"if",locations:[{start:{line:15,column:6},end:{line:17,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:15},1:{loc:{start:{line:22,column:20},end:{line:22,column:35}},type:"binary-expr",locations:[{start:{line:22,column:20},end:{line:22,column:29}},{start:{line:22,column:33},end:{line:22,column:35}}],line:22},2:{loc:{start:{line:23,column:4},end:{line:42,column:5}},type:"if",locations:[{start:{line:23,column:4},end:{line:42,column:5}},{start:{line:38,column:11},end:{line:42,column:5}}],line:23},3:{loc:{start:{line:30,column:26},end:{line:30,column:106}},type:"cond-expr",locations:[{start:{line:30,column:44},end:{line:30,column:74}},{start:{line:30,column:77},end:{line:30,column:106}}],line:30},4:{loc:{start:{line:31,column:67},end:{line:31,column:102}},type:"cond-expr",locations:[{start:{line:31,column:85},end:{line:31,column:91}},{start:{line:31,column:94},end:{line:31,column:102}}],line:31},5:{loc:{start:{line:34,column:22},end:{line:34,column:120}},type:"cond-expr",locations:[{start:{line:34,column:56},end:{line:34,column:79}},{start:{line:34,column:98},end:{line:34,column:120}}],line:34},6:{loc:{start:{line:38,column:11},end:{line:42,column:5}},type:"if",locations:[{start:{line:38,column:11},end:{line:42,column:5}},{start:{line:40,column:11},end:{line:42,column:5}}],line:38}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldDocLabel.tsx"],names:[],mappings:"AAuCQ,SASuB,KATvB;AAvCR,OAAO,WAAW;AAClB,SAAQ,eAAe,sBAAqB;AAc5C,qBAAqB,sBAAsB,MAAM,UAAkD;AAAA,EACjG,YAAa,OAA2B;AACtC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,MAAM;AAAA,IACR;AAAA,EACF;AAAA,EAEA,cAAc,CAAC,SAAkB;AAC/B,SAAK,SAAS;AAAA,MACZ;AAAA,IACF,GAAG,MAAM;AACP,UAAI,KAAK,MAAM,aAAa;AAC1B,aAAK,MAAM,YAAY,KAAK,MAAM,IAAI;AAAA,MACxC;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,OAAO,UAAS,IAAI,KAAK;AAChC,UAAM,EAAC,IAAG,IAAI,aAAa,CAAC;AAE5B,QAAI,KAAK;AACP,aAAO,oBAAC,WAAM,WAAU,wBACtB,+BAAC,SAAI,WAAU,uBACZ;AAAA;AAAA,QACA;AAAA,QACD;AAAA,UAAC;AAAA;AAAA,YACC,cAAY,KAAK,MAAM,OAAO,iCAAiC;AAAA,YAC/D,WAAW,4CAA4C,KAAK,MAAM,OAAO,SAAS,QAAQ;AAAA,YAC1F,SAAS,MAAM,KAAK,YAAY,CAAC,KAAK,MAAM,IAAI;AAAA,YAChD,eAAa,sBAAoB;AAAA,YAEhC,eAAK,MAAM,OAAO,oBAAC,kBAAe,IAAK,oBAAC,iBAAc;AAAA;AAAA,QACzD;AAAA,SACF,GACF;AAAA,IACF,WACS,OAAO;AACd,aAAO,oBAAC,WAAM,WAAU,wBACtB,8BAAC,SAAI,WAAU,uBACZ,iBACH,GACF;AAAA,IACF,OACK;AACH,0BAAC,SAAI;AAAA,IACP;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"3158bd93bbefd1bd0e63d26617da070781685c25"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ko=function(){return s},s}ko();class PB extends bn.Component{constructor(t){ko().f[0]++,ko().s[0]++;super(t);nn(this,"onToggleDoc",(ko().s[2]++,t=>{ko().f[1]++,ko().s[3]++,this.setState({open:t},()=>{ko().f[2]++,ko().s[4]++,this.props.onToggleDoc?(ko().b[0][0]++,ko().s[5]++,this.props.onToggleDoc(this.state.open)):ko().b[0][1]++})}));ko().s[1]++,this.state={open:!1}}render(){ko().f[3]++;const{label:t,fieldSpec:r}=(ko().s[6]++,this.props),{doc:i}=(ko().s[7]++,ko().b[1][0]++,r||(ko().b[1][1]++,{}));if(ko().s[8]++,i)return ko().b[2][0]++,ko().s[9]++,N.jsx("label",{className:"maputnik-doc-wrapper",children:N.jsxs("div",{className:"maputnik-doc-target",children:[t," ",N.jsx("button",{"aria-label":this.state.open?(ko().b[3][0]++,"close property documentation"):(ko().b[3][1]++,"open property documentation"),className:`maputnik-doc-button maputnik-doc-button--${this.state.open?(ko().b[4][0]++,"open"):(ko().b[4][1]++,"closed")}`,onClick:()=>(ko().f[4]++,ko().s[10]++,this.onToggleDoc(!this.state.open)),"data-wd-key":"field-doc-button-"+t,children:this.state.open?(ko().b[5][0]++,N.jsx(hJ,{})):(ko().b[5][1]++,N.jsx(fJ,{}))})]})});if(ko().b[2][1]++,ko().s[11]++,t)return ko().b[6][0]++,ko().s[12]++,N.jsx("label",{className:"maputnik-doc-wrapper",children:N.jsx("div",{className:"maputnik-doc-target",children:t})});ko().b[6][1]++,ko().s[13]++}}function ha(){var e="/home/runner/work/maputnik/maputnik/src/components/Doc.tsx",n="17184511a0ae3c272ec6d16762ac334920d5242e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/Doc.tsx",statementMap:{0:{start:{line:3,column:16},end:{line:8,column:1}},1:{start:{line:11,column:26},end:{line:11,column:36}},2:{start:{line:12,column:28},end:{line:12,column:37}},3:{start:{line:13,column:23},end:{line:13,column:47}},4:{start:{line:14,column:25},end:{line:16,column:26}},5:{start:{line:17,column:4},end:{line:47,column:9}},6:{start:{line:21,column:10},end:{line:24,column:20}},7:{start:{line:31,column:12},end:{line:31,column:75}},8:{start:{line:35,column:10},end:{line:44,column:20}},9:{start:{line:38,column:14},end:{line:42,column:15}},10:{start:{line:39,column:16},end:{line:39,column:81}},11:{start:{line:41,column:16},end:{line:41,column:72}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:10,column:2},end:{line:10,column:3}},loc:{start:{line:10,column:11},end:{line:48,column:3}},line:10},1:{name:"(anonymous_1)",decl:{start:{line:20,column:119},end:{line:20,column:120}},loc:{start:{line:20,column:137},end:{line:25,column:9}},line:20},2:{name:"(anonymous_2)",decl:{start:{line:30,column:37},end:{line:30,column:38}},loc:{start:{line:30,column:49},end:{line:32,column:11}},line:30},3:{name:"(anonymous_3)",decl:{start:{line:34,column:80},end:{line:34,column:81}},loc:{start:{line:34,column:103},end:{line:45,column:9}},line:34},4:{name:"(anonymous_4)",decl:{start:{line:37,column:37},end:{line:37,column:38}},loc:{start:{line:37,column:44},end:{line:43,column:13}},line:37}},branchMap:{0:{loc:{start:{line:14,column:25},end:{line:16,column:26}},type:"binary-expr",locations:[{start:{line:14,column:25},end:{line:14,column:33}},{start:{line:16,column:4},end:{line:16,column:26}}],line:14},1:{loc:{start:{line:18,column:6},end:{line:26,column:10}},type:"binary-expr",locations:[{start:{line:18,column:6},end:{line:18,column:9}},{start:{line:18,column:29},end:{line:26,column:10}}],line:18},2:{loc:{start:{line:20,column:8},end:{line:25,column:13}},type:"binary-expr",locations:[{start:{line:20,column:8},end:{line:20,column:20}},{start:{line:20,column:40},end:{line:25,column:13}}],line:20},3:{loc:{start:{line:27,column:6},end:{line:46,column:13}},type:"binary-expr",locations:[{start:{line:27,column:6},end:{line:27,column:16}},{start:{line:27,column:36},end:{line:46,column:13}}],line:27},4:{loc:{start:{line:38,column:14},end:{line:42,column:15}},type:"if",locations:[{start:{line:38,column:14},end:{line:42,column:15}},{start:{line:40,column:21},end:{line:42,column:15}}],line:38}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/Doc.tsx"],names:[],mappings:"AAsCM,mBAGM,KAKQ,YARd;AAtCN,OAAO,WAAW;AAElB,MAAM,UAAU;AAAA,EACd,IAAI;AAAA,EACJ,SAAS;AAAA,EACT,KAAK;AAAA,EACL,OAAO;AACT;AAgBA,qBAAqB,YAAY,MAAM,UAAoB;AAAA,EACzD,SAAU;AACR,UAAM,EAAC,UAAS,IAAI,KAAK;AAEzB,UAAM,EAAC,KAAK,OAAM,IAAI;AACtB,UAAM,aAAa,UAAU,aAAa;AAE1C,UAAM,eACJ,CAAC,CAAC;AAAA;AAAA,IAGF,CAAC,MAAM,QAAQ,MAAM;AAGvB,WACE,iCACG;AAAA,aACC,qBAAC,SAAI,WAAU,WACb;AAAA,4BAAC,SAAI,WAAU,gBAAe,eAAY,kBAAkB,eAAI;AAAA,QAC/D,gBACC,oBAAC,QAAG,WAAU,mBACX,iBAAO,QAAQ,MAAM,EAAE,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM;AAC5C,iBACE,qBAAC,QACC;AAAA,gCAAC,UAAM,eAAK,UAAU,GAAG,GAAE;AAAA,YAC3B,oBAAC,SAAK,gBAAM,KAAI;AAAA,eAFT,GAGT;AAAA,QAEJ,CAAC,GACH;AAAA,SAEJ;AAAA,MAED,cACC,oBAAC,SAAI,WAAU,wBACb,+BAAC,WAAM,WAAU,+BACf;AAAA,4BAAC,WACC,+BAAC,QACC;AAAA,8BAAC,QAAG;AAAA,UACH,OAAO,OAAO,OAAO,EAAE,IAAI,YAAU;AACpC,mBAAO,oBAAC,QAAiB,oBAAT,MAAgB;AAAA,UAClC,CAAC;AAAA,WACH,GACF;AAAA,QACA,oBAAC,WACE,iBAAO,QAAQ,UAAU,EAAE,IAAI,CAAC,CAAC,KAAK,UAAU,MAAM;AACrD,iBACE,qBAAC,QACC;AAAA,gCAAC,QAAI,eAAI;AAAA,YACR,OAAO,KAAK,OAAO,EAAE,IAAI,CAAC,MAAM;AAC/B,kBAAI,OAAO,UAAU,eAAe,KAAK,YAAY,CAAC,GAAG;AACvD,uBAAO,oBAAC,QAAY,qBAAW,CAAyB,KAAxC,CAA0C;AAAA,cAC5D,OACK;AACH,uBAAO,oBAAC,QAAW,kBAAH,CAAK;AAAA,cACvB;AAAA,YACF,CAAC;AAAA,eATM,GAUT;AAAA,QAEJ,CAAC,GACH;AAAA,SACF,GACF;AAAA,OAEJ;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"17184511a0ae3c272ec6d16762ac334920d5242e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ha=function(){return s},s}ha();const JI=(ha().s[0]++,{js:"JS",android:"Android",ios:"iOS",macos:"macOS"});class FB extends bn.Component{render(){ha().f[0]++;const{fieldSpec:n}=(ha().s[1]++,this.props),{doc:t,values:r}=(ha().s[2]++,n),i=(ha().s[3]++,n["sdk-support"]),o=(ha().s[4]++,ha().b[0][0]++,!!r&&(ha().b[0][1]++,!Array.isArray(r)));return ha().s[5]++,N.jsxs(N.Fragment,{children:[(ha().b[1][0]++,t&&(ha().b[1][1]++,N.jsxs("div",{className:"SpecDoc",children:[N.jsx("div",{className:"SpecDoc__doc","data-wd-key":"spec-field-doc",children:t}),(ha().b[2][0]++,o&&(ha().b[2][1]++,N.jsx("ul",{className:"SpecDoc__values",children:Object.entries(r).map(([s,a])=>(ha().f[1]++,ha().s[6]++,N.jsxs("li",{children:[N.jsx("code",{children:JSON.stringify(s)}),N.jsx("div",{children:a.doc})]},s)))})))]}))),(ha().b[3][0]++,i&&(ha().b[3][1]++,N.jsx("div",{className:"SpecDoc__sdk-support",children:N.jsxs("table",{className:"SpecDoc__sdk-support__table",children:[N.jsx("thead",{children:N.jsxs("tr",{children:[N.jsx("th",{}),Object.values(JI).map(s=>(ha().f[2]++,ha().s[7]++,N.jsx("th",{children:s},s)))]})}),N.jsx("tbody",{children:Object.entries(i).map(([s,a])=>(ha().f[3]++,ha().s[8]++,N.jsxs("tr",{children:[N.jsx("td",{children:s}),Object.keys(JI).map(f=>(ha().f[4]++,ha().s[9]++,Object.prototype.hasOwnProperty.call(a,f)?(ha().b[4][0]++,ha().s[10]++,N.jsx("td",{children:a[f]},f)):(ha().b[4][1]++,ha().s[11]++,N.jsx("td",{children:"no"},f))))]},s)))})]})})))]})}}function io(){var e="/home/runner/work/maputnik/maputnik/src/components/Block.tsx",n="79082a0e6b5f812e7e85f0d24298fdd4bfc28eb8",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/Block.tsx",statementMap:{0:{start:{line:7,column:13},end:{line:7,column:17}},1:{start:{line:9,column:4},end:{line:9,column:17}},2:{start:{line:10,column:4},end:{line:12,column:6}},3:{start:{line:15,column:18},end:{line:15,column:32}},4:{start:{line:16,column:4},end:{line:18,column:5}},5:{start:{line:17,column:6},end:{line:17,column:64}},6:{start:{line:20,column:16},end:{line:24,column:3}},7:{start:{line:21,column:4},end:{line:23,column:7}},8:{start:{line:31,column:17},end:{line:38,column:3}},9:{start:{line:32,column:15},end:{line:32,column:39}},10:{start:{line:33,column:21},end:{line:33,column:48}},11:{start:{line:34,column:4},end:{line:36,column:5}},12:{start:{line:35,column:6},end:{line:35,column:30}},13:{start:{line:37,column:4},end:{line:37,column:27}},14:{start:{line:40,column:4},end:{line:73,column:6}},15:{start:{line:62,column:95},end:{line:62,column:113}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:8,column:2},end:{line:8,column:3}},loc:{start:{line:8,column:21},end:{line:13,column:3}},line:8},1:{name:"(anonymous_1)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:14},end:{line:19,column:3}},line:14},2:{name:"(anonymous_2)",decl:{start:{line:20,column:16},end:{line:20,column:17}},loc:{start:{line:20,column:25},end:{line:24,column:3}},line:20},3:{name:"(anonymous_3)",decl:{start:{line:31,column:17},end:{line:31,column:18}},loc:{start:{line:31,column:28},end:{line:38,column:3}},line:31},4:{name:"(anonymous_4)",decl:{start:{line:39,column:2},end:{line:39,column:3}},loc:{start:{line:39,column:11},end:{line:74,column:3}},line:39},5:{name:"(anonymous_5)",decl:{start:{line:62,column:87},end:{line:62,column:88}},loc:{start:{line:62,column:95},end:{line:62,column:113}},line:62}},branchMap:{0:{loc:{start:{line:16,column:4},end:{line:18,column:5}},type:"if",locations:[{start:{line:16,column:4},end:{line:18,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:16},1:{loc:{start:{line:17,column:33},end:{line:17,column:62}},type:"cond-expr",locations:[{start:{line:17,column:48},end:{line:17,column:54}},{start:{line:17,column:57},end:{line:17,column:62}}],line:17},2:{loc:{start:{line:34,column:4},end:{line:36,column:5}},type:"if",locations:[{start:{line:34,column:4},end:{line:36,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:34},3:{loc:{start:{line:34,column:8},end:{line:34,column:66}},type:"binary-expr",locations:[{start:{line:34,column:8},end:{line:34,column:53}},{start:{line:34,column:57},end:{line:34,column:66}}],line:34},4:{loc:{start:{line:52,column:10},end:{line:59,column:14}},type:"binary-expr",locations:[{start:{line:52,column:10},end:{line:52,column:30}},{start:{line:52,column:50},end:{line:59,column:14}}],line:52},5:{loc:{start:{line:60,column:10},end:{line:60,column:134}},type:"binary-expr",locations:[{start:{line:60,column:10},end:{line:60,column:31}},{start:{line:60,column:51},end:{line:60,column:134}}],line:60},6:{loc:{start:{line:63,column:10},end:{line:70,column:11}},type:"binary-expr",locations:[{start:{line:63,column:10},end:{line:63,column:30}},{start:{line:63,column:50},end:{line:70,column:11}}],line:63},7:{loc:{start:{line:67,column:32},end:{line:67,column:64}},type:"cond-expr",locations:[{start:{line:67,column:53},end:{line:67,column:55}},{start:{line:67,column:58},end:{line:67,column:64}}],line:67}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0},f:{0:0,1:0,2:0,3:0,4:0,5:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/Block.tsx"],names:[],mappings:"AA8DW,SAWD,KAXC;AA9DX,OAAO,WAA6B;AACpC,OAAO,gBAAgB;AACvB,OAAO,mBAAmB;AAC1B,OAAO,SAAS;AAmBhB,qBAAqB,cAAc,MAAM,UAAkC;AAAA,EACzE,WAAkC;AAAA,EAElC,YAAa,OAAmB;AAC9B,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,SAAS;AAAA,IACX;AAAA,EACF;AAAA,EAEA,SAAS,GAAwE;AAC/E,UAAM,QAAQ,EAAE,OAAO;AACvB,QAAI,KAAK,MAAM,UAAU;AACvB,aAAO,KAAK,MAAM,SAAS,UAAU,KAAK,SAAY,KAAK;AAAA,IAC7D;AAAA,EACF;AAAA,EAEA,cAAc,CAAC,QAAiB;AAC9B,SAAK,SAAS;AAAA,MACZ,SAAS;AAAA,IACX,CAAC;AAAA,EACH;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQA,eAAe,CAAC,UAAoC;AAClD,UAAM,KAAK,MAAM,YAAY;AAC7B,UAAM,WAAW,KAAK,UAAU,SAAS,EAAE;AAE3C,QAAI,MAAM,YAAY,OAAO,aAAa,WAAW,CAAC,UAAU;AAC9D,YAAM,gBAAgB;AAAA,IACxB;AACA,UAAM,eAAe;AAAA,EACvB;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QAAM,OAAO,KAAK,MAAM;AAAA,QAC9B,eAAa,KAAK,MAAM,aAAa;AAAA,QACrC,WAAW,WAAW;AAAA,UACpB,wBAAwB;AAAA,UACxB,8BAA8B,KAAK,MAAM;AAAA,UACzC,yBAAyB,KAAK,MAAM;AAAA,QACtC,CAAC;AAAA,QACD,SAAS,KAAK;AAAA,QAEb;AAAA,eAAK,MAAM,aACV,oBAAC,SAAI,WAAU,8BACb;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,KAAK,MAAM;AAAA,cAClB,aAAa,KAAK;AAAA,cAClB,WAAW,KAAK,MAAM;AAAA;AAAA,UACxB,GACF;AAAA,UAED,CAAC,KAAK,MAAM,aACX,oBAAC,SAAI,WAAU,8BACZ,eAAK,MAAM,OACd;AAAA,UAEF,oBAAC,SAAI,WAAU,+BACZ,eAAK,MAAM,QACd;AAAA,UACA,oBAAC,SAAI,WAAU,gCAA+B,KAAK,QAAM,KAAK,WAAW,IACtE,eAAK,MAAM,UACd;AAAA,UACC,KAAK,MAAM,aACV;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,OAAO,EAAC,SAAS,KAAK,MAAM,UAAU,KAAK,OAAM;AAAA,cAEjD,8BAAC,OAAI,WAAW,KAAK,MAAM,WAAW;AAAA;AAAA,UACxC;AAAA;AAAA;AAAA,IAEJ;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"79082a0e6b5f812e7e85f0d24298fdd4bfc28eb8"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return io=function(){return s},s}io();class Uo extends bn.Component{constructor(t){io().f[0]++,io().s[1]++;super(t);nn(this,"_blockEl",(io().s[0]++,null));nn(this,"onToggleDoc",(io().s[6]++,t=>{io().f[2]++,io().s[7]++,this.setState({showDoc:t})}));nn(this,"onLabelClick",(io().s[8]++,t=>{var o;io().f[3]++;const r=(io().s[9]++,t.nativeEvent.target),i=(io().s[10]++,(o=this._blockEl)==null?void 0:o.contains(r));io().s[11]++,io().b[3][0]++,t.nativeEvent.target.nodeName!=="INPUT"&&(io().b[3][1]++,!i)?(io().b[2][0]++,io().s[12]++,t.stopPropagation()):io().b[2][1]++,io().s[13]++,t.preventDefault()}));io().s[2]++,this.state={showDoc:!1}}onChange(t){io().f[1]++;const r=(io().s[3]++,t.target.value);if(io().s[4]++,this.props.onChange)return io().b[0][0]++,io().s[5]++,this.props.onChange(r===""?(io().b[1][0]++,void 0):(io().b[1][1]++,r));io().b[0][1]++}render(){return io().f[4]++,io().s[14]++,N.jsxs("label",{style:this.props.style,"data-wd-key":this.props["data-wd-key"],className:Af({"maputnik-input-block":!0,"maputnik-input-block--wide":this.props.wideMode,"maputnik-action-block":this.props.action}),onClick:this.onLabelClick,children:[(io().b[4][0]++,this.props.fieldSpec&&(io().b[4][1]++,N.jsx("div",{className:"maputnik-input-block-label",children:N.jsx(PB,{label:this.props.label,onToggleDoc:this.onToggleDoc,fieldSpec:this.props.fieldSpec})}))),(io().b[5][0]++,!this.props.fieldSpec&&(io().b[5][1]++,N.jsx("div",{className:"maputnik-input-block-label",children:this.props.label}))),N.jsx("div",{className:"maputnik-input-block-action",children:this.props.action}),N.jsx("div",{className:"maputnik-input-block-content",ref:t=>(io().f[5]++,io().s[15]++,this._blockEl=t),children:this.props.children}),(io().b[6][0]++,this.props.fieldSpec&&(io().b[6][1]++,N.jsx("div",{className:"maputnik-doc-inline",style:{display:this.state.showDoc?(io().b[7][0]++,""):(io().b[7][1]++,"none")},children:N.jsx(FB,{fieldSpec:this.props.fieldSpec})})))]})}}function Jr(){var e="/home/runner/work/maputnik/maputnik/src/components/InputString.tsx",n="7edd0434d5570710fce0bf88d87716b3e75434c4",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputString.tsx",statementMap:{0:{start:{line:3,column:24},end:{line:6,column:3}},1:{start:{line:8,column:4},end:{line:8,column:17}},2:{start:{line:9,column:4},end:{line:12,column:6}},3:{start:{line:15,column:4},end:{line:19,column:5}},4:{start:{line:16,column:6},end:{line:18,column:8}},5:{start:{line:20,column:4},end:{line:20,column:14}},6:{start:{line:25,column:4},end:{line:36,column:5}},7:{start:{line:26,column:6},end:{line:26,column:23}},8:{start:{line:27,column:6},end:{line:30,column:8}},9:{start:{line:32,column:6},end:{line:32,column:20}},10:{start:{line:33,column:6},end:{line:35,column:8}},11:{start:{line:37,column:4},end:{line:39,column:5}},12:{start:{line:38,column:6},end:{line:38,column:48}},13:{start:{line:40,column:4},end:{line:72,column:7}},14:{start:{line:51,column:8},end:{line:57,column:11}},15:{start:{line:55,column:10},end:{line:56,column:49}},16:{start:{line:56,column:12},end:{line:56,column:49}},17:{start:{line:60,column:8},end:{line:64,column:9}},18:{start:{line:61,column:10},end:{line:61,column:44}},19:{start:{line:62,column:10},end:{line:63,column:50}},20:{start:{line:63,column:12},end:{line:63,column:50}},21:{start:{line:67,column:8},end:{line:69,column:9}},22:{start:{line:68,column:10},end:{line:68,column:48}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:4,column:13},end:{line:4,column:14}},loc:{start:{line:4,column:19},end:{line:5,column:5}},line:4},1:{name:"(anonymous_1)",decl:{start:{line:7,column:2},end:{line:7,column:3}},loc:{start:{line:7,column:21},end:{line:13,column:3}},line:7},2:{name:"(anonymous_2)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:48},end:{line:21,column:3}},line:14},3:{name:"(anonymous_3)",decl:{start:{line:22,column:2},end:{line:22,column:3}},loc:{start:{line:22,column:11},end:{line:73,column:3}},line:22},4:{name:"(anonymous_4)",decl:{start:{line:50,column:16},end:{line:50,column:17}},loc:{start:{line:50,column:23},end:{line:58,column:7}},line:50},5:{name:"(anonymous_5)",decl:{start:{line:54,column:11},end:{line:54,column:12}},loc:{start:{line:54,column:17},end:{line:57,column:9}},line:54},6:{name:"(anonymous_6)",decl:{start:{line:59,column:14},end:{line:59,column:15}},loc:{start:{line:59,column:20},end:{line:65,column:7}},line:59},7:{name:"(anonymous_7)",decl:{start:{line:66,column:17},end:{line:66,column:18}},loc:{start:{line:66,column:24},end:{line:70,column:7}},line:66}},branchMap:{0:{loc:{start:{line:11,column:13},end:{line:11,column:30}},type:"binary-expr",locations:[{start:{line:11,column:13},end:{line:11,column:24}},{start:{line:11,column:28},end:{line:11,column:30}}],line:11},1:{loc:{start:{line:15,column:4},end:{line:19,column:5}},type:"if",locations:[{start:{line:15,column:4},end:{line:19,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:15},2:{loc:{start:{line:25,column:4},end:{line:36,column:5}},type:"if",locations:[{start:{line:25,column:4},end:{line:36,column:5}},{start:{line:31,column:11},end:{line:36,column:5}}],line:25},3:{loc:{start:{line:37,column:4},end:{line:39,column:5}},type:"if",locations:[{start:{line:37,column:4},end:{line:39,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:37},4:{loc:{start:{line:43,column:18},end:{line:43,column:125}},type:"cond-expr",locations:[{start:{line:43,column:83},end:{line:43,column:104}},{start:{line:43,column:107},end:{line:43,column:125}}],line:43},5:{loc:{start:{line:47,column:13},end:{line:47,column:64}},type:"cond-expr",locations:[{start:{line:47,column:43},end:{line:47,column:45}},{start:{line:47,column:48},end:{line:47,column:64}}],line:47},6:{loc:{start:{line:55,column:10},end:{line:56,column:49}},type:"if",locations:[{start:{line:55,column:10},end:{line:56,column:49}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:55},7:{loc:{start:{line:60,column:8},end:{line:64,column:9}},type:"if",locations:[{start:{line:60,column:8},end:{line:64,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:60},8:{loc:{start:{line:62,column:10},end:{line:63,column:50}},type:"if",locations:[{start:{line:62,column:10},end:{line:63,column:50}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:62},9:{loc:{start:{line:67,column:8},end:{line:69,column:9}},type:"if",locations:[{start:{line:67,column:8},end:{line:69,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:67},10:{loc:{start:{line:67,column:12},end:{line:67,column:51}},type:"binary-expr",locations:[{start:{line:67,column:12},end:{line:67,column:28}},{start:{line:67,column:32},end:{line:67,column:51}}],line:67}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputString.tsx"],names:[],mappings:"AAAA,OAAO,WAAW;AAsBlB,qBAAqB,oBAAoB,MAAM,UAA8C;AAAA,EAC3F,OAAO,eAAe;AAAA,IACpB,SAAS,MAAM;AAAA,IAAC;AAAA,EAClB;AAAA,EAEA,YAAY,OAAyB;AACnC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,SAAS;AAAA,MACT,OAAO,MAAM,SAAS;AAAA,IACxB;AAAA,EACF;AAAA,EAEA,OAAO,yBAAyB,OAAyB,OAAyB;AAChF,QAAI,CAAC,MAAM,SAAS;AAClB,aAAO;AAAA,QACL,OAAO,MAAM;AAAA,MACf;AAAA,IACF;AACA,WAAO,CAAC;AAAA,EACV;AAAA,EAEA,SAAS;AACP,QAAI;AACJ,QAAI;AAEJ,QAAG,KAAK,MAAM,OAAO;AACnB,YAAM;AACN,gBAAU;AAAA,QACR;AAAA,QACA;AAAA,MACF;AAAA,IACF,OACK;AACH,YAAM;AACN,gBAAU;AAAA,QACR;AAAA,MACF;AAAA,IACF;AAEA,QAAG,KAAK,MAAM,UAAU;AACtB,cAAQ,KAAK,2BAA2B;AAAA,IAC1C;AAEA,WAAO,MAAM,cAAc,KAAK;AAAA,MAC9B,cAAc,KAAK,MAAM,YAAY;AAAA,MACrC,eAAe,KAAK,MAAM,aAAa;AAAA,MACvC,YAAY,OAAO,UAAU,eAAe,KAAK,KAAK,OAAO,YAAY,IAAI,KAAK,MAAM,aAAa,EAAE,QAAQ;AAAA,MAC/G,UAAU,KAAK,MAAM;AAAA,MACrB,WAAW,QAAQ,KAAK,GAAG;AAAA,MAC3B,OAAO,KAAK,MAAM;AAAA,MAClB,OAAO,KAAK,MAAM,UAAU,SAAY,KAAK,KAAK,MAAM;AAAA,MACxD,aAAa,KAAK,MAAM;AAAA,MACxB,OAAO,KAAK,MAAM;AAAA,MAClB,UAAU,CAAC,MAA2E;AACpF,aAAK,SAAS;AAAA,UACZ,SAAS;AAAA,UACT,OAAO,EAAE,OAAO;AAAA,QAClB,GAAG,MAAM;AACP,cAAI,KAAK,MAAM;AAAS,iBAAK,MAAM,QAAQ,KAAK,MAAM,KAAK;AAAA,QAC7D,CAAC;AAAA,MACH;AAAA,MACA,QAAQ,MAAM;AACZ,YAAG,KAAK,MAAM,UAAQ,KAAK,MAAM,OAAO;AACtC,eAAK,SAAS,EAAC,SAAS,MAAK,CAAC;AAC9B,cAAI,KAAK,MAAM;AAAU,iBAAK,MAAM,SAAS,KAAK,MAAM,KAAK;AAAA,QAC/D;AAAA,MACF;AAAA,MACA,WAAW,CAAC,MAAM;AAChB,YAAI,EAAE,YAAY,MAAM,KAAK,MAAM,UAAU;AAC3C,eAAK,MAAM,SAAS,KAAK,MAAM,KAAK;AAAA,QACtC;AAAA,MACF;AAAA,MACA,UAAU,KAAK,MAAM;AAAA,IACvB,CAAC;AAAA,EACH;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"7edd0434d5570710fce0bf88d87716b3e75434c4"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Jr=function(){return s},s}Jr();class Sd extends bn.Component{constructor(n){Jr().f[1]++,Jr().s[1]++,super(n),Jr().s[2]++,this.state={editing:!1,value:(Jr().b[0][0]++,n.value||(Jr().b[0][1]++,""))}}static getDerivedStateFromProps(n,t){if(Jr().f[2]++,Jr().s[3]++,t.editing)Jr().b[1][1]++;else return Jr().b[1][0]++,Jr().s[4]++,{value:n.value};return Jr().s[5]++,{}}render(){Jr().f[3]++;let n,t;return Jr().s[6]++,this.props.multi?(Jr().b[2][0]++,Jr().s[7]++,n="textarea",Jr().s[8]++,t=["maputnik-string","maputnik-string--multi"]):(Jr().b[2][1]++,Jr().s[9]++,n="input",Jr().s[10]++,t=["maputnik-string"]),Jr().s[11]++,this.props.disabled?(Jr().b[3][0]++,Jr().s[12]++,t.push("maputnik-string--disabled")):Jr().b[3][1]++,Jr().s[13]++,bn.createElement(n,{"aria-label":this.props["aria-label"],"data-wd-key":this.props["data-wd-key"],spellCheck:Object.prototype.hasOwnProperty.call(this.props,"spellCheck")?(Jr().b[4][0]++,this.props.spellCheck):(Jr().b[4][1]++,n!=="input"),disabled:this.props.disabled,className:t.join(" "),style:this.props.style,value:this.state.value===void 0?(Jr().b[5][0]++,""):(Jr().b[5][1]++,this.state.value),placeholder:this.props.default,title:this.props.title,onChange:r=>{Jr().f[4]++,Jr().s[14]++,this.setState({editing:!0,value:r.target.value},()=>{Jr().f[5]++,Jr().s[15]++,this.props.onInput?(Jr().b[6][0]++,Jr().s[16]++,this.props.onInput(this.state.value)):Jr().b[6][1]++})},onBlur:()=>{Jr().f[6]++,Jr().s[17]++,this.state.value!==this.props.value?(Jr().b[7][0]++,Jr().s[18]++,this.setState({editing:!1}),Jr().s[19]++,this.props.onChange?(Jr().b[8][0]++,Jr().s[20]++,this.props.onChange(this.state.value)):Jr().b[8][1]++):Jr().b[7][1]++},onKeyDown:r=>{Jr().f[7]++,Jr().s[21]++,Jr().b[10][0]++,r.keyCode===13&&(Jr().b[10][1]++,this.props.onChange)?(Jr().b[9][0]++,Jr().s[22]++,this.props.onChange(this.state.value)):Jr().b[9][1]++},required:this.props.required})}}nn(Sd,"defaultProps",(Jr().s[0]++,{onInput:()=>{Jr().f[0]++}}));function m3(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldString.tsx",n="37d7b9547efb8875177dbe7a186e7965cd9eb1c0",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldString.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:163}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldString.tsx"],names:[],mappings:"AAeM;AAfN,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,iBAAqC;AAU5C,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,SAAS;AACP,WAAO,oBAAC,SAAM,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WAC3D,8BAAC,eAAa,GAAG,KAAK,OAAO,GAC/B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"37d7b9547efb8875177dbe7a186e7965cd9eb1c0"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return m3=function(){return s},s}m3();class uh extends bn.Component{render(){return m3().f[0]++,m3().s[0]++,N.jsx(Uo,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx(Sd,{...this.props})})}}function ni(){var e="/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlFeaturePropertyPopup.tsx",n="50b90fa9d7d9eff2534e1385cb335e5d5d551a9d",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlFeaturePropertyPopup.tsx",statementMap:{0:{start:{line:6,column:2},end:{line:7,column:17}},1:{start:{line:7,column:4},end:{line:7,column:17}},2:{start:{line:8,column:2},end:{line:9,column:34}},3:{start:{line:9,column:4},end:{line:9,column:34}},4:{start:{line:10,column:2},end:{line:11,column:28}},5:{start:{line:11,column:4},end:{line:11,column:28}},6:{start:{line:12,column:2},end:{line:12,column:15}},7:{start:{line:15,column:2},end:{line:18,column:5}},8:{start:{line:16,column:21},end:{line:16,column:53}},9:{start:{line:17,column:4},end:{line:17,column:199}},10:{start:{line:21,column:2},end:{line:21,column:199}},11:{start:{line:24,column:2},end:{line:37,column:40}},12:{start:{line:40,column:25},end:{line:40,column:27}},13:{start:{line:41,column:2},end:{line:54,column:5}},14:{start:{line:42,column:25},end:{line:44,column:6}},15:{start:{line:43,column:6},end:{line:43,column:156}},16:{start:{line:45,column:4},end:{line:53,column:5}},17:{start:{line:46,column:6},end:{line:46,column:35}},18:{start:{line:48,column:6},end:{line:52,column:7}},19:{start:{line:49,column:8},end:{line:49,column:58}},20:{start:{line:51,column:8},end:{line:51,column:60}},21:{start:{line:55,column:2},end:{line:55,column:24}},22:{start:{line:59,column:21},end:{line:59,column:66}},23:{start:{line:60,column:4},end:{line:60,column:127}}},fnMap:{0:{name:"displayValue",decl:{start:{line:5,column:9},end:{line:5,column:21}},loc:{start:{line:5,column:29},end:{line:13,column:1}},line:5},1:{name:"renderProperties",decl:{start:{line:14,column:9},end:{line:14,column:25}},loc:{start:{line:14,column:35},end:{line:19,column:1}},line:14},2:{name:"(anonymous_2)",decl:{start:{line:15,column:45},end:{line:15,column:46}},loc:{start:{line:15,column:63},end:{line:18,column:3}},line:15},3:{name:"renderFeatureId",decl:{start:{line:20,column:9},end:{line:20,column:24}},loc:{start:{line:20,column:34},end:{line:22,column:1}},line:20},4:{name:"renderFeature",decl:{start:{line:23,column:9},end:{line:23,column:22}},loc:{start:{line:23,column:37},end:{line:38,column:1}},line:23},5:{name:"removeDuplicatedFeatures",decl:{start:{line:39,column:9},end:{line:39,column:33}},loc:{start:{line:39,column:44},end:{line:56,column:1}},line:39},6:{name:"(anonymous_6)",decl:{start:{line:41,column:19},end:{line:41,column:20}},loc:{start:{line:41,column:32},end:{line:54,column:3}},line:41},7:{name:"(anonymous_7)",decl:{start:{line:42,column:50},end:{line:42,column:51}},loc:{start:{line:42,column:64},end:{line:44,column:5}},line:42},8:{name:"(anonymous_8)",decl:{start:{line:58,column:2},end:{line:58,column:3}},loc:{start:{line:58,column:11},end:{line:61,column:3}},line:58}},branchMap:{0:{loc:{start:{line:6,column:2},end:{line:7,column:17}},type:"if",locations:[{start:{line:6,column:2},end:{line:7,column:17}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:6},1:{loc:{start:{line:6,column:6},end:{line:6,column:52}},type:"binary-expr",locations:[{start:{line:6,column:6},end:{line:6,column:34}},{start:{line:6,column:38},end:{line:6,column:52}}],line:6},2:{loc:{start:{line:8,column:2},end:{line:9,column:34}},type:"if",locations:[{start:{line:8,column:2},end:{line:9,column:34}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:8},3:{loc:{start:{line:10,column:2},end:{line:11,column:28}},type:"if",locations:[{start:{line:10,column:2},end:{line:11,column:28}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:10},4:{loc:{start:{line:10,column:6},end:{line:10,column:89}},type:"binary-expr",locations:[{start:{line:10,column:6},end:{line:10,column:31}},{start:{line:10,column:35},end:{line:10,column:60}},{start:{line:10,column:64},end:{line:10,column:89}}],line:10},5:{loc:{start:{line:29,column:6},end:{line:32,column:10}},type:"binary-expr",locations:[{start:{line:29,column:6},end:{line:29,column:32}},{start:{line:29,column:52},end:{line:32,column:10}}],line:29},6:{loc:{start:{line:43,column:13},end:{line:43,column:155}},type:"binary-expr",locations:[{start:{line:43,column:13},end:{line:43,column:77}},{start:{line:43,column:81},end:{line:43,column:155}}],line:43},7:{loc:{start:{line:45,column:4},end:{line:53,column:5}},type:"if",locations:[{start:{line:45,column:4},end:{line:53,column:5}},{start:{line:47,column:11},end:{line:53,column:5}}],line:45},8:{loc:{start:{line:48,column:6},end:{line:52,column:7}},type:"if",locations:[{start:{line:48,column:6},end:{line:52,column:7}},{start:{line:50,column:13},end:{line:52,column:7}}],line:48}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGlFeaturePropertyPopup.tsx"],names:[],mappings:"AA2BM,cAagI,YAbhI;AA3BN,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AAYxB,SAAS,aAAa,OAAwC;AAC5D,MAAI,OAAO,UAAU,eAAe,UAAU;AAAM,WAAO;AAC3D,MAAI,iBAAiB;AAAM,WAAO,MAAM,eAAe;AACvD,MAAI,OAAO,UAAU,YACb,OAAO,UAAU,YACjB,OAAO,UAAU;AAAU,WAAO,MAAM,SAAS;AACzD,SAAO;AACT;AAEA,SAAS,iBAAiB,SAAyB;AACjD,SAAO,OAAO,KAAK,QAAQ,UAAU,EAAE,IAAI,kBAAgB;AACzD,UAAM,WAAW,QAAQ,WAAW,YAAY;AAChD,WAAO,oBAAC,SAAyB,OAAO,cACtC,8BAAC,eAAY,OAAO,aAAa,QAAQ,GAAG,OAAO,EAAC,iBAAiB,cAAa,GAAE,KADnE,YAEnB;AAAA,EACF,CAAC;AACH;AAEA,SAAS,gBAAgB,SAAyB;AAChD,SAAO,oBAAC,SAAyB,OAAO,cACtC,8BAAC,eAAY,OAAO,aAAa,QAAQ,EAAE,GAAG,OAAO,EAAC,iBAAiB,cAAa,GAAG,KADtE,YAEnB;AACF;AAEA,SAAS,cAAc,SAAyB,KAAa;AAC3D,SAAO,qBAAC,SACN;AAAA,yBAAC,SAAI,WAAU,2BAA2B;AAAA,cAAQ,MAAM,QAAQ;AAAA,MAAE;AAAA,MAAG,QAAQ,MAAM,cAAc;AAAA,MAAG,QAAQ,sBAAsB,qBAAC,UAAK;AAAA;AAAA,QAAI,QAAQ;AAAA,SAAmB;AAAA,OAAQ;AAAA,IAC/K,oBAAC,SAA4B,OAAO,SAClC,8BAAC,eAAY,OAAO,QAAQ,SAAS,MAAM,OAAO,EAAC,iBAAiB,cAAa,GAAG,KAD1E,eAEZ;AAAA,IACC,gBAAgB,OAAO;AAAA,IACvB,iBAAiB,OAAO;AAAA,OANV,GAAG,QAAQ,WAAW,IAAI,GAAG,EAO9C;AACF;AAEA,SAAS,yBAAyB,UAA4B;AAC5D,QAAM,iBAAmC,CAAC;AAE1C,WAAS,QAAQ,aAAW;AAC1B,UAAM,eAAe,eAAe,UAAU,cAAY;AACxD,aAAO,QAAQ,MAAM,cAAc,MAAM,SAAS,MAAM,cAAc,KACjE,KAAK,UAAU,QAAQ,UAAU,MAAM,KAAK,UAAU,SAAS,UAAU;AAAA,IAChF,CAAC;AAED,QAAG,iBAAiB,IAAI;AACtB,qBAAe,KAAK,OAAO;AAAA,IAC7B,OAAO;AACL,UAAG,wBAAwB,eAAe,YAAY,GAAG;AACvD,uBAAe,YAAY,EAAE;AAAA,MAC/B,OAAO;AACL,uBAAe,YAAY,EAAE,qBAAqB;AAAA,MACpD;AAAA,IACF;AAAA,EACF,CAAC;AAED,SAAO;AACT;AAMA,MAAM,6BAA6B,MAAM,UAAqC;AAAA,EAC5E,SAAS;AACP,UAAM,WAAW,yBAAyB,KAAK,MAAM,QAAQ;AAC7D,WAAO,oBAAC,SAAI,WAAU,mCACnB,mBAAS,IAAI,aAAa,GAC7B;AAAA,EACF;AACF;AAGA,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"50b90fa9d7d9eff2534e1385cb335e5d5d551a9d"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ni=function(){return s},s}ni();function XR(e){return ni().f[0]++,ni().s[0]++,ni().b[1][0]++,typeof e>"u"||(ni().b[1][1]++,e===null)?(ni().b[0][0]++,ni().s[1]++,e):(ni().b[0][1]++,ni().s[2]++,e instanceof Date?(ni().b[2][0]++,ni().s[3]++,e.toLocaleString()):(ni().b[2][1]++,ni().s[4]++,ni().b[4][0]++,typeof e=="object"||(ni().b[4][1]++,typeof e=="number")||(ni().b[4][2]++,typeof e=="string")?(ni().b[3][0]++,ni().s[5]++,e.toString()):(ni().b[3][1]++,ni().s[6]++,e)))}function KJ(e){return ni().f[1]++,ni().s[7]++,Object.keys(e.properties).map(n=>{ni().f[2]++;const t=(ni().s[8]++,e.properties[n]);return ni().s[9]++,N.jsx(Uo,{label:n,children:N.jsx(uh,{value:XR(t),style:{backgroundColor:"transparent"}})},n)})}function PJ(e){return ni().f[3]++,ni().s[10]++,N.jsx(Uo,{label:"feature_id",children:N.jsx(uh,{value:XR(e.id),style:{backgroundColor:"transparent"}})},"feature-id")}function FJ(e,n){return ni().f[4]++,ni().s[11]++,N.jsxs("div",{children:[N.jsxs("div",{className:"maputnik-popup-layer-id",children:[e.layer.source,": ",e.layer["source-layer"],(ni().b[5][0]++,e.inspectModeCounter&&(ni().b[5][1]++,N.jsxs("span",{children:[" × ",e.inspectModeCounter]})))]}),N.jsx(Uo,{label:"$type",children:N.jsx(uh,{value:e.geometry.type,style:{backgroundColor:"transparent"}})},"property-type"),PJ(e),KJ(e)]},`${e.sourceLayer}-${n}`)}function DJ(e){ni().f[5]++;const n=(ni().s[12]++,[]);return ni().s[13]++,e.forEach(t=>{ni().f[6]++;const r=(ni().s[14]++,n.findIndex(i=>(ni().f[7]++,ni().s[15]++,ni().b[6][0]++,t.layer["source-layer"]===i.layer["source-layer"]&&(ni().b[6][1]++,JSON.stringify(t.properties)===JSON.stringify(i.properties)))));ni().s[16]++,r===-1?(ni().b[7][0]++,ni().s[17]++,n.push(t)):(ni().b[7][1]++,ni().s[18]++,"inspectModeCounter"in n[r]?(ni().b[8][0]++,ni().s[19]++,n[r].inspectModeCounter++):(ni().b[8][1]++,ni().s[20]++,n[r].inspectModeCounter=2))}),ni().s[21]++,n}class UJ extends bn.Component{render(){ni().f[8]++;const n=(ni().s[22]++,DJ(this.props.features));return ni().s[23]++,N.jsx("div",{className:"maputnik-feature-property-popup",children:n.map(FJ)})}}var JR={exports:{}},RJ={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},eL={exports:{}},LJ=function(n){return!n||typeof n=="string"?!1:n instanceof Array||Array.isArray(n)||n.length>=0&&(n.splice instanceof Function||Object.getOwnPropertyDescriptor(n,n.length-1)&&n.constructor.name!=="String")},zJ=LJ,jJ=Array.prototype.concat,WJ=Array.prototype.slice,e9=eL.exports=function(n){for(var t=[],r=0,i=n.length;r<i;r++){var o=n[r];zJ(o)?t=jJ.call(t,WJ.call(o)):t.push(o)}return t};e9.wrap=function(e){return function(){return e(e9(arguments))}};var NJ=eL.exports,BC=RJ,G_=NJ,tL=Object.hasOwnProperty,nL=Object.create(null);for(var oM in BC)tL.call(BC,oM)&&(nL[BC[oM]]=oM);var Uc=JR.exports={to:{},get:{}};Uc.get=function(e){var n=e.substring(0,3).toLowerCase(),t,r;switch(n){case"hsl":t=Uc.get.hsl(e),r="hsl";break;case"hwb":t=Uc.get.hwb(e),r="hwb";break;default:t=Uc.get.rgb(e),r="rgb";break}return t?{model:r,value:t}:null};Uc.get.rgb=function(e){if(!e)return null;var n=/^#([a-f0-9]{3,4})$/i,t=/^#([a-f0-9]{6})([a-f0-9]{2})?$/i,r=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,i=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,o=/^(\w+)$/,s=[0,0,0,1],a,f,g;if(a=e.match(t)){for(g=a[2],a=a[1],f=0;f<3;f++){var x=f*2;s[f]=parseInt(a.slice(x,x+2),16)}g&&(s[3]=parseInt(g,16)/255)}else if(a=e.match(n)){for(a=a[1],g=a[3],f=0;f<3;f++)s[f]=parseInt(a[f]+a[f],16);g&&(s[3]=parseInt(g+g,16)/255)}else if(a=e.match(r)){for(f=0;f<3;f++)s[f]=parseInt(a[f+1],0);a[4]&&(a[5]?s[3]=parseFloat(a[4])*.01:s[3]=parseFloat(a[4]))}else if(a=e.match(i)){for(f=0;f<3;f++)s[f]=Math.round(parseFloat(a[f+1])*2.55);a[4]&&(a[5]?s[3]=parseFloat(a[4])*.01:s[3]=parseFloat(a[4]))}else return(a=e.match(o))?a[1]==="transparent"?[0,0,0,0]:tL.call(BC,a[1])?(s=BC[a[1]],s[3]=1,s):null:null;for(f=0;f<3;f++)s[f]=Sm(s[f],0,255);return s[3]=Sm(s[3],0,1),s};Uc.get.hsl=function(e){if(!e)return null;var n=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,t=e.match(n);if(t){var r=parseFloat(t[4]),i=(parseFloat(t[1])%360+360)%360,o=Sm(parseFloat(t[2]),0,100),s=Sm(parseFloat(t[3]),0,100),a=Sm(isNaN(r)?1:r,0,1);return[i,o,s,a]}return null};Uc.get.hwb=function(e){if(!e)return null;var n=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,t=e.match(n);if(t){var r=parseFloat(t[4]),i=(parseFloat(t[1])%360+360)%360,o=Sm(parseFloat(t[2]),0,100),s=Sm(parseFloat(t[3]),0,100),a=Sm(isNaN(r)?1:r,0,1);return[i,o,s,a]}return null};Uc.to.hex=function(){var e=G_(arguments);return"#"+gx(e[0])+gx(e[1])+gx(e[2])+(e[3]<1?gx(Math.round(e[3]*255)):"")};Uc.to.rgb=function(){var e=G_(arguments);return e.length<4||e[3]===1?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"};Uc.to.rgb.percent=function(){var e=G_(arguments),n=Math.round(e[0]/255*100),t=Math.round(e[1]/255*100),r=Math.round(e[2]/255*100);return e.length<4||e[3]===1?"rgb("+n+"%, "+t+"%, "+r+"%)":"rgba("+n+"%, "+t+"%, "+r+"%, "+e[3]+")"};Uc.to.hsl=function(){var e=G_(arguments);return e.length<4||e[3]===1?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"};Uc.to.hwb=function(){var e=G_(arguments),n="";return e.length>=4&&e[3]!==1&&(n=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+n+")"};Uc.to.keyword=function(e){return nL[e.slice(0,3)]};function Sm(e,n,t){return Math.min(Math.max(n,e),t)}function gx(e){var n=Math.round(e).toString(16).toUpperCase();return n.length<2?"0"+n:n}var GJ=JR.exports,QJ={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};const s_=QJ,rL={};for(const e of Object.keys(s_))rL[s_[e]]=e;const Nr={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};var iL=Nr;for(const e of Object.keys(Nr)){if(!("channels"in Nr[e]))throw new Error("missing channels property: "+e);if(!("labels"in Nr[e]))throw new Error("missing channel labels property: "+e);if(Nr[e].labels.length!==Nr[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:n,labels:t}=Nr[e];delete Nr[e].channels,delete Nr[e].labels,Object.defineProperty(Nr[e],"channels",{value:n}),Object.defineProperty(Nr[e],"labels",{value:t})}Nr.rgb.hsl=function(e){const n=e[0]/255,t=e[1]/255,r=e[2]/255,i=Math.min(n,t,r),o=Math.max(n,t,r),s=o-i;let a,f;o===i?a=0:n===o?a=(t-r)/s:t===o?a=2+(r-n)/s:r===o&&(a=4+(n-t)/s),a=Math.min(a*60,360),a<0&&(a+=360);const g=(i+o)/2;return o===i?f=0:g<=.5?f=s/(o+i):f=s/(2-o-i),[a,f*100,g*100]};Nr.rgb.hsv=function(e){let n,t,r,i,o;const s=e[0]/255,a=e[1]/255,f=e[2]/255,g=Math.max(s,a,f),x=g-Math.min(s,a,f),k=function(B){return(g-B)/6/x+1/2};return x===0?(i=0,o=0):(o=x/g,n=k(s),t=k(a),r=k(f),s===g?i=r-t:a===g?i=1/3+n-r:f===g&&(i=2/3+t-n),i<0?i+=1:i>1&&(i-=1)),[i*360,o*100,g*100]};Nr.rgb.hwb=function(e){const n=e[0],t=e[1];let r=e[2];const i=Nr.rgb.hsl(e)[0],o=1/255*Math.min(n,Math.min(t,r));return r=1-1/255*Math.max(n,Math.max(t,r)),[i,o*100,r*100]};Nr.rgb.cmyk=function(e){const n=e[0]/255,t=e[1]/255,r=e[2]/255,i=Math.min(1-n,1-t,1-r),o=(1-n-i)/(1-i)||0,s=(1-t-i)/(1-i)||0,a=(1-r-i)/(1-i)||0;return[o*100,s*100,a*100,i*100]};function $J(e,n){return(e[0]-n[0])**2+(e[1]-n[1])**2+(e[2]-n[2])**2}Nr.rgb.keyword=function(e){const n=rL[e];if(n)return n;let t=1/0,r;for(const i of Object.keys(s_)){const o=s_[i],s=$J(e,o);s<t&&(t=s,r=i)}return r};Nr.keyword.rgb=function(e){return s_[e]};Nr.rgb.xyz=function(e){let n=e[0]/255,t=e[1]/255,r=e[2]/255;n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;const i=n*.4124+t*.3576+r*.1805,o=n*.2126+t*.7152+r*.0722,s=n*.0193+t*.1192+r*.9505;return[i*100,o*100,s*100]};Nr.rgb.lab=function(e){const n=Nr.rgb.xyz(e);let t=n[0],r=n[1],i=n[2];t/=95.047,r/=100,i/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;const o=116*r-16,s=500*(t-r),a=200*(r-i);return[o,s,a]};Nr.hsl.rgb=function(e){const n=e[0]/360,t=e[1]/100,r=e[2]/100;let i,o,s;if(t===0)return s=r*255,[s,s,s];r<.5?i=r*(1+t):i=r+t-r*t;const a=2*r-i,f=[0,0,0];for(let g=0;g<3;g++)o=n+1/3*-(g-1),o<0&&o++,o>1&&o--,6*o<1?s=a+(i-a)*6*o:2*o<1?s=i:3*o<2?s=a+(i-a)*(2/3-o)*6:s=a,f[g]=s*255;return f};Nr.hsl.hsv=function(e){const n=e[0];let t=e[1]/100,r=e[2]/100,i=t;const o=Math.max(r,.01);r*=2,t*=r<=1?r:2-r,i*=o<=1?o:2-o;const s=(r+t)/2,a=r===0?2*i/(o+i):2*t/(r+t);return[n,a*100,s*100]};Nr.hsv.rgb=function(e){const n=e[0]/60,t=e[1]/100;let r=e[2]/100;const i=Math.floor(n)%6,o=n-Math.floor(n),s=255*r*(1-t),a=255*r*(1-t*o),f=255*r*(1-t*(1-o));switch(r*=255,i){case 0:return[r,f,s];case 1:return[a,r,s];case 2:return[s,r,f];case 3:return[s,a,r];case 4:return[f,s,r];case 5:return[r,s,a]}};Nr.hsv.hsl=function(e){const n=e[0],t=e[1]/100,r=e[2]/100,i=Math.max(r,.01);let o,s;s=(2-t)*r;const a=(2-t)*i;return o=t*i,o/=a<=1?a:2-a,o=o||0,s/=2,[n,o*100,s*100]};Nr.hwb.rgb=function(e){const n=e[0]/360;let t=e[1]/100,r=e[2]/100;const i=t+r;let o;i>1&&(t/=i,r/=i);const s=Math.floor(6*n),a=1-r;o=6*n-s,s&1&&(o=1-o);const f=t+o*(a-t);let g,x,k;switch(s){default:case 6:case 0:g=a,x=f,k=t;break;case 1:g=f,x=a,k=t;break;case 2:g=t,x=a,k=f;break;case 3:g=t,x=f,k=a;break;case 4:g=f,x=t,k=a;break;case 5:g=a,x=t,k=f;break}return[g*255,x*255,k*255]};Nr.cmyk.rgb=function(e){const n=e[0]/100,t=e[1]/100,r=e[2]/100,i=e[3]/100,o=1-Math.min(1,n*(1-i)+i),s=1-Math.min(1,t*(1-i)+i),a=1-Math.min(1,r*(1-i)+i);return[o*255,s*255,a*255]};Nr.xyz.rgb=function(e){const n=e[0]/100,t=e[1]/100,r=e[2]/100;let i,o,s;return i=n*3.2406+t*-1.5372+r*-.4986,o=n*-.9689+t*1.8758+r*.0415,s=n*.0557+t*-.204+r*1.057,i=i>.0031308?1.055*i**(1/2.4)-.055:i*12.92,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,i=Math.min(Math.max(0,i),1),o=Math.min(Math.max(0,o),1),s=Math.min(Math.max(0,s),1),[i*255,o*255,s*255]};Nr.xyz.lab=function(e){let n=e[0],t=e[1],r=e[2];n/=95.047,t/=100,r/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,t=t>.008856?t**(1/3):7.787*t+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;const i=116*t-16,o=500*(n-t),s=200*(t-r);return[i,o,s]};Nr.lab.xyz=function(e){const n=e[0],t=e[1],r=e[2];let i,o,s;o=(n+16)/116,i=t/500+o,s=o-r/200;const a=o**3,f=i**3,g=s**3;return o=a>.008856?a:(o-16/116)/7.787,i=f>.008856?f:(i-16/116)/7.787,s=g>.008856?g:(s-16/116)/7.787,i*=95.047,o*=100,s*=108.883,[i,o,s]};Nr.lab.lch=function(e){const n=e[0],t=e[1],r=e[2];let i;i=Math.atan2(r,t)*360/2/Math.PI,i<0&&(i+=360);const s=Math.sqrt(t*t+r*r);return[n,s,i]};Nr.lch.lab=function(e){const n=e[0],t=e[1],i=e[2]/360*2*Math.PI,o=t*Math.cos(i),s=t*Math.sin(i);return[n,o,s]};Nr.rgb.ansi16=function(e,n=null){const[t,r,i]=e;let o=n===null?Nr.rgb.hsv(e)[2]:n;if(o=Math.round(o/50),o===0)return 30;let s=30+(Math.round(i/255)<<2|Math.round(r/255)<<1|Math.round(t/255));return o===2&&(s+=60),s};Nr.hsv.ansi16=function(e){return Nr.rgb.ansi16(Nr.hsv.rgb(e),e[2])};Nr.rgb.ansi256=function(e){const n=e[0],t=e[1],r=e[2];return n===t&&t===r?n<8?16:n>248?231:Math.round((n-8)/247*24)+232:16+36*Math.round(n/255*5)+6*Math.round(t/255*5)+Math.round(r/255*5)};Nr.ansi16.rgb=function(e){let n=e%10;if(n===0||n===7)return e>50&&(n+=3.5),n=n/10.5*255,[n,n,n];const t=(~~(e>50)+1)*.5,r=(n&1)*t*255,i=(n>>1&1)*t*255,o=(n>>2&1)*t*255;return[r,i,o]};Nr.ansi256.rgb=function(e){if(e>=232){const o=(e-232)*10+8;return[o,o,o]}e-=16;let n;const t=Math.floor(e/36)/5*255,r=Math.floor((n=e%36)/6)/5*255,i=n%6/5*255;return[t,r,i]};Nr.rgb.hex=function(e){const t=(((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255)).toString(16).toUpperCase();return"000000".substring(t.length)+t};Nr.hex.rgb=function(e){const n=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!n)return[0,0,0];let t=n[0];n[0].length===3&&(t=t.split("").map(a=>a+a).join(""));const r=parseInt(t,16),i=r>>16&255,o=r>>8&255,s=r&255;return[i,o,s]};Nr.rgb.hcg=function(e){const n=e[0]/255,t=e[1]/255,r=e[2]/255,i=Math.max(Math.max(n,t),r),o=Math.min(Math.min(n,t),r),s=i-o;let a,f;return s<1?a=o/(1-s):a=0,s<=0?f=0:i===n?f=(t-r)/s%6:i===t?f=2+(r-n)/s:f=4+(n-t)/s,f/=6,f%=1,[f*360,s*100,a*100]};Nr.hsl.hcg=function(e){const n=e[1]/100,t=e[2]/100,r=t<.5?2*n*t:2*n*(1-t);let i=0;return r<1&&(i=(t-.5*r)/(1-r)),[e[0],r*100,i*100]};Nr.hsv.hcg=function(e){const n=e[1]/100,t=e[2]/100,r=n*t;let i=0;return r<1&&(i=(t-r)/(1-r)),[e[0],r*100,i*100]};Nr.hcg.rgb=function(e){const n=e[0]/360,t=e[1]/100,r=e[2]/100;if(t===0)return[r*255,r*255,r*255];const i=[0,0,0],o=n%1*6,s=o%1,a=1-s;let f=0;switch(Math.floor(o)){case 0:i[0]=1,i[1]=s,i[2]=0;break;case 1:i[0]=a,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=s;break;case 3:i[0]=0,i[1]=a,i[2]=1;break;case 4:i[0]=s,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=a}return f=(1-t)*r,[(t*i[0]+f)*255,(t*i[1]+f)*255,(t*i[2]+f)*255]};Nr.hcg.hsv=function(e){const n=e[1]/100,t=e[2]/100,r=n+t*(1-n);let i=0;return r>0&&(i=n/r),[e[0],i*100,r*100]};Nr.hcg.hsl=function(e){const n=e[1]/100,r=e[2]/100*(1-n)+.5*n;let i=0;return r>0&&r<.5?i=n/(2*r):r>=.5&&r<1&&(i=n/(2*(1-r))),[e[0],i*100,r*100]};Nr.hcg.hwb=function(e){const n=e[1]/100,t=e[2]/100,r=n+t*(1-n);return[e[0],(r-n)*100,(1-r)*100]};Nr.hwb.hcg=function(e){const n=e[1]/100,r=1-e[2]/100,i=r-n;let o=0;return i<1&&(o=(r-i)/(1-i)),[e[0],i*100,o*100]};Nr.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};Nr.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};Nr.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};Nr.gray.hsl=function(e){return[0,0,e[0]]};Nr.gray.hsv=Nr.gray.hsl;Nr.gray.hwb=function(e){return[0,100,e[0]]};Nr.gray.cmyk=function(e){return[0,0,0,e[0]]};Nr.gray.lab=function(e){return[e[0],0,0]};Nr.gray.hex=function(e){const n=Math.round(e[0]/100*255)&255,r=((n<<16)+(n<<8)+n).toString(16).toUpperCase();return"000000".substring(r.length)+r};Nr.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]};const g3=iL;function YJ(){const e={},n=Object.keys(g3);for(let t=n.length,r=0;r<t;r++)e[n[r]]={distance:-1,parent:null};return e}function qJ(e){const n=YJ(),t=[e];for(n[e].distance=0;t.length;){const r=t.pop(),i=Object.keys(g3[r]);for(let o=i.length,s=0;s<o;s++){const a=i[s],f=n[a];f.distance===-1&&(f.distance=n[r].distance+1,f.parent=r,t.unshift(a))}}return n}function VJ(e,n){return function(t){return n(e(t))}}function HJ(e,n){const t=[n[e].parent,e];let r=g3[n[e].parent][e],i=n[e].parent;for(;n[i].parent;)t.unshift(n[i].parent),r=VJ(g3[n[i].parent][i],r),i=n[i].parent;return r.conversion=t,r}var ZJ=function(e){const n=qJ(e),t={},r=Object.keys(n);for(let i=r.length,o=0;o<i;o++){const s=r[o];n[s].parent!==null&&(t[s]=HJ(s,n))}return t};const K6=iL,XJ=ZJ,vg={},JJ=Object.keys(K6);function eee(e){const n=function(...t){const r=t[0];return r==null?r:(r.length>1&&(t=r),e(t))};return"conversion"in e&&(n.conversion=e.conversion),n}function tee(e){const n=function(...t){const r=t[0];if(r==null)return r;r.length>1&&(t=r);const i=e(t);if(typeof i=="object")for(let o=i.length,s=0;s<o;s++)i[s]=Math.round(i[s]);return i};return"conversion"in e&&(n.conversion=e.conversion),n}JJ.forEach(e=>{vg[e]={},Object.defineProperty(vg[e],"channels",{value:K6[e].channels}),Object.defineProperty(vg[e],"labels",{value:K6[e].labels});const n=XJ(e);Object.keys(n).forEach(r=>{const i=n[r];vg[e][r]=tee(i),vg[e][r].raw=eee(i)})});var nee=vg;const Cg=GJ,Fc=nee,oL=["keyword","gray","hex"],P6={};for(const e of Object.keys(Fc))P6[[...Fc[e].labels].sort().join("")]=e;const y3={};function ou(e,n){if(!(this instanceof ou))return new ou(e,n);if(n&&n in oL&&(n=null),n&&!(n in Fc))throw new Error("Unknown model: "+n);let t,r;if(e==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof ou)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if(typeof e=="string"){const i=Cg.get(e);if(i===null)throw new Error("Unable to parse color from string: "+e);this.model=i.model,r=Fc[this.model].channels,this.color=i.value.slice(0,r),this.valpha=typeof i.value[r]=="number"?i.value[r]:1}else if(e.length>0){this.model=n||"rgb",r=Fc[this.model].channels;const i=Array.prototype.slice.call(e,0,r);this.color=F6(i,r),this.valpha=typeof e[r]=="number"?e[r]:1}else if(typeof e=="number")this.model="rgb",this.color=[e>>16&255,e>>8&255,e&255],this.valpha=1;else{this.valpha=1;const i=Object.keys(e);"alpha"in e&&(i.splice(i.indexOf("alpha"),1),this.valpha=typeof e.alpha=="number"?e.alpha:0);const o=i.sort().join("");if(!(o in P6))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=P6[o];const{labels:s}=Fc[this.model],a=[];for(t=0;t<s.length;t++)a.push(e[s[t]]);this.color=F6(a)}if(y3[this.model])for(r=Fc[this.model].channels,t=0;t<r;t++){const i=y3[this.model][t];i&&(this.color[t]=i(this.color[t]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}ou.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let n=this.model in Cg.to?this:this.rgb();n=n.round(typeof e=="number"?e:1);const t=n.valpha===1?n.color:[...n.color,this.valpha];return Cg.to[n.model](t)},percentString(e){const n=this.rgb().round(typeof e=="number"?e:1),t=n.valpha===1?n.color:[...n.color,this.valpha];return Cg.to.rgb.percent(t)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){const e={},{channels:n}=Fc[this.model],{labels:t}=Fc[this.model];for(let r=0;r<n;r++)e[t[r]]=this.color[r];return this.valpha!==1&&(e.alpha=this.valpha),e},unitArray(){const e=this.rgb().color;return e[0]/=255,e[1]/=255,e[2]/=255,this.valpha!==1&&e.push(this.valpha),e},unitObject(){const e=this.rgb().object();return e.r/=255,e.g/=255,e.b/=255,this.valpha!==1&&(e.alpha=this.valpha),e},round(e){return e=Math.max(e||0,0),new ou([...this.color.map(iee(e)),this.valpha],this.model)},alpha(e){return e!==void 0?new ou([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:Ws("rgb",0,Rl(255)),green:Ws("rgb",1,Rl(255)),blue:Ws("rgb",2,Rl(255)),hue:Ws(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:Ws("hsl",1,Rl(100)),lightness:Ws("hsl",2,Rl(100)),saturationv:Ws("hsv",1,Rl(100)),value:Ws("hsv",2,Rl(100)),chroma:Ws("hcg",1,Rl(100)),gray:Ws("hcg",2,Rl(100)),white:Ws("hwb",1,Rl(100)),wblack:Ws("hwb",2,Rl(100)),cyan:Ws("cmyk",0,Rl(100)),magenta:Ws("cmyk",1,Rl(100)),yellow:Ws("cmyk",2,Rl(100)),black:Ws("cmyk",3,Rl(100)),x:Ws("xyz",0,Rl(95.047)),y:Ws("xyz",1,Rl(100)),z:Ws("xyz",2,Rl(108.833)),l:Ws("lab",0,Rl(100)),a:Ws("lab",1),b:Ws("lab",2),keyword(e){return e!==void 0?new ou(e):Fc[this.model].keyword(this.color)},hex(e){return e!==void 0?new ou(e):Cg.to.hex(this.rgb().round().color)},hexa(e){if(e!==void 0)return new ou(e);const n=this.rgb().round().color;let t=Math.round(this.valpha*255).toString(16).toUpperCase();return t.length===1&&(t="0"+t),Cg.to.hex(n)+t},rgbNumber(){const e=this.rgb().color;return(e[0]&255)<<16|(e[1]&255)<<8|e[2]&255},luminosity(){const e=this.rgb().color,n=[];for(const[t,r]of e.entries()){const i=r/255;n[t]=i<=.04045?i/12.92:((i+.055)/1.055)**2.4}return .2126*n[0]+.7152*n[1]+.0722*n[2]},contrast(e){const n=this.luminosity(),t=e.luminosity();return n>t?(n+.05)/(t+.05):(t+.05)/(n+.05)},level(e){const n=this.contrast(e);return n>=7?"AAA":n>=4.5?"AA":""},isDark(){const e=this.rgb().color;return(e[0]*2126+e[1]*7152+e[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){const e=this.rgb();for(let n=0;n<3;n++)e.color[n]=255-e.color[n];return e},lighten(e){const n=this.hsl();return n.color[2]+=n.color[2]*e,n},darken(e){const n=this.hsl();return n.color[2]-=n.color[2]*e,n},saturate(e){const n=this.hsl();return n.color[1]+=n.color[1]*e,n},desaturate(e){const n=this.hsl();return n.color[1]-=n.color[1]*e,n},whiten(e){const n=this.hwb();return n.color[1]+=n.color[1]*e,n},blacken(e){const n=this.hwb();return n.color[2]+=n.color[2]*e,n},grayscale(){const e=this.rgb().color,n=e[0]*.3+e[1]*.59+e[2]*.11;return ou.rgb(n,n,n)},fade(e){return this.alpha(this.valpha-this.valpha*e)},opaquer(e){return this.alpha(this.valpha+this.valpha*e)},rotate(e){const n=this.hsl();let t=n.color[0];return t=(t+e)%360,t=t<0?360+t:t,n.color[0]=t,n},mix(e,n){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);const t=e.rgb(),r=this.rgb(),i=n===void 0?.5:n,o=2*i-1,s=t.alpha()-r.alpha(),a=((o*s===-1?o:(o+s)/(1+o*s))+1)/2,f=1-a;return ou.rgb(a*t.red()+f*r.red(),a*t.green()+f*r.green(),a*t.blue()+f*r.blue(),t.alpha()*i+r.alpha()*(1-i))}};for(const e of Object.keys(Fc)){if(oL.includes(e))continue;const{channels:n}=Fc[e];ou.prototype[e]=function(...t){return this.model===e?new ou(this):t.length>0?new ou(t,e):new ou([...oee(Fc[this.model][e].raw(this.color)),this.valpha],e)},ou[e]=function(...t){let r=t[0];return typeof r=="number"&&(r=F6(t,n)),new ou(r,e)}}function ree(e,n){return Number(e.toFixed(n))}function iee(e){return function(n){return ree(n,e)}}function Ws(e,n,t){e=Array.isArray(e)?e:[e];for(const r of e)(y3[r]||(y3[r]=[]))[n]=t;return e=e[0],function(r){let i;return r!==void 0?(t&&(r=t(r)),i=this[e](),i.color[n]=r,i):(i=this[e]().color[n],t&&(i=t(i)),i)}}function Rl(e){return function(n){return Math.max(0,Math.min(e,n))}}function oee(e){return Array.isArray(e)?e:[e]}function F6(e,n){for(let t=0;t<n;t++)typeof e[t]!="number"&&(e[t]=0);return e}var aee=ou;const D6=ga(aee);function da(){var e="/home/runner/work/maputnik/maputnik/src/libs/zoomcontrol.ts",n="bc6e1b88794b9d2c3dff41979be33bc1153f4814",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/zoomcontrol.ts",statementMap:{0:{start:{line:2,column:9},end:{line:2,column:15}},1:{start:{line:3,column:15},end:{line:3,column:21}},2:{start:{line:4,column:12},end:{line:4,column:16}},3:{start:{line:6,column:4},end:{line:6,column:20}},4:{start:{line:7,column:4},end:{line:7,column:52}},5:{start:{line:8,column:4},end:{line:8,column:93}},6:{start:{line:9,column:4},end:{line:9,column:70}},7:{start:{line:10,column:4},end:{line:12,column:6}},8:{start:{line:13,column:4},end:{line:13,column:57}},9:{start:{line:14,column:4},end:{line:14,column:29}},10:{start:{line:15,column:4},end:{line:15,column:27}},11:{start:{line:18,column:4},end:{line:18,column:60}},12:{start:{line:21,column:4},end:{line:21,column:57}},13:{start:{line:21,column:33},end:{line:21,column:55}},14:{start:{line:22,column:4},end:{line:22,column:57}},15:{start:{line:22,column:33},end:{line:22,column:55}},16:{start:{line:23,column:4},end:{line:23,column:58}},17:{start:{line:23,column:34},end:{line:23,column:56}},18:{start:{line:26,column:4},end:{line:26,column:60}},19:{start:{line:27,column:4},end:{line:27,column:23}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:13},end:{line:16,column:3}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:17,column:2},end:{line:17,column:3}},loc:{start:{line:17,column:20},end:{line:19,column:3}},line:17},2:{name:"(anonymous_2)",decl:{start:{line:20,column:2},end:{line:20,column:3}},loc:{start:{line:20,column:22},end:{line:24,column:3}},line:20},3:{name:"(anonymous_3)",decl:{start:{line:21,column:27},end:{line:21,column:28}},loc:{start:{line:21,column:33},end:{line:21,column:55}},line:21},4:{name:"(anonymous_4)",decl:{start:{line:22,column:27},end:{line:22,column:28}},loc:{start:{line:22,column:33},end:{line:22,column:55}},line:22},5:{name:"(anonymous_5)",decl:{start:{line:23,column:28},end:{line:23,column:29}},loc:{start:{line:23,column:34},end:{line:23,column:56}},line:23},6:{name:"(anonymous_6)",decl:{start:{line:25,column:2},end:{line:25,column:3}},loc:{start:{line:25,column:13},end:{line:28,column:3}},line:25}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/zoomcontrol.ts"],names:[],mappings:"AAEA,qBAAqB,YAAY;AAAA,EAC/B,OAAuB;AAAA,EACvB,aAAyC;AAAA,EACzC,UAAkC;AAAA,EAElC,MAAM,KAAU;AACd,SAAK,OAAO;AACZ,SAAK,aAAa,SAAS,cAAc,KAAK;AAC9C,SAAK,WAAW,YAAY;AAC5B,SAAK,WAAW,aAAa,eAAe,oBAAoB;AAChE,SAAK,WAAW,YAAY;AAAA;AAAA;AAG5B,SAAK,UAAU,KAAK,WAAW,cAAc,MAAM;AAEnD,SAAK,kBAAkB;AAEvB,WAAO,KAAK;AAAA,EACd;AAAA,EAEA,kBAAkB;AAChB,SAAK,QAAS,YAAY,KAAK,KAAM,QAAQ,EAAE,QAAQ,CAAC;AAAA,EAC1D;AAAA,EAEA,oBAAoB;AAClB,SAAK,KAAM,GAAG,UAAU,MAAM,KAAK,gBAAgB,CAAC;AACpD,SAAK,KAAM,GAAG,UAAU,MAAM,KAAK,gBAAgB,CAAC;AACpD,SAAK,KAAM,GAAG,WAAW,MAAM,KAAK,gBAAgB,CAAC;AAAA,EACvD;AAAA,EAEA,WAAW;AACT,SAAK,WAAY,WAAY,YAAY,KAAK,UAAW;AACzD,SAAK,OAAO;AAAA,EACd;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"bc6e1b88794b9d2c3dff41979be33bc1153f4814"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return da=function(){return s},s}da();class see{constructor(){nn(this,"_map",(da().s[0]++,void 0));nn(this,"_container",(da().s[1]++,void 0));nn(this,"_textEl",(da().s[2]++,null))}onAdd(n){return da().f[0]++,da().s[3]++,this._map=n,da().s[4]++,this._container=document.createElement("div"),da().s[5]++,this._container.className="maplibregl-ctrl maplibregl-ctrl-group maplibregl-ctrl-zoom",da().s[6]++,this._container.setAttribute("data-wd-key","maplibre:ctrl-zoom"),da().s[7]++,this._container.innerHTML=`
|
||
Zoom: <span></span>
|
||
`,da().s[8]++,this._textEl=this._container.querySelector("span"),da().s[9]++,this.addEventListeners(),da().s[10]++,this._container}updateZoomLevel(){da().f[1]++,da().s[11]++,this._textEl.innerHTML=this._map.getZoom().toFixed(2)}addEventListeners(){da().f[2]++,da().s[12]++,this._map.on("render",()=>(da().f[3]++,da().s[13]++,this.updateZoomLevel())),da().s[14]++,this._map.on("zoomIn",()=>(da().f[4]++,da().s[15]++,this.updateZoomLevel())),da().s[16]++,this._map.on("zoomOut",()=>(da().f[5]++,da().s[17]++,this.updateZoomLevel()))}onRemove(){da().f[6]++,da().s[18]++,this._container.parentNode.removeChild(this._container),da().s[19]++,this._map=void 0}}function xi(){var e="/home/runner/work/maputnik/maputnik/src/libs/highlight.ts",n="a1afd3a6454022c4d7be658acdbd4aecf51f38d3",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/highlight.ts",statementMap:{0:{start:{line:4,column:2},end:{line:8,column:3}},1:{start:{line:5,column:4},end:{line:5,column:33}},2:{start:{line:6,column:9},end:{line:8,column:3}},3:{start:{line:7,column:4},end:{line:7,column:30}},4:{start:{line:9,column:2},end:{line:13,column:3}},5:{start:{line:10,column:4},end:{line:10,column:28}},6:{start:{line:12,column:4},end:{line:12,column:23}},7:{start:{line:14,column:2},end:{line:14,column:29}},8:{start:{line:15,column:2},end:{line:15,column:11}},9:{start:{line:18,column:2},end:{line:19,column:16}},10:{start:{line:19,column:4},end:{line:19,column:16}},11:{start:{line:20,column:24},end:{line:20,column:51}},12:{start:{line:21,column:16},end:{line:21,column:52}},13:{start:{line:22,column:2},end:{line:24,column:3}},14:{start:{line:23,column:4},end:{line:23,column:104}},15:{start:{line:25,column:2},end:{line:27,column:3}},16:{start:{line:26,column:4},end:{line:26,column:96}},17:{start:{line:28,column:2},end:{line:30,column:3}},18:{start:{line:29,column:4},end:{line:29,column:94}},19:{start:{line:31,column:2},end:{line:31,column:14}}},fnMap:{0:{name:"changeLayer",decl:{start:{line:3,column:9},end:{line:3,column:20}},loc:{start:{line:3,column:31},end:{line:16,column:1}},line:3},1:{name:"colorHighlightedLayer",decl:{start:{line:17,column:16},end:{line:17,column:37}},loc:{start:{line:17,column:45},end:{line:32,column:1}},line:17}},branchMap:{0:{loc:{start:{line:4,column:2},end:{line:8,column:3}},type:"if",locations:[{start:{line:4,column:2},end:{line:8,column:3}},{start:{line:6,column:9},end:{line:8,column:3}}],line:4},1:{loc:{start:{line:6,column:9},end:{line:8,column:3}},type:"if",locations:[{start:{line:6,column:9},end:{line:8,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:6},2:{loc:{start:{line:9,column:2},end:{line:13,column:3}},type:"if",locations:[{start:{line:9,column:2},end:{line:13,column:3}},{start:{line:11,column:9},end:{line:13,column:3}}],line:9},3:{loc:{start:{line:18,column:2},end:{line:19,column:16}},type:"if",locations:[{start:{line:18,column:2},end:{line:19,column:16}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:18},4:{loc:{start:{line:18,column:6},end:{line:18,column:70}},type:"binary-expr",locations:[{start:{line:18,column:6},end:{line:18,column:12}},{start:{line:18,column:16},end:{line:18,column:43}},{start:{line:18,column:47},end:{line:18,column:70}}],line:18},5:{loc:{start:{line:20,column:24},end:{line:20,column:51}},type:"binary-expr",locations:[{start:{line:20,column:24},end:{line:20,column:45}},{start:{line:20,column:49},end:{line:20,column:51}}],line:20},6:{loc:{start:{line:22,column:2},end:{line:24,column:3}},type:"if",locations:[{start:{line:22,column:2},end:{line:24,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:22},7:{loc:{start:{line:22,column:6},end:{line:22,column:62}},type:"binary-expr",locations:[{start:{line:22,column:6},end:{line:22,column:27}},{start:{line:22,column:31},end:{line:22,column:62}}],line:22},8:{loc:{start:{line:25,column:2},end:{line:27,column:3}},type:"if",locations:[{start:{line:25,column:2},end:{line:27,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:25},9:{loc:{start:{line:25,column:6},end:{line:25,column:56}},type:"binary-expr",locations:[{start:{line:25,column:6},end:{line:25,column:29}},{start:{line:25,column:33},end:{line:25,column:56}}],line:25},10:{loc:{start:{line:28,column:2},end:{line:30,column:3}},type:"if",locations:[{start:{line:28,column:2},end:{line:30,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:28}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0},f:{0:0,1:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/highlight.ts"],names:[],mappings:"AACA,OAAO,cAAc;AAErB,OAAO,YAAY;AAKnB,SAAS,YAAY,GAAqB,OAA2B;AACnE,MAAG,EAAE,SAAS,UAAU;AACtB,MAAE,MAAO,eAAe,IAAI;AAAA,EAC9B,WAAU,EAAE,SAAS,QAAQ;AAC3B,MAAE,MAAO,YAAY,IAAI;AAAA,EAC3B;AAEA,MAAG,YAAY,OAAO;AACpB,MAAE,SAAS,MAAM;AAAA,EACnB,OAAO;AACL,WAAO,EAAE,QAAQ;AAAA,EACnB;AACA,IAAE,KAAK,EAAE,KAAK;AACd,SAAO;AACT;AAEO,gBAAS,sBAAsB,OAAqD;AACzF,MAAG,CAAC,SAAS,MAAM,SAAS,gBAAgB,MAAM,SAAS;AAAU,WAAO;AAE5E,QAAM,gBAAgB,MAAM,cAAc,KAAK;AAC/C,QAAM,QAAQ,OAAO,YAAY,eAAe,CAAC;AAEjD,MAAG,MAAM,SAAS,UAAU,MAAM,SAAS,kBAAkB;AAC3D,WAAO,YAAY,SAAS,aAAa,OAAO,OAAO,MAAM,QAAQ,MAAM,cAAc,CAAC,GAAG,KAAK;AAAA,EACpG;AAEA,MAAG,MAAM,SAAS,YAAY,MAAM,SAAS,UAAU;AACrD,WAAO,YAAY,SAAS,YAAY,OAAO,MAAM,QAAQ,MAAM,cAAc,CAAC,GAAG,KAAK;AAAA,EAC5F;AAEA,MAAG,MAAM,SAAS,QAAQ;AACxB,WAAO,YAAY,SAAS,UAAU,OAAO,MAAM,QAAQ,MAAM,cAAc,CAAC,GAAG,KAAK;AAAA,EAC1F;AAEA,SAAO;AACT;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a1afd3a6454022c4d7be658acdbd4aecf51f38d3"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return xi=function(){return s},s}xi();function aM(e,n){return xi().f[0]++,xi().s[0]++,e.type==="circle"?(xi().b[0][0]++,xi().s[1]++,e.paint["circle-radius"]=3):(xi().b[0][1]++,xi().s[2]++,e.type==="line"?(xi().b[1][0]++,xi().s[3]++,e.paint["line-width"]=2):xi().b[1][1]++),xi().s[4]++,"filter"in n?(xi().b[2][0]++,xi().s[5]++,e.filter=n.filter):(xi().b[2][1]++,xi().s[6]++,delete e.filter),xi().s[7]++,e.id=e.id+"_highlight",xi().s[8]++,e}function lee(e){if(xi().f[1]++,xi().s[9]++,xi().b[4][0]++,!e||(xi().b[4][1]++,e.type==="background")||(xi().b[4][2]++,e.type==="raster"))return xi().b[3][0]++,xi().s[10]++,null;xi().b[3][1]++;const n=(xi().s[11]++,xi().b[5][0]++,e["source-layer"]||(xi().b[5][1]++,"")),t=(xi().s[12]++,t5.brightColor(n,1));return xi().s[13]++,xi().b[7][0]++,e.type==="fill"||(xi().b[7][1]++,e.type==="fill-extrusion")?(xi().b[6][0]++,xi().s[14]++,aM(_p.polygonLayer(t,t,e.source,e["source-layer"]),e)):(xi().b[6][1]++,xi().s[15]++,xi().b[9][0]++,e.type==="symbol"||(xi().b[9][1]++,e.type==="circle")?(xi().b[8][0]++,xi().s[16]++,aM(_p.circleLayer(t,e.source,e["source-layer"]),e)):(xi().b[8][1]++,xi().s[17]++,e.type==="line"?(xi().b[10][0]++,xi().s[18]++,aM(_p.lineLayer(t,e.source,e["source-layer"]),e)):(xi().b[10][1]++,xi().s[19]++,null)))}function DB(){var e="/home/runner/work/maputnik/maputnik/src/libs/maplibre-rtl.ts",n="a9dc98f82c73787713de0672aff7a601bfeb069d",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/maplibre-rtl.ts",statementMap:{0:{start:{line:2,column:0},end:{line:2,column:115}}},fnMap:{},branchMap:{},s:{0:0},f:{},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/maplibre-rtl.ts"],names:[],mappings:"AAAA,OAAO,gBAAgB;AAEvB,WAAW,iBAAiB,gFAAgF,KAAK;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a9dc98f82c73787713de0672aff7a601bfeb069d"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return DB=function(){return s},s}DB();DB().s[0]++;g2.setRTLTextPlugin("https://unpkg.com/@mapbox/mapbox-gl-rtl-text@0.2.3/mapbox-gl-rtl-text.min.js",!1);function cn(){var e="/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGl.tsx",n="cf2170ca14c8f07639bb91af4dc600c4bb0a376c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGl.tsx",statementMap:{0:{start:{line:16,column:2},end:{line:16,column:36}},1:{start:{line:17,column:2},end:{line:17,column:19}},2:{start:{line:20,column:26},end:{line:26,column:3}},3:{start:{line:27,column:16},end:{line:27,column:55}},4:{start:{line:28,column:2},end:{line:30,column:3}},5:{start:{line:29,column:4},end:{line:29,column:30}},6:{start:{line:31,column:18},end:{line:31,column:20}},7:{start:{line:32,column:2},end:{line:37,column:5}},8:{start:{line:33,column:19},end:{line:33,column:53}},9:{start:{line:34,column:4},end:{line:36,column:5}},10:{start:{line:35,column:6},end:{line:35,column:33}},11:{start:{line:38,column:23},end:{line:42,column:3}},12:{start:{line:43,column:2},end:{line:43,column:22}},13:{start:{line:46,column:24},end:{line:56,column:3}},14:{start:{line:57,column:14},end:{line:57,column:18}},15:{start:{line:59,column:4},end:{line:59,column:17}},16:{start:{line:60,column:4},end:{line:63,column:6}},17:{start:{line:66,column:4},end:{line:67,column:13}},18:{start:{line:67,column:6},end:{line:67,column:13}},19:{start:{line:68,column:4},end:{line:71,column:6}},20:{start:{line:74,column:17},end:{line:74,column:22}},21:{start:{line:75,column:4},end:{line:78,column:5}},22:{start:{line:76,column:6},end:{line:76,column:132}},23:{start:{line:79,column:4},end:{line:79,column:18}},24:{start:{line:82,column:16},end:{line:82,column:30}},25:{start:{line:83,column:4},end:{line:83,column:40}},26:{start:{line:84,column:4},end:{line:87,column:5}},27:{start:{line:85,column:6},end:{line:85,column:47}},28:{start:{line:86,column:6},end:{line:86,column:43}},29:{start:{line:88,column:4},end:{line:99,column:5}},30:{start:{line:89,column:6},end:{line:95,column:7}},31:{start:{line:90,column:8},end:{line:94,column:9}},32:{start:{line:91,column:10},end:{line:91,column:38}},33:{start:{line:93,column:10},end:{line:93,column:52}},34:{start:{line:96,column:6},end:{line:96,column:70}},35:{start:{line:97,column:6},end:{line:97,column:70}},36:{start:{line:98,column:6},end:{line:98,column:76}},37:{start:{line:102,column:20},end:{line:108,column:5}},38:{start:{line:109,column:16},end:{line:109,column:43}},39:{start:{line:110,column:26},end:{line:114,column:5}},40:{start:{line:111,column:21},end:{line:111,column:36}},41:{start:{line:112,column:19},end:{line:112,column:32}},42:{start:{line:113,column:6},end:{line:113,column:44}},43:{start:{line:115,column:4},end:{line:115,column:20}},44:{start:{line:116,column:4},end:{line:116,column:56}},45:{start:{line:117,column:4},end:{line:117,column:56}},46:{start:{line:118,column:4},end:{line:118,column:62}},47:{start:{line:119,column:24},end:{line:119,column:41}},48:{start:{line:120,column:4},end:{line:120,column:45}},49:{start:{line:121,column:16},end:{line:121,column:74}},50:{start:{line:122,column:4},end:{line:122,column:37}},51:{start:{line:123,column:20},end:{line:123,column:49}},52:{start:{line:124,column:20},end:{line:144,column:6}},53:{start:{line:134,column:8},end:{line:134,column:82}},54:{start:{line:136,column:62},end:{line:136,column:141}},55:{start:{line:138,column:8},end:{line:142,column:9}},56:{start:{line:139,column:10},end:{line:139,column:108}},57:{start:{line:141,column:10},end:{line:141,column:160}},58:{start:{line:145,column:4},end:{line:145,column:28}},59:{start:{line:146,column:4},end:{line:152,column:7}},60:{start:{line:147,column:6},end:{line:151,column:9}},61:{start:{line:153,column:4},end:{line:159,column:7}},62:{start:{line:154,column:6},end:{line:155,column:15}},63:{start:{line:155,column:8},end:{line:155,column:15}},64:{start:{line:156,column:6},end:{line:158,column:9}},65:{start:{line:160,column:4},end:{line:162,column:7}},66:{start:{line:161,column:6},end:{line:161,column:30}},67:{start:{line:163,column:4},end:{line:167,column:7}},68:{start:{line:164,column:6},end:{line:166,column:9}},69:{start:{line:168,column:4},end:{line:168,column:37}},70:{start:{line:169,column:4},end:{line:169,column:37}},71:{start:{line:171,column:22},end:{line:174,column:3}},72:{start:{line:172,column:18},end:{line:172,column:82}},73:{start:{line:172,column:66},end:{line:172,column:81}},74:{start:{line:173,column:4},end:{line:173,column:36}},75:{start:{line:176,column:4},end:{line:185,column:6}},76:{start:{line:182,column:20},end:{line:182,column:38}}},fnMap:{0:{name:"renderPopup",decl:{start:{line:15,column:9},end:{line:15,column:20}},loc:{start:{line:15,column:39},end:{line:18,column:1}},line:15},1:{name:"buildInspectStyle",decl:{start:{line:19,column:9},end:{line:19,column:26}},loc:{start:{line:19,column:78},end:{line:44,column:1}},line:19},2:{name:"(anonymous_2)",decl:{start:{line:32,column:48},end:{line:32,column:49}},loc:{start:{line:32,column:62},end:{line:37,column:3}},line:32},3:{name:"(anonymous_3)",decl:{start:{line:47,column:17},end:{line:47,column:18}},loc:{start:{line:47,column:23},end:{line:48,column:5}},line:47},4:{name:"(anonymous_4)",decl:{start:{line:49,column:18},end:{line:49,column:19}},loc:{start:{line:49,column:24},end:{line:50,column:5}},line:49},5:{name:"(anonymous_5)",decl:{start:{line:51,column:19},end:{line:51,column:20}},loc:{start:{line:51,column:25},end:{line:52,column:5}},line:51},6:{name:"(anonymous_6)",decl:{start:{line:53,column:14},end:{line:53,column:15}},loc:{start:{line:53,column:20},end:{line:54,column:5}},line:53},7:{name:"(anonymous_7)",decl:{start:{line:58,column:2},end:{line:58,column:3}},loc:{start:{line:58,column:21},end:{line:64,column:3}},line:58},8:{name:"(anonymous_8)",decl:{start:{line:65,column:2},end:{line:65,column:3}},loc:{start:{line:65,column:28},end:{line:72,column:3}},line:65},9:{name:"(anonymous_9)",decl:{start:{line:73,column:2},end:{line:73,column:3}},loc:{start:{line:73,column:46},end:{line:80,column:3}},line:73},10:{name:"(anonymous_10)",decl:{start:{line:81,column:2},end:{line:81,column:3}},loc:{start:{line:81,column:23},end:{line:100,column:3}},line:81},11:{name:"(anonymous_11)",decl:{start:{line:101,column:2},end:{line:101,column:3}},loc:{start:{line:101,column:22},end:{line:170,column:3}},line:101},12:{name:"(anonymous_12)",decl:{start:{line:110,column:26},end:{line:110,column:27}},loc:{start:{line:110,column:32},end:{line:114,column:5}},line:110},13:{name:"(anonymous_13)",decl:{start:{line:133,column:24},end:{line:133,column:25}},loc:{start:{line:133,column:44},end:{line:135,column:7}},line:133},14:{name:"(anonymous_14)",decl:{start:{line:136,column:25},end:{line:136,column:26}},loc:{start:{line:136,column:62},end:{line:136,column:141}},line:136},15:{name:"(anonymous_15)",decl:{start:{line:137,column:19},end:{line:137,column:20}},loc:{start:{line:137,column:33},end:{line:143,column:7}},line:137},16:{name:"(anonymous_16)",decl:{start:{line:146,column:25},end:{line:146,column:26}},loc:{start:{line:146,column:31},end:{line:152,column:5}},line:146},17:{name:"(anonymous_17)",decl:{start:{line:153,column:19},end:{line:153,column:20}},loc:{start:{line:153,column:26},end:{line:159,column:5}},line:153},18:{name:"(anonymous_18)",decl:{start:{line:160,column:20},end:{line:160,column:21}},loc:{start:{line:160,column:27},end:{line:162,column:5}},line:160},19:{name:"(anonymous_19)",decl:{start:{line:163,column:19},end:{line:163,column:20}},loc:{start:{line:163,column:27},end:{line:167,column:5}},line:163},20:{name:"(anonymous_20)",decl:{start:{line:171,column:22},end:{line:171,column:23}},loc:{start:{line:171,column:30},end:{line:174,column:3}},line:171},21:{name:"(anonymous_21)",decl:{start:{line:172,column:55},end:{line:172,column:56}},loc:{start:{line:172,column:66},end:{line:172,column:81}},line:172},22:{name:"(anonymous_22)",decl:{start:{line:175,column:2},end:{line:175,column:3}},loc:{start:{line:175,column:11},end:{line:186,column:3}},line:175},23:{name:"(anonymous_23)",decl:{start:{line:182,column:13},end:{line:182,column:14}},loc:{start:{line:182,column:20},end:{line:182,column:38}},line:182}},branchMap:{0:{loc:{start:{line:28,column:2},end:{line:30,column:3}},type:"if",locations:[{start:{line:28,column:2},end:{line:30,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:28},1:{loc:{start:{line:34,column:4},end:{line:36,column:5}},type:"if",locations:[{start:{line:34,column:4},end:{line:36,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:34},2:{loc:{start:{line:34,column:8},end:{line:34,column:64}},type:"binary-expr",locations:[{start:{line:34,column:8},end:{line:34,column:32}},{start:{line:34,column:36},end:{line:34,column:64}}],line:34},3:{loc:{start:{line:66,column:4},end:{line:67,column:13}},type:"if",locations:[{start:{line:66,column:4},end:{line:67,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:66},4:{loc:{start:{line:76,column:15},end:{line:76,column:131}},type:"binary-expr",locations:[{start:{line:76,column:15},end:{line:76,column:71}},{start:{line:76,column:75},end:{line:76,column:131}}],line:76},5:{loc:{start:{line:84,column:4},end:{line:87,column:5}},type:"if",locations:[{start:{line:84,column:4},end:{line:87,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:84},6:{loc:{start:{line:84,column:8},end:{line:84,column:98}},type:"binary-expr",locations:[{start:{line:84,column:8},end:{line:84,column:26}},{start:{line:84,column:30},end:{line:84,column:98}}],line:84},7:{loc:{start:{line:88,column:4},end:{line:99,column:5}},type:"if",locations:[{start:{line:88,column:4},end:{line:99,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:88},8:{loc:{start:{line:89,column:6},end:{line:95,column:7}},type:"if",locations:[{start:{line:89,column:6},end:{line:95,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:89},9:{loc:{start:{line:138,column:8},end:{line:142,column:9}},type:"if",locations:[{start:{line:138,column:8},end:{line:142,column:9}},{start:{line:140,column:15},end:{line:142,column:9}}],line:138},10:{loc:{start:{line:154,column:6},end:{line:155,column:15}},type:"if",locations:[{start:{line:154,column:6},end:{line:155,column:15}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:154}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0,74:0,75:0,76:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/MapMaplibreGl.tsx"],names:[],mappings:"AAyL6B;AAzL7B,OAAO,WAAuB;AAC9B,OAAO,cAAc;AACrB,OAAO,gBAAwG;AAE/G,OAAO,mBAAmB;AAE1B,OAAO,YAAY;AACnB,OAAO,6BAA6B;AACpC,OAAO,uCAA2D;AAClE,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,SAA2B,6BAA6B;AACxD,OAAO;AACP,OAAO;AACP,OAAO;AAEP,SAAS,YAAY,OAAoB,WAA+B;AACtE,WAAS,OAAO,OAAO,SAAS;AAChC,SAAO;AACT;AAEA,SAAS,kBAAkB,kBAAsC,eAAmC,kBAAqC;AACvI,QAAM,kBAAkB;AAAA,IACtB,MAAM;AAAA,IACN,QAAQ;AAAA,IACR,SAAS;AAAA,MACP,oBAAoB;AAAA,IACtB;AAAA,EACF;AAEA,QAAM,QAAQ,sBAAsB,gBAAgB;AACpD,MAAG,OAAO;AACR,kBAAc,KAAK,KAAK;AAAA,EAC1B;AAEA,QAAM,UAA+C,CAAC;AACtD,SAAO,KAAK,iBAAiB,OAAO,EAAE,QAAQ,cAAY;AACxD,UAAM,SAAS,iBAAiB,QAAQ,QAAQ;AAChD,QAAG,OAAO,SAAS,YAAY,OAAO,SAAS,cAAc;AAC3D,cAAQ,QAAQ,IAAI;AAAA,IACtB;AAAA,EACF,CAAC;AAED,QAAM,eAAe;AAAA,IACnB,GAAG;AAAA,IACH;AAAA,IACA,QAAQ,CAAC,eAAe,EAAE,OAAO,aAAqC;AAAA,EACxE;AACA,SAAO;AACT;AAuBA,qBAAqB,sBAAsB,MAAM,UAAkD;AAAA,EACjG,OAAO,eAAe;AAAA,IACpB,aAAa,MAAM;AAAA,IAAC;AAAA,IACpB,cAAc,MAAM;AAAA,IAAC;AAAA,IACrB,eAAe,MAAM;AAAA,IAAC;AAAA,IACtB,UAAU,MAAM;AAAA,IAAC;AAAA,IACjB,SAAS,CAAC;AAAA,EACZ;AAAA,EACA,YAAmC;AAAA,EAEnC,YAAY,OAA2B;AACrC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,KAAK;AAAA,MACL,SAAS;AAAA,IACX;AAAA,EACF;AAAA,EAEA,mBAAmB,OAA2B;AAC5C,QAAG,CAAC,KAAK,MAAM;AAAK;AAIpB,SAAK,MAAM,IAAI;AAAA,MACb,KAAK,MAAM,oBAAoB,MAAM,QAAQ;AAAA,MAC7C,EAAC,MAAM,KAAI;AAAA,IACb;AAAA,EACF;AAAA,EAEA,sBAAsB,WAA+B,WAA+B;AAClF,QAAI,SAAS;AACb,QAAI;AACF,eAAS,KAAK,UAAU,KAAK,KAAK,MAAM,KAAK,UAAU,SAAS,KAAK,KAAK,UAAU,KAAK,KAAK,MAAM,KAAK,UAAU,SAAS;AAAA,IAC9H,SAAQ,GAAG;AAAA,IAEX;AACA,WAAO;AAAA,EACT;AAAA,EAEA,qBAAqB;AACnB,UAAM,MAAM,KAAK,MAAM;AAEvB,SAAK,mBAAmB,KAAK,KAAK;AAElC,QAAG,KAAK,MAAM,WAAW,KAAK,MAAM,uBAAuB,KAAK,MAAM,QAAQ,iBAAiB;AAG7F,WAAK,MAAM,QAAQ,gBAAgB;AACnC,WAAK,MAAM,QAAQ,gBAAgB;AAAA,IACrC;AACA,QAAI,KAAK;AACP,UAAI,KAAK,MAAM,oBAAoB;AAIjC,YAAI;AACF,eAAK,MAAM,QAAQ,OAAO;AAAA,QAC5B,SAAQ,KAAK;AACX,kBAAQ,MAAM,uBAAuB,GAAG;AAAA,QAC1C;AAAA,MACF;AAEA,UAAI,qBAAqB,KAAK,MAAM,SAAS;AAC7C,UAAI,qBAAqB,KAAK,MAAM,SAAS;AAC7C,UAAI,wBAAwB,KAAK,MAAM,SAAS;AAAA,IAClD;AAAA,EACF;AAAA,EAEA,oBAAoB;AAClB,UAAM,UAAU;AAAA,MACd,GAAG,KAAK,MAAM;AAAA,MACd,WAAW,KAAK;AAAA,MAChB,OAAO,KAAK,MAAM;AAAA,MAClB,MAAM;AAAA,MACN,SAAS;AAAA,IACX;AAEA,UAAM,MAAM,IAAI,WAAW,IAAI,OAAO;AAEtC,UAAM,gBAAgB,MAAM;AAC1B,YAAM,SAAS,IAAI,UAAU;AAC7B,YAAM,OAAO,IAAI,QAAQ;AACzB,WAAK,MAAM,SAAS,EAAC,QAAQ,KAAI,CAAC;AAAA,IACpC;AACA,kBAAc;AAEd,QAAI,qBAAqB,QAAQ;AACjC,QAAI,qBAAqB,QAAQ;AACjC,QAAI,wBAAwB,QAAQ;AAEpC,UAAM,cAAc,IAAI;AACxB,QAAI,WAAW,aAAa,WAAW;AAEvC,UAAM,MAAM,IAAI,WAAW,kBAAkB,EAAC,gBAAe,KAAI,CAAC;AAClE,QAAI,WAAW,KAAK,WAAW;AAE/B,UAAM,UAAU,SAAS,cAAc,KAAK;AAE5C,UAAM,UAAU,IAAI,cAAc;AAAA,MAChC,OAAO,IAAI,WAAW,MAAM;AAAA,QAC1B,cAAc;AAAA,MAChB,CAAC;AAAA,MACD,cAAc;AAAA,MACd,qBAAqB;AAAA,MACrB,4BAA4B;AAAA,MAC5B,mBAAmB;AAAA,MACnB,wBAAwB;AAAA,MACxB,kBAAkB,CAAC,SAAiB,UAAkB;AACpD,eAAO,MAAM,OAAO,YAAY,SAAS,KAAK,CAAC,EAAE,WAAW,GAAG,EAAE,OAAO;AAAA,MAC1E;AAAA,MACA,mBAAmB,CAAC,kBAAsC,kBAAsC,kBAAkB,kBAAkB,eAAe,KAAK,MAAM,gBAAgB;AAAA,MAC9K,aAAa,CAAC,aAA+B;AAC3C,YAAG,KAAK,MAAM,oBAAoB;AAChC,iBAAO,YAAY,oBAAC,qCAAkC,UAAoB,GAAI,OAAO;AAAA,QACvF,OAAO;AACL,iBAAO,YAAY,oBAAC,2BAAwB,UAAoB,eAAe,KAAK,mBAAmB,MAAM,KAAK,MAAM,MAAM,GAAI,OAAO;AAAA,QAC3I;AAAA,MACF;AAAA,IACF,CAAC;AACD,QAAI,WAAW,OAAO;AAEtB,QAAI,GAAG,cAAc,MAAM;AACzB,WAAK,SAAS;AAAA,QACZ;AAAA,QACA;AAAA,QACA,MAAM,IAAI,QAAQ;AAAA,MACpB,CAAC;AAAA,IACH,CAAC;AAED,QAAI,GAAG,QAAQ,OAAK;AAClB,UAAG,EAAE,aAAa;AAAQ;AAC1B,WAAK,MAAM,aAAc;AAAA,QACvB,KAAK,KAAK,MAAM;AAAA,MAClB,CAAC;AAAA,IACH,CAAC;AAED,QAAI,GAAG,SAAS,OAAK;AACnB,cAAQ,IAAI,SAAS,CAAC;AAAA,IACxB,CAAC;AAED,QAAI,GAAG,QAAQ,QAAM;AACnB,WAAK,SAAS;AAAA,QACZ,MAAM,IAAI,QAAQ;AAAA,MACpB,CAAC;AAAA,IACH,CAAC;AAED,QAAI,GAAG,WAAW,aAAa;AAC/B,QAAI,GAAG,WAAW,aAAa;AAAA,EACjC;AAAA,EAEA,oBAAoB,CAAC,OAAe;AAClC,UAAM,QAAQ,KAAK,MAAM,SAAS,OAAO,UAAU,WAAS,MAAM,OAAO,EAAE;AAC3E,SAAK,MAAM,cAAc,KAAK;AAAA,EAChC;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,MAAK;AAAA,QACL,cAAW;AAAA,QACX,KAAK,OAAK,KAAK,YAAY;AAAA,QAC3B,eAAY;AAAA;AAAA,IACb;AAAA,EACH;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"cf2170ca14c8f07639bb91af4dc600c4bb0a376c"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return cn=function(){return s},s}cn();function t9(e,n){return cn().f[0]++,cn().s[0]++,_U.render(e,n),cn().s[1]++,n}function uee(e,n,t){cn().f[1]++;const r=(cn().s[2]++,{id:"background",type:"background",paint:{"background-color":"#1c1f24"}}),i=(cn().s[3]++,lee(t));cn().s[4]++,i?(cn().b[0][0]++,cn().s[5]++,n.push(i)):cn().b[0][1]++;const o=(cn().s[6]++,{});cn().s[7]++,Object.keys(e.sources).forEach(a=>{cn().f[2]++;const f=(cn().s[8]++,e.sources[a]);cn().s[9]++,cn().b[2][0]++,f.type!=="raster"&&(cn().b[2][1]++,f.type!=="raster-dem")?(cn().b[1][0]++,cn().s[10]++,o[a]=f):cn().b[1][1]++});const s=(cn().s[11]++,{...e,sources:o,layers:[r].concat(n)});return cn().s[12]++,s}class aL extends bn.Component{constructor(t){cn().f[7]++,cn().s[15]++;super(t);nn(this,"container",(cn().s[14]++,null));nn(this,"onLayerSelectById",(cn().s[71]++,t=>{cn().f[20]++;const r=(cn().s[72]++,this.props.mapStyle.layers.findIndex(i=>(cn().f[21]++,cn().s[73]++,i.id===t)));cn().s[74]++,this.props.onLayerSelect(r)}));cn().s[16]++,this.state={map:null,inspect:null}}updateMapFromProps(t){if(cn().f[8]++,cn().s[17]++,this.state.map)cn().b[3][1]++;else{cn().b[3][0]++,cn().s[18]++;return}cn().s[19]++,this.state.map.setStyle(this.props.replaceAccessTokens(t.mapStyle),{diff:!0})}shouldComponentUpdate(t,r){cn().f[9]++;let i=(cn().s[20]++,!1);cn().s[21]++;try{cn().s[22]++,i=(cn().b[4][0]++,JSON.stringify(this.props)!==JSON.stringify(t)||(cn().b[4][1]++,JSON.stringify(this.state)!==JSON.stringify(r)))}catch{}return cn().s[23]++,i}componentDidUpdate(){var r,i,o;cn().f[10]++;const t=(cn().s[24]++,this.state.map);if(cn().s[25]++,this.updateMapFromProps(this.props),cn().s[26]++,cn().b[6][0]++,this.state.inspect&&(cn().b[6][1]++,this.props.inspectModeEnabled!==this.state.inspect._showInspectMap)?(cn().b[5][0]++,cn().s[27]++,this.state.inspect._popupBlocked=!1,cn().s[28]++,this.state.inspect.toggleInspector()):cn().b[5][1]++,cn().s[29]++,t){if(cn().b[7][0]++,cn().s[30]++,this.props.inspectModeEnabled){cn().b[8][0]++,cn().s[31]++;try{cn().s[32]++,this.state.inspect.render()}catch(s){cn().s[33]++,console.error("FIXME: Caught error",s)}}else cn().b[8][1]++;cn().s[34]++,t.showTileBoundaries=(r=this.props.options)==null?void 0:r.showTileBoundaries,cn().s[35]++,t.showCollisionBoxes=(i=this.props.options)==null?void 0:i.showCollisionBoxes,cn().s[36]++,t.showOverdrawInspector=(o=this.props.options)==null?void 0:o.showOverdrawInspector}else cn().b[7][1]++}componentDidMount(){cn().f[11]++;const t=(cn().s[37]++,{...this.props.options,container:this.container,style:this.props.mapStyle,hash:!0,maxZoom:24}),r=(cn().s[38]++,new g2.Map(t));cn().s[39]++;const i=()=>{cn().f[12]++;const g=(cn().s[40]++,r.getCenter()),x=(cn().s[41]++,r.getZoom());cn().s[42]++,this.props.onChange({center:g,zoom:x})};cn().s[43]++,i(),cn().s[44]++,r.showTileBoundaries=t.showTileBoundaries,cn().s[45]++,r.showCollisionBoxes=t.showCollisionBoxes,cn().s[46]++,r.showOverdrawInspector=t.showOverdrawInspector;const o=(cn().s[47]++,new see);cn().s[48]++,r.addControl(o,"top-right");const s=(cn().s[49]++,new g2.NavigationControl({visualizePitch:!0}));cn().s[50]++,r.addControl(s,"top-right");const a=(cn().s[51]++,document.createElement("div")),f=(cn().s[52]++,new nJ({popup:new g2.Popup({closeOnClick:!1}),showMapPopup:!0,showMapPopupOnHover:!1,showInspectMapPopupOnHover:!0,showInspectButton:!1,blockHoverPopupOnClick:!0,assignLayerColor:(g,x)=>(cn().f[13]++,cn().s[53]++,D6(t5.brightColor(g,x)).desaturate(.5).string()),buildInspectStyle:(g,x)=>(cn().f[14]++,cn().s[54]++,uee(g,x,this.props.highlightedLayer)),renderPopup:g=>(cn().f[15]++,cn().s[55]++,this.props.inspectModeEnabled?(cn().b[9][0]++,cn().s[56]++,t9(N.jsx(UJ,{features:g}),a)):(cn().b[9][1]++,cn().s[57]++,t9(N.jsx(HR,{features:g,onLayerSelect:this.onLayerSelectById,zoom:this.state.zoom}),a)))}));cn().s[58]++,r.addControl(f),cn().s[59]++,r.on("style.load",()=>{cn().f[16]++,cn().s[60]++,this.setState({map:r,inspect:f,zoom:r.getZoom()})}),cn().s[61]++,r.on("data",g=>{if(cn().f[17]++,cn().s[62]++,g.dataType!=="tile"){cn().b[10][0]++,cn().s[63]++;return}else cn().b[10][1]++;cn().s[64]++,this.props.onDataChange({map:this.state.map})}),cn().s[65]++,r.on("error",g=>{cn().f[18]++,cn().s[66]++,console.log("ERROR",g)}),cn().s[67]++,r.on("zoom",g=>{cn().f[19]++,cn().s[68]++,this.setState({zoom:r.getZoom()})}),cn().s[69]++,r.on("dragend",i),cn().s[70]++,r.on("zoomend",i)}render(){return cn().f[22]++,cn().s[75]++,N.jsx("div",{className:"maputnik-map__map",role:"region","aria-label":"Map view",ref:t=>(cn().f[23]++,cn().s[76]++,this.container=t),"data-wd-key":"maplibre:map"})}}nn(aL,"defaultProps",(cn().s[13]++,{onMapLoaded:()=>{cn().f[3]++},onDataChange:()=>{cn().f[4]++},onLayerSelect:()=>{cn().f[5]++},onChange:()=>{cn().f[6]++},options:{}}));var Ep=function(){function e(n){this.propagationStopped,this.defaultPrevented,this.type=n,this.target=null}return e.prototype.preventDefault=function(){this.defaultPrevented=!0},e.prototype.stopPropagation=function(){this.propagationStopped=!0},e}();const xy={PROPERTYCHANGE:"propertychange"};var Aee=function(){function e(){this.disposed=!1}return e.prototype.dispose=function(){this.disposed||(this.disposed=!0,this.disposeInternal())},e.prototype.disposeInternal=function(){},e}();const UB=Aee;function cee(e,n,t){for(var r,i,o=t||c1,s=0,a=e.length,f=!1;s<a;)r=s+(a-s>>1),i=+o(e[r],n),i<0?s=r+1:(a=r,f=!i);return f?s:~s}function c1(e,n){return e>n?1:e<n?-1:0}function RB(e,n,t){var r=e.length;if(e[0]<=n)return 0;if(n<=e[r-1])return r-1;var i=void 0;if(t>0){for(i=1;i<r;++i)if(e[i]<n)return i-1}else if(t<0){for(i=1;i<r;++i)if(e[i]<=n)return i}else for(i=1;i<r;++i){if(e[i]==n)return i;if(e[i]<n)return typeof t=="function"?t(n,e[i-1],e[i])>0?i-1:i:e[i-1]-n<n-e[i]?i-1:i}return r-1}function dee(e,n,t){for(;n<t;){var r=e[n];e[n]=e[t],e[t]=r,++n,--t}}function sf(e,n){for(var t=Array.isArray(n)?n:[n],r=t.length,i=0;i<r;i++)e[e.length]=t[i]}function _1(e,n){var t=e.length;if(t!==n.length)return!1;for(var r=0;r<t;r++)if(e[r]!==n[r])return!1;return!0}function hee(e,n,t){var r=n||c1;return e.every(function(i,o){if(o===0)return!0;var s=r(e[o-1],i);return!(s>0||t&&s===0)})}function ty(){return!0}function n5(){return!1}function d1(){}function fee(e){var n=!1,t,r,i;return function(){var o=Array.prototype.slice.call(arguments);return(!n||this!==i||!_1(o,r))&&(n=!0,i=this,r=o,t=e.apply(this,arguments)),t}}var al=typeof Object.assign=="function"?Object.assign:function(e,n){if(e==null)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),r=1,i=arguments.length;r<i;++r){var o=arguments[r];if(o!=null)for(var s in o)o.hasOwnProperty(s)&&(t[s]=o[s])}return t};function Q_(e){for(var n in e)delete e[n]}var sL=typeof Object.values=="function"?Object.values:function(e){var n=[];for(var t in e)n.push(e[t]);return n};function h1(e){var n;for(n in e)return!1;return!n}var pee=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),mee=function(e){pee(n,e);function n(t){var r=e.call(this)||this;return r.eventTarget_=t,r.pendingRemovals_=null,r.dispatching_=null,r.listeners_=null,r}return n.prototype.addEventListener=function(t,r){if(!(!t||!r)){var i=this.listeners_||(this.listeners_={}),o=i[t]||(i[t]=[]);o.indexOf(r)===-1&&o.push(r)}},n.prototype.dispatchEvent=function(t){var r=typeof t=="string",i=r?t:t.type,o=this.listeners_&&this.listeners_[i];if(o){var s=r?new Ep(t):t;s.target||(s.target=this.eventTarget_||this);var a=this.dispatching_||(this.dispatching_={}),f=this.pendingRemovals_||(this.pendingRemovals_={});i in a||(a[i]=0,f[i]=0),++a[i];for(var g,x=0,k=o.length;x<k;++x)if("handleEvent"in o[x]?g=o[x].handleEvent(s):g=o[x].call(this,s),g===!1||s.propagationStopped){g=!1;break}if(--a[i]===0){var B=f[i];for(delete f[i];B--;)this.removeEventListener(i,d1);delete a[i]}return g}},n.prototype.disposeInternal=function(){this.listeners_&&Q_(this.listeners_)},n.prototype.getListeners=function(t){return this.listeners_&&this.listeners_[t]||void 0},n.prototype.hasListener=function(t){return this.listeners_?t?t in this.listeners_:Object.keys(this.listeners_).length>0:!1},n.prototype.removeEventListener=function(t,r){var i=this.listeners_&&this.listeners_[t];if(i){var o=i.indexOf(r);o!==-1&&(this.pendingRemovals_&&t in this.pendingRemovals_?(i[o]=d1,++this.pendingRemovals_[t]):(i.splice(o,1),i.length===0&&delete this.listeners_[t]))}},n}(UB);const zy=mee,ki={CHANGE:"change",ERROR:"error",BLUR:"blur",CLEAR:"clear",CONTEXTMENU:"contextmenu",CLICK:"click",DBLCLICK:"dblclick",DRAGENTER:"dragenter",DRAGOVER:"dragover",DROP:"drop",FOCUS:"focus",KEYDOWN:"keydown",KEYPRESS:"keypress",LOAD:"load",RESIZE:"resize",TOUCHMOVE:"touchmove",WHEEL:"wheel"};function wo(e,n,t,r,i){if(r&&r!==e&&(t=t.bind(r)),i){var o=t;t=function(){e.removeEventListener(n,t),o.apply(this,arguments)}}var s={target:e,type:n,listener:t};return e.addEventListener(n,t),s}function v3(e,n,t,r){return wo(e,n,t,r,!0)}function Ga(e){e&&e.target&&(e.target.removeEventListener(e.type,e.listener),Q_(e))}var gee=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),r5=function(e){gee(n,e);function n(){var t=e.call(this)||this;return t.on=t.onInternal,t.once=t.onceInternal,t.un=t.unInternal,t.revision_=0,t}return n.prototype.changed=function(){++this.revision_,this.dispatchEvent(ki.CHANGE)},n.prototype.getRevision=function(){return this.revision_},n.prototype.onInternal=function(t,r){if(Array.isArray(t)){for(var i=t.length,o=new Array(i),s=0;s<i;++s)o[s]=wo(this,t[s],r);return o}else return wo(this,t,r)},n.prototype.onceInternal=function(t,r){var i;if(Array.isArray(t)){var o=t.length;i=new Array(o);for(var s=0;s<o;++s)i[s]=v3(this,t[s],r)}else i=v3(this,t,r);return r.ol_key=i,i},n.prototype.unInternal=function(t,r){var i=r.ol_key;if(i)l_(i);else if(Array.isArray(t))for(var o=0,s=t.length;o<s;++o)this.removeEventListener(t[o],r);else this.removeEventListener(t,r)},n}(zy);r5.prototype.on;r5.prototype.once;r5.prototype.un;function l_(e){if(Array.isArray(e))for(var n=0,t=e.length;n<t;++n)Ga(e[n]);else Ga(e)}const lL=r5;function li(){return function(){throw new Error("Unimplemented abstract method.")}()}var yee=0;function $i(e){return e.ol_uid||(e.ol_uid=String(++yee))}var vee="6.15.1",uL=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),n9=function(e){uL(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.key=r,o.oldValue=i,o}return n}(Ep),mh=function(e){uL(n,e);function n(t){var r=e.call(this)||this;return r.on,r.once,r.un,$i(r),r.values_=null,t!==void 0&&r.setProperties(t),r}return n.prototype.get=function(t){var r;return this.values_&&this.values_.hasOwnProperty(t)&&(r=this.values_[t]),r},n.prototype.getKeys=function(){return this.values_&&Object.keys(this.values_)||[]},n.prototype.getProperties=function(){return this.values_&&al({},this.values_)||{}},n.prototype.hasProperties=function(){return!!this.values_},n.prototype.notify=function(t,r){var i;i="change:".concat(t),this.hasListener(i)&&this.dispatchEvent(new n9(i,t,r)),i=xy.PROPERTYCHANGE,this.hasListener(i)&&this.dispatchEvent(new n9(i,t,r))},n.prototype.addChangeListener=function(t,r){this.addEventListener("change:".concat(t),r)},n.prototype.removeChangeListener=function(t,r){this.removeEventListener("change:".concat(t),r)},n.prototype.set=function(t,r,i){var o=this.values_||(this.values_={});if(i)o[t]=r;else{var s=o[t];o[t]=r,s!==r&&this.notify(t,s)}},n.prototype.setProperties=function(t,r){for(var i in t)this.set(i,t[i],r)},n.prototype.applyProperties=function(t){t.values_&&al(this.values_||(this.values_={}),t.values_)},n.prototype.unset=function(t,r){if(this.values_&&t in this.values_){var i=this.values_[t];delete this.values_[t],h1(this.values_)&&(this.values_=null),r||this.notify(t,i)}},n}(lL),Cee=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),_ee=function(e){Cee(n,e);function n(t){var r=this,i="v"+vee.split("-")[0],o="Assertion failed. See https://openlayers.org/en/"+i+"/doc/errors/#"+t+" for details.";return r=e.call(this,o)||this,r.code=t,r.name="AssertionError",r.message=o,r}return n}(Error);const AL=_ee;function ao(e,n){if(!e)throw new AL(n)}var bee=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),xee=function(e){bee(n,e);function n(t){var r=e.call(this)||this;if(r.on,r.once,r.un,r.id_=void 0,r.geometryName_="geometry",r.style_=null,r.styleFunction_=void 0,r.geometryChangeKey_=null,r.addChangeListener(r.geometryName_,r.handleGeometryChanged_),t)if(typeof t.getSimplifiedGeometry=="function"){var i=t;r.setGeometry(i)}else{var o=t;r.setProperties(o)}return r}return n.prototype.clone=function(){var t=new n(this.hasProperties()?this.getProperties():null);t.setGeometryName(this.getGeometryName());var r=this.getGeometry();r&&t.setGeometry(r.clone());var i=this.getStyle();return i&&t.setStyle(i),t},n.prototype.getGeometry=function(){return this.get(this.geometryName_)},n.prototype.getId=function(){return this.id_},n.prototype.getGeometryName=function(){return this.geometryName_},n.prototype.getStyle=function(){return this.style_},n.prototype.getStyleFunction=function(){return this.styleFunction_},n.prototype.handleGeometryChange_=function(){this.changed()},n.prototype.handleGeometryChanged_=function(){this.geometryChangeKey_&&(Ga(this.geometryChangeKey_),this.geometryChangeKey_=null);var t=this.getGeometry();t&&(this.geometryChangeKey_=wo(t,ki.CHANGE,this.handleGeometryChange_,this)),this.changed()},n.prototype.setGeometry=function(t){this.set(this.geometryName_,t)},n.prototype.setStyle=function(t){this.style_=t,this.styleFunction_=t?wee(t):void 0,this.changed()},n.prototype.setId=function(t){this.id_=t,this.changed()},n.prototype.setGeometryName=function(t){this.removeChangeListener(this.geometryName_,this.handleGeometryChanged_),this.geometryName_=t,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),this.handleGeometryChanged_()},n}(mh);function wee(e){if(typeof e=="function")return e;var n;if(Array.isArray(e))n=e;else{ao(typeof e.getZIndex=="function",41);var t=e;n=[t]}return function(){return n}}var gA={RADIANS:"radians",DEGREES:"degrees",FEET:"ft",METERS:"m",PIXELS:"pixels",TILE_PIXELS:"tile-pixels",USFEET:"us-ft"},cf={};cf[gA.RADIANS]=6370997/(2*Math.PI);cf[gA.DEGREES]=2*Math.PI*6370997/360;cf[gA.FEET]=.3048;cf[gA.METERS]=1;cf[gA.USFEET]=1200/3937;var Fm=typeof navigator<"u"&&typeof navigator.userAgent<"u"?navigator.userAgent.toLowerCase():"",Mee=Fm.indexOf("firefox")!==-1,See=Fm.indexOf("safari")!==-1&&Fm.indexOf("chrom")==-1;See&&(Fm.indexOf("version/15.4")>=0||Fm.match(/cpu (os|iphone os) 15_4 like mac os x/));var Eee=Fm.indexOf("webkit")!==-1&&Fm.indexOf("edge")==-1,Oee=Fm.indexOf("macintosh")!==-1,cL=typeof devicePixelRatio<"u"?devicePixelRatio:1,i5=typeof WorkerGlobalScope<"u"&&typeof OffscreenCanvas<"u"&&self instanceof WorkerGlobalScope,Bee=typeof Image<"u"&&Image.prototype.decode,dL=function(){var e=!1;try{var n=Object.defineProperty({},"passive",{get:function(){e=!0}});window.addEventListener("_",null,n),window.removeEventListener("_",null,n)}catch{}return e}(),hL=new Array(6);function xd(){return[1,0,0,1,0,0]}function r9(e){return o5(e,1,0,0,1,0,0)}function LB(e,n){var t=e[0],r=e[1],i=e[2],o=e[3],s=e[4],a=e[5],f=n[0],g=n[1],x=n[2],k=n[3],B=n[4],P=n[5];return e[0]=t*f+i*g,e[1]=r*f+o*g,e[2]=t*x+i*k,e[3]=r*x+o*k,e[4]=t*B+i*P+s,e[5]=r*B+o*P+a,e}function o5(e,n,t,r,i,o,s){return e[0]=n,e[1]=t,e[2]=r,e[3]=i,e[4]=o,e[5]=s,e}function kee(e,n){return e[0]=n[0],e[1]=n[1],e[2]=n[2],e[3]=n[3],e[4]=n[4],e[5]=n[5],e}function rl(e,n){var t=n[0],r=n[1];return n[0]=e[0]*t+e[2]*r+e[4],n[1]=e[1]*t+e[3]*r+e[5],n}function sM(e,n,t){return LB(e,o5(hL,n,0,0,t,0,0))}function Iee(e,n,t){return o5(e,n,0,0,t,0,0)}function Tee(e,n,t){return LB(e,o5(hL,1,0,0,1,n,t))}function df(e,n,t,r,i,o,s,a){var f=Math.sin(o),g=Math.cos(o);return e[0]=r*g,e[1]=i*f,e[2]=-r*f,e[3]=i*g,e[4]=s*r*g-a*r*f+n,e[5]=s*i*f+a*i*g+t,e}function zB(e,n){var t=Kee(n);ao(t!==0,32);var r=n[0],i=n[1],o=n[2],s=n[3],a=n[4],f=n[5];return e[0]=s/t,e[1]=-i/t,e[2]=-o/t,e[3]=r/t,e[4]=(o*f-s*a)/t,e[5]=-(r*f-i*a)/t,e}function Kee(e){return e[0]*e[3]-e[1]*e[2]}var i9;function fL(e){var n="matrix("+e.join(", ")+")";if(i5)return n;var t=i9||(i9=document.createElement("div"));return t.style.transform=n,t.style.transform}const iu={UNKNOWN:0,INTERSECTING:1,ABOVE:2,RIGHT:4,BELOW:8,LEFT:16};function U6(e){for(var n=Ed(),t=0,r=e.length;t<r;++t)kC(n,e[t]);return n}function Pee(e,n,t){var r=Math.min.apply(null,e),i=Math.min.apply(null,n),o=Math.max.apply(null,e),s=Math.max.apply(null,n);return hf(r,i,o,s,t)}function Em(e,n,t){return t?(t[0]=e[0]-n,t[1]=e[1]-n,t[2]=e[2]+n,t[3]=e[3]+n,t):[e[0]-n,e[1]-n,e[2]+n,e[3]+n]}function pL(e,n){return n?(n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n):e.slice()}function b1(e,n,t){var r,i;return n<e[0]?r=e[0]-n:e[2]<n?r=n-e[2]:r=0,t<e[1]?i=e[1]-t:e[3]<t?i=t-e[3]:i=0,r*r+i*i}function $_(e,n){return jB(e,n[0],n[1])}function cm(e,n){return e[0]<=n[0]&&n[2]<=e[2]&&e[1]<=n[1]&&n[3]<=e[3]}function jB(e,n,t){return e[0]<=n&&n<=e[2]&&e[1]<=t&&t<=e[3]}function R6(e,n){var t=e[0],r=e[1],i=e[2],o=e[3],s=n[0],a=n[1],f=iu.UNKNOWN;return s<t?f=f|iu.LEFT:s>i&&(f=f|iu.RIGHT),a<r?f=f|iu.BELOW:a>o&&(f=f|iu.ABOVE),f===iu.UNKNOWN&&(f=iu.INTERSECTING),f}function Ed(){return[1/0,1/0,-1/0,-1/0]}function hf(e,n,t,r,i){return i?(i[0]=e,i[1]=n,i[2]=t,i[3]=r,i):[e,n,t,r]}function Y_(e){return hf(1/0,1/0,-1/0,-1/0,e)}function mL(e,n){var t=e[0],r=e[1];return hf(t,r,t,r,n)}function WB(e,n,t,r,i){var o=Y_(i);return yL(o,e,n,t,r)}function wy(e,n){return e[0]==n[0]&&e[2]==n[2]&&e[1]==n[1]&&e[3]==n[3]}function gL(e,n){return n[0]<e[0]&&(e[0]=n[0]),n[2]>e[2]&&(e[2]=n[2]),n[1]<e[1]&&(e[1]=n[1]),n[3]>e[3]&&(e[3]=n[3]),e}function kC(e,n){n[0]<e[0]&&(e[0]=n[0]),n[0]>e[2]&&(e[2]=n[0]),n[1]<e[1]&&(e[1]=n[1]),n[1]>e[3]&&(e[3]=n[1])}function yL(e,n,t,r,i){for(;t<r;t+=i)Fee(e,n[t],n[t+1]);return e}function Fee(e,n,t){e[0]=Math.min(e[0],n),e[1]=Math.min(e[1],t),e[2]=Math.max(e[2],n),e[3]=Math.max(e[3],t)}function vL(e,n){var t;return t=n(a5(e)),t||(t=n(s5(e)),t)||(t=n(l5(e)),t)||(t=n(Lm(e)),t)?t:!1}function L6(e){var n=0;return NB(e)||(n=os(e)*$A(e)),n}function a5(e){return[e[0],e[1]]}function s5(e){return[e[2],e[1]]}function Dm(e){return[(e[0]+e[2])/2,(e[1]+e[3])/2]}function Dee(e,n){var t;return n==="bottom-left"?t=a5(e):n==="bottom-right"?t=s5(e):n==="top-left"?t=Lm(e):n==="top-right"?t=l5(e):ao(!1,13),t}function z6(e,n,t,r,i){var o=j6(e,n,t,r),s=o[0],a=o[1],f=o[2],g=o[3],x=o[4],k=o[5],B=o[6],P=o[7];return hf(Math.min(s,f,x,B),Math.min(a,g,k,P),Math.max(s,f,x,B),Math.max(a,g,k,P),i)}function j6(e,n,t,r){var i=n*r[0]/2,o=n*r[1]/2,s=Math.cos(t),a=Math.sin(t),f=i*s,g=i*a,x=o*s,k=o*a,B=e[0],P=e[1];return[B-f+k,P-g-x,B-f-k,P-g+x,B+f-k,P+g+x,B+f+k,P+g-x,B-f+k,P-g-x]}function $A(e){return e[3]-e[1]}function X0(e,n,t){var r=t||Ed();return il(e,n)?(e[0]>n[0]?r[0]=e[0]:r[0]=n[0],e[1]>n[1]?r[1]=e[1]:r[1]=n[1],e[2]<n[2]?r[2]=e[2]:r[2]=n[2],e[3]<n[3]?r[3]=e[3]:r[3]=n[3]):Y_(r),r}function Lm(e){return[e[0],e[3]]}function l5(e){return[e[2],e[3]]}function os(e){return e[2]-e[0]}function il(e,n){return e[0]<=n[2]&&e[2]>=n[0]&&e[1]<=n[3]&&e[3]>=n[1]}function NB(e){return e[2]<e[0]||e[3]<e[1]}function Uee(e,n){return n?(n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n):e}function Ree(e,n,t){var r=!1,i=R6(e,n),o=R6(e,t);if(i===iu.INTERSECTING||o===iu.INTERSECTING)r=!0;else{var s=e[0],a=e[1],f=e[2],g=e[3],x=n[0],k=n[1],B=t[0],P=t[1],R=(P-k)/(B-x),H=void 0,W=void 0;o&iu.ABOVE&&!(i&iu.ABOVE)&&(H=B-(P-g)/R,r=H>=s&&H<=f),!r&&o&iu.RIGHT&&!(i&iu.RIGHT)&&(W=P-(B-f)*R,r=W>=a&&W<=g),!r&&o&iu.BELOW&&!(i&iu.BELOW)&&(H=B-(P-a)/R,r=H>=s&&H<=f),!r&&o&iu.LEFT&&!(i&iu.LEFT)&&(W=P-(B-s)*R,r=W>=a&&W<=g)}return r}function Lee(e,n,t,r){var i=[];if(r>1)for(var o=e[2]-e[0],s=e[3]-e[1],a=0;a<r;++a)i.push(e[0]+o*a/r,e[1],e[2],e[1]+s*a/r,e[2]-o*a/r,e[3],e[0],e[3]-s*a/r);else i=[e[0],e[1],e[2],e[1],e[2],e[3],e[0],e[3]];n(i,i,2);for(var f=[],g=[],a=0,x=i.length;a<x;a+=2)f.push(i[a]),g.push(i[a+1]);return Pee(f,g,t)}function CL(e,n){var t=n.getExtent(),r=Dm(e);if(n.canWrapX()&&(r[0]<t[0]||r[0]>=t[2])){var i=os(t),o=Math.floor((r[0]-t[0])/i),s=o*i;e[0]-=s,e[2]-=s}return e}function zee(e,n){if(n.canWrapX()){var t=n.getExtent();if(!isFinite(e[0])||!isFinite(e[2]))return[[t[0],e[1],t[2],e[3]]];CL(e,n);var r=os(t);if(os(e)>r)return[[t[0],e[1],t[2],e[3]]];if(e[0]<t[0])return[[e[0]+r,e[1],t[2],e[3]],[t[0],e[1],e[2],e[3]]];if(e[2]>t[2])return[[e[0],e[1],t[2],e[3]],[t[0],e[1],e[2]-r,e[3]]]}return[e]}var jee=function(){function e(n){this.code_=n.code,this.units_=n.units,this.extent_=n.extent!==void 0?n.extent:null,this.worldExtent_=n.worldExtent!==void 0?n.worldExtent:null,this.axisOrientation_=n.axisOrientation!==void 0?n.axisOrientation:"enu",this.global_=n.global!==void 0?n.global:!1,this.canWrapX_=!!(this.global_&&this.extent_),this.getPointResolutionFunc_=n.getPointResolution,this.defaultTileGrid_=null,this.metersPerUnit_=n.metersPerUnit}return e.prototype.canWrapX=function(){return this.canWrapX_},e.prototype.getCode=function(){return this.code_},e.prototype.getExtent=function(){return this.extent_},e.prototype.getUnits=function(){return this.units_},e.prototype.getMetersPerUnit=function(){return this.metersPerUnit_||cf[this.units_]},e.prototype.getWorldExtent=function(){return this.worldExtent_},e.prototype.getAxisOrientation=function(){return this.axisOrientation_},e.prototype.isGlobal=function(){return this.global_},e.prototype.setGlobal=function(n){this.global_=n,this.canWrapX_=!!(n&&this.extent_)},e.prototype.getDefaultTileGrid=function(){return this.defaultTileGrid_},e.prototype.setDefaultTileGrid=function(n){this.defaultTileGrid_=n},e.prototype.setExtent=function(n){this.extent_=n,this.canWrapX_=!!(this.global_&&n)},e.prototype.setWorldExtent=function(n){this.worldExtent_=n},e.prototype.setGetPointResolution=function(n){this.getPointResolutionFunc_=n},e.prototype.getPointResolutionFunc=function(){return this.getPointResolutionFunc_},e}();const GB=jee;function vl(e,n,t){return Math.min(Math.max(e,n),t)}var Wee=function(){var e;return"cosh"in Math?e=Math.cosh:e=function(n){var t=Math.exp(n);return(t+1/t)/2},e}(),Nee=function(){var e;return"log2"in Math?e=Math.log2:e=function(n){return Math.log(n)*Math.LOG2E},e}();function Gee(e,n,t,r,i,o){var s=i-t,a=o-r;if(s!==0||a!==0){var f=((e-t)*s+(n-r)*a)/(s*s+a*a);f>1?(t=i,r=o):f>0&&(t+=s*f,r+=a*f)}return J0(e,n,t,r)}function J0(e,n,t,r){var i=t-e,o=r-n;return i*i+o*o}function Qee(e){for(var n=e.length,t=0;t<n;t++){for(var r=t,i=Math.abs(e[t][t]),o=t+1;o<n;o++){var s=Math.abs(e[o][t]);s>i&&(i=s,r=o)}if(i===0)return null;var a=e[r];e[r]=e[t],e[t]=a;for(var f=t+1;f<n;f++)for(var g=-e[f][t]/e[t][t],x=t;x<n+1;x++)t==x?e[f][x]=0:e[f][x]+=g*e[t][x]}for(var k=new Array(n),B=n-1;B>=0;B--){k[B]=e[B][n]/e[B][B];for(var P=B-1;P>=0;P--)e[P][n]-=e[P][B]*k[B]}return k}function y2(e){return e*Math.PI/180}function e1(e,n){var t=e%n;return t*n<0?t+n:t}function Ap(e,n,t){return e+t*(n-e)}function _L(e,n){var t=Math.pow(10,n);return Math.round(e*t)/t}function yx(e,n){return Math.floor(_L(e,n))}function vx(e,n){return Math.ceil(_L(e,n))}var $ee=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),q_=6378137,Dg=Math.PI*q_,Yee=[-Dg,-Dg,Dg,Dg],qee=[-180,-85,180,85],Cx=q_*Math.log(Math.tan(Math.PI/2)),ig=function(e){$ee(n,e);function n(t){return e.call(this,{code:t,units:gA.METERS,extent:Yee,global:!0,worldExtent:qee,getPointResolution:function(r,i){return r/Wee(i[1]/q_)}})||this}return n}(GB),o9=[new ig("EPSG:3857"),new ig("EPSG:102100"),new ig("EPSG:102113"),new ig("EPSG:900913"),new ig("http://www.opengis.net/def/crs/EPSG/0/3857"),new ig("http://www.opengis.net/gml/srs/epsg.xml#3857")];function Vee(e,n,t){var r=e.length,i=t>1?t:2,o=n;o===void 0&&(i>2?o=e.slice():o=new Array(r));for(var s=0;s<r;s+=i){o[s]=Dg*e[s]/180;var a=q_*Math.log(Math.tan(Math.PI*(+e[s+1]+90)/360));a>Cx?a=Cx:a<-Cx&&(a=-Cx),o[s+1]=a}return o}function Hee(e,n,t){var r=e.length,i=t>1?t:2,o=n;o===void 0&&(i>2?o=e.slice():o=new Array(r));for(var s=0;s<r;s+=i)o[s]=180*e[s]/Dg,o[s+1]=360*Math.atan(Math.exp(e[s+1]/q_))/Math.PI-90;return o}var Zee=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Xee=6378137,a9=[-180,-90,180,90],Jee=Math.PI*Xee/180,g0=function(e){Zee(n,e);function n(t,r){return e.call(this,{code:t,units:gA.DEGREES,extent:a9,axisOrientation:r,global:!0,metersPerUnit:Jee,worldExtent:a9})||this}return n}(GB),s9=[new g0("CRS:84"),new g0("EPSG:4326","neu"),new g0("urn:ogc:def:crs:OGC:1.3:CRS84"),new g0("urn:ogc:def:crs:OGC:2:84"),new g0("http://www.opengis.net/def/crs/OGC/1.3/CRS84"),new g0("http://www.opengis.net/gml/srs/epsg.xml#4326","neu"),new g0("http://www.opengis.net/def/crs/EPSG/0/4326","neu")],W6={};function ete(e){return W6[e]||W6[e.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/,"EPSG:$3")]||null}function tte(e,n){W6[e]=n}var ny={};function C3(e,n,t){var r=e.getCode(),i=n.getCode();r in ny||(ny[r]={}),ny[r][i]=t}function nte(e,n){var t;return e in ny&&n in ny[e]&&(t=ny[e][n]),t}function rte(e,n){return e[0]+=+n[0],e[1]+=+n[1],e}function _3(e,n){for(var t=!0,r=e.length-1;r>=0;--r)if(e[r]!=n[r]){t=!1;break}return t}function QB(e,n){var t=Math.cos(n),r=Math.sin(n),i=e[0]*t-e[1]*r,o=e[1]*t+e[0]*r;return e[0]=i,e[1]=o,e}function ite(e,n){return e[0]*=n,e[1]*=n,e}function $B(e,n){if(n.canWrapX()){var t=os(n.getExtent()),r=ote(e,n,t);r&&(e[0]-=r*t)}return e}function ote(e,n,t){var r=n.getExtent(),i=0;if(n.canWrapX()&&(e[0]<r[0]||e[0]>r[2])){var o=t||os(r);i=Math.floor((e[0]-r[0])/o)}return i}var ate=63710088e-1;function l9(e,n,t){var r=t||ate,i=y2(e[1]),o=y2(n[1]),s=(o-i)/2,a=y2(n[0]-e[0])/2,f=Math.sin(s)*Math.sin(s)+Math.sin(a)*Math.sin(a)*Math.cos(i)*Math.cos(o);return 2*r*Math.atan2(Math.sqrt(f),Math.sqrt(1-f))}var N6=!0;function bL(e){var n=e===void 0?!0:e;N6=!n}function YB(e,n,t){var r;if(n!==void 0){for(var i=0,o=e.length;i<o;++i)n[i]=e[i];r=n}else r=e.slice();return r}function xL(e,n,t){if(n!==void 0&&e!==n){for(var r=0,i=e.length;r<i;++r)n[r]=e[r];e=n}return e}function ste(e){tte(e.getCode(),e),C3(e,e,YB)}function lte(e){e.forEach(ste)}function Fs(e){return typeof e=="string"?ete(e):e||null}function u9(e,n,t,r){e=Fs(e);var i,o=e.getPointResolutionFunc();if(o){if(i=o(n,t),r&&r!==e.getUnits()){var s=e.getMetersPerUnit();s&&(i=i*s/cf[r])}}else{var a=e.getUnits();if(a==gA.DEGREES&&!r||r==gA.DEGREES)i=n;else{var f=u5(e,Fs("EPSG:4326"));if(f===xL&&a!==gA.DEGREES)i=n*e.getMetersPerUnit();else{var g=[t[0]-n/2,t[1],t[0]+n/2,t[1],t[0],t[1]-n/2,t[0],t[1]+n/2];g=f(g,g,2);var x=l9(g.slice(0,2),g.slice(2,4)),k=l9(g.slice(4,6),g.slice(6,8));i=(x+k)/2}var s=r?cf[r]:e.getMetersPerUnit();s!==void 0&&(i/=s)}}return i}function A9(e){lte(e),e.forEach(function(n){e.forEach(function(t){n!==t&&C3(n,t,YB)})})}function ute(e,n,t,r){e.forEach(function(i){n.forEach(function(o){C3(i,o,t),C3(o,i,r)})})}function qB(e,n){return e?typeof e=="string"?Fs(e):e:Fs(n)}function G6(e,n){return bL(),VB(e,"EPSG:4326",n!==void 0?n:"EPSG:3857")}function lM(e,n){var t=VB(e,n!==void 0?n:"EPSG:3857","EPSG:4326"),r=t[0];return(r<-180||r>180)&&(t[0]=e1(r+180,360)-180),t}function I0(e,n){if(e===n)return!0;var t=e.getUnits()===n.getUnits();if(e.getCode()===n.getCode())return t;var r=u5(e,n);return r===YB&&t}function u5(e,n){var t=e.getCode(),r=n.getCode(),i=nte(t,r);return i||(i=xL),i}function b3(e,n){var t=Fs(e),r=Fs(n);return u5(t,r)}function VB(e,n,t){var r=b3(n,t);return r(e,void 0,e.length)}var Ate=null;function cte(){return Ate}function Q6(e,n){return e}function rp(e,n){return N6&&!_3(e,[0,0])&&e[0]>=-180&&e[0]<=180&&e[1]>=-90&&e[1]<=90&&(N6=!1,console.warn("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),e}function wL(e,n){return e}function j0(e,n){return e}function dte(){A9(o9),A9(s9),ute(s9,o9,Vee,Hee)}dte();function Om(e,n,t,r,i,o){for(var s=o||[],a=0,f=n;f<t;f+=r){var g=e[f],x=e[f+1];s[a++]=i[0]*g+i[2]*x+i[4],s[a++]=i[1]*g+i[3]*x+i[5]}return o&&s.length!=a&&(s.length=a),s}function ML(e,n,t,r,i,o,s){for(var a=s||[],f=Math.cos(i),g=Math.sin(i),x=o[0],k=o[1],B=0,P=n;P<t;P+=r){var R=e[P]-x,H=e[P+1]-k;a[B++]=x+R*f-H*g,a[B++]=k+R*g+H*f;for(var W=P+2;W<P+r;++W)a[B++]=e[W]}return s&&a.length!=B&&(a.length=B),a}function hte(e,n,t,r,i,o,s,a){for(var f=a||[],g=s[0],x=s[1],k=0,B=n;B<t;B+=r){var P=e[B]-g,R=e[B+1]-x;f[k++]=g+i*P,f[k++]=x+o*R;for(var H=B+2;H<B+r;++H)f[k++]=e[H]}return a&&f.length!=k&&(f.length=k),f}function fte(e,n,t,r,i,o,s){for(var a=s||[],f=0,g=n;g<t;g+=r){a[f++]=e[g]+i,a[f++]=e[g+1]+o;for(var x=g+2;x<g+r;++x)a[f++]=e[x]}return s&&a.length!=f&&(a.length=f),a}var pte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),c9=xd(),mte=function(e){pte(n,e);function n(){var t=e.call(this)||this;return t.extent_=Ed(),t.extentRevision_=-1,t.simplifiedGeometryMaxMinSquaredTolerance=0,t.simplifiedGeometryRevision=0,t.simplifyTransformedInternal=fee(function(r,i,o){if(!o)return this.getSimplifiedGeometry(i);var s=this.clone();return s.applyTransform(o),s.getSimplifiedGeometry(i)}),t}return n.prototype.simplifyTransformed=function(t,r){return this.simplifyTransformedInternal(this.getRevision(),t,r)},n.prototype.clone=function(){return li()},n.prototype.closestPointXY=function(t,r,i,o){return li()},n.prototype.containsXY=function(t,r){var i=this.getClosestPoint([t,r]);return i[0]===t&&i[1]===r},n.prototype.getClosestPoint=function(t,r){var i=r||[NaN,NaN];return this.closestPointXY(t[0],t[1],i,1/0),i},n.prototype.intersectsCoordinate=function(t){return this.containsXY(t[0],t[1])},n.prototype.computeExtent=function(t){return li()},n.prototype.getExtent=function(t){if(this.extentRevision_!=this.getRevision()){var r=this.computeExtent(this.extent_);(isNaN(r[0])||isNaN(r[1]))&&Y_(r),this.extentRevision_=this.getRevision()}return Uee(this.extent_,t)},n.prototype.rotate=function(t,r){li()},n.prototype.scale=function(t,r,i){li()},n.prototype.simplify=function(t){return this.getSimplifiedGeometry(t*t)},n.prototype.getSimplifiedGeometry=function(t){return li()},n.prototype.getType=function(){return li()},n.prototype.applyTransform=function(t){li()},n.prototype.intersectsExtent=function(t){return li()},n.prototype.translate=function(t,r){li()},n.prototype.transform=function(t,r){var i=Fs(t),o=i.getUnits()==gA.TILE_PIXELS?function(s,a,f){var g=i.getExtent(),x=i.getWorldExtent(),k=$A(x)/$A(g);return df(c9,x[0],x[3],k,-k,0,0,0),Om(s,0,s.length,f,c9,a),b3(i,r)(s,a,f)}:b3(i,r);return this.applyTransform(o),this},n}(mh);const SL=mte;var gte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),yte=function(e){gte(n,e);function n(t){var r=e.call(this)||this;return r.geometries_=t||null,r.changeEventsKeys_=[],r.listenGeometriesChange_(),r}return n.prototype.unlistenGeometriesChange_=function(){this.changeEventsKeys_.forEach(Ga),this.changeEventsKeys_.length=0},n.prototype.listenGeometriesChange_=function(){if(this.geometries_)for(var t=0,r=this.geometries_.length;t<r;++t)this.changeEventsKeys_.push(wo(this.geometries_[t],ki.CHANGE,this.changed,this))},n.prototype.clone=function(){var t=new n(null);return t.setGeometries(this.geometries_),t.applyProperties(this),t},n.prototype.closestPointXY=function(t,r,i,o){if(o<b1(this.getExtent(),t,r))return o;for(var s=this.geometries_,a=0,f=s.length;a<f;++a)o=s[a].closestPointXY(t,r,i,o);return o},n.prototype.containsXY=function(t,r){for(var i=this.geometries_,o=0,s=i.length;o<s;++o)if(i[o].containsXY(t,r))return!0;return!1},n.prototype.computeExtent=function(t){Y_(t);for(var r=this.geometries_,i=0,o=r.length;i<o;++i)gL(t,r[i].getExtent());return t},n.prototype.getGeometries=function(){return d9(this.geometries_)},n.prototype.getGeometriesArray=function(){return this.geometries_},n.prototype.getGeometriesArrayRecursive=function(){for(var t=[],r=this.geometries_,i=0,o=r.length;i<o;++i)r[i].getType()===this.getType()?t=t.concat(r[i].getGeometriesArrayRecursive()):t.push(r[i]);return t},n.prototype.getSimplifiedGeometry=function(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||this.simplifiedGeometryMaxMinSquaredTolerance!==0&&t<this.simplifiedGeometryMaxMinSquaredTolerance)return this;for(var r=[],i=this.geometries_,o=!1,s=0,a=i.length;s<a;++s){var f=i[s],g=f.getSimplifiedGeometry(t);r.push(g),g!==f&&(o=!0)}if(o){var x=new n(null);return x.setGeometriesArray(r),x}else return this.simplifiedGeometryMaxMinSquaredTolerance=t,this},n.prototype.getType=function(){return"GeometryCollection"},n.prototype.intersectsExtent=function(t){for(var r=this.geometries_,i=0,o=r.length;i<o;++i)if(r[i].intersectsExtent(t))return!0;return!1},n.prototype.isEmpty=function(){return this.geometries_.length===0},n.prototype.rotate=function(t,r){for(var i=this.geometries_,o=0,s=i.length;o<s;++o)i[o].rotate(t,r);this.changed()},n.prototype.scale=function(t,r,i){var o=i;o||(o=Dm(this.getExtent()));for(var s=this.geometries_,a=0,f=s.length;a<f;++a)s[a].scale(t,r,o);this.changed()},n.prototype.setGeometries=function(t){this.setGeometriesArray(d9(t))},n.prototype.setGeometriesArray=function(t){this.unlistenGeometriesChange_(),this.geometries_=t,this.listenGeometriesChange_(),this.changed()},n.prototype.applyTransform=function(t){for(var r=this.geometries_,i=0,o=r.length;i<o;++i)r[i].applyTransform(t);this.changed()},n.prototype.translate=function(t,r){for(var i=this.geometries_,o=0,s=i.length;o<s;++o)i[o].translate(t,r);this.changed()},n.prototype.disposeInternal=function(){this.unlistenGeometriesChange_(),e.prototype.disposeInternal.call(this)},n}(SL);function d9(e){for(var n=[],t=0,r=e.length;t<r;++t)n.push(e[t].clone());return n}const vte=yte;var EL=function(){function e(){this.dataProjection=void 0,this.defaultFeatureProjection=void 0,this.supportedMediaTypes=null}return e.prototype.getReadOptions=function(n,t){var r;if(t){var i=t.dataProjection?Fs(t.dataProjection):this.readProjection(n);t.extent&&i&&i.getUnits()===gA.TILE_PIXELS&&(i=Fs(i),i.setWorldExtent(t.extent)),r={dataProjection:i,featureProjection:t.featureProjection}}return this.adaptOptions(r)},e.prototype.adaptOptions=function(n){return al({dataProjection:this.dataProjection,featureProjection:this.defaultFeatureProjection},n)},e.prototype.getType=function(){return li()},e.prototype.readFeature=function(n,t){return li()},e.prototype.readFeatures=function(n,t){return li()},e.prototype.readGeometry=function(n,t){return li()},e.prototype.readProjection=function(n){return li()},e.prototype.writeFeature=function(n,t){return li()},e.prototype.writeFeatures=function(n,t){return li()},e.prototype.writeGeometry=function(n,t){return li()},e}();function HB(e,n,t){var r=t?Fs(t.featureProjection):null,i=t?Fs(t.dataProjection):null,o;if(r&&i&&!I0(r,i)?o=(n?e.clone():e).transform(n?r:i,n?i:r):o=e,n&&t&&t.decimals!==void 0){var s=Math.pow(10,t.decimals),a=function(f){for(var g=0,x=f.length;g<x;++g)f[g]=Math.round(f[g]*s)/s;return f};o===e&&(o=e.clone()),o.applyTransform(a)}return o}var Cte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),_te=function(e){Cte(n,e);function n(){return e.call(this)||this}return n.prototype.getType=function(){return"json"},n.prototype.readFeature=function(t,r){return this.readFeatureFromObject(_x(t),this.getReadOptions(t,r))},n.prototype.readFeatures=function(t,r){return this.readFeaturesFromObject(_x(t),this.getReadOptions(t,r))},n.prototype.readFeatureFromObject=function(t,r){return li()},n.prototype.readFeaturesFromObject=function(t,r){return li()},n.prototype.readGeometry=function(t,r){return this.readGeometryFromObject(_x(t),this.getReadOptions(t,r))},n.prototype.readGeometryFromObject=function(t,r){return li()},n.prototype.readProjection=function(t){return this.readProjectionFromObject(_x(t))},n.prototype.readProjectionFromObject=function(t){return li()},n.prototype.writeFeature=function(t,r){return JSON.stringify(this.writeFeatureObject(t,r))},n.prototype.writeFeatureObject=function(t,r){return li()},n.prototype.writeFeatures=function(t,r){return JSON.stringify(this.writeFeaturesObject(t,r))},n.prototype.writeFeaturesObject=function(t,r){return li()},n.prototype.writeGeometry=function(t,r){return JSON.stringify(this.writeGeometryObject(t,r))},n.prototype.writeGeometryObject=function(t,r){return li()},n}(EL);function _x(e){if(typeof e=="string"){var n=JSON.parse(e);return n||null}else return e!==null?e:null}const bte=_te,Ta={XY:"XY",XYZ:"XYZ",XYM:"XYM",XYZM:"XYZM"};var xte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),wte=function(e){xte(n,e);function n(){var t=e.call(this)||this;return t.layout=Ta.XY,t.stride=2,t.flatCoordinates=null,t}return n.prototype.computeExtent=function(t){return WB(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)},n.prototype.getCoordinates=function(){return li()},n.prototype.getFirstCoordinate=function(){return this.flatCoordinates.slice(0,this.stride)},n.prototype.getFlatCoordinates=function(){return this.flatCoordinates},n.prototype.getLastCoordinate=function(){return this.flatCoordinates.slice(this.flatCoordinates.length-this.stride)},n.prototype.getLayout=function(){return this.layout},n.prototype.getSimplifiedGeometry=function(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||this.simplifiedGeometryMaxMinSquaredTolerance!==0&&t<=this.simplifiedGeometryMaxMinSquaredTolerance)return this;var r=this.getSimplifiedGeometryInternal(t),i=r.getFlatCoordinates();return i.length<this.flatCoordinates.length?r:(this.simplifiedGeometryMaxMinSquaredTolerance=t,this)},n.prototype.getSimplifiedGeometryInternal=function(t){return this},n.prototype.getStride=function(){return this.stride},n.prototype.setFlatCoordinates=function(t,r){this.stride=h9(t),this.layout=t,this.flatCoordinates=r},n.prototype.setCoordinates=function(t,r){li()},n.prototype.setLayout=function(t,r,i){var o;if(t)o=h9(t);else{for(var s=0;s<i;++s)if(r.length===0){this.layout=Ta.XY,this.stride=2;return}else r=r[0];o=r.length,t=Mte(o)}this.layout=t,this.stride=o},n.prototype.applyTransform=function(t){this.flatCoordinates&&(t(this.flatCoordinates,this.flatCoordinates,this.stride),this.changed())},n.prototype.rotate=function(t,r){var i=this.getFlatCoordinates();if(i){var o=this.getStride();ML(i,0,i.length,o,t,r,i),this.changed()}},n.prototype.scale=function(t,r,i){var o=r;o===void 0&&(o=t);var s=i;s||(s=Dm(this.getExtent()));var a=this.getFlatCoordinates();if(a){var f=this.getStride();hte(a,0,a.length,f,t,o,s,a),this.changed()}},n.prototype.translate=function(t,r){var i=this.getFlatCoordinates();if(i){var o=this.getStride();fte(i,0,i.length,o,t,r,i),this.changed()}},n}(SL);function Mte(e){var n;return e==2?n=Ta.XY:e==3?n=Ta.XYZ:e==4&&(n=Ta.XYZM),n}function h9(e){var n;return e==Ta.XY?n=2:e==Ta.XYZ||e==Ta.XYM?n=3:e==Ta.XYZM&&(n=4),n}function Ste(e,n,t){var r=e.getFlatCoordinates();if(r){var i=e.getStride();return Om(r,0,r.length,i,n,t)}else return null}const x1=wte;function f9(e,n,t,r,i,o,s){var a=e[n],f=e[n+1],g=e[t]-a,x=e[t+1]-f,k;if(g===0&&x===0)k=n;else{var B=((i-a)*g+(o-f)*x)/(g*g+x*x);if(B>1)k=t;else if(B>0){for(var P=0;P<r;++P)s[P]=Ap(e[n+P],e[t+P],B);s.length=r;return}else k=n}for(var P=0;P<r;++P)s[P]=e[k+P];s.length=r}function ZB(e,n,t,r,i){var o=e[n],s=e[n+1];for(n+=r;n<t;n+=r){var a=e[n],f=e[n+1],g=J0(o,s,a,f);g>i&&(i=g),o=a,s=f}return i}function XB(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];i=ZB(e,n,a,r,i),n=a}return i}function Ete(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];i=XB(e,n,a,r,i),n=a[a.length-1]}return i}function JB(e,n,t,r,i,o,s,a,f,g,x){if(n==t)return g;var k,B;if(i===0)if(B=J0(s,a,e[n],e[n+1]),B<g){for(k=0;k<r;++k)f[k]=e[n+k];return f.length=r,B}else return g;for(var P=x||[NaN,NaN],R=n+r;R<t;)if(f9(e,R-r,R,r,s,a,P),B=J0(s,a,P[0],P[1]),B<g){for(g=B,k=0;k<r;++k)f[k]=P[k];f.length=r,R+=r}else R+=r*Math.max((Math.sqrt(B)-Math.sqrt(g))/i|0,1);if(o&&(f9(e,t-r,n,r,s,a,P),B=J0(s,a,P[0],P[1]),B<g)){for(g=B,k=0;k<r;++k)f[k]=P[k];f.length=r}return g}function e7(e,n,t,r,i,o,s,a,f,g,x){for(var k=x||[NaN,NaN],B=0,P=t.length;B<P;++B){var R=t[B];g=JB(e,n,R,r,i,o,s,a,f,g,k),n=R}return g}function Ote(e,n,t,r,i,o,s,a,f,g,x){for(var k=x||[NaN,NaN],B=0,P=t.length;B<P;++B){var R=t[B];g=e7(e,n,R,r,i,o,s,a,f,g,k),n=R[R.length-1]}return g}function Bte(e,n,t,r){for(var i=0,o=t.length;i<o;++i)e[n++]=t[i];return n}function A5(e,n,t,r){for(var i=0,o=t.length;i<o;++i)for(var s=t[i],a=0;a<r;++a)e[n++]=s[a];return n}function t7(e,n,t,r,i){for(var o=i||[],s=0,a=0,f=t.length;a<f;++a){var g=A5(e,n,t[a],r);o[s++]=g,n=g}return o.length=s,o}function kte(e,n,t,r,i){for(var o=i||[],s=0,a=0,f=t.length;a<f;++a){var g=t7(e,n,t[a],r,o[s]);o[s++]=g,n=g[g.length-1]}return o.length=s,o}function n7(e,n,t,r,i,o,s){var a=(t-n)/r;if(a<3){for(;n<t;n+=r)o[s++]=e[n],o[s++]=e[n+1];return s}var f=new Array(a);f[0]=1,f[a-1]=1;for(var g=[n,t-r],x=0;g.length>0;){for(var k=g.pop(),B=g.pop(),P=0,R=e[B],H=e[B+1],W=e[k],$=e[k+1],q=B+r;q<k;q+=r){var oe=e[q],ne=e[q+1],ce=Gee(oe,ne,R,H,W,$);ce>P&&(x=q,P=ce)}P>i&&(f[(x-n)/r]=1,B+r<x&&g.push(B,x),x+r<k&&g.push(x,k))}for(var q=0;q<a;++q)f[q]&&(o[s++]=e[n+q*r],o[s++]=e[n+q*r+1]);return s}function Ite(e,n,t,r,i,o,s,a){for(var f=0,g=t.length;f<g;++f){var x=t[f];s=n7(e,n,x,r,i,o,s),a.push(s),n=x}return s}function S0(e,n){return n*Math.round(e/n)}function Tte(e,n,t,r,i,o,s){if(n==t)return s;var a=S0(e[n],i),f=S0(e[n+1],i);n+=r,o[s++]=a,o[s++]=f;var g,x;do if(g=S0(e[n],i),x=S0(e[n+1],i),n+=r,n==t)return o[s++]=g,o[s++]=x,s;while(g==a&&x==f);for(;n<t;){var k=S0(e[n],i),B=S0(e[n+1],i);if(n+=r,!(k==g&&B==x)){var P=g-a,R=x-f,H=k-a,W=B-f;if(P*W==R*H&&(P<0&&H<P||P==H||P>0&&H>P)&&(R<0&&W<R||R==W||R>0&&W>R)){g=k,x=B;continue}o[s++]=g,o[s++]=x,a=g,f=x,g=k,x=B}}return o[s++]=g,o[s++]=x,s}function OL(e,n,t,r,i,o,s,a){for(var f=0,g=t.length;f<g;++f){var x=t[f];s=Tte(e,n,x,r,i,o,s),a.push(s),n=x}return s}function Kte(e,n,t,r,i,o,s,a){for(var f=0,g=t.length;f<g;++f){var x=t[f],k=[];s=OL(e,n,x,r,i,o,s,k),a.push(k),n=x[x.length-1]}return s}function BL(e,n,t,r,i){var o;for(n+=r;n<t;n+=r)if(o=i(e.slice(n-r,n),e.slice(n,n+r)),o)return o;return!1}function dm(e,n,t,r,i){for(var o=i!==void 0?i:[],s=0,a=n;a<t;a+=r)o[s++]=e.slice(a,a+r);return o.length=s,o}function u_(e,n,t,r,i){for(var o=i!==void 0?i:[],s=0,a=0,f=t.length;a<f;++a){var g=t[a];o[s++]=dm(e,n,g,r,o[s]),n=g}return o.length=s,o}function $6(e,n,t,r,i){for(var o=i!==void 0?i:[],s=0,a=0,f=t.length;a<f;++a){var g=t[a];o[s++]=u_(e,n,g,r,o[s]),n=g[g.length-1]}return o.length=s,o}function x3(e,n,t,r,i,o,s){var a,f,g=(t-n)/r;if(g===1)a=n;else if(g===2)a=n,f=i;else if(g!==0){for(var x=e[n],k=e[n+1],B=0,P=[0],R=n+r;R<t;R+=r){var H=e[R],W=e[R+1];B+=Math.sqrt((H-x)*(H-x)+(W-k)*(W-k)),P.push(B),x=H,k=W}var $=i*B,q=cee(P,$);q<0?(f=($-P[-q-2])/(P[-q-1]-P[-q-2]),a=n+(-q-2)*r):a=n+q*r}for(var oe=s>1?s:2,ne=o||new Array(oe),R=0;R<oe;++R)ne[R]=a===void 0?NaN:f===void 0?e[a+R]:Ap(e[a+R],e[a+r+R],f);return ne}function Y6(e,n,t,r,i,o){if(t==n)return null;var s;if(i<e[n+r-1])return o?(s=e.slice(n,n+r),s[r-1]=i,s):null;if(e[t-1]<i)return o?(s=e.slice(t-r,t),s[r-1]=i,s):null;if(i==e[n+r-1])return e.slice(n,n+r);for(var a=n/r,f=t/r;a<f;){var g=a+f>>1;i<e[(g+1)*r-1]?f=g:a=g+1}var x=e[a*r-1];if(i==x)return e.slice((a-1)*r,(a-1)*r+r);var k=e[(a+1)*r-1],B=(i-x)/(k-x);s=[];for(var P=0;P<r-1;++P)s.push(Ap(e[(a-1)*r+P],e[a*r+P],B));return s.push(i),s}function Pte(e,n,t,r,i,o,s){if(s)return Y6(e,n,t[t.length-1],r,i,o);var a;if(i<e[r-1])return o?(a=e.slice(0,r),a[r-1]=i,a):null;if(e[e.length-1]<i)return o?(a=e.slice(e.length-r),a[r-1]=i,a):null;for(var f=0,g=t.length;f<g;++f){var x=t[f];if(n!=x){if(i<e[n+r-1])return null;if(i<=e[x-1])return Y6(e,n,x,r,i,!1);n=x}}return null}function Fte(e,n,t,r,i){var o=vL(i,function(s){return!W0(e,n,t,r,s[0],s[1])});return!o}function W0(e,n,t,r,i,o){for(var s=0,a=e[t-r],f=e[t-r+1];n<t;n+=r){var g=e[n],x=e[n+1];f<=o?x>o&&(g-a)*(o-f)-(i-a)*(x-f)>0&&s++:x<=o&&(g-a)*(o-f)-(i-a)*(x-f)<0&&s--,a=g,f=x}return s!==0}function r7(e,n,t,r,i,o){if(t.length===0||!W0(e,n,t[0],r,i,o))return!1;for(var s=1,a=t.length;s<a;++s)if(W0(e,t[s-1],t[s],r,i,o))return!1;return!0}function Dte(e,n,t,r,i,o){if(t.length===0)return!1;for(var s=0,a=t.length;s<a;++s){var f=t[s];if(r7(e,n,f,r,i,o))return!0;n=f[f.length-1]}return!1}function c5(e,n,t,r,i){var o=yL(Ed(),e,n,t,r);return il(i,o)?cm(i,o)||o[0]>=i[0]&&o[2]<=i[2]||o[1]>=i[1]&&o[3]<=i[3]?!0:BL(e,n,t,r,function(s,a){return Ree(i,s,a)}):!1}function Ute(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){if(c5(e,n,t[o],r,i))return!0;n=t[o]}return!1}function kL(e,n,t,r,i){return!!(c5(e,n,t,r,i)||W0(e,n,t,r,i[0],i[1])||W0(e,n,t,r,i[0],i[3])||W0(e,n,t,r,i[2],i[1])||W0(e,n,t,r,i[2],i[3]))}function IL(e,n,t,r,i){if(!kL(e,n,t[0],r,i))return!1;if(t.length===1)return!0;for(var o=1,s=t.length;o<s;++o)if(Fte(e,t[o-1],t[o],r,i)&&!c5(e,t[o-1],t[o],r,i))return!1;return!0}function Rte(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];if(IL(e,n,a,r,i))return!0;n=a[a.length-1]}return!1}function TL(e,n,t,r){for(var i=e[n],o=e[n+1],s=0,a=n+r;a<t;a+=r){var f=e[a],g=e[a+1];s+=Math.sqrt((f-i)*(f-i)+(g-o)*(g-o)),i=f,o=g}return s}var Lte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),zte=function(e){Lte(n,e);function n(t,r){var i=e.call(this)||this;return i.flatMidpoint_=null,i.flatMidpointRevision_=-1,i.maxDelta_=-1,i.maxDeltaRevision_=-1,r!==void 0&&!Array.isArray(t[0])?i.setFlatCoordinates(r,t):i.setCoordinates(t,r),i}return n.prototype.appendCoordinate=function(t){this.flatCoordinates?sf(this.flatCoordinates,t):this.flatCoordinates=t.slice(),this.changed()},n.prototype.clone=function(){var t=new n(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t},n.prototype.closestPointXY=function(t,r,i,o){return o<b1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(ZB(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),JB(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!1,t,r,i,o))},n.prototype.forEachSegment=function(t){return BL(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)},n.prototype.getCoordinateAtM=function(t,r){if(this.layout!=Ta.XYM&&this.layout!=Ta.XYZM)return null;var i=r!==void 0?r:!1;return Y6(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,i)},n.prototype.getCoordinates=function(){return dm(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getCoordinateAt=function(t,r){return x3(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,r,this.stride)},n.prototype.getLength=function(){return TL(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getFlatMidpoint=function(){return this.flatMidpointRevision_!=this.getRevision()&&(this.flatMidpoint_=this.getCoordinateAt(.5,this.flatMidpoint_),this.flatMidpointRevision_=this.getRevision()),this.flatMidpoint_},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[];return r.length=n7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,r,0),new n(r,Ta.XY)},n.prototype.getType=function(){return"LineString"},n.prototype.intersectsExtent=function(t){return c5(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=A5(this.flatCoordinates,0,t,this.stride),this.changed()},n}(x1);const w3=zte;var jte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Wte=function(e){jte(n,e);function n(t,r,i){var o=e.call(this)||this;if(o.ends_=[],o.maxDelta_=-1,o.maxDeltaRevision_=-1,Array.isArray(t[0]))o.setCoordinates(t,r);else if(r!==void 0&&i)o.setFlatCoordinates(r,t),o.ends_=i;else{for(var s=o.getLayout(),a=t,f=[],g=[],x=0,k=a.length;x<k;++x){var B=a[x];x===0&&(s=B.getLayout()),sf(f,B.getFlatCoordinates()),g.push(f.length)}o.setFlatCoordinates(s,f),o.ends_=g}return o}return n.prototype.appendLineString=function(t){this.flatCoordinates?sf(this.flatCoordinates,t.getFlatCoordinates().slice()):this.flatCoordinates=t.getFlatCoordinates().slice(),this.ends_.push(this.flatCoordinates.length),this.changed()},n.prototype.clone=function(){var t=new n(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t},n.prototype.closestPointXY=function(t,r,i,o){return o<b1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(XB(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),e7(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!1,t,r,i,o))},n.prototype.getCoordinateAtM=function(t,r,i){if(this.layout!=Ta.XYM&&this.layout!=Ta.XYZM||this.flatCoordinates.length===0)return null;var o=r!==void 0?r:!1,s=i!==void 0?i:!1;return Pte(this.flatCoordinates,0,this.ends_,this.stride,t,o,s)},n.prototype.getCoordinates=function(){return u_(this.flatCoordinates,0,this.ends_,this.stride)},n.prototype.getEnds=function(){return this.ends_},n.prototype.getLineString=function(t){return t<0||this.ends_.length<=t?null:new w3(this.flatCoordinates.slice(t===0?0:this.ends_[t-1],this.ends_[t]),this.layout)},n.prototype.getLineStrings=function(){for(var t=this.flatCoordinates,r=this.ends_,i=this.layout,o=[],s=0,a=0,f=r.length;a<f;++a){var g=r[a],x=new w3(t.slice(s,g),i);o.push(x),s=g}return o},n.prototype.getFlatMidpoints=function(){for(var t=[],r=this.flatCoordinates,i=0,o=this.ends_,s=this.stride,a=0,f=o.length;a<f;++a){var g=o[a],x=x3(r,i,g,s,.5);sf(t,x),i=g}return t},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[],i=[];return r.length=Ite(this.flatCoordinates,0,this.ends_,this.stride,t,r,0,i),new n(r,Ta.XY,i)},n.prototype.getType=function(){return"MultiLineString"},n.prototype.intersectsExtent=function(t){return Ute(this.flatCoordinates,0,this.ends_,this.stride,t)},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,2),this.flatCoordinates||(this.flatCoordinates=[]);var i=t7(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=i.length===0?0:i[i.length-1],this.changed()},n}(x1);const KL=Wte;var Nte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Gte=function(e){Nte(n,e);function n(t,r){var i=e.call(this)||this;return i.setCoordinates(t,r),i}return n.prototype.clone=function(){var t=new n(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t},n.prototype.closestPointXY=function(t,r,i,o){var s=this.flatCoordinates,a=J0(t,r,s[0],s[1]);if(a<o){for(var f=this.stride,g=0;g<f;++g)i[g]=s[g];return i.length=f,a}else return o},n.prototype.getCoordinates=function(){return this.flatCoordinates?this.flatCoordinates.slice():[]},n.prototype.computeExtent=function(t){return mL(this.flatCoordinates,t)},n.prototype.getType=function(){return"Point"},n.prototype.intersectsExtent=function(t){return jB(t,this.flatCoordinates[0],this.flatCoordinates[1])},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,0),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=Bte(this.flatCoordinates,0,t,this.stride),this.changed()},n}(x1);const A_=Gte;var Qte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),$te=function(e){Qte(n,e);function n(t,r){var i=e.call(this)||this;return r&&!Array.isArray(t[0])?i.setFlatCoordinates(r,t):i.setCoordinates(t,r),i}return n.prototype.appendPoint=function(t){this.flatCoordinates?sf(this.flatCoordinates,t.getFlatCoordinates()):this.flatCoordinates=t.getFlatCoordinates().slice(),this.changed()},n.prototype.clone=function(){var t=new n(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t},n.prototype.closestPointXY=function(t,r,i,o){if(o<b1(this.getExtent(),t,r))return o;for(var s=this.flatCoordinates,a=this.stride,f=0,g=s.length;f<g;f+=a){var x=J0(t,r,s[f],s[f+1]);if(x<o){o=x;for(var k=0;k<a;++k)i[k]=s[f+k];i.length=a}}return o},n.prototype.getCoordinates=function(){return dm(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getPoint=function(t){var r=this.flatCoordinates?this.flatCoordinates.length/this.stride:0;return t<0||r<=t?null:new A_(this.flatCoordinates.slice(t*this.stride,(t+1)*this.stride),this.layout)},n.prototype.getPoints=function(){for(var t=this.flatCoordinates,r=this.layout,i=this.stride,o=[],s=0,a=t.length;s<a;s+=i){var f=new A_(t.slice(s,s+i),r);o.push(f)}return o},n.prototype.getType=function(){return"MultiPoint"},n.prototype.intersectsExtent=function(t){for(var r=this.flatCoordinates,i=this.stride,o=0,s=r.length;o<s;o+=i){var a=r[o],f=r[o+1];if(jB(t,a,f))return!0}return!1},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=A5(this.flatCoordinates,0,t,this.stride),this.changed()},n}(x1);const i7=$te;function PL(e,n,t,r){for(var i=0,o=e[t-r],s=e[t-r+1];n<t;n+=r){var a=e[n],f=e[n+1];i+=s*a-o*f,o=a,s=f}return i/2}function FL(e,n,t,r){for(var i=0,o=0,s=t.length;o<s;++o){var a=t[o];i+=PL(e,n,a,r),n=a}return i}function Yte(e,n,t,r){for(var i=0,o=0,s=t.length;o<s;++o){var a=t[o];i+=FL(e,n,a,r),n=a[a.length-1]}return i}var qte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Vte=function(e){qte(n,e);function n(t,r){var i=e.call(this)||this;return i.maxDelta_=-1,i.maxDeltaRevision_=-1,r!==void 0&&!Array.isArray(t[0])?i.setFlatCoordinates(r,t):i.setCoordinates(t,r),i}return n.prototype.clone=function(){return new n(this.flatCoordinates.slice(),this.layout)},n.prototype.closestPointXY=function(t,r,i,o){return o<b1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(ZB(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),JB(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!0,t,r,i,o))},n.prototype.getArea=function(){return PL(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getCoordinates=function(){return dm(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[];return r.length=n7(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,r,0),new n(r,Ta.XY)},n.prototype.getType=function(){return"LinearRing"},n.prototype.intersectsExtent=function(t){return!1},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=A5(this.flatCoordinates,0,t,this.stride),this.changed()},n}(x1);const p9=Vte;function o7(e,n,t,r,i,o,s){for(var a,f,g,x,k,B,P,R=i[o+1],H=[],W=0,$=t.length;W<$;++W){var q=t[W];for(x=e[q-r],B=e[q-r+1],a=n;a<q;a+=r)k=e[a],P=e[a+1],(R<=B&&P<=R||B<=R&&R<=P)&&(g=(R-B)/(P-B)*(k-x)+x,H.push(g)),x=k,B=P}var oe=NaN,ne=-1/0;for(H.sort(c1),x=H[0],a=1,f=H.length;a<f;++a){k=H[a];var ce=Math.abs(k-x);ce>ne&&(g=(x+k)/2,r7(e,n,t,r,g,R)&&(oe=g,ne=ce)),x=k}return isNaN(oe)&&(oe=i[o]),s?(s.push(oe,R,ne),s):[oe,R,ne]}function DL(e,n,t,r,i){for(var o=[],s=0,a=t.length;s<a;++s){var f=t[s];o=o7(e,n,f,r,i,2*s,o),n=f[f.length-1]}return o}function Hte(e,n,t,r){for(;n<t-r;){for(var i=0;i<r;++i){var o=e[n+i];e[n+i]=e[t-r+i],e[t-r+i]=o}n+=r,t-=r}}function a7(e,n,t,r){for(var i=0,o=e[t-r],s=e[t-r+1];n<t;n+=r){var a=e[n],f=e[n+1];i+=(a-o)*(f+s),o=a,s=f}return i===0?void 0:i>0}function UL(e,n,t,r,i){for(var o=i!==void 0?i:!1,s=0,a=t.length;s<a;++s){var f=t[s],g=a7(e,n,f,r);if(s===0){if(o&&g||!o&&!g)return!1}else if(o&&!g||!o&&g)return!1;n=f}return!0}function Zte(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o){var a=t[o];if(!UL(e,n,a,r,i))return!1;a.length&&(n=a[a.length-1])}return!0}function q6(e,n,t,r,i){for(var o=i!==void 0?i:!1,s=0,a=t.length;s<a;++s){var f=t[s],g=a7(e,n,f,r),x=s===0?o&&g||!o&&!g:o&&!g||!o&&g;x&&Hte(e,n,f,r),n=f}return n}function m9(e,n,t,r,i){for(var o=0,s=t.length;o<s;++o)n=q6(e,n,t[o],r,i);return n}function Xte(e,n){for(var t=[],r=0,i=0,o=0,s=n.length;o<s;++o){var a=n[o];if(!a7(e,r,a,2))t.push(n.slice(i,o+1));else{if(t.length===0)continue;t[t.length-1].push(n[i])}i=o+1,r=a}return t}var Jte=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),RL=function(e){Jte(n,e);function n(t,r,i){var o=e.call(this)||this;return o.ends_=[],o.flatInteriorPointRevision_=-1,o.flatInteriorPoint_=null,o.maxDelta_=-1,o.maxDeltaRevision_=-1,o.orientedRevision_=-1,o.orientedFlatCoordinates_=null,r!==void 0&&i?(o.setFlatCoordinates(r,t),o.ends_=i):o.setCoordinates(t,r),o}return n.prototype.appendLinearRing=function(t){this.flatCoordinates?sf(this.flatCoordinates,t.getFlatCoordinates()):this.flatCoordinates=t.getFlatCoordinates().slice(),this.ends_.push(this.flatCoordinates.length),this.changed()},n.prototype.clone=function(){var t=new n(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t},n.prototype.closestPointXY=function(t,r,i,o){return o<b1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(XB(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),e7(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!0,t,r,i,o))},n.prototype.containsXY=function(t,r){return r7(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,r)},n.prototype.getArea=function(){return FL(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride)},n.prototype.getCoordinates=function(t){var r;return t!==void 0?(r=this.getOrientedFlatCoordinates().slice(),q6(r,0,this.ends_,this.stride,t)):r=this.flatCoordinates,u_(r,0,this.ends_,this.stride)},n.prototype.getEnds=function(){return this.ends_},n.prototype.getFlatInteriorPoint=function(){if(this.flatInteriorPointRevision_!=this.getRevision()){var t=Dm(this.getExtent());this.flatInteriorPoint_=o7(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,0),this.flatInteriorPointRevision_=this.getRevision()}return this.flatInteriorPoint_},n.prototype.getInteriorPoint=function(){return new A_(this.getFlatInteriorPoint(),Ta.XYM)},n.prototype.getLinearRingCount=function(){return this.ends_.length},n.prototype.getLinearRing=function(t){return t<0||this.ends_.length<=t?null:new p9(this.flatCoordinates.slice(t===0?0:this.ends_[t-1],this.ends_[t]),this.layout)},n.prototype.getLinearRings=function(){for(var t=this.layout,r=this.flatCoordinates,i=this.ends_,o=[],s=0,a=0,f=i.length;a<f;++a){var g=i[a],x=new p9(r.slice(s,g),t);o.push(x),s=g}return o},n.prototype.getOrientedFlatCoordinates=function(){if(this.orientedRevision_!=this.getRevision()){var t=this.flatCoordinates;UL(t,0,this.ends_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=q6(this.orientedFlatCoordinates_,0,this.ends_,this.stride)),this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[],i=[];return r.length=OL(this.flatCoordinates,0,this.ends_,this.stride,Math.sqrt(t),r,0,i),new n(r,Ta.XY,i)},n.prototype.getType=function(){return"Polygon"},n.prototype.intersectsExtent=function(t){return IL(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t)},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,2),this.flatCoordinates||(this.flatCoordinates=[]);var i=t7(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=i.length===0?0:i[i.length-1],this.changed()},n}(x1);const c_=RL;function g9(e){var n=e[0],t=e[1],r=e[2],i=e[3],o=[n,t,n,i,r,i,r,t,n,t];return new RL(o,Ta.XY,[o.length])}function LL(e,n,t,r){for(var i=[],o=Ed(),s=0,a=t.length;s<a;++s){var f=t[s];o=WB(e,n,f[0],r),i.push((o[0]+o[2])/2,(o[1]+o[3])/2),n=f[f.length-1]}return i}var ene=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),tne=function(e){ene(n,e);function n(t,r,i){var o=e.call(this)||this;if(o.endss_=[],o.flatInteriorPointsRevision_=-1,o.flatInteriorPoints_=null,o.maxDelta_=-1,o.maxDeltaRevision_=-1,o.orientedRevision_=-1,o.orientedFlatCoordinates_=null,!i&&!Array.isArray(t[0])){for(var s=o.getLayout(),a=t,f=[],g=[],x=0,k=a.length;x<k;++x){var B=a[x];x===0&&(s=B.getLayout());for(var P=f.length,R=B.getEnds(),H=0,W=R.length;H<W;++H)R[H]+=P;sf(f,B.getFlatCoordinates()),g.push(R)}r=s,t=f,i=g}return r!==void 0&&i?(o.setFlatCoordinates(r,t),o.endss_=i):o.setCoordinates(t,r),o}return n.prototype.appendPolygon=function(t){var r;if(!this.flatCoordinates)this.flatCoordinates=t.getFlatCoordinates().slice(),r=t.getEnds().slice(),this.endss_.push();else{var i=this.flatCoordinates.length;sf(this.flatCoordinates,t.getFlatCoordinates()),r=t.getEnds().slice();for(var o=0,s=r.length;o<s;++o)r[o]+=i}this.endss_.push(r),this.changed()},n.prototype.clone=function(){for(var t=this.endss_.length,r=new Array(t),i=0;i<t;++i)r[i]=this.endss_[i].slice();var o=new n(this.flatCoordinates.slice(),this.layout,r);return o.applyProperties(this),o},n.prototype.closestPointXY=function(t,r,i,o){return o<b1(this.getExtent(),t,r)?o:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(Ete(this.flatCoordinates,0,this.endss_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Ote(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,this.maxDelta_,!0,t,r,i,o))},n.prototype.containsXY=function(t,r){return Dte(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t,r)},n.prototype.getArea=function(){return Yte(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride)},n.prototype.getCoordinates=function(t){var r;return t!==void 0?(r=this.getOrientedFlatCoordinates().slice(),m9(r,0,this.endss_,this.stride,t)):r=this.flatCoordinates,$6(r,0,this.endss_,this.stride)},n.prototype.getEndss=function(){return this.endss_},n.prototype.getFlatInteriorPoints=function(){if(this.flatInteriorPointsRevision_!=this.getRevision()){var t=LL(this.flatCoordinates,0,this.endss_,this.stride);this.flatInteriorPoints_=DL(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t),this.flatInteriorPointsRevision_=this.getRevision()}return this.flatInteriorPoints_},n.prototype.getInteriorPoints=function(){return new i7(this.getFlatInteriorPoints().slice(),Ta.XYM)},n.prototype.getOrientedFlatCoordinates=function(){if(this.orientedRevision_!=this.getRevision()){var t=this.flatCoordinates;Zte(t,0,this.endss_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=m9(this.orientedFlatCoordinates_,0,this.endss_,this.stride)),this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_},n.prototype.getSimplifiedGeometryInternal=function(t){var r=[],i=[];return r.length=Kte(this.flatCoordinates,0,this.endss_,this.stride,Math.sqrt(t),r,0,i),new n(r,Ta.XY,i)},n.prototype.getPolygon=function(t){if(t<0||this.endss_.length<=t)return null;var r;if(t===0)r=0;else{var i=this.endss_[t-1];r=i[i.length-1]}var o=this.endss_[t].slice(),s=o[o.length-1];if(r!==0)for(var a=0,f=o.length;a<f;++a)o[a]-=r;return new c_(this.flatCoordinates.slice(r,s),this.layout,o)},n.prototype.getPolygons=function(){for(var t=this.layout,r=this.flatCoordinates,i=this.endss_,o=[],s=0,a=0,f=i.length;a<f;++a){var g=i[a].slice(),x=g[g.length-1];if(s!==0)for(var k=0,B=g.length;k<B;++k)g[k]-=s;var P=new c_(r.slice(s,x),t,g);o.push(P),s=x}return o},n.prototype.getType=function(){return"MultiPolygon"},n.prototype.intersectsExtent=function(t){return Rte(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t)},n.prototype.setCoordinates=function(t,r){this.setLayout(r,t,3),this.flatCoordinates||(this.flatCoordinates=[]);var i=kte(this.flatCoordinates,0,t,this.stride,this.endss_);if(i.length===0)this.flatCoordinates.length=0;else{var o=i[i.length-1];this.flatCoordinates.length=o.length===0?0:o[o.length-1]}this.changed()},n}(x1);const zL=tne;var nne=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),rne=function(e){nne(n,e);function n(t){var r=this,i=t||{};return r=e.call(this)||this,r.dataProjection=Fs(i.dataProjection?i.dataProjection:"EPSG:4326"),i.featureProjection&&(r.defaultFeatureProjection=Fs(i.featureProjection)),r.geometryName_=i.geometryName,r.extractGeometryName_=i.extractGeometryName,r.supportedMediaTypes=["application/geo+json","application/vnd.geo+json"],r}return n.prototype.readFeatureFromObject=function(t,r){var i=null;t.type==="Feature"?i=t:i={type:"Feature",geometry:t,properties:null};var o=V6(i.geometry,r),s=new xee;return this.geometryName_?s.setGeometryName(this.geometryName_):this.extractGeometryName_&&"geometry_name"in i!==void 0&&s.setGeometryName(i.geometry_name),s.setGeometry(o),"id"in i&&s.setId(i.id),i.properties&&s.setProperties(i.properties,!0),s},n.prototype.readFeaturesFromObject=function(t,r){var i=t,o=null;if(i.type==="FeatureCollection"){var s=t;o=[];for(var a=s.features,f=0,g=a.length;f<g;++f)o.push(this.readFeatureFromObject(a[f],r))}else o=[this.readFeatureFromObject(t,r)];return o},n.prototype.readGeometryFromObject=function(t,r){return V6(t,r)},n.prototype.readProjectionFromObject=function(t){var r=t.crs,i;return r?r.type=="name"?i=Fs(r.properties.name):r.type==="EPSG"?i=Fs("EPSG:"+r.properties.code):ao(!1,36):i=this.dataProjection,i},n.prototype.writeFeatureObject=function(t,r){r=this.adaptOptions(r);var i={type:"Feature",geometry:null,properties:null},o=t.getId();if(o!==void 0&&(i.id=o),!t.hasProperties())return i;var s=t.getProperties(),a=t.getGeometry();return a&&(i.geometry=H6(a,r),delete s[t.getGeometryName()]),h1(s)||(i.properties=s),i},n.prototype.writeFeaturesObject=function(t,r){r=this.adaptOptions(r);for(var i=[],o=0,s=t.length;o<s;++o)i.push(this.writeFeatureObject(t[o],r));return{type:"FeatureCollection",features:i}},n.prototype.writeGeometryObject=function(t,r){return H6(t,this.adaptOptions(r))},n}(bte);function V6(e,n){if(!e)return null;var t;switch(e.type){case"Point":{t=one(e);break}case"LineString":{t=ane(e);break}case"Polygon":{t=Ane(e);break}case"MultiPoint":{t=lne(e);break}case"MultiLineString":{t=sne(e);break}case"MultiPolygon":{t=une(e);break}case"GeometryCollection":{t=ine(e);break}default:throw new Error("Unsupported GeoJSON type: "+e.type)}return HB(t,!1,n)}function ine(e,n){var t=e.geometries.map(function(r){return V6(r,n)});return new vte(t)}function one(e){return new A_(e.coordinates)}function ane(e){return new w3(e.coordinates)}function sne(e){return new KL(e.coordinates)}function lne(e){return new i7(e.coordinates)}function une(e){return new zL(e.coordinates)}function Ane(e){return new c_(e.coordinates)}function H6(e,n){e=HB(e,!0,n);var t=e.getType(),r;switch(t){case"Point":{r=mne(e);break}case"LineString":{r=dne(e);break}case"Polygon":{r=gne(e,n);break}case"MultiPoint":{r=fne(e);break}case"MultiLineString":{r=hne(e);break}case"MultiPolygon":{r=pne(e,n);break}case"GeometryCollection":{r=cne(e,n);break}case"Circle":{r={type:"GeometryCollection",geometries:[]};break}default:throw new Error("Unsupported geometry type: "+t)}return r}function cne(e,n){var t=e.getGeometriesArray().map(function(r){var i=al({},n);return delete i.featureProjection,H6(r,i)});return{type:"GeometryCollection",geometries:t}}function dne(e,n){return{type:"LineString",coordinates:e.getCoordinates()}}function hne(e,n){return{type:"MultiLineString",coordinates:e.getCoordinates()}}function fne(e,n){return{type:"MultiPoint",coordinates:e.getCoordinates()}}function pne(e,n){var t;return n&&(t=n.rightHanded),{type:"MultiPolygon",coordinates:e.getCoordinates(t)}}function mne(e,n){return{type:"Point",coordinates:e.getCoordinates()}}function gne(e,n){var t;return n&&(t=n.rightHanded),{type:"Polygon",coordinates:e.getCoordinates(t)}}var yne=na,bx=W4;function na(e){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(e)?e:new Uint8Array(e||0),this.pos=0,this.type=0,this.length=this.buf.length}na.Varint=0;na.Fixed64=1;na.Bytes=2;na.Fixed32=5;var Z6=65536*65536,y9=1/Z6,vne=12,jL=typeof TextDecoder>"u"?null:new TextDecoder("utf8");na.prototype={destroy:function(){this.buf=null},readFields:function(e,n,t){for(t=t||this.length;this.pos<t;){var r=this.readVarint(),i=r>>3,o=this.pos;this.type=r&7,e(i,n,this),this.pos===o&&this.skip(r)}return n},readMessage:function(e,n){return this.readFields(e,n,this.readVarint()+this.pos)},readFixed32:function(){var e=xx(this.buf,this.pos);return this.pos+=4,e},readSFixed32:function(){var e=C9(this.buf,this.pos);return this.pos+=4,e},readFixed64:function(){var e=xx(this.buf,this.pos)+xx(this.buf,this.pos+4)*Z6;return this.pos+=8,e},readSFixed64:function(){var e=xx(this.buf,this.pos)+C9(this.buf,this.pos+4)*Z6;return this.pos+=8,e},readFloat:function(){var e=bx.read(this.buf,this.pos,!0,23,4);return this.pos+=4,e},readDouble:function(){var e=bx.read(this.buf,this.pos,!0,52,8);return this.pos+=8,e},readVarint:function(e){var n=this.buf,t,r;return r=n[this.pos++],t=r&127,r<128||(r=n[this.pos++],t|=(r&127)<<7,r<128)||(r=n[this.pos++],t|=(r&127)<<14,r<128)||(r=n[this.pos++],t|=(r&127)<<21,r<128)?t:(r=n[this.pos],t|=(r&15)<<28,Cne(t,e,this))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var e=this.readVarint();return e%2===1?(e+1)/-2:e/2},readBoolean:function(){return!!this.readVarint()},readString:function(){var e=this.readVarint()+this.pos,n=this.pos;return this.pos=e,e-n>=vne&&jL?Pne(this.buf,n,e):Kne(this.buf,n,e)},readBytes:function(){var e=this.readVarint()+this.pos,n=this.buf.subarray(this.pos,e);return this.pos=e,n},readPackedVarint:function(e,n){if(this.type!==na.Bytes)return e.push(this.readVarint(n));var t=Hf(this);for(e=e||[];this.pos<t;)e.push(this.readVarint(n));return e},readPackedSVarint:function(e){if(this.type!==na.Bytes)return e.push(this.readSVarint());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readSVarint());return e},readPackedBoolean:function(e){if(this.type!==na.Bytes)return e.push(this.readBoolean());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readBoolean());return e},readPackedFloat:function(e){if(this.type!==na.Bytes)return e.push(this.readFloat());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readFloat());return e},readPackedDouble:function(e){if(this.type!==na.Bytes)return e.push(this.readDouble());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readDouble());return e},readPackedFixed32:function(e){if(this.type!==na.Bytes)return e.push(this.readFixed32());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readFixed32());return e},readPackedSFixed32:function(e){if(this.type!==na.Bytes)return e.push(this.readSFixed32());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readSFixed32());return e},readPackedFixed64:function(e){if(this.type!==na.Bytes)return e.push(this.readFixed64());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readFixed64());return e},readPackedSFixed64:function(e){if(this.type!==na.Bytes)return e.push(this.readSFixed64());var n=Hf(this);for(e=e||[];this.pos<n;)e.push(this.readSFixed64());return e},skip:function(e){var n=e&7;if(n===na.Varint)for(;this.buf[this.pos++]>127;);else if(n===na.Bytes)this.pos=this.readVarint()+this.pos;else if(n===na.Fixed32)this.pos+=4;else if(n===na.Fixed64)this.pos+=8;else throw new Error("Unimplemented type: "+n)},writeTag:function(e,n){this.writeVarint(e<<3|n)},realloc:function(e){for(var n=this.length||16;n<this.pos+e;)n*=2;if(n!==this.length){var t=new Uint8Array(n);t.set(this.buf),this.buf=t,this.length=n}},finish:function(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)},writeFixed32:function(e){this.realloc(4),ag(this.buf,e,this.pos),this.pos+=4},writeSFixed32:function(e){this.realloc(4),ag(this.buf,e,this.pos),this.pos+=4},writeFixed64:function(e){this.realloc(8),ag(this.buf,e&-1,this.pos),ag(this.buf,Math.floor(e*y9),this.pos+4),this.pos+=8},writeSFixed64:function(e){this.realloc(8),ag(this.buf,e&-1,this.pos),ag(this.buf,Math.floor(e*y9),this.pos+4),this.pos+=8},writeVarint:function(e){if(e=+e||0,e>268435455||e<0){_ne(e,this);return}this.realloc(4),this.buf[this.pos++]=e&127|(e>127?128:0),!(e<=127)&&(this.buf[this.pos++]=(e>>>=7)&127|(e>127?128:0),!(e<=127)&&(this.buf[this.pos++]=(e>>>=7)&127|(e>127?128:0),!(e<=127)&&(this.buf[this.pos++]=e>>>7&127)))},writeSVarint:function(e){this.writeVarint(e<0?-e*2-1:e*2)},writeBoolean:function(e){this.writeVarint(!!e)},writeString:function(e){e=String(e),this.realloc(e.length*4),this.pos++;var n=this.pos;this.pos=Fne(this.buf,e,this.pos);var t=this.pos-n;t>=128&&v9(n,t,this),this.pos=n-1,this.writeVarint(t),this.pos+=t},writeFloat:function(e){this.realloc(4),bx.write(this.buf,e,this.pos,!0,23,4),this.pos+=4},writeDouble:function(e){this.realloc(8),bx.write(this.buf,e,this.pos,!0,52,8),this.pos+=8},writeBytes:function(e){var n=e.length;this.writeVarint(n),this.realloc(n);for(var t=0;t<n;t++)this.buf[this.pos++]=e[t]},writeRawMessage:function(e,n){this.pos++;var t=this.pos;e(n,this);var r=this.pos-t;r>=128&&v9(t,r,this),this.pos=t-1,this.writeVarint(r),this.pos+=r},writeMessage:function(e,n,t){this.writeTag(e,na.Bytes),this.writeRawMessage(n,t)},writePackedVarint:function(e,n){n.length&&this.writeMessage(e,wne,n)},writePackedSVarint:function(e,n){n.length&&this.writeMessage(e,Mne,n)},writePackedBoolean:function(e,n){n.length&&this.writeMessage(e,One,n)},writePackedFloat:function(e,n){n.length&&this.writeMessage(e,Sne,n)},writePackedDouble:function(e,n){n.length&&this.writeMessage(e,Ene,n)},writePackedFixed32:function(e,n){n.length&&this.writeMessage(e,Bne,n)},writePackedSFixed32:function(e,n){n.length&&this.writeMessage(e,kne,n)},writePackedFixed64:function(e,n){n.length&&this.writeMessage(e,Ine,n)},writePackedSFixed64:function(e,n){n.length&&this.writeMessage(e,Tne,n)},writeBytesField:function(e,n){this.writeTag(e,na.Bytes),this.writeBytes(n)},writeFixed32Field:function(e,n){this.writeTag(e,na.Fixed32),this.writeFixed32(n)},writeSFixed32Field:function(e,n){this.writeTag(e,na.Fixed32),this.writeSFixed32(n)},writeFixed64Field:function(e,n){this.writeTag(e,na.Fixed64),this.writeFixed64(n)},writeSFixed64Field:function(e,n){this.writeTag(e,na.Fixed64),this.writeSFixed64(n)},writeVarintField:function(e,n){this.writeTag(e,na.Varint),this.writeVarint(n)},writeSVarintField:function(e,n){this.writeTag(e,na.Varint),this.writeSVarint(n)},writeStringField:function(e,n){this.writeTag(e,na.Bytes),this.writeString(n)},writeFloatField:function(e,n){this.writeTag(e,na.Fixed32),this.writeFloat(n)},writeDoubleField:function(e,n){this.writeTag(e,na.Fixed64),this.writeDouble(n)},writeBooleanField:function(e,n){this.writeVarintField(e,!!n)}};function Cne(e,n,t){var r=t.buf,i,o;if(o=r[t.pos++],i=(o&112)>>4,o<128||(o=r[t.pos++],i|=(o&127)<<3,o<128)||(o=r[t.pos++],i|=(o&127)<<10,o<128)||(o=r[t.pos++],i|=(o&127)<<17,o<128)||(o=r[t.pos++],i|=(o&127)<<24,o<128)||(o=r[t.pos++],i|=(o&1)<<31,o<128))return og(e,i,n);throw new Error("Expected varint not more than 10 bytes")}function Hf(e){return e.type===na.Bytes?e.readVarint()+e.pos:e.pos+1}function og(e,n,t){return t?n*4294967296+(e>>>0):(n>>>0)*4294967296+(e>>>0)}function _ne(e,n){var t,r;if(e>=0?(t=e%4294967296|0,r=e/4294967296|0):(t=~(-e%4294967296),r=~(-e/4294967296),t^4294967295?t=t+1|0:(t=0,r=r+1|0)),e>=18446744073709552e3||e<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");n.realloc(10),bne(t,r,n),xne(r,n)}function bne(e,n,t){t.buf[t.pos++]=e&127|128,e>>>=7,t.buf[t.pos++]=e&127|128,e>>>=7,t.buf[t.pos++]=e&127|128,e>>>=7,t.buf[t.pos++]=e&127|128,e>>>=7,t.buf[t.pos]=e&127}function xne(e,n){var t=(e&7)<<4;n.buf[n.pos++]|=t|((e>>>=3)?128:0),e&&(n.buf[n.pos++]=e&127|((e>>>=7)?128:0),e&&(n.buf[n.pos++]=e&127|((e>>>=7)?128:0),e&&(n.buf[n.pos++]=e&127|((e>>>=7)?128:0),e&&(n.buf[n.pos++]=e&127|((e>>>=7)?128:0),e&&(n.buf[n.pos++]=e&127)))))}function v9(e,n,t){var r=n<=16383?1:n<=2097151?2:n<=268435455?3:Math.floor(Math.log(n)/(Math.LN2*7));t.realloc(r);for(var i=t.pos-1;i>=e;i--)t.buf[i+r]=t.buf[i]}function wne(e,n){for(var t=0;t<e.length;t++)n.writeVarint(e[t])}function Mne(e,n){for(var t=0;t<e.length;t++)n.writeSVarint(e[t])}function Sne(e,n){for(var t=0;t<e.length;t++)n.writeFloat(e[t])}function Ene(e,n){for(var t=0;t<e.length;t++)n.writeDouble(e[t])}function One(e,n){for(var t=0;t<e.length;t++)n.writeBoolean(e[t])}function Bne(e,n){for(var t=0;t<e.length;t++)n.writeFixed32(e[t])}function kne(e,n){for(var t=0;t<e.length;t++)n.writeSFixed32(e[t])}function Ine(e,n){for(var t=0;t<e.length;t++)n.writeFixed64(e[t])}function Tne(e,n){for(var t=0;t<e.length;t++)n.writeSFixed64(e[t])}function xx(e,n){return(e[n]|e[n+1]<<8|e[n+2]<<16)+e[n+3]*16777216}function ag(e,n,t){e[t]=n,e[t+1]=n>>>8,e[t+2]=n>>>16,e[t+3]=n>>>24}function C9(e,n){return(e[n]|e[n+1]<<8|e[n+2]<<16)+(e[n+3]<<24)}function Kne(e,n,t){for(var r="",i=n;i<t;){var o=e[i],s=null,a=o>239?4:o>223?3:o>191?2:1;if(i+a>t)break;var f,g,x;a===1?o<128&&(s=o):a===2?(f=e[i+1],(f&192)===128&&(s=(o&31)<<6|f&63,s<=127&&(s=null))):a===3?(f=e[i+1],g=e[i+2],(f&192)===128&&(g&192)===128&&(s=(o&15)<<12|(f&63)<<6|g&63,(s<=2047||s>=55296&&s<=57343)&&(s=null))):a===4&&(f=e[i+1],g=e[i+2],x=e[i+3],(f&192)===128&&(g&192)===128&&(x&192)===128&&(s=(o&15)<<18|(f&63)<<12|(g&63)<<6|x&63,(s<=65535||s>=1114112)&&(s=null))),s===null?(s=65533,a=1):s>65535&&(s-=65536,r+=String.fromCharCode(s>>>10&1023|55296),s=56320|s&1023),r+=String.fromCharCode(s),i+=a}return r}function Pne(e,n,t){return jL.decode(e.subarray(n,t))}function Fne(e,n,t){for(var r=0,i,o;r<n.length;r++){if(i=n.charCodeAt(r),i>55295&&i<57344)if(o)if(i<56320){e[t++]=239,e[t++]=191,e[t++]=189,o=i;continue}else i=o-55296<<10|i-56320|65536,o=null;else{i>56319||r+1===n.length?(e[t++]=239,e[t++]=191,e[t++]=189):o=i;continue}else o&&(e[t++]=239,e[t++]=191,e[t++]=189,o=null);i<128?e[t++]=i:(i<2048?e[t++]=i>>6|192:(i<65536?e[t++]=i>>12|224:(e[t++]=i>>18|240,e[t++]=i>>12&63|128),e[t++]=i>>6&63|128),e[t++]=i&63|128)}return t}const Dne=ga(yne);var _9=xd(),d_=function(){function e(n,t,r,i,o){this.styleFunction,this.extent_,this.id_=o,this.type_=n,this.flatCoordinates_=t,this.flatInteriorPoints_=null,this.flatMidpoints_=null,this.ends_=r,this.properties_=i}return e.prototype.get=function(n){return this.properties_[n]},e.prototype.getExtent=function(){return this.extent_||(this.extent_=this.type_==="Point"?mL(this.flatCoordinates_):WB(this.flatCoordinates_,0,this.flatCoordinates_.length,2)),this.extent_},e.prototype.getFlatInteriorPoint=function(){if(!this.flatInteriorPoints_){var n=Dm(this.getExtent());this.flatInteriorPoints_=o7(this.flatCoordinates_,0,this.ends_,2,n,0)}return this.flatInteriorPoints_},e.prototype.getFlatInteriorPoints=function(){if(!this.flatInteriorPoints_){var n=LL(this.flatCoordinates_,0,this.ends_,2);this.flatInteriorPoints_=DL(this.flatCoordinates_,0,this.ends_,2,n)}return this.flatInteriorPoints_},e.prototype.getFlatMidpoint=function(){return this.flatMidpoints_||(this.flatMidpoints_=x3(this.flatCoordinates_,0,this.flatCoordinates_.length,2,.5)),this.flatMidpoints_},e.prototype.getFlatMidpoints=function(){if(!this.flatMidpoints_){this.flatMidpoints_=[];for(var n=this.flatCoordinates_,t=0,r=this.ends_,i=0,o=r.length;i<o;++i){var s=r[i],a=x3(n,t,s,2,.5);sf(this.flatMidpoints_,a),t=s}}return this.flatMidpoints_},e.prototype.getId=function(){return this.id_},e.prototype.getOrientedFlatCoordinates=function(){return this.flatCoordinates_},e.prototype.getGeometry=function(){return this},e.prototype.getSimplifiedGeometry=function(n){return this},e.prototype.simplifyTransformed=function(n,t){return this},e.prototype.getProperties=function(){return this.properties_},e.prototype.getStride=function(){return 2},e.prototype.getStyleFunction=function(){return this.styleFunction},e.prototype.getType=function(){return this.type_},e.prototype.transform=function(n){n=Fs(n);var t=n.getExtent(),r=n.getWorldExtent();if(t&&r){var i=$A(r)/$A(t);df(_9,r[0],r[3],i,-i,0,0,0),Om(this.flatCoordinates_,0,this.flatCoordinates_.length,2,_9,this.flatCoordinates_)}},e.prototype.getEnds=function(){return this.ends_},e}();d_.prototype.getEndss=d_.prototype.getEnds;d_.prototype.getFlatCoordinates=d_.prototype.getOrientedFlatCoordinates;const X6=d_;var Une=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Rne=function(e){Une(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.dataProjection=new GB({code:"",units:gA.TILE_PIXELS}),r.featureClass_=i.featureClass?i.featureClass:X6,r.geometryName_=i.geometryName,r.layerName_=i.layerName?i.layerName:"layer",r.layers_=i.layers?i.layers:null,r.idProperty_=i.idProperty,r.supportedMediaTypes=["application/vnd.mapbox-vector-tile","application/x-protobuf"],r}return n.prototype.readRawGeometry_=function(t,r,i,o){t.pos=r.geometry;for(var s=t.readVarint()+t.pos,a=1,f=0,g=0,x=0,k=0,B=0;t.pos<s;){if(!f){var P=t.readVarint();a=P&7,f=P>>3}f--,a===1||a===2?(g+=t.readSVarint(),x+=t.readSVarint(),a===1&&k>B&&(o.push(k),B=k),i.push(g,x),k+=2):a===7?k>B&&(i.push(i[B],i[B+1]),k+=2):ao(!1,59)}k>B&&(o.push(k),B=k)},n.prototype.createFeature_=function(t,r,i){var o=r.type;if(o===0)return null;var s,a=r.properties,f;this.idProperty_?(f=a[this.idProperty_],delete a[this.idProperty_]):f=r.id,a[this.layerName_]=r.layer.name;var g=[],x=[];this.readRawGeometry_(t,r,g,x);var k=Nne(o,x.length);if(this.featureClass_===X6)s=new this.featureClass_(k,g,x,a,f),s.transform(i.dataProjection);else{var B=void 0;if(k=="Polygon"){var P=Xte(g,x);B=P.length>1?new zL(g,Ta.XY,P):new c_(g,Ta.XY,x)}else B=k==="Point"?new A_(g,Ta.XY):k==="LineString"?new w3(g,Ta.XY):k==="MultiPoint"?new i7(g,Ta.XY):k==="MultiLineString"?new KL(g,Ta.XY,x):null;var R=this.featureClass_;s=new R,this.geometryName_&&s.setGeometryName(this.geometryName_);var H=HB(B,!1,i);s.setGeometry(H),f!==void 0&&s.setId(f),s.setProperties(a,!0)}return s},n.prototype.getType=function(){return"arraybuffer"},n.prototype.readFeatures=function(t,r){var i=this.layers_,o=this.adaptOptions(r),s=Fs(o.dataProjection);s.setWorldExtent(o.extent),o.dataProjection=s;var a=new Dne(t),f=a.readFields(Lne,{}),g=[];for(var x in f)if(!(i&&i.indexOf(x)==-1)){var k=f[x],B=k?[0,0,k.extent,k.extent]:null;s.setExtent(B);for(var P=0,R=k.length;P<R;++P){var H=Wne(a,k,P),W=this.createFeature_(a,H,o);W!==null&&g.push(W)}}return g},n.prototype.readProjection=function(t){return this.dataProjection},n.prototype.setLayers=function(t){this.layers_=t},n}(EL);function Lne(e,n,t){if(e===3){var r={keys:[],values:[],features:[]},i=t.readVarint()+t.pos;t.readFields(zne,r,i),r.length=r.features.length,r.length&&(n[r.name]=r)}}function zne(e,n,t){if(e===15)n.version=t.readVarint();else if(e===1)n.name=t.readString();else if(e===5)n.extent=t.readVarint();else if(e===2)n.features.push(t.pos);else if(e===3)n.keys.push(t.readString());else if(e===4){for(var r=null,i=t.readVarint()+t.pos;t.pos<i;)e=t.readVarint()>>3,r=e===1?t.readString():e===2?t.readFloat():e===3?t.readDouble():e===4?t.readVarint64():e===5?t.readVarint():e===6?t.readSVarint():e===7?t.readBoolean():null;n.values.push(r)}}function jne(e,n,t){if(e==1)n.id=t.readVarint();else if(e==2)for(var r=t.readVarint()+t.pos;t.pos<r;){var i=n.layer.keys[t.readVarint()],o=n.layer.values[t.readVarint()];n.properties[i]=o}else e==3?n.type=t.readVarint():e==4&&(n.geometry=t.pos)}function Wne(e,n,t){e.pos=n.features[t];var r=e.readVarint()+e.pos,i={layer:n,type:0,properties:{}};return e.readFields(jne,i,r),i}function Nne(e,n){var t;return e===1?t=n===1?"Point":"MultiPoint":e===2?t=n===1?"LineString":"MultiLineString":e===3&&(t="Polygon"),t}const Gne=Rne;var Qne=/^#([a-f0-9]{3}|[a-f0-9]{4}(?:[a-f0-9]{2}){0,2})$/i,$ne=/^([a-z]*)$|^hsla?\(.*\)$/i;function WL(e){return typeof e=="string"?e:NL(e)}function Yne(e){var n=document.createElement("div");if(n.style.color=e,n.style.color!==""){document.body.appendChild(n);var t=getComputedStyle(n).color;return document.body.removeChild(n),t}else return""}var qne=function(){var e=1024,n={},t=0;return function(r){var i;if(n.hasOwnProperty(r))i=n[r];else{if(t>=e){var o=0;for(var s in n)o++&3||(delete n[s],--t)}i=Vne(r),n[r]=i,++t}return i}}();function M3(e){return Array.isArray(e)?e:qne(e)}function Vne(e){var n,t,r,i,o;if($ne.exec(e)&&(e=Yne(e)),Qne.exec(e)){var s=e.length-1,a=void 0;s<=4?a=1:a=2;var f=s===4||s===8;n=parseInt(e.substr(1+0*a,a),16),t=parseInt(e.substr(1+1*a,a),16),r=parseInt(e.substr(1+2*a,a),16),f?i=parseInt(e.substr(1+3*a,a),16):i=255,a==1&&(n=(n<<4)+n,t=(t<<4)+t,r=(r<<4)+r,f&&(i=(i<<4)+i)),o=[n,t,r,i/255]}else e.indexOf("rgba(")==0?(o=e.slice(5,-1).split(",").map(Number),b9(o)):e.indexOf("rgb(")==0?(o=e.slice(4,-1).split(",").map(Number),o.push(1),b9(o)):ao(!1,14);return o}function b9(e){return e[0]=vl(e[0]+.5|0,0,255),e[1]=vl(e[1]+.5|0,0,255),e[2]=vl(e[2]+.5|0,0,255),e[3]=vl(e[3],0,1),e}function NL(e){var n=e[0];n!=(n|0)&&(n=n+.5|0);var t=e[1];t!=(t|0)&&(t=t+.5|0);var r=e[2];r!=(r|0)&&(r=r+.5|0);var i=e[3]===void 0?1:Math.round(e[3]*100)/100;return"rgba("+n+","+t+","+r+","+i+")"}var Hne=function(){function e(){this.cache_={},this.cacheSize_=0,this.maxCacheSize_=32}return e.prototype.clear=function(){this.cache_={},this.cacheSize_=0},e.prototype.canExpireCache=function(){return this.cacheSize_>this.maxCacheSize_},e.prototype.expire=function(){if(this.canExpireCache()){var n=0;for(var t in this.cache_){var r=this.cache_[t];!(n++&3)&&!r.hasListener()&&(delete this.cache_[t],--this.cacheSize_)}}},e.prototype.get=function(n,t,r){var i=x9(n,t,r);return i in this.cache_?this.cache_[i]:null},e.prototype.set=function(n,t,r,i){var o=x9(n,t,r);this.cache_[o]=i,++this.cacheSize_},e.prototype.setSize=function(n){this.maxCacheSize_=n,this.expire()},e}();function x9(e,n,t){var r=t?WL(t):"null";return n+":"+e+":"+r}var S3=new Hne;const fa={OPACITY:"opacity",VISIBLE:"visible",EXTENT:"extent",Z_INDEX:"zIndex",MAX_RESOLUTION:"maxResolution",MIN_RESOLUTION:"minResolution",MAX_ZOOM:"maxZoom",MIN_ZOOM:"minZoom",SOURCE:"source",MAP:"map"};var Zne=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Xne=function(e){Zne(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un,r.background_=t.background;var i=al({},t);return typeof t.properties=="object"&&(delete i.properties,al(i,t.properties)),i[fa.OPACITY]=t.opacity!==void 0?t.opacity:1,ao(typeof i[fa.OPACITY]=="number",64),i[fa.VISIBLE]=t.visible!==void 0?t.visible:!0,i[fa.Z_INDEX]=t.zIndex,i[fa.MAX_RESOLUTION]=t.maxResolution!==void 0?t.maxResolution:1/0,i[fa.MIN_RESOLUTION]=t.minResolution!==void 0?t.minResolution:0,i[fa.MIN_ZOOM]=t.minZoom!==void 0?t.minZoom:-1/0,i[fa.MAX_ZOOM]=t.maxZoom!==void 0?t.maxZoom:1/0,r.className_=i.className!==void 0?i.className:"ol-layer",delete i.className,r.setProperties(i),r.state_=null,r}return n.prototype.getBackground=function(){return this.background_},n.prototype.getClassName=function(){return this.className_},n.prototype.getLayerState=function(t){var r=this.state_||{layer:this,managed:t===void 0?!0:t},i=this.getZIndex();return r.opacity=vl(Math.round(this.getOpacity()*100)/100,0,1),r.visible=this.getVisible(),r.extent=this.getExtent(),r.zIndex=i===void 0&&!r.managed?1/0:i,r.maxResolution=this.getMaxResolution(),r.minResolution=Math.max(this.getMinResolution(),0),r.minZoom=this.getMinZoom(),r.maxZoom=this.getMaxZoom(),this.state_=r,r},n.prototype.getLayersArray=function(t){return li()},n.prototype.getLayerStatesArray=function(t){return li()},n.prototype.getExtent=function(){return this.get(fa.EXTENT)},n.prototype.getMaxResolution=function(){return this.get(fa.MAX_RESOLUTION)},n.prototype.getMinResolution=function(){return this.get(fa.MIN_RESOLUTION)},n.prototype.getMinZoom=function(){return this.get(fa.MIN_ZOOM)},n.prototype.getMaxZoom=function(){return this.get(fa.MAX_ZOOM)},n.prototype.getOpacity=function(){return this.get(fa.OPACITY)},n.prototype.getSourceState=function(){return li()},n.prototype.getVisible=function(){return this.get(fa.VISIBLE)},n.prototype.getZIndex=function(){return this.get(fa.Z_INDEX)},n.prototype.setBackground=function(t){this.background_=t,this.changed()},n.prototype.setExtent=function(t){this.set(fa.EXTENT,t)},n.prototype.setMaxResolution=function(t){this.set(fa.MAX_RESOLUTION,t)},n.prototype.setMinResolution=function(t){this.set(fa.MIN_RESOLUTION,t)},n.prototype.setMaxZoom=function(t){this.set(fa.MAX_ZOOM,t)},n.prototype.setMinZoom=function(t){this.set(fa.MIN_ZOOM,t)},n.prototype.setOpacity=function(t){ao(typeof t=="number",64),this.set(fa.OPACITY,t)},n.prototype.setVisible=function(t){this.set(fa.VISIBLE,t)},n.prototype.setZIndex=function(t){this.set(fa.Z_INDEX,t)},n.prototype.disposeInternal=function(){this.state_&&(this.state_.layer=null,this.state_=null),e.prototype.disposeInternal.call(this)},n}(mh);const GL=Xne,Bm={PRERENDER:"prerender",POSTRENDER:"postrender",PRECOMPOSE:"precompose",POSTCOMPOSE:"postcompose",RENDERCOMPLETE:"rendercomplete"};var Jne=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),d5=function(e){Jne(n,e);function n(t){var r=this,i=al({},t);delete i.source,r=e.call(this,i)||this,r.on,r.once,r.un,r.mapPrecomposeKey_=null,r.mapRenderKey_=null,r.sourceChangeKey_=null,r.renderer_=null,r.rendered=!1,t.render&&(r.render=t.render),t.map&&r.setMap(t.map),r.addChangeListener(fa.SOURCE,r.handleSourcePropertyChange_);var o=t.source?t.source:null;return r.setSource(o),r}return n.prototype.getLayersArray=function(t){var r=t||[];return r.push(this),r},n.prototype.getLayerStatesArray=function(t){var r=t||[];return r.push(this.getLayerState()),r},n.prototype.getSource=function(){return this.get(fa.SOURCE)||null},n.prototype.getRenderSource=function(){return this.getSource()},n.prototype.getSourceState=function(){var t=this.getSource();return t?t.getState():"undefined"},n.prototype.handleSourceChange_=function(){this.changed()},n.prototype.handleSourcePropertyChange_=function(){this.sourceChangeKey_&&(Ga(this.sourceChangeKey_),this.sourceChangeKey_=null);var t=this.getSource();t&&(this.sourceChangeKey_=wo(t,ki.CHANGE,this.handleSourceChange_,this)),this.changed()},n.prototype.getFeatures=function(t){return this.renderer_?this.renderer_.getFeatures(t):new Promise(function(r){return r([])})},n.prototype.getData=function(t){return!this.renderer_||!this.rendered?null:this.renderer_.getData(t)},n.prototype.render=function(t,r){var i=this.getRenderer();if(i.prepareFrame(t))return this.rendered=!0,i.renderFrame(t,r)},n.prototype.unrender=function(){this.rendered=!1},n.prototype.setMapInternal=function(t){t||this.unrender(),this.set(fa.MAP,t)},n.prototype.getMapInternal=function(){return this.get(fa.MAP)},n.prototype.setMap=function(t){this.mapPrecomposeKey_&&(Ga(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),t||this.changed(),this.mapRenderKey_&&(Ga(this.mapRenderKey_),this.mapRenderKey_=null),t&&(this.mapPrecomposeKey_=wo(t,Bm.PRECOMPOSE,function(r){var i=r,o=i.frameState.layerStatesArray,s=this.getLayerState(!1);ao(!o.some(function(a){return a.layer===s.layer}),67),o.push(s)},this),this.mapRenderKey_=wo(this,ki.CHANGE,t.render,t),this.changed())},n.prototype.setSource=function(t){this.set(fa.SOURCE,t)},n.prototype.getRenderer=function(){return this.renderer_||(this.renderer_=this.createRenderer()),this.renderer_},n.prototype.hasRenderer=function(){return!!this.renderer_},n.prototype.createRenderer=function(){return null},n.prototype.disposeInternal=function(){this.renderer_&&(this.renderer_.dispose(),delete this.renderer_),this.setSource(null),e.prototype.disposeInternal.call(this)},n}(GL);function E3(e,n){if(!e.visible)return!1;var t=n.resolution;if(t<e.minResolution||t>=e.maxResolution)return!1;var r=n.zoom;return r>e.minZoom&&r<=e.maxZoom}var ere=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),tre=function(e){ere(n,e);function n(t){var r=e.call(this)||this;return r.map_=t,r}return n.prototype.dispatchRenderEvent=function(t,r){li()},n.prototype.calculateMatrices2D=function(t){var r=t.viewState,i=t.coordinateToPixelTransform,o=t.pixelToCoordinateTransform;df(i,t.size[0]/2,t.size[1]/2,1/r.resolution,-1/r.resolution,-r.rotation,-r.center[0],-r.center[1]),zB(o,i)},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s,a,f,g){var x,k=r.viewState;function B(Ce,jt,Ft,Jt){return s.call(a,jt,Ce?Ft:null,Jt)}var P=k.projection,R=$B(t.slice(),P),H=[[0,0]];if(P.canWrapX()&&o){var W=P.getExtent(),$=os(W);H.push([-$,0],[$,0])}for(var q=r.layerStatesArray,oe=q.length,ne=[],ce=[],ae=0;ae<H.length;ae++)for(var ue=oe-1;ue>=0;--ue){var ye=q[ue],Re=ye.layer;if(Re.hasRenderer()&&E3(ye,k)&&f.call(g,Re)){var Ne=Re.getRenderer(),rt=Re.getSource();if(Ne&&rt){var ct=rt.getWrapX()?R:t,Fe=B.bind(null,ye.managed);ce[0]=ct[0]+H[ae][0],ce[1]=ct[1]+H[ae][1],x=Ne.forEachFeatureAtCoordinate(ce,r,i,Fe,ne)}if(x)return x}}if(ne.length!==0){var He=1/ne.length;return ne.forEach(function(Ce,jt){return Ce.distanceSq+=jt*He}),ne.sort(function(Ce,jt){return Ce.distanceSq-jt.distanceSq}),ne.some(function(Ce){return x=Ce.callback(Ce.feature,Ce.layer,Ce.geometry)}),x}},n.prototype.forEachLayerAtPixel=function(t,r,i,o,s){return li()},n.prototype.hasFeatureAtCoordinate=function(t,r,i,o,s,a){var f=this.forEachFeatureAtCoordinate(t,r,i,o,ty,this,s,a);return f!==void 0},n.prototype.getMap=function(){return this.map_},n.prototype.renderFrame=function(t){li()},n.prototype.scheduleExpireIconCache=function(t){S3.canExpireCache()&&t.postRenderFunctions.push(nre)},n}(UB);function nre(e,n){S3.expire()}const rre=tre;var ire=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),QL=function(e){ire(n,e);function n(t,r,i,o){var s=e.call(this,t)||this;return s.inversePixelTransform=r,s.frameState=i,s.context=o,s}return n}(Ep),wx="ol-hidden",ore="ol-selectable",h5="ol-unselectable",s7="ol-control",w9="ol-collapsed",are=new RegExp(["^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00 ))?)","(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?","(?:small|large)|medium|smaller|larger|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))","(?:\\s*\\/\\s*(normal|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])?))",`?\\s*([-,\\"\\'\\sa-z]+?)\\s*$`].join(""),"i"),M9=["style","variant","weight","size","lineHeight","family"],$L=function(e){var n=e.match(are);if(!n)return null;for(var t={lineHeight:"normal",size:"1.2em",style:"normal",weight:"normal",variant:"normal"},r=0,i=M9.length;r<i;++r){var o=n[r+1];o!==void 0&&(t[M9[r]]=o)}return t.families=t.family.split(/,\s?/),t};function YA(e,n,t,r){var i;return t&&t.length?i=t.shift():i5?i=new OffscreenCanvas(e||300,n||300):i=document.createElement("canvas"),e&&(i.width=e),n&&(i.height=n),i.getContext("2d",r)}function l7(e){var n=e.canvas;n.width=1,n.height=1,e.clearRect(0,0,1,1)}function sre(e){var n=e.offsetWidth,t=getComputedStyle(e);return n+=parseInt(t.marginLeft,10)+parseInt(t.marginRight,10),n}function lre(e){var n=e.offsetHeight,t=getComputedStyle(e);return n+=parseInt(t.marginTop,10)+parseInt(t.marginBottom,10),n}function S9(e,n){var t=n.parentNode;t&&t.replaceChild(e,n)}function O3(e){return e&&e.parentNode?e.parentNode.removeChild(e):null}function YL(e){for(;e.lastChild;)e.removeChild(e.lastChild)}function ure(e,n){for(var t=e.childNodes,r=0;;++r){var i=t[r],o=n[r];if(!i&&!o)break;if(i!==o){if(!i){e.appendChild(o);continue}if(!o){e.removeChild(i),--r;continue}e.insertBefore(o,i)}}}var qL="10px sans-serif",bp="#000",B3="round",h_=[],f_=0,My="round",p_=10,m_="#000",g_="center",k3="middle",N0=[0,0,0,0],y_=1,ip=new mh,J6=new zy;J6.setSize=function(){console.warn("labelCache is deprecated.")};var _g=null,eE,tE={},Are=function(){var e=100,n="32px ",t=["monospace","serif"],r=t.length,i="wmytzilWMYTZIL@#/&?$%10",o,s;function a(g,x,k){for(var B=!0,P=0;P<r;++P){var R=t[P];if(s=I3(g+" "+x+" "+n+R,i),k!=R){var H=I3(g+" "+x+" "+n+k+","+R,i);B=B&&H!=s}}return!!B}function f(){for(var g=!0,x=ip.getKeys(),k=0,B=x.length;k<B;++k){var P=x[k];ip.get(P)<e&&(a.apply(this,P.split(`
|
||
`))?(Q_(tE),_g=null,eE=void 0,ip.set(P,e)):(ip.set(P,ip.get(P)+1,!0),g=!1))}g&&(clearInterval(o),o=void 0)}return function(g){var x=$L(g);if(x)for(var k=x.families,B=0,P=k.length;B<P;++B){var R=k[B],H=x.style+`
|
||
`+x.weight+`
|
||
`+R;ip.get(H)===void 0&&(ip.set(H,e,!0),a(x.style,x.weight,R)||(ip.set(H,0,!0),o===void 0&&(o=setInterval(f,32))))}}}(),cre=function(){var e;return function(n){var t=tE[n];if(t==null){if(i5){var r=$L(n),i=VL(n,"Žg"),o=isNaN(Number(r.lineHeight))?1.2:Number(r.lineHeight);t=o*(i.actualBoundingBoxAscent+i.actualBoundingBoxDescent)}else e||(e=document.createElement("div"),e.innerHTML="M",e.style.minHeight="0",e.style.maxHeight="none",e.style.height="auto",e.style.padding="0",e.style.border="none",e.style.position="absolute",e.style.display="block",e.style.left="-99999px"),e.style.font=n,document.body.appendChild(e),t=e.offsetHeight,document.body.removeChild(e);tE[n]=t}return t}}();function VL(e,n){return _g||(_g=YA(1,1)),e!=eE&&(_g.font=e,eE=_g.font),_g.measureText(n)}function I3(e,n){return VL(e,n).width}function E9(e,n,t){if(n in t)return t[n];var r=n.split(`
|
||
`).reduce(function(i,o){return Math.max(i,I3(e,o))},0);return t[n]=r,r}function dre(e,n){for(var t=[],r=[],i=[],o=0,s=0,a=0,f=0,g=0,x=n.length;g<=x;g+=2){var k=n[g];if(k===`
|
||
`||g===x){o=Math.max(o,s),i.push(s),s=0,a+=f;continue}var B=n[g+1]||e.font,P=I3(B,k);t.push(P),s+=P;var R=cre(B);r.push(R),f=Math.max(f,R)}return{width:o,height:a,widths:t,heights:r,lineWidths:i}}function hre(e,n,t,r,i,o,s,a,f,g,x){e.save(),t!==1&&(e.globalAlpha*=t),n&&e.setTransform.apply(e,n),r.contextInstructions?(e.translate(f,g),e.scale(x[0],x[1]),fre(r,e)):x[0]<0||x[1]<0?(e.translate(f,g),e.scale(x[0],x[1]),e.drawImage(r,i,o,s,a,0,0,s,a)):e.drawImage(r,i,o,s,a,f,g,s*x[0],a*x[1]),e.restore()}function fre(e,n){for(var t=e.contextInstructions,r=0,i=t.length;r<i;r+=2)Array.isArray(t[r+1])?n[t[r]].apply(n,t[r+1]):n[t[r]]=t[r+1]}var pre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),mre=function(e){pre(n,e);function n(t){var r=e.call(this,t)||this;r.fontChangeListenerKey_=wo(ip,xy.PROPERTYCHANGE,t.redrawText.bind(t)),r.element_=document.createElement("div");var i=r.element_.style;i.position="absolute",i.width="100%",i.height="100%",i.zIndex="0",r.element_.className=h5+" ol-layers";var o=t.getViewport();return o.insertBefore(r.element_,o.firstChild||null),r.children_=[],r.renderedVisible_=!0,r}return n.prototype.dispatchRenderEvent=function(t,r){var i=this.getMap();if(i.hasListener(t)){var o=new QL(t,void 0,r);i.dispatchEvent(o)}},n.prototype.disposeInternal=function(){Ga(this.fontChangeListenerKey_),this.element_.parentNode.removeChild(this.element_),e.prototype.disposeInternal.call(this)},n.prototype.renderFrame=function(t){if(!t){this.renderedVisible_&&(this.element_.style.display="none",this.renderedVisible_=!1);return}this.calculateMatrices2D(t),this.dispatchRenderEvent(Bm.PRECOMPOSE,t);var r=t.layerStatesArray.sort(function(P,R){return P.zIndex-R.zIndex}),i=t.viewState;this.children_.length=0;for(var o=[],s=null,a=0,f=r.length;a<f;++a){var g=r[a];t.layerIndex=a;var x=g.layer,k=x.getSourceState();if(!E3(g,i)||k!="ready"&&k!="undefined"){x.unrender();continue}var B=x.render(t,s);B&&(B!==s&&(this.children_.push(B),s=B),"getDeclutter"in x&&o.push(x))}for(var a=o.length-1;a>=0;--a)o[a].renderDeclutter(t);ure(this.element_,this.children_),this.dispatchRenderEvent(Bm.POSTCOMPOSE,t),this.renderedVisible_||(this.element_.style.display="",this.renderedVisible_=!0),this.scheduleExpireIconCache(t)},n.prototype.forEachLayerAtPixel=function(t,r,i,o,s){for(var a=r.viewState,f=r.layerStatesArray,g=f.length,x=g-1;x>=0;--x){var k=f[x],B=k.layer;if(B.hasRenderer()&&E3(k,a)&&s(B)){var P=B.getRenderer(),R=P.getDataAtPixel(t,r,i);if(R){var H=o(B,R);if(H)return H}}}},n}(rre);const gre=mre,WA={ADD:"add",REMOVE:"remove"};var HL=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),O9={LENGTH:"length"},Mx=function(e){HL(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.element=r,o.index=i,o}return n}(Ep),_d=function(e){HL(n,e);function n(t,r){var i=e.call(this)||this;i.on,i.once,i.un;var o=r||{};if(i.unique_=!!o.unique,i.array_=t||[],i.unique_)for(var s=0,a=i.array_.length;s<a;++s)i.assertUnique_(i.array_[s],s);return i.updateLength_(),i}return n.prototype.clear=function(){for(;this.getLength()>0;)this.pop()},n.prototype.extend=function(t){for(var r=0,i=t.length;r<i;++r)this.push(t[r]);return this},n.prototype.forEach=function(t){for(var r=this.array_,i=0,o=r.length;i<o;++i)t(r[i],i,r)},n.prototype.getArray=function(){return this.array_},n.prototype.item=function(t){return this.array_[t]},n.prototype.getLength=function(){return this.get(O9.LENGTH)},n.prototype.insertAt=function(t,r){this.unique_&&this.assertUnique_(r),this.array_.splice(t,0,r),this.updateLength_(),this.dispatchEvent(new Mx(WA.ADD,r,t))},n.prototype.pop=function(){return this.removeAt(this.getLength()-1)},n.prototype.push=function(t){this.unique_&&this.assertUnique_(t);var r=this.getLength();return this.insertAt(r,t),this.getLength()},n.prototype.remove=function(t){for(var r=this.array_,i=0,o=r.length;i<o;++i)if(r[i]===t)return this.removeAt(i)},n.prototype.removeAt=function(t){var r=this.array_[t];return this.array_.splice(t,1),this.updateLength_(),this.dispatchEvent(new Mx(WA.REMOVE,r,t)),r},n.prototype.setAt=function(t,r){var i=this.getLength();if(t<i){this.unique_&&this.assertUnique_(r,t);var o=this.array_[t];this.array_[t]=r,this.dispatchEvent(new Mx(WA.REMOVE,o,t)),this.dispatchEvent(new Mx(WA.ADD,r,t))}else{for(var s=i;s<t;++s)this.insertAt(s,void 0);this.insertAt(t,r)}},n.prototype.updateLength_=function(){this.set(O9.LENGTH,this.array_.length)},n.prototype.assertUnique_=function(t,r){for(var i=0,o=this.array_.length;i<o;++i)if(this.array_[i]===t&&i!==r)throw new AL(58)},n}(mh),ZL=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),em=function(e){ZL(n,e);function n(t,r){var i=e.call(this,t)||this;return i.layer=r,i}return n}(Ep),uM={LAYERS:"layers"},yre=function(e){ZL(n,e);function n(t){var r=this,i=t||{},o=al({},i);delete o.layers;var s=i.layers;return r=e.call(this,o)||this,r.on,r.once,r.un,r.layersListenerKeys_=[],r.listenerKeys_={},r.addChangeListener(uM.LAYERS,r.handleLayersChanged_),s?Array.isArray(s)?s=new _d(s.slice(),{unique:!0}):ao(typeof s.getArray=="function",43):s=new _d(void 0,{unique:!0}),r.setLayers(s),r}return n.prototype.handleLayerChange_=function(){this.changed()},n.prototype.handleLayersChanged_=function(){this.layersListenerKeys_.forEach(Ga),this.layersListenerKeys_.length=0;var t=this.getLayers();this.layersListenerKeys_.push(wo(t,WA.ADD,this.handleLayersAdd_,this),wo(t,WA.REMOVE,this.handleLayersRemove_,this));for(var r in this.listenerKeys_)this.listenerKeys_[r].forEach(Ga);Q_(this.listenerKeys_);for(var i=t.getArray(),o=0,s=i.length;o<s;o++){var a=i[o];this.registerLayerListeners_(a),this.dispatchEvent(new em("addlayer",a))}this.changed()},n.prototype.registerLayerListeners_=function(t){var r=[wo(t,xy.PROPERTYCHANGE,this.handleLayerChange_,this),wo(t,ki.CHANGE,this.handleLayerChange_,this)];t instanceof n&&r.push(wo(t,"addlayer",this.handleLayerGroupAdd_,this),wo(t,"removelayer",this.handleLayerGroupRemove_,this)),this.listenerKeys_[$i(t)]=r},n.prototype.handleLayerGroupAdd_=function(t){this.dispatchEvent(new em("addlayer",t.layer))},n.prototype.handleLayerGroupRemove_=function(t){this.dispatchEvent(new em("removelayer",t.layer))},n.prototype.handleLayersAdd_=function(t){var r=t.element;this.registerLayerListeners_(r),this.dispatchEvent(new em("addlayer",r)),this.changed()},n.prototype.handleLayersRemove_=function(t){var r=t.element,i=$i(r);this.listenerKeys_[i].forEach(Ga),delete this.listenerKeys_[i],this.dispatchEvent(new em("removelayer",r)),this.changed()},n.prototype.getLayers=function(){return this.get(uM.LAYERS)},n.prototype.setLayers=function(t){var r=this.getLayers();if(r)for(var i=r.getArray(),o=0,s=i.length;o<s;++o)this.dispatchEvent(new em("removelayer",i[o]));this.set(uM.LAYERS,t)},n.prototype.getLayersArray=function(t){var r=t!==void 0?t:[];return this.getLayers().forEach(function(i){i.getLayersArray(r)}),r},n.prototype.getLayerStatesArray=function(t){var r=t!==void 0?t:[],i=r.length;this.getLayers().forEach(function(x){x.getLayerStatesArray(r)});var o=this.getLayerState(),s=o.zIndex;!t&&o.zIndex===void 0&&(s=0);for(var a=i,f=r.length;a<f;a++){var g=r[a];g.opacity*=o.opacity,g.visible=g.visible&&o.visible,g.maxResolution=Math.min(g.maxResolution,o.maxResolution),g.minResolution=Math.max(g.minResolution,o.minResolution),g.minZoom=Math.max(g.minZoom,o.minZoom),g.maxZoom=Math.min(g.maxZoom,o.maxZoom),o.extent!==void 0&&(g.extent!==void 0?g.extent=X0(g.extent,o.extent):g.extent=o.extent),g.zIndex===void 0&&(g.zIndex=s)}return r},n.prototype.getSourceState=function(){return"ready"},n}(GL);const f5=yre;var vre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),bg=function(e){vre(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.map=r,o.frameState=i!==void 0?i:null,o}return n}(Ep),Cre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Zp=function(e){Cre(n,e);function n(t,r,i,o,s,a){var f=e.call(this,t,r,s)||this;return f.originalEvent=i,f.pixel_=null,f.coordinate_=null,f.dragging=o!==void 0?o:!1,f.activePointers=a,f}return Object.defineProperty(n.prototype,"pixel",{get:function(){return this.pixel_||(this.pixel_=this.map.getEventPixel(this.originalEvent)),this.pixel_},set:function(t){this.pixel_=t},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"coordinate",{get:function(){return this.coordinate_||(this.coordinate_=this.map.getCoordinateFromPixel(this.pixel)),this.coordinate_},set:function(t){this.coordinate_=t},enumerable:!1,configurable:!0}),n.prototype.preventDefault=function(){e.prototype.preventDefault.call(this),"preventDefault"in this.originalEvent&&this.originalEvent.preventDefault()},n.prototype.stopPropagation=function(){e.prototype.stopPropagation.call(this),"stopPropagation"in this.originalEvent&&this.originalEvent.stopPropagation()},n}(bg);const Ns={SINGLECLICK:"singleclick",CLICK:ki.CLICK,DBLCLICK:ki.DBLCLICK,POINTERDRAG:"pointerdrag",POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"},nE={POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"};var _re=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),bre=function(e){_re(n,e);function n(t,r){var i=e.call(this,t)||this;i.map_=t,i.clickTimeoutId_,i.emulateClicks_=!1,i.dragging_=!1,i.dragListenerKeys_=[],i.moveTolerance_=r===void 0?1:r,i.down_=null;var o=i.map_.getViewport();return i.activePointers_=[],i.trackedTouches_={},i.element_=o,i.pointerdownListenerKey_=wo(o,nE.POINTERDOWN,i.handlePointerDown_,i),i.originalPointerMoveEvent_,i.relayedListenerKey_=wo(o,nE.POINTERMOVE,i.relayMoveEvent_,i),i.boundHandleTouchMove_=i.handleTouchMove_.bind(i),i.element_.addEventListener(ki.TOUCHMOVE,i.boundHandleTouchMove_,dL?{passive:!1}:!1),i}return n.prototype.emulateClick_=function(t){var r=new Zp(Ns.CLICK,this.map_,t);this.dispatchEvent(r),this.clickTimeoutId_!==void 0?(clearTimeout(this.clickTimeoutId_),this.clickTimeoutId_=void 0,r=new Zp(Ns.DBLCLICK,this.map_,t),this.dispatchEvent(r)):this.clickTimeoutId_=setTimeout((function(){this.clickTimeoutId_=void 0;var i=new Zp(Ns.SINGLECLICK,this.map_,t);this.dispatchEvent(i)}).bind(this),250)},n.prototype.updateActivePointers_=function(t){var r=t,i=r.pointerId;if(r.type==Ns.POINTERUP||r.type==Ns.POINTERCANCEL){delete this.trackedTouches_[i];for(var o in this.trackedTouches_)if(this.trackedTouches_[o].target!==r.target){delete this.trackedTouches_[o];break}}else(r.type==Ns.POINTERDOWN||r.type==Ns.POINTERMOVE)&&(this.trackedTouches_[i]=r);this.activePointers_=sL(this.trackedTouches_)},n.prototype.handlePointerUp_=function(t){this.updateActivePointers_(t);var r=new Zp(Ns.POINTERUP,this.map_,t,void 0,void 0,this.activePointers_);this.dispatchEvent(r),this.emulateClicks_&&!r.defaultPrevented&&!this.dragging_&&this.isMouseActionButton_(t)&&this.emulateClick_(this.down_),this.activePointers_.length===0&&(this.dragListenerKeys_.forEach(Ga),this.dragListenerKeys_.length=0,this.dragging_=!1,this.down_=null)},n.prototype.isMouseActionButton_=function(t){return t.button===0},n.prototype.handlePointerDown_=function(t){this.emulateClicks_=this.activePointers_.length===0,this.updateActivePointers_(t);var r=new Zp(Ns.POINTERDOWN,this.map_,t,void 0,void 0,this.activePointers_);this.dispatchEvent(r),this.down_={};for(var i in t){var o=t[i];this.down_[i]=typeof o=="function"?d1:o}if(this.dragListenerKeys_.length===0){var s=this.map_.getOwnerDocument();this.dragListenerKeys_.push(wo(s,Ns.POINTERMOVE,this.handlePointerMove_,this),wo(s,Ns.POINTERUP,this.handlePointerUp_,this),wo(this.element_,Ns.POINTERCANCEL,this.handlePointerUp_,this)),this.element_.getRootNode&&this.element_.getRootNode()!==s&&this.dragListenerKeys_.push(wo(this.element_.getRootNode(),Ns.POINTERUP,this.handlePointerUp_,this))}},n.prototype.handlePointerMove_=function(t){if(this.isMoving_(t)){this.updateActivePointers_(t),this.dragging_=!0;var r=new Zp(Ns.POINTERDRAG,this.map_,t,this.dragging_,void 0,this.activePointers_);this.dispatchEvent(r)}},n.prototype.relayMoveEvent_=function(t){this.originalPointerMoveEvent_=t;var r=!!(this.down_&&this.isMoving_(t));this.dispatchEvent(new Zp(Ns.POINTERMOVE,this.map_,t,r))},n.prototype.handleTouchMove_=function(t){var r=this.originalPointerMoveEvent_;(!r||r.defaultPrevented)&&(typeof t.cancelable!="boolean"||t.cancelable===!0)&&t.preventDefault()},n.prototype.isMoving_=function(t){return this.dragging_||Math.abs(t.clientX-this.down_.clientX)>this.moveTolerance_||Math.abs(t.clientY-this.down_.clientY)>this.moveTolerance_},n.prototype.disposeInternal=function(){this.relayedListenerKey_&&(Ga(this.relayedListenerKey_),this.relayedListenerKey_=null),this.element_.removeEventListener(ki.TOUCHMOVE,this.boundHandleTouchMove_),this.pointerdownListenerKey_&&(Ga(this.pointerdownListenerKey_),this.pointerdownListenerKey_=null),this.dragListenerKeys_.forEach(Ga),this.dragListenerKeys_.length=0,this.element_=null,e.prototype.disposeInternal.call(this)},n}(zy);const xre=bre,op={POSTRENDER:"postrender",MOVESTART:"movestart",MOVEEND:"moveend",LOADSTART:"loadstart",LOADEND:"loadend"},Gu={LAYERGROUP:"layergroup",SIZE:"size",TARGET:"target",VIEW:"view"};var T3=1/0,wre=function(){function e(n,t){this.priorityFunction_=n,this.keyFunction_=t,this.elements_=[],this.priorities_=[],this.queuedElements_={}}return e.prototype.clear=function(){this.elements_.length=0,this.priorities_.length=0,Q_(this.queuedElements_)},e.prototype.dequeue=function(){var n=this.elements_,t=this.priorities_,r=n[0];n.length==1?(n.length=0,t.length=0):(n[0]=n.pop(),t[0]=t.pop(),this.siftUp_(0));var i=this.keyFunction_(r);return delete this.queuedElements_[i],r},e.prototype.enqueue=function(n){ao(!(this.keyFunction_(n)in this.queuedElements_),31);var t=this.priorityFunction_(n);return t!=T3?(this.elements_.push(n),this.priorities_.push(t),this.queuedElements_[this.keyFunction_(n)]=!0,this.siftDown_(0,this.elements_.length-1),!0):!1},e.prototype.getCount=function(){return this.elements_.length},e.prototype.getLeftChildIndex_=function(n){return n*2+1},e.prototype.getRightChildIndex_=function(n){return n*2+2},e.prototype.getParentIndex_=function(n){return n-1>>1},e.prototype.heapify_=function(){var n;for(n=(this.elements_.length>>1)-1;n>=0;n--)this.siftUp_(n)},e.prototype.isEmpty=function(){return this.elements_.length===0},e.prototype.isKeyQueued=function(n){return n in this.queuedElements_},e.prototype.isQueued=function(n){return this.isKeyQueued(this.keyFunction_(n))},e.prototype.siftUp_=function(n){for(var t=this.elements_,r=this.priorities_,i=t.length,o=t[n],s=r[n],a=n;n<i>>1;){var f=this.getLeftChildIndex_(n),g=this.getRightChildIndex_(n),x=g<i&&r[g]<r[f]?g:f;t[n]=t[x],r[n]=r[x],n=x}t[n]=o,r[n]=s,this.siftDown_(a,n)},e.prototype.siftDown_=function(n,t){for(var r=this.elements_,i=this.priorities_,o=r[t],s=i[t];t>n;){var a=this.getParentIndex_(t);if(i[a]>s)r[t]=r[a],i[t]=i[a],t=a;else break}r[t]=o,i[t]=s},e.prototype.reprioritize=function(){var n=this.priorityFunction_,t=this.elements_,r=this.priorities_,i=0,o=t.length,s,a,f;for(a=0;a<o;++a)s=t[a],f=n(s),f==T3?delete this.queuedElements_[this.keyFunction_(s)]:(r[i]=f,t[i++]=s);t.length=i,r.length=i,this.heapify_()},e}();const Mre=wre,mr={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4};var Sre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Ere=function(e){Sre(n,e);function n(t,r){var i=e.call(this,function(o){return t.apply(null,o)},function(o){return o[0].getKey()})||this;return i.boundHandleTileChange_=i.handleTileChange.bind(i),i.tileChangeCallback_=r,i.tilesLoading_=0,i.tilesLoadingKeys_={},i}return n.prototype.enqueue=function(t){var r=e.prototype.enqueue.call(this,t);if(r){var i=t[0];i.addEventListener(ki.CHANGE,this.boundHandleTileChange_)}return r},n.prototype.getTilesLoading=function(){return this.tilesLoading_},n.prototype.handleTileChange=function(t){var r=t.target,i=r.getState();if(i===mr.LOADED||i===mr.ERROR||i===mr.EMPTY){r.removeEventListener(ki.CHANGE,this.boundHandleTileChange_);var o=r.getKey();o in this.tilesLoadingKeys_&&(delete this.tilesLoadingKeys_[o],--this.tilesLoading_),this.tileChangeCallback_()}},n.prototype.loadMoreTiles=function(t,r){for(var i=0,o,s,a;this.tilesLoading_<t&&i<r&&this.getCount()>0;)s=this.dequeue()[0],a=s.getKey(),o=s.getState(),o===mr.IDLE&&!(a in this.tilesLoadingKeys_)&&(this.tilesLoadingKeys_[a]=!0,++this.tilesLoading_,++i,s.load())},n}(Mre);const Ore=Ere;function Bre(e,n,t,r,i){if(!e||!(t in e.wantedTiles)||!e.wantedTiles[t][n.getKey()])return T3;var o=e.viewState.center,s=r[0]-o[0],a=r[1]-o[1];return 65536*Math.log(i)+Math.sqrt(s*s+a*a)/i}const Gs={ANIMATING:0,INTERACTING:1},ih={CENTER:"center",RESOLUTION:"resolution",ROTATION:"rotation"};var XL=42,u7=256;function B9(e,n,t){return function(r,i,o,s,a){if(r){if(!i&&!n)return r;var f=n?0:o[0]*i,g=n?0:o[1]*i,x=a?a[0]:0,k=a?a[1]:0,B=e[0]+f/2+x,P=e[2]-f/2+x,R=e[1]+g/2+k,H=e[3]-g/2+k;B>P&&(B=(P+B)/2,P=B),R>H&&(R=(H+R)/2,H=R);var W=vl(r[0],B,P),$=vl(r[1],R,H);if(s&&t&&i){var q=30*i;W+=-q*Math.log(1+Math.max(0,B-r[0])/q)+q*Math.log(1+Math.max(0,r[0]-P)/q),$+=-q*Math.log(1+Math.max(0,R-r[1])/q)+q*Math.log(1+Math.max(0,r[1]-H)/q)}return[W,$]}}}function kre(e){return e}function A7(e,n,t,r){var i=os(n)/t[0],o=$A(n)/t[1];return r?Math.min(e,Math.max(i,o)):Math.min(e,Math.min(i,o))}function c7(e,n,t){var r=Math.min(e,n),i=50;return r*=Math.log(1+i*Math.max(0,e/n-1))/i+1,t&&(r=Math.max(r,t),r/=Math.log(1+i*Math.max(0,t/e-1))/i+1),vl(r,t/2,n*2)}function Ire(e,n,t,r){return function(i,o,s,a){if(i!==void 0){var f=e[0],g=e[e.length-1],x=t?A7(f,t,s,r):f;if(a){var k=n!==void 0?n:!0;return k?c7(i,x,g):vl(i,g,x)}var B=Math.min(x,i),P=Math.floor(RB(e,B,o));return e[P]>x&&P<e.length-1?e[P+1]:e[P]}else return}}function Tre(e,n,t,r,i,o){return function(s,a,f,g){if(s!==void 0){var x=i?A7(n,i,f,o):n,k=t!==void 0?t:0;if(g){var B=r!==void 0?r:!0;return B?c7(s,x,k):vl(s,k,x)}var P=1e-9,R=Math.ceil(Math.log(n/x)/Math.log(e)-P),H=-a*(.5-P)+.5,W=Math.min(x,s),$=Math.floor(Math.log(n/W)/Math.log(e)+H),q=Math.max(R,$),oe=n/Math.pow(e,q);return vl(oe,k,x)}else return}}function k9(e,n,t,r,i){return function(o,s,a,f){if(o!==void 0){var g=r?A7(e,r,a,i):e,x=t!==void 0?t:!0;return!x||!f?vl(o,n,g):c7(o,g,n)}else return}}function d7(e){if(e!==void 0)return 0}function I9(e){if(e!==void 0)return e}function Kre(e){var n=2*Math.PI/e;return function(t,r){if(r)return t;if(t!==void 0)return t=Math.floor(t/n+.5)*n,t}}function Pre(e){var n=e||y2(5);return function(t,r){if(r)return t;if(t!==void 0)return Math.abs(t)<=n?0:t}}function JL(e){return Math.pow(e,3)}function jy(e){return 1-JL(1-e)}function Fre(e){return 3*e*e-2*e*e*e}function Dre(e){return e}var Ure=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),AM=0,pp=function(e){Ure(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un;var i=al({},t);return r.hints_=[0,0],r.animations_=[],r.updateAnimationKey_,r.projection_=qB(i.projection,"EPSG:3857"),r.viewportSize_=[100,100],r.targetCenter_=null,r.targetResolution_,r.targetRotation_,r.nextCenter_=null,r.nextResolution_,r.nextRotation_,r.cancelAnchor_=void 0,i.projection&&bL(),i.center&&(i.center=rp(i.center,r.projection_)),i.extent&&(i.extent=j0(i.extent,r.projection_)),r.applyOptions_(i),r}return n.prototype.applyOptions_=function(t){var r=al({},t);for(var i in ih)delete r[i];this.setProperties(r,!0);var o=Lre(t);this.maxResolution_=o.maxResolution,this.minResolution_=o.minResolution,this.zoomFactor_=o.zoomFactor,this.resolutions_=t.resolutions,this.padding_=t.padding,this.minZoom_=o.minZoom;var s=Rre(t),a=o.constraint,f=zre(t);this.constraints_={center:s,resolution:a,rotation:f},this.setRotation(t.rotation!==void 0?t.rotation:0),this.setCenterInternal(t.center!==void 0?t.center:null),t.resolution!==void 0?this.setResolution(t.resolution):t.zoom!==void 0&&this.setZoom(t.zoom)},Object.defineProperty(n.prototype,"padding",{get:function(){return this.padding_},set:function(t){var r=this.padding_;this.padding_=t;var i=this.getCenter();if(i){var o=t||[0,0,0,0];r=r||[0,0,0,0];var s=this.getResolution(),a=s/2*(o[3]-r[3]+r[1]-o[1]),f=s/2*(o[0]-r[0]+r[2]-o[2]);this.setCenterInternal([i[0]+a,i[1]-f])}},enumerable:!1,configurable:!0}),n.prototype.getUpdatedOptions_=function(t){var r=this.getProperties();return r.resolution!==void 0?r.resolution=this.getResolution():r.zoom=this.getZoom(),r.center=this.getCenterInternal(),r.rotation=this.getRotation(),al({},r,t)},n.prototype.animate=function(t){this.isDef()&&!this.getAnimating()&&this.resolveConstraints(0);for(var r=new Array(arguments.length),i=0;i<r.length;++i){var o=arguments[i];o.center&&(o=al({},o),o.center=rp(o.center,this.getProjection())),o.anchor&&(o=al({},o),o.anchor=rp(o.anchor,this.getProjection())),r[i]=o}this.animateInternal.apply(this,r)},n.prototype.animateInternal=function(t){var r=arguments.length,i;r>1&&typeof arguments[r-1]=="function"&&(i=arguments[r-1],--r);for(var o=0;o<r&&!this.isDef();++o){var s=arguments[o];s.center&&this.setCenterInternal(s.center),s.zoom!==void 0?this.setZoom(s.zoom):s.resolution&&this.setResolution(s.resolution),s.rotation!==void 0&&this.setRotation(s.rotation)}if(o===r){i&&Sx(i,!0);return}for(var a=Date.now(),f=this.targetCenter_.slice(),g=this.targetResolution_,x=this.targetRotation_,k=[];o<r;++o){var B=arguments[o],P={start:a,complete:!1,anchor:B.anchor,duration:B.duration!==void 0?B.duration:1e3,easing:B.easing||Fre,callback:i};if(B.center&&(P.sourceCenter=f,P.targetCenter=B.center.slice(),f=P.targetCenter),B.zoom!==void 0?(P.sourceResolution=g,P.targetResolution=this.getResolutionForZoom(B.zoom),g=P.targetResolution):B.resolution&&(P.sourceResolution=g,P.targetResolution=B.resolution,g=P.targetResolution),B.rotation!==void 0){P.sourceRotation=x;var R=e1(B.rotation-x+Math.PI,2*Math.PI)-Math.PI;P.targetRotation=x+R,x=P.targetRotation}jre(P)?P.complete=!0:a+=P.duration,k.push(P)}this.animations_.push(k),this.setHint(Gs.ANIMATING,1),this.updateAnimations_()},n.prototype.getAnimating=function(){return this.hints_[Gs.ANIMATING]>0},n.prototype.getInteracting=function(){return this.hints_[Gs.INTERACTING]>0},n.prototype.cancelAnimations=function(){this.setHint(Gs.ANIMATING,-this.hints_[Gs.ANIMATING]);for(var t,r=0,i=this.animations_.length;r<i;++r){var o=this.animations_[r];if(o[0].callback&&Sx(o[0].callback,!1),!t)for(var s=0,a=o.length;s<a;++s){var f=o[s];if(!f.complete){t=f.anchor;break}}}this.animations_.length=0,this.cancelAnchor_=t,this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN},n.prototype.updateAnimations_=function(){if(this.updateAnimationKey_!==void 0&&(cancelAnimationFrame(this.updateAnimationKey_),this.updateAnimationKey_=void 0),!!this.getAnimating()){for(var t=Date.now(),r=!1,i=this.animations_.length-1;i>=0;--i){for(var o=this.animations_[i],s=!0,a=0,f=o.length;a<f;++a){var g=o[a];if(!g.complete){var x=t-g.start,k=g.duration>0?x/g.duration:1;k>=1?(g.complete=!0,k=1):s=!1;var B=g.easing(k);if(g.sourceCenter){var P=g.sourceCenter[0],R=g.sourceCenter[1],H=g.targetCenter[0],W=g.targetCenter[1];this.nextCenter_=g.targetCenter;var $=P+B*(H-P),q=R+B*(W-R);this.targetCenter_=[$,q]}if(g.sourceResolution&&g.targetResolution){var oe=B===1?g.targetResolution:g.sourceResolution+B*(g.targetResolution-g.sourceResolution);if(g.anchor){var ne=this.getViewportSize_(this.getRotation()),ce=this.constraints_.resolution(oe,0,ne,!0);this.targetCenter_=this.calculateCenterZoom(ce,g.anchor)}this.nextResolution_=g.targetResolution,this.targetResolution_=oe,this.applyTargetState_(!0)}if(g.sourceRotation!==void 0&&g.targetRotation!==void 0){var ae=B===1?e1(g.targetRotation+Math.PI,2*Math.PI)-Math.PI:g.sourceRotation+B*(g.targetRotation-g.sourceRotation);if(g.anchor){var ue=this.constraints_.rotation(ae,!0);this.targetCenter_=this.calculateCenterRotate(ue,g.anchor)}this.nextRotation_=g.targetRotation,this.targetRotation_=ae}if(this.applyTargetState_(!0),r=!0,!g.complete)break}}if(s){this.animations_[i]=null,this.setHint(Gs.ANIMATING,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;var ye=o[0].callback;ye&&Sx(ye,!0)}}this.animations_=this.animations_.filter(Boolean),r&&this.updateAnimationKey_===void 0&&(this.updateAnimationKey_=requestAnimationFrame(this.updateAnimations_.bind(this)))}},n.prototype.calculateCenterRotate=function(t,r){var i,o=this.getCenterInternal();return o!==void 0&&(i=[o[0]-r[0],o[1]-r[1]],QB(i,t-this.getRotation()),rte(i,r)),i},n.prototype.calculateCenterZoom=function(t,r){var i,o=this.getCenterInternal(),s=this.getResolution();if(o!==void 0&&s!==void 0){var a=r[0]-t*(r[0]-o[0])/s,f=r[1]-t*(r[1]-o[1])/s;i=[a,f]}return i},n.prototype.getViewportSize_=function(t){var r=this.viewportSize_;if(t){var i=r[0],o=r[1];return[Math.abs(i*Math.cos(t))+Math.abs(o*Math.sin(t)),Math.abs(i*Math.sin(t))+Math.abs(o*Math.cos(t))]}else return r},n.prototype.setViewportSize=function(t){this.viewportSize_=Array.isArray(t)?t.slice():[100,100],this.getAnimating()||this.resolveConstraints(0)},n.prototype.getCenter=function(){var t=this.getCenterInternal();return t&&Q6(t,this.getProjection())},n.prototype.getCenterInternal=function(){return this.get(ih.CENTER)},n.prototype.getConstraints=function(){return this.constraints_},n.prototype.getConstrainResolution=function(){return this.get("constrainResolution")},n.prototype.getHints=function(t){return t!==void 0?(t[0]=this.hints_[0],t[1]=this.hints_[1],t):this.hints_.slice()},n.prototype.calculateExtent=function(t){var r=this.calculateExtentInternal(t);return wL(r,this.getProjection())},n.prototype.calculateExtentInternal=function(t){var r=t||this.getViewportSizeMinusPadding_(),i=this.getCenterInternal();ao(i,1);var o=this.getResolution();ao(o!==void 0,2);var s=this.getRotation();return ao(s!==void 0,3),z6(i,o,s,r)},n.prototype.getMaxResolution=function(){return this.maxResolution_},n.prototype.getMinResolution=function(){return this.minResolution_},n.prototype.getMaxZoom=function(){return this.getZoomForResolution(this.minResolution_)},n.prototype.setMaxZoom=function(t){this.applyOptions_(this.getUpdatedOptions_({maxZoom:t}))},n.prototype.getMinZoom=function(){return this.getZoomForResolution(this.maxResolution_)},n.prototype.setMinZoom=function(t){this.applyOptions_(this.getUpdatedOptions_({minZoom:t}))},n.prototype.setConstrainResolution=function(t){this.applyOptions_(this.getUpdatedOptions_({constrainResolution:t}))},n.prototype.getProjection=function(){return this.projection_},n.prototype.getResolution=function(){return this.get(ih.RESOLUTION)},n.prototype.getResolutions=function(){return this.resolutions_},n.prototype.getResolutionForExtent=function(t,r){return this.getResolutionForExtentInternal(j0(t,this.getProjection()),r)},n.prototype.getResolutionForExtentInternal=function(t,r){var i=r||this.getViewportSizeMinusPadding_(),o=os(t)/i[0],s=$A(t)/i[1];return Math.max(o,s)},n.prototype.getResolutionForValueFunction=function(t){var r=t||2,i=this.getConstrainedResolution(this.maxResolution_),o=this.minResolution_,s=Math.log(i/o)/Math.log(r);return function(a){var f=i/Math.pow(r,a*s);return f}},n.prototype.getRotation=function(){return this.get(ih.ROTATION)},n.prototype.getValueForResolutionFunction=function(t){var r=Math.log(t||2),i=this.getConstrainedResolution(this.maxResolution_),o=this.minResolution_,s=Math.log(i/o)/r;return function(a){var f=Math.log(i/a)/r/s;return f}},n.prototype.getViewportSizeMinusPadding_=function(t){var r=this.getViewportSize_(t),i=this.padding_;return i&&(r=[r[0]-i[1]-i[3],r[1]-i[0]-i[2]]),r},n.prototype.getState=function(){var t=this.getProjection(),r=this.getResolution(),i=this.getRotation(),o=this.getCenterInternal(),s=this.padding_;if(s){var a=this.getViewportSizeMinusPadding_();o=cM(o,this.getViewportSize_(),[a[0]/2+s[3],a[1]/2+s[0]],r,i)}return{center:o.slice(0),projection:t!==void 0?t:null,resolution:r,nextCenter:this.nextCenter_,nextResolution:this.nextResolution_,nextRotation:this.nextRotation_,rotation:i,zoom:this.getZoom()}},n.prototype.getZoom=function(){var t,r=this.getResolution();return r!==void 0&&(t=this.getZoomForResolution(r)),t},n.prototype.getZoomForResolution=function(t){var r=this.minZoom_||0,i,o;if(this.resolutions_){var s=RB(this.resolutions_,t,1);r=s,i=this.resolutions_[s],s==this.resolutions_.length-1?o=2:o=i/this.resolutions_[s+1]}else i=this.maxResolution_,o=this.zoomFactor_;return r+Math.log(i/t)/Math.log(o)},n.prototype.getResolutionForZoom=function(t){if(this.resolutions_){if(this.resolutions_.length<=1)return 0;var r=vl(Math.floor(t),0,this.resolutions_.length-2),i=this.resolutions_[r]/this.resolutions_[r+1];return this.resolutions_[r]/Math.pow(i,vl(t-r,0,1))}else return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)},n.prototype.fit=function(t,r){var i;if(ao(Array.isArray(t)||typeof t.getSimplifiedGeometry=="function",24),Array.isArray(t)){ao(!NB(t),25);var o=j0(t,this.getProjection());i=g9(o)}else if(t.getType()==="Circle"){var o=j0(t.getExtent(),this.getProjection());i=g9(o),i.rotate(this.getRotation(),Dm(o))}else{var s=cte();s?i=t.clone().transform(s,this.getProjection()):i=t}this.fitInternal(i,r)},n.prototype.rotatedExtentForGeometry=function(t){for(var r=this.getRotation(),i=Math.cos(r),o=Math.sin(-r),s=t.getFlatCoordinates(),a=t.getStride(),f=1/0,g=1/0,x=-1/0,k=-1/0,B=0,P=s.length;B<P;B+=a){var R=s[B]*i-s[B+1]*o,H=s[B]*o+s[B+1]*i;f=Math.min(f,R),g=Math.min(g,H),x=Math.max(x,R),k=Math.max(k,H)}return[f,g,x,k]},n.prototype.fitInternal=function(t,r){var i=r||{},o=i.size;o||(o=this.getViewportSizeMinusPadding_());var s=i.padding!==void 0?i.padding:[0,0,0,0],a=i.nearest!==void 0?i.nearest:!1,f;i.minResolution!==void 0?f=i.minResolution:i.maxZoom!==void 0?f=this.getResolutionForZoom(i.maxZoom):f=0;var g=this.rotatedExtentForGeometry(t),x=this.getResolutionForExtentInternal(g,[o[0]-s[1]-s[3],o[1]-s[0]-s[2]]);x=isNaN(x)?f:Math.max(x,f),x=this.getConstrainedResolution(x,a?0:1);var k=this.getRotation(),B=Math.sin(k),P=Math.cos(k),R=Dm(g);R[0]+=(s[1]-s[3])/2*x,R[1]+=(s[0]-s[2])/2*x;var H=R[0]*P-R[1]*B,W=R[1]*P+R[0]*B,$=this.getConstrainedCenter([H,W],x),q=i.callback?i.callback:d1;i.duration!==void 0?this.animateInternal({resolution:x,center:$,duration:i.duration,easing:i.easing},q):(this.targetResolution_=x,this.targetCenter_=$,this.applyTargetState_(!1,!0),Sx(q,!0))},n.prototype.centerOn=function(t,r,i){this.centerOnInternal(rp(t,this.getProjection()),r,i)},n.prototype.centerOnInternal=function(t,r,i){this.setCenterInternal(cM(t,r,i,this.getResolution(),this.getRotation()))},n.prototype.calculateCenterShift=function(t,r,i,o){var s,a=this.padding_;if(a&&t){var f=this.getViewportSizeMinusPadding_(-i),g=cM(t,o,[f[0]/2+a[3],f[1]/2+a[0]],r,i);s=[t[0]-g[0],t[1]-g[1]]}return s},n.prototype.isDef=function(){return!!this.getCenterInternal()&&this.getResolution()!==void 0},n.prototype.adjustCenter=function(t){var r=Q6(this.targetCenter_,this.getProjection());this.setCenter([r[0]+t[0],r[1]+t[1]])},n.prototype.adjustCenterInternal=function(t){var r=this.targetCenter_;this.setCenterInternal([r[0]+t[0],r[1]+t[1]])},n.prototype.adjustResolution=function(t,r){var i=r&&rp(r,this.getProjection());this.adjustResolutionInternal(t,i)},n.prototype.adjustResolutionInternal=function(t,r){var i=this.getAnimating()||this.getInteracting(),o=this.getViewportSize_(this.getRotation()),s=this.constraints_.resolution(this.targetResolution_*t,0,o,i);r&&(this.targetCenter_=this.calculateCenterZoom(s,r)),this.targetResolution_*=t,this.applyTargetState_()},n.prototype.adjustZoom=function(t,r){this.adjustResolution(Math.pow(this.zoomFactor_,-t),r)},n.prototype.adjustRotation=function(t,r){r&&(r=rp(r,this.getProjection())),this.adjustRotationInternal(t,r)},n.prototype.adjustRotationInternal=function(t,r){var i=this.getAnimating()||this.getInteracting(),o=this.constraints_.rotation(this.targetRotation_+t,i);r&&(this.targetCenter_=this.calculateCenterRotate(o,r)),this.targetRotation_+=t,this.applyTargetState_()},n.prototype.setCenter=function(t){this.setCenterInternal(t&&rp(t,this.getProjection()))},n.prototype.setCenterInternal=function(t){this.targetCenter_=t,this.applyTargetState_()},n.prototype.setHint=function(t,r){return this.hints_[t]+=r,this.changed(),this.hints_[t]},n.prototype.setResolution=function(t){this.targetResolution_=t,this.applyTargetState_()},n.prototype.setRotation=function(t){this.targetRotation_=t,this.applyTargetState_()},n.prototype.setZoom=function(t){this.setResolution(this.getResolutionForZoom(t))},n.prototype.applyTargetState_=function(t,r){var i=this.getAnimating()||this.getInteracting()||r,o=this.constraints_.rotation(this.targetRotation_,i),s=this.getViewportSize_(o),a=this.constraints_.resolution(this.targetResolution_,0,s,i),f=this.constraints_.center(this.targetCenter_,a,s,i,this.calculateCenterShift(this.targetCenter_,a,o,s));this.get(ih.ROTATION)!==o&&this.set(ih.ROTATION,o),this.get(ih.RESOLUTION)!==a&&(this.set(ih.RESOLUTION,a),this.set("zoom",this.getZoom(),!0)),(!f||!this.get(ih.CENTER)||!_3(this.get(ih.CENTER),f))&&this.set(ih.CENTER,f),this.getAnimating()&&!t&&this.cancelAnimations(),this.cancelAnchor_=void 0},n.prototype.resolveConstraints=function(t,r,i){var o=t!==void 0?t:200,s=r||0,a=this.constraints_.rotation(this.targetRotation_),f=this.getViewportSize_(a),g=this.constraints_.resolution(this.targetResolution_,s,f),x=this.constraints_.center(this.targetCenter_,g,f,!1,this.calculateCenterShift(this.targetCenter_,g,a,f));if(o===0&&!this.cancelAnchor_){this.targetResolution_=g,this.targetRotation_=a,this.targetCenter_=x,this.applyTargetState_();return}var k=i||(o===0?this.cancelAnchor_:void 0);this.cancelAnchor_=void 0,(this.getResolution()!==g||this.getRotation()!==a||!this.getCenterInternal()||!_3(this.getCenterInternal(),x))&&(this.getAnimating()&&this.cancelAnimations(),this.animateInternal({rotation:a,center:x,resolution:g,duration:o,easing:jy,anchor:k}))},n.prototype.beginInteraction=function(){this.resolveConstraints(0),this.setHint(Gs.INTERACTING,1)},n.prototype.endInteraction=function(t,r,i){var o=i&&rp(i,this.getProjection());this.endInteractionInternal(t,r,o)},n.prototype.endInteractionInternal=function(t,r,i){this.setHint(Gs.INTERACTING,-1),this.resolveConstraints(t,r,i)},n.prototype.getConstrainedCenter=function(t,r){var i=this.getViewportSize_(this.getRotation());return this.constraints_.center(t,r||this.getResolution(),i)},n.prototype.getConstrainedZoom=function(t,r){var i=this.getResolutionForZoom(t);return this.getZoomForResolution(this.getConstrainedResolution(i,r))},n.prototype.getConstrainedResolution=function(t,r){var i=r||0,o=this.getViewportSize_(this.getRotation());return this.constraints_.resolution(t,i,o)},n}(mh);function Sx(e,n){setTimeout(function(){e(n)},0)}function Rre(e){if(e.extent!==void 0){var n=e.smoothExtentConstraint!==void 0?e.smoothExtentConstraint:!0;return B9(e.extent,e.constrainOnlyCenter,n)}var t=qB(e.projection,"EPSG:3857");if(e.multiWorld!==!0&&t.isGlobal()){var r=t.getExtent().slice();return r[0]=-1/0,r[2]=1/0,B9(r,!1,!1)}return kre}function Lre(e){var n,t,r,i=28,o=2,s=e.minZoom!==void 0?e.minZoom:AM,a=e.maxZoom!==void 0?e.maxZoom:i,f=e.zoomFactor!==void 0?e.zoomFactor:o,g=e.multiWorld!==void 0?e.multiWorld:!1,x=e.smoothResolutionConstraint!==void 0?e.smoothResolutionConstraint:!0,k=e.showFullExtent!==void 0?e.showFullExtent:!1,B=qB(e.projection,"EPSG:3857"),P=B.getExtent(),R=e.constrainOnlyCenter,H=e.extent;if(!g&&!H&&B.isGlobal()&&(R=!1,H=P),e.resolutions!==void 0){var W=e.resolutions;t=W[s],r=W[a]!==void 0?W[a]:W[W.length-1],e.constrainResolution?n=Ire(W,x,!R&&H,k):n=k9(t,r,x,!R&&H,k)}else{var $=P?Math.max(os(P),$A(P)):360*cf[gA.DEGREES]/B.getMetersPerUnit(),q=$/u7/Math.pow(o,AM),oe=q/Math.pow(o,i-AM);t=e.maxResolution,t!==void 0?s=0:t=q/Math.pow(f,s),r=e.minResolution,r===void 0&&(e.maxZoom!==void 0?e.maxResolution!==void 0?r=t/Math.pow(f,a):r=q/Math.pow(f,a):r=oe),a=s+Math.floor(Math.log(t/r)/Math.log(f)),r=t/Math.pow(f,a-s),e.constrainResolution?n=Tre(f,t,r,x,!R&&H,k):n=k9(t,r,x,!R&&H,k)}return{constraint:n,maxResolution:t,minResolution:r,minZoom:s,zoomFactor:f}}function zre(e){var n=e.enableRotation!==void 0?e.enableRotation:!0;if(n){var t=e.constrainRotation;return t===void 0||t===!0?Pre():t===!1?I9:typeof t=="number"?Kre(t):I9}else return d7}function jre(e){return!(e.sourceCenter&&e.targetCenter&&!_3(e.sourceCenter,e.targetCenter)||e.sourceResolution!==e.targetResolution||e.sourceRotation!==e.targetRotation)}function cM(e,n,t,r,i){var o=Math.cos(-i),s=Math.sin(-i),a=e[0]*o-e[1]*s,f=e[1]*o+e[0]*s;a+=(n[0]/2-t[0])*r,f+=(t[1]-n[1]/2)*r,s=-s;var g=a*o-f*s,x=f*o+a*s;return[g,x]}function T9(e){return e[0]>0&&e[1]>0}function Wre(e,n,t){return t===void 0&&(t=[0,0]),t[0]=e[0]*n+.5|0,t[1]=e[1]*n+.5|0,t}function pA(e,n){return Array.isArray(e)?e:(n===void 0?n=[e,e]:(n[0]=e,n[1]=e),n)}var Nre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}();function ez(e){if(e instanceof d5){e.setMapInternal(null);return}e instanceof f5&&e.getLayers().forEach(ez)}function tz(e,n){if(e instanceof d5){e.setMapInternal(n);return}if(e instanceof f5)for(var t=e.getLayers().getArray(),r=0,i=t.length;r<i;++r)tz(t[r],n)}var Gre=function(e){Nre(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un;var i=Qre(t);r.renderComplete_,r.loaded_=!0,r.boundHandleBrowserEvent_=r.handleBrowserEvent.bind(r),r.maxTilesLoading_=t.maxTilesLoading!==void 0?t.maxTilesLoading:16,r.pixelRatio_=t.pixelRatio!==void 0?t.pixelRatio:cL,r.postRenderTimeoutHandle_,r.animationDelayKey_,r.animationDelay_=(function(){this.animationDelayKey_=void 0,this.renderFrame_(Date.now())}).bind(r),r.coordinateToPixelTransform_=xd(),r.pixelToCoordinateTransform_=xd(),r.frameIndex_=0,r.frameState_=null,r.previousExtent_=null,r.viewPropertyListenerKey_=null,r.viewChangeListenerKey_=null,r.layerGroupPropertyListenerKeys_=null,r.viewport_=document.createElement("div"),r.viewport_.className="ol-viewport"+("ontouchstart"in window?" ol-touch":""),r.viewport_.style.position="relative",r.viewport_.style.overflow="hidden",r.viewport_.style.width="100%",r.viewport_.style.height="100%",r.overlayContainer_=document.createElement("div"),r.overlayContainer_.style.position="absolute",r.overlayContainer_.style.zIndex="0",r.overlayContainer_.style.width="100%",r.overlayContainer_.style.height="100%",r.overlayContainer_.style.pointerEvents="none",r.overlayContainer_.className="ol-overlaycontainer",r.viewport_.appendChild(r.overlayContainer_),r.overlayContainerStopEvent_=document.createElement("div"),r.overlayContainerStopEvent_.style.position="absolute",r.overlayContainerStopEvent_.style.zIndex="0",r.overlayContainerStopEvent_.style.width="100%",r.overlayContainerStopEvent_.style.height="100%",r.overlayContainerStopEvent_.style.pointerEvents="none",r.overlayContainerStopEvent_.className="ol-overlaycontainer-stopevent",r.viewport_.appendChild(r.overlayContainerStopEvent_),r.mapBrowserEventHandler_=null,r.moveTolerance_=t.moveTolerance,r.keyboardEventTarget_=i.keyboardEventTarget,r.targetChangeHandlerKeys_=null,r.controls=i.controls||new _d,r.interactions=i.interactions||new _d,r.overlays_=i.overlays,r.overlayIdIndex_={},r.renderer_=null,r.postRenderFunctions_=[],r.tileQueue_=new Ore(r.getTilePriority.bind(r),r.handleTileChange_.bind(r)),r.addChangeListener(Gu.LAYERGROUP,r.handleLayerGroupChanged_),r.addChangeListener(Gu.VIEW,r.handleViewChanged_),r.addChangeListener(Gu.SIZE,r.handleSizeChanged_),r.addChangeListener(Gu.TARGET,r.handleTargetChanged_),r.setProperties(i.values);var o=r;return t.view&&!(t.view instanceof pp)&&t.view.then(function(s){o.setView(new pp(s))}),r.controls.addEventListener(WA.ADD,(function(s){s.element.setMap(this)}).bind(r)),r.controls.addEventListener(WA.REMOVE,(function(s){s.element.setMap(null)}).bind(r)),r.interactions.addEventListener(WA.ADD,(function(s){s.element.setMap(this)}).bind(r)),r.interactions.addEventListener(WA.REMOVE,(function(s){s.element.setMap(null)}).bind(r)),r.overlays_.addEventListener(WA.ADD,(function(s){this.addOverlayInternal_(s.element)}).bind(r)),r.overlays_.addEventListener(WA.REMOVE,(function(s){var a=s.element,f=a.getId();f!==void 0&&delete this.overlayIdIndex_[f.toString()],s.element.setMap(null)}).bind(r)),r.controls.forEach((function(s){s.setMap(this)}).bind(r)),r.interactions.forEach((function(s){s.setMap(this)}).bind(r)),r.overlays_.forEach(r.addOverlayInternal_.bind(r)),r}return n.prototype.createRenderer=function(){throw new Error("Use a map type that has a createRenderer method")},n.prototype.addControl=function(t){this.getControls().push(t)},n.prototype.addInteraction=function(t){this.getInteractions().push(t)},n.prototype.addLayer=function(t){var r=this.getLayerGroup().getLayers();r.push(t)},n.prototype.handleLayerAdd_=function(t){tz(t.layer,this)},n.prototype.addOverlay=function(t){this.getOverlays().push(t)},n.prototype.addOverlayInternal_=function(t){var r=t.getId();r!==void 0&&(this.overlayIdIndex_[r.toString()]=t),t.setMap(this)},n.prototype.disposeInternal=function(){this.controls.clear(),this.interactions.clear(),this.overlays_.clear(),this.setTarget(null),e.prototype.disposeInternal.call(this)},n.prototype.forEachFeatureAtPixel=function(t,r,i){if(!(!this.frameState_||!this.renderer_)){var o=this.getCoordinateFromPixelInternal(t);i=i!==void 0?i:{};var s=i.hitTolerance!==void 0?i.hitTolerance:0,a=i.layerFilter!==void 0?i.layerFilter:ty,f=i.checkWrapped!==!1;return this.renderer_.forEachFeatureAtCoordinate(o,this.frameState_,s,f,r,null,a,null)}},n.prototype.getFeaturesAtPixel=function(t,r){var i=[];return this.forEachFeatureAtPixel(t,function(o){i.push(o)},r),i},n.prototype.getAllLayers=function(){var t=[];function r(i){i.forEach(function(o){o instanceof f5?r(o.getLayers()):t.push(o)})}return r(this.getLayers()),t},n.prototype.forEachLayerAtPixel=function(t,r,i){if(!(!this.frameState_||!this.renderer_)){var o=i||{},s=o.hitTolerance!==void 0?o.hitTolerance:0,a=o.layerFilter||ty;return this.renderer_.forEachLayerAtPixel(t,this.frameState_,s,r,a)}},n.prototype.hasFeatureAtPixel=function(t,r){if(!this.frameState_||!this.renderer_)return!1;var i=this.getCoordinateFromPixelInternal(t);r=r!==void 0?r:{};var o=r.layerFilter!==void 0?r.layerFilter:ty,s=r.hitTolerance!==void 0?r.hitTolerance:0,a=r.checkWrapped!==!1;return this.renderer_.hasFeatureAtCoordinate(i,this.frameState_,s,a,o,null)},n.prototype.getEventCoordinate=function(t){return this.getCoordinateFromPixel(this.getEventPixel(t))},n.prototype.getEventCoordinateInternal=function(t){return this.getCoordinateFromPixelInternal(this.getEventPixel(t))},n.prototype.getEventPixel=function(t){var r=this.viewport_.getBoundingClientRect(),i="changedTouches"in t?t.changedTouches[0]:t;return[i.clientX-r.left,i.clientY-r.top]},n.prototype.getTarget=function(){return this.get(Gu.TARGET)},n.prototype.getTargetElement=function(){var t=this.getTarget();return t!==void 0?typeof t=="string"?document.getElementById(t):t:null},n.prototype.getCoordinateFromPixel=function(t){return Q6(this.getCoordinateFromPixelInternal(t),this.getView().getProjection())},n.prototype.getCoordinateFromPixelInternal=function(t){var r=this.frameState_;return r?rl(r.pixelToCoordinateTransform,t.slice()):null},n.prototype.getControls=function(){return this.controls},n.prototype.getOverlays=function(){return this.overlays_},n.prototype.getOverlayById=function(t){var r=this.overlayIdIndex_[t.toString()];return r!==void 0?r:null},n.prototype.getInteractions=function(){return this.interactions},n.prototype.getLayerGroup=function(){return this.get(Gu.LAYERGROUP)},n.prototype.setLayers=function(t){var r=this.getLayerGroup();if(t instanceof _d){r.setLayers(t);return}var i=r.getLayers();i.clear(),i.extend(t)},n.prototype.getLayers=function(){var t=this.getLayerGroup().getLayers();return t},n.prototype.getLoadingOrNotReady=function(){for(var t=this.getLayerGroup().getLayerStatesArray(),r=0,i=t.length;r<i;++r){var o=t[r];if(o.visible){var s=o.layer.getRenderer();if(s&&!s.ready)return!0;var a=o.layer.getSource();if(a&&a.loading)return!0}}return!1},n.prototype.getPixelFromCoordinate=function(t){var r=rp(t,this.getView().getProjection());return this.getPixelFromCoordinateInternal(r)},n.prototype.getPixelFromCoordinateInternal=function(t){var r=this.frameState_;return r?rl(r.coordinateToPixelTransform,t.slice(0,2)):null},n.prototype.getRenderer=function(){return this.renderer_},n.prototype.getSize=function(){return this.get(Gu.SIZE)},n.prototype.getView=function(){return this.get(Gu.VIEW)},n.prototype.getViewport=function(){return this.viewport_},n.prototype.getOverlayContainer=function(){return this.overlayContainer_},n.prototype.getOverlayContainerStopEvent=function(){return this.overlayContainerStopEvent_},n.prototype.getOwnerDocument=function(){var t=this.getTargetElement();return t?t.ownerDocument:document},n.prototype.getTilePriority=function(t,r,i,o){return Bre(this.frameState_,t,r,i,o)},n.prototype.handleBrowserEvent=function(t,r){var i=r||t.type,o=new Zp(i,this,t);this.handleMapBrowserEvent(o)},n.prototype.handleMapBrowserEvent=function(t){if(this.frameState_){var r=t.originalEvent,i=r.type;if(i===nE.POINTERDOWN||i===ki.WHEEL||i===ki.KEYDOWN){var o=this.getOwnerDocument(),s=this.viewport_.getRootNode?this.viewport_.getRootNode():o,a=r.target;if(this.overlayContainerStopEvent_.contains(a)||!(s===o?o.documentElement:s).contains(a))return}if(t.frameState=this.frameState_,this.dispatchEvent(t)!==!1)for(var f=this.getInteractions().getArray().slice(),g=f.length-1;g>=0;g--){var x=f[g];if(!(x.getMap()!==this||!x.getActive()||!this.getTargetElement())){var k=x.handleEvent(t);if(!k||t.propagationStopped)break}}}},n.prototype.handlePostRender=function(){var t=this.frameState_,r=this.tileQueue_;if(!r.isEmpty()){var i=this.maxTilesLoading_,o=i;if(t){var s=t.viewHints;if(s[Gs.ANIMATING]||s[Gs.INTERACTING]){var a=Date.now()-t.time>8;i=a?0:8,o=a?0:2}}r.getTilesLoading()<i&&(r.reprioritize(),r.loadMoreTiles(i,o))}t&&this.renderer_&&!t.animate&&(this.renderComplete_===!0?(this.hasListener(Bm.RENDERCOMPLETE)&&this.renderer_.dispatchRenderEvent(Bm.RENDERCOMPLETE,t),this.loaded_===!1&&(this.loaded_=!0,this.dispatchEvent(new bg(op.LOADEND,this,t)))):this.loaded_===!0&&(this.loaded_=!1,this.dispatchEvent(new bg(op.LOADSTART,this,t))));for(var f=this.postRenderFunctions_,g=0,x=f.length;g<x;++g)f[g](this,t);f.length=0},n.prototype.handleSizeChanged_=function(){this.getView()&&!this.getView().getAnimating()&&this.getView().resolveConstraints(0),this.render()},n.prototype.handleTargetChanged_=function(){if(this.mapBrowserEventHandler_){for(var t=0,r=this.targetChangeHandlerKeys_.length;t<r;++t)Ga(this.targetChangeHandlerKeys_[t]);this.targetChangeHandlerKeys_=null,this.viewport_.removeEventListener(ki.CONTEXTMENU,this.boundHandleBrowserEvent_),this.viewport_.removeEventListener(ki.WHEEL,this.boundHandleBrowserEvent_),this.mapBrowserEventHandler_.dispose(),this.mapBrowserEventHandler_=null,O3(this.viewport_)}var i=this.getTargetElement();if(!i)this.renderer_&&(clearTimeout(this.postRenderTimeoutHandle_),this.postRenderTimeoutHandle_=void 0,this.postRenderFunctions_.length=0,this.renderer_.dispose(),this.renderer_=null),this.animationDelayKey_&&(cancelAnimationFrame(this.animationDelayKey_),this.animationDelayKey_=void 0);else{i.appendChild(this.viewport_),this.renderer_||(this.renderer_=this.createRenderer()),this.mapBrowserEventHandler_=new xre(this,this.moveTolerance_);for(var o in Ns)this.mapBrowserEventHandler_.addEventListener(Ns[o],this.handleMapBrowserEvent.bind(this));this.viewport_.addEventListener(ki.CONTEXTMENU,this.boundHandleBrowserEvent_,!1),this.viewport_.addEventListener(ki.WHEEL,this.boundHandleBrowserEvent_,dL?{passive:!1}:!1);var s=this.getOwnerDocument().defaultView,a=this.keyboardEventTarget_?this.keyboardEventTarget_:i;this.targetChangeHandlerKeys_=[wo(a,ki.KEYDOWN,this.handleBrowserEvent,this),wo(a,ki.KEYPRESS,this.handleBrowserEvent,this),wo(s,ki.RESIZE,this.updateSize,this)]}this.updateSize()},n.prototype.handleTileChange_=function(){this.render()},n.prototype.handleViewPropertyChanged_=function(){this.render()},n.prototype.handleViewChanged_=function(){this.viewPropertyListenerKey_&&(Ga(this.viewPropertyListenerKey_),this.viewPropertyListenerKey_=null),this.viewChangeListenerKey_&&(Ga(this.viewChangeListenerKey_),this.viewChangeListenerKey_=null);var t=this.getView();t&&(this.updateViewportSize_(),this.viewPropertyListenerKey_=wo(t,xy.PROPERTYCHANGE,this.handleViewPropertyChanged_,this),this.viewChangeListenerKey_=wo(t,ki.CHANGE,this.handleViewPropertyChanged_,this),t.resolveConstraints(0)),this.render()},n.prototype.handleLayerGroupChanged_=function(){this.layerGroupPropertyListenerKeys_&&(this.layerGroupPropertyListenerKeys_.forEach(Ga),this.layerGroupPropertyListenerKeys_=null);var t=this.getLayerGroup();t&&(this.handleLayerAdd_(new em("addlayer",t)),this.layerGroupPropertyListenerKeys_=[wo(t,xy.PROPERTYCHANGE,this.render,this),wo(t,ki.CHANGE,this.render,this),wo(t,"addlayer",this.handleLayerAdd_,this),wo(t,"removelayer",this.handleLayerRemove_,this)]),this.render()},n.prototype.isRendered=function(){return!!this.frameState_},n.prototype.renderSync=function(){this.animationDelayKey_&&cancelAnimationFrame(this.animationDelayKey_),this.animationDelay_()},n.prototype.redrawText=function(){for(var t=this.getLayerGroup().getLayerStatesArray(),r=0,i=t.length;r<i;++r){var o=t[r].layer;o.hasRenderer()&&o.getRenderer().handleFontsChanged()}},n.prototype.render=function(){this.renderer_&&this.animationDelayKey_===void 0&&(this.animationDelayKey_=requestAnimationFrame(this.animationDelay_))},n.prototype.removeControl=function(t){return this.getControls().remove(t)},n.prototype.removeInteraction=function(t){return this.getInteractions().remove(t)},n.prototype.removeLayer=function(t){var r=this.getLayerGroup().getLayers();return r.remove(t)},n.prototype.handleLayerRemove_=function(t){ez(t.layer)},n.prototype.removeOverlay=function(t){return this.getOverlays().remove(t)},n.prototype.renderFrame_=function(t){var r=this,i=this.getSize(),o=this.getView(),s=this.frameState_,a=null;if(i!==void 0&&T9(i)&&o&&o.isDef()){var f=o.getHints(this.frameState_?this.frameState_.viewHints:void 0),g=o.getState();if(a={animate:!1,coordinateToPixelTransform:this.coordinateToPixelTransform_,declutterTree:null,extent:z6(g.center,g.resolution,g.rotation,i),index:this.frameIndex_++,layerIndex:0,layerStatesArray:this.getLayerGroup().getLayerStatesArray(),pixelRatio:this.pixelRatio_,pixelToCoordinateTransform:this.pixelToCoordinateTransform_,postRenderFunctions:[],size:i,tileQueue:this.tileQueue_,time:t,usedTiles:{},viewState:g,viewHints:f,wantedTiles:{},mapId:$i(this),renderTargets:{}},g.nextCenter&&g.nextResolution){var x=isNaN(g.nextRotation)?g.rotation:g.nextRotation;a.nextExtent=z6(g.nextCenter,g.nextResolution,x,i)}}if(this.frameState_=a,this.renderer_.renderFrame(a),a){if(a.animate&&this.render(),Array.prototype.push.apply(this.postRenderFunctions_,a.postRenderFunctions),s){var k=!this.previousExtent_||!NB(this.previousExtent_)&&!wy(a.extent,this.previousExtent_);k&&(this.dispatchEvent(new bg(op.MOVESTART,this,s)),this.previousExtent_=Y_(this.previousExtent_))}var B=this.previousExtent_&&!a.viewHints[Gs.ANIMATING]&&!a.viewHints[Gs.INTERACTING]&&!wy(a.extent,this.previousExtent_);B&&(this.dispatchEvent(new bg(op.MOVEEND,this,a)),pL(a.extent,this.previousExtent_))}this.dispatchEvent(new bg(op.POSTRENDER,this,a)),this.renderComplete_=this.hasListener(op.LOADSTART)||this.hasListener(op.LOADEND)||this.hasListener(Bm.RENDERCOMPLETE)?!this.tileQueue_.getTilesLoading()&&!this.tileQueue_.getCount()&&!this.getLoadingOrNotReady():void 0,this.postRenderTimeoutHandle_||(this.postRenderTimeoutHandle_=setTimeout(function(){r.postRenderTimeoutHandle_=void 0,r.handlePostRender()},0))},n.prototype.setLayerGroup=function(t){var r=this.getLayerGroup();r&&this.handleLayerRemove_(new em("removelayer",r)),this.set(Gu.LAYERGROUP,t)},n.prototype.setSize=function(t){this.set(Gu.SIZE,t)},n.prototype.setTarget=function(t){this.set(Gu.TARGET,t)},n.prototype.setView=function(t){if(!t||t instanceof pp){this.set(Gu.VIEW,t);return}this.set(Gu.VIEW,new pp);var r=this;t.then(function(i){r.setView(new pp(i))})},n.prototype.updateSize=function(){var t=this.getTargetElement(),r=void 0;if(t){var i=getComputedStyle(t),o=t.offsetWidth-parseFloat(i.borderLeftWidth)-parseFloat(i.paddingLeft)-parseFloat(i.paddingRight)-parseFloat(i.borderRightWidth),s=t.offsetHeight-parseFloat(i.borderTopWidth)-parseFloat(i.paddingTop)-parseFloat(i.paddingBottom)-parseFloat(i.borderBottomWidth);!isNaN(o)&&!isNaN(s)&&(r=[o,s],!T9(r)&&(t.offsetWidth||t.offsetHeight||t.getClientRects().length)&&console.warn("No map visible because the map container's width or height are 0."))}this.setSize(r),this.updateViewportSize_()},n.prototype.updateViewportSize_=function(){var t=this.getView();if(t){var r=void 0,i=getComputedStyle(this.viewport_);i.width&&i.height&&(r=[parseInt(i.width,10),parseInt(i.height,10)]),t.setViewportSize(r)}},n}(mh);function Qre(e){var n=null;e.keyboardEventTarget!==void 0&&(n=typeof e.keyboardEventTarget=="string"?document.getElementById(e.keyboardEventTarget):e.keyboardEventTarget);var t={},r=e.layers&&typeof e.layers.getLayers=="function"?e.layers:new f5({layers:e.layers});t[Gu.LAYERGROUP]=r,t[Gu.TARGET]=e.target,t[Gu.VIEW]=e.view instanceof pp?e.view:new pp;var i;e.controls!==void 0&&(Array.isArray(e.controls)?i=new _d(e.controls.slice()):(ao(typeof e.controls.getArray=="function",47),i=e.controls));var o;e.interactions!==void 0&&(Array.isArray(e.interactions)?o=new _d(e.interactions.slice()):(ao(typeof e.interactions.getArray=="function",48),o=e.interactions));var s;return e.overlays!==void 0?Array.isArray(e.overlays)?s=new _d(e.overlays.slice()):(ao(typeof e.overlays.getArray=="function",49),s=e.overlays):s=new _d,{controls:i,interactions:o,keyboardEventTarget:n,overlays:s,values:t}}const $re=Gre;var Yre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),qre=function(e){Yre(n,e);function n(t){var r=e.call(this)||this,i=t.element;return i&&!t.target&&!i.style.pointerEvents&&(i.style.pointerEvents="auto"),r.element=i||null,r.target_=null,r.map_=null,r.listenerKeys=[],t.render&&(r.render=t.render),t.target&&r.setTarget(t.target),r}return n.prototype.disposeInternal=function(){O3(this.element),e.prototype.disposeInternal.call(this)},n.prototype.getMap=function(){return this.map_},n.prototype.setMap=function(t){this.map_&&O3(this.element);for(var r=0,i=this.listenerKeys.length;r<i;++r)Ga(this.listenerKeys[r]);if(this.listenerKeys.length=0,this.map_=t,t){var o=this.target_?this.target_:t.getOverlayContainerStopEvent();o.appendChild(this.element),this.render!==d1&&this.listenerKeys.push(wo(t,op.POSTRENDER,this.render,this)),t.render()}},n.prototype.render=function(t){},n.prototype.setTarget=function(t){this.target_=typeof t=="string"?document.getElementById(t):t},n}(mh);const h7=qre;var Vre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Hre=function(e){Vre(n,e);function n(t){var r=this,i=t||{};r=e.call(this,{element:document.createElement("div"),render:i.render,target:i.target})||this,r.ulElement_=document.createElement("ul"),r.collapsed_=i.collapsed!==void 0?i.collapsed:!0,r.userCollapsed_=r.collapsed_,r.overrideCollapsible_=i.collapsible!==void 0,r.collapsible_=i.collapsible!==void 0?i.collapsible:!0,r.collapsible_||(r.collapsed_=!1);var o=i.className!==void 0?i.className:"ol-attribution",s=i.tipLabel!==void 0?i.tipLabel:"Attributions",a=i.expandClassName!==void 0?i.expandClassName:o+"-expand",f=i.collapseLabel!==void 0?i.collapseLabel:"›",g=i.collapseClassName!==void 0?i.collapseClassName:o+"-collapse";typeof f=="string"?(r.collapseLabel_=document.createElement("span"),r.collapseLabel_.textContent=f,r.collapseLabel_.className=g):r.collapseLabel_=f;var x=i.label!==void 0?i.label:"i";typeof x=="string"?(r.label_=document.createElement("span"),r.label_.textContent=x,r.label_.className=a):r.label_=x;var k=r.collapsible_&&!r.collapsed_?r.collapseLabel_:r.label_;r.toggleButton_=document.createElement("button"),r.toggleButton_.setAttribute("type","button"),r.toggleButton_.setAttribute("aria-expanded",String(!r.collapsed_)),r.toggleButton_.title=s,r.toggleButton_.appendChild(k),r.toggleButton_.addEventListener(ki.CLICK,r.handleClick_.bind(r),!1);var B=o+" "+h5+" "+s7+(r.collapsed_&&r.collapsible_?" "+w9:"")+(r.collapsible_?"":" ol-uncollapsible"),P=r.element;return P.className=B,P.appendChild(r.toggleButton_),P.appendChild(r.ulElement_),r.renderedAttributions_=[],r.renderedVisible_=!0,r}return n.prototype.collectSourceAttributions_=function(t){for(var r={},i=[],o=!0,s=t.layerStatesArray,a=0,f=s.length;a<f;++a){var g=s[a];if(E3(g,t.viewState)){var x=g.layer.getSource();if(x){var k=x.getAttributions();if(k){var B=k(t);if(B)if(o=o&&x.getAttributionsCollapsible()!==!1,Array.isArray(B))for(var P=0,R=B.length;P<R;++P)B[P]in r||(i.push(B[P]),r[B[P]]=!0);else B in r||(i.push(B),r[B]=!0)}}}}return this.overrideCollapsible_||this.setCollapsible(o),i},n.prototype.updateElement_=function(t){if(!t){this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1);return}var r=this.collectSourceAttributions_(t),i=r.length>0;if(this.renderedVisible_!=i&&(this.element.style.display=i?"":"none",this.renderedVisible_=i),!_1(r,this.renderedAttributions_)){YL(this.ulElement_);for(var o=0,s=r.length;o<s;++o){var a=document.createElement("li");a.innerHTML=r[o],this.ulElement_.appendChild(a)}this.renderedAttributions_=r}},n.prototype.handleClick_=function(t){t.preventDefault(),this.handleToggle_(),this.userCollapsed_=this.collapsed_},n.prototype.handleToggle_=function(){this.element.classList.toggle(w9),this.collapsed_?S9(this.collapseLabel_,this.label_):S9(this.label_,this.collapseLabel_),this.collapsed_=!this.collapsed_,this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_))},n.prototype.getCollapsible=function(){return this.collapsible_},n.prototype.setCollapsible=function(t){this.collapsible_!==t&&(this.collapsible_=t,this.element.classList.toggle("ol-uncollapsible"),this.userCollapsed_&&this.handleToggle_())},n.prototype.setCollapsed=function(t){this.userCollapsed_=t,!(!this.collapsible_||this.collapsed_===t)&&this.handleToggle_()},n.prototype.getCollapsed=function(){return this.collapsed_},n.prototype.render=function(t){this.updateElement_(t.frameState)},n}(h7);const Zre=Hre;var Xre=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Jre=function(e){Xre(n,e);function n(t){var r=this,i=t||{};r=e.call(this,{element:document.createElement("div"),render:i.render,target:i.target})||this;var o=i.className!==void 0?i.className:"ol-rotate",s=i.label!==void 0?i.label:"⇧",a=i.compassClassName!==void 0?i.compassClassName:"ol-compass";r.label_=null,typeof s=="string"?(r.label_=document.createElement("span"),r.label_.className=a,r.label_.textContent=s):(r.label_=s,r.label_.classList.add(a));var f=i.tipLabel?i.tipLabel:"Reset rotation",g=document.createElement("button");g.className=o+"-reset",g.setAttribute("type","button"),g.title=f,g.appendChild(r.label_),g.addEventListener(ki.CLICK,r.handleClick_.bind(r),!1);var x=o+" "+h5+" "+s7,k=r.element;return k.className=x,k.appendChild(g),r.callResetNorth_=i.resetNorth?i.resetNorth:void 0,r.duration_=i.duration!==void 0?i.duration:250,r.autoHide_=i.autoHide!==void 0?i.autoHide:!0,r.rotation_=void 0,r.autoHide_&&r.element.classList.add(wx),r}return n.prototype.handleClick_=function(t){t.preventDefault(),this.callResetNorth_!==void 0?this.callResetNorth_():this.resetNorth_()},n.prototype.resetNorth_=function(){var t=this.getMap(),r=t.getView();if(r){var i=r.getRotation();i!==void 0&&(this.duration_>0&&i%(2*Math.PI)!==0?r.animate({rotation:0,duration:this.duration_,easing:jy}):r.setRotation(0))}},n.prototype.render=function(t){var r=t.frameState;if(r){var i=r.viewState.rotation;if(i!=this.rotation_){var o="rotate("+i+"rad)";if(this.autoHide_){var s=this.element.classList.contains(wx);!s&&i===0?this.element.classList.add(wx):s&&i!==0&&this.element.classList.remove(wx)}this.label_.style.transform=o}this.rotation_=i}},n}(h7);const eie=Jre;var tie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),nie=function(e){tie(n,e);function n(t){var r=this,i=t||{};r=e.call(this,{element:document.createElement("div"),target:i.target})||this;var o=i.className!==void 0?i.className:"ol-zoom",s=i.delta!==void 0?i.delta:1,a=i.zoomInClassName!==void 0?i.zoomInClassName:o+"-in",f=i.zoomOutClassName!==void 0?i.zoomOutClassName:o+"-out",g=i.zoomInLabel!==void 0?i.zoomInLabel:"+",x=i.zoomOutLabel!==void 0?i.zoomOutLabel:"–",k=i.zoomInTipLabel!==void 0?i.zoomInTipLabel:"Zoom in",B=i.zoomOutTipLabel!==void 0?i.zoomOutTipLabel:"Zoom out",P=document.createElement("button");P.className=a,P.setAttribute("type","button"),P.title=k,P.appendChild(typeof g=="string"?document.createTextNode(g):g),P.addEventListener(ki.CLICK,r.handleClick_.bind(r,s),!1);var R=document.createElement("button");R.className=f,R.setAttribute("type","button"),R.title=B,R.appendChild(typeof x=="string"?document.createTextNode(x):x),R.addEventListener(ki.CLICK,r.handleClick_.bind(r,-s),!1);var H=o+" "+h5+" "+s7,W=r.element;return W.className=H,W.appendChild(P),W.appendChild(R),r.duration_=i.duration!==void 0?i.duration:250,r}return n.prototype.handleClick_=function(t,r){r.preventDefault(),this.zoomByDelta_(t)},n.prototype.zoomByDelta_=function(t){var r=this.getMap(),i=r.getView();if(i){var o=i.getZoom();if(o!==void 0){var s=i.getConstrainedZoom(o+t);this.duration_>0?(i.getAnimating()&&i.cancelAnimations(),i.animate({zoom:s,duration:this.duration_,easing:jy})):i.setZoom(s)}}},n}(h7);const rie=nie;var iie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Nu={ELEMENT:"element",MAP:"map",OFFSET:"offset",POSITION:"position",POSITIONING:"positioning"},oie=function(e){iie(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un,r.options=t,r.id=t.id,r.insertFirst=t.insertFirst!==void 0?t.insertFirst:!0,r.stopEvent=t.stopEvent!==void 0?t.stopEvent:!0,r.element=document.createElement("div"),r.element.className=t.className!==void 0?t.className:"ol-overlay-container "+ore,r.element.style.position="absolute",r.element.style.pointerEvents="auto";var i=t.autoPan;return i&&typeof i!="object"&&(i={animation:t.autoPanAnimation,margin:t.autoPanMargin}),r.autoPan=i||!1,r.rendered={transform_:"",visible:!0},r.mapPostrenderListenerKey=null,r.addChangeListener(Nu.ELEMENT,r.handleElementChanged),r.addChangeListener(Nu.MAP,r.handleMapChanged),r.addChangeListener(Nu.OFFSET,r.handleOffsetChanged),r.addChangeListener(Nu.POSITION,r.handlePositionChanged),r.addChangeListener(Nu.POSITIONING,r.handlePositioningChanged),t.element!==void 0&&r.setElement(t.element),r.setOffset(t.offset!==void 0?t.offset:[0,0]),r.setPositioning(t.positioning||"top-left"),t.position!==void 0&&r.setPosition(t.position),r}return n.prototype.getElement=function(){return this.get(Nu.ELEMENT)},n.prototype.getId=function(){return this.id},n.prototype.getMap=function(){return this.get(Nu.MAP)||null},n.prototype.getOffset=function(){return this.get(Nu.OFFSET)},n.prototype.getPosition=function(){return this.get(Nu.POSITION)},n.prototype.getPositioning=function(){return this.get(Nu.POSITIONING)},n.prototype.handleElementChanged=function(){YL(this.element);var t=this.getElement();t&&this.element.appendChild(t)},n.prototype.handleMapChanged=function(){this.mapPostrenderListenerKey&&(O3(this.element),Ga(this.mapPostrenderListenerKey),this.mapPostrenderListenerKey=null);var t=this.getMap();if(t){this.mapPostrenderListenerKey=wo(t,op.POSTRENDER,this.render,this),this.updatePixelPosition();var r=this.stopEvent?t.getOverlayContainerStopEvent():t.getOverlayContainer();this.insertFirst?r.insertBefore(this.element,r.childNodes[0]||null):r.appendChild(this.element),this.performAutoPan()}},n.prototype.render=function(){this.updatePixelPosition()},n.prototype.handleOffsetChanged=function(){this.updatePixelPosition()},n.prototype.handlePositionChanged=function(){this.updatePixelPosition(),this.performAutoPan()},n.prototype.handlePositioningChanged=function(){this.updatePixelPosition()},n.prototype.setElement=function(t){this.set(Nu.ELEMENT,t)},n.prototype.setMap=function(t){this.set(Nu.MAP,t)},n.prototype.setOffset=function(t){this.set(Nu.OFFSET,t)},n.prototype.setPosition=function(t){this.set(Nu.POSITION,t)},n.prototype.performAutoPan=function(){this.autoPan&&this.panIntoView(this.autoPan)},n.prototype.panIntoView=function(t){var r=this.getMap();if(!(!r||!r.getTargetElement()||!this.get(Nu.POSITION))){var i=this.getRect(r.getTargetElement(),r.getSize()),o=this.getElement(),s=this.getRect(o,[sre(o),lre(o)]),a=t||{},f=a.margin===void 0?20:a.margin;if(!cm(i,s)){var g=s[0]-i[0],x=i[2]-s[2],k=s[1]-i[1],B=i[3]-s[3],P=[0,0];if(g<0?P[0]=g-f:x<0&&(P[0]=Math.abs(x)+f),k<0?P[1]=k-f:B<0&&(P[1]=Math.abs(B)+f),P[0]!==0||P[1]!==0){var R=r.getView().getCenterInternal(),H=r.getPixelFromCoordinateInternal(R);if(!H)return;var W=[H[0]+P[0],H[1]+P[1]],$=a.animation||{};r.getView().animateInternal({center:r.getCoordinateFromPixelInternal(W),duration:$.duration,easing:$.easing})}}}},n.prototype.getRect=function(t,r){var i=t.getBoundingClientRect(),o=i.left+window.pageXOffset,s=i.top+window.pageYOffset;return[o,s,o+r[0],s+r[1]]},n.prototype.setPositioning=function(t){this.set(Nu.POSITIONING,t)},n.prototype.setVisible=function(t){this.rendered.visible!==t&&(this.element.style.display=t?"":"none",this.rendered.visible=t)},n.prototype.updatePixelPosition=function(){var t=this.getMap(),r=this.getPosition();if(!t||!t.isRendered()||!r){this.setVisible(!1);return}var i=t.getPixelFromCoordinate(r),o=t.getSize();this.updateRenderedPosition(i,o)},n.prototype.updateRenderedPosition=function(t,r){var i=this.element.style,o=this.getOffset(),s=this.getPositioning();this.setVisible(!0);var a=Math.round(t[0]+o[0])+"px",f=Math.round(t[1]+o[1])+"px",g="0%",x="0%";s=="bottom-right"||s=="center-right"||s=="top-right"?g="-100%":(s=="bottom-center"||s=="center-center"||s=="top-center")&&(g="-50%"),s=="bottom-left"||s=="bottom-center"||s=="bottom-right"?x="-100%":(s=="center-left"||s=="center-center"||s=="center-right")&&(x="-50%");var k="translate(".concat(g,", ").concat(x,") translate(").concat(a,", ").concat(f,")");this.rendered.transform_!=k&&(this.rendered.transform_=k,i.transform=k,i.msTransform=k)},n.prototype.getOptions=function(){return this.options},n}(mh);function aie(e){var n=e||{},t=new _d,r=n.zoom!==void 0?n.zoom:!0;r&&t.push(new rie(n.zoomOptions));var i=n.rotate!==void 0?n.rotate:!0;i&&t.push(new eie(n.rotateOptions));var o=n.attribution!==void 0?n.attribution:!0;return o&&t.push(new Zre(n.attributionOptions)),t}const K9={ACTIVE:"active"};var sie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),lie=function(e){sie(n,e);function n(t){var r=e.call(this)||this;return r.on,r.once,r.un,t&&t.handleEvent&&(r.handleEvent=t.handleEvent),r.map_=null,r.setActive(!0),r}return n.prototype.getActive=function(){return this.get(K9.ACTIVE)},n.prototype.getMap=function(){return this.map_},n.prototype.handleEvent=function(t){return!0},n.prototype.setActive=function(t){this.set(K9.ACTIVE,t)},n.prototype.setMap=function(t){this.map_=t},n}(mh);function uie(e,n,t){var r=e.getCenterInternal();if(r){var i=[r[0]+n[0],r[1]+n[1]];e.animateInternal({duration:t!==void 0?t:250,easing:Dre,center:e.getConstrainedCenter(i)})}}function f7(e,n,t,r){var i=e.getZoom();if(i!==void 0){var o=e.getConstrainedZoom(i+n),s=e.getResolutionForZoom(o);e.getAnimating()&&e.cancelAnimations(),e.animate({resolution:s,anchor:t,duration:r!==void 0?r:250,easing:jy})}}const V_=lie;var Aie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),cie=function(e){Aie(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.delta_=i.delta?i.delta:1,r.duration_=i.duration!==void 0?i.duration:250,r}return n.prototype.handleEvent=function(t){var r=!1;if(t.type==Ns.DBLCLICK){var i=t.originalEvent,o=t.map,s=t.coordinate,a=i.shiftKey?-this.delta_:this.delta_,f=o.getView();f7(f,a,s,this.duration_),i.preventDefault(),r=!0}return!r},n}(V_);const die=cie;var hie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),fie=function(e){hie(n,e);function n(t){var r=this,i=t||{};return r=e.call(this,i)||this,i.handleDownEvent&&(r.handleDownEvent=i.handleDownEvent),i.handleDragEvent&&(r.handleDragEvent=i.handleDragEvent),i.handleMoveEvent&&(r.handleMoveEvent=i.handleMoveEvent),i.handleUpEvent&&(r.handleUpEvent=i.handleUpEvent),i.stopDown&&(r.stopDown=i.stopDown),r.handlingDownUpSequence=!1,r.targetPointers=[],r}return n.prototype.getPointerCount=function(){return this.targetPointers.length},n.prototype.handleDownEvent=function(t){return!1},n.prototype.handleDragEvent=function(t){},n.prototype.handleEvent=function(t){if(!t.originalEvent)return!0;var r=!1;if(this.updateTrackedPointers_(t),this.handlingDownUpSequence){if(t.type==Ns.POINTERDRAG)this.handleDragEvent(t),t.originalEvent.preventDefault();else if(t.type==Ns.POINTERUP){var i=this.handleUpEvent(t);this.handlingDownUpSequence=i&&this.targetPointers.length>0}}else if(t.type==Ns.POINTERDOWN){var o=this.handleDownEvent(t);this.handlingDownUpSequence=o,r=this.stopDown(o)}else t.type==Ns.POINTERMOVE&&this.handleMoveEvent(t);return!r},n.prototype.handleMoveEvent=function(t){},n.prototype.handleUpEvent=function(t){return!1},n.prototype.stopDown=function(t){return t},n.prototype.updateTrackedPointers_=function(t){t.activePointers&&(this.targetPointers=t.activePointers)},n}(V_);function p7(e){for(var n=e.length,t=0,r=0,i=0;i<n;i++)t+=e[i].clientX,r+=e[i].clientY;return[t/n,r/n]}const H_=fie;function rE(e){var n=arguments;return function(t){for(var r=!0,i=0,o=n.length;i<o&&(r=r&&n[i](t),!!r);++i);return r}}var pie=function(e){var n=e.originalEvent;return n.altKey&&!(n.metaKey||n.ctrlKey)&&n.shiftKey},mie=function(e){var n=e.map.getTargetElement(),t=e.map.getOwnerDocument().activeElement;return n.contains(t)},nz=function(e){return e.map.getTargetElement().hasAttribute("tabindex")?mie(e):!0},gie=ty,rz=function(e){var n=e.originalEvent;return n.button==0&&!(Eee&&Oee&&n.ctrlKey)},iz=function(e){var n=e.originalEvent;return!n.altKey&&!(n.metaKey||n.ctrlKey)&&!n.shiftKey},yie=function(e){var n=e.originalEvent;return!n.altKey&&!(n.metaKey||n.ctrlKey)&&n.shiftKey},oz=function(e){var n=e.originalEvent,t=n.target.tagName;return t!=="INPUT"&&t!=="SELECT"&&t!=="TEXTAREA"&&!n.target.isContentEditable},dM=function(e){var n=e.originalEvent;return ao(n!==void 0,56),n.pointerType=="mouse"},vie=function(e){var n=e.originalEvent;return ao(n!==void 0,56),n.isPrimary&&n.button===0},Cie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),_ie=function(e){Cie(n,e);function n(t){var r=e.call(this,{stopDown:n5})||this,i=t||{};r.kinetic_=i.kinetic,r.lastCentroid=null,r.lastPointersCount_,r.panning_=!1;var o=i.condition?i.condition:rE(iz,vie);return r.condition_=i.onFocusOnly?rE(nz,o):o,r.noKinetic_=!1,r}return n.prototype.handleDragEvent=function(t){this.panning_||(this.panning_=!0,this.getMap().getView().beginInteraction());var r=this.targetPointers,i=p7(r);if(r.length==this.lastPointersCount_){if(this.kinetic_&&this.kinetic_.update(i[0],i[1]),this.lastCentroid){var o=[this.lastCentroid[0]-i[0],i[1]-this.lastCentroid[1]],s=t.map,a=s.getView();ite(o,a.getResolution()),QB(o,a.getRotation()),a.adjustCenterInternal(o)}}else this.kinetic_&&this.kinetic_.begin();this.lastCentroid=i,this.lastPointersCount_=r.length,t.originalEvent.preventDefault()},n.prototype.handleUpEvent=function(t){var r=t.map,i=r.getView();if(this.targetPointers.length===0){if(!this.noKinetic_&&this.kinetic_&&this.kinetic_.end()){var o=this.kinetic_.getDistance(),s=this.kinetic_.getAngle(),a=i.getCenterInternal(),f=r.getPixelFromCoordinateInternal(a),g=r.getCoordinateFromPixelInternal([f[0]-o*Math.cos(s),f[1]-o*Math.sin(s)]);i.animateInternal({center:i.getConstrainedCenter(g),duration:500,easing:jy})}return this.panning_&&(this.panning_=!1,i.endInteraction()),!1}else return this.kinetic_&&this.kinetic_.begin(),this.lastCentroid=null,!0},n.prototype.handleDownEvent=function(t){if(this.targetPointers.length>0&&this.condition_(t)){var r=t.map,i=r.getView();return this.lastCentroid=null,i.getAnimating()&&i.cancelAnimations(),this.kinetic_&&this.kinetic_.begin(),this.noKinetic_=this.targetPointers.length>1,!0}else return!1},n}(H_);const bie=_ie;var xie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),wie=function(e){xie(n,e);function n(t){var r=this,i=t||{};return r=e.call(this,{stopDown:n5})||this,r.condition_=i.condition?i.condition:pie,r.lastAngle_=void 0,r.duration_=i.duration!==void 0?i.duration:250,r}return n.prototype.handleDragEvent=function(t){if(dM(t)){var r=t.map,i=r.getView();if(i.getConstraints().rotation!==d7){var o=r.getSize(),s=t.pixel,a=Math.atan2(o[1]/2-s[1],s[0]-o[0]/2);if(this.lastAngle_!==void 0){var f=a-this.lastAngle_;i.adjustRotationInternal(-f)}this.lastAngle_=a}}},n.prototype.handleUpEvent=function(t){if(!dM(t))return!0;var r=t.map,i=r.getView();return i.endInteraction(this.duration_),!1},n.prototype.handleDownEvent=function(t){if(!dM(t))return!1;if(rz(t)&&this.condition_(t)){var r=t.map;return r.getView().beginInteraction(),this.lastAngle_=void 0,!0}else return!1},n}(H_),Mie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Sie=function(e){Mie(n,e);function n(t){var r=e.call(this)||this;return r.geometry_=null,r.element_=document.createElement("div"),r.element_.style.position="absolute",r.element_.style.pointerEvents="auto",r.element_.className="ol-box "+t,r.map_=null,r.startPixel_=null,r.endPixel_=null,r}return n.prototype.disposeInternal=function(){this.setMap(null)},n.prototype.render_=function(){var t=this.startPixel_,r=this.endPixel_,i="px",o=this.element_.style;o.left=Math.min(t[0],r[0])+i,o.top=Math.min(t[1],r[1])+i,o.width=Math.abs(r[0]-t[0])+i,o.height=Math.abs(r[1]-t[1])+i},n.prototype.setMap=function(t){if(this.map_){this.map_.getOverlayContainer().removeChild(this.element_);var r=this.element_.style;r.left="inherit",r.top="inherit",r.width="inherit",r.height="inherit"}this.map_=t,this.map_&&this.map_.getOverlayContainer().appendChild(this.element_)},n.prototype.setPixels=function(t,r){this.startPixel_=t,this.endPixel_=r,this.createOrUpdateGeometry(),this.render_()},n.prototype.createOrUpdateGeometry=function(){var t=this.startPixel_,r=this.endPixel_,i=[t,[t[0],r[1]],r,[r[0],t[1]]],o=i.map(this.map_.getCoordinateFromPixelInternal,this.map_);o[4]=o[0].slice(),this.geometry_?this.geometry_.setCoordinates([o]):this.geometry_=new c_([o])},n.prototype.getGeometry=function(){return this.geometry_},n}(UB);const Eie=Sie;var az=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Ex={BOXSTART:"boxstart",BOXDRAG:"boxdrag",BOXEND:"boxend",BOXCANCEL:"boxcancel"},hM=function(e){az(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.coordinate=r,o.mapBrowserEvent=i,o}return n}(Ep),Oie=function(e){az(n,e);function n(t){var r=e.call(this)||this;r.on,r.once,r.un;var i=t||{};return r.box_=new Eie(i.className||"ol-dragbox"),r.minArea_=i.minArea!==void 0?i.minArea:64,i.onBoxEnd&&(r.onBoxEnd=i.onBoxEnd),r.startPixel_=null,r.condition_=i.condition?i.condition:rz,r.boxEndCondition_=i.boxEndCondition?i.boxEndCondition:r.defaultBoxEndCondition,r}return n.prototype.defaultBoxEndCondition=function(t,r,i){var o=i[0]-r[0],s=i[1]-r[1];return o*o+s*s>=this.minArea_},n.prototype.getGeometry=function(){return this.box_.getGeometry()},n.prototype.handleDragEvent=function(t){this.box_.setPixels(this.startPixel_,t.pixel),this.dispatchEvent(new hM(Ex.BOXDRAG,t.coordinate,t))},n.prototype.handleUpEvent=function(t){this.box_.setMap(null);var r=this.boxEndCondition_(t,this.startPixel_,t.pixel);return r&&this.onBoxEnd(t),this.dispatchEvent(new hM(r?Ex.BOXEND:Ex.BOXCANCEL,t.coordinate,t)),!1},n.prototype.handleDownEvent=function(t){return this.condition_(t)?(this.startPixel_=t.pixel,this.box_.setMap(t.map),this.box_.setPixels(this.startPixel_,this.startPixel_),this.dispatchEvent(new hM(Ex.BOXSTART,t.coordinate,t)),!0):!1},n.prototype.onBoxEnd=function(t){},n}(H_);const Bie=Oie;var kie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Iie=function(e){kie(n,e);function n(t){var r=this,i=t||{},o=i.condition?i.condition:yie;return r=e.call(this,{condition:o,className:i.className||"ol-dragzoom",minArea:i.minArea})||this,r.duration_=i.duration!==void 0?i.duration:200,r.out_=i.out!==void 0?i.out:!1,r}return n.prototype.onBoxEnd=function(t){var r=this.getMap(),i=r.getView(),o=this.getGeometry();if(this.out_){var s=i.rotatedExtentForGeometry(o),a=i.getResolutionForExtentInternal(s),f=i.getResolution()/a;o=o.clone(),o.scale(f*f)}i.fitInternal(o,{duration:this.duration_,easing:jy})},n}(Bie);const Tie=Iie,y0={LEFT:37,UP:38,RIGHT:39,DOWN:40};var Kie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Pie=function(e){Kie(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.defaultCondition_=function(o){return iz(o)&&oz(o)},r.condition_=i.condition!==void 0?i.condition:r.defaultCondition_,r.duration_=i.duration!==void 0?i.duration:100,r.pixelDelta_=i.pixelDelta!==void 0?i.pixelDelta:128,r}return n.prototype.handleEvent=function(t){var r=!1;if(t.type==ki.KEYDOWN){var i=t.originalEvent,o=i.keyCode;if(this.condition_(t)&&(o==y0.DOWN||o==y0.LEFT||o==y0.RIGHT||o==y0.UP)){var s=t.map,a=s.getView(),f=a.getResolution()*this.pixelDelta_,g=0,x=0;o==y0.DOWN?x=-f:o==y0.LEFT?g=-f:o==y0.RIGHT?g=f:x=f;var k=[g,x];QB(k,a.getRotation()),uie(a,k,this.duration_),i.preventDefault(),r=!0}}return!r},n}(V_),Fie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Die=function(e){Fie(n,e);function n(t){var r=e.call(this)||this,i=t||{};return r.condition_=i.condition?i.condition:oz,r.delta_=i.delta?i.delta:1,r.duration_=i.duration!==void 0?i.duration:100,r}return n.prototype.handleEvent=function(t){var r=!1;if(t.type==ki.KEYDOWN||t.type==ki.KEYPRESS){var i=t.originalEvent,o=i.charCode;if(this.condition_(t)&&(o==43||o==45)){var s=t.map,a=o==43?this.delta_:-this.delta_,f=s.getView();f7(f,a,void 0,this.duration_),i.preventDefault(),r=!0}}return!r},n}(V_);const Uie=Die;var Rie=function(){function e(n,t,r){this.decay_=n,this.minVelocity_=t,this.delay_=r,this.points_=[],this.angle_=0,this.initialVelocity_=0}return e.prototype.begin=function(){this.points_.length=0,this.angle_=0,this.initialVelocity_=0},e.prototype.update=function(n,t){this.points_.push(n,t,Date.now())},e.prototype.end=function(){if(this.points_.length<6)return!1;var n=Date.now()-this.delay_,t=this.points_.length-3;if(this.points_[t+2]<n)return!1;for(var r=t-3;r>0&&this.points_[r+2]>n;)r-=3;var i=this.points_[t+2]-this.points_[r+2];if(i<1e3/60)return!1;var o=this.points_[t]-this.points_[r],s=this.points_[t+1]-this.points_[r+1];return this.angle_=Math.atan2(s,o),this.initialVelocity_=Math.sqrt(o*o+s*s)/i,this.initialVelocity_>this.minVelocity_},e.prototype.getDistance=function(){return(this.minVelocity_-this.initialVelocity_)/this.decay_},e.prototype.getAngle=function(){return this.angle_},e}(),Lie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),fM={TRACKPAD:"trackpad",WHEEL:"wheel"},zie=function(e){Lie(n,e);function n(t){var r=this,i=t||{};r=e.call(this,i)||this,r.totalDelta_=0,r.lastDelta_=0,r.maxDelta_=i.maxDelta!==void 0?i.maxDelta:1,r.duration_=i.duration!==void 0?i.duration:250,r.timeout_=i.timeout!==void 0?i.timeout:80,r.useAnchor_=i.useAnchor!==void 0?i.useAnchor:!0,r.constrainResolution_=i.constrainResolution!==void 0?i.constrainResolution:!1;var o=i.condition?i.condition:gie;return r.condition_=i.onFocusOnly?rE(nz,o):o,r.lastAnchor_=null,r.startTime_=void 0,r.timeoutId_,r.mode_=void 0,r.trackpadEventGap_=400,r.trackpadTimeoutId_,r.deltaPerZoom_=300,r}return n.prototype.endInteraction_=function(){this.trackpadTimeoutId_=void 0;var t=this.getMap();if(t){var r=t.getView();r.endInteraction(void 0,this.lastDelta_?this.lastDelta_>0?1:-1:0,this.lastAnchor_)}},n.prototype.handleEvent=function(t){if(!this.condition_(t))return!0;var r=t.type;if(r!==ki.WHEEL)return!0;var i=t.map,o=t.originalEvent;o.preventDefault(),this.useAnchor_&&(this.lastAnchor_=t.coordinate);var s;if(t.type==ki.WHEEL&&(s=o.deltaY,Mee&&o.deltaMode===WheelEvent.DOM_DELTA_PIXEL&&(s/=cL),o.deltaMode===WheelEvent.DOM_DELTA_LINE&&(s*=40)),s===0)return!1;this.lastDelta_=s;var a=Date.now();this.startTime_===void 0&&(this.startTime_=a),(!this.mode_||a-this.startTime_>this.trackpadEventGap_)&&(this.mode_=Math.abs(s)<4?fM.TRACKPAD:fM.WHEEL);var f=i.getView();if(this.mode_===fM.TRACKPAD&&!(f.getConstrainResolution()||this.constrainResolution_))return this.trackpadTimeoutId_?clearTimeout(this.trackpadTimeoutId_):(f.getAnimating()&&f.cancelAnimations(),f.beginInteraction()),this.trackpadTimeoutId_=setTimeout(this.endInteraction_.bind(this),this.timeout_),f.adjustZoom(-s/this.deltaPerZoom_,this.lastAnchor_),this.startTime_=a,!1;this.totalDelta_+=s;var g=Math.max(this.timeout_-(a-this.startTime_),0);return clearTimeout(this.timeoutId_),this.timeoutId_=setTimeout(this.handleWheelZoom_.bind(this,i),g),!1},n.prototype.handleWheelZoom_=function(t){var r=t.getView();r.getAnimating()&&r.cancelAnimations();var i=-vl(this.totalDelta_,-this.maxDelta_*this.deltaPerZoom_,this.maxDelta_*this.deltaPerZoom_)/this.deltaPerZoom_;(r.getConstrainResolution()||this.constrainResolution_)&&(i=i?i>0?1:-1:0),f7(r,i,this.lastAnchor_,this.duration_),this.mode_=void 0,this.totalDelta_=0,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_=void 0},n.prototype.setMouseAnchor=function(t){this.useAnchor_=t,t||(this.lastAnchor_=null)},n}(V_);const jie=zie;var Wie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Nie=function(e){Wie(n,e);function n(t){var r=this,i=t||{},o=i;return o.stopDown||(o.stopDown=n5),r=e.call(this,o)||this,r.anchor_=null,r.lastAngle_=void 0,r.rotating_=!1,r.rotationDelta_=0,r.threshold_=i.threshold!==void 0?i.threshold:.3,r.duration_=i.duration!==void 0?i.duration:250,r}return n.prototype.handleDragEvent=function(t){var r=0,i=this.targetPointers[0],o=this.targetPointers[1],s=Math.atan2(o.clientY-i.clientY,o.clientX-i.clientX);if(this.lastAngle_!==void 0){var a=s-this.lastAngle_;this.rotationDelta_+=a,!this.rotating_&&Math.abs(this.rotationDelta_)>this.threshold_&&(this.rotating_=!0),r=a}this.lastAngle_=s;var f=t.map,g=f.getView();if(g.getConstraints().rotation!==d7){var x=f.getViewport().getBoundingClientRect(),k=p7(this.targetPointers);k[0]-=x.left,k[1]-=x.top,this.anchor_=f.getCoordinateFromPixelInternal(k),this.rotating_&&(f.render(),g.adjustRotationInternal(r,this.anchor_))}},n.prototype.handleUpEvent=function(t){if(this.targetPointers.length<2){var r=t.map,i=r.getView();return i.endInteraction(this.duration_),!1}else return!0},n.prototype.handleDownEvent=function(t){if(this.targetPointers.length>=2){var r=t.map;return this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.handlingDownUpSequence||r.getView().beginInteraction(),!0}else return!1},n}(H_),Gie=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Qie=function(e){Gie(n,e);function n(t){var r=this,i=t||{},o=i;return o.stopDown||(o.stopDown=n5),r=e.call(this,o)||this,r.anchor_=null,r.duration_=i.duration!==void 0?i.duration:400,r.lastDistance_=void 0,r.lastScaleDelta_=1,r}return n.prototype.handleDragEvent=function(t){var r=1,i=this.targetPointers[0],o=this.targetPointers[1],s=i.clientX-o.clientX,a=i.clientY-o.clientY,f=Math.sqrt(s*s+a*a);this.lastDistance_!==void 0&&(r=this.lastDistance_/f),this.lastDistance_=f;var g=t.map,x=g.getView();r!=1&&(this.lastScaleDelta_=r);var k=g.getViewport().getBoundingClientRect(),B=p7(this.targetPointers);B[0]-=k.left,B[1]-=k.top,this.anchor_=g.getCoordinateFromPixelInternal(B),g.render(),x.adjustResolutionInternal(r,this.anchor_)},n.prototype.handleUpEvent=function(t){if(this.targetPointers.length<2){var r=t.map,i=r.getView(),o=this.lastScaleDelta_>1?1:-1;return i.endInteraction(this.duration_,o),!1}else return!0},n.prototype.handleDownEvent=function(t){if(this.targetPointers.length>=2){var r=t.map;return this.anchor_=null,this.lastDistance_=void 0,this.lastScaleDelta_=1,this.handlingDownUpSequence||r.getView().beginInteraction(),!0}else return!1},n}(H_);const $ie=Qie;function Yie(e,n,t,r,i){sz(e,n,t||0,r||e.length-1,i||qie)}function sz(e,n,t,r,i){for(;r>t;){if(r-t>600){var o=r-t+1,s=n-t+1,a=Math.log(o),f=.5*Math.exp(2*a/3),g=.5*Math.sqrt(a*f*(o-f)/o)*(s-o/2<0?-1:1),x=Math.max(t,Math.floor(n-s*f/o+g)),k=Math.min(r,Math.floor(n+(o-s)*f/o+g));sz(e,n,x,k,i)}var B=e[n],P=t,R=r;for(Wv(e,t,n),i(e[r],B)>0&&Wv(e,t,r);P<R;){for(Wv(e,P,R),P++,R--;i(e[P],B)<0;)P++;for(;i(e[R],B)>0;)R--}i(e[t],B)===0?Wv(e,t,R):(R++,Wv(e,R,r)),R<=n&&(t=R+1),n<=R&&(r=R-1)}}function Wv(e,n,t){var r=e[n];e[n]=e[t],e[t]=r}function qie(e,n){return e<n?-1:e>n?1:0}let lz=class{constructor(n=9){this._maxEntries=Math.max(4,n),this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4)),this.clear()}all(){return this._all(this.data,[])}search(n){let t=this.data;const r=[];if(!Bx(n,t))return r;const i=this.toBBox,o=[];for(;t;){for(let s=0;s<t.children.length;s++){const a=t.children[s],f=t.leaf?i(a):a;Bx(n,f)&&(t.leaf?r.push(a):mM(n,f)?this._all(a,r):o.push(a))}t=o.pop()}return r}collides(n){let t=this.data;if(!Bx(n,t))return!1;const r=[];for(;t;){for(let i=0;i<t.children.length;i++){const o=t.children[i],s=t.leaf?this.toBBox(o):o;if(Bx(n,s)){if(t.leaf||mM(n,s))return!0;r.push(o)}}t=r.pop()}return!1}load(n){if(!(n&&n.length))return this;if(n.length<this._minEntries){for(let r=0;r<n.length;r++)this.insert(n[r]);return this}let t=this._build(n.slice(),0,n.length-1,0);if(!this.data.children.length)this.data=t;else if(this.data.height===t.height)this._splitRoot(this.data,t);else{if(this.data.height<t.height){const r=this.data;this.data=t,t=r}this._insert(t,this.data.height-t.height-1,!0)}return this}insert(n){return n&&this._insert(n,this.data.height-1),this}clear(){return this.data=xg([]),this}remove(n,t){if(!n)return this;let r=this.data;const i=this.toBBox(n),o=[],s=[];let a,f,g;for(;r||o.length;){if(r||(r=o.pop(),f=o[o.length-1],a=s.pop(),g=!0),r.leaf){const x=Vie(n,r.children,t);if(x!==-1)return r.children.splice(x,1),o.push(r),this._condense(o),this}!g&&!r.leaf&&mM(r,i)?(o.push(r),s.push(a),a=0,f=r,r=r.children[0]):f?(a++,r=f.children[a],g=!1):r=null}return this}toBBox(n){return n}compareMinX(n,t){return n.minX-t.minX}compareMinY(n,t){return n.minY-t.minY}toJSON(){return this.data}fromJSON(n){return this.data=n,this}_all(n,t){const r=[];for(;n;)n.leaf?t.push(...n.children):r.push(...n.children),n=r.pop();return t}_build(n,t,r,i){const o=r-t+1;let s=this._maxEntries,a;if(o<=s)return a=xg(n.slice(t,r+1)),sg(a,this.toBBox),a;i||(i=Math.ceil(Math.log(o)/Math.log(s)),s=Math.ceil(o/Math.pow(s,i-1))),a=xg([]),a.leaf=!1,a.height=i;const f=Math.ceil(o/s),g=f*Math.ceil(Math.sqrt(s));P9(n,t,r,g,this.compareMinX);for(let x=t;x<=r;x+=g){const k=Math.min(x+g-1,r);P9(n,x,k,f,this.compareMinY);for(let B=x;B<=k;B+=f){const P=Math.min(B+f-1,k);a.children.push(this._build(n,B,P,i-1))}}return sg(a,this.toBBox),a}_chooseSubtree(n,t,r,i){for(;i.push(t),!(t.leaf||i.length-1===r);){let o=1/0,s=1/0,a;for(let f=0;f<t.children.length;f++){const g=t.children[f],x=pM(g),k=Xie(n,g)-x;k<s?(s=k,o=x<o?x:o,a=g):k===s&&x<o&&(o=x,a=g)}t=a||t.children[0]}return t}_insert(n,t,r){const i=r?n:this.toBBox(n),o=[],s=this._chooseSubtree(i,this.data,t,o);for(s.children.push(n),sC(s,i);t>=0&&o[t].children.length>this._maxEntries;)this._split(o,t),t--;this._adjustParentBBoxes(i,o,t)}_split(n,t){const r=n[t],i=r.children.length,o=this._minEntries;this._chooseSplitAxis(r,o,i);const s=this._chooseSplitIndex(r,o,i),a=xg(r.children.splice(s,r.children.length-s));a.height=r.height,a.leaf=r.leaf,sg(r,this.toBBox),sg(a,this.toBBox),t?n[t-1].children.push(a):this._splitRoot(r,a)}_splitRoot(n,t){this.data=xg([n,t]),this.data.height=n.height+1,this.data.leaf=!1,sg(this.data,this.toBBox)}_chooseSplitIndex(n,t,r){let i,o=1/0,s=1/0;for(let a=t;a<=r-t;a++){const f=aC(n,0,a,this.toBBox),g=aC(n,a,r,this.toBBox),x=Jie(f,g),k=pM(f)+pM(g);x<o?(o=x,i=a,s=k<s?k:s):x===o&&k<s&&(s=k,i=a)}return i||r-t}_chooseSplitAxis(n,t,r){const i=n.leaf?this.compareMinX:Hie,o=n.leaf?this.compareMinY:Zie,s=this._allDistMargin(n,t,r,i),a=this._allDistMargin(n,t,r,o);s<a&&n.children.sort(i)}_allDistMargin(n,t,r,i){n.children.sort(i);const o=this.toBBox,s=aC(n,0,t,o),a=aC(n,r-t,r,o);let f=Ox(s)+Ox(a);for(let g=t;g<r-t;g++){const x=n.children[g];sC(s,n.leaf?o(x):x),f+=Ox(s)}for(let g=r-t-1;g>=t;g--){const x=n.children[g];sC(a,n.leaf?o(x):x),f+=Ox(a)}return f}_adjustParentBBoxes(n,t,r){for(let i=r;i>=0;i--)sC(t[i],n)}_condense(n){for(let t=n.length-1,r;t>=0;t--)n[t].children.length===0?t>0?(r=n[t-1].children,r.splice(r.indexOf(n[t]),1)):this.clear():sg(n[t],this.toBBox)}};function Vie(e,n,t){if(!t)return n.indexOf(e);for(let r=0;r<n.length;r++)if(t(e,n[r]))return r;return-1}function sg(e,n){aC(e,0,e.children.length,n,e)}function aC(e,n,t,r,i){i||(i=xg(null)),i.minX=1/0,i.minY=1/0,i.maxX=-1/0,i.maxY=-1/0;for(let o=n;o<t;o++){const s=e.children[o];sC(i,e.leaf?r(s):s)}return i}function sC(e,n){return e.minX=Math.min(e.minX,n.minX),e.minY=Math.min(e.minY,n.minY),e.maxX=Math.max(e.maxX,n.maxX),e.maxY=Math.max(e.maxY,n.maxY),e}function Hie(e,n){return e.minX-n.minX}function Zie(e,n){return e.minY-n.minY}function pM(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function Ox(e){return e.maxX-e.minX+(e.maxY-e.minY)}function Xie(e,n){return(Math.max(n.maxX,e.maxX)-Math.min(n.minX,e.minX))*(Math.max(n.maxY,e.maxY)-Math.min(n.minY,e.minY))}function Jie(e,n){const t=Math.max(e.minX,n.minX),r=Math.max(e.minY,n.minY),i=Math.min(e.maxX,n.maxX),o=Math.min(e.maxY,n.maxY);return Math.max(0,i-t)*Math.max(0,o-r)}function mM(e,n){return e.minX<=n.minX&&e.minY<=n.minY&&n.maxX<=e.maxX&&n.maxY<=e.maxY}function Bx(e,n){return n.minX<=e.maxX&&n.minY<=e.maxY&&n.maxX>=e.minX&&n.maxY>=e.minY}function xg(e){return{children:e,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function P9(e,n,t,r,i){const o=[n,t];for(;o.length;){if(t=o.pop(),n=o.pop(),t-n<=r)continue;const s=n+Math.ceil((t-n)/r/2)*r;Yie(e,s,n,t,i),o.push(n,s,s,t)}}const Na={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4};var eoe=function(){function e(n){this.opacity_=n.opacity,this.rotateWithView_=n.rotateWithView,this.rotation_=n.rotation,this.scale_=n.scale,this.scaleArray_=pA(n.scale),this.displacement_=n.displacement,this.declutterMode_=n.declutterMode}return e.prototype.clone=function(){var n=this.getScale();return new e({opacity:this.getOpacity(),scale:Array.isArray(n)?n.slice():n,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})},e.prototype.getOpacity=function(){return this.opacity_},e.prototype.getRotateWithView=function(){return this.rotateWithView_},e.prototype.getRotation=function(){return this.rotation_},e.prototype.getScale=function(){return this.scale_},e.prototype.getScaleArray=function(){return this.scaleArray_},e.prototype.getDisplacement=function(){return this.displacement_},e.prototype.getDeclutterMode=function(){return this.declutterMode_},e.prototype.getAnchor=function(){return li()},e.prototype.getImage=function(n){return li()},e.prototype.getHitDetectionImage=function(){return li()},e.prototype.getPixelRatio=function(n){return 1},e.prototype.getImageState=function(){return li()},e.prototype.getImageSize=function(){return li()},e.prototype.getOrigin=function(){return li()},e.prototype.getSize=function(){return li()},e.prototype.setDisplacement=function(n){this.displacement_=n},e.prototype.setOpacity=function(n){this.opacity_=n},e.prototype.setRotateWithView=function(n){this.rotateWithView_=n},e.prototype.setRotation=function(n){this.rotation_=n},e.prototype.setScale=function(n){this.scale_=n,this.scaleArray_=pA(n)},e.prototype.listenImageChange=function(n){li()},e.prototype.load=function(){li()},e.prototype.unlistenImageChange=function(n){li()},e}();const uz=eoe;function tf(e){return Array.isArray(e)?NL(e):e}var toe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),noe=function(e){toe(n,e);function n(t){var r=this,i=t.rotateWithView!==void 0?t.rotateWithView:!1;return r=e.call(this,{opacity:1,rotateWithView:i,rotation:t.rotation!==void 0?t.rotation:0,scale:t.scale!==void 0?t.scale:1,displacement:t.displacement!==void 0?t.displacement:[0,0],declutterMode:t.declutterMode})||this,r.canvas_=void 0,r.hitDetectionCanvas_=null,r.fill_=t.fill!==void 0?t.fill:null,r.origin_=[0,0],r.points_=t.points,r.radius_=t.radius!==void 0?t.radius:t.radius1,r.radius2_=t.radius2,r.angle_=t.angle!==void 0?t.angle:0,r.stroke_=t.stroke!==void 0?t.stroke:null,r.size_=null,r.renderOptions_=null,r.render(),r}return n.prototype.clone=function(){var t=this.getScale(),r=new n({fill:this.getFill()?this.getFill().clone():void 0,points:this.getPoints(),radius:this.getRadius(),radius2:this.getRadius2(),angle:this.getAngle(),stroke:this.getStroke()?this.getStroke().clone():void 0,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return r.setOpacity(this.getOpacity()),r},n.prototype.getAnchor=function(){var t=this.size_;if(!t)return null;var r=this.getDisplacement();return[t[0]/2-r[0],t[1]/2+r[1]]},n.prototype.getAngle=function(){return this.angle_},n.prototype.getFill=function(){return this.fill_},n.prototype.setFill=function(t){this.fill_=t,this.render()},n.prototype.getHitDetectionImage=function(){return this.hitDetectionCanvas_||this.createHitDetectionCanvas_(this.renderOptions_),this.hitDetectionCanvas_},n.prototype.getImage=function(t){var r=this.canvas_[t];if(!r){var i=this.renderOptions_,o=YA(i.size*t,i.size*t);this.draw_(i,o,t),r=o.canvas,this.canvas_[t]=r}return r},n.prototype.getPixelRatio=function(t){return t},n.prototype.getImageSize=function(){return this.size_},n.prototype.getImageState=function(){return Na.LOADED},n.prototype.getOrigin=function(){return this.origin_},n.prototype.getPoints=function(){return this.points_},n.prototype.getRadius=function(){return this.radius_},n.prototype.getRadius2=function(){return this.radius2_},n.prototype.getSize=function(){return this.size_},n.prototype.getStroke=function(){return this.stroke_},n.prototype.setStroke=function(t){this.stroke_=t,this.render()},n.prototype.listenImageChange=function(t){},n.prototype.load=function(){},n.prototype.unlistenImageChange=function(t){},n.prototype.calculateLineJoinSize_=function(t,r,i){if(r===0||this.points_===1/0||t!=="bevel"&&t!=="miter")return r;var o=this.radius_,s=this.radius2_===void 0?o:this.radius2_;if(o<s){var a=o;o=s,s=a}var f=this.radius2_===void 0?this.points_:this.points_*2,g=2*Math.PI/f,x=s*Math.sin(g),k=Math.sqrt(s*s-x*x),B=o-k,P=Math.sqrt(x*x+B*B),R=P/x;if(t==="miter"&&R<=i)return R*r;var H=r/2/R,W=r/2*(B/P),$=Math.sqrt((o+H)*(o+H)+W*W),q=$-o;if(this.radius2_===void 0||t==="bevel")return q*2;var oe=o*Math.sin(g),ne=Math.sqrt(o*o-oe*oe),ce=s-ne,ae=Math.sqrt(oe*oe+ce*ce),ue=ae/oe;if(ue<=i){var ye=ue*r/2-s-o;return 2*Math.max(q,ye)}return q*2},n.prototype.createRenderOptions=function(){var t=My,r=0,i=null,o=0,s,a=0;this.stroke_&&(s=this.stroke_.getColor(),s===null&&(s=m_),s=tf(s),a=this.stroke_.getWidth(),a===void 0&&(a=y_),i=this.stroke_.getLineDash(),o=this.stroke_.getLineDashOffset(),t=this.stroke_.getLineJoin(),t===void 0&&(t=My),r=this.stroke_.getMiterLimit(),r===void 0&&(r=p_));var f=this.calculateLineJoinSize_(t,a,r),g=Math.max(this.radius_,this.radius2_||0),x=Math.ceil(2*g+f);return{strokeStyle:s,strokeWidth:a,size:x,lineDash:i,lineDashOffset:o,lineJoin:t,miterLimit:r}},n.prototype.render=function(){this.renderOptions_=this.createRenderOptions();var t=this.renderOptions_.size;this.canvas_={},this.size_=[t,t]},n.prototype.draw_=function(t,r,i){if(r.scale(i,i),r.translate(t.size/2,t.size/2),this.createPath_(r),this.fill_){var o=this.fill_.getColor();o===null&&(o=bp),r.fillStyle=tf(o),r.fill()}this.stroke_&&(r.strokeStyle=t.strokeStyle,r.lineWidth=t.strokeWidth,r.setLineDash&&t.lineDash&&(r.setLineDash(t.lineDash),r.lineDashOffset=t.lineDashOffset),r.lineJoin=t.lineJoin,r.miterLimit=t.miterLimit,r.stroke())},n.prototype.createHitDetectionCanvas_=function(t){if(this.fill_){var r=this.fill_.getColor(),i=0;if(typeof r=="string"&&(r=M3(r)),r===null?i=1:Array.isArray(r)&&(i=r.length===4?r[3]:1),i===0){var o=YA(t.size,t.size);this.hitDetectionCanvas_=o.canvas,this.drawHitDetectionCanvas_(t,o)}}this.hitDetectionCanvas_||(this.hitDetectionCanvas_=this.getImage(1))},n.prototype.createPath_=function(t){var r=this.points_,i=this.radius_;if(r===1/0)t.arc(0,0,i,0,2*Math.PI);else{var o=this.radius2_===void 0?i:this.radius2_;this.radius2_!==void 0&&(r*=2);for(var s=this.angle_-Math.PI/2,a=2*Math.PI/r,f=0;f<r;f++){var g=s+f*a,x=f%2===0?i:o;t.lineTo(x*Math.cos(g),x*Math.sin(g))}t.closePath()}},n.prototype.drawHitDetectionCanvas_=function(t,r){r.translate(t.size/2,t.size/2),this.createPath_(r),r.fillStyle=bp,r.fill(),this.stroke_&&(r.strokeStyle=t.strokeStyle,r.lineWidth=t.strokeWidth,t.lineDash&&(r.setLineDash(t.lineDash),r.lineDashOffset=t.lineDashOffset),r.lineJoin=t.lineJoin,r.miterLimit=t.miterLimit,r.stroke())},n}(uz);const roe=noe;var ioe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Az=function(e){ioe(n,e);function n(t){var r=t||{};return e.call(this,{points:1/0,fill:r.fill,radius:r.radius,stroke:r.stroke,scale:r.scale!==void 0?r.scale:1,rotation:r.rotation!==void 0?r.rotation:0,rotateWithView:r.rotateWithView!==void 0?r.rotateWithView:!1,displacement:r.displacement!==void 0?r.displacement:[0,0],declutterMode:r.declutterMode})||this}return n.prototype.clone=function(){var t=this.getScale(),r=new n({fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,radius:this.getRadius(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return r.setOpacity(this.getOpacity()),r},n.prototype.setRadius=function(t){this.radius_=t,this.render()},n}(roe),Ug=function(){function e(n){var t=n||{};this.color_=t.color!==void 0?t.color:null}return e.prototype.clone=function(){var n=this.getColor();return new e({color:Array.isArray(n)?n.slice():n||void 0})},e.prototype.getColor=function(){return this.color_},e.prototype.setColor=function(n){this.color_=n},e}(),lC=function(){function e(n){var t=n||{};this.color_=t.color!==void 0?t.color:null,this.lineCap_=t.lineCap,this.lineDash_=t.lineDash!==void 0?t.lineDash:null,this.lineDashOffset_=t.lineDashOffset,this.lineJoin_=t.lineJoin,this.miterLimit_=t.miterLimit,this.width_=t.width}return e.prototype.clone=function(){var n=this.getColor();return new e({color:Array.isArray(n)?n.slice():n||void 0,lineCap:this.getLineCap(),lineDash:this.getLineDash()?this.getLineDash().slice():void 0,lineDashOffset:this.getLineDashOffset(),lineJoin:this.getLineJoin(),miterLimit:this.getMiterLimit(),width:this.getWidth()})},e.prototype.getColor=function(){return this.color_},e.prototype.getLineCap=function(){return this.lineCap_},e.prototype.getLineDash=function(){return this.lineDash_},e.prototype.getLineDashOffset=function(){return this.lineDashOffset_},e.prototype.getLineJoin=function(){return this.lineJoin_},e.prototype.getMiterLimit=function(){return this.miterLimit_},e.prototype.getWidth=function(){return this.width_},e.prototype.setColor=function(n){this.color_=n},e.prototype.setLineCap=function(n){this.lineCap_=n},e.prototype.setLineDash=function(n){this.lineDash_=n},e.prototype.setLineDashOffset=function(n){this.lineDashOffset_=n},e.prototype.setLineJoin=function(n){this.lineJoin_=n},e.prototype.setMiterLimit=function(n){this.miterLimit_=n},e.prototype.setWidth=function(n){this.width_=n},e}(),E0=function(){function e(n){var t=n||{};this.geometry_=null,this.geometryFunction_=F9,t.geometry!==void 0&&this.setGeometry(t.geometry),this.fill_=t.fill!==void 0?t.fill:null,this.image_=t.image!==void 0?t.image:null,this.renderer_=t.renderer!==void 0?t.renderer:null,this.hitDetectionRenderer_=t.hitDetectionRenderer!==void 0?t.hitDetectionRenderer:null,this.stroke_=t.stroke!==void 0?t.stroke:null,this.text_=t.text!==void 0?t.text:null,this.zIndex_=t.zIndex}return e.prototype.clone=function(){var n=this.getGeometry();return n&&typeof n=="object"&&(n=n.clone()),new e({geometry:n,fill:this.getFill()?this.getFill().clone():void 0,image:this.getImage()?this.getImage().clone():void 0,renderer:this.getRenderer(),stroke:this.getStroke()?this.getStroke().clone():void 0,text:this.getText()?this.getText().clone():void 0,zIndex:this.getZIndex()})},e.prototype.getRenderer=function(){return this.renderer_},e.prototype.setRenderer=function(n){this.renderer_=n},e.prototype.setHitDetectionRenderer=function(n){this.hitDetectionRenderer_=n},e.prototype.getHitDetectionRenderer=function(){return this.hitDetectionRenderer_},e.prototype.getGeometry=function(){return this.geometry_},e.prototype.getGeometryFunction=function(){return this.geometryFunction_},e.prototype.getFill=function(){return this.fill_},e.prototype.setFill=function(n){this.fill_=n},e.prototype.getImage=function(){return this.image_},e.prototype.setImage=function(n){this.image_=n},e.prototype.getStroke=function(){return this.stroke_},e.prototype.setStroke=function(n){this.stroke_=n},e.prototype.getText=function(){return this.text_},e.prototype.setText=function(n){this.text_=n},e.prototype.getZIndex=function(){return this.zIndex_},e.prototype.setGeometry=function(n){typeof n=="function"?this.geometryFunction_=n:typeof n=="string"?this.geometryFunction_=function(t){return t.get(n)}:n?n!==void 0&&(this.geometryFunction_=function(){return n}):this.geometryFunction_=F9,this.geometry_=n},e.prototype.setZIndex=function(n){this.zIndex_=n},e}();function ooe(e){var n;if(typeof e=="function")n=e;else{var t;if(Array.isArray(e))t=e;else{ao(typeof e.getZIndex=="function",41);var r=e;t=[r]}n=function(){return t}}return n}var gM=null;function aoe(e,n){if(!gM){var t=new Ug({color:"rgba(255,255,255,0.4)"}),r=new lC({color:"#3399CC",width:1.25});gM=[new E0({image:new Az({fill:t,stroke:r,radius:5}),fill:t,stroke:r})]}return gM}function F9(e){return e.getGeometry()}var soe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),D9={RENDER_ORDER:"renderOrder"},loe=function(e){soe(n,e);function n(t){var r=this,i=t||{},o=al({},i);return delete o.style,delete o.renderBuffer,delete o.updateWhileAnimating,delete o.updateWhileInteracting,r=e.call(this,o)||this,r.declutter_=i.declutter!==void 0?i.declutter:!1,r.renderBuffer_=i.renderBuffer!==void 0?i.renderBuffer:100,r.style_=null,r.styleFunction_=void 0,r.setStyle(i.style),r.updateWhileAnimating_=i.updateWhileAnimating!==void 0?i.updateWhileAnimating:!1,r.updateWhileInteracting_=i.updateWhileInteracting!==void 0?i.updateWhileInteracting:!1,r}return n.prototype.getDeclutter=function(){return this.declutter_},n.prototype.getFeatures=function(t){return e.prototype.getFeatures.call(this,t)},n.prototype.getRenderBuffer=function(){return this.renderBuffer_},n.prototype.getRenderOrder=function(){return this.get(D9.RENDER_ORDER)},n.prototype.getStyle=function(){return this.style_},n.prototype.getStyleFunction=function(){return this.styleFunction_},n.prototype.getUpdateWhileAnimating=function(){return this.updateWhileAnimating_},n.prototype.getUpdateWhileInteracting=function(){return this.updateWhileInteracting_},n.prototype.renderDeclutter=function(t){t.declutterTree||(t.declutterTree=new lz(9)),this.getRenderer().renderDeclutter(t)},n.prototype.setRenderOrder=function(t){this.set(D9.RENDER_ORDER,t)},n.prototype.setStyle=function(t){this.style_=t!==void 0?t:aoe,this.styleFunction_=t===null?void 0:ooe(this.style_),this.changed()},n}(d5);const cz=loe;var ai={BEGIN_GEOMETRY:0,BEGIN_PATH:1,CIRCLE:2,CLOSE_PATH:3,CUSTOM:4,DRAW_CHARS:5,DRAW_IMAGE:6,END_GEOMETRY:7,FILL:8,MOVE_TO_LINE_TO:9,SET_FILL_STYLE:10,SET_STROKE_STYLE:11,STROKE:12},kx=[ai.FILL],hm=[ai.STROKE],G0=[ai.BEGIN_PATH],U9=[ai.CLOSE_PATH],uoe=function(){function e(){}return e.prototype.drawCustom=function(n,t,r,i){},e.prototype.drawGeometry=function(n){},e.prototype.setStyle=function(n){},e.prototype.drawCircle=function(n,t){},e.prototype.drawFeature=function(n,t){},e.prototype.drawGeometryCollection=function(n,t){},e.prototype.drawLineString=function(n,t){},e.prototype.drawMultiLineString=function(n,t){},e.prototype.drawMultiPoint=function(n,t){},e.prototype.drawMultiPolygon=function(n,t){},e.prototype.drawPoint=function(n,t){},e.prototype.drawPolygon=function(n,t){},e.prototype.drawText=function(n,t){},e.prototype.setFillStrokeStyle=function(n,t){},e.prototype.setImageStyle=function(n,t){},e.prototype.setTextStyle=function(n,t){},e}();const dz=uoe;var Aoe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),coe=function(e){Aoe(n,e);function n(t,r,i,o){var s=e.call(this)||this;return s.tolerance=t,s.maxExtent=r,s.pixelRatio=o,s.maxLineWidth=0,s.resolution=i,s.beginGeometryInstruction1_=null,s.beginGeometryInstruction2_=null,s.bufferedMaxExtent_=null,s.instructions=[],s.coordinates=[],s.tmpCoordinate_=[],s.hitDetectionInstructions=[],s.state={},s}return n.prototype.applyPixelRatio=function(t){var r=this.pixelRatio;return r==1?t:t.map(function(i){return i*r})},n.prototype.appendFlatPointCoordinates=function(t,r){for(var i=this.getBufferedMaxExtent(),o=this.tmpCoordinate_,s=this.coordinates,a=s.length,f=0,g=t.length;f<g;f+=r)o[0]=t[f],o[1]=t[f+1],$_(i,o)&&(s[a++]=o[0],s[a++]=o[1]);return a},n.prototype.appendFlatLineCoordinates=function(t,r,i,o,s,a){var f=this.coordinates,g=f.length,x=this.getBufferedMaxExtent();a&&(r+=o);var k=t[r],B=t[r+1],P=this.tmpCoordinate_,R=!0,H,W,$;for(H=r+o;H<i;H+=o)P[0]=t[H],P[1]=t[H+1],$=R6(x,P),$!==W?(R&&(f[g++]=k,f[g++]=B,R=!1),f[g++]=P[0],f[g++]=P[1]):$===iu.INTERSECTING?(f[g++]=P[0],f[g++]=P[1],R=!1):R=!0,k=P[0],B=P[1],W=$;return(s&&R||H===r+o)&&(f[g++]=k,f[g++]=B),g},n.prototype.drawCustomCoordinates_=function(t,r,i,o,s){for(var a=0,f=i.length;a<f;++a){var g=i[a],x=this.appendFlatLineCoordinates(t,r,g,o,!1,!1);s.push(x),r=g}return r},n.prototype.drawCustom=function(t,r,i,o){this.beginGeometry(t,r);var s=t.getType(),a=t.getStride(),f=this.coordinates.length,g,x,k,B,P;switch(s){case"MultiPolygon":g=t.getOrientedFlatCoordinates(),B=[];var R=t.getEndss();P=0;for(var H=0,W=R.length;H<W;++H){var $=[];P=this.drawCustomCoordinates_(g,P,R[H],a,$),B.push($)}this.instructions.push([ai.CUSTOM,f,B,t,i,$6]),this.hitDetectionInstructions.push([ai.CUSTOM,f,B,t,o||i,$6]);break;case"Polygon":case"MultiLineString":k=[],g=s=="Polygon"?t.getOrientedFlatCoordinates():t.getFlatCoordinates(),P=this.drawCustomCoordinates_(g,0,t.getEnds(),a,k),this.instructions.push([ai.CUSTOM,f,k,t,i,u_]),this.hitDetectionInstructions.push([ai.CUSTOM,f,k,t,o||i,u_]);break;case"LineString":case"Circle":g=t.getFlatCoordinates(),x=this.appendFlatLineCoordinates(g,0,g.length,a,!1,!1),this.instructions.push([ai.CUSTOM,f,x,t,i,dm]),this.hitDetectionInstructions.push([ai.CUSTOM,f,x,t,o||i,dm]);break;case"MultiPoint":g=t.getFlatCoordinates(),x=this.appendFlatPointCoordinates(g,a),x>f&&(this.instructions.push([ai.CUSTOM,f,x,t,i,dm]),this.hitDetectionInstructions.push([ai.CUSTOM,f,x,t,o||i,dm]));break;case"Point":g=t.getFlatCoordinates(),this.coordinates.push(g[0],g[1]),x=this.coordinates.length,this.instructions.push([ai.CUSTOM,f,x,t,i]),this.hitDetectionInstructions.push([ai.CUSTOM,f,x,t,o||i]);break}this.endGeometry(r)},n.prototype.beginGeometry=function(t,r){this.beginGeometryInstruction1_=[ai.BEGIN_GEOMETRY,r,0,t],this.instructions.push(this.beginGeometryInstruction1_),this.beginGeometryInstruction2_=[ai.BEGIN_GEOMETRY,r,0,t],this.hitDetectionInstructions.push(this.beginGeometryInstruction2_)},n.prototype.finish=function(){return{instructions:this.instructions,hitDetectionInstructions:this.hitDetectionInstructions,coordinates:this.coordinates}},n.prototype.reverseHitDetectionInstructions=function(){var t=this.hitDetectionInstructions;t.reverse();var r,i=t.length,o,s,a=-1;for(r=0;r<i;++r)o=t[r],s=o[0],s==ai.END_GEOMETRY?a=r:s==ai.BEGIN_GEOMETRY&&(o[2]=r,dee(this.hitDetectionInstructions,a,r),a=-1)},n.prototype.setFillStrokeStyle=function(t,r){var i=this.state;if(t){var o=t.getColor();i.fillStyle=tf(o||bp)}else i.fillStyle=void 0;if(r){var s=r.getColor();i.strokeStyle=tf(s||m_);var a=r.getLineCap();i.lineCap=a!==void 0?a:B3;var f=r.getLineDash();i.lineDash=f?f.slice():h_;var g=r.getLineDashOffset();i.lineDashOffset=g||f_;var x=r.getLineJoin();i.lineJoin=x!==void 0?x:My;var k=r.getWidth();i.lineWidth=k!==void 0?k:y_;var B=r.getMiterLimit();i.miterLimit=B!==void 0?B:p_,i.lineWidth>this.maxLineWidth&&(this.maxLineWidth=i.lineWidth,this.bufferedMaxExtent_=null)}else i.strokeStyle=void 0,i.lineCap=void 0,i.lineDash=null,i.lineDashOffset=void 0,i.lineJoin=void 0,i.lineWidth=void 0,i.miterLimit=void 0},n.prototype.createFill=function(t){var r=t.fillStyle,i=[ai.SET_FILL_STYLE,r];return typeof r!="string"&&i.push(!0),i},n.prototype.applyStroke=function(t){this.instructions.push(this.createStroke(t))},n.prototype.createStroke=function(t){return[ai.SET_STROKE_STYLE,t.strokeStyle,t.lineWidth*this.pixelRatio,t.lineCap,t.lineJoin,t.miterLimit,this.applyPixelRatio(t.lineDash),t.lineDashOffset*this.pixelRatio]},n.prototype.updateFillStyle=function(t,r){var i=t.fillStyle;(typeof i!="string"||t.currentFillStyle!=i)&&(i!==void 0&&this.instructions.push(r.call(this,t)),t.currentFillStyle=i)},n.prototype.updateStrokeStyle=function(t,r){var i=t.strokeStyle,o=t.lineCap,s=t.lineDash,a=t.lineDashOffset,f=t.lineJoin,g=t.lineWidth,x=t.miterLimit;(t.currentStrokeStyle!=i||t.currentLineCap!=o||s!=t.currentLineDash&&!_1(t.currentLineDash,s)||t.currentLineDashOffset!=a||t.currentLineJoin!=f||t.currentLineWidth!=g||t.currentMiterLimit!=x)&&(i!==void 0&&r.call(this,t),t.currentStrokeStyle=i,t.currentLineCap=o,t.currentLineDash=s,t.currentLineDashOffset=a,t.currentLineJoin=f,t.currentLineWidth=g,t.currentMiterLimit=x)},n.prototype.endGeometry=function(t){this.beginGeometryInstruction1_[2]=this.instructions.length,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_[2]=this.hitDetectionInstructions.length,this.beginGeometryInstruction2_=null;var r=[ai.END_GEOMETRY,t];this.instructions.push(r),this.hitDetectionInstructions.push(r)},n.prototype.getBufferedMaxExtent=function(){if(!this.bufferedMaxExtent_&&(this.bufferedMaxExtent_=pL(this.maxExtent),this.maxLineWidth>0)){var t=this.resolution*(this.maxLineWidth+1)/2;Em(this.bufferedMaxExtent_,t,this.bufferedMaxExtent_)}return this.bufferedMaxExtent_},n}(dz);const Z_=coe;var doe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),hoe=function(e){doe(n,e);function n(t,r,i,o){var s=e.call(this,t,r,i,o)||this;return s.hitDetectionImage_=null,s.image_=null,s.imagePixelRatio_=void 0,s.anchorX_=void 0,s.anchorY_=void 0,s.height_=void 0,s.opacity_=void 0,s.originX_=void 0,s.originY_=void 0,s.rotateWithView_=void 0,s.rotation_=void 0,s.scale_=void 0,s.width_=void 0,s.declutterMode_=void 0,s.declutterImageWithText_=void 0,s}return n.prototype.drawPoint=function(t,r){if(this.image_){this.beginGeometry(t,r);var i=t.getFlatCoordinates(),o=t.getStride(),s=this.coordinates.length,a=this.appendFlatPointCoordinates(i,o);this.instructions.push([ai.DRAW_IMAGE,s,a,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([ai.DRAW_IMAGE,s,a,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,this.opacity_,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(r)}},n.prototype.drawMultiPoint=function(t,r){if(this.image_){this.beginGeometry(t,r);var i=t.getFlatCoordinates(),o=t.getStride(),s=this.coordinates.length,a=this.appendFlatPointCoordinates(i,o);this.instructions.push([ai.DRAW_IMAGE,s,a,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([ai.DRAW_IMAGE,s,a,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,this.opacity_,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(r)}},n.prototype.finish=function(){return this.reverseHitDetectionInstructions(),this.anchorX_=void 0,this.anchorY_=void 0,this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.height_=void 0,this.scale_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.width_=void 0,e.prototype.finish.call(this)},n.prototype.setImageStyle=function(t,r){var i=t.getAnchor(),o=t.getSize(),s=t.getOrigin();this.imagePixelRatio_=t.getPixelRatio(this.pixelRatio),this.anchorX_=i[0],this.anchorY_=i[1],this.hitDetectionImage_=t.getHitDetectionImage(),this.image_=t.getImage(this.pixelRatio),this.height_=o[1],this.opacity_=t.getOpacity(),this.originX_=s[0],this.originY_=s[1],this.rotateWithView_=t.getRotateWithView(),this.rotation_=t.getRotation(),this.scale_=t.getScaleArray(),this.width_=o[0],this.declutterMode_=t.getDeclutterMode(),this.declutterImageWithText_=r},n}(Z_);const foe=hoe;var poe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),moe=function(e){poe(n,e);function n(t,r,i,o){return e.call(this,t,r,i,o)||this}return n.prototype.drawFlatCoordinates_=function(t,r,i,o){var s=this.coordinates.length,a=this.appendFlatLineCoordinates(t,r,i,o,!1,!1),f=[ai.MOVE_TO_LINE_TO,s,a];return this.instructions.push(f),this.hitDetectionInstructions.push(f),i},n.prototype.drawLineString=function(t,r){var i=this.state,o=i.strokeStyle,s=i.lineWidth;if(!(o===void 0||s===void 0)){this.updateStrokeStyle(i,this.applyStroke),this.beginGeometry(t,r),this.hitDetectionInstructions.push([ai.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,h_,f_],G0);var a=t.getFlatCoordinates(),f=t.getStride();this.drawFlatCoordinates_(a,0,a.length,f),this.hitDetectionInstructions.push(hm),this.endGeometry(r)}},n.prototype.drawMultiLineString=function(t,r){var i=this.state,o=i.strokeStyle,s=i.lineWidth;if(!(o===void 0||s===void 0)){this.updateStrokeStyle(i,this.applyStroke),this.beginGeometry(t,r),this.hitDetectionInstructions.push([ai.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset],G0);for(var a=t.getEnds(),f=t.getFlatCoordinates(),g=t.getStride(),x=0,k=0,B=a.length;k<B;++k)x=this.drawFlatCoordinates_(f,x,a[k],g);this.hitDetectionInstructions.push(hm),this.endGeometry(r)}},n.prototype.finish=function(){var t=this.state;return t.lastStroke!=null&&t.lastStroke!=this.coordinates.length&&this.instructions.push(hm),this.reverseHitDetectionInstructions(),this.state=null,e.prototype.finish.call(this)},n.prototype.applyStroke=function(t){t.lastStroke!=null&&t.lastStroke!=this.coordinates.length&&(this.instructions.push(hm),t.lastStroke=this.coordinates.length),t.lastStroke=0,e.prototype.applyStroke.call(this,t),this.instructions.push(G0)},n}(Z_);const goe=moe;var yoe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),voe=function(e){yoe(n,e);function n(t,r,i,o){return e.call(this,t,r,i,o)||this}return n.prototype.drawFlatCoordinatess_=function(t,r,i,o){var s=this.state,a=s.fillStyle!==void 0,f=s.strokeStyle!==void 0,g=i.length;this.instructions.push(G0),this.hitDetectionInstructions.push(G0);for(var x=0;x<g;++x){var k=i[x],B=this.coordinates.length,P=this.appendFlatLineCoordinates(t,r,k,o,!0,!f),R=[ai.MOVE_TO_LINE_TO,B,P];this.instructions.push(R),this.hitDetectionInstructions.push(R),f&&(this.instructions.push(U9),this.hitDetectionInstructions.push(U9)),r=k}return a&&(this.instructions.push(kx),this.hitDetectionInstructions.push(kx)),f&&(this.instructions.push(hm),this.hitDetectionInstructions.push(hm)),r},n.prototype.drawCircle=function(t,r){var i=this.state,o=i.fillStyle,s=i.strokeStyle;if(!(o===void 0&&s===void 0)){this.setFillStrokeStyles_(),this.beginGeometry(t,r),i.fillStyle!==void 0&&this.hitDetectionInstructions.push([ai.SET_FILL_STYLE,bp]),i.strokeStyle!==void 0&&this.hitDetectionInstructions.push([ai.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset]);var a=t.getFlatCoordinates(),f=t.getStride(),g=this.coordinates.length;this.appendFlatLineCoordinates(a,0,a.length,f,!1,!1);var x=[ai.CIRCLE,g];this.instructions.push(G0,x),this.hitDetectionInstructions.push(G0,x),i.fillStyle!==void 0&&(this.instructions.push(kx),this.hitDetectionInstructions.push(kx)),i.strokeStyle!==void 0&&(this.instructions.push(hm),this.hitDetectionInstructions.push(hm)),this.endGeometry(r)}},n.prototype.drawPolygon=function(t,r){var i=this.state,o=i.fillStyle,s=i.strokeStyle;if(!(o===void 0&&s===void 0)){this.setFillStrokeStyles_(),this.beginGeometry(t,r),i.fillStyle!==void 0&&this.hitDetectionInstructions.push([ai.SET_FILL_STYLE,bp]),i.strokeStyle!==void 0&&this.hitDetectionInstructions.push([ai.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset]);var a=t.getEnds(),f=t.getOrientedFlatCoordinates(),g=t.getStride();this.drawFlatCoordinatess_(f,0,a,g),this.endGeometry(r)}},n.prototype.drawMultiPolygon=function(t,r){var i=this.state,o=i.fillStyle,s=i.strokeStyle;if(!(o===void 0&&s===void 0)){this.setFillStrokeStyles_(),this.beginGeometry(t,r),i.fillStyle!==void 0&&this.hitDetectionInstructions.push([ai.SET_FILL_STYLE,bp]),i.strokeStyle!==void 0&&this.hitDetectionInstructions.push([ai.SET_STROKE_STYLE,i.strokeStyle,i.lineWidth,i.lineCap,i.lineJoin,i.miterLimit,i.lineDash,i.lineDashOffset]);for(var a=t.getEndss(),f=t.getOrientedFlatCoordinates(),g=t.getStride(),x=0,k=0,B=a.length;k<B;++k)x=this.drawFlatCoordinatess_(f,x,a[k],g);this.endGeometry(r)}},n.prototype.finish=function(){this.reverseHitDetectionInstructions(),this.state=null;var t=this.tolerance;if(t!==0)for(var r=this.coordinates,i=0,o=r.length;i<o;++i)r[i]=S0(r[i],t);return e.prototype.finish.call(this)},n.prototype.setFillStrokeStyles_=function(){var t=this.state,r=t.fillStyle;r!==void 0&&this.updateFillStyle(t,this.createFill),t.strokeStyle!==void 0&&this.updateStrokeStyle(t,this.applyStroke)},n}(Z_);const R9=voe,hz={POINT:"point",LINE:"line"};function Coe(e,n,t,r,i){var o=t,s=t,a=0,f=0,g=t,x,k,B,P,R,H,W,$,q,oe;for(k=t;k<r;k+=i){var ne=n[k],ce=n[k+1];R!==void 0&&(q=ne-R,oe=ce-H,P=Math.sqrt(q*q+oe*oe),W!==void 0&&(f+=B,x=Math.acos((W*q+$*oe)/(B*P)),x>e&&(f>a&&(a=f,o=g,s=k),f=0,g=k-i)),B=P,W=q,$=oe),R=ne,H=ce}return f+=P,f>a?[g,k]:[o,s]}var _oe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),IC={left:0,end:0,center:.5,right:1,start:1,top:0,middle:.5,hanging:.2,alphabetic:.8,ideographic:.8,bottom:1},boe=function(e){_oe(n,e);function n(t,r,i,o){var s=e.call(this,t,r,i,o)||this;return s.labels_=null,s.text_="",s.textOffsetX_=0,s.textOffsetY_=0,s.textRotateWithView_=void 0,s.textRotation_=0,s.textFillState_=null,s.fillStates={},s.textStrokeState_=null,s.strokeStates={},s.textState_={},s.textStates={},s.textKey_="",s.fillKey_="",s.strokeKey_="",s.declutterImageWithText_=void 0,s}return n.prototype.finish=function(){var t=e.prototype.finish.call(this);return t.textStates=this.textStates,t.fillStates=this.fillStates,t.strokeStates=this.strokeStates,t},n.prototype.drawText=function(t,r){var i=this.textFillState_,o=this.textStrokeState_,s=this.textState_;if(!(this.text_===""||!s||!i&&!o)){var a=this.coordinates,f=a.length,g=t.getType(),x=null,k=t.getStride();if(s.placement===hz.LINE&&(g=="LineString"||g=="MultiLineString"||g=="Polygon"||g=="MultiPolygon")){if(!il(this.getBufferedMaxExtent(),t.getExtent()))return;var B=void 0;if(x=t.getFlatCoordinates(),g=="LineString")B=[x.length];else if(g=="MultiLineString")B=t.getEnds();else if(g=="Polygon")B=t.getEnds().slice(0,1);else if(g=="MultiPolygon"){var P=t.getEndss();B=[];for(var R=0,H=P.length;R<H;++R)B.push(P[R][0])}this.beginGeometry(t,r);for(var W=s.textAlign,$=0,q=void 0,oe=0,ne=B.length;oe<ne;++oe){if(W==null){var ce=Coe(s.maxAngle,x,$,B[oe],k);$=ce[0],q=ce[1]}else q=B[oe];for(var R=$;R<q;R+=k)a.push(x[R],x[R+1]);var ae=a.length;$=B[oe],this.drawChars_(f,ae),f=ae}this.endGeometry(r)}else{var ue=s.overflow?null:[];switch(g){case"Point":case"MultiPoint":x=t.getFlatCoordinates();break;case"LineString":x=t.getFlatMidpoint();break;case"Circle":x=t.getCenter();break;case"MultiLineString":x=t.getFlatMidpoints(),k=2;break;case"Polygon":x=t.getFlatInteriorPoint(),s.overflow||ue.push(x[2]/this.resolution),k=3;break;case"MultiPolygon":var ye=t.getFlatInteriorPoints();x=[];for(var R=0,H=ye.length;R<H;R+=3)s.overflow||ue.push(ye[R+2]/this.resolution),x.push(ye[R],ye[R+1]);if(x.length===0)return;k=2;break}var ae=this.appendFlatPointCoordinates(x,k);if(ae===f)return;if(ue&&(ae-f)/2!==x.length/k){var Re=f/2;ue=ue.filter(function(Jt,Nt){var Ve=a[(Re+Nt)*2]===x[Nt*k]&&a[(Re+Nt)*2+1]===x[Nt*k+1];return Ve||--Re,Ve})}this.saveTextStates_(),(s.backgroundFill||s.backgroundStroke)&&(this.setFillStrokeStyle(s.backgroundFill,s.backgroundStroke),s.backgroundFill&&(this.updateFillStyle(this.state,this.createFill),this.hitDetectionInstructions.push(this.createFill(this.state))),s.backgroundStroke&&(this.updateStrokeStyle(this.state,this.applyStroke),this.hitDetectionInstructions.push(this.createStroke(this.state)))),this.beginGeometry(t,r);var Ne=s.padding;if(Ne!=N0&&(s.scale[0]<0||s.scale[1]<0)){var rt=s.padding[0],ct=s.padding[1],Fe=s.padding[2],He=s.padding[3];s.scale[0]<0&&(ct=-ct,He=-He),s.scale[1]<0&&(rt=-rt,Fe=-Fe),Ne=[rt,ct,Fe,He]}var Ce=this.pixelRatio;this.instructions.push([ai.DRAW_IMAGE,f,ae,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[1,1],NaN,void 0,this.declutterImageWithText_,Ne==N0?N0:Ne.map(function(Jt){return Jt*Ce}),!!s.backgroundFill,!!s.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,ue]);var jt=1/Ce;this.hitDetectionInstructions.push([ai.DRAW_IMAGE,f,ae,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[jt,jt],NaN,void 0,this.declutterImageWithText_,Ne,!!s.backgroundFill,!!s.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,ue]),this.endGeometry(r)}}},n.prototype.saveTextStates_=function(){var t=this.textStrokeState_,r=this.textState_,i=this.textFillState_,o=this.strokeKey_;t&&(o in this.strokeStates||(this.strokeStates[o]={strokeStyle:t.strokeStyle,lineCap:t.lineCap,lineDashOffset:t.lineDashOffset,lineWidth:t.lineWidth,lineJoin:t.lineJoin,miterLimit:t.miterLimit,lineDash:t.lineDash}));var s=this.textKey_;s in this.textStates||(this.textStates[s]={font:r.font,textAlign:r.textAlign||g_,justify:r.justify,textBaseline:r.textBaseline||k3,scale:r.scale});var a=this.fillKey_;i&&(a in this.fillStates||(this.fillStates[a]={fillStyle:i.fillStyle}))},n.prototype.drawChars_=function(t,r){var i=this.textStrokeState_,o=this.textState_,s=this.strokeKey_,a=this.textKey_,f=this.fillKey_;this.saveTextStates_();var g=this.pixelRatio,x=IC[o.textBaseline],k=this.textOffsetY_*g,B=this.text_,P=i?i.lineWidth*Math.abs(o.scale[0])/2:0;this.instructions.push([ai.DRAW_CHARS,t,r,x,o.overflow,f,o.maxAngle,g,k,s,P*g,B,a,1]),this.hitDetectionInstructions.push([ai.DRAW_CHARS,t,r,x,o.overflow,f,o.maxAngle,1,k,s,P,B,a,1/g])},n.prototype.setTextStyle=function(t,r){var i,o,s;if(!t)this.text_="";else{var a=t.getFill();a?(o=this.textFillState_,o||(o={},this.textFillState_=o),o.fillStyle=tf(a.getColor()||bp)):(o=null,this.textFillState_=o);var f=t.getStroke();if(!f)s=null,this.textStrokeState_=s;else{s=this.textStrokeState_,s||(s={},this.textStrokeState_=s);var g=f.getLineDash(),x=f.getLineDashOffset(),k=f.getWidth(),B=f.getMiterLimit();s.lineCap=f.getLineCap()||B3,s.lineDash=g?g.slice():h_,s.lineDashOffset=x===void 0?f_:x,s.lineJoin=f.getLineJoin()||My,s.lineWidth=k===void 0?y_:k,s.miterLimit=B===void 0?p_:B,s.strokeStyle=tf(f.getColor()||m_)}i=this.textState_;var P=t.getFont()||qL;Are(P);var R=t.getScaleArray();i.overflow=t.getOverflow(),i.font=P,i.maxAngle=t.getMaxAngle(),i.placement=t.getPlacement(),i.textAlign=t.getTextAlign(),i.justify=t.getJustify(),i.textBaseline=t.getTextBaseline()||k3,i.backgroundFill=t.getBackgroundFill(),i.backgroundStroke=t.getBackgroundStroke(),i.padding=t.getPadding()||N0,i.scale=R===void 0?[1,1]:R;var H=t.getOffsetX(),W=t.getOffsetY(),$=t.getRotateWithView(),q=t.getRotation();this.text_=t.getText()||"",this.textOffsetX_=H===void 0?0:H,this.textOffsetY_=W===void 0?0:W,this.textRotateWithView_=$===void 0?!1:$,this.textRotation_=q===void 0?0:q,this.strokeKey_=s?(typeof s.strokeStyle=="string"?s.strokeStyle:$i(s.strokeStyle))+s.lineCap+s.lineDashOffset+"|"+s.lineWidth+s.lineJoin+s.miterLimit+"["+s.lineDash.join()+"]":"",this.textKey_=i.font+i.scale+(i.textAlign||"?")+(i.justify||"?")+(i.textBaseline||"?"),this.fillKey_=o?typeof o.fillStyle=="string"?o.fillStyle:"|"+$i(o.fillStyle):""}this.declutterImageWithText_=r},n}(Z_),xoe={Circle:R9,Default:Z_,Image:foe,LineString:goe,Polygon:R9,Text:boe},K3=function(){function e(n,t,r,i){this.tolerance_=n,this.maxExtent_=t,this.pixelRatio_=i,this.resolution_=r,this.buildersByZIndex_={}}return e.prototype.finish=function(){var n={};for(var t in this.buildersByZIndex_){n[t]=n[t]||{};var r=this.buildersByZIndex_[t];for(var i in r){var o=r[i].finish();n[t][i]=o}}return n},e.prototype.getBuilder=function(n,t){var r=n!==void 0?n.toString():"0",i=this.buildersByZIndex_[r];i===void 0&&(i={},this.buildersByZIndex_[r]=i);var o=i[t];if(o===void 0){var s=xoe[t];o=new s(this.tolerance_,this.maxExtent_,this.resolution_,this.pixelRatio_),i[t]=o}return o},e}(),woe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Moe=function(e){woe(n,e);function n(t){var r=e.call(this)||this;return r.ready=!0,r.boundHandleImageChange_=r.handleImageChange_.bind(r),r.layer_=t,r.declutterExecutorGroup=null,r}return n.prototype.getFeatures=function(t){return li()},n.prototype.getData=function(t){return null},n.prototype.prepareFrame=function(t){return li()},n.prototype.renderFrame=function(t,r){return li()},n.prototype.loadedTileCallback=function(t,r,i){t[r]||(t[r]={}),t[r][i.tileCoord.toString()]=i},n.prototype.createLoadedTileFinder=function(t,r,i){return(function(o,s){var a=this.loadedTileCallback.bind(this,i,o);return t.forEachLoadedTile(r,o,s,a)}).bind(this)},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s){},n.prototype.getDataAtPixel=function(t,r,i){return null},n.prototype.getLayer=function(){return this.layer_},n.prototype.handleFontsChanged=function(){},n.prototype.handleImageChange_=function(t){var r=t.target;r.getState()===Na.LOADED&&this.renderIfReadyAndVisible()},n.prototype.loadImage=function(t){var r=t.getState();return r!=Na.LOADED&&r!=Na.ERROR&&t.addEventListener(ki.CHANGE,this.boundHandleImageChange_),r==Na.IDLE&&(t.load(),r=t.getState()),r==Na.LOADED},n.prototype.renderIfReadyAndVisible=function(){var t=this.getLayer();t&&t.getVisible()&&t.getSourceState()==="ready"&&t.changed()},n.prototype.disposeInternal=function(){delete this.layer_,e.prototype.disposeInternal.call(this)},n}(lL);const Soe=Moe;var Eoe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),L9=[],wg=null;function Ooe(){var e=document.createElement("canvas");e.width=1,e.height=1,wg=e.getContext("2d")}var Boe=function(e){Eoe(n,e);function n(t){var r=e.call(this,t)||this;return r.container=null,r.renderedResolution,r.tempTransform=xd(),r.pixelTransform=xd(),r.inversePixelTransform=xd(),r.context=null,r.containerReused=!1,r.pixelContext_=null,r.frameState=null,r}return n.prototype.getImageData=function(t,r,i){wg||Ooe(),wg.clearRect(0,0,1,1);var o;try{wg.drawImage(t,r,i,1,1,0,0,1,1),o=wg.getImageData(0,0,1,1).data}catch{return wg=null,null}return o},n.prototype.getBackground=function(t){var r=this.getLayer(),i=r.getBackground();return typeof i=="function"&&(i=i(t.viewState.resolution)),i||void 0},n.prototype.useContainer=function(t,r,i){var o=this.getLayer().getClassName(),s,a;if(t&&t.className===o&&(!i||t&&t.style.backgroundColor&&_1(M3(t.style.backgroundColor),M3(i)))){var f=t.firstElementChild;f instanceof HTMLCanvasElement&&(a=f.getContext("2d"))}if(a&&a.canvas.style.transform===r?(this.container=t,this.context=a,this.containerReused=!0):this.containerReused&&(this.container=null,this.context=null,this.containerReused=!1),!this.container){s=document.createElement("div"),s.className=o;var g=s.style;g.position="absolute",g.width="100%",g.height="100%",a=YA();var f=a.canvas;s.appendChild(f),g=f.style,g.position="absolute",g.left="0",g.transformOrigin="top left",this.container=s,this.context=a}!this.containerReused&&i&&!this.container.style.backgroundColor&&(this.container.style.backgroundColor=i)},n.prototype.clipUnrotated=function(t,r,i){var o=Lm(i),s=l5(i),a=s5(i),f=a5(i);rl(r.coordinateToPixelTransform,o),rl(r.coordinateToPixelTransform,s),rl(r.coordinateToPixelTransform,a),rl(r.coordinateToPixelTransform,f);var g=this.inversePixelTransform;rl(g,o),rl(g,s),rl(g,a),rl(g,f),t.save(),t.beginPath(),t.moveTo(Math.round(o[0]),Math.round(o[1])),t.lineTo(Math.round(s[0]),Math.round(s[1])),t.lineTo(Math.round(a[0]),Math.round(a[1])),t.lineTo(Math.round(f[0]),Math.round(f[1])),t.clip()},n.prototype.dispatchRenderEvent_=function(t,r,i){var o=this.getLayer();if(o.hasListener(t)){var s=new QL(t,this.inversePixelTransform,i,r);o.dispatchEvent(s)}},n.prototype.preRender=function(t,r){this.frameState=r,this.dispatchRenderEvent_(Bm.PRERENDER,t,r)},n.prototype.postRender=function(t,r){this.dispatchRenderEvent_(Bm.POSTRENDER,t,r)},n.prototype.getRenderTransform=function(t,r,i,o,s,a,f){var g=s/2,x=a/2,k=o/r,B=-k,P=-t[0]+f,R=-t[1];return df(this.tempTransform,g,x,k,B,-i,P,R)},n.prototype.getDataAtPixel=function(t,r,i){var o=rl(this.inversePixelTransform,t.slice()),s=this.context,a=this.getLayer(),f=a.getExtent();if(f){var g=rl(r.pixelToCoordinateTransform,t.slice());if(!$_(f,g))return null}var x=Math.round(o[0]),k=Math.round(o[1]),B=this.pixelContext_;if(!B){var P=document.createElement("canvas");P.width=1,P.height=1,B=P.getContext("2d"),this.pixelContext_=B}B.clearRect(0,0,1,1);var R;try{B.drawImage(s.canvas,x,k,1,1,0,0,1,1),R=B.getImageData(0,0,1,1).data}catch(H){return H.name==="SecurityError"?(this.pixelContext_=null,new Uint8Array):R}return R[3]===0?null:R},n.prototype.disposeInternal=function(){delete this.frameState,e.prototype.disposeInternal.call(this)},n}(Soe);const fz=Boe;function koe(e,n,t,r,i,o,s,a,f,g,x,k){var B=e[n],P=e[n+1],R=0,H=0,W=0,$=0;function q(){R=B,H=P,n+=r,B=e[n],P=e[n+1],$+=W,W=Math.sqrt((B-R)*(B-R)+(P-H)*(P-H))}do q();while(n<t-r&&$+W<o);for(var oe=W===0?0:(o-$)/W,ne=Ap(R,B,oe),ce=Ap(H,P,oe),ae=n-r,ue=$,ye=o+a*f(g,i,x);n<t-r&&$+W<ye;)q();oe=W===0?0:(ye-$)/W;var Re=Ap(R,B,oe),Ne=Ap(H,P,oe),rt;if(k){var ct=[ne,ce,Re,Ne];ML(ct,0,4,2,k,ct,ct),rt=ct[0]>ct[2]}else rt=ne>Re;var Fe=Math.PI,He=[],Ce=ae+r===n;n=ae,W=0,$=ue,B=e[n],P=e[n+1];var jt;if(Ce){q(),jt=Math.atan2(P-H,B-R),rt&&(jt+=jt>0?-Fe:Fe);var Ft=(Re+ne)/2,Jt=(Ne+ce)/2;return He[0]=[Ft,Jt,(ye-o)/2,jt,i],He}i=i.replace(/\n/g," ");for(var Nt=0,Ve=i.length;Nt<Ve;){q();var nt=Math.atan2(P-H,B-R);if(rt&&(nt+=nt>0?-Fe:Fe),jt!==void 0){var Je=nt-jt;if(Je+=Je>Fe?-2*Fe:Je<-Fe?2*Fe:0,Math.abs(Je)>s)return null}jt=nt;for(var Vt=Nt,pt=0;Nt<Ve;++Nt){var dt=rt?Ve-Nt-1:Nt,kt=a*f(g,i[dt],x);if(n+r<t&&$+W<o+pt+kt/2)break;pt+=kt}if(Nt!==Vt){var Dt=rt?i.substring(Ve-Vt,Ve-Nt):i.substring(Vt,Nt);oe=W===0?0:(o+pt/2-$)/W;var Ft=Ap(R,B,oe),Jt=Ap(H,P,oe);He.push([Ft,Jt,pt/2,nt,Dt]),o+=pt}}return He}var lg=Ed(),Qp=[],Zf=[],Xf=[],$p=[];function z9(e){return e[3].declutterBox}var Ioe=new RegExp("[֑-ࣿיִ-﷿ﹰ-ﻼࠀ--]");function j9(e,n){return(n==="start"||n==="end")&&!Ioe.test(e)&&(n=n==="start"?"left":"right"),IC[n]}function Toe(e,n,t){return t>0&&e.push(`
|
||
`,""),e.push(n,""),e}var Koe=function(){function e(n,t,r,i){this.overlaps=r,this.pixelRatio=t,this.resolution=n,this.alignFill_,this.instructions=i.instructions,this.coordinates=i.coordinates,this.coordinateCache_={},this.renderedTransform_=xd(),this.hitDetectionInstructions=i.hitDetectionInstructions,this.pixelCoordinates_=null,this.viewRotation_=0,this.fillStates=i.fillStates||{},this.strokeStates=i.strokeStates||{},this.textStates=i.textStates||{},this.widths_={},this.labels_={}}return e.prototype.createLabel=function(n,t,r,i){var o=n+t+r+i;if(this.labels_[o])return this.labels_[o];var s=i?this.strokeStates[i]:null,a=r?this.fillStates[r]:null,f=this.textStates[t],g=this.pixelRatio,x=[f.scale[0]*g,f.scale[1]*g],k=Array.isArray(n),B=f.justify?IC[f.justify]:j9(Array.isArray(n)?n[0]:n,f.textAlign||g_),P=i&&s.lineWidth?s.lineWidth:0,R=k?n:n.split(`
|
||
`).reduce(Toe,[]),H=dre(f,R),W=H.width,$=H.height,q=H.widths,oe=H.heights,ne=H.lineWidths,ce=W+P,ae=[],ue=(ce+2)*x[0],ye=($+P)*x[1],Re={width:ue<0?Math.floor(ue):Math.ceil(ue),height:ye<0?Math.floor(ye):Math.ceil(ye),contextInstructions:ae};if((x[0]!=1||x[1]!=1)&&ae.push("scale",x),i){ae.push("strokeStyle",s.strokeStyle),ae.push("lineWidth",P),ae.push("lineCap",s.lineCap),ae.push("lineJoin",s.lineJoin),ae.push("miterLimit",s.miterLimit);var Ne=i5?OffscreenCanvasRenderingContext2D:CanvasRenderingContext2D;Ne.prototype.setLineDash&&(ae.push("setLineDash",[s.lineDash]),ae.push("lineDashOffset",s.lineDashOffset))}r&&ae.push("fillStyle",a.fillStyle),ae.push("textBaseline","middle"),ae.push("textAlign","center");for(var rt=.5-B,ct=B*ce+rt*P,Fe=[],He=[],Ce=0,jt=0,Ft=0,Jt=0,Nt,Ve=0,nt=R.length;Ve<nt;Ve+=2){var Je=R[Ve];if(Je===`
|
||
`){jt+=Ce,Ce=0,ct=B*ce+rt*P,++Jt;continue}var Vt=R[Ve+1]||f.font;Vt!==Nt&&(i&&Fe.push("font",Vt),r&&He.push("font",Vt),Nt=Vt),Ce=Math.max(Ce,oe[Ft]);var pt=[Je,ct+rt*q[Ft]+B*(q[Ft]-ne[Jt]),.5*(P+Ce)+jt];ct+=q[Ft],i&&Fe.push("strokeText",pt),r&&He.push("fillText",pt),++Ft}return Array.prototype.push.apply(ae,Fe),Array.prototype.push.apply(ae,He),this.labels_[o]=Re,Re},e.prototype.replayTextBackground_=function(n,t,r,i,o,s,a){n.beginPath(),n.moveTo.apply(n,t),n.lineTo.apply(n,r),n.lineTo.apply(n,i),n.lineTo.apply(n,o),n.lineTo.apply(n,t),s&&(this.alignFill_=s[2],this.fill_(n)),a&&(this.setStrokeStyle_(n,a),n.stroke())},e.prototype.calculateImageOrLabelDimensions_=function(n,t,r,i,o,s,a,f,g,x,k,B,P,R,H,W){a*=B[0],f*=B[1];var $=r-a,q=i-f,oe=o+g>n?n-g:o,ne=s+x>t?t-x:s,ce=R[3]+oe*B[0]+R[1],ae=R[0]+ne*B[1]+R[2],ue=$-R[3],ye=q-R[0];(H||k!==0)&&(Qp[0]=ue,$p[0]=ue,Qp[1]=ye,Zf[1]=ye,Zf[0]=ue+ce,Xf[0]=Zf[0],Xf[1]=ye+ae,$p[1]=Xf[1]);var Re;return k!==0?(Re=df(xd(),r,i,1,1,k,-r,-i),rl(Re,Qp),rl(Re,Zf),rl(Re,Xf),rl(Re,$p),hf(Math.min(Qp[0],Zf[0],Xf[0],$p[0]),Math.min(Qp[1],Zf[1],Xf[1],$p[1]),Math.max(Qp[0],Zf[0],Xf[0],$p[0]),Math.max(Qp[1],Zf[1],Xf[1],$p[1]),lg)):hf(Math.min(ue,ue+ce),Math.min(ye,ye+ae),Math.max(ue,ue+ce),Math.max(ye,ye+ae),lg),P&&($=Math.round($),q=Math.round(q)),{drawImageX:$,drawImageY:q,drawImageW:oe,drawImageH:ne,originX:g,originY:x,declutterBox:{minX:lg[0],minY:lg[1],maxX:lg[2],maxY:lg[3],value:W},canvasTransform:Re,scale:B}},e.prototype.replayImageOrLabel_=function(n,t,r,i,o,s,a){var f=!!(s||a),g=i.declutterBox,x=n.canvas,k=a?a[2]*i.scale[0]/2:0,B=g.minX-k<=x.width/t&&g.maxX+k>=0&&g.minY-k<=x.height/t&&g.maxY+k>=0;return B&&(f&&this.replayTextBackground_(n,Qp,Zf,Xf,$p,s,a),hre(n,i.canvasTransform,o,r,i.originX,i.originY,i.drawImageW,i.drawImageH,i.drawImageX,i.drawImageY,i.scale)),!0},e.prototype.fill_=function(n){if(this.alignFill_){var t=rl(this.renderedTransform_,[0,0]),r=512*this.pixelRatio;n.save(),n.translate(t[0]%r,t[1]%r),n.rotate(this.viewRotation_)}n.fill(),this.alignFill_&&n.restore()},e.prototype.setStrokeStyle_=function(n,t){n.strokeStyle=t[1],n.lineWidth=t[2],n.lineCap=t[3],n.lineJoin=t[4],n.miterLimit=t[5],n.setLineDash&&(n.lineDashOffset=t[7],n.setLineDash(t[6]))},e.prototype.drawLabelWithPointPlacement_=function(n,t,r,i){var o=this.textStates[t],s=this.createLabel(n,t,i,r),a=this.strokeStates[r],f=this.pixelRatio,g=j9(Array.isArray(n)?n[0]:n,o.textAlign||g_),x=IC[o.textBaseline||k3],k=a&&a.lineWidth?a.lineWidth:0,B=s.width/f-2*o.scale[0],P=g*B+2*(.5-g)*k,R=x*s.height/f+2*(.5-x)*k;return{label:s,anchorX:P,anchorY:R}},e.prototype.execute_=function(n,t,r,i,o,s,a,f){var g;this.pixelCoordinates_&&_1(r,this.renderedTransform_)?g=this.pixelCoordinates_:(this.pixelCoordinates_||(this.pixelCoordinates_=[]),g=Om(this.coordinates,0,this.coordinates.length,2,r,this.pixelCoordinates_),kee(this.renderedTransform_,r));for(var x=0,k=i.length,B=0,P,R,H,W,$,q,oe,ne,ce,ae,ue,ye,Re=0,Ne=0,rt=null,ct=null,Fe=this.coordinateCache_,He=this.viewRotation_,Ce=Math.round(Math.atan2(-r[1],r[0])*1e12)/1e12,jt={context:n,pixelRatio:this.pixelRatio,resolution:this.resolution,rotation:He},Ft=this.instructions!=i||this.overlaps?0:200,Jt,Nt,Ve,nt;x<k;){var Je=i[x],Vt=Je[0];switch(Vt){case ai.BEGIN_GEOMETRY:Jt=Je[1],nt=Je[3],Jt.getGeometry()?a!==void 0&&!il(a,nt.getExtent())?x=Je[2]+1:++x:x=Je[2];break;case ai.BEGIN_PATH:Re>Ft&&(this.fill_(n),Re=0),Ne>Ft&&(n.stroke(),Ne=0),!Re&&!Ne&&(n.beginPath(),W=NaN,$=NaN),++x;break;case ai.CIRCLE:B=Je[1];var pt=g[B],dt=g[B+1],kt=g[B+2],Dt=g[B+3],Se=kt-pt,de=Dt-dt,xe=Math.sqrt(Se*Se+de*de);n.moveTo(pt+xe,dt),n.arc(pt,dt,xe,0,2*Math.PI,!0),++x;break;case ai.CLOSE_PATH:n.closePath(),++x;break;case ai.CUSTOM:B=Je[1],P=Je[2];var Pe=Je[3],Ze=Je[4],Xe=Je.length==6?Je[5]:void 0;jt.geometry=Pe,jt.feature=Jt,x in Fe||(Fe[x]=[]);var wt=Fe[x];Xe?Xe(g,B,P,2,wt):(wt[0]=g[B],wt[1]=g[B+1],wt.length=2),Ze(wt,jt),++x;break;case ai.DRAW_IMAGE:B=Je[1],P=Je[2],ne=Je[3],R=Je[4],H=Je[5];var Kt=Je[6],Pt=Je[7],zn=Je[8],mt=Je[9],pn=Je[10],ir=Je[11],Sn=Je[12],nr=Je[13],Mr=Je[14],Qr=Je[15];if(!ne&&Je.length>=20){ce=Je[19],ae=Je[20],ue=Je[21],ye=Je[22];var _r=this.drawLabelWithPointPlacement_(ce,ae,ue,ye);ne=_r.label,Je[3]=ne;var vi=Je[23];R=(_r.anchorX-vi)*this.pixelRatio,Je[4]=R;var we=Je[24];H=(_r.anchorY-we)*this.pixelRatio,Je[5]=H,Kt=ne.height,Je[6]=Kt,nr=ne.width,Je[13]=nr}var V=void 0;Je.length>25&&(V=Je[25]);var X=void 0,me=void 0,At=void 0;Je.length>17?(X=Je[16],me=Je[17],At=Je[18]):(X=N0,me=!1,At=!1),pn&&Ce?ir+=He:!pn&&!Ce&&(ir-=He);for(var bt=0;B<P;B+=2)if(!(V&&V[bt++]<nr/this.pixelRatio)){var Et=this.calculateImageOrLabelDimensions_(ne.width,ne.height,g[B],g[B+1],nr,Kt,R,H,zn,mt,ir,Sn,o,X,me||At,Jt),sr=[n,t,ne,Et,Pt,me?rt:null,At?ct:null];if(f){if(Mr==="none")continue;if(Mr==="obstacle"){f.insert(Et.declutterBox);continue}else{var Lt=void 0,Fn=void 0;if(Qr){var on=P-B;if(!Qr[on]){Qr[on]=sr;continue}if(Lt=Qr[on],delete Qr[on],Fn=z9(Lt),f.collides(Fn))continue}if(f.collides(Et.declutterBox))continue;Lt&&(f.insert(Fn),this.replayImageOrLabel_.apply(this,Lt)),f.insert(Et.declutterBox)}}this.replayImageOrLabel_.apply(this,sr)}++x;break;case ai.DRAW_CHARS:var m=Je[1],un=Je[2],In=Je[3],Gn=Je[4];ye=Je[5];var Zn=Je[6],Ke=Je[7],fe=Je[8];ue=Je[9];var _e=Je[10];ce=Je[11],ae=Je[12];var Ee=[Je[13],Je[13]],Te=this.textStates[ae],at=Te.font,it=[Te.scale[0]*Ke,Te.scale[1]*Ke],ht=void 0;at in this.widths_?ht=this.widths_[at]:(ht={},this.widths_[at]=ht);var et=TL(g,m,un,2),Ct=Math.abs(it[0])*E9(at,ce,ht);if(Gn||Ct<=et){var rn=this.textStates[ae].textAlign,Gt=(et-Ct)*IC[rn],$t=koe(g,m,un,2,ce,Gt,Zn,Math.abs(it[0]),E9,at,ht,Ce?0:this.viewRotation_);e:if($t){var gn=[],Jn=void 0,qn=void 0,Tr=void 0,vr=void 0,Dr=void 0;if(ue)for(Jn=0,qn=$t.length;Jn<qn;++Jn){Dr=$t[Jn],Tr=Dr[4],vr=this.createLabel(Tr,ae,"",ue),R=Dr[2]+(it[0]<0?-_e:_e),H=In*vr.height+(.5-In)*2*_e*it[1]/it[0]-fe;var Et=this.calculateImageOrLabelDimensions_(vr.width,vr.height,Dr[0],Dr[1],vr.width,vr.height,R,H,0,0,Dr[3],Ee,!1,N0,!1,Jt);if(f&&f.collides(Et.declutterBox))break e;gn.push([n,t,vr,Et,1,null,null])}if(ye)for(Jn=0,qn=$t.length;Jn<qn;++Jn){Dr=$t[Jn],Tr=Dr[4],vr=this.createLabel(Tr,ae,ye,""),R=Dr[2],H=In*vr.height-fe;var Et=this.calculateImageOrLabelDimensions_(vr.width,vr.height,Dr[0],Dr[1],vr.width,vr.height,R,H,0,0,Dr[3],Ee,!1,N0,!1,Jt);if(f&&f.collides(Et.declutterBox))break e;gn.push([n,t,vr,Et,1,null,null])}f&&f.load(gn.map(z9));for(var Yr=0,Zr=gn.length;Yr<Zr;++Yr)this.replayImageOrLabel_.apply(this,gn[Yr])}}++x;break;case ai.END_GEOMETRY:if(s!==void 0){Jt=Je[1];var Cr=s(Jt,nt);if(Cr)return Cr}++x;break;case ai.FILL:Ft?Re++:this.fill_(n),++x;break;case ai.MOVE_TO_LINE_TO:for(B=Je[1],P=Je[2],Nt=g[B],Ve=g[B+1],q=Nt+.5|0,oe=Ve+.5|0,(q!==W||oe!==$)&&(n.moveTo(Nt,Ve),W=q,$=oe),B+=2;B<P;B+=2)Nt=g[B],Ve=g[B+1],q=Nt+.5|0,oe=Ve+.5|0,(B==P-2||q!==W||oe!==$)&&(n.lineTo(Nt,Ve),W=q,$=oe);++x;break;case ai.SET_FILL_STYLE:rt=Je,this.alignFill_=Je[2],Re&&(this.fill_(n),Re=0,Ne&&(n.stroke(),Ne=0)),n.fillStyle=Je[1],++x;break;case ai.SET_STROKE_STYLE:ct=Je,Ne&&(n.stroke(),Ne=0),this.setStrokeStyle_(n,Je),++x;break;case ai.STROKE:Ft?Ne++:n.stroke(),++x;break;default:++x;break}}Re&&this.fill_(n),Ne&&n.stroke()},e.prototype.execute=function(n,t,r,i,o,s){this.viewRotation_=i,this.execute_(n,t,r,this.instructions,o,void 0,void 0,s)},e.prototype.executeHitDetection=function(n,t,r,i,o){return this.viewRotation_=r,this.execute_(n,1,t,this.hitDetectionInstructions,!0,i,o)},e}();const Poe=Koe;var yM=["Polygon","Circle","LineString","Image","Text","Default"],Foe=function(){function e(n,t,r,i,o,s){this.maxExtent_=n,this.overlaps_=i,this.pixelRatio_=r,this.resolution_=t,this.renderBuffer_=s,this.executorsByZIndex_={},this.hitDetectionContext_=null,this.hitDetectionTransform_=xd(),this.createExecutors_(o)}return e.prototype.clip=function(n,t){var r=this.getClipCoords(t);n.beginPath(),n.moveTo(r[0],r[1]),n.lineTo(r[2],r[3]),n.lineTo(r[4],r[5]),n.lineTo(r[6],r[7]),n.clip()},e.prototype.createExecutors_=function(n){for(var t in n){var r=this.executorsByZIndex_[t];r===void 0&&(r={},this.executorsByZIndex_[t]=r);var i=n[t];for(var o in i){var s=i[o];r[o]=new Poe(this.resolution_,this.pixelRatio_,this.overlaps_,s)}}},e.prototype.hasExecutors=function(n){for(var t in this.executorsByZIndex_)for(var r=this.executorsByZIndex_[t],i=0,o=n.length;i<o;++i)if(n[i]in r)return!0;return!1},e.prototype.forEachFeatureAtCoordinate=function(n,t,r,i,o,s){i=Math.round(i);var a=i*2+1,f=df(this.hitDetectionTransform_,i+.5,i+.5,1/t,-1/t,-r,-n[0],-n[1]),g=!this.hitDetectionContext_;g&&(this.hitDetectionContext_=YA(a,a));var x=this.hitDetectionContext_;x.canvas.width!==a||x.canvas.height!==a?(x.canvas.width=a,x.canvas.height=a):g||x.clearRect(0,0,a,a);var k;this.renderBuffer_!==void 0&&(k=Ed(),kC(k,n),Em(k,t*(this.renderBuffer_+i),k));var B=Doe(i),P;function R(ae,ue){for(var ye=x.getImageData(0,0,a,a).data,Re=0,Ne=B.length;Re<Ne;Re++)if(ye[B[Re]]>0){if(!s||P!=="Image"&&P!=="Text"||s.indexOf(ae)!==-1){var rt=(B[Re]-3)/4,ct=i-rt%a,Fe=i-(rt/a|0),He=o(ae,ue,ct*ct+Fe*Fe);if(He)return He}x.clearRect(0,0,a,a);break}}var H=Object.keys(this.executorsByZIndex_).map(Number);H.sort(c1);var W,$,q,oe,ne;for(W=H.length-1;W>=0;--W){var ce=H[W].toString();for(q=this.executorsByZIndex_[ce],$=yM.length-1;$>=0;--$)if(P=yM[$],oe=q[P],oe!==void 0&&(ne=oe.executeHitDetection(x,f,r,R,k),ne))return ne}},e.prototype.getClipCoords=function(n){var t=this.maxExtent_;if(!t)return null;var r=t[0],i=t[1],o=t[2],s=t[3],a=[r,i,r,s,o,s,o,i];return Om(a,0,8,2,n,a),a},e.prototype.isEmpty=function(){return h1(this.executorsByZIndex_)},e.prototype.execute=function(n,t,r,i,o,s,a){var f=Object.keys(this.executorsByZIndex_).map(Number);f.sort(c1),this.maxExtent_&&(n.save(),this.clip(n,r));var g=s||yM,x,k,B,P,R,H;for(a&&f.reverse(),x=0,k=f.length;x<k;++x){var W=f[x].toString();for(R=this.executorsByZIndex_[W],B=0,P=g.length;B<P;++B){var $=g[B];H=R[$],H!==void 0&&H.execute(n,t,r,i,o,a)}}this.maxExtent_&&n.restore()},e}(),vM={};function Doe(e){if(vM[e]!==void 0)return vM[e];for(var n=e*2+1,t=e*e,r=new Array(t+1),i=0;i<=e;++i)for(var o=0;o<=e;++o){var s=i*i+o*o;if(s>t)break;var a=r[s];a||(a=[],r[s]=a),a.push(((e+i)*n+(e+o))*4+3),i>0&&a.push(((e-i)*n+(e+o))*4+3),o>0&&(a.push(((e+i)*n+(e-o))*4+3),i>0&&a.push(((e-i)*n+(e-o))*4+3))}for(var f=[],i=0,g=r.length;i<g;++i)r[i]&&f.push.apply(f,r[i]);return vM[e]=f,f}const P3=Foe;var Uoe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Roe=function(e){Uoe(n,e);function n(t,r,i,o,s,a,f){var g=e.call(this)||this;return g.context_=t,g.pixelRatio_=r,g.extent_=i,g.transform_=o,g.viewRotation_=s,g.squaredTolerance_=a,g.userTransform_=f,g.contextFillState_=null,g.contextStrokeState_=null,g.contextTextState_=null,g.fillState_=null,g.strokeState_=null,g.image_=null,g.imageAnchorX_=0,g.imageAnchorY_=0,g.imageHeight_=0,g.imageOpacity_=0,g.imageOriginX_=0,g.imageOriginY_=0,g.imageRotateWithView_=!1,g.imageRotation_=0,g.imageScale_=[0,0],g.imageWidth_=0,g.text_="",g.textOffsetX_=0,g.textOffsetY_=0,g.textRotateWithView_=!1,g.textRotation_=0,g.textScale_=[0,0],g.textFillState_=null,g.textStrokeState_=null,g.textState_=null,g.pixelCoordinates_=[],g.tmpLocalTransform_=xd(),g}return n.prototype.drawImages_=function(t,r,i,o){if(this.image_){var s=Om(t,r,i,o,this.transform_,this.pixelCoordinates_),a=this.context_,f=this.tmpLocalTransform_,g=a.globalAlpha;this.imageOpacity_!=1&&(a.globalAlpha=g*this.imageOpacity_);var x=this.imageRotation_;this.imageRotateWithView_&&(x+=this.viewRotation_);for(var k=0,B=s.length;k<B;k+=2){var P=s[k]-this.imageAnchorX_,R=s[k+1]-this.imageAnchorY_;if(x!==0||this.imageScale_[0]!=1||this.imageScale_[1]!=1){var H=P+this.imageAnchorX_,W=R+this.imageAnchorY_;df(f,H,W,1,1,x,-H,-W),a.setTransform.apply(a,f),a.translate(H,W),a.scale(this.imageScale_[0],this.imageScale_[1]),a.drawImage(this.image_,this.imageOriginX_,this.imageOriginY_,this.imageWidth_,this.imageHeight_,-this.imageAnchorX_,-this.imageAnchorY_,this.imageWidth_,this.imageHeight_),a.setTransform(1,0,0,1,0,0)}else a.drawImage(this.image_,this.imageOriginX_,this.imageOriginY_,this.imageWidth_,this.imageHeight_,P,R,this.imageWidth_,this.imageHeight_)}this.imageOpacity_!=1&&(a.globalAlpha=g)}},n.prototype.drawText_=function(t,r,i,o){if(!(!this.textState_||this.text_==="")){this.textFillState_&&this.setContextFillState_(this.textFillState_),this.textStrokeState_&&this.setContextStrokeState_(this.textStrokeState_),this.setContextTextState_(this.textState_);var s=Om(t,r,i,o,this.transform_,this.pixelCoordinates_),a=this.context_,f=this.textRotation_;for(this.textRotateWithView_&&(f+=this.viewRotation_);r<i;r+=o){var g=s[r]+this.textOffsetX_,x=s[r+1]+this.textOffsetY_;if(f!==0||this.textScale_[0]!=1||this.textScale_[1]!=1){var k=df(this.tmpLocalTransform_,g,x,1,1,f,-g,-x);a.setTransform.apply(a,k),a.translate(g,x),a.scale(this.textScale_[0],this.textScale_[1]),this.textStrokeState_&&a.strokeText(this.text_,0,0),this.textFillState_&&a.fillText(this.text_,0,0),a.setTransform(1,0,0,1,0,0)}else this.textStrokeState_&&a.strokeText(this.text_,g,x),this.textFillState_&&a.fillText(this.text_,g,x)}}},n.prototype.moveToLineTo_=function(t,r,i,o,s){var a=this.context_,f=Om(t,r,i,o,this.transform_,this.pixelCoordinates_);a.moveTo(f[0],f[1]);var g=f.length;s&&(g-=2);for(var x=2;x<g;x+=2)a.lineTo(f[x],f[x+1]);return s&&a.closePath(),i},n.prototype.drawRings_=function(t,r,i,o){for(var s=0,a=i.length;s<a;++s)r=this.moveToLineTo_(t,r,i[s],o,!0);return r},n.prototype.drawCircle=function(t){if(il(this.extent_,t.getExtent())){if(this.fillState_||this.strokeState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);var r=Ste(t,this.transform_,this.pixelCoordinates_),i=r[2]-r[0],o=r[3]-r[1],s=Math.sqrt(i*i+o*o),a=this.context_;a.beginPath(),a.arc(r[0],r[1],s,0,2*Math.PI),this.fillState_&&a.fill(),this.strokeState_&&a.stroke()}this.text_!==""&&this.drawText_(t.getCenter(),0,2,2)}},n.prototype.setStyle=function(t){this.setFillStrokeStyle(t.getFill(),t.getStroke()),this.setImageStyle(t.getImage()),this.setTextStyle(t.getText())},n.prototype.setTransform=function(t){this.transform_=t},n.prototype.drawGeometry=function(t){var r=t.getType();switch(r){case"Point":this.drawPoint(t);break;case"LineString":this.drawLineString(t);break;case"Polygon":this.drawPolygon(t);break;case"MultiPoint":this.drawMultiPoint(t);break;case"MultiLineString":this.drawMultiLineString(t);break;case"MultiPolygon":this.drawMultiPolygon(t);break;case"GeometryCollection":this.drawGeometryCollection(t);break;case"Circle":this.drawCircle(t);break}},n.prototype.drawFeature=function(t,r){var i=r.getGeometryFunction()(t);!i||!il(this.extent_,i.getExtent())||(this.setStyle(r),this.drawGeometry(i))},n.prototype.drawGeometryCollection=function(t){for(var r=t.getGeometriesArray(),i=0,o=r.length;i<o;++i)this.drawGeometry(r[i])},n.prototype.drawPoint=function(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));var r=t.getFlatCoordinates(),i=t.getStride();this.image_&&this.drawImages_(r,0,r.length,i),this.text_!==""&&this.drawText_(r,0,r.length,i)},n.prototype.drawMultiPoint=function(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));var r=t.getFlatCoordinates(),i=t.getStride();this.image_&&this.drawImages_(r,0,r.length,i),this.text_!==""&&this.drawText_(r,0,r.length,i)},n.prototype.drawLineString=function(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),!!il(this.extent_,t.getExtent())){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);var r=this.context_,i=t.getFlatCoordinates();r.beginPath(),this.moveToLineTo_(i,0,i.length,t.getStride(),!1),r.stroke()}if(this.text_!==""){var o=t.getFlatMidpoint();this.drawText_(o,0,2,2)}}},n.prototype.drawMultiLineString=function(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));var r=t.getExtent();if(il(this.extent_,r)){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);var i=this.context_,o=t.getFlatCoordinates(),s=0,a=t.getEnds(),f=t.getStride();i.beginPath();for(var g=0,x=a.length;g<x;++g)s=this.moveToLineTo_(o,s,a[g],f,!1);i.stroke()}if(this.text_!==""){var k=t.getFlatMidpoints();this.drawText_(k,0,k.length,2)}}},n.prototype.drawPolygon=function(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),!!il(this.extent_,t.getExtent())){if(this.strokeState_||this.fillState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);var r=this.context_;r.beginPath(),this.drawRings_(t.getOrientedFlatCoordinates(),0,t.getEnds(),t.getStride()),this.fillState_&&r.fill(),this.strokeState_&&r.stroke()}if(this.text_!==""){var i=t.getFlatInteriorPoint();this.drawText_(i,0,2,2)}}},n.prototype.drawMultiPolygon=function(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),!!il(this.extent_,t.getExtent())){if(this.strokeState_||this.fillState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);var r=this.context_,i=t.getOrientedFlatCoordinates(),o=0,s=t.getEndss(),a=t.getStride();r.beginPath();for(var f=0,g=s.length;f<g;++f){var x=s[f];o=this.drawRings_(i,o,x,a)}this.fillState_&&r.fill(),this.strokeState_&&r.stroke()}if(this.text_!==""){var k=t.getFlatInteriorPoints();this.drawText_(k,0,k.length,2)}}},n.prototype.setContextFillState_=function(t){var r=this.context_,i=this.contextFillState_;i?i.fillStyle!=t.fillStyle&&(i.fillStyle=t.fillStyle,r.fillStyle=t.fillStyle):(r.fillStyle=t.fillStyle,this.contextFillState_={fillStyle:t.fillStyle})},n.prototype.setContextStrokeState_=function(t){var r=this.context_,i=this.contextStrokeState_;i?(i.lineCap!=t.lineCap&&(i.lineCap=t.lineCap,r.lineCap=t.lineCap),r.setLineDash&&(_1(i.lineDash,t.lineDash)||r.setLineDash(i.lineDash=t.lineDash),i.lineDashOffset!=t.lineDashOffset&&(i.lineDashOffset=t.lineDashOffset,r.lineDashOffset=t.lineDashOffset)),i.lineJoin!=t.lineJoin&&(i.lineJoin=t.lineJoin,r.lineJoin=t.lineJoin),i.lineWidth!=t.lineWidth&&(i.lineWidth=t.lineWidth,r.lineWidth=t.lineWidth),i.miterLimit!=t.miterLimit&&(i.miterLimit=t.miterLimit,r.miterLimit=t.miterLimit),i.strokeStyle!=t.strokeStyle&&(i.strokeStyle=t.strokeStyle,r.strokeStyle=t.strokeStyle)):(r.lineCap=t.lineCap,r.setLineDash&&(r.setLineDash(t.lineDash),r.lineDashOffset=t.lineDashOffset),r.lineJoin=t.lineJoin,r.lineWidth=t.lineWidth,r.miterLimit=t.miterLimit,r.strokeStyle=t.strokeStyle,this.contextStrokeState_={lineCap:t.lineCap,lineDash:t.lineDash,lineDashOffset:t.lineDashOffset,lineJoin:t.lineJoin,lineWidth:t.lineWidth,miterLimit:t.miterLimit,strokeStyle:t.strokeStyle})},n.prototype.setContextTextState_=function(t){var r=this.context_,i=this.contextTextState_,o=t.textAlign?t.textAlign:g_;i?(i.font!=t.font&&(i.font=t.font,r.font=t.font),i.textAlign!=o&&(i.textAlign=o,r.textAlign=o),i.textBaseline!=t.textBaseline&&(i.textBaseline=t.textBaseline,r.textBaseline=t.textBaseline)):(r.font=t.font,r.textAlign=o,r.textBaseline=t.textBaseline,this.contextTextState_={font:t.font,textAlign:o,textBaseline:t.textBaseline})},n.prototype.setFillStrokeStyle=function(t,r){var i=this;if(!t)this.fillState_=null;else{var o=t.getColor();this.fillState_={fillStyle:tf(o||bp)}}if(!r)this.strokeState_=null;else{var s=r.getColor(),a=r.getLineCap(),f=r.getLineDash(),g=r.getLineDashOffset(),x=r.getLineJoin(),k=r.getWidth(),B=r.getMiterLimit(),P=f||h_;this.strokeState_={lineCap:a!==void 0?a:B3,lineDash:this.pixelRatio_===1?P:P.map(function(R){return R*i.pixelRatio_}),lineDashOffset:(g||f_)*this.pixelRatio_,lineJoin:x!==void 0?x:My,lineWidth:(k!==void 0?k:y_)*this.pixelRatio_,miterLimit:B!==void 0?B:p_,strokeStyle:tf(s||m_)}}},n.prototype.setImageStyle=function(t){var r;if(!t||!(r=t.getSize())){this.image_=null;return}var i=t.getAnchor(),o=t.getOrigin();this.image_=t.getImage(this.pixelRatio_),this.imageAnchorX_=i[0]*this.pixelRatio_,this.imageAnchorY_=i[1]*this.pixelRatio_,this.imageHeight_=r[1]*this.pixelRatio_,this.imageOpacity_=t.getOpacity(),this.imageOriginX_=o[0],this.imageOriginY_=o[1],this.imageRotateWithView_=t.getRotateWithView(),this.imageRotation_=t.getRotation(),this.imageScale_=t.getScaleArray(),this.imageWidth_=r[0]*this.pixelRatio_},n.prototype.setTextStyle=function(t){if(!t)this.text_="";else{var r=t.getFill();if(!r)this.textFillState_=null;else{var i=r.getColor();this.textFillState_={fillStyle:tf(i||bp)}}var o=t.getStroke();if(!o)this.textStrokeState_=null;else{var s=o.getColor(),a=o.getLineCap(),f=o.getLineDash(),g=o.getLineDashOffset(),x=o.getLineJoin(),k=o.getWidth(),B=o.getMiterLimit();this.textStrokeState_={lineCap:a!==void 0?a:B3,lineDash:f||h_,lineDashOffset:g||f_,lineJoin:x!==void 0?x:My,lineWidth:k!==void 0?k:y_,miterLimit:B!==void 0?B:p_,strokeStyle:tf(s||m_)}}var P=t.getFont(),R=t.getOffsetX(),H=t.getOffsetY(),W=t.getRotateWithView(),$=t.getRotation(),q=t.getScaleArray(),oe=t.getText(),ne=t.getTextAlign(),ce=t.getTextBaseline();this.textState_={font:P!==void 0?P:qL,textAlign:ne!==void 0?ne:g_,textBaseline:ce!==void 0?ce:k3},this.text_=oe!==void 0?Array.isArray(oe)?oe.reduce(function(ae,ue,ye){return ae+=ye%2?" ":ue},""):oe:"",this.textOffsetX_=R!==void 0?this.pixelRatio_*R:0,this.textOffsetY_=H!==void 0?this.pixelRatio_*H:0,this.textRotateWithView_=W!==void 0?W:!1,this.textRotation_=$!==void 0?$:0,this.textScale_=[this.pixelRatio_*q[0],this.pixelRatio_*q[1]]}},n}(dz);const tm={FRACTION:"fraction",PIXELS:"pixels"},hd={BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",TOP_LEFT:"top-left",TOP_RIGHT:"top-right"};var Loe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),zoe=function(e){Loe(n,e);function n(t,r,i,o){var s=e.call(this)||this;return s.extent=t,s.pixelRatio_=i,s.resolution=r,s.state=o,s}return n.prototype.changed=function(){this.dispatchEvent(ki.CHANGE)},n.prototype.getExtent=function(){return this.extent},n.prototype.getImage=function(){return li()},n.prototype.getPixelRatio=function(){return this.pixelRatio_},n.prototype.getResolution=function(){return this.resolution},n.prototype.getState=function(){return this.state},n.prototype.load=function(){li()},n}(zy);const joe=zoe;var Woe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}();(function(e){Woe(n,e);function n(t,r,i,o,s,a){var f=e.call(this,t,r,i,Na.IDLE)||this;return f.src_=o,f.image_=new Image,s!==null&&(f.image_.crossOrigin=s),f.unlisten_=null,f.state=Na.IDLE,f.imageLoadFunction_=a,f}return n.prototype.getImage=function(){return this.image_},n.prototype.handleImageError_=function(){this.state=Na.ERROR,this.unlistenImage_(),this.changed()},n.prototype.handleImageLoad_=function(){this.resolution===void 0&&(this.resolution=$A(this.extent)/this.image_.height),this.state=Na.LOADED,this.unlistenImage_(),this.changed()},n.prototype.load=function(){(this.state==Na.IDLE||this.state==Na.ERROR)&&(this.state=Na.LOADING,this.changed(),this.imageLoadFunction_(this,this.src_),this.unlisten_=m7(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))},n.prototype.setImage=function(t){this.image_=t,this.resolution=$A(this.extent)/this.image_.height},n.prototype.unlistenImage_=function(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)},n})(joe);function m7(e,n,t){var r=e,i=!0,o=!1,s=!1,a=[v3(r,ki.LOAD,function(){s=!0,o||n()})];return r.src&&Bee?(o=!0,r.decode().then(function(){i&&n()}).catch(function(f){i&&(s?n():t())})):a.push(v3(r,ki.ERROR,t)),function(){i=!1,a.forEach(Ga)}}var Noe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Nv=null,Goe=function(e){Noe(n,e);function n(t,r,i,o,s,a){var f=e.call(this)||this;return f.hitDetectionImage_=null,f.image_=t||new Image,o!==null&&(f.image_.crossOrigin=o),f.canvas_={},f.color_=a,f.unlisten_=null,f.imageState_=s,f.size_=i,f.src_=r,f.tainted_,f}return n.prototype.isTainted_=function(){if(this.tainted_===void 0&&this.imageState_===Na.LOADED){Nv||(Nv=YA(1,1)),Nv.drawImage(this.image_,0,0);try{Nv.getImageData(0,0,1,1),this.tainted_=!1}catch{Nv=null,this.tainted_=!0}}return this.tainted_===!0},n.prototype.dispatchChangeEvent_=function(){this.dispatchEvent(ki.CHANGE)},n.prototype.handleImageError_=function(){this.imageState_=Na.ERROR,this.unlistenImage_(),this.dispatchChangeEvent_()},n.prototype.handleImageLoad_=function(){this.imageState_=Na.LOADED,this.size_?(this.image_.width=this.size_[0],this.image_.height=this.size_[1]):this.size_=[this.image_.width,this.image_.height],this.unlistenImage_(),this.dispatchChangeEvent_()},n.prototype.getImage=function(t){return this.replaceColor_(t),this.canvas_[t]?this.canvas_[t]:this.image_},n.prototype.getPixelRatio=function(t){return this.replaceColor_(t),this.canvas_[t]?t:1},n.prototype.getImageState=function(){return this.imageState_},n.prototype.getHitDetectionImage=function(){if(!this.hitDetectionImage_)if(this.isTainted_()){var t=this.size_[0],r=this.size_[1],i=YA(t,r);i.fillRect(0,0,t,r),this.hitDetectionImage_=i.canvas}else this.hitDetectionImage_=this.image_;return this.hitDetectionImage_},n.prototype.getSize=function(){return this.size_},n.prototype.getSrc=function(){return this.src_},n.prototype.load=function(){if(this.imageState_==Na.IDLE){this.imageState_=Na.LOADING;try{this.image_.src=this.src_}catch{this.handleImageError_()}this.unlisten_=m7(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this))}},n.prototype.replaceColor_=function(t){if(!(!this.color_||this.canvas_[t]||this.imageState_!==Na.LOADED)){var r=document.createElement("canvas");this.canvas_[t]=r,r.width=Math.ceil(this.image_.width*t),r.height=Math.ceil(this.image_.height*t);var i=r.getContext("2d");if(i.scale(t,t),i.drawImage(this.image_,0,0),i.globalCompositeOperation="multiply",i.globalCompositeOperation==="multiply"||this.isTainted_())i.fillStyle=WL(this.color_),i.fillRect(0,0,r.width/t,r.height/t),i.globalCompositeOperation="destination-in",i.drawImage(this.image_,0,0);else{for(var o=i.getImageData(0,0,r.width,r.height),s=o.data,a=this.color_[0]/255,f=this.color_[1]/255,g=this.color_[2]/255,x=this.color_[3],k=0,B=s.length;k<B;k+=4)s[k]*=a,s[k+1]*=f,s[k+2]*=g,s[k+3]*=x;i.putImageData(o,0,0)}}},n.prototype.unlistenImage_=function(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)},n}(zy);function Qoe(e,n,t,r,i,o){var s=S3.get(n,r,o);return s||(s=new Goe(e,n,t,r,i,o),S3.set(n,r,o,s)),s}var $oe=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Yoe=function(e){$oe(n,e);function n(t){var r=this,i=t||{},o=i.opacity!==void 0?i.opacity:1,s=i.rotation!==void 0?i.rotation:0,a=i.scale!==void 0?i.scale:1,f=i.rotateWithView!==void 0?i.rotateWithView:!1;r=e.call(this,{opacity:o,rotation:s,scale:a,displacement:i.displacement!==void 0?i.displacement:[0,0],rotateWithView:f,declutterMode:i.declutterMode})||this,r.anchor_=i.anchor!==void 0?i.anchor:[.5,.5],r.normalizedAnchor_=null,r.anchorOrigin_=i.anchorOrigin!==void 0?i.anchorOrigin:hd.TOP_LEFT,r.anchorXUnits_=i.anchorXUnits!==void 0?i.anchorXUnits:tm.FRACTION,r.anchorYUnits_=i.anchorYUnits!==void 0?i.anchorYUnits:tm.FRACTION,r.crossOrigin_=i.crossOrigin!==void 0?i.crossOrigin:null;var g=i.img!==void 0?i.img:null;r.imgSize_=i.imgSize;var x=i.src;ao(!(x!==void 0&&g),4),ao(!g||g&&r.imgSize_,5),(x===void 0||x.length===0)&&g&&(x=g.src||$i(g)),ao(x!==void 0&&x.length>0,6);var k=i.src!==void 0?Na.IDLE:Na.LOADED;return r.color_=i.color!==void 0?M3(i.color):null,r.iconImage_=Qoe(g,x,r.imgSize_!==void 0?r.imgSize_:null,r.crossOrigin_,k,r.color_),r.offset_=i.offset!==void 0?i.offset:[0,0],r.offsetOrigin_=i.offsetOrigin!==void 0?i.offsetOrigin:hd.TOP_LEFT,r.origin_=null,r.size_=i.size!==void 0?i.size:null,r}return n.prototype.clone=function(){var t=this.getScale();return new n({anchor:this.anchor_.slice(),anchorOrigin:this.anchorOrigin_,anchorXUnits:this.anchorXUnits_,anchorYUnits:this.anchorYUnits_,color:this.color_&&this.color_.slice?this.color_.slice():this.color_||void 0,crossOrigin:this.crossOrigin_,imgSize:this.imgSize_,offset:this.offset_.slice(),offsetOrigin:this.offsetOrigin_,opacity:this.getOpacity(),rotateWithView:this.getRotateWithView(),rotation:this.getRotation(),scale:Array.isArray(t)?t.slice():t,size:this.size_!==null?this.size_.slice():void 0,src:this.getSrc(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})},n.prototype.getAnchor=function(){var t=this.normalizedAnchor_;if(!t){t=this.anchor_;var r=this.getSize();if(this.anchorXUnits_==tm.FRACTION||this.anchorYUnits_==tm.FRACTION){if(!r)return null;t=this.anchor_.slice(),this.anchorXUnits_==tm.FRACTION&&(t[0]*=r[0]),this.anchorYUnits_==tm.FRACTION&&(t[1]*=r[1])}if(this.anchorOrigin_!=hd.TOP_LEFT){if(!r)return null;t===this.anchor_&&(t=this.anchor_.slice()),(this.anchorOrigin_==hd.TOP_RIGHT||this.anchorOrigin_==hd.BOTTOM_RIGHT)&&(t[0]=-t[0]+r[0]),(this.anchorOrigin_==hd.BOTTOM_LEFT||this.anchorOrigin_==hd.BOTTOM_RIGHT)&&(t[1]=-t[1]+r[1])}this.normalizedAnchor_=t}var i=this.getDisplacement();return[t[0]-i[0],t[1]+i[1]]},n.prototype.setAnchor=function(t){this.anchor_=t,this.normalizedAnchor_=null},n.prototype.getColor=function(){return this.color_},n.prototype.getImage=function(t){return this.iconImage_.getImage(t)},n.prototype.getPixelRatio=function(t){return this.iconImage_.getPixelRatio(t)},n.prototype.getImageSize=function(){return this.iconImage_.getSize()},n.prototype.getImageState=function(){return this.iconImage_.getImageState()},n.prototype.getHitDetectionImage=function(){return this.iconImage_.getHitDetectionImage()},n.prototype.getOrigin=function(){if(this.origin_)return this.origin_;var t=this.offset_;if(this.offsetOrigin_!=hd.TOP_LEFT){var r=this.getSize(),i=this.iconImage_.getSize();if(!r||!i)return null;t=t.slice(),(this.offsetOrigin_==hd.TOP_RIGHT||this.offsetOrigin_==hd.BOTTOM_RIGHT)&&(t[0]=i[0]-r[0]-t[0]),(this.offsetOrigin_==hd.BOTTOM_LEFT||this.offsetOrigin_==hd.BOTTOM_RIGHT)&&(t[1]=i[1]-r[1]-t[1])}return this.origin_=t,this.origin_},n.prototype.getSrc=function(){return this.iconImage_.getSrc()},n.prototype.getSize=function(){return this.size_?this.size_:this.iconImage_.getSize()},n.prototype.listenImageChange=function(t){this.iconImage_.addEventListener(ki.CHANGE,t)},n.prototype.load=function(){this.iconImage_.load()},n.prototype.unlistenImageChange=function(t){this.iconImage_.removeEventListener(ki.CHANGE,t)},n}(uz);const pz=Yoe;var qoe="#333",Voe=function(){function e(n){var t=n||{};this.font_=t.font,this.rotation_=t.rotation,this.rotateWithView_=t.rotateWithView,this.scale_=t.scale,this.scaleArray_=pA(t.scale!==void 0?t.scale:1),this.text_=t.text,this.textAlign_=t.textAlign,this.justify_=t.justify,this.textBaseline_=t.textBaseline,this.fill_=t.fill!==void 0?t.fill:new Ug({color:qoe}),this.maxAngle_=t.maxAngle!==void 0?t.maxAngle:Math.PI/4,this.placement_=t.placement!==void 0?t.placement:hz.POINT,this.overflow_=!!t.overflow,this.stroke_=t.stroke!==void 0?t.stroke:null,this.offsetX_=t.offsetX!==void 0?t.offsetX:0,this.offsetY_=t.offsetY!==void 0?t.offsetY:0,this.backgroundFill_=t.backgroundFill?t.backgroundFill:null,this.backgroundStroke_=t.backgroundStroke?t.backgroundStroke:null,this.padding_=t.padding===void 0?null:t.padding}return e.prototype.clone=function(){var n=this.getScale();return new e({font:this.getFont(),placement:this.getPlacement(),maxAngle:this.getMaxAngle(),overflow:this.getOverflow(),rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(n)?n.slice():n,text:this.getText(),textAlign:this.getTextAlign(),justify:this.getJustify(),textBaseline:this.getTextBaseline(),fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,offsetX:this.getOffsetX(),offsetY:this.getOffsetY(),backgroundFill:this.getBackgroundFill()?this.getBackgroundFill().clone():void 0,backgroundStroke:this.getBackgroundStroke()?this.getBackgroundStroke().clone():void 0,padding:this.getPadding()||void 0})},e.prototype.getOverflow=function(){return this.overflow_},e.prototype.getFont=function(){return this.font_},e.prototype.getMaxAngle=function(){return this.maxAngle_},e.prototype.getPlacement=function(){return this.placement_},e.prototype.getOffsetX=function(){return this.offsetX_},e.prototype.getOffsetY=function(){return this.offsetY_},e.prototype.getFill=function(){return this.fill_},e.prototype.getRotateWithView=function(){return this.rotateWithView_},e.prototype.getRotation=function(){return this.rotation_},e.prototype.getScale=function(){return this.scale_},e.prototype.getScaleArray=function(){return this.scaleArray_},e.prototype.getStroke=function(){return this.stroke_},e.prototype.getText=function(){return this.text_},e.prototype.getTextAlign=function(){return this.textAlign_},e.prototype.getJustify=function(){return this.justify_},e.prototype.getTextBaseline=function(){return this.textBaseline_},e.prototype.getBackgroundFill=function(){return this.backgroundFill_},e.prototype.getBackgroundStroke=function(){return this.backgroundStroke_},e.prototype.getPadding=function(){return this.padding_},e.prototype.setOverflow=function(n){this.overflow_=n},e.prototype.setFont=function(n){this.font_=n},e.prototype.setMaxAngle=function(n){this.maxAngle_=n},e.prototype.setOffsetX=function(n){this.offsetX_=n},e.prototype.setOffsetY=function(n){this.offsetY_=n},e.prototype.setPlacement=function(n){this.placement_=n},e.prototype.setRotateWithView=function(n){this.rotateWithView_=n},e.prototype.setFill=function(n){this.fill_=n},e.prototype.setRotation=function(n){this.rotation_=n},e.prototype.setScale=function(n){this.scale_=n,this.scaleArray_=pA(n!==void 0?n:1)},e.prototype.setStroke=function(n){this.stroke_=n},e.prototype.setText=function(n){this.text_=n},e.prototype.setTextAlign=function(n){this.textAlign_=n},e.prototype.setJustify=function(n){this.justify_=n},e.prototype.setTextBaseline=function(n){this.textBaseline_=n},e.prototype.setBackgroundFill=function(n){this.backgroundFill_=n},e.prototype.setBackgroundStroke=function(n){this.backgroundStroke_=n},e.prototype.setPadding=function(n){this.padding_=n},e}(),Dc=.5;function mz(e,n,t,r,i,o,s){var a=e[0]*Dc,f=e[1]*Dc,g=YA(a,f);g.imageSmoothingEnabled=!1;for(var x=g.canvas,k=new Roe(g,Dc,i,null,s),B=t.length,P=Math.floor((256*256*256-1)/B),R={},H=1;H<=B;++H){var W=t[H-1],$=W.getStyleFunction()||r;if(r){var q=$(W,o);if(q){Array.isArray(q)||(q=[q]);for(var oe=H*P,ne="#"+("000000"+oe.toString(16)).slice(-6),ce=0,ae=q.length;ce<ae;++ce){var ue=q[ce],ye=ue.getGeometryFunction()(W);if(!(!ye||!il(i,ye.getExtent()))){var Re=ue.clone(),Ne=Re.getFill();Ne&&Ne.setColor(ne);var rt=Re.getStroke();rt&&(rt.setColor(ne),rt.setLineDash(null)),Re.setText(void 0);var ct=ue.getImage();if(ct&&ct.getOpacity()!==0){var Fe=ct.getImageSize();if(!Fe)continue;var He=YA(Fe[0],Fe[1],void 0,{alpha:!1}),Ce=He.canvas;He.fillStyle=ne,He.fillRect(0,0,Ce.width,Ce.height),Re.setImage(new pz({img:Ce,imgSize:Fe,anchor:ct.getAnchor(),anchorXUnits:tm.PIXELS,anchorYUnits:tm.PIXELS,offset:ct.getOrigin(),opacity:1,size:ct.getSize(),scale:ct.getScale(),rotation:ct.getRotation(),rotateWithView:ct.getRotateWithView()}))}var jt=Re.getZIndex()||0,Ft=R[jt];Ft||(Ft={},R[jt]=Ft,Ft.Polygon=[],Ft.Circle=[],Ft.LineString=[],Ft.Point=[]),Ft[ye.getType().replace("Multi","")].push(ye,Re)}}}}}for(var Jt=Object.keys(R).map(Number).sort(c1),H=0,Nt=Jt.length;H<Nt;++H){var Ft=R[Jt[H]];for(var Ve in Ft)for(var nt=Ft[Ve],ce=0,ae=nt.length;ce<ae;ce+=2){k.setStyle(nt[ce+1]);for(var Je=0,Vt=n.length;Je<Vt;++Je)k.setTransform(n[Je]),k.drawGeometry(nt[ce])}}return g.getImageData(0,0,x.width,x.height)}function gz(e,n,t){var r=[];if(t){var i=Math.floor(Math.round(e[0])*Dc),o=Math.floor(Math.round(e[1])*Dc),s=(vl(i,0,t.width-1)+vl(o,0,t.height-1)*t.width)*4,a=t.data[s],f=t.data[s+1],g=t.data[s+2],x=g+256*(f+256*a),k=Math.floor((256*256*256-1)/n.length);x&&x%k===0&&r.push(n[x/k-1])}return r}var Hoe=.5,yz={Point:iae,LineString:tae,Polygon:aae,MultiPoint:oae,MultiLineString:nae,MultiPolygon:rae,GeometryCollection:eae,Circle:Xoe};function Zoe(e,n){return parseInt($i(e),10)-parseInt($i(n),10)}function vz(e,n){var t=iE(e,n);return t*t}function iE(e,n){return Hoe*e/n}function Xoe(e,n,t,r,i){var o=t.getFill(),s=t.getStroke();if(o||s){var a=e.getBuilder(t.getZIndex(),"Circle");a.setFillStrokeStyle(o,s),a.drawCircle(n,r)}var f=t.getText();if(f&&f.getText()){var g=(i||e).getBuilder(t.getZIndex(),"Text");g.setTextStyle(f),g.drawText(n,r)}}function F3(e,n,t,r,i,o,s){var a=!1,f=t.getImage();if(f){var g=f.getImageState();g==Na.LOADED||g==Na.ERROR?f.unlistenImageChange(i):(g==Na.IDLE&&f.load(),f.listenImageChange(i),a=!0)}return Joe(e,n,t,r,o,s),a}function Joe(e,n,t,r,i,o){var s=t.getGeometryFunction()(n);if(s){var a=s.simplifyTransformed(r,i),f=t.getRenderer();if(f)Cz(e,a,t,n);else{var g=yz[a.getType()];g(e,a,t,n,o)}}}function Cz(e,n,t,r){if(n.getType()=="GeometryCollection"){for(var i=n.getGeometries(),o=0,s=i.length;o<s;++o)Cz(e,i[o],t,r);return}var a=e.getBuilder(t.getZIndex(),"Default");a.drawCustom(n,r,t.getRenderer(),t.getHitDetectionRenderer())}function eae(e,n,t,r,i){var o=n.getGeometriesArray(),s,a;for(s=0,a=o.length;s<a;++s){var f=yz[o[s].getType()];f(e,o[s],t,r,i)}}function tae(e,n,t,r,i){var o=t.getStroke();if(o){var s=e.getBuilder(t.getZIndex(),"LineString");s.setFillStrokeStyle(null,o),s.drawLineString(n,r)}var a=t.getText();if(a&&a.getText()){var f=(i||e).getBuilder(t.getZIndex(),"Text");f.setTextStyle(a),f.drawText(n,r)}}function nae(e,n,t,r,i){var o=t.getStroke();if(o){var s=e.getBuilder(t.getZIndex(),"LineString");s.setFillStrokeStyle(null,o),s.drawMultiLineString(n,r)}var a=t.getText();if(a&&a.getText()){var f=(i||e).getBuilder(t.getZIndex(),"Text");f.setTextStyle(a),f.drawText(n,r)}}function rae(e,n,t,r,i){var o=t.getFill(),s=t.getStroke();if(s||o){var a=e.getBuilder(t.getZIndex(),"Polygon");a.setFillStrokeStyle(o,s),a.drawMultiPolygon(n,r)}var f=t.getText();if(f&&f.getText()){var g=(i||e).getBuilder(t.getZIndex(),"Text");g.setTextStyle(f),g.drawText(n,r)}}function iae(e,n,t,r,i){var o=t.getImage(),s=t.getText(),a;if(o){if(o.getImageState()!=Na.LOADED)return;var f=e;if(i){var g=o.getDeclutterMode();if(g!=="none")if(f=i,g==="obstacle"){var x=e.getBuilder(t.getZIndex(),"Image");x.setImageStyle(o,a),x.drawPoint(n,r)}else s&&s.getText()&&(a={})}var k=f.getBuilder(t.getZIndex(),"Image");k.setImageStyle(o,a),k.drawPoint(n,r)}if(s&&s.getText()){var B=e;i&&(B=i);var P=B.getBuilder(t.getZIndex(),"Text");P.setTextStyle(s,a),P.drawText(n,r)}}function oae(e,n,t,r,i){var o=t.getImage(),s=t.getText(),a;if(o){if(o.getImageState()!=Na.LOADED)return;var f=e;if(i){var g=o.getDeclutterMode();if(g!=="none")if(f=i,g==="obstacle"){var x=e.getBuilder(t.getZIndex(),"Image");x.setImageStyle(o,a),x.drawMultiPoint(n,r)}else s&&s.getText()&&(a={})}var k=f.getBuilder(t.getZIndex(),"Image");k.setImageStyle(o,a),k.drawMultiPoint(n,r)}if(s&&s.getText()){var B=e;i&&(B=i);var P=B.getBuilder(t.getZIndex(),"Text");P.setTextStyle(s,a),P.drawText(n,r)}}function aae(e,n,t,r,i){var o=t.getFill(),s=t.getStroke();if(o||s){var a=e.getBuilder(t.getZIndex(),"Polygon");a.setFillStrokeStyle(o,s),a.drawPolygon(n,r)}var f=t.getText();if(f&&f.getText()){var g=(i||e).getBuilder(t.getZIndex(),"Text");g.setTextStyle(f),g.drawText(n,r)}}var sae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),lae=function(e){sae(n,e);function n(t){var r=e.call(this,t)||this;return r.boundHandleStyleImageChange_=r.handleStyleImageChange_.bind(r),r.animatingOrInteracting_,r.hitDetectionImageData_=null,r.renderedFeatures_=null,r.renderedRevision_=-1,r.renderedResolution_=NaN,r.renderedExtent_=Ed(),r.wrappedRenderedExtent_=Ed(),r.renderedRotation_,r.renderedCenter_=null,r.renderedProjection_=null,r.renderedRenderOrder_=null,r.replayGroup_=null,r.replayGroupChanged=!0,r.declutterExecutorGroup=null,r.clipping=!0,r.compositionContext_=null,r.opacity_=1,r}return n.prototype.renderWorlds=function(t,r,i){var o=r.extent,s=r.viewState,a=s.center,f=s.resolution,g=s.projection,x=s.rotation,k=g.getExtent(),B=this.getLayer().getSource(),P=r.pixelRatio,R=r.viewHints,H=!(R[Gs.ANIMATING]||R[Gs.INTERACTING]),W=this.compositionContext_,$=Math.round(r.size[0]*P),q=Math.round(r.size[1]*P),oe=B.getWrapX()&&g.canWrapX(),ne=oe?os(k):null,ce=oe?Math.ceil((o[2]-k[2])/ne)+1:1,ae=oe?Math.floor((o[0]-k[0])/ne):0;do{var ue=this.getRenderTransform(a,f,x,P,$,q,ae*ne);t.execute(W,1,ue,x,H,void 0,i)}while(++ae<ce)},n.prototype.setupCompositionContext_=function(){if(this.opacity_!==1){var t=YA(this.context.canvas.width,this.context.canvas.height,L9);this.compositionContext_=t}else this.compositionContext_=this.context},n.prototype.releaseCompositionContext_=function(){if(this.opacity_!==1){var t=this.context.globalAlpha;this.context.globalAlpha=this.opacity_,this.context.drawImage(this.compositionContext_.canvas,0,0),this.context.globalAlpha=t,l7(this.compositionContext_),L9.push(this.compositionContext_.canvas),this.compositionContext_=null}},n.prototype.renderDeclutter=function(t){this.declutterExecutorGroup&&(this.setupCompositionContext_(),this.renderWorlds(this.declutterExecutorGroup,t,t.declutterTree),this.releaseCompositionContext_())},n.prototype.renderFrame=function(t,r){var i=t.pixelRatio,o=t.layerStatesArray[t.layerIndex];Iee(this.pixelTransform,1/i,1/i),zB(this.inversePixelTransform,this.pixelTransform);var s=fL(this.pixelTransform);this.useContainer(r,s,this.getBackground(t));var a=this.context,f=a.canvas,g=this.replayGroup_,x=this.declutterExecutorGroup;if((!g||g.isEmpty())&&(!x||x.isEmpty()))return null;var k=Math.round(t.size[0]*i),B=Math.round(t.size[1]*i);f.width!=k||f.height!=B?(f.width=k,f.height=B,f.style.transform!==s&&(f.style.transform=s)):this.containerReused||a.clearRect(0,0,k,B),this.preRender(a,t);var P=t.viewState;P.projection,this.opacity_=o.opacity,this.setupCompositionContext_();var R=!1,H=!0;if(o.extent&&this.clipping){var W=j0(o.extent);H=il(W,t.extent),R=H&&!cm(W,t.extent),R&&this.clipUnrotated(this.compositionContext_,t,W)}return H&&this.renderWorlds(g,t),R&&this.compositionContext_.restore(),this.releaseCompositionContext_(),this.postRender(a,t),this.renderedRotation_!==P.rotation&&(this.renderedRotation_=P.rotation,this.hitDetectionImageData_=null),this.container},n.prototype.getFeatures=function(t){return new Promise((function(r){if(!this.hitDetectionImageData_&&!this.animatingOrInteracting_){var i=[this.context.canvas.width,this.context.canvas.height];rl(this.pixelTransform,i);var o=this.renderedCenter_,s=this.renderedResolution_,a=this.renderedRotation_,f=this.renderedProjection_,g=this.wrappedRenderedExtent_,x=this.getLayer(),k=[],B=i[0]*Dc,P=i[1]*Dc;k.push(this.getRenderTransform(o,s,a,Dc,B,P,0).slice());var R=x.getSource(),H=f.getExtent();if(R.getWrapX()&&f.canWrapX()&&!cm(H,g)){for(var W=g[0],$=os(H),q=0,oe=void 0;W<H[0];)--q,oe=$*q,k.push(this.getRenderTransform(o,s,a,Dc,B,P,oe).slice()),W+=$;for(q=0,W=g[2];W>H[2];)++q,oe=$*q,k.push(this.getRenderTransform(o,s,a,Dc,B,P,oe).slice()),W-=$}this.hitDetectionImageData_=mz(i,k,this.renderedFeatures_,x.getStyleFunction(),g,s,a)}r(gz(t,this.renderedFeatures_,this.hitDetectionImageData_))}).bind(this))},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s){var a=this;if(this.replayGroup_){var f=r.viewState.resolution,g=r.viewState.rotation,x=this.getLayer(),k={},B=function(H,W,$){var q=$i(H),oe=k[q];if(oe){if(oe!==!0&&$<oe.distanceSq){if($===0)return k[q]=!0,s.splice(s.lastIndexOf(oe),1),o(H,x,W);oe.geometry=W,oe.distanceSq=$}}else{if($===0)return k[q]=!0,o(H,x,W);s.push(k[q]={feature:H,layer:x,geometry:W,distanceSq:$,callback:o})}},P,R=[this.replayGroup_];return this.declutterExecutorGroup&&R.push(this.declutterExecutorGroup),R.some(function(H){return P=H.forEachFeatureAtCoordinate(t,f,g,i,B,H===a.declutterExecutorGroup&&r.declutterTree?r.declutterTree.all().map(function(W){return W.value}):null)}),P}},n.prototype.handleFontsChanged=function(){var t=this.getLayer();t.getVisible()&&this.replayGroup_&&t.changed()},n.prototype.handleStyleImageChange_=function(t){this.renderIfReadyAndVisible()},n.prototype.prepareFrame=function(t){var r=this.getLayer(),i=r.getSource();if(!i)return!1;var o=t.viewHints[Gs.ANIMATING],s=t.viewHints[Gs.INTERACTING],a=r.getUpdateWhileAnimating(),f=r.getUpdateWhileInteracting();if(this.ready&&!a&&o||!f&&s)return this.animatingOrInteracting_=!0,!0;this.animatingOrInteracting_=!1;var g=t.extent,x=t.viewState,k=x.projection,B=x.resolution,P=t.pixelRatio,R=r.getRevision(),H=r.getRenderBuffer(),W=r.getRenderOrder();W===void 0&&(W=Zoe);var $=x.center.slice(),q=Em(g,H*B),oe=q.slice(),ne=[q.slice()],ce=k.getExtent();if(i.getWrapX()&&k.canWrapX()&&!cm(ce,t.extent)){var ae=os(ce),ue=Math.max(os(q)/2,ae);q[0]=ce[0]-ue,q[2]=ce[2]+ue,$B($,k);var ye=CL(ne[0],k);ye[0]<ce[0]&&ye[2]<ce[2]?ne.push([ye[0]+ae,ye[1],ye[2]+ae,ye[3]]):ye[0]>ce[0]&&ye[2]>ce[2]&&ne.push([ye[0]-ae,ye[1],ye[2]-ae,ye[3]])}if(this.ready&&this.renderedResolution_==B&&this.renderedRevision_==R&&this.renderedRenderOrder_==W&&cm(this.wrappedRenderedExtent_,q))return _1(this.renderedExtent_,oe)||(this.hitDetectionImageData_=null,this.renderedExtent_=oe),this.renderedCenter_=$,this.replayGroupChanged=!1,!0;this.replayGroup_=null;var Re=new K3(iE(B,P),q,B,P),Ne;this.getLayer().getDeclutter()&&(Ne=new K3(iE(B,P),q,B,P));for(var rt,ct,Fe,ct=0,Fe=ne.length;ct<Fe;++ct)i.loadFeatures(ne[ct],B,k);var He=vz(B,P),Ce=!0,jt=(function(nt){var Je,Vt=nt.getStyleFunction()||r.getStyleFunction();if(Vt&&(Je=Vt(nt,B)),Je){var pt=this.renderFeature(nt,He,Je,Re,rt,Ne);Ce=Ce&&!pt}}).bind(this),Ft=wL(q),Jt=i.getFeaturesInExtent(Ft);W&&Jt.sort(W);for(var ct=0,Fe=Jt.length;ct<Fe;++ct)jt(Jt[ct]);this.renderedFeatures_=Jt,this.ready=Ce;var Nt=Re.finish(),Ve=new P3(q,B,P,i.getOverlaps(),Nt,r.getRenderBuffer());return Ne&&(this.declutterExecutorGroup=new P3(q,B,P,i.getOverlaps(),Ne.finish(),r.getRenderBuffer())),this.renderedResolution_=B,this.renderedRevision_=R,this.renderedRenderOrder_=W,this.renderedExtent_=oe,this.wrappedRenderedExtent_=q,this.renderedCenter_=$,this.renderedProjection_=k,this.replayGroup_=Ve,this.hitDetectionImageData_=null,this.replayGroupChanged=!0,!0},n.prototype.renderFeature=function(t,r,i,o,s,a){if(!i)return!1;var f=!1;if(Array.isArray(i))for(var g=0,x=i.length;g<x;++g)f=F3(o,t,i[g],r,this.boundHandleStyleImageChange_,s,a)||f;else f=F3(o,t,i,r,this.boundHandleStyleImageChange_,s,a);return f},n}(fz);const uae=lae;var Aae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),cae=function(e){Aae(n,e);function n(t){return e.call(this,t)||this}return n.prototype.createRenderer=function(){return new uae(this)},n}(cz);const _z=cae;var W9=function(){function e(n){this.rbush_=new lz(n),this.items_={}}return e.prototype.insert=function(n,t){var r={minX:n[0],minY:n[1],maxX:n[2],maxY:n[3],value:t};this.rbush_.insert(r),this.items_[$i(t)]=r},e.prototype.load=function(n,t){for(var r=new Array(t.length),i=0,o=t.length;i<o;i++){var s=n[i],a=t[i],f={minX:s[0],minY:s[1],maxX:s[2],maxY:s[3],value:a};r[i]=f,this.items_[$i(a)]=f}this.rbush_.load(r)},e.prototype.remove=function(n){var t=$i(n),r=this.items_[t];return delete this.items_[t],this.rbush_.remove(r)!==null},e.prototype.update=function(n,t){var r=this.items_[$i(t)],i=[r.minX,r.minY,r.maxX,r.maxY];wy(i,n)||(this.remove(t),this.insert(n,t))},e.prototype.getAll=function(){var n=this.rbush_.all();return n.map(function(t){return t.value})},e.prototype.getInExtent=function(n){var t={minX:n[0],minY:n[1],maxX:n[2],maxY:n[3]},r=this.rbush_.search(t);return r.map(function(i){return i.value})},e.prototype.forEach=function(n){return this.forEach_(this.getAll(),n)},e.prototype.forEachInExtent=function(n,t){return this.forEach_(this.getInExtent(n),t)},e.prototype.forEach_=function(n,t){for(var r,i=0,o=n.length;i<o;i++)if(r=t(n[i]),r)return r;return r},e.prototype.isEmpty=function(){return h1(this.items_)},e.prototype.clear=function(){this.rbush_.clear(),this.items_={}},e.prototype.getExtent=function(n){var t=this.rbush_.toJSON();return hf(t.minX,t.minY,t.maxX,t.maxY,n)},e.prototype.concat=function(n){this.rbush_.load(n.rbush_.all());for(var t in n.items_)this.items_[t]=n.items_[t]},e}(),dae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),hae=function(e){dae(n,e);function n(t){var r=e.call(this)||this;r.projection=Fs(t.projection),r.attributions_=N9(t.attributions),r.attributionsCollapsible_=t.attributionsCollapsible!==void 0?t.attributionsCollapsible:!0,r.loading=!1,r.state_=t.state!==void 0?t.state:"ready",r.wrapX_=t.wrapX!==void 0?t.wrapX:!1,r.interpolate_=!!t.interpolate,r.viewResolver=null,r.viewRejector=null;var i=r;return r.viewPromise_=new Promise(function(o,s){i.viewResolver=o,i.viewRejector=s}),r}return n.prototype.getAttributions=function(){return this.attributions_},n.prototype.getAttributionsCollapsible=function(){return this.attributionsCollapsible_},n.prototype.getProjection=function(){return this.projection},n.prototype.getResolutions=function(){return li()},n.prototype.getView=function(){return this.viewPromise_},n.prototype.getState=function(){return this.state_},n.prototype.getWrapX=function(){return this.wrapX_},n.prototype.getInterpolate=function(){return this.interpolate_},n.prototype.refresh=function(){this.changed()},n.prototype.setAttributions=function(t){this.attributions_=N9(t),this.changed()},n.prototype.setState=function(t){this.state_=t,this.changed()},n}(mh);function N9(e){return e?Array.isArray(e)?function(n){return e}:typeof e=="function"?e:function(n){return[e]}:null}const bz=hae,oh={ADDFEATURE:"addfeature",CHANGEFEATURE:"changefeature",CLEAR:"clear",REMOVEFEATURE:"removefeature",FEATURESLOADSTART:"featuresloadstart",FEATURESLOADEND:"featuresloadend",FEATURESLOADERROR:"featuresloaderror"};function fae(e,n){return[[-1/0,-1/0,1/0,1/0]]}var pae=!1;function xz(e,n,t,r,i,o,s){var a=new XMLHttpRequest;a.open("GET",typeof e=="function"?e(t,r,i):e,!0),n.getType()=="arraybuffer"&&(a.responseType="arraybuffer"),a.withCredentials=pae,a.onload=function(f){if(!a.status||a.status>=200&&a.status<300){var g=n.getType(),x=void 0;g=="json"||g=="text"?x=a.responseText:g=="xml"?(x=a.responseXML,x||(x=new DOMParser().parseFromString(a.responseText,"application/xml"))):g=="arraybuffer"&&(x=a.response),x?o(n.readFeatures(x,{extent:t,featureProjection:i}),n.readProjection(x)):s()}else s()},a.onerror=s,a.send()}function G9(e,n){return function(t,r,i,o,s){var a=this;xz(e,n,t,r,i,function(f,g){a.addFeatures(f),o!==void 0&&o(f)},s||d1)}}var wz=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Yp=function(e){wz(n,e);function n(t,r,i){var o=e.call(this,t)||this;return o.feature=r,o.features=i,o}return n}(Ep),mae=function(e){wz(n,e);function n(t){var r=this,i=t||{};r=e.call(this,{attributions:i.attributions,interpolate:!0,projection:void 0,state:"ready",wrapX:i.wrapX!==void 0?i.wrapX:!0})||this,r.on,r.once,r.un,r.loader_=d1,r.format_=i.format,r.overlaps_=i.overlaps===void 0?!0:i.overlaps,r.url_=i.url,i.loader!==void 0?r.loader_=i.loader:r.url_!==void 0&&(ao(r.format_,7),r.loader_=G9(r.url_,r.format_)),r.strategy_=i.strategy!==void 0?i.strategy:fae;var o=i.useSpatialIndex!==void 0?i.useSpatialIndex:!0;r.featuresRtree_=o?new W9:null,r.loadedExtentsRtree_=new W9,r.loadingExtentsCount_=0,r.nullGeometryFeatures_={},r.idIndex_={},r.uidIndex_={},r.featureChangeKeys_={},r.featuresCollection_=null;var s,a;return Array.isArray(i.features)?a=i.features:i.features&&(s=i.features,a=s.getArray()),!o&&s===void 0&&(s=new _d(a)),a!==void 0&&r.addFeaturesInternal(a),s!==void 0&&r.bindFeaturesCollection_(s),r}return n.prototype.addFeature=function(t){this.addFeatureInternal(t),this.changed()},n.prototype.addFeatureInternal=function(t){var r=$i(t);if(!this.addToIndex_(r,t)){this.featuresCollection_&&this.featuresCollection_.remove(t);return}this.setupChangeEvents_(r,t);var i=t.getGeometry();if(i){var o=i.getExtent();this.featuresRtree_&&this.featuresRtree_.insert(o,t)}else this.nullGeometryFeatures_[r]=t;this.dispatchEvent(new Yp(oh.ADDFEATURE,t))},n.prototype.setupChangeEvents_=function(t,r){this.featureChangeKeys_[t]=[wo(r,ki.CHANGE,this.handleFeatureChange_,this),wo(r,xy.PROPERTYCHANGE,this.handleFeatureChange_,this)]},n.prototype.addToIndex_=function(t,r){var i=!0,o=r.getId();return o!==void 0&&(o.toString()in this.idIndex_?i=!1:this.idIndex_[o.toString()]=r),i&&(ao(!(t in this.uidIndex_),30),this.uidIndex_[t]=r),i},n.prototype.addFeatures=function(t){this.addFeaturesInternal(t),this.changed()},n.prototype.addFeaturesInternal=function(t){for(var r=[],i=[],o=[],s=0,a=t.length;s<a;s++){var f=t[s],g=$i(f);this.addToIndex_(g,f)&&i.push(f)}for(var s=0,x=i.length;s<x;s++){var f=i[s],g=$i(f);this.setupChangeEvents_(g,f);var k=f.getGeometry();if(k){var B=k.getExtent();r.push(B),o.push(f)}else this.nullGeometryFeatures_[g]=f}if(this.featuresRtree_&&this.featuresRtree_.load(r,o),this.hasListener(oh.ADDFEATURE))for(var s=0,P=i.length;s<P;s++)this.dispatchEvent(new Yp(oh.ADDFEATURE,i[s]))},n.prototype.bindFeaturesCollection_=function(t){var r=!1;this.addEventListener(oh.ADDFEATURE,function(i){r||(r=!0,t.push(i.feature),r=!1)}),this.addEventListener(oh.REMOVEFEATURE,function(i){r||(r=!0,t.remove(i.feature),r=!1)}),t.addEventListener(WA.ADD,(function(i){r||(r=!0,this.addFeature(i.element),r=!1)}).bind(this)),t.addEventListener(WA.REMOVE,(function(i){r||(r=!0,this.removeFeature(i.element),r=!1)}).bind(this)),this.featuresCollection_=t},n.prototype.clear=function(t){if(t){for(var r in this.featureChangeKeys_){var i=this.featureChangeKeys_[r];i.forEach(Ga)}this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){var o=(function(f){this.removeFeatureInternal(f)}).bind(this);this.featuresRtree_.forEach(o);for(var s in this.nullGeometryFeatures_)this.removeFeatureInternal(this.nullGeometryFeatures_[s])}this.featuresCollection_&&this.featuresCollection_.clear(),this.featuresRtree_&&this.featuresRtree_.clear(),this.nullGeometryFeatures_={};var a=new Yp(oh.CLEAR);this.dispatchEvent(a),this.changed()},n.prototype.forEachFeature=function(t){if(this.featuresRtree_)return this.featuresRtree_.forEach(t);this.featuresCollection_&&this.featuresCollection_.forEach(t)},n.prototype.forEachFeatureAtCoordinateDirect=function(t,r){var i=[t[0],t[1],t[0],t[1]];return this.forEachFeatureInExtent(i,function(o){var s=o.getGeometry();if(s.intersectsCoordinate(t))return r(o)})},n.prototype.forEachFeatureInExtent=function(t,r){if(this.featuresRtree_)return this.featuresRtree_.forEachInExtent(t,r);this.featuresCollection_&&this.featuresCollection_.forEach(r)},n.prototype.forEachFeatureIntersectingExtent=function(t,r){return this.forEachFeatureInExtent(t,function(i){var o=i.getGeometry();if(o.intersectsExtent(t)){var s=r(i);if(s)return s}})},n.prototype.getFeaturesCollection=function(){return this.featuresCollection_},n.prototype.getFeatures=function(){var t;return this.featuresCollection_?t=this.featuresCollection_.getArray().slice(0):this.featuresRtree_&&(t=this.featuresRtree_.getAll(),h1(this.nullGeometryFeatures_)||sf(t,sL(this.nullGeometryFeatures_))),t},n.prototype.getFeaturesAtCoordinate=function(t){var r=[];return this.forEachFeatureAtCoordinateDirect(t,function(i){r.push(i)}),r},n.prototype.getFeaturesInExtent=function(t,r){var i=this;if(this.featuresRtree_){var o=r&&r.canWrapX()&&this.getWrapX();if(!o)return this.featuresRtree_.getInExtent(t);var s=zee(t,r);return[].concat.apply([],s.map(function(a){return i.featuresRtree_.getInExtent(a)}))}else return this.featuresCollection_?this.featuresCollection_.getArray().slice(0):[]},n.prototype.getClosestFeatureToCoordinate=function(t,r){var i=t[0],o=t[1],s=null,a=[NaN,NaN],f=1/0,g=[-1/0,-1/0,1/0,1/0],x=r||ty;return this.featuresRtree_.forEachInExtent(g,function(k){if(x(k)){var B=k.getGeometry(),P=f;if(f=B.closestPointXY(i,o,a,f),f<P){s=k;var R=Math.sqrt(f);g[0]=i-R,g[1]=o-R,g[2]=i+R,g[3]=o+R}}}),s},n.prototype.getExtent=function(t){return this.featuresRtree_.getExtent(t)},n.prototype.getFeatureById=function(t){var r=this.idIndex_[t.toString()];return r!==void 0?r:null},n.prototype.getFeatureByUid=function(t){var r=this.uidIndex_[t];return r!==void 0?r:null},n.prototype.getFormat=function(){return this.format_},n.prototype.getOverlaps=function(){return this.overlaps_},n.prototype.getUrl=function(){return this.url_},n.prototype.handleFeatureChange_=function(t){var r=t.target,i=$i(r),o=r.getGeometry();if(!o)i in this.nullGeometryFeatures_||(this.featuresRtree_&&this.featuresRtree_.remove(r),this.nullGeometryFeatures_[i]=r);else{var s=o.getExtent();i in this.nullGeometryFeatures_?(delete this.nullGeometryFeatures_[i],this.featuresRtree_&&this.featuresRtree_.insert(s,r)):this.featuresRtree_&&this.featuresRtree_.update(s,r)}var a=r.getId();if(a!==void 0){var f=a.toString();this.idIndex_[f]!==r&&(this.removeFromIdIndex_(r),this.idIndex_[f]=r)}else this.removeFromIdIndex_(r),this.uidIndex_[i]=r;this.changed(),this.dispatchEvent(new Yp(oh.CHANGEFEATURE,r))},n.prototype.hasFeature=function(t){var r=t.getId();return r!==void 0?r in this.idIndex_:$i(t)in this.uidIndex_},n.prototype.isEmpty=function(){return this.featuresRtree_?this.featuresRtree_.isEmpty()&&h1(this.nullGeometryFeatures_):this.featuresCollection_?this.featuresCollection_.getLength()===0:!0},n.prototype.loadFeatures=function(t,r,i){for(var o=this.loadedExtentsRtree_,s=this.strategy_(t,r,i),a=function(k,B){var P=s[k],R=o.forEachInExtent(P,function(H){return cm(H.extent,P)});R||(++f.loadingExtentsCount_,f.dispatchEvent(new Yp(oh.FEATURESLOADSTART)),f.loader_.call(f,P,r,i,(function(H){--this.loadingExtentsCount_,this.dispatchEvent(new Yp(oh.FEATURESLOADEND,void 0,H))}).bind(f),(function(){--this.loadingExtentsCount_,this.dispatchEvent(new Yp(oh.FEATURESLOADERROR))}).bind(f)),o.insert(P,{extent:P.slice()}))},f=this,g=0,x=s.length;g<x;++g)a(g);this.loading=this.loader_.length<4?!1:this.loadingExtentsCount_>0},n.prototype.refresh=function(){this.clear(!0),this.loadedExtentsRtree_.clear(),e.prototype.refresh.call(this)},n.prototype.removeLoadedExtent=function(t){var r=this.loadedExtentsRtree_,i;r.forEachInExtent(t,function(o){if(wy(o.extent,t))return i=o,!0}),i&&r.remove(i)},n.prototype.removeFeature=function(t){if(t){var r=$i(t);r in this.nullGeometryFeatures_?delete this.nullGeometryFeatures_[r]:this.featuresRtree_&&this.featuresRtree_.remove(t);var i=this.removeFeatureInternal(t);i&&this.changed()}},n.prototype.removeFeatureInternal=function(t){var r=$i(t),i=this.featureChangeKeys_[r];if(i){i.forEach(Ga),delete this.featureChangeKeys_[r];var o=t.getId();return o!==void 0&&delete this.idIndex_[o.toString()],delete this.uidIndex_[r],this.dispatchEvent(new Yp(oh.REMOVEFEATURE,t)),t}},n.prototype.removeFromIdIndex_=function(t){var r=!1;for(var i in this.idIndex_)if(this.idIndex_[i]===t){delete this.idIndex_[i],r=!0;break}return r},n.prototype.setLoader=function(t){this.loader_=t},n.prototype.setUrl=function(t){ao(this.format_,7),this.url_=t,this.setLoader(G9(t,this.format_))},n}(bz);const Mz=mae;function gae(e){var n=e||{},t=new _d,r=new Rie(-.005,.05,100),i=n.altShiftDragRotate!==void 0?n.altShiftDragRotate:!0;i&&t.push(new wie);var o=n.doubleClickZoom!==void 0?n.doubleClickZoom:!0;o&&t.push(new die({delta:n.zoomDelta,duration:n.zoomDuration}));var s=n.dragPan!==void 0?n.dragPan:!0;s&&t.push(new bie({onFocusOnly:n.onFocusOnly,kinetic:r}));var a=n.pinchRotate!==void 0?n.pinchRotate:!0;a&&t.push(new Nie);var f=n.pinchZoom!==void 0?n.pinchZoom:!0;f&&t.push(new $ie({duration:n.zoomDuration}));var g=n.keyboard!==void 0?n.keyboard:!0;g&&(t.push(new Pie),t.push(new Uie({delta:n.zoomDelta,duration:n.zoomDuration})));var x=n.mouseWheelZoom!==void 0?n.mouseWheelZoom:!0;x&&t.push(new jie({onFocusOnly:n.onFocusOnly,duration:n.zoomDuration}));var k=n.shiftDragZoom!==void 0?n.shiftDragZoom:!0;return k&&t.push(new Tie({duration:n.zoomDuration})),t}var yae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),g7=function(e){yae(n,e);function n(t){return t=al({},t),t.controls||(t.controls=aie()),t.interactions||(t.interactions=gae({onFocusOnly:!0})),e.call(this,t)||this}return n.prototype.createRenderer=function(){return new gre(this)},n}($re),Sz=function(){function e(n,t,r,i){this.minX=n,this.maxX=t,this.minY=r,this.maxY=i}return e.prototype.contains=function(n){return this.containsXY(n[1],n[2])},e.prototype.containsTileRange=function(n){return this.minX<=n.minX&&n.maxX<=this.maxX&&this.minY<=n.minY&&n.maxY<=this.maxY},e.prototype.containsXY=function(n,t){return this.minX<=n&&n<=this.maxX&&this.minY<=t&&t<=this.maxY},e.prototype.equals=function(n){return this.minX==n.minX&&this.minY==n.minY&&this.maxX==n.maxX&&this.maxY==n.maxY},e.prototype.extend=function(n){n.minX<this.minX&&(this.minX=n.minX),n.maxX>this.maxX&&(this.maxX=n.maxX),n.minY<this.minY&&(this.minY=n.minY),n.maxY>this.maxY&&(this.maxY=n.maxY)},e.prototype.getHeight=function(){return this.maxY-this.minY+1},e.prototype.getSize=function(){return[this.getWidth(),this.getHeight()]},e.prototype.getWidth=function(){return this.maxX-this.minX+1},e.prototype.intersects=function(n){return this.minX<=n.maxX&&this.maxX>=n.minX&&this.minY<=n.maxY&&this.maxY>=n.minY},e}();function ug(e,n,t,r,i){return i!==void 0?(i.minX=e,i.maxX=n,i.minY=t,i.maxY=r,i):new Sz(e,n,t,r)}const Ez=Sz;function Q9(e,n,t,r){return r!==void 0?(r[0]=e,r[1]=n,r[2]=t,r):[e,n,t]}function Wy(e,n,t){return e+"/"+n+"/"+t}function Oz(e){return Wy(e[0],e[1],e[2])}function vae(e){var n=e.substring(e.lastIndexOf("/")+1,e.length).split(",").map(Number),t=n[0],r=n[1],i=n[2];return Wy(t,r,i)}function Bz(e){return e.split("/").map(Number)}function Cae(e){return(e[1]<<e[0])+e[2]}function _ae(e,n){var t=e[0],r=e[1],i=e[2];if(n.getMinZoom()>t||t>n.getMaxZoom())return!1;var o=n.getFullTileRange(t);return o?o.containsXY(r,i):!0}var bae=[0,0,0],qp=5,xae=function(){function e(n){this.minZoom=n.minZoom!==void 0?n.minZoom:0,this.resolutions_=n.resolutions,ao(hee(this.resolutions_,function(s,a){return a-s},!0),17);var t;if(!n.origins){for(var r=0,i=this.resolutions_.length-1;r<i;++r)if(!t)t=this.resolutions_[r]/this.resolutions_[r+1];else if(this.resolutions_[r]/this.resolutions_[r+1]!==t){t=void 0;break}}this.zoomFactor_=t,this.maxZoom=this.resolutions_.length-1,this.origin_=n.origin!==void 0?n.origin:null,this.origins_=null,n.origins!==void 0&&(this.origins_=n.origins,ao(this.origins_.length==this.resolutions_.length,20));var o=n.extent;o!==void 0&&!this.origin_&&!this.origins_&&(this.origin_=Lm(o)),ao(!this.origin_&&this.origins_||this.origin_&&!this.origins_,18),this.tileSizes_=null,n.tileSizes!==void 0&&(this.tileSizes_=n.tileSizes,ao(this.tileSizes_.length==this.resolutions_.length,19)),this.tileSize_=n.tileSize!==void 0?n.tileSize:this.tileSizes_?null:u7,ao(!this.tileSize_&&this.tileSizes_||this.tileSize_&&!this.tileSizes_,22),this.extent_=o!==void 0?o:null,this.fullTileRanges_=null,this.tmpSize_=[0,0],this.tmpExtent_=[0,0,0,0],n.sizes!==void 0?this.fullTileRanges_=n.sizes.map(function(s,a){var f=new Ez(Math.min(0,s[0]),Math.max(s[0]-1,-1),Math.min(0,s[1]),Math.max(s[1]-1,-1));if(o){var g=this.getTileRangeForExtentAndZ(o,a);f.minX=Math.max(g.minX,f.minX),f.maxX=Math.min(g.maxX,f.maxX),f.minY=Math.max(g.minY,f.minY),f.maxY=Math.min(g.maxY,f.maxY)}return f},this):o&&this.calculateTileRanges_(o)}return e.prototype.forEachTileCoord=function(n,t,r){for(var i=this.getTileRangeForExtentAndZ(n,t),o=i.minX,s=i.maxX;o<=s;++o)for(var a=i.minY,f=i.maxY;a<=f;++a)r([t,o,a])},e.prototype.forEachTileCoordParentTileRange=function(n,t,r,i){var o,s,a,f=null,g=n[0]-1;for(this.zoomFactor_===2?(s=n[1],a=n[2]):f=this.getTileCoordExtent(n,i);g>=this.minZoom;){if(this.zoomFactor_===2?(s=Math.floor(s/2),a=Math.floor(a/2),o=ug(s,s,a,a,r)):o=this.getTileRangeForExtentAndZ(f,g,r),t(g,o))return!0;--g}return!1},e.prototype.getExtent=function(){return this.extent_},e.prototype.getMaxZoom=function(){return this.maxZoom},e.prototype.getMinZoom=function(){return this.minZoom},e.prototype.getOrigin=function(n){return this.origin_?this.origin_:this.origins_[n]},e.prototype.getResolution=function(n){return this.resolutions_[n]},e.prototype.getResolutions=function(){return this.resolutions_},e.prototype.getTileCoordChildTileRange=function(n,t,r){if(n[0]<this.maxZoom){if(this.zoomFactor_===2){var i=n[1]*2,o=n[2]*2;return ug(i,i+1,o,o+1,t)}var s=this.getTileCoordExtent(n,r||this.tmpExtent_);return this.getTileRangeForExtentAndZ(s,n[0]+1,t)}return null},e.prototype.getTileRangeForTileCoordAndZ=function(n,t,r){if(t>this.maxZoom||t<this.minZoom)return null;var i=n[0],o=n[1],s=n[2];if(t===i)return ug(o,s,o,s,r);if(this.zoomFactor_){var a=Math.pow(this.zoomFactor_,t-i),f=Math.floor(o*a),g=Math.floor(s*a);if(t<i)return ug(f,f,g,g,r);var x=Math.floor(a*(o+1))-1,k=Math.floor(a*(s+1))-1;return ug(f,x,g,k,r)}var B=this.getTileCoordExtent(n,this.tmpExtent_);return this.getTileRangeForExtentAndZ(B,t,r)},e.prototype.getTileRangeExtent=function(n,t,r){var i=this.getOrigin(n),o=this.getResolution(n),s=pA(this.getTileSize(n),this.tmpSize_),a=i[0]+t.minX*s[0]*o,f=i[0]+(t.maxX+1)*s[0]*o,g=i[1]+t.minY*s[1]*o,x=i[1]+(t.maxY+1)*s[1]*o;return hf(a,g,f,x,r)},e.prototype.getTileRangeForExtentAndZ=function(n,t,r){var i=bae;this.getTileCoordForXYAndZ_(n[0],n[3],t,!1,i);var o=i[1],s=i[2];return this.getTileCoordForXYAndZ_(n[2],n[1],t,!0,i),ug(o,i[1],s,i[2],r)},e.prototype.getTileCoordCenter=function(n){var t=this.getOrigin(n[0]),r=this.getResolution(n[0]),i=pA(this.getTileSize(n[0]),this.tmpSize_);return[t[0]+(n[1]+.5)*i[0]*r,t[1]-(n[2]+.5)*i[1]*r]},e.prototype.getTileCoordExtent=function(n,t){var r=this.getOrigin(n[0]),i=this.getResolution(n[0]),o=pA(this.getTileSize(n[0]),this.tmpSize_),s=r[0]+n[1]*o[0]*i,a=r[1]-(n[2]+1)*o[1]*i,f=s+o[0]*i,g=a+o[1]*i;return hf(s,a,f,g,t)},e.prototype.getTileCoordForCoordAndResolution=function(n,t,r){return this.getTileCoordForXYAndResolution_(n[0],n[1],t,!1,r)},e.prototype.getTileCoordForXYAndResolution_=function(n,t,r,i,o){var s=this.getZForResolution(r),a=r/this.getResolution(s),f=this.getOrigin(s),g=pA(this.getTileSize(s),this.tmpSize_),x=a*(n-f[0])/r/g[0],k=a*(f[1]-t)/r/g[1];return i?(x=vx(x,qp)-1,k=vx(k,qp)-1):(x=yx(x,qp),k=yx(k,qp)),Q9(s,x,k,o)},e.prototype.getTileCoordForXYAndZ_=function(n,t,r,i,o){var s=this.getOrigin(r),a=this.getResolution(r),f=pA(this.getTileSize(r),this.tmpSize_),g=(n-s[0])/a/f[0],x=(s[1]-t)/a/f[1];return i?(g=vx(g,qp)-1,x=vx(x,qp)-1):(g=yx(g,qp),x=yx(x,qp)),Q9(r,g,x,o)},e.prototype.getTileCoordForCoordAndZ=function(n,t,r){return this.getTileCoordForXYAndZ_(n[0],n[1],t,!1,r)},e.prototype.getTileCoordResolution=function(n){return this.resolutions_[n[0]]},e.prototype.getTileSize=function(n){return this.tileSize_?this.tileSize_:this.tileSizes_[n]},e.prototype.getFullTileRange=function(n){return this.fullTileRanges_?this.fullTileRanges_[n]:this.extent_?this.getTileRangeForExtentAndZ(this.extent_,n):null},e.prototype.getZForResolution=function(n,t){var r=RB(this.resolutions_,n,t||0);return vl(r,this.minZoom,this.maxZoom)},e.prototype.tileCoordIntersectsViewport=function(n,t){return kL(t,0,t.length,2,this.getTileCoordExtent(n))},e.prototype.calculateTileRanges_=function(n){for(var t=this.resolutions_.length,r=new Array(t),i=this.minZoom;i<t;++i)r[i]=this.getTileRangeForExtentAndZ(n,i);this.fullTileRanges_=r},e}();const X_=xae;var wae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Mae=function(e){wae(n,e);function n(t,r,i){var o=e.call(this)||this,s=i||{};return o.tileCoord=t,o.state=r,o.interimTile=null,o.key="",o.transition_=s.transition===void 0?250:s.transition,o.transitionStarts_={},o.interpolate=!!s.interpolate,o}return n.prototype.changed=function(){this.dispatchEvent(ki.CHANGE)},n.prototype.release=function(){},n.prototype.getKey=function(){return this.key+"/"+this.tileCoord},n.prototype.getInterimTile=function(){if(!this.interimTile)return this;var t=this.interimTile;do{if(t.getState()==mr.LOADED)return this.transition_=0,t;t=t.interimTile}while(t);return this},n.prototype.refreshInterimChain=function(){if(this.interimTile){var t=this.interimTile,r=this;do{if(t.getState()==mr.LOADED){t.interimTile=null;break}else t.getState()==mr.LOADING?r=t:t.getState()==mr.IDLE?r.interimTile=t.interimTile:r=t;t=r.interimTile}while(t)}},n.prototype.getTileCoord=function(){return this.tileCoord},n.prototype.getState=function(){return this.state},n.prototype.setState=function(t){if(this.state!==mr.ERROR&&this.state>t)throw new Error("Tile load sequence violation");this.state=t,this.changed()},n.prototype.load=function(){li()},n.prototype.getAlpha=function(t,r){if(!this.transition_)return 1;var i=this.transitionStarts_[t];if(!i)i=r,this.transitionStarts_[t]=i;else if(i===-1)return 1;var o=r-i+1e3/60;return o>=this.transition_?1:JL(o/this.transition_)},n.prototype.inTransition=function(t){return this.transition_?this.transitionStarts_[t]!==-1:!1},n.prototype.endTransition=function(t){this.transition_&&(this.transitionStarts_[t]=-1)},n}(zy);const p5=Mae;var Sae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Eae=function(e){Sae(n,e);function n(t,r,i,o,s,a){var f=e.call(this,t,r,a)||this;return f.crossOrigin_=o,f.src_=i,f.key=i,f.image_=new Image,o!==null&&(f.image_.crossOrigin=o),f.unlisten_=null,f.tileLoadFunction_=s,f}return n.prototype.getImage=function(){return this.image_},n.prototype.setImage=function(t){this.image_=t,this.state=mr.LOADED,this.unlistenImage_(),this.changed()},n.prototype.handleImageError_=function(){this.state=mr.ERROR,this.unlistenImage_(),this.image_=Oae(),this.changed()},n.prototype.handleImageLoad_=function(){var t=this.image_;t.naturalWidth&&t.naturalHeight?this.state=mr.LOADED:this.state=mr.EMPTY,this.unlistenImage_(),this.changed()},n.prototype.load=function(){this.state==mr.ERROR&&(this.state=mr.IDLE,this.image_=new Image,this.crossOrigin_!==null&&(this.image_.crossOrigin=this.crossOrigin_)),this.state==mr.IDLE&&(this.state=mr.LOADING,this.changed(),this.tileLoadFunction_(this,this.src_),this.unlisten_=m7(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))},n.prototype.unlistenImage_=function(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)},n}(p5);function Oae(){var e=YA(1,1);return e.fillStyle="rgba(0,0,0,0)",e.fillRect(0,0,1,1),e.canvas}const kz=Eae;var Bae=.5,kae=10,$9=.25,Iae=function(){function e(n,t,r,i,o,s){this.sourceProj_=n,this.targetProj_=t;var a={},f=b3(this.targetProj_,this.sourceProj_);this.transformInv_=function(oe){var ne=oe[0]+"/"+oe[1];return a[ne]||(a[ne]=f(oe)),a[ne]},this.maxSourceExtent_=i,this.errorThresholdSquared_=o*o,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!i&&!!this.sourceProj_.getExtent()&&os(i)==os(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?os(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?os(this.targetProj_.getExtent()):null;var g=Lm(r),x=l5(r),k=s5(r),B=a5(r),P=this.transformInv_(g),R=this.transformInv_(x),H=this.transformInv_(k),W=this.transformInv_(B),$=kae+(s?Math.max(0,Math.ceil(Nee(L6(r)/(s*s*256*256)))):0);if(this.addQuad_(g,x,k,B,P,R,H,W,$),this.wrapsXInSource_){var q=1/0;this.triangles_.forEach(function(oe,ne,ce){q=Math.min(q,oe.source[0][0],oe.source[1][0],oe.source[2][0])}),this.triangles_.forEach((function(oe){if(Math.max(oe.source[0][0],oe.source[1][0],oe.source[2][0])-q>this.sourceWorldWidth_/2){var ne=[[oe.source[0][0],oe.source[0][1]],[oe.source[1][0],oe.source[1][1]],[oe.source[2][0],oe.source[2][1]]];ne[0][0]-q>this.sourceWorldWidth_/2&&(ne[0][0]-=this.sourceWorldWidth_),ne[1][0]-q>this.sourceWorldWidth_/2&&(ne[1][0]-=this.sourceWorldWidth_),ne[2][0]-q>this.sourceWorldWidth_/2&&(ne[2][0]-=this.sourceWorldWidth_);var ce=Math.min(ne[0][0],ne[1][0],ne[2][0]),ae=Math.max(ne[0][0],ne[1][0],ne[2][0]);ae-ce<this.sourceWorldWidth_/2&&(oe.source=ne)}}).bind(this))}a={}}return e.prototype.addTriangle_=function(n,t,r,i,o,s){this.triangles_.push({source:[i,o,s],target:[n,t,r]})},e.prototype.addQuad_=function(n,t,r,i,o,s,a,f,g){var x=U6([o,s,a,f]),k=this.sourceWorldWidth_?os(x)/this.sourceWorldWidth_:null,B=this.sourceWorldWidth_,P=this.sourceProj_.canWrapX()&&k>.5&&k<1,R=!1;if(g>0){if(this.targetProj_.isGlobal()&&this.targetWorldWidth_){var H=U6([n,t,r,i]),W=os(H)/this.targetWorldWidth_;R=W>$9||R}!P&&this.sourceProj_.isGlobal()&&k&&(R=k>$9||R)}if(!(!R&&this.maxSourceExtent_&&isFinite(x[0])&&isFinite(x[1])&&isFinite(x[2])&&isFinite(x[3])&&!il(x,this.maxSourceExtent_))){var $=0;if(!R&&(!isFinite(o[0])||!isFinite(o[1])||!isFinite(s[0])||!isFinite(s[1])||!isFinite(a[0])||!isFinite(a[1])||!isFinite(f[0])||!isFinite(f[1]))){if(g>0)R=!0;else if($=(!isFinite(o[0])||!isFinite(o[1])?8:0)+(!isFinite(s[0])||!isFinite(s[1])?4:0)+(!isFinite(a[0])||!isFinite(a[1])?2:0)+(!isFinite(f[0])||!isFinite(f[1])?1:0),$!=1&&$!=2&&$!=4&&$!=8)return}if(g>0){if(!R){var q=[(n[0]+r[0])/2,(n[1]+r[1])/2],oe=this.transformInv_(q),ne=void 0;if(P){var ce=(e1(o[0],B)+e1(a[0],B))/2;ne=ce-e1(oe[0],B)}else ne=(o[0]+a[0])/2-oe[0];var ae=(o[1]+a[1])/2-oe[1],ue=ne*ne+ae*ae;R=ue>this.errorThresholdSquared_}if(R){if(Math.abs(n[0]-r[0])<=Math.abs(n[1]-r[1])){var ye=[(t[0]+r[0])/2,(t[1]+r[1])/2],Re=this.transformInv_(ye),Ne=[(i[0]+n[0])/2,(i[1]+n[1])/2],rt=this.transformInv_(Ne);this.addQuad_(n,t,ye,Ne,o,s,Re,rt,g-1),this.addQuad_(Ne,ye,r,i,rt,Re,a,f,g-1)}else{var ct=[(n[0]+t[0])/2,(n[1]+t[1])/2],Fe=this.transformInv_(ct),He=[(r[0]+i[0])/2,(r[1]+i[1])/2],Ce=this.transformInv_(He);this.addQuad_(n,ct,He,i,o,Fe,Ce,f,g-1),this.addQuad_(ct,t,r,He,Fe,s,a,Ce,g-1)}return}}if(P){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}$&11||this.addTriangle_(n,r,i,o,a,f),$&14||this.addTriangle_(n,r,t,o,a,s),$&&($&13||this.addTriangle_(t,i,n,s,f,o),$&7||this.addTriangle_(t,i,r,s,f,a))}},e.prototype.calculateSourceExtent=function(){var n=Ed();return this.triangles_.forEach(function(t,r,i){var o=t.source;kC(n,o[0]),kC(n,o[1]),kC(n,o[2])}),n},e.prototype.getTriangles=function(){return this.triangles_},e}(),oE={imageSmoothingEnabled:!1,msImageSmoothingEnabled:!1},Tae={imageSmoothingEnabled:!0,msImageSmoothingEnabled:!0},CM,Iz=[];function Y9(e,n,t,r,i){e.beginPath(),e.moveTo(0,0),e.lineTo(n,t),e.lineTo(r,i),e.closePath(),e.save(),e.clip(),e.fillRect(0,0,Math.max(n,r)+1,Math.max(t,i)),e.restore()}function _M(e,n){return Math.abs(e[n*4]-210)>2||Math.abs(e[n*4+3]-.75*255)>2}function Kae(){if(CM===void 0){var e=document.createElement("canvas").getContext("2d");e.globalCompositeOperation="lighter",e.fillStyle="rgba(210, 0, 0, 0.75)",Y9(e,4,5,4,0),Y9(e,4,5,0,5);var n=e.getImageData(0,0,3,3).data;CM=_M(n,0)||_M(n,4)||_M(n,8)}return CM}function q9(e,n,t,r){var i=VB(t,n,e),o=u9(n,r,t),s=n.getMetersPerUnit();s!==void 0&&(o*=s);var a=e.getMetersPerUnit();a!==void 0&&(o/=a);var f=e.getExtent();if(!f||$_(f,i)){var g=u9(e,o,i)/o;isFinite(g)&&g>0&&(o/=g)}return o}function Pae(e,n,t,r){var i=Dm(t),o=q9(e,n,i,r);return(!isFinite(o)||o<=0)&&vL(t,function(s){return o=q9(e,n,s,r),isFinite(o)&&o>0}),o}function Fae(e,n,t,r,i,o,s,a,f,g,x,k){var B=YA(Math.round(t*e),Math.round(t*n),Iz);if(k||al(B,oE),f.length===0)return B.canvas;B.scale(t,t);function P(ne){return Math.round(ne*t)/t}B.globalCompositeOperation="lighter";var R=Ed();f.forEach(function(ne,ce,ae){gL(R,ne.extent)});var H=os(R),W=$A(R),$=YA(Math.round(t*H/r),Math.round(t*W/r));k||al($,oE);var q=t/r;f.forEach(function(ne,ce,ae){var ue=ne.extent[0]-R[0],ye=-(ne.extent[3]-R[3]),Re=os(ne.extent),Ne=$A(ne.extent);ne.image.width>0&&ne.image.height>0&&$.drawImage(ne.image,g,g,ne.image.width-2*g,ne.image.height-2*g,ue*q,ye*q,Re*q,Ne*q)});var oe=Lm(s);return a.getTriangles().forEach(function(ne,ce,ae){var ue=ne.source,ye=ne.target,Re=ue[0][0],Ne=ue[0][1],rt=ue[1][0],ct=ue[1][1],Fe=ue[2][0],He=ue[2][1],Ce=P((ye[0][0]-oe[0])/o),jt=P(-(ye[0][1]-oe[1])/o),Ft=P((ye[1][0]-oe[0])/o),Jt=P(-(ye[1][1]-oe[1])/o),Nt=P((ye[2][0]-oe[0])/o),Ve=P(-(ye[2][1]-oe[1])/o),nt=Re,Je=Ne;Re=0,Ne=0,rt-=nt,ct-=Je,Fe-=nt,He-=Je;var Vt=[[rt,ct,0,0,Ft-Ce],[Fe,He,0,0,Nt-Ce],[0,0,rt,ct,Jt-jt],[0,0,Fe,He,Ve-jt]],pt=Qee(Vt);if(pt){if(B.save(),B.beginPath(),Kae()||!k){B.moveTo(Ft,Jt);for(var dt=4,kt=Ce-Ft,Dt=jt-Jt,Se=0;Se<dt;Se++)B.lineTo(Ft+P((Se+1)*kt/dt),Jt+P(Se*Dt/(dt-1))),Se!=dt-1&&B.lineTo(Ft+P((Se+1)*kt/dt),Jt+P((Se+1)*Dt/(dt-1)));B.lineTo(Nt,Ve)}else B.moveTo(Ft,Jt),B.lineTo(Ce,jt),B.lineTo(Nt,Ve);B.clip(),B.transform(pt[0],pt[2],pt[1],pt[3],Ce,jt),B.translate(R[0]-nt,R[3]-Je),B.scale(r/t,-r/t),B.drawImage($.canvas,0,0),B.restore()}}),x&&(B.save(),B.globalCompositeOperation="source-over",B.strokeStyle="black",B.lineWidth=1,a.getTriangles().forEach(function(ne,ce,ae){var ue=ne.target,ye=(ue[0][0]-oe[0])/o,Re=-(ue[0][1]-oe[1])/o,Ne=(ue[1][0]-oe[0])/o,rt=-(ue[1][1]-oe[1])/o,ct=(ue[2][0]-oe[0])/o,Fe=-(ue[2][1]-oe[1])/o;B.beginPath(),B.moveTo(Ne,rt),B.lineTo(ye,Re),B.lineTo(ct,Fe),B.closePath(),B.stroke()}),B.restore()),B.canvas}var Dae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Uae=function(e){Dae(n,e);function n(t,r,i,o,s,a,f,g,x,k,B,P){var R=e.call(this,s,mr.IDLE,{interpolate:!!P})||this;R.renderEdges_=B!==void 0?B:!1,R.pixelRatio_=f,R.gutter_=g,R.canvas_=null,R.sourceTileGrid_=r,R.targetTileGrid_=o,R.wrappedTileCoord_=a||s,R.sourceTiles_=[],R.sourcesListenerKeys_=null,R.sourceZ_=0;var H=o.getTileCoordExtent(R.wrappedTileCoord_),W=R.targetTileGrid_.getExtent(),$=R.sourceTileGrid_.getExtent(),q=W?X0(H,W):H;if(L6(q)===0)return R.state=mr.EMPTY,R;var oe=t.getExtent();oe&&($?$=X0($,oe):$=oe);var ne=o.getResolution(R.wrappedTileCoord_[0]),ce=Pae(t,i,q,ne);if(!isFinite(ce)||ce<=0)return R.state=mr.EMPTY,R;var ae=k!==void 0?k:Bae;if(R.triangulation_=new Iae(t,i,q,$,ce*ae,ne),R.triangulation_.getTriangles().length===0)return R.state=mr.EMPTY,R;R.sourceZ_=r.getZForResolution(ce);var ue=R.triangulation_.calculateSourceExtent();if($&&(t.canWrapX()?(ue[1]=vl(ue[1],$[1],$[3]),ue[3]=vl(ue[3],$[1],$[3])):ue=X0(ue,$)),!L6(ue))R.state=mr.EMPTY;else{for(var ye=r.getTileRangeForExtentAndZ(ue,R.sourceZ_),Re=ye.minX;Re<=ye.maxX;Re++)for(var Ne=ye.minY;Ne<=ye.maxY;Ne++){var rt=x(R.sourceZ_,Re,Ne,f);rt&&R.sourceTiles_.push(rt)}R.sourceTiles_.length===0&&(R.state=mr.EMPTY)}return R}return n.prototype.getImage=function(){return this.canvas_},n.prototype.reproject_=function(){var t=[];if(this.sourceTiles_.forEach((function(x,k,B){x&&x.getState()==mr.LOADED&&t.push({extent:this.sourceTileGrid_.getTileCoordExtent(x.tileCoord),image:x.getImage()})}).bind(this)),this.sourceTiles_.length=0,t.length===0)this.state=mr.ERROR;else{var r=this.wrappedTileCoord_[0],i=this.targetTileGrid_.getTileSize(r),o=typeof i=="number"?i:i[0],s=typeof i=="number"?i:i[1],a=this.targetTileGrid_.getResolution(r),f=this.sourceTileGrid_.getResolution(this.sourceZ_),g=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=Fae(o,s,this.pixelRatio_,f,this.sourceTileGrid_.getExtent(),a,g,this.triangulation_,t,this.gutter_,this.renderEdges_,this.interpolate),this.state=mr.LOADED}this.changed()},n.prototype.load=function(){if(this.state==mr.IDLE){this.state=mr.LOADING,this.changed();var t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach((function(r,i,o){var s=r.getState();if(s==mr.IDLE||s==mr.LOADING){t++;var a=wo(r,ki.CHANGE,function(f){var g=r.getState();(g==mr.LOADED||g==mr.ERROR||g==mr.EMPTY)&&(Ga(a),t--,t===0&&(this.unlistenSources_(),this.reproject_()))},this);this.sourcesListenerKeys_.push(a)}}).bind(this)),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function(r,i,o){var s=r.getState();s==mr.IDLE&&r.load()})}},n.prototype.unlistenSources_=function(){this.sourcesListenerKeys_.forEach(Ga),this.sourcesListenerKeys_=null},n.prototype.release=function(){this.canvas_&&(l7(this.canvas_.getContext("2d")),Iz.push(this.canvas_),this.canvas_=null),e.prototype.release.call(this)},n}(p5);const Tz=Uae;var Rae=function(){function e(n){this.highWaterMark=n!==void 0?n:2048,this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}return e.prototype.canExpireCache=function(){return this.highWaterMark>0&&this.getCount()>this.highWaterMark},e.prototype.expireCache=function(n){for(;this.canExpireCache();)this.pop()},e.prototype.clear=function(){this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null},e.prototype.containsKey=function(n){return this.entries_.hasOwnProperty(n)},e.prototype.forEach=function(n){for(var t=this.oldest_;t;)n(t.value_,t.key_,this),t=t.newer},e.prototype.get=function(n,t){var r=this.entries_[n];return ao(r!==void 0,15),r===this.newest_||(r===this.oldest_?(this.oldest_=this.oldest_.newer,this.oldest_.older=null):(r.newer.older=r.older,r.older.newer=r.newer),r.newer=null,r.older=this.newest_,this.newest_.newer=r,this.newest_=r),r.value_},e.prototype.remove=function(n){var t=this.entries_[n];return ao(t!==void 0,15),t===this.newest_?(this.newest_=t.older,this.newest_&&(this.newest_.newer=null)):t===this.oldest_?(this.oldest_=t.newer,this.oldest_&&(this.oldest_.older=null)):(t.newer.older=t.older,t.older.newer=t.newer),delete this.entries_[n],--this.count_,t.value_},e.prototype.getCount=function(){return this.count_},e.prototype.getKeys=function(){var n=new Array(this.count_),t=0,r;for(r=this.newest_;r;r=r.older)n[t++]=r.key_;return n},e.prototype.getValues=function(){var n=new Array(this.count_),t=0,r;for(r=this.newest_;r;r=r.older)n[t++]=r.value_;return n},e.prototype.peekLast=function(){return this.oldest_.value_},e.prototype.peekLastKey=function(){return this.oldest_.key_},e.prototype.peekFirstKey=function(){return this.newest_.key_},e.prototype.peek=function(n){if(this.containsKey(n))return this.entries_[n].value_},e.prototype.pop=function(){var n=this.oldest_;return delete this.entries_[n.key_],n.newer&&(n.newer.older=null),this.oldest_=n.newer,this.oldest_||(this.newest_=null),--this.count_,n.value_},e.prototype.replace=function(n,t){this.get(n),this.entries_[n].value_=t},e.prototype.set=function(n,t){ao(!(n in this.entries_),16);var r={key_:n,newer:null,older:this.newest_,value_:t};this.newest_?this.newest_.newer=r:this.oldest_=r,this.newest_=r,this.entries_[n]=r,++this.count_},e.prototype.setSize=function(n){this.highWaterMark=n},e}();const Lae=Rae;var zae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),jae=function(e){zae(n,e);function n(){return e!==null&&e.apply(this,arguments)||this}return n.prototype.expireCache=function(t){for(;this.canExpireCache();){var r=this.peekLast();if(r.getKey()in t)break;this.pop().release()}},n.prototype.pruneExceptNewestZ=function(){if(this.getCount()!==0){var t=this.peekFirstKey(),r=Bz(t),i=r[0];this.forEach((function(o){o.tileCoord[0]!==i&&(this.remove(Oz(o.tileCoord)),o.release())}).bind(this))}},n}(Lae);const y7=jae,bM={TILELOADSTART:"tileloadstart",TILELOADEND:"tileloadend",TILELOADERROR:"tileloaderror"};function Kz(e){var n=e.getDefaultTileGrid();return n||(n=Gae(e),e.setDefaultTileGrid(n)),n}function Wae(e,n,t){var r=n[0],i=e.getTileCoordCenter(n),o=m5(t);if($_(o,i))return n;var s=os(o),a=Math.ceil((o[0]-i[0])/s);return i[0]+=s*a,e.getTileCoordForCoordAndZ(i,r)}function Nae(e,n,t,r){var i=r!==void 0?r:"top-left",o=Pz(e,n,t);return new X_({extent:e,origin:Dee(e,i),resolutions:o,tileSize:t})}function v7(e){var n=e||{},t=n.extent||Fs("EPSG:3857").getExtent(),r={extent:t,minZoom:n.minZoom,tileSize:n.tileSize,resolutions:Pz(t,n.maxZoom,n.tileSize,n.maxResolution)};return new X_(r)}function Pz(e,n,t,r){for(var i=n!==void 0?n:XL,o=$A(e),s=os(e),a=pA(t!==void 0?t:u7),f=r>0?r:Math.max(s/a[0],o/a[1]),g=i+1,x=new Array(g),k=0;k<g;++k)x[k]=f/Math.pow(2,k);return x}function Gae(e,n,t,r){var i=m5(e);return Nae(i,n,t,r)}function m5(e){e=Fs(e);var n=e.getExtent();if(!n){var t=180*cf[gA.DEGREES]/e.getMetersPerUnit();n=hf(-t,-t,t,t)}return n}var Fz=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Qae=function(e){Fz(n,e);function n(t){var r=e.call(this,{attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,projection:t.projection,state:t.state,wrapX:t.wrapX,interpolate:t.interpolate})||this;r.on,r.once,r.un,r.opaque_=t.opaque!==void 0?t.opaque:!1,r.tilePixelRatio_=t.tilePixelRatio!==void 0?t.tilePixelRatio:1,r.tileGrid=t.tileGrid!==void 0?t.tileGrid:null;var i=[256,256];return r.tileGrid&&pA(r.tileGrid.getTileSize(r.tileGrid.getMinZoom()),i),r.tileCache=new y7(t.cacheSize||0),r.tmpSize=[0,0],r.key_=t.key||"",r.tileOptions={transition:t.transition,interpolate:t.interpolate},r.zDirection=t.zDirection?t.zDirection:0,r}return n.prototype.canExpireCache=function(){return this.tileCache.canExpireCache()},n.prototype.expireCache=function(t,r){var i=this.getTileCacheForProjection(t);i&&i.expireCache(r)},n.prototype.forEachLoadedTile=function(t,r,i,o){var s=this.getTileCacheForProjection(t);if(!s)return!1;for(var a=!0,f,g,x,k=i.minX;k<=i.maxX;++k)for(var B=i.minY;B<=i.maxY;++B)g=Wy(r,k,B),x=!1,s.containsKey(g)&&(f=s.get(g),x=f.getState()===mr.LOADED,x&&(x=o(f)!==!1)),x||(a=!1);return a},n.prototype.getGutterForProjection=function(t){return 0},n.prototype.getKey=function(){return this.key_},n.prototype.setKey=function(t){this.key_!==t&&(this.key_=t,this.changed())},n.prototype.getOpaque=function(t){return this.opaque_},n.prototype.getResolutions=function(){return this.tileGrid?this.tileGrid.getResolutions():null},n.prototype.getTile=function(t,r,i,o,s){return li()},n.prototype.getTileGrid=function(){return this.tileGrid},n.prototype.getTileGridForProjection=function(t){return this.tileGrid?this.tileGrid:Kz(t)},n.prototype.getTileCacheForProjection=function(t){var r=this.getProjection();return ao(r===null||I0(r,t),68),this.tileCache},n.prototype.getTilePixelRatio=function(t){return this.tilePixelRatio_},n.prototype.getTilePixelSize=function(t,r,i){var o=this.getTileGridForProjection(i),s=this.getTilePixelRatio(r),a=pA(o.getTileSize(t),this.tmpSize);return s==1?a:Wre(a,s,this.tmpSize)},n.prototype.getTileCoordForTileUrlFunction=function(t,r){var i=r!==void 0?r:this.getProjection(),o=this.getTileGridForProjection(i);return this.getWrapX()&&i.isGlobal()&&(t=Wae(o,t,i)),_ae(t,o)?t:null},n.prototype.clear=function(){this.tileCache.clear()},n.prototype.refresh=function(){this.clear(),e.prototype.refresh.call(this)},n.prototype.updateCacheSize=function(t,r){var i=this.getTileCacheForProjection(r);t>i.highWaterMark&&(i.highWaterMark=t)},n.prototype.useTile=function(t,r,i,o){},n}(bz),$ae=function(e){Fz(n,e);function n(t,r){var i=e.call(this,t)||this;return i.tile=r,i}return n}(Ep);const Yae=Qae;function qae(e,n){var t=/\{z\}/g,r=/\{x\}/g,i=/\{y\}/g,o=/\{-y\}/g;return function(s,a,f){if(s)return e.replace(t,s[0].toString()).replace(r,s[1].toString()).replace(i,s[2].toString()).replace(o,function(){var g=s[0],x=n.getFullTileRange(g);ao(x,55);var k=x.getHeight()-s[2]-1;return k.toString()})}}function Dz(e,n){for(var t=e.length,r=new Array(t),i=0;i<t;++i)r[i]=qae(e[i],n);return Vae(r)}function Vae(e){return e.length===1?e[0]:function(n,t,r){if(n){var i=Cae(n),o=e1(i,e.length);return e[o](n,t,r)}else return}}function Hae(e){var n=[],t=/\{([a-z])-([a-z])\}/.exec(e);if(t){var r=t[1].charCodeAt(0),i=t[2].charCodeAt(0),o=void 0;for(o=r;o<=i;++o)n.push(e.replace(t[0],String.fromCharCode(o)));return n}if(t=/\{(\d+)-(\d+)\}/.exec(e),t){for(var s=parseInt(t[2],10),a=parseInt(t[1],10);a<=s;a++)n.push(e.replace(t[0],a.toString()));return n}return n.push(e),n}var Zae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Xae=function(e){Zae(n,e);function n(t){var r=e.call(this,{attributions:t.attributions,cacheSize:t.cacheSize,opaque:t.opaque,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tilePixelRatio:t.tilePixelRatio,wrapX:t.wrapX,transition:t.transition,interpolate:t.interpolate,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection})||this;return r.generateTileUrlFunction_=r.tileUrlFunction===n.prototype.tileUrlFunction,r.tileLoadFunction=t.tileLoadFunction,t.tileUrlFunction&&(r.tileUrlFunction=t.tileUrlFunction),r.urls=null,t.urls?r.setUrls(t.urls):t.url&&r.setUrl(t.url),r.tileLoadingKeys_={},r}return n.prototype.getTileLoadFunction=function(){return this.tileLoadFunction},n.prototype.getTileUrlFunction=function(){return Object.getPrototypeOf(this).tileUrlFunction===this.tileUrlFunction?this.tileUrlFunction.bind(this):this.tileUrlFunction},n.prototype.getUrls=function(){return this.urls},n.prototype.handleTileChange=function(t){var r=t.target,i=$i(r),o=r.getState(),s;o==mr.LOADING?(this.tileLoadingKeys_[i]=!0,s=bM.TILELOADSTART):i in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[i],s=o==mr.ERROR?bM.TILELOADERROR:o==mr.LOADED?bM.TILELOADEND:void 0),s!=null&&this.dispatchEvent(new $ae(s,r))},n.prototype.setTileLoadFunction=function(t){this.tileCache.clear(),this.tileLoadFunction=t,this.changed()},n.prototype.setTileUrlFunction=function(t,r){this.tileUrlFunction=t,this.tileCache.pruneExceptNewestZ(),typeof r<"u"?this.setKey(r):this.changed()},n.prototype.setUrl=function(t){var r=Hae(t);this.urls=r,this.setUrls(r)},n.prototype.setUrls=function(t){this.urls=t;var r=t.join(`
|
||
`);this.generateTileUrlFunction_?this.setTileUrlFunction(Dz(t,this.tileGrid),r):this.setKey(r)},n.prototype.tileUrlFunction=function(t,r,i){},n.prototype.useTile=function(t,r,i){var o=Wy(t,r,i);this.tileCache.containsKey(o)&&this.tileCache.get(o)},n}(Yae);const Uz=Xae;var Jae=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),ese=function(e){Jae(n,e);function n(t){var r=this,i=t.imageSmoothing!==void 0?t.imageSmoothing:!0;return t.interpolate!==void 0&&(i=t.interpolate),r=e.call(this,{attributions:t.attributions,cacheSize:t.cacheSize,opaque:t.opaque,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:tse,tilePixelRatio:t.tilePixelRatio,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:t.wrapX,transition:t.transition,interpolate:i,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection})||this,r.crossOrigin=t.crossOrigin!==void 0?t.crossOrigin:null,r.tileClass=t.tileClass!==void 0?t.tileClass:kz,r.tileCacheForProjection={},r.tileGridForProjection={},r.reprojectionErrorThreshold_=t.reprojectionErrorThreshold,r.renderReprojectionEdges_=!1,r}return n.prototype.canExpireCache=function(){if(this.tileCache.canExpireCache())return!0;for(var t in this.tileCacheForProjection)if(this.tileCacheForProjection[t].canExpireCache())return!0;return!1},n.prototype.expireCache=function(t,r){var i=this.getTileCacheForProjection(t);this.tileCache.expireCache(this.tileCache==i?r:{});for(var o in this.tileCacheForProjection){var s=this.tileCacheForProjection[o];s.expireCache(s==i?r:{})}},n.prototype.getGutterForProjection=function(t){return this.getProjection()&&t&&!I0(this.getProjection(),t)?0:this.getGutter()},n.prototype.getGutter=function(){return 0},n.prototype.getKey=function(){var t=e.prototype.getKey.call(this);return this.getInterpolate()||(t+=":disable-interpolation"),t},n.prototype.getOpaque=function(t){return this.getProjection()&&t&&!I0(this.getProjection(),t)?!1:e.prototype.getOpaque.call(this,t)},n.prototype.getTileGridForProjection=function(t){var r=this.getProjection();if(this.tileGrid&&(!r||I0(r,t)))return this.tileGrid;var i=$i(t);return i in this.tileGridForProjection||(this.tileGridForProjection[i]=Kz(t)),this.tileGridForProjection[i]},n.prototype.getTileCacheForProjection=function(t){var r=this.getProjection();if(!r||I0(r,t))return this.tileCache;var i=$i(t);return i in this.tileCacheForProjection||(this.tileCacheForProjection[i]=new y7(this.tileCache.highWaterMark)),this.tileCacheForProjection[i]},n.prototype.createTile_=function(t,r,i,o,s,a){var f=[t,r,i],g=this.getTileCoordForTileUrlFunction(f,s),x=g?this.tileUrlFunction(g,o,s):void 0,k=new this.tileClass(f,x!==void 0?mr.IDLE:mr.EMPTY,x!==void 0?x:"",this.crossOrigin,this.tileLoadFunction,this.tileOptions);return k.key=a,k.addEventListener(ki.CHANGE,this.handleTileChange.bind(this)),k},n.prototype.getTile=function(t,r,i,o,s){var a=this.getProjection();if(!a||!s||I0(a,s))return this.getTileInternal(t,r,i,o,a||s);var f=this.getTileCacheForProjection(s),g=[t,r,i],x=void 0,k=Oz(g);f.containsKey(k)&&(x=f.get(k));var B=this.getKey();if(x&&x.key==B)return x;var P=this.getTileGridForProjection(a),R=this.getTileGridForProjection(s),H=this.getTileCoordForTileUrlFunction(g,s),W=new Tz(a,P,s,R,g,H,this.getTilePixelRatio(o),this.getGutter(),(function($,q,oe,ne){return this.getTileInternal($,q,oe,ne,a)}).bind(this),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.getInterpolate());return W.key=B,x?(W.interimTile=x,W.refreshInterimChain(),f.replace(k,W)):f.set(k,W),W},n.prototype.getTileInternal=function(t,r,i,o,s){var a=null,f=Wy(t,r,i),g=this.getKey();if(!this.tileCache.containsKey(f))a=this.createTile_(t,r,i,o,s,g),this.tileCache.set(f,a);else if(a=this.tileCache.get(f),a.key!=g){var x=a;a=this.createTile_(t,r,i,o,s,g),x.getState()==mr.IDLE?a.interimTile=x.interimTile:a.interimTile=x,a.refreshInterimChain(),this.tileCache.replace(f,a)}return a},n.prototype.setRenderReprojectionEdges=function(t){if(this.renderReprojectionEdges_!=t){this.renderReprojectionEdges_=t;for(var r in this.tileCacheForProjection)this.tileCacheForProjection[r].clear();this.changed()}},n.prototype.setTileGridForProjection=function(t,r){{var i=Fs(t);if(i){var o=$i(i);o in this.tileGridForProjection||(this.tileGridForProjection[o]=r)}}},n}(Uz);function tse(e,n){e.getImage().src=n}const nse=ese;var Rz=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}();function rse(e,n,t,r){var i=document.createElement("script"),o="olc_"+$i(n);function s(){delete window[o],i.parentNode.removeChild(i)}i.async=!0,i.src=e+(e.indexOf("?")==-1?"?":"&")+(r||"callback")+"="+o;var a=setTimeout(function(){s(),t&&t()},1e4);window[o]=function(f){clearTimeout(a),s(),n(f)},document.head.appendChild(i)}(function(e){Rz(n,e);function n(t){var r=this,i="Unexpected response status: "+t.status;return r=e.call(this,i)||this,r.name="ResponseError",r.response=t,r}return n})(Error);(function(e){Rz(n,e);function n(t){var r=e.call(this,"Failed to issue request")||this;return r.name="ClientError",r.client=t,r}return n})(Error);var ise=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),ose=function(e){ise(n,e);function n(t){var r=this,i=t.imageSmoothing!==void 0?t.imageSmoothing:!0;if(t.interpolate!==void 0&&(i=t.interpolate),r=e.call(this,{attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:i,projection:Fs("EPSG:3857"),reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection})||this,r.tileJSON_=null,r.tileSize_=t.tileSize,t.url)if(t.jsonp)rse(t.url,r.handleTileJSONResponse.bind(r),r.handleTileJSONError.bind(r));else{var o=new XMLHttpRequest;o.addEventListener("load",r.onXHRLoad_.bind(r)),o.addEventListener("error",r.onXHRError_.bind(r)),o.open("GET",t.url),o.send()}else t.tileJSON?r.handleTileJSONResponse(t.tileJSON):ao(!1,51);return r}return n.prototype.onXHRLoad_=function(t){var r=t.target;if(!r.status||r.status>=200&&r.status<300){var i=void 0;try{i=JSON.parse(r.responseText)}catch{this.handleTileJSONError();return}this.handleTileJSONResponse(i)}else this.handleTileJSONError()},n.prototype.onXHRError_=function(t){this.handleTileJSONError()},n.prototype.getTileJSON=function(){return this.tileJSON_},n.prototype.handleTileJSONResponse=function(t){var r=Fs("EPSG:4326"),i=this.getProjection(),o;if(t.bounds!==void 0){var s=u5(r,i);o=Lee(t.bounds,s)}var a=m5(i),f=t.minzoom||0,g=t.maxzoom||22,x=v7({extent:a,maxZoom:g,minZoom:f,tileSize:this.tileSize_});if(this.tileGrid=x,this.tileUrlFunction=Dz(t.tiles,x),t.attribution!==void 0&&!this.getAttributions()){var k=o!==void 0?o:a;this.setAttributions(function(B){return il(k,B.extent)?[t.attribution]:null})}this.tileJSON_=t,this.setState("ready")},n.prototype.handleTileJSONError=function(){this.setState("error")},n}(nse);const Lz=ose,fm={PRELOAD:"preload",USE_INTERIM_TILES_ON_ERROR:"useInterimTilesOnError"};var ase=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),sse=function(e){ase(n,e);function n(t){var r=this,i=t||{},o=al({},i);return delete o.preload,delete o.useInterimTilesOnError,r=e.call(this,o)||this,r.on,r.once,r.un,r.setPreload(i.preload!==void 0?i.preload:0),r.setUseInterimTilesOnError(i.useInterimTilesOnError!==void 0?i.useInterimTilesOnError:!0),r}return n.prototype.getPreload=function(){return this.get(fm.PRELOAD)},n.prototype.setPreload=function(t){this.set(fm.PRELOAD,t)},n.prototype.getUseInterimTilesOnError=function(){return this.get(fm.USE_INTERIM_TILES_ON_ERROR)},n.prototype.setUseInterimTilesOnError=function(t){this.set(fm.USE_INTERIM_TILES_ON_ERROR,t)},n.prototype.getData=function(t){return e.prototype.getData.call(this,t)},n}(d5);const lse=sse;var use=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Ase=function(e){use(n,e);function n(t){var r=e.call(this,t)||this;return r.extentChanged=!0,r.renderedExtent_=null,r.renderedPixelRatio,r.renderedProjection=null,r.renderedRevision,r.renderedTiles=[],r.newTiles_=!1,r.tmpExtent=Ed(),r.tmpTileRange_=new Ez(0,0,0,0),r}return n.prototype.isDrawableTile=function(t){var r=this.getLayer(),i=t.getState(),o=r.getUseInterimTilesOnError();return i==mr.LOADED||i==mr.EMPTY||i==mr.ERROR&&!o},n.prototype.getTile=function(t,r,i,o){var s=o.pixelRatio,a=o.viewState.projection,f=this.getLayer(),g=f.getSource(),x=g.getTile(t,r,i,s,a);return x.getState()==mr.ERROR&&(f.getUseInterimTilesOnError()?f.getPreload()>0&&(this.newTiles_=!0):x.setState(mr.LOADED)),this.isDrawableTile(x)||(x=x.getInterimTile()),x},n.prototype.getData=function(t){var r=this.frameState;if(!r)return null;var i=this.getLayer(),o=rl(r.pixelToCoordinateTransform,t.slice()),s=i.getExtent();if(s&&!$_(s,o))return null;for(var a=r.pixelRatio,f=r.viewState.projection,g=r.viewState,x=i.getRenderSource(),k=x.getTileGridForProjection(g.projection),B=x.getTilePixelRatio(r.pixelRatio),P=k.getZForResolution(g.resolution);P>=k.getMinZoom();--P){var R=k.getTileCoordForCoordAndZ(o,P),H=x.getTile(P,R[1],R[2],a,f);if(!(H instanceof kz||H instanceof Tz))return null;if(H.getState()===mr.LOADED){var W=k.getOrigin(P),$=pA(k.getTileSize(P)),q=k.getResolution(P),oe=Math.floor(B*((o[0]-W[0])/q-R[1]*$[0])),ne=Math.floor(B*((W[1]-o[1])/q-R[2]*$[1])),ce=Math.round(B*x.getGutterForProjection(g.projection));return this.getImageData(H.getImage(),oe+ce,ne+ce)}}return null},n.prototype.loadedTileCallback=function(t,r,i){return this.isDrawableTile(i)?e.prototype.loadedTileCallback.call(this,t,r,i):!1},n.prototype.prepareFrame=function(t){return!!this.getLayer().getSource()},n.prototype.renderFrame=function(t,r){var i=t.layerStatesArray[t.layerIndex],o=t.viewState,s=o.projection,a=o.resolution,f=o.center,g=o.rotation,x=t.pixelRatio,k=this.getLayer(),B=k.getSource(),P=B.getRevision(),R=B.getTileGridForProjection(s),H=R.getZForResolution(a,B.zDirection),W=R.getResolution(H),$=t.extent,q=t.viewState.resolution,oe=B.getTilePixelRatio(x),ne=Math.round(os($)/q*x),ce=Math.round($A($)/q*x),ae=i.extent&&j0(i.extent);ae&&($=X0($,j0(i.extent)));var ue=W*ne/2/oe,ye=W*ce/2/oe,Re=[f[0]-ue,f[1]-ye,f[0]+ue,f[1]+ye],Ne=R.getTileRangeForExtentAndZ($,H),rt={};rt[H]={};var ct=this.createLoadedTileFinder(B,s,rt),Fe=this.tmpExtent,He=this.tmpTileRange_;this.newTiles_=!1;for(var Ce=g?j6(o.center,q,g,t.size):void 0,jt=Ne.minX;jt<=Ne.maxX;++jt)for(var Ft=Ne.minY;Ft<=Ne.maxY;++Ft)if(!(g&&!R.tileCoordIntersectsViewport([H,jt,Ft],Ce))){var Jt=this.getTile(H,jt,Ft,t);if(this.isDrawableTile(Jt)){var Nt=$i(this);if(Jt.getState()==mr.LOADED){rt[H][Jt.tileCoord.toString()]=Jt;var Ve=Jt.inTransition(Nt);Ve&&i.opacity!==1&&(Jt.endTransition(Nt),Ve=!1),!this.newTiles_&&(Ve||this.renderedTiles.indexOf(Jt)===-1)&&(this.newTiles_=!0)}if(Jt.getAlpha(Nt,t.time)===1)continue}var nt=R.getTileCoordChildTileRange(Jt.tileCoord,He,Fe),Je=!1;nt&&(Je=ct(H+1,nt)),Je||R.forEachTileCoordParentTileRange(Jt.tileCoord,ct,He,Fe)}var Vt=W/a*x/oe;df(this.pixelTransform,t.size[0]/2,t.size[1]/2,1/x,1/x,g,-ne/2,-ce/2);var pt=fL(this.pixelTransform);this.useContainer(r,pt,this.getBackground(t));var dt=this.context,kt=dt.canvas;zB(this.inversePixelTransform,this.pixelTransform),df(this.tempTransform,ne/2,ce/2,Vt,Vt,0,-ne/2,-ce/2),kt.width!=ne||kt.height!=ce?(kt.width=ne,kt.height=ce):this.containerReused||dt.clearRect(0,0,ne,ce),ae&&this.clipUnrotated(dt,t,ae),B.getInterpolate()||al(dt,oE),this.preRender(dt,t),this.renderedTiles.length=0;var Dt=Object.keys(rt).map(Number);Dt.sort(c1);var Se,de,xe;i.opacity===1&&(!this.containerReused||B.getOpaque(t.viewState.projection))?Dt=Dt.reverse():(Se=[],de=[]);for(var Pe=Dt.length-1;Pe>=0;--Pe){var Ze=Dt[Pe],Xe=B.getTilePixelSize(Ze,x,s),wt=R.getResolution(Ze),Kt=wt/W,Pt=Xe[0]*Kt*Vt,zn=Xe[1]*Kt*Vt,mt=R.getTileCoordForCoordAndZ(Lm(Re),Ze),pn=R.getTileCoordExtent(mt),ir=rl(this.tempTransform,[oe*(pn[0]-Re[0])/W,oe*(Re[3]-pn[3])/W]),Sn=oe*B.getGutterForProjection(s),nr=rt[Ze];for(var Mr in nr){var Jt=nr[Mr],Qr=Jt.tileCoord,_r=mt[1]-Qr[1],vi=Math.round(ir[0]-(_r-1)*Pt),we=mt[2]-Qr[2],V=Math.round(ir[1]-(we-1)*zn),jt=Math.round(ir[0]-_r*Pt),Ft=Math.round(ir[1]-we*zn),X=vi-jt,me=V-Ft,At=H===Ze,Ve=At&&Jt.getAlpha($i(this),t.time)!==1,bt=!1;if(!Ve)if(Se){xe=[jt,Ft,jt+X,Ft,jt+X,Ft+me,jt,Ft+me];for(var Et=0,sr=Se.length;Et<sr;++Et)if(H!==Ze&&Ze<de[Et]){var Lt=Se[Et];il([jt,Ft,jt+X,Ft+me],[Lt[0],Lt[3],Lt[4],Lt[7]])&&(bt||(dt.save(),bt=!0),dt.beginPath(),dt.moveTo(xe[0],xe[1]),dt.lineTo(xe[2],xe[3]),dt.lineTo(xe[4],xe[5]),dt.lineTo(xe[6],xe[7]),dt.moveTo(Lt[6],Lt[7]),dt.lineTo(Lt[4],Lt[5]),dt.lineTo(Lt[2],Lt[3]),dt.lineTo(Lt[0],Lt[1]),dt.clip())}Se.push(xe),de.push(Ze)}else dt.clearRect(jt,Ft,X,me);this.drawTileImage(Jt,t,jt,Ft,X,me,Sn,At),Se&&!Ve?(bt&&dt.restore(),this.renderedTiles.unshift(Jt)):this.renderedTiles.push(Jt),this.updateUsedTiles(t.usedTiles,B,Jt)}}return this.renderedRevision=P,this.renderedResolution=W,this.extentChanged=!this.renderedExtent_||!wy(this.renderedExtent_,Re),this.renderedExtent_=Re,this.renderedPixelRatio=x,this.renderedProjection=s,this.manageTilePyramid(t,B,R,x,s,$,H,k.getPreload()),this.scheduleExpireCache(t,B),this.postRender(dt,t),i.extent&&dt.restore(),al(dt,Tae),pt!==kt.style.transform&&(kt.style.transform=pt),this.container},n.prototype.drawTileImage=function(t,r,i,o,s,a,f,g){var x=this.getTileImage(t);if(x){var k=$i(this),B=r.layerStatesArray[r.layerIndex],P=B.opacity*(g?t.getAlpha(k,r.time):1),R=P!==this.context.globalAlpha;R&&(this.context.save(),this.context.globalAlpha=P),this.context.drawImage(x,f,f,x.width-2*f,x.height-2*f,i,o,s,a),R&&this.context.restore(),P!==B.opacity?r.animate=!0:g&&t.endTransition(k)}},n.prototype.getImage=function(){var t=this.context;return t?t.canvas:null},n.prototype.getTileImage=function(t){return t.getImage()},n.prototype.scheduleExpireCache=function(t,r){if(r.canExpireCache()){var i=(function(o,s,a){var f=$i(o);f in a.usedTiles&&o.expireCache(a.viewState.projection,a.usedTiles[f])}).bind(null,r);t.postRenderFunctions.push(i)}},n.prototype.updateUsedTiles=function(t,r,i){var o=$i(r);o in t||(t[o]={}),t[o][i.getKey()]=!0},n.prototype.manageTilePyramid=function(t,r,i,o,s,a,f,g,x){var k=$i(r);k in t.wantedTiles||(t.wantedTiles[k]={});var B=t.wantedTiles[k],P=t.tileQueue,R=i.getMinZoom(),H=t.viewState.rotation,W=H?j6(t.viewState.center,t.viewState.resolution,H,t.size):void 0,$=0,q,oe,ne,ce,ae,ue;for(ue=R;ue<=f;++ue)for(oe=i.getTileRangeForExtentAndZ(a,ue,oe),ne=i.getResolution(ue),ce=oe.minX;ce<=oe.maxX;++ce)for(ae=oe.minY;ae<=oe.maxY;++ae)H&&!i.tileCoordIntersectsViewport([ue,ce,ae],W)||(f-ue<=g?(++$,q=r.getTile(ue,ce,ae,o,s),q.getState()==mr.IDLE&&(B[q.getKey()]=!0,P.isKeyQueued(q.getKey())||P.enqueue([q,k,i.getTileCoordCenter(q.tileCoord),ne])),x!==void 0&&x(q)):r.useTile(ue,ce,ae,s));r.updateCacheSize($,s)},n}(fz);const zz=Ase;var cse=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),dse=function(e){cse(n,e);function n(t){return e.call(this,t)||this}return n.prototype.createRenderer=function(){return new zz(this)},n}(lse);const pm={IMAGE:"image",HYBRID:"hybrid",VECTOR:"vector"};var hse=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),fse={image:["Polygon","Circle","LineString","Image","Text"],hybrid:["Polygon","LineString"],vector:[]},pse={hybrid:["Image","Text","Default"],vector:["Polygon","Circle","LineString","Image","Text","Default"]},mse=function(e){hse(n,e);function n(t){var r=e.call(this,t)||this;return r.boundHandleStyleImageChange_=r.handleStyleImageChange_.bind(r),r.renderedLayerRevision_,r.renderedPixelToCoordinateTransform_=null,r.renderedRotation_,r.tmpTransform_=xd(),r}return n.prototype.prepareTile=function(t,r,i){var o,s=t.getState();return(s===mr.LOADED||s===mr.ERROR)&&(this.updateExecutorGroup_(t,r,i),this.tileImageNeedsRender_(t)&&(o=!0)),o},n.prototype.getTile=function(t,r,i,o){var s=o.pixelRatio,a=o.viewState,f=a.resolution,g=a.projection,x=this.getLayer(),k=x.getSource().getTile(t,r,i,s,g),B=o.viewHints,P=!(B[Gs.ANIMATING]||B[Gs.INTERACTING]);(P||!k.wantedResolution)&&(k.wantedResolution=f);var R=this.prepareTile(k,s,g);return R&&(P||Date.now()-o.time<8)&&x.getRenderMode()!==pm.VECTOR&&this.renderTileImage_(k,o),e.prototype.getTile.call(this,t,r,i,o)},n.prototype.isDrawableTile=function(t){var r=this.getLayer();return e.prototype.isDrawableTile.call(this,t)&&(r.getRenderMode()===pm.VECTOR?$i(r)in t.executorGroups:t.hasContext(r))},n.prototype.getTileImage=function(t){return t.getImage(this.getLayer())},n.prototype.prepareFrame=function(t){var r=this.getLayer().getRevision();return this.renderedLayerRevision_!==r&&(this.renderedLayerRevision_=r,this.renderedTiles.length=0),e.prototype.prepareFrame.call(this,t)},n.prototype.updateExecutorGroup_=function(t,r,i){var o=this.getLayer(),s=o.getRevision(),a=o.getRenderOrder()||null,f=t.wantedResolution,g=t.getReplayState(o);if(!(!g.dirty&&g.renderedResolution===f&&g.renderedRevision==s&&g.renderedRenderOrder==a)){var x=o.getSource(),k=o.getDeclutter(),B=x.getTileGrid(),P=x.getTileGridForProjection(i),R=P.getTileCoordExtent(t.wrappedTileCoord),H=x.getSourceTiles(r,i,t),W=$i(o);delete t.hitDetectionImageData[W],t.executorGroups[W]=[],k&&(t.declutterExecutorGroups[W]=[]),g.dirty=!1;for(var $=function(ce,ae){var ue=H[ce];if(ue.getState()!=mr.LOADED)return"continue";var ye=ue.tileCoord,Re=B.getTileCoordExtent(ye),Ne=X0(R,Re),rt=Em(Ne,o.getRenderBuffer()*f,q.tmpExtent),ct=wy(Re,Ne)?null:rt,Fe=new K3(0,rt,f,r),He=k?new K3(0,Ne,f,r):void 0,Ce=vz(f,r),jt=function(dt){var kt,Dt=dt.getStyleFunction()||o.getStyleFunction();if(Dt&&(kt=Dt(dt,f)),kt){var Se=this.renderFeature(dt,Ce,kt,Fe,He);g.dirty=g.dirty||Se}},Ft=ue.getFeatures();a&&a!==g.renderedRenderOrder&&Ft.sort(a);for(var Jt=0,Nt=Ft.length;Jt<Nt;++Jt){var Ve=Ft[Jt];(!ct||il(ct,Ve.getGeometry().getExtent()))&&jt.call(q,Ve)}var nt=Fe.finish(),Je=o.getRenderMode()!==pm.VECTOR&&k&&H.length===1?null:Ne,Vt=new P3(Je,f,r,x.getOverlaps(),nt,o.getRenderBuffer());if(t.executorGroups[W].push(Vt),He){var pt=new P3(null,f,r,x.getOverlaps(),He.finish(),o.getRenderBuffer());t.declutterExecutorGroups[W].push(pt)}},q=this,oe=0,ne=H.length;oe<ne;++oe)$(oe);g.renderedRevision=s,g.renderedRenderOrder=a,g.renderedResolution=f}},n.prototype.forEachFeatureAtCoordinate=function(t,r,i,o,s){var a=r.viewState.resolution,f=r.viewState.rotation;i=i??0;var g=this.getLayer(),x=g.getSource(),k=x.getTileGridForProjection(r.viewState.projection),B=U6([t]);Em(B,a*i,B);for(var P={},R=function(ne,ce,ae){var ue=ne.getId();ue===void 0&&(ue=$i(ne));var ye=P[ue];if(ye){if(ye!==!0&&ae<ye.distanceSq){if(ae===0)return P[ue]=!0,s.splice(s.lastIndexOf(ye),1),o(ne,g,ce);ye.geometry=ce,ye.distanceSq=ae}}else{if(ae===0)return P[ue]=!0,o(ne,g,ce);s.push(P[ue]={feature:ne,layer:g,geometry:ce,distanceSq:ae,callback:o})}},H=this.renderedTiles,W,$=function(ne,ce){var ae=H[ne],ue=k.getTileCoordExtent(ae.wrappedTileCoord);if(!il(ue,B))return"continue";var ye=$i(g),Re=[ae.executorGroups[ye]],Ne=ae.declutterExecutorGroups[ye];Ne&&Re.push(Ne),Re.some(function(rt){for(var ct=rt===Ne?r.declutterTree.all().map(function(jt){return jt.value}):null,Fe=0,He=rt.length;Fe<He;++Fe){var Ce=rt[Fe];if(W=Ce.forEachFeatureAtCoordinate(t,a,f,i,R,ct),W)return!0}})},q=0,oe=H.length;!W&&q<oe;++q)$(q);return W},n.prototype.getFeatures=function(t){return new Promise((function(r,i){for(var o=this.getLayer(),s=$i(o),a=o.getSource(),f=this.renderedProjection,g=f.getExtent(),x=this.renderedResolution,k=a.getTileGridForProjection(f),B=rl(this.renderedPixelToCoordinateTransform_,t.slice()),P=k.getTileCoordForCoordAndResolution(B,x),R,H=0,W=this.renderedTiles.length;H<W;++H)if(P.toString()===this.renderedTiles[H].tileCoord.toString()){if(R=this.renderedTiles[H],R.getState()===mr.LOADED){var $=k.getTileCoordExtent(R.tileCoord);a.getWrapX()&&f.canWrapX()&&!cm(g,$)&&$B(B,f);break}R=void 0}if(!R||R.loadingSourceTiles>0){r([]);return}var q=k.getTileCoordExtent(R.wrappedTileCoord),oe=Lm(q),ne=[(B[0]-oe[0])/x,(oe[1]-B[1])/x],ce=R.getSourceTiles().reduce(function(Ne,rt){return Ne.concat(rt.getFeatures())},[]),ae=R.hitDetectionImageData[s];if(!ae&&!this.animatingOrInteracting_){var ue=pA(k.getTileSize(k.getZForResolution(x,a.zDirection))),ye=this.renderedRotation_,Re=[this.getRenderTransform(k.getTileCoordCenter(R.wrappedTileCoord),x,0,Dc,ue[0]*Dc,ue[1]*Dc,0)];ae=mz(ue,Re,ce,o.getStyleFunction(),k.getTileCoordExtent(R.wrappedTileCoord),R.getReplayState(o).renderedResolution,ye),R.hitDetectionImageData[s]=ae}r(gz(ne,ce,ae))}).bind(this))},n.prototype.handleFontsChanged=function(){var t=this.getLayer();t.getVisible()&&this.renderedLayerRevision_!==void 0&&t.changed()},n.prototype.handleStyleImageChange_=function(t){this.renderIfReadyAndVisible()},n.prototype.renderDeclutter=function(t){var r=this.context,i=r.globalAlpha;r.globalAlpha=this.getLayer().getOpacity();for(var o=t.viewHints,s=!(o[Gs.ANIMATING]||o[Gs.INTERACTING]),a=this.renderedTiles,f=0,g=a.length;f<g;++f){var x=a[f],k=x.declutterExecutorGroups[$i(this.getLayer())];if(k)for(var B=k.length-1;B>=0;--B)k[B].execute(this.context,1,this.getTileRenderTransform(x,t),t.viewState.rotation,s,void 0,t.declutterTree)}r.globalAlpha=i},n.prototype.getTileRenderTransform=function(t,r){var i=r.pixelRatio,o=r.viewState,s=o.center,a=o.resolution,f=o.rotation,g=r.size,x=Math.round(g[0]*i),k=Math.round(g[1]*i),B=this.getLayer().getSource(),P=B.getTileGridForProjection(r.viewState.projection),R=t.tileCoord,H=P.getTileCoordExtent(t.wrappedTileCoord),W=P.getTileCoordExtent(R,this.tmpExtent)[0]-H[0],$=LB(sM(this.inversePixelTransform.slice(),1/i,1/i),this.getRenderTransform(s,a,f,i,x,k,W));return $},n.prototype.renderFrame=function(t,r){var i=t.viewHints,o=!(i[Gs.ANIMATING]||i[Gs.INTERACTING]);e.prototype.renderFrame.call(this,t,r),this.renderedPixelToCoordinateTransform_=t.pixelToCoordinateTransform.slice(),this.renderedRotation_=t.viewState.rotation;var s=this.getLayer(),a=s.getRenderMode(),f=this.context,g=f.globalAlpha;f.globalAlpha=s.getOpacity();for(var x=pse[a],k=t.viewState,B=k.rotation,P=s.getSource(),R=P.getTileGridForProjection(k.projection),H=R.getZForResolution(k.resolution,P.zDirection),W=this.renderedTiles,$=[],q=[],oe=!0,ne=W.length-1;ne>=0;--ne){var ce=W[ne];oe=oe&&!ce.getReplayState(s).dirty;var ae=ce.executorGroups[$i(s)].filter(function(Ft){return Ft.hasExecutors(x)});if(ae.length!==0){var ue=this.getTileRenderTransform(ce,t),ye=ce.tileCoord[0],Re=!1,Ne=ae[0].getClipCoords(ue);if(Ne){for(var rt=0,ct=$.length;rt<ct;++rt)if(H!==ye&&ye<q[rt]){var Fe=$[rt];il([Ne[0],Ne[3],Ne[4],Ne[7]],[Fe[0],Fe[3],Fe[4],Fe[7]])&&(Re||(f.save(),Re=!0),f.beginPath(),f.moveTo(Ne[0],Ne[1]),f.lineTo(Ne[2],Ne[3]),f.lineTo(Ne[4],Ne[5]),f.lineTo(Ne[6],Ne[7]),f.moveTo(Fe[6],Fe[7]),f.lineTo(Fe[4],Fe[5]),f.lineTo(Fe[2],Fe[3]),f.lineTo(Fe[0],Fe[1]),f.clip())}$.push(Ne),q.push(ye)}for(var He=0,Ce=ae.length;He<Ce;++He){var jt=ae[He];jt.execute(f,1,ue,B,o,x)}Re&&f.restore()}}return f.globalAlpha=g,this.ready=oe,this.container},n.prototype.renderFeature=function(t,r,i,o,s){if(!i)return!1;var a=!1;if(Array.isArray(i))for(var f=0,g=i.length;f<g;++f)a=F3(o,t,i[f],r,this.boundHandleStyleImageChange_,void 0,s)||a;else a=F3(o,t,i,r,this.boundHandleStyleImageChange_,void 0,s);return a},n.prototype.tileImageNeedsRender_=function(t){var r=this.getLayer();if(r.getRenderMode()===pm.VECTOR)return!1;var i=t.getReplayState(r),o=r.getRevision(),s=t.wantedResolution;return i.renderedTileResolution!==s||i.renderedTileRevision!==o},n.prototype.renderTileImage_=function(t,r){var i=this.getLayer(),o=t.getReplayState(i),s=i.getRevision(),a=t.executorGroups[$i(i)];o.renderedTileRevision=s;var f=t.wrappedTileCoord,g=f[0],x=i.getSource(),k=r.pixelRatio,B=r.viewState,P=B.projection,R=x.getTileGridForProjection(P),H=R.getResolution(t.tileCoord[0]),W=r.pixelRatio/t.wantedResolution*H,$=R.getResolution(g),q=t.getContext(i);k=Math.round(Math.max(k,W/k));var oe=x.getTilePixelSize(g,k,P);q.canvas.width=oe[0],q.canvas.height=oe[1];var ne=k/W;if(ne!==1){var ce=r9(this.tmpTransform_);sM(ce,ne,ne),q.setTransform.apply(q,ce)}var ae=R.getTileCoordExtent(f,this.tmpExtent),ue=W/$,ye=r9(this.tmpTransform_);sM(ye,ue,-ue),Tee(ye,-ae[0],-ae[3]);for(var Re=0,Ne=a.length;Re<Ne;++Re){var rt=a[Re];rt.execute(q,ne,ye,0,!0,fse[i.getRenderMode()])}o.renderedTileResolution=t.wantedResolution},n}(zz);const gse=mse;var yse=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),jz=function(e){yse(n,e);function n(t){var r=this,i=t||{},o=al({},i);delete o.preload,delete o.useInterimTilesOnError,r=e.call(this,o)||this,r.on,r.once,r.un,i.renderMode===pm.IMAGE&&(console.warn('renderMode: "image" is deprecated. Option ignored.'),i.renderMode=void 0);var s=i.renderMode||pm.HYBRID;return ao(s==pm.HYBRID||s==pm.VECTOR,28),r.renderMode_=s,r.setPreload(i.preload?i.preload:0),r.setUseInterimTilesOnError(i.useInterimTilesOnError!==void 0?i.useInterimTilesOnError:!0),r.getBackground,r.setBackground,r}return n.prototype.createRenderer=function(){return new gse(this)},n.prototype.getFeatures=function(t){return e.prototype.getFeatures.call(this,t)},n.prototype.getRenderMode=function(){return this.renderMode_},n.prototype.getPreload=function(){return this.get(fm.PRELOAD)},n.prototype.getUseInterimTilesOnError=function(){return this.get(fm.USE_INTERIM_TILES_ON_ERROR)},n.prototype.setPreload=function(t){this.set(fm.PRELOAD,t)},n.prototype.setUseInterimTilesOnError=function(t){this.set(fm.USE_INTERIM_TILES_ON_ERROR,t)},n}(cz),vse=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Cse=function(e){vse(n,e);function n(t,r,i,o,s,a){var f=e.call(this,t,r,a)||this;return f.extent=null,f.format_=o,f.features_=null,f.loader_,f.projection=null,f.resolution,f.tileLoadFunction_=s,f.url_=i,f.key=i,f}return n.prototype.getFormat=function(){return this.format_},n.prototype.getFeatures=function(){return this.features_},n.prototype.load=function(){this.state==mr.IDLE&&(this.setState(mr.LOADING),this.tileLoadFunction_(this,this.url_),this.loader_&&this.loader_(this.extent,this.resolution,this.projection))},n.prototype.onLoad=function(t,r){this.setFeatures(t)},n.prototype.onError=function(){this.setState(mr.ERROR)},n.prototype.setFeatures=function(t){this.features_=t,this.setState(mr.LOADED)},n.prototype.setLoader=function(t){this.loader_=t},n}(p5);const _se=Cse;var bse=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),V9=[],xse=function(e){bse(n,e);function n(t,r,i,o){var s=e.call(this,t,r,{transition:0})||this;return s.context_={},s.executorGroups={},s.declutterExecutorGroups={},s.loadingSourceTiles=0,s.hitDetectionImageData={},s.replayState_={},s.sourceTiles=[],s.errorTileKeys={},s.wantedResolution,s.getSourceTiles=o.bind(void 0,s),s.wrappedTileCoord=i,s}return n.prototype.getContext=function(t){var r=$i(t);return r in this.context_||(this.context_[r]=YA(1,1,V9)),this.context_[r]},n.prototype.hasContext=function(t){return $i(t)in this.context_},n.prototype.getImage=function(t){return this.hasContext(t)?this.getContext(t).canvas:null},n.prototype.getReplayState=function(t){var r=$i(t);return r in this.replayState_||(this.replayState_[r]={dirty:!1,renderedRenderOrder:null,renderedResolution:NaN,renderedRevision:-1,renderedTileResolution:NaN,renderedTileRevision:-1,renderedTileZ:-1}),this.replayState_[r]},n.prototype.load=function(){this.getSourceTiles()},n.prototype.release=function(){for(var t in this.context_){var r=this.context_[t];l7(r),V9.push(r.canvas),delete this.context_[t]}e.prototype.release.call(this)},n}(p5);const wse=xse;var Mse=function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},e(n,t)};return function(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Sse=function(e){Mse(n,e);function n(t){var r=this,i=t.projection||"EPSG:3857",o=t.extent||m5(i),s=t.tileGrid||v7({extent:o,maxResolution:t.maxResolution,maxZoom:t.maxZoom!==void 0?t.maxZoom:22,minZoom:t.minZoom,tileSize:t.tileSize||512});return r=e.call(this,{attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,interpolate:!0,opaque:!1,projection:i,state:t.state,tileGrid:s,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:Ese,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:t.wrapX===void 0?!0:t.wrapX,transition:t.transition,zDirection:t.zDirection===void 0?1:t.zDirection})||this,r.format_=t.format?t.format:null,r.sourceTileCache=new y7(r.tileCache.highWaterMark),r.overlaps_=t.overlaps==null?!0:t.overlaps,r.tileClass=t.tileClass?t.tileClass:_se,r.tileGrids_={},r}return n.prototype.getFeaturesInExtent=function(t){var r=[],i=this.tileCache;if(i.getCount()===0)return r;var o=Bz(i.peekFirstKey())[0],s=this.tileGrid;return i.forEach(function(a){if(!(a.tileCoord[0]!==o||a.getState()!==mr.LOADED))for(var f=a.getSourceTiles(),g=0,x=f.length;g<x;++g){var k=f[g],B=k.tileCoord;if(il(t,s.getTileCoordExtent(B))){var P=k.getFeatures();if(P)for(var R=0,H=P.length;R<H;++R){var W=P[R],$=W.getGeometry();il(t,$.getExtent())&&r.push(W)}}}}),r},n.prototype.getOverlaps=function(){return this.overlaps_},n.prototype.clear=function(){this.tileCache.clear(),this.sourceTileCache.clear()},n.prototype.expireCache=function(t,r){var i=this.getTileCacheForProjection(t),o=Object.keys(r).reduce(function(s,a){var f=vae(a),g=i.peek(f);if(g)for(var x=g.sourceTiles,k=0,B=x.length;k<B;++k)s[x[k].getKey()]=!0;return s},{});e.prototype.expireCache.call(this,t,r),this.sourceTileCache.expireCache(o)},n.prototype.getSourceTiles=function(t,r,i){var o=this;if(i.getState()===mr.IDLE){i.setState(mr.LOADING);var s=i.wrappedTileCoord,a=this.getTileGridForProjection(r),f=a.getTileCoordExtent(s),g=s[0],x=a.getResolution(g);Em(f,-x,f);var k=this.tileGrid,B=k.getExtent();B&&X0(f,B,f);var P=k.getZForResolution(x,this.zDirection);k.forEachTileCoord(f,P,function(R){var H=o.tileUrlFunction(R,t,r),W=o.sourceTileCache.containsKey(H)?o.sourceTileCache.get(H):new o.tileClass(R,H?mr.IDLE:mr.EMPTY,H,o.format_,o.tileLoadFunction);i.sourceTiles.push(W);var $=W.getState();if($<mr.LOADED){var q=function(oe){o.handleTileChange(oe);var ne=W.getState();if(ne===mr.LOADED||ne===mr.ERROR){var ce=W.getKey();ce in i.errorTileKeys?W.getState()===mr.LOADED&&delete i.errorTileKeys[ce]:i.loadingSourceTiles--,ne===mr.ERROR?i.errorTileKeys[ce]=!0:W.removeEventListener(ki.CHANGE,q),i.loadingSourceTiles===0&&i.setState(h1(i.errorTileKeys)?mr.LOADED:mr.ERROR)}};W.addEventListener(ki.CHANGE,q),i.loadingSourceTiles++}$===mr.IDLE&&(W.extent=k.getTileCoordExtent(R),W.projection=r,W.resolution=k.getResolution(R[0]),o.sourceTileCache.set(H,W),W.load())}),i.loadingSourceTiles||i.setState(i.sourceTiles.some(function(R){return R.getState()===mr.ERROR})?mr.ERROR:mr.LOADED)}return i.sourceTiles},n.prototype.getTile=function(t,r,i,o,s){var a=Wy(t,r,i),f=this.getKey(),g;if(this.tileCache.containsKey(a)&&(g=this.tileCache.get(a),g.key===f))return g;var x=[t,r,i],k=this.getTileCoordForTileUrlFunction(x,s),B=this.getTileGrid().getExtent(),P=this.getTileGridForProjection(s);if(k&&B){var R=P.getTileCoordExtent(k);Em(R,-P.getResolution(t),R),il(B,R)||(k=null)}var H=!0;if(k!==null){var W=this.tileGrid,$=P.getResolution(t),q=W.getZForResolution($,1),oe=P.getTileCoordExtent(k);Em(oe,-$,oe),W.forEachTileCoord(oe,q,(function(ce){H=H&&!this.tileUrlFunction(ce,o,s)}).bind(this))}var ne=new wse(x,H?mr.EMPTY:mr.IDLE,k,this.getSourceTiles.bind(this,o,s));return ne.key=f,g?(ne.interimTile=g,ne.refreshInterimChain(),this.tileCache.replace(a,ne)):this.tileCache.set(a,ne),ne},n.prototype.getTileGridForProjection=function(t){var r=t.getCode(),i=this.tileGrids_[r];if(!i){for(var o=this.tileGrid,s=o.getResolutions().slice(),a=s.map(function(k,B){return o.getOrigin(B)}),f=s.map(function(k,B){return o.getTileSize(B)}),g=XL+1,x=s.length;x<g;++x)s.push(s[x-1]/2),a.push(a[x-1]),f.push(f[x-1]);i=new X_({extent:o.getExtent(),origins:a,resolutions:s,tileSizes:f}),this.tileGrids_[r]=i}return i},n.prototype.getTilePixelRatio=function(t){return t},n.prototype.getTilePixelSize=function(t,r,i){var o=this.getTileGridForProjection(i),s=pA(o.getTileSize(t),this.tmpSize);return[Math.round(s[0]*r),Math.round(s[1]*r)]},n.prototype.updateCacheSize=function(t,r){e.prototype.updateCacheSize.call(this,t*2,r),this.sourceTileCache.highWaterMark=this.getTileCacheForProjection(r).highWaterMark},n}(Uz);const Wz=Sse;function Ese(e,n){e.setLoader(function(t,r,i){xz(n,e.getFormat(),t,r,i,e.onLoad.bind(e),e.onError.bind(e))})}var H9={thin:100,hairline:100,"ultra-light":100,"extra-light":100,light:200,book:300,regular:400,normal:400,plain:400,roman:400,standard:400,medium:500,"semi-bold":600,"demi-bold":600,bold:700,heavy:800,black:800,"extra-bold":800,"ultra-black":900,"extra-black":900,"ultra-bold":900,"heavy-black":900,fat:900,poster:900},Gv=" ",Z9=/(italic|oblique)$/i,X9={},Ose=function(e,n,t){var r=X9[e];if(!r){Array.isArray(e)||(e=[e]);for(var i=400,o="normal",s=[],a,f,g=0,x=e.length;g<x;++g){var k=e[g],B=k.split(" "),P=B[B.length-1].toLowerCase();P=="normal"||P=="italic"||P=="oblique"?(o=f?o:P,B.pop(),P=B[B.length-1].toLowerCase()):Z9.test(P)&&(P=P.replace(Z9,""),o=f?o:B[B.length-1].replace(P,""));for(var R in H9){var H=B.length>1?B[B.length-2].toLowerCase():"";if(P==R||P==R.replace("-","")||H+"-"+P==R){i=a?i:H9[R],B.pop(),H&&R.startsWith(H)&&B.pop();break}}!a&&typeof P=="number"&&(i=P);var W=B.join(Gv).replace("Klokantech Noto Sans","Noto Sans");W.indexOf(Gv)!==-1&&(W='"'+W+'"'),s.push(W)}r=X9[e]=[o,i,s]}return r[0]+Gv+r[1]+Gv+n+"px"+(t?"/"+t:"")+Gv+r[2]};const aE=ga(Ose);var Bse=8,kse={version:{required:!0,type:"enum",values:[8],doc:"Style specification version number. Must be 8.",example:8},name:{type:"string",doc:"A human-readable name for the style.",example:"Bright"},metadata:{type:"*",doc:"Arbitrary properties useful to track with the stylesheet, but do not influence rendering. Properties should be prefixed to avoid collisions, like 'mapbox:'."},center:{type:"array",value:"number",doc:"Default map center in longitude and latitude. The style center will be used only if the map has not been positioned by other means (e.g. map options or user interaction).",example:[-73.9749,40.7736]},zoom:{type:"number",doc:"Default zoom level. The style zoom will be used only if the map has not been positioned by other means (e.g. map options or user interaction).",example:12.5},bearing:{type:"number",default:0,period:360,units:"degrees",doc:'Default bearing, in degrees. The bearing is the compass direction that is "up"; for example, a bearing of 90° orients the map so that east is up. This value will be used only if the map has not been positioned by other means (e.g. map options or user interaction).',example:29},pitch:{type:"number",default:0,units:"degrees",doc:"Default pitch, in degrees. Zero is perpendicular to the surface, for a look straight down at the map, while a greater value like 60 looks ahead towards the horizon. The style pitch will be used only if the map has not been positioned by other means (e.g. map options or user interaction).",example:50},light:{type:"light",doc:"The global light source.",example:{anchor:"viewport",color:"white",intensity:.4}},terrain:{type:"terrain",doc:"A global modifier that elevates layers and markers based on a DEM data source."},fog:{type:"fog",doc:"A global effect that fades layers and markers based on their distance to the camera. The fog can be used to approximate the effect of atmosphere on distant objects and enhance the depth perception of the map when used with terrain or 3D features. Note: fog is renamed to atmosphere in the Android and iOS SDKs and planned to be changed in GL-JS v.3.0.0."},sources:{required:!0,type:"sources",doc:"Data source specifications.",example:{"mapbox-streets":{type:"vector",url:"mapbox://mapbox.mapbox-streets-v6"}}},sprite:{type:"string",doc:"A base URL for retrieving the sprite image and metadata. The extensions `.png`, `.json` and scale factor `@2x.png` will be automatically appended. This property is required if any layer uses the `background-pattern`, `fill-pattern`, `line-pattern`, `fill-extrusion-pattern`, or `icon-image` properties. The URL must be absolute, containing the [scheme, authority and path components](https://en.wikipedia.org/wiki/URL#Syntax).",example:"mapbox://sprites/mapbox/bright-v8"},glyphs:{type:"string",doc:"A URL template for loading signed-distance-field glyph sets in PBF format. The URL must include `{fontstack}` and `{range}` tokens. This property is required if any layer uses the `text-field` layout property. The URL must be absolute, containing the [scheme, authority and path components](https://en.wikipedia.org/wiki/URL#Syntax).",example:"mapbox://fonts/mapbox/{fontstack}/{range}.pbf"},transition:{type:"transition",doc:"A global transition definition to use as a default across properties, to be used for timing transitions between one value and the next when no property-specific transition is set. Collision-based symbol fading is controlled independently of the style's `transition` property.",example:{duration:300,delay:0}},projection:{type:"projection",doc:"The projection the map should be rendered in. Supported projections are Mercator, Globe, Albers, Equal Earth, Equirectangular (WGS84), Lambert conformal conic, Natural Earth, and Winkel Tripel. Terrain, sky and fog are supported by only Mercator and globe. CustomLayerInterface is not supported outside of Mercator.",example:{name:"albers",center:[-154,50],parallels:[55,65]}},layers:{required:!0,type:"array",value:"layer",doc:"Layers will be drawn in the order of this array.",example:[{id:"water",source:"mapbox-streets","source-layer":"water",type:"fill",paint:{"fill-color":"#00ffff"}}]}},Ise={"*":{type:"source",doc:"Specification of a data source. For vector and raster sources, either TileJSON or a URL to a TileJSON must be provided. For image and video sources, a URL must be provided. For GeoJSON sources, a URL or inline GeoJSON must be provided."}},Tse=["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],Kse={type:{required:!0,type:"enum",values:{vector:{doc:"A vector tile source."}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:`, `https:`, and `mapbox://<Tileset ID>`."},tiles:{type:"array",value:"string",doc:"An array of one or more tile source URLs, as in the TileJSON spec."},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129],doc:"An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by Mapbox GL."},scheme:{type:"enum",values:{xyz:{doc:"Slippy map tilenames scheme."},tms:{doc:"OSGeo spec scheme."}},default:"xyz",doc:"Influences the y direction of the tile coordinates. The global-mercator (aka Spherical Mercator) profile is assumed."},minzoom:{type:"number",default:0,doc:"Minimum zoom level for which tiles are available, as in the TileJSON spec."},maxzoom:{type:"number",default:22,doc:"Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},promoteId:{type:"promoteId",doc:"A property to use as a feature id (for feature state). Either a property name, or an object of the form `{<sourceLayer>: <propertyName>}`. If specified as a string for a vector tile source, the same property is used across all its source layers. If specified as an object only specified source layers will have id overriden, others will fallback to original feature id"},volatile:{type:"boolean",default:!1,doc:"A setting to determine whether a source's tiles are cached locally.","sdk-support":{"basic functionality":{android:"9.3.0",ios:"5.10.0"}}},"*":{type:"*",doc:"Other keys to configure the data source."}},Pse={type:{required:!0,type:"enum",values:{raster:{doc:"A raster tile source."}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:`, `https:`, and `mapbox://<Tileset ID>`."},tiles:{type:"array",value:"string",doc:"An array of one or more tile source URLs, as in the TileJSON spec."},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129],doc:"An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by Mapbox GL."},minzoom:{type:"number",default:0,doc:"Minimum zoom level for which tiles are available, as in the TileJSON spec."},maxzoom:{type:"number",default:22,doc:"Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels."},tileSize:{type:"number",default:512,units:"pixels",doc:"The minimum visual size to display tiles for this layer. Only configurable for raster layers."},scheme:{type:"enum",values:{xyz:{doc:"Slippy map tilenames scheme."},tms:{doc:"OSGeo spec scheme."}},default:"xyz",doc:"Influences the y direction of the tile coordinates. The global-mercator (aka Spherical Mercator) profile is assumed."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},volatile:{type:"boolean",default:!1,doc:"A setting to determine whether a source's tiles are cached locally.","sdk-support":{"basic functionality":{android:"9.3.0",ios:"5.10.0"}}},"*":{type:"*",doc:"Other keys to configure the data source."}},Fse={type:{required:!0,type:"enum",values:{"raster-dem":{doc:"A RGB-encoded raster DEM source"}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:`, `https:`, and `mapbox://<Tileset ID>`."},tiles:{type:"array",value:"string",doc:"An array of one or more tile source URLs, as in the TileJSON spec."},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129],doc:"An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by Mapbox GL."},minzoom:{type:"number",default:0,doc:"Minimum zoom level for which tiles are available, as in the TileJSON spec."},maxzoom:{type:"number",default:22,doc:"Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels."},tileSize:{type:"number",default:512,units:"pixels",doc:"The minimum visual size to display tiles for this layer. Only configurable for raster layers."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},encoding:{type:"enum",values:{terrarium:{doc:"Terrarium format PNG tiles. See https://aws.amazon.com/es/public-datasets/terrain/ for more info."},mapbox:{doc:"Mapbox Terrain RGB tiles. See https://www.mapbox.com/help/access-elevation-data/#mapbox-terrain-rgb for more info."}},default:"mapbox",doc:"The encoding used by this source. Mapbox Terrain RGB is used by default"},volatile:{type:"boolean",default:!1,doc:"A setting to determine whether a source's tiles are cached locally.","sdk-support":{"basic functionality":{android:"9.3.0",ios:"5.10.0"}}},"*":{type:"*",doc:"Other keys to configure the data source."}},Dse={type:{required:!0,type:"enum",values:{geojson:{doc:"A GeoJSON data source."}},doc:"The data type of the GeoJSON source."},data:{type:"*",doc:"A URL to a GeoJSON file, or inline GeoJSON."},maxzoom:{type:"number",default:18,doc:"Maximum zoom level at which to create vector tiles (higher means greater detail at high zoom levels)."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},buffer:{type:"number",default:128,maximum:512,minimum:0,doc:"Size of the tile buffer on each side. A value of 0 produces no buffer. A value of 512 produces a buffer as wide as the tile itself. Larger values produce fewer rendering artifacts near tile edges and slower performance."},filter:{type:"*",doc:"An expression for filtering features prior to processing them for rendering."},tolerance:{type:"number",default:.375,doc:"Douglas-Peucker simplification tolerance (higher means simpler geometries and faster performance)."},cluster:{type:"boolean",default:!1,doc:"If the data is a collection of point features, setting this to true clusters the points by radius into groups. Cluster groups become new `Point` features in the source with additional properties:\n * `cluster` Is `true` if the point is a cluster \n * `cluster_id` A unqiue id for the cluster to be used in conjunction with the [cluster inspection methods](https://www.mapbox.com/mapbox-gl-js/api/#geojsonsource#getclusterexpansionzoom)\n * `point_count` Number of original points grouped into this cluster\n * `point_count_abbreviated` An abbreviated point count"},clusterRadius:{type:"number",default:50,minimum:0,doc:"Radius of each cluster if clustering is enabled. A value of 512 indicates a radius equal to the width of a tile."},clusterMaxZoom:{type:"number",doc:"Max zoom on which to cluster points if clustering is enabled. Defaults to one zoom less than maxzoom (so that last zoom features are not clustered). Clusters are re-evaluated at integer zoom levels so setting clusterMaxZoom to 14 means the clusters will be displayed until z15."},clusterMinPoints:{type:"number",doc:"Minimum number of points necessary to form a cluster if clustering is enabled. Defaults to `2`."},clusterProperties:{type:"*",doc:'An object defining custom properties on the generated clusters if clustering is enabled, aggregating values from clustered points. Has the form `{"property_name": [operator, map_expression]}`. `operator` is any expression function that accepts at least 2 operands (e.g. `"+"` or `"max"`) — it accumulates the property value from clusters/points the cluster contains; `map_expression` produces the value of a single point.\n\nExample: `{"sum": ["+", ["get", "scalerank"]]}`.\n\nFor more advanced use cases, in place of `operator`, you can use a custom reduce expression that references a special `["accumulated"]` value, e.g.:\n`{"sum": [["+", ["accumulated"], ["get", "sum"]], ["get", "scalerank"]]}`'},lineMetrics:{type:"boolean",default:!1,doc:"Whether to calculate line distance metrics. This is required for line layers that specify `line-gradient` values."},generateId:{type:"boolean",default:!1,doc:"Whether to generate ids for the geojson features. When enabled, the `feature.id` property will be auto assigned based on its index in the `features` array, over-writing any previous values."},promoteId:{type:"promoteId",doc:"A property to use as a feature id (for feature state). Either a property name, or an object of the form `{<sourceLayer>: <propertyName>}`."}},Use={type:{required:!0,type:"enum",values:{video:{doc:"A video data source."}},doc:"The data type of the video source."},urls:{required:!0,type:"array",value:"string",doc:"URLs to video content in order of preferred format."},coordinates:{required:!0,doc:"Corners of video specified in longitude, latitude pairs.",type:"array",length:4,value:{type:"array",length:2,value:"number",doc:"A single longitude, latitude pair."}}},Rse={type:{required:!0,type:"enum",values:{image:{doc:"An image data source."}},doc:"The data type of the image source."},url:{required:!0,type:"string",doc:"URL that points to an image."},coordinates:{required:!0,doc:"Corners of image specified in longitude, latitude pairs.",type:"array",length:4,value:{type:"array",length:2,value:"number",doc:"A single longitude, latitude pair."}}},Lse={id:{type:"string",doc:"Unique layer name.",required:!0},type:{type:"enum",values:{fill:{doc:"A filled polygon with an optional stroked border.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},line:{doc:"A stroked line.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},symbol:{doc:"An icon or a text label.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},circle:{doc:"A filled circle.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},heatmap:{doc:"A heatmap.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"fill-extrusion":{doc:"An extruded (3D) polygon.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},raster:{doc:"Raster map textures such as satellite imagery.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},hillshade:{doc:"Client-side hillshading visualization based on DEM data. Currently, the implementation only supports Mapbox Terrain RGB and Mapzen Terrarium tiles.","sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},background:{doc:"The background color or pattern of the map.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},sky:{doc:"A spherical dome around the map that is always rendered behind all other layers.","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}}}},doc:"Rendering type of this layer.",required:!0},metadata:{type:"*",doc:"Arbitrary properties useful to track with the layer, but do not influence rendering. Properties should be prefixed to avoid collisions, like 'mapbox:'."},source:{type:"string",doc:"Name of a source description to be used for this layer. Required for all layer types except `background`."},"source-layer":{type:"string",doc:"Layer to use from a vector tile source. Required for vector tile sources; prohibited for all other source types, including GeoJSON sources."},minzoom:{type:"number",minimum:0,maximum:24,doc:"The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden."},maxzoom:{type:"number",minimum:0,maximum:24,doc:"The maximum zoom level for the layer. At zoom levels equal to or greater than the maxzoom, the layer will be hidden."},filter:{type:"filter",doc:'An expression specifying conditions on source features. Only features that match the filter are displayed. Zoom expressions in filters are only evaluated at integer zoom levels. The `["feature-state", ...]` expression is not supported in filter expressions. The `["pitch"]` and `["distance-from-center"]` expressions are supported only for filter expressions on the symbol layer.'},layout:{type:"layout",doc:"Layout properties for the layer."},paint:{type:"paint",doc:"Default paint properties for this layer."}},zse=["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background","layout_sky"],jse={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Wse={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},"property-type":"constant"}},Nse={"fill-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with a higher sort key will appear above features with a lower sort key.","sdk-support":{"basic functionality":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"},"data-driven styling":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Gse={"circle-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with a higher sort key will appear above features with a lower sort key.","sdk-support":{"basic functionality":{js:"1.2.0",android:"9.2.0",ios:"5.9.0",macos:"0.16.0"},"data-driven styling":{js:"1.2.0",android:"9.2.0",ios:"5.9.0",macos:"0.16.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Qse={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},"property-type":"constant"}},$se={"line-cap":{type:"enum",values:{butt:{doc:"A cap with a squared-off end which is drawn to the exact endpoint of the line."},round:{doc:"A cap with a rounded end which is drawn beyond the endpoint of the line at a radius of one-half of the line's width and centered on the endpoint of the line."},square:{doc:"A cap with a squared-off end which is drawn beyond the endpoint of the line at a distance of one-half of the line's width."}},default:"butt",doc:"The display of line endings.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"2.3.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-join":{type:"enum",values:{bevel:{doc:"A join with a squared-off end which is drawn beyond the endpoint of the line at a distance of one-half of the line's width."},round:{doc:"A join with a rounded end which is drawn beyond the endpoint of the line at a radius of one-half of the line's width and centered on the endpoint of the line."},miter:{doc:"A join with a sharp, angled corner which is drawn with the outer sides beyond the endpoint of the path until they meet."}},default:"miter",doc:"The display of lines when joining.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{type:"number",default:2,doc:"Used to automatically convert miter joins to bevel joins for sharp angles.",requires:[{"line-join":"miter"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-round-limit":{type:"number",default:1.05,doc:"Used to automatically convert round joins to miter joins for shallow angles.",requires:[{"line-join":"round"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with a higher sort key will appear above features with a lower sort key.","sdk-support":{"basic functionality":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"},"data-driven styling":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Yse={"symbol-placement":{type:"enum",values:{point:{doc:"The label is placed at the point where the geometry is located."},line:{doc:"The label is placed along the line of the geometry. Can only be used on `LineString` and `Polygon` geometries."},"line-center":{doc:"The label is placed at the center of the line of the geometry. Can only be used on `LineString` and `Polygon` geometries. Note that a single feature in a vector tile may contain multiple line geometries."}},default:"point",doc:"Label placement relative to its geometry.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"`line-center` value":{js:"0.47.0",android:"6.4.0",ios:"4.3.0",macos:"0.10.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-spacing":{type:"number",default:250,minimum:1,units:"pixels",doc:"Distance between two symbol anchors.",requires:[{"symbol-placement":"line"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{type:"boolean",default:!1,doc:"If true, the symbols will not cross tile edges to avoid mutual collisions. Recommended in layers that don't have enough padding in the vector tile to prevent collisions, or if it is a point symbol layer placed after a line symbol layer. When using a client that supports global collision detection, like Mapbox GL JS version 0.42.0 or greater, enabling this property is not needed to prevent clipped labels at tile boundaries.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with lower sort keys are drawn and placed first. When `icon-allow-overlap` or `text-allow-overlap` is `false`, features with a lower sort key will have priority during placement. When `icon-allow-overlap` or `text-allow-overlap` is set to `true`, features with a higher sort key will overlap over features with a lower sort key.","sdk-support":{"basic functionality":{js:"0.53.0",android:"7.4.0",ios:"4.11.0",macos:"0.14.0"},"data-driven styling":{js:"0.53.0",android:"7.4.0",ios:"4.11.0",macos:"0.14.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{type:"enum",values:{auto:{doc:"Sorts symbols by `symbol-sort-key` if set. Otherwise, sorts symbols by their y-position relative to the viewport if `icon-allow-overlap` or `text-allow-overlap` is set to `true` or `icon-ignore-placement` or `text-ignore-placement` is `false`."},"viewport-y":{doc:"Sorts symbols by their y-position relative to the viewport if `icon-allow-overlap` or `text-allow-overlap` is set to `true` or `icon-ignore-placement` or `text-ignore-placement` is `false`."},source:{doc:"Sorts symbols by `symbol-sort-key` if set. Otherwise, no sorting is applied; symbols are rendered in the same order as the source data."}},default:"auto",doc:"Determines whether overlapping symbols in the same layer are rendered in the order that they appear in the data source or by their y-position relative to the viewport. To control the order and prioritization of symbols otherwise, use `symbol-sort-key`.","sdk-support":{"basic functionality":{js:"0.49.0",android:"6.6.0",ios:"4.5.0",macos:"0.12.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{type:"boolean",default:!1,doc:"If true, the icon will be visible even if it collides with other previously drawn symbols.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{type:"boolean",default:!1,doc:"If true, other symbols can be visible even if they collide with the icon.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-optional":{type:"boolean",default:!1,doc:"If true, text will display without their corresponding icons when the icon collides with other symbols and the text does not.",requires:["icon-image","text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{type:"enum",values:{map:{doc:"When `symbol-placement` is set to `point`, aligns icons east-west. When `symbol-placement` is set to `line` or `line-center`, aligns icon x-axes with the line."},viewport:{doc:"Produces icons whose x-axes are aligned with the x-axis of the viewport, regardless of the value of `symbol-placement`."},auto:{doc:"When `symbol-placement` is set to `point`, this is equivalent to `viewport`. When `symbol-placement` is set to `line` or `line-center`, this is equivalent to `map`."}},default:"auto",doc:"In combination with `symbol-placement`, determines the rotation behavior of icons.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"`auto` value":{js:"0.25.0",android:"4.2.0",ios:"3.4.0",macos:"0.3.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-size":{type:"number",default:1,minimum:0,units:"factor of the original icon size",doc:"Scales the original size of the icon by the provided factor. The new pixel size of the image will be the original pixel size multiplied by `icon-size`. 1 is the original size; 3 triples the size of the image.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{type:"enum",values:{none:{doc:"The icon is displayed at its intrinsic aspect ratio."},width:{doc:"The icon is scaled in the x-dimension to fit the width of the text."},height:{doc:"The icon is scaled in the y-dimension to fit the height of the text."},both:{doc:"The icon is scaled in both x- and y-dimensions."}},default:"none",doc:"Scales the icon to fit around the associated text.",requires:["icon-image","text-field"],"sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"},"stretchable icons":{js:"1.6.0",android:"9.2.0",ios:"5.8.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",doc:"Size of the additional area added to dimensions determined by `icon-text-fit`, in clockwise order: top, right, bottom, left.",requires:["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],"sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-image":{type:"resolvedImage",doc:"Name of image in sprite to use for drawing an image background.",tokens:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{type:"number",default:0,period:360,units:"degrees",doc:"Rotates the icon clockwise.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.21.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{type:"number",default:2,minimum:0,units:"pixels",doc:"Size of the additional area around the icon bounding box used for detecting symbol collisions.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-keep-upright":{type:"boolean",default:!1,doc:"If true, the icon may be flipped to prevent it from being rendered upside-down.",requires:["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],doc:"Offset distance of icon from its anchor. Positive values indicate right and down, while negative values indicate left and up. Each component is multiplied by the value of `icon-size` to obtain the final offset in pixels. When combined with `icon-rotate` the offset will be as if the rotated direction was up.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{type:"enum",values:{center:{doc:"The center of the icon is placed closest to the anchor."},left:{doc:"The left side of the icon is placed closest to the anchor."},right:{doc:"The right side of the icon is placed closest to the anchor."},top:{doc:"The top of the icon is placed closest to the anchor."},bottom:{doc:"The bottom of the icon is placed closest to the anchor."},"top-left":{doc:"The top left corner of the icon is placed closest to the anchor."},"top-right":{doc:"The top right corner of the icon is placed closest to the anchor."},"bottom-left":{doc:"The bottom left corner of the icon is placed closest to the anchor."},"bottom-right":{doc:"The bottom right corner of the icon is placed closest to the anchor."}},default:"center",doc:"Part of the icon placed closest to the anchor.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{type:"enum",values:{map:{doc:"The icon is aligned to the plane of the map."},viewport:{doc:"The icon is aligned to the plane of the viewport."},auto:{doc:"Automatically matches the value of `icon-rotation-alignment`."}},default:"auto",doc:"Orientation of icon when map is pitched.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{type:"enum",values:{map:{doc:"The text is aligned to the plane of the map."},viewport:{doc:"The text is aligned to the plane of the viewport."},auto:{doc:"Automatically matches the value of `text-rotation-alignment`."}},default:"auto",doc:"Orientation of text when map is pitched.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"},"`auto` value":{js:"0.25.0",android:"4.2.0",ios:"3.4.0",macos:"0.3.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{type:"enum",values:{map:{doc:"When `symbol-placement` is set to `point`, aligns text east-west. When `symbol-placement` is set to `line` or `line-center`, aligns text x-axes with the line."},viewport:{doc:"Produces glyphs whose x-axes are aligned with the x-axis of the viewport, regardless of the value of `symbol-placement`."},auto:{doc:"When `symbol-placement` is set to `point`, this is equivalent to `viewport`. When `symbol-placement` is set to `line` or `line-center`, this is equivalent to `map`."}},default:"auto",doc:"In combination with `symbol-placement`, determines the rotation behavior of the individual glyphs forming the text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"`auto` value":{js:"0.25.0",android:"4.2.0",ios:"3.4.0",macos:"0.3.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-field":{type:"formatted",default:"",tokens:!0,doc:"Value to use for a text label. If a plain `string` is provided, it will be treated as a `formatted` with default/inherited formatting options. SDF images are not supported in formatted text and will be ignored.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-font":{type:"array",value:"string",default:["Open Sans Regular","Arial Unicode MS Regular"],doc:"Font stack to use for displaying text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-size":{type:"number",default:16,minimum:0,units:"pixels",doc:"Font size.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",doc:"The maximum line width for text wrapping.",requires:["text-field",{"symbol-placement":["point"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{type:"number",default:1.2,units:"ems",doc:"Text leading value for multi-line text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"2.3.0",android:"10.0.0",ios:"10.0.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-letter-spacing":{type:"number",default:0,units:"ems",doc:"Text tracking amount.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-justify":{type:"enum",values:{auto:{doc:"The text is aligned towards the anchor position."},left:{doc:"The text is aligned to the left."},center:{doc:"The text is centered."},right:{doc:"The text is aligned to the right."}},default:"center",doc:"Text justification options.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"},auto:{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{type:"number",units:"ems",default:0,doc:"Radial offset of text, in the direction of the symbol's anchor. Useful in combination with `text-variable-anchor`, which defaults to using the two-dimensional `text-offset` if present.","sdk-support":{"basic functionality":{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"},"data-driven styling":{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"}},requires:["text-field"],"property-type":"data-driven",expression:{interpolated:!0,parameters:["zoom","feature"]}},"text-variable-anchor":{type:"array",value:"enum",values:{center:{doc:"The center of the text is placed closest to the anchor."},left:{doc:"The left side of the text is placed closest to the anchor."},right:{doc:"The right side of the text is placed closest to the anchor."},top:{doc:"The top of the text is placed closest to the anchor."},bottom:{doc:"The bottom of the text is placed closest to the anchor."},"top-left":{doc:"The top left corner of the text is placed closest to the anchor."},"top-right":{doc:"The top right corner of the text is placed closest to the anchor."},"bottom-left":{doc:"The bottom left corner of the text is placed closest to the anchor."},"bottom-right":{doc:"The bottom right corner of the text is placed closest to the anchor."}},requires:["text-field",{"symbol-placement":["point"]}],doc:"To increase the chance of placing high-priority labels on the map, you can provide an array of `text-anchor` locations: the renderer will attempt to place the label at each location, in order, before moving onto the next label. Use `text-justify: auto` to choose justification based on anchor position. To apply an offset, use the `text-radial-offset` or the two-dimensional `text-offset`.","sdk-support":{"basic functionality":{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-anchor":{type:"enum",values:{center:{doc:"The center of the text is placed closest to the anchor."},left:{doc:"The left side of the text is placed closest to the anchor."},right:{doc:"The right side of the text is placed closest to the anchor."},top:{doc:"The top of the text is placed closest to the anchor."},bottom:{doc:"The bottom of the text is placed closest to the anchor."},"top-left":{doc:"The top left corner of the text is placed closest to the anchor."},"top-right":{doc:"The top right corner of the text is placed closest to the anchor."},"bottom-left":{doc:"The bottom left corner of the text is placed closest to the anchor."},"bottom-right":{doc:"The bottom right corner of the text is placed closest to the anchor."}},default:"center",doc:"Part of the text placed closest to the anchor.",requires:["text-field",{"!":"text-variable-anchor"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{type:"number",default:45,units:"degrees",doc:"Maximum angle change between adjacent characters.",requires:["text-field",{"symbol-placement":["line","line-center"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-writing-mode":{type:"array",value:"enum",values:{horizontal:{doc:"If a text's language supports horizontal writing mode, symbols would be laid out horizontally."},vertical:{doc:"If a text's language supports vertical writing mode, symbols would be laid out vertically."}},doc:"The property allows control over a symbol's orientation. Note that the property values act as a hint, so that a symbol whose language doesn’t support the provided orientation will be laid out in its natural orientation. Example: English point symbol will be rendered horizontally even if array value contains single 'vertical' enum value. For symbol with point placement, the order of elements in an array define priority order for the placement of an orientation variant. For symbol with line placement, the default text writing mode is either ['horizontal', 'vertical'] or ['vertical', 'horizontal'], the order doesn't affect the placement.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"1.3.0",android:"8.3.0",ios:"5.3.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotate":{type:"number",default:0,period:360,units:"degrees",doc:"Rotates the text clockwise.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",doc:"Size of the additional area around the text bounding box used for detecting symbol collisions.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-keep-upright":{type:"boolean",default:!0,doc:"If true, the text may be flipped vertically to prevent it from being rendered upside-down.",requires:["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-transform":{type:"enum",values:{none:{doc:"The text is not altered."},uppercase:{doc:"Forces all letters to be displayed in uppercase."},lowercase:{doc:"Forces all letters to be displayed in lowercase."}},default:"none",doc:"Specifies how to capitalize text, similar to the CSS `text-transform` property.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-offset":{type:"array",doc:"Offset distance of text from its anchor. Positive values indicate right and down, while negative values indicate left and up. If used with text-variable-anchor, input values will be taken as absolute values. Offsets along the x- and y-axis will be applied automatically based on the anchor position.",value:"number",units:"ems",length:2,default:[0,0],requires:["text-field",{"!":"text-radial-offset"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{type:"boolean",default:!1,doc:"If true, the text will be visible even if it collides with other previously drawn symbols.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{type:"boolean",default:!1,doc:"If true, other symbols can be visible even if they collide with the text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-optional":{type:"boolean",default:!1,doc:"If true, icons will display without their corresponding text when the text collides with other symbols and the icon does not.",requires:["text-field","icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},qse={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Vse={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},"property-type":"constant"}},Hse={type:"array",value:"*",doc:"A filter selects specific features from a layer."},Zse={type:"boolean",doc:'Expression which determines whether or not to display a symbol. Symbols support dynamic filtering, meaning this expression can use the `["pitch"]` and `["distance-from-center"]` expressions to reference the current state of the view.',default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature","pitch","distance-from-center"]}},Xse={type:"boolean",doc:'Expression which determines whether or not to display a polygon. Fill layer does NOT support dynamic filtering, meaning this expression can NOT use the `["pitch"]` and `["distance-from-center"]` expressions to reference the current state of the view.',default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}},Jse={type:"boolean",doc:'Expression which determines whether or not to display a Polygon or LineString. Line layer does NOT support dynamic filtering, meaning this expression can NOT use the `["pitch"]` and `["distance-from-center"]` expressions to reference the current state of the view.',default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}},ele={type:"boolean",doc:'Expression which determines whether or not to display a circle. Circle layer does NOT support dynamic filtering, meaning this expression can NOT use the `["pitch"]` and `["distance-from-center"]` expressions to reference the current state of the view.',default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}},tle={type:"boolean",doc:'Expression used to determine whether a point is being displayed or not. Heatmap layer does NOT support dynamic filtering, meaning this expression can NOT use the `["pitch"]` and `["distance-from-center"]` expressions to reference the current state of the view.',default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}},nle={type:"enum",values:{"==":{doc:'`["==", key, value]` equality: `feature[key] = value`'},"!=":{doc:'`["!=", key, value]` inequality: `feature[key] ≠ value`'},">":{doc:'`[">", key, value]` greater than: `feature[key] > value`'},">=":{doc:'`[">=", key, value]` greater than or equal: `feature[key] ≥ value`'},"<":{doc:'`["<", key, value]` less than: `feature[key] < value`'},"<=":{doc:'`["<=", key, value]` less than or equal: `feature[key] ≤ value`'},in:{doc:'`["in", key, v0, ..., vn]` set inclusion: `feature[key] ∈ {v0, ..., vn}`'},"!in":{doc:'`["!in", key, v0, ..., vn]` set exclusion: `feature[key] ∉ {v0, ..., vn}`'},all:{doc:'`["all", f0, ..., fn]` logical `AND`: `f0 ∧ ... ∧ fn`'},any:{doc:'`["any", f0, ..., fn]` logical `OR`: `f0 ∨ ... ∨ fn`'},none:{doc:'`["none", f0, ..., fn]` logical `NOR`: `¬f0 ∧ ... ∧ ¬fn`'},has:{doc:'`["has", key]` `feature[key]` exists'},"!has":{doc:'`["!has", key]` `feature[key]` does not exist'},within:{doc:'`["within", object]` feature geometry is within object geometry'}},doc:"The filter operator."},rle={type:"enum",values:{Point:{doc:"Filter to point geometries."},LineString:{doc:"Filter to line geometries."},Polygon:{doc:"Filter to polygon geometries."}},doc:"The geometry type for the filter to select."},ile={type:"array",minimum:0,maximum:24,value:["number","color"],length:2,doc:"Zoom level and value pair."},ole={type:"array",value:"*",minimum:1,doc:"An expression defines a function that can be used for data-driven style properties or feature filters."},ale={doc:"",type:"enum",values:{let:{doc:'Binds expressions to named variables, which can then be referenced in the result expression using ["var", "variable_name"].',group:"Variable binding","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},var:{doc:'References variable bound using "let".',group:"Variable binding","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},literal:{doc:"Provides a literal array or object value.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},array:{doc:"Asserts that the input is an array (optionally with a specific item type and length). If, when the input expression is evaluated, it is not of the asserted type, then this assertion will cause the whole expression to be aborted.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},at:{doc:"Retrieves an item from an array.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},in:{doc:"Determines whether an item exists in an array or a substring exists in a string. In the specific case when the second and third arguments are string literals, you must wrap at least one of them in a [`literal`](#types-literal) expression to hint correct interpretation to the [type system](#type-system).",group:"Lookup","sdk-support":{"basic functionality":{js:"1.6.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}}},"index-of":{doc:"Returns the first position at which an item can be found in an array or a substring can be found in a string, or `-1` if the input cannot be found. Accepts an optional index from where to begin the search.",group:"Lookup","sdk-support":{"basic functionality":{js:"1.10.0",android:"10.0.0",ios:"10.0.0"}}},slice:{doc:"Returns an item from an array or a substring from a string from a specified start index, or between a start index and an end index if set. The return value is inclusive of the start index but not of the end index.",group:"Lookup","sdk-support":{"basic functionality":{js:"1.10.0",android:"10.0.0",ios:"10.0.0"}}},case:{doc:"Selects the first output whose corresponding test condition evaluates to true, or the fallback value otherwise.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},match:{doc:'Selects the output for which the label value matches the input value, or the fallback value if no match is found. The input can be any expression (for example, `["get", "building_type"]`). Each label must be unique, and must be either:\n - a single literal value; or\n - an array of literal values, the values of which must be all strings or all numbers (for example `[100, 101]` or `["c", "b"]`).\n\nThe input matches if any of the values in the array matches using strict equality, similar to the `"in"` operator.\nIf the input type does not match the type of the labels, the result will be the fallback value.',group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},coalesce:{doc:"Evaluates each expression in turn until the first valid value is obtained. Invalid values are `null` and [`'image'`](#types-image) expressions that are unavailable in the style. If all values are invalid, `coalesce` returns the first value listed.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},step:{doc:'Produces discrete, stepped results by evaluating a piecewise-constant function defined by pairs of input and output values ("stops"). The `input` may be any numeric expression (e.g., `["get", "population"]`). Stop inputs must be numeric literals in strictly ascending order. Returns the output value of the stop just less than the input, or the first output if the input is less than the first stop.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.42.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},interpolate:{doc:'Produces continuous, smooth results by interpolating between pairs of input and output values ("stops"). The `input` may be any numeric expression (e.g., `["get", "population"]`). Stop inputs must be numeric literals in strictly ascending order. The output type must be `number`, `array<number>`, or `color`.\n\nInterpolation types:\n- `["linear"]`: Interpolates linearly between the pair of stops just less than and just greater than the input.\n- `["exponential", base]`: Interpolates exponentially between the stops just less than and just greater than the input. `base` controls the rate at which the output increases: higher values make the output increase more towards the high end of the range. With values close to 1 the output increases linearly.\n- `["cubic-bezier", x1, y1, x2, y2]`: Interpolates using the cubic bezier curve defined by the given control points.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.42.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"interpolate-hcl":{doc:'Produces continuous, smooth results by interpolating between pairs of input and output values ("stops"). Works like `interpolate`, but the output type must be `color`, and the interpolation is performed in the Hue-Chroma-Luminance color space.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.49.0"}}},"interpolate-lab":{doc:'Produces continuous, smooth results by interpolating between pairs of input and output values ("stops"). Works like `interpolate`, but the output type must be `color`, and the interpolation is performed in the CIELAB color space.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.49.0"}}},ln2:{doc:"Returns mathematical constant ln(2).",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},pi:{doc:"Returns the mathematical constant pi.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},e:{doc:"Returns the mathematical constant e.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},typeof:{doc:"Returns a string describing the type of the given value.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},string:{doc:"Asserts that the input value is a string. If multiple values are provided, each one is evaluated in order until a string is obtained. If none of the inputs are strings, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},number:{doc:"Asserts that the input value is a number. If multiple values are provided, each one is evaluated in order until a number is obtained. If none of the inputs are numbers, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},boolean:{doc:"Asserts that the input value is a boolean. If multiple values are provided, each one is evaluated in order until a boolean is obtained. If none of the inputs are booleans, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},object:{doc:"Asserts that the input value is an object. If multiple values are provided, each one is evaluated in order until an object is obtained. If none of the inputs are objects, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},collator:{doc:"Returns a `collator` for use in locale-dependent comparison operations. The `case-sensitive` and `diacritic-sensitive` options default to `false`. The `locale` argument specifies the IETF language tag of the locale to use. If none is provided, the default locale is used. If the requested locale is not available, the `collator` will use a system-defined fallback locale. Use `resolved-locale` to test the results of locale fallback behavior.",group:"Types","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},format:{doc:'Returns a `formatted` string for displaying mixed-format text in the `text-field` property. The input may contain a string literal or expression, including an [`\'image\'`](#types-image) expression. Strings may be followed by a style override object that supports the following properties:\n- `"text-font"`: Overrides the font stack specified by the root layout property.\n- `"text-color"`: Overrides the color specified by the root paint property.\n- `"font-scale"`: Applies a scaling factor on `text-size` as specified by the root layout property.',group:"Types","sdk-support":{"basic functionality":{js:"0.48.0",android:"6.7.0",ios:"4.6.0",macos:"0.12.0"},"text-font":{js:"0.48.0",android:"6.7.0",ios:"4.6.0",macos:"0.12.0"},"font-scale":{js:"0.48.0",android:"6.7.0",ios:"4.6.0",macos:"0.12.0"},"text-color":{js:"1.3.0",android:"7.3.0",ios:"4.10.0",macos:"0.14.0"},image:{js:"1.6.0",android:"8.6.0",ios:"5.7.0",macos:"0.15.0"}}},image:{doc:"Returns a [`ResolvedImage`](/mapbox-gl-js/style-spec/types/#resolvedimage) for use in [`icon-image`](/mapbox-gl-js/style-spec/layers/#layout-symbol-icon-image), `*-pattern` entries, and as a section in the [`'format'`](#types-format) expression. A [`'coalesce'`](#coalesce) expression containing `image` expressions will evaluate to the first listed image that is currently in the style. This validation process is synchronous and requires the image to have been added to the style before requesting it in the `'image'` argument.",group:"Types","sdk-support":{"basic functionality":{js:"1.4.0",android:"8.6.0",ios:"5.7.0",macos:"0.15.0"}}},"number-format":{doc:"Converts the input number into a string representation using the providing formatting rules. If set, the `locale` argument specifies the locale to use, as a BCP 47 language tag. If set, the `currency` argument specifies an ISO 4217 code to use for currency-style formatting. If set, the `unit` argument specifies a [simple ECMAScript unit](https://tc39.es/proposal-unified-intl-numberformat/section6/locales-currencies-tz_proposed_out.html#sec-issanctionedsimpleunitidentifier) to use for unit-style formatting. If set, the `min-fraction-digits` and `max-fraction-digits` arguments specify the minimum and maximum number of fractional digits to include.",group:"Types","sdk-support":{"basic functionality":{js:"0.54.0",android:"8.4.0",ios:"5.4.0",macos:"0.15.0"}}},"to-string":{doc:'Converts the input value to a string. If the input is `null`, the result is `""`. If the input is a [`boolean`](#types-boolean), the result is `"true"` or `"false"`. If the input is a number, it is converted to a string as specified by the ["NumberToString" algorithm](https://tc39.github.io/ecma262/#sec-tostring-applied-to-the-number-type) of the ECMAScript Language Specification. If the input is a [`color`](#color), it is converted to a string of the form `"rgba(r,g,b,a)"`, where `r`, `g`, and `b` are numerals ranging from 0 to 255, and `a` ranges from 0 to 1. If the input is an [`\'image\'`](#types-image) expression, `\'to-string\'` returns the image name. Otherwise, the input is converted to a string in the format specified by the [`JSON.stringify`](https://tc39.github.io/ecma262/#sec-json.stringify) function of the ECMAScript Language Specification.',group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-number":{doc:'Converts the input value to a number, if possible. If the input is `null` or `false`, the result is 0. If the input is `true`, the result is 1. If the input is a string, it is converted to a number as specified by the ["ToNumber Applied to the String Type" algorithm](https://tc39.github.io/ecma262/#sec-tonumber-applied-to-the-string-type) of the ECMAScript Language Specification. If multiple values are provided, each one is evaluated in order until the first successful conversion is obtained. If none of the inputs can be converted, the expression is an error.',group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-boolean":{doc:"Converts the input value to a boolean. The result is `false` when then input is an empty string, 0, `false`, `null`, or `NaN`; otherwise it is `true`.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-rgba":{doc:"Returns a four-element array containing the input color's red, green, blue, and alpha components, in that order.",group:"Color","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-color":{doc:"Converts the input value to a color. If multiple values are provided, each one is evaluated in order until the first successful conversion is obtained. If none of the inputs can be converted, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},rgb:{doc:"Creates a color value from red, green, and blue components, which must range between 0 and 255, and an alpha component of 1. If any component is out of range, the expression is an error.",group:"Color","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},rgba:{doc:"Creates a color value from red, green, blue components, which must range between 0 and 255, and an alpha component which must range between 0 and 1. If any component is out of range, the expression is an error.",group:"Color","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},get:{doc:"Retrieves a property value from the current feature's properties, or from another object if a second argument is provided. Returns `null` if the requested property is missing.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},has:{doc:"Tests for the presence of an property value in the current feature's properties, or from another object if a second argument is provided.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},length:{doc:"Returns the length of an array or string.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},properties:{doc:'Returns the feature properties object. Note that in some cases, it may be more efficient to use `["get", "property_name"]` directly.',group:"Feature data","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"feature-state":{doc:"Retrieves a property value from the current feature's state. Returns `null` if the requested property is not present on the feature's state. A feature's state is not part of the GeoJSON or vector tile data, and must be set programmatically on each feature. Features are identified by their `id` attribute, which must be an integer or a string that can be cast to an integer. Note that [\"feature-state\"] can only be used with paint properties that support data-driven styling.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.46.0",android:"10.0.0",ios:"10.0.0"}}},"geometry-type":{doc:"Returns the feature's geometry type: `Point`, `LineString` or `Polygon`. `Multi*` feature types return the singular forms.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},id:{doc:"Returns the feature's id, if it has one.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},zoom:{doc:'Returns the current zoom level. Note that in style layout and paint properties, ["zoom"] may only appear as the input to a top-level "step" or "interpolate" expression.',group:"Camera","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},pitch:{doc:'Returns the current pitch in degrees. `["pitch"]` may only be used in the `filter` expression for a `symbol` layer.',group:"Camera","sdk-support":{"basic functionality":{js:"2.6.0",android:"10.9.0",ios:"10.9.0"}}},"distance-from-center":{doc:'Returns the distance of a `symbol` instance from the center of the map. The distance is measured in pixels divided by the height of the map container. It measures 0 at the center, decreases towards the camera and increase away from the camera. For example, if the height of the map is 1000px, a value of -1 means 1000px away from the center towards the camera, and a value of 1 means a distance of 1000px away from the camera from the center. `["distance-from-center"]` may only be used in the `filter` expression for a `symbol` layer.',group:"Camera","sdk-support":{"basic functionality":{js:"2.6.0",android:"10.9.0",ios:"10.9.0"}}},"heatmap-density":{doc:"Returns the kernel density estimation of a pixel in a heatmap layer, which is a relative measure of how many data points are crowded around a particular pixel. Can only be used in the `heatmap-color` property.",group:"Heatmap","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"line-progress":{doc:"Returns the progress along a gradient line. Can only be used in the `line-gradient` property.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.6.0",macos:"0.12.0"}}},"sky-radial-progress":{doc:"Returns the distance of a point on the sky from the sun position. Returns 0 at sun position and 1 when the distance reaches `sky-gradient-radius`. Can only be used in the `sky-gradient` property.",group:"sky","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}}},accumulated:{doc:"Returns the value of a cluster property accumulated so far. Can only be used in the `clusterProperties` option of a clustered GeoJSON source.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.53.0",android:"8.4.0",ios:"5.5.0",macos:"0.15.0"}}},"+":{doc:"Returns the sum of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"*":{doc:"Returns the product of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"-":{doc:"For two inputs, returns the result of subtracting the second input from the first. For a single input, returns the result of subtracting it from 0.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"/":{doc:"Returns the result of floating point division of the first input by the second.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"%":{doc:"Returns the remainder after integer division of the first input by the second.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"^":{doc:"Returns the result of raising the first input to the power specified by the second.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},sqrt:{doc:"Returns the square root of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.42.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},log10:{doc:"Returns the base-ten logarithm of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},ln:{doc:"Returns the natural logarithm of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},log2:{doc:"Returns the base-two logarithm of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},sin:{doc:"Returns the sine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},cos:{doc:"Returns the cosine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},tan:{doc:"Returns the tangent of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},asin:{doc:"Returns the arcsine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},acos:{doc:"Returns the arccosine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},atan:{doc:"Returns the arctangent of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},min:{doc:"Returns the minimum value of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},max:{doc:"Returns the maximum value of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},round:{doc:'Rounds the input to the nearest integer. Halfway values are rounded away from zero. For example, `["round", -1.5]` evaluates to -2.',group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},abs:{doc:"Returns the absolute value of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},ceil:{doc:"Returns the smallest integer that is greater than or equal to the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},floor:{doc:"Returns the largest integer that is less than or equal to the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},distance:{doc:"Returns the shortest distance in meters between the evaluated feature and the input geometry. The input value can be a valid GeoJSON of type `Point`, `MultiPoint`, `LineString`, `MultiLineString`, `Polygon`, `MultiPolygon`, `Feature`, or `FeatureCollection`. Distance values returned may vary in precision due to loss in precision from encoding geometries, particularly below zoom level 13.",group:"Math","sdk-support":{"basic functionality":{android:"9.2.0",ios:"5.9.0",macos:"0.16.0"}}},"==":{doc:"Returns `true` if the input values are equal, `false` otherwise. The comparison is strictly typed: values of different runtime types are always considered unequal. Cases where the types are known to be different at parse time are considered invalid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},"!=":{doc:"Returns `true` if the input values are not equal, `false` otherwise. The comparison is strictly typed: values of different runtime types are always considered unequal. Cases where the types are known to be different at parse time are considered invalid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},">":{doc:"Returns `true` if the first input is strictly greater than the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},"<":{doc:"Returns `true` if the first input is strictly less than the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},">=":{doc:"Returns `true` if the first input is greater than or equal to the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},"<=":{doc:"Returns `true` if the first input is less than or equal to the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},all:{doc:"Returns `true` if all the inputs are `true`, `false` otherwise. The inputs are evaluated in order, and evaluation is short-circuiting: once an input expression evaluates to `false`, the result is `false` and no further input expressions are evaluated.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},any:{doc:"Returns `true` if any of the inputs are `true`, `false` otherwise. The inputs are evaluated in order, and evaluation is short-circuiting: once an input expression evaluates to `true`, the result is `true` and no further input expressions are evaluated.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"!":{doc:"Logical negation. Returns `true` if the input is `false`, and `false` if the input is `true`.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},within:{doc:"Returns `true` if the evaluated feature is fully contained inside a boundary of the input geometry, `false` otherwise. The input value can be a valid GeoJSON of type `Polygon`, `MultiPolygon`, `Feature`, or `FeatureCollection`. Supported features for evaluation:\n- `Point`: Returns `false` if a point is on the boundary or falls outside the boundary.\n- `LineString`: Returns `false` if any part of a line falls outside the boundary, the line intersects the boundary, or a line's endpoint is on the boundary.",group:"Decision","sdk-support":{"basic functionality":{js:"1.9.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}}},"is-supported-script":{doc:"Returns `true` if the input string is expected to render legibly. Returns `false` if the input string contains sections that cannot be rendered without potential loss of meaning (e.g. Indic scripts that require complex text shaping, or right-to-left scripts if the the `mapbox-gl-rtl-text` plugin is not in use in Mapbox GL JS).",group:"String","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.6.0",ios:"4.1.0",macos:"0.8.0"}}},upcase:{doc:"Returns the input string converted to uppercase. Follows the Unicode Default Case Conversion algorithm and the locale-insensitive case mappings in the Unicode Character Database.",group:"String","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},downcase:{doc:"Returns the input string converted to lowercase. Follows the Unicode Default Case Conversion algorithm and the locale-insensitive case mappings in the Unicode Character Database.",group:"String","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},concat:{doc:"Returns a `string` consisting of the concatenation of the inputs. Each input is converted to a string as if by `to-string`.",group:"String","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"resolved-locale":{doc:"Returns the IETF language tag of the locale being used by the provided `collator`. This can be used to determine the default system locale, or to determine if a requested locale was successfully loaded.",group:"String","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}}}},sle={range:{type:"array",default:[.5,10],minimum:-20,maximum:20,length:2,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},doc:"The start and end distance range in which fog fades from fully transparent to fully opaque. The distance to the point at the center of the map is defined as zero, so that negative range values are closer to the camera, and positive values are farther away.",example:[.5,10],"sdk-support":{"basic functionality":{js:"2.3.0",android:"10.6.0",ios:"10.6.0"}}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"The color of the atmosphere region immediately below the horizon and within the `range` and above the horizon and within `horizon-blend`. Using opacity is recommended only for smoothly transitioning fog on/off as anything less than 100% opacity results in more tiles loaded and drawn.","sdk-support":{"basic functionality":{js:"2.3.0",android:"10.6.0",ios:"10.6.0"}}},"high-color":{type:"color","property-type":"data-constant",default:"#245cdf",expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"The color of the atmosphere region above the horizon, `high-color` extends further above the horizon than the `color` property and its spread can be controlled with `horizon-blend`. The opacity can be set to `0` to remove the high atmosphere color contribution.","sdk-support":{"basic functionality":{js:"2.9.0",android:"10.6.0",ios:"10.6.0"}}},"space-color":{type:"color","property-type":"data-constant",default:["interpolate",["linear"],["zoom"],4,"#010b19",7,"#367ab9"],expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"The color of the region above the horizon and after the end of the `horizon-blend` contribution. The opacity can be set to `0` to have a transparent background.","sdk-support":{"basic functionality":{js:"2.9.0",android:"10.6.0",ios:"10.6.0"}}},"horizon-blend":{type:"number","property-type":"data-constant",default:["interpolate",["linear"],["zoom"],4,.2,7,.1],minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Horizon blend applies a smooth fade from the color of the atmosphere to the color of space. A value of zero leaves a sharp transition from atmosphere to space. Increasing the value blends the color of atmosphere into increasingly high angles of the sky.","sdk-support":{"basic functionality":{js:"2.3.0",android:"10.6.0",ios:"10.6.0"}}},"star-intensity":{type:"number","property-type":"data-constant",default:["interpolate",["linear"],["zoom"],5,.35,6,0],minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"A value controlling the star intensity where `0` will show no stars and `1` will show stars at their maximum intensity.","sdk-support":{"basic functionality":{js:"2.9.0",android:"10.6.0",ios:"10.6.0"}}}},lle={anchor:{type:"enum",default:"viewport",values:{map:{doc:"The position of the light source is aligned to the rotation of the map."},viewport:{doc:"The position of the light source is aligned to the rotation of the viewport."}},"property-type":"data-constant",transition:!1,expression:{interpolated:!1,parameters:["zoom"]},doc:"Whether extruded geometries are lit relative to the map or viewport.",example:"map","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},position:{type:"array",default:[1.15,210,30],length:3,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},doc:"Position of the light source relative to lit (extruded) geometries, in [r radial coordinate, a azimuthal angle, p polar angle] where r indicates the distance from the center of the base of an object to its light, a indicates the position of the light relative to 0° (0° when `light.anchor` is set to `viewport` corresponds to the top of the viewport, or 0° when `light.anchor` is set to `map` corresponds to due north, and degrees proceed clockwise), and p indicates the height of the light (from 0°, directly above, to 180°, directly below).",example:[1.5,90,80],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Color tint for lighting extruded geometries.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},intensity:{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Intensity of lighting (on a scale from 0 to 1). Higher numbers will present as more extreme contrast.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}}},ule={name:{type:"enum",values:{albers:{doc:"An Albers equal-area projection centered on the continental United States. You can configure the projection for a different region by setting `center` and `parallels` properties. You may want to set max bounds to constrain the map to the relevant region."},equalEarth:{doc:"An Equal Earth projection."},equirectangular:{doc:"An Equirectangular projection. This projection is very similar to the Plate Carrée projection."},lambertConformalConic:{doc:"A Lambert conformal conic projection. You can configure the projection for a region by setting `center` and `parallels` properties. You may want to set max bounds to constrain the map to the relevant region."},mercator:{doc:"The Mercator projection is the default projection."},naturalEarth:{doc:"A Natural Earth projection."},winkelTripel:{doc:"A Winkel Tripel projection."},globe:{doc:"A globe projection."}},default:"mercator",doc:"The name of the projection to be used for rendering the map.",required:!0,"sdk-support":{"basic functionality":{js:"2.6.0"}}},center:{type:"array",length:2,value:"number","property-type":"data-constant",minimum:[-180,-90],maximum:[180,90],transition:!1,doc:"The reference longitude and latitude of the projection. `center` takes the form of [lng, lat]. This property is only configurable for conic projections (Albers and Lambert Conformal Conic). All other projections are centered on [0, 0].",example:[-96,37.5],requires:[{name:["albers","lambertConformalConic"]}],"sdk-support":{"basic functionality":{js:"2.6.0"}}},parallels:{type:"array",length:2,value:"number","property-type":"data-constant",minimum:[-90,-90],maximum:[90,90],transition:!1,doc:"The standard parallels of the projection, denoting the desired latitude range with minimal distortion. `parallels` takes the form of [lat0, lat1]. This property is only configurable for conic projections (Albers and Lambert Conformal Conic).",example:[29.5,45.5],requires:[{name:["albers","lambertConformalConic"]}],"sdk-support":{"basic functionality":{js:"2.6.0"}}}},Ale={source:{type:"string",doc:"Name of a source of `raster_dem` type to be used for terrain elevation.",required:!0,"sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}}},exaggeration:{type:"number","property-type":"data-constant",default:1,minimum:0,maximum:1e3,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Exaggerates the elevation of the terrain by multiplying the data from the DEM with this value.",requires:["source"],"sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}}}},cle=["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background","paint_sky"],dle={"fill-antialias":{type:"boolean",default:!0,doc:"Whether or not the fill should be antialiased.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity of the entire fill layer. In contrast to the `fill-color`, this value will also affect the 1px stroke around the fill, if the stroke is used.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.21.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{type:"color",default:"#000000",doc:"The color of the filled part of this layer. This color can be specified as `rgba` with an alpha component and the color's opacity will not affect the opacity of the 1px stroke, if it is used.",transition:!0,requires:[{"!":"fill-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.19.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{type:"color",doc:"The outline color of the fill. Matches the value of `fill-color` if unspecified.",transition:!0,requires:[{"!":"fill-pattern"},{"fill-antialias":!0}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.19.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{type:"enum",values:{map:{doc:"The fill is translated relative to the map."},viewport:{doc:"The fill is translated relative to the viewport."}},doc:"Controls the frame of reference for `fill-translate`.",default:"map",requires:["fill-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-pattern":{type:"resolvedImage",transition:!1,doc:"Name of image in sprite to use for drawing image fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.49.0",android:"6.5.0",macos:"0.11.0",ios:"4.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"}},hle={"line-opacity":{type:"number",doc:"The opacity at which the line will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{type:"color",doc:"The color with which the line will be drawn.",default:"#000000",transition:!0,requires:[{"!":"line-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.23.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{type:"enum",values:{map:{doc:"The line is translated relative to the map."},viewport:{doc:"The line is translated relative to the viewport."}},doc:"Controls the frame of reference for `line-translate`.",default:"map",requires:["line-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-width":{type:"number",default:1,minimum:0,transition:!0,units:"pixels",doc:"Stroke thickness.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{type:"number",default:0,minimum:0,doc:"Draws a line casing outside of a line's actual path. Value indicates the width of the inner gap.",transition:!0,units:"pixels","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{type:"number",default:0,doc:"The line's offset. For linear features, a positive value offsets the line to the right, relative to the direction of the line, and a negative value to the left. For polygon features, a positive value results in an inset, and a negative value results in an outset.",transition:!0,units:"pixels","sdk-support":{"basic functionality":{js:"0.12.1",android:"3.0.0",ios:"3.1.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Blur applied to the line, in pixels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{type:"array",value:"number",doc:"Specifies the lengths of the alternating dashes and gaps that form the dash pattern. The lengths are later scaled by the line width. To convert a dash length to pixels, multiply the length by the current line width. Note that GeoJSON sources with `lineMetrics: true` specified won't render dashed lines to the expected scale. Also note that zoom-dependent expressions will be evaluated only at integer zoom levels.",minimum:0,transition:!1,units:"line widths",requires:[{"!":"line-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"2.3.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-pattern":{type:"resolvedImage",transition:!1,doc:"Name of image in sprite to use for drawing image lines. For seamless patterns, image width must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.49.0",android:"6.5.0",macos:"0.11.0",ios:"4.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-gradient":{type:"color",doc:'Defines a gradient with which to color a line feature. Can only be used with GeoJSON sources that specify `"lineMetrics": true`.',transition:!1,requires:[{"!":"line-pattern"},{source:"geojson",has:{lineMetrics:!0}}],"sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.4.0",macos:"0.11.0"},"data-driven styling":{}},expression:{interpolated:!0,parameters:["line-progress"]},"property-type":"color-ramp"},"line-trim-offset":{type:"array",value:"number",doc:"The line part between [trim-start, trim-end] will be marked as transparent to make a route vanishing effect. The line trim-off offset is based on the whole line range [0.0, 1.0].",length:2,default:[0,0],minimum:[0,0],maximum:[1,1],transition:!1,requires:[{source:"geojson",has:{lineMetrics:!0}}],"sdk-support":{"basic functionality":{js:"2.9.0",android:"10.5.0",ios:"10.5.0",macos:"10.5.0"}},"property-type":"constant"}},fle={"circle-radius":{type:"number",default:5,minimum:0,transition:!0,units:"pixels",doc:"Circle radius.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.18.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{type:"color",default:"#000000",doc:"The fill color of the circle.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.18.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{type:"number",default:0,doc:"Amount to blur the circle. 1 blurs the circle such that only the centerpoint is full opacity.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.20.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{type:"number",doc:"The opacity at which the circle will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.20.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{type:"enum",values:{map:{doc:"The circle is translated relative to the map."},viewport:{doc:"The circle is translated relative to the viewport."}},doc:"Controls the frame of reference for `circle-translate`.",default:"map",requires:["circle-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{type:"enum",values:{map:{doc:"Circles are scaled according to their apparent distance to the camera."},viewport:{doc:"Circles are not scaled."}},default:"map",doc:"Controls the scaling behavior of the circle when the map is pitched.","sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{type:"enum",values:{map:{doc:"The circle is aligned to the plane of the map."},viewport:{doc:"The circle is aligned to the plane of the viewport."}},default:"viewport",doc:"Orientation of circle when map is pitched.","sdk-support":{"basic functionality":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"The width of the circle's stroke. Strokes are placed outside of the `circle-radius`.","sdk-support":{"basic functionality":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{type:"color",default:"#000000",doc:"The stroke color of the circle.",transition:!0,"sdk-support":{"basic functionality":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{type:"number",doc:"The opacity of the circle's stroke.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"}},ple={"heatmap-radius":{type:"number",default:30,minimum:1,transition:!0,units:"pixels",doc:"Radius of influence of one heatmap point in pixels. Increasing the value makes the heatmap smoother, but less detailed. `queryRenderedFeatures` on heatmap layers will return points within this radius.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},"data-driven styling":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{type:"number",default:1,minimum:0,transition:!1,doc:"A measure of how much an individual point contributes to the heatmap. A value of 10 would be equivalent to having 10 points of weight 1 in the same spot. Especially useful when combined with clustering.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},"data-driven styling":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{type:"number",default:1,minimum:0,transition:!0,doc:"Similar to `heatmap-weight` but controls the intensity of the heatmap globally. Primarily used for adjusting the heatmap based on zoom level.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"heatmap-color":{type:"color",default:["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],doc:'Defines the color of each pixel based on its density value in a heatmap. Should be an expression that uses `["heatmap-density"]` as input.',transition:!1,"sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},"data-driven styling":{}},expression:{interpolated:!0,parameters:["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{type:"number",doc:"The global opacity at which the heatmap layer will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},mle={"icon-opacity":{doc:"The opacity at which the icon will be drawn.",type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{type:"color",default:"#000000",transition:!0,doc:"The color of the icon. This can only be used with [SDF icons](/help/troubleshooting/using-recolorable-images-in-mapbox-maps/).",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,doc:"The color of the icon's halo. Icon halos can only be used with [SDF icons](/help/troubleshooting/using-recolorable-images-in-mapbox-maps/).",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Distance of halo to the icon outline.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Fade out the halo towards the outside.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"Distance that the icon's anchor is moved from its original placement. Positive values indicate right and down, while negative values indicate left and up.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{type:"enum",values:{map:{doc:"Icons are translated relative to the map."},viewport:{doc:"Icons are translated relative to the viewport."}},doc:"Controls the frame of reference for `icon-translate`.",default:"map",requires:["icon-image","icon-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-opacity":{type:"number",doc:"The opacity at which the text will be drawn.",default:1,minimum:0,maximum:1,transition:!0,requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{type:"color",doc:"The color with which the text will be drawn.",default:"#000000",transition:!0,overridable:!0,requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,doc:"The color of the text's halo, which helps it stand out from backgrounds.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Distance of halo to the font outline. Max text halo width is 1/4 of the font-size.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"The halo's fadeout distance towards the outside.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"Distance that the text's anchor is moved from its original placement. Positive values indicate right and down, while negative values indicate left and up.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{type:"enum",values:{map:{doc:"The text is translated relative to the map."},viewport:{doc:"The text is translated relative to the viewport."}},doc:"Controls the frame of reference for `text-translate`.",default:"map",requires:["text-field","text-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},gle={"raster-opacity":{type:"number",doc:"The opacity at which the image will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{type:"number",default:0,period:360,transition:!0,units:"degrees",doc:"Rotates hues around the color wheel.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{type:"number",doc:"Increase or reduce the brightness of the image. The value is the minimum brightness.",default:0,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{type:"number",doc:"Increase or reduce the brightness of the image. The value is the maximum brightness.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-saturation":{type:"number",doc:"Increase or reduce the saturation of the image.",default:0,minimum:-1,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-contrast":{type:"number",doc:"Increase or reduce the contrast of the image.",default:0,minimum:-1,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-resampling":{type:"enum",doc:"The resampling/interpolation method to use for overscaling, also known as texture magnification filter",values:{linear:{doc:"(Bi)linear filtering interpolates pixel values using the weighted average of the four closest original source pixels creating a smooth but blurry look when overscaled"},nearest:{doc:"Nearest neighbor filtering interpolates pixel values using the nearest original source pixel creating a sharp but pixelated look when overscaled"}},default:"linear","sdk-support":{"basic functionality":{js:"0.47.0",android:"6.3.0",ios:"4.2.0",macos:"0.9.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{type:"number",default:300,minimum:0,transition:!1,units:"milliseconds",doc:"Fade duration when a new tile is added.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},yle={"hillshade-illumination-direction":{type:"number",default:335,minimum:0,maximum:359,doc:"The direction of the light source used to generate the hillshading with 0 as the top of the viewport if `hillshade-illumination-anchor` is set to `viewport` and due north if `hillshade-illumination-anchor` is set to `map`.",transition:!1,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{type:"enum",values:{map:{doc:"The hillshade illumination is relative to the north direction."},viewport:{doc:"The hillshade illumination is relative to the top of the viewport."}},default:"viewport",doc:"Direction of light source when map is rotated.","sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{type:"number",doc:"Intensity of the hillshade",default:.5,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{type:"color",default:"#000000",doc:"The shading color of areas that face away from the light source.",transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",doc:"The shading color of areas that faces towards the light source.",transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{type:"color",default:"#000000",doc:"The shading color used to accentuate rugged terrain like sharp cliffs and gorges.",transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},vle={"background-color":{type:"color",default:"#000000",doc:"The color with which the background will be drawn.",transition:!0,requires:[{"!":"background-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"background-pattern":{type:"resolvedImage",transition:!1,doc:"Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity at which the background will be drawn.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},Cle={"sky-type":{type:"enum",values:{gradient:{doc:"Renders the sky with a gradient that can be configured with `sky-gradient-radius` and `sky-gradient`."},atmosphere:{doc:"Renders the sky with a simulated atmospheric scattering algorithm, the sun direction can be attached to the light position or explicitly set through `sky-atmosphere-sun`."}},default:"atmosphere",doc:"The type of the sky","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"sky-atmosphere-sun":{type:"array",value:"number",length:2,units:"degrees",minimum:[0,0],maximum:[360,180],transition:!1,doc:"Position of the sun center [a azimuthal angle, p polar angle]. The azimuthal angle indicates the position of the sun relative to 0° north, where degrees proceed clockwise. The polar angle indicates the height of the sun, where 0° is directly above, at zenith, and 90° at the horizon. When this property is ommitted, the sun center is directly inherited from the light position.","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},requires:[{"sky-type":"atmosphere"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"sky-atmosphere-sun-intensity":{type:"number",requires:[{"sky-type":"atmosphere"}],default:10,minimum:0,maximum:100,transition:!1,doc:"Intensity of the sun as a light source in the atmosphere (on a scale from 0 to a 100). Setting higher values will brighten up the sky.","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},"property-type":"data-constant"},"sky-gradient-center":{type:"array",requires:[{"sky-type":"gradient"}],value:"number",default:[0,0],length:2,units:"degrees",minimum:[0,0],maximum:[360,180],transition:!1,doc:"Position of the gradient center [a azimuthal angle, p polar angle]. The azimuthal angle indicates the position of the gradient center relative to 0° north, where degrees proceed clockwise. The polar angle indicates the height of the gradient center, where 0° is directly above, at zenith, and 90° at the horizon.","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"sky-gradient-radius":{type:"number",requires:[{"sky-type":"gradient"}],default:90,minimum:0,maximum:180,transition:!1,doc:"The angular distance (measured in degrees) from `sky-gradient-center` up to which the gradient extends. A value of 180 causes the gradient to wrap around to the opposite direction from `sky-gradient-center`.","sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"sky-gradient":{type:"color",default:["interpolate",["linear"],["sky-radial-progress"],.8,"#87ceeb",1,"white"],doc:"Defines a radial color gradient with which to color the sky. The color values can be interpolated with an expression using `sky-radial-progress`. The range [0, 1] for the interpolant covers a radial distance (in degrees) of [0, `sky-gradient-radius`] centered at the position specified by `sky-gradient-center`.",transition:!1,requires:[{"sky-type":"gradient"}],"sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"},"data-driven styling":{}},expression:{interpolated:!0,parameters:["sky-radial-progress"]},"property-type":"color-ramp"},"sky-atmosphere-halo-color":{type:"color",default:"white",doc:"A color applied to the atmosphere sun halo. The alpha channel describes how strongly the sun halo is represented in an atmosphere sky layer.",transition:!1,requires:[{"sky-type":"atmosphere"}],"sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},"property-type":"data-constant"},"sky-atmosphere-color":{type:"color",default:"white",doc:"A color used to tweak the main atmospheric scattering coefficients. Using white applies the default coefficients giving the natural blue color to the atmosphere. This color affects how heavily the corresponding wavelength is represented during scattering. The alpha channel describes the density of the atmosphere, with 1 maximum density and 0 no density.",transition:!1,requires:[{"sky-type":"atmosphere"}],"sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},"property-type":"data-constant"},"sky-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity of the entire sky layer.",transition:!0,"sdk-support":{"basic functionality":{js:"2.0.0",ios:"10.0.0",android:"10.0.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},_le={duration:{type:"number",default:300,minimum:0,units:"milliseconds",doc:"Time allotted for transitions to complete."},delay:{type:"number",default:0,minimum:0,units:"milliseconds",doc:"Length of time before a transition begins."}},ble={"*":{type:"string",doc:"A name of a feature property to use as ID for feature state."}},Nz={$version:Bse,$root:kse,sources:Ise,source:Tse,source_vector:Kse,source_raster:Pse,source_raster_dem:Fse,source_geojson:Dse,source_video:Use,source_image:Rse,layer:Lse,layout:zse,layout_background:jse,layout_sky:Wse,layout_fill:Nse,layout_circle:Gse,layout_heatmap:Qse,"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},"property-type":"constant"},"fill-extrusion-edge-radius":{type:"number",private:!0,default:0,minimum:0,maximum:1,doc:"Radius of a fill extrusion edge in meters. If not zero, rounds extrusion edges for a smoother appearance.","sdk-support":{"basic functionality":{js:"v2.10.0",android:"10.7.0",ios:"10.7.0"}},"property-type":"constant"}},layout_line:$se,layout_symbol:Yse,layout_raster:qse,layout_hillshade:Vse,filter:Hse,filter_symbol:Zse,filter_fill:Xse,filter_line:Jse,filter_circle:ele,"filter_fill-extrusion":{type:"boolean",doc:'Expression which determines whether or not to display a Polygon. Fill-extrusion layer does NOT support dynamic filtering, meaning this expression can NOT use the `["pitch"]` and `["distance-from-center"]` expressions to reference the current state of the view.',default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}},filter_heatmap:tle,filter_operator:nle,geometry_type:rle,function:{expression:{type:"expression",doc:"An expression."},stops:{type:"array",doc:"An array of stops.",value:"function_stop"},base:{type:"number",default:1,minimum:0,doc:"The exponential base of the interpolation curve. It controls the rate at which the result increases. Higher values make the result increase more towards the high end of the range. With `1` the stops are interpolated linearly."},property:{type:"string",doc:"The name of a feature property to use as the function input.",default:"$zoom"},type:{type:"enum",values:{identity:{doc:"Return the input value as the output value."},exponential:{doc:"Generate an output by interpolating between stops just less than and just greater than the function input."},interval:{doc:"Return the output value of the stop just less than the function input."},categorical:{doc:"Return the output value of the stop equal to the function input."}},doc:"The interpolation strategy to use in function evaluation.",default:"exponential"},colorSpace:{type:"enum",values:{rgb:{doc:"Use the RGB color space to interpolate color values"},lab:{doc:"Use the LAB color space to interpolate color values."},hcl:{doc:"Use the HCL color space to interpolate color values, interpolating the Hue, Chroma, and Luminance channels individually."}},doc:"The color space in which colors interpolated. Interpolating colors in perceptual color spaces like LAB and HCL tend to produce color ramps that look more consistent and produce colors that can be differentiated more easily than those interpolated in RGB space.",default:"rgb"},default:{type:"*",required:!1,doc:`A value to serve as a fallback function result when a value isn't otherwise available. It is used in the following circumstances:
|
||
* In categorical functions, when the feature value does not match any of the stop domain values.
|
||
* In property and zoom-and-property functions, when a feature does not contain a value for the specified property.
|
||
* In identity functions, when the feature value is not valid for the style property (for example, if the function is being used for a \`circle-color\` property but the feature property value is not a string or not a valid color).
|
||
* In interval or exponential property and zoom-and-property functions, when the feature value is not numeric.
|
||
If no default is provided, the style property's default is used in these circumstances.`}},function_stop:ile,expression:ole,expression_name:ale,fog:sle,light:lle,projection:ule,terrain:Ale,paint:cle,paint_fill:dle,"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity of the entire fill extrusion layer. This is rendered on a per-layer, not per-feature, basis, and data-driven styling is not available.",transition:!0,"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{type:"color",default:"#000000",doc:"The base color of the extruded fill. The extrusion's surfaces will be shaded differently based on this color in combination with the root `light` settings. If this color is specified as `rgba` with an alpha component, the alpha component will be ignored; use `fill-extrusion-opacity` to set layer opacity.",transition:!0,requires:[{"!":"fill-extrusion-pattern"}],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up (on the flat plane), respectively.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{type:"enum",values:{map:{doc:"The fill extrusion is translated relative to the map."},viewport:{doc:"The fill extrusion is translated relative to the viewport."}},doc:"Controls the frame of reference for `fill-extrusion-translate`.",default:"map",requires:["fill-extrusion-translate"],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{type:"resolvedImage",transition:!1,doc:"Name of image in sprite to use for drawing images on extruded fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.49.0",android:"6.5.0",macos:"0.11.0",ios:"4.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"fill-extrusion-height":{type:"number",default:0,minimum:0,units:"meters",doc:"The height with which to extrude this layer.",transition:!0,"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{type:"number",default:0,minimum:0,units:"meters",doc:"The height with which to extrude the base of this layer. Must be less than or equal to `fill-extrusion-height`.",transition:!0,requires:["fill-extrusion-height"],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{type:"boolean",default:!0,doc:"Whether to apply a vertical gradient to the sides of a fill-extrusion layer. If true, sides will be shaded slightly darker farther down.",transition:!1,"sdk-support":{"basic functionality":{js:"0.50.0",android:"7.0.0",ios:"4.7.0",macos:"0.13.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-ambient-occlusion-intensity":{"property-type":"data-constant",type:"number",private:!0,default:0,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Controls the intensity of shading near ground and concave angles between walls. Default value 0.0 disables ambient occlusion and values around 0.3 provide the most plausible results for buildings.","sdk-support":{"basic functionality":{js:"2.10.0",android:"10.7.0",ios:"10.7.0"}}},"fill-extrusion-ambient-occlusion-radius":{"property-type":"data-constant",type:"number",private:!0,default:3,minimum:0,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Shades area near ground and concave angles between walls where the radius defines only vertical impact. Default value 3.0 corresponds to height of one floor and brings the most plausible results for buildings.",requires:["fill-extrusion-edge-radius"],"sdk-support":{"basic functionality":{js:"2.10.0",android:"10.7.0",ios:"10.7.0"}}}},paint_line:hle,paint_circle:fle,paint_heatmap:ple,paint_symbol:mle,paint_raster:gle,paint_hillshade:yle,paint_background:vle,paint_sky:Cle,transition:_le,"property-type":{"data-driven":{type:"property-type",doc:"Property is interpolable and can be represented using a property expression."},"color-ramp":{type:"property-type",doc:"Property should be specified using a color ramp from which the output color can be sampled based on a property calculation."},"data-constant":{type:"property-type",doc:"Property is interpolable but cannot be represented using a property expression."},constant:{type:"property-type",doc:"Property is constant across all zoom levels and property values."}},promoteId:ble},xM=typeof globalThis<"u"?globalThis:typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{},sE={exports:{}};/*! https://mths.be/punycode v1.3.2 by @mathias */(function(e,n){(function(t){var r=n&&!n.nodeType&&n,i=e&&!e.nodeType&&e,o=typeof xM=="object"&&xM;(o.global===o||o.window===o||o.self===o)&&(t=o);var s,a=2147483647,f=36,g=1,x=26,k=38,B=700,P=72,R=128,H="-",W=/^xn--/,$=/[^\x20-\x7E]/,q=/[\x2E\u3002\uFF0E\uFF61]/g,oe={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},ne=f-g,ce=Math.floor,ae=String.fromCharCode,ue;function ye(Ve){throw RangeError(oe[Ve])}function Re(Ve,nt){for(var Je=Ve.length,Vt=[];Je--;)Vt[Je]=nt(Ve[Je]);return Vt}function Ne(Ve,nt){var Je=Ve.split("@"),Vt="";Je.length>1&&(Vt=Je[0]+"@",Ve=Je[1]),Ve=Ve.replace(q,".");var pt=Ve.split("."),dt=Re(pt,nt).join(".");return Vt+dt}function rt(Ve){for(var nt=[],Je=0,Vt=Ve.length,pt,dt;Je<Vt;)pt=Ve.charCodeAt(Je++),pt>=55296&&pt<=56319&&Je<Vt?(dt=Ve.charCodeAt(Je++),(dt&64512)==56320?nt.push(((pt&1023)<<10)+(dt&1023)+65536):(nt.push(pt),Je--)):nt.push(pt);return nt}function ct(Ve){return Re(Ve,function(nt){var Je="";return nt>65535&&(nt-=65536,Je+=ae(nt>>>10&1023|55296),nt=56320|nt&1023),Je+=ae(nt),Je}).join("")}function Fe(Ve){return Ve-48<10?Ve-22:Ve-65<26?Ve-65:Ve-97<26?Ve-97:f}function He(Ve,nt){return Ve+22+75*(Ve<26)-((nt!=0)<<5)}function Ce(Ve,nt,Je){var Vt=0;for(Ve=Je?ce(Ve/B):Ve>>1,Ve+=ce(Ve/nt);Ve>ne*x>>1;Vt+=f)Ve=ce(Ve/ne);return ce(Vt+(ne+1)*Ve/(Ve+k))}function jt(Ve){var nt=[],Je=Ve.length,Vt,pt=0,dt=R,kt=P,Dt,Se,de,xe,Pe,Ze,Xe,wt,Kt;for(Dt=Ve.lastIndexOf(H),Dt<0&&(Dt=0),Se=0;Se<Dt;++Se)Ve.charCodeAt(Se)>=128&&ye("not-basic"),nt.push(Ve.charCodeAt(Se));for(de=Dt>0?Dt+1:0;de<Je;){for(xe=pt,Pe=1,Ze=f;de>=Je&&ye("invalid-input"),Xe=Fe(Ve.charCodeAt(de++)),(Xe>=f||Xe>ce((a-pt)/Pe))&&ye("overflow"),pt+=Xe*Pe,wt=Ze<=kt?g:Ze>=kt+x?x:Ze-kt,!(Xe<wt);Ze+=f)Kt=f-wt,Pe>ce(a/Kt)&&ye("overflow"),Pe*=Kt;Vt=nt.length+1,kt=Ce(pt-xe,Vt,xe==0),ce(pt/Vt)>a-dt&&ye("overflow"),dt+=ce(pt/Vt),pt%=Vt,nt.splice(pt++,0,dt)}return ct(nt)}function Ft(Ve){var nt,Je,Vt,pt,dt,kt,Dt,Se,de,xe,Pe,Ze=[],Xe,wt,Kt,Pt;for(Ve=rt(Ve),Xe=Ve.length,nt=R,Je=0,dt=P,kt=0;kt<Xe;++kt)Pe=Ve[kt],Pe<128&&Ze.push(ae(Pe));for(Vt=pt=Ze.length,pt&&Ze.push(H);Vt<Xe;){for(Dt=a,kt=0;kt<Xe;++kt)Pe=Ve[kt],Pe>=nt&&Pe<Dt&&(Dt=Pe);for(wt=Vt+1,Dt-nt>ce((a-Je)/wt)&&ye("overflow"),Je+=(Dt-nt)*wt,nt=Dt,kt=0;kt<Xe;++kt)if(Pe=Ve[kt],Pe<nt&&++Je>a&&ye("overflow"),Pe==nt){for(Se=Je,de=f;xe=de<=dt?g:de>=dt+x?x:de-dt,!(Se<xe);de+=f)Pt=Se-xe,Kt=f-xe,Ze.push(ae(He(xe+Pt%Kt,0))),Se=ce(Pt/Kt);Ze.push(ae(He(Se,0))),dt=Ce(Je,wt,Vt==pt),Je=0,++Vt}++Je,++nt}return Ze.join("")}function Jt(Ve){return Ne(Ve,function(nt){return W.test(nt)?jt(nt.slice(4).toLowerCase()):nt})}function Nt(Ve){return Ne(Ve,function(nt){return $.test(nt)?"xn--"+Ft(nt):nt})}if(s={version:"1.3.2",ucs2:{decode:rt,encode:ct},decode:jt,encode:Ft,toASCII:Nt,toUnicode:Jt},r&&i)if(e.exports==r)i.exports=s;else for(ue in s)s.hasOwnProperty(ue)&&(r[ue]=s[ue]);else t.punycode=s})(xM)})(sE,sE.exports);var xle={isString:function(e){return typeof e=="string"},isObject:function(e){return typeof e=="object"&&e!==null},isNull:function(e){return e===null},isNullOrUndefined:function(e){return e==null}},v_={};function wle(e,n){return Object.prototype.hasOwnProperty.call(e,n)}var Mle=function(e,n,t,r){n=n||"&",t=t||"=";var i={};if(typeof e!="string"||e.length===0)return i;var o=/\+/g;e=e.split(n);var s=1e3;r&&typeof r.maxKeys=="number"&&(s=r.maxKeys);var a=e.length;s>0&&a>s&&(a=s);for(var f=0;f<a;++f){var g=e[f].replace(o,"%20"),x=g.indexOf(t),k,B,P,R;x>=0?(k=g.substr(0,x),B=g.substr(x+1)):(k=g,B=""),P=decodeURIComponent(k),R=decodeURIComponent(B),wle(i,P)?Array.isArray(i[P])?i[P].push(R):i[P]=[i[P],R]:i[P]=R}return i},Qv=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}},Sle=function(e,n,t,r){return n=n||"&",t=t||"=",e===null&&(e=void 0),typeof e=="object"?Object.keys(e).map(function(i){var o=encodeURIComponent(Qv(i))+t;return Array.isArray(e[i])?e[i].map(function(s){return o+encodeURIComponent(Qv(s))}).join(n):o+encodeURIComponent(Qv(e[i]))}).join(n):r?encodeURIComponent(Qv(r))+t+encodeURIComponent(Qv(e)):""};v_.decode=v_.parse=Mle;v_.encode=v_.stringify=Sle;var Ele=sE.exports,cp=xle;function xp(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var Ole=/^([a-z0-9.+-]+:)/i,Ble=/:[0-9]*$/,kle=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,Ile=["<",">",'"',"`"," ","\r",`
|
||
`," "],Tle=["{","}","|","\\","^","`"].concat(Ile),lE=["'"].concat(Tle),J9=["%","/","?",";","#"].concat(lE),eT=["/","?","#"],Kle=255,tT=/^[+a-z0-9A-Z_-]{0,63}$/,Ple=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Fle={javascript:!0,"javascript:":!0},uE={javascript:!0,"javascript:":!0},ry={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},AE=v_;function Dle(e,n,t){if(e&&cp.isObject(e)&&e instanceof xp)return e;var r=new xp;return r.parse(e,n,t),r}xp.prototype.parse=function(e,n,t){if(!cp.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var r=e.indexOf("?"),i=r!==-1&&r<e.indexOf("#")?"?":"#",o=e.split(i),s=/\\/g;o[0]=o[0].replace(s,"/"),e=o.join(i);var a=e;if(a=a.trim(),!t&&e.split("#").length===1){var f=kle.exec(a);if(f)return this.path=a,this.href=a,this.pathname=f[1],f[2]?(this.search=f[2],n?this.query=AE.parse(this.search.substr(1)):this.query=this.search.substr(1)):n&&(this.search="",this.query={}),this}var g=Ole.exec(a);if(g){g=g[0];var x=g.toLowerCase();this.protocol=x,a=a.substr(g.length)}if(t||g||a.match(/^\/\/[^@\/]+@[^@\/]+/)){var k=a.substr(0,2)==="//";k&&!(g&&uE[g])&&(a=a.substr(2),this.slashes=!0)}if(!uE[g]&&(k||g&&!ry[g])){for(var B=-1,P=0;P<eT.length;P++){var R=a.indexOf(eT[P]);R!==-1&&(B===-1||R<B)&&(B=R)}var H,W;B===-1?W=a.lastIndexOf("@"):W=a.lastIndexOf("@",B),W!==-1&&(H=a.slice(0,W),a=a.slice(W+1),this.auth=decodeURIComponent(H)),B=-1;for(var P=0;P<J9.length;P++){var R=a.indexOf(J9[P]);R!==-1&&(B===-1||R<B)&&(B=R)}B===-1&&(B=a.length),this.host=a.slice(0,B),a=a.slice(B),this.parseHost(),this.hostname=this.hostname||"";var $=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!$)for(var q=this.hostname.split(/\./),P=0,oe=q.length;P<oe;P++){var ne=q[P];if(ne&&!ne.match(tT)){for(var ce="",ae=0,ue=ne.length;ae<ue;ae++)ne.charCodeAt(ae)>127?ce+="x":ce+=ne[ae];if(!ce.match(tT)){var ye=q.slice(0,P),Re=q.slice(P+1),Ne=ne.match(Ple);Ne&&(ye.push(Ne[1]),Re.unshift(Ne[2])),Re.length&&(a="/"+Re.join(".")+a),this.hostname=ye.join(".");break}}}this.hostname.length>Kle?this.hostname="":this.hostname=this.hostname.toLowerCase(),$||(this.hostname=Ele.toASCII(this.hostname));var rt=this.port?":"+this.port:"",ct=this.hostname||"";this.host=ct+rt,this.href+=this.host,$&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),a[0]!=="/"&&(a="/"+a))}if(!Fle[x])for(var P=0,oe=lE.length;P<oe;P++){var Fe=lE[P];if(a.indexOf(Fe)!==-1){var He=encodeURIComponent(Fe);He===Fe&&(He=escape(Fe)),a=a.split(Fe).join(He)}}var Ce=a.indexOf("#");Ce!==-1&&(this.hash=a.substr(Ce),a=a.slice(0,Ce));var jt=a.indexOf("?");if(jt!==-1?(this.search=a.substr(jt),this.query=a.substr(jt+1),n&&(this.query=AE.parse(this.query)),a=a.slice(0,jt)):n&&(this.search="",this.query={}),a&&(this.pathname=a),ry[x]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var rt=this.pathname||"",Ft=this.search||"";this.path=rt+Ft}return this.href=this.format(),this};xp.prototype.format=function(){var e=this.auth||"";e&&(e=encodeURIComponent(e),e=e.replace(/%3A/i,":"),e+="@");var n=this.protocol||"",t=this.pathname||"",r=this.hash||"",i=!1,o="";this.host?i=e+this.host:this.hostname&&(i=e+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(i+=":"+this.port)),this.query&&cp.isObject(this.query)&&Object.keys(this.query).length&&(o=AE.stringify(this.query));var s=this.search||o&&"?"+o||"";return n&&n.substr(-1)!==":"&&(n+=":"),this.slashes||(!n||ry[n])&&i!==!1?(i="//"+(i||""),t&&t.charAt(0)!=="/"&&(t="/"+t)):i||(i=""),r&&r.charAt(0)!=="#"&&(r="#"+r),s&&s.charAt(0)!=="?"&&(s="?"+s),t=t.replace(/[?#]/g,function(a){return encodeURIComponent(a)}),s=s.replace("#","%23"),n+i+t+s+r};xp.prototype.resolve=function(e){return this.resolveObject(Dle(e,!1,!0)).format()};xp.prototype.resolveObject=function(e){if(cp.isString(e)){var n=new xp;n.parse(e,!1,!0),e=n}for(var t=new xp,r=Object.keys(this),i=0;i<r.length;i++){var o=r[i];t[o]=this[o]}if(t.hash=e.hash,e.href==="")return t.href=t.format(),t;if(e.slashes&&!e.protocol){for(var s=Object.keys(e),a=0;a<s.length;a++){var f=s[a];f!=="protocol"&&(t[f]=e[f])}return ry[t.protocol]&&t.hostname&&!t.pathname&&(t.path=t.pathname="/"),t.href=t.format(),t}if(e.protocol&&e.protocol!==t.protocol){if(!ry[e.protocol]){for(var g=Object.keys(e),x=0;x<g.length;x++){var k=g[x];t[k]=e[k]}return t.href=t.format(),t}if(t.protocol=e.protocol,!e.host&&!uE[e.protocol]){for(var oe=(e.pathname||"").split("/");oe.length&&!(e.host=oe.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),oe[0]!==""&&oe.unshift(""),oe.length<2&&oe.unshift(""),t.pathname=oe.join("/")}else t.pathname=e.pathname;if(t.search=e.search,t.query=e.query,t.host=e.host||"",t.auth=e.auth,t.hostname=e.hostname||e.host,t.port=e.port,t.pathname||t.search){var B=t.pathname||"",P=t.search||"";t.path=B+P}return t.slashes=t.slashes||e.slashes,t.href=t.format(),t}var R=t.pathname&&t.pathname.charAt(0)==="/",H=e.host||e.pathname&&e.pathname.charAt(0)==="/",W=H||R||t.host&&e.pathname,$=W,q=t.pathname&&t.pathname.split("/")||[],oe=e.pathname&&e.pathname.split("/")||[],ne=t.protocol&&!ry[t.protocol];if(ne&&(t.hostname="",t.port=null,t.host&&(q[0]===""?q[0]=t.host:q.unshift(t.host)),t.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(oe[0]===""?oe[0]=e.host:oe.unshift(e.host)),e.host=null),W=W&&(oe[0]===""||q[0]==="")),H)t.host=e.host||e.host===""?e.host:t.host,t.hostname=e.hostname||e.hostname===""?e.hostname:t.hostname,t.search=e.search,t.query=e.query,q=oe;else if(oe.length)q||(q=[]),q.pop(),q=q.concat(oe),t.search=e.search,t.query=e.query;else if(!cp.isNullOrUndefined(e.search)){if(ne){t.hostname=t.host=q.shift();var ce=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;ce&&(t.auth=ce.shift(),t.host=t.hostname=ce.shift())}return t.search=e.search,t.query=e.query,(!cp.isNull(t.pathname)||!cp.isNull(t.search))&&(t.path=(t.pathname?t.pathname:"")+(t.search?t.search:"")),t.href=t.format(),t}if(!q.length)return t.pathname=null,t.search?t.path="/"+t.search:t.path=null,t.href=t.format(),t;for(var ae=q.slice(-1)[0],ue=(t.host||e.host||q.length>1)&&(ae==="."||ae==="..")||ae==="",ye=0,Re=q.length;Re>=0;Re--)ae=q[Re],ae==="."?q.splice(Re,1):ae===".."?(q.splice(Re,1),ye++):ye&&(q.splice(Re,1),ye--);if(!W&&!$)for(;ye--;ye)q.unshift("..");W&&q[0]!==""&&(!q[0]||q[0].charAt(0)!=="/")&&q.unshift(""),ue&&q.join("/").substr(-1)!=="/"&&q.push("");var Ne=q[0]===""||q[0]&&q[0].charAt(0)==="/";if(ne){t.hostname=t.host=Ne?"":q.length?q.shift():"";var ce=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;ce&&(t.auth=ce.shift(),t.host=t.hostname=ce.shift())}return W=W||t.host&&q.length,W&&!Ne&&q.unshift(""),q.length?t.pathname=q.join("/"):(t.pathname=null,t.path=null),(!cp.isNull(t.pathname)||!cp.isNull(t.search))&&(t.path=(t.pathname?t.pathname:"")+(t.search?t.search:"")),t.auth=e.auth||t.auth,t.slashes=t.slashes||e.slashes,t.href=t.format(),t};xp.prototype.parseHost=function(){var e=this.host,n=Ble.exec(e);n&&(n=n[0],n!==":"&&(this.port=n.substr(1)),e=e.substr(0,e.length-n.length)),e&&(this.hostname=e)};function Gz(e,...n){for(const t of n)for(const r in t)e[r]=t[r];return e}class Ule extends Error{constructor(n,t){super(t),this.message=t,this.key=n}}var Zh=Ule;class C7{constructor(n,t=[]){this.parent=n,this.bindings={};for(const[r,i]of t)this.bindings[r]=i}concat(n){return new C7(this,n)}get(n){if(this.bindings[n])return this.bindings[n];if(this.parent)return this.parent.get(n);throw new Error(`${n} not found in scope.`)}has(n){return this.bindings[n]?!0:this.parent?this.parent.has(n):!1}}var Rle=C7;const g5={kind:"null"},Xn={kind:"number"},oo={kind:"string"},Hi={kind:"boolean"},wp={kind:"color"},iy={kind:"object"},Xi={kind:"value"},Lle={kind:"error"},y5={kind:"collator"},v5={kind:"formatted"},J_={kind:"resolvedImage"};function yd(e,n){return{kind:"array",itemType:e,N:n}}function ps(e){if(e.kind==="array"){const n=ps(e.itemType);return typeof e.N=="number"?`array<${n}, ${e.N}>`:e.itemType.kind==="value"?"array":`array<${n}>`}else return e.kind}const zle=[g5,Xn,oo,Hi,wp,v5,iy,yd(Xi),J_];function C_(e,n){if(n.kind==="error")return null;if(e.kind==="array"){if(n.kind==="array"&&(n.N===0&&n.itemType.kind==="value"||!C_(e.itemType,n.itemType))&&(typeof e.N!="number"||e.N===n.N))return null}else{if(e.kind===n.kind)return null;if(e.kind==="value"){for(const t of zle)if(!C_(t,n))return null}}return`Expected ${ps(e)} but found ${ps(n)} instead.`}function _7(e,n){return n.some(t=>t.kind===e.kind)}function __(e,n){return n.some(t=>t==="null"?e===null:t==="array"?Array.isArray(e):t==="object"?e&&!Array.isArray(e)&&typeof e=="object":t===typeof e)}var jle={},Qz,nT={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],rebeccapurple:[102,51,153,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function TC(e){return e=Math.round(e),e<0?0:e>255?255:e}function rT(e){return e<0?0:e>1?1:e}function wM(e){return e[e.length-1]==="%"?TC(parseFloat(e)/100*255):TC(parseInt(e))}function Ix(e){return e[e.length-1]==="%"?rT(parseFloat(e)/100):rT(parseFloat(e))}function MM(e,n,t){return t<0?t+=1:t>1&&(t-=1),t*6<1?e+(n-e)*t*6:t*2<1?n:t*3<2?e+(n-e)*(2/3-t)*6:e}function Wle(e){var n=e.replace(/ /g,"").toLowerCase();if(n in nT)return nT[n].slice();if(n[0]==="#"){if(n.length===4){var t=parseInt(n.substr(1),16);return t>=0&&t<=4095?[(t&3840)>>4|(t&3840)>>8,t&240|(t&240)>>4,t&15|(t&15)<<4,1]:null}else if(n.length===7){var t=parseInt(n.substr(1),16);return t>=0&&t<=16777215?[(t&16711680)>>16,(t&65280)>>8,t&255,1]:null}return null}var r=n.indexOf("("),i=n.indexOf(")");if(r!==-1&&i+1===n.length){var o=n.substr(0,r),s=n.substr(r+1,i-(r+1)).split(","),a=1;switch(o){case"rgba":if(s.length!==4)return null;a=Ix(s.pop());case"rgb":return s.length!==3?null:[wM(s[0]),wM(s[1]),wM(s[2]),a];case"hsla":if(s.length!==4)return null;a=Ix(s.pop());case"hsl":if(s.length!==3)return null;var f=(parseFloat(s[0])%360+360)%360/360,g=Ix(s[1]),x=Ix(s[2]),k=x<=.5?x*(g+1):x+g-x*g,B=x*2-k;return[TC(MM(B,k,f+1/3)*255),TC(MM(B,k,f)*255),TC(MM(B,k,f-1/3)*255),a];default:return null}}return null}try{Qz=jle.parseCSSColor=Wle}catch{}class qA{constructor(n,t,r,i=1){this.r=n,this.g=t,this.b=r,this.a=i}static parse(n){if(!n)return;if(n instanceof qA)return n;if(typeof n!="string")return;const t=Qz(n);if(t)return new qA(t[0]/255*t[3],t[1]/255*t[3],t[2]/255*t[3],t[3])}toString(){const[n,t,r,i]=this.toArray();return`rgba(${Math.round(n)},${Math.round(t)},${Math.round(r)},${i})`}toArray(){const{r:n,g:t,b:r,a:i}=this;return i===0?[0,0,0,0]:[n*255/i,t*255/i,r*255/i,i]}toArray01(){const{r:n,g:t,b:r,a:i}=this;return i===0?[0,0,0,0]:[n/i,t/i,r/i,i]}toArray01PremultipliedAlpha(){const{r:n,g:t,b:r,a:i}=this;return[n,t,r,i]}}qA.black=new qA(0,0,0,1);qA.white=new qA(1,1,1,1);qA.transparent=new qA(0,0,0,0);qA.red=new qA(1,0,0,1);qA.blue=new qA(0,0,1,1);var Gl=qA;class b7{constructor(n,t,r){n?this.sensitivity=t?"variant":"case":this.sensitivity=t?"accent":"base",this.locale=r,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})}compare(n,t){return this.collator.compare(n,t)}resolvedLocale(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale}}class cE{constructor(n,t,r,i,o){this.text=n.normalize?n.normalize():n,this.image=t,this.scale=r,this.fontStack=i,this.textColor=o}}class ch{constructor(n){this.sections=n}static fromString(n){return new ch([new cE(n,null,null,null,null)])}isEmpty(){return this.sections.length===0?!0:!this.sections.some(n=>n.text.length!==0||n.image&&n.image.name.length!==0)}static factory(n){return n instanceof ch?n:ch.fromString(n)}toString(){return this.sections.length===0?"":this.sections.map(n=>n.text).join("")}serialize(){const n=["format"];for(const t of this.sections){if(t.image){n.push(["image",t.image.name]);continue}n.push(t.text);const r={};t.fontStack&&(r["text-font"]=["literal",t.fontStack.split(",")]),t.scale&&(r["font-scale"]=t.scale),t.textColor&&(r["text-color"]=["rgba"].concat(t.textColor.toArray())),n.push(r)}return n}}class Op{constructor(n){this.name=n.name,this.available=n.available}toString(){return this.name}static fromString(n){return n?new Op({name:n,available:!1}):null}serialize(){return["image",this.name]}}function $z(e,n,t,r){return typeof e=="number"&&e>=0&&e<=255&&typeof n=="number"&&n>=0&&n<=255&&typeof t=="number"&&t>=0&&t<=255?typeof r>"u"||typeof r=="number"&&r>=0&&r<=1?null:`Invalid rgba value [${[e,n,t,r].join(", ")}]: 'a' must be between 0 and 1.`:`Invalid rgba value [${(typeof r=="number"?[e,n,t,r]:[e,n,t]).join(", ")}]: 'r', 'g', and 'b' must be between 0 and 255.`}function D3(e){if(e===null)return!0;if(typeof e=="string")return!0;if(typeof e=="boolean")return!0;if(typeof e=="number")return!0;if(e instanceof Gl)return!0;if(e instanceof b7)return!0;if(e instanceof ch)return!0;if(e instanceof Op)return!0;if(Array.isArray(e)){for(const n of e)if(!D3(n))return!1;return!0}else if(typeof e=="object"){for(const n in e)if(!D3(e[n]))return!1;return!0}else return!1}function Wl(e){if(e===null)return g5;if(typeof e=="string")return oo;if(typeof e=="boolean")return Hi;if(typeof e=="number")return Xn;if(e instanceof Gl)return wp;if(e instanceof b7)return y5;if(e instanceof ch)return v5;if(e instanceof Op)return J_;if(Array.isArray(e)){const n=e.length;let t;for(const r of e){const i=Wl(r);if(!t)t=i;else{if(t===i)continue;t=Xi;break}}return yd(t||Xi,n)}else return iy}function KC(e){const n=typeof e;return e===null?"":n==="string"||n==="number"||n==="boolean"?String(e):e instanceof Gl||e instanceof ch||e instanceof Op?e.toString():JSON.stringify(e)}class x7{constructor(n,t){this.type=n,this.value=t}static parse(n,t){if(n.length!==2)return t.error(`'literal' expression requires exactly one argument, but found ${n.length-1} instead.`);if(!D3(n[1]))return t.error("invalid value");const r=n[1];let i=Wl(r);const o=t.expectedType;return i.kind==="array"&&i.N===0&&o&&o.kind==="array"&&(typeof o.N!="number"||o.N===0)&&(i=o),new x7(i,r)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}serialize(){return this.type.kind==="array"||this.type.kind==="object"?["literal",this.value]:this.value instanceof Gl?["rgba"].concat(this.value.toArray()):this.value instanceof ch?this.value.serialize():this.value}}var U3=x7;class Nle{constructor(n){this.name="ExpressionEvaluationError",this.message=n}toJSON(){return this.message}}var Cu=Nle;const SM={string:oo,number:Xn,boolean:Hi,object:iy};class w7{constructor(n,t){this.type=n,this.args=t}static parse(n,t){if(n.length<2)return t.error("Expected at least one argument.");let r=1,i;const o=n[0];if(o==="array"){let a;if(n.length>2){const g=n[1];if(typeof g!="string"||!(g in SM)||g==="object")return t.error('The item type argument of "array" must be one of string, number, boolean',1);a=SM[g],r++}else a=Xi;let f;if(n.length>3){if(n[2]!==null&&(typeof n[2]!="number"||n[2]<0||n[2]!==Math.floor(n[2])))return t.error('The length argument to "array" must be a positive integer literal',2);f=n[2],r++}i=yd(a,f)}else i=SM[o];const s=[];for(;r<n.length;r++){const a=t.parse(n[r],r,Xi);if(!a)return null;s.push(a)}return new w7(i,s)}evaluate(n){for(let t=0;t<this.args.length;t++){const r=this.args[t].evaluate(n);if(C_(this.type,Wl(r))){if(t===this.args.length-1)throw new Cu(`Expected value to be of type ${ps(this.type)}, but found ${ps(Wl(r))} instead.`)}else return r}return null}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}serialize(){const n=this.type,t=[n.kind];if(n.kind==="array"){const r=n.itemType;if(r.kind==="string"||r.kind==="number"||r.kind==="boolean"){t.push(r.kind);const i=n.N;(typeof i=="number"||this.args.length>1)&&t.push(i)}}return t.concat(this.args.map(r=>r.serialize()))}}var mp=w7;class C5{constructor(n){this.type=v5,this.sections=n}static parse(n,t){if(n.length<2)return t.error("Expected at least one argument.");const r=n[1];if(!Array.isArray(r)&&typeof r=="object")return t.error("First argument must be an image or text section.");const i=[];let o=!1;for(let s=1;s<=n.length-1;++s){const a=n[s];if(o&&typeof a=="object"&&!Array.isArray(a)){o=!1;let f=null;if(a["font-scale"]&&(f=t.parse(a["font-scale"],1,Xn),!f))return null;let g=null;if(a["text-font"]&&(g=t.parse(a["text-font"],1,yd(oo)),!g))return null;let x=null;if(a["text-color"]&&(x=t.parse(a["text-color"],1,wp),!x))return null;const k=i[i.length-1];k.scale=f,k.font=g,k.textColor=x}else{const f=t.parse(n[s],1,Xi);if(!f)return null;const g=f.type.kind;if(g!=="string"&&g!=="value"&&g!=="null"&&g!=="resolvedImage")return t.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");o=!0,i.push({content:f,scale:null,font:null,textColor:null})}}return new C5(i)}evaluate(n){const t=r=>{const i=r.content.evaluate(n);return Wl(i)===J_?new cE("",i,null,null,null):new cE(KC(i),null,r.scale?r.scale.evaluate(n):null,r.font?r.font.evaluate(n).join(","):null,r.textColor?r.textColor.evaluate(n):null)};return new ch(this.sections.map(t))}eachChild(n){for(const t of this.sections)n(t.content),t.scale&&n(t.scale),t.font&&n(t.font),t.textColor&&n(t.textColor)}outputDefined(){return!1}serialize(){const n=["format"];for(const t of this.sections){n.push(t.content.serialize());const r={};t.scale&&(r["font-scale"]=t.scale.serialize()),t.font&&(r["text-font"]=t.font.serialize()),t.textColor&&(r["text-color"]=t.textColor.serialize()),n.push(r)}return n}}class _5{constructor(n){this.type=J_,this.input=n}static parse(n,t){if(n.length!==2)return t.error("Expected two arguments.");const r=t.parse(n[1],1,oo);return r?new _5(r):t.error("No image name provided.")}evaluate(n){const t=this.input.evaluate(n),r=Op.fromString(t);return r&&n.availableImages&&(r.available=n.availableImages.indexOf(t)>-1),r}eachChild(n){n(this.input)}outputDefined(){return!1}serialize(){return["image",this.input.serialize()]}}const Gle={"to-boolean":Hi,"to-color":wp,"to-number":Xn,"to-string":oo};class M7{constructor(n,t){this.type=n,this.args=t}static parse(n,t){if(n.length<2)return t.error("Expected at least one argument.");const r=n[0];if((r==="to-boolean"||r==="to-string")&&n.length!==2)return t.error("Expected one argument.");const i=Gle[r],o=[];for(let s=1;s<n.length;s++){const a=t.parse(n[s],s,Xi);if(!a)return null;o.push(a)}return new M7(i,o)}evaluate(n){if(this.type.kind==="boolean")return!!this.args[0].evaluate(n);if(this.type.kind==="color"){let t,r;for(const i of this.args){if(t=i.evaluate(n),r=null,t instanceof Gl)return t;if(typeof t=="string"){const o=n.parseColor(t);if(o)return o}else if(Array.isArray(t)&&(t.length<3||t.length>4?r=`Invalid rbga value ${JSON.stringify(t)}: expected an array containing either three or four numeric values.`:r=$z(t[0],t[1],t[2],t[3]),!r))return new Gl(t[0]/255,t[1]/255,t[2]/255,t[3])}throw new Cu(r||`Could not parse color from value '${typeof t=="string"?t:String(JSON.stringify(t))}'`)}else if(this.type.kind==="number"){let t=null;for(const r of this.args){if(t=r.evaluate(n),t===null)return 0;const i=Number(t);if(!isNaN(i))return i}throw new Cu(`Could not convert ${JSON.stringify(t)} to number.`)}else return this.type.kind==="formatted"?ch.fromString(KC(this.args[0].evaluate(n))):this.type.kind==="resolvedImage"?Op.fromString(KC(this.args[0].evaluate(n))):KC(this.args[0].evaluate(n))}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}serialize(){if(this.type.kind==="formatted")return new C5([{content:this.args[0],scale:null,font:null,textColor:null}]).serialize();if(this.type.kind==="resolvedImage")return new _5(this.args[0]).serialize();const n=[`to-${this.type.kind}`];return this.eachChild(t=>{n.push(t.serialize())}),n}}var Rg=M7;const Qle=["Unknown","Point","LineString","Polygon"];class $le{constructor(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache={},this.availableImages=null,this.canonical=null,this.featureTileCoord=null,this.featureDistanceData=null}id(){return this.feature&&this.feature.id!==void 0?this.feature.id:null}geometryType(){return this.feature?typeof this.feature.type=="number"?Qle[this.feature.type]:this.feature.type:null}geometry(){return this.feature&&"geometry"in this.feature?this.feature.geometry:null}canonicalID(){return this.canonical}properties(){return this.feature&&this.feature.properties||{}}distanceFromCenter(){if(this.featureTileCoord&&this.featureDistanceData){const n=this.featureDistanceData.center,t=this.featureDistanceData.scale,{x:r,y:i}=this.featureTileCoord,o=r*t-n[0],s=i*t-n[1],a=this.featureDistanceData.bearing[0],f=this.featureDistanceData.bearing[1];return a*o+f*s}return 0}parseColor(n){let t=this._parseColorCache[n];return t||(t=this._parseColorCache[n]=Gl.parse(n)),t}}var Yz=$le;class Lg{constructor(n,t,r,i){this.name=n,this.type=t,this._evaluate=r,this.args=i}evaluate(n){return this._evaluate(n,this.args)}eachChild(n){this.args.forEach(n)}outputDefined(){return!1}serialize(){return[this.name].concat(this.args.map(n=>n.serialize()))}static parse(n,t){const r=n[0],i=Lg.definitions[r];if(!i)return t.error(`Unknown expression "${r}". If you wanted a literal array, use ["literal", [...]].`,0);const o=Array.isArray(i)?i[0]:i.type,s=Array.isArray(i)?[[i[1],i[2]]]:i.overloads,a=s.filter(([g])=>!Array.isArray(g)||g.length===n.length-1);let f=null;for(const[g,x]of a){f=new Xz(t.registry,t.path,null,t.scope);const k=[];let B=!1;for(let P=1;P<n.length;P++){const R=n[P],H=Array.isArray(g)?g[P-1]:g.type,W=f.parse(R,1+k.length,H);if(!W){B=!0;break}k.push(W)}if(!B){if(Array.isArray(g)&&g.length!==k.length){f.error(`Expected ${g.length} arguments, but found ${k.length} instead.`);continue}for(let P=0;P<k.length;P++){const R=Array.isArray(g)?g[P]:g.type,H=k[P];f.concat(P+1).checkSubtype(R,H.type)}if(f.errors.length===0)return new Lg(r,o,x,k)}}if(a.length===1)t.errors.push(...f.errors);else{const x=(a.length?a:s).map(([B])=>Yle(B)).join(" | "),k=[];for(let B=1;B<n.length;B++){const P=t.parse(n[B],1+k.length);if(!P)return null;k.push(ps(P.type))}t.error(`Expected arguments of type ${x}, but found (${k.join(", ")}) instead.`)}return null}static register(n,t){Lg.definitions=t;for(const r in t)n[r]=Lg}}function Yle(e){return Array.isArray(e)?`(${e.map(ps).join(", ")})`:`(${ps(e.type)}...)`}var Ny=Lg;class b5{constructor(n,t,r){this.type=y5,this.locale=r,this.caseSensitive=n,this.diacriticSensitive=t}static parse(n,t){if(n.length!==2)return t.error("Expected one argument.");const r=n[1];if(typeof r!="object"||Array.isArray(r))return t.error("Collator options argument must be an object.");const i=t.parse(r["case-sensitive"]===void 0?!1:r["case-sensitive"],1,Hi);if(!i)return null;const o=t.parse(r["diacritic-sensitive"]===void 0?!1:r["diacritic-sensitive"],1,Hi);if(!o)return null;let s=null;return r.locale&&(s=t.parse(r.locale,1,oo),!s)?null:new b5(i,o,s)}evaluate(n){return new b7(this.caseSensitive.evaluate(n),this.diacriticSensitive.evaluate(n),this.locale?this.locale.evaluate(n):null)}eachChild(n){n(this.caseSensitive),n(this.diacriticSensitive),this.locale&&n(this.locale)}outputDefined(){return!1}serialize(){const n={};return n["case-sensitive"]=this.caseSensitive.serialize(),n["diacritic-sensitive"]=this.diacriticSensitive.serialize(),this.locale&&(n.locale=this.locale.serialize()),["collator",n]}}const km=8192;function S7(e,n){e[0]=Math.min(e[0],n[0]),e[1]=Math.min(e[1],n[1]),e[2]=Math.max(e[2],n[0]),e[3]=Math.max(e[3],n[1])}function qle(e){return(180+e)/360}function Vle(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function R3(e,n){return!(e[0]<=n[0]||e[2]>=n[2]||e[1]<=n[1]||e[3]>=n[3])}function Hle(e,n){const t=qle(e[0]),r=Vle(e[1]),i=Math.pow(2,n.z);return[Math.round(t*i*km),Math.round(r*i*km)]}function Zle(e,n,t){const r=e[0]-n[0],i=e[1]-n[1],o=e[0]-t[0],s=e[1]-t[1];return r*s-o*i===0&&r*o<=0&&i*s<=0}function Xle(e,n,t){return n[1]>e[1]!=t[1]>e[1]&&e[0]<(t[0]-n[0])*(e[1]-n[1])/(t[1]-n[1])+n[0]}function E7(e,n){let t=!1;for(let r=0,i=n.length;r<i;r++){const o=n[r];for(let s=0,a=o.length;s<a-1;s++){if(Zle(e,o[s],o[s+1]))return!1;Xle(e,o[s],o[s+1])&&(t=!t)}}return t}function Jle(e,n){for(let t=0;t<n.length;t++)if(E7(e,n[t]))return!0;return!1}function eue(e,n){return e[0]*n[1]-e[1]*n[0]}function iT(e,n,t,r){const i=e[0]-t[0],o=e[1]-t[1],s=n[0]-t[0],a=n[1]-t[1],f=r[0]-t[0],g=r[1]-t[1],x=i*g-f*o,k=s*g-f*a;return x>0&&k<0||x<0&&k>0}function tue(e,n,t,r){const i=[n[0]-e[0],n[1]-e[1]],o=[r[0]-t[0],r[1]-t[1]];return eue(o,i)===0?!1:!!(iT(e,n,t,r)&&iT(t,r,e,n))}function nue(e,n,t){for(const r of t)for(let i=0;i<r.length-1;++i)if(tue(e,n,r[i],r[i+1]))return!0;return!1}function qz(e,n){for(let t=0;t<e.length;++t)if(!E7(e[t],n))return!1;for(let t=0;t<e.length-1;++t)if(nue(e[t],e[t+1],n))return!1;return!0}function rue(e,n){for(let t=0;t<n.length;t++)if(qz(e,n[t]))return!0;return!1}function O7(e,n,t){const r=[];for(let i=0;i<e.length;i++){const o=[];for(let s=0;s<e[i].length;s++){const a=Hle(e[i][s],t);S7(n,a),o.push(a)}r.push(o)}return r}function Vz(e,n,t){const r=[];for(let i=0;i<e.length;i++){const o=O7(e[i],n,t);r.push(o)}return r}function Hz(e,n,t,r){if(e[0]<t[0]||e[0]>t[2]){const i=r*.5;let o=e[0]-t[0]>i?-r:t[0]-e[0]>i?r:0;o===0&&(o=e[0]-t[2]>i?-r:t[2]-e[0]>i?r:0),e[0]+=o}S7(n,e)}function iue(e){e[0]=e[1]=1/0,e[2]=e[3]=-1/0}function oT(e,n,t,r){const i=Math.pow(2,r.z)*km,o=[r.x*km,r.y*km],s=[];if(!e)return s;for(const a of e)for(const f of a){const g=[f.x+o[0],f.y+o[1]];Hz(g,n,t,i),s.push(g)}return s}function aT(e,n,t,r){const i=Math.pow(2,r.z)*km,o=[r.x*km,r.y*km],s=[];if(!e)return s;for(const a of e){const f=[];for(const g of a){const x=[g.x+o[0],g.y+o[1]];S7(n,x),f.push(x)}s.push(f)}if(n[2]-n[0]<=i/2){iue(n);for(const a of s)for(const f of a)Hz(f,n,t,i)}return s}function oue(e,n){const t=[1/0,1/0,-1/0,-1/0],r=[1/0,1/0,-1/0,-1/0],i=e.canonicalID();if(!i)return!1;if(n.type==="Polygon"){const o=O7(n.coordinates,r,i),s=oT(e.geometry(),t,r,i);if(!R3(t,r))return!1;for(const a of s)if(!E7(a,o))return!1}if(n.type==="MultiPolygon"){const o=Vz(n.coordinates,r,i),s=oT(e.geometry(),t,r,i);if(!R3(t,r))return!1;for(const a of s)if(!Jle(a,o))return!1}return!0}function aue(e,n){const t=[1/0,1/0,-1/0,-1/0],r=[1/0,1/0,-1/0,-1/0],i=e.canonicalID();if(!i)return!1;if(n.type==="Polygon"){const o=O7(n.coordinates,r,i),s=aT(e.geometry(),t,r,i);if(!R3(t,r))return!1;for(const a of s)if(!qz(a,o))return!1}if(n.type==="MultiPolygon"){const o=Vz(n.coordinates,r,i),s=aT(e.geometry(),t,r,i);if(!R3(t,r))return!1;for(const a of s)if(!rue(a,o))return!1}return!0}class PC{constructor(n,t){this.type=Hi,this.geojson=n,this.geometries=t}static parse(n,t){if(n.length!==2)return t.error(`'within' expression requires exactly one argument, but found ${n.length-1} instead.`);if(D3(n[1])){const r=n[1];if(r.type==="FeatureCollection")for(let i=0;i<r.features.length;++i){const o=r.features[i].geometry.type;if(o==="Polygon"||o==="MultiPolygon")return new PC(r,r.features[i].geometry)}else if(r.type==="Feature"){const i=r.geometry.type;if(i==="Polygon"||i==="MultiPolygon")return new PC(r,r.geometry)}else if(r.type==="Polygon"||r.type==="MultiPolygon")return new PC(r,r)}return t.error("'within' expression requires valid geojson object that contains polygon geometry type.")}evaluate(n){if(n.geometry()!=null&&n.canonicalID()!=null){if(n.geometryType()==="Point")return oue(n,this.geometries);if(n.geometryType()==="LineString")return aue(n,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}serialize(){return["within",this.geojson]}}var B7=PC;function x5(e){if(e instanceof Ny){if(e.name==="get"&&e.args.length===1)return!1;if(e.name==="feature-state")return!1;if(e.name==="has"&&e.args.length===1)return!1;if(e.name==="properties"||e.name==="geometry-type"||e.name==="id")return!1;if(/^filter-/.test(e.name))return!1}if(e instanceof B7)return!1;let n=!0;return e.eachChild(t=>{n&&!x5(t)&&(n=!1)}),n}function k7(e){if(e instanceof Ny&&e.name==="feature-state")return!1;let n=!0;return e.eachChild(t=>{n&&!k7(t)&&(n=!1)}),n}function I7(e,n){if(e instanceof Ny&&n.indexOf(e.name)>=0)return!1;let t=!0;return e.eachChild(r=>{t&&!I7(r,n)&&(t=!1)}),t}class T7{constructor(n,t){this.type=t.type,this.name=n,this.boundExpression=t}static parse(n,t){if(n.length!==2||typeof n[1]!="string")return t.error("'var' expression requires exactly one string literal argument.");const r=n[1];return t.scope.has(r)?new T7(r,t.scope.get(r)):t.error(`Unknown variable "${r}". Make sure "${r}" has been bound in an enclosing "let" expression before using it.`,1)}evaluate(n){return this.boundExpression.evaluate(n)}eachChild(){}outputDefined(){return!1}serialize(){return["var",this.name]}}var Zz=T7;class K7{constructor(n,t=[],r,i=new Rle,o=[]){this.registry=n,this.path=t,this.key=t.map(s=>`[${s}]`).join(""),this.scope=i,this.errors=o,this.expectedType=r}parse(n,t,r,i,o={}){return t?this.concat(t,r,i)._parse(n,o):this._parse(n,o)}_parse(n,t){(n===null||typeof n=="string"||typeof n=="boolean"||typeof n=="number")&&(n=["literal",n]);function r(i,o,s){return s==="assert"?new mp(o,[i]):s==="coerce"?new Rg(o,[i]):i}if(Array.isArray(n)){if(n.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');const i=n[0];if(typeof i!="string")return this.error(`Expression name must be a string, but found ${typeof i} instead. If you wanted a literal array, use ["literal", [...]].`,0),null;const o=this.registry[i];if(o){let s=o.parse(n,this);if(!s)return null;if(this.expectedType){const a=this.expectedType,f=s.type;if((a.kind==="string"||a.kind==="number"||a.kind==="boolean"||a.kind==="object"||a.kind==="array")&&f.kind==="value")s=r(s,a,t.typeAnnotation||"assert");else if((a.kind==="color"||a.kind==="formatted"||a.kind==="resolvedImage")&&(f.kind==="value"||f.kind==="string"))s=r(s,a,t.typeAnnotation||"coerce");else if(this.checkSubtype(a,f))return null}if(!(s instanceof U3)&&s.type.kind!=="resolvedImage"&&dE(s)){const a=new Yz;try{s=new U3(s.type,s.evaluate(a))}catch(f){return this.error(f.message),null}}return s}return this.error(`Unknown expression "${i}". If you wanted a literal array, use ["literal", [...]].`,0)}else return typeof n>"u"?this.error("'undefined' value invalid. Use null instead."):typeof n=="object"?this.error('Bare objects invalid. Use ["literal", {...}] instead.'):this.error(`Expected an array, but found ${typeof n} instead.`)}concat(n,t,r){const i=typeof n=="number"?this.path.concat(n):this.path,o=r?this.scope.concat(r):this.scope;return new K7(this.registry,i,t||null,o,this.errors)}error(n,...t){const r=`${this.key}${t.map(i=>`[${i}]`).join("")}`;this.errors.push(new Zh(r,n))}checkSubtype(n,t){const r=C_(n,t);return r&&this.error(r),r}}var Xz=K7;function dE(e){if(e instanceof Zz)return dE(e.boundExpression);if(e instanceof Ny&&e.name==="error")return!1;if(e instanceof b5)return!1;if(e instanceof B7)return!1;const n=e instanceof Rg||e instanceof mp;let t=!0;return e.eachChild(r=>{n?t=t&&dE(r):t=t&&r instanceof U3}),t?x5(e)&&I7(e,["zoom","heatmap-density","line-progress","sky-radial-progress","accumulated","is-supported-script","pitch","distance-from-center"]):!1}function w5(e,n){const t=e.length-1;let r=0,i=t,o=0,s,a;for(;r<=i;)if(o=Math.floor((r+i)/2),s=e[o],a=e[o+1],s<=n){if(o===t||n<a)return o;r=o+1}else if(s>n)i=o-1;else throw new Cu("Input is not a number.");return 0}class P7{constructor(n,t,r){this.type=n,this.input=t,this.labels=[],this.outputs=[];for(const[i,o]of r)this.labels.push(i),this.outputs.push(o)}static parse(n,t){if(n.length-1<4)return t.error(`Expected at least 4 arguments, but found only ${n.length-1}.`);if((n.length-1)%2!==0)return t.error("Expected an even number of arguments.");const r=t.parse(n[1],1,Xn);if(!r)return null;const i=[];let o=null;t.expectedType&&t.expectedType.kind!=="value"&&(o=t.expectedType);for(let s=1;s<n.length;s+=2){const a=s===1?-1/0:n[s],f=n[s+1],g=s,x=s+1;if(typeof a!="number")return t.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',g);if(i.length&&i[i.length-1][0]>=a)return t.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',g);const k=t.parse(f,x,o);if(!k)return null;o=o||k.type,i.push([a,k])}return new P7(o,r,i)}evaluate(n){const t=this.labels,r=this.outputs;if(t.length===1)return r[0].evaluate(n);const i=this.input.evaluate(n);if(i<=t[0])return r[0].evaluate(n);const o=t.length;if(i>=t[o-1])return r[o-1].evaluate(n);const s=w5(t,i);return r[s].evaluate(n)}eachChild(n){n(this.input);for(const t of this.outputs)n(t)}outputDefined(){return this.outputs.every(n=>n.outputDefined())}serialize(){const n=["step",this.input.serialize()];for(let t=0;t<this.labels.length;t++)t>0&&n.push(this.labels[t]),n.push(this.outputs[t].serialize());return n}}var Jz=P7,sue=ej;function ej(e,n,t,r){this.cx=3*e,this.bx=3*(t-e)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*n,this.by=3*(r-n)-this.cy,this.ay=1-this.cy-this.by,this.p1x=e,this.p1y=n,this.p2x=t,this.p2y=r}ej.prototype={sampleCurveX:function(e){return((this.ax*e+this.bx)*e+this.cx)*e},sampleCurveY:function(e){return((this.ay*e+this.by)*e+this.cy)*e},sampleCurveDerivativeX:function(e){return(3*this.ax*e+2*this.bx)*e+this.cx},solveCurveX:function(e,n){if(n===void 0&&(n=1e-6),e<0)return 0;if(e>1)return 1;for(var t=e,r=0;r<8;r++){var i=this.sampleCurveX(t)-e;if(Math.abs(i)<n)return t;var o=this.sampleCurveDerivativeX(t);if(Math.abs(o)<1e-6)break;t=t-i/o}var s=0,a=1;for(t=e,r=0;r<20&&(i=this.sampleCurveX(t),!(Math.abs(i-e)<n));r++)e>i?s=t:a=t,t=(a-s)*.5+s;return t},solve:function(e,n){return this.sampleCurveY(this.solveCurveX(e,n))}};function Rc(e,n,t){return e*(1-t)+n*t}function lue(e,n,t){return new Gl(Rc(e.r,n.r,t),Rc(e.g,n.g,t),Rc(e.b,n.b,t),Rc(e.a,n.a,t))}function uue(e,n,t){return e.map((r,i)=>Rc(r,n[i],t))}var tj=Object.freeze({__proto__:null,number:Rc,color:lue,array:uue});const nj=.95047,rj=1,ij=1.08883,oj=4/29,oy=6/29,aj=3*oy*oy,Aue=oy*oy*oy,cue=Math.PI/180,due=180/Math.PI;function EM(e){return e>Aue?Math.pow(e,1/3):e/aj+oj}function OM(e){return e>oy?e*e*e:aj*(e-oj)}function BM(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function kM(e){return e/=255,e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function sj(e){const n=kM(e.r),t=kM(e.g),r=kM(e.b),i=EM((.4124564*n+.3575761*t+.1804375*r)/nj),o=EM((.2126729*n+.7151522*t+.072175*r)/rj),s=EM((.0193339*n+.119192*t+.9503041*r)/ij);return{l:116*o-16,a:500*(i-o),b:200*(o-s),alpha:e.a}}function lj(e){let n=(e.l+16)/116,t=isNaN(e.a)?n:n+e.a/500,r=isNaN(e.b)?n:n-e.b/200;return n=rj*OM(n),t=nj*OM(t),r=ij*OM(r),new Gl(BM(3.2404542*t-1.5371385*n-.4985314*r),BM(-.969266*t+1.8760108*n+.041556*r),BM(.0556434*t-.2040259*n+1.0572252*r),e.alpha)}function hue(e,n,t){return{l:Rc(e.l,n.l,t),a:Rc(e.a,n.a,t),b:Rc(e.b,n.b,t),alpha:Rc(e.alpha,n.alpha,t)}}function fue(e){const{l:n,a:t,b:r}=sj(e),i=Math.atan2(r,t)*due;return{h:i<0?i+360:i,c:Math.sqrt(t*t+r*r),l:n,alpha:e.a}}function pue(e){const n=e.h*cue,t=e.c,r=e.l;return lj({l:r,a:Math.cos(n)*t,b:Math.sin(n)*t,alpha:e.alpha})}function mue(e,n,t){const r=n-e;return e+t*(r>180||r<-180?r-360*Math.round(r/360):r)}function gue(e,n,t){return{h:mue(e.h,n.h,t),c:Rc(e.c,n.c,t),l:Rc(e.l,n.l,t),alpha:Rc(e.alpha,n.alpha,t)}}const uC={forward:sj,reverse:lj,interpolate:hue},AC={forward:fue,reverse:pue,interpolate:gue};var uj=Object.freeze({__proto__:null,lab:uC,hcl:AC});class L3{constructor(n,t,r,i,o){this.type=n,this.operator=t,this.interpolation=r,this.input=i,this.labels=[],this.outputs=[];for(const[s,a]of o)this.labels.push(s),this.outputs.push(a)}static interpolationFactor(n,t,r,i){let o=0;if(n.name==="exponential")o=IM(t,n.base,r,i);else if(n.name==="linear")o=IM(t,1,r,i);else if(n.name==="cubic-bezier"){const s=n.controlPoints;o=new sue(s[0],s[1],s[2],s[3]).solve(IM(t,1,r,i))}return o}static parse(n,t){let[r,i,o,...s]=n;if(!Array.isArray(i)||i.length===0)return t.error("Expected an interpolation type expression.",1);if(i[0]==="linear")i={name:"linear"};else if(i[0]==="exponential"){const g=i[1];if(typeof g!="number")return t.error("Exponential interpolation requires a numeric base.",1,1);i={name:"exponential",base:g}}else if(i[0]==="cubic-bezier"){const g=i.slice(1);if(g.length!==4||g.some(x=>typeof x!="number"||x<0||x>1))return t.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);i={name:"cubic-bezier",controlPoints:g}}else return t.error(`Unknown interpolation type ${String(i[0])}`,1,0);if(n.length-1<4)return t.error(`Expected at least 4 arguments, but found only ${n.length-1}.`);if((n.length-1)%2!==0)return t.error("Expected an even number of arguments.");if(o=t.parse(o,2,Xn),!o)return null;const a=[];let f=null;r==="interpolate-hcl"||r==="interpolate-lab"?f=wp:t.expectedType&&t.expectedType.kind!=="value"&&(f=t.expectedType);for(let g=0;g<s.length;g+=2){const x=s[g],k=s[g+1],B=g+3,P=g+4;if(typeof x!="number")return t.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',B);if(a.length&&a[a.length-1][0]>=x)return t.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',B);const R=t.parse(k,P,f);if(!R)return null;f=f||R.type,a.push([x,R])}return f.kind!=="number"&&f.kind!=="color"&&!(f.kind==="array"&&f.itemType.kind==="number"&&typeof f.N=="number")?t.error(`Type ${ps(f)} is not interpolatable.`):new L3(f,r,i,o,a)}evaluate(n){const t=this.labels,r=this.outputs;if(t.length===1)return r[0].evaluate(n);const i=this.input.evaluate(n);if(i<=t[0])return r[0].evaluate(n);const o=t.length;if(i>=t[o-1])return r[o-1].evaluate(n);const s=w5(t,i),a=t[s],f=t[s+1],g=L3.interpolationFactor(this.interpolation,i,a,f),x=r[s].evaluate(n),k=r[s+1].evaluate(n);return this.operator==="interpolate"?tj[this.type.kind.toLowerCase()](x,k,g):this.operator==="interpolate-hcl"?AC.reverse(AC.interpolate(AC.forward(x),AC.forward(k),g)):uC.reverse(uC.interpolate(uC.forward(x),uC.forward(k),g))}eachChild(n){n(this.input);for(const t of this.outputs)n(t)}outputDefined(){return this.outputs.every(n=>n.outputDefined())}serialize(){let n;this.interpolation.name==="linear"?n=["linear"]:this.interpolation.name==="exponential"?this.interpolation.base===1?n=["linear"]:n=["exponential",this.interpolation.base]:n=["cubic-bezier"].concat(this.interpolation.controlPoints);const t=[this.operator,n,this.input.serialize()];for(let r=0;r<this.labels.length;r++)t.push(this.labels[r],this.outputs[r].serialize());return t}}function IM(e,n,t,r){const i=r-t,o=e-t;return i===0?0:n===1?o/i:(Math.pow(n,o)-1)/(Math.pow(n,i)-1)}var Mp=L3;class z3{constructor(n,t){this.type=n,this.args=t}static parse(n,t){if(n.length<2)return t.error("Expectected at least one argument.");let r=null;const i=t.expectedType;i&&i.kind!=="value"&&(r=i);const o=[];for(const a of n.slice(1)){const f=t.parse(a,1+o.length,r,void 0,{typeAnnotation:"omit"});if(!f)return null;r=r||f.type,o.push(f)}return i&&o.some(a=>C_(i,a.type))?new z3(Xi,o):new z3(r,o)}evaluate(n){let t=null,r=0,i;for(const o of this.args){if(r++,t=o.evaluate(n),t&&t instanceof Op&&!t.available&&(i||(i=t),t=null,r===this.args.length))return i;if(t!==null)break}return t}eachChild(n){this.args.forEach(n)}outputDefined(){return this.args.every(n=>n.outputDefined())}serialize(){const n=["coalesce"];return this.eachChild(t=>{n.push(t.serialize())}),n}}var Aj=z3;class F7{constructor(n,t){this.type=t.type,this.bindings=[].concat(n),this.result=t}evaluate(n){return this.result.evaluate(n)}eachChild(n){for(const t of this.bindings)n(t[1]);n(this.result)}static parse(n,t){if(n.length<4)return t.error(`Expected at least 3 arguments, but found ${n.length-1} instead.`);const r=[];for(let o=1;o<n.length-1;o+=2){const s=n[o];if(typeof s!="string")return t.error(`Expected string, but found ${typeof s} instead.`,o);if(/[^a-zA-Z0-9_]/.test(s))return t.error("Variable names must contain only alphanumeric characters or '_'.",o);const a=t.parse(n[o+1],o+1);if(!a)return null;r.push([s,a])}const i=t.parse(n[n.length-1],n.length-1,t.expectedType,r);return i?new F7(r,i):null}outputDefined(){return this.result.outputDefined()}serialize(){const n=["let"];for(const[t,r]of this.bindings)n.push(t,r.serialize());return n.push(this.result.serialize()),n}}var cj=F7;class D7{constructor(n,t,r){this.type=n,this.index=t,this.input=r}static parse(n,t){if(n.length!==3)return t.error(`Expected 2 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Xn),i=t.parse(n[2],2,yd(t.expectedType||Xi));if(!r||!i)return null;const o=i.type;return new D7(o.itemType,r,i)}evaluate(n){const t=this.index.evaluate(n),r=this.input.evaluate(n);if(t<0)throw new Cu(`Array index out of bounds: ${t} < 0.`);if(t>=r.length)throw new Cu(`Array index out of bounds: ${t} > ${r.length-1}.`);if(t!==Math.floor(t))throw new Cu(`Array index must be an integer, but found ${t} instead.`);return r[t]}eachChild(n){n(this.index),n(this.input)}outputDefined(){return!1}serialize(){return["at",this.index.serialize(),this.input.serialize()]}}var yue=D7;class U7{constructor(n,t){this.type=Hi,this.needle=n,this.haystack=t}static parse(n,t){if(n.length!==3)return t.error(`Expected 2 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Xi),i=t.parse(n[2],2,Xi);return!r||!i?null:_7(r.type,[Hi,oo,Xn,g5,Xi])?new U7(r,i):t.error(`Expected first argument to be of type boolean, string, number or null, but found ${ps(r.type)} instead`)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(r==null)return!1;if(!__(t,["boolean","string","number","null"]))throw new Cu(`Expected first argument to be of type boolean, string, number or null, but found ${ps(Wl(t))} instead.`);if(!__(r,["string","array"]))throw new Cu(`Expected second argument to be of type array or string, but found ${ps(Wl(r))} instead.`);return r.indexOf(t)>=0}eachChild(n){n(this.needle),n(this.haystack)}outputDefined(){return!0}serialize(){return["in",this.needle.serialize(),this.haystack.serialize()]}}var vue=U7;class j3{constructor(n,t,r){this.type=Xn,this.needle=n,this.haystack=t,this.fromIndex=r}static parse(n,t){if(n.length<=2||n.length>=5)return t.error(`Expected 3 or 4 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Xi),i=t.parse(n[2],2,Xi);if(!r||!i)return null;if(!_7(r.type,[Hi,oo,Xn,g5,Xi]))return t.error(`Expected first argument to be of type boolean, string, number or null, but found ${ps(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,Xn);return o?new j3(r,i,o):null}else return new j3(r,i)}evaluate(n){const t=this.needle.evaluate(n),r=this.haystack.evaluate(n);if(!__(t,["boolean","string","number","null"]))throw new Cu(`Expected first argument to be of type boolean, string, number or null, but found ${ps(Wl(t))} instead.`);if(!__(r,["string","array"]))throw new Cu(`Expected second argument to be of type array or string, but found ${ps(Wl(r))} instead.`);if(this.fromIndex){const i=this.fromIndex.evaluate(n);return r.indexOf(t,i)}return r.indexOf(t)}eachChild(n){n(this.needle),n(this.haystack),this.fromIndex&&n(this.fromIndex)}outputDefined(){return!1}serialize(){if(this.fromIndex!=null&&this.fromIndex!==void 0){const n=this.fromIndex.serialize();return["index-of",this.needle.serialize(),this.haystack.serialize(),n]}return["index-of",this.needle.serialize(),this.haystack.serialize()]}}var Cue=j3;class R7{constructor(n,t,r,i,o,s){this.inputType=n,this.type=t,this.input=r,this.cases=i,this.outputs=o,this.otherwise=s}static parse(n,t){if(n.length<5)return t.error(`Expected at least 4 arguments, but found only ${n.length-1}.`);if(n.length%2!==1)return t.error("Expected an even number of arguments.");let r,i;t.expectedType&&t.expectedType.kind!=="value"&&(i=t.expectedType);const o={},s=[];for(let g=2;g<n.length-1;g+=2){let x=n[g];const k=n[g+1];Array.isArray(x)||(x=[x]);const B=t.concat(g);if(x.length===0)return B.error("Expected at least one branch label.");for(const R of x){if(typeof R!="number"&&typeof R!="string")return B.error("Branch labels must be numbers or strings.");if(typeof R=="number"&&Math.abs(R)>Number.MAX_SAFE_INTEGER)return B.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof R=="number"&&Math.floor(R)!==R)return B.error("Numeric branch labels must be integer values.");if(!r)r=Wl(R);else if(B.checkSubtype(r,Wl(R)))return null;if(typeof o[String(R)]<"u")return B.error("Branch labels must be unique.");o[String(R)]=s.length}const P=t.parse(k,g,i);if(!P)return null;i=i||P.type,s.push(P)}const a=t.parse(n[1],1,Xi);if(!a)return null;const f=t.parse(n[n.length-1],n.length-1,i);return!f||a.type.kind!=="value"&&t.concat(1).checkSubtype(r,a.type)?null:new R7(r,i,a,o,s,f)}evaluate(n){const t=this.input.evaluate(n);return(Wl(t)===this.inputType&&this.outputs[this.cases[t]]||this.otherwise).evaluate(n)}eachChild(n){n(this.input),this.outputs.forEach(n),n(this.otherwise)}outputDefined(){return this.outputs.every(n=>n.outputDefined())&&this.otherwise.outputDefined()}serialize(){const n=["match",this.input.serialize()],t=Object.keys(this.cases).sort(),r=[],i={};for(const s of t){const a=i[this.cases[s]];a===void 0?(i[this.cases[s]]=r.length,r.push([this.cases[s],[s]])):r[a][1].push(s)}const o=s=>this.inputType.kind==="number"?Number(s):s;for(const[s,a]of r)a.length===1?n.push(o(a[0])):n.push(a.map(o)),n.push(this.outputs[s].serialize());return n.push(this.otherwise.serialize()),n}}var _ue=R7;class L7{constructor(n,t,r){this.type=n,this.branches=t,this.otherwise=r}static parse(n,t){if(n.length<4)return t.error(`Expected at least 3 arguments, but found only ${n.length-1}.`);if(n.length%2!==0)return t.error("Expected an odd number of arguments.");let r;t.expectedType&&t.expectedType.kind!=="value"&&(r=t.expectedType);const i=[];for(let s=1;s<n.length-1;s+=2){const a=t.parse(n[s],s,Hi);if(!a)return null;const f=t.parse(n[s+1],s+1,r);if(!f)return null;i.push([a,f]),r=r||f.type}const o=t.parse(n[n.length-1],n.length-1,r);return o?new L7(r,i,o):null}evaluate(n){for(const[t,r]of this.branches)if(t.evaluate(n))return r.evaluate(n);return this.otherwise.evaluate(n)}eachChild(n){for(const[t,r]of this.branches)n(t),n(r);n(this.otherwise)}outputDefined(){return this.branches.every(([n,t])=>t.outputDefined())&&this.otherwise.outputDefined()}serialize(){const n=["case"];return this.eachChild(t=>{n.push(t.serialize())}),n}}var bue=L7;class W3{constructor(n,t,r,i){this.type=n,this.input=t,this.beginIndex=r,this.endIndex=i}static parse(n,t){if(n.length<=2||n.length>=5)return t.error(`Expected 3 or 4 arguments, but found ${n.length-1} instead.`);const r=t.parse(n[1],1,Xi),i=t.parse(n[2],2,Xn);if(!r||!i)return null;if(!_7(r.type,[yd(Xi),oo,Xi]))return t.error(`Expected first argument to be of type array or string, but found ${ps(r.type)} instead`);if(n.length===4){const o=t.parse(n[3],3,Xn);return o?new W3(r.type,r,i,o):null}else return new W3(r.type,r,i)}evaluate(n){const t=this.input.evaluate(n),r=this.beginIndex.evaluate(n);if(!__(t,["string","array"]))throw new Cu(`Expected first argument to be of type array or string, but found ${ps(Wl(t))} instead.`);if(this.endIndex){const i=this.endIndex.evaluate(n);return t.slice(r,i)}return t.slice(r)}eachChild(n){n(this.input),n(this.beginIndex),this.endIndex&&n(this.endIndex)}outputDefined(){return!1}serialize(){if(this.endIndex!=null&&this.endIndex!==void 0){const n=this.endIndex.serialize();return["slice",this.input.serialize(),this.beginIndex.serialize(),n]}return["slice",this.input.serialize(),this.beginIndex.serialize()]}}var xue=W3;function sT(e,n){return e==="=="||e==="!="?n.kind==="boolean"||n.kind==="string"||n.kind==="number"||n.kind==="null"||n.kind==="value":n.kind==="string"||n.kind==="number"||n.kind==="value"}function wue(e,n,t){return n===t}function Mue(e,n,t){return n!==t}function Sue(e,n,t){return n<t}function Eue(e,n,t){return n>t}function Oue(e,n,t){return n<=t}function Bue(e,n,t){return n>=t}function dj(e,n,t,r){return r.compare(n,t)===0}function kue(e,n,t,r){return!dj(e,n,t,r)}function Iue(e,n,t,r){return r.compare(n,t)<0}function Tue(e,n,t,r){return r.compare(n,t)>0}function Kue(e,n,t,r){return r.compare(n,t)<=0}function Pue(e,n,t,r){return r.compare(n,t)>=0}function Gy(e,n,t){const r=e!=="=="&&e!=="!=";return class hj{constructor(o,s,a){this.type=Hi,this.lhs=o,this.rhs=s,this.collator=a,this.hasUntypedArgument=o.type.kind==="value"||s.type.kind==="value"}static parse(o,s){if(o.length!==3&&o.length!==4)return s.error("Expected two or three arguments.");const a=o[0];let f=s.parse(o[1],1,Xi);if(!f)return null;if(!sT(a,f.type))return s.concat(1).error(`"${a}" comparisons are not supported for type '${ps(f.type)}'.`);let g=s.parse(o[2],2,Xi);if(!g)return null;if(!sT(a,g.type))return s.concat(2).error(`"${a}" comparisons are not supported for type '${ps(g.type)}'.`);if(f.type.kind!==g.type.kind&&f.type.kind!=="value"&&g.type.kind!=="value")return s.error(`Cannot compare types '${ps(f.type)}' and '${ps(g.type)}'.`);r&&(f.type.kind==="value"&&g.type.kind!=="value"?f=new mp(g.type,[f]):f.type.kind!=="value"&&g.type.kind==="value"&&(g=new mp(f.type,[g])));let x=null;if(o.length===4){if(f.type.kind!=="string"&&g.type.kind!=="string"&&f.type.kind!=="value"&&g.type.kind!=="value")return s.error("Cannot use collator to compare non-string types.");if(x=s.parse(o[3],3,y5),!x)return null}return new hj(f,g,x)}evaluate(o){const s=this.lhs.evaluate(o),a=this.rhs.evaluate(o);if(r&&this.hasUntypedArgument){const f=Wl(s),g=Wl(a);if(f.kind!==g.kind||!(f.kind==="string"||f.kind==="number"))throw new Cu(`Expected arguments for "${e}" to be (string, string) or (number, number), but found (${f.kind}, ${g.kind}) instead.`)}if(this.collator&&!r&&this.hasUntypedArgument){const f=Wl(s),g=Wl(a);if(f.kind!=="string"||g.kind!=="string")return n(o,s,a)}return this.collator?t(o,s,a,this.collator.evaluate(o)):n(o,s,a)}eachChild(o){o(this.lhs),o(this.rhs),this.collator&&o(this.collator)}outputDefined(){return!0}serialize(){const o=[e];return this.eachChild(s=>{o.push(s.serialize())}),o}}}const Fue=Gy("==",wue,dj),Due=Gy("!=",Mue,kue),Uue=Gy("<",Sue,Iue),Rue=Gy(">",Eue,Tue),Lue=Gy("<=",Oue,Kue),zue=Gy(">=",Bue,Pue);class z7{constructor(n,t,r,i,o,s){this.type=oo,this.number=n,this.locale=t,this.currency=r,this.unit=i,this.minFractionDigits=o,this.maxFractionDigits=s}static parse(n,t){if(n.length!==3)return t.error("Expected two arguments.");const r=t.parse(n[1],1,Xn);if(!r)return null;const i=n[2];if(typeof i!="object"||Array.isArray(i))return t.error("NumberFormat options argument must be an object.");let o=null;if(i.locale&&(o=t.parse(i.locale,1,oo),!o))return null;let s=null;if(i.currency&&(s=t.parse(i.currency,1,oo),!s))return null;let a=null;if(i.unit&&(a=t.parse(i.unit,1,oo),!a))return null;let f=null;if(i["min-fraction-digits"]&&(f=t.parse(i["min-fraction-digits"],1,Xn),!f))return null;let g=null;return i["max-fraction-digits"]&&(g=t.parse(i["max-fraction-digits"],1,Xn),!g)?null:new z7(r,o,s,a,f,g)}evaluate(n){return new Intl.NumberFormat(this.locale?this.locale.evaluate(n):[],{style:this.currency&&"currency"||this.unit&&"unit"||"decimal",currency:this.currency?this.currency.evaluate(n):void 0,unit:this.unit?this.unit.evaluate(n):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(n):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(n):void 0}).format(this.number.evaluate(n))}eachChild(n){n(this.number),this.locale&&n(this.locale),this.currency&&n(this.currency),this.unit&&n(this.unit),this.minFractionDigits&&n(this.minFractionDigits),this.maxFractionDigits&&n(this.maxFractionDigits)}outputDefined(){return!1}serialize(){const n={};return this.locale&&(n.locale=this.locale.serialize()),this.currency&&(n.currency=this.currency.serialize()),this.unit&&(n.unit=this.unit.serialize()),this.minFractionDigits&&(n["min-fraction-digits"]=this.minFractionDigits.serialize()),this.maxFractionDigits&&(n["max-fraction-digits"]=this.maxFractionDigits.serialize()),["number-format",this.number.serialize(),n]}}class j7{constructor(n){this.type=Xn,this.input=n}static parse(n,t){if(n.length!==2)return t.error(`Expected 1 argument, but found ${n.length-1} instead.`);const r=t.parse(n[1],1);return r?r.type.kind!=="array"&&r.type.kind!=="string"&&r.type.kind!=="value"?t.error(`Expected argument of type string or array, but found ${ps(r.type)} instead.`):new j7(r):null}evaluate(n){const t=this.input.evaluate(n);if(typeof t=="string")return t.length;if(Array.isArray(t))return t.length;throw new Cu(`Expected value to be of type string or array, but found ${ps(Wl(t))} instead.`)}eachChild(n){n(this.input)}outputDefined(){return!1}serialize(){const n=["length"];return this.eachChild(t=>{n.push(t.serialize())}),n}}var jue=j7;const fj={"==":Fue,"!=":Due,">":Rue,"<":Uue,">=":zue,"<=":Lue,array:mp,at:yue,boolean:mp,case:bue,coalesce:Aj,collator:b5,format:C5,image:_5,in:vue,"index-of":Cue,interpolate:Mp,"interpolate-hcl":Mp,"interpolate-lab":Mp,length:jue,let:cj,literal:U3,match:_ue,number:mp,"number-format":z7,object:mp,slice:xue,step:Jz,string:mp,"to-boolean":Rg,"to-color":Rg,"to-number":Rg,"to-string":Rg,var:Zz,within:B7};function lT(e,[n,t,r,i]){n=n.evaluate(e),t=t.evaluate(e),r=r.evaluate(e);const o=i?i.evaluate(e):1,s=$z(n,t,r,o);if(s)throw new Cu(s);return new Gl(n/255*o,t/255*o,r/255*o,o)}function uT(e,n){return e in n}function TM(e,n){const t=n[e];return typeof t>"u"?null:t}function Wue(e,n,t,r){for(;t<=r;){const i=t+r>>1;if(n[i]===e)return!0;n[i]>e?r=i-1:t=i+1}return!1}function v0(e){return{type:e}}Ny.register(fj,{error:[Lle,[oo],(e,[n])=>{throw new Cu(n.evaluate(e))}],typeof:[oo,[Xi],(e,[n])=>ps(Wl(n.evaluate(e)))],"to-rgba":[yd(Xn,4),[wp],(e,[n])=>n.evaluate(e).toArray()],rgb:[wp,[Xn,Xn,Xn],lT],rgba:[wp,[Xn,Xn,Xn,Xn],lT],has:{type:Hi,overloads:[[[oo],(e,[n])=>uT(n.evaluate(e),e.properties())],[[oo,iy],(e,[n,t])=>uT(n.evaluate(e),t.evaluate(e))]]},get:{type:Xi,overloads:[[[oo],(e,[n])=>TM(n.evaluate(e),e.properties())],[[oo,iy],(e,[n,t])=>TM(n.evaluate(e),t.evaluate(e))]]},"feature-state":[Xi,[oo],(e,[n])=>TM(n.evaluate(e),e.featureState||{})],properties:[iy,[],e=>e.properties()],"geometry-type":[oo,[],e=>e.geometryType()],id:[Xi,[],e=>e.id()],zoom:[Xn,[],e=>e.globals.zoom],pitch:[Xn,[],e=>e.globals.pitch||0],"distance-from-center":[Xn,[],e=>e.distanceFromCenter()],"heatmap-density":[Xn,[],e=>e.globals.heatmapDensity||0],"line-progress":[Xn,[],e=>e.globals.lineProgress||0],"sky-radial-progress":[Xn,[],e=>e.globals.skyRadialProgress||0],accumulated:[Xi,[],e=>e.globals.accumulated===void 0?null:e.globals.accumulated],"+":[Xn,v0(Xn),(e,n)=>{let t=0;for(const r of n)t+=r.evaluate(e);return t}],"*":[Xn,v0(Xn),(e,n)=>{let t=1;for(const r of n)t*=r.evaluate(e);return t}],"-":{type:Xn,overloads:[[[Xn,Xn],(e,[n,t])=>n.evaluate(e)-t.evaluate(e)],[[Xn],(e,[n])=>-n.evaluate(e)]]},"/":[Xn,[Xn,Xn],(e,[n,t])=>n.evaluate(e)/t.evaluate(e)],"%":[Xn,[Xn,Xn],(e,[n,t])=>n.evaluate(e)%t.evaluate(e)],ln2:[Xn,[],()=>Math.LN2],pi:[Xn,[],()=>Math.PI],e:[Xn,[],()=>Math.E],"^":[Xn,[Xn,Xn],(e,[n,t])=>Math.pow(n.evaluate(e),t.evaluate(e))],sqrt:[Xn,[Xn],(e,[n])=>Math.sqrt(n.evaluate(e))],log10:[Xn,[Xn],(e,[n])=>Math.log(n.evaluate(e))/Math.LN10],ln:[Xn,[Xn],(e,[n])=>Math.log(n.evaluate(e))],log2:[Xn,[Xn],(e,[n])=>Math.log(n.evaluate(e))/Math.LN2],sin:[Xn,[Xn],(e,[n])=>Math.sin(n.evaluate(e))],cos:[Xn,[Xn],(e,[n])=>Math.cos(n.evaluate(e))],tan:[Xn,[Xn],(e,[n])=>Math.tan(n.evaluate(e))],asin:[Xn,[Xn],(e,[n])=>Math.asin(n.evaluate(e))],acos:[Xn,[Xn],(e,[n])=>Math.acos(n.evaluate(e))],atan:[Xn,[Xn],(e,[n])=>Math.atan(n.evaluate(e))],min:[Xn,v0(Xn),(e,n)=>Math.min(...n.map(t=>t.evaluate(e)))],max:[Xn,v0(Xn),(e,n)=>Math.max(...n.map(t=>t.evaluate(e)))],abs:[Xn,[Xn],(e,[n])=>Math.abs(n.evaluate(e))],round:[Xn,[Xn],(e,[n])=>{const t=n.evaluate(e);return t<0?-Math.round(-t):Math.round(t)}],floor:[Xn,[Xn],(e,[n])=>Math.floor(n.evaluate(e))],ceil:[Xn,[Xn],(e,[n])=>Math.ceil(n.evaluate(e))],"filter-==":[Hi,[oo,Xi],(e,[n,t])=>e.properties()[n.value]===t.value],"filter-id-==":[Hi,[Xi],(e,[n])=>e.id()===n.value],"filter-type-==":[Hi,[oo],(e,[n])=>e.geometryType()===n.value],"filter-<":[Hi,[oo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<i}],"filter-id-<":[Hi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<r}],"filter->":[Hi,[oo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>i}],"filter-id->":[Hi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>r}],"filter-<=":[Hi,[oo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r<=i}],"filter-id-<=":[Hi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t<=r}],"filter->=":[Hi,[oo,Xi],(e,[n,t])=>{const r=e.properties()[n.value],i=t.value;return typeof r==typeof i&&r>=i}],"filter-id->=":[Hi,[Xi],(e,[n])=>{const t=e.id(),r=n.value;return typeof t==typeof r&&t>=r}],"filter-has":[Hi,[Xi],(e,[n])=>n.value in e.properties()],"filter-has-id":[Hi,[],e=>e.id()!==null&&e.id()!==void 0],"filter-type-in":[Hi,[yd(oo)],(e,[n])=>n.value.indexOf(e.geometryType())>=0],"filter-id-in":[Hi,[yd(Xi)],(e,[n])=>n.value.indexOf(e.id())>=0],"filter-in-small":[Hi,[oo,yd(Xi)],(e,[n,t])=>t.value.indexOf(e.properties()[n.value])>=0],"filter-in-large":[Hi,[oo,yd(Xi)],(e,[n,t])=>Wue(e.properties()[n.value],t.value,0,t.value.length-1)],all:{type:Hi,overloads:[[[Hi,Hi],(e,[n,t])=>n.evaluate(e)&&t.evaluate(e)],[v0(Hi),(e,n)=>{for(const t of n)if(!t.evaluate(e))return!1;return!0}]]},any:{type:Hi,overloads:[[[Hi,Hi],(e,[n,t])=>n.evaluate(e)||t.evaluate(e)],[v0(Hi),(e,n)=>{for(const t of n)if(t.evaluate(e))return!0;return!1}]]},"!":[Hi,[Hi],(e,[n])=>!n.evaluate(e)],"is-supported-script":[Hi,[oo],(e,[n])=>{const t=e.globals&&e.globals.isSupportedScript;return t?t(n.evaluate(e)):!0}],upcase:[oo,[oo],(e,[n])=>n.evaluate(e).toUpperCase()],downcase:[oo,[oo],(e,[n])=>n.evaluate(e).toLowerCase()],concat:[oo,v0(Xi),(e,n)=>n.map(t=>KC(t.evaluate(e))).join("")],"resolved-locale":[oo,[y5],(e,[n])=>n.evaluate(e).resolvedLocale()]});var pj=fj;function hE(e){return{result:"success",value:e}}function Mg(e){return{result:"error",value:e}}function Nue(e){return e["property-type"]==="data-driven"}function Gue(e){return!!e.expression&&e.expression.parameters.indexOf("zoom")>-1}function mj(e){return!!e.expression&&e.expression.interpolated}function W7(e){return e instanceof Number?"number":e instanceof String?"string":e instanceof Boolean?"boolean":Array.isArray(e)?"array":e===null?"null":typeof e}function N7(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Que(e){return e}function G7(e,n){const t=n.type==="color",r=e.stops&&typeof e.stops[0][0]=="object",i=r||e.property!==void 0,o=r||!i,s=e.type||(mj(n)?"exponential":"interval");if(t&&(e=Gz({},e),e.stops&&(e.stops=e.stops.map(x=>[x[0],Gl.parse(x[1])])),e.default?e.default=Gl.parse(e.default):e.default=Gl.parse(n.default)),e.colorSpace&&e.colorSpace!=="rgb"&&!uj[e.colorSpace])throw new Error(`Unknown color space: ${e.colorSpace}`);let a,f,g;if(s==="exponential")a=AT;else if(s==="interval")a=Yue;else if(s==="categorical"){a=$ue,f=Object.create(null);for(const x of e.stops)f[x[0]]=x[1];g=typeof e.stops[0][0]}else if(s==="identity")a=que;else throw new Error(`Unknown function type "${s}"`);if(r){const x={},k=[];for(let R=0;R<e.stops.length;R++){const H=e.stops[R],W=H[0].zoom;x[W]===void 0&&(x[W]={zoom:W,type:e.type,property:e.property,default:e.default,stops:[]},k.push(W)),x[W].stops.push([H[0].value,H[1]])}const B=[];for(const R of k)B.push([x[R].zoom,G7(x[R],n)]);const P={name:"linear"};return{kind:"composite",interpolationType:P,interpolationFactor:Mp.interpolationFactor.bind(void 0,P),zoomStops:B.map(R=>R[0]),evaluate({zoom:R},H){return AT({stops:B,base:e.base},n,R).evaluate(R,H)}}}else if(o){const x=s==="exponential"?{name:"exponential",base:e.base!==void 0?e.base:1}:null;return{kind:"camera",interpolationType:x,interpolationFactor:Mp.interpolationFactor.bind(void 0,x),zoomStops:e.stops.map(k=>k[0]),evaluate:({zoom:k})=>a(e,n,k,f,g)}}else return{kind:"source",evaluate(x,k){const B=k&&k.properties?k.properties[e.property]:void 0;return B===void 0?eb(e.default,n.default):a(e,n,B,f,g)}}}function eb(e,n,t){if(e!==void 0)return e;if(n!==void 0)return n;if(t!==void 0)return t}function $ue(e,n,t,r,i){const o=typeof t===i?r[t]:void 0;return eb(o,e.default,n.default)}function Yue(e,n,t){if(W7(t)!=="number")return eb(e.default,n.default);const r=e.stops.length;if(r===1||t<=e.stops[0][0])return e.stops[0][1];if(t>=e.stops[r-1][0])return e.stops[r-1][1];const i=w5(e.stops.map(o=>o[0]),t);return e.stops[i][1]}function AT(e,n,t){const r=e.base!==void 0?e.base:1;if(W7(t)!=="number")return eb(e.default,n.default);const i=e.stops.length;if(i===1||t<=e.stops[0][0])return e.stops[0][1];if(t>=e.stops[i-1][0])return e.stops[i-1][1];const o=w5(e.stops.map(x=>x[0]),t),s=Vue(t,r,e.stops[o][0],e.stops[o+1][0]),a=e.stops[o][1],f=e.stops[o+1][1];let g=tj[n.type]||Que;if(e.colorSpace&&e.colorSpace!=="rgb"){const x=uj[e.colorSpace];g=(k,B)=>x.reverse(x.interpolate(x.forward(k),x.forward(B),s))}return typeof a.evaluate=="function"?{evaluate(...x){const k=a.evaluate.apply(void 0,x),B=f.evaluate.apply(void 0,x);if(!(k===void 0||B===void 0))return g(k,B,s)}}:g(a,f,s)}function que(e,n,t){return n.type==="color"?t=Gl.parse(t):n.type==="formatted"?t=ch.fromString(t.toString()):n.type==="resolvedImage"?t=Op.fromString(t.toString()):W7(t)!==n.type&&(n.type!=="enum"||!n.values[t])&&(t=void 0),eb(t,e.default,n.default)}function Vue(e,n,t,r){const i=r-t,o=e-t;return i===0?0:n===1?o/i:(Math.pow(n,o)-1)/(Math.pow(n,i)-1)}class gj{constructor(n,t){this.expression=n,this._warningHistory={},this._evaluator=new Yz,this._defaultValue=t?Xue(t):null,this._enumValues=t&&t.type==="enum"?t.values:null}evaluateWithoutErrorHandling(n,t,r,i,o,s,a,f){return this._evaluator.globals=n,this._evaluator.feature=t,this._evaluator.featureState=r,this._evaluator.canonical=i||null,this._evaluator.availableImages=o||null,this._evaluator.formattedSection=s,this._evaluator.featureTileCoord=a||null,this._evaluator.featureDistanceData=f||null,this.expression.evaluate(this._evaluator)}evaluate(n,t,r,i,o,s,a,f){this._evaluator.globals=n,this._evaluator.feature=t||null,this._evaluator.featureState=r||null,this._evaluator.canonical=i||null,this._evaluator.availableImages=o||null,this._evaluator.formattedSection=s||null,this._evaluator.featureTileCoord=a||null,this._evaluator.featureDistanceData=f||null;try{const g=this.expression.evaluate(this._evaluator);if(g==null||typeof g=="number"&&g!==g)return this._defaultValue;if(this._enumValues&&!(g in this._enumValues))throw new Cu(`Expected value to be one of ${Object.keys(this._enumValues).map(x=>JSON.stringify(x)).join(", ")}, but found ${JSON.stringify(g)} instead.`);return g}catch(g){return this._warningHistory[g.message]||(this._warningHistory[g.message]=!0,typeof console<"u"&&console.warn(g.message)),this._defaultValue}}}function yj(e){return Array.isArray(e)&&e.length>0&&typeof e[0]=="string"&&e[0]in pj}function N3(e,n){const t=new Xz(pj,[],n?Zue(n):void 0),r=t.parse(e,void 0,void 0,void 0,n&&n.type==="string"?{typeAnnotation:"coerce"}:void 0);return r?hE(new gj(r,n)):Mg(t.errors)}class fE{constructor(n,t){this.kind=n,this._styleExpression=t,this.isStateDependent=n!=="constant"&&!k7(t.expression)}evaluateWithoutErrorHandling(n,t,r,i,o,s){return this._styleExpression.evaluateWithoutErrorHandling(n,t,r,i,o,s)}evaluate(n,t,r,i,o,s){return this._styleExpression.evaluate(n,t,r,i,o,s)}}class pE{constructor(n,t,r,i){this.kind=n,this.zoomStops=r,this._styleExpression=t,this.isStateDependent=n!=="camera"&&!k7(t.expression),this.interpolationType=i}evaluateWithoutErrorHandling(n,t,r,i,o,s){return this._styleExpression.evaluateWithoutErrorHandling(n,t,r,i,o,s)}evaluate(n,t,r,i,o,s){return this._styleExpression.evaluate(n,t,r,i,o,s)}interpolationFactor(n,t,r){return this.interpolationType?Mp.interpolationFactor(this.interpolationType,n,t,r):0}}function vj(e,n){if(e=N3(e,n),e.result==="error")return e;const t=e.value.expression,r=x5(t);if(!r&&!Nue(n))return Mg([new Zh("","data expressions not supported")]);const i=I7(t,["zoom","pitch","distance-from-center"]);if(!i&&!Gue(n))return Mg([new Zh("","zoom expressions not supported")]);const o=v2(t);if(!o&&!i)return Mg([new Zh("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')]);if(o instanceof Zh)return Mg([o]);if(o instanceof Mp&&!mj(n))return Mg([new Zh("",'"interpolate" expressions cannot be used with this property')]);if(!o)return hE(r?new fE("constant",e.value):new fE("source",e.value));const s=o instanceof Mp?o.interpolation:void 0;return hE(r?new pE("camera",e.value,o.labels,s):new pE("composite",e.value,o.labels,s))}class M5{constructor(n,t){this._parameters=n,this._specification=t,Gz(this,G7(this._parameters,this._specification))}static deserialize(n){return new M5(n._parameters,n._specification)}static serialize(n){return{_parameters:n._parameters,_specification:n._specification}}}function Hue(e,n){if(N7(e))return new M5(e,n);if(yj(e)){const t=vj(e,n);if(t.result==="error")throw new Error(t.value.map(r=>`${r.key}: ${r.message}`).join(", "));return t.value}else{let t=e;return typeof e=="string"&&n.type==="color"&&(t=Gl.parse(e)),{kind:"constant",evaluate:()=>t}}}function v2(e){let n=null;if(e instanceof cj)n=v2(e.result);else if(e instanceof Aj){for(const t of e.args)if(n=v2(t),n)break}else(e instanceof Jz||e instanceof Mp)&&e.input instanceof Ny&&e.input.name==="zoom"&&(n=e);return n instanceof Zh||e.eachChild(t=>{const r=v2(t);r instanceof Zh?n=r:!n&&r?n=new Zh("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):n&&r&&n!==r&&(n=new Zh("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),n}function Zue(e){const n={color:wp,string:oo,number:Xn,enum:oo,boolean:Hi,formatted:v5,resolvedImage:J_};return e.type==="array"?yd(n[e.value]||Xi,e.length):n[e.type]}function Xue(e){return e.type==="color"&&(N7(e.default)||Array.isArray(e.default))?new Gl(0,0,0,0):e.type==="color"?Gl.parse(e.default)||null:e.default===void 0?null:e.default}function b_(e){return typeof e=="object"?["literal",e]:e}function Jue(e,n){let t=e.stops;if(!t)return eAe(e,n);const r=t&&typeof t[0][0]=="object",i=r||e.property!==void 0,o=r||!i;return t=t.map(s=>!i&&n.tokens&&typeof s[1]=="string"?[s[0],iAe(s[1])]:[s[0],b_(s[1])]),r?tAe(e,n,t):o?rAe(e,n,t):mE(e,n,t)}function eAe(e,n){const t=["get",e.property];if(e.default===void 0)return n.type==="string"?["string",t]:t;if(n.type==="enum")return["match",t,Object.keys(n.values),t,e.default];{const r=[n.type==="color"?"to-color":n.type,t,b_(e.default)];return n.type==="array"&&r.splice(1,0,n.value,n.length||null),r}}function Q7(e){switch(e.colorSpace){case"hcl":return"interpolate-hcl";case"lab":return"interpolate-lab";default:return"interpolate"}}function tAe(e,n,t){const r={},i={},o=[];for(let a=0;a<t.length;a++){const f=t[a],g=f[0].zoom;r[g]===void 0&&(r[g]={zoom:g,type:e.type,property:e.property,default:e.default},i[g]=[],o.push(g)),i[g].push([f[0].value,f[1]])}if(Y7({},n)==="exponential"){const a=[Q7(e),["linear"],["zoom"]];for(const f of o){const g=mE(r[f],n,i[f]);ay(a,f,g,!1)}return a}else{const a=["step",["zoom"]];for(const f of o){const g=mE(r[f],n,i[f]);ay(a,f,g,!0)}return $7(a),a}}function nAe(e,n){if(e!==void 0)return e;if(n!==void 0)return n}function cT(e,n){const t=b_(nAe(e.default,n.default));return t===void 0&&n.type==="resolvedImage"?"":t}function mE(e,n,t){const r=Y7(e,n),i=["get",e.property];if(r==="categorical"&&typeof t[0][0]=="boolean"){const o=["case"];for(const s of t)o.push(["==",i,s[0]],s[1]);return o.push(cT(e,n)),o}else if(r==="categorical"){const o=["match",i];for(const s of t)ay(o,s[0],s[1],!1);return o.push(cT(e,n)),o}else if(r==="interval"){const o=["step",["number",i]];for(const s of t)ay(o,s[0],s[1],!0);return $7(o),e.default===void 0?o:["case",["==",["typeof",i],"number"],o,b_(e.default)]}else if(r==="exponential"){const o=e.base!==void 0?e.base:1,s=[Q7(e),o===1?["linear"]:["exponential",o],["number",i]];for(const a of t)ay(s,a[0],a[1],!1);return e.default===void 0?s:["case",["==",["typeof",i],"number"],s,b_(e.default)]}else throw new Error(`Unknown property function type ${r}`)}function rAe(e,n,t,r=["zoom"]){const i=Y7(e,n);let o,s=!1;if(i==="interval")o=["step",r],s=!0;else if(i==="exponential"){const a=e.base!==void 0?e.base:1;o=[Q7(e),a===1?["linear"]:["exponential",a],r]}else throw new Error(`Unknown zoom function type "${i}"`);for(const a of t)ay(o,a[0],a[1],s);return $7(o),o}function $7(e){e[0]==="step"&&e.length===3&&(e.push(0),e.push(e[3]))}function ay(e,n,t,r){e.length>3&&n===e[e.length-2]||(r&&e.length===2||e.push(n),e.push(t))}function Y7(e,n){return e.type?e.type:n.expression.interpolated?"exponential":"interval"}function iAe(e){const n=["concat"],t=/{([^{}]+)}/g;let r=0;for(let i=t.exec(e);i!==null;i=t.exec(e)){const o=e.slice(r,t.lastIndex-i[0].length);r=t.lastIndex,o.length>0&&n.push(o),n.push(["get",i[1]])}if(n.length===1)return e;if(r<e.length)n.push(e.slice(r));else if(n.length===2)return["to-string",n[1]];return n}function oAe(e){return e instanceof Number||e instanceof String||e instanceof Boolean?e.valueOf():e}function gE(e){if(Array.isArray(e))return e.map(gE);if(e instanceof Object&&!(e instanceof Number||e instanceof String||e instanceof Boolean)){const n={};for(const t in e)n[t]=gE(e[t]);return n}return oAe(e)}function q7(e){if(e===!0||e===!1)return!0;if(!Array.isArray(e)||e.length===0)return!1;switch(e[0]){case"has":return e.length>=2&&e[1]!=="$id"&&e[1]!=="$type";case"in":return e.length>=3&&(typeof e[1]!="string"||Array.isArray(e[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return e.length!==3||Array.isArray(e[1])||Array.isArray(e[2]);case"any":case"all":for(const n of e.slice(1))if(!q7(n)&&typeof n!="boolean")return!1;return!0;default:return!0}}function aAe(e,n="fill"){if(e==null)return{filter:()=>!0,needGeometry:!1,needFeature:!1};q7(e)||(e=G3(e));const t=e;let r=!0;try{r=sAe(t)}catch{console.warn(`Failed to extract static filter. Filter will continue working, but at higher memory usage and slower framerate.
|
||
This is most likely a bug, please report this via https://github.com/mapbox/mapbox-gl-js/issues/new?assignees=&labels=&template=Bug_report.md
|
||
and paste the contents of this message in the report.
|
||
Thank you!
|
||
Filter Expression:
|
||
${JSON.stringify(t,null,2)}
|
||
`)}const i=Nz[`filter_${n}`],o=N3(r,i);let s=null;if(o.result==="error")throw new Error(o.value.map(x=>`${x.key}: ${x.message}`).join(", "));s=(x,k,B)=>o.value.evaluate(x,k,{},B);let a=null,f=null;if(r!==t){const x=N3(t,i);if(x.result==="error")throw new Error(x.value.map(k=>`${k.key}: ${k.message}`).join(", "));a=(k,B,P,R,H)=>x.value.evaluate(k,B,{},P,void 0,void 0,R,H),f=!x5(x.value.expression)}s=s;const g=bj(r);return{filter:s,dynamicFilter:a||void 0,needGeometry:g,needFeature:!!f}}function sAe(e){if(!sy(e))return e;let n=gE(e);return _j(n),n=Cj(n),n}function Cj(e){if(!Array.isArray(e))return e;const n=AAe(e);return n===!0?n:n.map(t=>Cj(t))}function _j(e){let n=!1;const t=[];if(e[0]==="case"){for(let r=1;r<e.length-1;r+=2)n=n||sy(e[r]),t.push(e[r+1]);t.push(e[e.length-1])}else if(e[0]==="match"){n=n||sy(e[1]);for(let r=2;r<e.length-1;r+=2)t.push(e[r+1]);t.push(e[e.length-1])}else if(e[0]==="step"){n=n||sy(e[1]);for(let r=1;r<e.length-1;r+=2)t.push(e[r+1])}n&&(e.length=0,e.push("any",...t));for(let r=1;r<e.length;r++)_j(e[r])}function sy(e){if(!Array.isArray(e))return!1;if(lAe(e[0]))return!0;for(let n=1;n<e.length;n++){const t=e[n];if(sy(t))return!0}return!1}function lAe(e){return e==="pitch"||e==="distance-from-center"}const uAe=new Set(["in","==","!=",">",">=","<","<=","to-boolean"]);function AAe(e){if(uAe.has(e[0]))for(let n=1;n<e.length;n++){const t=e[n];if(sy(t))return!0}return e}function cAe(e,n){return e<n?-1:e>n?1:0}function bj(e){if(!Array.isArray(e))return!1;if(e[0]==="within")return!0;for(let n=1;n<e.length;n++)if(bj(e[n]))return!0;return!1}function G3(e){if(!e)return!0;const n=e[0];return e.length<=1?n!=="any":n==="=="?KM(e[1],e[2],"=="):n==="!="?Tx(KM(e[1],e[2],"==")):n==="<"||n===">"||n==="<="||n===">="?KM(e[1],e[2],n):n==="any"?dAe(e.slice(1)):n==="all"?["all"].concat(e.slice(1).map(G3)):n==="none"?["all"].concat(e.slice(1).map(G3).map(Tx)):n==="in"?dT(e[1],e.slice(2)):n==="!in"?Tx(dT(e[1],e.slice(2))):n==="has"?hT(e[1]):n==="!has"?Tx(hT(e[1])):n==="within"?e:!0}function KM(e,n,t){switch(e){case"$type":return[`filter-type-${t}`,n];case"$id":return[`filter-id-${t}`,n];default:return[`filter-${t}`,e,n]}}function dAe(e){return["any"].concat(e.map(G3))}function dT(e,n){if(n.length===0)return!1;switch(e){case"$type":return["filter-type-in",["literal",n]];case"$id":return["filter-id-in",["literal",n]];default:return n.length>200&&!n.some(t=>typeof t!=typeof n[0])?["filter-in-large",e,["literal",n.sort(cAe)]]:["filter-in-small",e,["literal",n]]}}function hT(e){switch(e){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",e]}}function Tx(e){return["!",e]}var hAe=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function fAe(e,n){const t={};for(const r in e)r!=="ref"&&(t[r]=e[r]);return hAe.forEach(r=>{r in n&&(t[r]=n[r])}),t}function pAe(e){e=e.slice();const n=Object.create(null);for(let t=0;t<e.length;t++)n[e[t].id]=e[t];for(let t=0;t<e.length;t++)"ref"in e[t]&&(e[t]=fAe(e[t],n[e[t].ref]));return e}function mAe(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var gAe={};(function(e){var n=function(){var t=function(W,$,q,oe){for(q=q||{},oe=W.length;oe--;q[W[oe]]=$);return q},r=[1,12],i=[1,13],o=[1,9],s=[1,10],a=[1,11],f=[1,14],g=[1,15],x=[14,18,22,24],k=[18,22],B=[22,24],P={trace:function(){},yy:{},symbols_:{error:2,JSONString:3,STRING:4,JSONNumber:5,NUMBER:6,JSONNullLiteral:7,NULL:8,JSONBooleanLiteral:9,TRUE:10,FALSE:11,JSONText:12,JSONValue:13,EOF:14,JSONObject:15,JSONArray:16,"{":17,"}":18,JSONMemberList:19,JSONMember:20,":":21,",":22,"[":23,"]":24,JSONElementList:25,$accept:0,$end:1},terminals_:{2:"error",4:"STRING",6:"NUMBER",8:"NULL",10:"TRUE",11:"FALSE",14:"EOF",17:"{",18:"}",21:":",22:",",23:"[",24:"]"},productions_:[0,[3,1],[5,1],[7,1],[9,1],[9,1],[12,2],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[15,2],[15,3],[20,3],[19,1],[19,3],[16,2],[16,3],[25,1],[25,3]],performAction:function($,q,oe,ne,ce,ae,ue){var ye=ae.length-1;switch(ce){case 1:this.$=new String($.replace(/\\(\\|")/g,"$1").replace(/\\n/g,`
|
||
`).replace(/\\r/g,"\r").replace(/\\t/g," ").replace(/\\v/g,"\v").replace(/\\f/g,"\f").replace(/\\b/g,"\b")),this.$.__line__=this._$.first_line;break;case 2:this.$=new Number($),this.$.__line__=this._$.first_line;break;case 3:this.$=null;break;case 4:this.$=new Boolean(!0),this.$.__line__=this._$.first_line;break;case 5:this.$=new Boolean(!1),this.$.__line__=this._$.first_line;break;case 6:return this.$=ae[ye-1];case 13:this.$={},Object.defineProperty(this.$,"__line__",{value:this._$.first_line,enumerable:!1});break;case 14:case 19:this.$=ae[ye-1],Object.defineProperty(this.$,"__line__",{value:this._$.first_line,enumerable:!1});break;case 15:this.$=[ae[ye-2],ae[ye]];break;case 16:this.$={},this.$[ae[ye][0]]=ae[ye][1];break;case 17:this.$=ae[ye-2],ae[ye-2][ae[ye][0]]=ae[ye][1];break;case 18:this.$=[],Object.defineProperty(this.$,"__line__",{value:this._$.first_line,enumerable:!1});break;case 20:this.$=[ae[ye]];break;case 21:this.$=ae[ye-2],ae[ye-2].push(ae[ye]);break}},table:[{3:5,4:r,5:6,6:i,7:3,8:o,9:4,10:s,11:a,12:1,13:2,15:7,16:8,17:f,23:g},{1:[3]},{14:[1,16]},t(x,[2,7]),t(x,[2,8]),t(x,[2,9]),t(x,[2,10]),t(x,[2,11]),t(x,[2,12]),t(x,[2,3]),t(x,[2,4]),t(x,[2,5]),t([14,18,21,22,24],[2,1]),t(x,[2,2]),{3:20,4:r,18:[1,17],19:18,20:19},{3:5,4:r,5:6,6:i,7:3,8:o,9:4,10:s,11:a,13:23,15:7,16:8,17:f,23:g,24:[1,21],25:22},{1:[2,6]},t(x,[2,13]),{18:[1,24],22:[1,25]},t(k,[2,16]),{21:[1,26]},t(x,[2,18]),{22:[1,28],24:[1,27]},t(B,[2,20]),t(x,[2,14]),{3:20,4:r,20:29},{3:5,4:r,5:6,6:i,7:3,8:o,9:4,10:s,11:a,13:30,15:7,16:8,17:f,23:g},t(x,[2,19]),{3:5,4:r,5:6,6:i,7:3,8:o,9:4,10:s,11:a,13:31,15:7,16:8,17:f,23:g},t(k,[2,17]),t(k,[2,15]),t(B,[2,21])],defaultActions:{16:[2,6]},parseError:function($,q){if(q.recoverable)this.trace($);else throw new Error($)},parse:function($){var q=this,oe=[0],ne=[null],ce=[],ae=this.table,ue="",ye=0,Re=0,Ne=2,rt=1,ct=ce.slice.call(arguments,1),Fe=Object.create(this.lexer),He={yy:{}};for(var Ce in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Ce)&&(He.yy[Ce]=this.yy[Ce]);Fe.setInput($,He.yy),He.yy.lexer=Fe,He.yy.parser=this,typeof Fe.yylloc>"u"&&(Fe.yylloc={});var jt=Fe.yylloc;ce.push(jt);var Ft=Fe.options&&Fe.options.ranges;typeof He.yy.parseError=="function"?this.parseError=He.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Jt(){var de;return de=Fe.lex()||rt,typeof de!="number"&&(de=q.symbols_[de]||de),de}for(var Nt,Ve,nt,Je,Vt={},pt,dt,kt,Dt;;){if(Ve=oe[oe.length-1],this.defaultActions[Ve]?nt=this.defaultActions[Ve]:((Nt===null||typeof Nt>"u")&&(Nt=Jt()),nt=ae[Ve]&&ae[Ve][Nt]),typeof nt>"u"||!nt.length||!nt[0]){var Se="";Dt=[];for(pt in ae[Ve])this.terminals_[pt]&&pt>Ne&&Dt.push("'"+this.terminals_[pt]+"'");Fe.showPosition?Se="Parse error on line "+(ye+1)+`:
|
||
`+Fe.showPosition()+`
|
||
Expecting `+Dt.join(", ")+", got '"+(this.terminals_[Nt]||Nt)+"'":Se="Parse error on line "+(ye+1)+": Unexpected "+(Nt==rt?"end of input":"'"+(this.terminals_[Nt]||Nt)+"'"),this.parseError(Se,{text:Fe.match,token:this.terminals_[Nt]||Nt,line:Fe.yylineno,loc:jt,expected:Dt})}if(nt[0]instanceof Array&&nt.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Ve+", token: "+Nt);switch(nt[0]){case 1:oe.push(Nt),ne.push(Fe.yytext),ce.push(Fe.yylloc),oe.push(nt[1]),Nt=null,Re=Fe.yyleng,ue=Fe.yytext,ye=Fe.yylineno,jt=Fe.yylloc;break;case 2:if(dt=this.productions_[nt[1]][1],Vt.$=ne[ne.length-dt],Vt._$={first_line:ce[ce.length-(dt||1)].first_line,last_line:ce[ce.length-1].last_line,first_column:ce[ce.length-(dt||1)].first_column,last_column:ce[ce.length-1].last_column},Ft&&(Vt._$.range=[ce[ce.length-(dt||1)].range[0],ce[ce.length-1].range[1]]),Je=this.performAction.apply(Vt,[ue,Re,ye,He.yy,nt[1],ne,ce].concat(ct)),typeof Je<"u")return Je;dt&&(oe=oe.slice(0,-1*dt*2),ne=ne.slice(0,-1*dt),ce=ce.slice(0,-1*dt)),oe.push(this.productions_[nt[1]][0]),ne.push(Vt.$),ce.push(Vt._$),kt=ae[oe[oe.length-2]][oe[oe.length-1]],oe.push(kt);break;case 3:return!0}}return!0}},R=function(){var W={EOF:1,parseError:function(q,oe){if(this.yy.parser)this.yy.parser.parseError(q,oe);else throw new Error(q)},setInput:function($,q){return this.yy=q||this.yy||{},this._input=$,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var $=this._input[0];this.yytext+=$,this.yyleng++,this.offset++,this.match+=$,this.matched+=$;var q=$.match(/(?:\r\n?|\n).*/g);return q?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),$},unput:function($){var q=$.length,oe=$.split(/(?:\r\n?|\n)/g);this._input=$+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-q),this.offset-=q;var ne=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),oe.length-1&&(this.yylineno-=oe.length-1);var ce=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:oe?(oe.length===ne.length?this.yylloc.first_column:0)+ne[ne.length-oe.length].length-oe[0].length:this.yylloc.first_column-q},this.options.ranges&&(this.yylloc.range=[ce[0],ce[0]+this.yyleng-q]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
||
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function($){this.unput(this.match.slice($))},pastInput:function(){var $=this.matched.substr(0,this.matched.length-this.match.length);return($.length>20?"...":"")+$.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var $=this.match;return $.length<20&&($+=this._input.substr(0,20-$.length)),($.substr(0,20)+($.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var $=this.pastInput(),q=new Array($.length+1).join("-");return $+this.upcomingInput()+`
|
||
`+q+"^"},test_match:function($,q){var oe,ne,ce;if(this.options.backtrack_lexer&&(ce={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(ce.yylloc.range=this.yylloc.range.slice(0))),ne=$[0].match(/(?:\r\n?|\n).*/g),ne&&(this.yylineno+=ne.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:ne?ne[ne.length-1].length-ne[ne.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+$[0].length},this.yytext+=$[0],this.match+=$[0],this.matches=$,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice($[0].length),this.matched+=$[0],oe=this.performAction.call(this,this.yy,this,q,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),oe)return oe;if(this._backtrack){for(var ae in ce)this[ae]=ce[ae];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var $,q,oe,ne;this._more||(this.yytext="",this.match="");for(var ce=this._currentRules(),ae=0;ae<ce.length;ae++)if(oe=this._input.match(this.rules[ce[ae]]),oe&&(!q||oe[0].length>q[0].length)){if(q=oe,ne=ae,this.options.backtrack_lexer){if($=this.test_match(oe,ce[ae]),$!==!1)return $;if(this._backtrack){q=!1;continue}else return!1}else if(!this.options.flex)break}return q?($=this.test_match(q,ce[ne]),$!==!1?$:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
||
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var q=this.next();return q||this.lex()},begin:function(q){this.conditionStack.push(q)},popState:function(){var q=this.conditionStack.length-1;return q>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(q){return q=this.conditionStack.length-1-Math.abs(q||0),q>=0?this.conditionStack[q]:"INITIAL"},pushState:function(q){this.begin(q)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(q,oe,ne,ce){switch(ne){case 0:break;case 1:return 6;case 2:return oe.yytext=oe.yytext.substr(1,oe.yyleng-2),4;case 3:return 17;case 4:return 18;case 5:return 23;case 6:return 24;case 7:return 22;case 8:return 21;case 9:return 10;case 10:return 11;case 11:return 8;case 12:return 14;case 13:return"INVALID"}},rules:[/^(?:\s+)/,/^(?:(-?([0-9]|[1-9][0-9]+))(\.[0-9]+)?([eE][-+]?[0-9]+)?\b)/,/^(?:"(?:\\[\\"bfnrt/]|\\u[a-fA-F0-9]{4}|[^\\\0-\x09\x0a-\x1f"])*")/,/^(?:\{)/,/^(?:\})/,/^(?:\[)/,/^(?:\])/,/^(?:,)/,/^(?::)/,/^(?:true\b)/,/^(?:false\b)/,/^(?:null\b)/,/^(?:$)/,/^(?:.)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}}};return W}();P.lexer=R;function H(){this.yy={}}return H.prototype=P,P.Parser=H,new H}();typeof mAe<"u"&&(e.parser=n,e.Parser=n.Parser,e.parse=function(){return n.parse.apply(n,arguments)})})(gAe);const xj={StyleExpression:gj,isExpression:yj,isExpressionFilter:q7,createExpression:N3,createPropertyExpression:vj,normalizePropertyExpression:Hue,ZoomConstantExpression:fE,ZoomDependentExpression:pE,StylePropertyFunction:M5},wj={convertFunction:Jue,createFunction:G7,isFunction:N7};var Mj=typeof Object.assign=="function"?Object.assign:function(e,n){if(e==null)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),r=1,i=arguments.length;r<i;++r){var o=arguments[r];if(o!=null)for(var s in o)o.hasOwnProperty(s)&&(t[s]=o[s])}return t};function PM(e){return e*Math.PI/180}var Sy=function(){for(var e=[],n=78271.51696402048;e.length<=24;n/=2)e.push(n);return e}();function Sj(e,n){if(typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof OffscreenCanvas<"u")return new OffscreenCanvas(e,n);var t=document.createElement("canvas");return t.width=e,t.height=n,t}function yAe(e,n){for(var t=0,r=n.length;t<r;++t){var i=n[t];if(i<e&&t+1<r){var o=n[t]/n[t+1];return t+Math.log(n[t]/e)/Math.log(o)}}return r-1}var vAe=Array(256).join(" ");function yE(e,n){if(n>=.05){for(var t="",r=e.split(`
|
||
`),i=vAe.slice(0,Math.round(n/.1)),o=0,s=r.length;o<s;++o)o>0&&(t+=`
|
||
`),t+=r[o].split("").join(i);return t}return e}var FM;function Ej(){return FM||(FM=Sj(1,1).getContext("2d")),FM}function C0(e,n){return Ej().measureText(e).width+(e.length-1)*n}var vE={};J6&&wo(J6,ki.CLEAR,function(){vE={}});function CE(e,n,t,r){if(e.indexOf(`
|
||
`)!==-1){for(var i=e.split(`
|
||
`),o=[],s=0,a=i.length;s<a;++s)o.push(CE(i[s],n,t,r));return o.join(`
|
||
`)}var f=t+","+n+","+e+","+r,g=vE[f];if(!g){var x=e.split(" ");if(x.length>1){var k=Ej();k.font=n;for(var B=k.measureText("M").width,P=B*t,R="",o=[],s=0,a=x.length;s<a;++s){var H=x[s],W=R+(R?" ":"")+H;C0(W,r)<=P?R=W:(R&&o.push(R),R=H)}R&&o.push(R);for(var s=0,a=o.length;s<a&&a>1;++s){var $=o[s];if(C0($,r)<P*.35){var q=s>0?C0(o[s-1],r):1/0,oe=s<a-1?C0(o[s+1],r):1/0;o.splice(s,1),a-=1,q<oe?(o[s-1]+=" "+$,s-=1):o[s]=$+" "+o[s]}}for(var s=0,a=o.length-1;s<a;++s){var ne=o[s],ce=o[s+1];if(C0(ne,r)>P*.7&&C0(ce,r)<P*.6){var ae=ne.split(" "),ue=ae.pop();C0(ue,r)<P*.2&&(o[s]=ae.join(" "),o[s+1]=ue+" "+ce),a-=1}}g=o.join(`
|
||
`)}else g=e;g=yE(g,r),vE[f]=g}return g}var CAe=wj.isFunction,_Ae=wj.convertFunction,bAe=xj.isExpression,xAe=xj.createPropertyExpression,wAe={Point:1,MultiPoint:1,LineString:2,MultiLineString:2,Polygon:3,MultiPolygon:3},MAe={center:[.5,.5],left:[0,.5],right:[1,.5],top:[.5,0],bottom:[.5,1],"top-left":[0,0],"top-right":[1,0],"bottom-left":[0,1],"bottom-right":[1,1]},SAe=function(e,n){var t=xAe(e,n);if(t.result==="error")throw new Error(t.value.map(function(r){return"".concat(r.key,": ").concat(r.message)}).join(", "));return t.value},_E={},Q3={zoom:0},Kx,DM;function bi(e,n,t,r,i,o){var s=e.id;o||(o={},console.warn("No functionCache provided to getValue()")),o[s]||(o[s]={});var a=o[s];if(!a[t]){var f=(e[n]||_E)[t],g=Nz["".concat(n,"_").concat(e.type)][t];f===void 0&&(f=g.default);var x=bAe(f);if(!x&&CAe(f)&&(f=_Ae(f,g),x=!0),x){var k=SAe(f,g);a[t]=k.evaluate.bind(k)}else g.type=="color"&&(f=Gl.parse(f)),a[t]=function(){return f}}return Q3.zoom=r,a[t](Q3,i)}function EAe(e,n,t,r,i){return i||console.warn("No filterCache provided to evaluateFilter()"),e in i||(i[e]=aAe(n).filter),Q3.zoom=r,i[e](Q3,t)}function Xp(e,n){if(e){if(e.a===0||n===0)return;var t=e.a;return n=n===void 0?1:n,t===0?"transparent":"rgba("+Math.round(e.r*255/t)+","+Math.round(e.g*255/t)+","+Math.round(e.b*255/t)+","+t*n+")"}return e}var OAe=/^([^]*)\{(.*)\}([^]*)$/;function UM(e,n){var t;do if(t=e.match(OAe),t){var r=n[t[2]]||"";e=t[1]+r+t[3]}while(t);return e}function BAe(e,n,t,r,i,o,s){if(r===void 0&&(r=Sy),typeof n=="string"&&(n=JSON.parse(n)),n.version!=8)throw new Error("glStyle version 8 required.");var a,f;if(o){if(typeof Image<"u"){var g=new Image;g.crossOrigin="anonymous",g.onload=function(){a=g,f=[g.width,g.height],e.changed(),g.onload=null},g.src=o}else if(typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope){var x=self;x.postMessage({action:"loadImage",src:o}),x.addEventListener("message",function(jt){jt.data.action==="imageLoaded"&&jt.data.src===o&&(a=jt.data.image,f=[a.width,a.height])})}}for(var k=pAe(n.layers),B={},P=[],R={},H={},W={},$={},q,oe=0,ne=k.length;oe<ne;++oe){var ce=k[oe],ae=ce.id;if(typeof t=="string"&&ce.source==t||t.indexOf(ae)!==-1){var ue=ce["source-layer"];if(!q){q=ce.source;var ye=n.sources[q];if(!ye)throw new Error('Source "'.concat(q,'" is not defined'));var Re=ye.type;if(Re!=="vector"&&Re!=="geojson")throw new Error('Source "'.concat(q,'" is not of type "vector" or "geojson", but "').concat(Re,'"'))}var Ne=B[ue];Ne||(Ne=[],B[ue]=Ne),Ne.push({layer:ce,index:oe}),P.push(ae)}}var rt=new lC,ct=new Ug,Fe=[],He=function(Ce,jt){var Ft=Ce.getProperties(),Jt=B[Ft.layer];if(Jt){var Nt=r.indexOf(jt);Nt==-1&&(Nt=yAe(jt,r));for(var Ve=wAe[Ce.getGeometry().getType()],nt={properties:Ft,type:Ve},Je=-1,Vt=function(kt,Dt){var Se=Jt[kt],de=Se.layer,xe=de.id,Pe=de.layout||_E,Ze=de.paint||_E;if(Pe.visibility==="none"||"minzoom"in de&&Nt<de.minzoom||"maxzoom"in de&&Nt>=de.maxzoom)return"continue";var Xe=de.filter;if(!Xe||EAe(xe,Xe,nt,Nt,$)){var wt=void 0,Kt=void 0,Pt=void 0,zn=void 0,mt=void 0,pn=void 0,ir=Se.index;if(Ve==3&&(de.type=="fill"||de.type=="fill-extrusion"))if(Kt=bi(de,"paint",de.type+"-opacity",Nt,nt,W),de.type+"-pattern"in Ze){var Sn=bi(de,"paint",de.type+"-pattern",Nt,nt,W);if(Sn){var nr=typeof Sn=="string"?UM(Sn,Ft):Sn.toString();if(a&&i&&i[nr]){++Je,pn=Fe[Je],(!pn||!pn.getFill()||pn.getStroke()||pn.getText())&&(pn=new E0({fill:new Ug}),Fe[Je]=pn),Pt=pn.getFill(),pn.setZIndex(ir);var Mr=nr+"."+Kt,Qr=H[Mr];if(!Qr){var _r=i[nr],vi=Sj(_r.width,_r.height),we=vi.getContext("2d");we.globalAlpha=Kt,we.drawImage(a,_r.x,_r.y,_r.width,_r.height,0,0,_r.width,_r.height),Qr=we.createPattern(vi,"repeat"),H[Mr]=Qr}Pt.setColor(Qr)}}}else wt=Xp(bi(de,"paint",de.type+"-color",Nt,nt,W),Kt),de.type+"-outline-color"in Ze&&(mt=Xp(bi(de,"paint",de.type+"-outline-color",Nt,nt,W),Kt)),mt||(mt=wt),(wt||mt)&&(++Je,pn=Fe[Je],(!pn||wt&&!pn.getFill()||!wt&&pn.getFill()||mt&&!pn.getStroke()||!mt&&pn.getStroke()||pn.getText())&&(pn=new E0({fill:wt?new Ug:void 0,stroke:mt?new lC:void 0}),Fe[Je]=pn),wt&&(Pt=pn.getFill(),Pt.setColor(wt)),mt&&(zn=pn.getStroke(),zn.setColor(mt),zn.setWidth(.5)),pn.setZIndex(ir));if(Ve!=1&&de.type=="line"){wt=!("line-pattern"in Ze)&&"line-color"in Ze?Xp(bi(de,"paint","line-color",Nt,nt,W),bi(de,"paint","line-opacity",Nt,nt,W)):void 0;var V=bi(de,"paint","line-width",Nt,nt,W);wt&&V>0&&(++Je,pn=Fe[Je],(!pn||!pn.getStroke()||pn.getFill()||pn.getText())&&(pn=new E0({stroke:new lC}),Fe[Je]=pn),zn=pn.getStroke(),zn.setLineCap(bi(de,"layout","line-cap",Nt,nt,W)),zn.setLineJoin(bi(de,"layout","line-join",Nt,nt,W)),zn.setMiterLimit(bi(de,"layout","line-miter-limit",Nt,nt,W)),zn.setColor(wt),zn.setWidth(V),zn.setLineDash(Ze["line-dasharray"]?bi(de,"paint","line-dasharray",Nt,nt,W).map(function(Lr){return Lr*V}):null),pn.setZIndex(ir))}var X=!1,me=null,At=0,bt=void 0,Et=void 0,sr=void 0;if((Ve==1||Ve==2)&&"icon-image"in Pe){var Lt=bi(de,"layout","icon-image",Nt,nt,W);if(Lt){bt=typeof Lt=="string"?UM(Lt,Ft):Lt.toString();var Fn=void 0;if(a&&i&&i[bt]){var on=bi(de,"layout","icon-rotation-alignment",Nt,nt,W);if(Ve==2){var m=Ce.getGeometry();if(m.getFlatMidpoint||m.getFlatMidpoints){var un=m.getExtent(),In=Math.sqrt(Math.max(Math.pow((un[2]-un[0])/jt,2),Math.pow((un[3]-un[1])/jt,2)));if(In>150){var Gn=m.getType()==="MultiLineString"?m.getFlatMidpoints():m.getFlatMidpoint();DM||(Kx=[NaN,NaN],DM=new X6("Point",Kx,[],{},null)),Fn=DM,Kx[0]=Gn[0],Kx[1]=Gn[1];var Zn=bi(de,"layout","symbol-placement",Nt,nt,W);if(Zn==="line"&&on==="map")for(var Ke=m.getStride(),fe=m.getFlatCoordinates(),_e=0,Ee=fe.length-Ke;_e<Ee;_e+=Ke){var Te=fe[_e],at=fe[_e+1],it=fe[_e+Ke],ht=fe[_e+Ke+1],et=Math.min(Te,it),Ct=Math.min(at,ht),rn=Math.max(Te,it),Gt=Math.max(at,ht);if(Gn[0]>=et&&Gn[0]<=rn&&Gn[1]>=Ct&&Gn[1]<=Gt){At=Math.atan2(at-ht,it-Te);break}}}}}if(Ve!==2||Fn){var $t=bi(de,"layout","icon-size",Nt,nt,W),gn=Ze["icon-color"]!==void 0?bi(de,"paint","icon-color",Nt,nt,W):null;if(!gn||gn.a!==0){var Mr=bt+"."+$t;if(gn!==null&&(Mr+="."+gn),Et=R[Mr],!Et){var Jn=i[bt];Et=new pz({color:gn?[gn.r*255,gn.g*255,gn.b*255,gn.a]:void 0,img:a,imgSize:f,size:[Jn.width,Jn.height],offset:[Jn.x,Jn.y],rotateWithView:on==="map",scale:$t/Jn.pixelRatio,displacement:"icon-offset"in Pe?bi(de,"layout","icon-offset",Nt,nt,W).map(function(Ti){return-Ti*Jn.pixelRatio}):void 0}),R[Mr]=Et}}Et&&(++Je,pn=Fe[Je],(!pn||!pn.getImage()||pn.getFill()||pn.getStroke())&&(pn=new E0,Fe[Je]=pn),pn.setGeometry(Fn),Et.setRotation(At+PM(bi(de,"layout","icon-rotate",Nt,nt,W))),Et.setOpacity(bi(de,"paint","icon-opacity",Nt,nt,W)),Et.setAnchor(MAe[bi(de,"layout","icon-anchor",Nt,nt,W)]),pn.setImage(Et),me=pn.getText(),pn.setText(void 0),pn.setZIndex(ir),X=!0,sr=!1)}else sr=!0}}}if(Ve==1&&de.type==="circle"){++Je,pn=Fe[Je],(!pn||!pn.getImage()||pn.getFill()||pn.getStroke())&&(pn=new E0,Fe[Je]=pn);var qn="circle-radius"in Ze?bi(de,"paint","circle-radius",Nt,nt,W):5,Tr=Xp(bi(de,"paint","circle-stroke-color",Nt,nt,W),bi(de,"paint","circle-stroke-opacity",Nt,nt,W)),vr=Xp(bi(de,"paint","circle-color",Nt,nt,W),bi(de,"paint","circle-opacity",Nt,nt,W)),Dr=bi(de,"paint","circle-stroke-width",Nt,nt,W),Yr=qn+"."+Tr+"."+vr+"."+Dr;Et=R[Yr],Et||(Et=new Az({radius:qn,stroke:Tr&&Dr>0?new lC({width:Dr,color:Tr}):void 0,fill:vr?new Ug({color:vr}):void 0}),R[Yr]=Et),pn.setImage(Et),me=pn.getText(),pn.setText(void 0),pn.setGeometry(void 0),pn.setZIndex(ir),X=!0}var Zr=void 0,Cr=void 0,ui,Ii,Io,Ci;if("text-field"in Pe){Ii=Math.round(bi(de,"layout","text-size",Nt,nt,W));var so=bi(de,"layout","text-font",Nt,nt,W);ui=bi(de,"layout","text-line-height",Nt,nt,W),Cr=aE(s?s(so):so,Ii,ui),Io=bi(de,"layout","text-letter-spacing",Nt,nt,W),Ci=bi(de,"layout","text-max-width",Nt,nt,W);var Yo=bi(de,"layout","text-field",Nt,nt,W);typeof Yo=="object"&&Yo.sections?Yo.sections.length===1?Zr=Yo.toString():Zr=Yo.sections.reduce(function(Lr,Ti,po){var Cl=Ti.fontStack?Ti.fontStack.split(","):so,br=aE(s?s(Cl):Cl,Ii*(Ti.scale||1),ui),_i=Ti.text;if(_i===`
|
||
`)return Lr.push(`
|
||
`,""),Lr;if(Ve==2){Lr.push(yE(_i,Io),br);return}_i=CE(_i,br,Ci,Io).split(`
|
||
`);for(var _l=0,Qa=_i.length;_l<Qa;++_l)_l>0&&Lr.push(`
|
||
`,""),Lr.push(_i[_l],br);return Lr},[]):Zr=UM(Yo,Ft).trim(),Kt=bi(de,"paint","text-opacity",Nt,nt,W)}if(Zr&&Kt&&!sr){X||(++Je,pn=Fe[Je],(!pn||!pn.getText()||pn.getFill()||pn.getStroke())&&(pn=new E0,Fe[Je]=pn),pn.setImage(void 0),pn.setGeometry(void 0)),pn.getText()||pn.setText(me||new Voe({padding:[2,2,2,2]})),me=pn.getText();var ba=Pe["text-transform"];ba=="uppercase"?Zr=Array.isArray(Zr)?Zr.map(function(Ti,po){return po%2?Ti:Ti.toUpperCase()}):Zr.toUpperCase():ba=="lowercase"&&(Zr=Array.isArray(Zr)?Zr.map(function(Ti,po){return po%2?Ti:Ti.toLowerCase()}):Zr.toLowerCase());var Ql=Array.isArray(Zr)?Zr:Ve==2?yE(Zr,Io):CE(Zr,Cr,Ci,Io);me.setText(Ql),me.setFont(Cr),me.setRotation(PM(bi(de,"layout","text-rotate",Nt,nt,W)));var Ai=bi(de,"layout","text-anchor",Nt,nt,W),Zn=X||Ve==1?"point":bi(de,"layout","symbol-placement",Nt,nt,W);me.setPlacement(Zn),me.setOverflow(Zn==="point");var Mi=bi(de,"paint","text-halo-width",Nt,nt,W),rr=bi(de,"layout","text-offset",Nt,nt,W),lo=bi(de,"paint","text-translate",Nt,nt,W),Gi=0,la=0;if(Zn=="point"){var ve="center";Ai.indexOf("left")!==-1?(ve="left",la=Mi):Ai.indexOf("right")!==-1&&(ve="right",la=-Mi),me.setTextAlign(ve);var Ge=bi(de,"layout","text-rotation-alignment",Nt,nt,W);me.setRotateWithView(Ge=="map")}else me.setMaxAngle(PM(bi(de,"layout","text-max-angle",Nt,nt,W))*Zr.length/Ql.length),me.setTextAlign(),me.setRotateWithView(!1);var Ht="middle";Ai.indexOf("bottom")==0?(Ht="bottom",Gi=-Mi-.5*(ui-1)*Ii):Ai.indexOf("top")==0&&(Ht="top",Gi=Mi+.5*(ui-1)*Ii),me.setTextBaseline(Ht),me.setOffsetX(rr[0]*Ii+la+lo[0]),me.setOffsetY(rr[1]*Ii+Gi+lo[1]),ct.setColor(Xp(bi(de,"paint","text-color",Nt,nt,W),Kt)),me.setFill(ct);var mn=Xp(bi(de,"paint","text-halo-color",Nt,nt,W),Kt);if(mn){rt.setColor(mn),Mi*=2;var Ot=.5*Ii;rt.setWidth(Mi<=Ot?Mi:Ot),me.setStroke(rt)}else me.setStroke(void 0);var En=bi(de,"layout","text-padding",Nt,nt,W),zr=me.getPadding();En!==zr[0]&&(zr[0]=En,zr[1]=En,zr[2]=En,zr[3]=En),pn.setZIndex(ir)}}},pt=0,dt=Jt.length;pt<dt;++pt)Vt(pt);if(Je>-1)return Fe.length=Je+1,Fe}};return e.setStyle(He),e.set("mapbox-source",q),e.set("mapbox-layers",P),He}var Oj={exports:{}};(function(){var e;Oj.exports={icon:"icons/google.svg",name:"google",title:"Google Fonts",link:"google.com/fonts",getNames:function(){return e},getLink:function(n){return"https://fonts.google.com/specimen/"+n.replace(/( )/g,"+")},normalizeName:function(n){return n}},e=["ABeeZee","Abel","Abril Fatface","Aclonica","Acme","Actor","Adamina","Advent Pro","Aguafina Script","Akronim","Aladin","Aldrich","Alef","Alegreya","Alegreya SC","Alegreya Sans","Alegreya Sans SC","Alex Brush","Alfa Slab One","Alice","Alike","Alike Angular","Allan","Allerta","Allerta Stencil","Allura","Almendra","Almendra Display","Almendra SC","Amarante","Amaranth","Amatic SC","Amethysta","Amiri","Amita","Anaheim","Andada","Andika","Angkor","Annie Use Your Telescope","Anonymous Pro","Antic","Antic Didone","Antic Slab","Anton","Arapey","Arbutus","Arbutus Slab","Architects Daughter","Archivo Black","Archivo Narrow","Arimo","Arizonia","Armata","Artifika","Arvo","Arya","Asap","Asar","Asset","Astloch","Asul","Atomic Age","Aubrey","Audiowide","Autour One","Average","Average Sans","Averia Gruesa Libre","Averia Libre","Averia Sans Libre","Averia Serif Libre","Bad Script","Balthazar","Bangers","Basic","Battambang","Baumans","Bayon","Belgrano","Belleza","BenchNine","Bentham","Berkshire Swash","Bevan","Bigelow Rules","Bigshot One","Bilbo","Bilbo Swash Caps","Biryani","Bitter","Black Ops One","Bokor","Bonbon","Boogaloo","Bowlby One","Bowlby One SC","Brawler","Bree Serif","Bubblegum Sans","Bubbler One","Buda","Buenard","Butcherman","Butterfly Kids","Cabin","Cabin Condensed","Cabin Sketch","Caesar Dressing","Cagliostro","Calligraffitti","Cambay","Cambo","Candal","Cantarell","Cantata One","Cantora One","Capriola","Cardo","Carme","Carrois Gothic","Carrois Gothic SC","Carter One","Catamaran","Caudex","Caveat","Caveat Brush","Cedarville Cursive","Ceviche One","Changa One","Chango","Chau Philomene One","Chela One","Chelsea Market","Chenla","Cherry Cream Soda","Cherry Swash","Chewy","Chicle","Chivo","Chonburi","Cinzel","Cinzel Decorative","Clicker Script","Coda","Coda Caption","Codystar","Combo","Comfortaa","Coming Soon","Concert One","Condiment","Content","Contrail One","Convergence","Cookie","Copse","Corben","Courgette","Cousine","Coustard","Covered By Your Grace","Crafty Girls","Creepster","Crete Round","Crimson Text","Croissant One","Crushed","Cuprum","Cutive","Cutive Mono","Damion","Dancing Script","Dangrek","Dawning of a New Day","Days One","Dekko","Delius","Delius Swash Caps","Delius Unicase","Della Respira","Denk One","Devonshire","Dhurjati","Didact Gothic","Diplomata","Diplomata SC","Domine","Donegal One","Doppio One","Dorsa","Dosis","Dr Sugiyama","Droid Sans","Droid Sans Mono","Droid Serif","Duru Sans","Dynalight","EB Garamond","Eagle Lake","Eater","Economica","Eczar","Ek Mukta","Electrolize","Elsie","Elsie Swash Caps","Emblema One","Emilys Candy","Engagement","Englebert","Enriqueta","Erica One","Esteban","Euphoria Script","Ewert","Exo","Exo 2","Expletus Sans","Fanwood Text","Fascinate","Fascinate Inline","Faster One","Fasthand","Fauna One","Federant","Federo","Felipa","Fenix","Finger Paint","Fira Mono","Fira Sans","Fjalla One","Fjord One","Flamenco","Flavors","Fondamento","Fontdiner Swanky","Forum","Francois One","Freckle Face","Fredericka the Great","Fredoka One","Freehand","Fresca","Frijole","Fruktur","Fugaz One","GFS Didot","GFS Neohellenic","Gabriela","Gafata","Galdeano","Galindo","Gentium Basic","Gentium Book Basic","Geo","Geostar","Geostar Fill","Germania One","Gidugu","Gilda Display","Give You Glory","Glass Antiqua","Glegoo","Gloria Hallelujah","Goblin One","Gochi Hand","Gorditas","Goudy Bookletter 1911","Graduate","Grand Hotel","Gravitas One","Great Vibes","Griffy","Gruppo","Gudea","Gurajada","Habibi","Halant","Hammersmith One","Hanalei","Hanalei Fill","Handlee","Hanuman","Happy Monkey","Headland One","Henny Penny","Herr Von Muellerhoff","Hind","Hind Siliguri","Hind Vadodara","Holtwood One SC","Homemade Apple","Homenaje","IM Fell DW Pica","IM Fell DW Pica SC","IM Fell Double Pica","IM Fell Double Pica SC","IM Fell English","IM Fell English SC","IM Fell French Canon","IM Fell French Canon SC","IM Fell Great Primer","IM Fell Great Primer SC","Iceberg","Iceland","Imprima","Inconsolata","Inder","Indie Flower","Inika","Inknut Antiqua","Irish Grover","Istok Web","Italiana","Italianno","Itim","Jacques Francois","Jacques Francois Shadow","Jaldi","Jim Nightshade","Jockey One","Jolly Lodger","Josefin Sans","Josefin Slab","Joti One","Judson","Julee","Julius Sans One","Junge","Jura","Just Another Hand","Just Me Again Down Here","Kadwa","Kalam","Kameron","Kantumruy","Karla","Karma","Kaushan Script","Kavoon","Kdam Thmor","Keania One","Kelly Slab","Kenia","Khand","Khmer","Khula","Kite One","Knewave","Kotta One","Koulen","Kranky","Kreon","Kristi","Krona One","Kurale","La Belle Aurore","Laila","Lakki Reddy","Lancelot","Lateef","Lato","League Script","Leckerli One","Ledger","Lekton","Lemon","Libre Baskerville","Life Savers","Lilita One","Lily Script One","Limelight","Linden Hill","Lobster","Lobster Two","Londrina Outline","Londrina Shadow","Londrina Sketch","Londrina Solid","Lora","Love Ya Like A Sister","Loved by the King","Lovers Quarrel","Luckiest Guy","Lusitana","Lustria","Macondo","Macondo Swash Caps","Magra","Maiden Orange","Mako","Mallanna","Mandali","Marcellus","Marcellus SC","Marck Script","Margarine","Marko One","Marmelad","Martel","Martel Sans","Marvel","Mate","Mate SC","Maven Pro","McLaren","Meddon","MedievalSharp","Medula One","Megrim","Meie Script","Merienda","Merienda One","Merriweather","Merriweather Sans","Metal","Metal Mania","Metamorphous","Metrophobic","Michroma","Milonga","Miltonian","Miltonian Tattoo","Miniver","Miss Fajardose","Modak","Modern Antiqua","Molengo","Molle","Monda","Monofett","Monoton","Monsieur La Doulaise","Montaga","Montez","Montserrat","Montserrat Alternates","Montserrat Subrayada","Moul","Moulpali","Mountains of Christmas","Mouse Memoirs","Mr Bedfort","Mr Dafoe","Mr De Haviland","Mrs Saint Delafield","Mrs Sheppards","Muli","Mystery Quest","NTR","Neucha","Neuton","New Rocker","News Cycle","Niconne","Nixie One","Nobile","Nokora","Norican","Nosifer","Nothing You Could Do","Noticia Text","Noto Sans","Noto Serif","Nova Cut","Nova Flat","Nova Mono","Nova Oval","Nova Round","Nova Script","Nova Slim","Nova Square","Numans","Nunito","Odor Mean Chey","Offside","Old Standard TT","Oldenburg","Oleo Script","Oleo Script Swash Caps","Open Sans","Open Sans Condensed","Oranienbaum","Orbitron","Oregano","Orienta","Original Surfer","Oswald","Over the Rainbow","Overlock","Overlock SC","Ovo","Oxygen","Oxygen Mono","PT Mono","PT Sans","PT Sans Caption","PT Sans Narrow","PT Serif","PT Serif Caption","Pacifico","Palanquin","Palanquin Dark","Paprika","Parisienne","Passero One","Passion One","Pathway Gothic One","Patrick Hand","Patrick Hand SC","Patua One","Paytone One","Peddana","Peralta","Permanent Marker","Petit Formal Script","Petrona","Philosopher","Piedra","Pinyon Script","Pirata One","Plaster","Play","Playball","Playfair Display","Playfair Display SC","Podkova","Poiret One","Poller One","Poly","Pompiere","Pontano Sans","Poppins","Port Lligat Sans","Port Lligat Slab","Pragati Narrow","Prata","Preahvihear","Press Start 2P","Princess Sofia","Prociono","Prosto One","Puritan","Purple Purse","Quando","Quantico","Quattrocento","Quattrocento Sans","Questrial","Quicksand","Quintessential","Qwigley","Racing Sans One","Radley","Rajdhani","Raleway","Raleway Dots","Ramabhadra","Ramaraja","Rambla","Rammetto One","Ranchers","Rancho","Ranga","Rationale","Ravi Prakash","Redressed","Reenie Beanie","Revalia","Rhodium Libre","Ribeye","Ribeye Marrow","Righteous","Risque","Roboto","Roboto Condensed","Roboto Mono","Roboto Slab","Rochester","Rock Salt","Rokkitt","Romanesco","Ropa Sans","Rosario","Rosarivo","Rouge Script","Rozha One","Rubik","Rubik Mono One","Rubik One","Ruda","Rufina","Ruge Boogie","Ruluko","Rum Raisin","Ruslan Display","Russo One","Ruthie","Rye","Sacramento","Sahitya","Sail","Salsa","Sanchez","Sancreek","Sansita One","Sarala","Sarina","Sarpanch","Satisfy","Scada","Scheherazade","Schoolbell","Seaweed Script","Sevillana","Seymour One","Shadows Into Light","Shadows Into Light Two","Shanti","Share","Share Tech","Share Tech Mono","Shojumaru","Short Stack","Siemreap","Sigmar One","Signika","Signika Negative","Simonetta","Sintony","Sirin Stencil","Six Caps","Skranji","Slabo 13px","Slabo 27px","Slackey","Smokum","Smythe","Sniglet","Snippet","Snowburst One","Sofadi One","Sofia","Sonsie One","Sorts Mill Goudy","Source Code Pro","Source Sans Pro","Source Serif Pro","Special Elite","Spicy Rice","Spinnaker","Spirax","Squada One","Sree Krushnadevaraya","Stalemate","Stalinist One","Stardos Stencil","Stint Ultra Condensed","Stint Ultra Expanded","Stoke","Strait","Sue Ellen Francisco","Sumana","Sunshiney","Supermercado One","Sura","Suranna","Suravaram","Suwannaphum","Swanky and Moo Moo","Syncopate","Tangerine","Taprom","Tauri","Teko","Telex","Tenali Ramakrishna","Tenor Sans","Text Me One","The Girl Next Door","Tienne","Tillana","Timmana","Tinos","Titan One","Titillium Web","Trade Winds","Trocchi","Trochut","Trykker","Tulpen One","Ubuntu","Ubuntu Condensed","Ubuntu Mono","Ultra","Uncial Antiqua","Underdog","Unica One","UnifrakturCook","UnifrakturMaguntia","Unkempt","Unlock","Unna","VT323","Vampiro One","Varela","Varela Round","Vast Shadow","Vesper Libre","Vibur","Vidaloka","Viga","Voces","Volkhov","Vollkorn","Voltaire","Waiting for the Sunrise","Wallpoet","Walter Turncoat","Warnes","Wellfleet","Wendy One","Wire One","Work Sans","Yanone Kaffeesatz","Yantramanav","Yellowtail","Yeseva One","Yesteryear","Zeyada"]}).call(mf);var kAe=Oj.exports;const IAe=ga(kAe);var fT={},TAe=/font-family: ?([^;]*);/,KAe=/("|')/g,Px;function PAe(e){if(!Px){Px={};for(var n=document.styleSheets,t=0,r=n.length;t<r;++t){var i=n[t];try{var o=i.rules||i.cssRules;if(o)for(var s=0,a=o.length;s<a;++s){var f=o[s];if(f.type==5){var g=f.cssText.match(TAe);Px[g[1].replace(KAe,"")]=!0}}}catch{}}}return e in Px}var pT={},FAe=IAe.getNames();function DAe(e){var n=e.toString();if(n in pT)return e;for(var t=e.map(function(g){var x=aE(g,1).split(" ");return[x.slice(3).join(" ").replace(/"/g,""),x[1]+x[0]]}),r=0,i=t.length;r<i;++r){var o=t[r],s=o[0];if(!PAe(s)&&FAe.indexOf(s)!==-1){var a="https://fonts.googleapis.com/css?family="+s.replace(/ /g,"+")+":"+o[1];if(!document.querySelector('link[href="'+a+'"]')){var f=document.createElement("link");f.href=a,f.rel="stylesheet",document.head.appendChild(f)}}}return pT[n]=!0,e}var Bj=/^(.*)(\?.*)$/;function $3(e,n){return n&&e.indexOf(".")===0&&(e=n+e),e}function RM(e,n,t){e=$3(e,n);var r=e.match(Bj);return r?r[1]+t+(r.length>2?r[2]:""):e+t}function UAe(e,n,t,r,i){return new Promise(function(o,s){if(typeof n!="object"&&(n=JSON.parse(n)),n.version!=8)return s(new Error("glStyle version 8 required."));if(!(e instanceof _z||e instanceof jz))return s(new Error("Can only apply to VectorLayer or VectorTileLayer"));var a,f,g,x;function k(){!x&&(!n.sprite||f)?(x=BAe(e,n,t,i,f,g,DAe),e.getStyle()?o():s(new Error("Nothing to show for source [".concat(t,"]")))):x?(e.setStyle(x),o()):s(new Error("Something went wrong trying to apply style."))}if(n.sprite){a=window.devicePixelRatio>=1.5?.5:1;var B=a==.5?"@2x":"",P=RM(n.sprite,r,B+".json");fetch(P,{credentials:"same-origin"}).then(function(R){return!R.ok&&B!==""?(P=RM(n.sprite,r,".json"),fetch(P,{credentials:"same-origin"})):R}).then(function(R){if(R.ok)return R.json();s(new Error("Problem fetching sprite from ".concat(P,": ").concat(R.statusText)))}).then(function(R){if(R===void 0)return s(new Error("No sprites found."));f=R,g=RM(n.sprite,r,B+".png"),k()}).catch(function(R){s(new Error("Sprites cannot be loaded: ".concat(P,": ").concat(R.message)))})}else k()})}var bE={};function RAe(e,n){var t={id:n.id,type:n.type},r={};function i(o){var s=n.layout||{},a=n.paint||{};t.paint=a;var f=typeof e.getSource=="function"?e.getSource().getTileGrid().getZForResolution(o):e.getView().getZoom(),g=typeof e.getTargetElement=="function"?e.getTargetElement():void 0,x,k;if(a["background-color"]!==void 0&&(x=bi(t,"paint","background-color",f,bE,r),g&&(g.style.background=Gl.parse(x).toString())),a["background-opacity"]!==void 0&&(k=bi(t,"paint","background-opacity",f,bE,r),g&&(g.style.opacity=k)),s.visibility=="none"){g&&(g.style.backgroundColor="",g.style.opacity="");return}return Xp(x,k)}if(typeof e.getTargetElement=="function")e.getTargetElement()&&i(),e.on(["change:resolution","change:target"],i);else if(typeof e.setBackground=="function")e.setBackground(i);else throw new Error("Unable to apply background.")}function LAe(e,n){var t;return e.some(function(r){if(r.id==n)return t=r.source,!0}),t}function kj(e){var n=e.bounds;if(n){var t=G6([n[0],n[1]]),r=G6([n[2],n[3]]);return[t[0],t[1],r[0],r[1]]}}function zAe(e,n){e=Mj({},e);var t=[n,JSON.stringify(e)].toString(),r=fT[t];return r||(r=new Lz({url:e.tiles?void 0:n,tileJSON:e.tiles?e:void 0}),fT[t]=r),new Promise(function(i){var o=r.on("change",function(){var s=r.getState();if(s==="ready"){var a=r.getTileJSON(),f=Array.isArray(a.tiles)?a.tiles:[a.tiles];if(n)for(var g=0,x=f.length;g<x;++g)f[g]=decodeURI(new URL(f[g],n).href);var k=r.getTileGrid(),B=kj(a),P=a.minzoom||0,R=a.maxzoom||22,H=r.get("ol-source");H===void 0&&(H=new Wz({attributions:r.getAttributions(),format:new Gne,tileGrid:new X_({origin:k.getOrigin(0),extent:B||k.getExtent(),minZoom:P,resolutions:Sy.slice(0,R+1),tileSize:512}),urls:f}),r.set("ol-source",H)),l_(o),i(H)}else s==="error"&&(r.set("ol-source",null),l_(o),i(void 0))});r.getState()==="ready"&&r.changed()})}function jAe(e,n){var t=new jz({declutter:!0,visible:!1});return zAe(e,n).then(function(r){t.setSource(r)}),t}function WAe(e,n){var t=new dse,r=new Lz({transition:0,url:e.tiles?void 0:n,tileJSON:e.tiles?e:void 0,crossOrigin:"anonymous"}),i=r.on("change",function(){var o=r.getState();if(o==="ready"){l_(i);var s=r.getTileJSON(),a=kj(s),f=r.getTileGrid(),g=e.tileSize||s.tileSize||512,x=s.minzoom||0,k=s.maxzoom||22;r.tileGrid=new X_({origin:f.getOrigin(0),extent:a||f.getExtent(),minZoom:x,resolutions:v7({maxZoom:k,tileSize:g}).getResolutions(),tileSize:g}),t.setSource(r)}else o==="error"&&(l_(i),t.setSource(void 0))});return r.setTileLoadFunction(function(o,s){if(s.indexOf("{bbox-epsg-3857}")!=-1){var a=r.getTileGrid().getTileCoordExtent(o.getTileCoord());s=s.replace("{bbox-epsg-3857}",a.toString())}var f=o.getImage();f.src=s}),t}var mT=new rne;function NAe(e,n){var t=e.data,r,i;return typeof t=="string"?i=$3(t,n):r=mT.readFeatures(t,{featureProjection:"EPSG:3857"}),new _z({declutter:!0,source:new Mz({attributions:e.attribution,features:r,format:mT,url:i}),visible:!1})}function gT(e,n,t,r){var i=t.getZoom(),o=bi(e,"paint","raster-opacity",i,bE,r);n.setOpacity(o)}function yT(e,n,t,r,i,o){o===void 0&&(o="");var s=[],a=n.getView();!a.isDef()&&!a.getRotation()&&!a.getResolutions()&&(a=new pp(Mj(a.getProperties(),{maxResolution:Sy[0]})),n.setView(a)),"center"in e&&!a.getCenter()&&a.setCenter(G6(e.center)),"zoom"in e&&a.getZoom()===void 0&&a.setResolution(Sy[0]/Math.pow(2,e.zoom)),(!a.getCenter()||a.getZoom()===void 0)&&a.fit(a.getProjection().getExtent(),{nearest:!0,size:n.getSize()}),e.sprite&&(e.sprite.indexOf("mapbox://")==0?e.sprite=t+"/sprite"+o:e.sprite.indexOf("http")!=0&&(e.sprite=(r?r+i:"")+e.sprite+o));for(var f=e.layers,g=[],x,k,B,P,R,H,W=function(ne,ce){x=f[ne];var ae=x.type;if(!(ae=="heatmap"||ae=="hillshade"))if(ae=="background")RAe(n,x);else{if(P=x.source||LAe(f,x.ref),P!=B){if(g.length&&(s.push(vT(R,g,e,i,n)),g=[]),k=e.sources[P],H=k.url,H)if(H=$3(H,i),H.indexOf("mapbox://")==0){var ue=H.replace("mapbox://","");k.tiles=["a","b","c","d"].map(function(Re){return"https://"+Re+".tiles.mapbox.com/v4/"+ue+"/{z}/{x}/{y}."+(k.type=="vector"?"vector.pbf":"png")+o})}else H.indexOf("/")===0&&r.indexOf("http")===0&&(H=r+H);if(k.tiles&&(k.tiles=k.tiles.map(function(Re){return $3(Re,i)})),k.type=="vector")R=jAe(k,H);else if(k.type=="raster"){R=WAe(k,H),R.setVisible(x.layout?x.layout.visibility!=="none":!0);var ye={};a.on("change:resolution",gT.bind($,x,R,a,ye)),gT(x,R,a,ye)}else k.type=="geojson"&&(R=NAe(k,i));B=P,R&&R.set("mapbox-source",B)}g.push(x.id)}},$=this,q=0,oe=f.length;q<oe;++q)W(q);return s.push(vT(R,g,e,i,n)),n.set("mapbox-style",e),Promise.all(s)}function GAe(e,n){var t,r="",i="",o="",s="";if((typeof e=="string"||e instanceof HTMLElement)&&(e=new g7({target:e})),typeof n=="string"){var a=n.match(Bj);a&&(i=a[1],r=a.length>2?a[2]:""),t=new Promise(function(f,g){fetch(n,{credentials:"same-origin"}).then(function(x){return x.json()}).then(function(x){var k=document.createElement("A");k.href=n;var B=k.href;s=k.pathname.split("/").slice(0,-1).join("/")+"/",o=B.substr(0,B.indexOf(s)),yT(x,e,i,o,s,r).then(function(){f(e)}).catch(g)}).catch(function(x){g(new Error("Could not load ".concat(n,": ").concat(x.message)))})})}else t=new Promise(function(f,g){yT(n,e).then(function(){f(e)}).catch(g)});return t}function QAe(e,n){return(typeof e=="string"||e instanceof HTMLElement)&&(e=new g7({target:e})),setTimeout(function(){GAe(e,n)},0),e}function vT(e,n,t,r,i){for(var o=24,s=0,a=t.layers,f=0,g=a.length;f<g;++f){var x=a[f];n.indexOf(x.id)!==-1&&(o=Math.min("minzoom"in x?x.minzoom:0,o),s=Math.max("maxzoom"in x?x.maxzoom:24,s))}return new Promise(function(k,B){var P=function(){var R=e.getSource();if(!R||R.getState()==="error"){B(new Error("Error accessing data for source "+e.get("mapbox-source")));return}if("getTileGrid"in R){var H=R.getTileGrid();if(H){var W=H.getMinZoom();(o>0||W>0)&&e.setMaxResolution(Math.min(Sy[o],H.getResolution(W))+1e-9),s<24&&e.setMinResolution(Sy[s]+1e-9)}}R instanceof Mz||R instanceof Wz?UAe(e,t,n,r).then(function(){e.setVisible(!0),k()},function($){B($)}):k()};e.set("mapbox-layers",n),i.getLayers().getArray().indexOf(e)===-1&&i.addLayer(e),e.getSource()?P():e.once("change:source",P)})}function Er(){var e="/home/runner/work/maputnik/maputnik/src/components/MapOpenLayers.tsx",n="7242f6b015e11a4c9eb3973d702f9d425918e132",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/MapOpenLayers.tsx",statementMap:{0:{start:{line:10,column:2},end:{line:14,column:3}},1:{start:{line:11,column:4},end:{line:11,column:16}},2:{start:{line:13,column:4},end:{line:13,column:149}},3:{start:{line:13,column:103},end:{line:13,column:133}},4:{start:{line:17,column:24},end:{line:24,column:3}},5:{start:{line:27,column:14},end:{line:27,column:18}},6:{start:{line:29,column:19},end:{line:29,column:23}},7:{start:{line:31,column:4},end:{line:31,column:17}},8:{start:{line:32,column:4},end:{line:37,column:6}},9:{start:{line:38,column:4},end:{line:38,column:67}},10:{start:{line:41,column:4},end:{line:42,column:13}},11:{start:{line:42,column:6},end:{line:42,column:13}},12:{start:{line:43,column:4},end:{line:43,column:33}},13:{start:{line:44,column:4},end:{line:44,column:33}},14:{start:{line:47,column:4},end:{line:51,column:5}},15:{start:{line:48,column:6},end:{line:50,column:8}},16:{start:{line:54,column:4},end:{line:60,column:7}},17:{start:{line:61,column:16},end:{line:68,column:6}},18:{start:{line:69,column:4},end:{line:77,column:7}},19:{start:{line:70,column:21},end:{line:70,column:45}},20:{start:{line:71,column:6},end:{line:76,column:9}},21:{start:{line:78,column:22},end:{line:88,column:5}},22:{start:{line:79,column:19},end:{line:79,column:42}},23:{start:{line:80,column:21},end:{line:80,column:56}},24:{start:{line:81,column:6},end:{line:87,column:9}},25:{start:{line:89,column:4},end:{line:89,column:16}},26:{start:{line:90,column:4},end:{line:90,column:33}},27:{start:{line:91,column:4},end:{line:101,column:7}},28:{start:{line:92,column:21},end:{line:92,column:56}},29:{start:{line:93,column:6},end:{line:100,column:9}},30:{start:{line:102,column:4},end:{line:102,column:19}},31:{start:{line:103,column:4},end:{line:105,column:6}},32:{start:{line:107,column:17},end:{line:110,column:3}},33:{start:{line:108,column:4},end:{line:108,column:20}},34:{start:{line:109,column:4},end:{line:109,column:37}},35:{start:{line:112,column:4},end:{line:169,column:9}},36:{start:{line:116,column:22},end:{line:116,column:45}},37:{start:{line:161,column:22},end:{line:161,column:40}}},fnMap:{0:{name:"renderCoords",decl:{start:{line:9,column:9},end:{line:9,column:21}},loc:{start:{line:9,column:30},end:{line:15,column:1}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:13,column:92},end:{line:13,column:93}},loc:{start:{line:13,column:103},end:{line:13,column:133}},line:13},2:{name:"(anonymous_2)",decl:{start:{line:18,column:17},end:{line:18,column:18}},loc:{start:{line:18,column:23},end:{line:19,column:5}},line:18},3:{name:"(anonymous_3)",decl:{start:{line:20,column:18},end:{line:20,column:19}},loc:{start:{line:20,column:24},end:{line:21,column:5}},line:20},4:{name:"(anonymous_4)",decl:{start:{line:22,column:19},end:{line:22,column:20}},loc:{start:{line:22,column:25},end:{line:23,column:5}},line:22},5:{name:"(anonymous_5)",decl:{start:{line:30,column:2},end:{line:30,column:3}},loc:{start:{line:30,column:21},end:{line:39,column:3}},line:30},6:{name:"(anonymous_6)",decl:{start:{line:40,column:2},end:{line:40,column:3}},loc:{start:{line:40,column:28},end:{line:45,column:3}},line:40},7:{name:"(anonymous_7)",decl:{start:{line:46,column:2},end:{line:46,column:3}},loc:{start:{line:46,column:32},end:{line:52,column:3}},line:46},8:{name:"(anonymous_8)",decl:{start:{line:53,column:2},end:{line:53,column:3}},loc:{start:{line:53,column:22},end:{line:106,column:3}},line:53},9:{name:"(anonymous_9)",decl:{start:{line:69,column:26},end:{line:69,column:27}},loc:{start:{line:69,column:35},end:{line:77,column:5}},line:69},10:{name:"(anonymous_10)",decl:{start:{line:78,column:22},end:{line:78,column:23}},loc:{start:{line:78,column:28},end:{line:88,column:5}},line:78},11:{name:"(anonymous_11)",decl:{start:{line:91,column:25},end:{line:91,column:26}},loc:{start:{line:91,column:33},end:{line:101,column:5}},line:91},12:{name:"(anonymous_12)",decl:{start:{line:107,column:17},end:{line:107,column:18}},loc:{start:{line:107,column:24},end:{line:110,column:3}},line:107},13:{name:"(anonymous_13)",decl:{start:{line:111,column:2},end:{line:111,column:3}},loc:{start:{line:111,column:11},end:{line:170,column:3}},line:111},14:{name:"(anonymous_14)",decl:{start:{line:116,column:15},end:{line:116,column:16}},loc:{start:{line:116,column:22},end:{line:116,column:45}},line:116},15:{name:"(anonymous_15)",decl:{start:{line:161,column:15},end:{line:161,column:16}},loc:{start:{line:161,column:22},end:{line:161,column:40}},line:161}},branchMap:{0:{loc:{start:{line:10,column:2},end:{line:14,column:3}},type:"if",locations:[{start:{line:10,column:2},end:{line:14,column:3}},{start:{line:12,column:9},end:{line:14,column:3}}],line:10},1:{loc:{start:{line:10,column:6},end:{line:10,column:34}},type:"binary-expr",locations:[{start:{line:10,column:6},end:{line:10,column:13}},{start:{line:10,column:17},end:{line:10,column:34}}],line:10},2:{loc:{start:{line:41,column:4},end:{line:42,column:13}},type:"if",locations:[{start:{line:41,column:4},end:{line:42,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:41},3:{loc:{start:{line:47,column:4},end:{line:51,column:5}},type:"if",locations:[{start:{line:47,column:4},end:{line:51,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:47},4:{loc:{start:{line:132,column:26},end:{line:132,column:59}},type:"binary-expr",locations:[{start:{line:132,column:26},end:{line:132,column:53}},{start:{line:132,column:57},end:{line:132,column:59}}],line:132},5:{loc:{start:{line:143,column:6},end:{line:156,column:10}},type:"binary-expr",locations:[{start:{line:143,column:6},end:{line:143,column:29}},{start:{line:143,column:49},end:{line:156,column:10}}],line:143}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/MapOpenLayers.tsx"],names:[],mappings:"AAkBW,cAuIL,YAvIK;AAlBX,OAAO,WAAW;AAClB,SAAQ,gBAAe;AAEvB,OAAO,6BAA6B;AAEpC,OAAO;AACP,SAAQ,aAAY;AACpB,SAAQ,KAAK,MAAM,eAAc;AAEjC,SAAQ,gBAAe;AAIvB,SAAS,aAAc,QAAkB;AACvC,MAAI,CAAC,UAAU,OAAO,SAAS,GAAG;AAChC,WAAO;AAAA,EACT,OACK;AACH,WAAO,oBAAC,UAAK,WAAU,mBACpB,iBAAO,IAAI,CAAC,UAAU,OAAO,KAAK,EAAE,SAAS,GAAG,GAAQ,CAAC,EAAE,KAAK,IAAI,GACvE;AAAA,EACF;AACF;AAqBA,qBAAqB,sBAAsB,MAAM,UAAkD;AAAA,EACjG,OAAO,eAAe;AAAA,IACpB,aAAa,MAAM;AAAA,IAAC;AAAA,IACpB,cAAc,MAAM;AAAA,IAAC;AAAA,IACrB,eAAe,MAAM;AAAA,IAAC;AAAA,EACxB;AAAA,EACA;AAAA,EACA;AAAA,EACA,YAAmC;AAAA,EACnC;AAAA,EACA,iBAAqC;AAAA,EAErC,YAAY,OAA2B;AACrC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,MAAM;AAAA,MACN,UAAU;AAAA,MACV,QAAQ,CAAC;AAAA,MACT,QAAQ,CAAC;AAAA,IACX;AACA,SAAK,cAAc,SAAS,KAAK,aAAa,KAAK,IAAI,GAAG,GAAG;AAAA,EAC/D;AAAA,EAEA,aAAa,aAAiC;AAC5C,QAAG,CAAC,KAAK;AAAK;AAGd,SAAK,IAAI,UAAU,EAAE,MAAM;AAC3B,UAAM,KAAK,KAAK,WAAW;AAAA,EAC7B;AAAA,EAEA,mBAAmB,WAA+B;AAChD,QAAI,KAAK,MAAM,aAAa,UAAU,UAAU;AAC9C,WAAK;AAAA,QACH,KAAK,MAAM,oBAAoB,KAAK,MAAM,QAAQ;AAAA,MACpD;AAAA,IACF;AAAA,EACF;AAAA,EAEA,oBAAoB;AAClB,SAAK,UAAU,IAAI,QAAQ;AAAA,MACzB,SAAS,KAAK;AAAA,MACd,SAAS;AAAA,MACT,kBAAkB;AAAA,QAChB,UAAU;AAAA,MACZ;AAAA,IACF,CAAC;AAED,UAAM,MAAM,IAAI,IAAI;AAAA,MAClB,QAAQ,KAAK;AAAA,MACb,UAAU,CAAC,KAAK,OAAO;AAAA,MACvB,MAAM,IAAI,KAAK;AAAA,QACb,MAAM;AAAA,QACN,QAAQ,CAAC,KAAK,GAAG;AAAA,MACnB,CAAC;AAAA,IACH,CAAC;AAED,QAAI,GAAG,eAAe,CAAC,QAAQ;AAC7B,YAAM,SAAS,SAAS,IAAI,UAAU;AACtC,WAAK,SAAS;AAAA,QACZ,QAAQ;AAAA,UACN,OAAO,CAAC,EAAE,QAAQ,CAAC;AAAA,UACnB,OAAO,CAAC,EAAE,QAAQ,CAAC;AAAA,QACrB;AAAA,MACF,CAAC;AAAA,IACH,CAAC;AAED,UAAM,YAAY,MAAM;AACtB,YAAM,OAAO,IAAI,QAAQ,EAAE,QAAQ;AACnC,YAAM,SAAS,SAAS,IAAI,QAAQ,EAAE,UAAU,CAAE;AAElD,WAAK,MAAM,SAAS;AAAA,QAClB;AAAA,QACA,QAAQ;AAAA,UACN,KAAK,OAAO,CAAC;AAAA,UACb,KAAK,OAAO,CAAC;AAAA,QACf;AAAA,MACF,CAAC;AAAA,IACH;AAEA,cAAU;AACV,QAAI,GAAG,WAAW,SAAS;AAE3B,QAAI,GAAG,cAAc,CAAC,OAAO;AAC3B,YAAM,SAAS,SAAS,IAAI,QAAQ,EAAE,UAAU,CAAE;AAClD,WAAK,SAAS;AAAA,QACZ,QAAQ;AAAA,UACN,OAAO,CAAC,EAAE,QAAQ,CAAC;AAAA,UACnB,OAAO,CAAC,EAAE,QAAQ,CAAC;AAAA,QACrB;AAAA,QACA,UAAU,IAAI,QAAQ,EAAE,YAAY,EAAE,QAAQ,CAAC;AAAA,QAC/C,MAAM,IAAI,QAAQ,EAAE,QAAQ,EAAG,QAAQ,CAAC;AAAA,MAC1C,CAAC;AAAA,IACH,CAAC;AAID,SAAK,MAAM;AACX,SAAK;AAAA,MACH,KAAK,MAAM,oBAAoB,KAAK,MAAM,QAAQ;AAAA,IACpD;AAAA,EACF;AAAA,EAEA,eAAe,CAAC,MAAW;AACzB,MAAE,OAAO,KAAK;AACd,SAAK,QAAS,YAAY,MAAS;AAAA,EACrC;AAAA,EAEA,SAAS;AACP,WAAO,qBAAC,SAAI,WAAU,yBACpB;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,KAAK,OAAK,KAAK,iBAAiB;AAAA,UAChC,OAAO,EAAC,YAAY,QAAO;AAAA,UAC3B,WAAU;AAAA,UAEV;AAAA;AAAA,cAAC;AAAA;AAAA,gBACC,WAAU;AAAA,gBACV,SAAS,KAAK;AAAA,gBACd,cAAW;AAAA,gBACZ;AAAA;AAAA,YAED;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,UAAU,KAAK,MAAM,oBAAoB,CAAC;AAAA,gBAC1C,eAAe,KAAK,MAAM;AAAA;AAAA,YAC5B;AAAA;AAAA;AAAA,MACF;AAAA,MACA,qBAAC,SAAI,WAAU,oBAAmB;AAAA;AAAA,QACzB,KAAK,MAAM;AAAA,SACpB;AAAA,MACC,KAAK,MAAM,gBACV,qBAAC,SAAI,WAAU,qBACb;AAAA,6BAAC,SACC;AAAA,8BAAC,WAAM,sBAAQ;AAAA,UACf,oBAAC,UAAM,uBAAa,KAAK,MAAM,MAAM,GAAE;AAAA,WACzC;AAAA,QACA,qBAAC,SACC;AAAA,8BAAC,WAAM,sBAAQ;AAAA,UACf,oBAAC,UAAM,uBAAa,KAAK,MAAM,MAAM,GAAE;AAAA,WACzC;AAAA,QACA,qBAAC,SACC;AAAA,8BAAC,WAAM,wBAAU;AAAA,UACjB,oBAAC,UAAM,eAAK,MAAM,UAAS;AAAA,WAC7B;AAAA,SACF;AAAA,MAEF;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,KAAK,OAAK,KAAK,YAAY;AAAA,UAC3B,MAAK;AAAA,UACL,cAAW;AAAA,UACX,OAAO;AAAA,YACL,GAAG,KAAK,MAAM;AAAA,UAChB;AAAA;AAAA,MACF;AAAA,OACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"7242f6b015e11a4c9eb3973d702f9d425918e132"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Er=function(){return s},s}Er();function CT(e){return Er().f[0]++,Er().s[0]++,Er().b[1][0]++,!e||(Er().b[1][1]++,e.length<2)?(Er().b[0][0]++,Er().s[1]++,null):(Er().b[0][1]++,Er().s[2]++,N.jsx("span",{className:"maputnik-coords",children:e.map(n=>(Er().f[1]++,Er().s[3]++,String(n).padStart(7," "))).join(", ")}))}class Ij extends bn.Component{constructor(t){Er().f[5]++,Er().s[7]++;super(t);nn(this,"updateStyle");nn(this,"map");nn(this,"container",(Er().s[5]++,null));nn(this,"overlay");nn(this,"popupContainer",(Er().s[6]++,null));nn(this,"closeOverlay",(Er().s[32]++,t=>{Er().f[12]++,Er().s[33]++,t.target.blur(),Er().s[34]++,this.overlay.setPosition(void 0)}));Er().s[8]++,this.state={zoom:"0",rotation:"0",cursor:[],center:[]},Er().s[9]++,this.updateStyle=Q4.throttle(this._updateStyle.bind(this),200)}_updateStyle(t){if(Er().f[6]++,Er().s[10]++,this.map)Er().b[2][1]++;else{Er().b[2][0]++,Er().s[11]++;return}Er().s[12]++,this.map.getLayers().clear(),Er().s[13]++,QAe(this.map,t)}componentDidUpdate(t){Er().f[7]++,Er().s[14]++,this.props.mapStyle!==t.mapStyle?(Er().b[3][0]++,Er().s[15]++,this.updateStyle(this.props.replaceAccessTokens(this.props.mapStyle))):Er().b[3][1]++}componentDidMount(){Er().f[8]++,Er().s[16]++,this.overlay=new oie({element:this.popupContainer,autoPan:!0,autoPanAnimation:{duration:250}});const t=(Er().s[17]++,new g7({target:this.container,overlays:[this.overlay],view:new pp({zoom:1,center:[180,-90]})}));Er().s[18]++,t.on("pointermove",i=>{Er().f[9]++;const o=(Er().s[19]++,lM(i.coordinate));Er().s[20]++,this.setState({cursor:[o[0].toFixed(2),o[1].toFixed(2)]})}),Er().s[21]++;const r=()=>{Er().f[10]++;const i=(Er().s[22]++,t.getView().getZoom()),o=(Er().s[23]++,lM(t.getView().getCenter()));Er().s[24]++,this.props.onChange({zoom:i,center:{lng:o[0],lat:o[1]}})};Er().s[25]++,r(),Er().s[26]++,t.on("moveend",r),Er().s[27]++,t.on("postrender",i=>{Er().f[11]++;const o=(Er().s[28]++,lM(t.getView().getCenter()));Er().s[29]++,this.setState({center:[o[0].toFixed(2),o[1].toFixed(2)],rotation:t.getView().getRotation().toFixed(2),zoom:t.getView().getZoom().toFixed(2)})}),Er().s[30]++,this.map=t,Er().s[31]++,this.updateStyle(this.props.replaceAccessTokens(this.props.mapStyle))}render(){return Er().f[13]++,Er().s[35]++,N.jsxs("div",{className:"maputnik-ol-container",children:[N.jsxs("div",{ref:t=>(Er().f[14]++,Er().s[36]++,this.popupContainer=t),style:{background:"black"},className:"maputnik-popup",children:[N.jsx("button",{className:"maplibregl-popup-close-button",onClick:this.closeOverlay,"aria-label":"Close popup",children:"×"}),N.jsx(HR,{features:(Er().b[4][0]++,this.state.selectedFeatures||(Er().b[4][1]++,[])),onLayerSelect:this.props.onLayerSelect})]}),N.jsxs("div",{className:"maputnik-ol-zoom",children:["Zoom: ",this.state.zoom]}),(Er().b[5][0]++,this.props.debugToolbox&&(Er().b[5][1]++,N.jsxs("div",{className:"maputnik-ol-debug",children:[N.jsxs("div",{children:[N.jsx("label",{children:"cursor: "}),N.jsx("span",{children:CT(this.state.cursor)})]}),N.jsxs("div",{children:[N.jsx("label",{children:"center: "}),N.jsx("span",{children:CT(this.state.center)})]}),N.jsxs("div",{children:[N.jsx("label",{children:"rotation: "}),N.jsx("span",{children:this.state.rotation})]})]}))),N.jsx("div",{className:"maputnik-ol",ref:t=>(Er().f[15]++,Er().s[37]++,this.container=t),role:"region","aria-label":"Map view",style:{...this.props.style}})]})}}nn(Ij,"defaultProps",(Er().s[4]++,{onMapLoaded:()=>{Er().f[2]++},onDataChange:()=>{Er().f[3]++},onLayerSelect:()=>{Er().f[4]++}}));function T0(){var e="/home/runner/work/maputnik/maputnik/src/components/Collapser.tsx",n="e73e8fb606fcd7318a8222b2e50c576ed3ad8702",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/Collapser.tsx",statementMap:{0:{start:{line:6,column:22},end:{line:10,column:5}},1:{start:{line:11,column:4},end:{line:11,column:154}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:12,column:3}},line:5}},branchMap:{0:{loc:{start:{line:11,column:11},end:{line:11,column:153}},type:"cond-expr",locations:[{start:{line:11,column:52},end:{line:11,column:92}},{start:{line:11,column:111},end:{line:11,column:153}}],line:11}},s:{0:0,1:0},f:{0:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/Collapser.tsx"],names:[],mappings:"AAeoC;AAfpC,OAAO,WAAW;AAClB,SAAQ,iBAAiB,qBAAoB;AAO7C,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,UAAM,YAAY;AAAA,MAChB,OAAO;AAAA,MACP,QAAQ;AAAA,MACR,GAAG,KAAK,MAAM;AAAA,IAChB;AACA,WAAO,KAAK,MAAM,cAAc,oBAAC,iBAAc,OAAO,WAAU,IAAK,oBAAC,mBAAgB,OAAO,WAAW;AAAA,EAC1G;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"e73e8fb606fcd7318a8222b2e50c576ed3ad8702"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return T0=function(){return s},s}T0();class $Ae extends bn.Component{render(){T0().f[0]++;const n=(T0().s[0]++,{width:20,height:20,...this.props.style});return T0().s[1]++,this.props.isCollapsed?(T0().b[0][0]++,N.jsx(SJ,{style:n})):(T0().b[0][1]++,N.jsx(MJ,{style:n}))}}function zg(){var e="/home/runner/work/maputnik/maputnik/src/components/LayerListGroup.tsx",n="b04bfec534013c327fd210571832bbd2813a944a",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/LayerListGroup.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:32,column:9}},1:{start:{line:11,column:25},end:{line:11,column:72}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:33,column:3}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:11,column:17},end:{line:11,column:18}},loc:{start:{line:11,column:25},end:{line:11,column:72}},line:11}},branchMap:{},s:{0:0,1:0},f:{0:0,1:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/LayerListGroup.tsx"],names:[],mappings:"AAcM,SAIE,KAJF;AAdN,OAAO,WAAW;AAClB,OAAO,eAAe;AAUtB,qBAAqB,uBAAuB,MAAM,UAA+B;AAAA,EAC/E,SAAS;AACP,WAAO,oBAAC,QAAG,WAAU,6BACnB;AAAA,MAAC;AAAA;AAAA,QAAI,WAAU;AAAA,QACb,eAAa,sBAAoB,KAAK,MAAM,aAAa;AAAA,QACzD,SAAS,QAAM,KAAK,MAAM,eAAe,CAAC,KAAK,MAAM,QAAQ;AAAA,QAE7D;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,iBAAe,KAAK,MAAM,eAAe;AAAA,cACzC,iBAAe,KAAK,MAAM;AAAA,cAEzB,eAAK,MAAM;AAAA;AAAA,UACd;AAAA,UACA,oBAAC,UAAK,WAAU,kBAAiB;AAAA,UACjC;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,EAAE,QAAQ,IAAI,OAAO,GAAG;AAAA,cAC/B,aAAa,KAAK,MAAM;AAAA;AAAA,UAC1B;AAAA;AAAA;AAAA,IACF,GACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"b04bfec534013c327fd210571832bbd2813a944a"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return zg=function(){return s},s}zg();class YAe extends bn.Component{render(){return zg().f[0]++,zg().s[0]++,N.jsx("li",{className:"maputnik-layer-list-group",children:N.jsxs("div",{className:"maputnik-layer-list-group-header","data-wd-key":"layer-list-group:"+this.props["data-wd-key"],onClick:n=>(zg().f[1]++,zg().s[1]++,this.props.onActiveToggle(!this.props.isActive)),children:[N.jsx("button",{className:"maputnik-layer-list-group-title","aria-controls":this.props["aria-controls"],"aria-expanded":this.props.isActive,children:this.props.title}),N.jsx("span",{className:"maputnik-space"}),N.jsx($Ae,{style:{height:14,width:14},isCollapsed:this.props.isActive})]})})}}function x_(){return x_=Object.assign?Object.assign.bind():function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},x_.apply(this,arguments)}function qAe(e){if(Array.isArray(e))return e}function VAe(e,n){var t=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(t!=null){var r,i,o,s,a=[],f=!0,g=!1;try{if(o=(t=t.call(e)).next,n===0){if(Object(t)!==t)return;f=!1}else for(;!(f=(r=o.call(t)).done)&&(a.push(r.value),a.length!==n);f=!0);}catch(x){g=!0,i=x}finally{try{if(!f&&t.return!=null&&(s=t.return(),Object(s)!==s))return}finally{if(g)throw i}}return a}}function xE(e,n){(n==null||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function Tj(e,n){if(e){if(typeof e=="string")return xE(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);if(t==="Object"&&e.constructor&&(t=e.constructor.name),t==="Map"||t==="Set")return Array.from(e);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return xE(e,n)}}function HAe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kj(e,n){return qAe(e)||VAe(e,n)||Tj(e,n)||HAe()}function Ey(e){"@babel/helpers - typeof";return Ey=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ey(e)}function ZAe(e,n){if(Ey(e)!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var r=t.call(e,n||"default");if(Ey(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(n==="string"?String:Number)(e)}function Pj(e){var n=ZAe(e,"string");return Ey(n)=="symbol"?n:String(n)}function pa(e,n,t){return n=Pj(n),n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function LM(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?Object(arguments[n]):{},r=Object.keys(t);typeof Object.getOwnPropertySymbols=="function"&&r.push.apply(r,Object.getOwnPropertySymbols(t).filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),r.forEach(function(i){pa(e,i,t[i])})}return e}function tb(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function _T(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Pj(r.key),r)}}function nb(e,n,t){return n&&_T(e.prototype,n),t&&_T(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ao(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function V7(e,n){if(n&&(Ey(n)==="object"||typeof n=="function"))return n;if(n!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ao(e)}function w_(e){return w_=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},w_(e)}function wE(e,n){return wE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},wE(e,n)}function H7(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),n&&wE(e,n)}var XAe=function(e,n,t,r,i,o,s,a){if(!e){var f;if(n===void 0)f=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var g=[t,r,i,o,s,a],x=0;f=new Error(n.replace(/%s/g,function(){return g[x++]})),f.name="Invariant Violation"}throw f.framesToPop=1,f}},JAe=XAe;const f1=ga(JAe);function ece(e){if(Array.isArray(e))return xE(e)}function tce(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function nce(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function rce(e){return ece(e)||tce(e)||Tj(e)||nce()}var ice=function(){function e(){tb(this,e),pa(this,"refs",{})}return nb(e,[{key:"add",value:function(t,r){this.refs[t]||(this.refs[t]=[]),this.refs[t].push(r)}},{key:"remove",value:function(t,r){var i=this.getIndex(t,r);i!==-1&&this.refs[t].splice(i,1)}},{key:"isActive",value:function(){return this.active}},{key:"getActive",value:function(){var t=this;return this.refs[this.active.collection].find(function(r){var i=r.node;return i.sortableInfo.index==t.active.index})}},{key:"getIndex",value:function(t,r){return this.refs[t].indexOf(r)}},{key:"getOrderedRefs",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.active.collection;return this.refs[t].sort(oce)}}]),e}();function oce(e,n){var t=e.node.sortableInfo.index,r=n.node.sortableInfo.index;return t-r}function Fj(e,n){return Object.keys(e).reduce(function(t,r){return n.indexOf(r)===-1&&(t[r]=e[r]),t},{})}var Ag={end:["touchend","touchcancel","mouseup"],move:["touchmove","mousemove"],start:["touchstart","mousedown"]},Dj=function(){if(typeof window>"u"||typeof document>"u")return"";var e=window.getComputedStyle(document.documentElement,"")||["-moz-hidden-iframe"],n=(Array.prototype.slice.call(e).join("").match(/-(moz|webkit|ms)-/)||e.OLink===""&&["","o"])[1];switch(n){case"ms":return"ms";default:return n&&n.length?n[0].toUpperCase()+n.substr(1):""}}();function Fx(e,n){Object.keys(n).forEach(function(t){e.style[t]=n[t]})}function Dx(e,n){e.style["".concat(Dj,"Transform")]=n==null?"":"translate3d(".concat(n.x,"px,").concat(n.y,"px,0)")}function zM(e,n){e.style["".concat(Dj,"TransitionDuration")]=n==null?"":"".concat(n,"ms")}function cC(e,n){for(;e;){if(n(e))return e;e=e.parentNode}return null}function bT(e,n,t){return Math.max(e,Math.min(t,n))}function jg(e){return e.substr(-2)==="px"?parseFloat(e):0}function ace(e){var n=window.getComputedStyle(e);return{bottom:jg(n.marginBottom),left:jg(n.marginLeft),right:jg(n.marginRight),top:jg(n.marginTop)}}function Z7(e,n){var t=n.displayName||n.name;return t?"".concat(e,"(").concat(t,")"):e}function jM(e,n){var t=e.getBoundingClientRect();return{top:t.top+n.top,left:t.left+n.left}}function $v(e){return e.touches&&e.touches.length?{x:e.touches[0].pageX,y:e.touches[0].pageY}:e.changedTouches&&e.changedTouches.length?{x:e.changedTouches[0].pageX,y:e.changedTouches[0].pageY}:{x:e.pageX,y:e.pageY}}function sce(e){return e.touches&&e.touches.length||e.changedTouches&&e.changedTouches.length}function C2(e,n){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{left:0,top:0};if(e){var r={left:t.left+e.offsetLeft,top:t.top+e.offsetTop};return e.parentNode===n?r:C2(e.parentNode,n,r)}}function lce(e,n,t){return e<t&&e>n?e-1:e>t&&e<n?e+1:e}function xT(e){var n=e.lockOffset,t=e.width,r=e.height,i=n,o=n,s="px";if(typeof n=="string"){var a=/^[+-]?\d*(?:\.\d*)?(px|%)$/.exec(n);f1(a!==null,'lockOffset value should be a number or a string of a number followed by "px" or "%". Given %s',n),i=parseFloat(n),o=parseFloat(n),s=a[1]}return f1(isFinite(i)&&isFinite(o),"lockOffset value should be a finite. Given %s",n),s==="%"&&(i=i*t/100,o=o*r/100),{x:i,y:o}}function uce(e){var n=e.height,t=e.width,r=e.lockOffset,i=Array.isArray(r)?r:[r,r];f1(i.length===2,"lockOffset prop of SortableContainer should be a single value or an array of exactly two values. Given %s",r);var o=Kj(i,2),s=o[0],a=o[1];return[xT({height:n,lockOffset:s,width:t}),xT({height:n,lockOffset:a,width:t})]}function Ace(e){var n=window.getComputedStyle(e),t=/(auto|scroll)/,r=["overflow","overflowX","overflowY"];return r.find(function(i){return t.test(n[i])})}function Uj(e){return e instanceof HTMLElement?Ace(e)?e:Uj(e.parentNode):null}function cce(e){var n=window.getComputedStyle(e);return n.display==="grid"?{x:jg(n.gridColumnGap),y:jg(n.gridRowGap)}:{x:0,y:0}}var _0={TAB:9,ESC:27,SPACE:32,LEFT:37,UP:38,RIGHT:39,DOWN:40},K0={Anchor:"A",Button:"BUTTON",Canvas:"CANVAS",Input:"INPUT",Option:"OPTION",Textarea:"TEXTAREA",Select:"SELECT"};function dce(e){var n="input, textarea, select, canvas, [contenteditable]",t=e.querySelectorAll(n),r=e.cloneNode(!0),i=rce(r.querySelectorAll(n));return i.forEach(function(o,s){if(o.type!=="file"&&(o.value=t[s].value),o.type==="radio"&&o.name&&(o.name="__sortableClone__".concat(o.name)),o.tagName===K0.Canvas&&t[s].width>0&&t[s].height>0){var a=o.getContext("2d");a.drawImage(t[s],0,0)}}),r}function hce(e){var n,t,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{withRef:!1};return t=n=function(i){H7(o,i);function o(){var s,a;tb(this,o);for(var f=arguments.length,g=new Array(f),x=0;x<f;x++)g[x]=arguments[x];return a=V7(this,(s=w_(o)).call.apply(s,[this].concat(g))),pa(Ao(Ao(a)),"wrappedInstance",kr.createRef()),a}return nb(o,[{key:"componentDidMount",value:function(){var a=Rm.findDOMNode(this);a.sortableHandle=!0}},{key:"getWrappedInstance",value:function(){return f1(r.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableHandle() call"),this.wrappedInstance.current}},{key:"render",value:function(){var a=r.withRef?this.wrappedInstance:null;return kr.createElement(e,x_({ref:a},this.props))}}]),o}(kr.Component),pa(n,"displayName",Z7("sortableHandle",e)),t}function wT(e){return e.sortableHandle!=null}var fce=function(){function e(n,t){tb(this,e),this.container=n,this.onScrollCallback=t}return nb(e,[{key:"clear",value:function(){this.interval!=null&&(clearInterval(this.interval),this.interval=null)}},{key:"update",value:function(t){var r=this,i=t.translate,o=t.minTranslate,s=t.maxTranslate,a=t.width,f=t.height,g={x:0,y:0},x={x:1,y:1},k={x:10,y:10},B=this.container,P=B.scrollTop,R=B.scrollLeft,H=B.scrollHeight,W=B.scrollWidth,$=B.clientHeight,q=B.clientWidth,oe=P===0,ne=H-P-$===0,ce=R===0,ae=W-R-q===0;i.y>=s.y-f/2&&!ne?(g.y=1,x.y=k.y*Math.abs((s.y-f/2-i.y)/f)):i.x>=s.x-a/2&&!ae?(g.x=1,x.x=k.x*Math.abs((s.x-a/2-i.x)/a)):i.y<=o.y+f/2&&!oe?(g.y=-1,x.y=k.y*Math.abs((i.y-f/2-o.y)/f)):i.x<=o.x+a/2&&!ce&&(g.x=-1,x.x=k.x*Math.abs((i.x-a/2-o.x)/a)),this.interval&&(this.clear(),this.isAutoScrolling=!1),(g.x!==0||g.y!==0)&&(this.interval=setInterval(function(){r.isAutoScrolling=!0;var ue={left:x.x*g.x,top:x.y*g.y};r.container.scrollTop+=ue.top,r.container.scrollLeft+=ue.left,r.onScrollCallback(ue)},5))}}]),e}();function pce(e){var n=e.node;return{height:n.offsetHeight,width:n.offsetWidth}}function mce(e){var n=[K0.Input,K0.Textarea,K0.Select,K0.Option,K0.Button];return!!(n.indexOf(e.target.tagName)!==-1||cC(e.target,function(t){return t.contentEditable==="true"}))}var Rj={axis:Pr.oneOf(["x","y","xy"]),contentWindow:Pr.any,disableAutoscroll:Pr.bool,distance:Pr.number,getContainer:Pr.func,getHelperDimensions:Pr.func,helperClass:Pr.string,helperContainer:Pr.oneOfType([Pr.func,typeof HTMLElement>"u"?Pr.any:Pr.instanceOf(HTMLElement)]),hideSortableGhost:Pr.bool,keyboardSortingTransitionDuration:Pr.number,lockAxis:Pr.string,lockOffset:Pr.oneOfType([Pr.number,Pr.string,Pr.arrayOf(Pr.oneOfType([Pr.number,Pr.string]))]),lockToContainerEdges:Pr.bool,onSortEnd:Pr.func,onSortMove:Pr.func,onSortOver:Pr.func,onSortStart:Pr.func,pressDelay:Pr.number,pressThreshold:Pr.number,keyCodes:Pr.shape({lift:Pr.arrayOf(Pr.number),drop:Pr.arrayOf(Pr.number),cancel:Pr.arrayOf(Pr.number),up:Pr.arrayOf(Pr.number),down:Pr.arrayOf(Pr.number)}),shouldCancelStart:Pr.func,transitionDuration:Pr.number,updateBeforeSortStart:Pr.func,useDragHandle:Pr.bool,useWindowAsScrollContainer:Pr.bool},Lj={lift:[_0.SPACE],drop:[_0.SPACE],cancel:[_0.ESC],up:[_0.UP,_0.LEFT],down:[_0.DOWN,_0.RIGHT]},gce={axis:"y",disableAutoscroll:!1,distance:0,getHelperDimensions:pce,hideSortableGhost:!0,lockOffset:"50%",lockToContainerEdges:!1,pressDelay:0,pressThreshold:5,keyCodes:Lj,shouldCancelStart:mce,transitionDuration:300,useWindowAsScrollContainer:!1},yce=Object.keys(Rj);function vce(e){f1(!(e.distance&&e.pressDelay),"Attempted to set both `pressDelay` and `distance` on SortableContainer, you may only use one or the other, not both at the same time.")}function Cce(e,n){try{var t=e()}catch(r){return n(!0,r)}return t&&t.then?t.then(n.bind(null,!1),n.bind(null,!0)):n(!1,value)}var zj=kr.createContext({manager:{}});function _ce(e){var n,t,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{withRef:!1};return t=n=function(i){H7(o,i);function o(s){var a;tb(this,o),a=V7(this,w_(o).call(this,s)),pa(Ao(Ao(a)),"state",{}),pa(Ao(Ao(a)),"handleStart",function(g){var x=a.props,k=x.distance,B=x.shouldCancelStart;if(!(g.button===2||B(g))){a.touched=!0,a.position=$v(g);var P=cC(g.target,function(oe){return oe.sortableInfo!=null});if(P&&P.sortableInfo&&a.nodeIsChild(P)&&!a.state.sorting){var R=a.props.useDragHandle,H=P.sortableInfo,W=H.index,$=H.collection,q=H.disabled;if(q||R&&!cC(g.target,wT))return;a.manager.active={collection:$,index:W},!sce(g)&&g.target.tagName===K0.Anchor&&g.preventDefault(),k||(a.props.pressDelay===0?a.handlePress(g):a.pressTimer=setTimeout(function(){return a.handlePress(g)},a.props.pressDelay))}}}),pa(Ao(Ao(a)),"nodeIsChild",function(g){return g.sortableInfo.manager===a.manager}),pa(Ao(Ao(a)),"handleMove",function(g){var x=a.props,k=x.distance,B=x.pressThreshold;if(!a.state.sorting&&a.touched&&!a._awaitingUpdateBeforeSortStart){var P=$v(g),R={x:a.position.x-P.x,y:a.position.y-P.y},H=Math.abs(R.x)+Math.abs(R.y);a.delta=R,!k&&(!B||H>=B)?(clearTimeout(a.cancelTimer),a.cancelTimer=setTimeout(a.cancel,0)):k&&H>=k&&a.manager.isActive()&&a.handlePress(g)}}),pa(Ao(Ao(a)),"handleEnd",function(){a.touched=!1,a.cancel()}),pa(Ao(Ao(a)),"cancel",function(){var g=a.props.distance,x=a.state.sorting;x||(g||clearTimeout(a.pressTimer),a.manager.active=null)}),pa(Ao(Ao(a)),"handlePress",function(g){try{var x=a.manager.getActive(),k=function(){if(x){var B=function(){var Ne=ce.sortableInfo.index,rt=ace(ce),ct=cce(a.container),Fe=a.scrollContainer.getBoundingClientRect(),He=H({index:Ne,node:ce,collection:ae});if(a.node=ce,a.margin=rt,a.gridGap=ct,a.width=He.width,a.height=He.height,a.marginOffset={x:a.margin.left+a.margin.right+a.gridGap.x,y:Math.max(a.margin.top,a.margin.bottom,a.gridGap.y)},a.boundingClientRect=ce.getBoundingClientRect(),a.containerBoundingRect=Fe,a.index=Ne,a.newIndex=Ne,a.axis={x:R.indexOf("x")>=0,y:R.indexOf("y")>=0},a.offsetEdge=C2(ce,a.container),ue?a.initialOffset=$v(LM({},g,{pageX:a.boundingClientRect.left,pageY:a.boundingClientRect.top})):a.initialOffset=$v(g),a.initialScroll={left:a.scrollContainer.scrollLeft,top:a.scrollContainer.scrollTop},a.initialWindowScroll={left:window.pageXOffset,top:window.pageYOffset},a.helper=a.helperContainer.appendChild(dce(ce)),Fx(a.helper,{boxSizing:"border-box",height:"".concat(a.height,"px"),left:"".concat(a.boundingClientRect.left-rt.left,"px"),pointerEvents:"none",position:"fixed",top:"".concat(a.boundingClientRect.top-rt.top,"px"),width:"".concat(a.width,"px")}),ue&&a.helper.focus(),$&&(a.sortableGhost=ce,Fx(ce,{opacity:0,visibility:"hidden"})),a.minTranslate={},a.maxTranslate={},ue){var Ce=ne?{top:0,left:0,width:a.contentWindow.innerWidth,height:a.contentWindow.innerHeight}:a.containerBoundingRect,jt=Ce.top,Ft=Ce.left,Jt=Ce.width,Nt=Ce.height,Ve=jt+Nt,nt=Ft+Jt;a.axis.x&&(a.minTranslate.x=Ft-a.boundingClientRect.left,a.maxTranslate.x=nt-(a.boundingClientRect.left+a.width)),a.axis.y&&(a.minTranslate.y=jt-a.boundingClientRect.top,a.maxTranslate.y=Ve-(a.boundingClientRect.top+a.height))}else a.axis.x&&(a.minTranslate.x=(ne?0:Fe.left)-a.boundingClientRect.left-a.width/2,a.maxTranslate.x=(ne?a.contentWindow.innerWidth:Fe.left+Fe.width)-a.boundingClientRect.left-a.width/2),a.axis.y&&(a.minTranslate.y=(ne?0:Fe.top)-a.boundingClientRect.top-a.height/2,a.maxTranslate.y=(ne?a.contentWindow.innerHeight:Fe.top+Fe.height)-a.boundingClientRect.top-a.height/2);W&&W.split(" ").forEach(function(Je){return a.helper.classList.add(Je)}),a.listenerNode=g.touches?g.target:a.contentWindow,ue?(a.listenerNode.addEventListener("wheel",a.handleKeyEnd,!0),a.listenerNode.addEventListener("mousedown",a.handleKeyEnd,!0),a.listenerNode.addEventListener("keydown",a.handleKeyDown)):(Ag.move.forEach(function(Je){return a.listenerNode.addEventListener(Je,a.handleSortMove,!1)}),Ag.end.forEach(function(Je){return a.listenerNode.addEventListener(Je,a.handleSortEnd,!1)})),a.setState({sorting:!0,sortingIndex:Ne}),oe&&oe({node:ce,index:Ne,collection:ae,isKeySorting:ue,nodes:a.manager.getOrderedRefs(),helper:a.helper},g),ue&&a.keyMove(0)},P=a.props,R=P.axis,H=P.getHelperDimensions,W=P.helperClass,$=P.hideSortableGhost,q=P.updateBeforeSortStart,oe=P.onSortStart,ne=P.useWindowAsScrollContainer,ce=x.node,ae=x.collection,ue=a.manager.isKeySorting,ye=function(){if(typeof q=="function"){a._awaitingUpdateBeforeSortStart=!0;var Re=Cce(function(){var Ne=ce.sortableInfo.index;return Promise.resolve(q({collection:ae,index:Ne,node:ce,isKeySorting:ue},g)).then(function(){})},function(Ne,rt){if(a._awaitingUpdateBeforeSortStart=!1,Ne)throw rt;return rt});if(Re&&Re.then)return Re.then(function(){})}}();return ye&&ye.then?ye.then(B):B(ye)}}();return Promise.resolve(k&&k.then?k.then(function(){}):void 0)}catch(B){return Promise.reject(B)}}),pa(Ao(Ao(a)),"handleSortMove",function(g){var x=a.props.onSortMove;typeof g.preventDefault=="function"&&g.cancelable&&g.preventDefault(),a.updateHelperPosition(g),a.animateNodes(),a.autoscroll(),x&&x(g)}),pa(Ao(Ao(a)),"handleSortEnd",function(g){var x=a.props,k=x.hideSortableGhost,B=x.onSortEnd,P=a.manager,R=P.active.collection,H=P.isKeySorting,W=a.manager.getOrderedRefs();a.listenerNode&&(H?(a.listenerNode.removeEventListener("wheel",a.handleKeyEnd,!0),a.listenerNode.removeEventListener("mousedown",a.handleKeyEnd,!0),a.listenerNode.removeEventListener("keydown",a.handleKeyDown)):(Ag.move.forEach(function(ce){return a.listenerNode.removeEventListener(ce,a.handleSortMove)}),Ag.end.forEach(function(ce){return a.listenerNode.removeEventListener(ce,a.handleSortEnd)}))),a.helper.parentNode.removeChild(a.helper),k&&a.sortableGhost&&Fx(a.sortableGhost,{opacity:"",visibility:""});for(var $=0,q=W.length;$<q;$++){var oe=W[$],ne=oe.node;oe.edgeOffset=null,oe.boundingClientRect=null,Dx(ne,null),zM(ne,null),oe.translate=null}a.autoScroller.clear(),a.manager.active=null,a.manager.isKeySorting=!1,a.setState({sorting:!1,sortingIndex:null}),typeof B=="function"&&B({collection:R,newIndex:a.newIndex,oldIndex:a.index,isKeySorting:H,nodes:W},g),a.touched=!1}),pa(Ao(Ao(a)),"autoscroll",function(){var g=a.props.disableAutoscroll,x=a.manager.isKeySorting;if(g){a.autoScroller.clear();return}if(x){var k=LM({},a.translate),B=0,P=0;a.axis.x&&(k.x=Math.min(a.maxTranslate.x,Math.max(a.minTranslate.x,a.translate.x)),B=a.translate.x-k.x),a.axis.y&&(k.y=Math.min(a.maxTranslate.y,Math.max(a.minTranslate.y,a.translate.y)),P=a.translate.y-k.y),a.translate=k,Dx(a.helper,a.translate),a.scrollContainer.scrollLeft+=B,a.scrollContainer.scrollTop+=P;return}a.autoScroller.update({height:a.height,maxTranslate:a.maxTranslate,minTranslate:a.minTranslate,translate:a.translate,width:a.width})}),pa(Ao(Ao(a)),"onAutoScroll",function(g){a.translate.x+=g.left,a.translate.y+=g.top,a.animateNodes()}),pa(Ao(Ao(a)),"handleKeyDown",function(g){var x=g.keyCode,k=a.props,B=k.shouldCancelStart,P=k.keyCodes,R=P===void 0?{}:P,H=LM({},Lj,R);a.manager.active&&!a.manager.isKeySorting||!a.manager.active&&(!H.lift.includes(x)||B(g)||!a.isValidSortingTarget(g))||(g.stopPropagation(),g.preventDefault(),H.lift.includes(x)&&!a.manager.active?a.keyLift(g):H.drop.includes(x)&&a.manager.active?a.keyDrop(g):H.cancel.includes(x)?(a.newIndex=a.manager.active.index,a.keyDrop(g)):H.up.includes(x)?a.keyMove(-1):H.down.includes(x)&&a.keyMove(1))}),pa(Ao(Ao(a)),"keyLift",function(g){var x=g.target,k=cC(x,function(H){return H.sortableInfo!=null}),B=k.sortableInfo,P=B.index,R=B.collection;a.initialFocusedNode=x,a.manager.isKeySorting=!0,a.manager.active={index:P,collection:R},a.handlePress(g)}),pa(Ao(Ao(a)),"keyMove",function(g){var x=a.manager.getOrderedRefs(),k=x[x.length-1].node.sortableInfo.index,B=a.newIndex+g,P=a.newIndex;if(!(B<0||B>k)){a.prevIndex=P,a.newIndex=B;var R=lce(a.newIndex,a.prevIndex,a.index),H=x.find(function(ue){var ye=ue.node;return ye.sortableInfo.index===R}),W=H.node,$=a.containerScrollDelta,q=H.boundingClientRect||jM(W,$),oe=H.translate||{x:0,y:0},ne={top:q.top+oe.y-$.top,left:q.left+oe.x-$.left},ce=P<B,ae={x:ce&&a.axis.x?W.offsetWidth-a.width:0,y:ce&&a.axis.y?W.offsetHeight-a.height:0};a.handleSortMove({pageX:ne.left+ae.x,pageY:ne.top+ae.y,ignoreTransition:g===0})}}),pa(Ao(Ao(a)),"keyDrop",function(g){a.handleSortEnd(g),a.initialFocusedNode&&a.initialFocusedNode.focus()}),pa(Ao(Ao(a)),"handleKeyEnd",function(g){a.manager.active&&a.keyDrop(g)}),pa(Ao(Ao(a)),"isValidSortingTarget",function(g){var x=a.props.useDragHandle,k=g.target,B=cC(k,function(P){return P.sortableInfo!=null});return B&&B.sortableInfo&&!B.sortableInfo.disabled&&(x?wT(k):k.sortableInfo)});var f=new ice;return vce(s),a.manager=f,a.wrappedInstance=kr.createRef(),a.sortableContextValue={manager:f},a.events={end:a.handleEnd,move:a.handleMove,start:a.handleStart},a}return nb(o,[{key:"componentDidMount",value:function(){var a=this,f=this.props.useWindowAsScrollContainer,g=this.getContainer();Promise.resolve(g).then(function(x){a.container=x,a.document=a.container.ownerDocument||document;var k=a.props.contentWindow||a.document.defaultView||window;a.contentWindow=typeof k=="function"?k():k,a.scrollContainer=f?a.document.scrollingElement||a.document.documentElement:Uj(a.container)||a.container,a.autoScroller=new fce(a.scrollContainer,a.onAutoScroll),Object.keys(a.events).forEach(function(B){return Ag[B].forEach(function(P){return a.container.addEventListener(P,a.events[B],!1)})}),a.container.addEventListener("keydown",a.handleKeyDown)})}},{key:"componentWillUnmount",value:function(){var a=this;this.helper&&this.helper.parentNode&&this.helper.parentNode.removeChild(this.helper),this.container&&(Object.keys(this.events).forEach(function(f){return Ag[f].forEach(function(g){return a.container.removeEventListener(g,a.events[f])})}),this.container.removeEventListener("keydown",this.handleKeyDown))}},{key:"updateHelperPosition",value:function(a){var f=this.props,g=f.lockAxis,x=f.lockOffset,k=f.lockToContainerEdges,B=f.transitionDuration,P=f.keyboardSortingTransitionDuration,R=P===void 0?B:P,H=this.manager.isKeySorting,W=a.ignoreTransition,$=$v(a),q={x:$.x-this.initialOffset.x,y:$.y-this.initialOffset.y};if(q.y-=window.pageYOffset-this.initialWindowScroll.top,q.x-=window.pageXOffset-this.initialWindowScroll.left,this.translate=q,k){var oe=uce({height:this.height,lockOffset:x,width:this.width}),ne=Kj(oe,2),ce=ne[0],ae=ne[1],ue={x:this.width/2-ce.x,y:this.height/2-ce.y},ye={x:this.width/2-ae.x,y:this.height/2-ae.y};q.x=bT(this.minTranslate.x+ue.x,this.maxTranslate.x-ye.x,q.x),q.y=bT(this.minTranslate.y+ue.y,this.maxTranslate.y-ye.y,q.y)}g==="x"?q.y=0:g==="y"&&(q.x=0),H&&R&&!W&&zM(this.helper,R),Dx(this.helper,q)}},{key:"animateNodes",value:function(){var a=this.props,f=a.transitionDuration,g=a.hideSortableGhost,x=a.onSortOver,k=this.containerScrollDelta,B=this.windowScrollDelta,P=this.manager.getOrderedRefs(),R={left:this.offsetEdge.left+this.translate.x+k.left,top:this.offsetEdge.top+this.translate.y+k.top},H=this.manager.isKeySorting,W=this.newIndex;this.newIndex=null;for(var $=0,q=P.length;$<q;$++){var oe=P[$].node,ne=oe.sortableInfo.index,ce=oe.offsetWidth,ae=oe.offsetHeight,ue={height:this.height>ae?ae/2:this.height/2,width:this.width>ce?ce/2:this.width/2},ye=H&&ne>this.index&&ne<=W,Re=H&&ne<this.index&&ne>=W,Ne={x:0,y:0},rt=P[$].edgeOffset;rt||(rt=C2(oe,this.container),P[$].edgeOffset=rt,H&&(P[$].boundingClientRect=jM(oe,k)));var ct=$<P.length-1&&P[$+1],Fe=$>0&&P[$-1];if(ct&&!ct.edgeOffset&&(ct.edgeOffset=C2(ct.node,this.container),H&&(ct.boundingClientRect=jM(ct.node,k))),ne===this.index){g&&(this.sortableGhost=oe,Fx(oe,{opacity:0,visibility:"hidden"}));continue}f&&zM(oe,f),this.axis.x?this.axis.y?Re||ne<this.index&&(R.left+B.left-ue.width<=rt.left&&R.top+B.top<=rt.top+ue.height||R.top+B.top+ue.height<=rt.top)?(Ne.x=this.width+this.marginOffset.x,rt.left+Ne.x>this.containerBoundingRect.width-ue.width&&ct&&(Ne.x=ct.edgeOffset.left-rt.left,Ne.y=ct.edgeOffset.top-rt.top),this.newIndex===null&&(this.newIndex=ne)):(ye||ne>this.index&&(R.left+B.left+ue.width>=rt.left&&R.top+B.top+ue.height>=rt.top||R.top+B.top+ue.height>=rt.top+ae))&&(Ne.x=-(this.width+this.marginOffset.x),rt.left+Ne.x<this.containerBoundingRect.left+ue.width&&Fe&&(Ne.x=Fe.edgeOffset.left-rt.left,Ne.y=Fe.edgeOffset.top-rt.top),this.newIndex=ne):ye||ne>this.index&&R.left+B.left+ue.width>=rt.left?(Ne.x=-(this.width+this.marginOffset.x),this.newIndex=ne):(Re||ne<this.index&&R.left+B.left<=rt.left+ue.width)&&(Ne.x=this.width+this.marginOffset.x,this.newIndex==null&&(this.newIndex=ne)):this.axis.y&&(ye||ne>this.index&&R.top+B.top+ue.height>=rt.top?(Ne.y=-(this.height+this.marginOffset.y),this.newIndex=ne):(Re||ne<this.index&&R.top+B.top<=rt.top+ue.height)&&(Ne.y=this.height+this.marginOffset.y,this.newIndex==null&&(this.newIndex=ne))),Dx(oe,Ne),P[$].translate=Ne}this.newIndex==null&&(this.newIndex=this.index),H&&(this.newIndex=W);var He=H?this.prevIndex:W;x&&this.newIndex!==He&&x({collection:this.manager.active.collection,index:this.index,newIndex:this.newIndex,oldIndex:He,isKeySorting:H,nodes:P,helper:this.helper})}},{key:"getWrappedInstance",value:function(){return f1(r.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableContainer() call"),this.wrappedInstance.current}},{key:"getContainer",value:function(){var a=this.props.getContainer;return typeof a!="function"?Rm.findDOMNode(this):a(r.withRef?this.getWrappedInstance():void 0)}},{key:"render",value:function(){var a=r.withRef?this.wrappedInstance:null;return kr.createElement(zj.Provider,{value:this.sortableContextValue},kr.createElement(e,x_({ref:a},Fj(this.props,yce))))}},{key:"helperContainer",get:function(){var a=this.props.helperContainer;return typeof a=="function"?a():this.props.helperContainer||this.document.body}},{key:"containerScrollDelta",get:function(){var a=this.props.useWindowAsScrollContainer;return a?{left:0,top:0}:{left:this.scrollContainer.scrollLeft-this.initialScroll.left,top:this.scrollContainer.scrollTop-this.initialScroll.top}}},{key:"windowScrollDelta",get:function(){return{left:this.contentWindow.pageXOffset-this.initialWindowScroll.left,top:this.contentWindow.pageYOffset-this.initialWindowScroll.top}}}]),o}(kr.Component),pa(n,"displayName",Z7("sortableList",e)),pa(n,"defaultProps",gce),pa(n,"propTypes",Rj),t}var jj={index:Pr.number.isRequired,collection:Pr.oneOfType([Pr.number,Pr.string]),disabled:Pr.bool},bce=Object.keys(jj);function xce(e){var n,t,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{withRef:!1};return t=n=function(i){H7(o,i);function o(){var s,a;tb(this,o);for(var f=arguments.length,g=new Array(f),x=0;x<f;x++)g[x]=arguments[x];return a=V7(this,(s=w_(o)).call.apply(s,[this].concat(g))),pa(Ao(Ao(a)),"wrappedInstance",kr.createRef()),a}return nb(o,[{key:"componentDidMount",value:function(){this.register()}},{key:"componentDidUpdate",value:function(a){this.node&&(a.index!==this.props.index&&(this.node.sortableInfo.index=this.props.index),a.disabled!==this.props.disabled&&(this.node.sortableInfo.disabled=this.props.disabled)),a.collection!==this.props.collection&&(this.unregister(a.collection),this.register())}},{key:"componentWillUnmount",value:function(){this.unregister()}},{key:"register",value:function(){var a=this.props,f=a.collection,g=a.disabled,x=a.index,k=Rm.findDOMNode(this);k.sortableInfo={collection:f,disabled:g,index:x,manager:this.context.manager},this.node=k,this.ref={node:k},this.context.manager.add(f,this.ref)}},{key:"unregister",value:function(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.props.collection;this.context.manager.remove(a,this.ref)}},{key:"getWrappedInstance",value:function(){return f1(r.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableElement() call"),this.wrappedInstance.current}},{key:"render",value:function(){var a=r.withRef?this.wrappedInstance:null;return kr.createElement(e,x_({ref:a},Fj(this.props,bce)))}}]),o}(kr.Component),pa(n,"displayName",Z7("sortableElement",e)),pa(n,"contextType",zj),pa(n,"propTypes",jj),pa(n,"defaultProps",{collection:0}),t}function fi(){var e="/home/runner/work/maputnik/maputnik/src/components/LayerListItem.tsx",n="63fcf32b678e8e84bae6e5adc5bc926b1550ab61",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/LayerListItem.tsx",statementMap:{0:{start:{line:8,column:23},end:{line:19,column:2}},1:{start:{line:9,column:2},end:{line:18,column:7}},2:{start:{line:22,column:4},end:{line:31,column:5}},3:{start:{line:24,column:8},end:{line:24,column:54}},4:{start:{line:26,column:8},end:{line:26,column:53}},5:{start:{line:28,column:8},end:{line:28,column:56}},6:{start:{line:30,column:8},end:{line:30,column:49}},7:{start:{line:34,column:51},end:{line:34,column:61}},8:{start:{line:35,column:25},end:{line:35,column:27}},9:{start:{line:36,column:4},end:{line:41,column:5}},10:{start:{line:37,column:6},end:{line:37,column:76}},11:{start:{line:38,column:6},end:{line:40,column:7}},12:{start:{line:39,column:8},end:{line:39,column:103}},13:{start:{line:42,column:4},end:{line:53,column:6}},14:{start:{line:57,column:24},end:{line:66,column:3}},15:{start:{line:67,column:29},end:{line:69,column:3}},16:{start:{line:71,column:4},end:{line:73,column:6}},17:{start:{line:76,column:29},end:{line:76,column:82}},18:{start:{line:77,column:4},end:{line:122,column:6}},19:{start:{line:81,column:25},end:{line:81,column:72}},20:{start:{line:97,column:31},end:{line:97,column:79}},21:{start:{line:106,column:31},end:{line:106,column:76}},22:{start:{line:116,column:31},end:{line:116,column:88}},23:{start:{line:125,column:30},end:{line:125,column:106}},24:{start:{line:125,column:73},end:{line:125,column:105}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:8,column:38},end:{line:8,column:39}},loc:{start:{line:8,column:49},end:{line:19,column:1}},line:8},1:{name:"(anonymous_1)",decl:{start:{line:21,column:2},end:{line:21,column:3}},loc:{start:{line:21,column:15},end:{line:32,column:3}},line:21},2:{name:"(anonymous_2)",decl:{start:{line:33,column:2},end:{line:33,column:3}},loc:{start:{line:33,column:11},end:{line:54,column:3}},line:33},3:{name:"(anonymous_3)",decl:{start:{line:60,column:17},end:{line:60,column:18}},loc:{start:{line:60,column:23},end:{line:61,column:5}},line:60},4:{name:"(anonymous_4)",decl:{start:{line:62,column:20},end:{line:62,column:21}},loc:{start:{line:62,column:26},end:{line:63,column:5}},line:62},5:{name:"(anonymous_5)",decl:{start:{line:64,column:29},end:{line:64,column:30}},loc:{start:{line:64,column:35},end:{line:65,column:5}},line:64},6:{name:"(anonymous_6)",decl:{start:{line:70,column:2},end:{line:70,column:3}},loc:{start:{line:70,column:20},end:{line:74,column:3}},line:70},7:{name:"(anonymous_7)",decl:{start:{line:75,column:2},end:{line:75,column:3}},loc:{start:{line:75,column:11},end:{line:123,column:3}},line:75},8:{name:"(anonymous_8)",decl:{start:{line:81,column:17},end:{line:81,column:18}},loc:{start:{line:81,column:25},end:{line:81,column:72}},line:81},9:{name:"(anonymous_9)",decl:{start:{line:97,column:23},end:{line:97,column:24}},loc:{start:{line:97,column:31},end:{line:97,column:79}},line:97},10:{name:"(anonymous_10)",decl:{start:{line:106,column:23},end:{line:106,column:24}},loc:{start:{line:106,column:31},end:{line:106,column:76}},line:106},11:{name:"(anonymous_11)",decl:{start:{line:116,column:23},end:{line:116,column:24}},loc:{start:{line:116,column:31},end:{line:116,column:88}},line:116},12:{name:"(anonymous_12)",decl:{start:{line:125,column:46},end:{line:125,column:47}},loc:{start:{line:125,column:73},end:{line:125,column:105}},line:125}},branchMap:{0:{loc:{start:{line:22,column:4},end:{line:31,column:5}},type:"switch",locations:[{start:{line:23,column:6},end:{line:24,column:54}},{start:{line:25,column:6},end:{line:26,column:53}},{start:{line:27,column:6},end:{line:28,column:56}},{start:{line:29,column:6},end:{line:30,column:49}}],line:22},1:{loc:{start:{line:36,column:4},end:{line:41,column:5}},type:"if",locations:[{start:{line:36,column:4},end:{line:41,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:36},2:{loc:{start:{line:38,column:6},end:{line:40,column:7}},type:"if",locations:[{start:{line:38,column:6},end:{line:40,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:38},3:{loc:{start:{line:76,column:29},end:{line:76,column:82}},type:"cond-expr",locations:[{start:{line:76,column:67},end:{line:76,column:73}},{start:{line:76,column:76},end:{line:76,column:82}}],line:76}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0},b:{0:[0,0,0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/LayerListItem.tsx"],names:[],mappings:"AAgBS,SACL,KADK;AAhBT,OAAO,WAAW;AAClB,OAAO,eAAe;AACtB,OAAO,gBAAgB;AAEvB,SAAQ,eAAe,cAAc,iBAAiB,gBAAe;AAErE,OAAO,eAAe;AACtB,SAAQ,iBAAiB,sBAAqB;AAQ9C,MAAM,iBAAiB,eAAe,CAAC,UAA+B;AACpE,SAAO,qBAAC,SAAI,WAAU,mCACpB;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,WAAU;AAAA,QACV,MAAM,MAAM;AAAA;AAAA,IACd;AAAA,IACA,oBAAC,YAAO,WAAU,+BACf,gBAAM,SACT;AAAA,KACF;AACF,CAAC;AAUD,MAAM,mBAAmB,MAAM,UAA2B;AAAA,EACxD,aAAa;AACX,YAAO,KAAK,MAAM,QAAQ;AAAA,MAC1B,KAAK;AAAa,eAAO,oBAAC,iBAAc;AAAA,MACxC,KAAK;AAAQ,eAAO,oBAAC,gBAAa;AAAA,MAClC,KAAK;AAAQ,eAAO,oBAAC,mBAAgB;AAAA,MACrC,KAAK;AAAU,eAAO,oBAAC,YAAS;AAAA,IAChC;AAAA,EACF;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,gBAAgB,mBAAkB,IAAI,KAAK;AAElD,QAAI,iBAAiB;AACrB,QAAI,gBAAgB;AAClB,uBAAiB,oCAAoC,cAAc;AAEnE,UAAI,oBAAoB;AACtB,0BAAkB,qCAAqC,cAAc,KAAK,kBAAkB;AAAA,MAC9F;AAAA,IACF;AAEA,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,UAAU;AAAA,QACV,OAAO,KAAK,MAAM;AAAA,QAClB,WAAW,mCAAmC,cAAc;AAAA,QAC5D,eAAa,KAAK,MAAM;AAAA,QACxB,SAAS,KAAK,MAAM;AAAA,QACpB,eAAY;AAAA,QAEX,eAAK,WAAW;AAAA;AAAA,IACnB;AAAA,EACF;AACF;AAgBA,MAAM,sBAAsB,MAAM,UAA8B;AAAA,EAC9D,OAAO,eAAe;AAAA,IACpB,YAAY;AAAA,IACZ,YAAY;AAAA,IACZ,aAAa,MAAM;AAAA,IAAC;AAAA,IACpB,gBAAgB,MAAM;AAAA,IAAC;AAAA,IACvB,yBAAyB,MAAM;AAAA,IAAC;AAAA,EAClC;AAAA,EAEA,OAAO,oBAAoB;AAAA,IACzB,eAAe,UAAU;AAAA,EAC3B;AAAA,EAEA,kBAAkB;AAChB,WAAO;AAAA,MACL,eAAe,EAAE,MAAM,GAAG;AAAA,IAC5B;AAAA,EACF;AAAA,EAEA,SAAS;AACP,UAAM,mBAAmB,KAAK,MAAM,eAAe,YAAY,SAAS;AAExE,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,IAAI,KAAK,MAAM;AAAA,QAEf,SAAS,QAAM,KAAK,MAAM,cAAc,KAAK,MAAM,UAAU;AAAA,QAC7D,eAAa,qBAAmB,KAAK,MAAM;AAAA,QAC3C,WAAW,WAAW;AAAA,UACpB,4BAA4B;AAAA,UAC5B,qCAAqC,KAAK,MAAM;AAAA,UAChD,CAAC,KAAK,MAAM,SAAU,GAAG;AAAA,QAC3B,CAAC;AAAA,QACD;AAAA,8BAAC,kBAAgB,GAAG,KAAK,OAAO;AAAA,UAChC,oBAAC,UAAK,OAAO,EAAC,UAAU,EAAC,GAAG;AAAA,UAC5B;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,qBAAmB,KAAK,MAAM,UAAQ;AAAA,cAC7C,QAAQ;AAAA,cACR,gBAAe;AAAA,cACf,SAAS,QAAM,KAAK,MAAM,eAAgB,KAAK,MAAM,UAAU;AAAA;AAAA,UACjE;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,qBAAmB,KAAK,MAAM,UAAQ;AAAA,cAC7C,QAAQ;AAAA,cACR,gBAAe;AAAA,cACf,SAAS,QAAM,KAAK,MAAM,YAAa,KAAK,MAAM,UAAU;AAAA;AAAA,UAC9D;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,qBAAmB,KAAK,MAAM,UAAQ;AAAA,cAC7C,QAAQ;AAAA,cACR,gBAAe;AAAA,cACf,oBAAoB;AAAA,cACpB,SAAS,QAAM,KAAK,MAAM,wBAAyB,KAAK,MAAM,UAAU;AAAA;AAAA,UAC1E;AAAA;AAAA;AAAA,MA5BK,KAAK,MAAM;AAAA,IA6BlB;AAAA,EACF;AACF;AAEA,MAAM,wBAAwB,gBAAgB,CAAC,UAA8B,oBAAC,iBAAe,GAAG,OAAO,CAAE;AAEzG,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"63fcf32b678e8e84bae6e5adc5bc926b1550ab61"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return fi=function(){return s},s}fi();const wce=(fi().s[0]++,hce(e=>(fi().f[0]++,fi().s[1]++,N.jsxs("div",{className:"maputnik-layer-list-item-handle",children:[N.jsx(VR,{className:"layer-handle__icon",type:e.layerType}),N.jsx("button",{className:"maputnik-layer-list-item-id",children:e.layerId})]}))));class WM extends bn.Component{renderIcon(){switch(fi().f[1]++,fi().s[2]++,this.props.action){case"duplicate":return fi().b[0][0]++,fi().s[3]++,N.jsx(vJ,{});case"show":return fi().b[0][1]++,fi().s[4]++,N.jsx(yJ,{});case"hide":return fi().b[0][2]++,fi().s[5]++,N.jsx(gJ,{});case"delete":return fi().b[0][3]++,fi().s[6]++,N.jsx(Ly,{})}}render(){fi().f[2]++;const{classBlockName:n,classBlockModifier:t}=(fi().s[7]++,this.props);let r=(fi().s[8]++,"");return fi().s[9]++,n?(fi().b[1][0]++,fi().s[10]++,r=`maputnik-layer-list-icon-action__${n}`,fi().s[11]++,t?(fi().b[2][0]++,fi().s[12]++,r+=` maputnik-layer-list-icon-action__${n}--${t}`):fi().b[2][1]++):fi().b[1][1]++,fi().s[13]++,N.jsx("button",{tabIndex:-1,title:this.props.action,className:`maputnik-layer-list-icon-action ${r}`,"data-wd-key":this.props.wdKey,onClick:this.props.onClick,"aria-hidden":"true",children:this.renderIcon()})}}class ME extends bn.Component{getChildContext(){return fi().f[6]++,fi().s[16]++,{reactIconBase:{size:14}}}render(){fi().f[7]++;const n=(fi().s[17]++,this.props.visibility==="visible"?(fi().b[3][0]++,"show"):(fi().b[3][1]++,"hide"));return fi().s[18]++,N.jsxs("li",{id:this.props.id,onClick:t=>(fi().f[8]++,fi().s[19]++,this.props.onLayerSelect(this.props.layerIndex)),"data-wd-key":"layer-list-item:"+this.props.layerId,className:Af({"maputnik-layer-list-item":!0,"maputnik-layer-list-item-selected":this.props.isSelected,[this.props.className]:!0}),children:[N.jsx(wce,{...this.props}),N.jsx("span",{style:{flexGrow:1}}),N.jsx(WM,{wdKey:"layer-list-item:"+this.props.layerId+":delete",action:"delete",classBlockName:"delete",onClick:t=>(fi().f[9]++,fi().s[20]++,this.props.onLayerDestroy(this.props.layerIndex))}),N.jsx(WM,{wdKey:"layer-list-item:"+this.props.layerId+":copy",action:"duplicate",classBlockName:"duplicate",onClick:t=>(fi().f[10]++,fi().s[21]++,this.props.onLayerCopy(this.props.layerIndex))}),N.jsx(WM,{wdKey:"layer-list-item:"+this.props.layerId+":toggle-visibility",action:n,classBlockName:"visibility",classBlockModifier:n,onClick:t=>(fi().f[11]++,fi().s[22]++,this.props.onLayerVisibilityToggle(this.props.layerIndex))})]},this.props.layerId)}}nn(ME,"defaultProps",(fi().s[14]++,{isSelected:!1,visibility:"visible",onLayerCopy:()=>{fi().f[3]++},onLayerDestroy:()=>{fi().f[4]++},onLayerVisibilityToggle:()=>{fi().f[5]++}})),nn(ME,"childContextTypes",(fi().s[15]++,{reactIconBase:Pr.object}));const Mce=(fi().s[23]++,xce(e=>(fi().f[12]++,fi().s[24]++,N.jsx(ME,{...e}))));function Y3(){var e="/home/runner/work/maputnik/maputnik/src/components/InputButton.tsx",n="522bfc6b8aacbfd03b55d947af2897dc69beb570",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputButton.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:20,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:21,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputButton.tsx"],names:[],mappings:"AAkBW;AAlBX,OAAO,WAAW;AAClB,OAAO,gBAAgB;AAevB,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,IAAI,KAAK,MAAM;AAAA,QACf,OAAO,KAAK,MAAM;AAAA,QAClB,MAAM,KAAK,MAAM;AAAA,QACjB,SAAS,KAAK,MAAM;AAAA,QACpB,UAAU,KAAK,MAAM;AAAA,QACrB,cAAY,KAAK,MAAM,YAAY;AAAA,QACnC,WAAW,WAAW,mBAAmB,KAAK,MAAM,SAAS;AAAA,QAC7D,eAAa,KAAK,MAAM,aAAa;AAAA,QACrC,OAAO,KAAK,MAAM;AAAA,QAEjB,eAAK,MAAM;AAAA;AAAA,IACd;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"522bfc6b8aacbfd03b55d947af2897dc69beb570"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Y3=function(){return s},s}Y3();class Ka extends bn.Component{render(){return Y3().f[0]++,Y3().s[0]++,N.jsx("button",{id:this.props.id,title:this.props.title,type:this.props.type,onClick:this.props.onClick,disabled:this.props.disabled,"aria-label":this.props["aria-label"],className:Af("maputnik-button",this.props.className),"data-wd-key":this.props["data-wd-key"],style:this.props.style,children:this.props.children})}}/*!
|
||
* tabbable 5.3.3
|
||
* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
|
||
*/var Wj=["input","select","textarea","a[href]","button","[tabindex]:not(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"],q3=Wj.join(","),Nj=typeof Element>"u",p1=Nj?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,SE=!Nj&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},Gj=function(n,t,r){var i=Array.prototype.slice.apply(n.querySelectorAll(q3));return t&&p1.call(n,q3)&&i.unshift(n),i=i.filter(r),i},Qj=function e(n,t,r){for(var i=[],o=Array.from(n);o.length;){var s=o.shift();if(s.tagName==="SLOT"){var a=s.assignedElements(),f=a.length?a:s.children,g=e(f,!0,r);r.flatten?i.push.apply(i,g):i.push({scope:s,candidates:g})}else{var x=p1.call(s,q3);x&&r.filter(s)&&(t||!n.includes(s))&&i.push(s);var k=s.shadowRoot||typeof r.getShadowRoot=="function"&&r.getShadowRoot(s),B=!r.shadowRootFilter||r.shadowRootFilter(s);if(k&&B){var P=e(k===!0?s.children:k.children,!0,r);r.flatten?i.push.apply(i,P):i.push({scope:s,candidates:P})}else o.unshift.apply(o,s.children)}}return i},$j=function(n,t){return n.tabIndex<0&&(t||/^(AUDIO|VIDEO|DETAILS)$/.test(n.tagName)||n.isContentEditable)&&isNaN(parseInt(n.getAttribute("tabindex"),10))?0:n.tabIndex},Sce=function(n,t){return n.tabIndex===t.tabIndex?n.documentOrder-t.documentOrder:n.tabIndex-t.tabIndex},Yj=function(n){return n.tagName==="INPUT"},Ece=function(n){return Yj(n)&&n.type==="hidden"},Oce=function(n){var t=n.tagName==="DETAILS"&&Array.prototype.slice.apply(n.children).some(function(r){return r.tagName==="SUMMARY"});return t},Bce=function(n,t){for(var r=0;r<n.length;r++)if(n[r].checked&&n[r].form===t)return n[r]},kce=function(n){if(!n.name)return!0;var t=n.form||SE(n),r=function(a){return t.querySelectorAll('input[type="radio"][name="'+a+'"]')},i;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")i=r(window.CSS.escape(n.name));else try{i=r(n.name)}catch(s){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",s.message),!1}var o=Bce(i,n.form);return!o||o===n},Ice=function(n){return Yj(n)&&n.type==="radio"},Tce=function(n){return Ice(n)&&!kce(n)},MT=function(n){var t=n.getBoundingClientRect(),r=t.width,i=t.height;return r===0&&i===0},Kce=function(n,t){var r=t.displayCheck,i=t.getShadowRoot;if(getComputedStyle(n).visibility==="hidden")return!0;var o=p1.call(n,"details>summary:first-of-type"),s=o?n.parentElement:n;if(p1.call(s,"details:not([open]) *"))return!0;var a=SE(n).host,f=(a==null?void 0:a.ownerDocument.contains(a))||n.ownerDocument.contains(n);if(!r||r==="full"){if(typeof i=="function"){for(var g=n;n;){var x=n.parentElement,k=SE(n);if(x&&!x.shadowRoot&&i(x)===!0)return MT(n);n.assignedSlot?n=n.assignedSlot:!x&&k!==n.ownerDocument?n=k.host:n=x}n=g}if(f)return!n.getClientRects().length}else if(r==="non-zero-area")return MT(n);return!1},Pce=function(n){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(n.tagName))for(var t=n.parentElement;t;){if(t.tagName==="FIELDSET"&&t.disabled){for(var r=0;r<t.children.length;r++){var i=t.children.item(r);if(i.tagName==="LEGEND")return p1.call(t,"fieldset[disabled] *")?!0:!i.contains(n)}return!0}t=t.parentElement}return!1},V3=function(n,t){return!(t.disabled||Ece(t)||Kce(t,n)||Oce(t)||Pce(t))},EE=function(n,t){return!(Tce(t)||$j(t)<0||!V3(n,t))},Fce=function(n){var t=parseInt(n.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},Dce=function e(n){var t=[],r=[];return n.forEach(function(i,o){var s=!!i.scope,a=s?i.scope:i,f=$j(a,s),g=s?e(i.candidates):a;f===0?s?t.push.apply(t,g):t.push(a):r.push({documentOrder:o,tabIndex:f,item:i,isScope:s,content:g})}),r.sort(Sce).reduce(function(i,o){return o.isScope?i.push.apply(i,o.content):i.push(o.content),i},[]).concat(t)},qj=function(n,t){t=t||{};var r;return t.getShadowRoot?r=Qj([n],t.includeContainer,{filter:EE.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:Fce}):r=Gj(n,t.includeContainer,EE.bind(null,t)),Dce(r)},Vj=function(n,t){t=t||{};var r;return t.getShadowRoot?r=Qj([n],t.includeContainer,{filter:V3.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):r=Gj(n,t.includeContainer,V3.bind(null,t)),r},dC=function(n,t){if(t=t||{},!n)throw new Error("No node provided");return p1.call(n,q3)===!1?!1:EE(t,n)},Uce=Wj.concat("iframe").join(","),_2=function(n,t){if(t=t||{},!n)throw new Error("No node provided");return p1.call(n,Uce)===!1?!1:V3(t,n)};const Rce=Object.freeze(Object.defineProperty({__proto__:null,focusable:Vj,isFocusable:_2,isTabbable:dC,tabbable:qj},Symbol.toStringTag,{value:"Module"}));/*!
|
||
* focus-trap 6.9.4
|
||
* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
|
||
*/function ST(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),t.push.apply(t,r)}return t}function ET(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?ST(Object(t),!0).forEach(function(r){Lce(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):ST(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function Lce(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var OT=function(){var e=[];return{activateTrap:function(t){if(e.length>0){var r=e[e.length-1];r!==t&&r.pause()}var i=e.indexOf(t);i===-1||e.splice(i,1),e.push(t)},deactivateTrap:function(t){var r=e.indexOf(t);r!==-1&&e.splice(r,1),e.length>0&&e[e.length-1].unpause()}}}(),zce=function(n){return n.tagName&&n.tagName.toLowerCase()==="input"&&typeof n.select=="function"},jce=function(n){return n.key==="Escape"||n.key==="Esc"||n.keyCode===27},Wce=function(n){return n.key==="Tab"||n.keyCode===9},BT=function(n){return setTimeout(n,0)},kT=function(n,t){var r=-1;return n.every(function(i,o){return t(i)?(r=o,!1):!0}),r},Yv=function(n){for(var t=arguments.length,r=new Array(t>1?t-1:0),i=1;i<t;i++)r[i-1]=arguments[i];return typeof n=="function"?n.apply(void 0,r):n},Ux=function(n){return n.target.shadowRoot&&typeof n.composedPath=="function"?n.composedPath()[0]:n.target},Nce=function(n,t){var r=(t==null?void 0:t.document)||document,i=ET({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0},t),o={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0},s,a=function(ae,ue,ye){return ae&&ae[ue]!==void 0?ae[ue]:i[ye||ue]},f=function(ae){return o.containerGroups.findIndex(function(ue){var ye=ue.container,Re=ue.tabbableNodes;return ye.contains(ae)||Re.find(function(Ne){return Ne===ae})})},g=function(ae){var ue=i[ae];if(typeof ue=="function"){for(var ye=arguments.length,Re=new Array(ye>1?ye-1:0),Ne=1;Ne<ye;Ne++)Re[Ne-1]=arguments[Ne];ue=ue.apply(void 0,Re)}if(ue===!0&&(ue=void 0),!ue){if(ue===void 0||ue===!1)return ue;throw new Error("`".concat(ae,"` was specified but was not a node, or did not return a node"))}var rt=ue;if(typeof ue=="string"&&(rt=r.querySelector(ue),!rt))throw new Error("`".concat(ae,"` as selector refers to no known node"));return rt},x=function(){var ae=g("initialFocus");if(ae===!1)return!1;if(ae===void 0)if(f(r.activeElement)>=0)ae=r.activeElement;else{var ue=o.tabbableGroups[0],ye=ue&&ue.firstTabbableNode;ae=ye||g("fallbackFocus")}if(!ae)throw new Error("Your focus-trap needs to have at least one focusable element");return ae},k=function(){if(o.containerGroups=o.containers.map(function(ae){var ue=qj(ae,i.tabbableOptions),ye=Vj(ae,i.tabbableOptions);return{container:ae,tabbableNodes:ue,focusableNodes:ye,firstTabbableNode:ue.length>0?ue[0]:null,lastTabbableNode:ue.length>0?ue[ue.length-1]:null,nextTabbableNode:function(Ne){var rt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,ct=ye.findIndex(function(Fe){return Fe===Ne});if(!(ct<0))return rt?ye.slice(ct+1).find(function(Fe){return dC(Fe,i.tabbableOptions)}):ye.slice(0,ct).reverse().find(function(Fe){return dC(Fe,i.tabbableOptions)})}}}),o.tabbableGroups=o.containerGroups.filter(function(ae){return ae.tabbableNodes.length>0}),o.tabbableGroups.length<=0&&!g("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},B=function ce(ae){if(ae!==!1&&ae!==r.activeElement){if(!ae||!ae.focus){ce(x());return}ae.focus({preventScroll:!!i.preventScroll}),o.mostRecentlyFocusedNode=ae,zce(ae)&&ae.select()}},P=function(ae){var ue=g("setReturnFocus",ae);return ue||(ue===!1?!1:ae)},R=function(ae){var ue=Ux(ae);if(!(f(ue)>=0)){if(Yv(i.clickOutsideDeactivates,ae)){s.deactivate({returnFocus:i.returnFocusOnDeactivate&&!_2(ue,i.tabbableOptions)});return}Yv(i.allowOutsideClick,ae)||ae.preventDefault()}},H=function(ae){var ue=Ux(ae),ye=f(ue)>=0;ye||ue instanceof Document?ye&&(o.mostRecentlyFocusedNode=ue):(ae.stopImmediatePropagation(),B(o.mostRecentlyFocusedNode||x()))},W=function(ae){var ue=Ux(ae);k();var ye=null;if(o.tabbableGroups.length>0){var Re=f(ue),Ne=Re>=0?o.containerGroups[Re]:void 0;if(Re<0)ae.shiftKey?ye=o.tabbableGroups[o.tabbableGroups.length-1].lastTabbableNode:ye=o.tabbableGroups[0].firstTabbableNode;else if(ae.shiftKey){var rt=kT(o.tabbableGroups,function(Ft){var Jt=Ft.firstTabbableNode;return ue===Jt});if(rt<0&&(Ne.container===ue||_2(ue,i.tabbableOptions)&&!dC(ue,i.tabbableOptions)&&!Ne.nextTabbableNode(ue,!1))&&(rt=Re),rt>=0){var ct=rt===0?o.tabbableGroups.length-1:rt-1,Fe=o.tabbableGroups[ct];ye=Fe.lastTabbableNode}}else{var He=kT(o.tabbableGroups,function(Ft){var Jt=Ft.lastTabbableNode;return ue===Jt});if(He<0&&(Ne.container===ue||_2(ue,i.tabbableOptions)&&!dC(ue,i.tabbableOptions)&&!Ne.nextTabbableNode(ue))&&(He=Re),He>=0){var Ce=He===o.tabbableGroups.length-1?0:He+1,jt=o.tabbableGroups[Ce];ye=jt.firstTabbableNode}}}else ye=g("fallbackFocus");ye&&(ae.preventDefault(),B(ye))},$=function(ae){if(jce(ae)&&Yv(i.escapeDeactivates,ae)!==!1){ae.preventDefault(),s.deactivate();return}if(Wce(ae)){W(ae);return}},q=function(ae){var ue=Ux(ae);f(ue)>=0||Yv(i.clickOutsideDeactivates,ae)||Yv(i.allowOutsideClick,ae)||(ae.preventDefault(),ae.stopImmediatePropagation())},oe=function(){if(o.active)return OT.activateTrap(s),o.delayInitialFocusTimer=i.delayInitialFocus?BT(function(){B(x())}):B(x()),r.addEventListener("focusin",H,!0),r.addEventListener("mousedown",R,{capture:!0,passive:!1}),r.addEventListener("touchstart",R,{capture:!0,passive:!1}),r.addEventListener("click",q,{capture:!0,passive:!1}),r.addEventListener("keydown",$,{capture:!0,passive:!1}),s},ne=function(){if(o.active)return r.removeEventListener("focusin",H,!0),r.removeEventListener("mousedown",R,!0),r.removeEventListener("touchstart",R,!0),r.removeEventListener("click",q,!0),r.removeEventListener("keydown",$,!0),s};return s={get active(){return o.active},get paused(){return o.paused},activate:function(ae){if(o.active)return this;var ue=a(ae,"onActivate"),ye=a(ae,"onPostActivate"),Re=a(ae,"checkCanFocusTrap");Re||k(),o.active=!0,o.paused=!1,o.nodeFocusedBeforeActivation=r.activeElement,ue&&ue();var Ne=function(){Re&&k(),oe(),ye&&ye()};return Re?(Re(o.containers.concat()).then(Ne,Ne),this):(Ne(),this)},deactivate:function(ae){if(!o.active)return this;var ue=ET({onDeactivate:i.onDeactivate,onPostDeactivate:i.onPostDeactivate,checkCanReturnFocus:i.checkCanReturnFocus},ae);clearTimeout(o.delayInitialFocusTimer),o.delayInitialFocusTimer=void 0,ne(),o.active=!1,o.paused=!1,OT.deactivateTrap(s);var ye=a(ue,"onDeactivate"),Re=a(ue,"onPostDeactivate"),Ne=a(ue,"checkCanReturnFocus"),rt=a(ue,"returnFocus","returnFocusOnDeactivate");ye&&ye();var ct=function(){BT(function(){rt&&B(P(o.nodeFocusedBeforeActivation)),Re&&Re()})};return rt&&Ne?(Ne(P(o.nodeFocusedBeforeActivation)).then(ct,ct),this):(ct(),this)},pause:function(){return o.paused||!o.active?this:(o.paused=!0,ne(),this)},unpause:function(){return!o.paused||!o.active?this:(o.paused=!1,k(),oe(),this)},updateContainerElements:function(ae){var ue=[].concat(ae).filter(Boolean);return o.containers=ue.map(function(ye){return typeof ye=="string"?r.querySelector(ye):ye}),o.active&&k(),this}},s.updateContainerElements(n),s};const Gce=Object.freeze(Object.defineProperty({__proto__:null,createFocusTrap:Nce},Symbol.toStringTag,{value:"Module"})),Qce=fO(Gce),$ce=fO(Rce);function OE(e){"@babel/helpers - typeof";return OE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},OE(e)}function Yce(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function IT(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function qce(e,n,t){return n&&IT(e.prototype,n),t&&IT(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Vce(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),n&&BE(e,n)}function BE(e,n){return BE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},BE(e,n)}function Hce(e){var n=Xce();return function(){var r=H3(e),i;if(n){var o=H3(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Zce(this,i)}}function Zce(e,n){if(n&&(OE(n)==="object"||typeof n=="function"))return n;if(n!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return hC(e)}function hC(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Xce(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function H3(e){return H3=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},H3(e)}function Jce(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var Rx=kr,ede=Rm,Fi=ph,tde=Qce,nde=tde.createFocusTrap,rde=$ce,ide=rde.isFocusable,X7=function(e){Vce(t,e);var n=Hce(t);function t(r){var i;Yce(this,t),i=n.call(this,r),Jce(hC(i),"getNodeForOption",function(a){var f,g=(f=this.internalOptions[a])!==null&&f!==void 0?f:this.originalOptions[a];if(typeof g=="function"){for(var x=arguments.length,k=new Array(x>1?x-1:0),B=1;B<x;B++)k[B-1]=arguments[B];g=g.apply(void 0,k)}if(g===!0&&(g=void 0),!g){if(g===void 0||g===!1)return g;throw new Error("`".concat(a,"` was specified but was not a node, or did not return a node"))}var P=g;if(typeof g=="string"){var R;if(P=(R=this.getDocument())===null||R===void 0?void 0:R.querySelector(g),!P)throw new Error("`".concat(a,"` as selector refers to no known node"))}return P}),i.handleDeactivate=i.handleDeactivate.bind(hC(i)),i.handlePostDeactivate=i.handlePostDeactivate.bind(hC(i)),i.handleClickOutsideDeactivates=i.handleClickOutsideDeactivates.bind(hC(i)),i.internalOptions={returnFocusOnDeactivate:!1,checkCanReturnFocus:null,onDeactivate:i.handleDeactivate,onPostDeactivate:i.handlePostDeactivate,clickOutsideDeactivates:i.handleClickOutsideDeactivates},i.originalOptions={returnFocusOnDeactivate:!0,onDeactivate:null,onPostDeactivate:null,checkCanReturnFocus:null,clickOutsideDeactivates:!1};var o=r.focusTrapOptions;for(var s in o)if(Object.prototype.hasOwnProperty.call(o,s)){if(s==="returnFocusOnDeactivate"||s==="onDeactivate"||s==="onPostDeactivate"||s==="checkCanReturnFocus"||s==="clickOutsideDeactivates"){i.originalOptions[s]=o[s];continue}i.internalOptions[s]=o[s]}return i.outsideClick=null,i.focusTrapElements=r.containerElements||[],i.updatePreviousElement(),i}return qce(t,[{key:"getDocument",value:function(){return this.props.focusTrapOptions.document||(typeof document<"u"?document:void 0)}},{key:"getReturnFocusNode",value:function(){var i=this.getNodeForOption("setReturnFocus",this.previouslyFocusedElement);return i||(i===!1?!1:this.previouslyFocusedElement)}},{key:"updatePreviousElement",value:function(){var i=this.getDocument();i&&(this.previouslyFocusedElement=i.activeElement)}},{key:"deactivateTrap",value:function(){!this.focusTrap||!this.focusTrap.active||this.focusTrap.deactivate({returnFocus:!1,checkCanReturnFocus:null,onDeactivate:this.originalOptions.onDeactivate})}},{key:"handleClickOutsideDeactivates",value:function(i){var o=typeof this.originalOptions.clickOutsideDeactivates=="function"?this.originalOptions.clickOutsideDeactivates.call(null,i):this.originalOptions.clickOutsideDeactivates;return o&&(this.outsideClick={target:i.target,allowDeactivation:o}),o}},{key:"handleDeactivate",value:function(){this.originalOptions.onDeactivate&&this.originalOptions.onDeactivate.call(null),this.deactivateTrap()}},{key:"handlePostDeactivate",value:function(){var i=this,o=function(){var a=i.getReturnFocusNode(),f=!!(i.originalOptions.returnFocusOnDeactivate&&a!==null&&a!==void 0&&a.focus&&(!i.outsideClick||i.outsideClick.allowDeactivation&&!ide(i.outsideClick.target,i.internalOptions.tabbableOptions))),g=i.internalOptions.preventScroll,x=g===void 0?!1:g;f&&a.focus({preventScroll:x}),i.originalOptions.onPostDeactivate&&i.originalOptions.onPostDeactivate.call(null),i.outsideClick=null};this.originalOptions.checkCanReturnFocus?this.originalOptions.checkCanReturnFocus.call(null,this.getReturnFocusNode()).then(o,o):o()}},{key:"setupFocusTrap",value:function(){if(!this.focusTrap){var i=this.focusTrapElements.map(ede.findDOMNode),o=i.some(Boolean);o&&(this.focusTrap=this.props._createFocusTrap(i,this.internalOptions),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause())}}},{key:"componentDidMount",value:function(){this.props.active&&this.setupFocusTrap()}},{key:"componentDidUpdate",value:function(i){if(this.focusTrap){i.containerElements!==this.props.containerElements&&this.focusTrap.updateContainerElements(this.props.containerElements);var o=!i.active&&this.props.active,s=i.active&&!this.props.active,a=!i.paused&&this.props.paused,f=i.paused&&!this.props.paused;if(o&&(this.updatePreviousElement(),this.focusTrap.activate()),s){this.deactivateTrap();return}a&&this.focusTrap.pause(),f&&this.focusTrap.unpause()}else i.containerElements!==this.props.containerElements&&(this.focusTrapElements=this.props.containerElements),this.props.active&&(this.updatePreviousElement(),this.setupFocusTrap())}},{key:"componentWillUnmount",value:function(){this.deactivateTrap()}},{key:"render",value:function(){var i=this,o=this.props.children?Rx.Children.only(this.props.children):void 0;if(o){if(o.type&&o.type===Rx.Fragment)throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");var s=function(g){var x=i.props.containerElements;o&&(typeof o.ref=="function"?o.ref(g):o.ref&&(o.ref.current=g)),i.focusTrapElements=x||[g]},a=Rx.cloneElement(o,{ref:s});return a}return null}}]),t}(Rx.Component),qv=typeof Element>"u"?Function:Element;X7.propTypes={active:Fi.bool,paused:Fi.bool,focusTrapOptions:Fi.shape({document:Fi.object,onActivate:Fi.func,onPostActivate:Fi.func,checkCanFocusTrap:Fi.func,onDeactivate:Fi.func,onPostDeactivate:Fi.func,checkCanReturnFocus:Fi.func,initialFocus:Fi.oneOfType([Fi.instanceOf(qv),Fi.string,Fi.bool,Fi.func]),fallbackFocus:Fi.oneOfType([Fi.instanceOf(qv),Fi.string,Fi.func]),escapeDeactivates:Fi.oneOfType([Fi.bool,Fi.func]),clickOutsideDeactivates:Fi.oneOfType([Fi.bool,Fi.func]),returnFocusOnDeactivate:Fi.bool,setReturnFocus:Fi.oneOfType([Fi.instanceOf(qv),Fi.string,Fi.bool,Fi.func]),allowOutsideClick:Fi.oneOfType([Fi.bool,Fi.func]),preventScroll:Fi.bool,tabbableOptions:Fi.shape({displayCheck:Fi.oneOf(["full","non-zero-area","none"]),getShadowRoot:Fi.oneOfType([Fi.bool,Fi.func])})}),containerElements:Fi.arrayOf(Fi.instanceOf(qv)),children:Fi.oneOfType([Fi.element,Fi.instanceOf(qv)])};X7.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:nde};var ode=X7,TT=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}();function KT(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function NM(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function PT(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var Lx=kr,Sg=Rm,zx=!!Sg.createPortal;function ade(e,n){if(!window.document)return function(r){PT(i,r);function i(){return KT(this,i),NM(this,(i.__proto__||Object.getPrototypeOf(i)).apply(this,arguments))}return TT(i,[{key:"render",value:function(){return!1}}]),i}(Lx.Component);n=n||{};var t=function(r){PT(i,r);function i(){var o,s,a,f;KT(this,i);for(var g=arguments.length,x=Array(g),k=0;k<g;k++)x[k]=arguments[k];return f=(s=(a=NM(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(x))),a),a.renderDisplaced=function(){Sg.unstable_renderSubtreeIntoContainer(a,Lx.createElement(e,a.props,a.props.children),a.container)},a.removeDisplaced=function(){Sg.unmountComponentAtNode(a.container)},s),NM(a,f)}return TT(i,[{key:"componentWillMount",value:function(){this.container=function(){if(n.renderTo)return typeof n.renderTo=="string"?document.querySelector(n.renderTo):n.renderTo;var s=document.createElement("div");return document.body.appendChild(s),s}()}},{key:"componentDidMount",value:function(){zx||this.props.mounted&&this.renderDisplaced()}},{key:"componentDidUpdate",value:function(s){zx||(s.mounted&&!this.props.mounted?Sg.unmountComponentAtNode(this.container):this.props.mounted&&this.renderDisplaced())}},{key:"componentWillUnmount",value:function(){zx||Sg.unmountComponentAtNode(this.container),n.renderTo||this.container.parentNode.removeChild(this.container)}},{key:"render",value:function(){return!zx||this.props.mounted===!1?null:Sg.createPortal(Lx.createElement(e,this.props,this.props.children),this.container)}}]),i}(Lx.Component);return t.defaultProps={mounted:!0},t.WrappedComponent=e,t}var sde=ade,Hj={exports:{}};(function(e){(function(n){var t=!1,r,i;function o(){if(typeof r<"u")return r;var k=document.documentElement,B=document.createElement("div");return B.setAttribute("style","width:99px;height:99px;position:absolute;top:-9999px;overflow:scroll;"),k.appendChild(B),r=B.offsetWidth-B.clientWidth,k.removeChild(B),r}function s(){return document.documentElement.scrollHeight>window.innerHeight}function a(k){if(!(typeof document>"u"||t)){var B=document.documentElement;i=window.pageYOffset,s()?B.style.width="calc(100% - "+o()+"px)":B.style.width="100%",B.style.position="fixed",B.style.top=-i+"px",B.style.overflow="hidden",t=!0}}function f(){if(!(typeof document>"u"||!t)){var k=document.documentElement;k.style.width="",k.style.position="",k.style.top="",k.style.overflow="",window.scroll(0,i),t=!1}}function g(){if(t){f();return}a()}var x={on:a,off:f,toggle:g};e.exports=x})()})(Hj);var lde=Hj.exports;function kE(e){"@babel/helpers - typeof";return kE=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},kE(e)}function ude(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function FT(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ade(e,n,t){return n&&FT(e.prototype,n),t&&FT(e,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function cde(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),n&&IE(e,n)}function IE(e,n){return IE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},IE(e,n)}function dde(e){var n=fde();return function(){var r=Z3(e),i;if(n){var o=Z3(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return hde(this,i)}}function hde(e,n){if(n&&(kE(n)==="object"||typeof n=="function"))return n;if(n!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return fC(e)}function fC(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function fde(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Z3(e){return Z3=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Z3(e)}function pC(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var Vv=kr,pde=ode,Zj=sde,jx=lde,J7=function(e){cde(t,e);var n=dde(t);function t(r){var i;if(ude(this,t),i=n.call(this,r),pC(fC(i),"getApplicationNode",function(){return i.props.getApplicationNode?i.props.getApplicationNode():i.props.applicationNode}),pC(fC(i),"checkUnderlayClick",function(o){i.dialogNode&&i.dialogNode.contains(o.target)||o.pageX>o.target.ownerDocument.documentElement.offsetWidth||o.pageY>o.target.ownerDocument.documentElement.offsetHeight||i.exit(o)}),pC(fC(i),"checkDocumentKeyDown",function(o){i.props.escapeExits&&(o.key==="Escape"||o.key==="Esc"||o.keyCode===27)&&i.exit(o)}),pC(fC(i),"exit",function(o){i.props.onExit&&i.props.onExit(o)}),!r.titleText&&!r.titleId)throw new Error("react-aria-modal instances should have a `titleText` or `titleId`");return i}return Ade(t,[{key:"componentDidMount",value:function(){this.props.onEnter&&this.props.onEnter();var i=this.getApplicationNode();setTimeout(function(){i&&i.setAttribute("aria-hidden","true")},0),this.props.escapeExits&&this.addKeyDownListener(),this.props.scrollDisabled&&jx.on()}},{key:"componentDidUpdate",value:function(i){i.scrollDisabled&&!this.props.scrollDisabled?jx.off():!i.scrollDisabled&&this.props.scrollDisabled&&jx.on(),this.props.escapeExits&&!i.escapeExits?this.addKeyDownListener():!this.props.escapeExits&&i.escapeExits&&this.removeKeyDownListener()}},{key:"componentWillUnmount",value:function(){this.props.scrollDisabled&&jx.off();var i=this.getApplicationNode();i&&i.setAttribute("aria-hidden","false"),this.removeKeyDownListener()}},{key:"addKeyDownListener",value:function(){var i=this;setTimeout(function(){document.addEventListener("keydown",i.checkDocumentKeyDown)})}},{key:"removeKeyDownListener",value:function(){var i=this;setTimeout(function(){document.removeEventListener("keydown",i.checkDocumentKeyDown)})}},{key:"render",value:function(){var i=this.props,o={};if(i.includeDefaultStyles&&(o={position:"fixed",top:0,left:0,width:"100%",height:"100%",zIndex:1050,overflowX:"hidden",overflowY:"auto",WebkitOverflowScrolling:"touch",textAlign:"center"},i.underlayColor&&(o.background=i.underlayColor),i.underlayClickExits&&(o.cursor="pointer")),i.underlayStyle)for(var s in i.underlayStyle)i.underlayStyle.hasOwnProperty(s)&&(o[s]=i.underlayStyle[s]);var a={className:i.underlayClass,style:o};i.underlayClickExits&&(a.onMouseDown=this.checkUnderlayClick);for(var f in this.props.underlayProps)a[f]=this.props.underlayProps[f];var g={};i.includeDefaultStyles&&(g={display:"inline-block",height:"100%",verticalAlign:"middle"});var x={key:"a",style:g},k={};if(i.includeDefaultStyles&&(k={display:"inline-block",textAlign:"left",top:0,maxWidth:"100%",cursor:"auto",outline:i.focusDialog?0:null},i.verticallyCenter&&(k.verticalAlign="middle",k.top=0)),i.dialogStyle)for(var B in i.dialogStyle)i.dialogStyle.hasOwnProperty(B)&&(k[B]=i.dialogStyle[B]);var P={key:"b",ref:(function($){this.dialogNode=$}).bind(this),role:i.alert?"alertdialog":"dialog",id:i.dialogId,className:i.dialogClass,style:k};i.titleId?P["aria-labelledby"]=i.titleId:i.titleText&&(P["aria-label"]=i.titleText),i.focusDialog&&(P.tabIndex="-1");for(var R in i)/^(data-|aria-)/.test(R)&&(P[R]=i[R]);var H=[Vv.createElement("div",P,i.children)];i.verticallyCenter&&H.unshift(Vv.createElement("div",x));var W=i.focusTrapOptions||{};return(i.focusDialog||i.initialFocus)&&(W.initialFocus=i.focusDialog?"#".concat(this.props.dialogId):i.initialFocus),W.escapeDeactivates=i.escapeExits,Vv.createElement(pde,{focusTrapOptions:W,paused:i.focusTrapPaused},Vv.createElement("div",a,H))}}]),t}(Vv.Component);pC(J7,"defaultProps",{underlayProps:{},dialogId:"react-aria-modal-dialog",underlayClickExits:!0,escapeExits:!0,underlayColor:"rgba(0,0,0,0.5)",includeDefaultStyles:!0,focusTrapPaused:!1,scrollDisabled:!0});var Xj=Zj(J7);Xj.renderTo=function(e){return Zj(J7,{renderTo:e})};var mde=Xj;const gde=ga(mde);function tu(){var e="/home/runner/work/maputnik/maputnik/src/components/Modal.tsx",n="182829ebe13a379e94c383087c7e861e586a9014",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/Modal.tsx",statementMap:{0:{start:{line:7,column:24},end:{line:9,column:3}},1:{start:{line:11,column:12},end:{line:18,column:3}},2:{start:{line:12,column:4},end:{line:14,column:5}},3:{start:{line:13,column:6},end:{line:13,column:36}},4:{start:{line:15,column:4},end:{line:17,column:10}},5:{start:{line:16,column:6},end:{line:16,column:37}},6:{start:{line:20,column:4},end:{line:58,column:5}},7:{start:{line:21,column:6},end:{line:55,column:8}},8:{start:{line:57,column:6},end:{line:57,column:19}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:11,column:12},end:{line:11,column:13}},loc:{start:{line:11,column:18},end:{line:18,column:3}},line:11},1:{name:"(anonymous_1)",decl:{start:{line:15,column:15},end:{line:15,column:16}},loc:{start:{line:15,column:21},end:{line:17,column:5}},line:15},2:{name:"(anonymous_2)",decl:{start:{line:19,column:2},end:{line:19,column:3}},loc:{start:{line:19,column:11},end:{line:59,column:3}},line:19}},branchMap:{0:{loc:{start:{line:12,column:4},end:{line:14,column:5}},type:"if",locations:[{start:{line:12,column:4},end:{line:14,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:12},1:{loc:{start:{line:20,column:4},end:{line:58,column:5}},type:"if",locations:[{start:{line:20,column:4},end:{line:58,column:5}},{start:{line:56,column:11},end:{line:58,column:5}}],line:20}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},f:{0:0,1:0,2:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/Modal.tsx"],names:[],mappings:"AA+CU,SACE,KADF;AA/CV,OAAO,WAAW;AAClB,SAAQ,eAAc;AACtB,OAAO,eAAe;AACtB,OAAO,gBAAgB;AAcvB,qBAAqB,cAAc,MAAM,UAAsB;AAAA,EAC7D,OAAO,eAAe;AAAA,IACpB,oBAAoB;AAAA,EACtB;AAAA;AAAA,EAGA,UAAU,MAAM;AACd,QAAI,SAAS,eAAe;AAC1B,MAAC,SAAS,cAA8B,KAAK;AAAA,IAC/C;AAEA,eAAW,MAAM;AACf,WAAK,MAAM,aAAa,KAAK;AAAA,IAC/B,GAAG,CAAC;AAAA,EACN;AAAA,EAEA,SAAS;AACP,QAAG,KAAK,MAAM,QAAQ;AACpB,aAAO;AAAA,QAAC;AAAA;AAAA,UACN,WAAW,KAAK,MAAM;AAAA,UACtB,oBAAoB,KAAK,MAAM;AAAA,UAE/B,eAAe,KAAK,MAAM;AAAA,UAC1B,eAAa,KAAK,MAAM,aAAa;AAAA,UACrC,kBAAkB;AAAA,UAClB,QAAQ,KAAK;AAAA,UAEb;AAAA,YAAC;AAAA;AAAA,cAAI,WAAW,WAAW,kBAAkB,KAAK,MAAM,SAAS;AAAA,cAC/D,eAAa,KAAK,MAAM,aAAa;AAAA,cAErC;AAAA,qCAAC,YAAO,WAAU,yBAChB;AAAA,sCAAC,QAAG,WAAU,+BAA+B,eAAK,MAAM,OAAM;AAAA,kBAC9D,oBAAC,UAAK,WAAU,+BAA8B;AAAA,kBAC9C;AAAA,oBAAC;AAAA;AAAA,sBAAO,WAAU;AAAA,sBAChB,OAAM;AAAA,sBACN,SAAS,KAAK;AAAA,sBACd,eAAa,KAAK,MAAM,aAAa,IAAE;AAAA,sBAEvC,8BAAC,WAAQ;AAAA;AAAA,kBACX;AAAA,mBACF;AAAA,gBACA,oBAAC,SAAI,WAAU,2BACb,8BAAC,SAAI,WAAU,0BAA0B,eAAK,MAAM,UAAS,GAC/D;AAAA;AAAA;AAAA,UACF;AAAA;AAAA,MACF;AAAA,IACF,OACK;AACH,aAAO;AAAA,IACT;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"182829ebe13a379e94c383087c7e861e586a9014"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return tu=function(){return s},s}tu();class _f extends bn.Component{constructor(){super(...arguments);nn(this,"onClose",(tu().s[1]++,()=>{tu().f[0]++,tu().s[2]++,document.activeElement?(tu().b[0][0]++,tu().s[3]++,document.activeElement.blur()):tu().b[0][1]++,tu().s[4]++,setTimeout(()=>{tu().f[1]++,tu().s[5]++,this.props.onOpenToggle(!1)},0)}))}render(){return tu().f[2]++,tu().s[6]++,this.props.isOpen?(tu().b[1][0]++,tu().s[7]++,N.jsx(gde,{titleText:this.props.title,underlayClickExits:this.props.underlayClickExits,underlayProps:this.props.underlayProps,"data-wd-key":this.props["data-wd-key"],verticallyCenter:!0,onExit:this.onClose,children:N.jsxs("div",{className:Af("maputnik-modal",this.props.className),"data-wd-key":this.props["data-wd-key"],children:[N.jsxs("header",{className:"maputnik-modal-header",children:[N.jsx("h1",{className:"maputnik-modal-header-title",children:this.props.title}),N.jsx("span",{className:"maputnik-modal-header-space"}),N.jsx("button",{className:"maputnik-modal-header-toggle",title:"Close modal",onClick:this.onClose,"data-wd-key":this.props["data-wd-key"]+".close-modal",children:N.jsx(EJ,{})})]}),N.jsx("div",{className:"maputnik-modal-scroller",children:N.jsx("div",{className:"maputnik-modal-content",children:this.props.children})})]})})):(tu().b[1][1]++,tu().s[8]++,!1)}}nn(_f,"defaultProps",(tu().s[0]++,{underlayClickExits:!0}));const yde=8,vde={version:{required:!0,type:"enum",values:[8],doc:"Style specification version number. Must be 8.",example:8},name:{type:"string",doc:"A human-readable name for the style.",example:"Bright"},metadata:{type:"*",doc:"Arbitrary properties useful to track with the stylesheet, but do not influence rendering. Properties should be prefixed to avoid collisions, like 'maplibre:'.",example:{"styleeditor:slimmode":!0,"styleeditor:comment":"Style generated 1677776383","styleeditor:version":"3.14.159265","example:object":{String:"one",Number:2,Boolean:!1}}},center:{type:"array",value:"number",doc:"Default map center in longitude and latitude. The style center will be used only if the map has not been positioned by other means (e.g. map options or user interaction).",example:[-73.9749,40.7736]},zoom:{type:"number",doc:"Default zoom level. The style zoom will be used only if the map has not been positioned by other means (e.g. map options or user interaction).",example:12.5},bearing:{type:"number",default:0,period:360,units:"degrees",doc:'Default bearing, in degrees. The bearing is the compass direction that is "up"; for example, a bearing of 90° orients the map so that east is up. This value will be used only if the map has not been positioned by other means (e.g. map options or user interaction).',example:29},pitch:{type:"number",default:0,units:"degrees",doc:"Default pitch, in degrees. Zero is perpendicular to the surface, for a look straight down at the map, while a greater value like 60 looks ahead towards the horizon. The style pitch will be used only if the map has not been positioned by other means (e.g. map options or user interaction).",example:50},light:{type:"light",doc:"The global light source.",example:{anchor:"viewport",color:"white",intensity:.4}},sky:{type:"sky",doc:"The map's sky configuration.",example:{"sky-color":"#199EF3","fog-color":"#00ff00","horizon-blend":.5,"fog-blend":.6}},terrain:{type:"terrain",doc:"The terrain configuration.",example:{source:"raster-dem-source",exaggeration:.5}},sources:{required:!0,type:"sources",doc:"Data source specifications.",example:{"maplibre-demotiles":{type:"vector",url:"https://demotiles.maplibre.org/tiles/tiles.json"}}},sprite:{type:"sprite",doc:"An array of `{id: 'my-sprite', url: 'https://example.com/sprite'}` objects. Each object should represent a unique URL to load a sprite from and and a unique ID to use as a prefix when referencing images from that sprite (i.e. 'my-sprite:image'). All the URLs are internally extended to load both .json and .png files. If the `id` field is equal to 'default', the prefix is omitted (just 'image' instead of 'default:image'). All the IDs and URLs must be unique. For backwards compatibility, instead of an array, one can also provide a single string that represent a URL to load the sprite from. The images in this case won't be prefixed.",example:"https://demotiles.maplibre.org/styles/osm-bright-gl-style/sprite"},glyphs:{type:"string",doc:"A URL template for loading signed-distance-field glyph sets in PBF format. The URL must include `{fontstack}` and `{range}` tokens. This property is required if any layer uses the `text-field` layout property. The URL must be absolute, containing the [scheme, authority and path components](https://en.wikipedia.org/wiki/URL#Syntax).",example:"https://demotiles.maplibre.org/font/{fontstack}/{range}.pbf"},transition:{type:"transition",doc:"A global transition definition to use as a default across properties, to be used for timing transitions between one value and the next when no property-specific transition is set. Collision-based symbol fading is controlled independently of the style's `transition` property.",example:{duration:300,delay:0}},layers:{required:!0,type:"array",value:"layer",doc:"Layers will be drawn in the order of this array.",example:[{id:"coastline",source:"maplibre","source-layer":"contries",type:"line",paint:{"line-color":"#198EC8"}}]}},Cde={"*":{type:"source",doc:"Specification of a data source. For vector and raster sources, either TileJSON or a URL to a TileJSON must be provided. For image and video sources, a URL must be provided. For GeoJSON sources, a URL or inline GeoJSON must be provided."}},_de=["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],bde={type:{required:!0,type:"enum",values:{vector:{doc:"A vector tile source."}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:` and `https:`."},tiles:{type:"array",value:"string",doc:"An array of one or more tile source URLs, as in the TileJSON spec."},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129],doc:"An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by MapLibre."},scheme:{type:"enum",values:{xyz:{doc:"Slippy map tilenames scheme."},tms:{doc:"OSGeo spec scheme."}},default:"xyz",doc:"Influences the y direction of the tile coordinates. The global-mercator (aka Spherical Mercator) profile is assumed."},minzoom:{type:"number",default:0,doc:"Minimum zoom level for which tiles are available, as in the TileJSON spec."},maxzoom:{type:"number",default:22,doc:"Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},promoteId:{type:"promoteId",doc:"A property to use as a feature id (for feature state). Either a property name, or an object of the form `{<sourceLayer>: <propertyName>}`. If specified as a string for a vector tile source, the same property is used across all its source layers."},volatile:{type:"boolean",default:!1,doc:"A setting to determine whether a source's tiles are cached locally.","sdk-support":{"basic functionality":{android:"9.3.0",ios:"5.10.0"}}},"*":{type:"*",doc:"Other keys to configure the data source."}},xde={type:{required:!0,type:"enum",values:{raster:{doc:"A raster tile source."}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:` and `https:`."},tiles:{type:"array",value:"string",doc:"An array of one or more tile source URLs, as in the TileJSON spec."},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129],doc:"An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by MapLibre."},minzoom:{type:"number",default:0,doc:"Minimum zoom level for which tiles are available, as in the TileJSON spec."},maxzoom:{type:"number",default:22,doc:"Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels."},tileSize:{type:"number",default:512,units:"pixels",doc:"The minimum visual size to display tiles for this layer. Only configurable for raster layers."},scheme:{type:"enum",values:{xyz:{doc:"Slippy map tilenames scheme."},tms:{doc:"OSGeo spec scheme."}},default:"xyz",doc:"Influences the y direction of the tile coordinates. The global-mercator (aka Spherical Mercator) profile is assumed."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},volatile:{type:"boolean",default:!1,doc:"A setting to determine whether a source's tiles are cached locally.","sdk-support":{"basic functionality":{android:"9.3.0",ios:"5.10.0"}}},"*":{type:"*",doc:"Other keys to configure the data source."}},wde={type:{required:!0,type:"enum",values:{"raster-dem":{doc:"A RGB-encoded raster DEM source"}},doc:"The type of the source."},url:{type:"string",doc:"A URL to a TileJSON resource. Supported protocols are `http:` and `https:`."},tiles:{type:"array",value:"string",doc:"An array of one or more tile source URLs, as in the TileJSON spec."},bounds:{type:"array",value:"number",length:4,default:[-180,-85.051129,180,85.051129],doc:"An array containing the longitude and latitude of the southwest and northeast corners of the source's bounding box in the following order: `[sw.lng, sw.lat, ne.lng, ne.lat]`. When this property is included in a source, no tiles outside of the given bounds are requested by MapLibre."},minzoom:{type:"number",default:0,doc:"Minimum zoom level for which tiles are available, as in the TileJSON spec."},maxzoom:{type:"number",default:22,doc:"Maximum zoom level for which tiles are available, as in the TileJSON spec. Data from tiles at the maxzoom are used when displaying the map at higher zoom levels."},tileSize:{type:"number",default:512,units:"pixels",doc:"The minimum visual size to display tiles for this layer. Only configurable for raster layers."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},encoding:{type:"enum",values:{terrarium:{doc:"Terrarium format PNG tiles. See https://aws.amazon.com/es/public-datasets/terrain/ for more info."},mapbox:{doc:"Mapbox Terrain RGB tiles. See https://www.mapbox.com/help/access-elevation-data/#mapbox-terrain-rgb for more info."},custom:{doc:"Decodes tiles using the redFactor, blueFactor, greenFactor, baseShift parameters."}},default:"mapbox",doc:"The encoding used by this source. Mapbox Terrain RGB is used by default."},redFactor:{type:"number",default:1,doc:"Value that will be multiplied by the red channel value when decoding. Only used on custom encodings.","sdk-support":{"basic functionality":{js:"3.4"}}},blueFactor:{type:"number",default:1,doc:"Value that will be multiplied by the blue channel value when decoding. Only used on custom encodings.","sdk-support":{"basic functionality":{js:"3.4"}}},greenFactor:{type:"number",default:1,doc:"Value that will be multiplied by the green channel value when decoding. Only used on custom encodings.","sdk-support":{"basic functionality":{js:"3.4"}}},baseShift:{type:"number",default:0,doc:"Value that will be added to the encoding mix when decoding. Only used on custom encodings.","sdk-support":{"basic functionality":{js:"3.4"}}},volatile:{type:"boolean",default:!1,doc:"A setting to determine whether a source's tiles are cached locally.","sdk-support":{"basic functionality":{android:"9.3.0",ios:"5.10.0"}}},"*":{type:"*",doc:"Other keys to configure the data source."}},Mde={type:{required:!0,type:"enum",values:{geojson:{doc:"A GeoJSON data source."}},doc:"The data type of the GeoJSON source."},data:{required:!0,type:"*",doc:"A URL to a GeoJSON file, or inline GeoJSON."},maxzoom:{type:"number",default:18,doc:"Maximum zoom level at which to create vector tiles (higher means greater detail at high zoom levels)."},attribution:{type:"string",doc:"Contains an attribution to be displayed when the map is shown to a user."},buffer:{type:"number",default:128,maximum:512,minimum:0,doc:"Size of the tile buffer on each side. A value of 0 produces no buffer. A value of 512 produces a buffer as wide as the tile itself. Larger values produce fewer rendering artifacts near tile edges and slower performance."},filter:{type:"*",doc:"An expression for filtering features prior to processing them for rendering."},tolerance:{type:"number",default:.375,doc:"Douglas-Peucker simplification tolerance (higher means simpler geometries and faster performance)."},cluster:{type:"boolean",default:!1,doc:"If the data is a collection of point features, setting this to true clusters the points by radius into groups. Cluster groups become new `Point` features in the source with additional properties:\n * `cluster` Is `true` if the point is a cluster \n * `cluster_id` A unqiue id for the cluster to be used in conjunction with the [cluster inspection methods](https://maplibre.org/maplibre-gl-js-docs/api/sources/#geojsonsource#getclusterexpansionzoom)\n * `point_count` Number of original points grouped into this cluster\n * `point_count_abbreviated` An abbreviated point count"},clusterRadius:{type:"number",default:50,minimum:0,doc:"Radius of each cluster if clustering is enabled. A value of 512 indicates a radius equal to the width of a tile."},clusterMaxZoom:{type:"number",doc:"Max zoom on which to cluster points if clustering is enabled. Defaults to one zoom less than maxzoom (so that last zoom features are not clustered). Clusters are re-evaluated at integer zoom levels so setting clusterMaxZoom to 14 means the clusters will be displayed until z15."},clusterMinPoints:{type:"number",doc:"Minimum number of points necessary to form a cluster if clustering is enabled. Defaults to `2`."},clusterProperties:{type:"*",doc:'An object defining custom properties on the generated clusters if clustering is enabled, aggregating values from clustered points. Has the form `{"property_name": [operator, map_expression]}`. `operator` is any expression function that accepts at least 2 operands (e.g. `"+"` or `"max"`) — it accumulates the property value from clusters/points the cluster contains; `map_expression` produces the value of a single point.\n\nExample: `{"sum": ["+", ["get", "scalerank"]]}`.\n\nFor more advanced use cases, in place of `operator`, you can use a custom reduce expression that references a special `["accumulated"]` value, e.g.:\n`{"sum": [["+", ["accumulated"], ["get", "sum"]], ["get", "scalerank"]]}`'},lineMetrics:{type:"boolean",default:!1,doc:"Whether to calculate line distance metrics. This is required for line layers that specify `line-gradient` values."},generateId:{type:"boolean",default:!1,doc:"Whether to generate ids for the geojson features. When enabled, the `feature.id` property will be auto assigned based on its index in the `features` array, over-writing any previous values."},promoteId:{type:"promoteId",doc:"A property to use as a feature id (for feature state). Either a property name, or an object of the form `{<sourceLayer>: <propertyName>}`."}},Sde={type:{required:!0,type:"enum",values:{video:{doc:"A video data source."}},doc:"The data type of the video source."},urls:{required:!0,type:"array",value:"string",doc:"URLs to video content in order of preferred format."},coordinates:{required:!0,doc:"Corners of video specified in longitude, latitude pairs.",type:"array",length:4,value:{type:"array",length:2,value:"number",doc:"A single longitude, latitude pair."}}},Ede={type:{required:!0,type:"enum",values:{image:{doc:"An image data source."}},doc:"The data type of the image source."},url:{required:!0,type:"string",doc:"URL that points to an image."},coordinates:{required:!0,doc:"Corners of image specified in longitude, latitude pairs.",type:"array",length:4,value:{type:"array",length:2,value:"number",doc:"A single longitude, latitude pair."}}},Ode={id:{type:"string",doc:"Unique layer name.",required:!0},type:{type:"enum",values:{fill:{doc:"A filled polygon with an optional stroked border.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},line:{doc:"A stroked line.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},symbol:{doc:"An icon or a text label.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},circle:{doc:"A filled circle.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},heatmap:{doc:"A heatmap.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"fill-extrusion":{doc:"An extruded (3D) polygon.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},raster:{doc:"Raster map textures such as satellite imagery.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}},hillshade:{doc:"Client-side hillshading visualization based on DEM data. The implementation supports Mapbox Terrain RGB, Mapzen Terrarium tiles and custom encodings.","sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},background:{doc:"The background color or pattern of the map.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}}}},doc:"Rendering type of this layer.",required:!0},metadata:{type:"*",doc:"Arbitrary properties useful to track with the layer, but do not influence rendering. Properties should be prefixed to avoid collisions, like 'maplibre:'.",example:{"source:comment":"Hydrology FCCODE 460 - Narrow wash"}},source:{type:"string",doc:"Name of a source description to be used for this layer. Required for all layer types except `background`."},"source-layer":{type:"string",doc:"Layer to use from a vector tile source. Required for vector tile sources; prohibited for all other source types, including GeoJSON sources."},minzoom:{type:"number",minimum:0,maximum:24,doc:"The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden."},maxzoom:{type:"number",minimum:0,maximum:24,doc:"The maximum zoom level for the layer. At zoom levels equal to or greater than the maxzoom, the layer will be hidden."},filter:{type:"filter",doc:"A expression specifying conditions on source features. Only features that match the filter are displayed. Zoom expressions in filters are only evaluated at integer zoom levels. The `feature-state` expression is not supported in filter expressions."},layout:{type:"layout",doc:"Layout properties for the layer."},paint:{type:"paint",doc:"Default paint properties for this layer."}},Bde=["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background"],kde={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Ide={"fill-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with a higher sort key will appear above features with a lower sort key.","sdk-support":{"basic functionality":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"},"data-driven styling":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Tde={"circle-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with a higher sort key will appear above features with a lower sort key.","sdk-support":{"basic functionality":{js:"1.2.0",android:"9.2.0",ios:"5.9.0",macos:"0.16.0"},"data-driven styling":{js:"1.2.0",android:"9.2.0",ios:"5.9.0",macos:"0.16.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Kde={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},"property-type":"constant"}},Pde={"line-cap":{type:"enum",values:{butt:{doc:"A cap with a squared-off end which is drawn to the exact endpoint of the line."},round:{doc:"A cap with a rounded end which is drawn beyond the endpoint of the line at a radius of one-half of the line's width and centered on the endpoint of the line."},square:{doc:"A cap with a squared-off end which is drawn beyond the endpoint of the line at a distance of one-half of the line's width."}},default:"butt",doc:"The display of line endings.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-join":{type:"enum",values:{bevel:{doc:"A join with a squared-off end which is drawn beyond the endpoint of the line at a distance of one-half of the line's width."},round:{doc:"A join with a rounded end which is drawn beyond the endpoint of the line at a radius of one-half of the line's width and centered on the endpoint of the line."},miter:{doc:"A join with a sharp, angled corner which is drawn with the outer sides beyond the endpoint of the path until they meet."}},default:"miter",doc:"The display of lines when joining.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{type:"number",default:2,doc:"Used to automatically convert miter joins to bevel joins for sharp angles.",requires:[{"line-join":"miter"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-round-limit":{type:"number",default:1.05,doc:"Used to automatically convert round joins to miter joins for shallow angles.",requires:[{"line-join":"round"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with a higher sort key will appear above features with a lower sort key.","sdk-support":{"basic functionality":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"},"data-driven styling":{js:"1.2.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Fde={"symbol-placement":{type:"enum",values:{point:{doc:"The label is placed at the point where the geometry is located."},line:{doc:"The label is placed along the line of the geometry. Can only be used on `LineString` and `Polygon` geometries."},"line-center":{doc:"The label is placed at the center of the line of the geometry. Can only be used on `LineString` and `Polygon` geometries. Note that a single feature in a vector tile may contain multiple line geometries."}},default:"point",doc:"Label placement relative to its geometry.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"`line-center` value":{js:"0.47.0",android:"6.4.0",ios:"4.3.0",macos:"0.10.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-spacing":{type:"number",default:250,minimum:1,units:"pixels",doc:"Distance between two symbol anchors.",requires:[{"symbol-placement":"line"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{type:"boolean",default:!1,doc:"If true, the symbols will not cross tile edges to avoid mutual collisions. Recommended in layers that don't have enough padding in the vector tile to prevent collisions, or if it is a point symbol layer placed after a line symbol layer. When using a client that supports global collision detection, like MapLibre GL JS version 0.42.0 or greater, enabling this property is not needed to prevent clipped labels at tile boundaries.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{type:"number",doc:"Sorts features in ascending order based on this value. Features with lower sort keys are drawn and placed first. When `icon-allow-overlap` or `text-allow-overlap` is `false`, features with a lower sort key will have priority during placement. When `icon-allow-overlap` or `text-allow-overlap` is set to `true`, features with a higher sort key will overlap over features with a lower sort key.","sdk-support":{"basic functionality":{js:"0.53.0",android:"7.4.0",ios:"4.11.0",macos:"0.14.0"},"data-driven styling":{js:"0.53.0",android:"7.4.0",ios:"4.11.0",macos:"0.14.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{type:"enum",values:{auto:{doc:"Sorts symbols by `symbol-sort-key` if set. Otherwise, sorts symbols by their y-position relative to the viewport if `icon-allow-overlap` or `text-allow-overlap` is set to `true` or `icon-ignore-placement` or `text-ignore-placement` is `false`."},"viewport-y":{doc:"Sorts symbols by their y-position relative to the viewport if `icon-allow-overlap` or `text-allow-overlap` is set to `true` or `icon-ignore-placement` or `text-ignore-placement` is `false`."},source:{doc:"Sorts symbols by `symbol-sort-key` if set. Otherwise, no sorting is applied; symbols are rendered in the same order as the source data."}},default:"auto",doc:"Determines whether overlapping symbols in the same layer are rendered in the order that they appear in the data source or by their y-position relative to the viewport. To control the order and prioritization of symbols otherwise, use `symbol-sort-key`.","sdk-support":{"basic functionality":{js:"0.49.0",android:"6.6.0",ios:"4.5.0",macos:"0.12.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{type:"boolean",default:!1,doc:"If true, the icon will be visible even if it collides with other previously drawn symbols.",requires:["icon-image",{"!":"icon-overlap"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-overlap":{type:"enum",values:{never:{doc:"The icon will be hidden if it collides with any other previously drawn symbol."},always:{doc:"The icon will be visible even if it collides with any other previously drawn symbol."},cooperative:{doc:"If the icon collides with another previously drawn symbol, the overlap mode for that symbol is checked. If the previous symbol was placed using `never` overlap mode, the new icon is hidden. If the previous symbol was placed using `always` or `cooperative` overlap mode, the new icon is visible."}},doc:"Allows for control over whether to show an icon when it overlaps other symbols on the map. If `icon-overlap` is not set, `icon-allow-overlap` is used instead.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"2.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{type:"boolean",default:!1,doc:"If true, other symbols can be visible even if they collide with the icon.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-optional":{type:"boolean",default:!1,doc:"If true, text will display without their corresponding icons when the icon collides with other symbols and the text does not.",requires:["icon-image","text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{type:"enum",values:{map:{doc:"When `symbol-placement` is set to `point`, aligns icons east-west. When `symbol-placement` is set to `line` or `line-center`, aligns icon x-axes with the line."},viewport:{doc:"Produces icons whose x-axes are aligned with the x-axis of the viewport, regardless of the value of `symbol-placement`."},auto:{doc:"When `symbol-placement` is set to `point`, this is equivalent to `viewport`. When `symbol-placement` is set to `line` or `line-center`, this is equivalent to `map`."}},default:"auto",doc:"In combination with `symbol-placement`, determines the rotation behavior of icons.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"`auto` value":{js:"0.25.0",android:"4.2.0",ios:"3.4.0",macos:"0.3.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-size":{type:"number",default:1,minimum:0,units:"factor of the original icon size",doc:"Scales the original size of the icon by the provided factor. The new pixel size of the image will be the original pixel size multiplied by `icon-size`. 1 is the original size; 3 triples the size of the image.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{type:"enum",values:{none:{doc:"The icon is displayed at its intrinsic aspect ratio."},width:{doc:"The icon is scaled in the x-dimension to fit the width of the text."},height:{doc:"The icon is scaled in the y-dimension to fit the height of the text."},both:{doc:"The icon is scaled in both x- and y-dimensions."}},default:"none",doc:"Scales the icon to fit around the associated text.",requires:["icon-image","text-field"],"sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"},"stretchable icons":{js:"1.6.0",android:"9.2.0",ios:"5.8.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{type:"array",value:"number",length:4,default:[0,0,0,0],units:"pixels",doc:"Size of the additional area added to dimensions determined by `icon-text-fit`, in clockwise order: top, right, bottom, left.",requires:["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],"sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-image":{type:"resolvedImage",doc:"Name of image in sprite to use for drawing an image background.",tokens:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{type:"number",default:0,period:360,units:"degrees",doc:"Rotates the icon clockwise.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.21.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{type:"padding",default:[2],units:"pixels",doc:"Size of additional area round the icon bounding box used for detecting symbol collisions. Values are declared using CSS margin shorthand syntax: a single value applies to all four sides; two values apply to [top/bottom, left/right]; three values apply to [top, left/right, bottom]; four values apply to [top, right, bottom, left]. For backwards compatibility, a single bare number is accepted, and treated the same as a one-element array - padding applied to all sides.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"2.2.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-keep-upright":{type:"boolean",default:!1,doc:"If true, the icon may be flipped to prevent it from being rendered upside-down.",requires:["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],doc:"Offset distance of icon from its anchor. Positive values indicate right and down, while negative values indicate left and up. Each component is multiplied by the value of `icon-size` to obtain the final offset in pixels. When combined with `icon-rotate` the offset will be as if the rotated direction was up.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{type:"enum",values:{center:{doc:"The center of the icon is placed closest to the anchor."},left:{doc:"The left side of the icon is placed closest to the anchor."},right:{doc:"The right side of the icon is placed closest to the anchor."},top:{doc:"The top of the icon is placed closest to the anchor."},bottom:{doc:"The bottom of the icon is placed closest to the anchor."},"top-left":{doc:"The top left corner of the icon is placed closest to the anchor."},"top-right":{doc:"The top right corner of the icon is placed closest to the anchor."},"bottom-left":{doc:"The bottom left corner of the icon is placed closest to the anchor."},"bottom-right":{doc:"The bottom right corner of the icon is placed closest to the anchor."}},default:"center",doc:"Part of the icon placed closest to the anchor.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{type:"enum",values:{map:{doc:"The icon is aligned to the plane of the map."},viewport:{doc:"The icon is aligned to the plane of the viewport."},auto:{doc:"Automatically matches the value of `icon-rotation-alignment`."}},default:"auto",doc:"Orientation of icon when map is pitched.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{type:"enum",values:{map:{doc:"The text is aligned to the plane of the map."},viewport:{doc:"The text is aligned to the plane of the viewport."},auto:{doc:"Automatically matches the value of `text-rotation-alignment`."}},default:"auto",doc:"Orientation of text when map is pitched.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"},"`auto` value":{js:"0.25.0",android:"4.2.0",ios:"3.4.0",macos:"0.3.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{type:"enum",values:{map:{doc:"When `symbol-placement` is set to `point`, aligns text east-west. When `symbol-placement` is set to `line` or `line-center`, aligns text x-axes with the line."},viewport:{doc:"Produces glyphs whose x-axes are aligned with the x-axis of the viewport, regardless of the value of `symbol-placement`."},"viewport-glyph":{doc:"When `symbol-placement` is set to `point`, aligns text to the x-axis of the viewport. When `symbol-placement` is set to `line` or `line-center`, aligns glyphs to the x-axis of the viewport and places them along the line."},auto:{doc:"When `symbol-placement` is set to `point`, this is equivalent to `viewport`. When `symbol-placement` is set to `line` or `line-center`, this is equivalent to `map`."}},default:"auto",doc:"In combination with `symbol-placement`, determines the rotation behavior of the individual glyphs forming the text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"`auto` value":{js:"0.25.0",android:"4.2.0",ios:"3.4.0",macos:"0.3.0"},"`viewport-glyph` value":{js:"2.1.8"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-field":{type:"formatted",default:"",tokens:!0,doc:"Value to use for a text label. If a plain `string` is provided, it will be treated as a `formatted` with default/inherited formatting options.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-font":{type:"array",value:"string",default:["Open Sans Regular","Arial Unicode MS Regular"],doc:"Font stack to use for displaying text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-size":{type:"number",default:16,minimum:0,units:"pixels",doc:"Font size.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",doc:"The maximum line width for text wrapping.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{type:"number",default:1.2,units:"ems",doc:"Text leading value for multi-line text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-letter-spacing":{type:"number",default:0,units:"ems",doc:"Text tracking amount.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.40.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-justify":{type:"enum",values:{auto:{doc:"The text is aligned towards the anchor position."},left:{doc:"The text is aligned to the left."},center:{doc:"The text is centered."},right:{doc:"The text is aligned to the right."}},default:"center",doc:"Text justification options.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"},auto:{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{type:"number",units:"ems",default:0,doc:"Radial offset of text, in the direction of the symbol's anchor. Useful in combination with `text-variable-anchor`, which defaults to using the two-dimensional `text-offset` if present.","sdk-support":{"basic functionality":{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"},"data-driven styling":{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"}},requires:["text-field"],"property-type":"data-driven",expression:{interpolated:!0,parameters:["zoom","feature"]}},"text-variable-anchor":{type:"array",value:"enum",values:{center:{doc:"The center of the text is placed closest to the anchor."},left:{doc:"The left side of the text is placed closest to the anchor."},right:{doc:"The right side of the text is placed closest to the anchor."},top:{doc:"The top of the text is placed closest to the anchor."},bottom:{doc:"The bottom of the text is placed closest to the anchor."},"top-left":{doc:"The top left corner of the text is placed closest to the anchor."},"top-right":{doc:"The top right corner of the text is placed closest to the anchor."},"bottom-left":{doc:"The bottom left corner of the text is placed closest to the anchor."},"bottom-right":{doc:"The bottom right corner of the text is placed closest to the anchor."}},requires:["text-field",{"symbol-placement":["point"]}],doc:"To increase the chance of placing high-priority labels on the map, you can provide an array of `text-anchor` locations: the renderer will attempt to place the label at each location, in order, before moving onto the next label. Use `text-justify: auto` to choose justification based on anchor position. To apply an offset, use the `text-radial-offset` or the two-dimensional `text-offset`.","sdk-support":{"basic functionality":{js:"0.54.0",android:"7.4.0",ios:"4.10.0",macos:"0.14.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-variable-anchor-offset":{type:"variableAnchorOffsetCollection",requires:["text-field",{"symbol-placement":["point"]}],doc:'To increase the chance of placing high-priority labels on the map, you can provide an array of `text-anchor` locations, each paired with an offset value. The renderer will attempt to place the label at each location, in order, before moving on to the next location+offset. Use `text-justify: auto` to choose justification based on anchor position. \n\n The length of the array must be even, and must alternate between enum and point entries. i.e., each anchor location must be accompanied by a point, and that point defines the offset when the corresponding anchor location is used. Positive offset values indicate right and down, while negative values indicate left and up. Anchor locations may repeat, allowing the renderer to try multiple offsets to try and place a label using the same anchor. \n\n When present, this property takes precedence over `text-anchor`, `text-variable-anchor`, `text-offset`, and `text-radial-offset`. \n\n ```json \n { "text-variable-anchor-offset": ["top", [0, 4], "left", [3,0], "bottom", [1, 1]] } \n ``` \n\n When the renderer chooses the `top` anchor, `[0, 4]` will be used for `text-offset`; the text will be shifted down by 4 ems. \n\n When the renderer chooses the `left` anchor, `[3, 0]` will be used for `text-offset`; the text will be shifted right by 3 ems.',"sdk-support":{"basic functionality":{js:"3.3.0"},"data-driven styling":{js:"3.3.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-anchor":{type:"enum",values:{center:{doc:"The center of the text is placed closest to the anchor."},left:{doc:"The left side of the text is placed closest to the anchor."},right:{doc:"The right side of the text is placed closest to the anchor."},top:{doc:"The top of the text is placed closest to the anchor."},bottom:{doc:"The bottom of the text is placed closest to the anchor."},"top-left":{doc:"The top left corner of the text is placed closest to the anchor."},"top-right":{doc:"The top right corner of the text is placed closest to the anchor."},"bottom-left":{doc:"The bottom left corner of the text is placed closest to the anchor."},"bottom-right":{doc:"The bottom right corner of the text is placed closest to the anchor."}},default:"center",doc:"Part of the text placed closest to the anchor.",requires:["text-field",{"!":"text-variable-anchor"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{type:"number",default:45,units:"degrees",doc:"Maximum angle change between adjacent characters.",requires:["text-field",{"symbol-placement":["line","line-center"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-writing-mode":{type:"array",value:"enum",values:{horizontal:{doc:"If a text's language supports horizontal writing mode, symbols with point placement would be laid out horizontally."},vertical:{doc:"If a text's language supports vertical writing mode, symbols with point placement would be laid out vertically."}},doc:"The property allows control over a symbol's orientation. Note that the property values act as a hint, so that a symbol whose language doesn’t support the provided orientation will be laid out in its natural orientation. Example: English point symbol will be rendered horizontally even if array value contains single 'vertical' enum value. The order of elements in an array define priority order for the placement of an orientation variant.",requires:["text-field",{"symbol-placement":["point"]}],"sdk-support":{"basic functionality":{js:"1.3.0",android:"8.3.0",ios:"5.3.0",macos:"0.15.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotate":{type:"number",default:0,period:360,units:"degrees",doc:"Rotates the text clockwise.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",doc:"Size of the additional area around the text bounding box used for detecting symbol collisions.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-keep-upright":{type:"boolean",default:!0,doc:"If true, the text may be flipped vertically to prevent it from being rendered upside-down.",requires:["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-transform":{type:"enum",values:{none:{doc:"The text is not altered."},uppercase:{doc:"Forces all letters to be displayed in uppercase."},lowercase:{doc:"Forces all letters to be displayed in lowercase."}},default:"none",doc:"Specifies how to capitalize text, similar to the CSS `text-transform` property.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-offset":{type:"array",doc:"Offset distance of text from its anchor. Positive values indicate right and down, while negative values indicate left and up. If used with text-variable-anchor, input values will be taken as absolute values. Offsets along the x- and y-axis will be applied automatically based on the anchor position.",value:"number",units:"ems",length:2,default:[0,0],requires:["text-field",{"!":"text-radial-offset"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.35.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{type:"boolean",default:!1,doc:"If true, the text will be visible even if it collides with other previously drawn symbols.",requires:["text-field",{"!":"text-overlap"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-overlap":{type:"enum",values:{never:{doc:"The text will be hidden if it collides with any other previously drawn symbol."},always:{doc:"The text will be visible even if it collides with any other previously drawn symbol."},cooperative:{doc:"If the text collides with another previously drawn symbol, the overlap mode for that symbol is checked. If the previous symbol was placed using `never` overlap mode, the new text is hidden. If the previous symbol was placed using `always` or `cooperative` overlap mode, the new text is visible."}},doc:"Allows for control over whether to show symbol text when it overlaps other symbols on the map. If `text-overlap` is not set, `text-allow-overlap` is used instead",requires:["text-field"],"sdk-support":{"basic functionality":{js:"2.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{type:"boolean",default:!1,doc:"If true, other symbols can be visible even if they collide with the text.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-optional":{type:"boolean",default:!1,doc:"If true, icons will display without their corresponding text when the text collides with other symbols and the icon does not.",requires:["text-field","icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Dde={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},"property-type":"constant"}},Ude={visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},"property-type":"constant"}},Rde={type:"array",value:"*",doc:"A filter selects specific features from a layer."},Lde={type:"enum",values:{"==":{doc:'`["==", key, value]` equality: `feature[key] = value`'},"!=":{doc:'`["!=", key, value]` inequality: `feature[key] ≠ value`'},">":{doc:'`[">", key, value]` greater than: `feature[key] > value`'},">=":{doc:'`[">=", key, value]` greater than or equal: `feature[key] ≥ value`'},"<":{doc:'`["<", key, value]` less than: `feature[key] < value`'},"<=":{doc:'`["<=", key, value]` less than or equal: `feature[key] ≤ value`'},in:{doc:'`["in", key, v0, ..., vn]` set inclusion: `feature[key] ∈ {v0, ..., vn}`'},"!in":{doc:'`["!in", key, v0, ..., vn]` set exclusion: `feature[key] ∉ {v0, ..., vn}`'},all:{doc:'`["all", f0, ..., fn]` logical `AND`: `f0 ∧ ... ∧ fn`'},any:{doc:'`["any", f0, ..., fn]` logical `OR`: `f0 ∨ ... ∨ fn`'},none:{doc:'`["none", f0, ..., fn]` logical `NOR`: `¬f0 ∧ ... ∧ ¬fn`'},has:{doc:'`["has", key]` `feature[key]` exists'},"!has":{doc:'`["!has", key]` `feature[key]` does not exist'},within:{doc:'`["within", object]` feature geometry is within object geometry'}},doc:"The filter operator."},zde={type:"enum",values:{Point:{doc:"Filter to point geometries."},LineString:{doc:"Filter to line geometries."},Polygon:{doc:"Filter to polygon geometries."}},doc:"The geometry type for the filter to select."},jde={type:"array",minimum:0,maximum:24,value:["number","color"],length:2,doc:"Zoom level and value pair."},Wde={type:"array",value:"*",minimum:1,doc:"An expression defines a function that can be used for data-driven style properties or feature filters."},Nde={doc:"",type:"enum",values:{let:{doc:'Binds expressions to named variables, which can then be referenced in the result expression using ["var", "variable_name"].',group:"Variable binding","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},var:{doc:'References variable bound using "let".',group:"Variable binding","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},literal:{doc:"Provides a literal array or object value.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},array:{doc:"Asserts that the input is an array (optionally with a specific item type and length). If, when the input expression is evaluated, it is not of the asserted type, then this assertion will cause the whole expression to be aborted.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},at:{doc:"Retrieves an item from an array.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},in:{doc:"Determines whether an item exists in an array or a substring exists in a string.",group:"Lookup","sdk-support":{"basic functionality":{js:"1.6.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}}},"index-of":{doc:"Returns the first position at which an item can be found in an array or a substring can be found in a string, or `-1` if the input cannot be found. Accepts an optional index from where to begin the search.",group:"Lookup","sdk-support":{"basic functionality":{js:"1.10.0"}}},slice:{doc:"Returns an item from an array or a substring from a string from a specified start index, or between a start index and an end index if set. The return value is inclusive of the start index but not of the end index.",group:"Lookup","sdk-support":{"basic functionality":{js:"1.10.0"}}},case:{doc:"Selects the first output whose corresponding test condition evaluates to true, or the fallback value otherwise.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},match:{doc:'Selects the output whose label value matches the input value, or the fallback value if no match is found. The input can be any expression (e.g. `["get", "building_type"]`). Each label must be either:\n - a single literal value; or\n - an array of literal values, whose values must be all strings or all numbers (e.g. `[100, 101]` or `["c", "b"]`). The input matches if any of the values in the array matches, similar to the `"in"` operator.\nEach label must be unique. If the input type does not match the type of the labels, the result will be the fallback value.',group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},coalesce:{doc:"Evaluates each expression in turn until the first non-null value is obtained, and returns that value.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},step:{doc:'Produces discrete, stepped results by evaluating a piecewise-constant function defined by pairs of input and output values ("stops"). The `input` may be any numeric expression (e.g., `["get", "population"]`). Stop inputs must be numeric literals in strictly ascending order. Returns the output value of the stop just less than the input, or the first output if the input is less than the first stop.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.42.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},interpolate:{doc:'Produces continuous, smooth results by interpolating between pairs of input and output values ("stops"). The `input` may be any numeric expression (e.g., `["get", "population"]`). Stop inputs must be numeric literals in strictly ascending order. The output type must be `number`, `array<number>`, or `color`.\n\nInterpolation types:\n- `["linear"]`, or an expression returning one of those types: Interpolates linearly between the pair of stops just less than and just greater than the input.\n- `["exponential", base]`: Interpolates exponentially between the stops just less than and just greater than the input. `base` controls the rate at which the output increases: higher values make the output increase more towards the high end of the range. With values close to 1 the output increases linearly.\n- `["cubic-bezier", x1, y1, x2, y2]`: Interpolates using the cubic bezier curve defined by the given control points.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.42.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"interpolate-hcl":{doc:'Produces continuous, smooth results by interpolating between pairs of input and output values ("stops"). Works like `interpolate`, but the output type must be `color`, and the interpolation is performed in the Hue-Chroma-Luminance color space.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.49.0"}}},"interpolate-lab":{doc:'Produces continuous, smooth results by interpolating between pairs of input and output values ("stops"). Works like `interpolate`, but the output type must be `color`, and the interpolation is performed in the CIELAB color space.',group:"Ramps, scales, curves","sdk-support":{"basic functionality":{js:"0.49.0"}}},ln2:{doc:"Returns mathematical constant ln(2).",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},pi:{doc:"Returns the mathematical constant pi.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},e:{doc:"Returns the mathematical constant e.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},typeof:{doc:"Returns a string describing the type of the given value.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},string:{doc:"Asserts that the input value is a string. If multiple values are provided, each one is evaluated in order until a string is obtained. If none of the inputs are strings, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},number:{doc:"Asserts that the input value is a number. If multiple values are provided, each one is evaluated in order until a number is obtained. If none of the inputs are numbers, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},boolean:{doc:"Asserts that the input value is a boolean. If multiple values are provided, each one is evaluated in order until a boolean is obtained. If none of the inputs are booleans, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},object:{doc:"Asserts that the input value is an object. If multiple values are provided, each one is evaluated in order until an object is obtained. If none of the inputs are objects, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},collator:{doc:"Returns a `collator` for use in locale-dependent comparison operations. The `case-sensitive` and `diacritic-sensitive` options default to `false`. The `locale` argument specifies the IETF language tag of the locale to use. If none is provided, the default locale is used. If the requested locale is not available, the `collator` will use a system-defined fallback locale. Use `resolved-locale` to test the results of locale fallback behavior.",group:"Types","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},format:{doc:'Returns a `formatted` string for displaying mixed-format text in the `text-field` property. The input may contain a string literal or expression, including an [`\'image\'`](#types-image) expression. Strings may be followed by a style override object that supports the following properties:\n- `"text-font"`: Overrides the font stack specified by the root layout property.\n- `"text-color"`: Overrides the color specified by the root paint property.\n- `"font-scale"`: Applies a scaling factor on `text-size` as specified by the root layout property.',group:"Types","sdk-support":{"basic functionality":{js:"0.48.0",android:"6.7.0",ios:"4.6.0",macos:"0.12.0"},"text-font":{js:"0.48.0",android:"6.7.0",ios:"4.6.0",macos:"0.12.0"},"font-scale":{js:"0.48.0",android:"6.7.0",ios:"4.6.0",macos:"0.12.0"},"text-color":{js:"1.3.0",android:"7.3.0",ios:"4.10.0",macos:"0.14.0"},image:{js:"1.6.0",android:"8.6.0",ios:"5.7.0",macos:"0.15.0"}}},image:{doc:"Returns an `image` type for use in `icon-image`, `*-pattern` entries and as a section in the `format` expression. If set, the `image` argument will check that the requested image exists in the style and will return either the resolved image name or `null`, depending on whether or not the image is currently in the style. This validation process is synchronous and requires the image to have been added to the style before requesting it in the `image` argument.",group:"Types","sdk-support":{"basic functionality":{js:"1.4.0",android:"8.6.0",ios:"5.7.0",macos:"0.15.0"}}},"number-format":{doc:"Converts the input number into a string representation using the providing formatting rules. If set, the `locale` argument specifies the locale to use, as a BCP 47 language tag. If set, the `currency` argument specifies an ISO 4217 code to use for currency-style formatting. If set, the `min-fraction-digits` and `max-fraction-digits` arguments specify the minimum and maximum number of fractional digits to include.",group:"Types","sdk-support":{"basic functionality":{js:"0.54.0"}}},"to-string":{doc:'Converts the input value to a string. If the input is `null`, the result is `""`. If the input is a boolean, the result is `"true"` or `"false"`. If the input is a number, it is converted to a string as specified by the ["NumberToString" algorithm](https://tc39.github.io/ecma262/#sec-tostring-applied-to-the-number-type) of the ECMAScript Language Specification. If the input is a color, it is converted to a string of the form `"rgba(r,g,b,a)"`, where `r`, `g`, and `b` are numerals ranging from 0 to 255, and `a` ranges from 0 to 1. Otherwise, the input is converted to a string in the format specified by the [`JSON.stringify`](https://tc39.github.io/ecma262/#sec-json.stringify) function of the ECMAScript Language Specification.',group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-number":{doc:'Converts the input value to a number, if possible. If the input is `null` or `false`, the result is 0. If the input is `true`, the result is 1. If the input is a string, it is converted to a number as specified by the ["ToNumber Applied to the String Type" algorithm](https://tc39.github.io/ecma262/#sec-tonumber-applied-to-the-string-type) of the ECMAScript Language Specification. If multiple values are provided, each one is evaluated in order until the first successful conversion is obtained. If none of the inputs can be converted, the expression is an error.',group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-boolean":{doc:"Converts the input value to a boolean. The result is `false` when then input is an empty string, 0, `false`, `null`, or `NaN`; otherwise it is `true`.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-rgba":{doc:"Returns a four-element array containing the input color's red, green, blue, and alpha components, in that order.",group:"Color","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"to-color":{doc:"Converts the input value to a color. If multiple values are provided, each one is evaluated in order until the first successful conversion is obtained. If none of the inputs can be converted, the expression is an error.",group:"Types","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},rgb:{doc:"Creates a color value from red, green, and blue components, which must range between 0 and 255, and an alpha component of 1. If any component is out of range, the expression is an error.",group:"Color","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},rgba:{doc:"Creates a color value from red, green, blue components, which must range between 0 and 255, and an alpha component which must range between 0 and 1. If any component is out of range, the expression is an error.",group:"Color","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},get:{doc:"Retrieves a property value from the current feature's properties, or from another object if a second argument is provided. Returns null if the requested property is missing.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},has:{doc:"Tests for the presence of an property value in the current feature's properties, or from another object if a second argument is provided.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},length:{doc:"Gets the length of an array or string.",group:"Lookup","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},properties:{doc:'Gets the feature properties object. Note that in some cases, it may be more efficient to use ["get", "property_name"] directly.',group:"Feature data","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"feature-state":{doc:"Retrieves a property value from the current feature's state. Returns null if the requested property is not present on the feature's state. A feature's state is not part of the GeoJSON or vector tile data, and must be set programmatically on each feature. When `source.promoteId` is not provided, features are identified by their `id` attribute, which must be an integer or a string that can be cast to an integer. When `source.promoteId` is provided, features are identified by their `promoteId` property, which may be a number, string, or any primitive data type. Note that [\"feature-state\"] can only be used with paint properties that support data-driven styling.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.46.0"}}},"geometry-type":{doc:"Gets the feature's geometry type: `Point`, `MultiPoint`, `LineString`, `MultiLineString`, `Polygon`, `MultiPolygon`.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},id:{doc:"Gets the feature's id, if it has one.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},zoom:{doc:'Gets the current zoom level. Note that in style layout and paint properties, ["zoom"] may only appear as the input to a top-level "step" or "interpolate" expression.',group:"Zoom","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"heatmap-density":{doc:"Gets the kernel density estimation of a pixel in a heatmap layer, which is a relative measure of how many data points are crowded around a particular pixel. Can only be used in the `heatmap-color` property.",group:"Heatmap","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"line-progress":{doc:"Gets the progress along a gradient line. Can only be used in the `line-gradient` property.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.6.0",macos:"0.12.0"}}},accumulated:{doc:"Gets the value of a cluster property accumulated so far. Can only be used in the `clusterProperties` option of a clustered GeoJSON source.",group:"Feature data","sdk-support":{"basic functionality":{js:"0.53.0"}}},"+":{doc:"Returns the sum of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"*":{doc:"Returns the product of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"-":{doc:"For two inputs, returns the result of subtracting the second input from the first. For a single input, returns the result of subtracting it from 0.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"/":{doc:"Returns the result of floating point division of the first input by the second.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"%":{doc:"Returns the remainder after integer division of the first input by the second.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"^":{doc:"Returns the result of raising the first input to the power specified by the second.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},sqrt:{doc:"Returns the square root of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.42.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},log10:{doc:"Returns the base-ten logarithm of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},ln:{doc:"Returns the natural logarithm of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},log2:{doc:"Returns the base-two logarithm of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},sin:{doc:"Returns the sine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},cos:{doc:"Returns the cosine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},tan:{doc:"Returns the tangent of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},asin:{doc:"Returns the arcsine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},acos:{doc:"Returns the arccosine of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},atan:{doc:"Returns the arctangent of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},min:{doc:"Returns the minimum value of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},max:{doc:"Returns the maximum value of the inputs.",group:"Math","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},round:{doc:'Rounds the input to the nearest integer. Halfway values are rounded away from zero. For example, `["round", -1.5]` evaluates to -2.',group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},abs:{doc:"Returns the absolute value of the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},ceil:{doc:"Returns the smallest integer that is greater than or equal to the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},floor:{doc:"Returns the largest integer that is less than or equal to the input.",group:"Math","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},distance:{doc:"Returns the shortest distance in meters between the evaluated feature and the input geometry. The input value can be a valid GeoJSON of type `Point`, `MultiPoint`, `LineString`, `MultiLineString`, `Polygon`, `MultiPolygon`, `Feature`, or `FeatureCollection`. Distance values returned may vary in precision due to loss in precision from encoding geometries, particularly below zoom level 13.",group:"Math","sdk-support":{"basic functionality":{android:"9.2.0",ios:"5.9.0",macos:"0.16.0"}}},"==":{doc:"Returns `true` if the input values are equal, `false` otherwise. The comparison is strictly typed: values of different runtime types are always considered unequal. Cases where the types are known to be different at parse time are considered invalid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},"!=":{doc:"Returns `true` if the input values are not equal, `false` otherwise. The comparison is strictly typed: values of different runtime types are always considered unequal. Cases where the types are known to be different at parse time are considered invalid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},">":{doc:"Returns `true` if the first input is strictly greater than the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},"<":{doc:"Returns `true` if the first input is strictly less than the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},">=":{doc:"Returns `true` if the first input is greater than or equal to the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},"<=":{doc:"Returns `true` if the first input is less than or equal to the second, `false` otherwise. The arguments are required to be either both strings or both numbers; if during evaluation they are not, expression evaluation produces an error. Cases where this constraint is known not to hold at parse time are considered in valid and will produce a parse error. Accepts an optional `collator` argument to control locale-dependent string comparisons.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},collator:{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}},all:{doc:"Returns `true` if all the inputs are `true`, `false` otherwise. The inputs are evaluated in order, and evaluation is short-circuiting: once an input expression evaluates to `false`, the result is `false` and no further input expressions are evaluated.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},any:{doc:"Returns `true` if any of the inputs are `true`, `false` otherwise. The inputs are evaluated in order, and evaluation is short-circuiting: once an input expression evaluates to `true`, the result is `true` and no further input expressions are evaluated.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"!":{doc:"Logical negation. Returns `true` if the input is `false`, and `false` if the input is `true`.",group:"Decision","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},within:{doc:"Returns `true` if the evaluated feature is fully contained inside a boundary of the input geometry, `false` otherwise. The input value can be a valid GeoJSON of type `Polygon`, `MultiPolygon`, `Feature`, or `FeatureCollection`. Supported features for evaluation:\n- `Point`: Returns `false` if a point is on the boundary or falls outside the boundary.\n- `LineString`: Returns `false` if any part of a line falls outside the boundary, the line intersects the boundary, or a line's endpoint is on the boundary.",group:"Decision","sdk-support":{"basic functionality":{js:"1.9.0",android:"9.1.0",ios:"5.8.0",macos:"0.15.0"}}},"is-supported-script":{doc:"Returns `true` if the input string is expected to render legibly. Returns `false` if the input string contains sections that cannot be rendered without potential loss of meaning (e.g. Indic scripts that require complex text shaping, or right-to-left scripts if the the `mapbox-gl-rtl-text` plugin is not in use in MapLibre GL JS).",group:"String","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.6.0"}}},upcase:{doc:"Returns the input string converted to uppercase. Follows the Unicode Default Case Conversion algorithm and the locale-insensitive case mappings in the Unicode Character Database.",group:"String","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},downcase:{doc:"Returns the input string converted to lowercase. Follows the Unicode Default Case Conversion algorithm and the locale-insensitive case mappings in the Unicode Character Database.",group:"String","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},concat:{doc:"Returns a `string` consisting of the concatenation of the inputs. Each input is converted to a string as if by `to-string`.",group:"String","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}}},"resolved-locale":{doc:"Returns the IETF language tag of the locale being used by the provided `collator`. This can be used to determine the default system locale, or to determine if a requested locale was successfully loaded.",group:"String","sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.2.0",macos:"0.9.0"}}}}},Gde={anchor:{type:"enum",default:"viewport",values:{map:{doc:"The position of the light source is aligned to the rotation of the map."},viewport:{doc:"The position of the light source is aligned to the rotation of the viewport."}},"property-type":"data-constant",transition:!1,expression:{interpolated:!1,parameters:["zoom"]},doc:"Whether extruded geometries are lit relative to the map or viewport.",example:"map","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},position:{type:"array",default:[1.15,210,30],length:3,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},doc:"Position of the light source relative to lit (extruded) geometries, in [r radial coordinate, a azimuthal angle, p polar angle] where r indicates the distance from the center of the base of an object to its light, a indicates the position of the light relative to 0° (0° when `light.anchor` is set to `viewport` corresponds to the top of the viewport, or 0° when `light.anchor` is set to `map` corresponds to due north, and degrees proceed clockwise), and p indicates the height of the light (from 0°, directly above, to 180°, directly below).",example:[1.5,90,80],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Color tint for lighting extruded geometries.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}},intensity:{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"Intensity of lighting (on a scale from 0 to 1). Higher numbers will present as more extreme contrast.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}}}},Qde={"sky-color":{type:"color","property-type":"data-constant",default:"#88C6FC",expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"The base color for the sky."},"fog-color":{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"The base color for the fog."},"fog-blend":{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"How to blend the fog over the 3D terrain. A value between 0 and 1. Where 0 is the map center and 1 is the horizon"},"horizon-blend":{type:"number","property-type":"data-constant",default:.8,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0,doc:"How to blend the fog and sky color at the horizon. A value between 0 and 1. Where 0 is the horizon and 1 is map-height / 2"}},$de={source:{type:"string",doc:"The source for the terrain data.",required:!0,"sdk-support":{"basic functionality":{js:"2.2.0"}}},exaggeration:{type:"number",minimum:0,doc:"The exaggeration of the terrain - how high it will look.",default:1,"sdk-support":{"basic functionality":{js:"2.2.0"}}}},Yde=["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background"],qde={"fill-antialias":{type:"boolean",default:!0,doc:"Whether or not the fill should be antialiased.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity of the entire fill layer. In contrast to the `fill-color`, this value will also affect the 1px stroke around the fill, if the stroke is used.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.21.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{type:"color",default:"#000000",doc:"The color of the filled part of this layer. This color can be specified as `rgba` with an alpha component and the color's opacity will not affect the opacity of the 1px stroke, if it is used.",transition:!0,requires:[{"!":"fill-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.19.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{type:"color",doc:"The outline color of the fill. Matches the value of `fill-color` if unspecified.",transition:!0,requires:[{"!":"fill-pattern"},{"fill-antialias":!0}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.19.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{type:"enum",values:{map:{doc:"The fill is translated relative to the map."},viewport:{doc:"The fill is translated relative to the viewport."}},doc:"Controls the frame of reference for `fill-translate`.",default:"map",requires:["fill-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-pattern":{type:"resolvedImage",transition:!0,doc:"Name of image in sprite to use for drawing image fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.49.0",android:"6.5.0",macos:"0.11.0",ios:"4.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"}},Vde={"line-opacity":{type:"number",doc:"The opacity at which the line will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{type:"color",doc:"The color with which the line will be drawn.",default:"#000000",transition:!0,requires:[{"!":"line-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.23.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{type:"enum",values:{map:{doc:"The line is translated relative to the map."},viewport:{doc:"The line is translated relative to the viewport."}},doc:"Controls the frame of reference for `line-translate`.",default:"map",requires:["line-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-width":{type:"number",default:1,minimum:0,transition:!0,units:"pixels",doc:"Stroke thickness.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{type:"number",default:0,minimum:0,doc:"Draws a line casing outside of a line's actual path. Value indicates the width of the inner gap.",transition:!0,units:"pixels","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{type:"number",default:0,doc:"The line's offset. For linear features, a positive value offsets the line to the right, relative to the direction of the line, and a negative value to the left. For polygon features, a positive value results in an inset, and a negative value results in an outset.",transition:!0,units:"pixels","sdk-support":{"basic functionality":{js:"0.12.1",android:"3.0.0",ios:"3.1.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Blur applied to the line, in pixels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{type:"array",value:"number",doc:"Specifies the lengths of the alternating dashes and gaps that form the dash pattern. The lengths are later scaled by the line width. To convert a dash length to pixels, multiply the length by the current line width. Note that GeoJSON sources with `lineMetrics: true` specified won't render dashed lines to the expected scale. Also note that zoom-dependent expressions will be evaluated only at integer zoom levels.",minimum:0,transition:!0,units:"line widths",requires:[{"!":"line-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"line-pattern":{type:"resolvedImage",transition:!0,doc:"Name of image in sprite to use for drawing image lines. For seamless patterns, image width must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.49.0",android:"6.5.0",macos:"0.11.0",ios:"4.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-gradient":{type:"color",doc:'Defines a gradient with which to color a line feature. Can only be used with GeoJSON sources that specify `"lineMetrics": true`.',transition:!1,requires:[{"!":"line-dasharray"},{"!":"line-pattern"},{source:"geojson",has:{lineMetrics:!0}}],"sdk-support":{"basic functionality":{js:"0.45.0",android:"6.5.0",ios:"4.4.0",macos:"0.11.0"},"data-driven styling":{}},expression:{interpolated:!0,parameters:["line-progress"]},"property-type":"color-ramp"}},Hde={"circle-radius":{type:"number",default:5,minimum:0,transition:!0,units:"pixels",doc:"Circle radius.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.18.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{type:"color",default:"#000000",doc:"The fill color of the circle.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.18.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{type:"number",default:0,doc:"Amount to blur the circle. 1 blurs the circle such that only the centerpoint is full opacity.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.20.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{type:"number",doc:"The opacity at which the circle will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.20.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up, respectively.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{type:"enum",values:{map:{doc:"The circle is translated relative to the map."},viewport:{doc:"The circle is translated relative to the viewport."}},doc:"Controls the frame of reference for `circle-translate`.",default:"map",requires:["circle-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{type:"enum",values:{map:{doc:"Circles are scaled according to their apparent distance to the camera."},viewport:{doc:"Circles are not scaled."}},default:"map",doc:"Controls the scaling behavior of the circle when the map is pitched.","sdk-support":{"basic functionality":{js:"0.21.0",android:"4.2.0",ios:"3.4.0",macos:"0.2.1"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{type:"enum",values:{map:{doc:"The circle is aligned to the plane of the map."},viewport:{doc:"The circle is aligned to the plane of the viewport."}},default:"viewport",doc:"Orientation of circle when map is pitched.","sdk-support":{"basic functionality":{js:"0.39.0",android:"5.2.0",ios:"3.7.0",macos:"0.6.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"The width of the circle's stroke. Strokes are placed outside of the `circle-radius`.","sdk-support":{"basic functionality":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{type:"color",default:"#000000",doc:"The stroke color of the circle.",transition:!0,"sdk-support":{"basic functionality":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{type:"number",doc:"The opacity of the circle's stroke.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"},"data-driven styling":{js:"0.29.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"}},Zde={"heatmap-radius":{type:"number",default:30,minimum:1,transition:!0,units:"pixels",doc:"Radius of influence of one heatmap point in pixels. Increasing the value makes the heatmap smoother, but less detailed.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},"data-driven styling":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{type:"number",default:1,minimum:0,transition:!1,doc:"A measure of how much an individual point contributes to the heatmap. A value of 10 would be equivalent to having 10 points of weight 1 in the same spot. Especially useful when combined with clustering.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},"data-driven styling":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{type:"number",default:1,minimum:0,transition:!0,doc:"Similar to `heatmap-weight` but controls the intensity of the heatmap globally. Primarily used for adjusting the heatmap based on zoom level.","sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"heatmap-color":{type:"color",default:["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],doc:'Defines the color of each pixel based on its density value in a heatmap. Should be an expression that uses `["heatmap-density"]` as input.',transition:!1,"sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"},"data-driven styling":{}},expression:{interpolated:!0,parameters:["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{type:"number",doc:"The global opacity at which the heatmap layer will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.41.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},Xde={"icon-opacity":{doc:"The opacity at which the icon will be drawn.",type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{type:"color",default:"#000000",transition:!0,doc:"The color of the icon. This can only be used with SDF icons.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,doc:"The color of the icon's halo. Icon halos can only be used with SDF icons.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Distance of halo to the icon outline.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Fade out the halo towards the outside.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"Distance that the icon's anchor is moved from its original placement. Positive values indicate right and down, while negative values indicate left and up.",requires:["icon-image"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{type:"enum",values:{map:{doc:"Icons are translated relative to the map."},viewport:{doc:"Icons are translated relative to the viewport."}},doc:"Controls the frame of reference for `icon-translate`.",default:"map",requires:["icon-image","icon-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-opacity":{type:"number",doc:"The opacity at which the text will be drawn.",default:1,minimum:0,maximum:1,transition:!0,requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{type:"color",doc:"The color with which the text will be drawn.",default:"#000000",transition:!0,overridable:!0,requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,doc:"The color of the text's halo, which helps it stand out from backgrounds.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"Distance of halo to the font outline. Max text halo width is 1/4 of the font-size.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",doc:"The halo's fadeout distance towards the outside.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{js:"0.33.0",android:"5.0.0",ios:"3.5.0",macos:"0.4.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"Distance that the text's anchor is moved from its original placement. Positive values indicate right and down, while negative values indicate left and up.",requires:["text-field"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{type:"enum",values:{map:{doc:"The text is translated relative to the map."},viewport:{doc:"The text is translated relative to the viewport."}},doc:"Controls the frame of reference for `text-translate`.",default:"map",requires:["text-field","text-translate"],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},Jde={"raster-opacity":{type:"number",doc:"The opacity at which the image will be drawn.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{type:"number",default:0,period:360,transition:!0,units:"degrees",doc:"Rotates hues around the color wheel.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{type:"number",doc:"Increase or reduce the brightness of the image. The value is the minimum brightness.",default:0,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{type:"number",doc:"Increase or reduce the brightness of the image. The value is the maximum brightness.",default:1,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-saturation":{type:"number",doc:"Increase or reduce the saturation of the image.",default:0,minimum:-1,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-contrast":{type:"number",doc:"Increase or reduce the contrast of the image.",default:0,minimum:-1,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-resampling":{type:"enum",doc:"The resampling/interpolation method to use for overscaling, also known as texture magnification filter",values:{linear:{doc:"(Bi)linear filtering interpolates pixel values using the weighted average of the four closest original source pixels creating a smooth but blurry look when overscaled"},nearest:{doc:"Nearest neighbor filtering interpolates pixel values using the nearest original source pixel creating a sharp but pixelated look when overscaled"}},default:"linear","sdk-support":{"basic functionality":{js:"0.47.0",android:"6.3.0",ios:"4.2.0",macos:"0.9.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{type:"number",default:300,minimum:0,transition:!1,units:"milliseconds",doc:"Fade duration when a new tile is added, or when a video is started or its coordinates are updated.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},ehe={"hillshade-illumination-direction":{type:"number",default:335,minimum:0,maximum:359,doc:"The direction of the light source used to generate the hillshading with 0 as the top of the viewport if `hillshade-illumination-anchor` is set to `viewport` and due north if `hillshade-illumination-anchor` is set to `map`.",transition:!1,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{type:"enum",values:{map:{doc:"The hillshade illumination is relative to the north direction."},viewport:{doc:"The hillshade illumination is relative to the top of the viewport."}},default:"viewport",doc:"Direction of light source when map is rotated.","sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{type:"number",doc:"Intensity of the hillshade",default:.5,minimum:0,maximum:1,transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{type:"color",default:"#000000",doc:"The shading color of areas that face away from the light source.",transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"color",default:"#FFFFFF",doc:"The shading color of areas that faces towards the light source.",transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{type:"color",default:"#000000",doc:"The shading color used to accentuate rugged terrain like sharp cliffs and gorges.",transition:!0,"sdk-support":{"basic functionality":{js:"0.43.0",android:"6.0.0",ios:"4.0.0",macos:"0.7.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},the={"background-color":{type:"color",default:"#000000",doc:"The color with which the background will be drawn.",transition:!0,requires:[{"!":"background-pattern"}],"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"background-pattern":{type:"resolvedImage",transition:!0,doc:"Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"},"data-driven styling":{}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity at which the background will be drawn.",transition:!0,"sdk-support":{"basic functionality":{js:"0.10.0",android:"2.0.1",ios:"2.0.0",macos:"0.1.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},nhe={duration:{type:"number",default:300,minimum:0,units:"milliseconds",doc:"Time allotted for transitions to complete."},delay:{type:"number",default:0,minimum:0,units:"milliseconds",doc:"Length of time before a transition begins."}},rhe={"*":{type:"string",doc:"A name of a feature property to use as ID for feature state."}},Ji={$version:yde,$root:vde,sources:Cde,source:_de,source_vector:bde,source_raster:xde,source_raster_dem:wde,source_geojson:Mde,source_video:Sde,source_image:Ede,layer:Ode,layout:Bde,layout_background:kde,layout_fill:Ide,layout_circle:Tde,layout_heatmap:Kde,"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{doc:"The layer is shown."},none:{doc:"The layer is not shown."}},default:"visible",doc:"Whether this layer is displayed.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},"property-type":"constant"}},layout_line:Pde,layout_symbol:Fde,layout_raster:Dde,layout_hillshade:Ude,filter:Rde,filter_operator:Lde,geometry_type:zde,function:{expression:{type:"expression",doc:"An expression."},stops:{type:"array",doc:"An array of stops.",value:"function_stop"},base:{type:"number",default:1,minimum:0,doc:"The exponential base of the interpolation curve. It controls the rate at which the result increases. Higher values make the result increase more towards the high end of the range. With `1` the stops are interpolated linearly."},property:{type:"string",doc:"The name of a feature property to use as the function input.",default:"$zoom"},type:{type:"enum",values:{identity:{doc:"Return the input value as the output value."},exponential:{doc:"Generate an output by interpolating between stops just less than and just greater than the function input."},interval:{doc:"Return the output value of the stop just less than the function input."},categorical:{doc:"Return the output value of the stop equal to the function input."}},doc:"The interpolation strategy to use in function evaluation.",default:"exponential"},colorSpace:{type:"enum",values:{rgb:{doc:"Use the RGB color space to interpolate color values"},lab:{doc:"Use the LAB color space to interpolate color values."},hcl:{doc:"Use the HCL color space to interpolate color values, interpolating the Hue, Chroma, and Luminance channels individually."}},doc:"The color space in which colors interpolated. Interpolating colors in perceptual color spaces like LAB and HCL tend to produce color ramps that look more consistent and produce colors that can be differentiated more easily than those interpolated in RGB space.",default:"rgb"},default:{type:"*",required:!1,doc:`A value to serve as a fallback function result when a value isn't otherwise available. It is used in the following circumstances:
|
||
* In categorical functions, when the feature value does not match any of the stop domain values.
|
||
* In property and zoom-and-property functions, when a feature does not contain a value for the specified property.
|
||
* In identity functions, when the feature value is not valid for the style property (for example, if the function is being used for a \`circle-color\` property but the feature property value is not a string or not a valid color).
|
||
* In interval or exponential property and zoom-and-property functions, when the feature value is not numeric.
|
||
If no default is provided, the style property's default is used in these circumstances.`}},function_stop:jde,expression:Wde,expression_name:Nde,light:Gde,sky:Qde,terrain:$de,paint:Yde,paint_fill:qde,"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",default:1,minimum:0,maximum:1,doc:"The opacity of the entire fill extrusion layer. This is rendered on a per-layer, not per-feature, basis, and data-driven styling is not available.",transition:!0,"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{type:"color",default:"#000000",doc:"The base color of the extruded fill. The extrusion's surfaces will be shaded differently based on this color in combination with the root `light` settings. If this color is specified as `rgba` with an alpha component, the alpha component will be ignored; use `fill-extrusion-opacity` to set layer opacity.",transition:!0,requires:[{"!":"fill-extrusion-pattern"}],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",doc:"The geometry's offset. Values are [x, y] where negatives indicate left and up (on the flat plane), respectively.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{type:"enum",values:{map:{doc:"The fill extrusion is translated relative to the map."},viewport:{doc:"The fill extrusion is translated relative to the viewport."}},doc:"Controls the frame of reference for `fill-extrusion-translate`.",default:"map",requires:["fill-extrusion-translate"],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{type:"resolvedImage",transition:!0,doc:"Name of image in sprite to use for drawing images on extruded fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.","sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.49.0",android:"6.5.0",macos:"0.11.0",ios:"4.4.0"}},expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"fill-extrusion-height":{type:"number",default:0,minimum:0,units:"meters",doc:"The height with which to extrude this layer.",transition:!0,"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{type:"number",default:0,minimum:0,units:"meters",doc:"The height with which to extrude the base of this layer. Must be less than or equal to `fill-extrusion-height`.",transition:!0,requires:["fill-extrusion-height"],"sdk-support":{"basic functionality":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"},"data-driven styling":{js:"0.27.0",android:"5.1.0",ios:"3.6.0",macos:"0.5.0"}},expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{type:"boolean",default:!0,doc:"Whether to apply a vertical gradient to the sides of a fill-extrusion layer. If true, sides will be shaded slightly darker farther down.",transition:!1,"sdk-support":{"basic functionality":{js:"0.50.0",ios:"4.7.0",macos:"0.13.0"}},expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_line:Vde,paint_circle:Hde,paint_heatmap:Zde,paint_symbol:Xde,paint_raster:Jde,paint_hillshade:ehe,paint_background:the,transition:nhe,"property-type":{"data-driven":{type:"property-type",doc:"Property is interpolable and can be represented using a property expression."},"cross-faded":{type:"property-type",doc:"Property is non-interpolable; rather, its values will be cross-faded to smoothly transition between integer zooms."},"cross-faded-data-driven":{type:"property-type",doc:"Property is non-interpolable; rather, its values will be cross-faded to smoothly transition between integer zooms. It can be represented using a property expression."},"color-ramp":{type:"property-type",doc:"Property should be specified using a color ramp from which the output color can be sampled based on a property calculation."},"data-constant":{type:"property-type",doc:"Property is interpolable but cannot be represented using a property expression."},constant:{type:"property-type",doc:"Property is constant across all zoom levels and property values."}},promoteId:rhe};function yu(){var e="/home/runner/work/maputnik/maputnik/src/components/InputSelect.tsx",n="1b99a181d4a9dd7b629113889cbb71c3a4bb4d42",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputSelect.tsx",statementMap:{0:{start:{line:5,column:18},end:{line:5,column:36}},1:{start:{line:6,column:4},end:{line:8,column:5}},2:{start:{line:7,column:6},end:{line:7,column:43}},3:{start:{line:7,column:35},end:{line:7,column:41}},4:{start:{line:9,column:4},end:{line:21,column:6}},5:{start:{line:17,column:25},end:{line:17,column:60}},6:{start:{line:19,column:64},end:{line:19,column:115}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:4,column:2},end:{line:4,column:3}},loc:{start:{line:4,column:11},end:{line:22,column:3}},line:4},1:{name:"(anonymous_1)",decl:{start:{line:7,column:28},end:{line:7,column:29}},loc:{start:{line:7,column:35},end:{line:7,column:41}},line:7},2:{name:"(anonymous_2)",decl:{start:{line:17,column:18},end:{line:17,column:19}},loc:{start:{line:17,column:25},end:{line:17,column:60}},line:17},3:{name:"(anonymous_3)",decl:{start:{line:19,column:30},end:{line:19,column:31}},loc:{start:{line:19,column:64},end:{line:19,column:115}},line:19}},branchMap:{0:{loc:{start:{line:6,column:4},end:{line:8,column:5}},type:"if",locations:[{start:{line:6,column:4},end:{line:8,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:6},1:{loc:{start:{line:6,column:8},end:{line:6,column:56}},type:"binary-expr",locations:[{start:{line:6,column:8},end:{line:6,column:26}},{start:{line:6,column:30},end:{line:6,column:56}}],line:6}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},f:{0:0,1:0,2:0,3:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputSelect.tsx"],names:[],mappings:"AA4BsC;AA5BtC,OAAO,WAAW;AAYlB,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,SAAS;AACP,QAAI,UAAU,KAAK,MAAM;AACzB,QAAG,QAAQ,SAAS,KAAK,CAAC,MAAM,QAAQ,QAAQ,CAAC,CAAC,GAAG;AACnD,gBAAU,QAAQ,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;AAAA,IACrC;AAEA,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,eAAa,KAAK,MAAM,aAAa;AAAA,QACrC,OAAO,KAAK,MAAM;AAAA,QAClB,OAAO,KAAK,MAAM;AAAA,QAClB,OAAO,KAAK,MAAM;AAAA,QAClB,UAAU,OAAK,KAAK,MAAM,SAAS,EAAE,OAAO,KAAK;AAAA,QACjD,cAAY,KAAK,MAAM,YAAY;AAAA,QAEjC,kBAAQ,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM,oBAAC,YAAiB,OAAO,KAAM,mBAAlB,GAAwB,CAAS;AAAA;AAAA,IAChF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"1b99a181d4a9dd7b629113889cbb71c3a4bb4d42"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return yu=function(){return s},s}yu();class w1 extends bn.Component{render(){yu().f[0]++;let n=(yu().s[0]++,this.props.options);return yu().s[1]++,yu().b[1][0]++,n.length>0&&(yu().b[1][1]++,!Array.isArray(n[0]))?(yu().b[0][0]++,yu().s[2]++,n=n.map(t=>(yu().f[1]++,yu().s[3]++,[t,t]))):yu().b[0][1]++,yu().s[4]++,N.jsx("select",{className:"maputnik-select","data-wd-key":this.props["data-wd-key"],style:this.props.style,title:this.props.title,value:this.props.value,onChange:t=>(yu().f[2]++,yu().s[5]++,this.props.onChange(t.target.value)),"aria-label":this.props["aria-label"],children:n.map(([t,r])=>(yu().f[3]++,yu().s[6]++,N.jsx("option",{value:t,children:r},t)))})}}function ap(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldType.tsx",n="1b7060ffc75823b83956b34c84f8d7f711912270",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldType.tsx",statementMap:{0:{start:{line:8,column:24},end:{line:10,column:3}},1:{start:{line:12,column:4},end:{line:48,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:11,column:2},end:{line:11,column:3}},loc:{start:{line:11,column:11},end:{line:49,column:3}},line:11}},branchMap:{0:{loc:{start:{line:20,column:10},end:{line:26,column:11}},type:"binary-expr",locations:[{start:{line:20,column:10},end:{line:20,column:29}},{start:{line:20,column:49},end:{line:26,column:11}}],line:20},1:{loc:{start:{line:27,column:10},end:{line:45,column:11}},type:"binary-expr",locations:[{start:{line:27,column:10},end:{line:27,column:30}},{start:{line:27,column:50},end:{line:45,column:11}}],line:27}},s:{0:0,1:0},f:{0:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldType.tsx"],names:[],mappings:"AAqBW,SAKH,KALG;AArBX,OAAO,WAAW;AAElB,OAAO,YAAY;AACnB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AAUxB,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,OAAO,eAAe;AAAA,IACpB,UAAU;AAAA,EACZ;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QAAM,OAAO;AAAA,QAAQ,WAAW,OAAO,MAAM;AAAA,QACnD,eAAa,KAAK,MAAM;AAAA,QACxB,OAAO,KAAK,MAAM;AAAA,QAEjB;AAAA,eAAK,MAAM,YACV;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,KAAK,MAAM;AAAA,cAClB,UAAU;AAAA;AAAA,UACZ;AAAA,UAED,CAAC,KAAK,MAAM,YACX;AAAA,YAAC;AAAA;AAAA,cACC,SAAS;AAAA,gBACP,CAAC,cAAc,YAAY;AAAA,gBAC3B,CAAC,QAAQ,MAAM;AAAA,gBACf,CAAC,QAAQ,MAAM;AAAA,gBACf,CAAC,UAAU,QAAQ;AAAA,gBACnB,CAAC,UAAU,QAAQ;AAAA,gBACnB,CAAC,UAAU,QAAQ;AAAA,gBACnB,CAAC,kBAAkB,gBAAgB;AAAA,gBACnC,CAAC,aAAa,WAAW;AAAA,gBACzB,CAAC,WAAW,SAAS;AAAA,cACvB;AAAA,cACA,UAAU,KAAK,MAAM;AAAA,cACrB,OAAO,KAAK,MAAM;AAAA,cAClB,eAAa,KAAK,MAAM,QAAQ;AAAA;AAAA,UAClC;AAAA;AAAA;AAAA,IAEJ;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"1b7060ffc75823b83956b34c84f8d7f711912270"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ap=function(){return s},s}ap();class e8 extends bn.Component{render(){return ap().f[0]++,ap().s[1]++,N.jsxs(Uo,{label:"Type",fieldSpec:Ji.layer.type,"data-wd-key":this.props.wdKey,error:this.props.error,children:[(ap().b[0][0]++,this.props.disabled&&(ap().b[0][1]++,N.jsx(Sd,{value:this.props.value,disabled:!0}))),(ap().b[1][0]++,!this.props.disabled&&(ap().b[1][1]++,N.jsx(w1,{options:[["background","Background"],["fill","Fill"],["line","Line"],["symbol","Symbol"],["raster","Raster"],["circle","Circle"],["fill-extrusion","Fill Extrusion"],["hillshade","Hillshade"],["heatmap","Heatmap"]],onChange:this.props.onChange,value:this.props.value,"data-wd-key":this.props.wdKey+".select"})))]})}}nn(e8,"defaultProps",(ap().s[0]++,{disabled:!1}));function X3(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldId.tsx",n="a7d93cb2f79962c714e16c8b482f49de057b0cb8",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldId.tsx",statementMap:{0:{start:{line:8,column:4},end:{line:24,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:2},end:{line:7,column:3}},loc:{start:{line:7,column:11},end:{line:25,column:3}},line:7}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldId.tsx"],names:[],mappings:"AAmBM;AAnBN,OAAO,WAAW;AAElB,OAAO,YAAY;AACnB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AASxB,qBAAqB,gBAAgB,MAAM,UAAwB;AAAA,EACjE,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QAAM,OAAO;AAAA,QAAM,WAAW,OAAO,MAAM;AAAA,QACjD,eAAa,KAAK,MAAM;AAAA,QACxB,OAAO,KAAK,MAAM;AAAA,QAElB;AAAA,UAAC;AAAA;AAAA,YACC,OAAO,KAAK,MAAM;AAAA,YAClB,SAAS,KAAK,MAAM;AAAA,YACpB,eAAa,KAAK,MAAM,QAAQ;AAAA;AAAA,QAClC;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a7d93cb2f79962c714e16c8b482f49de057b0cb8"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return X3=function(){return s},s}X3();class Jj extends bn.Component{render(){return X3().f[0]++,X3().s[0]++,N.jsx(Uo,{label:"ID",fieldSpec:Ji.layer.id,"data-wd-key":this.props.wdKey,error:this.props.error,children:N.jsx(Sd,{value:this.props.value,onInput:this.props.onChange,"data-wd-key":this.props.wdKey+".input"})})}}var eW={exports:{}},ihe=/[\-+]?(?:\d*\.|)\d+(?:[eE][\-+]?\d+|)/.source;function ohe(e){var n,t,r,i=e.ownerDocument,o=i.body,s=i&&i.documentElement;return n=e.getBoundingClientRect(),t=n.left,r=n.top,t-=s.clientLeft||o.clientLeft||0,r-=s.clientTop||o.clientTop||0,{left:t,top:r}}function tW(e,n){var t=e["page"+(n?"Y":"X")+"Offset"],r="scroll"+(n?"Top":"Left");if(typeof t!="number"){var i=e.document;t=i.documentElement[r],typeof t!="number"&&(t=i.body[r])}return t}function TE(e){return tW(e)}function KE(e){return tW(e,!0)}function nW(e){var n=ohe(e),t=e.ownerDocument,r=t.defaultView||t.parentWindow;return n.left+=TE(r),n.top+=KE(r),n}function ahe(e,n,t){var r="",i=e.ownerDocument;return(t=t||i.defaultView.getComputedStyle(e,null))&&(r=t.getPropertyValue(n)||t[n]),r}var she=new RegExp("^("+ihe+")(?!px)[a-z%]+$","i"),lhe=/^(top|right|bottom|left)$/,GM="currentStyle",QM="runtimeStyle",b0="left",uhe="px";function Ahe(e,n){var t=e[GM]&&e[GM][n];if(she.test(t)&&!lhe.test(n)){var r=e.style,i=r[b0],o=e[QM][b0];e[QM][b0]=e[GM][b0],r[b0]=n==="fontSize"?"1em":t||0,t=r.pixelLeft+uhe,r[b0]=i,e[QM][b0]=o}return t===""?"auto":t}var m1;typeof window<"u"&&(m1=window.getComputedStyle?ahe:Ahe);function che(e,n){ly(e,"position")==="static"&&(e.style.position="relative");var t=nW(e),r={},i,o;for(o in n)i=parseFloat(ly(e,o))||0,r[o]=i+n[o]-t[o];ly(e,r)}function t8(e,n){for(var t=0;t<e.length;t++)n(e[t])}function rW(e){return m1(e,"boxSizing")==="border-box"}var dhe=["margin","border","padding"],PE=-1,hhe=2,FE=1,fhe=0;function phe(e,n,t){var r={},i=e.style,o;for(o in n)r[o]=i[o],i[o]=n[o];t.call(e);for(o in n)i[o]=r[o]}function mC(e,n,t){var r=0,i,o,s;for(o=0;o<n.length;o++)if(i=n[o],i)for(s=0;s<t.length;s++){var a;i==="border"?a=i+t[s]+"Width":a=i+t[s],r+=parseFloat(m1(e,a))||0}return r}function b2(e){return e!=null&&e==e.window}var nf={};t8(["Width","Height"],function(e){nf["doc"+e]=function(n){var t=n.document;return Math.max(t.documentElement["scroll"+e],t.body["scroll"+e],nf["viewport"+e](t))},nf["viewport"+e]=function(n){var t="client"+e,r=n.document,i=r.body,o=r.documentElement,s=o[t];return r.compatMode==="CSS1Compat"&&s||i&&i[t]||s}});function DT(e,n,t){if(b2(e))return n==="width"?nf.viewportWidth(e):nf.viewportHeight(e);if(e.nodeType===9)return n==="width"?nf.docWidth(e):nf.docHeight(e);var r=n==="width"?["Left","Right"]:["Top","Bottom"],i=n==="width"?e.offsetWidth:e.offsetHeight;m1(e);var o=rW(e),s=0;(i==null||i<=0)&&(i=void 0,s=m1(e,n),(s==null||Number(s)<0)&&(s=e.style[n]||0),s=parseFloat(s)||0),t===void 0&&(t=o?FE:PE);var a=i!==void 0||o,f=i||s;return t===PE?a?f-mC(e,["border","padding"],r):s:a?f+(t===FE?0:t===hhe?-mC(e,["border"],r):mC(e,["margin"],r)):s+mC(e,dhe.slice(t),r)}var mhe={position:"absolute",visibility:"hidden",display:"block"};function UT(e){var n,t=arguments;return e.offsetWidth!==0?n=DT.apply(void 0,t):phe(e,mhe,function(){n=DT.apply(void 0,t)}),n}t8(["width","height"],function(e){var n=e.charAt(0).toUpperCase()+e.slice(1);nf["outer"+n]=function(r,i){return r&&UT(r,e,i?fhe:FE)};var t=e==="width"?["Left","Right"]:["Top","Bottom"];nf[e]=function(r,i){if(i!==void 0){if(r){m1(r);var o=rW(r);return o&&(i+=mC(r,["padding","border"],t)),ly(r,e,i)}return}return r&&UT(r,e,PE)}});function ly(e,n,t){if(typeof n=="object"){for(var r in n)ly(e,r,n[r]);return}if(typeof t<"u")typeof t=="number"&&(t=t+"px"),e.style[n]=t;else return m1(e,n)}function iW(e,n){for(var t in n)e[t]=n[t];return e}var oW=eW.exports={getWindow:function(e){var n=e.ownerDocument||e;return n.defaultView||n.parentWindow},offset:function(e,n){if(typeof n<"u")che(e,n);else return nW(e)},isWindow:b2,each:t8,css:ly,clone:function(e){var n={};for(var t in e)n[t]=e[t];var r=e.overflow;if(r)for(t in e)n.overflow[t]=e.overflow[t];return n},mix:iW,scrollLeft:function(e,n){if(b2(e)){if(n===void 0)return TE(e);window.scrollTo(n,KE(e))}else{if(n===void 0)return e.scrollLeft;e.scrollLeft=n}},scrollTop:function(e,n){if(b2(e)){if(n===void 0)return KE(e);window.scrollTo(TE(e),n)}else{if(n===void 0)return e.scrollTop;e.scrollTop=n}},merge:function(){for(var e={},n=0;n<arguments.length;n++)oW.mix(e,arguments[n]);return e},viewportWidth:0,viewportHeight:0};iW(oW,nf);var ghe=eW.exports,Ra=ghe;function yhe(e,n,t){t=t||{},n.nodeType===9&&(n=Ra.getWindow(n));var r=t.allowHorizontalScroll,i=t.onlyScrollIfNeeded,o=t.alignWithTop,s=t.alignWithLeft;r=r===void 0?!0:r;var a=Ra.isWindow(n),f=Ra.offset(e),g=Ra.outerHeight(e),x=Ra.outerWidth(e),k,B,P,R,H,W,$,q,oe,ne;a?($=n,ne=Ra.height($),oe=Ra.width($),q={left:Ra.scrollLeft($),top:Ra.scrollTop($)},H={left:f.left-q.left,top:f.top-q.top},W={left:f.left+x-(q.left+oe),top:f.top+g-(q.top+ne)},R=q):(k=Ra.offset(n),B=n.clientHeight,P=n.clientWidth,R={left:n.scrollLeft,top:n.scrollTop},H={left:f.left-(k.left+(parseFloat(Ra.css(n,"borderLeftWidth"))||0)),top:f.top-(k.top+(parseFloat(Ra.css(n,"borderTopWidth"))||0))},W={left:f.left+x-(k.left+P+(parseFloat(Ra.css(n,"borderRightWidth"))||0)),top:f.top+g-(k.top+B+(parseFloat(Ra.css(n,"borderBottomWidth"))||0))}),H.top<0||W.top>0?o===!0?Ra.scrollTop(n,R.top+H.top):o===!1?Ra.scrollTop(n,R.top+W.top):H.top<0?Ra.scrollTop(n,R.top+H.top):Ra.scrollTop(n,R.top+W.top):i||(o=o===void 0?!0:!!o,o?Ra.scrollTop(n,R.top+H.top):Ra.scrollTop(n,R.top+W.top)),r&&(H.left<0||W.left>0?s===!0?Ra.scrollLeft(n,R.left+H.left):s===!1?Ra.scrollLeft(n,R.left+W.left):H.left<0?Ra.scrollLeft(n,R.left+H.left):Ra.scrollLeft(n,R.left+W.left):i||(s=s===void 0?!0:!!s,s?Ra.scrollLeft(n,R.left+H.left):Ra.scrollLeft(n,R.left+W.left)))}var vhe=yhe,Che=vhe,x2=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},_he=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}();function bhe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function xhe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function whe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var P0=kr,gl=ph,Mhe=Rm,RT=Mhe.findDOMNode,She=Che,Ehe=["blur","checkValidity","click","focus","select","setCustomValidity","setSelectionRange","setRangeText"];function Ohe(){return{x:window.pageXOffset!==void 0?window.pageXOffset:(document.documentElement||document.body.parentNode||document.body).scrollLeft,y:window.pageYOffset!==void 0?window.pageYOffset:(document.documentElement||document.body.parentNode||document.body).scrollTop}}var S5=function(e){whe(n,e);function n(t){bhe(this,n);var r=xhe(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,t));return r.state={isOpen:!1,highlightedIndex:null},r._debugStates=[],r.ensureHighlightedIndex=r.ensureHighlightedIndex.bind(r),r.exposeAPI=r.exposeAPI.bind(r),r.handleInputFocus=r.handleInputFocus.bind(r),r.handleInputBlur=r.handleInputBlur.bind(r),r.handleChange=r.handleChange.bind(r),r.handleKeyDown=r.handleKeyDown.bind(r),r.handleInputClick=r.handleInputClick.bind(r),r.maybeAutoCompleteText=r.maybeAutoCompleteText.bind(r),r}return _he(n,[{key:"componentWillMount",value:function(){this.refs={},this._ignoreBlur=!1,this._ignoreFocus=!1,this._scrollOffset=null,this._scrollTimer=null}},{key:"componentWillUnmount",value:function(){clearTimeout(this._scrollTimer),this._scrollTimer=null}},{key:"componentWillReceiveProps",value:function(r){this.state.highlightedIndex!==null&&this.setState(this.ensureHighlightedIndex),r.autoHighlight&&(this.props.value!==r.value||this.state.highlightedIndex===null)&&this.setState(this.maybeAutoCompleteText)}},{key:"componentDidMount",value:function(){this.isOpen()&&this.setMenuPositions()}},{key:"componentDidUpdate",value:function(r,i){(this.state.isOpen&&!i.isOpen||"open"in this.props&&this.props.open&&!r.open)&&this.setMenuPositions(),this.maybeScrollItemIntoView(),i.isOpen!==this.state.isOpen&&this.props.onMenuVisibilityChange(this.state.isOpen)}},{key:"exposeAPI",value:function(r){var i=this;this.refs.input=r,Ehe.forEach(function(o){return i[o]=r&&r[o]&&r[o].bind(r)})}},{key:"maybeScrollItemIntoView",value:function(){if(this.isOpen()&&this.state.highlightedIndex!==null){var r=this.refs["item-"+this.state.highlightedIndex],i=this.refs.menu;She(RT(r),RT(i),{onlyScrollIfNeeded:!0})}}},{key:"handleKeyDown",value:function(r){n.keyDownHandlers[r.key]?n.keyDownHandlers[r.key].call(this,r):this.isOpen()||this.setState({isOpen:!0})}},{key:"handleChange",value:function(r){this.props.onChange(r,r.target.value)}},{key:"getFilteredItems",value:function(r){var i=r.items;return r.shouldItemRender&&(i=i.filter(function(o){return r.shouldItemRender(o,r.value)})),r.sortItems&&i.sort(function(o,s){return r.sortItems(o,s,r.value)}),i}},{key:"maybeAutoCompleteText",value:function(r,i){for(var o=r.highlightedIndex,s=i.value,a=i.getItemValue,f=o===null?0:o,g=this.getFilteredItems(i),x=0;x<g.length&&!i.isItemSelectable(g[f]);x++)f=(f+1)%g.length;var k=g[f]&&i.isItemSelectable(g[f])?g[f]:null;if(s!==""&&k){var B=a(k),P=B.toLowerCase().indexOf(s.toLowerCase())===0;if(P)return{highlightedIndex:f}}return{highlightedIndex:null}}},{key:"ensureHighlightedIndex",value:function(r,i){if(r.highlightedIndex>=this.getFilteredItems(i).length)return{highlightedIndex:null}}},{key:"setMenuPositions",value:function(){var r=this.refs.input,i=r.getBoundingClientRect(),o=window.window.getComputedStyle(r),s=parseInt(o.marginBottom,10)||0,a=parseInt(o.marginLeft,10)||0,f=parseInt(o.marginRight,10)||0;this.setState({menuTop:i.bottom+s,menuLeft:i.left+a,menuWidth:i.width+a+f})}},{key:"highlightItemFromMouse",value:function(r){this.setState({highlightedIndex:r})}},{key:"selectItemFromMouse",value:function(r){var i=this,o=this.props.getItemValue(r);this.setIgnoreBlur(!1),this.setState({isOpen:!1,highlightedIndex:null},function(){i.props.onSelect(o,r)})}},{key:"setIgnoreBlur",value:function(r){this._ignoreBlur=r}},{key:"renderMenu",value:function(){var r=this,i=this.getFilteredItems(this.props).map(function(a,f){var g=r.props.renderItem(a,r.state.highlightedIndex===f,{cursor:"default"});return P0.cloneElement(g,{onMouseEnter:r.props.isItemSelectable(a)?function(){return r.highlightItemFromMouse(f)}:null,onClick:r.props.isItemSelectable(a)?function(){return r.selectItemFromMouse(a)}:null,ref:function(k){return r.refs["item-"+f]=k}})}),o={left:this.state.menuLeft,top:this.state.menuTop,minWidth:this.state.menuWidth},s=this.props.renderMenu(i,this.props.value,o);return P0.cloneElement(s,{ref:function(f){return r.refs.menu=f},onTouchStart:function(){return r.setIgnoreBlur(!0)},onMouseEnter:function(){return r.setIgnoreBlur(!0)},onMouseLeave:function(){return r.setIgnoreBlur(!1)}})}},{key:"handleInputBlur",value:function(r){var i=this;if(this._ignoreBlur){this._ignoreFocus=!0,this._scrollOffset=Ohe(),this.refs.input.focus();return}var o=void 0,s=this.state.highlightedIndex;if(this.props.selectOnBlur&&s!==null){var a=this.getFilteredItems(this.props),f=a[s],g=this.props.getItemValue(f);o=function(){return i.props.onSelect(g,f)}}this.setState({isOpen:!1,highlightedIndex:null},o);var x=this.props.inputProps.onBlur;x&&x(r)}},{key:"handleInputFocus",value:function(r){var i=this;if(this._ignoreFocus){this._ignoreFocus=!1;var o=this._scrollOffset,s=o.x,a=o.y;this._scrollOffset=null,window.scrollTo(s,a),clearTimeout(this._scrollTimer),this._scrollTimer=setTimeout(function(){i._scrollTimer=null,window.scrollTo(s,a)},0);return}this.setState({isOpen:!0});var f=this.props.inputProps.onFocus;f&&f(r)}},{key:"isInputFocused",value:function(){var r=this.refs.input;return r.ownerDocument&&r===r.ownerDocument.activeElement}},{key:"handleInputClick",value:function(){this.isInputFocused()&&!this.isOpen()&&this.setState({isOpen:!0})}},{key:"composeEventHandlers",value:function(r,i){return i?function(o){r(o),i(o)}:r}},{key:"isOpen",value:function(){return"open"in this.props?this.props.open:this.state.isOpen}},{key:"render",value:function(){this.props.debug&&this._debugStates.push({id:this._debugStates.length,state:this.state});var r=this.props.inputProps,i=this.isOpen();return P0.createElement("div",x2({style:x2({},this.props.wrapperStyle)},this.props.wrapperProps),this.props.renderInput(x2({},r,{role:"combobox","aria-autocomplete":"list","aria-expanded":i,autoComplete:"off",ref:this.exposeAPI,onFocus:this.handleInputFocus,onBlur:this.handleInputBlur,onChange:this.handleChange,onKeyDown:this.composeEventHandlers(this.handleKeyDown,r.onKeyDown),onClick:this.composeEventHandlers(this.handleInputClick,r.onClick),value:this.props.value})),i&&this.renderMenu(),this.props.debug&&P0.createElement("pre",{style:{marginLeft:300}},JSON.stringify(this._debugStates.slice(Math.max(0,this._debugStates.length-5),this._debugStates.length),null,2)))}}]),n}(P0.Component);S5.propTypes={items:gl.array.isRequired,value:gl.any,onChange:gl.func,onSelect:gl.func,shouldItemRender:gl.func,isItemSelectable:gl.func,sortItems:gl.func,getItemValue:gl.func.isRequired,renderItem:gl.func.isRequired,renderMenu:gl.func,menuStyle:gl.object,renderInput:gl.func,inputProps:gl.object,wrapperProps:gl.object,wrapperStyle:gl.object,autoHighlight:gl.bool,selectOnBlur:gl.bool,onMenuVisibilityChange:gl.func,open:gl.bool,debug:gl.bool};S5.defaultProps={value:"",wrapperProps:{},wrapperStyle:{display:"inline-block"},inputProps:{},renderInput:function(n){return P0.createElement("input",n)},onChange:function(){},onSelect:function(){},isItemSelectable:function(){return!0},renderMenu:function(n,t,r){return P0.createElement("div",{style:x2({},r,this.menuStyle),children:n})},menuStyle:{borderRadius:"3px",boxShadow:"0 2px 12px rgba(0, 0, 0, 0.1)",background:"rgba(255, 255, 255, 0.9)",padding:"2px 0",fontSize:"90%",position:"fixed",overflow:"auto",maxHeight:"50%"},autoHighlight:!0,selectOnBlur:!1,onMenuVisibilityChange:function(){}};S5.keyDownHandlers={ArrowDown:function(n){n.preventDefault();var t=this.getFilteredItems(this.props);if(t.length){for(var r=this.state.highlightedIndex,i=r===null?-1:r,o=0;o<t.length;o++){var s=(i+o+1)%t.length;if(this.props.isItemSelectable(t[s])){i=s;break}}i>-1&&i!==r&&this.setState({highlightedIndex:i,isOpen:!0})}},ArrowUp:function(n){n.preventDefault();var t=this.getFilteredItems(this.props);if(t.length){for(var r=this.state.highlightedIndex,i=r===null?t.length:r,o=0;o<t.length;o++){var s=(i-(1+o)+t.length)%t.length;if(this.props.isItemSelectable(t[s])){i=s;break}}i!==t.length&&this.setState({highlightedIndex:i,isOpen:!0})}},Enter:function(n){var t=this;if(n.keyCode===13)if(this.setIgnoreBlur(!1),this.isOpen())if(this.state.highlightedIndex==null)this.setState({isOpen:!1},function(){t.refs.input.select()});else{n.preventDefault();var r=this.getFilteredItems(this.props)[this.state.highlightedIndex],i=this.props.getItemValue(r);this.setState({isOpen:!1,highlightedIndex:null},function(){t.refs.input.setSelectionRange(i.length,i.length),t.props.onSelect(i,r)})}else return},Escape:function(){this.setIgnoreBlur(!1),this.setState({highlightedIndex:null,isOpen:!1})},Tab:function(){this.setIgnoreBlur(!1)}};var Bhe=S5;const khe=ga(Bhe);function Ni(){var e="/home/runner/work/maputnik/maputnik/src/components/InputAutocomplete.tsx",n="6ef9facf9aeabdae687b5aca973710969d826d60",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputAutocomplete.tsx",statementMap:{0:{start:{line:5,column:19},end:{line:5,column:22}},1:{start:{line:7,column:10},end:{line:9,column:3}},2:{start:{line:10,column:23},end:{line:10,column:27}},3:{start:{line:11,column:24},end:{line:15,column:3}},4:{start:{line:17,column:4},end:{line:25,column:5}},5:{start:{line:18,column:24},end:{line:18,column:96}},6:{start:{line:19,column:31},end:{line:19,column:62}},7:{start:{line:20,column:6},end:{line:24,column:7}},8:{start:{line:21,column:8},end:{line:23,column:11}},9:{start:{line:28,column:4},end:{line:28,column:25}},10:{start:{line:31,column:4},end:{line:31,column:25}},11:{start:{line:34,column:4},end:{line:34,column:47}},12:{start:{line:37,column:4},end:{line:86,column:6}},13:{start:{line:41,column:10},end:{line:41,column:39}},14:{start:{line:63,column:36},end:{line:63,column:43}},15:{start:{line:64,column:29},end:{line:64,column:45}},16:{start:{line:65,column:33},end:{line:65,column:49}},17:{start:{line:67,column:14},end:{line:69,column:15}},18:{start:{line:68,column:16},end:{line:68,column:79}},19:{start:{line:70,column:14},end:{line:70,column:27}},20:{start:{line:72,column:65},end:{line:82,column:13}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:12,column:14},end:{line:12,column:15}},loc:{start:{line:12,column:20},end:{line:13,column:5}},line:12},1:{name:"(anonymous_1)",decl:{start:{line:16,column:2},end:{line:16,column:3}},loc:{start:{line:16,column:18},end:{line:26,column:3}},line:16},2:{name:"(anonymous_2)",decl:{start:{line:27,column:2},end:{line:27,column:3}},loc:{start:{line:27,column:22},end:{line:29,column:3}},line:27},3:{name:"(anonymous_3)",decl:{start:{line:30,column:2},end:{line:30,column:3}},loc:{start:{line:30,column:23},end:{line:32,column:3}},line:30},4:{name:"(anonymous_4)",decl:{start:{line:33,column:2},end:{line:33,column:3}},loc:{start:{line:33,column:14},end:{line:35,column:3}},line:33},5:{name:"(anonymous_5)",decl:{start:{line:36,column:2},end:{line:36,column:3}},loc:{start:{line:36,column:11},end:{line:87,column:3}},line:36},6:{name:"(anonymous_6)",decl:{start:{line:40,column:13},end:{line:40,column:14}},loc:{start:{line:40,column:21},end:{line:42,column:9}},line:40},7:{name:"(anonymous_7)",decl:{start:{line:63,column:26},end:{line:63,column:27}},loc:{start:{line:63,column:36},end:{line:63,column:43}},line:63},8:{name:"(anonymous_8)",decl:{start:{line:64,column:22},end:{line:64,column:23}},loc:{start:{line:64,column:29},end:{line:64,column:45}},line:64},9:{name:"(anonymous_9)",decl:{start:{line:65,column:22},end:{line:65,column:23}},loc:{start:{line:65,column:33},end:{line:65,column:49}},line:65},10:{name:"(anonymous_10)",decl:{start:{line:66,column:30},end:{line:66,column:31}},loc:{start:{line:66,column:52},end:{line:71,column:13}},line:66},11:{name:"(anonymous_11)",decl:{start:{line:72,column:24},end:{line:72,column:25}},loc:{start:{line:72,column:65},end:{line:82,column:13}},line:72}},branchMap:{0:{loc:{start:{line:17,column:4},end:{line:25,column:5}},type:"if",locations:[{start:{line:17,column:4},end:{line:25,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:17},1:{loc:{start:{line:20,column:6},end:{line:24,column:7}},type:"if",locations:[{start:{line:20,column:6},end:{line:24,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:20},2:{loc:{start:{line:34,column:24},end:{line:34,column:45}},type:"cond-expr",locations:[{start:{line:34,column:35},end:{line:34,column:41}},{start:{line:34,column:44},end:{line:34,column:45}}],line:34},3:{loc:{start:{line:66,column:37},end:{line:66,column:47}},type:"default-arg",locations:[{start:{line:66,column:45},end:{line:66,column:47}}],line:66},4:{loc:{start:{line:67,column:14},end:{line:69,column:15}},type:"if",locations:[{start:{line:67,column:14},end:{line:69,column:15}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:67}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0],4:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputAutocomplete.tsx"],names:[],mappings:"AAsFU;AAtFV,OAAO,WAAW;AAClB,OAAO,gBAAgB;AACvB,OAAO,kBAAkB;AAGzB,MAAM,aAAa;AAUnB,qBAAqB,0BAA0B,MAAM,UAAkC;AAAA,EACrF,QAAQ;AAAA,IACN,WAAW;AAAA,EACb;AAAA,EAEA,qBAA4C;AAAA,EAE5C,OAAO,eAAe;AAAA,IACpB,UAAU,MAAM;AAAA,IAAC;AAAA,IACjB,SAAS,CAAC;AAAA,EACZ;AAAA,EAEA,gBAAgB;AACd,QAAG,KAAK,MAAM,4BAA4B;AACxC,YAAM,YAAY,OAAO,cAAc,KAAK,mBAAoB,sBAAsB,EAAE;AACxF,YAAM,mBAAmB,KAAK,IAAI,WAAW,UAAU;AAEvD,UAAG,oBAAoB,KAAK,MAAM,WAAW;AAC3C,aAAK,SAAS;AAAA,UACZ,WAAW;AAAA,QACb,CAAC;AAAA,MACH;AAAA,IACF;AAAA,EACF;AAAA,EAEA,oBAAoB;AAClB,SAAK,cAAc;AAAA,EACrB;AAAA,EAEA,qBAAqB;AACnB,SAAK,cAAc;AAAA,EACrB;AAAA,EAEA,SAAS,GAAW;AAClB,SAAK,MAAM,SAAS,MAAM,KAAK,SAAY,CAAC;AAAA,EAC9C;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,KAAK,CAAC,OAAO;AACX,eAAK,qBAAqB;AAAA,QAC5B;AAAA,QAEA;AAAA,UAAC;AAAA;AAAA,YACC,WAAW;AAAA,cACT,UAAU;AAAA,cACV,UAAU;AAAA,cACV,WAAW,KAAK,MAAM;AAAA,cACtB,QAAQ;AAAA,YACV;AAAA,YACA,cAAc;AAAA,cACZ,WAAW;AAAA,cACX,OAAO,CAAC;AAAA,YACV;AAAA,YACA,YAAY;AAAA,cACV,cAAc,KAAK,MAAM,YAAY;AAAA,cACrC,WAAW;AAAA,cACX,YAAY;AAAA,YACd;AAAA,YACA,OAAO,KAAK,MAAM;AAAA,YAClB,OAAO,KAAK,MAAM;AAAA,YAClB,cAAc,CAAC,SAAS,KAAK,CAAC;AAAA,YAC9B,UAAU,OAAK,KAAK,SAAS,CAAC;AAAA,YAC9B,UAAU,CAAC,IAAI,MAAM,KAAK,SAAS,CAAC;AAAA,YACpC,kBAAkB,CAAC,MAAM,QAAM,OAAO;AACpC,kBAAI,OAAO,UAAW,UAAU;AAC9B,uBAAO,KAAK,CAAC,EAAE,YAAY,EAAE,QAAQ,MAAM,YAAY,CAAC,IAAI;AAAA,cAC9D;AACA,qBAAO;AAAA,YACT;AAAA,YACA,YAAY,CAAC,MAAM,kBACjB;AAAA,cAAC;AAAA;AAAA,gBAEC,WAAW,WAAW;AAAA,kBACpB,mCAAmC;AAAA,kBACnC,4CAA4C;AAAA,gBAC9C,CAAC;AAAA,gBAEA,eAAK,CAAC;AAAA;AAAA,cANF,KAAK,CAAC;AAAA,YAOb;AAAA;AAAA,QAEJ;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6ef9facf9aeabdae687b5aca973710969d826d60"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Ni=function(){return s},s}Ni();const LT=(Ni().s[0]++,140);class Qy extends bn.Component{constructor(){super(...arguments);nn(this,"state",(Ni().s[1]++,{maxHeight:LT}));nn(this,"autocompleteMenuEl",(Ni().s[2]++,null))}calcMaxHeight(){if(Ni().f[1]++,Ni().s[4]++,this.props.keepMenuWithinWindowBounds){Ni().b[0][0]++;const t=(Ni().s[5]++,window.innerHeight-this.autocompleteMenuEl.getBoundingClientRect().top),r=(Ni().s[6]++,Math.min(t,LT));Ni().s[7]++,r!=this.state.maxHeight?(Ni().b[1][0]++,Ni().s[8]++,this.setState({maxHeight:r})):Ni().b[1][1]++}else Ni().b[0][1]++}componentDidMount(){Ni().f[2]++,Ni().s[9]++,this.calcMaxHeight()}componentDidUpdate(){Ni().f[3]++,Ni().s[10]++,this.calcMaxHeight()}onChange(t){Ni().f[4]++,Ni().s[11]++,this.props.onChange(t===""?(Ni().b[2][0]++,void 0):(Ni().b[2][1]++,t))}render(){return Ni().f[5]++,Ni().s[12]++,N.jsx("div",{ref:t=>{Ni().f[6]++,Ni().s[13]++,this.autocompleteMenuEl=t},children:N.jsx(khe,{menuStyle:{position:"fixed",overflow:"auto",maxHeight:this.state.maxHeight,zIndex:"998"},wrapperProps:{className:"maputnik-autocomplete",style:{}},inputProps:{"aria-label":this.props["aria-label"],className:"maputnik-string",spellCheck:!1},value:this.props.value,items:this.props.options,getItemValue:t=>(Ni().f[7]++,Ni().s[14]++,t[0]),onSelect:t=>(Ni().f[8]++,Ni().s[15]++,this.onChange(t)),onChange:(t,r)=>(Ni().f[9]++,Ni().s[16]++,this.onChange(r)),shouldItemRender:(t,r=(Ni().b[3][0]++,""))=>(Ni().f[10]++,Ni().s[17]++,typeof r=="string"?(Ni().b[4][0]++,Ni().s[18]++,t[0].toLowerCase().indexOf(r.toLowerCase())>-1):(Ni().b[4][1]++,Ni().s[19]++,!1)),renderItem:(t,r)=>(Ni().f[11]++,Ni().s[20]++,N.jsx("div",{className:Af({"maputnik-autocomplete-menu-item":!0,"maputnik-autocomplete-menu-item-selected":r}),children:t[1]},t[0]))})})}}nn(Qy,"defaultProps",(Ni().s[3]++,{onChange:()=>{Ni().f[0]++},options:[]}));function nm(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldSource.tsx",n="44fb815ce2e11a9e460bc73a5ffbca69a1bcff3c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldSource.tsx",statementMap:{0:{start:{line:7,column:24},end:{line:11,column:3}},1:{start:{line:13,column:4},end:{line:29,column:6}},2:{start:{line:25,column:56},end:{line:25,column:66}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:8,column:14},end:{line:8,column:15}},loc:{start:{line:8,column:20},end:{line:9,column:5}},line:8},1:{name:"(anonymous_1)",decl:{start:{line:12,column:2},end:{line:12,column:3}},loc:{start:{line:12,column:11},end:{line:30,column:3}},line:12},2:{name:"(anonymous_2)",decl:{start:{line:25,column:47},end:{line:25,column:48}},loc:{start:{line:25,column:56},end:{line:25,column:66}},line:25}},branchMap:{},s:{0:0,1:0,2:0},f:{0:0,1:0,2:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldSource.tsx"],names:[],mappings:"AA2BM;AA3BN,OAAO,WAAW;AAElB,OAAO,YAAY;AACnB,OAAO,WAAW;AAClB,OAAO,uBAAuB;AAU9B,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,OAAO,eAAe;AAAA,IACpB,UAAU,MAAM;AAAA,IAAC;AAAA,IACjB,WAAW,CAAC;AAAA,EACd;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,OAAO;AAAA,QACP,WAAW,OAAO,MAAM;AAAA,QACxB,OAAO,KAAK,MAAM;AAAA,QAClB,eAAa,KAAK,MAAM;AAAA,QAExB;AAAA,UAAC;AAAA;AAAA,YACC,OAAO,KAAK,MAAM;AAAA,YAClB,UAAU,KAAK,MAAM;AAAA,YACrB,SAAS,KAAK,MAAM,WAAW,IAAI,SAAO,CAAC,KAAK,GAAG,CAAC;AAAA;AAAA,QACtD;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"44fb815ce2e11a9e460bc73a5ffbca69a1bcff3c"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return nm=function(){return s},s}nm();class n8 extends bn.Component{render(){var n;return nm().f[1]++,nm().s[1]++,N.jsx(Uo,{label:"Source",fieldSpec:Ji.layer.source,error:this.props.error,"data-wd-key":this.props.wdKey,children:N.jsx(Qy,{value:this.props.value,onChange:this.props.onChange,options:(n=this.props.sourceIds)==null?void 0:n.map(t=>(nm().f[2]++,nm().s[2]++,[t,t]))})})}}nn(n8,"defaultProps",(nm().s[0]++,{onChange:()=>{nm().f[0]++},sourceIds:[]}));function rm(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldSourceLayer.tsx",n="f2bf4f193e0e44eb8c2b4f31458a3cde7f5305bd",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldSourceLayer.tsx",statementMap:{0:{start:{line:7,column:24},end:{line:12,column:3}},1:{start:{line:14,column:4},end:{line:31,column:6}},2:{start:{line:27,column:59},end:{line:27,column:65}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:8,column:14},end:{line:8,column:15}},loc:{start:{line:8,column:20},end:{line:9,column:5}},line:8},1:{name:"(anonymous_1)",decl:{start:{line:13,column:2},end:{line:13,column:3}},loc:{start:{line:13,column:11},end:{line:32,column:3}},line:13},2:{name:"(anonymous_2)",decl:{start:{line:27,column:52},end:{line:27,column:53}},loc:{start:{line:27,column:59},end:{line:27,column:65}},line:27}},branchMap:{},s:{0:0,1:0,2:0},f:{0:0,1:0,2:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldSourceLayer.tsx"],names:[],mappings:"AA4BM;AA5BN,OAAO,WAAW;AAElB,SAAQ,cAAa;AACrB,OAAO,WAAW;AAClB,OAAO,uBAAuB;AAU9B,qBAAqB,yBAAyB,MAAM,UAAiC;AAAA,EACnF,OAAO,eAAe;AAAA,IACpB,UAAU,MAAM;AAAA,IAAC;AAAA,IACjB,gBAAgB,CAAC;AAAA,IACjB,SAAS;AAAA,EACX;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,OAAO;AAAA,QACP,WAAW,OAAO,MAAM,cAAc;AAAA,QACtC,eAAY;AAAA,QACZ,OAAO,KAAK,MAAM;AAAA,QAElB;AAAA,UAAC;AAAA;AAAA,YACC,4BAA4B,CAAC,CAAC,KAAK,MAAM;AAAA,YACzC,OAAO,KAAK,MAAM;AAAA,YAClB,UAAU,KAAK,MAAM;AAAA,YACrB,SAAS,KAAK,MAAM,gBAAgB,IAAI,OAAK,CAAC,GAAG,CAAC,CAAC;AAAA;AAAA,QACrD;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"f2bf4f193e0e44eb8c2b4f31458a3cde7f5305bd"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return rm=function(){return s},s}rm();class r8 extends bn.Component{render(){var n;return rm().f[1]++,rm().s[1]++,N.jsx(Uo,{label:"Source Layer",fieldSpec:ma.layer["source-layer"],"data-wd-key":"layer-source-layer",error:this.props.error,children:N.jsx(Qy,{keepMenuWithinWindowBounds:!!this.props.isFixed,value:this.props.value,onChange:this.props.onChange,options:(n=this.props.sourceLayerIds)==null?void 0:n.map(t=>(rm().f[2]++,rm().s[2]++,[t,t]))})})}}nn(r8,"defaultProps",(rm().s[0]++,{onChange:()=>{rm().f[0]++},sourceLayerIds:[],isFixed:!1}));function dr(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalAdd.tsx",n="a7785e30671066cb83402b9013479a4548583811",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalAdd.tsx",statementMap:{0:{start:{line:10,column:13},end:{line:25,column:3}},1:{start:{line:11,column:26},end:{line:11,column:52}},2:{start:{line:12,column:18},end:{line:15,column:5}},3:{start:{line:16,column:4},end:{line:21,column:5}},4:{start:{line:17,column:6},end:{line:17,column:39}},5:{start:{line:18,column:6},end:{line:20,column:7}},6:{start:{line:19,column:8},end:{line:19,column:59}},7:{start:{line:22,column:4},end:{line:22,column:30}},8:{start:{line:23,column:4},end:{line:23,column:45}},9:{start:{line:24,column:4},end:{line:24,column:35}},10:{start:{line:27,column:4},end:{line:27,column:17}},11:{start:{line:28,column:18},end:{line:31,column:5}},12:{start:{line:32,column:4},end:{line:35,column:5}},13:{start:{line:33,column:6},end:{line:33,column:56}},14:{start:{line:34,column:6},end:{line:34,column:66}},15:{start:{line:36,column:4},end:{line:36,column:23}},16:{start:{line:39,column:20},end:{line:39,column:34}},17:{start:{line:40,column:20},end:{line:40,column:35}},18:{start:{line:41,column:32},end:{line:41,column:56}},19:{start:{line:42,column:32},end:{line:42,column:56}},20:{start:{line:43,column:4},end:{line:50,column:5}},21:{start:{line:47,column:6},end:{line:49,column:9}},22:{start:{line:53,column:22},end:{line:53,column:54}},23:{start:{line:54,column:4},end:{line:54,column:34}},24:{start:{line:57,column:20},end:{line:57,column:22}},25:{start:{line:58,column:18},end:{line:78,column:5}},26:{start:{line:79,column:4},end:{line:84,column:5}},27:{start:{line:80,column:22},end:{line:80,column:30}},28:{start:{line:81,column:6},end:{line:83,column:7}},29:{start:{line:82,column:8},end:{line:82,column:26}},30:{start:{line:85,column:4},end:{line:85,column:19}},31:{start:{line:88,column:20},end:{line:88,column:52}},32:{start:{line:89,column:19},end:{line:89,column:61}},33:{start:{line:90,column:4},end:{line:146,column:6}},34:{start:{line:105,column:16},end:{line:105,column:41}},35:{start:{line:114,column:31},end:{line:114,column:57}},36:{start:{line:123,column:31},end:{line:123,column:59}},37:{start:{line:132,column:31},end:{line:132,column:67}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:10,column:13},end:{line:10,column:14}},loc:{start:{line:10,column:19},end:{line:25,column:3}},line:10},1:{name:"(anonymous_1)",decl:{start:{line:26,column:2},end:{line:26,column:3}},loc:{start:{line:26,column:21},end:{line:37,column:3}},line:26},2:{name:"(anonymous_2)",decl:{start:{line:38,column:2},end:{line:38,column:3}},loc:{start:{line:38,column:44},end:{line:51,column:3}},line:38},3:{name:"(anonymous_3)",decl:{start:{line:52,column:2},end:{line:52,column:3}},loc:{start:{line:52,column:29},end:{line:55,column:3}},line:52},4:{name:"(anonymous_4)",decl:{start:{line:56,column:2},end:{line:56,column:3}},loc:{start:{line:56,column:19},end:{line:86,column:3}},line:56},5:{name:"(anonymous_5)",decl:{start:{line:87,column:2},end:{line:87,column:3}},loc:{start:{line:87,column:11},end:{line:147,column:3}},line:87},6:{name:"(anonymous_6)",decl:{start:{line:104,column:24},end:{line:104,column:25}},loc:{start:{line:104,column:31},end:{line:106,column:15}},line:104},7:{name:"(anonymous_7)",decl:{start:{line:114,column:24},end:{line:114,column:25}},loc:{start:{line:114,column:31},end:{line:114,column:57}},line:114},8:{name:"(anonymous_8)",decl:{start:{line:123,column:24},end:{line:123,column:25}},loc:{start:{line:123,column:31},end:{line:123,column:59}},line:123},9:{name:"(anonymous_9)",decl:{start:{line:132,column:24},end:{line:132,column:25}},loc:{start:{line:132,column:31},end:{line:132,column:67}},line:132}},branchMap:{0:{loc:{start:{line:16,column:4},end:{line:21,column:5}},type:"if",locations:[{start:{line:16,column:4},end:{line:21,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:16},1:{loc:{start:{line:18,column:6},end:{line:20,column:7}},type:"if",locations:[{start:{line:18,column:6},end:{line:20,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:18},2:{loc:{start:{line:18,column:10},end:{line:18,column:68}},type:"binary-expr",locations:[{start:{line:18,column:10},end:{line:18,column:38}},{start:{line:18,column:42},end:{line:18,column:68}}],line:18},3:{loc:{start:{line:32,column:4},end:{line:35,column:5}},type:"if",locations:[{start:{line:32,column:4},end:{line:35,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:32},4:{loc:{start:{line:43,column:4},end:{line:50,column:5}},type:"if",locations:[{start:{line:43,column:4},end:{line:50,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:43},5:{loc:{start:{line:45,column:6},end:{line:45,column:160}},type:"binary-expr",locations:[{start:{line:45,column:6},end:{line:45,column:25}},{start:{line:45,column:29},end:{line:45,column:52}},{start:{line:45,column:56},end:{line:45,column:106}},{start:{line:45,column:110},end:{line:45,column:160}}],line:45},6:{loc:{start:{line:53,column:22},end:{line:53,column:54}},type:"binary-expr",locations:[{start:{line:53,column:22},end:{line:53,column:48}},{start:{line:53,column:52},end:{line:53,column:54}}],line:53},7:{loc:{start:{line:54,column:11},end:{line:54,column:33}},type:"binary-expr",locations:[{start:{line:54,column:11},end:{line:54,column:27}},{start:{line:54,column:31},end:{line:54,column:33}}],line:54},8:{loc:{start:{line:81,column:6},end:{line:83,column:7}},type:"if",locations:[{start:{line:81,column:6},end:{line:83,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:81},9:{loc:{start:{line:81,column:10},end:{line:81,column:61}},type:"binary-expr",locations:[{start:{line:81,column:10},end:{line:81,column:24}},{start:{line:81,column:28},end:{line:81,column:61}}],line:81},10:{loc:{start:{line:117,column:10},end:{line:125,column:11}},type:"binary-expr",locations:[{start:{line:117,column:10},end:{line:117,column:42}},{start:{line:117,column:62},end:{line:125,column:11}}],line:117},11:{loc:{start:{line:126,column:10},end:{line:134,column:11}},type:"binary-expr",locations:[{start:{line:126,column:10},end:{line:126,column:87}},{start:{line:126,column:107},end:{line:134,column:11}}],line:126}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0,0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalAdd.tsx"],names:[],mappings:"AAyIM,SACE,KADF;AAzIN,OAAO,WAAW;AAElB,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAClB,OAAO,eAAe;AACtB,OAAO,aAAa;AACpB,OAAO,iBAAiB;AACxB,OAAO,sBAAsB;AAmB7B,qBAAqB,iBAAiB,MAAM,UAAwC;AAAA,EAClF,WAAW,MAAM;AACf,UAAM,gBAAgB,KAAK,MAAM,OAAO,MAAM,CAAC;AAC/C,UAAM,QAAuB;AAAA,MAC3B,IAAI,KAAK,MAAM;AAAA,MACf,MAAM,KAAK,MAAM;AAAA,IACnB;AAEA,QAAG,KAAK,MAAM,SAAS,cAAc;AACnC,YAAM,SAAS,KAAK,MAAM;AAC1B,UAAG,KAAK,MAAM,SAAS,YAAY,KAAK,MAAM,cAAc,GAAG;AAC7D,cAAM,cAAc,IAAI,KAAK,MAAM,cAAc;AAAA,MACnD;AAAA,IACF;AAEA,kBAAc,KAAK,KAA2B;AAE9C,SAAK,MAAM,eAAe,aAAa;AACvC,SAAK,MAAM,aAAa,KAAK;AAAA,EAC/B;AAAA,EAEA,YAAY,OAAsB;AAChC,UAAM,KAAK;AACX,UAAM,QAAuB;AAAA,MAC3B,MAAM;AAAA,MACN,IAAI;AAAA,IACN;AAEA,QAAG,MAAM,QAAQ,SAAS,GAAG;AAC3B,YAAM,SAAS,OAAO,KAAK,KAAK,MAAM,OAAO,EAAE,CAAC;AAChD,YAAM,cAAc,IAAI,KAAK,MAAM,QAAQ,MAAM,MAAwC,EAAE,CAAC;AAAA,IAC9F;AACA,SAAK,QAAQ;AAAA,EACf;AAAA,EAEA,mBAAmB,YAA2B,WAA0B;AAEtE,UAAM,UAAU,UAAU;AAC1B,UAAM,UAAU,KAAK,MAAM;AAE3B,UAAM,sBAAsB,KAAK,WAAW,OAAO;AACnD,UAAM,sBAAsB,KAAK,WAAW,OAAO;AAEnD;AAAA;AAAA,MAEE,YAAY,WACT,UAAU,WAAW,MAErB,oBAAoB,QAAQ,UAAU,MAAO,IAAI,MAEjD,oBAAoB,QAAQ,KAAK,MAAM,MAAO,IAAI;AAAA,MACrD;AAEA,WAAK,SAAS;AAAA,QACZ,QAAQ;AAAA,MACV,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,mBAAmB,QAAgB;AACjC,UAAM,YAAY,KAAK,MAAM,QAAQ,MAAM,KAAK,CAAC;AACjD,WAAO,UAAU,UAAU,CAAC;AAAA,EAC9B;AAAA,EAEA,WAAW,MAAc;AACvB,UAAM,UAAU,CAAC;AAEjB,UAAM,QAAQ;AAAA,MACZ,QAAQ;AAAA,QACN;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACF;AAAA,MACA,QAAQ;AAAA,QACN;AAAA,MACF;AAAA,MACA,SAAS;AAAA,QACP;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACF;AAAA,IACF;AAEA,eAAU,CAAC,KAAK,GAAG,KAAK,OAAO,QAAQ,KAAK,MAAM,OAAO,GAAU;AACjE,YAAM,UAAU,IAAI;AACpB,UAAG,MAAM,OAAO,KAAK,MAAM,OAAO,EAAE,QAAQ,IAAI,IAAI,IAAI;AACtD,gBAAQ,KAAK,GAAG;AAAA,MAClB;AAAA,IACF;AAEA,WAAO;AAAA,EACT;AAAA,EAGA,SAAS;AACP,UAAM,UAAU,KAAK,WAAW,KAAK,MAAM,IAAI;AAC/C,UAAM,SAAS,KAAK,mBAAmB,KAAK,MAAM,MAAO;AAEzD,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAO;AAAA,QACP,eAAY;AAAA,QACZ,WAAU;AAAA,QAEV,+BAAC,SAAI,WAAU,sBACb;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,KAAK,MAAM;AAAA,cAClB,OAAM;AAAA,cACN,UAAU,CAAC,MAAc;AACvB,qBAAK,SAAS,EAAE,IAAI,EAAE,CAAC;AAAA,cACzB;AAAA;AAAA,UACF;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,KAAK,MAAM;AAAA,cAClB,OAAM;AAAA,cACN,UAAU,CAAC,MAAkC,KAAK,SAAS,EAAE,MAAM,EAAE,CAAC;AAAA;AAAA,UACxE;AAAA,UACC,KAAK,MAAM,SAAS,gBACvB;AAAA,YAAC;AAAA;AAAA,cACC,WAAW;AAAA,cACX,OAAM;AAAA,cACN,OAAO,KAAK,MAAM;AAAA,cAClB,UAAU,CAAC,MAAc,KAAK,SAAS,EAAE,QAAQ,EAAE,CAAC;AAAA;AAAA,UACtD;AAAA,UAEG,CAAC,cAAc,UAAU,aAAa,SAAS,EAAE,QAAQ,KAAK,MAAM,IAAI,IAAI,KAC/E;AAAA,YAAC;AAAA;AAAA,cACC,SAAS;AAAA,cACT,gBAAgB;AAAA,cAChB,OAAO,KAAK,MAAM,cAAc;AAAA,cAChC,UAAU,CAAC,MAAc,KAAK,SAAS,EAAE,gBAAgB,EAAE,CAAC;AAAA;AAAA,UAC9D;AAAA,UAEE;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,SAAS,KAAK;AAAA,cACd,eAAY;AAAA,cACb;AAAA;AAAA,UAED;AAAA,WACF;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a7785e30671066cb83402b9013479a4548583811"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return dr=function(){return s},s}dr();class Ihe extends bn.Component{constructor(t){dr().f[1]++,dr().s[10]++;super(t);nn(this,"addLayer",(dr().s[0]++,()=>{dr().f[0]++;const t=(dr().s[1]++,this.props.layers.slice(0)),r=(dr().s[2]++,{id:this.state.id,type:this.state.type});dr().s[3]++,this.state.type!=="background"?(dr().b[0][0]++,dr().s[4]++,r.source=this.state.source,dr().s[5]++,dr().b[2][0]++,this.state.type!=="raster"&&(dr().b[2][1]++,this.state["source-layer"])?(dr().b[1][0]++,dr().s[6]++,r["source-layer"]=this.state["source-layer"]):dr().b[1][1]++):dr().b[0][1]++,dr().s[7]++,t.push(r),dr().s[8]++,this.props.onLayersChange(t),dr().s[9]++,this.props.onOpenToggle(!1)}));const r=(dr().s[11]++,{type:"fill",id:""});dr().s[12]++,t.sources.length>0?(dr().b[3][0]++,dr().s[13]++,r.source=Object.keys(this.props.sources)[0],dr().s[14]++,r["source-layer"]=this.props.sources[r.source][0]):dr().b[3][1]++,dr().s[15]++,this.state=r}componentDidUpdate(t,r){dr().f[2]++;const i=(dr().s[16]++,r.type),o=(dr().s[17]++,this.state.type),s=(dr().s[18]++,this.getSources(i)),a=(dr().s[19]++,this.getSources(o));dr().s[20]++,dr().b[5][0]++,i!==o&&(dr().b[5][1]++,r.source!=="")&&(dr().b[5][2]++,s.indexOf(r.source)>-1)&&(dr().b[5][3]++,a.indexOf(this.state.source)<0)?(dr().b[4][0]++,dr().s[21]++,this.setState({source:""})):dr().b[4][1]++}getLayersForSource(t){dr().f[3]++;const r=(dr().s[22]++,dr().b[6][0]++,this.props.sources[t]||(dr().b[6][1]++,{}));return dr().s[23]++,dr().b[7][0]++,r.layers||(dr().b[7][1]++,[])}getSources(t){dr().f[4]++;const r=(dr().s[24]++,[]),i=(dr().s[25]++,{vector:["fill","line","symbol","circle","fill-extrusion","heatmap"],raster:["raster"],geojson:["fill","line","symbol","circle","fill-extrusion","heatmap"]});dr().s[26]++;for(const[o,s]of Object.entries(this.props.sources)){const a=(dr().s[27]++,s.type);dr().s[28]++,dr().b[9][0]++,i[a]&&(dr().b[9][1]++,i[a].indexOf(t)>-1)?(dr().b[8][0]++,dr().s[29]++,r.push(o)):dr().b[8][1]++}return dr().s[30]++,r}render(){dr().f[5]++;const t=(dr().s[31]++,this.getSources(this.state.type)),r=(dr().s[32]++,this.getLayersForSource(this.state.source));return dr().s[33]++,N.jsx(_f,{isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Add Layer","data-wd-key":"modal:add-layer",className:"maputnik-add-modal",children:N.jsxs("div",{className:"maputnik-add-layer",children:[N.jsx(Jj,{value:this.state.id,wdKey:"add-layer.layer-id",onChange:i=>{dr().f[6]++,dr().s[34]++,this.setState({id:i})}}),N.jsx(e8,{value:this.state.type,wdKey:"add-layer.layer-type",onChange:i=>(dr().f[7]++,dr().s[35]++,this.setState({type:i}))}),(dr().b[10][0]++,this.state.type!=="background"&&(dr().b[10][1]++,N.jsx(n8,{sourceIds:t,wdKey:"add-layer.layer-source-block",value:this.state.source,onChange:i=>(dr().f[8]++,dr().s[36]++,this.setState({source:i}))}))),(dr().b[11][0]++,["background","raster","hillshade","heatmap"].indexOf(this.state.type)<0&&(dr().b[11][1]++,N.jsx(r8,{isFixed:!0,sourceLayerIds:r,value:this.state["source-layer"],onChange:i=>(dr().f[9]++,dr().s[37]++,this.setState({"source-layer":i}))}))),N.jsx(Ka,{className:"maputnik-add-layer-button",onClick:this.addLayer,"data-wd-key":"add-layer",children:"Add Layer"})]})})}}function Q0(){var e="/home/runner/work/maputnik/maputnik/src/libs/document-uid.ts",n="a991ed6da2a27b46f1adbb88a645aa2ee0df375e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/document-uid.ts",statementMap:{0:{start:{line:1,column:10},end:{line:1,column:11}},1:{start:{line:3,column:2},end:{line:3,column:8}},2:{start:{line:4,column:2},end:{line:4,column:22}}},fnMap:{0:{name:"generateUniqueId",decl:{start:{line:2,column:24},end:{line:2,column:40}},loc:{start:{line:2,column:54},end:{line:5,column:1}},line:2}},branchMap:{0:{loc:{start:{line:2,column:41},end:{line:2,column:52}},type:"default-arg",locations:[{start:{line:2,column:50},end:{line:2,column:52}}],line:2}},s:{0:0,1:0,2:0},f:{0:0},b:{0:[0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/document-uid.ts"],names:[],mappings:"AAGA,IAAI,MAAM;AAEV,wBAAwB,iBAAiB,SAAO,IAAI;AAClD;AACA,SAAO,SAAO;AAChB;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a991ed6da2a27b46f1adbb88a645aa2ee0df375e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Q0=function(){return s},s}Q0();let zT=(Q0().s[0]++,0);function Oy(e=(Q0().b[0][0]++,"")){return Q0().f[0]++,Q0().s[1]++,zT++,Q0().s[2]++,e+zT}function ti(){var e="/home/runner/work/maputnik/maputnik/src/libs/layer.ts",n="8d7d71e3a97c0e4b8cc5fd0ca26b8fdf4aa2aa36",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/layer.ts",statementMap:{0:{start:{line:3,column:28},end:{line:3,column:46}},1:{start:{line:4,column:2},end:{line:8,column:5}},2:{start:{line:5,column:4},end:{line:7,column:5}},3:{start:{line:6,column:6},end:{line:6,column:45}},4:{start:{line:9,column:29},end:{line:9,column:48}},5:{start:{line:10,column:2},end:{line:14,column:5}},6:{start:{line:11,column:4},end:{line:13,column:5}},7:{start:{line:12,column:6},end:{line:12,column:46}},8:{start:{line:15,column:2},end:{line:20,column:4}},9:{start:{line:23,column:2},end:{line:59,column:3}},10:{start:{line:24,column:4},end:{line:43,column:5}},11:{start:{line:25,column:23},end:{line:31,column:7}},12:{start:{line:32,column:6},end:{line:32,column:39}},13:{start:{line:33,column:6},end:{line:35,column:7}},14:{start:{line:34,column:8},end:{line:34,column:31}},15:{start:{line:36,column:6},end:{line:36,column:22}},16:{start:{line:38,column:23},end:{line:40,column:7}},17:{start:{line:41,column:6},end:{line:41,column:32}},18:{start:{line:42,column:6},end:{line:42,column:22}},19:{start:{line:45,column:4},end:{line:58,column:5}},20:{start:{line:46,column:6},end:{line:52,column:8}},21:{start:{line:54,column:6},end:{line:57,column:8}},22:{start:{line:62,column:2},end:{line:62,column:64}},23:{start:{line:65,column:29},end:{line:65,column:56}},24:{start:{line:66,column:19},end:{line:66,column:22}},25:{start:{line:67,column:2},end:{line:74,column:3}},26:{start:{line:67,column:15},end:{line:67,column:18}},27:{start:{line:68,column:32},end:{line:68,column:61}},28:{start:{line:69,column:4},end:{line:73,column:5}},29:{start:{line:70,column:6},end:{line:70,column:25}},30:{start:{line:72,column:6},end:{line:72,column:24}},31:{start:{line:75,column:2},end:{line:75,column:20}}},fnMap:{0:{name:"changeType",decl:{start:{line:2,column:16},end:{line:2,column:26}},loc:{start:{line:2,column:43},end:{line:21,column:1}},line:2},1:{name:"(anonymous_1)",decl:{start:{line:4,column:41},end:{line:4,column:42}},loc:{start:{line:4,column:59},end:{line:8,column:3}},line:4},2:{name:"(anonymous_2)",decl:{start:{line:10,column:42},end:{line:10,column:43}},loc:{start:{line:10,column:60},end:{line:14,column:3}},line:10},3:{name:"changeProperty",decl:{start:{line:22,column:16},end:{line:22,column:30}},loc:{start:{line:22,column:65},end:{line:60,column:1}},line:22},4:{name:"layerPrefix",decl:{start:{line:61,column:16},end:{line:61,column:27}},loc:{start:{line:61,column:34},end:{line:63,column:1}},line:61},5:{name:"findClosestCommonPrefix",decl:{start:{line:64,column:16},end:{line:64,column:39}},loc:{start:{line:64,column:53},end:{line:76,column:1}},line:64}},branchMap:{0:{loc:{start:{line:5,column:4},end:{line:7,column:5}},type:"if",locations:[{start:{line:5,column:4},end:{line:7,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:5},1:{loc:{start:{line:11,column:4},end:{line:13,column:5}},type:"if",locations:[{start:{line:11,column:4},end:{line:13,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:11},2:{loc:{start:{line:23,column:2},end:{line:59,column:3}},type:"if",locations:[{start:{line:23,column:2},end:{line:59,column:3}},{start:{line:44,column:9},end:{line:59,column:3}}],line:23},3:{loc:{start:{line:24,column:4},end:{line:43,column:5}},type:"if",locations:[{start:{line:24,column:4},end:{line:43,column:5}},{start:{line:37,column:11},end:{line:43,column:5}}],line:24},4:{loc:{start:{line:33,column:6},end:{line:35,column:7}},type:"if",locations:[{start:{line:33,column:6},end:{line:35,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:33},5:{loc:{start:{line:45,column:4},end:{line:58,column:5}},type:"if",locations:[{start:{line:45,column:4},end:{line:58,column:5}},{start:{line:53,column:11},end:{line:58,column:5}}],line:45},6:{loc:{start:{line:69,column:4},end:{line:73,column:5}},type:"if",locations:[{start:{line:69,column:4},end:{line:73,column:5}},{start:{line:71,column:11},end:{line:73,column:5}}],line:69}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0},f:{0:0,1:0,2:0,3:0,4:0,5:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/layer.ts"],names:[],mappings:"AAAA,SAAQ,cAAa;AAGd,gBAAS,WAAW,OAA2B,SAAiB;AACrE,QAAM,oBAAiD,EAAE,GAAG,MAAM,MAAM;AACxE,SAAO,KAAK,iBAAiB,EAAE,QAAQ,kBAAgB;AACrD,QAAG,EAAE,gBAAgB,OAAO,WAAW,OAAO,IAAI;AAChD,aAAO,kBAAkB,YAAiD;AAAA,IAC5E;AAAA,EACF,CAAC;AAED,QAAM,qBAAmD,EAAE,GAAG,MAAM,OAAO;AAC3E,SAAO,KAAK,kBAAkB,EAAE,QAAQ,kBAAgB;AACtD,QAAG,EAAE,gBAAgB,OAAO,YAAY,OAAO,IAAI;AACjD,aAAO,mBAAmB,YAAkD;AAAA,IAC9E;AAAA,EACF,CAAC;AAED,SAAO;AAAA,IACL,GAAG;AAAA,IACH,OAAO;AAAA,IACP,QAAQ;AAAA,IACR,MAAM;AAAA,EACR;AACF;AAKO,gBAAS,eAAe,OAA2B,OAAwC,UAAkB,UAAe;AAEjI,MAAG,aAAa,QAAW;AACzB,QAAG,OAAO;AACR,YAAM,WAAgB;AAAA,QACpB,GAAG;AAAA;AAAA,QAEH,CAAC,KAAK,GAAG;AAAA,UACP,GAAG,MAAM,KAAK;AAAA,QAChB;AAAA,MACF;AACA,aAAO,SAAS,KAAK,EAAE,QAAQ;AAG/B,UAAG,OAAO,KAAK,SAAS,KAAK,CAAC,EAAE,SAAS,GAAG;AAC1C,eAAO,SAAS,KAAK;AAAA,MACvB;AACA,aAAO;AAAA,IACT,OAAO;AACL,YAAM,WAAgB;AAAA,QACpB,GAAG;AAAA,MACL;AACA,aAAO,SAAS,QAAQ;AACxB,aAAO;AAAA,IACT;AAAA,EACF,OACK;AACH,QAAG,OAAO;AACR,aAAO;AAAA,QACL,GAAG;AAAA,QACH,CAAC,KAAK,GAAG;AAAA,UACP,GAAG,MAAM,KAAK;AAAA,UACd,CAAC,QAAQ,GAAG;AAAA,QACd;AAAA,MACF;AAAA,IACF,OAAO;AACL,aAAO;AAAA,QACL,GAAG;AAAA,QACH,CAAC,QAAQ,GAAG;AAAA,MACd;AAAA,IACF;AAAA,EACF;AACF;AAEO,gBAAS,YAAY,MAAc;AACxC,SAAO,KAAK,QAAQ,KAAK,GAAG,EAAE,QAAQ,KAAK,GAAG,EAAE,MAAM,GAAG,EAAE,CAAC;AAC9D;AAEO,gBAAS,wBAAwB,QAA8B,KAAa;AACjF,QAAM,qBAAqB,YAAY,OAAO,GAAG,EAAE,EAAE;AACrD,MAAI,aAAa;AACjB,WAAS,IAAI,KAAK,IAAI,GAAG,KAAK;AAC5B,UAAM,sBAAsB,YAAY,OAAO,IAAE,CAAC,EAAE,EAAE;AACtD,QAAG,wBAAwB,oBAAoB;AAC7C,mBAAa,IAAI;AAAA,IACnB,OAAO;AACL,aAAO;AAAA,IACT;AAAA,EACF;AACA,SAAO;AACT;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"8d7d71e3a97c0e4b8cc5fd0ca26b8fdf4aa2aa36"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ti=function(){return s},s}ti();function The(e,n){ti().f[0]++;const t=(ti().s[0]++,{...e.paint});ti().s[1]++,Object.keys(t).forEach(i=>{ti().f[1]++,ti().s[2]++,i in ma["paint_"+n]?ti().b[0][1]++:(ti().b[0][0]++,ti().s[3]++,delete t[i])});const r=(ti().s[4]++,{...e.layout});return ti().s[5]++,Object.keys(r).forEach(i=>{ti().f[2]++,ti().s[6]++,i in ma["layout_"+n]?ti().b[1][1]++:(ti().b[1][0]++,ti().s[7]++,delete r[i])}),ti().s[8]++,{...e,paint:t,layout:r,type:n}}function Khe(e,n,t,r){if(ti().f[3]++,ti().s[9]++,r===void 0)if(ti().b[2][0]++,ti().s[10]++,n){ti().b[3][0]++;const i=(ti().s[11]++,{...e,[n]:{...e[n]}});return ti().s[12]++,delete i[n][t],ti().s[13]++,Object.keys(i[n]).length<1?(ti().b[4][0]++,ti().s[14]++,delete i[n]):ti().b[4][1]++,ti().s[15]++,i}else{ti().b[3][1]++;const i=(ti().s[16]++,{...e});return ti().s[17]++,delete i[t],ti().s[18]++,i}else return ti().b[2][1]++,ti().s[19]++,n?(ti().b[5][0]++,ti().s[20]++,{...e,[n]:{...e[n],[t]:r}}):(ti().b[5][1]++,ti().s[21]++,{...e,[t]:r})}function Wg(e){return ti().f[4]++,ti().s[22]++,e.replace(" ","-").replace("_","-").split("-")[0]}function Phe(e,n){ti().f[5]++;const t=(ti().s[23]++,Wg(e[n].id));let r=(ti().s[24]++,n);ti().s[25]++;for(let i=(ti().s[26]++,n);i>0;i--){const o=(ti().s[27]++,Wg(e[i-1].id));if(ti().s[28]++,o===t)ti().b[6][0]++,ti().s[29]++,r=i-1;else return ti().b[6][1]++,ti().s[30]++,r}return ti().s[31]++,r}function Qt(){var e="/home/runner/work/maputnik/maputnik/src/components/LayerList.tsx",n="a7cd6405e81ca6260ef85d5394a18c33340b5775",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/LayerList.tsx",statementMap:{0:{start:{line:12,column:24},end:{line:15,column:3}},1:{start:{line:19,column:4},end:{line:19,column:17}},2:{start:{line:20,column:4},end:{line:20,column:45}},3:{start:{line:21,column:4},end:{line:21,column:48}},4:{start:{line:22,column:4},end:{line:31,column:6}},5:{start:{line:34,column:4},end:{line:43,column:7}},6:{start:{line:45,column:17},end:{line:62,column:3}},7:{start:{line:46,column:14},end:{line:46,column:15}},8:{start:{line:47,column:22},end:{line:47,column:24}},9:{start:{line:48,column:4},end:{line:57,column:7}},10:{start:{line:49,column:26},end:{line:49,column:51}},11:{start:{line:50,column:24},end:{line:50,column:52}},12:{start:{line:51,column:6},end:{line:53,column:7}},13:{start:{line:52,column:8},end:{line:52,column:63}},14:{start:{line:54,column:6},end:{line:56,column:9}},15:{start:{line:55,column:8},end:{line:55,column:17}},16:{start:{line:58,column:4},end:{line:61,column:7}},17:{start:{line:64,column:19},end:{line:64,column:21}},18:{start:{line:65,column:41},end:{line:65,column:50}},19:{start:{line:66,column:4},end:{line:83,column:5}},20:{start:{line:66,column:17},end:{line:66,column:18}},21:{start:{line:67,column:24},end:{line:67,column:44}},22:{start:{line:68,column:28},end:{line:68,column:52}},23:{start:{line:69,column:6},end:{line:72,column:8}},24:{start:{line:73,column:20},end:{line:76,column:7}},25:{start:{line:77,column:6},end:{line:82,column:7}},26:{start:{line:78,column:26},end:{line:78,column:51}},27:{start:{line:79,column:8},end:{line:79,column:30}},28:{start:{line:81,column:8},end:{line:81,column:29}},29:{start:{line:84,column:4},end:{line:84,column:18}},30:{start:{line:87,column:22},end:{line:87,column:50}},31:{start:{line:88,column:22},end:{line:88,column:55}},32:{start:{line:89,column:4},end:{line:93,column:5}},33:{start:{line:90,column:6},end:{line:90,column:68}},34:{start:{line:92,column:6},end:{line:92,column:35}},35:{start:{line:94,column:4},end:{line:96,column:7}},36:{start:{line:99,column:22},end:{line:99,column:78}},37:{start:{line:100,column:4},end:{line:100,column:51}},38:{start:{line:103,column:4},end:{line:105,column:5}},39:{start:{line:104,column:6},end:{line:104,column:18}},40:{start:{line:107,column:18},end:{line:109,column:7}},41:{start:{line:110,column:6},end:{line:114,column:7}},42:{start:{line:111,column:8},end:{line:113,column:10}},43:{start:{line:115,column:6},end:{line:115,column:17}},44:{start:{line:117,column:24},end:{line:120,column:5}},45:{start:{line:122,column:18},end:{line:124,column:7}},46:{start:{line:125,column:6},end:{line:125,column:27}},47:{start:{line:126,column:6},end:{line:126,column:17}},48:{start:{line:128,column:23},end:{line:131,column:5}},49:{start:{line:132,column:25},end:{line:132,column:53}},50:{start:{line:133,column:4},end:{line:133,column:24}},51:{start:{line:136,column:4},end:{line:152,column:5}},52:{start:{line:137,column:31},end:{line:137,column:59}},53:{start:{line:138,column:6},end:{line:151,column:7}},54:{start:{line:139,column:23},end:{line:139,column:44}},55:{start:{line:140,column:24},end:{line:143,column:9}},56:{start:{line:144,column:25},end:{line:149,column:19}},57:{start:{line:145,column:10},end:{line:145,column:37}},58:{start:{line:146,column:10},end:{line:148,column:11}},59:{start:{line:147,column:12},end:{line:147,column:36}},60:{start:{line:150,column:8},end:{line:150,column:33}},61:{start:{line:155,column:22},end:{line:155,column:24}},62:{start:{line:156,column:14},end:{line:156,column:15}},63:{start:{line:157,column:26},end:{line:157,column:46}},64:{start:{line:158,column:4},end:{line:209,column:7}},65:{start:{line:159,column:26},end:{line:159,column:51}},66:{start:{line:160,column:6},end:{line:173,column:7}},67:{start:{line:161,column:36},end:{line:171,column:9}},68:{start:{line:165,column:47},end:{line:165,column:52}},69:{start:{line:172,column:8},end:{line:172,column:28}},70:{start:{line:174,column:6},end:{line:208,column:9}},71:{start:{line:175,column:25},end:{line:175,column:72}},72:{start:{line:176,column:27},end:{line:178,column:10}},73:{start:{line:177,column:10},end:{line:177,column:97}},74:{start:{line:179,column:32},end:{line:179,column:34}},75:{start:{line:180,column:8},end:{line:182,column:9}},76:{start:{line:181,column:10},end:{line:181,column:53}},77:{start:{line:183,column:41},end:{line:205,column:9}},78:{start:{line:206,column:8},end:{line:206,column:33}},79:{start:{line:207,column:8},end:{line:207,column:17}},80:{start:{line:210,column:4},end:{line:262,column:6}},81:{start:{line:265,column:35},end:{line:265,column:118}},82:{start:{line:265,column:80},end:{line:265,column:117}},83:{start:{line:268,column:4},end:{line:277,column:6}},84:{start:{line:275,column:33},end:{line:275,column:38}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:13,column:19},end:{line:13,column:20}},loc:{start:{line:13,column:25},end:{line:14,column:5}},line:13},1:{name:"(anonymous_1)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:21},end:{line:32,column:3}},line:18},2:{name:"(anonymous_2)",decl:{start:{line:33,column:2},end:{line:33,column:3}},loc:{start:{line:33,column:25},end:{line:44,column:3}},line:33},3:{name:"(anonymous_3)",decl:{start:{line:45,column:17},end:{line:45,column:18}},loc:{start:{line:45,column:23},end:{line:62,column:3}},line:45},4:{name:"(anonymous_4)",decl:{start:{line:48,column:33},end:{line:48,column:34}},loc:{start:{line:48,column:45},end:{line:57,column:5}},line:48},5:{name:"(anonymous_5)",decl:{start:{line:54,column:21},end:{line:54,column:22}},loc:{start:{line:54,column:33},end:{line:56,column:7}},line:54},6:{name:"(anonymous_6)",decl:{start:{line:63,column:2},end:{line:63,column:3}},loc:{start:{line:63,column:18},end:{line:85,column:3}},line:63},7:{name:"(anonymous_7)",decl:{start:{line:86,column:2},end:{line:86,column:3}},loc:{start:{line:86,column:37},end:{line:97,column:3}},line:86},8:{name:"(anonymous_8)",decl:{start:{line:98,column:2},end:{line:98,column:3}},loc:{start:{line:98,column:32},end:{line:101,column:3}},line:98},9:{name:"(anonymous_9)",decl:{start:{line:102,column:2},end:{line:102,column:3}},loc:{start:{line:102,column:46},end:{line:134,column:3}},line:102},10:{name:"getRequiredProps",decl:{start:{line:106,column:13},end:{line:106,column:29}},loc:{start:{line:106,column:37},end:{line:116,column:5}},line:106},11:{name:"withoutLayers",decl:{start:{line:121,column:13},end:{line:121,column:26}},loc:{start:{line:121,column:34},end:{line:127,column:5}},line:121},12:{name:"(anonymous_12)",decl:{start:{line:135,column:2},end:{line:135,column:3}},loc:{start:{line:135,column:32},end:{line:153,column:3}},line:135},13:{name:"(anonymous_13)",decl:{start:{line:144,column:50},end:{line:144,column:51}},loc:{start:{line:144,column:63},end:{line:149,column:9}},line:144},14:{name:"(anonymous_14)",decl:{start:{line:154,column:2},end:{line:154,column:3}},loc:{start:{line:154,column:11},end:{line:263,column:3}},line:154},15:{name:"(anonymous_15)",decl:{start:{line:158,column:26},end:{line:158,column:27}},loc:{start:{line:158,column:38},end:{line:209,column:5}},line:158},16:{name:"(anonymous_16)",decl:{start:{line:165,column:40},end:{line:165,column:41}},loc:{start:{line:165,column:47},end:{line:165,column:52}},line:165},17:{name:"(anonymous_17)",decl:{start:{line:174,column:21},end:{line:174,column:22}},loc:{start:{line:174,column:44},end:{line:208,column:7}},line:174},18:{name:"(anonymous_18)",decl:{start:{line:176,column:50},end:{line:176,column:51}},loc:{start:{line:176,column:61},end:{line:178,column:9}},line:176},19:{name:"(anonymous_19)",decl:{start:{line:265,column:53},end:{line:265,column:54}},loc:{start:{line:265,column:80},end:{line:265,column:117}},line:265},20:{name:"(anonymous_20)",decl:{start:{line:267,column:2},end:{line:267,column:3}},loc:{start:{line:267,column:11},end:{line:278,column:3}},line:267},21:{name:"(anonymous_21)",decl:{start:{line:275,column:27},end:{line:275,column:28}},loc:{start:{line:275,column:33},end:{line:275,column:38}},line:275}},branchMap:{0:{loc:{start:{line:51,column:6},end:{line:53,column:7}},type:"if",locations:[{start:{line:51,column:6},end:{line:53,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:51},1:{loc:{start:{line:71,column:8},end:{line:71,column:79}},type:"cond-expr",locations:[{start:{line:71,column:41},end:{line:71,column:75}},{start:{line:71,column:78},end:{line:71,column:79}}],line:71},2:{loc:{start:{line:77,column:6},end:{line:82,column:7}},type:"if",locations:[{start:{line:77,column:6},end:{line:82,column:7}},{start:{line:80,column:13},end:{line:82,column:7}}],line:77},3:{loc:{start:{line:77,column:10},end:{line:77,column:81}},type:"binary-expr",locations:[{start:{line:77,column:10},end:{line:77,column:23}},{start:{line:77,column:27},end:{line:77,column:81}}],line:77},4:{loc:{start:{line:89,column:4},end:{line:93,column:5}},type:"if",locations:[{start:{line:89,column:4},end:{line:93,column:5}},{start:{line:91,column:11},end:{line:93,column:5}}],line:89},5:{loc:{start:{line:100,column:11},end:{line:100,column:50}},type:"cond-expr",locations:[{start:{line:100,column:34},end:{line:100,column:38}},{start:{line:100,column:41},end:{line:100,column:50}}],line:100},6:{loc:{start:{line:103,column:4},end:{line:105,column:5}},type:"if",locations:[{start:{line:103,column:4},end:{line:105,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:103},7:{loc:{start:{line:110,column:6},end:{line:114,column:7}},type:"if",locations:[{start:{line:110,column:6},end:{line:114,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:110},8:{loc:{start:{line:132,column:27},end:{line:132,column:52}},type:"binary-expr",locations:[{start:{line:132,column:27},end:{line:132,column:38}},{start:{line:132,column:42},end:{line:132,column:52}}],line:132},9:{loc:{start:{line:136,column:4},end:{line:152,column:5}},type:"if",locations:[{start:{line:136,column:4},end:{line:152,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:136},10:{loc:{start:{line:138,column:6},end:{line:151,column:7}},type:"if",locations:[{start:{line:138,column:6},end:{line:151,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:138},11:{loc:{start:{line:138,column:10},end:{line:138,column:51}},type:"binary-expr",locations:[{start:{line:138,column:10},end:{line:138,column:26}},{start:{line:138,column:30},end:{line:138,column:51}}],line:138},12:{loc:{start:{line:146,column:10},end:{line:148,column:11}},type:"if",locations:[{start:{line:146,column:10},end:{line:148,column:11}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:146},13:{loc:{start:{line:146,column:14},end:{line:146,column:68}},type:"binary-expr",locations:[{start:{line:146,column:14},end:{line:146,column:32}},{start:{line:146,column:36},end:{line:146,column:68}}],line:146},14:{loc:{start:{line:160,column:6},end:{line:173,column:7}},type:"if",locations:[{start:{line:160,column:6},end:{line:173,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:160},15:{loc:{start:{line:167,column:22},end:{line:167,column:98}},type:"binary-expr",locations:[{start:{line:167,column:22},end:{line:167,column:57}},{start:{line:167,column:61},end:{line:167,column:98}}],line:167},16:{loc:{start:{line:177,column:17},end:{line:177,column:96}},type:"binary-expr",locations:[{start:{line:177,column:17},end:{line:177,column:29}},{start:{line:177,column:33},end:{line:177,column:62}},{start:{line:177,column:66},end:{line:177,column:96}}],line:177},17:{loc:{start:{line:180,column:8},end:{line:182,column:9}},type:"if",locations:[{start:{line:180,column:8},end:{line:182,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:180},18:{loc:{start:{line:187,column:52},end:{line:187,column:153}},type:"binary-expr",locations:[{start:{line:187,column:52},end:{line:187,column:69}},{start:{line:187,column:73},end:{line:187,column:112}},{start:{line:187,column:116},end:{line:187,column:153}}],line:187},19:{loc:{start:{line:188,column:53},end:{line:188,column:105}},type:"binary-expr",locations:[{start:{line:188,column:53},end:{line:188,column:84}},{start:{line:188,column:88},end:{line:188,column:105}}],line:188},20:{loc:{start:{line:196,column:25},end:{line:196,column:43}},type:"binary-expr",locations:[{start:{line:196,column:25},end:{line:196,column:37}},{start:{line:196,column:41},end:{line:196,column:43}}],line:196},21:{loc:{start:{line:239,column:26},end:{line:239,column:90}},type:"cond-expr",locations:[{start:{line:239,column:69},end:{line:239,column:79}},{start:{line:239,column:82},end:{line:239,column:90}}],line:239}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0,74:0,75:0,76:0,77:0,78:0,79:0,80:0,81:0,82:0,83:0,84:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0,0],17:[0,0],18:[0,0,0],19:[0,0],20:[0,0],21:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/LayerList.tsx"],names:[],mappings:"AAiNoB,cAkEd,YAlEc;AAjNpB,OAAO,WAAuB;AAC9B,OAAO,gBAAgB;AACvB,OAAO,YAAY;AAEnB,OAAO,oBAAoB;AAC3B,OAAO,mBAAmB;AAC1B,OAAO,cAAc;AAErB,SAAwB,yBAAwB;AAEhD,OAAO,sBAAsB;AAC7B,SAAS,yBAAyB,mBAAmB;AAsBrD,MAAM,2BAA2B,MAAM,UAA4D;AAAA,EACjG,OAAO,eAAe;AAAA,IACpB,eAAe,MAAM;AAAA,IAAC;AAAA,EACxB;AAAA,EACA;AAAA,EACA;AAAA,EAEA,YAAY,OAAgC;AAC1C,UAAM,KAAK;AACX,SAAK,kBAAkB,MAAM,UAAU;AACvC,SAAK,qBAAqB,MAAM,UAAU;AAC1C,SAAK,QAAQ;AAAA,MACX,iBAAiB,CAAC;AAAA,MAClB,sBAAsB;AAAA,MACtB,MAAM;AAAA,QACJ,KAAK,CAAC,iBAAiB;AAAA,MACzB;AAAA,MACA,QAAQ;AAAA,QACN,KAAK;AAAA,MACP;AAAA,IACF;AAAA,EACF;AAAA,EAEA,YAAY,WAAmB;AAC7B,SAAK,SAAS;AAAA,MACZ,MAAM;AAAA,QACJ,GAAG,KAAK,MAAM;AAAA,QACd,CAAC,SAAS,GAAG,CAAC,iBAAiB;AAAA,MACjC;AAAA,MACA,QAAQ;AAAA,QACN,GAAG,KAAK,MAAM;AAAA,QACd,CAAC,SAAS,GAAG,CAAC,KAAK,MAAM,OAAO,SAAS;AAAA,MAC3C;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,eAAe,MAAM;AACnB,QAAI,MAAM;AAEV,UAAM,YAAqC,CAAC;AAE5C,SAAK,cAAc,EAAE,QAAQ,YAAU;AACrC,YAAM,cAAc,YAAY,OAAO,CAAC,EAAE,EAAE;AAC5C,YAAM,YAAY,CAAC,aAAa,GAAG,EAAE,KAAK,GAAG;AAG7C,UAAI,OAAO,SAAS,GAAG;AACrB,kBAAU,SAAS,IAAI,KAAK,MAAM;AAAA,MACpC;AAEA,aAAO,QAAQ,CAAC,WAAW;AACzB,eAAO;AAAA,MACT,CAAC;AAAA,IACH,CAAC;AAED,SAAK,SAAS;AAAA,MACZ,iBAAiB;AAAA,MACjB,sBAAsB,CAAC,KAAK,MAAM;AAAA,IACpC,CAAC;AAAA,EACH;AAAA,EAEA,gBAA0D;AACxD,UAAM,SAAS,CAAC;AAChB,UAAM,eAAe,oBAAI,IAAI;AAE7B,aAAS,IAAI,GAAG,IAAI,KAAK,MAAM,OAAO,QAAQ,KAAK;AACjD,YAAM,YAAY,KAAK,MAAM,OAAO,CAAC;AACrC,YAAM,gBAAgB,KAAK,MAAM,OAAO,IAAE,CAAC;AAC3C,mBAAa;AAAA,QAAI,UAAU;AAAA,QACzB,aAAa,IAAI,UAAU,EAAE,IAAI,aAAa,IAAI,UAAU,EAAE,IAAI,IAAI;AAAA,MACxE;AACA,YAAM,QAAQ;AAAA,QACZ,GAAG;AAAA,QACH,KAAK,eAAe,UAAU,EAAE,IAAI,aAAa,IAAI,UAAU,EAAE,CAAC;AAAA,MACpE;AACA,UAAG,iBAAiB,YAAY,cAAc,EAAE,KAAK,YAAY,MAAM,EAAE,GAAG;AAC1E,cAAM,YAAY,OAAO,OAAO,SAAS,CAAC;AAC1C,kBAAU,KAAK,KAAK;AAAA,MACtB,OAAO;AACL,eAAO,KAAK,CAAC,KAAK,CAAC;AAAA,MACrB;AAAA,IACF;AACA,WAAO;AAAA,EACT;AAAA,EAEA,iBAAiB,aAAqB,KAAa;AACjD,UAAM,YAAY,CAAC,aAAa,GAAG,EAAE,KAAK,GAAG;AAC7C,UAAM,YAAY,EAAE,GAAG,KAAK,MAAM,gBAAgB;AAClD,QAAG,aAAa,KAAK,MAAM,iBAAiB;AAC1C,gBAAU,SAAS,IAAI,CAAC,KAAK,MAAM,gBAAgB,SAAS;AAAA,IAC9D,OAAO;AACL,gBAAU,SAAS,IAAI;AAAA,IACzB;AACA,SAAK,SAAS;AAAA,MACZ,iBAAiB;AAAA,IACnB,CAAC;AAAA,EACH;AAAA,EAEA,YAAY,aAAqB,KAAa;AAC5C,UAAM,YAAY,KAAK,MAAM,gBAAgB,CAAC,aAAa,GAAG,EAAE,KAAK,GAAG,CAAC;AACzE,WAAO,cAAc,SAAY,OAAO;AAAA,EAC1C;AAAA,EAEA,sBAAuB,WAAoC,WAAoC;AAE7F,QAAI,KAAK,UAAU,WAAW;AAC5B,aAAO;AAAA,IACT;AAIA,aAAS,iBAAiB,OAA2B;AACnD,YAAM,MAAiD;AAAA,QACrD,IAAI,MAAM;AAAA,MACZ;AAEA,UAAI,MAAM,QAAQ;AAChB,YAAI,SAAS;AAAA,UACX,YAAY,MAAM,OAAO;AAAA,QAC3B;AAAA,MACF;AACA,aAAO;AAAA,IACT;AACA,UAAM,cAAc,OAAO;AAAA,MACzB,UAAU,OAAO,IAAI,gBAAgB;AAAA,MACrC,KAAK,MAAM,OAAO,IAAI,gBAAgB;AAAA,IACxC;AAEA,aAAS,cAAc,OAAgC;AACrD,YAAM,MAAM;AAAA,QACV,GAAG;AAAA,MACL;AACA,aAAO,IAAI,QAAQ;AACnB,aAAO;AAAA,IACT;AAIA,UAAM,aAAa,OAAO;AAAA,MACxB,cAAc,KAAK,KAAK;AAAA,MACxB,cAAc,SAAS;AAAA,IACzB;AAEA,UAAM,eAAe,EAAE,eAAe;AACtC,WAAO;AAAA,EACT;AAAA,EAEA,mBAAoB,WAAoC;AACtD,QAAI,UAAU,uBAAuB,KAAK,MAAM,oBAAoB;AAClE,YAAM,mBAAmB,KAAK,gBAAgB;AAC9C,UAAI,oBAAoB,iBAAiB,MAAM;AAC7C,cAAM,SAAS,iBAAiB;AAChC,cAAM,UAAU;AAAA,UACd,MAAM,KAAK,mBAAmB;AAAA,UAC9B,WAAW;AAAA,QACb;AACA,cAAM,WAAW,IAAI,qBAAqB,aAAW;AACnD,mBAAS,UAAU,MAAM;AACzB,cAAI,QAAQ,SAAS,KAAK,QAAQ,CAAC,EAAE,oBAAoB,GAAG;AAC1D,mBAAO,eAAe;AAAA,UACxB;AAAA,QACF,GAAG,OAAO;AAEV,iBAAS,QAAQ,MAAM;AAAA,MACzB;AAAA,IACF;AAAA,EACF;AAAA,EAEA,SAAS;AAEP,UAAM,YAA2B,CAAC;AAClC,QAAI,MAAM;AACV,UAAM,gBAAgB,KAAK,cAAc;AACzC,kBAAc,QAAQ,YAAU;AAC9B,YAAM,cAAc,YAAY,OAAO,CAAC,EAAE,EAAE;AAC5C,UAAG,OAAO,SAAS,GAAG;AACpB,cAAM,MAAM;AAAA,UAAC;AAAA;AAAA,YACX,eAAa,CAAC,aAAa,GAAG,EAAE,KAAK,GAAG;AAAA,YACxC,iBAAe,OAAO,IAAI,OAAK,EAAE,GAAG,EAAE,KAAK,GAAG;AAAA,YAE9C,OAAO;AAAA,YACP,UAAU,CAAC,KAAK,YAAY,aAAa,GAAG,KAAK,QAAQ,KAAK,MAAM;AAAA,YACpE,gBAAgB,KAAK,iBAAiB,KAAK,MAAM,aAAa,GAAG;AAAA;AAAA,UAH5D,SAAS,WAAW,IAAI,GAAG;AAAA,QAIlC;AACA,kBAAU,KAAK,GAAG;AAAA,MACpB;AAEA,aAAO,QAAQ,CAAC,OAAO,eAAe;AACpC,cAAM,WAAW,wBAAwB,KAAK,MAAM,QAAQ,GAAG;AAE/D,cAAM,aAAa,KAAK,MAAM,OAAO,KAAK,WAAS;AACjD,iBACE,MAAM,UACN,MAAM,OAAO,SAAS,WACtB,MAAM,OAAO,KAAK,SAAS;AAAA,QAE/B,CAAC;AAED,cAAM,kBAAgD,CAAC;AACvD,YAAI,QAAQ,KAAK,MAAM,oBAAoB;AACzC,0BAAgB,MAAM,KAAK;AAAA,QAC7B;AAEA,cAAM,WAAW;AAAA,UAAC;AAAA;AAAA,YAChB,WAAW,WAAW;AAAA,cACpB,sCAAsC,OAAO,SAAS,KAAK,KAAK,YAAY,aAAa,QAAQ,KAAK,QAAQ,KAAK,MAAM;AAAA,cACzH,uCAAuC,cAAc,OAAO,SAAS,KAAK,OAAO,SAAS;AAAA,cAC1F,mCAAmC,CAAC,CAAC;AAAA,YACvC,CAAC;AAAA,YACD,OAAO;AAAA,YAEP,IAAI,MAAM;AAAA,YACV,SAAS,MAAM;AAAA,YACf,YAAY;AAAA,YACZ,WAAW,MAAM;AAAA,YACjB,aAAa,MAAM,UAAU,CAAC,GAAG;AAAA,YACjC,YAAY,QAAQ,KAAK,MAAM;AAAA,YAC/B,eAAe,KAAK,MAAM;AAAA,YAC1B,gBAAgB,KAAK,MAAM,gBAAgB,KAAK,IAAI;AAAA,YACpD,aAAa,KAAK,MAAM,YAAY,KAAK,IAAI;AAAA,YAC7C,yBAAyB,KAAK,MAAM,wBAAwB,KAAK,IAAI;AAAA,YACpE,GAAG;AAAA;AAAA,UAXC,MAAM;AAAA,QAYb;AACA,kBAAU,KAAK,QAAQ;AACvB,eAAO;AAAA,MACT,CAAC;AAAA,IACH,CAAC;AAED,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,MAAK;AAAA,QACL,cAAW;AAAA,QACX,KAAK,KAAK;AAAA,QAEV;AAAA;AAAA,YAAC;AAAA;AAAA,cAEC,QAAQ,KAAK,MAAM;AAAA,cACnB,SAAS,KAAK,MAAM;AAAA,cACpB,QAAQ,KAAK,MAAM,OAAO;AAAA,cAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,KAAK;AAAA,cAC/C,gBAAgB,KAAK,MAAM;AAAA;AAAA,YALtB,KAAK,MAAM,KAAK;AAAA,UAMvB;AAAA,UACA,qBAAC,YAAO,WAAU,8BAChB;AAAA,gCAAC,UAAK,WAAU,oCAAmC,oBAAM;AAAA,YACzD,oBAAC,UAAK,WAAU,kBAAiB;AAAA,YACjC,oBAAC,SAAI,WAAU,6BACb,8BAAC,SAAI,WAAU,wBACb;AAAA,cAAC;AAAA;AAAA,gBACC,IAAG;AAAA,gBACH,eAAY;AAAA,gBACZ,SAAS,KAAK;AAAA,gBACd,WAAU;AAAA,gBACT,eAAK,MAAM,yBAAyB,OAAO,aAAa;AAAA;AAAA,YAC3D,GACF,GACF;AAAA,YACA,oBAAC,SAAI,WAAU,6BACb,8BAAC,SAAI,WAAU,wBACb;AAAA,cAAC;AAAA;AAAA,gBACC,SAAS,KAAK,YAAY,KAAK,MAAM,KAAK;AAAA,gBAC1C,eAAY;AAAA,gBACZ,WAAU;AAAA,gBAA2C;AAAA;AAAA,YAEvD,GACF,GACF;AAAA,aACF;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,MAAK;AAAA,cACL,cAAW;AAAA,cAEX,8BAAC,QAAG,WAAU,iCACX,qBACH;AAAA;AAAA,UACF;AAAA;AAAA;AAAA,IACF;AAAA,EACF;AACF;AAGA,MAAM,6BAA6B,kBAAkB,CAAC,UAAmC,oBAAC,sBAAoB,GAAG,OAAO,CAAE;AAM1H,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACL,GAAG,KAAK;AAAA,QACT,aAAY;AAAA,QACZ,WAAW,KAAK,MAAM,YAAY,KAAK,IAAI;AAAA,QAC3C,eAAe;AAAA,QACf,mBAAmB,MAAM;AAAA;AAAA,IAC3B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a7cd6405e81ca6260ef85d5394a18c33340b5775"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Qt=function(){return s},s}Qt();class aW extends bn.Component{constructor(t){Qt().f[1]++,Qt().s[1]++;super(t);nn(this,"selectedItemRef");nn(this,"scrollContainerRef");nn(this,"toggleLayers",(Qt().s[6]++,()=>{Qt().f[3]++;let t=(Qt().s[7]++,0);const r=(Qt().s[8]++,{});Qt().s[9]++,this.groupedLayers().forEach(i=>{Qt().f[4]++;const o=(Qt().s[10]++,Wg(i[0].id)),s=(Qt().s[11]++,[o,t].join("-"));Qt().s[12]++,i.length>1?(Qt().b[0][0]++,Qt().s[13]++,r[s]=this.state.areAllGroupsExpanded):Qt().b[0][1]++,Qt().s[14]++,i.forEach(a=>{Qt().f[5]++,Qt().s[15]++,t+=1})}),Qt().s[16]++,this.setState({collapsedGroups:r,areAllGroupsExpanded:!this.state.areAllGroupsExpanded})}));Qt().s[2]++,this.selectedItemRef=bn.createRef(),Qt().s[3]++,this.scrollContainerRef=bn.createRef(),Qt().s[4]++,this.state={collapsedGroups:{},areAllGroupsExpanded:!1,keys:{add:+Oy()},isOpen:{add:!1}}}toggleModal(t){Qt().f[2]++,Qt().s[5]++,this.setState({keys:{...this.state.keys,[t]:+Oy()},isOpen:{...this.state.isOpen,[t]:!this.state.isOpen[t]}})}groupedLayers(){Qt().f[6]++;const t=(Qt().s[17]++,[]),r=(Qt().s[18]++,new Map);Qt().s[19]++;for(let i=(Qt().s[20]++,0);i<this.props.layers.length;i++){const o=(Qt().s[21]++,this.props.layers[i]),s=(Qt().s[22]++,this.props.layers[i-1]);Qt().s[23]++,r.set(o.id,r.has(o.id)?(Qt().b[1][0]++,r.get(o.id)+1):(Qt().b[1][1]++,0));const a=(Qt().s[24]++,{...o,key:`layers-list-${o.id}-${r.get(o.id)}`});if(Qt().s[25]++,Qt().b[3][0]++,s&&(Qt().b[3][1]++,Wg(s.id)==Wg(a.id))){Qt().b[2][0]++;const f=(Qt().s[26]++,t[t.length-1]);Qt().s[27]++,f.push(a)}else Qt().b[2][1]++,Qt().s[28]++,t.push([a])}return Qt().s[29]++,t}toggleLayerGroup(t,r){Qt().f[7]++;const i=(Qt().s[30]++,[t,r].join("-")),o=(Qt().s[31]++,{...this.state.collapsedGroups});Qt().s[32]++,i in this.state.collapsedGroups?(Qt().b[4][0]++,Qt().s[33]++,o[i]=!this.state.collapsedGroups[i]):(Qt().b[4][1]++,Qt().s[34]++,o[i]=!1),Qt().s[35]++,this.setState({collapsedGroups:o})}isCollapsed(t,r){Qt().f[8]++;const i=(Qt().s[36]++,this.state.collapsedGroups[[t,r].join("-")]);return Qt().s[37]++,i===void 0?(Qt().b[5][0]++,!0):(Qt().b[5][1]++,i)}shouldComponentUpdate(t,r){if(Qt().f[9]++,Qt().s[38]++,this.state!==r)return Qt().b[6][0]++,Qt().s[39]++,!0;Qt().b[6][1]++;function i(g){Qt().f[10]++;const x=(Qt().s[40]++,{id:g.id});return Qt().s[41]++,g.layout?(Qt().b[7][0]++,Qt().s[42]++,x.layout={visibility:g.layout.visibility}):Qt().b[7][1]++,Qt().s[43]++,x}const o=(Qt().s[44]++,p6.isEqual(t.layers.map(i),this.props.layers.map(i)));function s(g){Qt().f[11]++;const x=(Qt().s[45]++,{...g});return Qt().s[46]++,delete x.layers,Qt().s[47]++,x}const a=(Qt().s[48]++,p6.isEqual(s(this.props),s(t))),f=(Qt().s[49]++,Qt().b[8][0]++,!(o&&(Qt().b[8][1]++,a)));return Qt().s[50]++,f}componentDidUpdate(t){if(Qt().f[12]++,Qt().s[51]++,t.selectedLayerIndex!==this.props.selectedLayerIndex){Qt().b[9][0]++;const r=(Qt().s[52]++,this.selectedItemRef.current);if(Qt().s[53]++,Qt().b[11][0]++,r&&(Qt().b[11][1]++,r.node)){Qt().b[10][0]++;const i=(Qt().s[54]++,r.node),o=(Qt().s[55]++,{root:this.scrollContainerRef.current,threshold:1}),s=(Qt().s[56]++,new IntersectionObserver(a=>{Qt().f[13]++,Qt().s[57]++,s.unobserve(i),Qt().s[58]++,Qt().b[13][0]++,a.length>0&&(Qt().b[13][1]++,a[0].intersectionRatio<1)?(Qt().b[12][0]++,Qt().s[59]++,i.scrollIntoView()):Qt().b[12][1]++},o));Qt().s[60]++,s.observe(i)}else Qt().b[10][1]++}else Qt().b[9][1]++}render(){Qt().f[14]++;const t=(Qt().s[61]++,[]);let r=(Qt().s[62]++,0);const i=(Qt().s[63]++,this.groupedLayers());return Qt().s[64]++,i.forEach(o=>{Qt().f[15]++;const s=(Qt().s[65]++,Wg(o[0].id));if(Qt().s[66]++,o.length>1){Qt().b[14][0]++;const a=(Qt().s[67]++,N.jsx(YAe,{"data-wd-key":[s,r].join("-"),"aria-controls":o.map(f=>(Qt().f[16]++,Qt().s[68]++,f.key)).join(" "),title:s,isActive:(Qt().b[15][0]++,!this.isCollapsed(s,r)||(Qt().b[15][1]++,r===this.props.selectedLayerIndex)),onActiveToggle:this.toggleLayerGroup.bind(this,s,r)},`group-${s}-${r}`));Qt().s[69]++,t.push(a)}else Qt().b[14][1]++;Qt().s[70]++,o.forEach((a,f)=>{var P;Qt().f[17]++;const g=(Qt().s[71]++,Phe(this.props.layers,r)),x=(Qt().s[72]++,this.props.errors.find(R=>(Qt().f[18]++,Qt().s[73]++,Qt().b[16][0]++,R.parsed&&(Qt().b[16][1]++,R.parsed.type==="layer")&&(Qt().b[16][2]++,R.parsed.data.index==r)))),k=(Qt().s[74]++,{});Qt().s[75]++,r===this.props.selectedLayerIndex?(Qt().b[17][0]++,Qt().s[76]++,k.ref=this.selectedItemRef):Qt().b[17][1]++;const B=(Qt().s[77]++,N.jsx(Mce,{className:Af({"maputnik-layer-list-item-collapsed":(Qt().b[18][0]++,o.length>1&&(Qt().b[18][1]++,this.isCollapsed(s,g))&&(Qt().b[18][2]++,r!==this.props.selectedLayerIndex)),"maputnik-layer-list-item-group-last":(Qt().b[19][0]++,f==o.length-1&&(Qt().b[19][1]++,o.length>1)),"maputnik-layer-list-item--error":!!x}),index:r,id:a.key,layerId:a.id,layerIndex:r,layerType:a.type,visibility:(Qt().b[20][0]++,a.layout||(Qt().b[20][1]++,{})).visibility,isSelected:r===this.props.selectedLayerIndex,onLayerSelect:this.props.onLayerSelect,onLayerDestroy:(P=this.props.onLayerDestroy)==null?void 0:P.bind(this),onLayerCopy:this.props.onLayerCopy.bind(this),onLayerVisibilityToggle:this.props.onLayerVisibilityToggle.bind(this),...k},a.key));Qt().s[78]++,t.push(B),Qt().s[79]++,r+=1})}),Qt().s[80]++,N.jsxs("section",{className:"maputnik-layer-list",role:"complementary","aria-label":"Layers list",ref:this.scrollContainerRef,children:[N.jsx(Ihe,{layers:this.props.layers,sources:this.props.sources,isOpen:this.state.isOpen.add,onOpenToggle:this.toggleModal.bind(this,"add"),onLayersChange:this.props.onLayersChange},this.state.keys.add),N.jsxs("header",{className:"maputnik-layer-list-header",children:[N.jsx("span",{className:"maputnik-layer-list-header-title",children:"Layers"}),N.jsx("span",{className:"maputnik-space"}),N.jsx("div",{className:"maputnik-default-property",children:N.jsx("div",{className:"maputnik-multibutton",children:N.jsx("button",{id:"skip-target-layer-list","data-wd-key":"skip-target-layer-list",onClick:this.toggleLayers,className:"maputnik-button",children:this.state.areAllGroupsExpanded===!0?(Qt().b[21][0]++,"Collapse"):(Qt().b[21][1]++,"Expand")})})}),N.jsx("div",{className:"maputnik-default-property",children:N.jsx("div",{className:"maputnik-multibutton",children:N.jsx("button",{onClick:this.toggleModal.bind(this,"add"),"data-wd-key":"layer-list:add-layer",className:"maputnik-button maputnik-button-selected",children:"Add Layer"})})})]}),N.jsx("div",{role:"navigation","aria-label":"Layers list",children:N.jsx("ul",{className:"maputnik-layer-list-container",children:t})})]})}}nn(aW,"defaultProps",(Qt().s[0]++,{onLayerSelect:()=>{Qt().f[0]++}}));const Fhe=(Qt().s[81]++,_ce(e=>(Qt().f[19]++,Qt().s[82]++,N.jsx(aW,{...e}))));class Dhe extends bn.Component{render(){return Qt().f[20]++,Qt().s[83]++,N.jsx(Fhe,{...this.props,helperClass:"sortableHelper",onSortEnd:this.props.onMoveLayer.bind(this),useDragHandle:!0,shouldCancelStart:()=>(Qt().f[21]++,Qt().s[84]++,!1)})}}var E5={},sW="a menu outside a mounted Wrapper with an id, or a menu that does not exist";function Uhe(e,n){E5[e]=n}function Rhe(e){delete E5[e]}function Lhe(e,n){var t=E5[e];if(!t)throw new Error("Cannot open "+sW);t.openMenu(n)}function zhe(e,n){var t=E5[e];if(!t)throw new Error("Cannot close "+sW);t.closeMenu(n)}var lW={registerManager:Uhe,unregisterManager:Rhe,openMenu:Lhe,closeMenu:zhe};function gs(e){e=e||{};var n=e.keybindings||{};this._settings={keybindings:{next:n.next||{keyCode:40},prev:n.prev||{keyCode:38},first:n.first,last:n.last},wrap:e.wrap,stringSearch:e.stringSearch,stringSearchDelay:800},this._keybindingsLookup=[];var t,r;for(t in this._settings.keybindings)r=this._settings.keybindings[t],r&&[].concat(r).forEach((function(i){i.metaKey=i.metaKey||!1,i.ctrlKey=i.ctrlKey||!1,i.altKey=i.altKey||!1,i.shiftKey=i.shiftKey||!1,this._keybindingsLookup.push({action:t,eventMatcher:i})}).bind(this));this._searchString="",this._members=[],e.members&&this.setMembers(e.members),this._boundHandleKeydownEvent=this._handleKeydownEvent.bind(this)}gs.prototype.activate=function(){return document.addEventListener("keydown",this._boundHandleKeydownEvent,!0),this};gs.prototype.deactivate=function(){return document.removeEventListener("keydown",this._boundHandleKeydownEvent,!0),this._clearSearchStringRefreshTimer(),this};gs.prototype._handleKeydownEvent=function(e){var n=this._getActiveElementIndex();if(n!==-1){var t=!1;this._keybindingsLookup.forEach((function(r){if(jhe(r.eventMatcher,e))switch(t=!0,e.preventDefault(),r.action){case"next":this.moveFocusForward();break;case"prev":this.moveFocusBack();break;case"first":this.moveFocusToFirst();break;case"last":this.moveFocusToLast();break;default:return}}).bind(this)),t||this._handleUnboundKey(e)}};gs.prototype.moveFocusForward=function(){var e=this._getActiveElementIndex(),n;return e<this._members.length-1?n=e+1:this._settings.wrap?n=0:n=e,this.focusNodeAtIndex(n),n};gs.prototype.moveFocusBack=function(){var e=this._getActiveElementIndex(),n;return e>0?n=e-1:this._settings.wrap?n=this._members.length-1:n=e,this.focusNodeAtIndex(n),n};gs.prototype.moveFocusToFirst=function(){this.focusNodeAtIndex(0)};gs.prototype.moveFocusToLast=function(){this.focusNodeAtIndex(this._members.length-1)};gs.prototype._handleUnboundKey=function(e){if(this._settings.stringSearch){if(this._searchString!==""&&(e.key===" "||e.keyCode===32))return e.preventDefault(),-1;if(!Whe(e.keyCode)||e.ctrlKey||e.metaKey||e.altKey)return-1;e.preventDefault(),this._addToSearchString(String.fromCharCode(e.keyCode)),this._runStringSearch()}};gs.prototype._clearSearchString=function(){this._searchString=""};gs.prototype._addToSearchString=function(e){this._searchString+=e.toLowerCase()};gs.prototype._startSearchStringRefreshTimer=function(){var e=this;this._clearSearchStringRefreshTimer(),this._stringSearchTimer=setTimeout(function(){e._clearSearchString()},this._settings.stringSearchDelay)};gs.prototype._clearSearchStringRefreshTimer=function(){clearTimeout(this._stringSearchTimer)};gs.prototype._runStringSearch=function(){this._startSearchStringRefreshTimer(),this.moveFocusByString(this._searchString)};gs.prototype.moveFocusByString=function(e){for(var n,t=0,r=this._members.length;t<r;t++)if(n=this._members[t],!!n.text&&n.text.indexOf(e)===0)return uW(n.node)};gs.prototype._findIndexOfNode=function(e){for(var n=0,t=this._members.length;n<t;n++)if(this._members[n].node===e)return n;return-1};gs.prototype._getActiveElementIndex=function(){return this._findIndexOfNode(document.activeElement)};gs.prototype.focusNodeAtIndex=function(e){var n=this._members[e];return n&&uW(n.node),this};gs.prototype.addMember=function(e,n){var t=e.node||e,r=e.text||t.getAttribute("data-focus-group-text")||t.textContent||"";this._checkNode(t);var i=r.replace(/[\W_]/g,"").toLowerCase(),o={node:t,text:i};return n!=null?this._members.splice(n,0,o):this._members.push(o),this};gs.prototype.removeMember=function(e){var n=typeof e=="number"?e:this._findIndexOfNode(e);if(n!==-1)return this._members.splice(n,1),this};gs.prototype.clearMembers=function(){return this._members=[],this};gs.prototype.setMembers=function(e){this.clearMembers();for(var n=0,t=e.length;n<t;n++)this.addMember(e[n]);return this};gs.prototype.getMembers=function(){return this._members};gs.prototype._checkNode=function(e){if(!e.nodeType||e.nodeType!==window.Node.ELEMENT_NODE)throw new Error("focus-group: only DOM nodes allowed");return e};function jhe(e,n){for(var t in e)if(n[t]!==void 0&&e[t]!==n[t])return!1;return!0}function Whe(e){return e>=65&&e<=90}function uW(e){!e||!e.focus||(e.focus(),e.tagName.toLowerCase()==="input"&&e.select())}var Nhe=function(n){return new gs(n)},Ghe=Nhe,jT=lW,Qhe={wrap:!0,stringSearch:!0},$he={init:function(n){this.updateOptions(n),this.handleBlur=Yhe.bind(this),this.handleSelection=qhe.bind(this),this.handleMenuKey=Vhe.bind(this),this.focusGroup=Ghe(Qhe),this.button=null,this.menu=null,this.isOpen=!1},updateOptions:function(n){var t=this.options;this.options=n||this.options||{},typeof this.options.closeOnSelection>"u"&&(this.options.closeOnSelection=!0),typeof this.options.closeOnBlur>"u"&&(this.options.closeOnBlur=!0),this.options.id&&jT.registerManager(this.options.id,this),t&&t.id&&t.id!==this.options.id&&jT.unregisterManager(this.options.id,this)},focusItem:function(n){this.focusGroup.focusNodeAtIndex(n)},addItem:function(n){this.focusGroup.addMember(n)},clearItems:function(){this.focusGroup.clearMembers()},handleButtonNonArrowKey:function(n){this.focusGroup._handleUnboundKey(n)},destroy:function(){this.button=null,this.menu=null,this.focusGroup.deactivate(),clearTimeout(this.blurTimer),clearTimeout(this.moveFocusTimer)},update:function(){this.menu.setState({isOpen:this.isOpen}),this.button.setState({menuOpen:this.isOpen}),this.options.onMenuToggle&&this.options.onMenuToggle({isOpen:this.isOpen})},openMenu:function(n){if(!this.isOpen&&(n=n||{},n.focusMenu===void 0&&(n.focusMenu=!0),this.isOpen=!0,this.update(),this.focusGroup.activate(),n.focusMenu)){var t=this;this.moveFocusTimer=setTimeout(function(){t.focusItem(0)},0)}},closeMenu:function(n){this.isOpen&&(n=n||{},this.isOpen=!1,this.update(),n.focusButton&&this.button.ref.current.focus())},toggleMenu:function(n,t){n=n||{},t=t||{},this.isOpen?this.closeMenu(n):this.openMenu(t)}};function Yhe(){var e=this;e.blurTimer=setTimeout(function(){if(e.button){var n=e.button.ref.current;if(n){var t=n.ownerDocument.activeElement;if(!(n&&t===n)){var r=e.menu.ref.current;if(r===t){e.focusItem(0);return}r&&r.contains(t)||e.isOpen&&e.closeMenu({focusButton:!1})}}}},0)}function qhe(e,n){this.options.closeOnSelection&&this.closeMenu({focusButton:!0}),this.options.onSelection&&this.options.onSelection(e,n)}function Vhe(e){if(this.isOpen)switch(e.key){case"Escape":e.preventDefault(),this.closeMenu({focusButton:!0});break;case"Home":e.preventDefault(),this.focusGroup.moveFocusToFirst();break;case"End":e.preventDefault(),this.focusGroup.moveFocusToLast();break}}var Hhe=function(e){var n=Object.create($he);return n.init(e),n},Zhe=kr,Xhe=Zhe.createContext(),O5=Xhe,Wx=ph,B5={refType:Wx.oneOfType([Wx.func,Wx.shape({current:Wx.elementType})])},k5=function(e,n,t){t=t||{};for(var r in n)n.hasOwnProperty(r)&&(t[r]||(e[r]=n[r]))};function Jhe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function efe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function tfe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var FC=kr,cg=ph,nfe=Hhe,rfe=O5,ife=B5,ofe=ife.refType,DE=k5,J3={children:cg.node.isRequired,forwardedRef:ofe,onMenuToggle:cg.func,onSelection:cg.func,closeOnSelection:cg.bool,closeOnBlur:cg.bool,tag:cg.string},WT=function(n){return{onMenuToggle:n.onMenuToggle,onSelection:n.onSelection,closeOnSelection:n.closeOnSelection,closeOnBlur:n.closeOnBlur,id:n.id}},i8=function(e){tfe(n,e);function n(t){Jhe(this,n);var r=efe(this,e.call(this,t));return r.manager=nfe(WT(t)),r}return n.prototype.componentDidUpdate=function(){this.manager.updateOptions(WT(this.props))},n.prototype.render=function(){var r={};return DE(r,this.props,J3),FC.createElement(rfe.Provider,{value:this.manager},FC.createElement(this.props.tag,r,this.props.children))},n}(FC.Component);i8.propTypes=J3;i8.defaultProps={tag:"div"};var afe=FC.forwardRef(function(e,n){var t={forwardedRef:n};return DE(t,e,{children:J3.children,forwardedRef:J3.forwardedRef}),DE(t,{forwardedRef:n}),FC.createElement(i8,t,e.children)});function sfe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function NT(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function lfe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var uy=kr,Nx=ph,ufe=O5,Afe=B5,cfe=Afe.refType,w2=k5,DC={ambManager:Nx.object.isRequired,children:Nx.node.isRequired,disabled:Nx.bool,forwardedRef:cfe,tag:Nx.string},dfe=function(){return["button","fieldset","input","optgroup","option","select","textarea"]},o8=function(e){lfe(n,e);function n(){var t,r,i;sfe(this,n);for(var o=arguments.length,s=Array(o),a=0;a<o;a++)s[a]=arguments[a];return i=(t=(r=NT(this,e.call.apply(e,[this].concat(s))),r),r.ref=uy.createRef(),r.handleKeyDown=function(f){if(!r.props.disabled){var g=r.props.ambManager;switch(f.key){case"ArrowDown":f.preventDefault(),g.isOpen?g.focusItem(0):g.openMenu();break;case"Enter":case" ":f.preventDefault(),g.toggleMenu();break;case"Escape":g.handleMenuKey(f);break;default:g.handleButtonNonArrowKey(f)}}},r.handleClick=function(){r.props.disabled||r.props.ambManager.toggleMenu({},{focusMenu:!1})},r.setRef=function(f){r.ref.current=f,typeof r.props.forwardedRef=="function"?r.props.forwardedRef(f):r.props.forwardedRef&&(r.props.forwardedRef.current=f)},t),NT(r,i)}return n.prototype.componentDidMount=function(){this.props.ambManager.button=this},n.prototype.componentWillUnmount=function(){this.props.ambManager.destroy()},n.prototype.render=function(){var r=this.props,i=this.props.ambManager,o={role:"button",tabIndex:r.disabled?"":"0","aria-haspopup":!0,"aria-expanded":i.isOpen,"aria-disabled":r.disabled,onKeyDown:this.handleKeyDown,onClick:this.handleClick},s={};return w2(s,DC),dfe().indexOf(r.tag)>=0&&delete s.disabled,i.options.closeOnBlur&&(o.onBlur=i.handleBlur),w2(o,r,s),w2(o,{ref:this.setRef}),uy.createElement(r.tag,o,r.children)},n}(uy.Component);o8.propTypes=DC;o8.defaultProps={tag:"span"};var hfe=uy.forwardRef(function(e,n){return uy.createElement(ufe.Consumer,null,function(t){var r={ambManager:t,forwardedRef:n};return w2(r,e,{ambManager:DC.ambManager,children:DC.children,forwardedRef:DC.forwardedRef}),uy.createElement(o8,r,e.children)})}),ffe=function(n,t,r){var i=0,o=0,s=!1,a=!1,f=!1;n.addEventListener("click",g,r),n.addEventListener("touchstart",x,r);function g(W){f||t(W)}function x(W){f=!0,!s&&(s=!0,n.addEventListener("touchmove",k,r),n.addEventListener("touchend",B,r),n.addEventListener("touchcancel",P,r),a=!1,i=W.touches[0].clientX,o=W.touches[0].clientY)}function k(W){a||Math.abs(W.touches[0].clientX-i)<=10&&Math.abs(W.touches[0].clientY-o)<=10||(a=!0)}function B(W){s=!1,R(),a||t(W)}function P(){s=!1,a=!1,i=0,o=0}function R(){n.removeEventListener("touchmove",k,r),n.removeEventListener("touchend",B,r),n.removeEventListener("touchcancel",P,r)}function H(){n.removeEventListener("click",g,r),n.removeEventListener("touchstart",x,r),R()}return{remove:H}};function pfe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function GT(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function mfe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var Ay=kr,Hv=ph,gfe=ffe,yfe=O5,vfe=B5,Cfe=vfe.refType,UE=k5,UC={ambManager:Hv.object.isRequired,children:Hv.oneOfType([Hv.func,Hv.node]).isRequired,forwardedRef:Cfe,tag:Hv.string},a8=function(e){mfe(n,e);function n(){var t,r,i;pfe(this,n);for(var o=arguments.length,s=Array(o),a=0;a<o;a++)s[a]=arguments[a];return i=(t=(r=GT(this,e.call.apply(e,[this].concat(s))),r),r.ref=Ay.createRef(),r.addTapListener=function(){var f=r.ref.current;if(f){var g=f.ownerDocument;g&&(r.tapListener=gfe(g.documentElement,r.handleTap))}},r.handleTap=function(f){r.ref.current.contains(f.target)||r.props.ambManager.button.ref.current.contains(f.target)||r.props.ambManager.closeMenu()},r.setRef=function(f){r.ref.current=f,typeof r.props.forwardedRef=="function"?r.props.forwardedRef(f):r.props.forwardedRef&&(r.props.forwardedRef.current=f)},t),GT(r,i)}return n.prototype.componentDidMount=function(){this.props.ambManager.menu=this},n.prototype.componentDidUpdate=function(){var r=this.props.ambManager;r.options.closeOnBlur&&(r.isOpen&&!this.tapListener?this.addTapListener():!r.isOpen&&this.tapListener&&(this.tapListener.remove(),delete this.tapListener),r.isOpen||r.clearItems())},n.prototype.componentWillUnmount=function(){this.tapListener&&this.tapListener.remove(),this.props.ambManager.destroy()},n.prototype.render=function(){var r=this.props,i=this.props.ambManager,o=function(){return typeof r.children=="function"?r.children({isOpen:i.isOpen}):i.isOpen?r.children:!1}();if(!o)return!1;var s={onKeyDown:i.handleMenuKey,role:"menu",tabIndex:-1};return i.options.closeOnBlur&&(s.onBlur=i.handleBlur),UE(s,r,UC),UE(s,{ref:this.setRef}),Ay.createElement(r.tag,s,o)},n}(Ay.Component);a8.propTypes=UC;a8.defaultProps={tag:"div"};var _fe=Ay.forwardRef(function(e,n){return Ay.createElement(yfe.Consumer,null,function(t){var r={ambManager:t,forwardedRef:n};return UE(r,e,{ambManager:UC.ambManager,children:UC.children,forwardedRef:UC.forwardedRef}),Ay.createElement(a8,r,e.children)})});function bfe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function QT(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function xfe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var cy=kr,Zv=ph,wfe=O5,Mfe=B5,Sfe=Mfe.refType,AW=k5,RC={ambManager:Zv.object.isRequired,children:Zv.node.isRequired,forwardedRef:Sfe,tag:Zv.string,text:Zv.string,value:Zv.any},s8=function(e){xfe(n,e);function n(){var t,r,i;bfe(this,n);for(var o=arguments.length,s=Array(o),a=0;a<o;a++)s[a]=arguments[a];return i=(t=(r=QT(this,e.call.apply(e,[this].concat(s))),r),r.ref=cy.createRef(),r.handleKeyDown=function(f){f.key!=="Enter"&&f.key!==" "||r.props.tag==="a"&&r.props.href||(f.preventDefault(),r.selectItem(f))},r.selectItem=function(f){var g=typeof r.props.value<"u"?r.props.value:r.props.children;r.props.ambManager.handleSelection(g,f)},r.setRef=function(f){r.ref.current=f,typeof r.props.forwardedRef=="function"?r.props.forwardedRef(f):r.props.forwardedRef&&(r.props.forwardedRef.current=f)},t),QT(r,i)}return n.prototype.componentDidMount=function(){this.props.ambManager.addItem({node:this.ref.current,text:this.props.text})},n.prototype.render=function(){var r={onClick:this.selectItem,onKeyDown:this.handleKeyDown,role:"menuitem",tabIndex:"-1",ref:this.setRef};return AW(r,this.props,RC),cy.createElement(this.props.tag,r,this.props.children)},n}(cy.Component);s8.propTypes=RC;s8.defaultProps={tag:"div"};var Efe=cy.forwardRef(function(e,n){return cy.createElement(wfe.Consumer,null,function(t){var r={ambManager:t,forwardedRef:n};return AW(r,e,{ambManager:RC.ambManager,children:RC.children,forwardedRef:RC.forwardedRef}),cy.createElement(s8,r,e.children)})}),$T=lW,Gx={Wrapper:afe,Button:hfe,Menu:_fe,MenuItem:Efe,openMenu:$T.openMenu,closeMenu:$T.closeMenu};function I5(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function YT(e,n){for(var t=0;t<n.length;t++){var r=n[t];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l8(e,n,t){return n&&YT(e.prototype,n),t&&YT(e,t),e}function is(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function ff(){return ff=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},ff.apply(this,arguments)}function qT(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),t.push.apply(t,r)}return t}function RE(e){for(var n=1;n<arguments.length;n++){var t=arguments[n]!=null?arguments[n]:{};n%2?qT(Object(t),!0).forEach(function(r){is(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):qT(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}function u8(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),n&&LE(e,n)}function e4(e){return e4=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},e4(e)}function LE(e,n){return LE=Object.setPrototypeOf||function(r,i){return r.__proto__=i,r},LE(e,n)}function Ofe(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function Bfe(e,n){if(e==null)return{};var t={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(n.indexOf(i)>=0)&&(t[i]=e[i]);return t}function T5(e,n){if(e==null)return{};var t=Bfe(e,n),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(n.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(t[r]=e[r])}return t}function lh(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function kfe(e,n){return n&&(typeof n=="object"||typeof n=="function")?n:lh(e)}function A8(e){var n=Ofe();return function(){var r=e4(e),i;if(n){var o=e4(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return kfe(this,i)}}function Ife(e,n){return Pfe(e)||Dfe(e,n)||cW(e,n)||Rfe()}function Tfe(e){return Kfe(e)||Ffe(e)||cW(e)||Ufe()}function Kfe(e){if(Array.isArray(e))return zE(e)}function Pfe(e){if(Array.isArray(e))return e}function Ffe(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function Dfe(e,n){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var t=[],r=!0,i=!1,o=void 0;try{for(var s=e[Symbol.iterator](),a;!(r=(a=s.next()).done)&&(t.push(a.value),!(n&&t.length===n));r=!0);}catch(f){i=!0,o=f}finally{try{!r&&s.return!=null&&s.return()}finally{if(i)throw o}}return t}}function cW(e,n){if(e){if(typeof e=="string")return zE(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);if(t==="Object"&&e.constructor&&(t=e.constructor.name),t==="Map"||t==="Set")return Array.from(e);if(t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return zE(e,n)}}function zE(e,n){(n==null||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function Ufe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Rfe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Lfe=function e(n){var t=this,r=n.expanded,i=r===void 0?[]:r,o=n.allowMultipleExpanded,s=o===void 0?!1:o,a=n.allowZeroExpanded,f=a===void 0?!1:a;I5(this,e),is(this,"expanded",void 0),is(this,"allowMultipleExpanded",void 0),is(this,"allowZeroExpanded",void 0),is(this,"toggleExpanded",function(g){if(t.isItemDisabled(g))return t;var x=t.isItemExpanded(g);return x?t.augment({expanded:t.expanded.filter(function(k){return k!==g})}):t.augment({expanded:t.allowMultipleExpanded?[].concat(Tfe(t.expanded),[g]):[g]})}),is(this,"isItemDisabled",function(g){var x=t.isItemExpanded(g),k=t.expanded.length===1;return!!(x&&!t.allowZeroExpanded&&k)}),is(this,"isItemExpanded",function(g){return t.expanded.indexOf(g)!==-1}),is(this,"getPanelAttributes",function(g,x){var k=x??t.isItemExpanded(g);return{role:t.allowMultipleExpanded?void 0:"region","aria-hidden":t.allowMultipleExpanded?!k:void 0,"aria-labelledby":t.getButtonId(g),id:t.getPanelId(g),hidden:k?void 0:!0}}),is(this,"getHeadingAttributes",function(){return{role:"heading"}}),is(this,"getButtonAttributes",function(g,x){var k=x??t.isItemExpanded(g),B=t.isItemDisabled(g);return{id:t.getButtonId(g),"aria-disabled":B,"aria-expanded":k,"aria-controls":t.getPanelId(g),role:"button",tabIndex:0}}),is(this,"getPanelId",function(g){return"accordion__panel-".concat(g)}),is(this,"getButtonId",function(g){return"accordion__heading-".concat(g)}),is(this,"augment",function(g){return new e(RE({expanded:t.expanded,allowMultipleExpanded:t.allowMultipleExpanded,allowZeroExpanded:t.allowZeroExpanded},g))}),this.expanded=i,this.allowMultipleExpanded=s,this.allowZeroExpanded=f},dW=kr.createContext(null),hW=function(e){u8(t,e);var n=A8(t);function t(){var r;I5(this,t);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=n.call.apply(n,[this].concat(o)),is(lh(r),"state",new Lfe({expanded:r.props.preExpanded,allowMultipleExpanded:r.props.allowMultipleExpanded,allowZeroExpanded:r.props.allowZeroExpanded})),is(lh(r),"toggleExpanded",function(a){r.setState(function(f){return f.toggleExpanded(a)},function(){r.props.onChange&&r.props.onChange(r.state.expanded)})}),is(lh(r),"isItemDisabled",function(a){return r.state.isItemDisabled(a)}),is(lh(r),"isItemExpanded",function(a){return r.state.isItemExpanded(a)}),is(lh(r),"getPanelAttributes",function(a,f){return r.state.getPanelAttributes(a,f)}),is(lh(r),"getHeadingAttributes",function(){return r.state.getHeadingAttributes()}),is(lh(r),"getButtonAttributes",function(a,f){return r.state.getButtonAttributes(a,f)}),r}return l8(t,[{key:"render",value:function(){var i=this.state,o=i.allowZeroExpanded,s=i.allowMultipleExpanded;return kr.createElement(dW.Provider,{value:{allowMultipleExpanded:s,allowZeroExpanded:o,toggleExpanded:this.toggleExpanded,isItemDisabled:this.isItemDisabled,isItemExpanded:this.isItemExpanded,getPanelAttributes:this.getPanelAttributes,getHeadingAttributes:this.getHeadingAttributes,getButtonAttributes:this.getButtonAttributes}},this.props.children||null)}}]),t}(kr.PureComponent);is(hW,"defaultProps",{allowMultipleExpanded:!1,allowZeroExpanded:!1});var fW=function(e){u8(t,e);var n=A8(t);function t(){var r;I5(this,t);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=n.call.apply(n,[this].concat(o)),is(lh(r),"renderChildren",function(a){return a?r.props.children(a):null}),r}return l8(t,[{key:"render",value:function(){return kr.createElement(dW.Consumer,null,this.renderChildren)}}]),t}(kr.PureComponent),zfe=function(n){var t=n.className,r=t===void 0?"accordion":t,i=n.allowMultipleExpanded,o=n.allowZeroExpanded,s=n.onChange,a=n.preExpanded,f=T5(n,["className","allowMultipleExpanded","allowZeroExpanded","onChange","preExpanded"]);return kr.createElement(hW,{preExpanded:a,allowMultipleExpanded:i,allowZeroExpanded:o,onChange:s},kr.createElement("div",ff({"data-accordion-component":"Accordion",className:r},f)))},jE;(function(e){e.Accordion="Accordion",e.AccordionItem="AccordionItem",e.AccordionItemButton="AccordionItemButton",e.AccordionItemHeading="AccordionItemHeading",e.AccordionItemPanel="AccordionItemPanel"})(jE||(jE={}));var pW=jE,jfe=0,$M=jfe;function Wfe(){var e=$M;return $M=$M+1,"raa-".concat(e)}var Nfe=/[\u0009\u000a\u000c\u000d\u0020]/g;function M_(e){return e===""||Nfe.test(e)?(console.error('uuid must be a valid HTML5 id but was given "'.concat(e,'", ASCII whitespaces are forbidden')),!1):!0}var mW=kr.createContext(null),Gfe=function(n){var t=n.children,r=n.uuid,i=n.accordionContext,o=n.dangerouslySetExpanded,s=function(){i.toggleExpanded(r)},a=function(g){var x=o??g.isItemExpanded(r),k=g.isItemDisabled(r),B=g.getPanelAttributes(r,o),P=g.getHeadingAttributes(r),R=g.getButtonAttributes(r,o);return kr.createElement(mW.Provider,{value:{uuid:r,expanded:x,disabled:k,toggleExpanded:s,panelAttributes:B,headingAttributes:P,buttonAttributes:R}},t)};return kr.createElement(fW,null,a)},Qfe=function(n){return kr.createElement(fW,null,function(t){return kr.createElement(Gfe,ff({},n,{accordionContext:t}))})},K5=function(n){var t=n.children,r=function(o){return o?t(o):null};return kr.createElement(mW.Consumer,null,r)},gW=function(n){var t=n.uuid,r=n.dangerouslySetExpanded,i=n.className,o=i===void 0?"accordion__item":i,s=n.activeClassName,a=T5(n,["uuid","dangerouslySetExpanded","className","activeClassName"]),f=kr.useState(Wfe()),g=Ife(f,1),x=g[0],k=t??x,B=function(R){var H=R.expanded,W=H&&s?s:o;return kr.createElement("div",ff({"data-accordion-component":"AccordionItem",className:W},a))};return M_(k.toString()),a.id&&M_(a.id),kr.createElement(Qfe,{uuid:k,dangerouslySetExpanded:r},kr.createElement(K5,null,B))};gW.displayName=pW.AccordionItem;function yW(e){return e&&(e.matches('[data-accordion-component="Accordion"]')?e:yW(e.parentElement))}function P5(e){var n=yW(e);return n&&Array.from(n.querySelectorAll('[data-accordion-component="AccordionItemButton"]'))}function $fe(e){var n=P5(e)||[],t=n[0];t&&t.focus()}function Yfe(e){var n=P5(e)||[],t=n[n.length-1];t&&t.focus()}function qfe(e){var n=P5(e)||[],t=n.indexOf(e);if(t!==-1){var r=n[t+1];r&&r.focus()}}function Vfe(e){var n=P5(e)||[],t=n.indexOf(e);if(t!==-1){var r=n[t-1];r&&r.focus()}}var Jf={END:"End",ENTER:"Enter",HOME:"Home",SPACE:" ",SPACE_DEPRECATED:"Spacebar",UP:"ArrowUp",DOWN:"ArrowDown",LEFT:"ArrowLeft",RIGHT:"ArrowRight"},Hfe=function(n){var t=n.toggleExpanded,r=n.className,i=r===void 0?"accordion__button":r,o=T5(n,["toggleExpanded","className"]),s=function(f){var g=f.key;if((g===Jf.ENTER||g===Jf.SPACE||g===Jf.SPACE_DEPRECATED)&&(f.preventDefault(),t()),f.target instanceof HTMLElement)switch(g){case Jf.HOME:{f.preventDefault(),$fe(f.target);break}case Jf.END:{f.preventDefault(),Yfe(f.target);break}case Jf.LEFT:case Jf.UP:{f.preventDefault(),Vfe(f.target);break}case Jf.RIGHT:case Jf.DOWN:{f.preventDefault(),qfe(f.target);break}}};return o.id&&M_(o.id),kr.createElement("div",ff({className:i},o,{role:"button",tabIndex:0,onClick:t,onKeyDown:s,"data-accordion-component":"AccordionItemButton"}))},Zfe=function(n){return kr.createElement(K5,null,function(t){var r=t.toggleExpanded,i=t.buttonAttributes;return kr.createElement(Hfe,ff({toggleExpanded:r},n,i))})},Xfe={className:"accordion__heading","aria-level":3},Jfe=`AccordionItemButton may contain only one child element, which must be an instance of AccordionItemButton.
|
||
|
||
From the WAI-ARIA spec (https://www.w3.org/TR/wai-aria-practices-1.1/#accordion):
|
||
|
||
“The button element is the only element inside the heading element. That is, if there are other visually persistent elements, they are not included inside the heading element.”
|
||
|
||
`,vW=function(e){u8(t,e);var n=A8(t);function t(){var r;I5(this,t);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=n.call.apply(n,[this].concat(o)),is(lh(r),"ref",void 0),is(lh(r),"setRef",function(a){r.ref=a}),r}return l8(t,[{key:"componentDidUpdate",value:function(){t.VALIDATE(this.ref)}},{key:"componentDidMount",value:function(){t.VALIDATE(this.ref)}},{key:"render",value:function(){return kr.createElement("div",ff({"data-accordion-component":"AccordionItemHeading"},this.props,{ref:this.setRef}))}}],[{key:"VALIDATE",value:function(i){if(i===void 0)throw new Error("ref is undefined");if(!(i.childElementCount===1&&i.firstElementChild&&i.firstElementChild.getAttribute("data-accordion-component")==="AccordionItemButton"))throw new Error(Jfe)}}]),t}(kr.PureComponent);is(vW,"defaultProps",Xfe);var CW=function(n){return kr.createElement(K5,null,function(t){var r=t.headingAttributes;return n.id&&M_(n.id),kr.createElement(vW,ff({},n,r))})};CW.displayName=pW.AccordionItemHeading;var epe=function(n){var t=n.className,r=t===void 0?"accordion__panel":t,i=n.region,o=n.id,s=T5(n,["className","region","id"]),a=function(g){var x=g.panelAttributes;o&&M_(o);var k=RE(RE({},x),{},{"aria-labelledby":i?x["aria-labelledby"]:void 0});return kr.createElement("div",ff({"data-accordion-component":"AccordionItemPanel",className:r},s,k,{role:i?"region":void 0}))};return kr.createElement(K5,null,a)},YM={exports:{}},VT;function F5(){return VT||(VT=1,function(e,n){(function(t,r){e.exports=r()})(mf,function(){var t=navigator.userAgent,r=navigator.platform,i=/gecko\/\d/i.test(t),o=/MSIE \d/.test(t),s=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(t),a=/Edge\/(\d+)/.exec(t),f=o||s||a,g=f&&(o?document.documentMode||6:+(a||s)[1]),x=!a&&/WebKit\//.test(t),k=x&&/Qt\/\d+\.\d+/.test(t),B=!a&&/Chrome\/(\d+)/.exec(t),P=B&&+B[1],R=/Opera\//.test(t),H=/Apple Computer/.test(navigator.vendor),W=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(t),$=/PhantomJS/.test(t),q=H&&(/Mobile\/\w+/.test(t)||navigator.maxTouchPoints>2),oe=/Android/.test(t),ne=q||oe||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(t),ce=q||/Mac/.test(r),ae=/\bCrOS\b/.test(t),ue=/win/i.test(r),ye=R&&t.match(/Version\/(\d*\.\d*)/);ye&&(ye=Number(ye[1])),ye&&ye>=15&&(R=!1,x=!0);var Re=ce&&(k||R&&(ye==null||ye<12.11)),Ne=i||f&&g>=9;function rt(A){return new RegExp("(^|\\s)"+A+"(?:$|\\s)\\s*")}var ct=function(A,h){var b=A.className,_=rt(h).exec(b);if(_){var E=b.slice(_.index+_[0].length);A.className=b.slice(0,_.index)+(E?_[1]+E:"")}};function Fe(A){for(var h=A.childNodes.length;h>0;--h)A.removeChild(A.firstChild);return A}function He(A,h){return Fe(A).appendChild(h)}function Ce(A,h,b,_){var E=document.createElement(A);if(b&&(E.className=b),_&&(E.style.cssText=_),typeof h=="string")E.appendChild(document.createTextNode(h));else if(h)for(var U=0;U<h.length;++U)E.appendChild(h[U]);return E}function jt(A,h,b,_){var E=Ce(A,h,b,_);return E.setAttribute("role","presentation"),E}var Ft;document.createRange?Ft=function(A,h,b,_){var E=document.createRange();return E.setEnd(_||A,b),E.setStart(A,h),E}:Ft=function(A,h,b){var _=document.body.createTextRange();try{_.moveToElementText(A.parentNode)}catch{return _}return _.collapse(!0),_.moveEnd("character",b),_.moveStart("character",h),_};function Jt(A,h){if(h.nodeType==3&&(h=h.parentNode),A.contains)return A.contains(h);do if(h.nodeType==11&&(h=h.host),h==A)return!0;while(h=h.parentNode)}function Nt(A){var h=A.ownerDocument||A,b;try{b=A.activeElement}catch{b=h.body||null}for(;b&&b.shadowRoot&&b.shadowRoot.activeElement;)b=b.shadowRoot.activeElement;return b}function Ve(A,h){var b=A.className;rt(h).test(b)||(A.className+=(b?" ":"")+h)}function nt(A,h){for(var b=A.split(" "),_=0;_<b.length;_++)b[_]&&!rt(b[_]).test(h)&&(h+=" "+b[_]);return h}var Je=function(A){A.select()};q?Je=function(A){A.selectionStart=0,A.selectionEnd=A.value.length}:f&&(Je=function(A){try{A.select()}catch{}});function Vt(A){return A.display.wrapper.ownerDocument}function pt(A){return dt(A.display.wrapper)}function dt(A){return A.getRootNode?A.getRootNode():A.ownerDocument}function kt(A){return Vt(A).defaultView}function Dt(A){var h=Array.prototype.slice.call(arguments,1);return function(){return A.apply(null,h)}}function Se(A,h,b){h||(h={});for(var _ in A)A.hasOwnProperty(_)&&(b!==!1||!h.hasOwnProperty(_))&&(h[_]=A[_]);return h}function de(A,h,b,_,E){h==null&&(h=A.search(/[^\s\u00a0]/),h==-1&&(h=A.length));for(var U=_||0,Y=E||0;;){var J=A.indexOf(" ",U);if(J<0||J>=h)return Y+(h-U);Y+=J-U,Y+=b-Y%b,U=J+1}}var xe=function(){this.id=null,this.f=null,this.time=0,this.handler=Dt(this.onTimeout,this)};xe.prototype.onTimeout=function(A){A.id=0,A.time<=+new Date?A.f():setTimeout(A.handler,A.time-+new Date)},xe.prototype.set=function(A,h){this.f=h;var b=+new Date+A;(!this.id||b<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,A),this.time=b)};function Pe(A,h){for(var b=0;b<A.length;++b)if(A[b]==h)return b;return-1}var Ze=50,Xe={toString:function(){return"CodeMirror.Pass"}},wt={scroll:!1},Kt={origin:"*mouse"},Pt={origin:"+move"};function zn(A,h,b){for(var _=0,E=0;;){var U=A.indexOf(" ",_);U==-1&&(U=A.length);var Y=U-_;if(U==A.length||E+Y>=h)return _+Math.min(Y,h-E);if(E+=U-_,E+=b-E%b,_=U+1,E>=h)return _}}var mt=[""];function pn(A){for(;mt.length<=A;)mt.push(ir(mt)+" ");return mt[A]}function ir(A){return A[A.length-1]}function Sn(A,h){for(var b=[],_=0;_<A.length;_++)b[_]=h(A[_],_);return b}function nr(A,h,b){for(var _=0,E=b(h);_<A.length&&b(A[_])<=E;)_++;A.splice(_,0,h)}function Mr(){}function Qr(A,h){var b;return Object.create?b=Object.create(A):(Mr.prototype=A,b=new Mr),h&&Se(h,b),b}var _r=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function vi(A){return/\w/.test(A)||A>""&&(A.toUpperCase()!=A.toLowerCase()||_r.test(A))}function we(A,h){return h?h.source.indexOf("\\w")>-1&&vi(A)?!0:h.test(A):vi(A)}function V(A){for(var h in A)if(A.hasOwnProperty(h)&&A[h])return!1;return!0}var X=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function me(A){return A.charCodeAt(0)>=768&&X.test(A)}function At(A,h,b){for(;(b<0?h>0:h<A.length)&&me(A.charAt(h));)h+=b;return h}function bt(A,h,b){for(var _=h>b?-1:1;;){if(h==b)return h;var E=(h+b)/2,U=_<0?Math.ceil(E):Math.floor(E);if(U==h)return A(U)?h:b;A(U)?b=U:h=U+_}}function Et(A,h,b,_){if(!A)return _(h,b,"ltr",0);for(var E=!1,U=0;U<A.length;++U){var Y=A[U];(Y.from<b&&Y.to>h||h==b&&Y.to==h)&&(_(Math.max(Y.from,h),Math.min(Y.to,b),Y.level==1?"rtl":"ltr",U),E=!0)}E||_(h,b,"ltr")}var sr=null;function Lt(A,h,b){var _;sr=null;for(var E=0;E<A.length;++E){var U=A[E];if(U.from<h&&U.to>h)return E;U.to==h&&(U.from!=U.to&&b=="before"?_=E:sr=E),U.from==h&&(U.from!=U.to&&b!="before"?_=E:sr=E)}return _??sr}var Fn=function(){var A="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",h="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function b(pe){return pe<=247?A.charAt(pe):1424<=pe&&pe<=1524?"R":1536<=pe&&pe<=1785?h.charAt(pe-1536):1774<=pe&&pe<=2220?"r":8192<=pe&&pe<=8203?"w":pe==8204?"b":"L"}var _=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,E=/[stwN]/,U=/[LRr]/,Y=/[Lb1n]/,J=/[1n]/;function se(pe,We,Ye){this.level=pe,this.from=We,this.to=Ye}return function(pe,We){var Ye=We=="ltr"?"L":"R";if(pe.length==0||We=="ltr"&&!_.test(pe))return!1;for(var Mt=pe.length,yt=[],qt=0;qt<Mt;++qt)yt.push(b(pe.charCodeAt(qt)));for(var Zt=0,Bn=Ye;Zt<Mt;++Zt){var Wn=yt[Zt];Wn=="m"?yt[Zt]=Bn:Bn=Wn}for(var er=0,fn=Ye;er<Mt;++er){var ar=yt[er];ar=="1"&&fn=="r"?yt[er]="n":U.test(ar)&&(fn=ar,ar=="r"&&(yt[er]="R"))}for(var Ir=1,Br=yt[0];Ir<Mt-1;++Ir){var Xr=yt[Ir];Xr=="+"&&Br=="1"&&yt[Ir+1]=="1"?yt[Ir]="1":Xr==","&&Br==yt[Ir+1]&&(Br=="1"||Br=="n")&&(yt[Ir]=Br),Br=Xr}for(var fo=0;fo<Mt;++fo){var Ea=yt[fo];if(Ea==",")yt[fo]="N";else if(Ea=="%"){var ca=void 0;for(ca=fo+1;ca<Mt&&yt[ca]=="%";++ca);for(var Oa=fo&&yt[fo-1]=="!"||ca<Mt&&yt[ca]=="1"?"1":"N",Va=fo;Va<ca;++Va)yt[Va]=Oa;fo=ca-1}}for(var Ha=0,fl=Ye;Ha<Mt;++Ha){var zs=yt[Ha];fl=="L"&&zs=="1"?yt[Ha]="L":U.test(zs)&&(fl=zs)}for(var ds=0;ds<Mt;++ds)if(E.test(yt[ds])){var Za=void 0;for(Za=ds+1;Za<Mt&&E.test(yt[Za]);++Za);for(var Ba=(ds?yt[ds-1]:Ye)=="L",js=(Za<Mt?yt[Za]:Ye)=="L",sA=Ba==js?Ba?"L":"R":Ye,bc=ds;bc<Za;++bc)yt[bc]=sA;ds=Za-1}for(var Os=[],Ru,Bs=0;Bs<Mt;)if(Y.test(yt[Bs])){var o0=Bs;for(++Bs;Bs<Mt&&Y.test(yt[Bs]);++Bs);Os.push(new se(0,o0,Bs))}else{var UA=Bs,xc=Os.length,wc=We=="rtl"?1:0;for(++Bs;Bs<Mt&&yt[Bs]!="L";++Bs);for(var To=UA;To<Bs;)if(J.test(yt[To])){UA<To&&(Os.splice(xc,0,new se(1,UA,To)),xc+=wc);var cd=To;for(++To;To<Bs&&J.test(yt[To]);++To);Os.splice(xc,0,new se(2,cd,To)),xc+=wc,UA=To}else++To;UA<Bs&&Os.splice(xc,0,new se(1,UA,Bs))}return We=="ltr"&&(Os[0].level==1&&(Ru=pe.match(/^\s+/))&&(Os[0].from=Ru[0].length,Os.unshift(new se(0,0,Ru[0].length))),ir(Os).level==1&&(Ru=pe.match(/\s+$/))&&(ir(Os).to-=Ru[0].length,Os.push(new se(0,Mt-Ru[0].length,Mt)))),We=="rtl"?Os.reverse():Os}}();function on(A,h){var b=A.order;return b==null&&(b=A.order=Fn(A.text,h)),b}var m=[],un=function(A,h,b){if(A.addEventListener)A.addEventListener(h,b,!1);else if(A.attachEvent)A.attachEvent("on"+h,b);else{var _=A._handlers||(A._handlers={});_[h]=(_[h]||m).concat(b)}};function In(A,h){return A._handlers&&A._handlers[h]||m}function Gn(A,h,b){if(A.removeEventListener)A.removeEventListener(h,b,!1);else if(A.detachEvent)A.detachEvent("on"+h,b);else{var _=A._handlers,E=_&&_[h];if(E){var U=Pe(E,b);U>-1&&(_[h]=E.slice(0,U).concat(E.slice(U+1)))}}}function Zn(A,h){var b=In(A,h);if(b.length)for(var _=Array.prototype.slice.call(arguments,2),E=0;E<b.length;++E)b[E].apply(null,_)}function Ke(A,h,b){return typeof h=="string"&&(h={type:h,preventDefault:function(){this.defaultPrevented=!0}}),Zn(A,b||h.type,A,h),it(h)||h.codemirrorIgnore}function fe(A){var h=A._handlers&&A._handlers.cursorActivity;if(h)for(var b=A.curOp.cursorActivityHandlers||(A.curOp.cursorActivityHandlers=[]),_=0;_<h.length;++_)Pe(b,h[_])==-1&&b.push(h[_])}function _e(A,h){return In(A,h).length>0}function Ee(A){A.prototype.on=function(h,b){un(this,h,b)},A.prototype.off=function(h,b){Gn(this,h,b)}}function Te(A){A.preventDefault?A.preventDefault():A.returnValue=!1}function at(A){A.stopPropagation?A.stopPropagation():A.cancelBubble=!0}function it(A){return A.defaultPrevented!=null?A.defaultPrevented:A.returnValue==!1}function ht(A){Te(A),at(A)}function et(A){return A.target||A.srcElement}function Ct(A){var h=A.which;return h==null&&(A.button&1?h=1:A.button&2?h=3:A.button&4&&(h=2)),ce&&A.ctrlKey&&h==1&&(h=3),h}var rn=function(){if(f&&g<9)return!1;var A=Ce("div");return"draggable"in A||"dragDrop"in A}(),Gt;function $t(A){if(Gt==null){var h=Ce("span","");He(A,Ce("span",[h,document.createTextNode("x")])),A.firstChild.offsetHeight!=0&&(Gt=h.offsetWidth<=1&&h.offsetHeight>2&&!(f&&g<8))}var b=Gt?Ce("span",""):Ce("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return b.setAttribute("cm-text",""),b}var gn;function Jn(A){if(gn!=null)return gn;var h=He(A,document.createTextNode("AخA")),b=Ft(h,0,1).getBoundingClientRect(),_=Ft(h,1,2).getBoundingClientRect();return Fe(A),!b||b.left==b.right?!1:gn=_.right-b.right<3}var qn=`
|
||
|
||
b`.split(/\n/).length!=3?function(A){for(var h=0,b=[],_=A.length;h<=_;){var E=A.indexOf(`
|
||
`,h);E==-1&&(E=A.length);var U=A.slice(h,A.charAt(E-1)=="\r"?E-1:E),Y=U.indexOf("\r");Y!=-1?(b.push(U.slice(0,Y)),h+=Y+1):(b.push(U),h=E+1)}return b}:function(A){return A.split(/\r\n?|\n/)},Tr=window.getSelection?function(A){try{return A.selectionStart!=A.selectionEnd}catch{return!1}}:function(A){var h;try{h=A.ownerDocument.selection.createRange()}catch{}return!h||h.parentElement()!=A?!1:h.compareEndPoints("StartToEnd",h)!=0},vr=function(){var A=Ce("div");return"oncopy"in A?!0:(A.setAttribute("oncopy","return;"),typeof A.oncopy=="function")}(),Dr=null;function Yr(A){if(Dr!=null)return Dr;var h=He(A,Ce("span","x")),b=h.getBoundingClientRect(),_=Ft(h,0,1).getBoundingClientRect();return Dr=Math.abs(b.left-_.left)>1}var Zr={},Cr={};function ui(A,h){arguments.length>2&&(h.dependencies=Array.prototype.slice.call(arguments,2)),Zr[A]=h}function Ii(A,h){Cr[A]=h}function Io(A){if(typeof A=="string"&&Cr.hasOwnProperty(A))A=Cr[A];else if(A&&typeof A.name=="string"&&Cr.hasOwnProperty(A.name)){var h=Cr[A.name];typeof h=="string"&&(h={name:h}),A=Qr(h,A),A.name=h.name}else{if(typeof A=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(A))return Io("application/xml");if(typeof A=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(A))return Io("application/json")}return typeof A=="string"?{name:A}:A||{name:"null"}}function Ci(A,h){h=Io(h);var b=Zr[h.name];if(!b)return Ci(A,"text/plain");var _=b(A,h);if(so.hasOwnProperty(h.name)){var E=so[h.name];for(var U in E)E.hasOwnProperty(U)&&(_.hasOwnProperty(U)&&(_["_"+U]=_[U]),_[U]=E[U])}if(_.name=h.name,h.helperType&&(_.helperType=h.helperType),h.modeProps)for(var Y in h.modeProps)_[Y]=h.modeProps[Y];return _}var so={};function Yo(A,h){var b=so.hasOwnProperty(A)?so[A]:so[A]={};Se(h,b)}function ba(A,h){if(h===!0)return h;if(A.copyState)return A.copyState(h);var b={};for(var _ in h){var E=h[_];E instanceof Array&&(E=E.concat([])),b[_]=E}return b}function Ql(A,h){for(var b;A.innerMode&&(b=A.innerMode(h),!(!b||b.mode==A));)h=b.state,A=b.mode;return b||{mode:A,state:h}}function Ai(A,h,b){return A.startState?A.startState(h,b):!0}var Mi=function(A,h,b){this.pos=this.start=0,this.string=A,this.tabSize=h||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=b};Mi.prototype.eol=function(){return this.pos>=this.string.length},Mi.prototype.sol=function(){return this.pos==this.lineStart},Mi.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Mi.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},Mi.prototype.eat=function(A){var h=this.string.charAt(this.pos),b;if(typeof A=="string"?b=h==A:b=h&&(A.test?A.test(h):A(h)),b)return++this.pos,h},Mi.prototype.eatWhile=function(A){for(var h=this.pos;this.eat(A););return this.pos>h},Mi.prototype.eatSpace=function(){for(var A=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>A},Mi.prototype.skipToEnd=function(){this.pos=this.string.length},Mi.prototype.skipTo=function(A){var h=this.string.indexOf(A,this.pos);if(h>-1)return this.pos=h,!0},Mi.prototype.backUp=function(A){this.pos-=A},Mi.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=de(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?de(this.string,this.lineStart,this.tabSize):0)},Mi.prototype.indentation=function(){return de(this.string,null,this.tabSize)-(this.lineStart?de(this.string,this.lineStart,this.tabSize):0)},Mi.prototype.match=function(A,h,b){if(typeof A=="string"){var _=function(Y){return b?Y.toLowerCase():Y},E=this.string.substr(this.pos,A.length);if(_(E)==_(A))return h!==!1&&(this.pos+=A.length),!0}else{var U=this.string.slice(this.pos).match(A);return U&&U.index>0?null:(U&&h!==!1&&(this.pos+=U[0].length),U)}},Mi.prototype.current=function(){return this.string.slice(this.start,this.pos)},Mi.prototype.hideFirstChars=function(A,h){this.lineStart+=A;try{return h()}finally{this.lineStart-=A}},Mi.prototype.lookAhead=function(A){var h=this.lineOracle;return h&&h.lookAhead(A)},Mi.prototype.baseToken=function(){var A=this.lineOracle;return A&&A.baseToken(this.pos)};function rr(A,h){if(h-=A.first,h<0||h>=A.size)throw new Error("There is no line "+(h+A.first)+" in the document.");for(var b=A;!b.lines;)for(var _=0;;++_){var E=b.children[_],U=E.chunkSize();if(h<U){b=E;break}h-=U}return b.lines[h]}function lo(A,h,b){var _=[],E=h.line;return A.iter(h.line,b.line+1,function(U){var Y=U.text;E==b.line&&(Y=Y.slice(0,b.ch)),E==h.line&&(Y=Y.slice(h.ch)),_.push(Y),++E}),_}function Gi(A,h,b){var _=[];return A.iter(h,b,function(E){_.push(E.text)}),_}function la(A,h){var b=h-A.height;if(b)for(var _=A;_;_=_.parent)_.height+=b}function ve(A){if(A.parent==null)return null;for(var h=A.parent,b=Pe(h.lines,A),_=h.parent;_;h=_,_=_.parent)for(var E=0;_.children[E]!=h;++E)b+=_.children[E].chunkSize();return b+h.first}function Ge(A,h){var b=A.first;e:do{for(var _=0;_<A.children.length;++_){var E=A.children[_],U=E.height;if(h<U){A=E;continue e}h-=U,b+=E.chunkSize()}return b}while(!A.lines);for(var Y=0;Y<A.lines.length;++Y){var J=A.lines[Y],se=J.height;if(h<se)break;h-=se}return b+Y}function Ht(A,h){return h>=A.first&&h<A.first+A.size}function mn(A,h){return String(A.lineNumberFormatter(h+A.firstLineNumber))}function Ot(A,h,b){if(b===void 0&&(b=null),!(this instanceof Ot))return new Ot(A,h,b);this.line=A,this.ch=h,this.sticky=b}function En(A,h){return A.line-h.line||A.ch-h.ch}function zr(A,h){return A.sticky==h.sticky&&En(A,h)==0}function Lr(A){return Ot(A.line,A.ch)}function Ti(A,h){return En(A,h)<0?h:A}function po(A,h){return En(A,h)<0?A:h}function Cl(A,h){return Math.max(A.first,Math.min(h,A.first+A.size-1))}function br(A,h){if(h.line<A.first)return Ot(A.first,0);var b=A.first+A.size-1;return h.line>b?Ot(b,rr(A,b).text.length):_i(h,rr(A,h.line).text.length)}function _i(A,h){var b=A.ch;return b==null||b>h?Ot(A.line,h):b<0?Ot(A.line,0):A}function _l(A,h){for(var b=[],_=0;_<h.length;_++)b[_]=br(A,h[_]);return b}var Qa=function(A,h){this.state=A,this.lookAhead=h},ys=function(A,h,b,_){this.state=h,this.doc=A,this.line=b,this.maxLookAhead=_||0,this.baseTokens=null,this.baseTokenPos=1};ys.prototype.lookAhead=function(A){var h=this.doc.getLine(this.line+A);return h!=null&&A>this.maxLookAhead&&(this.maxLookAhead=A),h},ys.prototype.baseToken=function(A){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=A;)this.baseTokenPos+=2;var h=this.baseTokens[this.baseTokenPos+1];return{type:h&&h.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-A}},ys.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},ys.fromSaved=function(A,h,b){return h instanceof Qa?new ys(A,ba(A.mode,h.state),b,h.lookAhead):new ys(A,ba(A.mode,h),b)},ys.prototype.save=function(A){var h=A!==!1?ba(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new Qa(h,this.maxLookAhead):h};function qs(A,h,b,_){var E=[A.state.modeGen],U={};Hu(A,h.text,A.doc.mode,b,function(pe,We){return E.push(pe,We)},U,_);for(var Y=b.state,J=function(pe){b.baseTokens=E;var We=A.state.overlays[pe],Ye=1,Mt=0;b.state=!0,Hu(A,h.text,We.mode,b,function(yt,qt){for(var Zt=Ye;Mt<yt;){var Bn=E[Ye];Bn>yt&&E.splice(Ye,1,yt,E[Ye+1],Bn),Ye+=2,Mt=Math.min(yt,Bn)}if(qt)if(We.opaque)E.splice(Zt,Ye-Zt,yt,"overlay "+qt),Ye=Zt+2;else for(;Zt<Ye;Zt+=2){var Wn=E[Zt+1];E[Zt+1]=(Wn?Wn+" ":"")+"overlay "+qt}},U),b.state=Y,b.baseTokens=null,b.baseTokenPos=1},se=0;se<A.state.overlays.length;++se)J(se);return{styles:E,classes:U.bgClass||U.textClass?U:null}}function Vs(A,h,b){if(!h.styles||h.styles[0]!=A.state.modeGen){var _=va(A,ve(h)),E=h.text.length>A.options.maxHighlightLength&&ba(A.doc.mode,_.state),U=qs(A,h,_);E&&(_.state=E),h.stateAfter=_.save(!E),h.styles=U.styles,U.classes?h.styleClasses=U.classes:h.styleClasses&&(h.styleClasses=null),b===A.doc.highlightFrontier&&(A.doc.modeFrontier=Math.max(A.doc.modeFrontier,++A.doc.highlightFrontier))}return h.styles}function va(A,h,b){var _=A.doc,E=A.display;if(!_.mode.startState)return new ys(_,!0,h);var U=ZA(A,h,b),Y=U>_.first&&rr(_,U-1).stateAfter,J=Y?ys.fromSaved(_,Y,U):new ys(_,Ai(_.mode),U);return _.iter(U,h,function(se){$a(A,se.text,J);var pe=J.line;se.stateAfter=pe==h-1||pe%5==0||pe>=E.viewFrom&&pe<E.viewTo?J.save():null,J.nextLine()}),b&&(_.modeFrontier=J.line),J}function $a(A,h,b,_){var E=A.doc.mode,U=new Mi(h,A.options.tabSize,b);for(U.start=U.pos=_||0,h==""&&ll(E,b.state);!U.eol();)xu(E,U,b.state),U.start=U.pos}function ll(A,h){if(A.blankLine)return A.blankLine(h);if(A.innerMode){var b=Ql(A,h);if(b.mode.blankLine)return b.mode.blankLine(b.state)}}function xu(A,h,b,_){for(var E=0;E<10;E++){_&&(_[0]=Ql(A,b).mode);var U=A.token(h,b);if(h.pos>h.start)return U}throw new Error("Mode "+A.name+" failed to advance stream.")}var bl=function(A,h,b){this.start=A.start,this.end=A.pos,this.string=A.current(),this.type=h||null,this.state=b};function CA(A,h,b,_){var E=A.doc,U=E.mode,Y;h=br(E,h);var J=rr(E,h.line),se=va(A,h.line,b),pe=new Mi(J.text,A.options.tabSize,se),We;for(_&&(We=[]);(_||pe.pos<h.ch)&&!pe.eol();)pe.start=pe.pos,Y=xu(U,pe,se.state),_&&We.push(new bl(pe,Y,ba(E.mode,se.state)));return _?We:new bl(pe,Y,se.state)}function HA(A,h){if(A)for(;;){var b=A.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!b)break;A=A.slice(0,b.index)+A.slice(b.index+b[0].length);var _=b[1]?"bgClass":"textClass";h[_]==null?h[_]=b[2]:new RegExp("(?:^|\\s)"+b[2]+"(?:$|\\s)").test(h[_])||(h[_]+=" "+b[2])}return A}function Hu(A,h,b,_,E,U,Y){var J=b.flattenSpans;J==null&&(J=A.options.flattenSpans);var se=0,pe=null,We=new Mi(h,A.options.tabSize,_),Ye,Mt=A.options.addModeClass&&[null];for(h==""&&HA(ll(b,_.state),U);!We.eol();){if(We.pos>A.options.maxHighlightLength?(J=!1,Y&&$a(A,h,_,We.pos),We.pos=h.length,Ye=null):Ye=HA(xu(b,We,_.state,Mt),U),Mt){var yt=Mt[0].name;yt&&(Ye="m-"+(Ye?yt+" "+Ye:yt))}if(!J||pe!=Ye){for(;se<We.start;)se=Math.min(We.start,se+5e3),E(se,pe);pe=Ye}We.start=We.pos}for(;se<We.pos;){var qt=Math.min(We.pos,se+5e3);E(qt,pe),se=qt}}function ZA(A,h,b){for(var _,E,U=A.doc,Y=b?-1:h-(A.doc.mode.innerMode?1e3:100),J=h;J>Y;--J){if(J<=U.first)return U.first;var se=rr(U,J-1),pe=se.stateAfter;if(pe&&(!b||J+(pe instanceof Qa?pe.lookAhead:0)<=U.modeFrontier))return J;var We=de(se.text,null,A.options.tabSize);(E==null||_>We)&&(E=J-1,_=We)}return E}function _A(A,h){if(A.modeFrontier=Math.min(A.modeFrontier,h),!(A.highlightFrontier<h-10)){for(var b=A.first,_=h-1;_>b;_--){var E=rr(A,_).stateAfter;if(E&&(!(E instanceof Qa)||_+E.lookAhead<h)){b=_+1;break}}A.highlightFrontier=Math.min(A.highlightFrontier,b)}}var Ya=!1,vs=!1;function bA(){Ya=!0}function Zu(){vs=!0}function Ds(A,h,b){this.marker=A,this.from=h,this.to=b}function Us(A,h){if(A)for(var b=0;b<A.length;++b){var _=A[b];if(_.marker==h)return _}}function Cs(A,h){for(var b,_=0;_<A.length;++_)A[_]!=h&&(b||(b=[])).push(A[_]);return b}function lu(A,h,b){var _=b&&window.WeakSet&&(b.markedSpans||(b.markedSpans=new WeakSet));_&&A.markedSpans&&_.has(A.markedSpans)?A.markedSpans.push(h):(A.markedSpans=A.markedSpans?A.markedSpans.concat([h]):[h],_&&_.add(A.markedSpans)),h.marker.attachLine(A)}function wu(A,h,b){var _;if(A)for(var E=0;E<A.length;++E){var U=A[E],Y=U.marker,J=U.from==null||(Y.inclusiveLeft?U.from<=h:U.from<h);if(J||U.from==h&&Y.type=="bookmark"&&(!b||!U.marker.insertLeft)){var se=U.to==null||(Y.inclusiveRight?U.to>=h:U.to>h);(_||(_=[])).push(new Ds(Y,U.from,se?null:U.to))}}return _}function uu(A,h,b){var _;if(A)for(var E=0;E<A.length;++E){var U=A[E],Y=U.marker,J=U.to==null||(Y.inclusiveRight?U.to>=h:U.to>h);if(J||U.from==h&&Y.type=="bookmark"&&(!b||U.marker.insertLeft)){var se=U.from==null||(Y.inclusiveLeft?U.from<=h:U.from<h);(_||(_=[])).push(new Ds(Y,se?null:U.from-h,U.to==null?null:U.to-h))}}return _}function as(A,h){if(h.full)return null;var b=Ht(A,h.from.line)&&rr(A,h.from.line).markedSpans,_=Ht(A,h.to.line)&&rr(A,h.to.line).markedSpans;if(!b&&!_)return null;var E=h.from.ch,U=h.to.ch,Y=En(h.from,h.to)==0,J=wu(b,E,Y),se=uu(_,U,Y),pe=h.text.length==1,We=ir(h.text).length+(pe?E:0);if(J)for(var Ye=0;Ye<J.length;++Ye){var Mt=J[Ye];if(Mt.to==null){var yt=Us(se,Mt.marker);yt?pe&&(Mt.to=yt.to==null?null:yt.to+We):Mt.to=E}}if(se)for(var qt=0;qt<se.length;++qt){var Zt=se[qt];if(Zt.to!=null&&(Zt.to+=We),Zt.from==null){var Bn=Us(J,Zt.marker);Bn||(Zt.from=We,pe&&(J||(J=[])).push(Zt))}else Zt.from+=We,pe&&(J||(J=[])).push(Zt)}J&&(J=Mu(J)),se&&se!=J&&(se=Mu(se));var Wn=[J];if(!pe){var er=h.text.length-2,fn;if(er>0&&J)for(var ar=0;ar<J.length;++ar)J[ar].to==null&&(fn||(fn=[])).push(new Ds(J[ar].marker,null,null));for(var Ir=0;Ir<er;++Ir)Wn.push(fn);Wn.push(se)}return Wn}function Mu(A){for(var h=0;h<A.length;++h){var b=A[h];b.from!=null&&b.from==b.to&&b.marker.clearWhenEmpty!==!1&&A.splice(h--,1)}return A.length?A:null}function Au(A,h,b){var _=null;if(A.iter(h.line,b.line+1,function(yt){if(yt.markedSpans)for(var qt=0;qt<yt.markedSpans.length;++qt){var Zt=yt.markedSpans[qt].marker;Zt.readOnly&&(!_||Pe(_,Zt)==-1)&&(_||(_=[])).push(Zt)}}),!_)return null;for(var E=[{from:h,to:b}],U=0;U<_.length;++U)for(var Y=_[U],J=Y.find(0),se=0;se<E.length;++se){var pe=E[se];if(!(En(pe.to,J.from)<0||En(pe.from,J.to)>0)){var We=[se,1],Ye=En(pe.from,J.from),Mt=En(pe.to,J.to);(Ye<0||!Y.inclusiveLeft&&!Ye)&&We.push({from:pe.from,to:J.from}),(Mt>0||!Y.inclusiveRight&&!Mt)&&We.push({from:J.to,to:pe.to}),E.splice.apply(E,We),se+=We.length-3}}return E}function bo(A){var h=A.markedSpans;if(h){for(var b=0;b<h.length;++b)h[b].marker.detachLine(A);A.markedSpans=null}}function mo(A,h){if(h){for(var b=0;b<h.length;++b)h[b].marker.attachLine(A);A.markedSpans=h}}function ee(A){return A.inclusiveLeft?-1:0}function Ie(A){return A.inclusiveRight?1:0}function st(A,h){var b=A.lines.length-h.lines.length;if(b!=0)return b;var _=A.find(),E=h.find(),U=En(_.from,E.from)||ee(A)-ee(h);if(U)return-U;var Y=En(_.to,E.to)||Ie(A)-Ie(h);return Y||h.id-A.id}function Xt(A,h){var b=vs&&A.markedSpans,_;if(b)for(var E=void 0,U=0;U<b.length;++U)E=b[U],E.marker.collapsed&&(h?E.from:E.to)==null&&(!_||st(_,E.marker)<0)&&(_=E.marker);return _}function Sr(A){return Xt(A,!0)}function _n(A){return Xt(A,!1)}function Si(A,h){var b=vs&&A.markedSpans,_;if(b)for(var E=0;E<b.length;++E){var U=b[E];U.marker.collapsed&&(U.from==null||U.from<h)&&(U.to==null||U.to>h)&&(!_||st(_,U.marker)<0)&&(_=U.marker)}return _}function Ki(A,h,b,_,E){var U=rr(A,h),Y=vs&&U.markedSpans;if(Y)for(var J=0;J<Y.length;++J){var se=Y[J];if(se.marker.collapsed){var pe=se.marker.find(0),We=En(pe.from,b)||ee(se.marker)-ee(E),Ye=En(pe.to,_)||Ie(se.marker)-Ie(E);if(!(We>=0&&Ye<=0||We<=0&&Ye>=0)&&(We<=0&&(se.marker.inclusiveRight&&E.inclusiveLeft?En(pe.to,b)>=0:En(pe.to,b)>0)||We>=0&&(se.marker.inclusiveRight&&E.inclusiveLeft?En(pe.from,_)<=0:En(pe.from,_)<0)))return!0}}}function qr(A){for(var h;h=Sr(A);)A=h.find(-1,!0).line;return A}function Yi(A){for(var h;h=_n(A);)A=h.find(1,!0).line;return A}function qo(A){for(var h,b;h=_n(A);)A=h.find(1,!0).line,(b||(b=[])).push(A);return b}function Ca(A,h){var b=rr(A,h),_=qr(b);return b==_?h:ve(_)}function Vo(A,h){if(h>A.lastLine())return h;var b=rr(A,h),_;if(!Li(A,b))return h;for(;_=_n(b);)b=_.find(1,!0).line;return ve(b)+1}function Li(A,h){var b=vs&&h.markedSpans;if(b){for(var _=void 0,E=0;E<b.length;++E)if(_=b[E],!!_.marker.collapsed){if(_.from==null)return!0;if(!_.marker.widgetNode&&_.from==0&&_.marker.inclusiveLeft&&Xo(A,h,_))return!0}}}function Xo(A,h,b){if(b.to==null){var _=b.marker.find(1,!0);return Xo(A,_.line,Us(_.line.markedSpans,b.marker))}if(b.marker.inclusiveRight&&b.to==h.text.length)return!0;for(var E=void 0,U=0;U<h.markedSpans.length;++U)if(E=h.markedSpans[U],E.marker.collapsed&&!E.marker.widgetNode&&E.from==b.to&&(E.to==null||E.to!=b.from)&&(E.marker.inclusiveLeft||b.marker.inclusiveRight)&&Xo(A,h,E))return!0}function Pa(A){A=qr(A);for(var h=0,b=A.parent,_=0;_<b.lines.length;++_){var E=b.lines[_];if(E==A)break;h+=E.height}for(var U=b.parent;U;b=U,U=b.parent)for(var Y=0;Y<U.children.length;++Y){var J=U.children[Y];if(J==b)break;h+=J.height}return h}function Rs(A){if(A.height==0)return 0;for(var h=A.text.length,b,_=A;b=Sr(_);){var E=b.find(0,!0);_=E.from.line,h+=E.from.ch-E.to.ch}for(_=A;b=_n(_);){var U=b.find(0,!0);h-=_.text.length-U.from.ch,_=U.to.line,h+=_.text.length-U.to.ch}return h}function _s(A){var h=A.display,b=A.doc;h.maxLine=rr(b,b.first),h.maxLineLength=Rs(h.maxLine),h.maxLineChanged=!0,b.iter(function(_){var E=Rs(_);E>h.maxLineLength&&(h.maxLineLength=E,h.maxLine=_)})}var Su=function(A,h,b){this.text=A,mo(this,h),this.height=b?b(this):1};Su.prototype.lineNo=function(){return ve(this)},Ee(Su);function XA(A,h,b,_){A.text=h,A.stateAfter&&(A.stateAfter=null),A.styles&&(A.styles=null),A.order!=null&&(A.order=null),bo(A),mo(A,b);var E=_?_(A):1;E!=A.height&&la(A,E)}function ss(A){A.parent=null,bo(A)}var jm={},$l={};function Bp(A,h){if(!A||/^\s*$/.test(A))return null;var b=h.addModeClass?$l:jm;return b[A]||(b[A]=A.replace(/\S+/g,"cm-$&"))}function Id(A,h){var b=jt("span",null,null,x?"padding-right: .1px":null),_={pre:jt("pre",[b],"CodeMirror-line"),content:b,col:0,pos:0,cm:A,trailingSpace:!1,splitSpaces:A.getOption("lineWrapping")};h.measure={};for(var E=0;E<=(h.rest?h.rest.length:0);E++){var U=E?h.rest[E-1]:h.line,Y=void 0;_.pos=0,_.addToken=Gc,Jn(A.display.measure)&&(Y=on(U,A.doc.direction))&&(_.addToken=Mo(_.addToken,Y)),_.map=[];var J=h!=A.display.externalMeasured&&ve(U);yh(U,_,Vs(A,U,J)),U.styleClasses&&(U.styleClasses.bgClass&&(_.bgClass=nt(U.styleClasses.bgClass,_.bgClass||"")),U.styleClasses.textClass&&(_.textClass=nt(U.styleClasses.textClass,_.textClass||""))),_.map.length==0&&_.map.push(0,0,_.content.appendChild($t(A.display.measure))),E==0?(h.measure.map=_.map,h.measure.cache={}):((h.measure.maps||(h.measure.maps=[])).push(_.map),(h.measure.caches||(h.measure.caches=[])).push({}))}if(x){var se=_.content.lastChild;(/\bcm-tab\b/.test(se.className)||se.querySelector&&se.querySelector(".cm-tab"))&&(_.content.className="cm-tab-wrap-hack")}return Zn(A,"renderLine",A,h.line,_.pre),_.pre.className&&(_.textClass=nt(_.pre.className,_.textClass||"")),_}function cu(A){var h=Ce("span","•","cm-invalidchar");return h.title="\\u"+A.charCodeAt(0).toString(16),h.setAttribute("aria-label",h.title),h}function Gc(A,h,b,_,E,U,Y){if(h){var J=A.splitSpaces?Td(h,A.trailingSpace):h,se=A.cm.state.specialChars,pe=!1,We;if(!se.test(h))A.col+=h.length,We=document.createTextNode(J),A.map.push(A.pos,A.pos+h.length,We),f&&g<9&&(pe=!0),A.pos+=h.length;else{We=document.createDocumentFragment();for(var Ye=0;;){se.lastIndex=Ye;var Mt=se.exec(h),yt=Mt?Mt.index-Ye:h.length-Ye;if(yt){var qt=document.createTextNode(J.slice(Ye,Ye+yt));f&&g<9?We.appendChild(Ce("span",[qt])):We.appendChild(qt),A.map.push(A.pos,A.pos+yt,qt),A.col+=yt,A.pos+=yt}if(!Mt)break;Ye+=yt+1;var Zt=void 0;if(Mt[0]==" "){var Bn=A.cm.options.tabSize,Wn=Bn-A.col%Bn;Zt=We.appendChild(Ce("span",pn(Wn),"cm-tab")),Zt.setAttribute("role","presentation"),Zt.setAttribute("cm-text"," "),A.col+=Wn}else Mt[0]=="\r"||Mt[0]==`
|
||
`?(Zt=We.appendChild(Ce("span",Mt[0]=="\r"?"␍":"","cm-invalidchar")),Zt.setAttribute("cm-text",Mt[0]),A.col+=1):(Zt=A.cm.options.specialCharPlaceholder(Mt[0]),Zt.setAttribute("cm-text",Mt[0]),f&&g<9?We.appendChild(Ce("span",[Zt])):We.appendChild(Zt),A.col+=1);A.map.push(A.pos,A.pos+1,Zt),A.pos++}}if(A.trailingSpace=J.charCodeAt(h.length-1)==32,b||_||E||pe||U||Y){var er=b||"";_&&(er+=_),E&&(er+=E);var fn=Ce("span",[We],er,U);if(Y)for(var ar in Y)Y.hasOwnProperty(ar)&&ar!="style"&&ar!="class"&&fn.setAttribute(ar,Y[ar]);return A.content.appendChild(fn)}A.content.appendChild(We)}}function Td(A,h){if(A.length>1&&!/ /.test(A))return A;for(var b=h,_="",E=0;E<A.length;E++){var U=A.charAt(E);U==" "&&b&&(E==A.length-1||A.charCodeAt(E+1)==32)&&(U=" "),_+=U,b=U==" "}return _}function Mo(A,h){return function(b,_,E,U,Y,J,se){E=E?E+" cm-force-border":"cm-force-border";for(var pe=b.pos,We=pe+_.length;;){for(var Ye=void 0,Mt=0;Mt<h.length&&(Ye=h[Mt],!(Ye.to>pe&&Ye.from<=pe));Mt++);if(Ye.to>=We)return A(b,_,E,U,Y,J,se);A(b,_.slice(0,Ye.to-pe),E,U,null,J,se),U=null,_=_.slice(Ye.to-pe),pe=Ye.to}}}function Eu(A,h,b,_){var E=!_&&b.widgetNode;E&&A.map.push(A.pos,A.pos+h,E),!_&&A.cm.display.input.needsContentAttribute&&(E||(E=A.content.appendChild(document.createElement("span"))),E.setAttribute("cm-marker",b.id)),E&&(A.cm.display.input.setUneditable(E),A.content.appendChild(E)),A.pos+=h,A.trailingSpace=!1}function yh(A,h,b){var _=A.markedSpans,E=A.text,U=0;if(!_){for(var Y=1;Y<b.length;Y+=2)h.addToken(h,E.slice(U,U=b[Y]),Bp(b[Y+1],h.cm.options));return}for(var J=E.length,se=0,pe=1,We="",Ye,Mt,yt=0,qt,Zt,Bn,Wn,er;;){if(yt==se){qt=Zt=Bn=Mt="",er=null,Wn=null,yt=1/0;for(var fn=[],ar=void 0,Ir=0;Ir<_.length;++Ir){var Br=_[Ir],Xr=Br.marker;if(Xr.type=="bookmark"&&Br.from==se&&Xr.widgetNode)fn.push(Xr);else if(Br.from<=se&&(Br.to==null||Br.to>se||Xr.collapsed&&Br.to==se&&Br.from==se)){if(Br.to!=null&&Br.to!=se&&yt>Br.to&&(yt=Br.to,Zt=""),Xr.className&&(qt+=" "+Xr.className),Xr.css&&(Mt=(Mt?Mt+";":"")+Xr.css),Xr.startStyle&&Br.from==se&&(Bn+=" "+Xr.startStyle),Xr.endStyle&&Br.to==yt&&(ar||(ar=[])).push(Xr.endStyle,Br.to),Xr.title&&((er||(er={})).title=Xr.title),Xr.attributes)for(var fo in Xr.attributes)(er||(er={}))[fo]=Xr.attributes[fo];Xr.collapsed&&(!Wn||st(Wn.marker,Xr)<0)&&(Wn=Br)}else Br.from>se&&yt>Br.from&&(yt=Br.from)}if(ar)for(var Ea=0;Ea<ar.length;Ea+=2)ar[Ea+1]==yt&&(Zt+=" "+ar[Ea]);if(!Wn||Wn.from==se)for(var ca=0;ca<fn.length;++ca)Eu(h,0,fn[ca]);if(Wn&&(Wn.from||0)==se){if(Eu(h,(Wn.to==null?J+1:Wn.to)-se,Wn.marker,Wn.from==null),Wn.to==null)return;Wn.to==se&&(Wn=!1)}}if(se>=J)break;for(var Oa=Math.min(J,yt);;){if(We){var Va=se+We.length;if(!Wn){var Ha=Va>Oa?We.slice(0,Oa-se):We;h.addToken(h,Ha,Ye?Ye+qt:qt,Bn,se+Ha.length==yt?Zt:"",Mt,er)}if(Va>=Oa){We=We.slice(Oa-se),se=Oa;break}se=Va,Bn=""}We=E.slice(U,U=b[pe++]),Ye=Bp(b[pe++],h.cm.options)}}}function vh(A,h,b){this.line=h,this.rest=qo(h),this.size=this.rest?ve(ir(this.rest))-b+1:1,this.node=this.text=null,this.hidden=Li(A,h)}function Yl(A,h,b){for(var _=[],E,U=h;U<b;U=E){var Y=new vh(A.doc,rr(A.doc,U),U);E=U+Y.size,_.push(Y)}return _}var JA=null;function Qc(A){JA?JA.ops.push(A):A.ownsGroup=JA={ops:[A],delayedCallbacks:[]}}function $c(A){var h=A.delayedCallbacks,b=0;do{for(;b<h.length;b++)h[b].call(null);for(var _=0;_<A.ops.length;_++){var E=A.ops[_];if(E.cursorActivityHandlers)for(;E.cursorActivityCalled<E.cursorActivityHandlers.length;)E.cursorActivityHandlers[E.cursorActivityCalled++].call(null,E.cm)}}while(b<h.length)}function xf(A,h){var b=A.ownsGroup;if(b)try{$c(b)}finally{JA=null,h(b)}}var ql=null;function Ur(A,h){var b=In(A,h);if(b.length){var _=Array.prototype.slice.call(arguments,2),E;JA?E=JA.delayedCallbacks:ql?E=ql:(E=ql=[],setTimeout(Ch,0));for(var U=function(J){E.push(function(){return b[J].apply(null,_)})},Y=0;Y<b.length;++Y)U(Y)}}function Ch(){var A=ql;ql=null;for(var h=0;h<A.length;++h)A[h]()}function wf(A,h,b,_){for(var E=0;E<h.changes.length;E++){var U=h.changes[E];U=="text"?zi(A,h):U=="gutter"?Lo(A,h,b,_):U=="class"?Yc(A,h):U=="widget"&&So(A,h,_)}h.changes=null}function ec(A){return A.node==A.text&&(A.node=Ce("div",null,null,"position: relative"),A.text.parentNode&&A.text.parentNode.replaceChild(A.node,A.text),A.node.appendChild(A.text),f&&g<8&&(A.node.style.zIndex=2)),A.node}function Ro(A,h){var b=h.bgClass?h.bgClass+" "+(h.line.bgClass||""):h.line.bgClass;if(b&&(b+=" CodeMirror-linebackground"),h.background)b?h.background.className=b:(h.background.parentNode.removeChild(h.background),h.background=null);else if(b){var _=ec(h);h.background=_.insertBefore(Ce("div",null,b),_.firstChild),A.display.input.setUneditable(h.background)}}function _h(A,h){var b=A.display.externalMeasured;return b&&b.line==h.line?(A.display.externalMeasured=null,h.measure=b.measure,b.built):Id(A,h)}function zi(A,h){var b=h.text.className,_=_h(A,h);h.text==h.node&&(h.node=_.pre),h.text.parentNode.replaceChild(_.pre,h.text),h.text=_.pre,_.bgClass!=h.bgClass||_.textClass!=h.textClass?(h.bgClass=_.bgClass,h.textClass=_.textClass,Yc(A,h)):b&&(h.text.className=b)}function Yc(A,h){Ro(A,h),h.line.wrapClass?ec(h).className=h.line.wrapClass:h.node!=h.text&&(h.node.className="");var b=h.textClass?h.textClass+" "+(h.line.textClass||""):h.line.textClass;h.text.className=b||""}function Lo(A,h,b,_){if(h.gutter&&(h.node.removeChild(h.gutter),h.gutter=null),h.gutterBackground&&(h.node.removeChild(h.gutterBackground),h.gutterBackground=null),h.line.gutterClass){var E=ec(h);h.gutterBackground=Ce("div",null,"CodeMirror-gutter-background "+h.line.gutterClass,"left: "+(A.options.fixedGutter?_.fixedPos:-_.gutterTotalWidth)+"px; width: "+_.gutterTotalWidth+"px"),A.display.input.setUneditable(h.gutterBackground),E.insertBefore(h.gutterBackground,h.text)}var U=h.line.gutterMarkers;if(A.options.lineNumbers||U){var Y=ec(h),J=h.gutter=Ce("div",null,"CodeMirror-gutter-wrapper","left: "+(A.options.fixedGutter?_.fixedPos:-_.gutterTotalWidth)+"px");if(J.setAttribute("aria-hidden","true"),A.display.input.setUneditable(J),Y.insertBefore(J,h.text),h.line.gutterClass&&(J.className+=" "+h.line.gutterClass),A.options.lineNumbers&&(!U||!U["CodeMirror-linenumbers"])&&(h.lineNumber=J.appendChild(Ce("div",mn(A.options,b),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+_.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+A.display.lineNumInnerWidth+"px"))),U)for(var se=0;se<A.display.gutterSpecs.length;++se){var pe=A.display.gutterSpecs[se].className,We=U.hasOwnProperty(pe)&&U[pe];We&&J.appendChild(Ce("div",[We],"CodeMirror-gutter-elt","left: "+_.gutterLeft[pe]+"px; width: "+_.gutterWidth[pe]+"px"))}}}function So(A,h,b){h.alignable&&(h.alignable=null);for(var _=rt("CodeMirror-linewidget"),E=h.node.firstChild,U=void 0;E;E=U)U=E.nextSibling,_.test(E.className)&&h.node.removeChild(E);nc(A,h,b)}function tc(A,h,b,_){var E=_h(A,h);return h.text=h.node=E.pre,E.bgClass&&(h.bgClass=E.bgClass),E.textClass&&(h.textClass=E.textClass),Yc(A,h),Lo(A,h,b,_),nc(A,h,_),h.node}function nc(A,h,b){if(Ls(A,h.line,h,b,!0),h.rest)for(var _=0;_<h.rest.length;_++)Ls(A,h.rest[_],h,b,!1)}function Ls(A,h,b,_,E){if(h.widgets)for(var U=ec(b),Y=0,J=h.widgets;Y<J.length;++Y){var se=J[Y],pe=Ce("div",[se.node],"CodeMirror-linewidget"+(se.className?" "+se.className:""));se.handleMouseEvents||pe.setAttribute("cm-ignore-events","true"),Kd(se,pe,b,_),A.display.input.setUneditable(pe),E&&se.above?U.insertBefore(pe,b.gutter||b.text):U.appendChild(pe),Ur(se,"redraw")}}function Kd(A,h,b,_){if(A.noHScroll){(b.alignable||(b.alignable=[])).push(h);var E=_.wrapperWidth;h.style.left=_.fixedPos+"px",A.coverGutter||(E-=_.gutterTotalWidth,h.style.paddingLeft=_.gutterTotalWidth+"px"),h.style.width=E+"px"}A.coverGutter&&(h.style.zIndex=5,h.style.position="relative",A.noHScroll||(h.style.marginLeft=-_.gutterTotalWidth+"px"))}function Ou(A){if(A.height!=null)return A.height;var h=A.doc.cm;if(!h)return 0;if(!Jt(document.body,A.node)){var b="position: relative;";A.coverGutter&&(b+="margin-left: -"+h.display.gutters.offsetWidth+"px;"),A.noHScroll&&(b+="width: "+h.display.wrapper.clientWidth+"px;"),He(h.display.measure,Ce("div",[A.node],null,b))}return A.height=A.node.parentNode.offsetHeight}function xl(A,h){for(var b=et(h);b!=A.wrapper;b=b.parentNode)if(!b||b.nodeType==1&&b.getAttribute("cm-ignore-events")=="true"||b.parentNode==A.sizer&&b!=A.mover)return!0}function Xu(A){return A.lineSpace.offsetTop}function qc(A){return A.mover.offsetHeight-A.lineSpace.offsetHeight}function Mf(A){if(A.cachedPaddingH)return A.cachedPaddingH;var h=He(A.measure,Ce("pre","x","CodeMirror-line-like")),b=window.getComputedStyle?window.getComputedStyle(h):h.currentStyle,_={left:parseInt(b.paddingLeft),right:parseInt(b.paddingRight)};return!isNaN(_.left)&&!isNaN(_.right)&&(A.cachedPaddingH=_),_}function wl(A){return Ze-A.display.nativeBarWidth}function Ju(A){return A.display.scroller.clientWidth-wl(A)-A.display.barWidth}function bh(A){return A.display.scroller.clientHeight-wl(A)-A.display.barHeight}function eA(A,h,b){var _=A.options.lineWrapping,E=_&&Ju(A);if(!h.measure.heights||_&&h.measure.width!=E){var U=h.measure.heights=[];if(_){h.measure.width=E;for(var Y=h.text.firstChild.getClientRects(),J=0;J<Y.length-1;J++){var se=Y[J],pe=Y[J+1];Math.abs(se.bottom-pe.bottom)>2&&U.push((se.bottom+pe.top)/2-b.top)}}U.push(b.bottom-b.top)}}function xh(A,h,b){if(A.line==h)return{map:A.measure.map,cache:A.measure.cache};if(A.rest){for(var _=0;_<A.rest.length;_++)if(A.rest[_]==h)return{map:A.measure.maps[_],cache:A.measure.caches[_]};for(var E=0;E<A.rest.length;E++)if(ve(A.rest[E])>b)return{map:A.measure.maps[E],cache:A.measure.caches[E],before:!0}}}function kp(A,h){h=qr(h);var b=ve(h),_=A.display.externalMeasured=new vh(A.doc,h,b);_.lineN=b;var E=_.built=Id(A,_);return _.text=E.pre,He(A.display.lineMeasure,E.pre),_}function Pd(A,h,b,_){return Ml(A,Hs(A,h),b,_)}function rc(A,h){if(h>=A.display.viewFrom&&h<A.display.viewTo)return A.display.view[ic(A,h)];var b=A.display.externalMeasured;if(b&&h>=b.lineN&&h<b.lineN+b.size)return b}function Hs(A,h){var b=ve(h),_=rc(A,b);_&&!_.text?_=null:_&&_.changes&&(wf(A,_,b,nA(A)),A.curOp.forceUpdate=!0),_||(_=kp(A,h));var E=xh(_,h,b);return{line:h,view:_,rect:null,map:E.map,cache:E.cache,before:E.before,hasHeights:!1}}function Ml(A,h,b,_,E){h.before&&(b=-1);var U=b+(_||""),Y;return h.cache.hasOwnProperty(U)?Y=h.cache[U]:(h.rect||(h.rect=h.view.text.getBoundingClientRect()),h.hasHeights||(eA(A,h.view,h.rect),h.hasHeights=!0),Y=bs(A,h,b,_),Y.bogus||(h.cache[U]=Y)),{left:Y.left,right:Y.right,top:E?Y.rtop:Y.top,bottom:E?Y.rbottom:Y.bottom}}var wh={left:0,right:0,top:0,bottom:0};function ra(A,h,b){for(var _,E,U,Y,J,se,pe=0;pe<A.length;pe+=3)if(J=A[pe],se=A[pe+1],h<J?(E=0,U=1,Y="left"):h<se?(E=h-J,U=E+1):(pe==A.length-3||h==se&&A[pe+3]>h)&&(U=se-J,E=U-1,h>=se&&(Y="right")),E!=null){if(_=A[pe+2],J==se&&b==(_.insertLeft?"left":"right")&&(Y=b),b=="left"&&E==0)for(;pe&&A[pe-2]==A[pe-3]&&A[pe-1].insertLeft;)_=A[(pe-=3)+2],Y="left";if(b=="right"&&E==se-J)for(;pe<A.length-3&&A[pe+3]==A[pe+4]&&!A[pe+5].insertLeft;)_=A[(pe+=3)+2],Y="right";break}return{node:_,start:E,end:U,collapse:Y,coverStart:J,coverEnd:se}}function Bu(A,h){var b=wh;if(h=="left")for(var _=0;_<A.length&&(b=A[_]).left==b.right;_++);else for(var E=A.length-1;E>=0&&(b=A[E]).left==b.right;E--);return b}function bs(A,h,b,_){var E=ra(h.map,b,_),U=E.node,Y=E.start,J=E.end,se=E.collapse,pe;if(U.nodeType==3){for(var We=0;We<4;We++){for(;Y&&me(h.line.text.charAt(E.coverStart+Y));)--Y;for(;E.coverStart+J<E.coverEnd&&me(h.line.text.charAt(E.coverStart+J));)++J;if(f&&g<9&&Y==0&&J==E.coverEnd-E.coverStart?pe=U.parentNode.getBoundingClientRect():pe=Bu(Ft(U,Y,J).getClientRects(),_),pe.left||pe.right||Y==0)break;J=Y,Y=Y-1,se="right"}f&&g<11&&(pe=ul(A.display.measure,pe))}else{Y>0&&(se=_="right");var Ye;A.options.lineWrapping&&(Ye=U.getClientRects()).length>1?pe=Ye[_=="right"?Ye.length-1:0]:pe=U.getBoundingClientRect()}if(f&&g<9&&!Y&&(!pe||!pe.left&&!pe.right)){var Mt=U.parentNode.getClientRects()[0];Mt?pe={left:Mt.left,right:Mt.left+ls(A.display),top:Mt.top,bottom:Mt.bottom}:pe=wh}for(var yt=pe.top-h.rect.top,qt=pe.bottom-h.rect.top,Zt=(yt+qt)/2,Bn=h.view.measure.heights,Wn=0;Wn<Bn.length-1&&!(Zt<Bn[Wn]);Wn++);var er=Wn?Bn[Wn-1]:0,fn=Bn[Wn],ar={left:(se=="right"?pe.right:pe.left)-h.rect.left,right:(se=="left"?pe.left:pe.right)-h.rect.left,top:er,bottom:fn};return!pe.left&&!pe.right&&(ar.bogus=!0),A.options.singleCursorHeightPerLine||(ar.rtop=yt,ar.rbottom=qt),ar}function ul(A,h){if(!window.screen||screen.logicalXDPI==null||screen.logicalXDPI==screen.deviceXDPI||!Yr(A))return h;var b=screen.logicalXDPI/screen.deviceXDPI,_=screen.logicalYDPI/screen.deviceYDPI;return{left:h.left*b,right:h.right*b,top:h.top*_,bottom:h.bottom*_}}function Fd(A){if(A.measure&&(A.measure.cache={},A.measure.heights=null,A.rest))for(var h=0;h<A.rest.length;h++)A.measure.caches[h]={}}function Dd(A){A.display.externalMeasure=null,Fe(A.display.lineMeasure);for(var h=0;h<A.display.view.length;h++)Fd(A.display.view[h])}function Sl(A){Dd(A),A.display.cachedCharWidth=A.display.cachedTextHeight=A.display.cachedPaddingH=null,A.options.lineWrapping||(A.display.maxLineChanged=!0),A.display.lineNumChars=null}function xA(A){return B&&oe?-(A.body.getBoundingClientRect().left-parseInt(getComputedStyle(A.body).marginLeft)):A.defaultView.pageXOffset||(A.documentElement||A.body).scrollLeft}function Vc(A){return B&&oe?-(A.body.getBoundingClientRect().top-parseInt(getComputedStyle(A.body).marginTop)):A.defaultView.pageYOffset||(A.documentElement||A.body).scrollTop}function Ud(A){var h=qr(A),b=h.widgets,_=0;if(b)for(var E=0;E<b.length;++E)b[E].above&&(_+=Ou(b[E]));return _}function ku(A,h,b,_,E){if(!E){var U=Ud(h);b.top+=U,b.bottom+=U}if(_=="line")return b;_||(_="local");var Y=Pa(h);if(_=="local"?Y+=Xu(A.display):Y-=A.display.viewOffset,_=="page"||_=="window"){var J=A.display.lineSpace.getBoundingClientRect();Y+=J.top+(_=="window"?0:Vc(Vt(A)));var se=J.left+(_=="window"?0:xA(Vt(A)));b.left+=se,b.right+=se}return b.top+=Y,b.bottom+=Y,b}function xt(A,h,b){if(b=="div")return h;var _=h.left,E=h.top;if(b=="page")_-=xA(Vt(A)),E-=Vc(Vt(A));else if(b=="local"||!b){var U=A.display.sizer.getBoundingClientRect();_+=U.left,E+=U.top}var Y=A.display.lineSpace.getBoundingClientRect();return{left:_-Y.left,top:E-Y.top}}function sn(A,h,b,_,E){return _||(_=rr(A.doc,h.line)),ku(A,_,Pd(A,_,h.ch,E),b)}function Wt(A,h,b,_,E,U){_=_||rr(A.doc,h.line),E||(E=Hs(A,_));function Y(qt,Zt){var Bn=Ml(A,E,qt,Zt?"right":"left",U);return Zt?Bn.left=Bn.right:Bn.right=Bn.left,ku(A,_,Bn,b)}var J=on(_,A.doc.direction),se=h.ch,pe=h.sticky;if(se>=_.text.length?(se=_.text.length,pe="before"):se<=0&&(se=0,pe="after"),!J)return Y(pe=="before"?se-1:se,pe=="before");function We(qt,Zt,Bn){var Wn=J[Zt],er=Wn.level==1;return Y(Bn?qt-1:qt,er!=Bn)}var Ye=Lt(J,se,pe),Mt=sr,yt=We(se,Ye,pe=="before");return Mt!=null&&(yt.other=We(se,Mt,pe!="before")),yt}function or(A,h){var b=0;h=br(A.doc,h),A.options.lineWrapping||(b=ls(A.display)*h.ch);var _=rr(A.doc,h.line),E=Pa(_)+Xu(A.display);return{left:b,right:b,top:E,bottom:E+_.height}}function ri(A,h,b,_,E){var U=Ot(A,h,b);return U.xRel=E,_&&(U.outside=_),U}function to(A,h,b){var _=A.doc;if(b+=A.display.viewOffset,b<0)return ri(_.first,0,null,-1,-1);var E=Ge(_,b),U=_.first+_.size-1;if(E>U)return ri(_.first+_.size-1,rr(_,U).text.length,null,1,1);h<0&&(h=0);for(var Y=rr(_,E);;){var J=Rd(A,Y,E,h,b),se=Si(Y,J.ch+(J.xRel>0||J.outside>0?1:0));if(!se)return J;var pe=se.find(1);if(pe.line==E)return pe;Y=rr(_,E=pe.line)}}function ia(A,h,b,_){_-=Ud(h);var E=h.text.length,U=bt(function(Y){return Ml(A,b,Y-1).bottom<=_},E,0);return E=bt(function(Y){return Ml(A,b,Y).top>_},U,E),{begin:U,end:E}}function ho(A,h,b,_){b||(b=Hs(A,h));var E=ku(A,h,Ml(A,b,_),"line").top;return ia(A,h,b,E)}function xs(A,h,b,_){return A.bottom<=b?!1:A.top>b?!0:(_?A.left:A.right)>h}function Rd(A,h,b,_,E){E-=Pa(h);var U=Hs(A,h),Y=Ud(h),J=0,se=h.text.length,pe=!0,We=on(h,A.doc.direction);if(We){var Ye=(A.options.lineWrapping?tA:El)(A,h,b,U,We,_,E);pe=Ye.level!=1,J=pe?Ye.from:Ye.to-1,se=pe?Ye.to:Ye.from-1}var Mt=null,yt=null,qt=bt(function(Ir){var Br=Ml(A,U,Ir);return Br.top+=Y,Br.bottom+=Y,xs(Br,_,E,!1)?(Br.top<=E&&Br.left<=_&&(Mt=Ir,yt=Br),!0):!1},J,se),Zt,Bn,Wn=!1;if(yt){var er=_-yt.left<yt.right-_,fn=er==pe;qt=Mt+(fn?0:1),Bn=fn?"after":"before",Zt=er?yt.left:yt.right}else{!pe&&(qt==se||qt==J)&&qt++,Bn=qt==0?"after":qt==h.text.length?"before":Ml(A,U,qt-(pe?1:0)).bottom+Y<=E==pe?"after":"before";var ar=Wt(A,Ot(b,qt,Bn),"line",h,U);Zt=ar.left,Wn=E<ar.top?-1:E>=ar.bottom?1:0}return qt=At(h.text,qt,1),ri(b,qt,Bn,Wn,_-Zt)}function El(A,h,b,_,E,U,Y){var J=bt(function(Ye){var Mt=E[Ye],yt=Mt.level!=1;return xs(Wt(A,Ot(b,yt?Mt.to:Mt.from,yt?"before":"after"),"line",h,_),U,Y,!0)},0,E.length-1),se=E[J];if(J>0){var pe=se.level!=1,We=Wt(A,Ot(b,pe?se.from:se.to,pe?"after":"before"),"line",h,_);xs(We,U,Y,!0)&&We.top>Y&&(se=E[J-1])}return se}function tA(A,h,b,_,E,U,Y){var J=ia(A,h,_,Y),se=J.begin,pe=J.end;/\s/.test(h.text.charAt(pe-1))&&pe--;for(var We=null,Ye=null,Mt=0;Mt<E.length;Mt++){var yt=E[Mt];if(!(yt.from>=pe||yt.to<=se)){var qt=yt.level!=1,Zt=Ml(A,_,qt?Math.min(pe,yt.to)-1:Math.max(se,yt.from)).right,Bn=Zt<U?U-Zt+1e9:Zt-U;(!We||Ye>Bn)&&(We=yt,Ye=Bn)}}return We||(We=E[E.length-1]),We.from<se&&(We={from:se,to:We.to,level:We.level}),We.to>pe&&(We={from:We.from,to:pe,level:We.level}),We}var wA;function Jo(A){if(A.cachedTextHeight!=null)return A.cachedTextHeight;if(wA==null){wA=Ce("pre",null,"CodeMirror-line-like");for(var h=0;h<49;++h)wA.appendChild(document.createTextNode("x")),wA.appendChild(Ce("br"));wA.appendChild(document.createTextNode("x"))}He(A.measure,wA);var b=wA.offsetHeight/50;return b>3&&(A.cachedTextHeight=b),Fe(A.measure),b||1}function ls(A){if(A.cachedCharWidth!=null)return A.cachedCharWidth;var h=Ce("span","xxxxxxxxxx"),b=Ce("pre",[h],"CodeMirror-line-like");He(A.measure,b);var _=h.getBoundingClientRect(),E=(_.right-_.left)/10;return E>2&&(A.cachedCharWidth=E),E||10}function nA(A){for(var h=A.display,b={},_={},E=h.gutters.clientLeft,U=h.gutters.firstChild,Y=0;U;U=U.nextSibling,++Y){var J=A.display.gutterSpecs[Y].className;b[J]=U.offsetLeft+U.clientLeft+E,_[J]=U.clientWidth}return{fixedPos:Ei(h),gutterTotalWidth:h.gutters.offsetWidth,gutterLeft:b,gutterWidth:_,wrapperWidth:h.wrapper.clientWidth}}function Ei(A){return A.scroller.getBoundingClientRect().left-A.sizer.getBoundingClientRect().left}function MA(A){var h=Jo(A.display),b=A.options.lineWrapping,_=b&&Math.max(5,A.display.scroller.clientWidth/ls(A.display)-3);return function(E){if(Li(A.doc,E))return 0;var U=0;if(E.widgets)for(var Y=0;Y<E.widgets.length;Y++)E.widgets[Y].height&&(U+=E.widgets[Y].height);return b?U+(Math.ceil(E.text.length/_)||1)*h:U+h}}function Mh(A){var h=A.doc,b=MA(A);h.iter(function(_){var E=b(_);E!=_.height&&la(_,E)})}function Al(A,h,b,_){var E=A.display;if(!b&&et(h).getAttribute("cm-not-content")=="true")return null;var U,Y,J=E.lineSpace.getBoundingClientRect();try{U=h.clientX-J.left,Y=h.clientY-J.top}catch{return null}var se=to(A,U,Y),pe;if(_&&se.xRel>0&&(pe=rr(A.doc,se.line).text).length==se.ch){var We=de(pe,pe.length,A.options.tabSize)-pe.length;se=Ot(se.line,Math.max(0,Math.round((U-Mf(A.display).left)/ls(A.display))-We))}return se}function ic(A,h){if(h>=A.display.viewTo||(h-=A.display.viewFrom,h<0))return null;for(var b=A.display.view,_=0;_<b.length;_++)if(h-=b[_].size,h<0)return _}function us(A,h,b,_){h==null&&(h=A.doc.first),b==null&&(b=A.doc.first+A.doc.size),_||(_=0);var E=A.display;if(_&&b<E.viewTo&&(E.updateLineNumbers==null||E.updateLineNumbers>h)&&(E.updateLineNumbers=h),A.curOp.viewChanged=!0,h>=E.viewTo)vs&&Ca(A.doc,h)<E.viewTo&&Fa(A);else if(b<=E.viewFrom)vs&&Vo(A.doc,b+_)>E.viewFrom?Fa(A):(E.viewFrom+=_,E.viewTo+=_);else if(h<=E.viewFrom&&b>=E.viewTo)Fa(A);else if(h<=E.viewFrom){var U=jn(A,b,b+_,1);U?(E.view=E.view.slice(U.index),E.viewFrom=U.lineN,E.viewTo+=_):Fa(A)}else if(b>=E.viewTo){var Y=jn(A,h,h,-1);Y?(E.view=E.view.slice(0,Y.index),E.viewTo=Y.lineN):Fa(A)}else{var J=jn(A,h,h,-1),se=jn(A,b,b+_,1);J&&se?(E.view=E.view.slice(0,J.index).concat(Yl(A,J.lineN,se.lineN)).concat(E.view.slice(se.index)),E.viewTo+=_):Fa(A)}var pe=E.externalMeasured;pe&&(b<pe.lineN?pe.lineN+=_:h<pe.lineN+pe.size&&(E.externalMeasured=null))}function Ol(A,h,b){A.curOp.viewChanged=!0;var _=A.display,E=A.display.externalMeasured;if(E&&h>=E.lineN&&h<E.lineN+E.size&&(_.externalMeasured=null),!(h<_.viewFrom||h>=_.viewTo)){var U=_.view[ic(A,h)];if(U.node!=null){var Y=U.changes||(U.changes=[]);Pe(Y,b)==-1&&Y.push(b)}}}function Fa(A){A.display.viewFrom=A.display.viewTo=A.doc.first,A.display.view=[],A.display.viewOffset=0}function jn(A,h,b,_){var E=ic(A,h),U,Y=A.display.view;if(!vs||b==A.doc.first+A.doc.size)return{index:E,lineN:b};for(var J=A.display.viewFrom,se=0;se<E;se++)J+=Y[se].size;if(J!=h){if(_>0){if(E==Y.length-1)return null;U=J+Y[E].size-h,E++}else U=J-h;h+=U,b+=U}for(;Ca(A.doc,b)!=b;){if(E==(_<0?0:Y.length-1))return null;b+=_*Y[E-(_<0?1:0)].size,E+=_}return{index:E,lineN:b}}function Hc(A,h,b){var _=A.display,E=_.view;E.length==0||h>=_.viewTo||b<=_.viewFrom?(_.view=Yl(A,h,b),_.viewFrom=h):(_.viewFrom>h?_.view=Yl(A,h,_.viewFrom).concat(_.view):_.viewFrom<h&&(_.view=_.view.slice(ic(A,h))),_.viewFrom=h,_.viewTo<b?_.view=_.view.concat(Yl(A,_.viewTo,b)):_.viewTo>b&&(_.view=_.view.slice(0,ic(A,b)))),_.viewTo=b}function oc(A){for(var h=A.display.view,b=0,_=0;_<h.length;_++){var E=h[_];!E.hidden&&(!E.node||E.changes)&&++b}return b}function cl(A){A.display.input.showSelection(A.display.input.prepareSelection())}function ac(A,h){h===void 0&&(h=!0);var b=A.doc,_={},E=_.cursors=document.createDocumentFragment(),U=_.selection=document.createDocumentFragment(),Y=A.options.$customCursor;Y&&(h=!0);for(var J=0;J<b.sel.ranges.length;J++)if(!(!h&&J==b.sel.primIndex)){var se=b.sel.ranges[J];if(!(se.from().line>=A.display.viewTo||se.to().line<A.display.viewFrom)){var pe=se.empty();if(Y){var We=Y(A,se);We&&Nn(A,We,E)}else(pe||A.options.showCursorWhenSelecting)&&Nn(A,se.head,E);pe||Sf(A,se,U)}}return _}function Nn(A,h,b){var _=Wt(A,h,"div",null,null,!A.options.singleCursorHeightPerLine),E=b.appendChild(Ce("div"," ","CodeMirror-cursor"));if(E.style.left=_.left+"px",E.style.top=_.top+"px",E.style.height=Math.max(0,_.bottom-_.top)*A.options.cursorHeight+"px",/\bcm-fat-cursor\b/.test(A.getWrapperElement().className)){var U=sn(A,h,"div",null,null),Y=U.right-U.left;E.style.width=(Y>0?Y:A.defaultCharWidth())+"px"}if(_.other){var J=b.appendChild(Ce("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));J.style.display="",J.style.left=_.other.left+"px",J.style.top=_.other.top+"px",J.style.height=(_.other.bottom-_.other.top)*.85+"px"}}function rA(A,h){return A.top-h.top||A.left-h.left}function Sf(A,h,b){var _=A.display,E=A.doc,U=document.createDocumentFragment(),Y=Mf(A.display),J=Y.left,se=Math.max(_.sizerWidth,Ju(A)-_.sizer.offsetLeft)-Y.right,pe=E.direction=="ltr";function We(fn,ar,Ir,Br){ar<0&&(ar=0),ar=Math.round(ar),Br=Math.round(Br),U.appendChild(Ce("div",null,"CodeMirror-selected","position: absolute; left: "+fn+`px;
|
||
top: `+ar+"px; width: "+(Ir??se-fn)+`px;
|
||
height: `+(Br-ar)+"px"))}function Ye(fn,ar,Ir){var Br=rr(E,fn),Xr=Br.text.length,fo,Ea;function ca(Ha,fl){return sn(A,Ot(fn,Ha),"div",Br,fl)}function Oa(Ha,fl,zs){var ds=ho(A,Br,null,Ha),Za=fl=="ltr"==(zs=="after")?"left":"right",Ba=zs=="after"?ds.begin:ds.end-(/\s/.test(Br.text.charAt(ds.end-1))?2:1);return ca(Ba,Za)[Za]}var Va=on(Br,E.direction);return Et(Va,ar||0,Ir??Xr,function(Ha,fl,zs,ds){var Za=zs=="ltr",Ba=ca(Ha,Za?"left":"right"),js=ca(fl-1,Za?"right":"left"),sA=ar==null&&Ha==0,bc=Ir==null&&fl==Xr,Os=ds==0,Ru=!Va||ds==Va.length-1;if(js.top-Ba.top<=3){var Bs=(pe?sA:bc)&&Os,o0=(pe?bc:sA)&&Ru,UA=Bs?J:(Za?Ba:js).left,xc=o0?se:(Za?js:Ba).right;We(UA,Ba.top,xc-UA,Ba.bottom)}else{var wc,To,cd,Lp;Za?(wc=pe&&sA&&Os?J:Ba.left,To=pe?se:Oa(Ha,zs,"before"),cd=pe?J:Oa(fl,zs,"after"),Lp=pe&&bc&&Ru?se:js.right):(wc=pe?Oa(Ha,zs,"before"):J,To=!pe&&sA&&Os?se:Ba.right,cd=!pe&&bc&&Ru?J:js.left,Lp=pe?Oa(fl,zs,"after"):se),We(wc,Ba.top,To-wc,Ba.bottom),Ba.bottom<js.top&&We(J,Ba.bottom,null,js.top),We(cd,js.top,Lp-cd,js.bottom)}(!fo||rA(Ba,fo)<0)&&(fo=Ba),rA(js,fo)<0&&(fo=js),(!Ea||rA(Ba,Ea)<0)&&(Ea=Ba),rA(js,Ea)<0&&(Ea=js)}),{start:fo,end:Ea}}var Mt=h.from(),yt=h.to();if(Mt.line==yt.line)Ye(Mt.line,Mt.ch,yt.ch);else{var qt=rr(E,Mt.line),Zt=rr(E,yt.line),Bn=qr(qt)==qr(Zt),Wn=Ye(Mt.line,Mt.ch,Bn?qt.text.length+1:null).end,er=Ye(yt.line,Bn?0:null,yt.ch).start;Bn&&(Wn.top<er.top-2?(We(Wn.right,Wn.top,null,Wn.bottom),We(J,er.top,er.left,er.bottom)):We(Wn.right,Wn.top,er.left-Wn.right,Wn.bottom)),Wn.bottom<er.top&&We(J,Wn.bottom,null,er.top)}b.appendChild(U)}function sc(A){if(A.state.focused){var h=A.display;clearInterval(h.blinker);var b=!0;h.cursorDiv.style.visibility="",A.options.cursorBlinkRate>0?h.blinker=setInterval(function(){A.hasFocus()||Zc(A),h.cursorDiv.style.visibility=(b=!b)?"":"hidden"},A.options.cursorBlinkRate):A.options.cursorBlinkRate<0&&(h.cursorDiv.style.visibility="hidden")}}function Vl(A){A.hasFocus()||(A.display.input.focus(),A.state.focused||Sh(A))}function lc(A){A.state.delayingBlurEvent=!0,setTimeout(function(){A.state.delayingBlurEvent&&(A.state.delayingBlurEvent=!1,A.state.focused&&Zc(A))},100)}function Sh(A,h){A.state.delayingBlurEvent&&!A.state.draggingText&&(A.state.delayingBlurEvent=!1),A.options.readOnly!="nocursor"&&(A.state.focused||(Zn(A,"focus",A,h),A.state.focused=!0,Ve(A.display.wrapper,"CodeMirror-focused"),!A.curOp&&A.display.selForContextMenu!=A.doc.sel&&(A.display.input.reset(),x&&setTimeout(function(){return A.display.input.reset(!0)},20)),A.display.input.receivedFocus()),sc(A))}function Zc(A,h){A.state.delayingBlurEvent||(A.state.focused&&(Zn(A,"blur",A,h),A.state.focused=!1,ct(A.display.wrapper,"CodeMirror-focused")),clearInterval(A.display.blinker),setTimeout(function(){A.state.focused||(A.display.shift=!1)},150))}function Eh(A){for(var h=A.display,b=h.lineDiv.offsetTop,_=Math.max(0,h.scroller.getBoundingClientRect().top),E=h.lineDiv.getBoundingClientRect().top,U=0,Y=0;Y<h.view.length;Y++){var J=h.view[Y],se=A.options.lineWrapping,pe=void 0,We=0;if(!J.hidden){if(E+=J.line.height,f&&g<8){var Ye=J.node.offsetTop+J.node.offsetHeight;pe=Ye-b,b=Ye}else{var Mt=J.node.getBoundingClientRect();pe=Mt.bottom-Mt.top,!se&&J.text.firstChild&&(We=J.text.firstChild.getBoundingClientRect().right-Mt.left-1)}var yt=J.line.height-pe;if((yt>.005||yt<-.005)&&(E<_&&(U-=yt),la(J.line,pe),Hl(J.line),J.rest))for(var qt=0;qt<J.rest.length;qt++)Hl(J.rest[qt]);if(We>A.display.sizerWidth){var Zt=Math.ceil(We/ls(A.display));Zt>A.display.maxLineLength&&(A.display.maxLineLength=Zt,A.display.maxLine=J.line,A.display.maxLineChanged=!0)}}}Math.abs(U)>2&&(h.scroller.scrollTop+=U)}function Hl(A){if(A.widgets)for(var h=0;h<A.widgets.length;++h){var b=A.widgets[h],_=b.node.parentNode;_&&(b.height=_.offsetHeight)}}function go(A,h,b){var _=b&&b.top!=null?Math.max(0,b.top):A.scroller.scrollTop;_=Math.floor(_-Xu(A));var E=b&&b.bottom!=null?b.bottom:_+A.wrapper.clientHeight,U=Ge(h,_),Y=Ge(h,E);if(b&&b.ensure){var J=b.ensure.from.line,se=b.ensure.to.line;J<U?(U=J,Y=Ge(h,Pa(rr(h,J))+A.wrapper.clientHeight)):Math.min(se,h.lastLine())>=Y&&(U=Ge(h,Pa(rr(h,se))-A.wrapper.clientHeight),Y=se)}return{from:U,to:Math.max(Y,U+1)}}function Xc(A,h){if(!Ke(A,"scrollCursorIntoView")){var b=A.display,_=b.sizer.getBoundingClientRect(),E=null,U=b.wrapper.ownerDocument;if(h.top+_.top<0?E=!0:h.bottom+_.top>(U.defaultView.innerHeight||U.documentElement.clientHeight)&&(E=!1),E!=null&&!$){var Y=Ce("div","",null,`position: absolute;
|
||
top: `+(h.top-b.viewOffset-Xu(A.display))+`px;
|
||
height: `+(h.bottom-h.top+wl(A)+b.barHeight)+`px;
|
||
left: `+h.left+"px; width: "+Math.max(2,h.right-h.left)+"px;");A.display.lineSpace.appendChild(Y),Y.scrollIntoView(E),A.display.lineSpace.removeChild(Y)}}}function Ef(A,h,b,_){_==null&&(_=0);var E;!A.options.lineWrapping&&h==b&&(b=h.sticky=="before"?Ot(h.line,h.ch+1,"before"):h,h=h.ch?Ot(h.line,h.sticky=="before"?h.ch-1:h.ch,"after"):h);for(var U=0;U<5;U++){var Y=!1,J=Wt(A,h),se=!b||b==h?J:Wt(A,b);E={left:Math.min(J.left,se.left),top:Math.min(J.top,se.top)-_,right:Math.max(J.left,se.left),bottom:Math.max(J.bottom,se.bottom)+_};var pe=Oh(A,E),We=A.doc.scrollTop,Ye=A.doc.scrollLeft;if(pe.scrollTop!=null&&(SA(A,pe.scrollTop),Math.abs(A.doc.scrollTop-We)>1&&(Y=!0)),pe.scrollLeft!=null&&(dl(A,pe.scrollLeft),Math.abs(A.doc.scrollLeft-Ye)>1&&(Y=!0)),!Y)break}return E}function Of(A,h){var b=Oh(A,h);b.scrollTop!=null&&SA(A,b.scrollTop),b.scrollLeft!=null&&dl(A,b.scrollLeft)}function Oh(A,h){var b=A.display,_=Jo(A.display);h.top<0&&(h.top=0);var E=A.curOp&&A.curOp.scrollTop!=null?A.curOp.scrollTop:b.scroller.scrollTop,U=bh(A),Y={};h.bottom-h.top>U&&(h.bottom=h.top+U);var J=A.doc.height+qc(b),se=h.top<_,pe=h.bottom>J-_;if(h.top<E)Y.scrollTop=se?0:h.top;else if(h.bottom>E+U){var We=Math.min(h.top,(pe?J:h.bottom)-U);We!=E&&(Y.scrollTop=We)}var Ye=A.options.fixedGutter?0:b.gutters.offsetWidth,Mt=A.curOp&&A.curOp.scrollLeft!=null?A.curOp.scrollLeft:b.scroller.scrollLeft-Ye,yt=Ju(A)-b.gutters.offsetWidth,qt=h.right-h.left>yt;return qt&&(h.right=h.left+yt),h.left<10?Y.scrollLeft=0:h.left<Mt?Y.scrollLeft=Math.max(0,h.left+Ye-(qt?0:10)):h.right>yt+Mt-3&&(Y.scrollLeft=h.right+(qt?0:10)-yt),Y}function Bh(A,h){h!=null&&(gr(A),A.curOp.scrollTop=(A.curOp.scrollTop==null?A.doc.scrollTop:A.curOp.scrollTop)+h)}function oa(A){gr(A);var h=A.getCursor();A.curOp.scrollToPos={from:h,to:h,margin:A.options.cursorScrollMargin}}function Eo(A,h,b){(h!=null||b!=null)&&gr(A),h!=null&&(A.curOp.scrollLeft=h),b!=null&&(A.curOp.scrollTop=b)}function uc(A,h){gr(A),A.curOp.scrollToPos=h}function gr(A){var h=A.curOp.scrollToPos;if(h){A.curOp.scrollToPos=null;var b=or(A,h.from),_=or(A,h.to);Or(A,b,_,h.margin)}}function Or(A,h,b,_){var E=Oh(A,{left:Math.min(h.left,b.left),top:Math.min(h.top,b.top)-_,right:Math.max(h.right,b.right),bottom:Math.max(h.bottom,b.bottom)+_});Eo(A,E.scrollLeft,E.scrollTop)}function SA(A,h){Math.abs(A.doc.scrollTop-h)<2||(i||Il(A,{top:h}),Jc(A,h,!0),i&&Il(A),Ku(A,100))}function Jc(A,h,b){h=Math.max(0,Math.min(A.display.scroller.scrollHeight-A.display.scroller.clientHeight,h)),!(A.display.scroller.scrollTop==h&&!b)&&(A.doc.scrollTop=h,A.display.scrollbars.setScrollTop(h),A.display.scroller.scrollTop!=h&&(A.display.scroller.scrollTop=h))}function dl(A,h,b,_){h=Math.max(0,Math.min(h,A.display.scroller.scrollWidth-A.display.scroller.clientWidth)),!((b?h==A.doc.scrollLeft:Math.abs(A.doc.scrollLeft-h)<2)&&!_)&&(A.doc.scrollLeft=h,u(A),A.display.scroller.scrollLeft!=h&&(A.display.scroller.scrollLeft=h),A.display.scrollbars.setScrollLeft(h))}function xa(A){var h=A.display,b=h.gutters.offsetWidth,_=Math.round(A.doc.height+qc(A.display));return{clientHeight:h.scroller.clientHeight,viewHeight:h.wrapper.clientHeight,scrollWidth:h.scroller.scrollWidth,clientWidth:h.scroller.clientWidth,viewWidth:h.wrapper.clientWidth,barLeft:A.options.fixedGutter?b:0,docHeight:_,scrollHeight:_+wl(A)+h.barHeight,nativeBarWidth:h.nativeBarWidth,gutterWidth:b}}var Bl=function(A,h,b){this.cm=b;var _=this.vert=Ce("div",[Ce("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),E=this.horiz=Ce("div",[Ce("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");_.tabIndex=E.tabIndex=-1,A(_),A(E),un(_,"scroll",function(){_.clientHeight&&h(_.scrollTop,"vertical")}),un(E,"scroll",function(){E.clientWidth&&h(E.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,f&&g<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Bl.prototype.update=function(A){var h=A.scrollWidth>A.clientWidth+1,b=A.scrollHeight>A.clientHeight+1,_=A.nativeBarWidth;if(b){this.vert.style.display="block",this.vert.style.bottom=h?_+"px":"0";var E=A.viewHeight-(h?_:0);this.vert.firstChild.style.height=Math.max(0,A.scrollHeight-A.clientHeight+E)+"px"}else this.vert.scrollTop=0,this.vert.style.display="",this.vert.firstChild.style.height="0";if(h){this.horiz.style.display="block",this.horiz.style.right=b?_+"px":"0",this.horiz.style.left=A.barLeft+"px";var U=A.viewWidth-A.barLeft-(b?_:0);this.horiz.firstChild.style.width=Math.max(0,A.scrollWidth-A.clientWidth+U)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&A.clientHeight>0&&(_==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:b?_:0,bottom:h?_:0}},Bl.prototype.setScrollLeft=function(A){this.horiz.scrollLeft!=A&&(this.horiz.scrollLeft=A),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Bl.prototype.setScrollTop=function(A){this.vert.scrollTop!=A&&(this.vert.scrollTop=A),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Bl.prototype.zeroWidthHack=function(){var A=ce&&!W?"12px":"18px";this.horiz.style.height=this.vert.style.width=A,this.horiz.style.visibility=this.vert.style.visibility="hidden",this.disableHoriz=new xe,this.disableVert=new xe},Bl.prototype.enableZeroWidthBar=function(A,h,b){A.style.visibility="";function _(){var E=A.getBoundingClientRect(),U=b=="vert"?document.elementFromPoint(E.right-1,(E.top+E.bottom)/2):document.elementFromPoint((E.right+E.left)/2,E.bottom-1);U!=A?A.style.visibility="hidden":h.set(1e3,_)}h.set(1e3,_)},Bl.prototype.clear=function(){var A=this.horiz.parentNode;A.removeChild(this.horiz),A.removeChild(this.vert)};var As=function(){};As.prototype.update=function(){return{bottom:0,right:0}},As.prototype.setScrollLeft=function(){},As.prototype.setScrollTop=function(){},As.prototype.clear=function(){};function Iu(A,h){h||(h=xa(A));var b=A.display.barWidth,_=A.display.barHeight;iA(A,h);for(var E=0;E<4&&b!=A.display.barWidth||_!=A.display.barHeight;E++)b!=A.display.barWidth&&A.options.lineWrapping&&Eh(A),iA(A,xa(A)),b=A.display.barWidth,_=A.display.barHeight}function iA(A,h){var b=A.display,_=b.scrollbars.update(h);b.sizer.style.paddingRight=(b.barWidth=_.right)+"px",b.sizer.style.paddingBottom=(b.barHeight=_.bottom)+"px",b.heightForcer.style.borderBottom=_.bottom+"px solid transparent",_.right&&_.bottom?(b.scrollbarFiller.style.display="block",b.scrollbarFiller.style.height=_.bottom+"px",b.scrollbarFiller.style.width=_.right+"px"):b.scrollbarFiller.style.display="",_.bottom&&A.options.coverGutterNextToScrollbar&&A.options.fixedGutter?(b.gutterFiller.style.display="block",b.gutterFiller.style.height=_.bottom+"px",b.gutterFiller.style.width=h.gutterWidth+"px"):b.gutterFiller.style.display=""}var Oo={native:Bl,null:As};function zo(A){A.display.scrollbars&&(A.display.scrollbars.clear(),A.display.scrollbars.addClass&&ct(A.display.wrapper,A.display.scrollbars.addClass)),A.display.scrollbars=new Oo[A.options.scrollbarStyle](function(h){A.display.wrapper.insertBefore(h,A.display.scrollbarFiller),un(h,"mousedown",function(){A.state.focused&&setTimeout(function(){return A.display.input.focus()},0)}),h.setAttribute("cm-not-content","true")},function(h,b){b=="horizontal"?dl(A,h):SA(A,h)},A),A.display.scrollbars.addClass&&Ve(A.display.wrapper,A.display.scrollbars.addClass)}var Ip=0;function du(A){A.curOp={cm:A,viewChanged:!1,startHeight:A.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Ip,markArrays:null},Qc(A.curOp)}function Tu(A){var h=A.curOp;h&&xf(h,function(b){for(var _=0;_<b.ops.length;_++)b.ops[_].cm.curOp=null;Bf(b)})}function Bf(A){for(var h=A.ops,b=0;b<h.length;b++)Ac(h[b]);for(var _=0;_<h.length;_++)cc(h[_]);for(var E=0;E<h.length;E++)ed(h[E]);for(var U=0;U<h.length;U++)ke(h[U]);for(var Y=0;Y<h.length;Y++)oA(h[Y])}function Ac(A){var h=A.cm,b=h.display;kh(h),A.updateMaxLine&&_s(h),A.mustUpdate=A.viewChanged||A.forceUpdate||A.scrollTop!=null||A.scrollToPos&&(A.scrollToPos.from.line<b.viewFrom||A.scrollToPos.to.line>=b.viewTo)||b.maxLineChanged&&h.options.lineWrapping,A.update=A.mustUpdate&&new kl(h,A.mustUpdate&&{top:A.scrollTop,ensure:A.scrollToPos},A.forceUpdate)}function cc(A){A.updatedDisplay=A.mustUpdate&&Ld(A.cm,A.update)}function ed(A){var h=A.cm,b=h.display;A.updatedDisplay&&Eh(h),A.barMeasure=xa(h),b.maxLineChanged&&!h.options.lineWrapping&&(A.adjustWidthTo=Pd(h,b.maxLine,b.maxLine.text.length).left+3,h.display.sizerWidth=A.adjustWidthTo,A.barMeasure.scrollWidth=Math.max(b.scroller.clientWidth,b.sizer.offsetLeft+A.adjustWidthTo+wl(h)+h.display.barWidth),A.maxScrollLeft=Math.max(0,b.sizer.offsetLeft+A.adjustWidthTo-Ju(h))),(A.updatedDisplay||A.selectionChanged)&&(A.preparedSelection=b.input.prepareSelection())}function ke(A){var h=A.cm;A.adjustWidthTo!=null&&(h.display.sizer.style.minWidth=A.adjustWidthTo+"px",A.maxScrollLeft<h.doc.scrollLeft&&dl(h,Math.min(h.display.scroller.scrollLeft,A.maxScrollLeft),!0),h.display.maxLineChanged=!1);var b=A.focus&&A.focus==Nt(pt(h));A.preparedSelection&&h.display.input.showSelection(A.preparedSelection,b),(A.updatedDisplay||A.startHeight!=h.doc.height)&&Iu(h,A.barMeasure),A.updatedDisplay&&O(h,A.barMeasure),A.selectionChanged&&sc(h),h.state.focused&&A.updateInput&&h.display.input.reset(A.typing),b&&Vl(A.cm)}function oA(A){var h=A.cm,b=h.display,_=h.doc;if(A.updatedDisplay&&zd(h,A.update),b.wheelStartX!=null&&(A.scrollTop!=null||A.scrollLeft!=null||A.scrollToPos)&&(b.wheelStartX=b.wheelStartY=null),A.scrollTop!=null&&Jc(h,A.scrollTop,A.forceScroll),A.scrollLeft!=null&&dl(h,A.scrollLeft,!0,!0),A.scrollToPos){var E=Ef(h,br(_,A.scrollToPos.from),br(_,A.scrollToPos.to),A.scrollToPos.margin);Xc(h,E)}var U=A.maybeHiddenMarkers,Y=A.maybeUnhiddenMarkers;if(U)for(var J=0;J<U.length;++J)U[J].lines.length||Zn(U[J],"hide");if(Y)for(var se=0;se<Y.length;++se)Y[se].lines.length&&Zn(Y[se],"unhide");b.wrapper.offsetHeight&&(_.scrollTop=h.display.scroller.scrollTop),A.changeObjs&&Zn(h,"changes",h,A.changeObjs),A.update&&A.update.finish()}function wa(A,h){if(A.curOp)return h();du(A);try{return h()}finally{Tu(A)}}function uo(A,h){return function(){if(A.curOp)return h.apply(A,arguments);du(A);try{return h.apply(A,arguments)}finally{Tu(A)}}}function jr(A){return function(){if(this.curOp)return A.apply(this,arguments);du(this);try{return A.apply(this,arguments)}finally{Tu(this)}}}function Ma(A){return function(){var h=this.cm;if(!h||h.curOp)return A.apply(this,arguments);du(h);try{return A.apply(this,arguments)}finally{Tu(h)}}}function Ku(A,h){A.doc.highlightFrontier<A.display.viewTo&&A.state.highlight.set(h,Dt(dc,A))}function dc(A){var h=A.doc;if(!(h.highlightFrontier>=A.display.viewTo)){var b=+new Date+A.options.workTime,_=va(A,h.highlightFrontier),E=[];h.iter(_.line,Math.min(h.first+h.size,A.display.viewTo+500),function(U){if(_.line>=A.display.viewFrom){var Y=U.styles,J=U.text.length>A.options.maxHighlightLength?ba(h.mode,_.state):null,se=qs(A,U,_,!0);J&&(_.state=J),U.styles=se.styles;var pe=U.styleClasses,We=se.classes;We?U.styleClasses=We:pe&&(U.styleClasses=null);for(var Ye=!Y||Y.length!=U.styles.length||pe!=We&&(!pe||!We||pe.bgClass!=We.bgClass||pe.textClass!=We.textClass),Mt=0;!Ye&&Mt<Y.length;++Mt)Ye=Y[Mt]!=U.styles[Mt];Ye&&E.push(_.line),U.stateAfter=_.save(),_.nextLine()}else U.text.length<=A.options.maxHighlightLength&&$a(A,U.text,_),U.stateAfter=_.line%5==0?_.save():null,_.nextLine();if(+new Date>b)return Ku(A,A.options.workDelay),!0}),h.highlightFrontier=_.line,h.modeFrontier=Math.max(h.modeFrontier,_.line),E.length&&wa(A,function(){for(var U=0;U<E.length;U++)Ol(A,E[U],"text")})}}var kl=function(A,h,b){var _=A.display;this.viewport=h,this.visible=go(_,A.doc,h),this.editorIsHidden=!_.wrapper.offsetWidth,this.wrapperHeight=_.wrapper.clientHeight,this.wrapperWidth=_.wrapper.clientWidth,this.oldDisplayWidth=Ju(A),this.force=b,this.dims=nA(A),this.events=[]};kl.prototype.signal=function(A,h){_e(A,h)&&this.events.push(arguments)},kl.prototype.finish=function(){for(var A=0;A<this.events.length;A++)Zn.apply(null,this.events[A])};function kh(A){var h=A.display;!h.scrollbarsClipped&&h.scroller.offsetWidth&&(h.nativeBarWidth=h.scroller.offsetWidth-h.scroller.clientWidth,h.heightForcer.style.height=wl(A)+"px",h.sizer.style.marginBottom=-h.nativeBarWidth+"px",h.sizer.style.borderRightWidth=wl(A)+"px",h.scrollbarsClipped=!0)}function hc(A){if(A.hasFocus())return null;var h=Nt(pt(A));if(!h||!Jt(A.display.lineDiv,h))return null;var b={activeElt:h};if(window.getSelection){var _=kt(A).getSelection();_.anchorNode&&_.extend&&Jt(A.display.lineDiv,_.anchorNode)&&(b.anchorNode=_.anchorNode,b.anchorOffset=_.anchorOffset,b.focusNode=_.focusNode,b.focusOffset=_.focusOffset)}return b}function Ih(A){if(!(!A||!A.activeElt||A.activeElt==Nt(dt(A.activeElt)))&&(A.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(A.activeElt.nodeName)&&A.anchorNode&&Jt(document.body,A.anchorNode)&&Jt(document.body,A.focusNode))){var h=A.activeElt.ownerDocument,b=h.defaultView.getSelection(),_=h.createRange();_.setEnd(A.anchorNode,A.anchorOffset),_.collapse(!1),b.removeAllRanges(),b.addRange(_),b.extend(A.focusNode,A.focusOffset)}}function Ld(A,h){var b=A.display,_=A.doc;if(h.editorIsHidden)return Fa(A),!1;if(!h.force&&h.visible.from>=b.viewFrom&&h.visible.to<=b.viewTo&&(b.updateLineNumbers==null||b.updateLineNumbers>=b.viewTo)&&b.renderedView==b.view&&oc(A)==0)return!1;p(A)&&(Fa(A),h.dims=nA(A));var E=_.first+_.size,U=Math.max(h.visible.from-A.options.viewportMargin,_.first),Y=Math.min(E,h.visible.to+A.options.viewportMargin);b.viewFrom<U&&U-b.viewFrom<20&&(U=Math.max(_.first,b.viewFrom)),b.viewTo>Y&&b.viewTo-Y<20&&(Y=Math.min(E,b.viewTo)),vs&&(U=Ca(A.doc,U),Y=Vo(A.doc,Y));var J=U!=b.viewFrom||Y!=b.viewTo||b.lastWrapHeight!=h.wrapperHeight||b.lastWrapWidth!=h.wrapperWidth;Hc(A,U,Y),b.viewOffset=Pa(rr(A.doc,b.viewFrom)),A.display.mover.style.top=b.viewOffset+"px";var se=oc(A);if(!J&&se==0&&!h.force&&b.renderedView==b.view&&(b.updateLineNumbers==null||b.updateLineNumbers>=b.viewTo))return!1;var pe=hc(A);return se>4&&(b.lineDiv.style.display="none"),kf(A,b.updateLineNumbers,h.dims),se>4&&(b.lineDiv.style.display=""),b.renderedView=b.view,Ih(pe),Fe(b.cursorDiv),Fe(b.selectionDiv),b.gutters.style.height=b.sizer.style.minHeight=0,J&&(b.lastWrapHeight=h.wrapperHeight,b.lastWrapWidth=h.wrapperWidth,Ku(A,400)),b.updateLineNumbers=null,!0}function zd(A,h){for(var b=h.viewport,_=!0;;_=!1){if(!_||!A.options.lineWrapping||h.oldDisplayWidth==Ju(A)){if(b&&b.top!=null&&(b={top:Math.min(A.doc.height+qc(A.display)-bh(A),b.top)}),h.visible=go(A.display,A.doc,b),h.visible.from>=A.display.viewFrom&&h.visible.to<=A.display.viewTo)break}else _&&(h.visible=go(A.display,A.doc,b));if(!Ld(A,h))break;Eh(A);var E=xa(A);cl(A),Iu(A,E),O(A,E),h.force=!1}h.signal(A,"update",A),(A.display.viewFrom!=A.display.reportedViewFrom||A.display.viewTo!=A.display.reportedViewTo)&&(h.signal(A,"viewportChange",A,A.display.viewFrom,A.display.viewTo),A.display.reportedViewFrom=A.display.viewFrom,A.display.reportedViewTo=A.display.viewTo)}function Il(A,h){var b=new kl(A,h);if(Ld(A,b)){Eh(A),zd(A,b);var _=xa(A);cl(A),Iu(A,_),O(A,_),b.finish()}}function kf(A,h,b){var _=A.display,E=A.options.lineNumbers,U=_.lineDiv,Y=U.firstChild;function J(qt){var Zt=qt.nextSibling;return x&&ce&&A.display.currentWheelTarget==qt?qt.style.display="none":qt.parentNode.removeChild(qt),Zt}for(var se=_.view,pe=_.viewFrom,We=0;We<se.length;We++){var Ye=se[We];if(!Ye.hidden)if(!Ye.node||Ye.node.parentNode!=U){var Mt=tc(A,Ye,pe,b);U.insertBefore(Mt,Y)}else{for(;Y!=Ye.node;)Y=J(Y);var yt=E&&h!=null&&h<=pe&&Ye.lineNumber;Ye.changes&&(Pe(Ye.changes,"gutter")>-1&&(yt=!1),wf(A,Ye,pe,b)),yt&&(Fe(Ye.lineNumber),Ye.lineNumber.appendChild(document.createTextNode(mn(A.options,pe)))),Y=Ye.node.nextSibling}pe+=Ye.size}for(;Y;)Y=J(Y)}function Pi(A){var h=A.gutters.offsetWidth;A.sizer.style.marginLeft=h+"px",Ur(A,"gutterChanged",A)}function O(A,h){A.display.sizer.style.minHeight=h.docHeight+"px",A.display.heightForcer.style.top=h.docHeight+"px",A.display.gutters.style.height=h.docHeight+A.display.barHeight+wl(A)+"px"}function u(A){var h=A.display,b=h.view;if(!(!h.alignWidgets&&(!h.gutters.firstChild||!A.options.fixedGutter))){for(var _=Ei(h)-h.scroller.scrollLeft+A.doc.scrollLeft,E=h.gutters.offsetWidth,U=_+"px",Y=0;Y<b.length;Y++)if(!b[Y].hidden){A.options.fixedGutter&&(b[Y].gutter&&(b[Y].gutter.style.left=U),b[Y].gutterBackground&&(b[Y].gutterBackground.style.left=U));var J=b[Y].alignable;if(J)for(var se=0;se<J.length;se++)J[se].style.left=U}A.options.fixedGutter&&(h.gutters.style.left=_+E+"px")}}function p(A){if(!A.options.lineNumbers)return!1;var h=A.doc,b=mn(A.options,h.first+h.size-1),_=A.display;if(b.length!=_.lineNumChars){var E=_.measure.appendChild(Ce("div",[Ce("div",b)],"CodeMirror-linenumber CodeMirror-gutter-elt")),U=E.firstChild.offsetWidth,Y=E.offsetWidth-U;return _.lineGutter.style.width="",_.lineNumInnerWidth=Math.max(U,_.lineGutter.offsetWidth-Y)+1,_.lineNumWidth=_.lineNumInnerWidth+Y,_.lineNumChars=_.lineNumInnerWidth?b.length:-1,_.lineGutter.style.width=_.lineNumWidth+"px",Pi(A.display),!0}return!1}function C(A,h){for(var b=[],_=!1,E=0;E<A.length;E++){var U=A[E],Y=null;if(typeof U!="string"&&(Y=U.style,U=U.className),U=="CodeMirror-linenumbers")if(h)_=!0;else continue;b.push({className:U,style:Y})}return h&&!_&&b.push({className:"CodeMirror-linenumbers",style:null}),b}function M(A){var h=A.gutters,b=A.gutterSpecs;Fe(h),A.lineGutter=null;for(var _=0;_<b.length;++_){var E=b[_],U=E.className,Y=E.style,J=h.appendChild(Ce("div",null,"CodeMirror-gutter "+U));Y&&(J.style.cssText=Y),U=="CodeMirror-linenumbers"&&(A.lineGutter=J,J.style.width=(A.lineNumWidth||1)+"px")}h.style.display=b.length?"":"none",Pi(A)}function I(A){M(A.display),us(A),u(A)}function L(A,h,b,_){var E=this;this.input=b,E.scrollbarFiller=Ce("div",null,"CodeMirror-scrollbar-filler"),E.scrollbarFiller.setAttribute("cm-not-content","true"),E.gutterFiller=Ce("div",null,"CodeMirror-gutter-filler"),E.gutterFiller.setAttribute("cm-not-content","true"),E.lineDiv=jt("div",null,"CodeMirror-code"),E.selectionDiv=Ce("div",null,null,"position: relative; z-index: 1"),E.cursorDiv=Ce("div",null,"CodeMirror-cursors"),E.measure=Ce("div",null,"CodeMirror-measure"),E.lineMeasure=Ce("div",null,"CodeMirror-measure"),E.lineSpace=jt("div",[E.measure,E.lineMeasure,E.selectionDiv,E.cursorDiv,E.lineDiv],null,"position: relative; outline: none");var U=jt("div",[E.lineSpace],"CodeMirror-lines");E.mover=Ce("div",[U],null,"position: relative"),E.sizer=Ce("div",[E.mover],"CodeMirror-sizer"),E.sizerWidth=null,E.heightForcer=Ce("div",null,null,"position: absolute; height: "+Ze+"px; width: 1px;"),E.gutters=Ce("div",null,"CodeMirror-gutters"),E.lineGutter=null,E.scroller=Ce("div",[E.sizer,E.heightForcer,E.gutters],"CodeMirror-scroll"),E.scroller.setAttribute("tabIndex","-1"),E.wrapper=Ce("div",[E.scrollbarFiller,E.gutterFiller,E.scroller],"CodeMirror"),B&&P>=105&&(E.wrapper.style.clipPath="inset(0px)"),E.wrapper.setAttribute("translate","no"),f&&g<8&&(E.gutters.style.zIndex=-1,E.scroller.style.paddingRight=0),!x&&!(i&&ne)&&(E.scroller.draggable=!0),A&&(A.appendChild?A.appendChild(E.wrapper):A(E.wrapper)),E.viewFrom=E.viewTo=h.first,E.reportedViewFrom=E.reportedViewTo=h.first,E.view=[],E.renderedView=null,E.externalMeasured=null,E.viewOffset=0,E.lastWrapHeight=E.lastWrapWidth=0,E.updateLineNumbers=null,E.nativeBarWidth=E.barHeight=E.barWidth=0,E.scrollbarsClipped=!1,E.lineNumWidth=E.lineNumInnerWidth=E.lineNumChars=null,E.alignWidgets=!1,E.cachedCharWidth=E.cachedTextHeight=E.cachedPaddingH=null,E.maxLine=null,E.maxLineLength=0,E.maxLineChanged=!1,E.wheelDX=E.wheelDY=E.wheelStartX=E.wheelStartY=null,E.shift=!1,E.selForContextMenu=null,E.activeTouch=null,E.gutterSpecs=C(_.gutters,_.lineNumbers),M(E),b.init(E)}var j=0,G=null;f?G=-.53:i?G=15:B?G=-.7:H&&(G=-1/3);function te(A){var h=A.wheelDeltaX,b=A.wheelDeltaY;return h==null&&A.detail&&A.axis==A.HORIZONTAL_AXIS&&(h=A.detail),b==null&&A.detail&&A.axis==A.VERTICAL_AXIS?b=A.detail:b==null&&(b=A.wheelDelta),{x:h,y:b}}function Ae(A){var h=te(A);return h.x*=G,h.y*=G,h}function he(A,h){B&&P==102&&(A.display.chromeScrollHack==null?A.display.sizer.style.pointerEvents="none":clearTimeout(A.display.chromeScrollHack),A.display.chromeScrollHack=setTimeout(function(){A.display.chromeScrollHack=null,A.display.sizer.style.pointerEvents=""},100));var b=te(h),_=b.x,E=b.y,U=G;h.deltaMode===0&&(_=h.deltaX,E=h.deltaY,U=1);var Y=A.display,J=Y.scroller,se=J.scrollWidth>J.clientWidth,pe=J.scrollHeight>J.clientHeight;if(_&&se||E&&pe){if(E&&ce&&x){e:for(var We=h.target,Ye=Y.view;We!=J;We=We.parentNode)for(var Mt=0;Mt<Ye.length;Mt++)if(Ye[Mt].node==We){A.display.currentWheelTarget=We;break e}}if(_&&!i&&!R&&U!=null){E&&pe&&SA(A,Math.max(0,J.scrollTop+E*U)),dl(A,Math.max(0,J.scrollLeft+_*U)),(!E||E&&pe)&&Te(h),Y.wheelStartX=null;return}if(E&&U!=null){var yt=E*U,qt=A.doc.scrollTop,Zt=qt+Y.wrapper.clientHeight;yt<0?qt=Math.max(0,qt+yt-50):Zt=Math.min(A.doc.height,Zt+yt+50),Il(A,{top:qt,bottom:Zt})}j<20&&h.deltaMode!==0&&(Y.wheelStartX==null?(Y.wheelStartX=J.scrollLeft,Y.wheelStartY=J.scrollTop,Y.wheelDX=_,Y.wheelDY=E,setTimeout(function(){if(Y.wheelStartX!=null){var Bn=J.scrollLeft-Y.wheelStartX,Wn=J.scrollTop-Y.wheelStartY,er=Wn&&Y.wheelDY&&Wn/Y.wheelDY||Bn&&Y.wheelDX&&Bn/Y.wheelDX;Y.wheelStartX=Y.wheelStartY=null,er&&(G=(G*j+er)/(j+1),++j)}},200)):(Y.wheelDX+=_,Y.wheelDY+=E))}}var Me=function(A,h){this.ranges=A,this.primIndex=h};Me.prototype.primary=function(){return this.ranges[this.primIndex]},Me.prototype.equals=function(A){if(A==this)return!0;if(A.primIndex!=this.primIndex||A.ranges.length!=this.ranges.length)return!1;for(var h=0;h<this.ranges.length;h++){var b=this.ranges[h],_=A.ranges[h];if(!zr(b.anchor,_.anchor)||!zr(b.head,_.head))return!1}return!0},Me.prototype.deepCopy=function(){for(var A=[],h=0;h<this.ranges.length;h++)A[h]=new De(Lr(this.ranges[h].anchor),Lr(this.ranges[h].head));return new Me(A,this.primIndex)},Me.prototype.somethingSelected=function(){for(var A=0;A<this.ranges.length;A++)if(!this.ranges[A].empty())return!0;return!1},Me.prototype.contains=function(A,h){h||(h=A);for(var b=0;b<this.ranges.length;b++){var _=this.ranges[b];if(En(h,_.from())>=0&&En(A,_.to())<=0)return b}return-1};var De=function(A,h){this.anchor=A,this.head=h};De.prototype.from=function(){return po(this.anchor,this.head)},De.prototype.to=function(){return Ti(this.anchor,this.head)},De.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function je(A,h,b){var _=A&&A.options.selectionsMayTouch,E=h[b];h.sort(function(Mt,yt){return En(Mt.from(),yt.from())}),b=Pe(h,E);for(var U=1;U<h.length;U++){var Y=h[U],J=h[U-1],se=En(J.to(),Y.from());if(_&&!Y.empty()?se>0:se>=0){var pe=po(J.from(),Y.from()),We=Ti(J.to(),Y.to()),Ye=J.empty()?Y.from()==Y.head:J.from()==J.head;U<=b&&--b,h.splice(--U,2,new De(Ye?We:pe,Ye?pe:We))}}return new Me(h,b)}function Qe(A,h){return new Me([new De(A,h||A)],0)}function Le(A){return A.text?Ot(A.from.line+A.text.length-1,ir(A.text).length+(A.text.length==1?A.from.ch:0)):A.to}function ft(A,h){if(En(A,h.from)<0)return A;if(En(A,h.to)<=0)return Le(h);var b=A.line+h.text.length-(h.to.line-h.from.line)-1,_=A.ch;return A.line==h.to.line&&(_+=Le(h).ch-h.to.ch),Ot(b,_)}function Bt(A,h){for(var b=[],_=0;_<A.sel.ranges.length;_++){var E=A.sel.ranges[_];b.push(new De(ft(E.anchor,h),ft(E.head,h)))}return je(A.cm,b,A.sel.primIndex)}function qe(A,h,b){return A.line==h.line?Ot(b.line,A.ch-h.ch+b.ch):Ot(b.line+(A.line-h.line),A.ch)}function _t(A,h,b){for(var _=[],E=Ot(A.first,0),U=E,Y=0;Y<h.length;Y++){var J=h[Y],se=qe(J.from,E,U),pe=qe(Le(J),E,U);if(E=J.to,U=pe,b=="around"){var We=A.sel.ranges[Y],Ye=En(We.head,We.anchor)<0;_[Y]=new De(Ye?pe:se,Ye?se:pe)}else _[Y]=new De(se,se)}return new Me(_,A.sel.primIndex)}function Ut(A){A.doc.mode=Ci(A.options,A.doc.modeOption),Tt(A)}function Tt(A){A.doc.iter(function(h){h.stateAfter&&(h.stateAfter=null),h.styles&&(h.styles=null)}),A.doc.modeFrontier=A.doc.highlightFrontier=A.doc.first,Ku(A,100),A.state.modeGen++,A.curOp&&us(A)}function en(A,h){return h.from.ch==0&&h.to.ch==0&&ir(h.text)==""&&(!A.cm||A.cm.options.wholeLineUpdateBefore)}function hn(A,h,b,_){function E(er){return b?b[er]:null}function U(er,fn,ar){XA(er,fn,ar,_),Ur(er,"change",er,h)}function Y(er,fn){for(var ar=[],Ir=er;Ir<fn;++Ir)ar.push(new Su(pe[Ir],E(Ir),_));return ar}var J=h.from,se=h.to,pe=h.text,We=rr(A,J.line),Ye=rr(A,se.line),Mt=ir(pe),yt=E(pe.length-1),qt=se.line-J.line;if(h.full)A.insert(0,Y(0,pe.length)),A.remove(pe.length,A.size-pe.length);else if(en(A,h)){var Zt=Y(0,pe.length-1);U(Ye,Ye.text,yt),qt&&A.remove(J.line,qt),Zt.length&&A.insert(J.line,Zt)}else if(We==Ye)if(pe.length==1)U(We,We.text.slice(0,J.ch)+Mt+We.text.slice(se.ch),yt);else{var Bn=Y(1,pe.length-1);Bn.push(new Su(Mt+We.text.slice(se.ch),yt,_)),U(We,We.text.slice(0,J.ch)+pe[0],E(0)),A.insert(J.line+1,Bn)}else if(pe.length==1)U(We,We.text.slice(0,J.ch)+pe[0]+Ye.text.slice(se.ch),E(0)),A.remove(J.line+1,qt);else{U(We,We.text.slice(0,J.ch)+pe[0],E(0)),U(Ye,Mt+Ye.text.slice(se.ch),yt);var Wn=Y(1,pe.length-1);qt>1&&A.remove(J.line+1,qt-1),A.insert(J.line+1,Wn)}Ur(A,"change",A,h)}function An(A,h,b){function _(E,U,Y){if(E.linked)for(var J=0;J<E.linked.length;++J){var se=E.linked[J];if(se.doc!=U){var pe=Y&&se.sharedHist;b&&!pe||(h(se.doc,pe),_(se.doc,E,pe))}}}_(A,null,!0)}function On(A,h){if(h.cm)throw new Error("This document is already in use.");A.doc=h,h.cm=A,Mh(A),Ut(A),lr(A),A.options.direction=h.direction,A.options.lineWrapping||_s(A),A.options.mode=h.modeOption,us(A)}function lr(A){(A.doc.direction=="rtl"?Ve:ct)(A.display.lineDiv,"CodeMirror-rtl")}function xr(A){wa(A,function(){lr(A),us(A)})}function Tn(A){this.done=[],this.undone=[],this.undoDepth=A?A.undoDepth:1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=A?A.maxGeneration:1}function yr(A,h){var b={from:Lr(h.from),to:Le(h),text:lo(A,h.from,h.to)};return vo(A,b,h.from.line,h.to.line+1),An(A,function(_){return vo(_,b,h.from.line,h.to.line+1)},!0),b}function Qn(A){for(;A.length;){var h=ir(A);if(h.ranges)A.pop();else break}}function Ho(A,h){if(h)return Qn(A.done),ir(A.done);if(A.done.length&&!ir(A.done).ranges)return ir(A.done);if(A.done.length>1&&!A.done[A.done.length-2].ranges)return A.done.pop(),ir(A.done)}function pi(A,h,b,_){var E=A.history;E.undone.length=0;var U=+new Date,Y,J;if((E.lastOp==_||E.lastOrigin==h.origin&&h.origin&&(h.origin.charAt(0)=="+"&&E.lastModTime>U-(A.cm?A.cm.options.historyEventDelay:500)||h.origin.charAt(0)=="*"))&&(Y=Ho(E,E.lastOp==_)))J=ir(Y.changes),En(h.from,h.to)==0&&En(h.from,J.to)==0?J.to=Le(h):Y.changes.push(yr(A,h));else{var se=ir(E.done);for((!se||!se.ranges)&&yo(A.sel,E.done),Y={changes:[yr(A,h)],generation:E.generation},E.done.push(Y);E.done.length>E.undoDepth;)E.done.shift(),E.done[0].ranges||E.done.shift()}E.done.push(b),E.generation=++E.maxGeneration,E.lastModTime=E.lastSelTime=U,E.lastOp=E.lastSelOp=_,E.lastOrigin=E.lastSelOrigin=h.origin,J||Zn(A,"historyAdded")}function ii(A,h,b,_){var E=h.charAt(0);return E=="*"||E=="+"&&b.ranges.length==_.ranges.length&&b.somethingSelected()==_.somethingSelected()&&new Date-A.history.lastSelTime<=(A.cm?A.cm.options.historyEventDelay:500)}function si(A,h,b,_){var E=A.history,U=_&&_.origin;b==E.lastSelOp||U&&E.lastSelOrigin==U&&(E.lastModTime==E.lastSelTime&&E.lastOrigin==U||ii(A,U,ir(E.done),h))?E.done[E.done.length-1]=h:yo(h,E.done),E.lastSelTime=+new Date,E.lastSelOrigin=U,E.lastSelOp=b,_&&_.clearRedo!==!1&&Qn(E.undone)}function yo(A,h){var b=ir(h);b&&b.ranges&&b.equals(A)||h.push(A)}function vo(A,h,b,_){var E=h["spans_"+A.id],U=0;A.iter(Math.max(A.first,b),Math.min(A.first+A.size,_),function(Y){Y.markedSpans&&((E||(E=h["spans_"+A.id]={}))[U]=Y.markedSpans),++U})}function Zs(A){if(!A)return null;for(var h,b=0;b<A.length;++b)A[b].marker.explicitlyCleared?h||(h=A.slice(0,b)):h&&h.push(A[b]);return h?h.length?h:null:A}function Sa(A,h){var b=h["spans_"+A.id];if(!b)return null;for(var _=[],E=0;E<h.text.length;++E)_.push(Zs(b[E]));return _}function aa(A,h){var b=Sa(A,h),_=as(A,h);if(!b)return _;if(!_)return b;for(var E=0;E<b.length;++E){var U=b[E],Y=_[E];if(U&&Y)e:for(var J=0;J<Y.length;++J){for(var se=Y[J],pe=0;pe<U.length;++pe)if(U[pe].marker==se.marker)continue e;U.push(se)}else Y&&(b[E]=Y)}return b}function _a(A,h,b){for(var _=[],E=0;E<A.length;++E){var U=A[E];if(U.ranges){_.push(b?Me.prototype.deepCopy.call(U):U);continue}var Y=U.changes,J=[];_.push({changes:J});for(var se=0;se<Y.length;++se){var pe=Y[se],We=void 0;if(J.push({from:pe.from,to:pe.to,text:pe.text}),h)for(var Ye in pe)(We=Ye.match(/^spans_(\d+)$/))&&Pe(h,Number(We[1]))>-1&&(ir(J)[Ye]=pe[Ye],delete pe[Ye])}}return _}function no(A,h,b,_){if(_){var E=A.anchor;if(b){var U=En(h,E)<0;U!=En(b,E)<0?(E=h,h=b):U!=En(h,b)<0&&(h=b)}return new De(E,h)}else return new De(b||h,h)}function ws(A,h,b,_,E){E==null&&(E=A.cm&&(A.cm.display.shift||A.extend)),ji(A,new Me([no(A.sel.primary(),h,b,E)],0),_)}function Pu(A,h,b){for(var _=[],E=A.cm&&(A.cm.display.shift||A.extend),U=0;U<A.sel.ranges.length;U++)_[U]=no(A.sel.ranges[U],h[U],null,E);var Y=je(A.cm,_,A.sel.primIndex);ji(A,Y,b)}function Ms(A,h,b,_){var E=A.sel.ranges.slice(0);E[h]=b,ji(A,je(A.cm,E,A.sel.primIndex),_)}function aA(A,h,b,_){ji(A,Qe(h,b),_)}function hu(A,h,b){var _={ranges:h.ranges,update:function(E){this.ranges=[];for(var U=0;U<E.length;U++)this.ranges[U]=new De(br(A,E[U].anchor),br(A,E[U].head))},origin:b&&b.origin};return Zn(A,"beforeSelectionChange",A,_),A.cm&&Zn(A.cm,"beforeSelectionChange",A.cm,_),_.ranges!=h.ranges?je(A.cm,_.ranges,_.ranges.length-1):h}function Zo(A,h,b){var _=A.history.done,E=ir(_);E&&E.ranges?(_[_.length-1]=h,Oi(A,h,b)):ji(A,h,b)}function ji(A,h,b){Oi(A,h,b),si(A,A.sel,A.cm?A.cm.curOp.id:NaN,b)}function Oi(A,h,b){(_e(A,"beforeSelectionChange")||A.cm&&_e(A.cm,"beforeSelectionChange"))&&(h=hu(A,h,b));var _=b&&b.bias||(En(h.primary().head,A.sel.primary().head)<0?-1:1);cs(A,Da(A,h,_,!0)),!(b&&b.scroll===!1)&&A.cm&&A.cm.getOption("readOnly")!="nocursor"&&oa(A.cm)}function cs(A,h){h.equals(A.sel)||(A.sel=h,A.cm&&(A.cm.curOp.updateInput=1,A.cm.curOp.selectionChanged=!0,fe(A.cm)),Ur(A,"cursorActivity",A))}function jo(A){cs(A,Da(A,A.sel,null,!1))}function Da(A,h,b,_){for(var E,U=0;U<h.ranges.length;U++){var Y=h.ranges[U],J=h.ranges.length==A.sel.ranges.length&&A.sel.ranges[U],se=sa(A,Y.anchor,J&&J.anchor,b,_),pe=Y.head==Y.anchor?se:sa(A,Y.head,J&&J.head,b,_);(E||se!=Y.anchor||pe!=Y.head)&&(E||(E=h.ranges.slice(0,U)),E[U]=new De(se,pe))}return E?je(A.cm,E,h.primIndex):h}function ua(A,h,b,_,E){var U=rr(A,h.line);if(U.markedSpans)for(var Y=0;Y<U.markedSpans.length;++Y){var J=U.markedSpans[Y],se=J.marker,pe="selectLeft"in se?!se.selectLeft:se.inclusiveLeft,We="selectRight"in se?!se.selectRight:se.inclusiveRight;if((J.from==null||(pe?J.from<=h.ch:J.from<h.ch))&&(J.to==null||(We?J.to>=h.ch:J.to>h.ch))){if(E&&(Zn(se,"beforeCursorEnter"),se.explicitlyCleared))if(U.markedSpans){--Y;continue}else break;if(!se.atomic)continue;if(b){var Ye=se.find(_<0?1:-1),Mt=void 0;if((_<0?We:pe)&&(Ye=If(A,Ye,-_,Ye&&Ye.line==h.line?U:null)),Ye&&Ye.line==h.line&&(Mt=En(Ye,b))&&(_<0?Mt<0:Mt>0))return ua(A,Ye,h,_,E)}var yt=se.find(_<0?-1:1);return(_<0?pe:We)&&(yt=If(A,yt,_,yt.line==h.line?U:null)),yt?ua(A,yt,h,_,E):null}}return h}function sa(A,h,b,_,E){var U=_||1,Y=ua(A,h,b,U,E)||!E&&ua(A,h,b,U,!0)||ua(A,h,b,-U,E)||!E&&ua(A,h,b,-U,!0);return Y||(A.cantEdit=!0,Ot(A.first,0))}function If(A,h,b,_){return b<0&&h.ch==0?h.line>A.first?br(A,Ot(h.line-1)):null:b>0&&h.ch==(_||rr(A,h.line)).text.length?h.line<A.first+A.size-1?Ot(h.line+1,0):null:new Ot(h.line,h.ch+b)}function Wo(A){A.setSelection(Ot(A.firstLine(),0),Ot(A.lastLine()),wt)}function jd(A,h,b){var _={canceled:!1,from:h.from,to:h.to,text:h.text,origin:h.origin,cancel:function(){return _.canceled=!0}};return b&&(_.update=function(E,U,Y,J){E&&(_.from=br(A,E)),U&&(_.to=br(A,U)),Y&&(_.text=Y),J!==void 0&&(_.origin=J)}),Zn(A,"beforeChange",A,_),A.cm&&Zn(A.cm,"beforeChange",A.cm,_),_.canceled?(A.cm&&(A.cm.curOp.updateInput=2),null):{from:_.from,to:_.to,text:_.text,origin:_.origin}}function fc(A,h,b){if(A.cm){if(!A.cm.curOp)return uo(A.cm,fc)(A,h,b);if(A.cm.state.suppressEdits)return}if(!((_e(A,"beforeChange")||A.cm&&_e(A.cm,"beforeChange"))&&(h=jd(A,h,!0),!h))){var _=Ya&&!b&&Au(A,h.from,h.to);if(_)for(var E=_.length-1;E>=0;--E)EA(A,{from:_[E].from,to:_[E].to,text:E?[""]:h.text,origin:h.origin});else EA(A,h)}}function EA(A,h){if(!(h.text.length==1&&h.text[0]==""&&En(h.from,h.to)==0)){var b=Bt(A,h);pi(A,h,b,A.cm?A.cm.curOp.id:NaN),OA(A,h,b,as(A,h));var _=[];An(A,function(E,U){!U&&Pe(_,E.history)==-1&&(td(E.history,h),_.push(E.history)),OA(E,h,null,as(E,h))})}}function hl(A,h,b){var _=A.cm&&A.cm.state.suppressEdits;if(!(_&&!b)){for(var E=A.history,U,Y=A.sel,J=h=="undo"?E.done:E.undone,se=h=="undo"?E.undone:E.done,pe=0;pe<J.length&&(U=J[pe],!(b?U.ranges&&!U.equals(A.sel):!U.ranges));pe++);if(pe!=J.length){for(E.lastOrigin=E.lastSelOrigin=null;;)if(U=J.pop(),U.ranges){if(yo(U,se),b&&!U.equals(A.sel)){ji(A,U,{clearRedo:!1});return}Y=U}else if(_){J.push(U);return}else break;var We=[];yo(Y,se),se.push({changes:We,generation:E.generation}),E.generation=U.generation||++E.maxGeneration;for(var Ye=_e(A,"beforeChange")||A.cm&&_e(A.cm,"beforeChange"),Mt=function(Zt){var Bn=U.changes[Zt];if(Bn.origin=h,Ye&&!jd(A,Bn,!1))return J.length=0,{};We.push(yr(A,Bn));var Wn=Zt?Bt(A,Bn):ir(J);OA(A,Bn,Wn,aa(A,Bn)),!Zt&&A.cm&&A.cm.scrollIntoView({from:Bn.from,to:Le(Bn)});var er=[];An(A,function(fn,ar){!ar&&Pe(er,fn.history)==-1&&(td(fn.history,Bn),er.push(fn.history)),OA(fn,Bn,null,aa(fn,Bn))})},yt=U.changes.length-1;yt>=0;--yt){var qt=Mt(yt);if(qt)return qt.v}}}}function Fu(A,h){if(h!=0&&(A.first+=h,A.sel=new Me(Sn(A.sel.ranges,function(E){return new De(Ot(E.anchor.line+h,E.anchor.ch),Ot(E.head.line+h,E.head.ch))}),A.sel.primIndex),A.cm)){us(A.cm,A.first,A.first-h,h);for(var b=A.cm.display,_=b.viewFrom;_<b.viewTo;_++)Ol(A.cm,_,"gutter")}}function OA(A,h,b,_){if(A.cm&&!A.cm.curOp)return uo(A.cm,OA)(A,h,b,_);if(h.to.line<A.first){Fu(A,h.text.length-1-(h.to.line-h.from.line));return}if(!(h.from.line>A.lastLine())){if(h.from.line<A.first){var E=h.text.length-1-(A.first-h.from.line);Fu(A,E),h={from:Ot(A.first,0),to:Ot(h.to.line+E,h.to.ch),text:[ir(h.text)],origin:h.origin}}var U=A.lastLine();h.to.line>U&&(h={from:h.from,to:Ot(U,rr(A,U).text.length),text:[h.text[0]],origin:h.origin}),h.removed=lo(A,h.from,h.to),b||(b=Bt(A,h)),A.cm?Wd(A.cm,h,_):hn(A,h,_),Oi(A,b,wt),A.cantEdit&&sa(A,Ot(A.firstLine(),0))&&(A.cantEdit=!1)}}function Wd(A,h,b){var _=A.doc,E=A.display,U=h.from,Y=h.to,J=!1,se=U.line;A.options.lineWrapping||(se=ve(qr(rr(_,U.line))),_.iter(se,Y.line+1,function(yt){if(yt==E.maxLine)return J=!0,!0})),_.sel.contains(h.from,h.to)>-1&&fe(A),hn(_,h,b,MA(A)),A.options.lineWrapping||(_.iter(se,U.line+h.text.length,function(yt){var qt=Rs(yt);qt>E.maxLineLength&&(E.maxLine=yt,E.maxLineLength=qt,E.maxLineChanged=!0,J=!1)}),J&&(A.curOp.updateMaxLine=!0)),_A(_,U.line),Ku(A,400);var pe=h.text.length-(Y.line-U.line)-1;h.full?us(A):U.line==Y.line&&h.text.length==1&&!en(A.doc,h)?Ol(A,U.line,"text"):us(A,U.line,Y.line+1,pe);var We=_e(A,"changes"),Ye=_e(A,"change");if(Ye||We){var Mt={from:U,to:Y,text:h.text,removed:h.removed,origin:h.origin};Ye&&Ur(A,"change",A,Mt),We&&(A.curOp.changeObjs||(A.curOp.changeObjs=[])).push(Mt)}A.display.selForContextMenu=null}function BA(A,h,b,_,E){var U;_||(_=b),En(_,b)<0&&(U=[_,b],b=U[0],_=U[1]),typeof h=="string"&&(h=A.splitLines(h)),fc(A,{from:b,to:_,text:h,origin:E})}function Nd(A,h,b,_){b<A.line?A.line+=_:h<A.line&&(A.line=h,A.ch=0)}function Tf(A,h,b,_){for(var E=0;E<A.length;++E){var U=A[E],Y=!0;if(U.ranges){U.copied||(U=A[E]=U.deepCopy(),U.copied=!0);for(var J=0;J<U.ranges.length;J++)Nd(U.ranges[J].anchor,h,b,_),Nd(U.ranges[J].head,h,b,_);continue}for(var se=0;se<U.changes.length;++se){var pe=U.changes[se];if(b<pe.from.line)pe.from=Ot(pe.from.line+_,pe.from.ch),pe.to=Ot(pe.to.line+_,pe.to.ch);else if(h<=pe.to.line){Y=!1;break}}Y||(A.splice(0,E+1),E=0)}}function td(A,h){var b=h.from.line,_=h.to.line,E=h.text.length-(_-b)-1;Tf(A.done,b,_,E),Tf(A.undone,b,_,E)}function Th(A,h,b,_){var E=h,U=h;return typeof h=="number"?U=rr(A,Cl(A,h)):E=ve(h),E==null?null:(_(U,E)&&A.cm&&Ol(A.cm,E,b),U)}function pc(A){this.lines=A,this.parent=null;for(var h=0,b=0;b<A.length;++b)A[b].parent=this,h+=A[b].height;this.height=h}pc.prototype={chunkSize:function(){return this.lines.length},removeInner:function(A,h){for(var b=A,_=A+h;b<_;++b){var E=this.lines[b];this.height-=E.height,ss(E),Ur(E,"delete")}this.lines.splice(A,h)},collapse:function(A){A.push.apply(A,this.lines)},insertInner:function(A,h,b){this.height+=b,this.lines=this.lines.slice(0,A).concat(h).concat(this.lines.slice(A));for(var _=0;_<h.length;++_)h[_].parent=this},iterN:function(A,h,b){for(var _=A+h;A<_;++A)if(b(this.lines[A]))return!0}};function Kh(A){this.children=A;for(var h=0,b=0,_=0;_<A.length;++_){var E=A[_];h+=E.chunkSize(),b+=E.height,E.parent=this}this.size=h,this.height=b,this.parent=null}Kh.prototype={chunkSize:function(){return this.size},removeInner:function(A,h){this.size-=h;for(var b=0;b<this.children.length;++b){var _=this.children[b],E=_.chunkSize();if(A<E){var U=Math.min(h,E-A),Y=_.height;if(_.removeInner(A,U),this.height-=Y-_.height,E==U&&(this.children.splice(b--,1),_.parent=null),(h-=U)==0)break;A=0}else A-=E}if(this.size-h<25&&(this.children.length>1||!(this.children[0]instanceof pc))){var J=[];this.collapse(J),this.children=[new pc(J)],this.children[0].parent=this}},collapse:function(A){for(var h=0;h<this.children.length;++h)this.children[h].collapse(A)},insertInner:function(A,h,b){this.size+=h.length,this.height+=b;for(var _=0;_<this.children.length;++_){var E=this.children[_],U=E.chunkSize();if(A<=U){if(E.insertInner(A,h,b),E.lines&&E.lines.length>50){for(var Y=E.lines.length%25+25,J=Y;J<E.lines.length;){var se=new pc(E.lines.slice(J,J+=25));E.height-=se.height,this.children.splice(++_,0,se),se.parent=this}E.lines=E.lines.slice(0,Y),this.maybeSpill()}break}A-=U}},maybeSpill:function(){if(!(this.children.length<=10)){var A=this;do{var h=A.children.splice(A.children.length-5,5),b=new Kh(h);if(A.parent){A.size-=b.size,A.height-=b.height;var E=Pe(A.parent.children,A);A.parent.children.splice(E+1,0,b)}else{var _=new Kh(A.children);_.parent=A,A.children=[_,b],A=_}b.parent=A.parent}while(A.children.length>10);A.parent.maybeSpill()}},iterN:function(A,h,b){for(var _=0;_<this.children.length;++_){var E=this.children[_],U=E.chunkSize();if(A<U){var Y=Math.min(h,U-A);if(E.iterN(A,Y,b))return!0;if((h-=Y)==0)break;A=0}else A-=U}}};var nd=function(A,h,b){if(b)for(var _ in b)b.hasOwnProperty(_)&&(this[_]=b[_]);this.doc=A,this.node=h};nd.prototype.clear=function(){var A=this.doc.cm,h=this.line.widgets,b=this.line,_=ve(b);if(!(_==null||!h)){for(var E=0;E<h.length;++E)h[E]==this&&h.splice(E--,1);h.length||(b.widgets=null);var U=Ou(this);la(b,Math.max(0,b.height-U)),A&&(wa(A,function(){rd(A,b,-U),Ol(A,_,"widget")}),Ur(A,"lineWidgetCleared",A,this,_))}},nd.prototype.changed=function(){var A=this,h=this.height,b=this.doc.cm,_=this.line;this.height=null;var E=Ou(this)-h;E&&(Li(this.doc,_)||la(_,_.height+E),b&&wa(b,function(){b.curOp.forceUpdate=!0,rd(b,_,E),Ur(b,"lineWidgetChanged",b,A,ve(_))}))},Ee(nd);function rd(A,h,b){Pa(h)<(A.curOp&&A.curOp.scrollTop||A.doc.scrollTop)&&Bh(A,b)}function k1(A,h,b,_){var E=new nd(A,b,_),U=A.cm;return U&&E.noHScroll&&(U.display.alignWidgets=!0),Th(A,h,"widget",function(Y){var J=Y.widgets||(Y.widgets=[]);if(E.insertAt==null?J.push(E):J.splice(Math.min(J.length,Math.max(0,E.insertAt)),0,E),E.line=Y,U&&!Li(A,Y)){var se=Pa(Y)<A.scrollTop;la(Y,Y.height+Ou(E)),se&&Bh(U,E.height),U.curOp.forceUpdate=!0}return!0}),U&&Ur(U,"lineWidgetAdded",U,E,typeof h=="number"?h:ve(h)),E}var Gd=0,Zl=function(A,h){this.lines=[],this.type=h,this.doc=A,this.id=++Gd};Zl.prototype.clear=function(){if(!this.explicitlyCleared){var A=this.doc.cm,h=A&&!A.curOp;if(h&&du(A),_e(this,"clear")){var b=this.find();b&&Ur(this,"clear",b.from,b.to)}for(var _=null,E=null,U=0;U<this.lines.length;++U){var Y=this.lines[U],J=Us(Y.markedSpans,this);A&&!this.collapsed?Ol(A,ve(Y),"text"):A&&(J.to!=null&&(E=ve(Y)),J.from!=null&&(_=ve(Y))),Y.markedSpans=Cs(Y.markedSpans,J),J.from==null&&this.collapsed&&!Li(this.doc,Y)&&A&&la(Y,Jo(A.display))}if(A&&this.collapsed&&!A.options.lineWrapping)for(var se=0;se<this.lines.length;++se){var pe=qr(this.lines[se]),We=Rs(pe);We>A.display.maxLineLength&&(A.display.maxLine=pe,A.display.maxLineLength=We,A.display.maxLineChanged=!0)}_!=null&&A&&this.collapsed&&us(A,_,E+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,A&&jo(A.doc)),A&&Ur(A,"markerCleared",A,this,_,E),h&&Tu(A),this.parent&&this.parent.clear()}},Zl.prototype.find=function(A,h){A==null&&this.type=="bookmark"&&(A=1);for(var b,_,E=0;E<this.lines.length;++E){var U=this.lines[E],Y=Us(U.markedSpans,this);if(Y.from!=null&&(b=Ot(h?U:ve(U),Y.from),A==-1))return b;if(Y.to!=null&&(_=Ot(h?U:ve(U),Y.to),A==1))return _}return b&&{from:b,to:_}},Zl.prototype.changed=function(){var A=this,h=this.find(-1,!0),b=this,_=this.doc.cm;!h||!_||wa(_,function(){var E=h.line,U=ve(h.line),Y=rc(_,U);if(Y&&(Fd(Y),_.curOp.selectionChanged=_.curOp.forceUpdate=!0),_.curOp.updateMaxLine=!0,!Li(b.doc,E)&&b.height!=null){var J=b.height;b.height=null;var se=Ou(b)-J;se&&la(E,E.height+se)}Ur(_,"markerChanged",_,A)})},Zl.prototype.attachLine=function(A){if(!this.lines.length&&this.doc.cm){var h=this.doc.cm.curOp;(!h.maybeHiddenMarkers||Pe(h.maybeHiddenMarkers,this)==-1)&&(h.maybeUnhiddenMarkers||(h.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(A)},Zl.prototype.detachLine=function(A){if(this.lines.splice(Pe(this.lines,A),1),!this.lines.length&&this.doc.cm){var h=this.doc.cm.curOp;(h.maybeHiddenMarkers||(h.maybeHiddenMarkers=[])).push(this)}},Ee(Zl);function mc(A,h,b,_,E){if(_&&_.shared)return Wm(A,h,b,_,E);if(A.cm&&!A.cm.curOp)return uo(A.cm,mc)(A,h,b,_,E);var U=new Zl(A,E),Y=En(h,b);if(_&&Se(_,U,!1),Y>0||Y==0&&U.clearWhenEmpty!==!1)return U;if(U.replacedWith&&(U.collapsed=!0,U.widgetNode=jt("span",[U.replacedWith],"CodeMirror-widget"),_.handleMouseEvents||U.widgetNode.setAttribute("cm-ignore-events","true"),_.insertLeft&&(U.widgetNode.insertLeft=!0)),U.collapsed){if(Ki(A,h.line,h,b,U)||h.line!=b.line&&Ki(A,b.line,h,b,U))throw new Error("Inserting collapsed marker partially overlapping an existing one");Zu()}U.addToHistory&&pi(A,{from:h,to:b,origin:"markText"},A.sel,NaN);var J=h.line,se=A.cm,pe;if(A.iter(J,b.line+1,function(Ye){se&&U.collapsed&&!se.options.lineWrapping&&qr(Ye)==se.display.maxLine&&(pe=!0),U.collapsed&&J!=h.line&&la(Ye,0),lu(Ye,new Ds(U,J==h.line?h.ch:null,J==b.line?b.ch:null),A.cm&&A.cm.curOp),++J}),U.collapsed&&A.iter(h.line,b.line+1,function(Ye){Li(A,Ye)&&la(Ye,0)}),U.clearOnEnter&&un(U,"beforeCursorEnter",function(){return U.clear()}),U.readOnly&&(bA(),(A.history.done.length||A.history.undone.length)&&A.clearHistory()),U.collapsed&&(U.id=++Gd,U.atomic=!0),se){if(pe&&(se.curOp.updateMaxLine=!0),U.collapsed)us(se,h.line,b.line+1);else if(U.className||U.startStyle||U.endStyle||U.css||U.attributes||U.title)for(var We=h.line;We<=b.line;We++)Ol(se,We,"text");U.atomic&&jo(se.doc),Ur(se,"markerAdded",se,U)}return U}var Qd=function(A,h){this.markers=A,this.primary=h;for(var b=0;b<A.length;++b)A[b].parent=this};Qd.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var A=0;A<this.markers.length;++A)this.markers[A].clear();Ur(this,"clear")}},Qd.prototype.find=function(A,h){return this.primary.find(A,h)},Ee(Qd);function Wm(A,h,b,_,E){_=Se(_),_.shared=!1;var U=[mc(A,h,b,_,E)],Y=U[0],J=_.widgetNode;return An(A,function(se){J&&(_.widgetNode=J.cloneNode(!0)),U.push(mc(se,br(se,h),br(se,b),_,E));for(var pe=0;pe<se.linked.length;++pe)if(se.linked[pe].isParent)return;Y=ir(U)}),new Qd(U,Y)}function I1(A){return A.findMarks(Ot(A.first,0),A.clipPos(Ot(A.lastLine())),function(h){return h.parent})}function Xs(A,h){for(var b=0;b<h.length;b++){var _=h[b],E=_.find(),U=A.clipPos(E.from),Y=A.clipPos(E.to);if(En(U,Y)){var J=mc(A,U,Y,_.primary,_.primary.type);_.markers.push(J),J.parent=_}}}function Ph(A){for(var h=function(_){var E=A[_],U=[E.primary.doc];An(E.primary.doc,function(se){return U.push(se)});for(var Y=0;Y<E.markers.length;Y++){var J=E.markers[Y];Pe(U,J.doc)==-1&&(J.parent=null,E.markers.splice(Y--,1))}},b=0;b<A.length;b++)h(b)}var Kf=0,Js=function(A,h,b,_,E){if(!(this instanceof Js))return new Js(A,h,b,_,E);b==null&&(b=0),Kh.call(this,[new pc([new Su("",null)])]),this.first=b,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=b;var U=Ot(b,0);this.sel=Qe(U),this.history=new Tn(null),this.id=++Kf,this.modeOption=h,this.lineSep=_,this.direction=E=="rtl"?"rtl":"ltr",this.extend=!1,typeof A=="string"&&(A=this.splitLines(A)),hn(this,{from:U,to:U,text:A}),ji(this,Qe(U),wt)};Js.prototype=Qr(Kh.prototype,{constructor:Js,iter:function(A,h,b){b?this.iterN(A-this.first,h-A,b):this.iterN(this.first,this.first+this.size,A)},insert:function(A,h){for(var b=0,_=0;_<h.length;++_)b+=h[_].height;this.insertInner(A-this.first,h,b)},remove:function(A,h){this.removeInner(A-this.first,h)},getValue:function(A){var h=Gi(this,this.first,this.first+this.size);return A===!1?h:h.join(A||this.lineSeparator())},setValue:Ma(function(A){var h=Ot(this.first,0),b=this.first+this.size-1;fc(this,{from:h,to:Ot(b,rr(this,b).text.length),text:this.splitLines(A),origin:"setValue",full:!0},!0),this.cm&&Eo(this.cm,0,0),ji(this,Qe(h),wt)}),replaceRange:function(A,h,b,_){h=br(this,h),b=b?br(this,b):h,BA(this,A,h,b,_)},getRange:function(A,h,b){var _=lo(this,br(this,A),br(this,h));return b===!1?_:b===""?_.join(""):_.join(b||this.lineSeparator())},getLine:function(A){var h=this.getLineHandle(A);return h&&h.text},getLineHandle:function(A){if(Ht(this,A))return rr(this,A)},getLineNumber:function(A){return ve(A)},getLineHandleVisualStart:function(A){return typeof A=="number"&&(A=rr(this,A)),qr(A)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(A){return br(this,A)},getCursor:function(A){var h=this.sel.primary(),b;return A==null||A=="head"?b=h.head:A=="anchor"?b=h.anchor:A=="end"||A=="to"||A===!1?b=h.to():b=h.from(),b},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:Ma(function(A,h,b){aA(this,br(this,typeof A=="number"?Ot(A,h||0):A),null,b)}),setSelection:Ma(function(A,h,b){aA(this,br(this,A),br(this,h||A),b)}),extendSelection:Ma(function(A,h,b){ws(this,br(this,A),h&&br(this,h),b)}),extendSelections:Ma(function(A,h){Pu(this,_l(this,A),h)}),extendSelectionsBy:Ma(function(A,h){var b=Sn(this.sel.ranges,A);Pu(this,_l(this,b),h)}),setSelections:Ma(function(A,h,b){if(A.length){for(var _=[],E=0;E<A.length;E++)_[E]=new De(br(this,A[E].anchor),br(this,A[E].head||A[E].anchor));h==null&&(h=Math.min(A.length-1,this.sel.primIndex)),ji(this,je(this.cm,_,h),b)}}),addSelection:Ma(function(A,h,b){var _=this.sel.ranges.slice(0);_.push(new De(br(this,A),br(this,h||A))),ji(this,je(this.cm,_,_.length-1),b)}),getSelection:function(A){for(var h=this.sel.ranges,b,_=0;_<h.length;_++){var E=lo(this,h[_].from(),h[_].to());b=b?b.concat(E):E}return A===!1?b:b.join(A||this.lineSeparator())},getSelections:function(A){for(var h=[],b=this.sel.ranges,_=0;_<b.length;_++){var E=lo(this,b[_].from(),b[_].to());A!==!1&&(E=E.join(A||this.lineSeparator())),h[_]=E}return h},replaceSelection:function(A,h,b){for(var _=[],E=0;E<this.sel.ranges.length;E++)_[E]=A;this.replaceSelections(_,h,b||"+input")},replaceSelections:Ma(function(A,h,b){for(var _=[],E=this.sel,U=0;U<E.ranges.length;U++){var Y=E.ranges[U];_[U]={from:Y.from(),to:Y.to(),text:this.splitLines(A[U]),origin:b}}for(var J=h&&h!="end"&&_t(this,_,h),se=_.length-1;se>=0;se--)fc(this,_[se]);J?Zo(this,J):this.cm&&oa(this.cm)}),undo:Ma(function(){hl(this,"undo")}),redo:Ma(function(){hl(this,"redo")}),undoSelection:Ma(function(){hl(this,"undo",!0)}),redoSelection:Ma(function(){hl(this,"redo",!0)}),setExtending:function(A){this.extend=A},getExtending:function(){return this.extend},historySize:function(){for(var A=this.history,h=0,b=0,_=0;_<A.done.length;_++)A.done[_].ranges||++h;for(var E=0;E<A.undone.length;E++)A.undone[E].ranges||++b;return{undo:h,redo:b}},clearHistory:function(){var A=this;this.history=new Tn(this.history),An(this,function(h){return h.history=A.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(A){return A&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(A){return this.history.generation==(A||this.cleanGeneration)},getHistory:function(){return{done:_a(this.history.done),undone:_a(this.history.undone)}},setHistory:function(A){var h=this.history=new Tn(this.history);h.done=_a(A.done.slice(0),null,!0),h.undone=_a(A.undone.slice(0),null,!0)},setGutterMarker:Ma(function(A,h,b){return Th(this,A,"gutter",function(_){var E=_.gutterMarkers||(_.gutterMarkers={});return E[h]=b,!b&&V(E)&&(_.gutterMarkers=null),!0})}),clearGutter:Ma(function(A){var h=this;this.iter(function(b){b.gutterMarkers&&b.gutterMarkers[A]&&Th(h,b,"gutter",function(){return b.gutterMarkers[A]=null,V(b.gutterMarkers)&&(b.gutterMarkers=null),!0})})}),lineInfo:function(A){var h;if(typeof A=="number"){if(!Ht(this,A)||(h=A,A=rr(this,A),!A))return null}else if(h=ve(A),h==null)return null;return{line:h,handle:A,text:A.text,gutterMarkers:A.gutterMarkers,textClass:A.textClass,bgClass:A.bgClass,wrapClass:A.wrapClass,widgets:A.widgets}},addLineClass:Ma(function(A,h,b){return Th(this,A,h=="gutter"?"gutter":"class",function(_){var E=h=="text"?"textClass":h=="background"?"bgClass":h=="gutter"?"gutterClass":"wrapClass";if(!_[E])_[E]=b;else{if(rt(b).test(_[E]))return!1;_[E]+=" "+b}return!0})}),removeLineClass:Ma(function(A,h,b){return Th(this,A,h=="gutter"?"gutter":"class",function(_){var E=h=="text"?"textClass":h=="background"?"bgClass":h=="gutter"?"gutterClass":"wrapClass",U=_[E];if(U)if(b==null)_[E]=null;else{var Y=U.match(rt(b));if(!Y)return!1;var J=Y.index+Y[0].length;_[E]=U.slice(0,Y.index)+(!Y.index||J==U.length?"":" ")+U.slice(J)||null}else return!1;return!0})}),addLineWidget:Ma(function(A,h,b){return k1(this,A,h,b)}),removeLineWidget:function(A){A.clear()},markText:function(A,h,b){return mc(this,br(this,A),br(this,h),b,b&&b.type||"range")},setBookmark:function(A,h){var b={replacedWith:h&&(h.nodeType==null?h.widget:h),insertLeft:h&&h.insertLeft,clearWhenEmpty:!1,shared:h&&h.shared,handleMouseEvents:h&&h.handleMouseEvents};return A=br(this,A),mc(this,A,A,b,"bookmark")},findMarksAt:function(A){A=br(this,A);var h=[],b=rr(this,A.line).markedSpans;if(b)for(var _=0;_<b.length;++_){var E=b[_];(E.from==null||E.from<=A.ch)&&(E.to==null||E.to>=A.ch)&&h.push(E.marker.parent||E.marker)}return h},findMarks:function(A,h,b){A=br(this,A),h=br(this,h);var _=[],E=A.line;return this.iter(A.line,h.line+1,function(U){var Y=U.markedSpans;if(Y)for(var J=0;J<Y.length;J++){var se=Y[J];!(se.to!=null&&E==A.line&&A.ch>=se.to||se.from==null&&E!=A.line||se.from!=null&&E==h.line&&se.from>=h.ch)&&(!b||b(se.marker))&&_.push(se.marker.parent||se.marker)}++E}),_},getAllMarks:function(){var A=[];return this.iter(function(h){var b=h.markedSpans;if(b)for(var _=0;_<b.length;++_)b[_].from!=null&&A.push(b[_].marker)}),A},posFromIndex:function(A){var h,b=this.first,_=this.lineSeparator().length;return this.iter(function(E){var U=E.text.length+_;if(U>A)return h=A,!0;A-=U,++b}),br(this,Ot(b,h))},indexFromPos:function(A){A=br(this,A);var h=A.ch;if(A.line<this.first||A.ch<0)return 0;var b=this.lineSeparator().length;return this.iter(this.first,A.line,function(_){h+=_.text.length+b}),h},copy:function(A){var h=new Js(Gi(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return h.scrollTop=this.scrollTop,h.scrollLeft=this.scrollLeft,h.sel=this.sel,h.extend=!1,A&&(h.history.undoDepth=this.history.undoDepth,h.setHistory(this.getHistory())),h},linkedDoc:function(A){A||(A={});var h=this.first,b=this.first+this.size;A.from!=null&&A.from>h&&(h=A.from),A.to!=null&&A.to<b&&(b=A.to);var _=new Js(Gi(this,h,b),A.mode||this.modeOption,h,this.lineSep,this.direction);return A.sharedHist&&(_.history=this.history),(this.linked||(this.linked=[])).push({doc:_,sharedHist:A.sharedHist}),_.linked=[{doc:this,isParent:!0,sharedHist:A.sharedHist}],Xs(_,I1(this)),_},unlinkDoc:function(A){if(A instanceof qi&&(A=A.doc),this.linked)for(var h=0;h<this.linked.length;++h){var b=this.linked[h];if(b.doc==A){this.linked.splice(h,1),A.unlinkDoc(this),Ph(I1(this));break}}if(A.history==this.history){var _=[A.id];An(A,function(E){return _.push(E.id)},!0),A.history=new Tn(null),A.history.done=_a(this.history.done,_),A.history.undone=_a(this.history.undone,_)}},iterLinkedDocs:function(A){An(this,A)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(A){return this.lineSep?A.split(this.lineSep):qn(A)},lineSeparator:function(){return this.lineSep||`
|
||
`},setDirection:Ma(function(A){A!="rtl"&&(A="ltr"),A!=this.direction&&(this.direction=A,this.iter(function(h){return h.order=null}),this.cm&&xr(this.cm))})}),Js.prototype.eachLine=Js.prototype.iter;var id=0;function ev(A){var h=this;if(Nm(h),!(Ke(h,A)||xl(h.display,A))){Te(A),f&&(id=+new Date);var b=Al(h,A,!0),_=A.dataTransfer.files;if(!(!b||h.isReadOnly()))if(_&&_.length&&window.FileReader&&window.File)for(var E=_.length,U=Array(E),Y=0,J=function(){++Y==E&&uo(h,function(){b=br(h.doc,b);var yt={from:b,to:b,text:h.doc.splitLines(U.filter(function(qt){return qt!=null}).join(h.doc.lineSeparator())),origin:"paste"};fc(h.doc,yt),Zo(h.doc,Qe(br(h.doc,b),br(h.doc,Le(yt))))})()},se=function(yt,qt){if(h.options.allowDropFileTypes&&Pe(h.options.allowDropFileTypes,yt.type)==-1){J();return}var Zt=new FileReader;Zt.onerror=function(){return J()},Zt.onload=function(){var Bn=Zt.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(Bn)){J();return}U[qt]=Bn,J()},Zt.readAsText(yt)},pe=0;pe<_.length;pe++)se(_[pe],pe);else{if(h.state.draggingText&&h.doc.sel.contains(b)>-1){h.state.draggingText(A),setTimeout(function(){return h.display.input.focus()},20);return}try{var We=A.dataTransfer.getData("Text");if(We){var Ye;if(h.state.draggingText&&!h.state.draggingText.copy&&(Ye=h.listSelections()),Oi(h.doc,Qe(b,b)),Ye)for(var Mt=0;Mt<Ye.length;++Mt)BA(h.doc,"",Ye[Mt].anchor,Ye[Mt].head,"drag");h.replaceSelection(We,"around","paste"),h.display.input.focus()}}catch{}}}}function Fh(A,h){if(f&&(!A.state.draggingText||+new Date-id<100)){ht(h);return}if(!(Ke(A,h)||xl(A.display,h))&&(h.dataTransfer.setData("Text",A.getSelection()),h.dataTransfer.effectAllowed="copyMove",h.dataTransfer.setDragImage&&!H)){var b=Ce("img",null,null,"position: fixed; left: 0; top: 0;");b.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",R&&(b.width=b.height=1,A.display.wrapper.appendChild(b),b._top=b.offsetTop),h.dataTransfer.setDragImage(b,0,0),R&&b.parentNode.removeChild(b)}}function Qi(A,h){var b=Al(A,h);if(b){var _=document.createDocumentFragment();Nn(A,b,_),A.display.dragCursor||(A.display.dragCursor=Ce("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),A.display.lineSpace.insertBefore(A.display.dragCursor,A.display.cursorDiv)),He(A.display.dragCursor,_)}}function Nm(A){A.display.dragCursor&&(A.display.lineSpace.removeChild(A.display.dragCursor),A.display.dragCursor=null)}function Gm(A){if(document.getElementsByClassName){for(var h=document.getElementsByClassName("CodeMirror"),b=[],_=0;_<h.length;_++){var E=h[_].CodeMirror;E&&b.push(E)}b.length&&b[0].operation(function(){for(var U=0;U<b.length;U++)A(b[U])})}}var $d=!1;function T1(){$d||(Qm(),$d=!0)}function Qm(){var A;un(window,"resize",function(){A==null&&(A=setTimeout(function(){A=null,Gm(K1)},100))}),un(window,"blur",function(){return Gm(Zc)})}function K1(A){var h=A.display;h.cachedCharWidth=h.cachedTextHeight=h.cachedPaddingH=null,h.scrollbarsClipped=!1,A.setSize()}for(var qa={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},gc=0;gc<10;gc++)qa[gc+48]=qa[gc+96]=String(gc);for(var Ss=65;Ss<=90;Ss++)qa[Ss]=String.fromCharCode(Ss);for(var od=1;od<=12;od++)qa[od+111]=qa[od+63235]="F"+od;var kA={};kA.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},kA.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},kA.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},kA.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},kA.default=ce?kA.macDefault:kA.pcDefault;function $m(A){var h=A.split(/-(?!$)/);A=h[h.length-1];for(var b,_,E,U,Y=0;Y<h.length-1;Y++){var J=h[Y];if(/^(cmd|meta|m)$/i.test(J))U=!0;else if(/^a(lt)?$/i.test(J))b=!0;else if(/^(c|ctrl|control)$/i.test(J))_=!0;else if(/^s(hift)?$/i.test(J))E=!0;else throw new Error("Unrecognized modifier name: "+J)}return b&&(A="Alt-"+A),_&&(A="Ctrl-"+A),U&&(A="Cmd-"+A),E&&(A="Shift-"+A),A}function fu(A){var h={};for(var b in A)if(A.hasOwnProperty(b)){var _=A[b];if(/^(name|fallthrough|(de|at)tach)$/.test(b))continue;if(_=="..."){delete A[b];continue}for(var E=Sn(b.split(" "),$m),U=0;U<E.length;U++){var Y=void 0,J=void 0;U==E.length-1?(J=E.join(" "),Y=_):(J=E.slice(0,U+1).join(" "),Y="...");var se=h[J];if(!se)h[J]=Y;else if(se!=Y)throw new Error("Inconsistent bindings for "+J)}delete A[b]}for(var pe in h)A[pe]=h[pe];return A}function pu(A,h,b,_){h=ad(h);var E=h.call?h.call(A,_):h[A];if(E===!1)return"nothing";if(E==="...")return"multi";if(E!=null&&b(E))return"handled";if(h.fallthrough){if(Object.prototype.toString.call(h.fallthrough)!="[object Array]")return pu(A,h.fallthrough,b,_);for(var U=0;U<h.fallthrough.length;U++){var Y=pu(A,h.fallthrough[U],b,_);if(Y)return Y}}}function Tp(A){var h=typeof A=="string"?A:qa[A.keyCode];return h=="Ctrl"||h=="Alt"||h=="Shift"||h=="Mod"}function Ym(A,h,b){var _=A;return h.altKey&&_!="Alt"&&(A="Alt-"+A),(Re?h.metaKey:h.ctrlKey)&&_!="Ctrl"&&(A="Ctrl-"+A),(Re?h.ctrlKey:h.metaKey)&&_!="Mod"&&(A="Cmd-"+A),!b&&h.shiftKey&&_!="Shift"&&(A="Shift-"+A),A}function Yd(A,h){if(R&&A.keyCode==34&&A.char)return!1;var b=qa[A.keyCode];return b==null||A.altGraphKey?!1:(A.keyCode==3&&A.code&&(b=A.code),Ym(b,A,h))}function ad(A){return typeof A=="string"?kA[A]:A}function yc(A,h){for(var b=A.doc.sel.ranges,_=[],E=0;E<b.length;E++){for(var U=h(b[E]);_.length&&En(U.from,ir(_).to)<=0;){var Y=_.pop();if(En(Y.from,U.from)<0){U.from=Y.from;break}}_.push(U)}wa(A,function(){for(var J=_.length-1;J>=0;J--)BA(A.doc,"",_[J].from,_[J].to,"+delete");oa(A)})}function IA(A,h,b){var _=At(A.text,h+b,b);return _<0||_>A.text.length?null:_}function vc(A,h,b){var _=IA(A,h.ch,b);return _==null?null:new Ot(h.line,_,b<0?"after":"before")}function Pf(A,h,b,_,E){if(A){h.doc.direction=="rtl"&&(E=-E);var U=on(b,h.doc.direction);if(U){var Y=E<0?ir(U):U[0],J=E<0==(Y.level==1),se=J?"after":"before",pe;if(Y.level>0||h.doc.direction=="rtl"){var We=Hs(h,b);pe=E<0?b.text.length-1:0;var Ye=Ml(h,We,pe).top;pe=bt(function(Mt){return Ml(h,We,Mt).top==Ye},E<0==(Y.level==1)?Y.from:Y.to-1,pe),se=="before"&&(pe=IA(b,pe,1))}else pe=E<0?Y.to:Y.from;return new Ot(_,pe,se)}}return new Ot(_,E<0?b.text.length:0,E<0?"before":"after")}function sd(A,h,b,_){var E=on(h,A.doc.direction);if(!E)return vc(h,b,_);b.ch>=h.text.length?(b.ch=h.text.length,b.sticky="before"):b.ch<=0&&(b.ch=0,b.sticky="after");var U=Lt(E,b.ch,b.sticky),Y=E[U];if(A.doc.direction=="ltr"&&Y.level%2==0&&(_>0?Y.to>b.ch:Y.from<b.ch))return vc(h,b,_);var J=function(Wn,er){return IA(h,Wn instanceof Ot?Wn.ch:Wn,er)},se,pe=function(Wn){return A.options.lineWrapping?(se=se||Hs(A,h),ho(A,h,se,Wn)):{begin:0,end:h.text.length}},We=pe(b.sticky=="before"?J(b,-1):b.ch);if(A.doc.direction=="rtl"||Y.level==1){var Ye=Y.level==1==_<0,Mt=J(b,Ye?1:-1);if(Mt!=null&&(Ye?Mt<=Y.to&&Mt<=We.end:Mt>=Y.from&&Mt>=We.begin)){var yt=Ye?"before":"after";return new Ot(b.line,Mt,yt)}}var qt=function(Wn,er,fn){for(var ar=function(fo,Ea){return Ea?new Ot(b.line,J(fo,1),"before"):new Ot(b.line,fo,"after")};Wn>=0&&Wn<E.length;Wn+=er){var Ir=E[Wn],Br=er>0==(Ir.level!=1),Xr=Br?fn.begin:J(fn.end,-1);if(Ir.from<=Xr&&Xr<Ir.to||(Xr=Br?Ir.from:J(Ir.to,-1),fn.begin<=Xr&&Xr<fn.end))return ar(Xr,Br)}},Zt=qt(U+_,_,We);if(Zt)return Zt;var Bn=_>0?We.end:J(We.begin,-1);return Bn!=null&&!(_>0&&Bn==h.text.length)&&(Zt=qt(_>0?0:E.length-1,_,pe(Bn)),Zt)?Zt:null}var Ff={selectAll:Wo,singleSelection:function(A){return A.setSelection(A.getCursor("anchor"),A.getCursor("head"),wt)},killLine:function(A){return yc(A,function(h){if(h.empty()){var b=rr(A.doc,h.head.line).text.length;return h.head.ch==b&&h.head.line<A.lastLine()?{from:h.head,to:Ot(h.head.line+1,0)}:{from:h.head,to:Ot(h.head.line,b)}}else return{from:h.from(),to:h.to()}})},deleteLine:function(A){return yc(A,function(h){return{from:Ot(h.from().line,0),to:br(A.doc,Ot(h.to().line+1,0))}})},delLineLeft:function(A){return yc(A,function(h){return{from:Ot(h.from().line,0),to:h.from()}})},delWrappedLineLeft:function(A){return yc(A,function(h){var b=A.charCoords(h.head,"div").top+5,_=A.coordsChar({left:0,top:b},"div");return{from:_,to:h.from()}})},delWrappedLineRight:function(A){return yc(A,function(h){var b=A.charCoords(h.head,"div").top+5,_=A.coordsChar({left:A.display.lineDiv.offsetWidth+100,top:b},"div");return{from:h.from(),to:_}})},undo:function(A){return A.undo()},redo:function(A){return A.redo()},undoSelection:function(A){return A.undoSelection()},redoSelection:function(A){return A.redoSelection()},goDocStart:function(A){return A.extendSelection(Ot(A.firstLine(),0))},goDocEnd:function(A){return A.extendSelection(Ot(A.lastLine()))},goLineStart:function(A){return A.extendSelectionsBy(function(h){return Cc(A,h.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(A){return A.extendSelectionsBy(function(h){return qm(A,h.head)},{origin:"+move",bias:1})},goLineEnd:function(A){return A.extendSelectionsBy(function(h){return P1(A,h.head.line)},{origin:"+move",bias:-1})},goLineRight:function(A){return A.extendSelectionsBy(function(h){var b=A.cursorCoords(h.head,"div").top+5;return A.coordsChar({left:A.display.lineDiv.offsetWidth+100,top:b},"div")},Pt)},goLineLeft:function(A){return A.extendSelectionsBy(function(h){var b=A.cursorCoords(h.head,"div").top+5;return A.coordsChar({left:0,top:b},"div")},Pt)},goLineLeftSmart:function(A){return A.extendSelectionsBy(function(h){var b=A.cursorCoords(h.head,"div").top+5,_=A.coordsChar({left:0,top:b},"div");return _.ch<A.getLine(_.line).search(/\S/)?qm(A,h.head):_},Pt)},goLineUp:function(A){return A.moveV(-1,"line")},goLineDown:function(A){return A.moveV(1,"line")},goPageUp:function(A){return A.moveV(-1,"page")},goPageDown:function(A){return A.moveV(1,"page")},goCharLeft:function(A){return A.moveH(-1,"char")},goCharRight:function(A){return A.moveH(1,"char")},goColumnLeft:function(A){return A.moveH(-1,"column")},goColumnRight:function(A){return A.moveH(1,"column")},goWordLeft:function(A){return A.moveH(-1,"word")},goGroupRight:function(A){return A.moveH(1,"group")},goGroupLeft:function(A){return A.moveH(-1,"group")},goWordRight:function(A){return A.moveH(1,"word")},delCharBefore:function(A){return A.deleteH(-1,"codepoint")},delCharAfter:function(A){return A.deleteH(1,"char")},delWordBefore:function(A){return A.deleteH(-1,"word")},delWordAfter:function(A){return A.deleteH(1,"word")},delGroupBefore:function(A){return A.deleteH(-1,"group")},delGroupAfter:function(A){return A.deleteH(1,"group")},indentAuto:function(A){return A.indentSelection("smart")},indentMore:function(A){return A.indentSelection("add")},indentLess:function(A){return A.indentSelection("subtract")},insertTab:function(A){return A.replaceSelection(" ")},insertSoftTab:function(A){for(var h=[],b=A.listSelections(),_=A.options.tabSize,E=0;E<b.length;E++){var U=b[E].from(),Y=de(A.getLine(U.line),U.ch,_);h.push(pn(_-Y%_))}A.replaceSelections(h)},defaultTab:function(A){A.somethingSelected()?A.indentSelection("add"):A.execCommand("insertTab")},transposeChars:function(A){return wa(A,function(){for(var h=A.listSelections(),b=[],_=0;_<h.length;_++)if(h[_].empty()){var E=h[_].head,U=rr(A.doc,E.line).text;if(U){if(E.ch==U.length&&(E=new Ot(E.line,E.ch-1)),E.ch>0)E=new Ot(E.line,E.ch+1),A.replaceRange(U.charAt(E.ch-1)+U.charAt(E.ch-2),Ot(E.line,E.ch-2),E,"+transpose");else if(E.line>A.doc.first){var Y=rr(A.doc,E.line-1).text;Y&&(E=new Ot(E.line,1),A.replaceRange(U.charAt(0)+A.doc.lineSeparator()+Y.charAt(Y.length-1),Ot(E.line-1,Y.length-1),E,"+transpose"))}}b.push(new De(E,E))}A.setSelections(b)})},newlineAndIndent:function(A){return wa(A,function(){for(var h=A.listSelections(),b=h.length-1;b>=0;b--)A.replaceRange(A.doc.lineSeparator(),h[b].anchor,h[b].head,"+input");h=A.listSelections();for(var _=0;_<h.length;_++)A.indentLine(h[_].from().line,null,!0);oa(A)})},openLine:function(A){return A.replaceSelection(`
|
||
`,"start")},toggleOverwrite:function(A){return A.toggleOverwrite()}};function Cc(A,h){var b=rr(A.doc,h),_=qr(b);return _!=b&&(h=ve(_)),Pf(!0,A,_,h,1)}function P1(A,h){var b=rr(A.doc,h),_=Yi(b);return _!=b&&(h=ve(_)),Pf(!0,A,b,h,-1)}function qm(A,h){var b=Cc(A,h.line),_=rr(A.doc,b.line),E=on(_,A.doc.direction);if(!E||E[0].level==0){var U=Math.max(b.ch,_.text.search(/\S/)),Y=h.line==b.line&&h.ch<=U&&h.ch;return Ot(b.line,Y?0:U,b.sticky)}return b}function Dh(A,h,b){if(typeof h=="string"&&(h=Ff[h],!h))return!1;A.display.input.ensurePolled();var _=A.display.shift,E=!1;try{A.isReadOnly()&&(A.state.suppressEdits=!0),b&&(A.display.shift=!1),E=h(A)!=Xe}finally{A.display.shift=_,A.state.suppressEdits=!1}return E}function Vm(A,h,b){for(var _=0;_<A.state.keyMaps.length;_++){var E=pu(h,A.state.keyMaps[_],b,A);if(E)return E}return A.options.extraKeys&&pu(h,A.options.extraKeys,b,A)||pu(h,A.options.keyMap,b,A)}var tv=new xe;function TA(A,h,b,_){var E=A.state.keySeq;if(E){if(Tp(h))return"handled";if(/\'$/.test(h)?A.state.keySeq=null:tv.set(50,function(){A.state.keySeq==E&&(A.state.keySeq=null,A.display.input.reset())}),Hm(A,E+" "+h,b,_))return!0}return Hm(A,h,b,_)}function Hm(A,h,b,_){var E=Vm(A,h,_);return E=="multi"&&(A.state.keySeq=h),E=="handled"&&Ur(A,"keyHandled",A,h,b),(E=="handled"||E=="multi")&&(Te(b),sc(A)),!!E}function Aa(A,h){var b=Yd(h,!0);return b?h.shiftKey&&!A.state.keySeq?TA(A,"Shift-"+b,h,function(_){return Dh(A,_,!0)})||TA(A,b,h,function(_){if(typeof _=="string"?/^go[A-Z]/.test(_):_.motion)return Dh(A,_)}):TA(A,b,h,function(_){return Dh(A,_)}):!1}function Kp(A,h,b){return TA(A,"'"+b+"'",h,function(_){return Dh(A,_,!0)})}var Df=null;function Uh(A){var h=this;if(!(A.target&&A.target!=h.display.input.getField())&&(h.curOp.focus=Nt(pt(h)),!Ke(h,A))){f&&g<11&&A.keyCode==27&&(A.returnValue=!1);var b=A.keyCode;h.display.shift=b==16||A.shiftKey;var _=Aa(h,A);R&&(Df=_?b:null,!_&&b==88&&!vr&&(ce?A.metaKey:A.ctrlKey)&&h.replaceSelection("",null,"cut")),i&&!ce&&!_&&b==46&&A.shiftKey&&!A.ctrlKey&&document.execCommand&&document.execCommand("cut"),b==18&&!/\bCodeMirror-crosshair\b/.test(h.display.lineDiv.className)&&el(h)}}function el(A){var h=A.display.lineDiv;Ve(h,"CodeMirror-crosshair");function b(_){(_.keyCode==18||!_.altKey)&&(ct(h,"CodeMirror-crosshair"),Gn(document,"keyup",b),Gn(document,"mouseover",b))}un(document,"keyup",b),un(document,"mouseover",b)}function Tl(A){A.keyCode==16&&(this.doc.sel.shift=!1),Ke(this,A)}function Zm(A){var h=this;if(!(A.target&&A.target!=h.display.input.getField())&&!(xl(h.display,A)||Ke(h,A)||A.ctrlKey&&!A.altKey||ce&&A.metaKey)){var b=A.keyCode,_=A.charCode;if(R&&b==Df){Df=null,Te(A);return}if(!(R&&(!A.which||A.which<10)&&Aa(h,A))){var E=String.fromCharCode(_??b);E!="\b"&&(Kp(h,A,E)||h.display.input.onKeyPress(A))}}}var F1=400,KA=function(A,h,b){this.time=A,this.pos=h,this.button=b};KA.prototype.compare=function(A,h,b){return this.time+F1>A&&En(h,this.pos)==0&&b==this.button};var Du,ld;function Xm(A,h){var b=+new Date;return ld&&ld.compare(b,A,h)?(Du=ld=null,"triple"):Du&&Du.compare(b,A,h)?(ld=new KA(b,A,h),Du=null,"double"):(Du=new KA(b,A,h),ld=null,"single")}function D1(A){var h=this,b=h.display;if(!(Ke(h,A)||b.activeTouch&&b.input.supportsTouch())){if(b.input.ensurePolled(),b.shift=A.shiftKey,xl(b,A)){x||(b.scroller.draggable=!1,setTimeout(function(){return b.scroller.draggable=!0},100));return}if(!qd(h,A)){var _=Al(h,A),E=Ct(A),U=_?Xm(_,E):"single";kt(h).focus(),E==1&&h.state.selectingText&&h.state.selectingText(A),!(_&&Jm(h,E,_,U,A))&&(E==1?_?Uf(h,_,U,A):et(A)==b.scroller&&Te(A):E==2?(_&&ws(h.doc,_),setTimeout(function(){return b.input.focus()},20)):E==3&&(Ne?h.display.input.onContextMenu(A):lc(h)))}}}function Jm(A,h,b,_,E){var U="Click";return _=="double"?U="Double"+U:_=="triple"&&(U="Triple"+U),U=(h==1?"Left":h==2?"Middle":"Right")+U,TA(A,Ym(U,E),E,function(Y){if(typeof Y=="string"&&(Y=Ff[Y]),!Y)return!1;var J=!1;try{A.isReadOnly()&&(A.state.suppressEdits=!0),J=Y(A,b)!=Xe}finally{A.state.suppressEdits=!1}return J})}function PA(A,h,b){var _=A.getOption("configureMouse"),E=_?_(A,h,b):{};if(E.unit==null){var U=ae?b.shiftKey&&b.metaKey:b.altKey;E.unit=U?"rectangle":h=="single"?"char":h=="double"?"word":"line"}return(E.extend==null||A.doc.extend)&&(E.extend=A.doc.extend||b.shiftKey),E.addNew==null&&(E.addNew=ce?b.metaKey:b.ctrlKey),E.moveOnDrag==null&&(E.moveOnDrag=!(ce?b.altKey:b.ctrlKey)),E}function Uf(A,h,b,_){f?setTimeout(Dt(Vl,A),0):A.curOp.focus=Nt(pt(A));var E=PA(A,b,_),U=A.doc.sel,Y;A.options.dragDrop&&rn&&!A.isReadOnly()&&b=="single"&&(Y=U.contains(h))>-1&&(En((Y=U.ranges[Y]).from(),h)<0||h.xRel>0)&&(En(Y.to(),h)>0||h.xRel<0)?e0(A,_,h,E):Pp(A,_,h,E)}function e0(A,h,b,_){var E=A.display,U=!1,Y=uo(A,function(pe){x&&(E.scroller.draggable=!1),A.state.draggingText=!1,A.state.delayingBlurEvent&&(A.hasFocus()?A.state.delayingBlurEvent=!1:lc(A)),Gn(E.wrapper.ownerDocument,"mouseup",Y),Gn(E.wrapper.ownerDocument,"mousemove",J),Gn(E.scroller,"dragstart",se),Gn(E.scroller,"drop",Y),U||(Te(pe),_.addNew||ws(A.doc,b,null,null,_.extend),x&&!H||f&&g==9?setTimeout(function(){E.wrapper.ownerDocument.body.focus({preventScroll:!0}),E.input.focus()},20):E.input.focus())}),J=function(pe){U=U||Math.abs(h.clientX-pe.clientX)+Math.abs(h.clientY-pe.clientY)>=10},se=function(){return U=!0};x&&(E.scroller.draggable=!0),A.state.draggingText=Y,Y.copy=!_.moveOnDrag,un(E.wrapper.ownerDocument,"mouseup",Y),un(E.wrapper.ownerDocument,"mousemove",J),un(E.scroller,"dragstart",se),un(E.scroller,"drop",Y),A.state.delayingBlurEvent=!0,setTimeout(function(){return E.input.focus()},20),E.scroller.dragDrop&&E.scroller.dragDrop()}function t0(A,h,b){if(b=="char")return new De(h,h);if(b=="word")return A.findWordAt(h);if(b=="line")return new De(Ot(h.line,0),br(A.doc,Ot(h.line+1,0)));var _=b(A,h);return new De(_.from,_.to)}function Pp(A,h,b,_){f&&lc(A);var E=A.display,U=A.doc;Te(h);var Y,J,se=U.sel,pe=se.ranges;if(_.addNew&&!_.extend?(J=U.sel.contains(b),J>-1?Y=pe[J]:Y=new De(b,b)):(Y=U.sel.primary(),J=U.sel.primIndex),_.unit=="rectangle")_.addNew||(Y=new De(b,b)),b=Al(A,h,!0,!0),J=-1;else{var We=t0(A,b,_.unit);_.extend?Y=no(Y,We.anchor,We.head,_.extend):Y=We}_.addNew?J==-1?(J=pe.length,ji(U,je(A,pe.concat([Y]),J),{scroll:!1,origin:"*mouse"})):pe.length>1&&pe[J].empty()&&_.unit=="char"&&!_.extend?(ji(U,je(A,pe.slice(0,J).concat(pe.slice(J+1)),0),{scroll:!1,origin:"*mouse"}),se=U.sel):Ms(U,J,Y,Kt):(J=0,ji(U,new Me([Y],0),Kt),se=U.sel);var Ye=b;function Mt(fn){if(En(Ye,fn)!=0)if(Ye=fn,_.unit=="rectangle"){for(var ar=[],Ir=A.options.tabSize,Br=de(rr(U,b.line).text,b.ch,Ir),Xr=de(rr(U,fn.line).text,fn.ch,Ir),fo=Math.min(Br,Xr),Ea=Math.max(Br,Xr),ca=Math.min(b.line,fn.line),Oa=Math.min(A.lastLine(),Math.max(b.line,fn.line));ca<=Oa;ca++){var Va=rr(U,ca).text,Ha=zn(Va,fo,Ir);fo==Ea?ar.push(new De(Ot(ca,Ha),Ot(ca,Ha))):Va.length>Ha&&ar.push(new De(Ot(ca,Ha),Ot(ca,zn(Va,Ea,Ir))))}ar.length||ar.push(new De(b,b)),ji(U,je(A,se.ranges.slice(0,J).concat(ar),J),{origin:"*mouse",scroll:!1}),A.scrollIntoView(fn)}else{var fl=Y,zs=t0(A,fn,_.unit),ds=fl.anchor,Za;En(zs.anchor,ds)>0?(Za=zs.head,ds=po(fl.from(),zs.anchor)):(Za=zs.anchor,ds=Ti(fl.to(),zs.head));var Ba=se.ranges.slice(0);Ba[J]=Rh(A,new De(br(U,ds),Za)),ji(U,je(A,Ba,J),Kt)}}var yt=E.wrapper.getBoundingClientRect(),qt=0;function Zt(fn){var ar=++qt,Ir=Al(A,fn,!0,_.unit=="rectangle");if(Ir)if(En(Ir,Ye)!=0){A.curOp.focus=Nt(pt(A)),Mt(Ir);var Br=go(E,U);(Ir.line>=Br.to||Ir.line<Br.from)&&setTimeout(uo(A,function(){qt==ar&&Zt(fn)}),150)}else{var Xr=fn.clientY<yt.top?-20:fn.clientY>yt.bottom?20:0;Xr&&setTimeout(uo(A,function(){qt==ar&&(E.scroller.scrollTop+=Xr,Zt(fn))}),50)}}function Bn(fn){A.state.selectingText=!1,qt=1/0,fn&&(Te(fn),E.input.focus()),Gn(E.wrapper.ownerDocument,"mousemove",Wn),Gn(E.wrapper.ownerDocument,"mouseup",er),U.history.lastSelOrigin=null}var Wn=uo(A,function(fn){fn.buttons===0||!Ct(fn)?Bn(fn):Zt(fn)}),er=uo(A,Bn);A.state.selectingText=er,un(E.wrapper.ownerDocument,"mousemove",Wn),un(E.wrapper.ownerDocument,"mouseup",er)}function Rh(A,h){var b=h.anchor,_=h.head,E=rr(A.doc,b.line);if(En(b,_)==0&&b.sticky==_.sticky)return h;var U=on(E);if(!U)return h;var Y=Lt(U,b.ch,b.sticky),J=U[Y];if(J.from!=b.ch&&J.to!=b.ch)return h;var se=Y+(J.from==b.ch==(J.level!=1)?0:1);if(se==0||se==U.length)return h;var pe;if(_.line!=b.line)pe=(_.line-b.line)*(A.doc.direction=="ltr"?1:-1)>0;else{var We=Lt(U,_.ch,_.sticky),Ye=We-Y||(_.ch-b.ch)*(J.level==1?-1:1);We==se-1||We==se?pe=Ye<0:pe=Ye>0}var Mt=U[se+(pe?-1:0)],yt=pe==(Mt.level==1),qt=yt?Mt.from:Mt.to,Zt=yt?"after":"before";return b.ch==qt&&b.sticky==Zt?h:new De(new Ot(b.line,qt,Zt),_)}function Rf(A,h,b,_){var E,U;if(h.touches)E=h.touches[0].clientX,U=h.touches[0].clientY;else try{E=h.clientX,U=h.clientY}catch{return!1}if(E>=Math.floor(A.display.gutters.getBoundingClientRect().right))return!1;_&&Te(h);var Y=A.display,J=Y.lineDiv.getBoundingClientRect();if(U>J.bottom||!_e(A,b))return it(h);U-=J.top-Y.viewOffset;for(var se=0;se<A.display.gutterSpecs.length;++se){var pe=Y.gutters.childNodes[se];if(pe&&pe.getBoundingClientRect().right>=E){var We=Ge(A.doc,U),Ye=A.display.gutterSpecs[se];return Zn(A,b,A,We,Ye.className,h),it(h)}}}function qd(A,h){return Rf(A,h,"gutterClick",!0)}function Lf(A,h){xl(A.display,h)||Fp(A,h)||Ke(A,h,"contextmenu")||Ne||A.display.input.onContextMenu(h)}function Fp(A,h){return _e(A,"gutterContextMenu")?Rf(A,h,"gutterContextMenu",!1):!1}function U1(A){A.display.wrapper.className=A.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+A.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Sl(A)}var Vd={toString:function(){return"CodeMirror.Init"}},zf={},jf={};function FA(A){var h=A.optionHandlers;function b(_,E,U,Y){A.defaults[_]=E,U&&(h[_]=Y?function(J,se,pe){pe!=Vd&&U(J,se,pe)}:U)}A.defineOption=b,A.Init=Vd,b("value","",function(_,E){return _.setValue(E)},!0),b("mode",null,function(_,E){_.doc.modeOption=E,Ut(_)},!0),b("indentUnit",2,Ut,!0),b("indentWithTabs",!1),b("smartIndent",!0),b("tabSize",4,function(_){Tt(_),Sl(_),us(_)},!0),b("lineSeparator",null,function(_,E){if(_.doc.lineSep=E,!!E){var U=[],Y=_.doc.first;_.doc.iter(function(se){for(var pe=0;;){var We=se.text.indexOf(E,pe);if(We==-1)break;pe=We+E.length,U.push(Ot(Y,We))}Y++});for(var J=U.length-1;J>=0;J--)BA(_.doc,E,U[J],Ot(U[J].line,U[J].ch+E.length))}}),b("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\u202d\u202e\u2066\u2067\u2069\ufeff\ufff9-\ufffc]/g,function(_,E,U){_.state.specialChars=new RegExp(E.source+(E.test(" ")?"":"| "),"g"),U!=Vd&&_.refresh()}),b("specialCharPlaceholder",cu,function(_){return _.refresh()},!0),b("electricChars",!0),b("inputStyle",ne?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),b("spellcheck",!1,function(_,E){return _.getInputField().spellcheck=E},!0),b("autocorrect",!1,function(_,E){return _.getInputField().autocorrect=E},!0),b("autocapitalize",!1,function(_,E){return _.getInputField().autocapitalize=E},!0),b("rtlMoveVisually",!ue),b("wholeLineUpdateBefore",!0),b("theme","default",function(_){U1(_),I(_)},!0),b("keyMap","default",function(_,E,U){var Y=ad(E),J=U!=Vd&&ad(U);J&&J.detach&&J.detach(_,Y),Y.attach&&Y.attach(_,J||null)}),b("extraKeys",null),b("configureMouse",null),b("lineWrapping",!1,n0,!0),b("gutters",[],function(_,E){_.display.gutterSpecs=C(E,_.options.lineNumbers),I(_)},!0),b("fixedGutter",!0,function(_,E){_.display.gutters.style.left=E?Ei(_.display)+"px":"0",_.refresh()},!0),b("coverGutterNextToScrollbar",!1,function(_){return Iu(_)},!0),b("scrollbarStyle","native",function(_){zo(_),Iu(_),_.display.scrollbars.setScrollTop(_.doc.scrollTop),_.display.scrollbars.setScrollLeft(_.doc.scrollLeft)},!0),b("lineNumbers",!1,function(_,E){_.display.gutterSpecs=C(_.options.gutters,E),I(_)},!0),b("firstLineNumber",1,I,!0),b("lineNumberFormatter",function(_){return _},I,!0),b("showCursorWhenSelecting",!1,cl,!0),b("resetSelectionOnContextMenu",!0),b("lineWiseCopyCut",!0),b("pasteLinesPerSelection",!0),b("selectionsMayTouch",!1),b("readOnly",!1,function(_,E){E=="nocursor"&&(Zc(_),_.display.input.blur()),_.display.input.readOnlyChanged(E)}),b("screenReaderLabel",null,function(_,E){E=E===""?null:E,_.display.input.screenReaderLabelChanged(E)}),b("disableInput",!1,function(_,E){E||_.display.input.reset()},!0),b("dragDrop",!0,nv),b("allowDropFileTypes",null),b("cursorBlinkRate",530),b("cursorScrollMargin",0),b("cursorHeight",1,cl,!0),b("singleCursorHeightPerLine",!0,cl,!0),b("workTime",100),b("workDelay",100),b("flattenSpans",!0,Tt,!0),b("addModeClass",!1,Tt,!0),b("pollInterval",100),b("undoDepth",200,function(_,E){return _.doc.history.undoDepth=E}),b("historyEventDelay",1250),b("viewportMargin",10,function(_){return _.refresh()},!0),b("maxHighlightLength",1e4,Tt,!0),b("moveInputWithCursor",!0,function(_,E){E||_.display.input.resetPosition()}),b("tabindex",null,function(_,E){return _.display.input.getField().tabIndex=E||""}),b("autofocus",null),b("direction","ltr",function(_,E){return _.doc.setDirection(E)},!0),b("phrases",null)}function nv(A,h,b){var _=b&&b!=Vd;if(!h!=!_){var E=A.display.dragFunctions,U=h?un:Gn;U(A.display.scroller,"dragstart",E.start),U(A.display.scroller,"dragenter",E.enter),U(A.display.scroller,"dragover",E.over),U(A.display.scroller,"dragleave",E.leave),U(A.display.scroller,"drop",E.drop)}}function n0(A){A.options.lineWrapping?(Ve(A.display.wrapper,"CodeMirror-wrap"),A.display.sizer.style.minWidth="",A.display.sizerWidth=null):(ct(A.display.wrapper,"CodeMirror-wrap"),_s(A)),Mh(A),us(A),Sl(A),setTimeout(function(){return Iu(A)},100)}function qi(A,h){var b=this;if(!(this instanceof qi))return new qi(A,h);this.options=h=h?Se(h):{},Se(zf,h,!1);var _=h.value;typeof _=="string"?_=new Js(_,h.mode,null,h.lineSeparator,h.direction):h.mode&&(_.modeOption=h.mode),this.doc=_;var E=new qi.inputStyles[h.inputStyle](this),U=this.display=new L(A,_,E,h);U.wrapper.CodeMirror=this,U1(this),h.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),zo(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new xe,keySeq:null,specialChars:null},h.autofocus&&!ne&&U.input.focus(),f&&g<11&&setTimeout(function(){return b.display.input.reset(!0)},20),R1(this),T1(),du(this),this.curOp.forceUpdate=!0,On(this,_),h.autofocus&&!ne||this.hasFocus()?setTimeout(function(){b.hasFocus()&&!b.state.focused&&Sh(b)},20):Zc(this);for(var Y in jf)jf.hasOwnProperty(Y)&&jf[Y](this,h[Y],Vd);p(this),h.finishInit&&h.finishInit(this);for(var J=0;J<Dp.length;++J)Dp[J](this);Tu(this),x&&h.lineWrapping&&getComputedStyle(U.lineDiv).textRendering=="optimizelegibility"&&(U.lineDiv.style.textRendering="auto")}qi.defaults=zf,qi.optionHandlers=jf;function R1(A){var h=A.display;un(h.scroller,"mousedown",uo(A,D1)),f&&g<11?un(h.scroller,"dblclick",uo(A,function(se){if(!Ke(A,se)){var pe=Al(A,se);if(!(!pe||qd(A,se)||xl(A.display,se))){Te(se);var We=A.findWordAt(pe);ws(A.doc,We.anchor,We.head)}}})):un(h.scroller,"dblclick",function(se){return Ke(A,se)||Te(se)}),un(h.scroller,"contextmenu",function(se){return Lf(A,se)}),un(h.input.getField(),"contextmenu",function(se){h.scroller.contains(se.target)||Lf(A,se)});var b,_={end:0};function E(){h.activeTouch&&(b=setTimeout(function(){return h.activeTouch=null},1e3),_=h.activeTouch,_.end=+new Date)}function U(se){if(se.touches.length!=1)return!1;var pe=se.touches[0];return pe.radiusX<=1&&pe.radiusY<=1}function Y(se,pe){if(pe.left==null)return!0;var We=pe.left-se.left,Ye=pe.top-se.top;return We*We+Ye*Ye>20*20}un(h.scroller,"touchstart",function(se){if(!Ke(A,se)&&!U(se)&&!qd(A,se)){h.input.ensurePolled(),clearTimeout(b);var pe=+new Date;h.activeTouch={start:pe,moved:!1,prev:pe-_.end<=300?_:null},se.touches.length==1&&(h.activeTouch.left=se.touches[0].pageX,h.activeTouch.top=se.touches[0].pageY)}}),un(h.scroller,"touchmove",function(){h.activeTouch&&(h.activeTouch.moved=!0)}),un(h.scroller,"touchend",function(se){var pe=h.activeTouch;if(pe&&!xl(h,se)&&pe.left!=null&&!pe.moved&&new Date-pe.start<300){var We=A.coordsChar(h.activeTouch,"page"),Ye;!pe.prev||Y(pe,pe.prev)?Ye=new De(We,We):!pe.prev.prev||Y(pe,pe.prev.prev)?Ye=A.findWordAt(We):Ye=new De(Ot(We.line,0),br(A.doc,Ot(We.line+1,0))),A.setSelection(Ye.anchor,Ye.head),A.focus(),Te(se)}E()}),un(h.scroller,"touchcancel",E),un(h.scroller,"scroll",function(){h.scroller.clientHeight&&(SA(A,h.scroller.scrollTop),dl(A,h.scroller.scrollLeft,!0),Zn(A,"scroll",A))}),un(h.scroller,"mousewheel",function(se){return he(A,se)}),un(h.scroller,"DOMMouseScroll",function(se){return he(A,se)}),un(h.wrapper,"scroll",function(){return h.wrapper.scrollTop=h.wrapper.scrollLeft=0}),h.dragFunctions={enter:function(se){Ke(A,se)||ht(se)},over:function(se){Ke(A,se)||(Qi(A,se),ht(se))},start:function(se){return Fh(A,se)},drop:uo(A,ev),leave:function(se){Ke(A,se)||Nm(A)}};var J=h.input.getField();un(J,"keyup",function(se){return Tl.call(A,se)}),un(J,"keydown",uo(A,Uh)),un(J,"keypress",uo(A,Zm)),un(J,"focus",function(se){return Sh(A,se)}),un(J,"blur",function(se){return Zc(A,se)})}var Dp=[];qi.defineInitHook=function(A){return Dp.push(A)};function Wf(A,h,b,_){var E=A.doc,U;b==null&&(b="add"),b=="smart"&&(E.mode.indent?U=va(A,h).state:b="prev");var Y=A.options.tabSize,J=rr(E,h),se=de(J.text,null,Y);J.stateAfter&&(J.stateAfter=null);var pe=J.text.match(/^\s*/)[0],We;if(!_&&!/\S/.test(J.text))We=0,b="not";else if(b=="smart"&&(We=E.mode.indent(U,J.text.slice(pe.length),J.text),We==Xe||We>150)){if(!_)return;b="prev"}b=="prev"?h>E.first?We=de(rr(E,h-1).text,null,Y):We=0:b=="add"?We=se+A.options.indentUnit:b=="subtract"?We=se-A.options.indentUnit:typeof b=="number"&&(We=se+b),We=Math.max(0,We);var Ye="",Mt=0;if(A.options.indentWithTabs)for(var yt=Math.floor(We/Y);yt;--yt)Mt+=Y,Ye+=" ";if(Mt<We&&(Ye+=pn(We-Mt)),Ye!=pe)return BA(E,Ye,Ot(h,0),Ot(h,pe.length),"+input"),J.stateAfter=null,!0;for(var qt=0;qt<E.sel.ranges.length;qt++){var Zt=E.sel.ranges[qt];if(Zt.head.line==h&&Zt.head.ch<pe.length){var Bn=Ot(h,pe.length);Ms(E,qt,new De(Bn,Bn));break}}}var mu=null;function Nf(A){mu=A}function r0(A,h,b,_,E){var U=A.doc;A.display.shift=!1,_||(_=U.sel);var Y=+new Date-200,J=E=="paste"||A.state.pasteIncoming>Y,se=qn(h),pe=null;if(J&&_.ranges.length>1)if(mu&&mu.text.join(`
|
||
`)==h){if(_.ranges.length%mu.text.length==0){pe=[];for(var We=0;We<mu.text.length;We++)pe.push(U.splitLines(mu.text[We]))}}else se.length==_.ranges.length&&A.options.pasteLinesPerSelection&&(pe=Sn(se,function(Wn){return[Wn]}));for(var Ye=A.curOp.updateInput,Mt=_.ranges.length-1;Mt>=0;Mt--){var yt=_.ranges[Mt],qt=yt.from(),Zt=yt.to();yt.empty()&&(b&&b>0?qt=Ot(qt.line,qt.ch-b):A.state.overwrite&&!J?Zt=Ot(Zt.line,Math.min(rr(U,Zt.line).text.length,Zt.ch+ir(se).length)):J&&mu&&mu.lineWise&&mu.text.join(`
|
||
`)==se.join(`
|
||
`)&&(qt=Zt=Ot(qt.line,0)));var Bn={from:qt,to:Zt,text:pe?pe[Mt%pe.length]:se,origin:E||(J?"paste":A.state.cutIncoming>Y?"cut":"+input")};fc(A.doc,Bn),Ur(A,"inputRead",A,Bn)}h&&!J&&Up(A,h),oa(A),A.curOp.updateInput<2&&(A.curOp.updateInput=Ye),A.curOp.typing=!0,A.state.pasteIncoming=A.state.cutIncoming=-1}function DA(A,h){var b=A.clipboardData&&A.clipboardData.getData("Text");if(b)return A.preventDefault(),!h.isReadOnly()&&!h.options.disableInput&&h.hasFocus()&&wa(h,function(){return r0(h,b,0,null,"paste")}),!0}function Up(A,h){if(!(!A.options.electricChars||!A.options.smartIndent))for(var b=A.doc.sel,_=b.ranges.length-1;_>=0;_--){var E=b.ranges[_];if(!(E.head.ch>100||_&&b.ranges[_-1].head.line==E.head.line)){var U=A.getModeAt(E.head),Y=!1;if(U.electricChars){for(var J=0;J<U.electricChars.length;J++)if(h.indexOf(U.electricChars.charAt(J))>-1){Y=Wf(A,E.head.line,"smart");break}}else U.electricInput&&U.electricInput.test(rr(A.doc,E.head.line).text.slice(0,E.head.ch))&&(Y=Wf(A,E.head.line,"smart"));Y&&Ur(A,"electricInput",A,E.head.line)}}}function Rp(A){for(var h=[],b=[],_=0;_<A.doc.sel.ranges.length;_++){var E=A.doc.sel.ranges[_].head.line,U={anchor:Ot(E,0),head:Ot(E+1,0)};b.push(U),h.push(A.getRange(U.anchor,U.head))}return{text:h,ranges:b}}function Hd(A,h,b,_){A.setAttribute("autocorrect",b?"on":"off"),A.setAttribute("autocapitalize",_?"on":"off"),A.setAttribute("spellcheck",!!h)}function _c(){var A=Ce("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; min-height: 1em; outline: none"),h=Ce("div",[A],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return x?A.style.width="1000px":A.setAttribute("wrap","off"),q&&(A.style.border="1px solid black"),h}function ud(A){var h=A.optionHandlers,b=A.helpers={};A.prototype={constructor:A,focus:function(){kt(this).focus(),this.display.input.focus()},setOption:function(_,E){var U=this.options,Y=U[_];U[_]==E&&_!="mode"||(U[_]=E,h.hasOwnProperty(_)&&uo(this,h[_])(this,E,Y),Zn(this,"optionChange",this,_))},getOption:function(_){return this.options[_]},getDoc:function(){return this.doc},addKeyMap:function(_,E){this.state.keyMaps[E?"push":"unshift"](ad(_))},removeKeyMap:function(_){for(var E=this.state.keyMaps,U=0;U<E.length;++U)if(E[U]==_||E[U].name==_)return E.splice(U,1),!0},addOverlay:jr(function(_,E){var U=_.token?_:A.getMode(this.options,_);if(U.startState)throw new Error("Overlays may not be stateful.");nr(this.state.overlays,{mode:U,modeSpec:_,opaque:E&&E.opaque,priority:E&&E.priority||0},function(Y){return Y.priority}),this.state.modeGen++,us(this)}),removeOverlay:jr(function(_){for(var E=this.state.overlays,U=0;U<E.length;++U){var Y=E[U].modeSpec;if(Y==_||typeof _=="string"&&Y.name==_){E.splice(U,1),this.state.modeGen++,us(this);return}}}),indentLine:jr(function(_,E,U){typeof E!="string"&&typeof E!="number"&&(E==null?E=this.options.smartIndent?"smart":"prev":E=E?"add":"subtract"),Ht(this.doc,_)&&Wf(this,_,E,U)}),indentSelection:jr(function(_){for(var E=this.doc.sel.ranges,U=-1,Y=0;Y<E.length;Y++){var J=E[Y];if(J.empty())J.head.line>U&&(Wf(this,J.head.line,_,!0),U=J.head.line,Y==this.doc.sel.primIndex&&oa(this));else{var se=J.from(),pe=J.to(),We=Math.max(U,se.line);U=Math.min(this.lastLine(),pe.line-(pe.ch?0:1))+1;for(var Ye=We;Ye<U;++Ye)Wf(this,Ye,_);var Mt=this.doc.sel.ranges;se.ch==0&&E.length==Mt.length&&Mt[Y].from().ch>0&&Ms(this.doc,Y,new De(se,Mt[Y].to()),wt)}}}),getTokenAt:function(_,E){return CA(this,_,E)},getLineTokens:function(_,E){return CA(this,Ot(_),E,!0)},getTokenTypeAt:function(_){_=br(this.doc,_);var E=Vs(this,rr(this.doc,_.line)),U=0,Y=(E.length-1)/2,J=_.ch,se;if(J==0)se=E[2];else for(;;){var pe=U+Y>>1;if((pe?E[pe*2-1]:0)>=J)Y=pe;else if(E[pe*2+1]<J)U=pe+1;else{se=E[pe*2+2];break}}var We=se?se.indexOf("overlay "):-1;return We<0?se:We==0?null:se.slice(0,We-1)},getModeAt:function(_){var E=this.doc.mode;return E.innerMode?A.innerMode(E,this.getTokenAt(_).state).mode:E},getHelper:function(_,E){return this.getHelpers(_,E)[0]},getHelpers:function(_,E){var U=[];if(!b.hasOwnProperty(E))return U;var Y=b[E],J=this.getModeAt(_);if(typeof J[E]=="string")Y[J[E]]&&U.push(Y[J[E]]);else if(J[E])for(var se=0;se<J[E].length;se++){var pe=Y[J[E][se]];pe&&U.push(pe)}else J.helperType&&Y[J.helperType]?U.push(Y[J.helperType]):Y[J.name]&&U.push(Y[J.name]);for(var We=0;We<Y._global.length;We++){var Ye=Y._global[We];Ye.pred(J,this)&&Pe(U,Ye.val)==-1&&U.push(Ye.val)}return U},getStateAfter:function(_,E){var U=this.doc;return _=Cl(U,_??U.first+U.size-1),va(this,_+1,E).state},cursorCoords:function(_,E){var U,Y=this.doc.sel.primary();return _==null?U=Y.head:typeof _=="object"?U=br(this.doc,_):U=_?Y.from():Y.to(),Wt(this,U,E||"page")},charCoords:function(_,E){return sn(this,br(this.doc,_),E||"page")},coordsChar:function(_,E){return _=xt(this,_,E||"page"),to(this,_.left,_.top)},lineAtHeight:function(_,E){return _=xt(this,{top:_,left:0},E||"page").top,Ge(this.doc,_+this.display.viewOffset)},heightAtLine:function(_,E,U){var Y=!1,J;if(typeof _=="number"){var se=this.doc.first+this.doc.size-1;_<this.doc.first?_=this.doc.first:_>se&&(_=se,Y=!0),J=rr(this.doc,_)}else J=_;return ku(this,J,{top:0,left:0},E||"page",U||Y).top+(Y?this.doc.height-Pa(J):0)},defaultTextHeight:function(){return Jo(this.display)},defaultCharWidth:function(){return ls(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(_,E,U,Y,J){var se=this.display;_=Wt(this,br(this.doc,_));var pe=_.bottom,We=_.left;if(E.style.position="absolute",E.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(E),se.sizer.appendChild(E),Y=="over")pe=_.top;else if(Y=="above"||Y=="near"){var Ye=Math.max(se.wrapper.clientHeight,this.doc.height),Mt=Math.max(se.sizer.clientWidth,se.lineSpace.clientWidth);(Y=="above"||_.bottom+E.offsetHeight>Ye)&&_.top>E.offsetHeight?pe=_.top-E.offsetHeight:_.bottom+E.offsetHeight<=Ye&&(pe=_.bottom),We+E.offsetWidth>Mt&&(We=Mt-E.offsetWidth)}E.style.top=pe+"px",E.style.left=E.style.right="",J=="right"?(We=se.sizer.clientWidth-E.offsetWidth,E.style.right="0px"):(J=="left"?We=0:J=="middle"&&(We=(se.sizer.clientWidth-E.offsetWidth)/2),E.style.left=We+"px"),U&&Of(this,{left:We,top:pe,right:We+E.offsetWidth,bottom:pe+E.offsetHeight})},triggerOnKeyDown:jr(Uh),triggerOnKeyPress:jr(Zm),triggerOnKeyUp:Tl,triggerOnMouseDown:jr(D1),execCommand:function(_){if(Ff.hasOwnProperty(_))return Ff[_].call(null,this)},triggerElectric:jr(function(_){Up(this,_)}),findPosH:function(_,E,U,Y){var J=1;E<0&&(J=-1,E=-E);for(var se=br(this.doc,_),pe=0;pe<E&&(se=Vr(this.doc,se,J,U,Y),!se.hitSide);++pe);return se},moveH:jr(function(_,E){var U=this;this.extendSelectionsBy(function(Y){return U.display.shift||U.doc.extend||Y.empty()?Vr(U.doc,Y.head,_,E,U.options.rtlMoveVisually):_<0?Y.from():Y.to()},Pt)}),deleteH:jr(function(_,E){var U=this.doc.sel,Y=this.doc;U.somethingSelected()?Y.replaceSelection("",null,"+delete"):yc(this,function(J){var se=Vr(Y,J.head,_,E,!1);return _<0?{from:se,to:J.head}:{from:J.head,to:se}})}),findPosV:function(_,E,U,Y){var J=1,se=Y;E<0&&(J=-1,E=-E);for(var pe=br(this.doc,_),We=0;We<E;++We){var Ye=Wt(this,pe,"div");if(se==null?se=Ye.left:Ye.left=se,pe=Gf(this,Ye,J,U),pe.hitSide)break}return pe},moveV:jr(function(_,E){var U=this,Y=this.doc,J=[],se=!this.display.shift&&!Y.extend&&Y.sel.somethingSelected();if(Y.extendSelectionsBy(function(We){if(se)return _<0?We.from():We.to();var Ye=Wt(U,We.head,"div");We.goalColumn!=null&&(Ye.left=We.goalColumn),J.push(Ye.left);var Mt=Gf(U,Ye,_,E);return E=="page"&&We==Y.sel.primary()&&Bh(U,sn(U,Mt,"div").top-Ye.top),Mt},Pt),J.length)for(var pe=0;pe<Y.sel.ranges.length;pe++)Y.sel.ranges[pe].goalColumn=J[pe]}),findWordAt:function(_){var E=this.doc,U=rr(E,_.line).text,Y=_.ch,J=_.ch;if(U){var se=this.getHelper(_,"wordChars");(_.sticky=="before"||J==U.length)&&Y?--Y:++J;for(var pe=U.charAt(Y),We=we(pe,se)?function(Ye){return we(Ye,se)}:/\s/.test(pe)?function(Ye){return/\s/.test(Ye)}:function(Ye){return!/\s/.test(Ye)&&!we(Ye)};Y>0&&We(U.charAt(Y-1));)--Y;for(;J<U.length&&We(U.charAt(J));)++J}return new De(Ot(_.line,Y),Ot(_.line,J))},toggleOverwrite:function(_){_!=null&&_==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?Ve(this.display.cursorDiv,"CodeMirror-overwrite"):ct(this.display.cursorDiv,"CodeMirror-overwrite"),Zn(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==Nt(pt(this))},isReadOnly:function(){return!!(this.options.readOnly||this.doc.cantEdit)},scrollTo:jr(function(_,E){Eo(this,_,E)}),getScrollInfo:function(){var _=this.display.scroller;return{left:_.scrollLeft,top:_.scrollTop,height:_.scrollHeight-wl(this)-this.display.barHeight,width:_.scrollWidth-wl(this)-this.display.barWidth,clientHeight:bh(this),clientWidth:Ju(this)}},scrollIntoView:jr(function(_,E){_==null?(_={from:this.doc.sel.primary().head,to:null},E==null&&(E=this.options.cursorScrollMargin)):typeof _=="number"?_={from:Ot(_,0),to:null}:_.from==null&&(_={from:_,to:null}),_.to||(_.to=_.from),_.margin=E||0,_.from.line!=null?uc(this,_):Or(this,_.from,_.to,_.margin)}),setSize:jr(function(_,E){var U=this,Y=function(se){return typeof se=="number"||/^\d+$/.test(String(se))?se+"px":se};_!=null&&(this.display.wrapper.style.width=Y(_)),E!=null&&(this.display.wrapper.style.height=Y(E)),this.options.lineWrapping&&Dd(this);var J=this.display.viewFrom;this.doc.iter(J,this.display.viewTo,function(se){if(se.widgets){for(var pe=0;pe<se.widgets.length;pe++)if(se.widgets[pe].noHScroll){Ol(U,J,"widget");break}}++J}),this.curOp.forceUpdate=!0,Zn(this,"refresh",this)}),operation:function(_){return wa(this,_)},startOperation:function(){return du(this)},endOperation:function(){return Tu(this)},refresh:jr(function(){var _=this.display.cachedTextHeight;us(this),this.curOp.forceUpdate=!0,Sl(this),Eo(this,this.doc.scrollLeft,this.doc.scrollTop),Pi(this.display),(_==null||Math.abs(_-Jo(this.display))>.5||this.options.lineWrapping)&&Mh(this),Zn(this,"refresh",this)}),swapDoc:jr(function(_){var E=this.doc;return E.cm=null,this.state.selectingText&&this.state.selectingText(),On(this,_),Sl(this),this.display.input.reset(),Eo(this,_.scrollLeft,_.scrollTop),this.curOp.forceScroll=!0,Ur(this,"swapDoc",this,E),E}),phrase:function(_){var E=this.options.phrases;return E&&Object.prototype.hasOwnProperty.call(E,_)?E[_]:_},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},Ee(A),A.registerHelper=function(_,E,U){b.hasOwnProperty(_)||(b[_]=A[_]={_global:[]}),b[_][E]=U},A.registerGlobalHelper=function(_,E,U,Y){A.registerHelper(_,E,Y),b[_]._global.push({pred:U,val:Y})}}function Vr(A,h,b,_,E){var U=h,Y=b,J=rr(A,h.line),se=E&&A.direction=="rtl"?-b:b;function pe(){var er=h.line+se;return er<A.first||er>=A.first+A.size?!1:(h=new Ot(er,h.ch,h.sticky),J=rr(A,er))}function We(er){var fn;if(_=="codepoint"){var ar=J.text.charCodeAt(h.ch+(b>0?0:-1));if(isNaN(ar))fn=null;else{var Ir=b>0?ar>=55296&&ar<56320:ar>=56320&&ar<57343;fn=new Ot(h.line,Math.max(0,Math.min(J.text.length,h.ch+b*(Ir?2:1))),-b)}}else E?fn=sd(A.cm,J,h,b):fn=vc(J,h,b);if(fn==null)if(!er&&pe())h=Pf(E,A.cm,J,h.line,se);else return!1;else h=fn;return!0}if(_=="char"||_=="codepoint")We();else if(_=="column")We(!0);else if(_=="word"||_=="group")for(var Ye=null,Mt=_=="group",yt=A.cm&&A.cm.getHelper(h,"wordChars"),qt=!0;!(b<0&&!We(!qt));qt=!1){var Zt=J.text.charAt(h.ch)||`
|
||
`,Bn=we(Zt,yt)?"w":Mt&&Zt==`
|
||
`?"n":!Mt||/\s/.test(Zt)?null:"p";if(Mt&&!qt&&!Bn&&(Bn="s"),Ye&&Ye!=Bn){b<0&&(b=1,We(),h.sticky="after");break}if(Bn&&(Ye=Bn),b>0&&!We(!qt))break}var Wn=sa(A,h,U,Y,!0);return zr(U,Wn)&&(Wn.hitSide=!0),Wn}function Gf(A,h,b,_){var E=A.doc,U=h.left,Y;if(_=="page"){var J=Math.min(A.display.wrapper.clientHeight,kt(A).innerHeight||E(A).documentElement.clientHeight),se=Math.max(J-.5*Jo(A.display),3);Y=(b>0?h.bottom:h.top)+b*se}else _=="line"&&(Y=b>0?h.bottom+3:h.top-3);for(var pe;pe=to(A,U,Y),!!pe.outside;){if(b<0?Y<=0:Y>=E.height){pe.hitSide=!0;break}Y+=b*5}return pe}var Co=function(A){this.cm=A,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new xe,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};Co.prototype.init=function(A){var h=this,b=this,_=b.cm,E=b.div=A.lineDiv;E.contentEditable=!0,Hd(E,_.options.spellcheck,_.options.autocorrect,_.options.autocapitalize);function U(J){for(var se=J.target;se;se=se.parentNode){if(se==E)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(se.className))break}return!1}un(E,"paste",function(J){!U(J)||Ke(_,J)||DA(J,_)||g<=11&&setTimeout(uo(_,function(){return h.updateFromDOM()}),20)}),un(E,"compositionstart",function(J){h.composing={data:J.data,done:!1}}),un(E,"compositionupdate",function(J){h.composing||(h.composing={data:J.data,done:!1})}),un(E,"compositionend",function(J){h.composing&&(J.data!=h.composing.data&&h.readFromDOMSoon(),h.composing.done=!0)}),un(E,"touchstart",function(){return b.forceCompositionEnd()}),un(E,"input",function(){h.composing||h.readFromDOMSoon()});function Y(J){if(!(!U(J)||Ke(_,J))){if(_.somethingSelected())Nf({lineWise:!1,text:_.getSelections()}),J.type=="cut"&&_.replaceSelection("",null,"cut");else if(_.options.lineWiseCopyCut){var se=Rp(_);Nf({lineWise:!0,text:se.text}),J.type=="cut"&&_.operation(function(){_.setSelections(se.ranges,0,wt),_.replaceSelection("",null,"cut")})}else return;if(J.clipboardData){J.clipboardData.clearData();var pe=mu.text.join(`
|
||
`);if(J.clipboardData.setData("Text",pe),J.clipboardData.getData("Text")==pe){J.preventDefault();return}}var We=_c(),Ye=We.firstChild;Hd(Ye),_.display.lineSpace.insertBefore(We,_.display.lineSpace.firstChild),Ye.value=mu.text.join(`
|
||
`);var Mt=Nt(dt(E));Je(Ye),setTimeout(function(){_.display.lineSpace.removeChild(We),Mt.focus(),Mt==E&&b.showPrimarySelection()},50)}}un(E,"copy",Y),un(E,"cut",Y)},Co.prototype.screenReaderLabelChanged=function(A){A?this.div.setAttribute("aria-label",A):this.div.removeAttribute("aria-label")},Co.prototype.prepareSelection=function(){var A=ac(this.cm,!1);return A.focus=Nt(dt(this.div))==this.div,A},Co.prototype.showSelection=function(A,h){!A||!this.cm.display.view.length||((A.focus||h)&&this.showPrimarySelection(),this.showMultipleSelections(A))},Co.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Co.prototype.showPrimarySelection=function(){var A=this.getSelection(),h=this.cm,b=h.doc.sel.primary(),_=b.from(),E=b.to();if(h.display.viewTo==h.display.viewFrom||_.line>=h.display.viewTo||E.line<h.display.viewFrom){A.removeAllRanges();return}var U=Es(h,A.anchorNode,A.anchorOffset),Y=Es(h,A.focusNode,A.focusOffset);if(!(U&&!U.bad&&Y&&!Y.bad&&En(po(U,Y),_)==0&&En(Ti(U,Y),E)==0)){var J=h.display.view,se=_.line>=h.display.viewFrom&&Ad(h,_)||{node:J[0].measure.map[2],offset:0},pe=E.line<h.display.viewTo&&Ad(h,E);if(!pe){var We=J[J.length-1].measure,Ye=We.maps?We.maps[We.maps.length-1]:We.map;pe={node:Ye[Ye.length-1],offset:Ye[Ye.length-2]-Ye[Ye.length-3]}}if(!se||!pe){A.removeAllRanges();return}var Mt=A.rangeCount&&A.getRangeAt(0),yt;try{yt=Ft(se.node,se.offset,pe.offset,pe.node)}catch{}yt&&(!i&&h.state.focused?(A.collapse(se.node,se.offset),yt.collapsed||(A.removeAllRanges(),A.addRange(yt))):(A.removeAllRanges(),A.addRange(yt)),Mt&&A.anchorNode==null?A.addRange(Mt):i&&this.startGracePeriod()),this.rememberSelection()}},Co.prototype.startGracePeriod=function(){var A=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){A.gracePeriod=!1,A.selectionChanged()&&A.cm.operation(function(){return A.cm.curOp.selectionChanged=!0})},20)},Co.prototype.showMultipleSelections=function(A){He(this.cm.display.cursorDiv,A.cursors),He(this.cm.display.selectionDiv,A.selection)},Co.prototype.rememberSelection=function(){var A=this.getSelection();this.lastAnchorNode=A.anchorNode,this.lastAnchorOffset=A.anchorOffset,this.lastFocusNode=A.focusNode,this.lastFocusOffset=A.focusOffset},Co.prototype.selectionInEditor=function(){var A=this.getSelection();if(!A.rangeCount)return!1;var h=A.getRangeAt(0).commonAncestorContainer;return Jt(this.div,h)},Co.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||Nt(dt(this.div))!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},Co.prototype.blur=function(){this.div.blur()},Co.prototype.getField=function(){return this.div},Co.prototype.supportsTouch=function(){return!0},Co.prototype.receivedFocus=function(){var A=this,h=this;this.selectionInEditor()?setTimeout(function(){return A.pollSelection()},20):wa(this.cm,function(){return h.cm.curOp.selectionChanged=!0});function b(){h.cm.state.focused&&(h.pollSelection(),h.polling.set(h.cm.options.pollInterval,b))}this.polling.set(this.cm.options.pollInterval,b)},Co.prototype.selectionChanged=function(){var A=this.getSelection();return A.anchorNode!=this.lastAnchorNode||A.anchorOffset!=this.lastAnchorOffset||A.focusNode!=this.lastFocusNode||A.focusOffset!=this.lastFocusOffset},Co.prototype.pollSelection=function(){if(!(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())){var A=this.getSelection(),h=this.cm;if(oe&&B&&this.cm.display.gutterSpecs.length&&rv(A.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(!this.composing){this.rememberSelection();var b=Es(h,A.anchorNode,A.anchorOffset),_=Es(h,A.focusNode,A.focusOffset);b&&_&&wa(h,function(){ji(h.doc,Qe(b,_),wt),(b.bad||_.bad)&&(h.curOp.selectionChanged=!0)})}}},Co.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var A=this.cm,h=A.display,b=A.doc.sel.primary(),_=b.from(),E=b.to();if(_.ch==0&&_.line>A.firstLine()&&(_=Ot(_.line-1,rr(A.doc,_.line-1).length)),E.ch==rr(A.doc,E.line).text.length&&E.line<A.lastLine()&&(E=Ot(E.line+1,0)),_.line<h.viewFrom||E.line>h.viewTo-1)return!1;var U,Y,J;_.line==h.viewFrom||(U=ic(A,_.line))==0?(Y=ve(h.view[0].line),J=h.view[0].node):(Y=ve(h.view[U].line),J=h.view[U-1].node.nextSibling);var se=ic(A,E.line),pe,We;if(se==h.view.length-1?(pe=h.viewTo-1,We=h.lineDiv.lastChild):(pe=ve(h.view[se+1].line)-1,We=h.view[se+1].node.previousSibling),!J)return!1;for(var Ye=A.doc.splitLines(i0(A,J,We,Y,pe)),Mt=lo(A.doc,Ot(Y,0),Ot(pe,rr(A.doc,pe).text.length));Ye.length>1&&Mt.length>1;)if(ir(Ye)==ir(Mt))Ye.pop(),Mt.pop(),pe--;else if(Ye[0]==Mt[0])Ye.shift(),Mt.shift(),Y++;else break;for(var yt=0,qt=0,Zt=Ye[0],Bn=Mt[0],Wn=Math.min(Zt.length,Bn.length);yt<Wn&&Zt.charCodeAt(yt)==Bn.charCodeAt(yt);)++yt;for(var er=ir(Ye),fn=ir(Mt),ar=Math.min(er.length-(Ye.length==1?yt:0),fn.length-(Mt.length==1?yt:0));qt<ar&&er.charCodeAt(er.length-qt-1)==fn.charCodeAt(fn.length-qt-1);)++qt;if(Ye.length==1&&Mt.length==1&&Y==_.line)for(;yt&&yt>_.ch&&er.charCodeAt(er.length-qt-1)==fn.charCodeAt(fn.length-qt-1);)yt--,qt++;Ye[Ye.length-1]=er.slice(0,er.length-qt).replace(/^\u200b+/,""),Ye[0]=Ye[0].slice(yt).replace(/\u200b+$/,"");var Ir=Ot(Y,yt),Br=Ot(pe,Mt.length?ir(Mt).length-qt:0);if(Ye.length>1||Ye[0]||En(Ir,Br))return BA(A.doc,Ye,Ir,Br,"+input"),!0},Co.prototype.ensurePolled=function(){this.forceCompositionEnd()},Co.prototype.reset=function(){this.forceCompositionEnd()},Co.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Co.prototype.readFromDOMSoon=function(){var A=this;this.readDOMTimeout==null&&(this.readDOMTimeout=setTimeout(function(){if(A.readDOMTimeout=null,A.composing)if(A.composing.done)A.composing=null;else return;A.updateFromDOM()},80))},Co.prototype.updateFromDOM=function(){var A=this;(this.cm.isReadOnly()||!this.pollContent())&&wa(this.cm,function(){return us(A.cm)})},Co.prototype.setUneditable=function(A){A.contentEditable="false"},Co.prototype.onKeyPress=function(A){A.charCode==0||this.composing||(A.preventDefault(),this.cm.isReadOnly()||uo(this.cm,r0)(this.cm,String.fromCharCode(A.charCode==null?A.keyCode:A.charCode),0))},Co.prototype.readOnlyChanged=function(A){this.div.contentEditable=String(A!="nocursor")},Co.prototype.onContextMenu=function(){},Co.prototype.resetPosition=function(){},Co.prototype.needsContentAttribute=!0;function Ad(A,h){var b=rc(A,h.line);if(!b||b.hidden)return null;var _=rr(A.doc,h.line),E=xh(b,_,h.line),U=on(_,A.doc.direction),Y="left";if(U){var J=Lt(U,h.ch);Y=J%2?"right":"left"}var se=ra(E.map,h.ch,Y);return se.offset=se.collapse=="right"?se.end:se.start,se}function rv(A){for(var h=A;h;h=h.parentNode)if(/CodeMirror-gutter-wrapper/.test(h.className))return!0;return!1}function Uu(A,h){return h&&(A.bad=!0),A}function i0(A,h,b,_,E){var U="",Y=!1,J=A.doc.lineSeparator(),se=!1;function pe(yt){return function(qt){return qt.id==yt}}function We(){Y&&(U+=J,se&&(U+=J),Y=se=!1)}function Ye(yt){yt&&(We(),U+=yt)}function Mt(yt){if(yt.nodeType==1){var qt=yt.getAttribute("cm-text");if(qt){Ye(qt);return}var Zt=yt.getAttribute("cm-marker"),Bn;if(Zt){var Wn=A.findMarks(Ot(_,0),Ot(E+1,0),pe(+Zt));Wn.length&&(Bn=Wn[0].find(0))&&Ye(lo(A.doc,Bn.from,Bn.to).join(J));return}if(yt.getAttribute("contenteditable")=="false")return;var er=/^(pre|div|p|li|table|br)$/i.test(yt.nodeName);if(!/^br$/i.test(yt.nodeName)&&yt.textContent.length==0)return;er&&We();for(var fn=0;fn<yt.childNodes.length;fn++)Mt(yt.childNodes[fn]);/^(pre|p)$/i.test(yt.nodeName)&&(se=!0),er&&(Y=!0)}else yt.nodeType==3&&Ye(yt.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;Mt(h),h!=b;)h=h.nextSibling,se=!1;return U}function Es(A,h,b){var _;if(h==A.display.lineDiv){if(_=A.display.lineDiv.childNodes[b],!_)return Uu(A.clipPos(Ot(A.display.viewTo-1)),!0);h=null,b=0}else for(_=h;;_=_.parentNode){if(!_||_==A.display.lineDiv)return null;if(_.parentNode&&_.parentNode==A.display.lineDiv)break}for(var E=0;E<A.display.view.length;E++){var U=A.display.view[E];if(U.node==_)return iv(U,h,b)}}function iv(A,h,b){var _=A.text.firstChild,E=!1;if(!h||!Jt(_,h))return Uu(Ot(ve(A.line),0),!0);if(h==_&&(E=!0,h=_.childNodes[b],b=0,!h)){var U=A.rest?ir(A.rest):A.line;return Uu(Ot(ve(U),U.text.length),E)}var Y=h.nodeType==3?h:null,J=h;for(!Y&&h.childNodes.length==1&&h.firstChild.nodeType==3&&(Y=h.firstChild,b&&(b=Y.nodeValue.length));J.parentNode!=_;)J=J.parentNode;var se=A.measure,pe=se.maps;function We(Bn,Wn,er){for(var fn=-1;fn<(pe?pe.length:0);fn++)for(var ar=fn<0?se.map:pe[fn],Ir=0;Ir<ar.length;Ir+=3){var Br=ar[Ir+2];if(Br==Bn||Br==Wn){var Xr=ve(fn<0?A.line:A.rest[fn]),fo=ar[Ir]+er;return(er<0||Br!=Bn)&&(fo=ar[Ir+(er?1:0)]),Ot(Xr,fo)}}}var Ye=We(Y,J,b);if(Ye)return Uu(Ye,E);for(var Mt=J.nextSibling,yt=Y?Y.nodeValue.length-b:0;Mt;Mt=Mt.nextSibling){if(Ye=We(Mt,Mt.firstChild,0),Ye)return Uu(Ot(Ye.line,Ye.ch-yt),E);yt+=Mt.textContent.length}for(var qt=J.previousSibling,Zt=b;qt;qt=qt.previousSibling){if(Ye=We(qt,qt.firstChild,-1),Ye)return Uu(Ot(Ye.line,Ye.ch+Zt),E);Zt+=qt.textContent.length}}var Ua=function(A){this.cm=A,this.prevInput="",this.pollingFast=!1,this.polling=new xe,this.hasSelection=!1,this.composing=null,this.resetting=!1};Ua.prototype.init=function(A){var h=this,b=this,_=this.cm;this.createField(A);var E=this.textarea;A.wrapper.insertBefore(this.wrapper,A.wrapper.firstChild),q&&(E.style.width="0px"),un(E,"input",function(){f&&g>=9&&h.hasSelection&&(h.hasSelection=null),b.poll()}),un(E,"paste",function(Y){Ke(_,Y)||DA(Y,_)||(_.state.pasteIncoming=+new Date,b.fastPoll())});function U(Y){if(!Ke(_,Y)){if(_.somethingSelected())Nf({lineWise:!1,text:_.getSelections()});else if(_.options.lineWiseCopyCut){var J=Rp(_);Nf({lineWise:!0,text:J.text}),Y.type=="cut"?_.setSelections(J.ranges,null,wt):(b.prevInput="",E.value=J.text.join(`
|
||
`),Je(E))}else return;Y.type=="cut"&&(_.state.cutIncoming=+new Date)}}un(E,"cut",U),un(E,"copy",U),un(A.scroller,"paste",function(Y){if(!(xl(A,Y)||Ke(_,Y))){if(!E.dispatchEvent){_.state.pasteIncoming=+new Date,b.focus();return}var J=new Event("paste");J.clipboardData=Y.clipboardData,E.dispatchEvent(J)}}),un(A.lineSpace,"selectstart",function(Y){xl(A,Y)||Te(Y)}),un(E,"compositionstart",function(){var Y=_.getCursor("from");b.composing&&b.composing.range.clear(),b.composing={start:Y,range:_.markText(Y,_.getCursor("to"),{className:"CodeMirror-composing"})}}),un(E,"compositionend",function(){b.composing&&(b.poll(),b.composing.range.clear(),b.composing=null)})},Ua.prototype.createField=function(A){this.wrapper=_c(),this.textarea=this.wrapper.firstChild;var h=this.cm.options;Hd(this.textarea,h.spellcheck,h.autocorrect,h.autocapitalize)},Ua.prototype.screenReaderLabelChanged=function(A){A?this.textarea.setAttribute("aria-label",A):this.textarea.removeAttribute("aria-label")},Ua.prototype.prepareSelection=function(){var A=this.cm,h=A.display,b=A.doc,_=ac(A);if(A.options.moveInputWithCursor){var E=Wt(A,b.sel.primary().head,"div"),U=h.wrapper.getBoundingClientRect(),Y=h.lineDiv.getBoundingClientRect();_.teTop=Math.max(0,Math.min(h.wrapper.clientHeight-10,E.top+Y.top-U.top)),_.teLeft=Math.max(0,Math.min(h.wrapper.clientWidth-10,E.left+Y.left-U.left))}return _},Ua.prototype.showSelection=function(A){var h=this.cm,b=h.display;He(b.cursorDiv,A.cursors),He(b.selectionDiv,A.selection),A.teTop!=null&&(this.wrapper.style.top=A.teTop+"px",this.wrapper.style.left=A.teLeft+"px")},Ua.prototype.reset=function(A){if(!(this.contextMenuPending||this.composing&&A)){var h=this.cm;if(this.resetting=!0,h.somethingSelected()){this.prevInput="";var b=h.getSelection();this.textarea.value=b,h.state.focused&&Je(this.textarea),f&&g>=9&&(this.hasSelection=b)}else A||(this.prevInput=this.textarea.value="",f&&g>=9&&(this.hasSelection=null));this.resetting=!1}},Ua.prototype.getField=function(){return this.textarea},Ua.prototype.supportsTouch=function(){return!1},Ua.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!ne||Nt(dt(this.textarea))!=this.textarea))try{this.textarea.focus()}catch{}},Ua.prototype.blur=function(){this.textarea.blur()},Ua.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ua.prototype.receivedFocus=function(){this.slowPoll()},Ua.prototype.slowPoll=function(){var A=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){A.poll(),A.cm.state.focused&&A.slowPoll()})},Ua.prototype.fastPoll=function(){var A=!1,h=this;h.pollingFast=!0;function b(){var _=h.poll();!_&&!A?(A=!0,h.polling.set(60,b)):(h.pollingFast=!1,h.slowPoll())}h.polling.set(20,b)},Ua.prototype.poll=function(){var A=this,h=this.cm,b=this.textarea,_=this.prevInput;if(this.contextMenuPending||this.resetting||!h.state.focused||Tr(b)&&!_&&!this.composing||h.isReadOnly()||h.options.disableInput||h.state.keySeq)return!1;var E=b.value;if(E==_&&!h.somethingSelected())return!1;if(f&&g>=9&&this.hasSelection===E||ce&&/[\uf700-\uf7ff]/.test(E))return h.display.input.reset(),!1;if(h.doc.sel==h.display.selForContextMenu){var U=E.charCodeAt(0);if(U==8203&&!_&&(_=""),U==8666)return this.reset(),this.cm.execCommand("undo")}for(var Y=0,J=Math.min(_.length,E.length);Y<J&&_.charCodeAt(Y)==E.charCodeAt(Y);)++Y;return wa(h,function(){r0(h,E.slice(Y),_.length-Y,null,A.composing?"*compose":null),E.length>1e3||E.indexOf(`
|
||
`)>-1?b.value=A.prevInput="":A.prevInput=E,A.composing&&(A.composing.range.clear(),A.composing.range=h.markText(A.composing.start,h.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Ua.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ua.prototype.onKeyPress=function(){f&&g>=9&&(this.hasSelection=null),this.fastPoll()},Ua.prototype.onContextMenu=function(A){var h=this,b=h.cm,_=b.display,E=h.textarea;h.contextMenuPending&&h.contextMenuPending();var U=Al(b,A),Y=_.scroller.scrollTop;if(!U||R)return;var J=b.options.resetSelectionOnContextMenu;J&&b.doc.sel.contains(U)==-1&&uo(b,ji)(b.doc,Qe(U),wt);var se=E.style.cssText,pe=h.wrapper.style.cssText,We=h.wrapper.offsetParent.getBoundingClientRect();h.wrapper.style.cssText="position: static",E.style.cssText=`position: absolute; width: 30px; height: 30px;
|
||
top: `+(A.clientY-We.top-5)+"px; left: "+(A.clientX-We.left-5)+`px;
|
||
z-index: 1000; background: `+(f?"rgba(255, 255, 255, .05)":"transparent")+`;
|
||
outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var Ye;x&&(Ye=E.ownerDocument.defaultView.scrollY),_.input.focus(),x&&E.ownerDocument.defaultView.scrollTo(null,Ye),_.input.reset(),b.somethingSelected()||(E.value=h.prevInput=" "),h.contextMenuPending=yt,_.selForContextMenu=b.doc.sel,clearTimeout(_.detectingSelectAll);function Mt(){if(E.selectionStart!=null){var Zt=b.somethingSelected(),Bn=""+(Zt?E.value:"");E.value="⇚",E.value=Bn,h.prevInput=Zt?"":"",E.selectionStart=1,E.selectionEnd=Bn.length,_.selForContextMenu=b.doc.sel}}function yt(){if(h.contextMenuPending==yt&&(h.contextMenuPending=!1,h.wrapper.style.cssText=pe,E.style.cssText=se,f&&g<9&&_.scrollbars.setScrollTop(_.scroller.scrollTop=Y),E.selectionStart!=null)){(!f||f&&g<9)&&Mt();var Zt=0,Bn=function(){_.selForContextMenu==b.doc.sel&&E.selectionStart==0&&E.selectionEnd>0&&h.prevInput==""?uo(b,Wo)(b):Zt++<10?_.detectingSelectAll=setTimeout(Bn,500):(_.selForContextMenu=null,_.input.reset())};_.detectingSelectAll=setTimeout(Bn,200)}}if(f&&g>=9&&Mt(),Ne){ht(A);var qt=function(){Gn(window,"mouseup",qt),setTimeout(yt,20)};un(window,"mouseup",qt)}else setTimeout(yt,50)},Ua.prototype.readOnlyChanged=function(A){A||this.reset(),this.textarea.disabled=A=="nocursor",this.textarea.readOnly=!!A},Ua.prototype.setUneditable=function(){},Ua.prototype.needsContentAttribute=!1;function L1(A,h){if(h=h?Se(h):{},h.value=A.value,!h.tabindex&&A.tabIndex&&(h.tabindex=A.tabIndex),!h.placeholder&&A.placeholder&&(h.placeholder=A.placeholder),h.autofocus==null){var b=Nt(dt(A));h.autofocus=b==A||A.getAttribute("autofocus")!=null&&b==document.body}function _(){A.value=J.getValue()}var E;if(A.form&&(un(A.form,"submit",_),!h.leaveSubmitMethodAlone)){var U=A.form;E=U.submit;try{var Y=U.submit=function(){_(),U.submit=E,U.submit(),U.submit=Y}}catch{}}h.finishInit=function(se){se.save=_,se.getTextArea=function(){return A},se.toTextArea=function(){se.toTextArea=isNaN,_(),A.parentNode.removeChild(se.getWrapperElement()),A.style.display="",A.form&&(Gn(A.form,"submit",_),!h.leaveSubmitMethodAlone&&typeof A.form.submit=="function"&&(A.form.submit=E))}},A.style.display="none";var J=qi(function(se){return A.parentNode.insertBefore(se,A.nextSibling)},h);return J}function ov(A){A.off=Gn,A.on=un,A.wheelEventPixels=Ae,A.Doc=Js,A.splitLines=qn,A.countColumn=de,A.findColumn=zn,A.isWordChar=vi,A.Pass=Xe,A.signal=Zn,A.Line=Su,A.changeEnd=Le,A.scrollbarModel=Oo,A.Pos=Ot,A.cmpPos=En,A.modes=Zr,A.mimeModes=Cr,A.resolveMode=Io,A.getMode=Ci,A.modeExtensions=so,A.extendMode=Yo,A.copyState=ba,A.startState=Ai,A.innerMode=Ql,A.commands=Ff,A.keyMap=kA,A.keyName=Yd,A.isModifierKey=Tp,A.lookupKey=pu,A.normalizeKeyMap=fu,A.StringStream=Mi,A.SharedTextMarker=Qd,A.TextMarker=Zl,A.LineWidget=nd,A.e_preventDefault=Te,A.e_stopPropagation=at,A.e_stop=ht,A.addClass=Ve,A.contains=Jt,A.rmClass=ct,A.keyNames=qa}FA(qi),ud(qi);var z1="iter insert remove copy getEditor constructor".split(" ");for(var Qf in Js.prototype)Js.prototype.hasOwnProperty(Qf)&&Pe(z1,Qf)<0&&(qi.prototype[Qf]=function(A){return function(){return A.apply(this.doc,arguments)}}(Js.prototype[Qf]));return Ee(Js),qi.inputStyles={textarea:Ua,contenteditable:Co},qi.defineMode=function(A){!qi.defaults.mode&&A!="null"&&(qi.defaults.mode=A),ui.apply(this,arguments)},qi.defineMIME=Ii,qi.defineMode("null",function(){return{token:function(A){return A.skipToEnd()}}}),qi.defineMIME("text/plain","null"),qi.defineExtension=function(A,h){qi.prototype[A]=h},qi.defineDocExtension=function(A,h){Js.prototype[A]=h},qi.fromTextArea=L1,ov(qi),qi.version="5.65.16",qi})}(YM)),YM.exports}var tpe=F5();const Kc=ga(tpe);(function(e,n){(function(t){t(F5())})(function(t){t.defineMode("javascript",function(r,i){var o=r.indentUnit,s=i.statementIndent,a=i.jsonld,f=i.json||a,g=i.trackScope!==!1,x=i.typescript,k=i.wordCharacters||/[\w$\xa1-\uffff]/,B=function(){function ve(Lr){return{type:Lr,style:"keyword"}}var Ge=ve("keyword a"),Ht=ve("keyword b"),mn=ve("keyword c"),Ot=ve("keyword d"),En=ve("operator"),zr={type:"atom",style:"atom"};return{if:ve("if"),while:Ge,with:Ge,else:Ht,do:Ht,try:Ht,finally:Ht,return:Ot,break:Ot,continue:Ot,new:ve("new"),delete:mn,void:mn,throw:mn,debugger:ve("debugger"),var:ve("var"),const:ve("var"),let:ve("var"),function:ve("function"),catch:ve("catch"),for:ve("for"),switch:ve("switch"),case:ve("case"),default:ve("default"),in:En,typeof:En,instanceof:En,true:zr,false:zr,null:zr,undefined:zr,NaN:zr,Infinity:zr,this:ve("this"),class:ve("class"),super:ve("atom"),yield:mn,export:ve("export"),import:ve("import"),extends:mn,await:mn}}(),P=/[+\-*&%=<>!?|~^@]/,R=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function H(ve){for(var Ge=!1,Ht,mn=!1;(Ht=ve.next())!=null;){if(!Ge){if(Ht=="/"&&!mn)return;Ht=="["?mn=!0:mn&&Ht=="]"&&(mn=!1)}Ge=!Ge&&Ht=="\\"}}var W,$;function q(ve,Ge,Ht){return W=ve,$=Ht,Ge}function oe(ve,Ge){var Ht=ve.next();if(Ht=='"'||Ht=="'")return Ge.tokenize=ne(Ht),Ge.tokenize(ve,Ge);if(Ht=="."&&ve.match(/^\d[\d_]*(?:[eE][+\-]?[\d_]+)?/))return q("number","number");if(Ht=="."&&ve.match(".."))return q("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(Ht))return q(Ht);if(Ht=="="&&ve.eat(">"))return q("=>","operator");if(Ht=="0"&&ve.match(/^(?:x[\dA-Fa-f_]+|o[0-7_]+|b[01_]+)n?/))return q("number","number");if(/\d/.test(Ht))return ve.match(/^[\d_]*(?:n|(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)?/),q("number","number");if(Ht=="/")return ve.eat("*")?(Ge.tokenize=ce,ce(ve,Ge)):ve.eat("/")?(ve.skipToEnd(),q("comment","comment")):la(ve,Ge,1)?(H(ve),ve.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),q("regexp","string-2")):(ve.eat("="),q("operator","operator",ve.current()));if(Ht=="`")return Ge.tokenize=ae,ae(ve,Ge);if(Ht=="#"&&ve.peek()=="!")return ve.skipToEnd(),q("meta","meta");if(Ht=="#"&&ve.eatWhile(k))return q("variable","property");if(Ht=="<"&&ve.match("!--")||Ht=="-"&&ve.match("->")&&!/\S/.test(ve.string.slice(0,ve.start)))return ve.skipToEnd(),q("comment","comment");if(P.test(Ht))return(Ht!=">"||!Ge.lexical||Ge.lexical.type!=">")&&(ve.eat("=")?(Ht=="!"||Ht=="=")&&ve.eat("="):/[<>*+\-|&?]/.test(Ht)&&(ve.eat(Ht),Ht==">"&&ve.eat(Ht))),Ht=="?"&&ve.eat(".")?q("."):q("operator","operator",ve.current());if(k.test(Ht)){ve.eatWhile(k);var mn=ve.current();if(Ge.lastType!="."){if(B.propertyIsEnumerable(mn)){var Ot=B[mn];return q(Ot.type,Ot.style,mn)}if(mn=="async"&&ve.match(/^(\s|\/\*([^*]|\*(?!\/))*?\*\/)*[\[\(\w]/,!1))return q("async","keyword",mn)}return q("variable","variable",mn)}}function ne(ve){return function(Ge,Ht){var mn=!1,Ot;if(a&&Ge.peek()=="@"&&Ge.match(R))return Ht.tokenize=oe,q("jsonld-keyword","meta");for(;(Ot=Ge.next())!=null&&!(Ot==ve&&!mn);)mn=!mn&&Ot=="\\";return mn||(Ht.tokenize=oe),q("string","string")}}function ce(ve,Ge){for(var Ht=!1,mn;mn=ve.next();){if(mn=="/"&&Ht){Ge.tokenize=oe;break}Ht=mn=="*"}return q("comment","comment")}function ae(ve,Ge){for(var Ht=!1,mn;(mn=ve.next())!=null;){if(!Ht&&(mn=="`"||mn=="$"&&ve.eat("{"))){Ge.tokenize=oe;break}Ht=!Ht&&mn=="\\"}return q("quasi","string-2",ve.current())}var ue="([{}])";function ye(ve,Ge){Ge.fatArrowAt&&(Ge.fatArrowAt=null);var Ht=ve.string.indexOf("=>",ve.start);if(!(Ht<0)){if(x){var mn=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(ve.string.slice(ve.start,Ht));mn&&(Ht=mn.index)}for(var Ot=0,En=!1,zr=Ht-1;zr>=0;--zr){var Lr=ve.string.charAt(zr),Ti=ue.indexOf(Lr);if(Ti>=0&&Ti<3){if(!Ot){++zr;break}if(--Ot==0){Lr=="("&&(En=!0);break}}else if(Ti>=3&&Ti<6)++Ot;else if(k.test(Lr))En=!0;else if(/["'\/`]/.test(Lr))for(;;--zr){if(zr==0)return;var po=ve.string.charAt(zr-1);if(po==Lr&&ve.string.charAt(zr-2)!="\\"){zr--;break}}else if(En&&!Ot){++zr;break}}En&&!Ot&&(Ge.fatArrowAt=zr)}}var Re={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,import:!0,"jsonld-keyword":!0};function Ne(ve,Ge,Ht,mn,Ot,En){this.indented=ve,this.column=Ge,this.type=Ht,this.prev=Ot,this.info=En,mn!=null&&(this.align=mn)}function rt(ve,Ge){if(!g)return!1;for(var Ht=ve.localVars;Ht;Ht=Ht.next)if(Ht.name==Ge)return!0;for(var mn=ve.context;mn;mn=mn.prev)for(var Ht=mn.vars;Ht;Ht=Ht.next)if(Ht.name==Ge)return!0}function ct(ve,Ge,Ht,mn,Ot){var En=ve.cc;for(Fe.state=ve,Fe.stream=Ot,Fe.marked=null,Fe.cc=En,Fe.style=Ge,ve.lexical.hasOwnProperty("align")||(ve.lexical.align=!0);;){var zr=En.length?En.pop():f?Pe:de;if(zr(Ht,mn)){for(;En.length&&En[En.length-1].lex;)En.pop()();return Fe.marked?Fe.marked:Ht=="variable"&&rt(ve,mn)?"variable-2":Ge}}}var Fe={state:null,column:null,marked:null,cc:null};function He(){for(var ve=arguments.length-1;ve>=0;ve--)Fe.cc.push(arguments[ve])}function Ce(){return He.apply(null,arguments),!0}function jt(ve,Ge){for(var Ht=Ge;Ht;Ht=Ht.next)if(Ht.name==ve)return!0;return!1}function Ft(ve){var Ge=Fe.state;if(Fe.marked="def",!!g){if(Ge.context){if(Ge.lexical.info=="var"&&Ge.context&&Ge.context.block){var Ht=Jt(ve,Ge.context);if(Ht!=null){Ge.context=Ht;return}}else if(!jt(ve,Ge.localVars)){Ge.localVars=new nt(ve,Ge.localVars);return}}i.globalVars&&!jt(ve,Ge.globalVars)&&(Ge.globalVars=new nt(ve,Ge.globalVars))}}function Jt(ve,Ge){if(Ge)if(Ge.block){var Ht=Jt(ve,Ge.prev);return Ht?Ht==Ge.prev?Ge:new Ve(Ht,Ge.vars,!0):null}else return jt(ve,Ge.vars)?Ge:new Ve(Ge.prev,new nt(ve,Ge.vars),!1);else return null}function Nt(ve){return ve=="public"||ve=="private"||ve=="protected"||ve=="abstract"||ve=="readonly"}function Ve(ve,Ge,Ht){this.prev=ve,this.vars=Ge,this.block=Ht}function nt(ve,Ge){this.name=ve,this.next=Ge}var Je=new nt("this",new nt("arguments",null));function Vt(){Fe.state.context=new Ve(Fe.state.context,Fe.state.localVars,!1),Fe.state.localVars=Je}function pt(){Fe.state.context=new Ve(Fe.state.context,Fe.state.localVars,!0),Fe.state.localVars=null}Vt.lex=pt.lex=!0;function dt(){Fe.state.localVars=Fe.state.context.vars,Fe.state.context=Fe.state.context.prev}dt.lex=!0;function kt(ve,Ge){var Ht=function(){var mn=Fe.state,Ot=mn.indented;if(mn.lexical.type=="stat")Ot=mn.lexical.indented;else for(var En=mn.lexical;En&&En.type==")"&&En.align;En=En.prev)Ot=En.indented;mn.lexical=new Ne(Ot,Fe.stream.column(),ve,null,mn.lexical,Ge)};return Ht.lex=!0,Ht}function Dt(){var ve=Fe.state;ve.lexical.prev&&(ve.lexical.type==")"&&(ve.indented=ve.lexical.indented),ve.lexical=ve.lexical.prev)}Dt.lex=!0;function Se(ve){function Ge(Ht){return Ht==ve?Ce():ve==";"||Ht=="}"||Ht==")"||Ht=="]"?He():Ce(Ge)}return Ge}function de(ve,Ge){return ve=="var"?Ce(kt("vardef",Ge),at,Se(";"),Dt):ve=="keyword a"?Ce(kt("form"),Xe,de,Dt):ve=="keyword b"?Ce(kt("form"),de,Dt):ve=="keyword d"?Fe.stream.match(/^\s*$/,!1)?Ce():Ce(kt("stat"),Kt,Se(";"),Dt):ve=="debugger"?Ce(Se(";")):ve=="{"?Ce(kt("}"),pt,bt,Dt,dt):ve==";"?Ce():ve=="if"?(Fe.state.lexical.info=="else"&&Fe.state.cc[Fe.state.cc.length-1]==Dt&&Fe.state.cc.pop()(),Ce(kt("form"),Xe,de,Dt,Gt)):ve=="function"?Ce(qn):ve=="for"?Ce(kt("form"),pt,$t,de,dt,Dt):ve=="class"||x&&Ge=="interface"?(Fe.marked="keyword",Ce(kt("form",ve=="class"?ve:Ge),Zr,Dt)):ve=="variable"?x&&Ge=="declare"?(Fe.marked="keyword",Ce(de)):x&&(Ge=="module"||Ge=="enum"||Ge=="type")&&Fe.stream.match(/^\s*\w/,!1)?(Fe.marked="keyword",Ge=="enum"?Ce(rr):Ge=="type"?Ce(vr,Se("operator"),on,Se(";")):Ce(kt("form"),it,Se("{"),kt("}"),bt,Dt,Dt)):x&&Ge=="namespace"?(Fe.marked="keyword",Ce(kt("form"),Pe,de,Dt)):x&&Ge=="abstract"?(Fe.marked="keyword",Ce(de)):Ce(kt("stat"),_r):ve=="switch"?Ce(kt("form"),Xe,Se("{"),kt("}","switch"),pt,bt,Dt,Dt,dt):ve=="case"?Ce(Pe,Se(":")):ve=="default"?Ce(Se(":")):ve=="catch"?Ce(kt("form"),Vt,xe,de,Dt,dt):ve=="export"?Ce(kt("stat"),Io,Dt):ve=="import"?Ce(kt("stat"),so,Dt):ve=="async"?Ce(de):Ge=="@"?Ce(Pe,de):He(kt("stat"),Pe,Se(";"),Dt)}function xe(ve){if(ve=="(")return Ce(Dr,Se(")"))}function Pe(ve,Ge){return wt(ve,Ge,!1)}function Ze(ve,Ge){return wt(ve,Ge,!0)}function Xe(ve){return ve!="("?He():Ce(kt(")"),Kt,Se(")"),Dt)}function wt(ve,Ge,Ht){if(Fe.state.fatArrowAt==Fe.stream.start){var mn=Ht?Sn:ir;if(ve=="(")return Ce(Vt,kt(")"),me(Dr,")"),Dt,Se("=>"),mn,dt);if(ve=="variable")return He(Vt,it,Se("=>"),mn,dt)}var Ot=Ht?zn:Pt;return Re.hasOwnProperty(ve)?Ce(Ot):ve=="function"?Ce(qn,Ot):ve=="class"||x&&Ge=="interface"?(Fe.marked="keyword",Ce(kt("form"),Yr,Dt)):ve=="keyword c"||ve=="async"?Ce(Ht?Ze:Pe):ve=="("?Ce(kt(")"),Kt,Se(")"),Dt,Ot):ve=="operator"||ve=="spread"?Ce(Ht?Ze:Pe):ve=="["?Ce(kt("]"),Mi,Dt,Ot):ve=="{"?At(we,"}",null,Ot):ve=="quasi"?He(mt,Ot):ve=="new"?Ce(nr(Ht)):Ce()}function Kt(ve){return ve.match(/[;\}\)\],]/)?He():He(Pe)}function Pt(ve,Ge){return ve==","?Ce(Kt):zn(ve,Ge,!1)}function zn(ve,Ge,Ht){var mn=Ht==!1?Pt:zn,Ot=Ht==!1?Pe:Ze;if(ve=="=>")return Ce(Vt,Ht?Sn:ir,dt);if(ve=="operator")return/\+\+|--/.test(Ge)||x&&Ge=="!"?Ce(mn):x&&Ge=="<"&&Fe.stream.match(/^([^<>]|<[^<>]*>)*>\s*\(/,!1)?Ce(kt(">"),me(on,">"),Dt,mn):Ge=="?"?Ce(Pe,Se(":"),Ot):Ce(Ot);if(ve=="quasi")return He(mt,mn);if(ve!=";"){if(ve=="(")return At(Ze,")","call",mn);if(ve==".")return Ce(vi,mn);if(ve=="[")return Ce(kt("]"),Kt,Se("]"),Dt,mn);if(x&&Ge=="as")return Fe.marked="keyword",Ce(on,mn);if(ve=="regexp")return Fe.state.lastType=Fe.marked="operator",Fe.stream.backUp(Fe.stream.pos-Fe.stream.start-1),Ce(Ot)}}function mt(ve,Ge){return ve!="quasi"?He():Ge.slice(Ge.length-2)!="${"?Ce(mt):Ce(Kt,pn)}function pn(ve){if(ve=="}")return Fe.marked="string-2",Fe.state.tokenize=ae,Ce(mt)}function ir(ve){return ye(Fe.stream,Fe.state),He(ve=="{"?de:Pe)}function Sn(ve){return ye(Fe.stream,Fe.state),He(ve=="{"?de:Ze)}function nr(ve){return function(Ge){return Ge=="."?Ce(ve?Qr:Mr):Ge=="variable"&&x?Ce(_e,ve?zn:Pt):He(ve?Ze:Pe)}}function Mr(ve,Ge){if(Ge=="target")return Fe.marked="keyword",Ce(Pt)}function Qr(ve,Ge){if(Ge=="target")return Fe.marked="keyword",Ce(zn)}function _r(ve){return ve==":"?Ce(Dt,de):He(Pt,Se(";"),Dt)}function vi(ve){if(ve=="variable")return Fe.marked="property",Ce()}function we(ve,Ge){if(ve=="async")return Fe.marked="property",Ce(we);if(ve=="variable"||Fe.style=="keyword"){if(Fe.marked="property",Ge=="get"||Ge=="set")return Ce(V);var Ht;return x&&Fe.state.fatArrowAt==Fe.stream.start&&(Ht=Fe.stream.match(/^\s*:\s*/,!1))&&(Fe.state.fatArrowAt=Fe.stream.pos+Ht[0].length),Ce(X)}else{if(ve=="number"||ve=="string")return Fe.marked=a?"property":Fe.style+" property",Ce(X);if(ve=="jsonld-keyword")return Ce(X);if(x&&Nt(Ge))return Fe.marked="keyword",Ce(we);if(ve=="[")return Ce(Pe,Et,Se("]"),X);if(ve=="spread")return Ce(Ze,X);if(Ge=="*")return Fe.marked="keyword",Ce(we);if(ve==":")return He(X)}}function V(ve){return ve!="variable"?He(X):(Fe.marked="property",Ce(qn))}function X(ve){if(ve==":")return Ce(Ze);if(ve=="(")return He(qn)}function me(ve,Ge,Ht){function mn(Ot,En){if(Ht?Ht.indexOf(Ot)>-1:Ot==","){var zr=Fe.state.lexical;return zr.info=="call"&&(zr.pos=(zr.pos||0)+1),Ce(function(Lr,Ti){return Lr==Ge||Ti==Ge?He():He(ve)},mn)}return Ot==Ge||En==Ge?Ce():Ht&&Ht.indexOf(";")>-1?He(ve):Ce(Se(Ge))}return function(Ot,En){return Ot==Ge||En==Ge?Ce():He(ve,mn)}}function At(ve,Ge,Ht){for(var mn=3;mn<arguments.length;mn++)Fe.cc.push(arguments[mn]);return Ce(kt(Ge,Ht),me(ve,Ge),Dt)}function bt(ve){return ve=="}"?Ce():He(de,bt)}function Et(ve,Ge){if(x){if(ve==":")return Ce(on);if(Ge=="?")return Ce(Et)}}function sr(ve,Ge){if(x&&(ve==":"||Ge=="in"))return Ce(on)}function Lt(ve){if(x&&ve==":")return Fe.stream.match(/^\s*\w+\s+is\b/,!1)?Ce(Pe,Fn,on):Ce(on)}function Fn(ve,Ge){if(Ge=="is")return Fe.marked="keyword",Ce()}function on(ve,Ge){if(Ge=="keyof"||Ge=="typeof"||Ge=="infer"||Ge=="readonly")return Fe.marked="keyword",Ce(Ge=="typeof"?Ze:on);if(ve=="variable"||Ge=="void")return Fe.marked="type",Ce(fe);if(Ge=="|"||Ge=="&")return Ce(on);if(ve=="string"||ve=="number"||ve=="atom")return Ce(fe);if(ve=="[")return Ce(kt("]"),me(on,"]",","),Dt,fe);if(ve=="{")return Ce(kt("}"),un,Dt,fe);if(ve=="(")return Ce(me(Ke,")"),m,fe);if(ve=="<")return Ce(me(on,">"),on);if(ve=="quasi")return He(Gn,fe)}function m(ve){if(ve=="=>")return Ce(on)}function un(ve){return ve.match(/[\}\)\]]/)?Ce():ve==","||ve==";"?Ce(un):He(In,un)}function In(ve,Ge){if(ve=="variable"||Fe.style=="keyword")return Fe.marked="property",Ce(In);if(Ge=="?"||ve=="number"||ve=="string")return Ce(In);if(ve==":")return Ce(on);if(ve=="[")return Ce(Se("variable"),sr,Se("]"),In);if(ve=="(")return He(Tr,In);if(!ve.match(/[;\}\)\],]/))return Ce()}function Gn(ve,Ge){return ve!="quasi"?He():Ge.slice(Ge.length-2)!="${"?Ce(Gn):Ce(on,Zn)}function Zn(ve){if(ve=="}")return Fe.marked="string-2",Fe.state.tokenize=ae,Ce(Gn)}function Ke(ve,Ge){return ve=="variable"&&Fe.stream.match(/^\s*[?:]/,!1)||Ge=="?"?Ce(Ke):ve==":"?Ce(on):ve=="spread"?Ce(Ke):He(on)}function fe(ve,Ge){if(Ge=="<")return Ce(kt(">"),me(on,">"),Dt,fe);if(Ge=="|"||ve=="."||Ge=="&")return Ce(on);if(ve=="[")return Ce(on,Se("]"),fe);if(Ge=="extends"||Ge=="implements")return Fe.marked="keyword",Ce(on);if(Ge=="?")return Ce(on,Se(":"),on)}function _e(ve,Ge){if(Ge=="<")return Ce(kt(">"),me(on,">"),Dt,fe)}function Ee(){return He(on,Te)}function Te(ve,Ge){if(Ge=="=")return Ce(on)}function at(ve,Ge){return Ge=="enum"?(Fe.marked="keyword",Ce(rr)):He(it,Et,Ct,rn)}function it(ve,Ge){if(x&&Nt(Ge))return Fe.marked="keyword",Ce(it);if(ve=="variable")return Ft(Ge),Ce();if(ve=="spread")return Ce(it);if(ve=="[")return At(et,"]");if(ve=="{")return At(ht,"}")}function ht(ve,Ge){return ve=="variable"&&!Fe.stream.match(/^\s*:/,!1)?(Ft(Ge),Ce(Ct)):(ve=="variable"&&(Fe.marked="property"),ve=="spread"?Ce(it):ve=="}"?He():ve=="["?Ce(Pe,Se("]"),Se(":"),ht):Ce(Se(":"),it,Ct))}function et(){return He(it,Ct)}function Ct(ve,Ge){if(Ge=="=")return Ce(Ze)}function rn(ve){if(ve==",")return Ce(at)}function Gt(ve,Ge){if(ve=="keyword b"&&Ge=="else")return Ce(kt("form","else"),de,Dt)}function $t(ve,Ge){if(Ge=="await")return Ce($t);if(ve=="(")return Ce(kt(")"),gn,Dt)}function gn(ve){return ve=="var"?Ce(at,Jn):ve=="variable"?Ce(Jn):He(Jn)}function Jn(ve,Ge){return ve==")"?Ce():ve==";"?Ce(Jn):Ge=="in"||Ge=="of"?(Fe.marked="keyword",Ce(Pe,Jn)):He(Pe,Jn)}function qn(ve,Ge){if(Ge=="*")return Fe.marked="keyword",Ce(qn);if(ve=="variable")return Ft(Ge),Ce(qn);if(ve=="(")return Ce(Vt,kt(")"),me(Dr,")"),Dt,Lt,de,dt);if(x&&Ge=="<")return Ce(kt(">"),me(Ee,">"),Dt,qn)}function Tr(ve,Ge){if(Ge=="*")return Fe.marked="keyword",Ce(Tr);if(ve=="variable")return Ft(Ge),Ce(Tr);if(ve=="(")return Ce(Vt,kt(")"),me(Dr,")"),Dt,Lt,dt);if(x&&Ge=="<")return Ce(kt(">"),me(Ee,">"),Dt,Tr)}function vr(ve,Ge){if(ve=="keyword"||ve=="variable")return Fe.marked="type",Ce(vr);if(Ge=="<")return Ce(kt(">"),me(Ee,">"),Dt)}function Dr(ve,Ge){return Ge=="@"&&Ce(Pe,Dr),ve=="spread"?Ce(Dr):x&&Nt(Ge)?(Fe.marked="keyword",Ce(Dr)):x&&ve=="this"?Ce(Et,Ct):He(it,Et,Ct)}function Yr(ve,Ge){return ve=="variable"?Zr(ve,Ge):Cr(ve,Ge)}function Zr(ve,Ge){if(ve=="variable")return Ft(Ge),Ce(Cr)}function Cr(ve,Ge){if(Ge=="<")return Ce(kt(">"),me(Ee,">"),Dt,Cr);if(Ge=="extends"||Ge=="implements"||x&&ve==",")return Ge=="implements"&&(Fe.marked="keyword"),Ce(x?on:Pe,Cr);if(ve=="{")return Ce(kt("}"),ui,Dt)}function ui(ve,Ge){if(ve=="async"||ve=="variable"&&(Ge=="static"||Ge=="get"||Ge=="set"||x&&Nt(Ge))&&Fe.stream.match(/^\s+#?[\w$\xa1-\uffff]/,!1))return Fe.marked="keyword",Ce(ui);if(ve=="variable"||Fe.style=="keyword")return Fe.marked="property",Ce(Ii,ui);if(ve=="number"||ve=="string")return Ce(Ii,ui);if(ve=="[")return Ce(Pe,Et,Se("]"),Ii,ui);if(Ge=="*")return Fe.marked="keyword",Ce(ui);if(x&&ve=="(")return He(Tr,ui);if(ve==";"||ve==",")return Ce(ui);if(ve=="}")return Ce();if(Ge=="@")return Ce(Pe,ui)}function Ii(ve,Ge){if(Ge=="!"||Ge=="?")return Ce(Ii);if(ve==":")return Ce(on,Ct);if(Ge=="=")return Ce(Ze);var Ht=Fe.state.lexical.prev,mn=Ht&&Ht.info=="interface";return He(mn?Tr:qn)}function Io(ve,Ge){return Ge=="*"?(Fe.marked="keyword",Ce(Ai,Se(";"))):Ge=="default"?(Fe.marked="keyword",Ce(Pe,Se(";"))):ve=="{"?Ce(me(Ci,"}"),Ai,Se(";")):He(de)}function Ci(ve,Ge){if(Ge=="as")return Fe.marked="keyword",Ce(Se("variable"));if(ve=="variable")return He(Ze,Ci)}function so(ve){return ve=="string"?Ce():ve=="("?He(Pe):ve=="."?He(Pt):He(Yo,ba,Ai)}function Yo(ve,Ge){return ve=="{"?At(Yo,"}"):(ve=="variable"&&Ft(Ge),Ge=="*"&&(Fe.marked="keyword"),Ce(Ql))}function ba(ve){if(ve==",")return Ce(Yo,ba)}function Ql(ve,Ge){if(Ge=="as")return Fe.marked="keyword",Ce(Yo)}function Ai(ve,Ge){if(Ge=="from")return Fe.marked="keyword",Ce(Pe)}function Mi(ve){return ve=="]"?Ce():He(me(Ze,"]"))}function rr(){return He(kt("form"),it,Se("{"),kt("}"),me(lo,"}"),Dt,Dt)}function lo(){return He(it,Ct)}function Gi(ve,Ge){return ve.lastType=="operator"||ve.lastType==","||P.test(Ge.charAt(0))||/[,.]/.test(Ge.charAt(0))}function la(ve,Ge,Ht){return Ge.tokenize==oe&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(Ge.lastType)||Ge.lastType=="quasi"&&/\{\s*$/.test(ve.string.slice(0,ve.pos-(Ht||0)))}return{startState:function(ve){var Ge={tokenize:oe,lastType:"sof",cc:[],lexical:new Ne((ve||0)-o,0,"block",!1),localVars:i.localVars,context:i.localVars&&new Ve(null,null,!1),indented:ve||0};return i.globalVars&&typeof i.globalVars=="object"&&(Ge.globalVars=i.globalVars),Ge},token:function(ve,Ge){if(ve.sol()&&(Ge.lexical.hasOwnProperty("align")||(Ge.lexical.align=!1),Ge.indented=ve.indentation(),ye(ve,Ge)),Ge.tokenize!=ce&&ve.eatSpace())return null;var Ht=Ge.tokenize(ve,Ge);return W=="comment"?Ht:(Ge.lastType=W=="operator"&&($=="++"||$=="--")?"incdec":W,ct(Ge,Ht,W,$,ve))},indent:function(ve,Ge){if(ve.tokenize==ce||ve.tokenize==ae)return t.Pass;if(ve.tokenize!=oe)return 0;var Ht=Ge&&Ge.charAt(0),mn=ve.lexical,Ot;if(!/^\s*else\b/.test(Ge))for(var En=ve.cc.length-1;En>=0;--En){var zr=ve.cc[En];if(zr==Dt)mn=mn.prev;else if(zr!=Gt&&zr!=dt)break}for(;(mn.type=="stat"||mn.type=="form")&&(Ht=="}"||(Ot=ve.cc[ve.cc.length-1])&&(Ot==Pt||Ot==zn)&&!/^[,\.=+\-*:?[\(]/.test(Ge));)mn=mn.prev;s&&mn.type==")"&&mn.prev.type=="stat"&&(mn=mn.prev);var Lr=mn.type,Ti=Ht==Lr;return Lr=="vardef"?mn.indented+(ve.lastType=="operator"||ve.lastType==","?mn.info.length+1:0):Lr=="form"&&Ht=="{"?mn.indented:Lr=="form"?mn.indented+o:Lr=="stat"?mn.indented+(Gi(ve,Ge)?s||o:0):mn.info=="switch"&&!Ti&&i.doubleIndentSwitch!=!1?mn.indented+(/^(?:case|default)\b/.test(Ge)?o:2*o):mn.align?mn.column+(Ti?0:1):mn.indented+(Ti?0:o)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:f?null:"/*",blockCommentEnd:f?null:"*/",blockCommentContinue:f?null:" * ",lineComment:f?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:f?"json":"javascript",jsonldMode:a,jsonMode:f,expressionAllowed:la,skipExpression:function(ve){ct(ve,"atom","atom","true",new t.StringStream("",2,null))}}}),t.registerHelper("wordChars","javascript",/[\w$]/),t.defineMIME("text/javascript","javascript"),t.defineMIME("text/ecmascript","javascript"),t.defineMIME("application/javascript","javascript"),t.defineMIME("application/x-javascript","javascript"),t.defineMIME("application/ecmascript","javascript"),t.defineMIME("application/json",{name:"javascript",json:!0}),t.defineMIME("application/x-json",{name:"javascript",json:!0}),t.defineMIME("application/manifest+json",{name:"javascript",json:!0}),t.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),t.defineMIME("text/typescript",{name:"javascript",typescript:!0}),t.defineMIME("application/typescript",{name:"javascript",typescript:!0})})})();(function(e,n){(function(t){t(F5())})(function(t){var r="CodeMirror-lint-markers",i="CodeMirror-lint-line-";function o(ue,ye,Re){var Ne=document.createElement("div");Ne.className="CodeMirror-lint-tooltip cm-s-"+ue.options.theme,Ne.appendChild(Re.cloneNode(!0)),ue.state.lint.options.selfContain?ue.getWrapperElement().appendChild(Ne):document.body.appendChild(Ne);function rt(ct){if(!Ne.parentNode)return t.off(document,"mousemove",rt);var Fe=Math.max(0,ct.clientY-Ne.offsetHeight-5),He=Math.max(0,Math.min(ct.clientX+5,Ne.ownerDocument.defaultView.innerWidth-Ne.offsetWidth));Ne.style.top=Fe+"px",Ne.style.left=He+"px"}return t.on(document,"mousemove",rt),rt(ye),Ne.style.opacity!=null&&(Ne.style.opacity=1),Ne}function s(ue){ue.parentNode&&ue.parentNode.removeChild(ue)}function a(ue){ue.parentNode&&(ue.style.opacity==null&&s(ue),ue.style.opacity=0,setTimeout(function(){s(ue)},600))}function f(ue,ye,Re,Ne){var rt=o(ue,ye,Re);function ct(){t.off(Ne,"mouseout",ct),rt&&(a(rt),rt=null)}var Fe=setInterval(function(){if(rt)for(var He=Ne;;He=He.parentNode){if(He&&He.nodeType==11&&(He=He.host),He==document.body)return;if(!He){ct();break}}if(!rt)return clearInterval(Fe)},400);t.on(Ne,"mouseout",ct)}function g(ue,ye,Re){this.marked=[],ye instanceof Function&&(ye={getAnnotations:ye}),(!ye||ye===!0)&&(ye={}),this.options={},this.linterOptions=ye.options||{};for(var Ne in x)this.options[Ne]=x[Ne];for(var Ne in ye)x.hasOwnProperty(Ne)?ye[Ne]!=null&&(this.options[Ne]=ye[Ne]):ye.options||(this.linterOptions[Ne]=ye[Ne]);this.timeout=null,this.hasGutter=Re,this.onMouseOver=function(rt){ae(ue,rt)},this.waitingFor=0}var x={highlightLines:!1,tooltips:!0,delay:500,lintOnChange:!0,getAnnotations:null,async:!1,selfContain:null,formatAnnotation:null,onUpdateLinting:null};function k(ue){var ye=ue.state.lint;ye.hasGutter&&ue.clearGutter(r),ye.options.highlightLines&&B(ue);for(var Re=0;Re<ye.marked.length;++Re)ye.marked[Re].clear();ye.marked.length=0}function B(ue){ue.eachLine(function(ye){var Re=ye.wrapClass&&/\bCodeMirror-lint-line-\w+\b/.exec(ye.wrapClass);Re&&ue.removeLineClass(ye,"wrap",Re[0])})}function P(ue,ye,Re,Ne,rt){var ct=document.createElement("div"),Fe=ct;return ct.className="CodeMirror-lint-marker CodeMirror-lint-marker-"+Re,Ne&&(Fe=ct.appendChild(document.createElement("div")),Fe.className="CodeMirror-lint-marker CodeMirror-lint-marker-multiple"),rt!=!1&&t.on(Fe,"mouseover",function(He){f(ue,He,ye,Fe)}),ct}function R(ue,ye){return ue=="error"?ue:ye}function H(ue){for(var ye=[],Re=0;Re<ue.length;++Re){var Ne=ue[Re],rt=Ne.from.line;(ye[rt]||(ye[rt]=[])).push(Ne)}return ye}function W(ue){var ye=ue.severity;ye||(ye="error");var Re=document.createElement("div");return Re.className="CodeMirror-lint-message CodeMirror-lint-message-"+ye,typeof ue.messageHTML<"u"?Re.innerHTML=ue.messageHTML:Re.appendChild(document.createTextNode(ue.message)),Re}function $(ue,ye){var Re=ue.state.lint,Ne=++Re.waitingFor;function rt(){Ne=-1,ue.off("change",rt)}ue.on("change",rt),ye(ue.getValue(),function(ct,Fe){ue.off("change",rt),Re.waitingFor==Ne&&(Fe&&ct instanceof t&&(ct=Fe),ue.operation(function(){oe(ue,ct)}))},Re.linterOptions,ue)}function q(ue){var ye=ue.state.lint;if(ye){var Re=ye.options,Ne=Re.getAnnotations||ue.getHelper(t.Pos(0,0),"lint");if(Ne)if(Re.async||Ne.async)$(ue,Ne);else{var rt=Ne(ue.getValue(),ye.linterOptions,ue);if(!rt)return;rt.then?rt.then(function(ct){ue.operation(function(){oe(ue,ct)})}):ue.operation(function(){oe(ue,rt)})}}}function oe(ue,ye){var Re=ue.state.lint;if(Re){var Ne=Re.options;k(ue);for(var rt=H(ye),ct=0;ct<rt.length;++ct){var Fe=rt[ct];if(Fe){for(var He=null,Ce=Re.hasGutter&&document.createDocumentFragment(),jt=0;jt<Fe.length;++jt){var Ft=Fe[jt],Jt=Ft.severity;Jt||(Jt="error"),He=R(He,Jt),Ne.formatAnnotation&&(Ft=Ne.formatAnnotation(Ft)),Re.hasGutter&&Ce.appendChild(W(Ft)),Ft.to&&Re.marked.push(ue.markText(Ft.from,Ft.to,{className:"CodeMirror-lint-mark CodeMirror-lint-mark-"+Jt,__annotation:Ft}))}Re.hasGutter&&ue.setGutterMarker(ct,r,P(ue,Ce,He,Fe.length>1,Ne.tooltips)),Ne.highlightLines&&ue.addLineClass(ct,"wrap",i+He)}}Ne.onUpdateLinting&&Ne.onUpdateLinting(ye,rt,ue)}}function ne(ue){var ye=ue.state.lint;ye&&(clearTimeout(ye.timeout),ye.timeout=setTimeout(function(){q(ue)},ye.options.delay))}function ce(ue,ye,Re){for(var Ne=Re.target||Re.srcElement,rt=document.createDocumentFragment(),ct=0;ct<ye.length;ct++){var Fe=ye[ct];rt.appendChild(W(Fe))}f(ue,Re,rt,Ne)}function ae(ue,ye){var Re=ye.target||ye.srcElement;if(/\bCodeMirror-lint-mark-/.test(Re.className)){for(var Ne=Re.getBoundingClientRect(),rt=(Ne.left+Ne.right)/2,ct=(Ne.top+Ne.bottom)/2,Fe=ue.findMarksAt(ue.coordsChar({left:rt,top:ct},"client")),He=[],Ce=0;Ce<Fe.length;++Ce){var jt=Fe[Ce].__annotation;jt&&He.push(jt)}He.length&&ce(ue,He,ye)}}t.defineOption("lint",!1,function(ue,ye,Re){if(Re&&Re!=t.Init&&(k(ue),ue.state.lint.options.lintOnChange!==!1&&ue.off("change",ne),t.off(ue.getWrapperElement(),"mouseover",ue.state.lint.onMouseOver),clearTimeout(ue.state.lint.timeout),delete ue.state.lint),ye){for(var Ne=ue.getOption("gutters"),rt=!1,ct=0;ct<Ne.length;++ct)Ne[ct]==r&&(rt=!0);var Fe=ue.state.lint=new g(ue,ye,rt);Fe.options.lintOnChange&&ue.on("change",ne),Fe.options.tooltips!=!1&&Fe.options.tooltips!="gutter"&&t.on(ue.getWrapperElement(),"mouseover",Fe.onMouseOver),q(ue)}}),t.defineExtension("performLint",function(){q(this)})})})();(function(e,n){(function(t){t(F5())})(function(t){var r=/MSIE \d/.test(navigator.userAgent)&&(document.documentMode==null||document.documentMode<8),i=t.Pos,o={"(":")>",")":"(<","[":"]>","]":"[<","{":"}>","}":"{<","<":">>",">":"<<"};function s(B){return B&&B.bracketRegex||/[(){}[\]]/}function a(B,P,R){var H=B.getLineHandle(P.line),W=P.ch-1,$=R&&R.afterCursor;$==null&&($=/(^| )cm-fat-cursor($| )/.test(B.getWrapperElement().className));var q=s(R),oe=!$&&W>=0&&q.test(H.text.charAt(W))&&o[H.text.charAt(W)]||q.test(H.text.charAt(W+1))&&o[H.text.charAt(++W)];if(!oe)return null;var ne=oe.charAt(1)==">"?1:-1;if(R&&R.strict&&ne>0!=(W==P.ch))return null;var ce=B.getTokenTypeAt(i(P.line,W+1)),ae=f(B,i(P.line,W+(ne>0?1:0)),ne,ce,R);return ae==null?null:{from:i(P.line,W),to:ae&&ae.pos,match:ae&&ae.ch==oe.charAt(0),forward:ne>0}}function f(B,P,R,H,W){for(var $=W&&W.maxScanLineLength||1e4,q=W&&W.maxScanLines||1e3,oe=[],ne=s(W),ce=R>0?Math.min(P.line+q,B.lastLine()+1):Math.max(B.firstLine()-1,P.line-q),ae=P.line;ae!=ce;ae+=R){var ue=B.getLine(ae);if(ue){var ye=R>0?0:ue.length-1,Re=R>0?ue.length:-1;if(!(ue.length>$))for(ae==P.line&&(ye=P.ch-(R<0?1:0));ye!=Re;ye+=R){var Ne=ue.charAt(ye);if(ne.test(Ne)&&(H===void 0||(B.getTokenTypeAt(i(ae,ye+1))||"")==(H||""))){var rt=o[Ne];if(rt&&rt.charAt(1)==">"==R>0)oe.push(Ne);else if(oe.length)oe.pop();else return{pos:i(ae,ye),ch:Ne}}}}}return ae-R==(R>0?B.lastLine():B.firstLine())?!1:null}function g(B,P,R){for(var H=B.state.matchBrackets.maxHighlightLineLength||1e3,W=R&&R.highlightNonMatching,$=[],q=B.listSelections(),oe=0;oe<q.length;oe++){var ne=q[oe].empty()&&a(B,q[oe].head,R);if(ne&&(ne.match||W!==!1)&&B.getLine(ne.from.line).length<=H){var ce=ne.match?"CodeMirror-matchingbracket":"CodeMirror-nonmatchingbracket";$.push(B.markText(ne.from,i(ne.from.line,ne.from.ch+1),{className:ce})),ne.to&&B.getLine(ne.to.line).length<=H&&$.push(B.markText(ne.to,i(ne.to.line,ne.to.ch+1),{className:ce}))}}if($.length){r&&B.state.focused&&B.focus();var ae=function(){B.operation(function(){for(var ue=0;ue<$.length;ue++)$[ue].clear()})};if(P)setTimeout(ae,800);else return ae}}function x(B){B.operation(function(){B.state.matchBrackets.currentlyHighlighted&&(B.state.matchBrackets.currentlyHighlighted(),B.state.matchBrackets.currentlyHighlighted=null),B.state.matchBrackets.currentlyHighlighted=g(B,!1,B.state.matchBrackets)})}function k(B){B.state.matchBrackets&&B.state.matchBrackets.currentlyHighlighted&&(B.state.matchBrackets.currentlyHighlighted(),B.state.matchBrackets.currentlyHighlighted=null)}t.defineOption("matchBrackets",!1,function(B,P,R){R&&R!=t.Init&&(B.off("cursorActivity",x),B.off("focus",x),B.off("blur",k),k(B)),P&&(B.state.matchBrackets=typeof P=="object"?P:{},B.on("cursorActivity",x),B.on("focus",x),B.on("blur",k))}),t.defineExtension("matchBrackets",function(){g(this,!0)}),t.defineExtension("findMatchingBracket",function(B,P,R){return(R||typeof P=="boolean")&&(R?(R.strict=P,P=R):P=P?{strict:!0}:null),a(this,B,P)}),t.defineExtension("scanForBracket",function(B,P,R,H){return f(this,B,P,R,H)})})})();var npe=/("(?:[^\\"]|\\.)*")|[:,]/g,rpe=function(n,t){var r,i,o;return t=t||{},r=JSON.stringify([1],void 0,t.indent===void 0?2:t.indent).slice(2,-3),i=r===""?1/0:t.maxLength===void 0?80:t.maxLength,o=t.replacer,function s(a,f,g){var x,k,B,P,R,H,W,$,q,oe,ne,ce;if(a&&typeof a.toJSON=="function"&&(a=a.toJSON()),ne=JSON.stringify(a,o),ne===void 0)return ne;if(W=i-f.length-g,ne.length<=W&&(q=ne.replace(npe,function(ae,ue){return ue||ae+" "}),q.length<=W))return q;if(o!=null&&(a=JSON.parse(ne),o=void 0),typeof a=="object"&&a!==null){if($=f+r,B=[],k=0,Array.isArray(a))for(oe="[",x="]",W=a.length;k<W;k++)B.push(s(a[k],$,k===W-1?0:1)||"null");else for(oe="{",x="}",H=Object.keys(a),W=H.length;k<W;k++)P=H[k],R=JSON.stringify(P)+": ",ce=s(a[P],$,R.length+(k===W-1?0:1)),ce!==void 0&&B.push(R+ce);if(B.length>0)return[oe,r+B.join(`,
|
||
`+$),x].join(`
|
||
`+f)}return ne}(n,"",0)};const _W=ga(rpe);function ipe(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var bW={};(function(e){var n=function(){var t={trace:function(){},yy:{},symbols_:{error:2,JSONString:3,STRING:4,JSONNumber:5,NUMBER:6,JSONNullLiteral:7,NULL:8,JSONBooleanLiteral:9,TRUE:10,FALSE:11,JSONText:12,JSONValue:13,EOF:14,JSONObject:15,JSONArray:16,"{":17,"}":18,JSONMemberList:19,JSONMember:20,":":21,",":22,"[":23,"]":24,JSONElementList:25,$accept:0,$end:1},terminals_:{2:"error",4:"STRING",6:"NUMBER",8:"NULL",10:"TRUE",11:"FALSE",14:"EOF",17:"{",18:"}",21:":",22:",",23:"[",24:"]"},productions_:[0,[3,1],[5,1],[7,1],[9,1],[9,1],[12,2],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[15,2],[15,3],[20,3],[19,1],[19,3],[16,2],[16,3],[25,1],[25,3]],performAction:function(o,s,a,f,g,x,k){var B=x.length-1;switch(g){case 1:this.$=o.replace(/\\(\\|")/g,"$1").replace(/\\n/g,`
|
||
`).replace(/\\r/g,"\r").replace(/\\t/g," ").replace(/\\v/g,"\v").replace(/\\f/g,"\f").replace(/\\b/g,"\b");break;case 2:this.$=Number(o);break;case 3:this.$=null;break;case 4:this.$=!0;break;case 5:this.$=!1;break;case 6:return this.$=x[B-1];case 13:this.$={};break;case 14:this.$=x[B-1];break;case 15:this.$=[x[B-2],x[B]];break;case 16:this.$={},this.$[x[B][0]]=x[B][1];break;case 17:this.$=x[B-2],x[B-2][x[B][0]]=x[B][1];break;case 18:this.$=[];break;case 19:this.$=x[B-1];break;case 20:this.$=[x[B]];break;case 21:this.$=x[B-2],x[B-2].push(x[B]);break}},table:[{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],12:1,13:2,15:7,16:8,17:[1,14],23:[1,15]},{1:[3]},{14:[1,16]},{14:[2,7],18:[2,7],22:[2,7],24:[2,7]},{14:[2,8],18:[2,8],22:[2,8],24:[2,8]},{14:[2,9],18:[2,9],22:[2,9],24:[2,9]},{14:[2,10],18:[2,10],22:[2,10],24:[2,10]},{14:[2,11],18:[2,11],22:[2,11],24:[2,11]},{14:[2,12],18:[2,12],22:[2,12],24:[2,12]},{14:[2,3],18:[2,3],22:[2,3],24:[2,3]},{14:[2,4],18:[2,4],22:[2,4],24:[2,4]},{14:[2,5],18:[2,5],22:[2,5],24:[2,5]},{14:[2,1],18:[2,1],21:[2,1],22:[2,1],24:[2,1]},{14:[2,2],18:[2,2],22:[2,2],24:[2,2]},{3:20,4:[1,12],18:[1,17],19:18,20:19},{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],13:23,15:7,16:8,17:[1,14],23:[1,15],24:[1,21],25:22},{1:[2,6]},{14:[2,13],18:[2,13],22:[2,13],24:[2,13]},{18:[1,24],22:[1,25]},{18:[2,16],22:[2,16]},{21:[1,26]},{14:[2,18],18:[2,18],22:[2,18],24:[2,18]},{22:[1,28],24:[1,27]},{22:[2,20],24:[2,20]},{14:[2,14],18:[2,14],22:[2,14],24:[2,14]},{3:20,4:[1,12],20:29},{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],13:30,15:7,16:8,17:[1,14],23:[1,15]},{14:[2,19],18:[2,19],22:[2,19],24:[2,19]},{3:5,4:[1,12],5:6,6:[1,13],7:3,8:[1,9],9:4,10:[1,10],11:[1,11],13:31,15:7,16:8,17:[1,14],23:[1,15]},{18:[2,17],22:[2,17]},{18:[2,15],22:[2,15]},{22:[2,21],24:[2,21]}],defaultActions:{16:[2,6]},parseError:function(o,s){throw new Error(o)},parse:function(o){var s=this,a=[0],f=[null],g=[],x=this.table,k="",B=0,P=0,R=0,H=2,W=1;this.lexer.setInput(o),this.lexer.yy=this.yy,this.yy.lexer=this.lexer,typeof this.lexer.yylloc>"u"&&(this.lexer.yylloc={});var $=this.lexer.yylloc;g.push($),typeof this.yy.parseError=="function"&&(this.parseError=this.yy.parseError);function q(Ce){a.length=a.length-2*Ce,f.length=f.length-Ce,g.length=g.length-Ce}function oe(){var Ce;return Ce=s.lexer.lex()||1,typeof Ce!="number"&&(Ce=s.symbols_[Ce]||Ce),Ce}for(var ne,ce,ae,ue,ye,Re={},Ne,rt,ct,Fe;;){if(ae=a[a.length-1],this.defaultActions[ae]?ue=this.defaultActions[ae]:(ne==null&&(ne=oe()),ue=x[ae]&&x[ae][ne]),typeof ue>"u"||!ue.length||!ue[0]){if(!R){Fe=[];for(Ne in x[ae])this.terminals_[Ne]&&Ne>2&&Fe.push("'"+this.terminals_[Ne]+"'");var He="";this.lexer.showPosition?He="Parse error on line "+(B+1)+`:
|
||
`+this.lexer.showPosition()+`
|
||
Expecting `+Fe.join(", ")+", got '"+this.terminals_[ne]+"'":He="Parse error on line "+(B+1)+": Unexpected "+(ne==1?"end of input":"'"+(this.terminals_[ne]||ne)+"'"),this.parseError(He,{text:this.lexer.match,token:this.terminals_[ne]||ne,line:this.lexer.yylineno,loc:$,expected:Fe})}if(R==3){if(ne==W)throw new Error(He||"Parsing halted.");P=this.lexer.yyleng,k=this.lexer.yytext,B=this.lexer.yylineno,$=this.lexer.yylloc,ne=oe()}for(;!(H.toString()in x[ae]);){if(ae==0)throw new Error(He||"Parsing halted.");q(1),ae=a[a.length-1]}ce=ne,ne=H,ae=a[a.length-1],ue=x[ae]&&x[ae][H],R=3}if(ue[0]instanceof Array&&ue.length>1)throw new Error("Parse Error: multiple actions possible at state: "+ae+", token: "+ne);switch(ue[0]){case 1:a.push(ne),f.push(this.lexer.yytext),g.push(this.lexer.yylloc),a.push(ue[1]),ne=null,ce?(ne=ce,ce=null):(P=this.lexer.yyleng,k=this.lexer.yytext,B=this.lexer.yylineno,$=this.lexer.yylloc,R>0&&R--);break;case 2:if(rt=this.productions_[ue[1]][1],Re.$=f[f.length-rt],Re._$={first_line:g[g.length-(rt||1)].first_line,last_line:g[g.length-1].last_line,first_column:g[g.length-(rt||1)].first_column,last_column:g[g.length-1].last_column},ye=this.performAction.call(Re,k,P,B,this.yy,ue[1],f,g),typeof ye<"u")return ye;rt&&(a=a.slice(0,-1*rt*2),f=f.slice(0,-1*rt),g=g.slice(0,-1*rt)),a.push(this.productions_[ue[1]][0]),f.push(Re.$),g.push(Re._$),ct=x[a[a.length-2]][a[a.length-1]],a.push(ct);break;case 3:return!0}}return!0}},r=function(){var i={EOF:1,parseError:function(s,a){if(this.yy.parseError)this.yy.parseError(s,a);else throw new Error(s)},setInput:function(o){return this._input=o,this._more=this._less=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this},input:function(){var o=this._input[0];this.yytext+=o,this.yyleng++,this.match+=o,this.matched+=o;var s=o.match(/\n/);return s&&this.yylineno++,this._input=this._input.slice(1),o},unput:function(o){return this._input=o+this._input,this},more:function(){return this._more=!0,this},less:function(o){this._input=this.match.slice(o)+this._input},pastInput:function(){var o=this.matched.substr(0,this.matched.length-this.match.length);return(o.length>20?"...":"")+o.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var o=this.match;return o.length<20&&(o+=this._input.substr(0,20-o.length)),(o.substr(0,20)+(o.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var o=this.pastInput(),s=new Array(o.length+1).join("-");return o+this.upcomingInput()+`
|
||
`+s+"^"},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);var o,s,a,f,g;this._more||(this.yytext="",this.match="");for(var x=this._currentRules(),k=0;k<x.length&&(a=this._input.match(this.rules[x[k]]),!(a&&(!s||a[0].length>s[0].length)&&(s=a,f=k,!this.options.flex)));k++);if(s)return g=s[0].match(/\n.*/g),g&&(this.yylineno+=g.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:g?g[g.length-1].length-1:this.yylloc.last_column+s[0].length},this.yytext+=s[0],this.match+=s[0],this.yyleng=this.yytext.length,this._more=!1,this._input=this._input.slice(s[0].length),this.matched+=s[0],o=this.performAction.call(this,this.yy,this,x[f],this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),o||void 0;if(this._input==="")return this.EOF;this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
||
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var s=this.next();return typeof s<"u"?s:this.lex()},begin:function(s){this.conditionStack.push(s)},popState:function(){return this.conditionStack.pop()},_currentRules:function(){return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules},topState:function(){return this.conditionStack[this.conditionStack.length-2]},pushState:function(s){this.begin(s)}};return i.options={},i.performAction=function(s,a,f,g){switch(f){case 0:break;case 1:return 6;case 2:return a.yytext=a.yytext.substr(1,a.yyleng-2),4;case 3:return 17;case 4:return 18;case 5:return 23;case 6:return 24;case 7:return 22;case 8:return 21;case 9:return 10;case 10:return 11;case 11:return 8;case 12:return 14;case 13:return"INVALID"}},i.rules=[/^(?:\s+)/,/^(?:(-?([0-9]|[1-9][0-9]+))(\.[0-9]+)?([eE][-+]?[0-9]+)?\b)/,/^(?:"(?:\\[\\"bfnrt/]|\\u[a-fA-F0-9]{4}|[^\\\0-\x09\x0a-\x1f"])*")/,/^(?:\{)/,/^(?:\})/,/^(?:\[)/,/^(?:\])/,/^(?:,)/,/^(?::)/,/^(?:true\b)/,/^(?:false\b)/,/^(?:null\b)/,/^(?:$)/,/^(?:.)/],i.conditions={INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13],inclusive:!0}},i}();return t.lexer=r,t}();typeof ipe<"u"&&(e.parser=n,e.parse=n.parse.bind(n))})(bW);const WE=ga(bW);var xW={exports:{}};(function(e,n){(function(t,r){e.exports=r()})(mf,function(){var t=typeof window<"u"||typeof window<"u"?window:typeof self<"u"?self:{};function r(de,xe){return xe={exports:{}},de(xe,xe.exports),xe.exports}var i=r(function(de){function xe(){var Pe=0,Ze=1,Xe=2,wt=3,Kt=4,Pt=5,zn=6,mt=7,pn=8,ir=9,Sn=10,nr=11,Mr=12,Qr=13,_r=14,vi=15,we=16,V=17,X=0,me=1,At=2,bt=3,Et=4;function sr(m,un){return 55296<=m.charCodeAt(un)&&m.charCodeAt(un)<=56319&&56320<=m.charCodeAt(un+1)&&m.charCodeAt(un+1)<=57343}function Lt(m,un){un===void 0&&(un=0);var In=m.charCodeAt(un);if(55296<=In&&In<=56319&&un<m.length-1){var Gn=In,Zn=m.charCodeAt(un+1);return 56320<=Zn&&Zn<=57343?(Gn-55296)*1024+(Zn-56320)+65536:Gn}if(56320<=In&&In<=57343&&un>=1){var Gn=m.charCodeAt(un-1),Zn=In;return 55296<=Gn&&Gn<=56319?(Gn-55296)*1024+(Zn-56320)+65536:Zn}return In}function Fn(m,un,In){var Gn=[m].concat(un).concat([In]),Zn=Gn[Gn.length-2],Ke=In,fe=Gn.lastIndexOf(_r);if(fe>1&&Gn.slice(1,fe).every(function(Te){return Te==wt})&&[wt,Qr,V].indexOf(m)==-1)return At;var _e=Gn.lastIndexOf(Kt);if(_e>0&&Gn.slice(1,_e).every(function(Te){return Te==Kt})&&[Mr,Kt].indexOf(Zn)==-1)return Gn.filter(function(Te){return Te==Kt}).length%2==1?bt:Et;if(Zn==Pe&&Ke==Ze)return X;if(Zn==Xe||Zn==Pe||Zn==Ze)return Ke==_r&&un.every(function(Te){return Te==wt})?At:me;if(Ke==Xe||Ke==Pe||Ke==Ze)return me;if(Zn==zn&&(Ke==zn||Ke==mt||Ke==ir||Ke==Sn))return X;if((Zn==ir||Zn==mt)&&(Ke==mt||Ke==pn))return X;if((Zn==Sn||Zn==pn)&&Ke==pn)return X;if(Ke==wt||Ke==vi)return X;if(Ke==Pt)return X;if(Zn==Mr)return X;var Ee=Gn.indexOf(wt)!=-1?Gn.lastIndexOf(wt)-1:Gn.length-2;return[Qr,V].indexOf(Gn[Ee])!=-1&&Gn.slice(Ee+1,-1).every(function(Te){return Te==wt})&&Ke==_r||Zn==vi&&[we,V].indexOf(Ke)!=-1?X:un.indexOf(Kt)!=-1?At:Zn==Kt&&Ke==Kt?X:me}this.nextBreak=function(m,un){if(un===void 0&&(un=0),un<0)return 0;if(un>=m.length-1)return m.length;for(var In=on(Lt(m,un)),Gn=[],Zn=un+1;Zn<m.length;Zn++)if(!sr(m,Zn-1)){var Ke=on(Lt(m,Zn));if(Fn(In,Gn,Ke))return Zn;Gn.push(Ke)}return m.length},this.splitGraphemes=function(m){for(var un=[],In=0,Gn;(Gn=this.nextBreak(m,In))<m.length;)un.push(m.slice(In,Gn)),In=Gn;return In<m.length&&un.push(m.slice(In)),un},this.iterateGraphemes=function(m){var un=0,In={next:(function(){var Gn,Zn;return(Zn=this.nextBreak(m,un))<m.length?(Gn=m.slice(un,Zn),un=Zn,{value:Gn,done:!1}):un<m.length?(Gn=m.slice(un),un=m.length,{value:Gn,done:!1}):{value:void 0,done:!0}}).bind(this)};return typeof Symbol<"u"&&Symbol.iterator&&(In[Symbol.iterator]=function(){return In}),In},this.countGraphemes=function(m){for(var un=0,In=0,Gn;(Gn=this.nextBreak(m,In))<m.length;)In=Gn,un++;return In<m.length&&un++,un};function on(m){return 1536<=m&&m<=1541||m==1757||m==1807||m==2274||m==3406||m==69821||70082<=m&&m<=70083||m==72250||72326<=m&&m<=72329||m==73030?Mr:m==13?Pe:m==10?Ze:0<=m&&m<=9||11<=m&&m<=12||14<=m&&m<=31||127<=m&&m<=159||m==173||m==1564||m==6158||m==8203||8206<=m&&m<=8207||m==8232||m==8233||8234<=m&&m<=8238||8288<=m&&m<=8292||m==8293||8294<=m&&m<=8303||55296<=m&&m<=57343||m==65279||65520<=m&&m<=65528||65529<=m&&m<=65531||113824<=m&&m<=113827||119155<=m&&m<=119162||m==917504||m==917505||917506<=m&&m<=917535||917632<=m&&m<=917759||918e3<=m&&m<=921599?Xe:768<=m&&m<=879||1155<=m&&m<=1159||1160<=m&&m<=1161||1425<=m&&m<=1469||m==1471||1473<=m&&m<=1474||1476<=m&&m<=1477||m==1479||1552<=m&&m<=1562||1611<=m&&m<=1631||m==1648||1750<=m&&m<=1756||1759<=m&&m<=1764||1767<=m&&m<=1768||1770<=m&&m<=1773||m==1809||1840<=m&&m<=1866||1958<=m&&m<=1968||2027<=m&&m<=2035||2070<=m&&m<=2073||2075<=m&&m<=2083||2085<=m&&m<=2087||2089<=m&&m<=2093||2137<=m&&m<=2139||2260<=m&&m<=2273||2275<=m&&m<=2306||m==2362||m==2364||2369<=m&&m<=2376||m==2381||2385<=m&&m<=2391||2402<=m&&m<=2403||m==2433||m==2492||m==2494||2497<=m&&m<=2500||m==2509||m==2519||2530<=m&&m<=2531||2561<=m&&m<=2562||m==2620||2625<=m&&m<=2626||2631<=m&&m<=2632||2635<=m&&m<=2637||m==2641||2672<=m&&m<=2673||m==2677||2689<=m&&m<=2690||m==2748||2753<=m&&m<=2757||2759<=m&&m<=2760||m==2765||2786<=m&&m<=2787||2810<=m&&m<=2815||m==2817||m==2876||m==2878||m==2879||2881<=m&&m<=2884||m==2893||m==2902||m==2903||2914<=m&&m<=2915||m==2946||m==3006||m==3008||m==3021||m==3031||m==3072||3134<=m&&m<=3136||3142<=m&&m<=3144||3146<=m&&m<=3149||3157<=m&&m<=3158||3170<=m&&m<=3171||m==3201||m==3260||m==3263||m==3266||m==3270||3276<=m&&m<=3277||3285<=m&&m<=3286||3298<=m&&m<=3299||3328<=m&&m<=3329||3387<=m&&m<=3388||m==3390||3393<=m&&m<=3396||m==3405||m==3415||3426<=m&&m<=3427||m==3530||m==3535||3538<=m&&m<=3540||m==3542||m==3551||m==3633||3636<=m&&m<=3642||3655<=m&&m<=3662||m==3761||3764<=m&&m<=3769||3771<=m&&m<=3772||3784<=m&&m<=3789||3864<=m&&m<=3865||m==3893||m==3895||m==3897||3953<=m&&m<=3966||3968<=m&&m<=3972||3974<=m&&m<=3975||3981<=m&&m<=3991||3993<=m&&m<=4028||m==4038||4141<=m&&m<=4144||4146<=m&&m<=4151||4153<=m&&m<=4154||4157<=m&&m<=4158||4184<=m&&m<=4185||4190<=m&&m<=4192||4209<=m&&m<=4212||m==4226||4229<=m&&m<=4230||m==4237||m==4253||4957<=m&&m<=4959||5906<=m&&m<=5908||5938<=m&&m<=5940||5970<=m&&m<=5971||6002<=m&&m<=6003||6068<=m&&m<=6069||6071<=m&&m<=6077||m==6086||6089<=m&&m<=6099||m==6109||6155<=m&&m<=6157||6277<=m&&m<=6278||m==6313||6432<=m&&m<=6434||6439<=m&&m<=6440||m==6450||6457<=m&&m<=6459||6679<=m&&m<=6680||m==6683||m==6742||6744<=m&&m<=6750||m==6752||m==6754||6757<=m&&m<=6764||6771<=m&&m<=6780||m==6783||6832<=m&&m<=6845||m==6846||6912<=m&&m<=6915||m==6964||6966<=m&&m<=6970||m==6972||m==6978||7019<=m&&m<=7027||7040<=m&&m<=7041||7074<=m&&m<=7077||7080<=m&&m<=7081||7083<=m&&m<=7085||m==7142||7144<=m&&m<=7145||m==7149||7151<=m&&m<=7153||7212<=m&&m<=7219||7222<=m&&m<=7223||7376<=m&&m<=7378||7380<=m&&m<=7392||7394<=m&&m<=7400||m==7405||m==7412||7416<=m&&m<=7417||7616<=m&&m<=7673||7675<=m&&m<=7679||m==8204||8400<=m&&m<=8412||8413<=m&&m<=8416||m==8417||8418<=m&&m<=8420||8421<=m&&m<=8432||11503<=m&&m<=11505||m==11647||11744<=m&&m<=11775||12330<=m&&m<=12333||12334<=m&&m<=12335||12441<=m&&m<=12442||m==42607||42608<=m&&m<=42610||42612<=m&&m<=42621||42654<=m&&m<=42655||42736<=m&&m<=42737||m==43010||m==43014||m==43019||43045<=m&&m<=43046||43204<=m&&m<=43205||43232<=m&&m<=43249||43302<=m&&m<=43309||43335<=m&&m<=43345||43392<=m&&m<=43394||m==43443||43446<=m&&m<=43449||m==43452||m==43493||43561<=m&&m<=43566||43569<=m&&m<=43570||43573<=m&&m<=43574||m==43587||m==43596||m==43644||m==43696||43698<=m&&m<=43700||43703<=m&&m<=43704||43710<=m&&m<=43711||m==43713||43756<=m&&m<=43757||m==43766||m==44005||m==44008||m==44013||m==64286||65024<=m&&m<=65039||65056<=m&&m<=65071||65438<=m&&m<=65439||m==66045||m==66272||66422<=m&&m<=66426||68097<=m&&m<=68099||68101<=m&&m<=68102||68108<=m&&m<=68111||68152<=m&&m<=68154||m==68159||68325<=m&&m<=68326||m==69633||69688<=m&&m<=69702||69759<=m&&m<=69761||69811<=m&&m<=69814||69817<=m&&m<=69818||69888<=m&&m<=69890||69927<=m&&m<=69931||69933<=m&&m<=69940||m==70003||70016<=m&&m<=70017||70070<=m&&m<=70078||70090<=m&&m<=70092||70191<=m&&m<=70193||m==70196||70198<=m&&m<=70199||m==70206||m==70367||70371<=m&&m<=70378||70400<=m&&m<=70401||m==70460||m==70462||m==70464||m==70487||70502<=m&&m<=70508||70512<=m&&m<=70516||70712<=m&&m<=70719||70722<=m&&m<=70724||m==70726||m==70832||70835<=m&&m<=70840||m==70842||m==70845||70847<=m&&m<=70848||70850<=m&&m<=70851||m==71087||71090<=m&&m<=71093||71100<=m&&m<=71101||71103<=m&&m<=71104||71132<=m&&m<=71133||71219<=m&&m<=71226||m==71229||71231<=m&&m<=71232||m==71339||m==71341||71344<=m&&m<=71349||m==71351||71453<=m&&m<=71455||71458<=m&&m<=71461||71463<=m&&m<=71467||72193<=m&&m<=72198||72201<=m&&m<=72202||72243<=m&&m<=72248||72251<=m&&m<=72254||m==72263||72273<=m&&m<=72278||72281<=m&&m<=72283||72330<=m&&m<=72342||72344<=m&&m<=72345||72752<=m&&m<=72758||72760<=m&&m<=72765||m==72767||72850<=m&&m<=72871||72874<=m&&m<=72880||72882<=m&&m<=72883||72885<=m&&m<=72886||73009<=m&&m<=73014||m==73018||73020<=m&&m<=73021||73023<=m&&m<=73029||m==73031||92912<=m&&m<=92916||92976<=m&&m<=92982||94095<=m&&m<=94098||113821<=m&&m<=113822||m==119141||119143<=m&&m<=119145||119150<=m&&m<=119154||119163<=m&&m<=119170||119173<=m&&m<=119179||119210<=m&&m<=119213||119362<=m&&m<=119364||121344<=m&&m<=121398||121403<=m&&m<=121452||m==121461||m==121476||121499<=m&&m<=121503||121505<=m&&m<=121519||122880<=m&&m<=122886||122888<=m&&m<=122904||122907<=m&&m<=122913||122915<=m&&m<=122916||122918<=m&&m<=122922||125136<=m&&m<=125142||125252<=m&&m<=125258||917536<=m&&m<=917631||917760<=m&&m<=917999?wt:127462<=m&&m<=127487?Kt:m==2307||m==2363||2366<=m&&m<=2368||2377<=m&&m<=2380||2382<=m&&m<=2383||2434<=m&&m<=2435||2495<=m&&m<=2496||2503<=m&&m<=2504||2507<=m&&m<=2508||m==2563||2622<=m&&m<=2624||m==2691||2750<=m&&m<=2752||m==2761||2763<=m&&m<=2764||2818<=m&&m<=2819||m==2880||2887<=m&&m<=2888||2891<=m&&m<=2892||m==3007||3009<=m&&m<=3010||3014<=m&&m<=3016||3018<=m&&m<=3020||3073<=m&&m<=3075||3137<=m&&m<=3140||3202<=m&&m<=3203||m==3262||3264<=m&&m<=3265||3267<=m&&m<=3268||3271<=m&&m<=3272||3274<=m&&m<=3275||3330<=m&&m<=3331||3391<=m&&m<=3392||3398<=m&&m<=3400||3402<=m&&m<=3404||3458<=m&&m<=3459||3536<=m&&m<=3537||3544<=m&&m<=3550||3570<=m&&m<=3571||m==3635||m==3763||3902<=m&&m<=3903||m==3967||m==4145||4155<=m&&m<=4156||4182<=m&&m<=4183||m==4228||m==6070||6078<=m&&m<=6085||6087<=m&&m<=6088||6435<=m&&m<=6438||6441<=m&&m<=6443||6448<=m&&m<=6449||6451<=m&&m<=6456||6681<=m&&m<=6682||m==6741||m==6743||6765<=m&&m<=6770||m==6916||m==6965||m==6971||6973<=m&&m<=6977||6979<=m&&m<=6980||m==7042||m==7073||7078<=m&&m<=7079||m==7082||m==7143||7146<=m&&m<=7148||m==7150||7154<=m&&m<=7155||7204<=m&&m<=7211||7220<=m&&m<=7221||m==7393||7410<=m&&m<=7411||m==7415||43043<=m&&m<=43044||m==43047||43136<=m&&m<=43137||43188<=m&&m<=43203||43346<=m&&m<=43347||m==43395||43444<=m&&m<=43445||43450<=m&&m<=43451||43453<=m&&m<=43456||43567<=m&&m<=43568||43571<=m&&m<=43572||m==43597||m==43755||43758<=m&&m<=43759||m==43765||44003<=m&&m<=44004||44006<=m&&m<=44007||44009<=m&&m<=44010||m==44012||m==69632||m==69634||m==69762||69808<=m&&m<=69810||69815<=m&&m<=69816||m==69932||m==70018||70067<=m&&m<=70069||70079<=m&&m<=70080||70188<=m&&m<=70190||70194<=m&&m<=70195||m==70197||70368<=m&&m<=70370||70402<=m&&m<=70403||m==70463||70465<=m&&m<=70468||70471<=m&&m<=70472||70475<=m&&m<=70477||70498<=m&&m<=70499||70709<=m&&m<=70711||70720<=m&&m<=70721||m==70725||70833<=m&&m<=70834||m==70841||70843<=m&&m<=70844||m==70846||m==70849||71088<=m&&m<=71089||71096<=m&&m<=71099||m==71102||71216<=m&&m<=71218||71227<=m&&m<=71228||m==71230||m==71340||71342<=m&&m<=71343||m==71350||71456<=m&&m<=71457||m==71462||72199<=m&&m<=72200||m==72249||72279<=m&&m<=72280||m==72343||m==72751||m==72766||m==72873||m==72881||m==72884||94033<=m&&m<=94078||m==119142||m==119149?Pt:4352<=m&&m<=4447||43360<=m&&m<=43388?zn:4448<=m&&m<=4519||55216<=m&&m<=55238?mt:4520<=m&&m<=4607||55243<=m&&m<=55291?pn:m==44032||m==44060||m==44088||m==44116||m==44144||m==44172||m==44200||m==44228||m==44256||m==44284||m==44312||m==44340||m==44368||m==44396||m==44424||m==44452||m==44480||m==44508||m==44536||m==44564||m==44592||m==44620||m==44648||m==44676||m==44704||m==44732||m==44760||m==44788||m==44816||m==44844||m==44872||m==44900||m==44928||m==44956||m==44984||m==45012||m==45040||m==45068||m==45096||m==45124||m==45152||m==45180||m==45208||m==45236||m==45264||m==45292||m==45320||m==45348||m==45376||m==45404||m==45432||m==45460||m==45488||m==45516||m==45544||m==45572||m==45600||m==45628||m==45656||m==45684||m==45712||m==45740||m==45768||m==45796||m==45824||m==45852||m==45880||m==45908||m==45936||m==45964||m==45992||m==46020||m==46048||m==46076||m==46104||m==46132||m==46160||m==46188||m==46216||m==46244||m==46272||m==46300||m==46328||m==46356||m==46384||m==46412||m==46440||m==46468||m==46496||m==46524||m==46552||m==46580||m==46608||m==46636||m==46664||m==46692||m==46720||m==46748||m==46776||m==46804||m==46832||m==46860||m==46888||m==46916||m==46944||m==46972||m==47e3||m==47028||m==47056||m==47084||m==47112||m==47140||m==47168||m==47196||m==47224||m==47252||m==47280||m==47308||m==47336||m==47364||m==47392||m==47420||m==47448||m==47476||m==47504||m==47532||m==47560||m==47588||m==47616||m==47644||m==47672||m==47700||m==47728||m==47756||m==47784||m==47812||m==47840||m==47868||m==47896||m==47924||m==47952||m==47980||m==48008||m==48036||m==48064||m==48092||m==48120||m==48148||m==48176||m==48204||m==48232||m==48260||m==48288||m==48316||m==48344||m==48372||m==48400||m==48428||m==48456||m==48484||m==48512||m==48540||m==48568||m==48596||m==48624||m==48652||m==48680||m==48708||m==48736||m==48764||m==48792||m==48820||m==48848||m==48876||m==48904||m==48932||m==48960||m==48988||m==49016||m==49044||m==49072||m==49100||m==49128||m==49156||m==49184||m==49212||m==49240||m==49268||m==49296||m==49324||m==49352||m==49380||m==49408||m==49436||m==49464||m==49492||m==49520||m==49548||m==49576||m==49604||m==49632||m==49660||m==49688||m==49716||m==49744||m==49772||m==49800||m==49828||m==49856||m==49884||m==49912||m==49940||m==49968||m==49996||m==50024||m==50052||m==50080||m==50108||m==50136||m==50164||m==50192||m==50220||m==50248||m==50276||m==50304||m==50332||m==50360||m==50388||m==50416||m==50444||m==50472||m==50500||m==50528||m==50556||m==50584||m==50612||m==50640||m==50668||m==50696||m==50724||m==50752||m==50780||m==50808||m==50836||m==50864||m==50892||m==50920||m==50948||m==50976||m==51004||m==51032||m==51060||m==51088||m==51116||m==51144||m==51172||m==51200||m==51228||m==51256||m==51284||m==51312||m==51340||m==51368||m==51396||m==51424||m==51452||m==51480||m==51508||m==51536||m==51564||m==51592||m==51620||m==51648||m==51676||m==51704||m==51732||m==51760||m==51788||m==51816||m==51844||m==51872||m==51900||m==51928||m==51956||m==51984||m==52012||m==52040||m==52068||m==52096||m==52124||m==52152||m==52180||m==52208||m==52236||m==52264||m==52292||m==52320||m==52348||m==52376||m==52404||m==52432||m==52460||m==52488||m==52516||m==52544||m==52572||m==52600||m==52628||m==52656||m==52684||m==52712||m==52740||m==52768||m==52796||m==52824||m==52852||m==52880||m==52908||m==52936||m==52964||m==52992||m==53020||m==53048||m==53076||m==53104||m==53132||m==53160||m==53188||m==53216||m==53244||m==53272||m==53300||m==53328||m==53356||m==53384||m==53412||m==53440||m==53468||m==53496||m==53524||m==53552||m==53580||m==53608||m==53636||m==53664||m==53692||m==53720||m==53748||m==53776||m==53804||m==53832||m==53860||m==53888||m==53916||m==53944||m==53972||m==54e3||m==54028||m==54056||m==54084||m==54112||m==54140||m==54168||m==54196||m==54224||m==54252||m==54280||m==54308||m==54336||m==54364||m==54392||m==54420||m==54448||m==54476||m==54504||m==54532||m==54560||m==54588||m==54616||m==54644||m==54672||m==54700||m==54728||m==54756||m==54784||m==54812||m==54840||m==54868||m==54896||m==54924||m==54952||m==54980||m==55008||m==55036||m==55064||m==55092||m==55120||m==55148||m==55176?ir:44033<=m&&m<=44059||44061<=m&&m<=44087||44089<=m&&m<=44115||44117<=m&&m<=44143||44145<=m&&m<=44171||44173<=m&&m<=44199||44201<=m&&m<=44227||44229<=m&&m<=44255||44257<=m&&m<=44283||44285<=m&&m<=44311||44313<=m&&m<=44339||44341<=m&&m<=44367||44369<=m&&m<=44395||44397<=m&&m<=44423||44425<=m&&m<=44451||44453<=m&&m<=44479||44481<=m&&m<=44507||44509<=m&&m<=44535||44537<=m&&m<=44563||44565<=m&&m<=44591||44593<=m&&m<=44619||44621<=m&&m<=44647||44649<=m&&m<=44675||44677<=m&&m<=44703||44705<=m&&m<=44731||44733<=m&&m<=44759||44761<=m&&m<=44787||44789<=m&&m<=44815||44817<=m&&m<=44843||44845<=m&&m<=44871||44873<=m&&m<=44899||44901<=m&&m<=44927||44929<=m&&m<=44955||44957<=m&&m<=44983||44985<=m&&m<=45011||45013<=m&&m<=45039||45041<=m&&m<=45067||45069<=m&&m<=45095||45097<=m&&m<=45123||45125<=m&&m<=45151||45153<=m&&m<=45179||45181<=m&&m<=45207||45209<=m&&m<=45235||45237<=m&&m<=45263||45265<=m&&m<=45291||45293<=m&&m<=45319||45321<=m&&m<=45347||45349<=m&&m<=45375||45377<=m&&m<=45403||45405<=m&&m<=45431||45433<=m&&m<=45459||45461<=m&&m<=45487||45489<=m&&m<=45515||45517<=m&&m<=45543||45545<=m&&m<=45571||45573<=m&&m<=45599||45601<=m&&m<=45627||45629<=m&&m<=45655||45657<=m&&m<=45683||45685<=m&&m<=45711||45713<=m&&m<=45739||45741<=m&&m<=45767||45769<=m&&m<=45795||45797<=m&&m<=45823||45825<=m&&m<=45851||45853<=m&&m<=45879||45881<=m&&m<=45907||45909<=m&&m<=45935||45937<=m&&m<=45963||45965<=m&&m<=45991||45993<=m&&m<=46019||46021<=m&&m<=46047||46049<=m&&m<=46075||46077<=m&&m<=46103||46105<=m&&m<=46131||46133<=m&&m<=46159||46161<=m&&m<=46187||46189<=m&&m<=46215||46217<=m&&m<=46243||46245<=m&&m<=46271||46273<=m&&m<=46299||46301<=m&&m<=46327||46329<=m&&m<=46355||46357<=m&&m<=46383||46385<=m&&m<=46411||46413<=m&&m<=46439||46441<=m&&m<=46467||46469<=m&&m<=46495||46497<=m&&m<=46523||46525<=m&&m<=46551||46553<=m&&m<=46579||46581<=m&&m<=46607||46609<=m&&m<=46635||46637<=m&&m<=46663||46665<=m&&m<=46691||46693<=m&&m<=46719||46721<=m&&m<=46747||46749<=m&&m<=46775||46777<=m&&m<=46803||46805<=m&&m<=46831||46833<=m&&m<=46859||46861<=m&&m<=46887||46889<=m&&m<=46915||46917<=m&&m<=46943||46945<=m&&m<=46971||46973<=m&&m<=46999||47001<=m&&m<=47027||47029<=m&&m<=47055||47057<=m&&m<=47083||47085<=m&&m<=47111||47113<=m&&m<=47139||47141<=m&&m<=47167||47169<=m&&m<=47195||47197<=m&&m<=47223||47225<=m&&m<=47251||47253<=m&&m<=47279||47281<=m&&m<=47307||47309<=m&&m<=47335||47337<=m&&m<=47363||47365<=m&&m<=47391||47393<=m&&m<=47419||47421<=m&&m<=47447||47449<=m&&m<=47475||47477<=m&&m<=47503||47505<=m&&m<=47531||47533<=m&&m<=47559||47561<=m&&m<=47587||47589<=m&&m<=47615||47617<=m&&m<=47643||47645<=m&&m<=47671||47673<=m&&m<=47699||47701<=m&&m<=47727||47729<=m&&m<=47755||47757<=m&&m<=47783||47785<=m&&m<=47811||47813<=m&&m<=47839||47841<=m&&m<=47867||47869<=m&&m<=47895||47897<=m&&m<=47923||47925<=m&&m<=47951||47953<=m&&m<=47979||47981<=m&&m<=48007||48009<=m&&m<=48035||48037<=m&&m<=48063||48065<=m&&m<=48091||48093<=m&&m<=48119||48121<=m&&m<=48147||48149<=m&&m<=48175||48177<=m&&m<=48203||48205<=m&&m<=48231||48233<=m&&m<=48259||48261<=m&&m<=48287||48289<=m&&m<=48315||48317<=m&&m<=48343||48345<=m&&m<=48371||48373<=m&&m<=48399||48401<=m&&m<=48427||48429<=m&&m<=48455||48457<=m&&m<=48483||48485<=m&&m<=48511||48513<=m&&m<=48539||48541<=m&&m<=48567||48569<=m&&m<=48595||48597<=m&&m<=48623||48625<=m&&m<=48651||48653<=m&&m<=48679||48681<=m&&m<=48707||48709<=m&&m<=48735||48737<=m&&m<=48763||48765<=m&&m<=48791||48793<=m&&m<=48819||48821<=m&&m<=48847||48849<=m&&m<=48875||48877<=m&&m<=48903||48905<=m&&m<=48931||48933<=m&&m<=48959||48961<=m&&m<=48987||48989<=m&&m<=49015||49017<=m&&m<=49043||49045<=m&&m<=49071||49073<=m&&m<=49099||49101<=m&&m<=49127||49129<=m&&m<=49155||49157<=m&&m<=49183||49185<=m&&m<=49211||49213<=m&&m<=49239||49241<=m&&m<=49267||49269<=m&&m<=49295||49297<=m&&m<=49323||49325<=m&&m<=49351||49353<=m&&m<=49379||49381<=m&&m<=49407||49409<=m&&m<=49435||49437<=m&&m<=49463||49465<=m&&m<=49491||49493<=m&&m<=49519||49521<=m&&m<=49547||49549<=m&&m<=49575||49577<=m&&m<=49603||49605<=m&&m<=49631||49633<=m&&m<=49659||49661<=m&&m<=49687||49689<=m&&m<=49715||49717<=m&&m<=49743||49745<=m&&m<=49771||49773<=m&&m<=49799||49801<=m&&m<=49827||49829<=m&&m<=49855||49857<=m&&m<=49883||49885<=m&&m<=49911||49913<=m&&m<=49939||49941<=m&&m<=49967||49969<=m&&m<=49995||49997<=m&&m<=50023||50025<=m&&m<=50051||50053<=m&&m<=50079||50081<=m&&m<=50107||50109<=m&&m<=50135||50137<=m&&m<=50163||50165<=m&&m<=50191||50193<=m&&m<=50219||50221<=m&&m<=50247||50249<=m&&m<=50275||50277<=m&&m<=50303||50305<=m&&m<=50331||50333<=m&&m<=50359||50361<=m&&m<=50387||50389<=m&&m<=50415||50417<=m&&m<=50443||50445<=m&&m<=50471||50473<=m&&m<=50499||50501<=m&&m<=50527||50529<=m&&m<=50555||50557<=m&&m<=50583||50585<=m&&m<=50611||50613<=m&&m<=50639||50641<=m&&m<=50667||50669<=m&&m<=50695||50697<=m&&m<=50723||50725<=m&&m<=50751||50753<=m&&m<=50779||50781<=m&&m<=50807||50809<=m&&m<=50835||50837<=m&&m<=50863||50865<=m&&m<=50891||50893<=m&&m<=50919||50921<=m&&m<=50947||50949<=m&&m<=50975||50977<=m&&m<=51003||51005<=m&&m<=51031||51033<=m&&m<=51059||51061<=m&&m<=51087||51089<=m&&m<=51115||51117<=m&&m<=51143||51145<=m&&m<=51171||51173<=m&&m<=51199||51201<=m&&m<=51227||51229<=m&&m<=51255||51257<=m&&m<=51283||51285<=m&&m<=51311||51313<=m&&m<=51339||51341<=m&&m<=51367||51369<=m&&m<=51395||51397<=m&&m<=51423||51425<=m&&m<=51451||51453<=m&&m<=51479||51481<=m&&m<=51507||51509<=m&&m<=51535||51537<=m&&m<=51563||51565<=m&&m<=51591||51593<=m&&m<=51619||51621<=m&&m<=51647||51649<=m&&m<=51675||51677<=m&&m<=51703||51705<=m&&m<=51731||51733<=m&&m<=51759||51761<=m&&m<=51787||51789<=m&&m<=51815||51817<=m&&m<=51843||51845<=m&&m<=51871||51873<=m&&m<=51899||51901<=m&&m<=51927||51929<=m&&m<=51955||51957<=m&&m<=51983||51985<=m&&m<=52011||52013<=m&&m<=52039||52041<=m&&m<=52067||52069<=m&&m<=52095||52097<=m&&m<=52123||52125<=m&&m<=52151||52153<=m&&m<=52179||52181<=m&&m<=52207||52209<=m&&m<=52235||52237<=m&&m<=52263||52265<=m&&m<=52291||52293<=m&&m<=52319||52321<=m&&m<=52347||52349<=m&&m<=52375||52377<=m&&m<=52403||52405<=m&&m<=52431||52433<=m&&m<=52459||52461<=m&&m<=52487||52489<=m&&m<=52515||52517<=m&&m<=52543||52545<=m&&m<=52571||52573<=m&&m<=52599||52601<=m&&m<=52627||52629<=m&&m<=52655||52657<=m&&m<=52683||52685<=m&&m<=52711||52713<=m&&m<=52739||52741<=m&&m<=52767||52769<=m&&m<=52795||52797<=m&&m<=52823||52825<=m&&m<=52851||52853<=m&&m<=52879||52881<=m&&m<=52907||52909<=m&&m<=52935||52937<=m&&m<=52963||52965<=m&&m<=52991||52993<=m&&m<=53019||53021<=m&&m<=53047||53049<=m&&m<=53075||53077<=m&&m<=53103||53105<=m&&m<=53131||53133<=m&&m<=53159||53161<=m&&m<=53187||53189<=m&&m<=53215||53217<=m&&m<=53243||53245<=m&&m<=53271||53273<=m&&m<=53299||53301<=m&&m<=53327||53329<=m&&m<=53355||53357<=m&&m<=53383||53385<=m&&m<=53411||53413<=m&&m<=53439||53441<=m&&m<=53467||53469<=m&&m<=53495||53497<=m&&m<=53523||53525<=m&&m<=53551||53553<=m&&m<=53579||53581<=m&&m<=53607||53609<=m&&m<=53635||53637<=m&&m<=53663||53665<=m&&m<=53691||53693<=m&&m<=53719||53721<=m&&m<=53747||53749<=m&&m<=53775||53777<=m&&m<=53803||53805<=m&&m<=53831||53833<=m&&m<=53859||53861<=m&&m<=53887||53889<=m&&m<=53915||53917<=m&&m<=53943||53945<=m&&m<=53971||53973<=m&&m<=53999||54001<=m&&m<=54027||54029<=m&&m<=54055||54057<=m&&m<=54083||54085<=m&&m<=54111||54113<=m&&m<=54139||54141<=m&&m<=54167||54169<=m&&m<=54195||54197<=m&&m<=54223||54225<=m&&m<=54251||54253<=m&&m<=54279||54281<=m&&m<=54307||54309<=m&&m<=54335||54337<=m&&m<=54363||54365<=m&&m<=54391||54393<=m&&m<=54419||54421<=m&&m<=54447||54449<=m&&m<=54475||54477<=m&&m<=54503||54505<=m&&m<=54531||54533<=m&&m<=54559||54561<=m&&m<=54587||54589<=m&&m<=54615||54617<=m&&m<=54643||54645<=m&&m<=54671||54673<=m&&m<=54699||54701<=m&&m<=54727||54729<=m&&m<=54755||54757<=m&&m<=54783||54785<=m&&m<=54811||54813<=m&&m<=54839||54841<=m&&m<=54867||54869<=m&&m<=54895||54897<=m&&m<=54923||54925<=m&&m<=54951||54953<=m&&m<=54979||54981<=m&&m<=55007||55009<=m&&m<=55035||55037<=m&&m<=55063||55065<=m&&m<=55091||55093<=m&&m<=55119||55121<=m&&m<=55147||55149<=m&&m<=55175||55177<=m&&m<=55203?Sn:m==9757||m==9977||9994<=m&&m<=9997||m==127877||127938<=m&&m<=127940||m==127943||127946<=m&&m<=127948||128066<=m&&m<=128067||128070<=m&&m<=128080||m==128110||128112<=m&&m<=128120||m==128124||128129<=m&&m<=128131||128133<=m&&m<=128135||m==128170||128372<=m&&m<=128373||m==128378||m==128400||128405<=m&&m<=128406||128581<=m&&m<=128583||128587<=m&&m<=128591||m==128675||128692<=m&&m<=128694||m==128704||m==128716||129304<=m&&m<=129308||129310<=m&&m<=129311||m==129318||129328<=m&&m<=129337||129341<=m&&m<=129342||129489<=m&&m<=129501?Qr:127995<=m&&m<=127999?_r:m==8205?vi:m==9792||m==9794||9877<=m&&m<=9878||m==9992||m==10084||m==127752||m==127806||m==127859||m==127891||m==127908||m==127912||m==127979||m==127981||m==128139||128187<=m&&m<=128188||m==128295||m==128300||m==128488||m==128640||m==128658?we:128102<=m&&m<=128105?V:nr}return this}de.exports&&(de.exports=xe)}),o=new i,s=function(xe,Pe,Ze){for(var Xe=o.iterateGraphemes(xe.substring(Pe)),wt="",Kt=0;Kt<Ze-Pe;Kt++){var Pt=Xe.next();if(wt+=Pt.value,Pt.done)break}return wt},a=function(de,xe,Pe,Ze,Xe,wt,Kt){return{start:{line:de,column:xe,offset:Pe},end:{line:Ze,column:Xe,offset:wt},source:Kt||null}},f=r(function(de,xe){(function(Pe,Ze){de.exports=Ze()})(t,function(){var Pe="",Ze,Xe=wt;function wt(Sn,nr){if(typeof Sn!="string")throw new TypeError("expected a string");if(nr===1)return Sn;if(nr===2)return Sn+Sn;var Mr=Sn.length*nr;if(Ze!==Sn||typeof Ze>"u")Ze=Sn,Pe="";else if(Pe.length>=Mr)return Pe.substr(0,Mr);for(;Mr>Pe.length&&nr>1;)nr&1&&(Pe+=Sn),nr>>=1,Sn+=Sn;return Pe+=Sn,Pe=Pe.substr(0,Mr),Pe}var Kt=function(nr,Mr,Qr){if(nr==null||Mr==null)return nr;var _r=String(nr),vi=typeof Mr=="number"?Mr:parseInt(Mr,10);if(isNaN(vi)||!isFinite(vi))return _r;var we=_r.length;if(we>=vi)return _r;var V=Qr==null?"":String(Qr);V===""&&(V=" ");for(var X=vi-we;V.length<X;)V+=V;var me=V.length>X?V.substr(0,X):V;return me+_r},Pt=Object.assign||function(Sn){for(var nr=1;nr<arguments.length;nr++){var Mr=arguments[nr];for(var Qr in Mr)Object.prototype.hasOwnProperty.call(Mr,Qr)&&(Sn[Qr]=Mr[Qr])}return Sn};function zn(Sn,nr,Mr,Qr){var _r=String(nr),vi=Kt(_r,Mr," "),we=Xe(" ",Qr.tabSize);return vi+" | "+Sn.replace(/\t/g,we)}function mt(Sn,nr,Mr,Qr,_r){return Sn.slice(nr,Mr).map(function(vi,we){return zn(vi,nr+we+1,Qr,_r)}).join(`
|
||
`)}var pn={extraLines:2,tabSize:4},ir=function(nr,Mr,Qr,_r){_r=Pt({},pn,_r);var vi=nr.split(/\r\n?|\n|\f/),we=Math.max(1,Mr-_r.extraLines)-1,V=Math.min(Mr+_r.extraLines,vi.length),X=String(V).length,me=mt(vi,we,Mr,X,_r),At=zn(vi[Mr-1].substring(0,Qr-1),Mr,X,_r),bt=Xe(" ",At.length)+"^",Et=mt(vi,Mr,V,X,_r);return[me,bt,Et].filter(Boolean).join(`
|
||
`)};return ir})}),g=new Error().stack,x=function(de){var xe=Object.create(SyntaxError.prototype);return Object.assign(xe,de,{name:"SyntaxError"}),Object.defineProperty(xe,"stack",{get:function(){return g?g.replace(/^(.+\n){1,3}/,String(xe)+`
|
||
`):""}}),xe},k=function(de,xe,Pe,Ze,Xe){throw x({message:Ze?de+`
|
||
`+f(xe,Ze,Xe):de,rawMessage:de,source:Pe,line:Ze,column:Xe})},B={unexpectedEnd:function(){return"Unexpected end of input"},unexpectedToken:function(xe){for(var Pe=arguments.length,Ze=Array(Pe>1?Pe-1:0),Xe=1;Xe<Pe;Xe++)Ze[Xe-1]=arguments[Xe];return"Unexpected token <"+xe+"> at "+Ze.filter(Boolean).join(":")}},P={unexpectedSymbol:function(xe){for(var Pe=arguments.length,Ze=Array(Pe>1?Pe-1:0),Xe=1;Xe<Pe;Xe++)Ze[Xe-1]=arguments[Xe];return"Unexpected symbol <"+xe+"> at "+Ze.filter(Boolean).join(":")}},R={LEFT_BRACE:0,RIGHT_BRACE:1,LEFT_BRACKET:2,RIGHT_BRACKET:3,COLON:4,COMMA:5,STRING:6,NUMBER:7,TRUE:8,FALSE:9,NULL:10},H={"{":R.LEFT_BRACE,"}":R.RIGHT_BRACE,"[":R.LEFT_BRACKET,"]":R.RIGHT_BRACKET,":":R.COLON,",":R.COMMA},W={true:R.TRUE,false:R.FALSE,null:R.NULL},$={_START_:0,START_QUOTE_OR_CHAR:1,ESCAPE:2},q={'"':0,"\\":1,"/":2,b:3,f:4,n:5,r:6,t:7,u:8},oe={_START_:0,MINUS:1,ZERO:2,DIGIT:3,POINT:4,DIGIT_FRACTION:5,EXP:6,EXP_DIGIT_OR_SIGN:7};function ne(de){return de>="1"&&de<="9"}function ce(de){return de>="0"&&de<="9"}function ae(de){return ce(de)||de>="a"&&de<="f"||de>="A"&&de<="F"}function ue(de){return de==="e"||de==="E"}function ye(de,xe,Pe,Ze){var Xe=de.charAt(xe);if(Xe==="\r")xe++,Pe++,Ze=1,de.charAt(xe)===`
|
||
`&&xe++;else if(Xe===`
|
||
`)xe++,Pe++,Ze=1;else if(Xe===" "||Xe===" ")xe++,Ze++;else return null;return{index:xe,line:Pe,column:Ze}}function Re(de,xe,Pe,Ze){var Xe=de.charAt(xe);return Xe in H?{type:H[Xe],line:Pe,column:Ze+1,index:xe+1,value:null}:null}function Ne(de,xe,Pe,Ze){for(var Xe in W)if(W.hasOwnProperty(Xe)&&de.substr(xe,Xe.length)===Xe)return{type:W[Xe],line:Pe,column:Ze+Xe.length,index:xe+Xe.length,value:Xe};return null}function rt(de,xe,Pe,Ze){for(var Xe=xe,wt=$._START_;xe<de.length;){var Kt=de.charAt(xe);switch(wt){case $._START_:{if(Kt==='"')xe++,wt=$.START_QUOTE_OR_CHAR;else return null;break}case $.START_QUOTE_OR_CHAR:{if(Kt==="\\")xe++,wt=$.ESCAPE;else{if(Kt==='"')return xe++,{type:R.STRING,line:Pe,column:Ze+xe-Xe,index:xe,value:de.slice(Xe,xe)};xe++}break}case $.ESCAPE:{if(Kt in q){if(xe++,Kt==="u")for(var Pt=0;Pt<4;Pt++){var zn=de.charAt(xe);if(zn&&ae(zn))xe++;else return null}wt=$.START_QUOTE_OR_CHAR}else return null;break}}}}function ct(de,xe,Pe,Ze){var Xe=xe,wt=xe,Kt=oe._START_;e:for(;xe<de.length;){var Pt=de.charAt(xe);switch(Kt){case oe._START_:{if(Pt==="-")Kt=oe.MINUS;else if(Pt==="0")wt=xe+1,Kt=oe.ZERO;else if(ne(Pt))wt=xe+1,Kt=oe.DIGIT;else return null;break}case oe.MINUS:{if(Pt==="0")wt=xe+1,Kt=oe.ZERO;else if(ne(Pt))wt=xe+1,Kt=oe.DIGIT;else return null;break}case oe.ZERO:{if(Pt===".")Kt=oe.POINT;else if(ue(Pt))Kt=oe.EXP;else break e;break}case oe.DIGIT:{if(ce(Pt))wt=xe+1;else if(Pt===".")Kt=oe.POINT;else if(ue(Pt))Kt=oe.EXP;else break e;break}case oe.POINT:{if(ce(Pt))wt=xe+1,Kt=oe.DIGIT_FRACTION;else break e;break}case oe.DIGIT_FRACTION:{if(ce(Pt))wt=xe+1;else if(ue(Pt))Kt=oe.EXP;else break e;break}case oe.EXP:{if(Pt==="+"||Pt==="-")Kt=oe.EXP_DIGIT_OR_SIGN;else if(ce(Pt))wt=xe+1,Kt=oe.EXP_DIGIT_OR_SIGN;else break e;break}case oe.EXP_DIGIT_OR_SIGN:{if(ce(Pt))wt=xe+1;else break e;break}}xe++}return wt>0?{type:R.NUMBER,line:Pe,column:Ze+wt-Xe,index:wt,value:de.slice(Xe,wt)}:null}var Fe=function(xe,Pe){for(var Ze=1,Xe=1,wt=0,Kt=[];wt<xe.length;){var Pt=[xe,wt,Ze,Xe],zn=ye.apply(void 0,Pt);if(zn){wt=zn.index,Ze=zn.line,Xe=zn.column;continue}var mt=Re.apply(void 0,Pt)||Ne.apply(void 0,Pt)||rt.apply(void 0,Pt)||ct.apply(void 0,Pt);if(mt){var pn={type:mt.type,value:mt.value,loc:a(Ze,Xe,wt,mt.line,mt.column,mt.index,Pe.source)};Kt.push(pn),wt=mt.index,Ze=mt.line,Xe=mt.column}else k(P.unexpectedSymbol(s(xe,wt,wt+1),Pe.source,Ze,Xe),xe,Pe.source,Ze,Xe)}return Kt},He={_START_:0,OPEN_OBJECT:1,PROPERTY:2,COMMA:3},Ce={_START_:0,KEY:1,COLON:2},jt={_START_:0,OPEN_ARRAY:1,VALUE:2,COMMA:3},Ft={loc:!0,source:null};function Jt(de,xe,Pe){var Ze=xe.length>0?xe[xe.length-1].loc.end:{line:1,column:1};k(B.unexpectedEnd(),de,Pe.source,Ze.line,Ze.column)}function Nt(de){for(var xe=0,Pe=0;Pe<4;Pe++)xe=xe*16+parseInt(de[Pe],16);return String.fromCharCode(xe)}var Ve={b:"\b",f:"\f",n:`
|
||
`,r:"\r",t:" "},nt=['"',"\\","/"];function Je(de){for(var xe="",Pe=0;Pe<de.length;Pe++){var Ze=de.charAt(Pe);if(Ze==="\\"){Pe++;var Xe=de.charAt(Pe);if(Xe==="u")xe+=Nt(de.substr(Pe+1,4)),Pe+=4;else if(nt.indexOf(Xe)!==-1)xe+=Xe;else if(Xe in Ve)xe+=Ve[Xe];else break}else xe+=Ze}return xe}function Vt(de,xe,Pe,Ze){for(var Xe=void 0,wt={type:"Object",children:[]},Kt=He._START_;Pe<xe.length;){var Pt=xe[Pe];switch(Kt){case He._START_:{if(Pt.type===R.LEFT_BRACE)Xe=Pt,Kt=He.OPEN_OBJECT,Pe++;else return null;break}case He.OPEN_OBJECT:{if(Pt.type===R.RIGHT_BRACE)return Ze.loc&&(wt.loc=a(Xe.loc.start.line,Xe.loc.start.column,Xe.loc.start.offset,Pt.loc.end.line,Pt.loc.end.column,Pt.loc.end.offset,Ze.source)),{value:wt,index:Pe+1};var zn=pt(de,xe,Pe,Ze);wt.children.push(zn.value),Kt=He.PROPERTY,Pe=zn.index;break}case He.PROPERTY:{if(Pt.type===R.RIGHT_BRACE)return Ze.loc&&(wt.loc=a(Xe.loc.start.line,Xe.loc.start.column,Xe.loc.start.offset,Pt.loc.end.line,Pt.loc.end.column,Pt.loc.end.offset,Ze.source)),{value:wt,index:Pe+1};Pt.type===R.COMMA?(Kt=He.COMMA,Pe++):k(B.unexpectedToken(s(de,Pt.loc.start.offset,Pt.loc.end.offset),Ze.source,Pt.loc.start.line,Pt.loc.start.column),de,Ze.source,Pt.loc.start.line,Pt.loc.start.column);break}case He.COMMA:{var mt=pt(de,xe,Pe,Ze);mt?(Pe=mt.index,wt.children.push(mt.value),Kt=He.PROPERTY):k(B.unexpectedToken(s(de,Pt.loc.start.offset,Pt.loc.end.offset),Ze.source,Pt.loc.start.line,Pt.loc.start.column),de,Ze.source,Pt.loc.start.line,Pt.loc.start.column);break}}}Jt(de,xe,Ze)}function pt(de,xe,Pe,Ze){for(var Xe=void 0,wt={type:"Property",key:null,value:null},Kt=Ce._START_;Pe<xe.length;){var Pt=xe[Pe];switch(Kt){case Ce._START_:{if(Pt.type===R.STRING){var zn={type:"Identifier",value:Je(de.slice(Pt.loc.start.offset+1,Pt.loc.end.offset-1)),raw:Pt.value};Ze.loc&&(zn.loc=Pt.loc),Xe=Pt,wt.key=zn,Kt=Ce.KEY,Pe++}else return null;break}case Ce.KEY:{Pt.type===R.COLON?(Kt=Ce.COLON,Pe++):k(B.unexpectedToken(s(de,Pt.loc.start.offset,Pt.loc.end.offset),Ze.source,Pt.loc.start.line,Pt.loc.start.column),de,Ze.source,Pt.loc.start.line,Pt.loc.start.column);break}case Ce.COLON:{var mt=Dt(de,xe,Pe,Ze);return wt.value=mt.value,Ze.loc&&(wt.loc=a(Xe.loc.start.line,Xe.loc.start.column,Xe.loc.start.offset,mt.value.loc.end.line,mt.value.loc.end.column,mt.value.loc.end.offset,Ze.source)),{value:wt,index:mt.index}}}}}function dt(de,xe,Pe,Ze){for(var Xe=void 0,wt={type:"Array",children:[]},Kt=jt._START_,Pt=void 0;Pe<xe.length;)switch(Pt=xe[Pe],Kt){case jt._START_:{if(Pt.type===R.LEFT_BRACKET)Xe=Pt,Kt=jt.OPEN_ARRAY,Pe++;else return null;break}case jt.OPEN_ARRAY:{if(Pt.type===R.RIGHT_BRACKET)return Ze.loc&&(wt.loc=a(Xe.loc.start.line,Xe.loc.start.column,Xe.loc.start.offset,Pt.loc.end.line,Pt.loc.end.column,Pt.loc.end.offset,Ze.source)),{value:wt,index:Pe+1};var zn=Dt(de,xe,Pe,Ze);Pe=zn.index,wt.children.push(zn.value),Kt=jt.VALUE;break}case jt.VALUE:{if(Pt.type===R.RIGHT_BRACKET)return Ze.loc&&(wt.loc=a(Xe.loc.start.line,Xe.loc.start.column,Xe.loc.start.offset,Pt.loc.end.line,Pt.loc.end.column,Pt.loc.end.offset,Ze.source)),{value:wt,index:Pe+1};Pt.type===R.COMMA?(Kt=jt.COMMA,Pe++):k(B.unexpectedToken(s(de,Pt.loc.start.offset,Pt.loc.end.offset),Ze.source,Pt.loc.start.line,Pt.loc.start.column),de,Ze.source,Pt.loc.start.line,Pt.loc.start.column);break}case jt.COMMA:{var mt=Dt(de,xe,Pe,Ze);Pe=mt.index,wt.children.push(mt.value),Kt=jt.VALUE;break}}Jt(de,xe,Ze)}function kt(de,xe,Pe,Ze){var Xe=xe[Pe],wt=null;switch(Xe.type){case R.STRING:{wt=Je(de.slice(Xe.loc.start.offset+1,Xe.loc.end.offset-1));break}case R.NUMBER:{wt=Number(Xe.value);break}case R.TRUE:{wt=!0;break}case R.FALSE:{wt=!1;break}case R.NULL:{wt=null;break}default:return null}var Kt={type:"Literal",value:wt,raw:Xe.value};return Ze.loc&&(Kt.loc=Xe.loc),{value:Kt,index:Pe+1}}function Dt(de,xe,Pe,Ze){var Xe=xe[Pe],wt=kt.apply(void 0,arguments)||Vt.apply(void 0,arguments)||dt.apply(void 0,arguments);if(wt)return wt;k(B.unexpectedToken(s(de,Xe.loc.start.offset,Xe.loc.end.offset),Ze.source,Xe.loc.start.line,Xe.loc.start.column),de,Ze.source,Xe.loc.start.line,Xe.loc.start.column)}var Se=function(de,xe){xe=Object.assign({},Ft,xe);var Pe=Fe(de,xe);Pe.length===0&&Jt(de,Pe,xe);var Ze=Dt(de,Pe,0,xe);if(Ze.index===Pe.length)return Ze.value;var Xe=Pe[Ze.index];k(B.unexpectedToken(s(de,Xe.loc.start.offset,Xe.loc.end.offset),xe.source,Xe.loc.start.line,Xe.loc.start.column),de,xe.source,Xe.loc.start.line,Xe.loc.start.column)};return Se})})(xW);var ope=xW.exports;const ape=ga(ope);function Mn(){var e="/home/runner/work/maputnik/maputnik/src/libs/codemirror-mgl.ts",n="a994e12e3e6547813b669a430e6cb42da5d99bba",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/codemirror-mgl.ts",statementMap:{0:{start:{line:5,column:0},end:{line:10,column:3}},1:{start:{line:6,column:2},end:{line:9,column:4}},2:{start:{line:11,column:0},end:{line:26,column:3}},3:{start:{line:12,column:16},end:{line:12,column:18}},4:{start:{line:13,column:2},end:{line:20,column:4}},5:{start:{line:14,column:16},end:{line:14,column:24}},6:{start:{line:15,column:4},end:{line:19,column:7}},7:{start:{line:21,column:2},end:{line:24,column:3}},8:{start:{line:22,column:4},end:{line:22,column:25}},9:{start:{line:25,column:2},end:{line:25,column:15}},10:{start:{line:27,column:0},end:{line:134,column:3}},11:{start:{line:28,column:16},end:{line:28,column:18}},12:{start:{line:29,column:21},end:{line:29,column:29}},13:{start:{line:30,column:22},end:{line:30,column:26}},14:{start:{line:31,column:2},end:{line:38,column:4}},15:{start:{line:32,column:16},end:{line:32,column:24}},16:{start:{line:33,column:4},end:{line:37,column:7}},17:{start:{line:39,column:2},end:{line:42,column:3}},18:{start:{line:40,column:4},end:{line:40,column:23}},19:{start:{line:43,column:2},end:{line:45,column:3}},20:{start:{line:44,column:4},end:{line:44,column:17}},21:{start:{line:46,column:14},end:{line:46,column:29}},22:{start:{line:47,column:16},end:{line:47,column:32}},23:{start:{line:49,column:4},end:{line:69,column:5}},24:{start:{line:50,column:6},end:{line:50,column:20}},25:{start:{line:51,column:11},end:{line:69,column:5}},26:{start:{line:52,column:6},end:{line:52,column:18}},27:{start:{line:53,column:11},end:{line:69,column:5}},28:{start:{line:54,column:6},end:{line:54,column:20}},29:{start:{line:56,column:18},end:{line:56,column:25}},30:{start:{line:58,column:6},end:{line:67,column:7}},31:{start:{line:59,column:8},end:{line:59,column:41}},32:{start:{line:61,column:8},end:{line:63,column:11}},33:{start:{line:62,column:10},end:{line:62,column:101}},34:{start:{line:64,column:8},end:{line:66,column:9}},35:{start:{line:65,column:10},end:{line:65,column:34}},36:{start:{line:68,column:6},end:{line:68,column:63}},37:{start:{line:71,column:12},end:{line:71,column:16}},38:{start:{line:72,column:2},end:{line:103,column:3}},39:{start:{line:73,column:19},end:{line:83,column:6}},40:{start:{line:84,column:4},end:{line:98,column:5}},41:{start:{line:85,column:6},end:{line:97,column:8}},42:{start:{line:88,column:10},end:{line:88,column:76}},43:{start:{line:90,column:34},end:{line:90,column:85}},44:{start:{line:91,column:10},end:{line:95,column:12}},45:{start:{line:99,column:9},end:{line:103,column:3}},46:{start:{line:100,column:4},end:{line:100,column:56}},47:{start:{line:102,column:4},end:{line:102,column:50}},48:{start:{line:104,column:2},end:{line:132,column:3}},49:{start:{line:105,column:19},end:{line:105,column:28}},50:{start:{line:106,column:4},end:{line:131,column:7}},51:{start:{line:107,column:31},end:{line:107,column:36}},52:{start:{line:108,column:6},end:{line:130,column:7}},53:{start:{line:109,column:31},end:{line:109,column:64}},54:{start:{line:110,column:20},end:{line:114,column:9}},55:{start:{line:115,column:8},end:{line:115,column:24}},56:{start:{line:116,column:13},end:{line:130,column:7}},57:{start:{line:117,column:21},end:{line:117,column:83}},58:{start:{line:118,column:28},end:{line:118,column:64}},59:{start:{line:119,column:8},end:{line:122,column:9}},60:{start:{line:120,column:10},end:{line:120,column:69}},61:{start:{line:121,column:10},end:{line:121,column:17}},62:{start:{line:123,column:24},end:{line:123,column:35}},63:{start:{line:124,column:31},end:{line:124,column:34}},64:{start:{line:125,column:8},end:{line:129,column:11}},65:{start:{line:133,column:2},end:{line:133,column:15}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:29},end:{line:5,column:30}},loc:{start:{line:5,column:55},end:{line:10,column:1}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:11,column:42},end:{line:11,column:43}},loc:{start:{line:11,column:52},end:{line:26,column:1}},line:11},2:{name:"(anonymous_2)",decl:{start:{line:13,column:31},end:{line:13,column:32}},loc:{start:{line:13,column:46},end:{line:20,column:3}},line:13},3:{name:"(anonymous_3)",decl:{start:{line:27,column:41},end:{line:27,column:42}},loc:{start:{line:27,column:62},end:{line:134,column:1}},line:27},4:{name:"(anonymous_4)",decl:{start:{line:31,column:22},end:{line:31,column:23}},loc:{start:{line:31,column:37},end:{line:38,column:3}},line:31},5:{name:"getArrayPositionalFromAst",decl:{start:{line:48,column:11},end:{line:48,column:36}},loc:{start:{line:48,column:49},end:{line:70,column:3}},line:48},6:{name:"(anonymous_6)",decl:{start:{line:61,column:37},end:{line:61,column:38}},loc:{start:{line:61,column:52},end:{line:63,column:9}},line:61},7:{name:"(anonymous_7)",decl:{start:{line:87,column:29},end:{line:87,column:30}},loc:{start:{line:87,column:38},end:{line:89,column:9}},line:87},8:{name:"(anonymous_8)",decl:{start:{line:89,column:15},end:{line:89,column:16}},loc:{start:{line:89,column:24},end:{line:96,column:9}},line:89},9:{name:"(anonymous_9)",decl:{start:{line:106,column:19},end:{line:106,column:20}},loc:{start:{line:106,column:30},end:{line:131,column:5}},line:106}},branchMap:{0:{loc:{start:{line:43,column:2},end:{line:45,column:3}},type:"if",locations:[{start:{line:43,column:2},end:{line:45,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:43},1:{loc:{start:{line:49,column:4},end:{line:69,column:5}},type:"if",locations:[{start:{line:49,column:4},end:{line:69,column:5}},{start:{line:51,column:11},end:{line:69,column:5}}],line:49},2:{loc:{start:{line:51,column:11},end:{line:69,column:5}},type:"if",locations:[{start:{line:51,column:11},end:{line:69,column:5}},{start:{line:53,column:11},end:{line:69,column:5}}],line:51},3:{loc:{start:{line:53,column:11},end:{line:69,column:5}},type:"if",locations:[{start:{line:53,column:11},end:{line:69,column:5}},{start:{line:55,column:11},end:{line:69,column:5}}],line:53},4:{loc:{start:{line:58,column:6},end:{line:67,column:7}},type:"if",locations:[{start:{line:58,column:6},end:{line:67,column:7}},{start:{line:60,column:13},end:{line:67,column:7}}],line:58},5:{loc:{start:{line:62,column:17},end:{line:62,column:100}},type:"binary-expr",locations:[{start:{line:62,column:17},end:{line:62,column:30}},{start:{line:62,column:34},end:{line:62,column:69}},{start:{line:62,column:73},end:{line:62,column:100}}],line:62},6:{loc:{start:{line:64,column:8},end:{line:66,column:9}},type:"if",locations:[{start:{line:64,column:8},end:{line:66,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:64},7:{loc:{start:{line:72,column:2},end:{line:103,column:3}},type:"if",locations:[{start:{line:72,column:2},end:{line:103,column:3}},{start:{line:99,column:9},end:{line:103,column:3}}],line:72},8:{loc:{start:{line:84,column:4},end:{line:98,column:5}},type:"if",locations:[{start:{line:84,column:4},end:{line:98,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:84},9:{loc:{start:{line:99,column:9},end:{line:103,column:3}},type:"if",locations:[{start:{line:99,column:9},end:{line:103,column:3}},{start:{line:101,column:9},end:{line:103,column:3}}],line:99},10:{loc:{start:{line:104,column:2},end:{line:132,column:3}},type:"if",locations:[{start:{line:104,column:2},end:{line:132,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:104},11:{loc:{start:{line:108,column:6},end:{line:130,column:7}},type:"if",locations:[{start:{line:108,column:6},end:{line:130,column:7}},{start:{line:116,column:13},end:{line:130,column:7}}],line:108},12:{loc:{start:{line:116,column:13},end:{line:130,column:7}},type:"if",locations:[{start:{line:116,column:13},end:{line:130,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:116},13:{loc:{start:{line:119,column:8},end:{line:122,column:9}},type:"if",locations:[{start:{line:119,column:8},end:{line:122,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:119}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/codemirror-mgl.ts"],names:[],mappings:"AACA,OAAO,cAAc;AACrB,OAAO,gBAAiC;AACxC,OAAO,eAAe;AACtB,SAAQ,YAAY,wBAAuB;AAK3C,WAAW,WAAW,OAAO,CAAC,QAAQ,iBAAiB;AAErD,SAAO,WAAW,MAAM;AAAA,IACtB,EAAC,GAAG,QAAQ,MAAM,KAAI;AAAA,IACtB;AAAA,EACF;AACF,CAAC;AAED,WAAW,eAAe,QAAQ,QAAQ,CAAC,SAAiB;AAC1D,QAAM,QAAkC,CAAC;AAKzC,EAAC,SAAiB,OAAO,aAAa,CAAC,KAAa,SAAc;AAChE,UAAM,MAAM,KAAK;AACjB,UAAM,KAAK;AAAA,MACT,MAAS,WAAW,IAAI,IAAI,aAAa,GAAG,IAAI,YAAY;AAAA,MAC5D,IAAS,WAAW,IAAI,IAAI,YAAa,GAAG,IAAI,WAAW;AAAA,MAC3D,SAAS;AAAA,IACX,CAAC;AAAA,EACH;AAEA,MAAI;AACF,aAAS,MAAM,IAAI;AAAA,EACrB,SACM,GAAG;AAAA,EAET;AACA,SAAO;AACT,CAAC;AAED,WAAW,eAAe,QAAQ,OAAO,CAAC,MAAc,MAAW,QAAa;AAC9E,QAAM,QAAkC,CAAC;AACzC,QAAM,EAAC,OAAM,IAAI;AACjB,QAAM,EAAC,QAAO,IAAI;AAElB,SAAO,aAAa,CAAC,KAAa,SAAc;AAC9C,UAAM,MAAM,KAAK;AACjB,UAAM,KAAK;AAAA,MACT,MAAM,WAAW,IAAI,IAAI,aAAa,GAAG,IAAI,YAAY;AAAA,MACzD,IAAI,WAAW,IAAI,IAAI,YAAY,GAAG,IAAI,WAAW;AAAA,MACrD,SAAS;AAAA,IACX,CAAC;AAAA,EACH;AACA,MAAI;AACF,WAAO,MAAM,IAAI;AAAA,EACnB,SACO,GAAG;AAAA,EAEV;AAEA,MAAI,MAAM,SAAS,GAAG;AAEpB,WAAO;AAAA,EACT;AAEA,QAAM,MAAM,UAAU,IAAI;AAC1B,QAAM,QAAQ,KAAK,MAAM,IAAI;AAE7B,WAAS,0BAA0B,MAAW,MAAgB;AAC5D,QAAI,CAAC,MAAM;AACT,aAAO;AAAA,IACT,WACS,KAAK,SAAS,GAAG;AACxB,aAAO;AAAA,IACT,WACS,CAAC,KAAK,UAAU;AACvB,aAAO;AAAA,IACT,OACK;AACH,YAAM,MAAM,KAAK,CAAC;AAClB,UAAI;AACJ,UAAI,IAAI,MAAM,UAAU,GAAG;AACzB,kBAAU,KAAK,SAAS,KAAK,CAAC,CAAC;AAAA,MACjC,OACK;AACH,kBAAU,KAAK,SAAS,KAAK,CAAC,cAAmB;AAC/C,iBACE,UAAU,OACV,UAAU,IAAI,SAAS,gBACvB,UAAU,IAAI,UAAU;AAAA,QAE5B,CAAC;AACD,YAAI,SAAS;AACX,oBAAU,QAAQ;AAAA,QACpB;AAAA,MACF;AACA,aAAO,0BAA0B,SAAS,KAAK,MAAM,CAAC,CAAC;AAAA,IACzD;AAAA,EACF;AAEA,MAAI,MAA6D;AACjE,MAAI,YAAY,SAAS;AAEvB,UAAM,SAAS,iBAAiB;AAAA,MAC9B,WAAW;AAAA,MACX,QAAQ;AAAA,MACR,YAAY,CAAC;AAAA,MACb,WAAW,CAAC;AAAA,MACZ,UAAU;AAAA,MACV,UAAU;AAAA,MACV,UAAU;AAAA,QACR;AAAA,MACF;AAAA,IACF,CAAC;AAED,QAAI,QAAQ;AACV,YAAM;AAAA,QACJ,QAAQ;AAAA,QACR,OAAO,OACJ,OAAO,SAAO;AAEb,iBAAO,CAAC,IAAI,QAAQ,MAAM,sCAAsC;AAAA,QAClE,CAAC,EACA,IAAI,SAAO;AAEV,gBAAM,kBAAkB,IAAI,QAAQ,QAAQ,iBAAiB,EAAE,EAAE,MAAM,GAAG;AAC1E,iBAAO;AAAA,YACL,MAAM;AAAA,YACN,KAAK,gBAAgB,CAAC;AAAA,YACtB,SAAS,gBAAgB,CAAC;AAAA,UAC5B;AAAA,QACF,CAAC;AAAA,MACL;AAAA,IACF;AAAA,EACF,WACS,YAAY,cAAc;AACjC,UAAM,WAAW,iBAAiB,OAAO,KAAK,IAAI;AAAA,EACpD,OACK;AACH,UAAM,IAAI,MAAM,mBAAmB,OAAO,EAAE;AAAA,EAC9C;AAEA,MAAI,KAAK,WAAW,SAAS;AAC3B,UAAM,SAAS,IAAI;AACnB,WAAO,QAAQ,WAAS;AACtB,YAAM,EAAC,KAAK,QAAO,IAAI;AAEvB,UAAI,CAAC,KAAK;AACR,cAAM,iBAAiB,IAAI,cAAc,IAAI,SAAS,CAAC;AACvD,cAAM,MAAM;AAAA,UACV,MAAM,WAAW,IAAI,IAAI,UAAU,GAAG,CAAC;AAAA,UACvC,IAAI,WAAW,IAAI,IAAI,SAAS,GAAG,eAAe,KAAK,MAAM;AAAA,UAC7D;AAAA,QACF;AACA,cAAM,KAAK,GAAG;AAAA,MAChB,WACS,KAAK;AACZ,cAAM,OAAO,IAAI,QAAQ,YAAY,EAAE,EAAE,MAAM,WAAW,EAAE,OAAO,OAAO;AAC1E,cAAM,cAAc,0BAA0B,KAAK,IAAI;AACvD,YAAI,CAAC,aAAa;AAChB,kBAAQ,KAAK,uCAAuC,KAAK;AACzD;AAAA,QACF;AAEA,cAAM,EAAC,IAAG,IAAI;AACd,cAAM,EAAC,OAAO,IAAG,IAAI;AAErB,cAAM,KAAK;AAAA,UACT,MAAM,WAAW,IAAI,MAAM,OAAO,GAAG,MAAM,MAAM;AAAA,UACjD,IAAI,WAAW,IAAI,IAAI,OAAO,GAAG,IAAI,MAAM;AAAA,UAC3C;AAAA,QACF,CAAC;AAAA,MACH;AAAA,IACF,CAAC;AAAA,EACH;AAEA,SAAO;AACT,CAAC;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a994e12e3e6547813b669a430e6cb42da5d99bba"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Mn=function(){return s},s}Mn();Mn().s[0]++;Kc.defineMode("mgl",(e,n)=>(Mn().f[0]++,Mn().s[1]++,Kc.modes.javascript({...e,json:!0},n)));Mn().s[2]++;Kc.registerHelper("lint","json",e=>{Mn().f[1]++;const n=(Mn().s[3]++,[]);Mn().s[4]++,WE.parser.parseError=(t,r)=>{Mn().f[2]++;const i=(Mn().s[5]++,r.loc);Mn().s[6]++,n.push({from:Kc.Pos(i.first_line-1,i.first_column),to:Kc.Pos(i.last_line-1,i.last_column),message:t})},Mn().s[7]++;try{Mn().s[8]++,WE.parse(e)}catch{}return Mn().s[9]++,n});Mn().s[10]++;Kc.registerHelper("lint","mgl",(e,n,t)=>{Mn().f[3]++;const r=(Mn().s[11]++,[]),{parser:i}=(Mn().s[12]++,WE),{context:o}=(Mn().s[13]++,n);Mn().s[14]++,i.parseError=(x,k)=>{Mn().f[4]++;const B=(Mn().s[15]++,k.loc);Mn().s[16]++,r.push({from:Kc.Pos(B.first_line-1,B.first_column),to:Kc.Pos(B.last_line-1,B.last_column),message:x})},Mn().s[17]++;try{Mn().s[18]++,i.parse(e)}catch{}if(Mn().s[19]++,r.length>0)return Mn().b[0][0]++,Mn().s[20]++,r;Mn().b[0][1]++;const s=(Mn().s[21]++,ape(e)),a=(Mn().s[22]++,JSON.parse(e));function f(x,k){if(Mn().f[5]++,Mn().s[23]++,x){if(Mn().b[1][1]++,Mn().s[25]++,k.length<1)return Mn().b[2][0]++,Mn().s[26]++,x;if(Mn().b[2][1]++,Mn().s[27]++,x.children){Mn().b[3][1]++;const B=(Mn().s[29]++,k[0]);let P;return Mn().s[30]++,B.match(/^[0-9]+$/)?(Mn().b[4][0]++,Mn().s[31]++,P=x.children[k[0]]):(Mn().b[4][1]++,Mn().s[32]++,P=x.children.find(R=>(Mn().f[6]++,Mn().s[33]++,Mn().b[5][0]++,R.key&&(Mn().b[5][1]++,R.key.type==="Identifier")&&(Mn().b[5][2]++,R.key.value===B))),Mn().s[34]++,P?(Mn().b[6][0]++,Mn().s[35]++,P=P.value):Mn().b[6][1]++),Mn().s[36]++,f(P,k.slice(1))}else{Mn().b[3][0]++,Mn().s[28]++;return}}else{Mn().b[1][0]++,Mn().s[24]++;return}}let g=(Mn().s[37]++,null);if(Mn().s[38]++,o==="layer"){Mn().b[7][0]++;const x=(Mn().s[39]++,Bd({version:8,name:"Empty Style",metadata:{},sources:{},sprite:"",glyphs:"https://example.com/glyphs/{fontstack}/{range}.pbf",layers:[a]}));Mn().s[40]++,x?(Mn().b[8][0]++,Mn().s[41]++,g={result:"error",value:x.filter(k=>(Mn().f[7]++,Mn().s[42]++,!k.message.match(/^layers\[0\]: source ".*" not found$/))).map(k=>{Mn().f[8]++;const B=(Mn().s[43]++,k.message.replace(/^layers\[0\]./,"").split(":"));return Mn().s[44]++,{name:"",key:B[0],message:B[1]}})}):Mn().b[8][1]++}else if(Mn().b[7][1]++,Mn().s[45]++,o==="expression")Mn().b[9][0]++,Mn().s[46]++,g=OX.createExpression(a,n.spec);else throw Mn().b[9][1]++,Mn().s[47]++,new Error(`Invalid context ${o}`);if(Mn().s[48]++,(g==null?void 0:g.result)==="error"){Mn().b[10][0]++;const x=(Mn().s[49]++,g.value);Mn().s[50]++,x.forEach(k=>{Mn().f[9]++;const{key:B,message:P}=(Mn().s[51]++,k);if(Mn().s[52]++,B)if(Mn().b[11][1]++,Mn().s[56]++,B){Mn().b[12][0]++;const R=(Mn().s[57]++,B.replace(/^\[|\]$/g,"").split(/\.|[[\]]+/).filter(Boolean)),H=(Mn().s[58]++,f(s,R));if(Mn().s[59]++,H)Mn().b[13][1]++;else{Mn().b[13][0]++,Mn().s[60]++,console.warn("Something went wrong parsing error:",k),Mn().s[61]++;return}const{loc:W}=(Mn().s[62]++,H),{start:$,end:q}=(Mn().s[63]++,W);Mn().s[64]++,r.push({from:Kc.Pos($.line-1,$.column),to:Kc.Pos(q.line-1,q.column),message:P})}else Mn().b[12][1]++;else{Mn().b[11][0]++;const R=(Mn().s[53]++,t.getLineHandle(t.lastLine())),H=(Mn().s[54]++,{from:Kc.Pos(t.firstLine(),0),to:Kc.Pos(t.lastLine(),R.text.length),message:P});Mn().s[55]++,r.push(H)}})}else Mn().b[10][1]++;return Mn().s[65]++,r});function Pn(){var e="/home/runner/work/maputnik/maputnik/src/components/InputJson.tsx",n="73341c4954366276bd838a194b53fa026df00a42",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputJson.tsx",statementMap:{0:{start:{line:13,column:24},end:{line:28,column:3}},1:{start:{line:18,column:6},end:{line:18,column:65}},2:{start:{line:31,column:8},end:{line:31,column:12}},3:{start:{line:32,column:22},end:{line:32,column:27}},4:{start:{line:34,column:4},end:{line:34,column:17}},5:{start:{line:35,column:4},end:{line:35,column:32}},6:{start:{line:36,column:4},end:{line:40,column:6}},7:{start:{line:43,column:4},end:{line:59,column:7}},8:{start:{line:60,column:4},end:{line:60,column:42}},9:{start:{line:61,column:4},end:{line:61,column:40}},10:{start:{line:62,column:4},end:{line:62,column:38}},11:{start:{line:64,column:18},end:{line:66,column:3}},12:{start:{line:65,column:4},end:{line:65,column:31}},13:{start:{line:67,column:12},end:{line:74,column:3}},14:{start:{line:68,column:4},end:{line:69,column:27}},15:{start:{line:69,column:6},end:{line:69,column:27}},16:{start:{line:70,column:4},end:{line:73,column:7}},17:{start:{line:75,column:11},end:{line:83,column:3}},18:{start:{line:76,column:4},end:{line:76,column:32}},19:{start:{line:77,column:4},end:{line:78,column:26}},20:{start:{line:78,column:6},end:{line:78,column:26}},21:{start:{line:79,column:4},end:{line:82,column:7}},22:{start:{line:85,column:4},end:{line:85,column:43}},23:{start:{line:86,column:4},end:{line:86,column:41}},24:{start:{line:87,column:4},end:{line:87,column:39}},25:{start:{line:90,column:4},end:{line:95,column:5}},26:{start:{line:91,column:6},end:{line:91,column:36}},27:{start:{line:92,column:6},end:{line:94,column:8}},28:{start:{line:97,column:13},end:{line:126,column:3}},29:{start:{line:98,column:4},end:{line:104,column:5}},30:{start:{line:99,column:6},end:{line:99,column:37}},31:{start:{line:100,column:6},end:{line:102,column:9}},32:{start:{line:103,column:6},end:{line:103,column:13}},33:{start:{line:105,column:20},end:{line:105,column:40}},34:{start:{line:106,column:4},end:{line:122,column:5}},35:{start:{line:108,column:6},end:{line:113,column:7}},36:{start:{line:109,column:8},end:{line:109,column:42}},37:{start:{line:111,column:8},end:{line:111,column:19}},38:{start:{line:112,column:8},end:{line:112,column:27}},39:{start:{line:114,column:6},end:{line:121,column:7}},40:{start:{line:115,column:8},end:{line:115,column:35}},41:{start:{line:117,column:8},end:{line:118,column:43}},42:{start:{line:118,column:10},end:{line:118,column:43}},43:{start:{line:119,column:8},end:{line:120,column:35}},44:{start:{line:120,column:10},end:{line:120,column:35}},45:{start:{line:123,column:4},end:{line:125,column:7}},46:{start:{line:128,column:28},end:{line:128,column:38}},47:{start:{line:129,column:18},end:{line:129,column:20}},48:{start:{line:130,column:4},end:{line:132,column:5}},49:{start:{line:131,column:6},end:{line:131,column:45}},50:{start:{line:133,column:4},end:{line:147,column:9}},51:{start:{line:143,column:23},end:{line:143,column:36}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:17,column:14},end:{line:17,column:15}},loc:{start:{line:17,column:24},end:{line:19,column:5}},line:17},1:{name:"(anonymous_1)",decl:{start:{line:20,column:13},end:{line:20,column:14}},loc:{start:{line:20,column:19},end:{line:21,column:5}},line:20},2:{name:"(anonymous_2)",decl:{start:{line:22,column:12},end:{line:22,column:13}},loc:{start:{line:22,column:18},end:{line:23,column:5}},line:22},3:{name:"(anonymous_3)",decl:{start:{line:24,column:19},end:{line:24,column:20}},loc:{start:{line:24,column:25},end:{line:25,column:5}},line:24},4:{name:"(anonymous_4)",decl:{start:{line:26,column:17},end:{line:26,column:18}},loc:{start:{line:26,column:23},end:{line:27,column:5}},line:26},5:{name:"(anonymous_5)",decl:{start:{line:33,column:2},end:{line:33,column:3}},loc:{start:{line:33,column:21},end:{line:41,column:3}},line:33},6:{name:"(anonymous_6)",decl:{start:{line:42,column:2},end:{line:42,column:3}},loc:{start:{line:42,column:22},end:{line:63,column:3}},line:42},7:{name:"(anonymous_7)",decl:{start:{line:64,column:18},end:{line:64,column:19}},loc:{start:{line:64,column:24},end:{line:66,column:3}},line:64},8:{name:"(anonymous_8)",decl:{start:{line:67,column:12},end:{line:67,column:13}},loc:{start:{line:67,column:18},end:{line:74,column:3}},line:67},9:{name:"(anonymous_9)",decl:{start:{line:75,column:11},end:{line:75,column:12}},loc:{start:{line:75,column:17},end:{line:83,column:3}},line:75},10:{name:"(anonymous_10)",decl:{start:{line:84,column:2},end:{line:84,column:3}},loc:{start:{line:84,column:25},end:{line:88,column:3}},line:84},11:{name:"(anonymous_11)",decl:{start:{line:89,column:2},end:{line:89,column:3}},loc:{start:{line:89,column:32},end:{line:96,column:3}},line:89},12:{name:"(anonymous_12)",decl:{start:{line:97,column:13},end:{line:97,column:14}},loc:{start:{line:97,column:21},end:{line:126,column:3}},line:97},13:{name:"(anonymous_13)",decl:{start:{line:127,column:2},end:{line:127,column:3}},loc:{start:{line:127,column:11},end:{line:148,column:3}},line:127},14:{name:"(anonymous_14)",decl:{start:{line:143,column:15},end:{line:143,column:16}},loc:{start:{line:143,column:23},end:{line:143,column:36}},line:143}},branchMap:{0:{loc:{start:{line:45,column:12},end:{line:47,column:7}},type:"binary-expr",locations:[{start:{line:45,column:12},end:{line:45,column:27}},{start:{line:45,column:31},end:{line:47,column:7}}],line:45},1:{loc:{start:{line:53,column:12},end:{line:55,column:7}},type:"binary-expr",locations:[{start:{line:53,column:12},end:{line:53,column:27}},{start:{line:53,column:31},end:{line:55,column:7}}],line:53},2:{loc:{start:{line:68,column:4},end:{line:69,column:27}},type:"if",locations:[{start:{line:68,column:4},end:{line:69,column:27}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:68},3:{loc:{start:{line:77,column:4},end:{line:78,column:26}},type:"if",locations:[{start:{line:77,column:4},end:{line:78,column:26}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:77},4:{loc:{start:{line:90,column:4},end:{line:95,column:5}},type:"if",locations:[{start:{line:90,column:4},end:{line:95,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:90},5:{loc:{start:{line:90,column:8},end:{line:90,column:69}},type:"binary-expr",locations:[{start:{line:90,column:8},end:{line:90,column:29}},{start:{line:90,column:33},end:{line:90,column:69}}],line:90},6:{loc:{start:{line:98,column:4},end:{line:104,column:5}},type:"if",locations:[{start:{line:98,column:4},end:{line:104,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:98},7:{loc:{start:{line:106,column:4},end:{line:122,column:5}},type:"if",locations:[{start:{line:106,column:4},end:{line:122,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:106},8:{loc:{start:{line:114,column:6},end:{line:121,column:7}},type:"if",locations:[{start:{line:114,column:6},end:{line:121,column:7}},{start:{line:116,column:13},end:{line:121,column:7}}],line:114},9:{loc:{start:{line:114,column:10},end:{line:114,column:41}},type:"binary-expr",locations:[{start:{line:114,column:10},end:{line:114,column:13}},{start:{line:114,column:17},end:{line:114,column:41}}],line:114},10:{loc:{start:{line:117,column:8},end:{line:118,column:43}},type:"if",locations:[{start:{line:117,column:8},end:{line:118,column:43}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:117},11:{loc:{start:{line:119,column:8},end:{line:120,column:35}},type:"if",locations:[{start:{line:119,column:8},end:{line:120,column:35}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:119},12:{loc:{start:{line:130,column:4},end:{line:132,column:5}},type:"if",locations:[{start:{line:130,column:4},end:{line:132,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:130}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputJson.tsx"],names:[],mappings:"AAqKM,SACQ,KADR;AArKN,OAAO,WAAW;AAClB,OAAO,gBAAgB;AACvB,OAAO,gBAA8B;AAErC,OAAO;AACP,OAAO;AACP,OAAO;AACP,OAAO;AACP,OAAO;AACP,OAAO,qBAAqB;AAC5B,OAAO;AA0BP,qBAAqB,kBAAkB,MAAM,UAA0C;AAAA,EACrF,OAAO,eAAe;AAAA,IACpB,aAAa;AAAA,IACb,cAAc;AAAA,IACd,SAAS,CAAC,yBAAyB;AAAA,IACnC,UAAU,CAAC,SAAc;AACvB,aAAO,gBAAgB,MAAM,EAAC,QAAQ,GAAG,WAAW,GAAE,CAAC;AAAA,IACzD;AAAA,IACA,SAAS,MAAM;AAAA,IAAC;AAAA,IAChB,QAAQ,MAAM;AAAA,IAAC;AAAA,IACf,eAAe,MAAM;AAAA,IAAC;AAAA,IACtB,aAAa,MAAM;AAAA,IAAC;AAAA,EACtB;AAAA,EACA;AAAA,EACA;AAAA,EACA,MAA6B;AAAA,EAC7B,oBAA6B;AAAA,EAE7B,YAAY,OAAuB;AACjC,UAAM,KAAK;AACX,SAAK,YAAY;AACjB,SAAK,QAAQ;AAAA,MACX,WAAW;AAAA,MACX,aAAa;AAAA,MACb,WAAW,KAAK,MAAM,SAAU,KAAK,MAAM,KAAK;AAAA,IAClD;AAAA,EACF;AAAA,EAEA,oBAAqB;AACnB,SAAK,OAAO,WAAW,KAAK,KAAM;AAAA,MAChC,OAAO,KAAK,MAAM,SAAU,KAAK,MAAM,KAAK;AAAA,MAC5C,MAAM,KAAK,MAAM,QAAQ;AAAA,QACvB,MAAM;AAAA,MACR;AAAA,MACA,cAAc,KAAK,MAAM;AAAA,MACzB,SAAS;AAAA,MACT,OAAO;AAAA,MACP,gBAAgB;AAAA,MAChB,aAAa,KAAK,MAAM;AAAA,MACxB,MAAM,KAAK,MAAM,QAAQ;AAAA,QACvB,SAAS;AAAA,MACX;AAAA,MACA,eAAe;AAAA,MACf,SAAS,KAAK,MAAM;AAAA,MACpB,gBAAgB;AAAA,IAClB,CAAC;AAED,SAAK,KAAK,GAAG,UAAU,KAAK,QAAQ;AACpC,SAAK,KAAK,GAAG,SAAS,KAAK,OAAO;AAClC,SAAK,KAAK,GAAG,QAAQ,KAAK,MAAM;AAAA,EAClC;AAAA,EAEA,gBAAgB,MAAM;AACpB,SAAK,YAAY;AAAA,EACnB;AAAA,EAEA,UAAU,MAAM;AACd,QAAI,KAAK,MAAM;AAAS,WAAK,MAAM,QAAQ;AAC3C,SAAK,SAAS;AAAA,MACZ,WAAW;AAAA,MACX,aAAc,KAAK,cAAc;AAAA,IACnC,CAAC;AAAA,EACH;AAAA,EAEA,SAAS,MAAM;AACb,SAAK,YAAY;AACjB,QAAI,KAAK,MAAM;AAAQ,WAAK,MAAM,OAAO;AACzC,SAAK,SAAS;AAAA,MACZ,WAAW;AAAA,MACX,aAAa;AAAA,IACf,CAAC;AAAA,EACH;AAAA,EAEA,uBAAwB;AACtB,SAAK,KAAM,IAAI,UAAU,KAAK,QAAQ;AACtC,SAAK,KAAM,IAAI,SAAS,KAAK,OAAO;AACpC,SAAK,KAAM,IAAI,QAAQ,KAAK,MAAM;AAAA,EACpC;AAAA,EAEA,mBAAmB,WAA2B;AAC5C,QAAI,CAAC,KAAK,MAAM,aAAa,UAAU,UAAU,KAAK,MAAM,OAAO;AACjE,WAAK,oBAAoB;AACzB,WAAK,KAAM;AAAA,QACT,KAAK,MAAM,SAAU,KAAK,MAAM,KAAK;AAAA,MACvC;AAAA,IACF;AAAA,EACF;AAAA,EAEA,WAAW,CAAC,OAAgB;AAC1B,QAAI,KAAK,mBAAmB;AAC1B,WAAK,oBAAoB;AACzB,WAAK,SAAS;AAAA,QACZ,WAAW,KAAK,KAAM,SAAS;AAAA,MACjC,CAAC;AACD;AAAA,IACF;AACA,UAAM,UAAU,KAAK,KAAM,SAAS;AAEpC,QAAI,KAAK,MAAM,cAAc,SAAS;AACpC,UAAI,aAAa;AACjB,UAAI;AACF,sBAAc,KAAK,MAAM,OAAO;AAAA,MAClC,SAAQ,MAAM;AACZ,cAAM;AACN,gBAAQ,KAAK,IAAI;AAAA,MACnB;AAEA,UAAI,OAAO,KAAK,MAAM,eAAe;AACnC,aAAK,MAAM,cAAc;AAAA,MAC3B,OACK;AACH,YAAI,KAAK,MAAM;AAAU,eAAK,MAAM,SAAS,WAAW;AACxD,YAAI,KAAK,MAAM;AAAa,eAAK,MAAM,YAAY;AAAA,MACrD;AAAA,IACF;AAEA,SAAK,SAAS;AAAA,MACZ,WAAW;AAAA,IACb,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,YAAW,IAAI,KAAK;AAC3B,UAAM,QAAQ,CAAC;AACf,QAAI,KAAK,MAAM,WAAW;AACxB,YAAM,YAAY,KAAK,MAAM;AAAA,IAC/B;AAEA,WAAO,qBAAC,SAAI,WAAU,cAAa,eAAe,KAAK,eAAe,eAAY,QAChF;AAAA,2BAAC,SAAI,WAAW,WAAW,uBAAuB,EAAC,2BAA2B,YAAW,CAAC,GAAG;AAAA;AAAA,QACrF,oBAAC,SAAI,iBAAG;AAAA,QAAM;AAAA,SACtB;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,WAAW,WAAW,wBAAwB,KAAK,MAAM,SAAS;AAAA,UAClE,KAAK,CAAC,OAAO,KAAK,MAAM;AAAA,UACxB;AAAA;AAAA,MACF;AAAA,OACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"73341c4954366276bd838a194b53fa026df00a42"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Pn=function(){return s},s}Pn();class wW extends bn.Component{constructor(t){Pn().f[5]++,Pn().s[4]++;super(t);nn(this,"_keyEvent");nn(this,"_doc");nn(this,"_el",(Pn().s[2]++,null));nn(this,"_cancelNextChange",(Pn().s[3]++,!1));nn(this,"onPointerDown",(Pn().s[11]++,()=>{Pn().f[7]++,Pn().s[12]++,this._keyEvent="pointer"}));nn(this,"onFocus",(Pn().s[13]++,()=>{Pn().f[8]++,Pn().s[14]++,this.props.onFocus?(Pn().b[2][0]++,Pn().s[15]++,this.props.onFocus()):Pn().b[2][1]++,Pn().s[16]++,this.setState({isEditing:!0,showMessage:this._keyEvent==="keyboard"})}));nn(this,"onBlur",(Pn().s[17]++,()=>{Pn().f[9]++,Pn().s[18]++,this._keyEvent="keyboard",Pn().s[19]++,this.props.onBlur?(Pn().b[3][0]++,Pn().s[20]++,this.props.onBlur()):Pn().b[3][1]++,Pn().s[21]++,this.setState({isEditing:!1,showMessage:!1})}));nn(this,"onChange",(Pn().s[28]++,t=>{if(Pn().f[12]++,Pn().s[29]++,this._cancelNextChange){Pn().b[6][0]++,Pn().s[30]++,this._cancelNextChange=!1,Pn().s[31]++,this.setState({prevValue:this._doc.getValue()}),Pn().s[32]++;return}else Pn().b[6][1]++;const r=(Pn().s[33]++,this._doc.getValue());if(Pn().s[34]++,this.state.prevValue!==r){Pn().b[7][0]++;let i,o;Pn().s[35]++;try{Pn().s[36]++,i=JSON.parse(r)}catch(s){Pn().s[37]++,o=s,Pn().s[38]++,console.warn(s)}Pn().s[39]++,Pn().b[9][0]++,o&&(Pn().b[9][1]++,this.props.onJSONInvalid)?(Pn().b[8][0]++,Pn().s[40]++,this.props.onJSONInvalid()):(Pn().b[8][1]++,Pn().s[41]++,this.props.onChange?(Pn().b[10][0]++,Pn().s[42]++,this.props.onChange(i)):Pn().b[10][1]++,Pn().s[43]++,this.props.onJSONValid?(Pn().b[11][0]++,Pn().s[44]++,this.props.onJSONValid()):Pn().b[11][1]++)}else Pn().b[7][1]++;Pn().s[45]++,this.setState({prevValue:r})}));Pn().s[5]++,this._keyEvent="keyboard",Pn().s[6]++,this.state={isEditing:!1,showMessage:!1,prevValue:this.props.getValue(this.props.layer)}}componentDidMount(){Pn().f[6]++,Pn().s[7]++,this._doc=Kc(this._el,{value:this.props.getValue(this.props.layer),mode:(Pn().b[0][0]++,this.props.mode||(Pn().b[0][1]++,{name:"mgl"})),lineWrapping:this.props.lineWrapping,tabSize:2,theme:"maputnik",viewportMargin:1/0,lineNumbers:this.props.lineNumbers,lint:(Pn().b[1][0]++,this.props.lint||(Pn().b[1][1]++,{context:"layer"})),matchBrackets:!0,gutters:this.props.gutters,scrollbarStyle:"null"}),Pn().s[8]++,this._doc.on("change",this.onChange),Pn().s[9]++,this._doc.on("focus",this.onFocus),Pn().s[10]++,this._doc.on("blur",this.onBlur)}componentWillUnMount(){Pn().f[10]++,Pn().s[22]++,this._doc.off("change",this.onChange),Pn().s[23]++,this._doc.off("focus",this.onFocus),Pn().s[24]++,this._doc.off("blur",this.onBlur)}componentDidUpdate(t){Pn().f[11]++,Pn().s[25]++,Pn().b[5][0]++,!this.state.isEditing&&(Pn().b[5][1]++,t.layer!==this.props.layer)?(Pn().b[4][0]++,Pn().s[26]++,this._cancelNextChange=!0,Pn().s[27]++,this._doc.setValue(this.props.getValue(this.props.layer))):Pn().b[4][1]++}render(){Pn().f[13]++;const{showMessage:t}=(Pn().s[46]++,this.state),r=(Pn().s[47]++,{});return Pn().s[48]++,this.props.maxHeight?(Pn().b[12][0]++,Pn().s[49]++,r.maxHeight=this.props.maxHeight):Pn().b[12][1]++,Pn().s[50]++,N.jsxs("div",{className:"JSONEditor",onPointerDown:this.onPointerDown,"aria-hidden":"true",children:[N.jsxs("div",{className:Af("JSONEditor__message",{"JSONEditor__message--on":t}),children:["Press ",N.jsx("kbd",{children:"ESC"})," to lose focus"]}),N.jsx("div",{className:Af("codemirror-container",this.props.className),ref:i=>(Pn().f[14]++,Pn().s[51]++,this._el=i),style:r})]})}}nn(wW,"defaultProps",(Pn().s[0]++,{lineNumbers:!0,lineWrapping:!1,gutters:["CodeMirror-lint-markers"],getValue:t=>(Pn().f[0]++,Pn().s[1]++,_W(t,{indent:2,maxLength:40})),onFocus:()=>{Pn().f[1]++},onBlur:()=>{Pn().f[2]++},onJSONInvalid:()=>{Pn().f[3]++},onJSONValid:()=>{Pn().f[4]++}}));function t4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldJson.tsx",n="60f4cd40e505c4a9f8de1078b77716b10a4a4264",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldJson.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:6,column:61}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:7,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldJson.tsx"],names:[],mappings:"AASW;AATX,OAAO,WAAW;AAClB,OAAO,eAAiC;AAMxC,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,WAAO,oBAAC,aAAW,GAAG,KAAK,OAAO;AAAA,EACpC;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"60f4cd40e505c4a9f8de1078b77716b10a4a4264"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return t4=function(){return s},s}t4();class c8 extends bn.Component{render(){return t4().f[0]++,t4().s[0]++,N.jsx(wW,{...this.props})}}var S_="M12.42,5.29C11.32,5.19 10.35,6 10.25,7.11L10,10H12.82V12H9.82L9.38,17.07C9.18,19.27 7.24,20.9 5.04,20.7C3.79,20.59 2.66,19.9 2,18.83L3.5,17.33C3.83,18.38 4.96,18.97 6,18.63C6.78,18.39 7.33,17.7 7.4,16.89L7.82,12H4.82V10H8L8.27,6.93C8.46,4.73 10.39,3.1 12.6,3.28C13.86,3.39 15,4.09 15.66,5.17L14.16,6.67C13.91,5.9 13.23,5.36 12.42,5.29M22,13.65L20.59,12.24L17.76,15.07L14.93,12.24L13.5,13.65L16.35,16.5L13.5,19.31L14.93,20.72L17.76,17.89L20.59,20.72L22,19.31L19.17,16.5L22,13.65Z",spe="M7,10L12,15L17,10H7Z",lpe="M7,15L12,10L17,15H7Z",d8="M22,10A2,2 0 0,1 20,12H4A2,2 0 0,1 2,10V3H4V5H8V3H10V5H14V3H16V5H20V3H22V10M4,10H8V7H4V10M10,10H14V7H10V10M20,10V7H16V10H20M11,14H13V17H16V19H13V22H11V19H8V17H11V14Z";function t1(){var e="/home/runner/work/maputnik/maputnik/src/libs/filterops.ts",n="99dad9631fbee5fc23be2dafaf7c7eea92c38eac",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/filterops.ts",statementMap:{0:{start:{line:2,column:34},end:{line:2,column:56}},1:{start:{line:3,column:28},end:{line:3,column:41}},2:{start:{line:4,column:30},end:{line:4,column:123}},3:{start:{line:4,column:88},end:{line:4,column:122}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:4,column:80},end:{line:4,column:81}},loc:{start:{line:4,column:88},end:{line:4,column:122}},line:4}},branchMap:{},s:{0:0,1:0,2:0,3:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/filterops.ts"],names:[],mappings:"AAAA,OAAO,YAAY;AAEZ,aAAM,qBAAqB,CAAC,OAAO,OAAO,MAAM;AAChD,aAAM,eAAe,CAAC,MAAM,KAAK;AACjC,aAAM,iBAAiB,OAC3B,KAAK,OAAO,gBAAgB,MAAM,EAClC,OAAO,QAAM,mBAAmB,QAAQ,EAAE,IAAI,CAAC;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"99dad9631fbee5fc23be2dafaf7c7eea92c38eac"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return t1=function(){return s},s}t1();const h8=(t1().s[0]++,["all","any","none"]);t1().s[1]++;const upe=(t1().s[2]++,Object.keys(Ji.filter_operator.values).filter(e=>(t1().f[0]++,t1().s[3]++,h8.indexOf(e)<0)));function Wr(){var e="/home/runner/work/maputnik/maputnik/src/components/SingleFilterEditor.tsx",n="3d8bcd70e58647712bf929f9e6ef3e13fde3cd73",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/SingleFilterEditor.tsx",statementMap:{0:{start:{line:8,column:2},end:{line:9,column:13}},1:{start:{line:9,column:4},end:{line:9,column:13}},2:{start:{line:10,column:2},end:{line:11,column:13}},3:{start:{line:11,column:4},end:{line:11,column:13}},4:{start:{line:12,column:2},end:{line:12,column:23}},5:{start:{line:15,column:19},end:{line:15,column:40}},6:{start:{line:16,column:2},end:{line:18,column:3}},7:{start:{line:17,column:4},end:{line:17,column:13}},8:{start:{line:19,column:2},end:{line:25,column:3}},9:{start:{line:20,column:4},end:{line:20,column:16}},10:{start:{line:21,column:9},end:{line:25,column:3}},11:{start:{line:22,column:4},end:{line:22,column:17}},12:{start:{line:24,column:4},end:{line:24,column:13}},13:{start:{line:28,column:2},end:{line:28,column:21}},14:{start:{line:29,column:2},end:{line:29,column:22}},15:{start:{line:30,column:2},end:{line:30,column:11}},16:{start:{line:33,column:24},end:{line:35,column:3}},17:{start:{line:37,column:20},end:{line:37,column:76}},18:{start:{line:38,column:4},end:{line:42,column:5}},19:{start:{line:39,column:6},end:{line:39,column:43}},20:{start:{line:40,column:11},end:{line:42,column:5}},21:{start:{line:41,column:6},end:{line:41,column:47}},22:{start:{line:43,column:4},end:{line:43,column:35}},23:{start:{line:46,column:14},end:{line:46,column:31}},24:{start:{line:47,column:21},end:{line:47,column:25}},25:{start:{line:48,column:25},end:{line:48,column:29}},26:{start:{line:49,column:23},end:{line:49,column:33}},27:{start:{line:50,column:4},end:{line:77,column:9}},28:{start:{line:56,column:72},end:{line:56,column:92}},29:{start:{line:57,column:41},end:{line:57,column:104}},30:{start:{line:65,column:37},end:{line:65,column:100}},31:{start:{line:74,column:27},end:{line:74,column:89}}},fnMap:{0:{name:"tryParseInt",decl:{start:{line:7,column:9},end:{line:7,column:20}},loc:{start:{line:7,column:24},end:{line:13,column:1}},line:7},1:{name:"tryParseBool",decl:{start:{line:14,column:9},end:{line:14,column:21}},loc:{start:{line:14,column:25},end:{line:26,column:1}},line:14},2:{name:"parseFilter",decl:{start:{line:27,column:9},end:{line:27,column:20}},loc:{start:{line:27,column:24},end:{line:31,column:1}},line:27},3:{name:"(anonymous_3)",decl:{start:{line:36,column:2},end:{line:36,column:3}},loc:{start:{line:36,column:58},end:{line:44,column:3}},line:36},4:{name:"(anonymous_4)",decl:{start:{line:45,column:2},end:{line:45,column:3}},loc:{start:{line:45,column:11},end:{line:78,column:3}},line:45},5:{name:"(anonymous_5)",decl:{start:{line:56,column:58},end:{line:56,column:59}},loc:{start:{line:56,column:72},end:{line:56,column:92}},line:56},6:{name:"(anonymous_6)",decl:{start:{line:57,column:20},end:{line:57,column:21}},loc:{start:{line:57,column:41},end:{line:57,column:104}},line:57},7:{name:"(anonymous_7)",decl:{start:{line:65,column:20},end:{line:65,column:21}},loc:{start:{line:65,column:37},end:{line:65,column:100}},line:65},8:{name:"(anonymous_8)",decl:{start:{line:74,column:20},end:{line:74,column:21}},loc:{start:{line:74,column:27},end:{line:74,column:89}},line:74}},branchMap:{0:{loc:{start:{line:8,column:2},end:{line:9,column:13}},type:"if",locations:[{start:{line:8,column:2},end:{line:9,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:8},1:{loc:{start:{line:10,column:2},end:{line:11,column:13}},type:"if",locations:[{start:{line:10,column:2},end:{line:11,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:10},2:{loc:{start:{line:16,column:2},end:{line:18,column:3}},type:"if",locations:[{start:{line:16,column:2},end:{line:18,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:16},3:{loc:{start:{line:19,column:2},end:{line:25,column:3}},type:"if",locations:[{start:{line:19,column:2},end:{line:25,column:3}},{start:{line:21,column:9},end:{line:25,column:3}}],line:19},4:{loc:{start:{line:21,column:9},end:{line:25,column:3}},type:"if",locations:[{start:{line:21,column:9},end:{line:25,column:3}},{start:{line:23,column:9},end:{line:25,column:3}}],line:21},5:{loc:{start:{line:38,column:4},end:{line:42,column:5}},type:"if",locations:[{start:{line:38,column:4},end:{line:42,column:5}},{start:{line:40,column:11},end:{line:42,column:5}}],line:38},6:{loc:{start:{line:38,column:8},end:{line:38,column:49}},type:"binary-expr",locations:[{start:{line:38,column:8},end:{line:38,column:26}},{start:{line:38,column:30},end:{line:38,column:49}}],line:38},7:{loc:{start:{line:40,column:11},end:{line:42,column:5}},type:"if",locations:[{start:{line:40,column:11},end:{line:42,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:40},8:{loc:{start:{line:69,column:6},end:{line:76,column:10}},type:"binary-expr",locations:[{start:{line:69,column:6},end:{line:69,column:27}},{start:{line:69,column:47},end:{line:76,column:10}}],line:69}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/SingleFilterEditor.tsx"],names:[],mappings:"AA+DW,SAEH,KAFG;AA/DX,OAAO,WAAW;AAElB,SAAQ,sBAAqB;AAC7B,OAAO,iBAAiB;AACxB,OAAO,uBAAuB;AAC9B,OAAO,iBAAiB;AAExB,SAAS,YAAY,GAAoB;AACvC,MAAI,MAAM;AAAI,WAAO;AACrB,MAAI,MAAM,CAAW;AAAG,WAAO;AAC/B,SAAO,WAAW,CAAW;AAC/B;AAEA,SAAS,aAAa,GAAqB;AACzC,QAAM,WAAY,OAAO,MAAO;AAChC,MAAG,CAAC,UAAU;AACZ,WAAO;AAAA,EACT;AAEA,MAAG,EAAE,MAAM,cAAc,GAAG;AAC1B,WAAO;AAAA,EACT,WACQ,EAAE,MAAM,eAAe,GAAG;AAChC,WAAO;AAAA,EACT,OACK;AACH,WAAO;AAAA,EACT;AACF;AAEA,SAAS,YAAY,GAA8B;AACjD,MAAI,YAAY,CAAQ;AACxB,MAAI,aAAa,CAAQ;AACzB,SAAO;AACT;AAQA,qBAAqB,2BAA2B,MAAM,UAAmC;AAAA,EACvF,OAAO,eAAe;AAAA,IACpB,YAAY,CAAC;AAAA,EACf;AAAA,EAEA,oBAAoB,UAAkB,cAAsB,YAAsB;AAChF,QAAI,YAAY,CAAC,UAAU,cAAc,GAAG,WAAW,IAAI,WAAW,CAAC;AACvE,QAAG,aAAa,SAAS,aAAa,QAAQ;AAC5C,kBAAY,CAAC,UAAU,YAAY;AAAA,IACrC,WAAU,WAAW,WAAW,GAAG;AACjC,kBAAY,CAAC,UAAU,cAAc,EAAE;AAAA,IACzC;AACA,SAAK,MAAM,SAAS,SAAS;AAAA,EAC/B;AAAA,EAEA,SAAS;AACP,UAAM,IAAI,KAAK,MAAM;AACrB,UAAM,WAAW,EAAE,CAAC;AACpB,UAAM,eAAe,EAAE,CAAC;AACxB,UAAM,aAAa,EAAE,MAAM,CAAC;AAE5B,WAAO,qBAAC,SAAI,WAAU,iCACpB;AAAA,0BAAC,SAAI,WAAU,mCACb;AAAA,QAAC;AAAA;AAAA,UACC,cAAW;AAAA,UACX,OAAO;AAAA,UACP,SAAS,OAAO,KAAK,KAAK,MAAM,UAAW,EAAE,IAAI,cAAY,CAAC,UAAU,QAAQ,CAAC;AAAA,UACjF,UAAU,CAAC,oBAA4B,KAAK,oBAAoB,UAAU,iBAAiB,UAAU;AAAA;AAAA,MACvG,GACF;AAAA,MACA,oBAAC,SAAI,WAAU,mCACb;AAAA,QAAC;AAAA;AAAA,UACC,cAAW;AAAA,UACX,OAAO;AAAA,UACP,UAAU,CAAC,gBAAwB,KAAK,oBAAoB,aAAa,cAAc,UAAU;AAAA,UACjG,SAAS;AAAA;AAAA,MACX,GACF;AAAA,MACC,WAAW,SAAS,KACrB,oBAAC,SAAI,WAAU,+BACb;AAAA,QAAC;AAAA;AAAA,UACC,cAAW;AAAA,UACX,OAAO,WAAW,KAAK,GAAG;AAAA,UAC1B,UAAU,CAAC,MAAc,KAAK,oBAAoB,UAAU,cAAc,EAAE,MAAM,GAAG,CAAC;AAAA;AAAA,MACxF,GACF;AAAA,OAEF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"3d8bcd70e58647712bf929f9e6ef3e13fde3cd73"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Wr=function(){return s},s}Wr();function Ape(e){return Wr().f[0]++,Wr().s[0]++,e===""?(Wr().b[0][0]++,Wr().s[1]++,e):(Wr().b[0][1]++,Wr().s[2]++,isNaN(e)?(Wr().b[1][0]++,Wr().s[3]++,e):(Wr().b[1][1]++,Wr().s[4]++,parseFloat(e)))}function cpe(e){Wr().f[1]++;const n=(Wr().s[5]++,typeof e=="string");if(Wr().s[6]++,n)Wr().b[2][1]++;else return Wr().b[2][0]++,Wr().s[7]++,e;return Wr().s[8]++,e.match(/^\s*true\s*$/)?(Wr().b[3][0]++,Wr().s[9]++,!0):(Wr().b[3][1]++,Wr().s[10]++,e.match(/^\s*false\s*$/)?(Wr().b[4][0]++,Wr().s[11]++,!1):(Wr().b[4][1]++,Wr().s[12]++,e))}function dpe(e){return Wr().f[2]++,Wr().s[13]++,e=Ape(e),Wr().s[14]++,e=cpe(e),Wr().s[15]++,e}class MW extends bn.Component{onFilterPartChanged(n,t,r){Wr().f[3]++;let i=(Wr().s[17]++,[n,t,...r.map(dpe)]);Wr().s[18]++,Wr().b[6][0]++,n==="has"||(Wr().b[6][1]++,n==="!has")?(Wr().b[5][0]++,Wr().s[19]++,i=[n,t]):(Wr().b[5][1]++,Wr().s[20]++,r.length===0?(Wr().b[7][0]++,Wr().s[21]++,i=[n,t,""]):Wr().b[7][1]++),Wr().s[22]++,this.props.onChange(i)}render(){Wr().f[4]++;const n=(Wr().s[23]++,this.props.filter),t=(Wr().s[24]++,n[0]),r=(Wr().s[25]++,n[1]),i=(Wr().s[26]++,n.slice(2));return Wr().s[27]++,N.jsxs("div",{className:"maputnik-filter-editor-single",children:[N.jsx("div",{className:"maputnik-filter-editor-property",children:N.jsx(Qy,{"aria-label":"key",value:r,options:Object.keys(this.props.properties).map(o=>(Wr().f[5]++,Wr().s[28]++,[o,o])),onChange:o=>(Wr().f[6]++,Wr().s[29]++,this.onFilterPartChanged(t,o,i))})}),N.jsx("div",{className:"maputnik-filter-editor-operator",children:N.jsx(w1,{"aria-label":"function",value:t,onChange:o=>(Wr().f[7]++,Wr().s[30]++,this.onFilterPartChanged(o,r,i)),options:upe})}),(Wr().b[8][0]++,i.length>0&&(Wr().b[8][1]++,N.jsx("div",{className:"maputnik-filter-editor-args",children:N.jsx(Sd,{"aria-label":"value",value:i.join(","),onChange:o=>(Wr().f[8]++,Wr().s[31]++,this.onFilterPartChanged(t,r,o.split(",")))})})))]})}}nn(MW,"defaultProps",(Wr().s[16]++,{properties:{}}));function n4(){var e="/home/runner/work/maputnik/maputnik/src/components/FilterEditorBlock.tsx",n="de90f2b7c2375daa3c7ce706798711f2e425045c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FilterEditorBlock.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:18,column:9}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:19,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FilterEditorBlock.tsx"],names:[],mappings:"AAUW,SAOD,KAPC;AAVX,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,SAAQ,gBAAe;AAMvB,qBAAqB,0BAA0B,MAAM,UAAkC;AAAA,EACrF,SAAS;AACP,WAAO,qBAAC,SAAI,WAAU,gCACpB;AAAA,0BAAC,SAAI,WAAU,uCACb;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,SAAS,KAAK,MAAM;AAAA,UACpB,OAAM;AAAA,UAEN,8BAAC,YAAS;AAAA;AAAA,MACZ,GACF;AAAA,MACA,oBAAC,SAAI,WAAU,wCACZ,eAAK,MAAM,UACd;AAAA,OACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"de90f2b7c2375daa3c7ce706798711f2e425045c"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return n4=function(){return s},s}n4();class hpe extends bn.Component{render(){return n4().f[0]++,n4().s[0]++,N.jsxs("div",{className:"maputnik-filter-editor-block",children:[N.jsx("div",{className:"maputnik-filter-editor-block-action",children:N.jsx(Ka,{className:"maputnik-delete-filter",onClick:this.props.onDelete,title:"Delete filter block",children:N.jsx(Ly,{})})}),N.jsx("div",{className:"maputnik-filter-editor-block-content",children:this.props.children})]})}}var fpe=1/0,ppe="[object Symbol]",f8="\\ud800-\\udfff",SW="\\u0300-\\u036f\\ufe20-\\ufe23",EW="\\u20d0-\\u20f0",OW="\\ufe0e\\ufe0f",mpe="["+f8+"]",NE="["+SW+EW+"]",GE="\\ud83c[\\udffb-\\udfff]",gpe="(?:"+NE+"|"+GE+")",BW="[^"+f8+"]",kW="(?:\\ud83c[\\udde6-\\uddff]){2}",IW="[\\ud800-\\udbff][\\udc00-\\udfff]",TW="\\u200d",KW=gpe+"?",PW="["+OW+"]?",ype="(?:"+TW+"(?:"+[BW,kW,IW].join("|")+")"+PW+KW+")*",vpe=PW+KW+ype,Cpe="(?:"+[BW+NE+"?",NE,kW,IW,mpe].join("|")+")",_pe=RegExp(GE+"(?="+GE+")|"+Cpe+vpe,"g"),bpe=RegExp("["+TW+f8+SW+EW+OW+"]"),xpe=typeof window=="object"&&window&&window.Object===Object&&window,wpe=typeof self=="object"&&self&&self.Object===Object&&self,Mpe=xpe||wpe||Function("return this")();function Spe(e){return e.split("")}function FW(e){return bpe.test(e)}function Epe(e){return FW(e)?Ope(e):Spe(e)}function Ope(e){return e.match(_pe)||[]}var Bpe=Object.prototype,kpe=Bpe.toString,HT=Mpe.Symbol,ZT=HT?HT.prototype:void 0,XT=ZT?ZT.toString:void 0;function Ipe(e,n,t){var r=-1,i=e.length;n<0&&(n=-n>i?0:i+n),t=t>i?i:t,t<0&&(t+=i),i=n>t?0:t-n>>>0,n>>>=0;for(var o=Array(i);++r<i;)o[r]=e[r+n];return o}function Tpe(e){if(typeof e=="string")return e;if(Dpe(e))return XT?XT.call(e):"";var n=e+"";return n=="0"&&1/e==-fpe?"-0":n}function Kpe(e,n,t){var r=e.length;return t=t===void 0?r:t,!n&&t>=r?e:Ipe(e,n,t)}function Ppe(e){return function(n){n=DW(n);var t=FW(n)?Epe(n):void 0,r=t?t[0]:n.charAt(0),i=t?Kpe(t,1).join(""):n.slice(1);return r[e]()+i}}function Fpe(e){return!!e&&typeof e=="object"}function Dpe(e){return typeof e=="symbol"||Fpe(e)&&kpe.call(e)==ppe}function DW(e){return e==null?"":Tpe(e)}function Upe(e){return Rpe(DW(e).toLowerCase())}var Rpe=Ppe("toUpperCase"),Lpe=Upe;const p8=ga(Lpe);function Nh(){var e="/home/runner/work/maputnik/maputnik/src/libs/label-from-field-name.ts",n="8b86d889d32efa9a6cc667b2fa3579002dfb58fc",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/label-from-field-name.ts",statementMap:{0:{start:{line:4,column:16},end:{line:4,column:36}},1:{start:{line:5,column:2},end:{line:9,column:3}},2:{start:{line:6,column:4},end:{line:6,column:52}},3:{start:{line:8,column:4},end:{line:8,column:22}},4:{start:{line:10,column:2},end:{line:10,column:27}}},fnMap:{0:{name:"labelFromFieldName",decl:{start:{line:2,column:24},end:{line:2,column:42}},loc:{start:{line:2,column:54},end:{line:11,column:1}},line:2}},branchMap:{0:{loc:{start:{line:5,column:2},end:{line:9,column:3}},type:"if",locations:[{start:{line:5,column:2},end:{line:9,column:3}},{start:{line:7,column:9},end:{line:9,column:3}}],line:5}},s:{0:0,1:0,2:0,3:0,4:0},f:{0:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/label-from-field-name.ts"],names:[],mappings:"AAAA,OAAO,gBAAgB;AAEvB,wBAAwB,mBAAmB,WAAmB;AAC5D,MAAI;AACJ,QAAM,QAAQ,UAAU,MAAM,GAAG;AACjC,MAAI,MAAM,SAAS,GAAG;AACpB,YAAQ,UAAU,MAAM,GAAG,EAAE,MAAM,CAAC,EAAE,KAAK,GAAG;AAAA,EAChD,OACK;AACH,YAAQ;AAAA,EACV;AACA,SAAO,WAAW,KAAK;AACzB;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"8b86d889d32efa9a6cc667b2fa3579002dfb58fc"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Nh=function(){return s},s}Nh();function D5(e){Nh().f[0]++;let n;const t=(Nh().s[0]++,e.split("-"));return Nh().s[1]++,t.length>1?(Nh().b[0][0]++,Nh().s[2]++,n=e.split("-").slice(1).join(" ")):(Nh().b[0][1]++,Nh().s[3]++,n=e),Nh().s[4]++,p8(n)}function Di(){var e="/home/runner/work/maputnik/maputnik/src/components/_ExpressionProperty.tsx",n="aa37ab38c9a5b53df0808e7895b75ac0976599a1",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/_ExpressionProperty.tsx",statementMap:{0:{start:{line:10,column:24},end:{line:16,column:3}},1:{start:{line:18,column:4},end:{line:18,column:17}},2:{start:{line:19,column:4},end:{line:21,column:6}},3:{start:{line:23,column:18},end:{line:27,column:3}},4:{start:{line:24,column:4},end:{line:26,column:7}},5:{start:{line:28,column:16},end:{line:32,column:3}},6:{start:{line:29,column:4},end:{line:31,column:7}},7:{start:{line:34,column:61},end:{line:34,column:71}},8:{start:{line:35,column:26},end:{line:35,column:36}},9:{start:{line:36,column:25},end:{line:36,column:52}},10:{start:{line:37,column:42},end:{line:59,column:8}},11:{start:{line:60,column:21},end:{line:60,column:83}},12:{start:{line:61,column:23},end:{line:61,column:39}},13:{start:{line:62,column:26},end:{line:62,column:40}},14:{start:{line:63,column:24},end:{line:63,column:26}},15:{start:{line:65,column:6},end:{line:65,column:65}},16:{start:{line:67,column:4},end:{line:78,column:5}},17:{start:{line:68,column:6},end:{line:68,column:52}},18:{start:{line:70,column:6},end:{line:74,column:9}},19:{start:{line:71,column:8},end:{line:71,column:45}},20:{start:{line:73,column:8},end:{line:73,column:39}},21:{start:{line:75,column:6},end:{line:77,column:7}},22:{start:{line:76,column:8},end:{line:76,column:37}},23:{start:{line:79,column:4},end:{line:109,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:12,column:13},end:{line:12,column:14}},loc:{start:{line:12,column:19},end:{line:13,column:5}},line:12},1:{name:"(anonymous_1)",decl:{start:{line:14,column:12},end:{line:14,column:13}},loc:{start:{line:14,column:18},end:{line:15,column:5}},line:14},2:{name:"(anonymous_2)",decl:{start:{line:17,column:2},end:{line:17,column:3}},loc:{start:{line:17,column:21},end:{line:22,column:3}},line:17},3:{name:"(anonymous_3)",decl:{start:{line:23,column:18},end:{line:23,column:19}},loc:{start:{line:23,column:28},end:{line:27,column:3}},line:23},4:{name:"(anonymous_4)",decl:{start:{line:28,column:16},end:{line:28,column:17}},loc:{start:{line:28,column:22},end:{line:32,column:3}},line:28},5:{name:"(anonymous_5)",decl:{start:{line:33,column:2},end:{line:33,column:3}},loc:{start:{line:33,column:11},end:{line:110,column:3}},line:33},6:{name:"getValue",decl:{start:{line:64,column:13},end:{line:64,column:21}},loc:{start:{line:64,column:28},end:{line:66,column:5}},line:64},7:{name:"(anonymous_7)",decl:{start:{line:70,column:36},end:{line:70,column:37}},loc:{start:{line:70,column:55},end:{line:72,column:7}},line:70},8:{name:"(anonymous_8)",decl:{start:{line:72,column:17},end:{line:72,column:18}},loc:{start:{line:72,column:36},end:{line:74,column:7}},line:72}},branchMap:{0:{loc:{start:{line:36,column:25},end:{line:36,column:52}},type:"cond-expr",locations:[{start:{line:36,column:35},end:{line:36,column:45}},{start:{line:36,column:48},end:{line:36,column:52}}],line:36},1:{loc:{start:{line:38,column:6},end:{line:48,column:7}},type:"binary-expr",locations:[{start:{line:38,column:6},end:{line:38,column:23}},{start:{line:38,column:43},end:{line:48,column:7}}],line:38},2:{loc:{start:{line:60,column:21},end:{line:60,column:83}},type:"cond-expr",locations:[{start:{line:60,column:44},end:{line:60,column:53}},{start:{line:60,column:56},end:{line:60,column:83}}],line:60},3:{loc:{start:{line:67,column:4},end:{line:78,column:5}},type:"if",locations:[{start:{line:67,column:4},end:{line:78,column:5}},{start:{line:69,column:11},end:{line:78,column:5}}],line:67},4:{loc:{start:{line:75,column:6},end:{line:77,column:7}},type:"if",locations:[{start:{line:75,column:6},end:{line:77,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:75}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/_ExpressionProperty.tsx"],names:[],mappings:"AA4DM,mBASM,KATN;AA5DN,OAAO,WAAW;AAClB,SAAQ,UAAU,cAAa;AAC/B,OAAO,qBAAqB;AAE5B,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,wBAAwB;AAC/B,OAAO,eAAe;AAqBtB,qBAAqB,2BAA2B,MAAM,UAA4D;AAAA,EAChH,OAAO,eAAe;AAAA,IACpB,QAAQ,CAAC;AAAA,IACT,SAAS,MAAM;AAAA,IAAC;AAAA,IAChB,QAAQ,MAAM;AAAA,IAAC;AAAA,EACjB;AAAA,EAEA,YAAa,OAA+B;AAC1C,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,WAAW;AAAA,IACb;AAAA,EACF;AAAA,EAEA,gBAAgB,CAAC,SAAgB;AAC/B,SAAK,SAAS;AAAA,MACZ,WAAW;AAAA,IACb,CAAC;AAAA,EACH;AAAA,EAEA,cAAc,MAAM;AAClB,SAAK,SAAS;AAAA,MACZ,WAAW;AAAA,IACb,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,QAAQ,WAAW,WAAW,OAAO,QAAO,IAAI,KAAK;AAC5D,UAAM,EAAC,UAAS,IAAI,KAAK;AACzB,UAAM,eAAe,UAAU,CAAC,QAAQ,IAAI;AAE5C,UAAM,gBACJ,iCACG;AAAA,WAAK,MAAM,UACV;AAAA,QAAC;AAAA;AAAA,UAEC,SAAS,KAAK,MAAM;AAAA,UACpB,UAAU;AAAA,UACV,WAAU;AAAA,UACV,OAAM;AAAA,UAEN,8BAAC,UAAO;AAAA;AAAA,QANJ;AAAA,MAON;AAAA,MAEF;AAAA,QAAC;AAAA;AAAA,UAEC,SAAS,KAAK,MAAM;AAAA,UACpB,WAAU;AAAA,UACV,OAAM;AAAA,UAEN,8BAAC,YAAS;AAAA;AAAA,QALN;AAAA,MAMN;AAAA,OACF;AAGF,UAAM,WAAW,cAAc,SAAY,YAAY,GAAG,SAAS,IAAI,SAAS;AAEhF,UAAM,aAAa,OAAQ,QAAQ;AACnC,UAAM,gBAAgB,GAAG,QAAQ;AACjC,UAAM,cAAc,CAAC;AAErB,aAAS,SAAS,MAAW;AAC3B,aAAO,gBAAgB,MAAM,EAAC,QAAQ,GAAG,WAAW,GAAE,CAAC;AAAA,IACzD;AAEA,QAAI,WAAW;AACb,kBAAY,KAAK,EAAC,SAAS,eAAc,CAAC;AAAA,IAC5C,OACK;AACH,aAAO,QAAQ,MAAO,EACnB,OAAO,CAAC,CAAC,KAAK,MAAM,MAAM;AACzB,eAAO,IAAI,WAAW,aAAa;AAAA,MACrC,CAAC,EACA,QAAQ,CAAC,CAAC,MAAM,KAAK,MAAM;AAC1B,eAAO,YAAY,KAAK,KAAK;AAAA,MAC/B,CAAC;AAEH,UAAI,YAAY;AACd,oBAAY,KAAK,UAAU;AAAA,MAC7B;AAAA,IACF;AAEA,WAAO;AAAA,MAAC;AAAA;AAAA,QAEN,OAAO;AAAA,QACP,WAAW,KAAK,MAAM;AAAA,QACtB,OAAO,mBAAmB,KAAK,MAAM,SAAS;AAAA,QAC9C,QAAQ;AAAA,QACR,UAAU;AAAA,QAEV;AAAA,UAAC;AAAA;AAAA,YACC,MAAM,EAAC,MAAM,MAAK;AAAA,YAClB,MAAM;AAAA,cACJ,SAAS;AAAA,cACT,MAAM,KAAK,MAAM;AAAA,YACnB;AAAA,YACA,WAAU;AAAA,YACV,SAAS,KAAK,MAAM;AAAA,YACpB,QAAQ,KAAK,MAAM;AAAA,YACnB,eAAe,KAAK;AAAA,YACpB,aAAa,KAAK;AAAA,YAClB,OAAO;AAAA,YACP,aAAa;AAAA,YACb,WAAW;AAAA,YACX,cAAc;AAAA,YACd;AAAA,YACA,UAAU,KAAK,MAAM;AAAA;AAAA,QACvB;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"aa37ab38c9a5b53df0808e7895b75ac0976599a1"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Di=function(){return s},s}Di();class m8 extends bn.Component{constructor(t){Di().f[2]++,Di().s[1]++;super(t);nn(this,"onJSONInvalid",(Di().s[3]++,t=>{Di().f[3]++,Di().s[4]++,this.setState({jsonError:!0})}));nn(this,"onJSONValid",(Di().s[5]++,()=>{Di().f[4]++,Di().s[6]++,this.setState({jsonError:!1})}));Di().s[2]++,this.state={jsonError:!1}}render(){Di().f[5]++;const{errors:t,fieldName:r,fieldType:i,value:o,canUndo:s}=(Di().s[7]++,this.props),{jsonError:a}=(Di().s[8]++,this.state),f=(Di().s[9]++,s?(Di().b[0][0]++,!s()):(Di().b[0][1]++,!0)),g=(Di().s[10]++,N.jsxs(N.Fragment,{children:[(Di().b[1][0]++,this.props.onUndo&&(Di().b[1][1]++,N.jsx(Ka,{onClick:this.props.onUndo,disabled:f,className:"maputnik-delete-stop",title:"Revert from expression",children:N.jsx(CJ,{})},"undo_action"))),N.jsx(Ka,{onClick:this.props.onDelete,className:"maputnik-delete-stop",title:"Delete expression",children:N.jsx(Ly,{})},"delete_action")]})),x=(Di().s[11]++,i===void 0?(Di().b[2][0]++,r):(Di().b[2][1]++,`${i}.${r}`)),k=(Di().s[12]++,t[x]),B=(Di().s[13]++,`${x}[`),P=(Di().s[14]++,[]);function R(H){return Di().f[6]++,Di().s[15]++,_W(H,{indent:2,maxLength:38})}return Di().s[16]++,a?(Di().b[3][0]++,Di().s[17]++,P.push({message:"Invalid JSON"})):(Di().b[3][1]++,Di().s[18]++,Object.entries(t).filter(([H,W])=>(Di().f[7]++,Di().s[19]++,H.startsWith(B))).forEach(([H,W])=>(Di().f[8]++,Di().s[20]++,P.push(W))),Di().s[21]++,k?(Di().b[4][0]++,Di().s[22]++,P.push(k)):Di().b[4][1]++),Di().s[23]++,N.jsx(Uo,{error:P,fieldSpec:this.props.fieldSpec,label:D5(this.props.fieldName),action:g,wideMode:!0,children:N.jsx(c8,{mode:{name:"mgl"},lint:{context:"expression",spec:this.props.fieldSpec},className:"maputnik-expression-editor",onFocus:this.props.onFocus,onBlur:this.props.onBlur,onJSONInvalid:this.onJSONInvalid,onJSONValid:this.onJSONValid,layer:o,lineNumbers:!1,maxHeight:200,lineWrapping:!0,getValue:R,onChange:this.props.onChange})})}}nn(m8,"defaultProps",(Di().s[0]++,{errors:{},onFocus:()=>{Di().f[0]++},onBlur:()=>{Di().f[1]++}}));function dn(){var e="/home/runner/work/maputnik/maputnik/src/components/FilterEditor.tsx",n="539ebaafc62ae27a5559677295475532f297ca46",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FilterEditor.tsx",statementMap:{0:{start:{line:16,column:17},end:{line:16,column:40}},1:{start:{line:17,column:2},end:{line:19,column:3}},2:{start:{line:18,column:4},end:{line:18,column:18}},3:{start:{line:20,column:20},end:{line:20,column:29}},4:{start:{line:21,column:16},end:{line:21,column:31}},5:{start:{line:22,column:2},end:{line:25,column:3}},6:{start:{line:23,column:4},end:{line:23,column:24}},7:{start:{line:24,column:4},end:{line:24,column:32}},8:{start:{line:26,column:2},end:{line:26,column:35}},9:{start:{line:29,column:2},end:{line:29,column:65}},10:{start:{line:32,column:2},end:{line:53,column:4}},11:{start:{line:55,column:19},end:{line:59,column:1}},12:{start:{line:61,column:2},end:{line:63,column:3}},13:{start:{line:62,column:4},end:{line:62,column:16}},14:{start:{line:64,column:21},end:{line:64,column:42}},15:{start:{line:65,column:2},end:{line:65,column:38}},16:{start:{line:68,column:2},end:{line:68,column:52}},17:{start:{line:71,column:2},end:{line:73,column:3}},18:{start:{line:72,column:4},end:{line:72,column:97}},19:{start:{line:72,column:38},end:{line:72,column:59}},20:{start:{line:72,column:75},end:{line:72,column:84}},21:{start:{line:74,column:2},end:{line:74,column:15}},22:{start:{line:77,column:24},end:{line:79,column:3}},23:{start:{line:81,column:4},end:{line:81,column:17}},24:{start:{line:82,column:4},end:{line:85,column:6}},25:{start:{line:89,column:22},end:{line:89,column:58}},26:{start:{line:90,column:4},end:{line:90,column:35}},27:{start:{line:91,column:4},end:{line:91,column:35}},28:{start:{line:94,column:22},end:{line:94,column:58}},29:{start:{line:95,column:4},end:{line:95,column:39}},30:{start:{line:96,column:4},end:{line:96,column:35}},31:{start:{line:98,column:18},end:{line:102,column:3}},32:{start:{line:99,column:26},end:{line:99,column:62}},33:{start:{line:100,column:4},end:{line:100,column:43}},34:{start:{line:101,column:4},end:{line:101,column:39}},35:{start:{line:103,column:16},end:{line:107,column:3}},36:{start:{line:104,column:4},end:{line:106,column:7}},37:{start:{line:108,column:15},end:{line:112,column:3}},38:{start:{line:109,column:4},end:{line:111,column:7}},39:{start:{line:113,column:19},end:{line:119,column:3}},40:{start:{line:114,column:19},end:{line:114,column:46}},41:{start:{line:115,column:4},end:{line:115,column:47}},42:{start:{line:116,column:4},end:{line:118,column:7}},43:{start:{line:121,column:32},end:{line:121,column:75}},44:{start:{line:122,column:4},end:{line:135,column:5}},45:{start:{line:123,column:6},end:{line:126,column:8}},46:{start:{line:127,column:11},end:{line:135,column:5}},47:{start:{line:128,column:6},end:{line:130,column:8}},48:{start:{line:132,column:6},end:{line:134,column:8}},49:{start:{line:138,column:23},end:{line:138,column:33}},50:{start:{line:139,column:36},end:{line:139,column:46}},51:{start:{line:140,column:22},end:{line:142,column:5}},52:{start:{line:143,column:26},end:{line:143,column:33}},53:{start:{line:144,column:36},end:{line:144,column:112}},54:{start:{line:145,column:4},end:{line:265,column:5}},55:{start:{line:146,column:6},end:{line:159,column:11}},56:{start:{line:160,column:11},end:{line:265,column:5}},57:{start:{line:161,column:21},end:{line:161,column:48}},58:{start:{line:162,column:26},end:{line:162,column:35}},59:{start:{line:163,column:22},end:{line:163,column:37}},60:{start:{line:164,column:38},end:{line:172,column:10}},61:{start:{line:173,column:27},end:{line:186,column:8}},62:{start:{line:174,column:22},end:{line:174,column:50}},63:{start:{line:175,column:8},end:{line:185,column:29}},64:{start:{line:187,column:6},end:{line:234,column:11}},65:{start:{line:198,column:33},end:{line:198,column:63}},66:{start:{line:236,column:25},end:{line:236,column:35}},67:{start:{line:237,column:6},end:{line:264,column:11}},68:{start:{line:242,column:14},end:{line:242,column:59}},69:{start:{line:243,column:14},end:{line:243,column:49}}},fnMap:{0:{name:"combiningFilter",decl:{start:{line:15,column:9},end:{line:15,column:24}},loc:{start:{line:15,column:32},end:{line:27,column:1}},line:15},1:{name:"migrateFilter",decl:{start:{line:28,column:9},end:{line:28,column:22}},loc:{start:{line:28,column:31},end:{line:30,column:1}},line:28},2:{name:"createStyleFromFilter",decl:{start:{line:31,column:9},end:{line:31,column:30}},loc:{start:{line:31,column:39},end:{line:54,column:1}},line:31},3:{name:"checkIfSimpleFilter",decl:{start:{line:60,column:9},end:{line:60,column:28}},loc:{start:{line:60,column:37},end:{line:66,column:1}},line:60},4:{name:"hasCombiningFilter",decl:{start:{line:67,column:9},end:{line:67,column:27}},loc:{start:{line:67,column:36},end:{line:69,column:1}},line:67},5:{name:"hasNestedCombiningFilter",decl:{start:{line:70,column:9},end:{line:70,column:33}},loc:{start:{line:70,column:42},end:{line:75,column:1}},line:70},6:{name:"(anonymous_6)",decl:{start:{line:72,column:31},end:{line:72,column:32}},loc:{start:{line:72,column:38},end:{line:72,column:59}},line:72},7:{name:"(anonymous_7)",decl:{start:{line:72,column:68},end:{line:72,column:69}},loc:{start:{line:72,column:75},end:{line:72,column:84}},line:72},8:{name:"(anonymous_8)",decl:{start:{line:80,column:2},end:{line:80,column:3}},loc:{start:{line:80,column:21},end:{line:86,column:3}},line:80},9:{name:"(anonymous_9)",decl:{start:{line:88,column:2},end:{line:88,column:3}},loc:{start:{line:88,column:42},end:{line:92,column:3}},line:88},10:{name:"(anonymous_10)",decl:{start:{line:93,column:2},end:{line:93,column:3}},loc:{start:{line:93,column:30},end:{line:97,column:3}},line:93},11:{name:"(anonymous_11)",decl:{start:{line:98,column:18},end:{line:98,column:19}},loc:{start:{line:98,column:24},end:{line:102,column:3}},line:98},12:{name:"(anonymous_12)",decl:{start:{line:103,column:16},end:{line:103,column:17}},loc:{start:{line:103,column:25},end:{line:107,column:3}},line:103},13:{name:"(anonymous_13)",decl:{start:{line:108,column:15},end:{line:108,column:16}},loc:{start:{line:108,column:21},end:{line:112,column:3}},line:108},14:{name:"(anonymous_14)",decl:{start:{line:113,column:19},end:{line:113,column:20}},loc:{start:{line:113,column:25},end:{line:119,column:3}},line:113},15:{name:"(anonymous_15)",decl:{start:{line:120,column:2},end:{line:120,column:3}},loc:{start:{line:120,column:55},end:{line:136,column:3}},line:120},16:{name:"(anonymous_16)",decl:{start:{line:137,column:2},end:{line:137,column:3}},loc:{start:{line:137,column:11},end:{line:266,column:3}},line:137},17:{name:"(anonymous_17)",decl:{start:{line:173,column:39},end:{line:173,column:40}},loc:{start:{line:173,column:51},end:{line:186,column:7}},line:173},18:{name:"(anonymous_18)",decl:{start:{line:198,column:26},end:{line:198,column:27}},loc:{start:{line:198,column:33},end:{line:198,column:63}},line:198},19:{name:"(anonymous_19)",decl:{start:{line:241,column:22},end:{line:241,column:23}},loc:{start:{line:241,column:28},end:{line:244,column:13}},line:241}},branchMap:{0:{loc:{start:{line:16,column:17},end:{line:16,column:40}},type:"binary-expr",locations:[{start:{line:16,column:17},end:{line:16,column:29}},{start:{line:16,column:33},end:{line:16,column:40}}],line:16},1:{loc:{start:{line:17,column:2},end:{line:19,column:3}},type:"if",locations:[{start:{line:17,column:2},end:{line:19,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:17},2:{loc:{start:{line:22,column:2},end:{line:25,column:3}},type:"if",locations:[{start:{line:22,column:2},end:{line:25,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:22},3:{loc:{start:{line:61,column:2},end:{line:63,column:3}},type:"if",locations:[{start:{line:61,column:2},end:{line:63,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:61},4:{loc:{start:{line:61,column:6},end:{line:61,column:59}},type:"binary-expr",locations:[{start:{line:61,column:6},end:{line:61,column:25}},{start:{line:61,column:29},end:{line:61,column:59}}],line:61},5:{loc:{start:{line:71,column:2},end:{line:73,column:3}},type:"if",locations:[{start:{line:71,column:2},end:{line:73,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:71},6:{loc:{start:{line:122,column:4},end:{line:135,column:5}},type:"if",locations:[{start:{line:122,column:4},end:{line:135,column:5}},{start:{line:127,column:11},end:{line:135,column:5}}],line:122},7:{loc:{start:{line:122,column:8},end:{line:122,column:73}},type:"binary-expr",locations:[{start:{line:122,column:8},end:{line:122,column:28}},{start:{line:122,column:32},end:{line:122,column:73}}],line:122},8:{loc:{start:{line:127,column:11},end:{line:135,column:5}},type:"if",locations:[{start:{line:127,column:11},end:{line:135,column:5}},{start:{line:131,column:11},end:{line:135,column:5}}],line:127},9:{loc:{start:{line:127,column:15},end:{line:127,column:80}},type:"binary-expr",locations:[{start:{line:127,column:15},end:{line:127,column:34}},{start:{line:127,column:38},end:{line:127,column:80}}],line:127},10:{loc:{start:{line:144,column:36},end:{line:144,column:112}},type:"binary-expr",locations:[{start:{line:144,column:36},end:{line:144,column:55}},{start:{line:144,column:59},end:{line:144,column:112}}],line:144},11:{loc:{start:{line:145,column:4},end:{line:265,column:5}},type:"if",locations:[{start:{line:145,column:4},end:{line:265,column:5}},{start:{line:160,column:11},end:{line:265,column:5}}],line:145},12:{loc:{start:{line:160,column:11},end:{line:265,column:5}},type:"if",locations:[{start:{line:160,column:11},end:{line:265,column:5}},{start:{line:235,column:11},end:{line:265,column:5}}],line:160},13:{loc:{start:{line:184,column:10},end:{line:184,column:119}},type:"binary-expr",locations:[{start:{line:184,column:10},end:{line:184,column:15}},{start:{line:184,column:35},end:{line:184,column:119}}],line:184},14:{loc:{start:{line:229,column:30},end:{line:229,column:62}},type:"cond-expr",locations:[{start:{line:229,column:51},end:{line:229,column:53}},{start:{line:229,column:56},end:{line:229,column:62}}],line:229},15:{loc:{start:{line:252,column:8},end:{line:263,column:12}},type:"binary-expr",locations:[{start:{line:252,column:8},end:{line:252,column:38}},{start:{line:252,column:58},end:{line:263,column:12}}],line:252}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FilterEditor.tsx"],names:[],mappings:"AA+LQ,SAsDA,UAtDA,KAGA,YAHA;AA/LR,OAAO,WAAW;AAClB,SAAQ,4BAA2B;AACnC,SAAQ,eAAc;AAEtB,SAAQ,QAAQ,SAAS,qBAAoB;AAC7C,SAAQ,0BAAyB;AAEjC,SAAQ,0BAAyB;AACjC,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAClB,OAAO,wBAAwB;AAC/B,OAAO,uBAAuB;AAC9B,OAAO,iBAAiB;AACxB,OAAO,SAAS;AAChB,OAAO,wBAAwB;AAG/B,SAAS,gBAAgB,OAA+E;AACtG,QAAM,SAAS,MAAM,UAAU,CAAC,KAAK;AAErC,MAAI,CAAC,MAAM,QAAQ,MAAM,GAAG;AAC1B,WAAO;AAAA,EACT;AAEA,MAAI,cAAc,OAAO,CAAC;AAC1B,MAAI,UAAU,OAAO,MAAM,CAAC;AAE5B,MAAG,mBAAmB,QAAQ,WAAW,IAAI,GAAG;AAC9C,kBAAc;AACd,cAAU,CAAC,OAAO,MAAM,CAAC,CAAC;AAAA,EAC5B;AAEA,SAAO,CAAC,aAAa,GAAG,OAAO;AACjC;AAEA,SAAS,cAAc,QAA6D;AAElF,SAAQ,QAAQ,sBAAsB,MAAM,CAAQ,EAAE,OAAO,CAAC,EAAU;AAC1E;AAEA,SAAS,sBAAsB,QAAgG;AAC7H,SAAO;AAAA,IACL,MAAM;AAAA,IACN,WAAW;AAAA,IACX,QAAQ;AAAA,IACR,YAAY,EAAC,qBAAqB,SAAQ;AAAA,IAC1C,WAAW;AAAA,MACT,OAAO;AAAA,QACL,QAAQ;AAAA,QACR,QAAQ;AAAA,MACV;AAAA,IACF;AAAA,IACA,UAAU;AAAA,IACV,UAAU;AAAA,IACV,UAAU;AAAA,MACR;AAAA,QACE,IAAI;AAAA,QACJ,MAAM;AAAA,QACN,QAAQ;AAAA,QACR;AAAA,MACF;AAAA,IACF;AAAA,EACF;AACF;AAEA,MAAM,aAAa;AAAA,EACjB;AAAA,EACA;AAAA,EACA;AACF;AAGA,SAAS,oBAAqB,QAA6D;AACzF,MAAI,OAAO,WAAW,KAAK,WAAW,SAAS,OAAO,CAAC,CAAC,GAAG;AACzD,WAAO;AAAA,EACT;AACA,QAAM,aAAa,cAAc,MAAM;AACvC,SAAO,CAAC,QAAQ,YAAY,MAAM;AACpC;AAEA,SAAS,mBAAmB,QAA6D;AACvF,SAAO,mBAAmB,QAAQ,OAAO,CAAC,CAAC,KAAK;AAClD;AAEA,SAAS,yBAAyB,QAA6D;AAC7F,MAAG,mBAAmB,MAAM,GAAG;AAC7B,WAAO,OAAO,MAAM,CAAC,EAAE,IAAI,OAAK,mBAAmB,CAAQ,CAAC,EAAE,OAAO,OAAK,KAAK,IAAI,EAAE,SAAS;AAAA,EAChG;AACA,SAAO;AACT;AAgBA,qBAAqB,qBAAqB,MAAM,UAAgD;AAAA,EAC9F,OAAO,eAAe;AAAA,IACpB,QAAQ,CAAC,KAAK;AAAA,EAChB;AAAA,EAEA,YAAa,OAA0B;AACrC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,SAAS;AAAA,MACT,qBAAqB,oBAAoB,gBAAgB,KAAK,CAAC;AAAA,IACjE;AAAA,EACF;AAAA;AAAA,EAGA,oBAAoB,WAAmB,SAAgB;AACrD,UAAM,YAAY,gBAAgB,KAAK,KAAK,EAAE,MAAM,CAAC;AACrD,cAAU,SAAS,IAAI;AACvB,SAAK,MAAM,SAAS,SAAS;AAAA,EAC/B;AAAA,EAEA,iBAAiB,WAAmB;AAClC,UAAM,YAAY,gBAAgB,KAAK,KAAK,EAAE,MAAM,CAAC;AACrD,cAAU,OAAO,YAAY,GAAG,CAAC;AACjC,SAAK,MAAM,SAAS,SAAS;AAAA,EAC/B;AAAA,EAEA,gBAAgB,MAAM;AACpB,UAAM,gBAAgB,gBAAgB,KAAK,KAAK,EAAE,MAAM,CAAC;AACzD,IAAC,cAAwB,KAAK,CAAC,MAAM,QAAQ,EAAE,CAAC;AAChD,SAAK,MAAM,SAAS,aAAa;AAAA,EACnC;AAAA,EAEA,cAAc,CAAC,QAAiB;AAC9B,SAAK,SAAS;AAAA,MACZ,SAAS;AAAA,IACX,CAAC;AAAA,EACH;AAAA,EAEA,aAAa,MAAM;AACjB,SAAK,SAAS;AAAA,MACZ,qBAAqB;AAAA,IACvB,CAAC;AAAA,EACH;AAAA,EAEA,iBAAiB,MAAM;AACrB,UAAM,SAAS,gBAAgB,KAAK,KAAK;AACzC,SAAK,MAAM,SAAS,cAAc,MAAM,CAAC;AACzC,SAAK,SAAS;AAAA,MACZ,qBAAqB;AAAA,IACvB,CAAC;AAAA,EACH;AAAA,EAEA,OAAO,yBAAyB,OAA0B,cAAiC;AACzF,UAAM,sBAAsB,oBAAoB,gBAAgB,KAAK,CAAC;AAGtE,QAAI,CAAC,uBAAuB,aAAa,wBAAwB,MAAM;AACrE,aAAO;AAAA,QACL,qBAAqB;AAAA,QACrB,qBAAqB;AAAA,MACvB;AAAA,IACF,WACS,uBAAuB,aAAa,wBAAwB,OAAO;AAC1E,aAAO;AAAA,QACL,qBAAqB;AAAA,MACvB;AAAA,IACF,OACK;AACH,aAAO;AAAA,QACL,qBAAqB;AAAA,MACvB;AAAA,IACF;AAAA,EACF;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,OAAM,IAAI,KAAK;AACtB,UAAM,EAAC,oBAAmB,IAAI,KAAK;AACnC,UAAM,YAAU;AAAA,MACd,KAAK,OAAO,MAAM,OAAO,MAAM;AAAA,IACjC;AACA,UAAM,gBAAgB,CAAC,KAAK;AAE5B,UAAM,0BAA0B,uBAAuB,yBAAyB,gBAAgB,KAAK,KAAK,CAAC;AAE3G,QAAI,yBAAyB;AAC3B,aAAO,qBAAC,SAAI,WAAU,sCACpB;AAAA,4BAAC,OAAE,+CAEH;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YACC,SAAS,KAAK;AAAA,YACd,OAAM;AAAA,YAEN;AAAA,kCAAC,SAAI,OAAO,EAAC,aAAa,SAAS,OAAM,QAAQ,QAAO,QAAQ,eAAe,SAAQ,GAAG,SAAQ,aAChG,8BAAC,UAAK,MAAK,gBAAe,GAAG,oBAAoB,GACnD;AAAA,cAAM;AAAA;AAAA;AAAA,QAER;AAAA,SACF;AAAA,IACF,WACS,qBAAqB;AAC5B,YAAM,SAAS,gBAAgB,KAAK,KAAK;AACzC,YAAM,cAAc,OAAO,CAAC;AAC5B,YAAM,UAAU,OAAO,MAAM,CAAC;AAE9B,YAAM,UACJ,oBAAC,SACC;AAAA,QAAC;AAAA;AAAA,UACC,SAAS,KAAK;AAAA,UACd,OAAM;AAAA,UACN,WAAU;AAAA,UAEV,8BAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,SAAQ,GAAG,SAAQ,aAC1E,8BAAC,UAAK,MAAK,gBAAe,GAAG,oBAAoB,GACnD;AAAA;AAAA,MACF,GACF;AAGF,YAAM,eAAe,QAAQ,IAAI,CAAC,GAAG,QAAQ;AAC3C,cAAM,QAAQ,OAAQ,UAAU,MAAI,CAAC,GAAG;AAExC,eACE,qBAAC,SACC;AAAA,8BAAC,qBAA4B,UAAU,KAAK,iBAAiB,KAAK,MAAM,GAAG,GACzE;AAAA,YAAC;AAAA;AAAA,cACC,YAAY,KAAK,MAAM;AAAA,cACvB,QAAQ;AAAA,cACR,UAAU,KAAK,oBAAoB,KAAK,MAAM,MAAM,CAAC;AAAA;AAAA,UACvD,KALsB,GAMxB;AAAA,UACC,SACC,oBAAC,SAAgB,WAAU,yBAAyB,gBAAM,WAAjD,OAAyD;AAAA,aAT5D,SAAS,GAAG,EAWtB;AAAA,MAEJ,CAAC;AAGD,aACE,iCACE;AAAA;AAAA,UAAC;AAAA;AAAA,YAEC;AAAA,YACA,OAAO;AAAA,YACP,QAAQ;AAAA,YAER;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO;AAAA,gBACP,UAAU,CAAC,MAAqB,KAAK,oBAAoB,GAAG,CAAC;AAAA,gBAC7D,SAAS,CAAC,CAAC,OAAO,sBAAsB,GAAG,CAAC,QAAQ,mBAAmB,GAAG,CAAC,OAAO,oBAAoB,CAAC;AAAA;AAAA,YACzG;AAAA;AAAA,UATI;AAAA,QAUN;AAAA,QACC;AAAA,QACD;AAAA,UAAC;AAAA;AAAA,YAEC,WAAU;AAAA,YAEV;AAAA,cAAC;AAAA;AAAA,gBACC,eAAY;AAAA,gBACZ,WAAU;AAAA,gBACV,SAAS,KAAK;AAAA,gBAEd;AAAA,sCAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,cAAa,GAAG,SAAQ,aAC/E,8BAAC,UAAK,MAAK,gBAAe,GAAG,sBAAsB,GACrD;AAAA,kBAAM;AAAA;AAAA;AAAA,YACR;AAAA;AAAA,UAXI;AAAA,QAYN;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YAEC,WAAU;AAAA,YACV,OAAO,EAAC,SAAS,KAAK,MAAM,UAAU,KAAK,OAAM;AAAA,YAEjD,8BAAC,OAAI,WAAsB;AAAA;AAAA,UAJvB;AAAA,QAKN;AAAA,SACF;AAAA,IAEJ,OACK;AACH,YAAM,EAAC,OAAM,IAAI,KAAK;AAEtB,aACE,iCACE;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,UAAU,MAAM;AACd,mBAAK,SAAS,EAAC,qBAAqB,KAAI,CAAC;AACzC,mBAAK,MAAM,SAAS,aAAa;AAAA,YACnC;AAAA,YACA,WAAU;AAAA,YACV;AAAA,YACA,OAAO;AAAA,YACP;AAAA,YACA,UAAU,KAAK,MAAM;AAAA;AAAA,QACvB;AAAA,QACC,KAAK,MAAM,uBACV,qBAAC,SAAI,WAAU,yBAAwB;AAAA;AAAA,UACG;AAAA,UACxC;AAAA,YAAC;AAAA;AAAA,cACC,SAAS,KAAK;AAAA,cACd,WAAU;AAAA,cACX;AAAA;AAAA,UAED;AAAA,WACF;AAAA,SAEJ;AAAA,IAEJ;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"539ebaafc62ae27a5559677295475532f297ca46"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return dn=function(){return s},s}dn();function Vp(e){dn().f[0]++;const n=(dn().s[0]++,dn().b[0][0]++,e.filter||(dn().b[0][1]++,["all"]));if(dn().s[1]++,Array.isArray(n))dn().b[1][1]++;else return dn().b[1][0]++,dn().s[2]++,n;let t=(dn().s[3]++,n[0]),r=(dn().s[4]++,n.slice(1));return dn().s[5]++,h8.indexOf(t)<0?(dn().b[2][0]++,dn().s[6]++,t="all",dn().s[7]++,r=[n.slice(0)]):dn().b[2][1]++,dn().s[8]++,[t,...r]}function zpe(e){return dn().f[1]++,dn().s[9]++,EX(jpe(e)).layers[0].filter}function jpe(e){return dn().f[2]++,dn().s[10]++,{id:"tmp",version:8,name:"Empty Style",metadata:{"maputnik:renderer":"mlgljs"},sources:{tmp:{type:"geojson",data:""}},sprite:"",glyphs:"https://orangemug.github.io/font-glyphs/glyphs/{fontstack}/{range}.pbf",layers:[{id:"tmp",type:"fill",source:"tmp",filter:e}]}}const Wpe=(dn().s[11]++,["all","any","none"]);function JT(e){if(dn().f[3]++,dn().s[12]++,dn().b[4][0]++,e.length===1&&(dn().b[4][1]++,Wpe.includes(e[0])))return dn().b[3][0]++,dn().s[13]++,!0;dn().b[3][1]++;const n=(dn().s[14]++,EC(e));return dn().s[15]++,!Q4.isEqual(n,e)}function eK(e){return dn().f[4]++,dn().s[16]++,h8.indexOf(e[0])>=0}function Npe(e){return dn().f[5]++,dn().s[17]++,eK(e)?(dn().b[5][0]++,dn().s[18]++,e.slice(1).map(n=>(dn().f[6]++,dn().s[19]++,eK(n))).filter(n=>(dn().f[7]++,dn().s[20]++,n==!0)).length>0):(dn().b[5][1]++,dn().s[21]++,!1)}class UW extends bn.Component{constructor(t){dn().f[8]++,dn().s[23]++;super(t);nn(this,"addFilterItem",(dn().s[31]++,()=>{dn().f[11]++;const t=(dn().s[32]++,Vp(this.props).slice(0));dn().s[33]++,t.push(["==","name",""]),dn().s[34]++,this.props.onChange(t)}));nn(this,"onToggleDoc",(dn().s[35]++,t=>{dn().f[12]++,dn().s[36]++,this.setState({showDoc:t})}));nn(this,"makeFilter",(dn().s[37]++,()=>{dn().f[13]++,dn().s[38]++,this.setState({displaySimpleFilter:!0})}));nn(this,"makeExpression",(dn().s[39]++,()=>{dn().f[14]++;const t=(dn().s[40]++,Vp(this.props));dn().s[41]++,this.props.onChange(zpe(t)),dn().s[42]++,this.setState({displaySimpleFilter:!1})}));dn().s[24]++,this.state={showDoc:!1,displaySimpleFilter:JT(Vp(t))}}onFilterPartChanged(t,r){dn().f[9]++;const i=(dn().s[25]++,Vp(this.props).slice(0));dn().s[26]++,i[t]=r,dn().s[27]++,this.props.onChange(i)}deleteFilterItem(t){dn().f[10]++;const r=(dn().s[28]++,Vp(this.props).slice(0));dn().s[29]++,r.splice(t+1,1),dn().s[30]++,this.props.onChange(r)}static getDerivedStateFromProps(t,r){dn().f[15]++;const i=(dn().s[43]++,JT(Vp(t)));return dn().s[44]++,dn().b[7][0]++,!i&&(dn().b[7][1]++,r.displaySimpleFilter===!0)?(dn().b[6][0]++,dn().s[45]++,{displaySimpleFilter:!1,valueIsSimpleFilter:!1}):(dn().b[6][1]++,dn().s[46]++,dn().b[9][0]++,i&&(dn().b[9][1]++,r.displaySimpleFilter===!1)?(dn().b[8][0]++,dn().s[47]++,{valueIsSimpleFilter:!0}):(dn().b[8][1]++,dn().s[48]++,{valueIsSimpleFilter:!1}))}render(){dn().f[16]++;const{errors:t}=(dn().s[49]++,this.props),{displaySimpleFilter:r}=(dn().s[50]++,this.state),i=(dn().s[51]++,{doc:ma.layer.filter.doc+" Combine multiple filters together by using a compound filter."}),o=(dn().s[52]++,["all"]),s=(dn().s[53]++,dn().b[10][0]++,r&&(dn().b[10][1]++,Npe(Vp(this.props))));if(dn().s[54]++,s)return dn().b[11][0]++,dn().s[55]++,N.jsxs("div",{className:"maputnik-filter-editor-unsupported",children:[N.jsx("p",{children:"Nested filters are not supported."}),N.jsxs(Ka,{onClick:this.makeExpression,title:"Convert to expression",children:[N.jsx("svg",{style:{marginRight:"0.2em",width:"14px",height:"14px",verticalAlign:"middle"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:S_})}),"Upgrade to expression"]})]});if(dn().b[11][1]++,dn().s[56]++,r){dn().b[12][0]++;const a=(dn().s[57]++,Vp(this.props)),f=(dn().s[58]++,a[0]),g=(dn().s[59]++,a.slice(1)),x=(dn().s[60]++,N.jsx("div",{children:N.jsx(Ka,{onClick:this.makeExpression,title:"Convert to expression",className:"maputnik-make-zoom-function",children:N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"middle"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:S_})})})})),k=(dn().s[61]++,g.map((B,P)=>{dn().f[17]++;const R=(dn().s[62]++,t[`filter[${P+1}]`]);return dn().s[63]++,N.jsxs("div",{children:[N.jsx(hpe,{onDelete:this.deleteFilterItem.bind(this,P),children:N.jsx(MW,{properties:this.props.properties,filter:B,onChange:this.onFilterPartChanged.bind(this,P+1)})},P),(dn().b[13][0]++,R&&(dn().b[13][1]++,N.jsx("div",{className:"maputnik-inline-error",children:R.message},"error")))]},`block-${P}`)}));return dn().s[64]++,N.jsxs(N.Fragment,{children:[N.jsx(Uo,{fieldSpec:i,label:"Filter",action:x,children:N.jsx(w1,{value:f,onChange:B=>(dn().f[18]++,dn().s[65]++,this.onFilterPartChanged(0,B)),options:[["all","every filter matches"],["none","no filter matches"],["any","any filter matches"]]})},"top"),k,N.jsx("div",{className:"maputnik-filter-editor-add-wrapper",children:N.jsxs(Ka,{"data-wd-key":"layer-filter-button",className:"maputnik-add-filter",onClick:this.addFilterItem,children:[N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:d8})})," Add filter"]})},"buttons"),N.jsx("div",{className:"maputnik-doc-inline",style:{display:this.state.showDoc?(dn().b[14][0]++,""):(dn().b[14][1]++,"none")},children:N.jsx(FB,{fieldSpec:i})},"doc")]})}else{dn().b[12][1]++;const{filter:a}=(dn().s[66]++,this.props);return dn().s[67]++,N.jsxs(N.Fragment,{children:[N.jsx(m8,{onDelete:()=>{dn().f[19]++,dn().s[68]++,this.setState({displaySimpleFilter:!0}),dn().s[69]++,this.props.onChange(o)},fieldName:"filter",fieldSpec:i,value:a,errors:t,onChange:this.props.onChange}),(dn().b[15][0]++,this.state.valueIsSimpleFilter&&(dn().b[15][1]++,N.jsxs("div",{className:"maputnik-expr-infobox",children:["You've entered a old style filter,"," ",N.jsx("button",{onClick:this.makeFilter,className:"maputnik-expr-infobox__button",children:"switch to filter editor"})]})))]})}}}nn(UW,"defaultProps",(dn().s[22]++,{filter:["all"]}));var U5={},Ps={},rb={},Gpe=typeof window=="object"&&window&&window.Object===Object&&window,RW=Gpe,Qpe=RW,$pe=typeof self=="object"&&self&&self.Object===Object&&self,Ype=Qpe||$pe||Function("return this")(),gh=Ype,qpe=gh,Vpe=qpe.Symbol,ib=Vpe,tK=ib,LW=Object.prototype,Hpe=LW.hasOwnProperty,Zpe=LW.toString,Xv=tK?tK.toStringTag:void 0;function Xpe(e){var n=Hpe.call(e,Xv),t=e[Xv];try{e[Xv]=void 0;var r=!0}catch{}var i=Zpe.call(e);return r&&(n?e[Xv]=t:delete e[Xv]),i}var Jpe=Xpe,eme=Object.prototype,tme=eme.toString;function nme(e){return tme.call(e)}var rme=nme,nK=ib,ime=Jpe,ome=rme,ame="[object Null]",sme="[object Undefined]",rK=nK?nK.toStringTag:void 0;function lme(e){return e==null?e===void 0?sme:ame:rK&&rK in Object(e)?ime(e):ome(e)}var M1=lme,ume=Array.isArray,Nc=ume;function Ame(e){return e!=null&&typeof e=="object"}var bf=Ame,cme=M1,dme=Nc,hme=bf,fme="[object String]";function pme(e){return typeof e=="string"||!dme(e)&&hme(e)&&cme(e)==fme}var mme=pme;function gme(e){return function(n,t,r){for(var i=-1,o=Object(n),s=r(n),a=s.length;a--;){var f=s[e?a:++i];if(t(o[f],f,o)===!1)break}return n}}var yme=gme,vme=yme,Cme=vme(),zW=Cme;function _me(e,n){for(var t=-1,r=Array(e);++t<e;)r[t]=n(t);return r}var bme=_me,xme=M1,wme=bf,Mme="[object Arguments]";function Sme(e){return wme(e)&&xme(e)==Mme}var Eme=Sme,iK=Eme,Ome=bf,jW=Object.prototype,Bme=jW.hasOwnProperty,kme=jW.propertyIsEnumerable,Ime=iK(function(){return arguments}())?iK:function(e){return Ome(e)&&Bme.call(e,"callee")&&!kme.call(e,"callee")},g8=Ime,r4={exports:{}};function Tme(){return!1}var Kme=Tme;r4.exports;(function(e,n){var t=gh,r=Kme,i=n&&!n.nodeType&&n,o=i&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s?t.Buffer:void 0,f=a?a.isBuffer:void 0,g=f||r;e.exports=g})(r4,r4.exports);var R5=r4.exports,Pme=9007199254740991,Fme=/^(?:0|[1-9]\d*)$/;function Dme(e,n){var t=typeof e;return n=n??Pme,!!n&&(t=="number"||t!="symbol"&&Fme.test(e))&&e>-1&&e%1==0&&e<n}var y8=Dme,Ume=9007199254740991;function Rme(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Ume}var v8=Rme,Lme=M1,zme=v8,jme=bf,Wme="[object Arguments]",Nme="[object Array]",Gme="[object Boolean]",Qme="[object Date]",$me="[object Error]",Yme="[object Function]",qme="[object Map]",Vme="[object Number]",Hme="[object Object]",Zme="[object RegExp]",Xme="[object Set]",Jme="[object String]",e0e="[object WeakMap]",t0e="[object ArrayBuffer]",n0e="[object DataView]",r0e="[object Float32Array]",i0e="[object Float64Array]",o0e="[object Int8Array]",a0e="[object Int16Array]",s0e="[object Int32Array]",l0e="[object Uint8Array]",u0e="[object Uint8ClampedArray]",A0e="[object Uint16Array]",c0e="[object Uint32Array]",rs={};rs[r0e]=rs[i0e]=rs[o0e]=rs[a0e]=rs[s0e]=rs[l0e]=rs[u0e]=rs[A0e]=rs[c0e]=!0;rs[Wme]=rs[Nme]=rs[t0e]=rs[Gme]=rs[n0e]=rs[Qme]=rs[$me]=rs[Yme]=rs[qme]=rs[Vme]=rs[Hme]=rs[Zme]=rs[Xme]=rs[Jme]=rs[e0e]=!1;function d0e(e){return jme(e)&&zme(e.length)&&!!rs[Lme(e)]}var h0e=d0e;function f0e(e){return function(n){return e(n)}}var C8=f0e,i4={exports:{}};i4.exports;(function(e,n){var t=RW,r=n&&!n.nodeType&&n,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,s=o&&t.process,a=function(){try{var f=i&&i.require&&i.require("util").types;return f||s&&s.binding&&s.binding("util")}catch{}}();e.exports=a})(i4,i4.exports);var _8=i4.exports,p0e=h0e,m0e=C8,oK=_8,aK=oK&&oK.isTypedArray,g0e=aK?m0e(aK):p0e,b8=g0e,y0e=bme,v0e=g8,C0e=Nc,_0e=R5,b0e=y8,x0e=b8,w0e=Object.prototype,M0e=w0e.hasOwnProperty;function S0e(e,n){var t=C0e(e),r=!t&&v0e(e),i=!t&&!r&&_0e(e),o=!t&&!r&&!i&&x0e(e),s=t||r||i||o,a=s?y0e(e.length,String):[],f=a.length;for(var g in e)(n||M0e.call(e,g))&&!(s&&(g=="length"||i&&(g=="offset"||g=="parent")||o&&(g=="buffer"||g=="byteLength"||g=="byteOffset")||b0e(g,f)))&&a.push(g);return a}var WW=S0e,E0e=Object.prototype;function O0e(e){var n=e&&e.constructor,t=typeof n=="function"&&n.prototype||E0e;return e===t}var x8=O0e;function B0e(e,n){return function(t){return e(n(t))}}var NW=B0e,k0e=NW,I0e=k0e(Object.keys,Object),T0e=I0e,K0e=x8,P0e=T0e,F0e=Object.prototype,D0e=F0e.hasOwnProperty;function U0e(e){if(!K0e(e))return P0e(e);var n=[];for(var t in Object(e))D0e.call(e,t)&&t!="constructor"&&n.push(t);return n}var R0e=U0e;function L0e(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}var kd=L0e,z0e=M1,j0e=kd,W0e="[object AsyncFunction]",N0e="[object Function]",G0e="[object GeneratorFunction]",Q0e="[object Proxy]";function $0e(e){if(!j0e(e))return!1;var n=z0e(e);return n==N0e||n==G0e||n==W0e||n==Q0e}var w8=$0e,Y0e=w8,q0e=v8;function V0e(e){return e!=null&&q0e(e.length)&&!Y0e(e)}var $y=V0e,H0e=WW,Z0e=R0e,X0e=$y;function J0e(e){return X0e(e)?H0e(e):Z0e(e)}var ob=J0e,e1e=zW,t1e=ob;function n1e(e,n){return e&&e1e(e,n,t1e)}var GW=n1e;function r1e(e){return e}var L5=r1e,i1e=L5;function o1e(e){return typeof e=="function"?e:i1e}var QW=o1e,a1e=GW,s1e=QW;function l1e(e,n){return e&&a1e(e,s1e(n))}var M8=l1e,u1e=NW,A1e=u1e(Object.getPrototypeOf,Object),S8=A1e,c1e=M1,d1e=S8,h1e=bf,f1e="[object Object]",p1e=Function.prototype,m1e=Object.prototype,$W=p1e.toString,g1e=m1e.hasOwnProperty,y1e=$W.call(Object);function v1e(e){if(!h1e(e)||c1e(e)!=f1e)return!1;var n=d1e(e);if(n===null)return!0;var t=g1e.call(n,"constructor")&&n.constructor;return typeof t=="function"&&t instanceof t&&$W.call(t)==y1e}var YW=v1e;function C1e(e,n){for(var t=-1,r=e==null?0:e.length,i=Array(r);++t<r;)i[t]=n(e[t],t,e);return i}var qW=C1e;function _1e(){this.__data__=[],this.size=0}var b1e=_1e;function x1e(e,n){return e===n||e!==e&&n!==n}var ab=x1e,w1e=ab;function M1e(e,n){for(var t=e.length;t--;)if(w1e(e[t][0],n))return t;return-1}var z5=M1e,S1e=z5,E1e=Array.prototype,O1e=E1e.splice;function B1e(e){var n=this.__data__,t=S1e(n,e);if(t<0)return!1;var r=n.length-1;return t==r?n.pop():O1e.call(n,t,1),--this.size,!0}var k1e=B1e,I1e=z5;function T1e(e){var n=this.__data__,t=I1e(n,e);return t<0?void 0:n[t][1]}var K1e=T1e,P1e=z5;function F1e(e){return P1e(this.__data__,e)>-1}var D1e=F1e,U1e=z5;function R1e(e,n){var t=this.__data__,r=U1e(t,e);return r<0?(++this.size,t.push([e,n])):t[r][1]=n,this}var L1e=R1e,z1e=b1e,j1e=k1e,W1e=K1e,N1e=D1e,G1e=L1e;function Yy(e){var n=-1,t=e==null?0:e.length;for(this.clear();++n<t;){var r=e[n];this.set(r[0],r[1])}}Yy.prototype.clear=z1e;Yy.prototype.delete=j1e;Yy.prototype.get=W1e;Yy.prototype.has=N1e;Yy.prototype.set=G1e;var j5=Yy,Q1e=j5;function $1e(){this.__data__=new Q1e,this.size=0}var Y1e=$1e;function q1e(e){var n=this.__data__,t=n.delete(e);return this.size=n.size,t}var V1e=q1e;function H1e(e){return this.__data__.get(e)}var Z1e=H1e;function X1e(e){return this.__data__.has(e)}var J1e=X1e,ege=gh,tge=ege["__core-js_shared__"],nge=tge,qM=nge,sK=function(){var e=/[^.]+$/.exec(qM&&qM.keys&&qM.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function rge(e){return!!sK&&sK in e}var ige=rge,oge=Function.prototype,age=oge.toString;function sge(e){if(e!=null){try{return age.call(e)}catch{}try{return e+""}catch{}}return""}var VW=sge,lge=w8,uge=ige,Age=kd,cge=VW,dge=/[\\^$.*+?()[\]{}|]/g,hge=/^\[object .+?Constructor\]$/,fge=Function.prototype,pge=Object.prototype,mge=fge.toString,gge=pge.hasOwnProperty,yge=RegExp("^"+mge.call(gge).replace(dge,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function vge(e){if(!Age(e)||uge(e))return!1;var n=lge(e)?yge:hge;return n.test(cge(e))}var Cge=vge;function _ge(e,n){return e==null?void 0:e[n]}var bge=_ge,xge=Cge,wge=bge;function Mge(e,n){var t=wge(e,n);return xge(t)?t:void 0}var S1=Mge,Sge=S1,Ege=gh,Oge=Sge(Ege,"Map"),E8=Oge,Bge=S1,kge=Bge(Object,"create"),W5=kge,lK=W5;function Ige(){this.__data__=lK?lK(null):{},this.size=0}var Tge=Ige;function Kge(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}var Pge=Kge,Fge=W5,Dge="__lodash_hash_undefined__",Uge=Object.prototype,Rge=Uge.hasOwnProperty;function Lge(e){var n=this.__data__;if(Fge){var t=n[e];return t===Dge?void 0:t}return Rge.call(n,e)?n[e]:void 0}var zge=Lge,jge=W5,Wge=Object.prototype,Nge=Wge.hasOwnProperty;function Gge(e){var n=this.__data__;return jge?n[e]!==void 0:Nge.call(n,e)}var Qge=Gge,$ge=W5,Yge="__lodash_hash_undefined__";function qge(e,n){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=$ge&&n===void 0?Yge:n,this}var Vge=qge,Hge=Tge,Zge=Pge,Xge=zge,Jge=Qge,eye=Vge;function qy(e){var n=-1,t=e==null?0:e.length;for(this.clear();++n<t;){var r=e[n];this.set(r[0],r[1])}}qy.prototype.clear=Hge;qy.prototype.delete=Zge;qy.prototype.get=Xge;qy.prototype.has=Jge;qy.prototype.set=eye;var tye=qy,uK=tye,nye=j5,rye=E8;function iye(){this.size=0,this.__data__={hash:new uK,map:new(rye||nye),string:new uK}}var oye=iye;function aye(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}var sye=aye,lye=sye;function uye(e,n){var t=e.__data__;return lye(n)?t[typeof n=="string"?"string":"hash"]:t.map}var N5=uye,Aye=N5;function cye(e){var n=Aye(this,e).delete(e);return this.size-=n?1:0,n}var dye=cye,hye=N5;function fye(e){return hye(this,e).get(e)}var pye=fye,mye=N5;function gye(e){return mye(this,e).has(e)}var yye=gye,vye=N5;function Cye(e,n){var t=vye(this,e),r=t.size;return t.set(e,n),this.size+=t.size==r?0:1,this}var _ye=Cye,bye=oye,xye=dye,wye=pye,Mye=yye,Sye=_ye;function Vy(e){var n=-1,t=e==null?0:e.length;for(this.clear();++n<t;){var r=e[n];this.set(r[0],r[1])}}Vy.prototype.clear=bye;Vy.prototype.delete=xye;Vy.prototype.get=wye;Vy.prototype.has=Mye;Vy.prototype.set=Sye;var O8=Vy,Eye=j5,Oye=E8,Bye=O8,kye=200;function Iye(e,n){var t=this.__data__;if(t instanceof Eye){var r=t.__data__;if(!Oye||r.length<kye-1)return r.push([e,n]),this.size=++t.size,this;t=this.__data__=new Bye(r)}return t.set(e,n),this.size=t.size,this}var Tye=Iye,Kye=j5,Pye=Y1e,Fye=V1e,Dye=Z1e,Uye=J1e,Rye=Tye;function Hy(e){var n=this.__data__=new Kye(e);this.size=n.size}Hy.prototype.clear=Pye;Hy.prototype.delete=Fye;Hy.prototype.get=Dye;Hy.prototype.has=Uye;Hy.prototype.set=Rye;var G5=Hy,Lye="__lodash_hash_undefined__";function zye(e){return this.__data__.set(e,Lye),this}var jye=zye;function Wye(e){return this.__data__.has(e)}var Nye=Wye,Gye=O8,Qye=jye,$ye=Nye;function o4(e){var n=-1,t=e==null?0:e.length;for(this.__data__=new Gye;++n<t;)this.add(e[n])}o4.prototype.add=o4.prototype.push=Qye;o4.prototype.has=$ye;var Yye=o4;function qye(e,n){for(var t=-1,r=e==null?0:e.length;++t<r;)if(n(e[t],t,e))return!0;return!1}var Vye=qye;function Hye(e,n){return e.has(n)}var Zye=Hye,Xye=Yye,Jye=Vye,eve=Zye,tve=1,nve=2;function rve(e,n,t,r,i,o){var s=t&tve,a=e.length,f=n.length;if(a!=f&&!(s&&f>a))return!1;var g=o.get(e),x=o.get(n);if(g&&x)return g==n&&x==e;var k=-1,B=!0,P=t&nve?new Xye:void 0;for(o.set(e,n),o.set(n,e);++k<a;){var R=e[k],H=n[k];if(r)var W=s?r(H,R,k,n,e,o):r(R,H,k,e,n,o);if(W!==void 0){if(W)continue;B=!1;break}if(P){if(!Jye(n,function($,q){if(!eve(P,q)&&(R===$||i(R,$,t,r,o)))return P.push(q)})){B=!1;break}}else if(!(R===H||i(R,H,t,r,o))){B=!1;break}}return o.delete(e),o.delete(n),B}var HW=rve,ive=gh,ove=ive.Uint8Array,ZW=ove;function ave(e){var n=-1,t=Array(e.size);return e.forEach(function(r,i){t[++n]=[i,r]}),t}var sve=ave;function lve(e){var n=-1,t=Array(e.size);return e.forEach(function(r){t[++n]=r}),t}var uve=lve,AK=ib,cK=ZW,Ave=ab,cve=HW,dve=sve,hve=uve,fve=1,pve=2,mve="[object Boolean]",gve="[object Date]",yve="[object Error]",vve="[object Map]",Cve="[object Number]",_ve="[object RegExp]",bve="[object Set]",xve="[object String]",wve="[object Symbol]",Mve="[object ArrayBuffer]",Sve="[object DataView]",dK=AK?AK.prototype:void 0,VM=dK?dK.valueOf:void 0;function Eve(e,n,t,r,i,o,s){switch(t){case Sve:if(e.byteLength!=n.byteLength||e.byteOffset!=n.byteOffset)return!1;e=e.buffer,n=n.buffer;case Mve:return!(e.byteLength!=n.byteLength||!o(new cK(e),new cK(n)));case mve:case gve:case Cve:return Ave(+e,+n);case yve:return e.name==n.name&&e.message==n.message;case _ve:case xve:return e==n+"";case vve:var a=dve;case bve:var f=r&fve;if(a||(a=hve),e.size!=n.size&&!f)return!1;var g=s.get(e);if(g)return g==n;r|=pve,s.set(e,n);var x=cve(a(e),a(n),r,i,o,s);return s.delete(e),x;case wve:if(VM)return VM.call(e)==VM.call(n)}return!1}var Ove=Eve;function Bve(e,n){for(var t=-1,r=n.length,i=e.length;++t<r;)e[i+t]=n[t];return e}var XW=Bve,kve=XW,Ive=Nc;function Tve(e,n,t){var r=n(e);return Ive(e)?r:kve(r,t(e))}var JW=Tve;function Kve(e,n){for(var t=-1,r=e==null?0:e.length,i=0,o=[];++t<r;){var s=e[t];n(s,t,e)&&(o[i++]=s)}return o}var Pve=Kve;function Fve(){return[]}var eN=Fve,Dve=Pve,Uve=eN,Rve=Object.prototype,Lve=Rve.propertyIsEnumerable,hK=Object.getOwnPropertySymbols,zve=hK?function(e){return e==null?[]:(e=Object(e),Dve(hK(e),function(n){return Lve.call(e,n)}))}:Uve,B8=zve,jve=JW,Wve=B8,Nve=ob;function Gve(e){return jve(e,Nve,Wve)}var tN=Gve,fK=tN,Qve=1,$ve=Object.prototype,Yve=$ve.hasOwnProperty;function qve(e,n,t,r,i,o){var s=t&Qve,a=fK(e),f=a.length,g=fK(n),x=g.length;if(f!=x&&!s)return!1;for(var k=f;k--;){var B=a[k];if(!(s?B in n:Yve.call(n,B)))return!1}var P=o.get(e),R=o.get(n);if(P&&R)return P==n&&R==e;var H=!0;o.set(e,n),o.set(n,e);for(var W=s;++k<f;){B=a[k];var $=e[B],q=n[B];if(r)var oe=s?r(q,$,B,n,e,o):r($,q,B,e,n,o);if(!(oe===void 0?$===q||i($,q,t,r,o):oe)){H=!1;break}W||(W=B=="constructor")}if(H&&!W){var ne=e.constructor,ce=n.constructor;ne!=ce&&"constructor"in e&&"constructor"in n&&!(typeof ne=="function"&&ne instanceof ne&&typeof ce=="function"&&ce instanceof ce)&&(H=!1)}return o.delete(e),o.delete(n),H}var Vve=qve,Hve=S1,Zve=gh,Xve=Hve(Zve,"DataView"),Jve=Xve,eCe=S1,tCe=gh,nCe=eCe(tCe,"Promise"),rCe=nCe,iCe=S1,oCe=gh,aCe=iCe(oCe,"Set"),sCe=aCe,lCe=S1,uCe=gh,ACe=lCe(uCe,"WeakMap"),cCe=ACe,QE=Jve,$E=E8,YE=rCe,qE=sCe,VE=cCe,nN=M1,Zy=VW,pK="[object Map]",dCe="[object Object]",mK="[object Promise]",gK="[object Set]",yK="[object WeakMap]",vK="[object DataView]",hCe=Zy(QE),fCe=Zy($E),pCe=Zy(YE),mCe=Zy(qE),gCe=Zy(VE),O0=nN;(QE&&O0(new QE(new ArrayBuffer(1)))!=vK||$E&&O0(new $E)!=pK||YE&&O0(YE.resolve())!=mK||qE&&O0(new qE)!=gK||VE&&O0(new VE)!=yK)&&(O0=function(e){var n=nN(e),t=n==dCe?e.constructor:void 0,r=t?Zy(t):"";if(r)switch(r){case hCe:return vK;case fCe:return pK;case pCe:return mK;case mCe:return gK;case gCe:return yK}return n});var Q5=O0,HM=G5,yCe=HW,vCe=Ove,CCe=Vve,CK=Q5,_K=Nc,bK=R5,_Ce=b8,bCe=1,xK="[object Arguments]",wK="[object Array]",Qx="[object Object]",xCe=Object.prototype,MK=xCe.hasOwnProperty;function wCe(e,n,t,r,i,o){var s=_K(e),a=_K(n),f=s?wK:CK(e),g=a?wK:CK(n);f=f==xK?Qx:f,g=g==xK?Qx:g;var x=f==Qx,k=g==Qx,B=f==g;if(B&&bK(e)){if(!bK(n))return!1;s=!0,x=!1}if(B&&!x)return o||(o=new HM),s||_Ce(e)?yCe(e,n,t,r,i,o):vCe(e,n,f,t,r,i,o);if(!(t&bCe)){var P=x&&MK.call(e,"__wrapped__"),R=k&&MK.call(n,"__wrapped__");if(P||R){var H=P?e.value():e,W=R?n.value():n;return o||(o=new HM),i(H,W,t,r,o)}}return B?(o||(o=new HM),CCe(e,n,t,r,i,o)):!1}var MCe=wCe,SCe=MCe,SK=bf;function rN(e,n,t,r,i){return e===n?!0:e==null||n==null||!SK(e)&&!SK(n)?e!==e&&n!==n:SCe(e,n,t,r,rN,i)}var iN=rN,ECe=G5,OCe=iN,BCe=1,kCe=2;function ICe(e,n,t,r){var i=t.length,o=i,s=!r;if(e==null)return!o;for(e=Object(e);i--;){var a=t[i];if(s&&a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++i<o;){a=t[i];var f=a[0],g=e[f],x=a[1];if(s&&a[2]){if(g===void 0&&!(f in e))return!1}else{var k=new ECe;if(r)var B=r(g,x,f,e,n,k);if(!(B===void 0?OCe(x,g,BCe|kCe,r,k):B))return!1}}return!0}var TCe=ICe,KCe=kd;function PCe(e){return e===e&&!KCe(e)}var oN=PCe,FCe=oN,DCe=ob;function UCe(e){for(var n=DCe(e),t=n.length;t--;){var r=n[t],i=e[r];n[t]=[r,i,FCe(i)]}return n}var RCe=UCe;function LCe(e,n){return function(t){return t==null?!1:t[e]===n&&(n!==void 0||e in Object(t))}}var aN=LCe,zCe=TCe,jCe=RCe,WCe=aN;function NCe(e){var n=jCe(e);return n.length==1&&n[0][2]?WCe(n[0][0],n[0][1]):function(t){return t===e||zCe(t,e,n)}}var GCe=NCe,QCe=M1,$Ce=bf,YCe="[object Symbol]";function qCe(e){return typeof e=="symbol"||$Ce(e)&&QCe(e)==YCe}var $5=qCe,VCe=Nc,HCe=$5,ZCe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,XCe=/^\w*$/;function JCe(e,n){if(VCe(e))return!1;var t=typeof e;return t=="number"||t=="symbol"||t=="boolean"||e==null||HCe(e)?!0:XCe.test(e)||!ZCe.test(e)||n!=null&&e in Object(n)}var k8=JCe,sN=O8,e_e="Expected a function";function I8(e,n){if(typeof e!="function"||n!=null&&typeof n!="function")throw new TypeError(e_e);var t=function(){var r=arguments,i=n?n.apply(this,r):r[0],o=t.cache;if(o.has(i))return o.get(i);var s=e.apply(this,r);return t.cache=o.set(i,s)||o,s};return t.cache=new(I8.Cache||sN),t}I8.Cache=sN;var t_e=I8,n_e=t_e,r_e=500;function i_e(e){var n=n_e(e,function(r){return t.size===r_e&&t.clear(),r}),t=n.cache;return n}var o_e=i_e,a_e=o_e,s_e=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,l_e=/\\(\\)?/g,u_e=a_e(function(e){var n=[];return e.charCodeAt(0)===46&&n.push(""),e.replace(s_e,function(t,r,i,o){n.push(i?o.replace(l_e,"$1"):r||t)}),n}),A_e=u_e,EK=ib,c_e=qW,d_e=Nc,h_e=$5,f_e=1/0,OK=EK?EK.prototype:void 0,BK=OK?OK.toString:void 0;function lN(e){if(typeof e=="string")return e;if(d_e(e))return c_e(e,lN)+"";if(h_e(e))return BK?BK.call(e):"";var n=e+"";return n=="0"&&1/e==-f_e?"-0":n}var p_e=lN,m_e=p_e;function g_e(e){return e==null?"":m_e(e)}var y_e=g_e,v_e=Nc,C_e=k8,__e=A_e,b_e=y_e;function x_e(e,n){return v_e(e)?e:C_e(e,n)?[e]:__e(b_e(e))}var uN=x_e,w_e=$5,M_e=1/0;function S_e(e){if(typeof e=="string"||w_e(e))return e;var n=e+"";return n=="0"&&1/e==-M_e?"-0":n}var Y5=S_e,E_e=uN,O_e=Y5;function B_e(e,n){n=E_e(n,e);for(var t=0,r=n.length;e!=null&&t<r;)e=e[O_e(n[t++])];return t&&t==r?e:void 0}var AN=B_e,k_e=AN;function I_e(e,n,t){var r=e==null?void 0:k_e(e,n);return r===void 0?t:r}var T_e=I_e;function K_e(e,n){return e!=null&&n in Object(e)}var P_e=K_e,F_e=uN,D_e=g8,U_e=Nc,R_e=y8,L_e=v8,z_e=Y5;function j_e(e,n,t){n=F_e(n,e);for(var r=-1,i=n.length,o=!1;++r<i;){var s=z_e(n[r]);if(!(o=e!=null&&t(e,s)))break;e=e[s]}return o||++r!=i?o:(i=e==null?0:e.length,!!i&&L_e(i)&&R_e(s,i)&&(U_e(e)||D_e(e)))}var W_e=j_e,N_e=P_e,G_e=W_e;function Q_e(e,n){return e!=null&&G_e(e,n,N_e)}var $_e=Q_e,Y_e=iN,q_e=T_e,V_e=$_e,H_e=k8,Z_e=oN,X_e=aN,J_e=Y5,ebe=1,tbe=2;function nbe(e,n){return H_e(e)&&Z_e(n)?X_e(J_e(e),n):function(t){var r=q_e(t,e);return r===void 0&&r===n?V_e(t,e):Y_e(n,r,ebe|tbe)}}var rbe=nbe;function ibe(e){return function(n){return n==null?void 0:n[e]}}var obe=ibe,abe=AN;function sbe(e){return function(n){return abe(n,e)}}var lbe=sbe,ube=obe,Abe=lbe,cbe=k8,dbe=Y5;function hbe(e){return cbe(e)?ube(dbe(e)):Abe(e)}var fbe=hbe,pbe=GCe,mbe=rbe,gbe=L5,ybe=Nc,vbe=fbe;function Cbe(e){return typeof e=="function"?e:e==null?gbe:typeof e=="object"?ybe(e)?mbe(e[0],e[1]):pbe(e):vbe(e)}var _be=Cbe,bbe=$y;function xbe(e,n){return function(t,r){if(t==null)return t;if(!bbe(t))return e(t,r);for(var i=t.length,o=n?i:-1,s=Object(t);(n?o--:++o<i)&&r(s[o],o,s)!==!1;);return t}}var wbe=xbe,Mbe=GW,Sbe=wbe,Ebe=Sbe(Mbe),cN=Ebe,Obe=cN,Bbe=$y;function kbe(e,n){var t=-1,r=Bbe(e)?Array(e.length):[];return Obe(e,function(i,o,s){r[++t]=n(i,o,s)}),r}var Ibe=kbe,Tbe=qW,Kbe=_be,Pbe=Ibe,Fbe=Nc;function Dbe(e,n){var t=Fbe(e)?Tbe:Pbe;return t(e,Kbe(n))}var Ube=Dbe;Object.defineProperty(rb,"__esModule",{value:!0});rb.flattenNames=void 0;var Rbe=mme,Lbe=q5(Rbe),zbe=M8,jbe=q5(zbe),Wbe=YW,Nbe=q5(Wbe),Gbe=Ube,Qbe=q5(Gbe);function q5(e){return e&&e.__esModule?e:{default:e}}var $be=rb.flattenNames=function e(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=[];return(0,Qbe.default)(n,function(r){Array.isArray(r)?e(r).map(function(i){return t.push(i)}):(0,Nbe.default)(r)?(0,jbe.default)(r,function(i,o){i===!0&&t.push(o),t.push(o+"-"+i)}):(0,Lbe.default)(r)&&t.push(r)}),t};rb.default=$be;var sb={};function Ybe(e,n){for(var t=-1,r=e==null?0:e.length;++t<r&&n(e[t],t,e)!==!1;);return e}var dN=Ybe,qbe=S1,Vbe=function(){try{var e=qbe(Object,"defineProperty");return e({},"",{}),e}catch{}}(),hN=Vbe,kK=hN;function Hbe(e,n,t){n=="__proto__"&&kK?kK(e,n,{configurable:!0,enumerable:!0,value:t,writable:!0}):e[n]=t}var T8=Hbe,Zbe=T8,Xbe=ab,Jbe=Object.prototype,exe=Jbe.hasOwnProperty;function txe(e,n,t){var r=e[n];(!(exe.call(e,n)&&Xbe(r,t))||t===void 0&&!(n in e))&&Zbe(e,n,t)}var fN=txe,nxe=fN,rxe=T8;function ixe(e,n,t,r){var i=!t;t||(t={});for(var o=-1,s=n.length;++o<s;){var a=n[o],f=r?r(t[a],e[a],a,t,e):void 0;f===void 0&&(f=e[a]),i?rxe(t,a,f):nxe(t,a,f)}return t}var lb=ixe,oxe=lb,axe=ob;function sxe(e,n){return e&&oxe(n,axe(n),e)}var lxe=sxe;function uxe(e){var n=[];if(e!=null)for(var t in Object(e))n.push(t);return n}var Axe=uxe,cxe=kd,dxe=x8,hxe=Axe,fxe=Object.prototype,pxe=fxe.hasOwnProperty;function mxe(e){if(!cxe(e))return hxe(e);var n=dxe(e),t=[];for(var r in e)r=="constructor"&&(n||!pxe.call(e,r))||t.push(r);return t}var gxe=mxe,yxe=WW,vxe=gxe,Cxe=$y;function _xe(e){return Cxe(e)?yxe(e,!0):vxe(e)}var ub=_xe,bxe=lb,xxe=ub;function wxe(e,n){return e&&bxe(n,xxe(n),e)}var Mxe=wxe,a4={exports:{}};a4.exports;(function(e,n){var t=gh,r=n&&!n.nodeType&&n,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,s=o?t.Buffer:void 0,a=s?s.allocUnsafe:void 0;function f(g,x){if(x)return g.slice();var k=g.length,B=a?a(k):new g.constructor(k);return g.copy(B),B}e.exports=f})(a4,a4.exports);var pN=a4.exports;function Sxe(e,n){var t=-1,r=e.length;for(n||(n=Array(r));++t<r;)n[t]=e[t];return n}var mN=Sxe,Exe=lb,Oxe=B8;function Bxe(e,n){return Exe(e,Oxe(e),n)}var kxe=Bxe,Ixe=XW,Txe=S8,Kxe=B8,Pxe=eN,Fxe=Object.getOwnPropertySymbols,Dxe=Fxe?function(e){for(var n=[];e;)Ixe(n,Kxe(e)),e=Txe(e);return n}:Pxe,gN=Dxe,Uxe=lb,Rxe=gN;function Lxe(e,n){return Uxe(e,Rxe(e),n)}var zxe=Lxe,jxe=JW,Wxe=gN,Nxe=ub;function Gxe(e){return jxe(e,Nxe,Wxe)}var Qxe=Gxe,$xe=Object.prototype,Yxe=$xe.hasOwnProperty;function qxe(e){var n=e.length,t=new e.constructor(n);return n&&typeof e[0]=="string"&&Yxe.call(e,"index")&&(t.index=e.index,t.input=e.input),t}var Vxe=qxe,IK=ZW;function Hxe(e){var n=new e.constructor(e.byteLength);return new IK(n).set(new IK(e)),n}var K8=Hxe,Zxe=K8;function Xxe(e,n){var t=n?Zxe(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.byteLength)}var Jxe=Xxe,e2e=/\w*$/;function t2e(e){var n=new e.constructor(e.source,e2e.exec(e));return n.lastIndex=e.lastIndex,n}var n2e=t2e,TK=ib,KK=TK?TK.prototype:void 0,PK=KK?KK.valueOf:void 0;function r2e(e){return PK?Object(PK.call(e)):{}}var i2e=r2e,o2e=K8;function a2e(e,n){var t=n?o2e(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.length)}var yN=a2e,s2e=K8,l2e=Jxe,u2e=n2e,A2e=i2e,c2e=yN,d2e="[object Boolean]",h2e="[object Date]",f2e="[object Map]",p2e="[object Number]",m2e="[object RegExp]",g2e="[object Set]",y2e="[object String]",v2e="[object Symbol]",C2e="[object ArrayBuffer]",_2e="[object DataView]",b2e="[object Float32Array]",x2e="[object Float64Array]",w2e="[object Int8Array]",M2e="[object Int16Array]",S2e="[object Int32Array]",E2e="[object Uint8Array]",O2e="[object Uint8ClampedArray]",B2e="[object Uint16Array]",k2e="[object Uint32Array]";function I2e(e,n,t){var r=e.constructor;switch(n){case C2e:return s2e(e);case d2e:case h2e:return new r(+e);case _2e:return l2e(e,t);case b2e:case x2e:case w2e:case M2e:case S2e:case E2e:case O2e:case B2e:case k2e:return c2e(e,t);case f2e:return new r;case p2e:case y2e:return new r(e);case m2e:return u2e(e);case g2e:return new r;case v2e:return A2e(e)}}var T2e=I2e,K2e=kd,FK=Object.create,P2e=function(){function e(){}return function(n){if(!K2e(n))return{};if(FK)return FK(n);e.prototype=n;var t=new e;return e.prototype=void 0,t}}(),F2e=P2e,D2e=F2e,U2e=S8,R2e=x8;function L2e(e){return typeof e.constructor=="function"&&!R2e(e)?D2e(U2e(e)):{}}var vN=L2e,z2e=Q5,j2e=bf,W2e="[object Map]";function N2e(e){return j2e(e)&&z2e(e)==W2e}var G2e=N2e,Q2e=G2e,$2e=C8,DK=_8,UK=DK&&DK.isMap,Y2e=UK?$2e(UK):Q2e,q2e=Y2e,V2e=Q5,H2e=bf,Z2e="[object Set]";function X2e(e){return H2e(e)&&V2e(e)==Z2e}var J2e=X2e,e3e=J2e,t3e=C8,RK=_8,LK=RK&&RK.isSet,n3e=LK?t3e(LK):e3e,r3e=n3e,i3e=G5,o3e=dN,a3e=fN,s3e=lxe,l3e=Mxe,u3e=pN,A3e=mN,c3e=kxe,d3e=zxe,h3e=tN,f3e=Qxe,p3e=Q5,m3e=Vxe,g3e=T2e,y3e=vN,v3e=Nc,C3e=R5,_3e=q2e,b3e=kd,x3e=r3e,w3e=ob,M3e=ub,S3e=1,E3e=2,O3e=4,CN="[object Arguments]",B3e="[object Array]",k3e="[object Boolean]",I3e="[object Date]",T3e="[object Error]",_N="[object Function]",K3e="[object GeneratorFunction]",P3e="[object Map]",F3e="[object Number]",bN="[object Object]",D3e="[object RegExp]",U3e="[object Set]",R3e="[object String]",L3e="[object Symbol]",z3e="[object WeakMap]",j3e="[object ArrayBuffer]",W3e="[object DataView]",N3e="[object Float32Array]",G3e="[object Float64Array]",Q3e="[object Int8Array]",$3e="[object Int16Array]",Y3e="[object Int32Array]",q3e="[object Uint8Array]",V3e="[object Uint8ClampedArray]",H3e="[object Uint16Array]",Z3e="[object Uint32Array]",ja={};ja[CN]=ja[B3e]=ja[j3e]=ja[W3e]=ja[k3e]=ja[I3e]=ja[N3e]=ja[G3e]=ja[Q3e]=ja[$3e]=ja[Y3e]=ja[P3e]=ja[F3e]=ja[bN]=ja[D3e]=ja[U3e]=ja[R3e]=ja[L3e]=ja[q3e]=ja[V3e]=ja[H3e]=ja[Z3e]=!0;ja[T3e]=ja[_N]=ja[z3e]=!1;function M2(e,n,t,r,i,o){var s,a=n&S3e,f=n&E3e,g=n&O3e;if(t&&(s=i?t(e,r,i,o):t(e)),s!==void 0)return s;if(!b3e(e))return e;var x=v3e(e);if(x){if(s=m3e(e),!a)return A3e(e,s)}else{var k=p3e(e),B=k==_N||k==K3e;if(C3e(e))return u3e(e,a);if(k==bN||k==CN||B&&!i){if(s=f||B?{}:y3e(e),!a)return f?d3e(e,l3e(s,e)):c3e(e,s3e(s,e))}else{if(!ja[k])return i?e:{};s=g3e(e,k,a)}}o||(o=new i3e);var P=o.get(e);if(P)return P;o.set(e,s),x3e(e)?e.forEach(function(W){s.add(M2(W,n,t,W,e,o))}):_3e(e)&&e.forEach(function(W,$){s.set($,M2(W,n,t,$,e,o))});var R=g?f?f3e:h3e:f?M3e:w3e,H=x?void 0:R(e);return o3e(H||e,function(W,$){H&&($=W,W=e[$]),a3e(s,$,M2(W,n,t,$,e,o))}),s}var X3e=M2,J3e=X3e,e4e=1,t4e=4;function n4e(e){return J3e(e,e4e|t4e)}var r4e=n4e;Object.defineProperty(sb,"__esModule",{value:!0});sb.mergeClasses=void 0;var i4e=M8,o4e=xN(i4e),a4e=r4e,s4e=xN(a4e),l4e=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e};function xN(e){return e&&e.__esModule?e:{default:e}}var u4e=sb.mergeClasses=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=n.default&&(0,s4e.default)(n.default)||{};return t.map(function(i){var o=n[i];return o&&(0,o4e.default)(o,function(s,a){r[a]||(r[a]={}),r[a]=l4e({},r[a],o[a])}),i}),r};sb.default=u4e;var Ab={};Object.defineProperty(Ab,"__esModule",{value:!0});Ab.autoprefix=void 0;var A4e=M8,zK=d4e(A4e),c4e=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e};function d4e(e){return e&&e.__esModule?e:{default:e}}var h4e={borderRadius:function(n){return{msBorderRadius:n,MozBorderRadius:n,OBorderRadius:n,WebkitBorderRadius:n,borderRadius:n}},boxShadow:function(n){return{msBoxShadow:n,MozBoxShadow:n,OBoxShadow:n,WebkitBoxShadow:n,boxShadow:n}},userSelect:function(n){return{WebkitTouchCallout:n,KhtmlUserSelect:n,MozUserSelect:n,msUserSelect:n,WebkitUserSelect:n,userSelect:n}},flex:function(n){return{WebkitBoxFlex:n,MozBoxFlex:n,WebkitFlex:n,msFlex:n,flex:n}},flexBasis:function(n){return{WebkitFlexBasis:n,flexBasis:n}},justifyContent:function(n){return{WebkitJustifyContent:n,justifyContent:n}},transition:function(n){return{msTransition:n,MozTransition:n,OTransition:n,WebkitTransition:n,transition:n}},transform:function(n){return{msTransform:n,MozTransform:n,OTransform:n,WebkitTransform:n,transform:n}},absolute:function(n){var t=n&&n.split(" ");return{position:"absolute",top:t&&t[0],right:t&&t[1],bottom:t&&t[2],left:t&&t[3]}},extend:function(n,t){var r=t[n];return r||{extend:n}}},f4e=Ab.autoprefix=function(n){var t={};return(0,zK.default)(n,function(r,i){var o={};(0,zK.default)(r,function(s,a){var f=h4e[a];f?o=c4e({},o,f(s)):o[a]=s}),t[i]=o}),t};Ab.default=f4e;var cb={};Object.defineProperty(cb,"__esModule",{value:!0});cb.hover=void 0;var p4e=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},m4e=kr,ZM=g4e(m4e);function g4e(e){return e&&e.__esModule?e:{default:e}}function y4e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function jK(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function v4e(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var C4e=cb.hover=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"span";return function(r){v4e(i,r);function i(){var o,s,a,f;y4e(this,i);for(var g=arguments.length,x=Array(g),k=0;k<g;k++)x[k]=arguments[k];return f=(s=(a=jK(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(x))),a),a.state={hover:!1},a.handleMouseOver=function(){return a.setState({hover:!0})},a.handleMouseOut=function(){return a.setState({hover:!1})},a.render=function(){return ZM.default.createElement(t,{onMouseOver:a.handleMouseOver,onMouseOut:a.handleMouseOut},ZM.default.createElement(n,p4e({},a.props,a.state)))},s),jK(a,f)}return i}(ZM.default.Component)};cb.default=C4e;var db={};Object.defineProperty(db,"__esModule",{value:!0});db.active=void 0;var _4e=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},b4e=kr,XM=x4e(b4e);function x4e(e){return e&&e.__esModule?e:{default:e}}function w4e(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function WK(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function M4e(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var S4e=db.active=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"span";return function(r){M4e(i,r);function i(){var o,s,a,f;w4e(this,i);for(var g=arguments.length,x=Array(g),k=0;k<g;k++)x[k]=arguments[k];return f=(s=(a=WK(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(x))),a),a.state={active:!1},a.handleMouseDown=function(){return a.setState({active:!0})},a.handleMouseUp=function(){return a.setState({active:!1})},a.render=function(){return XM.default.createElement(t,{onMouseDown:a.handleMouseDown,onMouseUp:a.handleMouseUp},XM.default.createElement(n,_4e({},a.props,a.state)))},s),WK(a,f)}return i}(XM.default.Component)};db.default=S4e;var P8={};Object.defineProperty(P8,"__esModule",{value:!0});var E4e=function(n,t){var r={},i=function(s){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;r[s]=a};return n===0&&i("first-child"),n===t-1&&i("last-child"),(n===0||n%2===0)&&i("even"),Math.abs(n%2)===1&&i("odd"),i("nth-child",n),r};P8.default=E4e;Object.defineProperty(Ps,"__esModule",{value:!0});Ps.ReactCSS=Ps.loop=Ps.handleActive=Ps.handleHover=Ps.hover=void 0;var O4e=rb,B4e=Xy(O4e),k4e=sb,I4e=Xy(k4e),T4e=Ab,K4e=Xy(T4e),P4e=cb,wN=Xy(P4e),F4e=db,D4e=Xy(F4e),U4e=P8,R4e=Xy(U4e);function Xy(e){return e&&e.__esModule?e:{default:e}}Ps.hover=wN.default;Ps.handleHover=wN.default;Ps.handleActive=D4e.default;Ps.loop=R4e.default;var L4e=Ps.ReactCSS=function(n){for(var t=arguments.length,r=Array(t>1?t-1:0),i=1;i<t;i++)r[i-1]=arguments[i];var o=(0,B4e.default)(r),s=(0,I4e.default)(n,o);return(0,K4e.default)(s)};Ps.default=L4e;var z4e=T8,j4e=ab;function W4e(e,n,t){(t!==void 0&&!j4e(e[n],t)||t===void 0&&!(n in e))&&z4e(e,n,t)}var MN=W4e,N4e=$y,G4e=bf;function Q4e(e){return G4e(e)&&N4e(e)}var $4e=Q4e;function Y4e(e,n){if(!(n==="constructor"&&typeof e[n]=="function")&&n!="__proto__")return e[n]}var SN=Y4e,q4e=lb,V4e=ub;function H4e(e){return q4e(e,V4e(e))}var Z4e=H4e,NK=MN,X4e=pN,J4e=yN,e5e=mN,t5e=vN,GK=g8,QK=Nc,n5e=$4e,r5e=R5,i5e=w8,o5e=kd,a5e=YW,s5e=b8,$K=SN,l5e=Z4e;function u5e(e,n,t,r,i,o,s){var a=$K(e,t),f=$K(n,t),g=s.get(f);if(g){NK(e,t,g);return}var x=o?o(a,f,t+"",e,n,s):void 0,k=x===void 0;if(k){var B=QK(f),P=!B&&r5e(f),R=!B&&!P&&s5e(f);x=f,B||P||R?QK(a)?x=a:n5e(a)?x=e5e(a):P?(k=!1,x=X4e(f,!0)):R?(k=!1,x=J4e(f,!0)):x=[]:a5e(f)||GK(f)?(x=a,GK(a)?x=l5e(a):(!o5e(a)||i5e(a))&&(x=t5e(f))):k=!1}k&&(s.set(f,x),i(x,f,r,o,s),s.delete(f)),NK(e,t,x)}var A5e=u5e,c5e=G5,d5e=MN,h5e=zW,f5e=A5e,p5e=kd,m5e=ub,g5e=SN;function EN(e,n,t,r,i){e!==n&&h5e(n,function(o,s){if(i||(i=new c5e),p5e(o))f5e(e,n,s,t,EN,r,i);else{var a=r?r(g5e(e,s),o,s+"",e,n,i):void 0;a===void 0&&(a=o),d5e(e,s,a)}},m5e)}var y5e=EN;function v5e(e,n,t){switch(t.length){case 0:return e.call(n);case 1:return e.call(n,t[0]);case 2:return e.call(n,t[0],t[1]);case 3:return e.call(n,t[0],t[1],t[2])}return e.apply(n,t)}var C5e=v5e,_5e=C5e,YK=Math.max;function b5e(e,n,t){return n=YK(n===void 0?e.length-1:n,0),function(){for(var r=arguments,i=-1,o=YK(r.length-n,0),s=Array(o);++i<o;)s[i]=r[n+i];i=-1;for(var a=Array(n+1);++i<n;)a[i]=r[i];return a[n]=t(s),_5e(e,this,a)}}var x5e=b5e;function w5e(e){return function(){return e}}var M5e=w5e,S5e=M5e,qK=hN,E5e=L5,O5e=qK?function(e,n){return qK(e,"toString",{configurable:!0,enumerable:!1,value:S5e(n),writable:!0})}:E5e,B5e=O5e,k5e=800,I5e=16,T5e=Date.now;function K5e(e){var n=0,t=0;return function(){var r=T5e(),i=I5e-(r-t);if(t=r,i>0){if(++n>=k5e)return arguments[0]}else n=0;return e.apply(void 0,arguments)}}var P5e=K5e,F5e=B5e,D5e=P5e,U5e=D5e(F5e),R5e=U5e,L5e=L5,z5e=x5e,j5e=R5e;function W5e(e,n){return j5e(z5e(e,n,L5e),e+"")}var N5e=W5e,G5e=ab,Q5e=$y,$5e=y8,Y5e=kd;function q5e(e,n,t){if(!Y5e(t))return!1;var r=typeof n;return(r=="number"?Q5e(t)&&$5e(n,t.length):r=="string"&&n in t)?G5e(t[n],e):!1}var V5e=q5e,H5e=N5e,Z5e=V5e;function X5e(e){return H5e(function(n,t){var r=-1,i=t.length,o=i>1?t[i-1]:void 0,s=i>2?t[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,s&&Z5e(t[0],t[1],s)&&(o=i<3?void 0:o,i=1),n=Object(n);++r<i;){var a=t[r];a&&e(n,a,r,o)}return n})}var J5e=X5e,ewe=y5e,twe=J5e,nwe=twe(function(e,n,t){ewe(e,n,t)}),ON=nwe,F8={},hb={},D8={};Object.defineProperty(D8,"__esModule",{value:!0});D8.calculateChange=function(n,t,r,i,o){var s=o.clientWidth,a=o.clientHeight,f=typeof n.pageX=="number"?n.pageX:n.touches[0].pageX,g=typeof n.pageY=="number"?n.pageY:n.touches[0].pageY,x=f-(o.getBoundingClientRect().left+window.pageXOffset),k=g-(o.getBoundingClientRect().top+window.pageYOffset);if(r==="vertical"){var B=void 0;if(k<0?B=0:k>a?B=1:B=Math.round(k*100/a)/100,t.a!==B)return{h:t.h,s:t.s,l:t.l,a:B,source:"rgb"}}else{var P=void 0;if(x<0?P=0:x>s?P=1:P=Math.round(x*100/s)/100,i!==P)return{h:t.h,s:t.s,l:t.l,a:P,source:"rgb"}}return null};var E1={},V5={};Object.defineProperty(V5,"__esModule",{value:!0});var JM={},rwe=V5.render=function(n,t,r,i){if(typeof document>"u"&&!i)return null;var o=i?new i:document.createElement("canvas");o.width=r*2,o.height=r*2;var s=o.getContext("2d");return s?(s.fillStyle=n,s.fillRect(0,0,o.width,o.height),s.fillStyle=t,s.fillRect(0,0,r,r),s.translate(r,r),s.fillRect(0,0,r,r),o.toDataURL()):null};V5.get=function(n,t,r,i){var o=n+"-"+t+"-"+r+(i?"-server":"");if(JM[o])return JM[o];var s=rwe(n,t,r,i);return JM[o]=s,s};Object.defineProperty(E1,"__esModule",{value:!0});E1.Checkboard=void 0;var VK=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},BN=kr,HK=kN(BN),iwe=Ps,owe=kN(iwe),awe=V5,swe=lwe(awe);function lwe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function kN(e){return e&&e.__esModule?e:{default:e}}var IN=E1.Checkboard=function(n){var t=n.white,r=n.grey,i=n.size,o=n.renderers,s=n.borderRadius,a=n.boxShadow,f=n.children,g=(0,owe.default)({default:{grid:{borderRadius:s,boxShadow:a,absolute:"0px 0px 0px 0px",background:"url("+swe.get(t,r,i,o.canvas)+") center left"}}});return(0,BN.isValidElement)(f)?HK.default.cloneElement(f,VK({},f.props,{style:VK({},f.props.style,g.grid)})):HK.default.createElement("div",{style:g.grid})};IN.defaultProps={size:8,white:"transparent",grey:"rgba(0,0,0,.08)",renderers:{}};E1.default=IN;Object.defineProperty(hb,"__esModule",{value:!0});hb.Alpha=void 0;var uwe=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},Awe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),HE=kr,Hp=U8(HE),cwe=Ps,dwe=U8(cwe),hwe=D8,fwe=gwe(hwe),pwe=E1,mwe=U8(pwe);function gwe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function U8(e){return e&&e.__esModule?e:{default:e}}function ywe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function ZK(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function vwe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var Cwe=hb.Alpha=function(e){vwe(n,e);function n(){var t,r,i,o;ywe(this,n);for(var s=arguments.length,a=Array(s),f=0;f<s;f++)a[f]=arguments[f];return o=(r=(i=ZK(this,(t=n.__proto__||Object.getPrototypeOf(n)).call.apply(t,[this].concat(a))),i),i.handleChange=function(g){var x=fwe.calculateChange(g,i.props.hsl,i.props.direction,i.props.a,i.container);x&&typeof i.props.onChange=="function"&&i.props.onChange(x,g)},i.handleMouseDown=function(g){i.handleChange(g),window.addEventListener("mousemove",i.handleChange),window.addEventListener("mouseup",i.handleMouseUp)},i.handleMouseUp=function(){i.unbindEventListeners()},i.unbindEventListeners=function(){window.removeEventListener("mousemove",i.handleChange),window.removeEventListener("mouseup",i.handleMouseUp)},r),ZK(i,o)}return Awe(n,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"render",value:function(){var r=this,i=this.props.rgb,o=(0,dwe.default)({default:{alpha:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},checkboard:{absolute:"0px 0px 0px 0px",overflow:"hidden",borderRadius:this.props.radius},gradient:{absolute:"0px 0px 0px 0px",background:"linear-gradient(to right, rgba("+i.r+","+i.g+","+i.b+`, 0) 0%,
|
||
rgba(`+i.r+","+i.g+","+i.b+", 1) 100%)",boxShadow:this.props.shadow,borderRadius:this.props.radius},container:{position:"relative",height:"100%",margin:"0 3px"},pointer:{position:"absolute",left:i.a*100+"%"},slider:{width:"4px",borderRadius:"1px",height:"8px",boxShadow:"0 0 2px rgba(0, 0, 0, .6)",background:"#fff",marginTop:"1px",transform:"translateX(-2px)"}},vertical:{gradient:{background:"linear-gradient(to bottom, rgba("+i.r+","+i.g+","+i.b+`, 0) 0%,
|
||
rgba(`+i.r+","+i.g+","+i.b+", 1) 100%)"},pointer:{left:0,top:i.a*100+"%"}},overwrite:uwe({},this.props.style)},{vertical:this.props.direction==="vertical",overwrite:!0});return Hp.default.createElement("div",{style:o.alpha},Hp.default.createElement("div",{style:o.checkboard},Hp.default.createElement(mwe.default,{renderers:this.props.renderers})),Hp.default.createElement("div",{style:o.gradient}),Hp.default.createElement("div",{style:o.container,ref:function(a){return r.container=a},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},Hp.default.createElement("div",{style:o.pointer},this.props.pointer?Hp.default.createElement(this.props.pointer,this.props):Hp.default.createElement("div",{style:o.slider}))))}}]),n}(HE.PureComponent||HE.Component);hb.default=Cwe;var fb={};Object.defineProperty(fb,"__esModule",{value:!0});fb.EditableInput=void 0;var _we=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),ZE=kr,eS=TN(ZE),bwe=Ps,xwe=TN(bwe);function TN(e){return e&&e.__esModule?e:{default:e}}function wwe(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function Mwe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function Swe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function Ewe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var Owe=1,KN=38,Bwe=40,kwe=[KN,Bwe],Iwe=function(n){return kwe.indexOf(n)>-1},Twe=function(n){return Number(String(n).replace(/%/g,""))},Kwe=1,Pwe=fb.EditableInput=function(e){Ewe(n,e);function n(t){Mwe(this,n);var r=Swe(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return r.handleBlur=function(){r.state.blurValue&&r.setState({value:r.state.blurValue,blurValue:null})},r.handleChange=function(i){r.setUpdatedValue(i.target.value,i)},r.handleKeyDown=function(i){var o=Twe(i.target.value);if(!isNaN(o)&&Iwe(i.keyCode)){var s=r.getArrowOffset(),a=i.keyCode===KN?o+s:o-s;r.setUpdatedValue(a,i)}},r.handleDrag=function(i){if(r.props.dragLabel){var o=Math.round(r.props.value+i.movementX);o>=0&&o<=r.props.dragMax&&r.props.onChange&&r.props.onChange(r.getValueObjectWithLabel(o),i)}},r.handleMouseDown=function(i){r.props.dragLabel&&(i.preventDefault(),r.handleDrag(i),window.addEventListener("mousemove",r.handleDrag),window.addEventListener("mouseup",r.handleMouseUp))},r.handleMouseUp=function(){r.unbindEventListeners()},r.unbindEventListeners=function(){window.removeEventListener("mousemove",r.handleDrag),window.removeEventListener("mouseup",r.handleMouseUp)},r.state={value:String(t.value).toUpperCase(),blurValue:String(t.value).toUpperCase()},r.inputId="rc-editable-input-"+Kwe++,r}return _we(n,[{key:"componentDidUpdate",value:function(r,i){this.props.value!==this.state.value&&(r.value!==this.props.value||i.value!==this.state.value)&&(this.input===document.activeElement?this.setState({blurValue:String(this.props.value).toUpperCase()}):this.setState({value:String(this.props.value).toUpperCase(),blurValue:!this.state.blurValue&&String(this.props.value).toUpperCase()}))}},{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"getValueObjectWithLabel",value:function(r){return wwe({},this.props.label,r)}},{key:"getArrowOffset",value:function(){return this.props.arrowOffset||Owe}},{key:"setUpdatedValue",value:function(r,i){var o=this.props.label?this.getValueObjectWithLabel(r):r;this.props.onChange&&this.props.onChange(o,i),this.setState({value:r})}},{key:"render",value:function(){var r=this,i=(0,xwe.default)({default:{wrap:{position:"relative"}},"user-override":{wrap:this.props.style&&this.props.style.wrap?this.props.style.wrap:{},input:this.props.style&&this.props.style.input?this.props.style.input:{},label:this.props.style&&this.props.style.label?this.props.style.label:{}},"dragLabel-true":{label:{cursor:"ew-resize"}}},{"user-override":!0},this.props);return eS.default.createElement("div",{style:i.wrap},eS.default.createElement("input",{id:this.inputId,style:i.input,ref:function(s){return r.input=s},value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,onBlur:this.handleBlur,placeholder:this.props.placeholder,spellCheck:"false"}),this.props.label&&!this.props.hideLabel?eS.default.createElement("label",{htmlFor:this.inputId,style:i.label,onMouseDown:this.handleMouseDown},this.props.label):null)}}]),n}(ZE.PureComponent||ZE.Component);fb.default=Pwe;var pb={},R8={};Object.defineProperty(R8,"__esModule",{value:!0});R8.calculateChange=function(n,t,r,i){var o=i.clientWidth,s=i.clientHeight,a=typeof n.pageX=="number"?n.pageX:n.touches[0].pageX,f=typeof n.pageY=="number"?n.pageY:n.touches[0].pageY,g=a-(i.getBoundingClientRect().left+window.pageXOffset),x=f-(i.getBoundingClientRect().top+window.pageYOffset);if(t==="vertical"){var k=void 0;if(x<0)k=359;else if(x>s)k=0;else{var B=-(x*100/s)+100;k=360*B/100}if(r.h!==k)return{h:k,s:r.s,l:r.l,a:r.a,source:"hsl"}}else{var P=void 0;if(g<0)P=0;else if(g>o)P=359;else{var R=g*100/o;P=360*R/100}if(r.h!==P)return{h:P,s:r.s,l:r.l,a:r.a,source:"hsl"}}return null};Object.defineProperty(pb,"__esModule",{value:!0});pb.Hue=void 0;var Fwe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),XE=kr,dg=PN(XE),Dwe=Ps,Uwe=PN(Dwe),Rwe=R8,Lwe=zwe(Rwe);function zwe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function PN(e){return e&&e.__esModule?e:{default:e}}function jwe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function XK(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function Wwe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var Nwe=pb.Hue=function(e){Wwe(n,e);function n(){var t,r,i,o;jwe(this,n);for(var s=arguments.length,a=Array(s),f=0;f<s;f++)a[f]=arguments[f];return o=(r=(i=XK(this,(t=n.__proto__||Object.getPrototypeOf(n)).call.apply(t,[this].concat(a))),i),i.handleChange=function(g){var x=Lwe.calculateChange(g,i.props.direction,i.props.hsl,i.container);x&&typeof i.props.onChange=="function"&&i.props.onChange(x,g)},i.handleMouseDown=function(g){i.handleChange(g),window.addEventListener("mousemove",i.handleChange),window.addEventListener("mouseup",i.handleMouseUp)},i.handleMouseUp=function(){i.unbindEventListeners()},r),XK(i,o)}return Fwe(n,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"unbindEventListeners",value:function(){window.removeEventListener("mousemove",this.handleChange),window.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var r=this,i=this.props.direction,o=i===void 0?"horizontal":i,s=(0,Uwe.default)({default:{hue:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius,boxShadow:this.props.shadow},container:{padding:"0 2px",position:"relative",height:"100%",borderRadius:this.props.radius},pointer:{position:"absolute",left:this.props.hsl.h*100/360+"%"},slider:{marginTop:"1px",width:"4px",borderRadius:"1px",height:"8px",boxShadow:"0 0 2px rgba(0, 0, 0, .6)",background:"#fff",transform:"translateX(-2px)"}},vertical:{pointer:{left:"0px",top:-(this.props.hsl.h*100/360)+100+"%"}}},{vertical:o==="vertical"});return dg.default.createElement("div",{style:s.hue},dg.default.createElement("div",{className:"hue-"+o,style:s.container,ref:function(f){return r.container=f},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},dg.default.createElement("style",null,`
|
||
.hue-horizontal {
|
||
background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0
|
||
33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);
|
||
background: -webkit-linear-gradient(to right, #f00 0%, #ff0
|
||
17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);
|
||
}
|
||
|
||
.hue-vertical {
|
||
background: linear-gradient(to top, #f00 0%, #ff0 17%, #0f0 33%,
|
||
#0ff 50%, #00f 67%, #f0f 83%, #f00 100%);
|
||
background: -webkit-linear-gradient(to top, #f00 0%, #ff0 17%,
|
||
#0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);
|
||
}
|
||
`),dg.default.createElement("div",{style:s.pointer},this.props.pointer?dg.default.createElement(this.props.pointer,this.props):dg.default.createElement("div",{style:s.slider}))))}}]),n}(XE.PureComponent||XE.Component);pb.default=Nwe;var mb={};Object.defineProperty(mb,"__esModule",{value:!0});mb.Raised=void 0;var Gwe=kr,tS=H5(Gwe),Qwe=ph,$x=H5(Qwe),$we=Ps,Ywe=H5($we),qwe=ON,Vwe=H5(qwe);function H5(e){return e&&e.__esModule?e:{default:e}}var L8=mb.Raised=function(n){var t=n.zDepth,r=n.radius,i=n.background,o=n.children,s=n.styles,a=s===void 0?{}:s,f=(0,Ywe.default)((0,Vwe.default)({default:{wrap:{position:"relative",display:"inline-block"},content:{position:"relative"},bg:{absolute:"0px 0px 0px 0px",boxShadow:"0 "+t+"px "+t*4+"px rgba(0,0,0,.24)",borderRadius:r,background:i}},"zDepth-0":{bg:{boxShadow:"none"}},"zDepth-1":{bg:{boxShadow:"0 2px 10px rgba(0,0,0,.12), 0 2px 5px rgba(0,0,0,.16)"}},"zDepth-2":{bg:{boxShadow:"0 6px 20px rgba(0,0,0,.19), 0 8px 17px rgba(0,0,0,.2)"}},"zDepth-3":{bg:{boxShadow:"0 17px 50px rgba(0,0,0,.19), 0 12px 15px rgba(0,0,0,.24)"}},"zDepth-4":{bg:{boxShadow:"0 25px 55px rgba(0,0,0,.21), 0 16px 28px rgba(0,0,0,.22)"}},"zDepth-5":{bg:{boxShadow:"0 40px 77px rgba(0,0,0,.22), 0 27px 24px rgba(0,0,0,.2)"}},square:{bg:{borderRadius:"0"}},circle:{bg:{borderRadius:"50%"}}},a),{"zDepth-1":t===1});return tS.default.createElement("div",{style:f.wrap},tS.default.createElement("div",{style:f.bg}),tS.default.createElement("div",{style:f.content},o))};L8.propTypes={background:$x.default.string,zDepth:$x.default.oneOf([0,1,2,3,4,5]),radius:$x.default.number,styles:$x.default.object};L8.defaultProps={background:"#fff",zDepth:1,radius:2,styles:{}};mb.default=L8;var gb={},Hwe=gh,Zwe=function(){return Hwe.Date.now()},Xwe=Zwe,Jwe=/\s/;function eMe(e){for(var n=e.length;n--&&Jwe.test(e.charAt(n)););return n}var tMe=eMe,nMe=tMe,rMe=/^\s+/;function iMe(e){return e&&e.slice(0,nMe(e)+1).replace(rMe,"")}var oMe=iMe,aMe=oMe,JK=kd,sMe=$5,eP=NaN,lMe=/^[-+]0x[0-9a-f]+$/i,uMe=/^0b[01]+$/i,AMe=/^0o[0-7]+$/i,cMe=parseInt;function dMe(e){if(typeof e=="number")return e;if(sMe(e))return eP;if(JK(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=JK(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=aMe(e);var t=uMe.test(e);return t||AMe.test(e)?cMe(e.slice(2),t?2:8):lMe.test(e)?eP:+e}var hMe=dMe,fMe=kd,nS=Xwe,tP=hMe,pMe="Expected a function",mMe=Math.max,gMe=Math.min;function yMe(e,n,t){var r,i,o,s,a,f,g=0,x=!1,k=!1,B=!0;if(typeof e!="function")throw new TypeError(pMe);n=tP(n)||0,fMe(t)&&(x=!!t.leading,k="maxWait"in t,o=k?mMe(tP(t.maxWait)||0,n):o,B="trailing"in t?!!t.trailing:B);function P(ae){var ue=r,ye=i;return r=i=void 0,g=ae,s=e.apply(ye,ue),s}function R(ae){return g=ae,a=setTimeout($,n),x?P(ae):s}function H(ae){var ue=ae-f,ye=ae-g,Re=n-ue;return k?gMe(Re,o-ye):Re}function W(ae){var ue=ae-f,ye=ae-g;return f===void 0||ue>=n||ue<0||k&&ye>=o}function $(){var ae=nS();if(W(ae))return q(ae);a=setTimeout($,H(ae))}function q(ae){return a=void 0,B&&r?P(ae):(r=i=void 0,s)}function oe(){a!==void 0&&clearTimeout(a),g=0,r=f=i=a=void 0}function ne(){return a===void 0?s:q(nS())}function ce(){var ae=nS(),ue=W(ae);if(r=arguments,i=this,f=ae,ue){if(a===void 0)return R(f);if(k)return clearTimeout(a),a=setTimeout($,n),P(f)}return a===void 0&&(a=setTimeout($,n)),s}return ce.cancel=oe,ce.flush=ne,ce}var FN=yMe,vMe=FN,CMe=kd,_Me="Expected a function";function bMe(e,n,t){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(_Me);return CMe(t)&&(r="leading"in t?!!t.leading:r,i="trailing"in t?!!t.trailing:i),vMe(e,n,{leading:r,maxWait:n,trailing:i})}var xMe=bMe,z8={};Object.defineProperty(z8,"__esModule",{value:!0});z8.calculateChange=function(n,t,r){var i=r.getBoundingClientRect(),o=i.width,s=i.height,a=typeof n.pageX=="number"?n.pageX:n.touches[0].pageX,f=typeof n.pageY=="number"?n.pageY:n.touches[0].pageY,g=a-(r.getBoundingClientRect().left+window.pageXOffset),x=f-(r.getBoundingClientRect().top+window.pageYOffset);g<0?g=0:g>o&&(g=o),x<0?x=0:x>s&&(x=s);var k=g/o,B=1-x/s;return{h:t.h,s:k,v:B,a:t.a,source:"hsv"}};Object.defineProperty(gb,"__esModule",{value:!0});gb.Saturation=void 0;var wMe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),JE=kr,x0=j8(JE),MMe=Ps,SMe=j8(MMe),EMe=xMe,OMe=j8(EMe),BMe=z8,kMe=IMe(BMe);function IMe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function j8(e){return e&&e.__esModule?e:{default:e}}function TMe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function KMe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function PMe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var FMe=gb.Saturation=function(e){PMe(n,e);function n(t){TMe(this,n);var r=KMe(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,t));return r.handleChange=function(i){typeof r.props.onChange=="function"&&r.throttle(r.props.onChange,kMe.calculateChange(i,r.props.hsl,r.container),i)},r.handleMouseDown=function(i){r.handleChange(i);var o=r.getContainerRenderWindow();o.addEventListener("mousemove",r.handleChange),o.addEventListener("mouseup",r.handleMouseUp)},r.handleMouseUp=function(){r.unbindEventListeners()},r.throttle=(0,OMe.default)(function(i,o,s){i(o,s)},50),r}return wMe(n,[{key:"componentWillUnmount",value:function(){this.throttle.cancel(),this.unbindEventListeners()}},{key:"getContainerRenderWindow",value:function(){for(var r=this.container,i=window;!i.document.contains(r)&&i.parent!==i;)i=i.parent;return i}},{key:"unbindEventListeners",value:function(){var r=this.getContainerRenderWindow();r.removeEventListener("mousemove",this.handleChange),r.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var r=this,i=this.props.style||{},o=i.color,s=i.white,a=i.black,f=i.pointer,g=i.circle,x=(0,SMe.default)({default:{color:{absolute:"0px 0px 0px 0px",background:"hsl("+this.props.hsl.h+",100%, 50%)",borderRadius:this.props.radius},white:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},black:{absolute:"0px 0px 0px 0px",boxShadow:this.props.shadow,borderRadius:this.props.radius},pointer:{position:"absolute",top:-(this.props.hsv.v*100)+100+"%",left:this.props.hsv.s*100+"%",cursor:"default"},circle:{width:"4px",height:"4px",boxShadow:`0 0 0 1.5px #fff, inset 0 0 1px 1px rgba(0,0,0,.3),
|
||
0 0 1px 2px rgba(0,0,0,.4)`,borderRadius:"50%",cursor:"hand",transform:"translate(-2px, -2px)"}},custom:{color:o,white:s,black:a,pointer:f,circle:g}},{custom:!!this.props.style});return x0.default.createElement("div",{style:x.color,ref:function(B){return r.container=B},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},x0.default.createElement("style",null,`
|
||
.saturation-white {
|
||
background: -webkit-linear-gradient(to right, #fff, rgba(255,255,255,0));
|
||
background: linear-gradient(to right, #fff, rgba(255,255,255,0));
|
||
}
|
||
.saturation-black {
|
||
background: -webkit-linear-gradient(to top, #000, rgba(0,0,0,0));
|
||
background: linear-gradient(to top, #000, rgba(0,0,0,0));
|
||
}
|
||
`),x0.default.createElement("div",{style:x.white,className:"saturation-white"},x0.default.createElement("div",{style:x.black,className:"saturation-black"}),x0.default.createElement("div",{style:x.pointer},this.props.pointer?x0.default.createElement(this.props.pointer,this.props):x0.default.createElement("div",{style:x.circle}))))}}]),n}(JE.PureComponent||JE.Component);gb.default=FMe;var yb={},fA={},DMe=dN,UMe=cN,RMe=QW,LMe=Nc;function zMe(e,n){var t=LMe(e)?DMe:UMe;return t(e,RMe(n))}var jMe=zMe,WMe=jMe,DN={exports:{}};(function(e,n){(function(t,r){e.exports=r()})(mf,function(){function t(Se){"@babel/helpers - typeof";return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(de){return typeof de}:function(de){return de&&typeof Symbol=="function"&&de.constructor===Symbol&&de!==Symbol.prototype?"symbol":typeof de},t(Se)}var r=/^\s+/,i=/\s+$/;function o(Se,de){if(Se=Se||"",de=de||{},Se instanceof o)return Se;if(!(this instanceof o))return new o(Se,de);var xe=s(Se);this._originalInput=Se,this._r=xe.r,this._g=xe.g,this._b=xe.b,this._a=xe.a,this._roundA=Math.round(100*this._a)/100,this._format=de.format||xe.format,this._gradientType=de.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=xe.ok}o.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var de=this.toRgb();return(de.r*299+de.g*587+de.b*114)/1e3},getLuminance:function(){var de=this.toRgb(),xe,Pe,Ze,Xe,wt,Kt;return xe=de.r/255,Pe=de.g/255,Ze=de.b/255,xe<=.03928?Xe=xe/12.92:Xe=Math.pow((xe+.055)/1.055,2.4),Pe<=.03928?wt=Pe/12.92:wt=Math.pow((Pe+.055)/1.055,2.4),Ze<=.03928?Kt=Ze/12.92:Kt=Math.pow((Ze+.055)/1.055,2.4),.2126*Xe+.7152*wt+.0722*Kt},setAlpha:function(de){return this._a=He(de),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var de=x(this._r,this._g,this._b);return{h:de.h*360,s:de.s,v:de.v,a:this._a}},toHsvString:function(){var de=x(this._r,this._g,this._b),xe=Math.round(de.h*360),Pe=Math.round(de.s*100),Ze=Math.round(de.v*100);return this._a==1?"hsv("+xe+", "+Pe+"%, "+Ze+"%)":"hsva("+xe+", "+Pe+"%, "+Ze+"%, "+this._roundA+")"},toHsl:function(){var de=f(this._r,this._g,this._b);return{h:de.h*360,s:de.s,l:de.l,a:this._a}},toHslString:function(){var de=f(this._r,this._g,this._b),xe=Math.round(de.h*360),Pe=Math.round(de.s*100),Ze=Math.round(de.l*100);return this._a==1?"hsl("+xe+", "+Pe+"%, "+Ze+"%)":"hsla("+xe+", "+Pe+"%, "+Ze+"%, "+this._roundA+")"},toHex:function(de){return B(this._r,this._g,this._b,de)},toHexString:function(de){return"#"+this.toHex(de)},toHex8:function(de){return P(this._r,this._g,this._b,this._a,de)},toHex8String:function(de){return"#"+this.toHex8(de)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(Ce(this._r,255)*100)+"%",g:Math.round(Ce(this._g,255)*100)+"%",b:Math.round(Ce(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(Ce(this._r,255)*100)+"%, "+Math.round(Ce(this._g,255)*100)+"%, "+Math.round(Ce(this._b,255)*100)+"%)":"rgba("+Math.round(Ce(this._r,255)*100)+"%, "+Math.round(Ce(this._g,255)*100)+"%, "+Math.round(Ce(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:ct[B(this._r,this._g,this._b,!0)]||!1},toFilter:function(de){var xe="#"+R(this._r,this._g,this._b,this._a),Pe=xe,Ze=this._gradientType?"GradientType = 1, ":"";if(de){var Xe=o(de);Pe="#"+R(Xe._r,Xe._g,Xe._b,Xe._a)}return"progid:DXImageTransform.Microsoft.gradient("+Ze+"startColorstr="+xe+",endColorstr="+Pe+")"},toString:function(de){var xe=!!de;de=de||this._format;var Pe=!1,Ze=this._a<1&&this._a>=0,Xe=!xe&&Ze&&(de==="hex"||de==="hex6"||de==="hex3"||de==="hex4"||de==="hex8"||de==="name");return Xe?de==="name"&&this._a===0?this.toName():this.toRgbString():(de==="rgb"&&(Pe=this.toRgbString()),de==="prgb"&&(Pe=this.toPercentageRgbString()),(de==="hex"||de==="hex6")&&(Pe=this.toHexString()),de==="hex3"&&(Pe=this.toHexString(!0)),de==="hex4"&&(Pe=this.toHex8String(!0)),de==="hex8"&&(Pe=this.toHex8String()),de==="name"&&(Pe=this.toName()),de==="hsl"&&(Pe=this.toHslString()),de==="hsv"&&(Pe=this.toHsvString()),Pe||this.toHexString())},clone:function(){return o(this.toString())},_applyModification:function(de,xe){var Pe=de.apply(null,[this].concat([].slice.call(xe)));return this._r=Pe._r,this._g=Pe._g,this._b=Pe._b,this.setAlpha(Pe._a),this},lighten:function(){return this._applyModification(q,arguments)},brighten:function(){return this._applyModification(oe,arguments)},darken:function(){return this._applyModification(ne,arguments)},desaturate:function(){return this._applyModification(H,arguments)},saturate:function(){return this._applyModification(W,arguments)},greyscale:function(){return this._applyModification($,arguments)},spin:function(){return this._applyModification(ce,arguments)},_applyCombination:function(de,xe){return de.apply(null,[this].concat([].slice.call(xe)))},analogous:function(){return this._applyCombination(Re,arguments)},complement:function(){return this._applyCombination(ae,arguments)},monochromatic:function(){return this._applyCombination(Ne,arguments)},splitcomplement:function(){return this._applyCombination(ye,arguments)},triad:function(){return this._applyCombination(ue,[3])},tetrad:function(){return this._applyCombination(ue,[4])}},o.fromRatio=function(Se,de){if(t(Se)=="object"){var xe={};for(var Pe in Se)Se.hasOwnProperty(Pe)&&(Pe==="a"?xe[Pe]=Se[Pe]:xe[Pe]=nt(Se[Pe]));Se=xe}return o(Se,de)};function s(Se){var de={r:0,g:0,b:0},xe=1,Pe=null,Ze=null,Xe=null,wt=!1,Kt=!1;return typeof Se=="string"&&(Se=kt(Se)),t(Se)=="object"&&(dt(Se.r)&&dt(Se.g)&&dt(Se.b)?(de=a(Se.r,Se.g,Se.b),wt=!0,Kt=String(Se.r).substr(-1)==="%"?"prgb":"rgb"):dt(Se.h)&&dt(Se.s)&&dt(Se.v)?(Pe=nt(Se.s),Ze=nt(Se.v),de=k(Se.h,Pe,Ze),wt=!0,Kt="hsv"):dt(Se.h)&&dt(Se.s)&&dt(Se.l)&&(Pe=nt(Se.s),Xe=nt(Se.l),de=g(Se.h,Pe,Xe),wt=!0,Kt="hsl"),Se.hasOwnProperty("a")&&(xe=Se.a)),xe=He(xe),{ok:wt,format:Se.format||Kt,r:Math.min(255,Math.max(de.r,0)),g:Math.min(255,Math.max(de.g,0)),b:Math.min(255,Math.max(de.b,0)),a:xe}}function a(Se,de,xe){return{r:Ce(Se,255)*255,g:Ce(de,255)*255,b:Ce(xe,255)*255}}function f(Se,de,xe){Se=Ce(Se,255),de=Ce(de,255),xe=Ce(xe,255);var Pe=Math.max(Se,de,xe),Ze=Math.min(Se,de,xe),Xe,wt,Kt=(Pe+Ze)/2;if(Pe==Ze)Xe=wt=0;else{var Pt=Pe-Ze;switch(wt=Kt>.5?Pt/(2-Pe-Ze):Pt/(Pe+Ze),Pe){case Se:Xe=(de-xe)/Pt+(de<xe?6:0);break;case de:Xe=(xe-Se)/Pt+2;break;case xe:Xe=(Se-de)/Pt+4;break}Xe/=6}return{h:Xe,s:wt,l:Kt}}function g(Se,de,xe){var Pe,Ze,Xe;Se=Ce(Se,360),de=Ce(de,100),xe=Ce(xe,100);function wt(zn,mt,pn){return pn<0&&(pn+=1),pn>1&&(pn-=1),pn<1/6?zn+(mt-zn)*6*pn:pn<1/2?mt:pn<2/3?zn+(mt-zn)*(2/3-pn)*6:zn}if(de===0)Pe=Ze=Xe=xe;else{var Kt=xe<.5?xe*(1+de):xe+de-xe*de,Pt=2*xe-Kt;Pe=wt(Pt,Kt,Se+1/3),Ze=wt(Pt,Kt,Se),Xe=wt(Pt,Kt,Se-1/3)}return{r:Pe*255,g:Ze*255,b:Xe*255}}function x(Se,de,xe){Se=Ce(Se,255),de=Ce(de,255),xe=Ce(xe,255);var Pe=Math.max(Se,de,xe),Ze=Math.min(Se,de,xe),Xe,wt,Kt=Pe,Pt=Pe-Ze;if(wt=Pe===0?0:Pt/Pe,Pe==Ze)Xe=0;else{switch(Pe){case Se:Xe=(de-xe)/Pt+(de<xe?6:0);break;case de:Xe=(xe-Se)/Pt+2;break;case xe:Xe=(Se-de)/Pt+4;break}Xe/=6}return{h:Xe,s:wt,v:Kt}}function k(Se,de,xe){Se=Ce(Se,360)*6,de=Ce(de,100),xe=Ce(xe,100);var Pe=Math.floor(Se),Ze=Se-Pe,Xe=xe*(1-de),wt=xe*(1-Ze*de),Kt=xe*(1-(1-Ze)*de),Pt=Pe%6,zn=[xe,wt,Xe,Xe,Kt,xe][Pt],mt=[Kt,xe,xe,wt,Xe,Xe][Pt],pn=[Xe,Xe,Kt,xe,xe,wt][Pt];return{r:zn*255,g:mt*255,b:pn*255}}function B(Se,de,xe,Pe){var Ze=[Ve(Math.round(Se).toString(16)),Ve(Math.round(de).toString(16)),Ve(Math.round(xe).toString(16))];return Pe&&Ze[0].charAt(0)==Ze[0].charAt(1)&&Ze[1].charAt(0)==Ze[1].charAt(1)&&Ze[2].charAt(0)==Ze[2].charAt(1)?Ze[0].charAt(0)+Ze[1].charAt(0)+Ze[2].charAt(0):Ze.join("")}function P(Se,de,xe,Pe,Ze){var Xe=[Ve(Math.round(Se).toString(16)),Ve(Math.round(de).toString(16)),Ve(Math.round(xe).toString(16)),Ve(Je(Pe))];return Ze&&Xe[0].charAt(0)==Xe[0].charAt(1)&&Xe[1].charAt(0)==Xe[1].charAt(1)&&Xe[2].charAt(0)==Xe[2].charAt(1)&&Xe[3].charAt(0)==Xe[3].charAt(1)?Xe[0].charAt(0)+Xe[1].charAt(0)+Xe[2].charAt(0)+Xe[3].charAt(0):Xe.join("")}function R(Se,de,xe,Pe){var Ze=[Ve(Je(Pe)),Ve(Math.round(Se).toString(16)),Ve(Math.round(de).toString(16)),Ve(Math.round(xe).toString(16))];return Ze.join("")}o.equals=function(Se,de){return!Se||!de?!1:o(Se).toRgbString()==o(de).toRgbString()},o.random=function(){return o.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function H(Se,de){de=de===0?0:de||10;var xe=o(Se).toHsl();return xe.s-=de/100,xe.s=jt(xe.s),o(xe)}function W(Se,de){de=de===0?0:de||10;var xe=o(Se).toHsl();return xe.s+=de/100,xe.s=jt(xe.s),o(xe)}function $(Se){return o(Se).desaturate(100)}function q(Se,de){de=de===0?0:de||10;var xe=o(Se).toHsl();return xe.l+=de/100,xe.l=jt(xe.l),o(xe)}function oe(Se,de){de=de===0?0:de||10;var xe=o(Se).toRgb();return xe.r=Math.max(0,Math.min(255,xe.r-Math.round(255*-(de/100)))),xe.g=Math.max(0,Math.min(255,xe.g-Math.round(255*-(de/100)))),xe.b=Math.max(0,Math.min(255,xe.b-Math.round(255*-(de/100)))),o(xe)}function ne(Se,de){de=de===0?0:de||10;var xe=o(Se).toHsl();return xe.l-=de/100,xe.l=jt(xe.l),o(xe)}function ce(Se,de){var xe=o(Se).toHsl(),Pe=(xe.h+de)%360;return xe.h=Pe<0?360+Pe:Pe,o(xe)}function ae(Se){var de=o(Se).toHsl();return de.h=(de.h+180)%360,o(de)}function ue(Se,de){if(isNaN(de)||de<=0)throw new Error("Argument to polyad must be a positive number");for(var xe=o(Se).toHsl(),Pe=[o(Se)],Ze=360/de,Xe=1;Xe<de;Xe++)Pe.push(o({h:(xe.h+Xe*Ze)%360,s:xe.s,l:xe.l}));return Pe}function ye(Se){var de=o(Se).toHsl(),xe=de.h;return[o(Se),o({h:(xe+72)%360,s:de.s,l:de.l}),o({h:(xe+216)%360,s:de.s,l:de.l})]}function Re(Se,de,xe){de=de||6,xe=xe||30;var Pe=o(Se).toHsl(),Ze=360/xe,Xe=[o(Se)];for(Pe.h=(Pe.h-(Ze*de>>1)+720)%360;--de;)Pe.h=(Pe.h+Ze)%360,Xe.push(o(Pe));return Xe}function Ne(Se,de){de=de||6;for(var xe=o(Se).toHsv(),Pe=xe.h,Ze=xe.s,Xe=xe.v,wt=[],Kt=1/de;de--;)wt.push(o({h:Pe,s:Ze,v:Xe})),Xe=(Xe+Kt)%1;return wt}o.mix=function(Se,de,xe){xe=xe===0?0:xe||50;var Pe=o(Se).toRgb(),Ze=o(de).toRgb(),Xe=xe/100,wt={r:(Ze.r-Pe.r)*Xe+Pe.r,g:(Ze.g-Pe.g)*Xe+Pe.g,b:(Ze.b-Pe.b)*Xe+Pe.b,a:(Ze.a-Pe.a)*Xe+Pe.a};return o(wt)},o.readability=function(Se,de){var xe=o(Se),Pe=o(de);return(Math.max(xe.getLuminance(),Pe.getLuminance())+.05)/(Math.min(xe.getLuminance(),Pe.getLuminance())+.05)},o.isReadable=function(Se,de,xe){var Pe=o.readability(Se,de),Ze,Xe;switch(Xe=!1,Ze=Dt(xe),Ze.level+Ze.size){case"AAsmall":case"AAAlarge":Xe=Pe>=4.5;break;case"AAlarge":Xe=Pe>=3;break;case"AAAsmall":Xe=Pe>=7;break}return Xe},o.mostReadable=function(Se,de,xe){var Pe=null,Ze=0,Xe,wt,Kt,Pt;xe=xe||{},wt=xe.includeFallbackColors,Kt=xe.level,Pt=xe.size;for(var zn=0;zn<de.length;zn++)Xe=o.readability(Se,de[zn]),Xe>Ze&&(Ze=Xe,Pe=o(de[zn]));return o.isReadable(Se,Pe,{level:Kt,size:Pt})||!wt?Pe:(xe.includeFallbackColors=!1,o.mostReadable(Se,["#fff","#000"],xe))};var rt=o.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},ct=o.hexNames=Fe(rt);function Fe(Se){var de={};for(var xe in Se)Se.hasOwnProperty(xe)&&(de[Se[xe]]=xe);return de}function He(Se){return Se=parseFloat(Se),(isNaN(Se)||Se<0||Se>1)&&(Se=1),Se}function Ce(Se,de){Jt(Se)&&(Se="100%");var xe=Nt(Se);return Se=Math.min(de,Math.max(0,parseFloat(Se))),xe&&(Se=parseInt(Se*de,10)/100),Math.abs(Se-de)<1e-6?1:Se%de/parseFloat(de)}function jt(Se){return Math.min(1,Math.max(0,Se))}function Ft(Se){return parseInt(Se,16)}function Jt(Se){return typeof Se=="string"&&Se.indexOf(".")!=-1&&parseFloat(Se)===1}function Nt(Se){return typeof Se=="string"&&Se.indexOf("%")!=-1}function Ve(Se){return Se.length==1?"0"+Se:""+Se}function nt(Se){return Se<=1&&(Se=Se*100+"%"),Se}function Je(Se){return Math.round(parseFloat(Se)*255).toString(16)}function Vt(Se){return Ft(Se)/255}var pt=function(){var Se="[-\\+]?\\d+%?",de="[-\\+]?\\d*\\.\\d+%?",xe="(?:"+de+")|(?:"+Se+")",Pe="[\\s|\\(]+("+xe+")[,|\\s]+("+xe+")[,|\\s]+("+xe+")\\s*\\)?",Ze="[\\s|\\(]+("+xe+")[,|\\s]+("+xe+")[,|\\s]+("+xe+")[,|\\s]+("+xe+")\\s*\\)?";return{CSS_UNIT:new RegExp(xe),rgb:new RegExp("rgb"+Pe),rgba:new RegExp("rgba"+Ze),hsl:new RegExp("hsl"+Pe),hsla:new RegExp("hsla"+Ze),hsv:new RegExp("hsv"+Pe),hsva:new RegExp("hsva"+Ze),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function dt(Se){return!!pt.CSS_UNIT.exec(Se)}function kt(Se){Se=Se.replace(r,"").replace(i,"").toLowerCase();var de=!1;if(rt[Se])Se=rt[Se],de=!0;else if(Se=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var xe;return(xe=pt.rgb.exec(Se))?{r:xe[1],g:xe[2],b:xe[3]}:(xe=pt.rgba.exec(Se))?{r:xe[1],g:xe[2],b:xe[3],a:xe[4]}:(xe=pt.hsl.exec(Se))?{h:xe[1],s:xe[2],l:xe[3]}:(xe=pt.hsla.exec(Se))?{h:xe[1],s:xe[2],l:xe[3],a:xe[4]}:(xe=pt.hsv.exec(Se))?{h:xe[1],s:xe[2],v:xe[3]}:(xe=pt.hsva.exec(Se))?{h:xe[1],s:xe[2],v:xe[3],a:xe[4]}:(xe=pt.hex8.exec(Se))?{r:Ft(xe[1]),g:Ft(xe[2]),b:Ft(xe[3]),a:Vt(xe[4]),format:de?"name":"hex8"}:(xe=pt.hex6.exec(Se))?{r:Ft(xe[1]),g:Ft(xe[2]),b:Ft(xe[3]),format:de?"name":"hex"}:(xe=pt.hex4.exec(Se))?{r:Ft(xe[1]+""+xe[1]),g:Ft(xe[2]+""+xe[2]),b:Ft(xe[3]+""+xe[3]),a:Vt(xe[4]+""+xe[4]),format:de?"name":"hex8"}:(xe=pt.hex3.exec(Se))?{r:Ft(xe[1]+""+xe[1]),g:Ft(xe[2]+""+xe[2]),b:Ft(xe[3]+""+xe[3]),format:de?"name":"hex"}:!1}function Dt(Se){var de,xe;return Se=Se||{level:"AA",size:"small"},de=(Se.level||"AA").toUpperCase(),xe=(Se.size||"small").toLowerCase(),de!=="AA"&&de!=="AAA"&&(de="AA"),xe!=="small"&&xe!=="large"&&(xe="small"),{level:de,size:xe}}return o})})(DN);var NMe=DN.exports;Object.defineProperty(fA,"__esModule",{value:!0});fA.isvalidColorString=fA.red=fA.getContrastingColor=fA.isValidHex=fA.toState=fA.simpleCheckForValidColor=void 0;var GMe=WMe,QMe=UN(GMe),$Me=NMe,s4=UN($Me);function UN(e){return e&&e.__esModule?e:{default:e}}fA.simpleCheckForValidColor=function(n){var t=["r","g","b","a","h","s","l","v"],r=0,i=0;return(0,QMe.default)(t,function(o){if(n[o]&&(r+=1,isNaN(n[o])||(i+=1),o==="s"||o==="l")){var s=/^\d+%$/;s.test(n[o])&&(i+=1)}}),r===i?n:!1};var YMe=fA.toState=function(n,t){var r=n.hex?(0,s4.default)(n.hex):(0,s4.default)(n),i=r.toHsl(),o=r.toHsv(),s=r.toRgb(),a=r.toHex();i.s===0&&(i.h=t||0,o.h=t||0);var f=a==="000000"&&s.a===0;return{hsl:i,hex:f?"transparent":"#"+a,rgb:s,hsv:o,oldHue:n.h||t||i.h,source:n.source}};fA.isValidHex=function(n){if(n==="transparent")return!0;var t=String(n).charAt(0)==="#"?1:0;return n.length!==4+t&&n.length<7+t&&(0,s4.default)(n).isValid()};fA.getContrastingColor=function(n){if(!n)return"#fff";var t=YMe(n);if(t.hex==="transparent")return"rgba(0,0,0,0.4)";var r=(t.rgb.r*299+t.rgb.g*587+t.rgb.b*114)/1e3;return r>=128?"#000":"#fff"};fA.red={hsl:{a:1,h:0,l:.5,s:1},hex:"#ff0000",rgb:{r:255,g:0,b:0,a:1},hsv:{h:0,s:1,v:1,a:1}};fA.isvalidColorString=function(n,t){var r=n.replace("°","");return(0,s4.default)(t+" ("+r+")")._ok};Object.defineProperty(yb,"__esModule",{value:!0});yb.ColorWrap=void 0;var Jv=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},qMe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),eO=kr,VMe=RN(eO),HMe=FN,ZMe=RN(HMe),XMe=fA,hg=JMe(XMe);function JMe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function RN(e){return e&&e.__esModule?e:{default:e}}function eSe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function tSe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function nSe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var rSe=yb.ColorWrap=function(n){var t=function(r){nSe(i,r);function i(o){eSe(this,i);var s=tSe(this,(i.__proto__||Object.getPrototypeOf(i)).call(this));return s.handleChange=function(a,f){var g=hg.simpleCheckForValidColor(a);if(g){var x=hg.toState(a,a.h||s.state.oldHue);s.setState(x),s.props.onChangeComplete&&s.debounce(s.props.onChangeComplete,x,f),s.props.onChange&&s.props.onChange(x,f)}},s.handleSwatchHover=function(a,f){var g=hg.simpleCheckForValidColor(a);if(g){var x=hg.toState(a,a.h||s.state.oldHue);s.props.onSwatchHover&&s.props.onSwatchHover(x,f)}},s.state=Jv({},hg.toState(o.color,0)),s.debounce=(0,ZMe.default)(function(a,f,g){a(f,g)},100),s}return qMe(i,[{key:"render",value:function(){var s={};return this.props.onSwatchHover&&(s.onSwatchHover=this.handleSwatchHover),VMe.default.createElement(n,Jv({},this.props,this.state,{onChange:this.handleChange},s))}}],[{key:"getDerivedStateFromProps",value:function(s,a){return Jv({},hg.toState(s.color,a.oldHue))}}]),i}(eO.PureComponent||eO.Component);return t.propTypes=Jv({},n.propTypes),t.defaultProps=Jv({},n.defaultProps,{color:{h:250,s:.5,l:.2,a:1}}),t};yb.default=rSe;var vb={},Z5={};Object.defineProperty(Z5,"__esModule",{value:!0});Z5.handleFocus=void 0;var iSe=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},oSe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),aSe=kr,rS=sSe(aSe);function sSe(e){return e&&e.__esModule?e:{default:e}}function lSe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function nP(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function uSe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}Z5.handleFocus=function(n){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"span";return function(r){uSe(i,r);function i(){var o,s,a,f;lSe(this,i);for(var g=arguments.length,x=Array(g),k=0;k<g;k++)x[k]=arguments[k];return f=(s=(a=nP(this,(o=i.__proto__||Object.getPrototypeOf(i)).call.apply(o,[this].concat(x))),a),a.state={focus:!1},a.handleFocus=function(){return a.setState({focus:!0})},a.handleBlur=function(){return a.setState({focus:!1})},s),nP(a,f)}return oSe(i,[{key:"render",value:function(){return rS.default.createElement(t,{onFocus:this.handleFocus,onBlur:this.handleBlur},rS.default.createElement(n,iSe({},this.props,this.state)))}}]),i}(rS.default.Component)};Object.defineProperty(vb,"__esModule",{value:!0});vb.Swatch=void 0;var rP=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},ASe=kr,iP=W8(ASe),cSe=Ps,dSe=W8(cSe),hSe=Z5,fSe=E1,pSe=W8(fSe);function W8(e){return e&&e.__esModule?e:{default:e}}var mSe=13,gSe=vb.Swatch=function(n){var t=n.color,r=n.style,i=n.onClick,o=i===void 0?function(){}:i,s=n.onHover,a=n.title,f=a===void 0?t:a,g=n.children,x=n.focus,k=n.focusStyle,B=k===void 0?{}:k,P=t==="transparent",R=(0,dSe.default)({default:{swatch:rP({background:t,height:"100%",width:"100%",cursor:"pointer",position:"relative",outline:"none"},r,x?B:{})}}),H=function(ne){return o(t,ne)},W=function(ne){return ne.keyCode===mSe&&o(t,ne)},$=function(ne){return s(t,ne)},q={};return s&&(q.onMouseOver=$),iP.default.createElement("div",rP({style:R.swatch,onClick:H,title:f,tabIndex:0,onKeyDown:W},q),g,P&&iP.default.createElement(pSe.default,{borderRadius:R.swatch.borderRadius,boxShadow:"inset 0 0 0 1px rgba(0,0,0,0.1)"}))};vb.default=(0,hSe.handleFocus)(gSe);(function(e){Object.defineProperty(e,"__esModule",{value:!0});var n=hb;Object.defineProperty(e,"Alpha",{enumerable:!0,get:function(){return g(n).default}});var t=E1;Object.defineProperty(e,"Checkboard",{enumerable:!0,get:function(){return g(t).default}});var r=fb;Object.defineProperty(e,"EditableInput",{enumerable:!0,get:function(){return g(r).default}});var i=pb;Object.defineProperty(e,"Hue",{enumerable:!0,get:function(){return g(i).default}});var o=mb;Object.defineProperty(e,"Raised",{enumerable:!0,get:function(){return g(o).default}});var s=gb;Object.defineProperty(e,"Saturation",{enumerable:!0,get:function(){return g(s).default}});var a=yb;Object.defineProperty(e,"ColorWrap",{enumerable:!0,get:function(){return g(a).default}});var f=vb;Object.defineProperty(e,"Swatch",{enumerable:!0,get:function(){return g(f).default}});function g(x){return x&&x.__esModule?x:{default:x}}})(F8);var Cb={};function ySe(e){return e===void 0}var vSe=ySe,N8={};Object.defineProperty(N8,"__esModule",{value:!0});var oP=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},CSe=kr,aP=_Se(CSe);function _Se(e){return e&&e.__esModule?e:{default:e}}function bSe(e,n){var t={};for(var r in e)n.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}var Yx=24;N8.default=function(e){var n=e.fill,t=n===void 0?"currentColor":n,r=e.width,i=r===void 0?Yx:r,o=e.height,s=o===void 0?Yx:o,a=e.style,f=a===void 0?{}:a,g=bSe(e,["fill","width","height","style"]);return aP.default.createElement("svg",oP({viewBox:"0 0 "+Yx+" "+Yx,style:oP({fill:t,width:i,height:s},f)},g),aP.default.createElement("path",{d:"M12,18.17L8.83,15L7.42,16.41L12,21L16.59,16.41L15.17,15M12,5.83L15.17,9L16.58,7.59L12,3L7.41,7.59L8.83,9L12,5.83Z"}))};Object.defineProperty(Cb,"__esModule",{value:!0});Cb.ChromeFields=void 0;var xSe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),wSe=kr,La=X5(wSe),MSe=Ps,SSe=X5(MSe),ESe=fA,OSe=TSe(ESe),BSe=vSe,sP=X5(BSe),ep=F8,kSe=N8,ISe=X5(kSe);function TSe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function X5(e){return e&&e.__esModule?e:{default:e}}function KSe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function PSe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function FSe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var LN=Cb.ChromeFields=function(e){FSe(n,e);function n(t){KSe(this,n);var r=PSe(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return r.toggleViews=function(){r.state.view==="hex"?r.setState({view:"rgb"}):r.state.view==="rgb"?r.setState({view:"hsl"}):r.state.view==="hsl"&&(r.props.hsl.a===1?r.setState({view:"hex"}):r.setState({view:"rgb"}))},r.handleChange=function(i,o){i.hex?OSe.isValidHex(i.hex)&&r.props.onChange({hex:i.hex,source:"hex"},o):i.r||i.g||i.b?r.props.onChange({r:i.r||r.props.rgb.r,g:i.g||r.props.rgb.g,b:i.b||r.props.rgb.b,source:"rgb"},o):i.a?(i.a<0?i.a=0:i.a>1&&(i.a=1),r.props.onChange({h:r.props.hsl.h,s:r.props.hsl.s,l:r.props.hsl.l,a:Math.round(i.a*100)/100,source:"rgb"},o)):(i.h||i.s||i.l)&&(typeof i.s=="string"&&i.s.includes("%")&&(i.s=i.s.replace("%","")),typeof i.l=="string"&&i.l.includes("%")&&(i.l=i.l.replace("%","")),i.s==1?i.s=.01:i.l==1&&(i.l=.01),r.props.onChange({h:i.h||r.props.hsl.h,s:Number((0,sP.default)(i.s)?r.props.hsl.s:i.s),l:Number((0,sP.default)(i.l)?r.props.hsl.l:i.l),source:"hsl"},o))},r.showHighlight=function(i){i.currentTarget.style.background="#eee"},r.hideHighlight=function(i){i.currentTarget.style.background="transparent"},t.hsl.a!==1&&t.view==="hex"?r.state={view:"rgb"}:r.state={view:t.view},r}return xSe(n,[{key:"render",value:function(){var r=this,i=(0,SSe.default)({default:{wrap:{paddingTop:"16px",display:"flex"},fields:{flex:"1",display:"flex",marginLeft:"-6px"},field:{paddingLeft:"6px",width:"100%"},alpha:{paddingLeft:"6px",width:"100%"},toggle:{width:"32px",textAlign:"right",position:"relative"},icon:{marginRight:"-4px",marginTop:"12px",cursor:"pointer",position:"relative"},iconHighlight:{position:"absolute",width:"24px",height:"28px",background:"#eee",borderRadius:"4px",top:"10px",left:"12px",display:"none"},input:{fontSize:"11px",color:"#333",width:"100%",borderRadius:"2px",border:"none",boxShadow:"inset 0 0 0 1px #dadada",height:"21px",textAlign:"center"},label:{textTransform:"uppercase",fontSize:"11px",lineHeight:"11px",color:"#969696",textAlign:"center",display:"block",marginTop:"12px"},svg:{fill:"#333",width:"24px",height:"24px",border:"1px transparent solid",borderRadius:"5px"}},disableAlpha:{alpha:{display:"none"}}},this.props,this.state),o=void 0;return this.state.view==="hex"?o=La.default.createElement("div",{style:i.fields,className:"flexbox-fix"},La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"hex",value:this.props.hex,onChange:this.handleChange}))):this.state.view==="rgb"?o=La.default.createElement("div",{style:i.fields,className:"flexbox-fix"},La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"r",value:this.props.rgb.r,onChange:this.handleChange})),La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"g",value:this.props.rgb.g,onChange:this.handleChange})),La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"b",value:this.props.rgb.b,onChange:this.handleChange})),La.default.createElement("div",{style:i.alpha},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"a",value:this.props.rgb.a,arrowOffset:.01,onChange:this.handleChange}))):this.state.view==="hsl"&&(o=La.default.createElement("div",{style:i.fields,className:"flexbox-fix"},La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"h",value:Math.round(this.props.hsl.h),onChange:this.handleChange})),La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"s",value:Math.round(this.props.hsl.s*100)+"%",onChange:this.handleChange})),La.default.createElement("div",{style:i.field},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"l",value:Math.round(this.props.hsl.l*100)+"%",onChange:this.handleChange})),La.default.createElement("div",{style:i.alpha},La.default.createElement(ep.EditableInput,{style:{input:i.input,label:i.label},label:"a",value:this.props.hsl.a,arrowOffset:.01,onChange:this.handleChange})))),La.default.createElement("div",{style:i.wrap,className:"flexbox-fix"},o,La.default.createElement("div",{style:i.toggle},La.default.createElement("div",{style:i.icon,onClick:this.toggleViews,ref:function(a){return r.icon=a}},La.default.createElement(ISe.default,{style:i.svg,onMouseOver:this.showHighlight,onMouseEnter:this.showHighlight,onMouseOut:this.hideHighlight}))))}}],[{key:"getDerivedStateFromProps",value:function(r,i){return r.hsl.a!==1&&i.view==="hex"?{view:"rgb"}:null}}]),n}(La.default.Component);LN.defaultProps={view:"hex"};Cb.default=LN;var _b={};Object.defineProperty(_b,"__esModule",{value:!0});_b.ChromePointer=void 0;var DSe=kr,USe=zN(DSe),RSe=Ps,LSe=zN(RSe);function zN(e){return e&&e.__esModule?e:{default:e}}var zSe=_b.ChromePointer=function(){var n=(0,LSe.default)({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",transform:"translate(-6px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return USe.default.createElement("div",{style:n.picker})};_b.default=zSe;var bb={};Object.defineProperty(bb,"__esModule",{value:!0});bb.ChromePointerCircle=void 0;var jSe=kr,WSe=jN(jSe),NSe=Ps,GSe=jN(NSe);function jN(e){return e&&e.__esModule?e:{default:e}}var QSe=bb.ChromePointerCircle=function(){var n=(0,GSe.default)({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}}});return WSe.default.createElement("div",{style:n.picker})};bb.default=QSe;Object.defineProperty(U5,"__esModule",{value:!0});U5.Chrome=void 0;var $Se=kr,hA=O1($Se),YSe=ph,fg=O1(YSe),qSe=Ps,VSe=O1(qSe),HSe=ON,ZSe=O1(HSe),gC=F8,XSe=Cb,JSe=O1(XSe),e6e=_b,lP=O1(e6e),t6e=bb,n6e=O1(t6e);function O1(e){return e&&e.__esModule?e:{default:e}}var G8=U5.Chrome=function(n){var t=n.width,r=n.onChange,i=n.disableAlpha,o=n.rgb,s=n.hsl,a=n.hsv,f=n.hex,g=n.renderers,x=n.styles,k=x===void 0?{}:x,B=n.className,P=B===void 0?"":B,R=n.defaultView,H=(0,VSe.default)((0,ZSe.default)({default:{picker:{width:t,background:"#fff",borderRadius:"2px",boxShadow:"0 0 2px rgba(0,0,0,.3), 0 4px 8px rgba(0,0,0,.3)",boxSizing:"initial",fontFamily:"Menlo"},saturation:{width:"100%",paddingBottom:"55%",position:"relative",borderRadius:"2px 2px 0 0",overflow:"hidden"},Saturation:{radius:"2px 2px 0 0"},body:{padding:"16px 16px 12px"},controls:{display:"flex"},color:{width:"32px"},swatch:{marginTop:"6px",width:"16px",height:"16px",borderRadius:"8px",position:"relative",overflow:"hidden"},active:{absolute:"0px 0px 0px 0px",borderRadius:"8px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.1)",background:"rgba("+o.r+", "+o.g+", "+o.b+", "+o.a+")",zIndex:"2"},toggles:{flex:"1"},hue:{height:"10px",position:"relative",marginBottom:"8px"},Hue:{radius:"2px"},alpha:{height:"10px",position:"relative"},Alpha:{radius:"2px"}},disableAlpha:{color:{width:"22px"},alpha:{display:"none"},hue:{marginBottom:"0px"},swatch:{width:"10px",height:"10px",marginTop:"0px"}}},k),{disableAlpha:i});return hA.default.createElement("div",{style:H.picker,className:"chrome-picker "+P},hA.default.createElement("div",{style:H.saturation},hA.default.createElement(gC.Saturation,{style:H.Saturation,hsl:s,hsv:a,pointer:n6e.default,onChange:r})),hA.default.createElement("div",{style:H.body},hA.default.createElement("div",{style:H.controls,className:"flexbox-fix"},hA.default.createElement("div",{style:H.color},hA.default.createElement("div",{style:H.swatch},hA.default.createElement("div",{style:H.active}),hA.default.createElement(gC.Checkboard,{renderers:g}))),hA.default.createElement("div",{style:H.toggles},hA.default.createElement("div",{style:H.hue},hA.default.createElement(gC.Hue,{style:H.Hue,hsl:s,pointer:lP.default,onChange:r})),hA.default.createElement("div",{style:H.alpha},hA.default.createElement(gC.Alpha,{style:H.Alpha,rgb:o,hsl:s,pointer:lP.default,renderers:g,onChange:r})))),hA.default.createElement(JSe.default,{rgb:o,hsl:s,hex:f,view:R,onChange:r,disableAlpha:i})))};G8.propTypes={width:fg.default.oneOfType([fg.default.string,fg.default.number]),disableAlpha:fg.default.bool,styles:fg.default.object,defaultView:fg.default.oneOf(["hex","rgb","hsl"])};G8.defaultProps={width:225,disableAlpha:!1,styles:{}};var r6e=U5.default=(0,gC.ColorWrap)(G8);function hi(){var e="/home/runner/work/maputnik/maputnik/src/components/InputColor.tsx",n="cb6d03ea084207ffce2f89af246bc26074c13af7",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputColor.tsx",statementMap:{0:{start:{line:7,column:14},end:{line:7,column:23}},1:{start:{line:8,column:2},end:{line:8,column:56}},2:{start:{line:11,column:10},end:{line:13,column:3}},3:{start:{line:14,column:15},end:{line:14,column:19}},4:{start:{line:16,column:4},end:{line:16,column:17}},5:{start:{line:17,column:4},end:{line:17,column:75}},6:{start:{line:20,column:4},end:{line:20,column:27}},7:{start:{line:25,column:21},end:{line:39,column:3}},8:{start:{line:26,column:17},end:{line:26,column:32}},9:{start:{line:27,column:4},end:{line:38,column:5}},10:{start:{line:28,column:18},end:{line:28,column:46}},11:{start:{line:29,column:6},end:{line:32,column:8}},12:{start:{line:34,column:6},end:{line:37,column:8}},13:{start:{line:40,column:17},end:{line:42,column:3}},14:{start:{line:41,column:4},end:{line:41,column:62}},15:{start:{line:44,column:4},end:{line:49,column:5}},16:{start:{line:45,column:6},end:{line:45,column:43}},17:{start:{line:47,column:6},end:{line:47,column:49}},18:{start:{line:48,column:6},end:{line:48,column:39}},19:{start:{line:52,column:4},end:{line:52,column:47}},20:{start:{line:55,column:19},end:{line:55,column:42}},21:{start:{line:56,column:25},end:{line:56,column:44}},22:{start:{line:57,column:31},end:{line:63,column:5}},23:{start:{line:64,column:35},end:{line:99,column:5}},24:{start:{line:79,column:31},end:{line:79,column:67}},25:{start:{line:100,column:24},end:{line:102,column:5}},26:{start:{line:103,column:4},end:{line:122,column:9}},27:{start:{line:113,column:26},end:{line:113,column:49}},28:{start:{line:119,column:27},end:{line:119,column:56}}},fnMap:{0:{name:"formatColor",decl:{start:{line:6,column:9},end:{line:6,column:20}},loc:{start:{line:6,column:28},end:{line:9,column:1}},line:6},1:{name:"(anonymous_1)",decl:{start:{line:15,column:2},end:{line:15,column:3}},loc:{start:{line:15,column:21},end:{line:18,column:3}},line:15},2:{name:"(anonymous_2)",decl:{start:{line:19,column:2},end:{line:19,column:3}},loc:{start:{line:19,column:21},end:{line:21,column:3}},line:19},3:{name:"(anonymous_3)",decl:{start:{line:25,column:21},end:{line:25,column:22}},loc:{start:{line:25,column:27},end:{line:39,column:3}},line:25},4:{name:"(anonymous_4)",decl:{start:{line:40,column:17},end:{line:40,column:18}},loc:{start:{line:40,column:23},end:{line:42,column:3}},line:40},5:{name:"(anonymous_5)",decl:{start:{line:43,column:2},end:{line:43,column:3}},loc:{start:{line:43,column:14},end:{line:50,column:3}},line:43},6:{name:"(anonymous_6)",decl:{start:{line:51,column:2},end:{line:51,column:3}},loc:{start:{line:51,column:14},end:{line:53,column:3}},line:51},7:{name:"(anonymous_7)",decl:{start:{line:54,column:2},end:{line:54,column:3}},loc:{start:{line:54,column:11},end:{line:123,column:3}},line:54},8:{name:"(anonymous_8)",decl:{start:{line:79,column:24},end:{line:79,column:25}},loc:{start:{line:79,column:31},end:{line:79,column:67}},line:79},9:{name:"(anonymous_9)",decl:{start:{line:113,column:15},end:{line:113,column:16}},loc:{start:{line:113,column:26},end:{line:113,column:49}},line:113},10:{name:"(anonymous_10)",decl:{start:{line:119,column:20},end:{line:119,column:21}},loc:{start:{line:119,column:27},end:{line:119,column:56}},line:119}},branchMap:{0:{loc:{start:{line:27,column:4},end:{line:38,column:5}},type:"if",locations:[{start:{line:27,column:4},end:{line:38,column:5}},{start:{line:33,column:11},end:{line:38,column:5}}],line:27},1:{loc:{start:{line:52,column:24},end:{line:52,column:45}},type:"cond-expr",locations:[{start:{line:52,column:35},end:{line:52,column:41}},{start:{line:52,column:44},end:{line:52,column:45}}],line:52},2:{loc:{start:{line:104,column:6},end:{line:104,column:39}},type:"binary-expr",locations:[{start:{line:104,column:6},end:{line:104,column:29}},{start:{line:104,column:33},end:{line:104,column:39}}],line:104},3:{loc:{start:{line:118,column:17},end:{line:118,column:57}},type:"cond-expr",locations:[{start:{line:118,column:36},end:{line:118,column:52}},{start:{line:118,column:55},end:{line:118,column:57}}],line:118}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputColor.tsx"],names:[],mappings:"AAsFmB,SAQb,KARa;AAtFnB,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,kBAAkB;AAEzB,OAAO,YAAY;AAEnB,SAAS,YAAY,OAA4B;AAC/C,QAAM,MAAM,MAAM;AAClB,SAAO,QAAQ,IAAI,CAAC,KAAK,IAAI,CAAC,KAAK,IAAI,CAAC,KAAK,IAAI,CAAC;AACpD;AAaA,qBAAqB,mBAAmB,MAAM,UAA2B;AAAA,EACvE,QAAQ;AAAA,IACN,cAAc;AAAA,EAChB;AAAA,EACA,aAAsC;AAAA,EAEtC,YAAa,OAAwB;AACnC,UAAM,KAAK;AACX,SAAK,kBAAkB,OAAO,SAAS,KAAK,iBAAiB,MAAK,EAAE;AAAA,EACtE;AAAA,EAEA,gBAAgB,GAAW;AACzB,SAAK,MAAM,SAAS,CAAC;AAAA,EACvB;AAAA;AAAA;AAAA;AAAA,EAKA,mBAAmB,MAAM;AACvB,UAAM,OAAO,KAAK;AAClB,QAAG,MAAM;AACP,YAAM,MAAM,KAAK,sBAAsB;AACvC,aAAO;AAAA,QACL,KAAK,IAAI;AAAA,QACT,MAAM,IAAI,OAAO;AAAA,MACnB;AAAA,IACF,OAAO;AACL,aAAO;AAAA,QACL,KAAK;AAAA,QACL,MAAM;AAAA,MACR;AAAA,IACF;AAAA,EACF;AAAA,EAEA,eAAe,MAAM;AACnB,SAAK,SAAS,EAAE,cAAc,CAAC,KAAK,MAAM,aAAa,CAAC;AAAA,EAC1D;AAAA,EAEA,IAAI,QAAQ;AAEV,QAAI;AACF,aAAO,MAAM,KAAK,MAAM,KAAK,EAAE,IAAI;AAAA,IACrC,SACM,KAAK;AACT,cAAQ,KAAK,yBAAyB,GAAG;AACzC,aAAO,MAAM,kBAAkB;AAAA,IACjC;AAAA,EACF;AAAA,EAEA,SAAU,GAAW;AACnB,SAAK,MAAM,SAAS,MAAM,KAAK,SAAY,CAAC;AAAA,EAC9C;AAAA,EAEA,SAAS;AACP,UAAM,SAAS,KAAK,iBAAiB;AACrC,UAAM,eAAe,KAAK,MAAM,OAAO;AACvC,UAAM,qBAAqB;AAAA,MACzB,GAAG,aAAa;AAAA,MAChB,GAAG,aAAa;AAAA,MAChB,GAAG,aAAa;AAAA;AAAA,MAEhB,GAAG,aAAa;AAAA,IAClB;AAEA,UAAM,SAAS;AAAA,MAAC;AAAA;AAAA,QACd,WAAU;AAAA,QACV,OAAO;AAAA,UACL,UAAU;AAAA,UACV,QAAQ;AAAA,UACR,MAAM,OAAO;AAAA,UACb,KAAK,OAAO;AAAA,QACd;AAAA,QACA;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,UAAU,OAAK,KAAK,gBAAgB,YAAY,CAAC,CAAC;AAAA;AAAA,UACpD;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,SAAS,KAAK;AAAA,cACd,OAAO;AAAA,gBACL,QAAQ;AAAA,gBACR,UAAU;AAAA,gBACV,KAAK;AAAA,gBACL,OAAO;AAAA,gBACP,QAAQ;AAAA,gBACR,MAAM;AAAA,cACR;AAAA;AAAA,UACF;AAAA;AAAA;AAAA,IACF;AAEA,UAAM,cAAc;AAAA,MAClB,iBAAiB,KAAK,MAAM;AAAA,IAC9B;AAEA,WAAO,qBAAC,SAAI,WAAU,0BACnB;AAAA,WAAK,MAAM,gBAAgB;AAAA,MAC5B,oBAAC,SAAI,WAAU,yBAAwB,OAAO,aAAa;AAAA,MAC3D;AAAA,QAAC;AAAA;AAAA,UACC,cAAY,KAAK,MAAM,YAAY;AAAA,UACnC,YAAW;AAAA,UACX,cAAa;AAAA,UACb,WAAU;AAAA,UACV,KAAK,CAAC,UAAU,KAAK,aAAa;AAAA,UAClC,SAAS,KAAK;AAAA,UACd,OAAO,KAAK,MAAM;AAAA,UAClB,MAAM,KAAK,MAAM;AAAA,UACjB,aAAa,KAAK,MAAM;AAAA,UACxB,OAAO,KAAK,MAAM,QAAQ,KAAK,MAAM,QAAQ;AAAA,UAC7C,UAAU,CAAC,MAAM,KAAK,SAAS,EAAE,OAAO,KAAK;AAAA;AAAA,MAC/C;AAAA,OACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"cb6d03ea084207ffce2f89af246bc26074c13af7"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return hi=function(){return s},s}hi();function i6e(e){hi().f[0]++;const n=(hi().s[0]++,e.rgb);return hi().s[1]++,`rgba(${n.r}, ${n.g}, ${n.b}, ${n.a})`}class WN extends bn.Component{constructor(t){hi().f[1]++,hi().s[4]++;super(t);nn(this,"state",(hi().s[2]++,{pickerOpened:!1}));nn(this,"colorInput",(hi().s[3]++,null));nn(this,"calcPickerOffset",(hi().s[7]++,()=>{hi().f[3]++;const t=(hi().s[8]++,this.colorInput);if(hi().s[9]++,t){hi().b[0][0]++;const r=(hi().s[10]++,t.getBoundingClientRect());return hi().s[11]++,{top:r.top,left:r.left+196}}else return hi().b[0][1]++,hi().s[12]++,{top:160,left:555}}));nn(this,"togglePicker",(hi().s[13]++,()=>{hi().f[4]++,hi().s[14]++,this.setState({pickerOpened:!this.state.pickerOpened})}));hi().s[5]++,this.onChangeNoCheck=p6.throttle(this.onChangeNoCheck,1e3/30)}onChangeNoCheck(t){hi().f[2]++,hi().s[6]++,this.props.onChange(t)}get color(){hi().f[5]++,hi().s[15]++;try{return hi().s[16]++,D6(this.props.value).rgb()}catch(t){return hi().s[17]++,console.warn("Error parsing color: ",t),hi().s[18]++,D6("rgb(255,255,255)")}}onChange(t){hi().f[6]++,hi().s[19]++,this.props.onChange(t===""?(hi().b[1][0]++,void 0):(hi().b[1][1]++,t))}render(){hi().f[7]++;const t=(hi().s[20]++,this.calcPickerOffset()),r=(hi().s[21]++,this.color.object()),i=(hi().s[22]++,{r:r.r,g:r.g,b:r.b,a:r.alpha}),o=(hi().s[23]++,N.jsxs("div",{className:"maputnik-color-picker-offset",style:{position:"fixed",zIndex:1,left:t.left,top:t.top},children:[N.jsx(r6e,{color:i,onChange:a=>(hi().f[8]++,hi().s[24]++,this.onChangeNoCheck(i6e(a)))}),N.jsx("div",{className:"maputnik-color-picker-offset",onClick:this.togglePicker,style:{zIndex:-1,position:"fixed",top:"0px",right:"0px",bottom:"0px",left:"0px"}})]})),s=(hi().s[25]++,{backgroundColor:this.props.value});return hi().s[26]++,N.jsxs("div",{className:"maputnik-color-wrapper",children:[(hi().b[2][0]++,this.state.pickerOpened&&(hi().b[2][1]++,o)),N.jsx("div",{className:"maputnik-color-swatch",style:s}),N.jsx("input",{"aria-label":this.props["aria-label"],spellCheck:"false",autoComplete:"off",className:"maputnik-color",ref:a=>(hi().f[9]++,hi().s[27]++,this.colorInput=a),onClick:this.togglePicker,style:this.props.style,name:this.props.name,placeholder:this.props.default,value:this.props.value?(hi().b[3][0]++,this.props.value):(hi().b[3][1]++,""),onChange:a=>(hi().f[10]++,hi().s[28]++,this.onChange(a.target.value))})]})}}function Rt(){var e="/home/runner/work/maputnik/maputnik/src/components/InputNumber.tsx",n="6f326a25e01ec46339f6b8716575d23b39d5290d",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputNumber.tsx",statementMap:{0:{start:{line:5,column:24},end:{line:7,column:3}},1:{start:{line:8,column:19},end:{line:8,column:24}},2:{start:{line:10,column:4},end:{line:10,column:17}},3:{start:{line:11,column:4},end:{line:16,column:6}},4:{start:{line:19,column:4},end:{line:24,column:5}},5:{start:{line:20,column:6},end:{line:23,column:8}},6:{start:{line:25,column:4},end:{line:25,column:16}},7:{start:{line:28,column:18},end:{line:28,column:77}},8:{start:{line:29,column:23},end:{line:29,column:49}},9:{start:{line:30,column:4},end:{line:40,column:5}},10:{start:{line:31,column:6},end:{line:32,column:35}},11:{start:{line:32,column:8},end:{line:32,column:35}},12:{start:{line:33,column:6},end:{line:35,column:9}},13:{start:{line:36,column:11},end:{line:40,column:5}},14:{start:{line:37,column:6},end:{line:39,column:9}},15:{start:{line:41,column:4},end:{line:43,column:7}},16:{start:{line:46,column:4},end:{line:48,column:5}},17:{start:{line:47,column:6},end:{line:47,column:18}},18:{start:{line:49,column:18},end:{line:49,column:20}},19:{start:{line:50,column:4},end:{line:52,column:5}},20:{start:{line:51,column:6},end:{line:51,column:19}},21:{start:{line:53,column:4},end:{line:55,column:5}},22:{start:{line:54,column:6},end:{line:54,column:19}},23:{start:{line:56,column:4},end:{line:58,column:5}},24:{start:{line:57,column:6},end:{line:57,column:19}},25:{start:{line:59,column:4},end:{line:59,column:16}},26:{start:{line:61,column:15},end:{line:75,column:3}},27:{start:{line:62,column:4},end:{line:62,column:38}},28:{start:{line:63,column:4},end:{line:65,column:5}},29:{start:{line:64,column:6},end:{line:64,column:13}},30:{start:{line:66,column:4},end:{line:74,column:5}},31:{start:{line:67,column:6},end:{line:73,column:7}},32:{start:{line:68,column:8},end:{line:68,column:43}},33:{start:{line:69,column:8},end:{line:69,column:56}},34:{start:{line:71,column:8},end:{line:71,column:33}},35:{start:{line:72,column:8},end:{line:72,column:46}},36:{start:{line:76,column:18},end:{line:102,column:3}},37:{start:{line:77,column:16},end:{line:77,column:42}},38:{start:{line:78,column:17},end:{line:78,column:37}},39:{start:{line:79,column:21},end:{line:79,column:26}},40:{start:{line:80,column:4},end:{line:96,column:5}},41:{start:{line:81,column:19},end:{line:81,column:31}},42:{start:{line:82,column:6},end:{line:95,column:7}},43:{start:{line:83,column:8},end:{line:87,column:9}},44:{start:{line:84,column:10},end:{line:84,column:42}},45:{start:{line:86,column:10},end:{line:86,column:42}},46:{start:{line:88,column:8},end:{line:88,column:27}},47:{start:{line:90,column:8},end:{line:94,column:9}},48:{start:{line:91,column:10},end:{line:91,column:31}},49:{start:{line:93,column:10},end:{line:93,column:40}},50:{start:{line:97,column:4},end:{line:97,column:32}},51:{start:{line:98,column:4},end:{line:98,column:70}},52:{start:{line:99,column:4},end:{line:99,column:41}},53:{start:{line:100,column:4},end:{line:101,column:33}},54:{start:{line:101,column:6},end:{line:101,column:33}},55:{start:{line:104,column:4},end:{line:187,column:5}},56:{start:{line:105,column:20},end:{line:105,column:81}},57:{start:{line:106,column:27},end:{line:106,column:82}},58:{start:{line:108,column:6},end:{line:112,column:7}},59:{start:{line:109,column:8},end:{line:109,column:38}},60:{start:{line:111,column:8},end:{line:111,column:27}},61:{start:{line:113,column:6},end:{line:167,column:11}},62:{start:{line:126,column:14},end:{line:126,column:41}},63:{start:{line:129,column:14},end:{line:129,column:67}},64:{start:{line:132,column:14},end:{line:132,column:69}},65:{start:{line:135,column:14},end:{line:139,column:17}},66:{start:{line:154,column:14},end:{line:154,column:47}},67:{start:{line:157,column:14},end:{line:157,column:47}},68:{start:{line:160,column:14},end:{line:160,column:48}},69:{start:{line:161,column:14},end:{line:161,column:32}},70:{start:{line:169,column:20},end:{line:169,column:81}},71:{start:{line:170,column:6},end:{line:186,column:8}},72:{start:{line:178,column:27},end:{line:178,column:59}},73:{start:{line:180,column:12},end:{line:180,column:45}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:21},end:{line:17,column:3}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:48},end:{line:26,column:3}},line:18},2:{name:"(anonymous_2)",decl:{start:{line:27,column:2},end:{line:27,column:3}},loc:{start:{line:27,column:24},end:{line:44,column:3}},line:27},3:{name:"(anonymous_3)",decl:{start:{line:45,column:2},end:{line:45,column:3}},loc:{start:{line:45,column:13},end:{line:60,column:3}},line:45},4:{name:"(anonymous_4)",decl:{start:{line:61,column:15},end:{line:61,column:16}},loc:{start:{line:61,column:21},end:{line:75,column:3}},line:61},5:{name:"(anonymous_5)",decl:{start:{line:76,column:18},end:{line:76,column:19}},loc:{start:{line:76,column:25},end:{line:102,column:3}},line:76},6:{name:"(anonymous_6)",decl:{start:{line:103,column:2},end:{line:103,column:3}},loc:{start:{line:103,column:11},end:{line:188,column:3}},line:103},7:{name:"(anonymous_7)",decl:{start:{line:125,column:23},end:{line:125,column:24}},loc:{start:{line:125,column:29},end:{line:127,column:13}},line:125},8:{name:"(anonymous_8)",decl:{start:{line:128,column:27},end:{line:128,column:28}},loc:{start:{line:128,column:33},end:{line:130,column:13}},line:128},9:{name:"(anonymous_9)",decl:{start:{line:131,column:25},end:{line:131,column:26}},loc:{start:{line:131,column:31},end:{line:133,column:13}},line:131},10:{name:"(anonymous_10)",decl:{start:{line:134,column:20},end:{line:134,column:21}},loc:{start:{line:134,column:26},end:{line:140,column:13}},line:134},11:{name:"(anonymous_11)",decl:{start:{line:153,column:21},end:{line:153,column:22}},loc:{start:{line:153,column:29},end:{line:155,column:13}},line:153},12:{name:"(anonymous_12)",decl:{start:{line:156,column:22},end:{line:156,column:23}},loc:{start:{line:156,column:29},end:{line:158,column:13}},line:156},13:{name:"(anonymous_13)",decl:{start:{line:159,column:20},end:{line:159,column:21}},loc:{start:{line:159,column:28},end:{line:162,column:13}},line:159},14:{name:"(anonymous_14)",decl:{start:{line:178,column:20},end:{line:178,column:21}},loc:{start:{line:178,column:27},end:{line:178,column:59}},line:178},15:{name:"(anonymous_15)",decl:{start:{line:179,column:19},end:{line:179,column:20}},loc:{start:{line:179,column:25},end:{line:181,column:11}},line:179}},branchMap:{0:{loc:{start:{line:19,column:4},end:{line:24,column:5}},type:"if",locations:[{start:{line:19,column:4},end:{line:24,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:19},1:{loc:{start:{line:19,column:8},end:{line:19,column:53}},type:"binary-expr",locations:[{start:{line:19,column:8},end:{line:19,column:22}},{start:{line:19,column:26},end:{line:19,column:53}}],line:19},2:{loc:{start:{line:28,column:18},end:{line:28,column:77}},type:"cond-expr",locations:[{start:{line:28,column:59},end:{line:28,column:65}},{start:{line:28,column:68},end:{line:28,column:77}}],line:28},3:{loc:{start:{line:28,column:18},end:{line:28,column:56}},type:"binary-expr",locations:[{start:{line:28,column:18},end:{line:28,column:33}},{start:{line:28,column:37},end:{line:28,column:56}}],line:28},4:{loc:{start:{line:30,column:4},end:{line:40,column:5}},type:"if",locations:[{start:{line:30,column:4},end:{line:40,column:5}},{start:{line:36,column:11},end:{line:40,column:5}}],line:30},5:{loc:{start:{line:30,column:8},end:{line:30,column:41}},type:"binary-expr",locations:[{start:{line:30,column:8},end:{line:30,column:27}},{start:{line:30,column:31},end:{line:30,column:41}}],line:30},6:{loc:{start:{line:31,column:6},end:{line:32,column:35}},type:"if",locations:[{start:{line:31,column:6},end:{line:32,column:35}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:31},7:{loc:{start:{line:36,column:11},end:{line:40,column:5}},type:"if",locations:[{start:{line:36,column:11},end:{line:40,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:36},8:{loc:{start:{line:36,column:15},end:{line:36,column:49}},type:"binary-expr",locations:[{start:{line:36,column:15},end:{line:36,column:35}},{start:{line:36,column:39},end:{line:36,column:49}}],line:36},9:{loc:{start:{line:42,column:18},end:{line:42,column:50}},type:"cond-expr",locations:[{start:{line:42,column:36},end:{line:42,column:42}},{start:{line:42,column:45},end:{line:42,column:50}}],line:42},10:{loc:{start:{line:46,column:4},end:{line:48,column:5}},type:"if",locations:[{start:{line:46,column:4},end:{line:48,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:46},11:{loc:{start:{line:50,column:4},end:{line:52,column:5}},type:"if",locations:[{start:{line:50,column:4},end:{line:52,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:50},12:{loc:{start:{line:53,column:4},end:{line:55,column:5}},type:"if",locations:[{start:{line:53,column:4},end:{line:55,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:53},13:{loc:{start:{line:53,column:8},end:{line:53,column:56}},type:"binary-expr",locations:[{start:{line:53,column:8},end:{line:53,column:30}},{start:{line:53,column:34},end:{line:53,column:56}}],line:53},14:{loc:{start:{line:56,column:4},end:{line:58,column:5}},type:"if",locations:[{start:{line:56,column:4},end:{line:58,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:56},15:{loc:{start:{line:56,column:8},end:{line:56,column:56}},type:"binary-expr",locations:[{start:{line:56,column:8},end:{line:56,column:30}},{start:{line:56,column:34},end:{line:56,column:56}}],line:56},16:{loc:{start:{line:63,column:4},end:{line:65,column:5}},type:"if",locations:[{start:{line:63,column:4},end:{line:65,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:63},17:{loc:{start:{line:66,column:4},end:{line:74,column:5}},type:"if",locations:[{start:{line:66,column:4},end:{line:74,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:66},18:{loc:{start:{line:67,column:6},end:{line:73,column:7}},type:"if",locations:[{start:{line:67,column:6},end:{line:73,column:7}},{start:{line:70,column:13},end:{line:73,column:7}}],line:67},19:{loc:{start:{line:80,column:4},end:{line:96,column:5}},type:"if",locations:[{start:{line:80,column:4},end:{line:96,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:80},20:{loc:{start:{line:82,column:6},end:{line:95,column:7}},type:"if",locations:[{start:{line:82,column:6},end:{line:95,column:7}},{start:{line:89,column:13},end:{line:95,column:7}}],line:82},21:{loc:{start:{line:83,column:8},end:{line:87,column:9}},type:"if",locations:[{start:{line:83,column:8},end:{line:87,column:9}},{start:{line:85,column:15},end:{line:87,column:9}}],line:83},22:{loc:{start:{line:90,column:8},end:{line:94,column:9}},type:"if",locations:[{start:{line:90,column:8},end:{line:94,column:9}},{start:{line:92,column:15},end:{line:94,column:9}}],line:90},23:{loc:{start:{line:100,column:4},end:{line:101,column:33}},type:"if",locations:[{start:{line:100,column:4},end:{line:101,column:33}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:100},24:{loc:{start:{line:104,column:4},end:{line:187,column:5}},type:"if",locations:[{start:{line:104,column:4},end:{line:187,column:5}},{start:{line:168,column:11},end:{line:187,column:5}}],line:104},25:{loc:{start:{line:104,column:8},end:{line:104,column:205}},type:"binary-expr",locations:[{start:{line:104,column:8},end:{line:104,column:63}},{start:{line:104,column:67},end:{line:104,column:122}},{start:{line:104,column:126},end:{line:104,column:151}},{start:{line:104,column:155},end:{line:104,column:180}},{start:{line:104,column:184},end:{line:104,column:205}}],line:104},26:{loc:{start:{line:105,column:20},end:{line:105,column:81}},type:"cond-expr",locations:[{start:{line:105,column:41},end:{line:105,column:62}},{start:{line:105,column:65},end:{line:105,column:81}}],line:105},27:{loc:{start:{line:106,column:27},end:{line:106,column:82}},type:"cond-expr",locations:[{start:{line:106,column:59},end:{line:106,column:61}},{start:{line:106,column:64},end:{line:106,column:82}}],line:106},28:{loc:{start:{line:108,column:6},end:{line:112,column:7}},type:"if",locations:[{start:{line:108,column:6},end:{line:112,column:7}},{start:{line:110,column:13},end:{line:112,column:7}}],line:108},29:{loc:{start:{line:123,column:19},end:{line:123,column:58}},type:"cond-expr",locations:[{start:{line:123,column:38},end:{line:123,column:50}},{start:{line:123,column:53},end:{line:123,column:58}}],line:123},30:{loc:{start:{line:152,column:19},end:{line:152,column:58}},type:"cond-expr",locations:[{start:{line:152,column:43},end:{line:152,column:45}},{start:{line:152,column:48},end:{line:152,column:58}}],line:152},31:{loc:{start:{line:169,column:20},end:{line:169,column:81}},type:"cond-expr",locations:[{start:{line:169,column:41},end:{line:169,column:62}},{start:{line:169,column:65},end:{line:169,column:81}}],line:169},32:{loc:{start:{line:177,column:17},end:{line:177,column:46}},type:"cond-expr",locations:[{start:{line:177,column:36},end:{line:177,column:38}},{start:{line:177,column:41},end:{line:177,column:46}}],line:177}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0],17:[0,0],18:[0,0],19:[0,0],20:[0,0],21:[0,0],22:[0,0],23:[0,0],24:[0,0],25:[0,0,0,0,0],26:[0,0],27:[0,0],28:[0,0],29:[0,0],30:[0,0],31:[0,0],32:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputNumber.tsx"],names:[],mappings:"AA2Ka,SACL,KADK;AA3Kb,OAAO,WAAmC;AAC1C,OAAO,sBAAsB;AAuB7B,qBAAqB,oBAAoB,MAAM,UAA8C;AAAA,EAC3F,OAAO,eAAe;AAAA,IACpB,WAAW;AAAA,EACb;AAAA,EACA,iBAA0B;AAAA,EAE1B,YAAY,OAAyB;AACnC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,MAAM,CAAC,iBAAiB;AAAA,MACxB,SAAS;AAAA,MACT,OAAO,MAAM;AAAA,MACb,YAAY,MAAM;AAAA,IACpB;AAAA,EACF;AAAA,EAEA,OAAO,yBAAyB,OAAyB,OAAyB;AAChF,QAAI,CAAC,MAAM,WAAW,MAAM,UAAU,MAAM,OAAO;AACjD,aAAO;AAAA,QACL,OAAO,MAAM;AAAA,QACb,YAAY,MAAM;AAAA,MACpB;AAAA,IACF;AACA,WAAO;AAAA,EACT;AAAA,EAEA,YAAY,UAAuC;AACjD,UAAM,QAAS,aAAa,MAAM,aAAa,SAC7C,SAAY,CAAC;AAEf,UAAM,aAAa,KAAK,MAAM,UAAU;AACxC,QAAG,KAAK,QAAQ,KAAK,KAAK,YAAY;AACpC,UAAI,KAAK,MAAM;AAAU,aAAK,MAAM,SAAS,KAAK;AAClD,WAAK,SAAS;AAAA,QACZ;AAAA,MACF,CAAC;AAAA,IACH,WACS,CAAC,KAAK,QAAQ,KAAK,KAAK,YAAY;AAC3C,WAAK,SAAS;AAAA,QACZ,OAAO;AAAA,MACT,CAAC;AAAA,IACH;AAEA,SAAK,SAAS;AAAA,MACZ,YAAY,aAAa,KAAK,SAAY;AAAA,IAC5C,CAAC;AAAA,EACH;AAAA,EAEA,QAAQ,GAAgC;AACtC,QAAI,MAAM,QAAW;AACnB,aAAO;AAAA,IACT;AAEA,UAAM,QAAQ,CAAC;AACf,QAAG,MAAM,KAAK,GAAG;AACf,aAAO;AAAA,IACT;AAEA,QAAG,CAAC,MAAM,KAAK,MAAM,GAAI,KAAK,QAAQ,KAAK,MAAM,KAAM;AACrD,aAAO;AAAA,IACT;AAEA,QAAG,CAAC,MAAM,KAAK,MAAM,GAAI,KAAK,QAAQ,KAAK,MAAM,KAAM;AACrD,aAAO;AAAA,IACT;AAEA,WAAO;AAAA,EACT;AAAA,EAEA,aAAa,MAAM;AACjB,SAAK,SAAS,EAAC,SAAS,MAAK,CAAC;AAE9B,QAAG,CAAC,KAAK,MAAM,OAAO;AACpB;AAAA,IACF;AAGA,QAAI,CAAC,KAAK,QAAQ,KAAK,MAAM,KAAK,GAAG;AACnC,UAAG,KAAK,QAAQ,KAAK,MAAM,KAAK,GAAG;AACjC,aAAK,YAAY,KAAK,MAAM,KAAK;AACjC,aAAK,SAAS,EAAC,YAAY,KAAK,MAAM,MAAK,CAAC;AAAA,MAC9C,OAAO;AACL,aAAK,YAAY,MAAS;AAC1B,aAAK,SAAS,EAAC,YAAY,OAAS,CAAC;AAAA,MACvC;AAAA,IACF;AAAA,EACF;AAAA,EAEA,gBAAgB,CAAC,MAAqE;AACpF,QAAI,QAAQ,WAAW,EAAE,OAAO,KAAK;AACrC,UAAM,OAAO,KAAK,MAAM;AACxB,QAAI,aAAa;AAEjB,QAAG,MAAM;AAEP,YAAM,OAAO,QAAQ;AAGrB,UAAI,KAAK,gBAAgB;AAKvB,YAAI,QAAQ,KAAK,MAAM,YAAa;AAClC,kBAAQ,KAAK,MAAM,QAAS;AAAA,QAC9B,OACK;AACH,kBAAQ,KAAK,MAAM,QAAS;AAAA,QAC9B;AACA,qBAAa;AAAA,MACf,OACK;AACH,YAAI,OAAO,OAAK,GAAG;AACjB,kBAAQ,QAAQ;AAAA,QAClB,OACK;AACH,kBAAQ,SAAS,OAAO;AAAA,QAC1B;AAAA,MACF;AAAA,IACF;AAEA,SAAK,iBAAiB;AAGtB,YAAQ,KAAK,IAAI,KAAK,MAAM,KAAM,KAAK,IAAI,KAAK,MAAM,KAAM,KAAK,CAAC;AAElE,SAAK,SAAS,EAAC,OAAO,WAAU,CAAC;AACjC,QAAI,KAAK,MAAM;AAAU,WAAK,MAAM,SAAS,KAAK;AAAA,EACpD;AAAA,EAEA,SAAS;AACP,QACE,OAAO,UAAU,eAAe,KAAK,KAAK,OAAO,KAAK,KACtD,OAAO,UAAU,eAAe,KAAK,KAAK,OAAO,KAAK,KACtD,KAAK,MAAM,QAAQ,UAAa,KAAK,MAAM,QAAQ,UACnD,KAAK,MAAM,YACX;AACA,YAAM,QAAQ,KAAK,MAAM,UAAU,KAAK,MAAM,aAAa,KAAK,MAAM;AACtE,YAAM,eAAe,KAAK,MAAM,YAAY,SAAY,KAAK,KAAK,MAAM;AACxE,UAAI;AACJ,UAAI,KAAK,MAAM,cAAc;AAC3B,qBAAa,KAAK,MAAM;AAAA,MAC1B,OACK;AACH,qBAAa;AAAA,MACf;AAEA,aAAO,qBAAC,SAAI,WAAU,6BACpB;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,WAAU;AAAA,YAEV,MAAK;AAAA,YACL,KAAK,KAAK,MAAM;AAAA,YAChB,KAAK,KAAK,MAAM;AAAA,YAChB,MAAK;AAAA,YACL,YAAW;AAAA,YACX,OAAO,UAAU,SAAY,eAAe;AAAA,YAC5C,UAAU,KAAK;AAAA,YACf,WAAW,MAAM;AACf,mBAAK,iBAAiB;AAAA,YACxB;AAAA,YACA,eAAe,MAAM;AACnB,mBAAK,SAAS,EAAC,SAAS,MAAM,cAAc,KAAI,CAAC;AAAA,YACnD;AAAA,YACA,aAAa,MAAM;AAEjB,mBAAK,SAAS,EAAC,SAAS,OAAO,cAAc,MAAK,CAAC;AAAA,YACrD;AAAA,YACA,QAAQ,MAAM;AACZ,mBAAK,SAAS;AAAA,gBACZ,SAAS;AAAA,gBACT,cAAc;AAAA,gBACd,YAAY,KAAK,MAAM;AAAA,cACzB,CAAC;AAAA,YACH;AAAA,YACA,eAAa,KAAK,MAAM,aAAa,IAAI;AAAA;AAAA,UAzBrC;AAAA,QA0BN;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YAEC,MAAK;AAAA,YACL,YAAW;AAAA,YACX,WAAU;AAAA,YACV,aAAa,KAAK,MAAM,SAAS,SAAS;AAAA,YAC1C,OAAO,eAAe,SAAY,KAAK;AAAA,YACvC,SAAS,QAAM;AACb,mBAAK,SAAS,EAAC,SAAS,KAAI,CAAC;AAAA,YAC/B;AAAA,YACA,UAAU,OAAK;AACb,mBAAK,YAAY,EAAE,OAAO,KAAK;AAAA,YACjC;AAAA,YACA,QAAQ,QAAM;AACZ,mBAAK,SAAS,EAAC,SAAS,MAAK,CAAC;AAC9B,mBAAK,WAAW;AAAA,YAClB;AAAA,YACA,eAAa,KAAK,MAAM,aAAa,IAAI;AAAA;AAAA,UAhBrC;AAAA,QAkBN;AAAA,SACF;AAAA,IACF,OACK;AACH,YAAM,QAAQ,KAAK,MAAM,UAAU,KAAK,MAAM,aAAa,KAAK,MAAM;AAEtE,aAAO;AAAA,QAAC;AAAA;AAAA,UACN,cAAY,KAAK,MAAM,YAAY;AAAA,UACnC,YAAW;AAAA,UACX,WAAU;AAAA,UACV,aAAa,KAAK,MAAM,SAAS,SAAS;AAAA,UAC1C,OAAO,UAAU,SAAY,KAAK;AAAA,UAClC,UAAU,OAAK,KAAK,YAAY,EAAE,OAAO,KAAK;AAAA,UAC9C,SAAS,MAAM;AACb,iBAAK,SAAS,EAAC,SAAS,KAAI,CAAC;AAAA,UAC/B;AAAA,UACA,QAAQ,KAAK;AAAA,UACb,UAAU,KAAK,MAAM;AAAA,UACrB,eAAa,KAAK,MAAM,aAAa;AAAA;AAAA,MACvC;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6f326a25e01ec46339f6b8716575d23b39d5290d"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Rt=function(){return s},s}Rt();class pf extends bn.Component{constructor(t){Rt().f[0]++,Rt().s[2]++;super(t);nn(this,"_keyboardEvent",(Rt().s[1]++,!1));nn(this,"resetValue",(Rt().s[26]++,()=>{if(Rt().f[4]++,Rt().s[27]++,this.setState({editing:!1}),Rt().s[28]++,this.state.value)Rt().b[16][1]++;else{Rt().b[16][0]++,Rt().s[29]++;return}Rt().s[30]++,this.isValid(this.state.value)?Rt().b[17][1]++:(Rt().b[17][0]++,Rt().s[31]++,this.isValid(this.props.value)?(Rt().b[18][0]++,Rt().s[32]++,this.changeValue(this.props.value),Rt().s[33]++,this.setState({dirtyValue:this.props.value})):(Rt().b[18][1]++,Rt().s[34]++,this.changeValue(void 0),Rt().s[35]++,this.setState({dirtyValue:void 0})))}));nn(this,"onChangeRange",(Rt().s[36]++,t=>{Rt().f[5]++;let r=(Rt().s[37]++,parseFloat(t.target.value));const i=(Rt().s[38]++,this.props.rangeStep);let o=(Rt().s[39]++,r);if(Rt().s[40]++,i){Rt().b[19][0]++;const s=(Rt().s[41]++,r%i);Rt().s[42]++,this._keyboardEvent?(Rt().b[20][0]++,Rt().s[43]++,r<this.state.dirtyValue?(Rt().b[21][0]++,Rt().s[44]++,r=this.state.value-i):(Rt().b[21][1]++,Rt().s[45]++,r=this.state.value+i),Rt().s[46]++,o=r):(Rt().b[20][1]++,Rt().s[47]++,s<i/2?(Rt().b[22][0]++,Rt().s[48]++,r=r-s):(Rt().b[22][1]++,Rt().s[49]++,r=r+(i-s)))}else Rt().b[19][1]++;Rt().s[50]++,this._keyboardEvent=!1,Rt().s[51]++,r=Math.max(this.props.min,Math.min(this.props.max,r)),Rt().s[52]++,this.setState({value:r,dirtyValue:o}),Rt().s[53]++,this.props.onChange?(Rt().b[23][0]++,Rt().s[54]++,this.props.onChange(r)):Rt().b[23][1]++}));Rt().s[3]++,this.state={uuid:+Oy(),editing:!1,value:t.value,dirtyValue:t.value}}static getDerivedStateFromProps(t,r){return Rt().f[1]++,Rt().s[4]++,Rt().b[1][0]++,!r.editing&&(Rt().b[1][1]++,t.value!==r.value)?(Rt().b[0][0]++,Rt().s[5]++,{value:t.value,dirtyValue:t.value}):(Rt().b[0][1]++,Rt().s[6]++,null)}changeValue(t){Rt().f[2]++;const r=(Rt().s[7]++,Rt().b[3][0]++,t===""||(Rt().b[3][1]++,t===void 0)?(Rt().b[2][0]++,void 0):(Rt().b[2][1]++,+t)),i=(Rt().s[8]++,this.props.value!==r);Rt().s[9]++,Rt().b[5][0]++,this.isValid(r)&&(Rt().b[5][1]++,i)?(Rt().b[4][0]++,Rt().s[10]++,this.props.onChange?(Rt().b[6][0]++,Rt().s[11]++,this.props.onChange(r)):Rt().b[6][1]++,Rt().s[12]++,this.setState({value:r})):(Rt().b[4][1]++,Rt().s[13]++,Rt().b[8][0]++,!this.isValid(r)&&(Rt().b[8][1]++,i)?(Rt().b[7][0]++,Rt().s[14]++,this.setState({value:void 0})):Rt().b[7][1]++),Rt().s[15]++,this.setState({dirtyValue:t===""?(Rt().b[9][0]++,void 0):(Rt().b[9][1]++,r)})}isValid(t){if(Rt().f[3]++,Rt().s[16]++,t===void 0)return Rt().b[10][0]++,Rt().s[17]++,!0;Rt().b[10][1]++;const r=(Rt().s[18]++,+t);return Rt().s[19]++,isNaN(r)?(Rt().b[11][0]++,Rt().s[20]++,!1):(Rt().b[11][1]++,Rt().s[21]++,Rt().b[13][0]++,!isNaN(this.props.min)&&(Rt().b[13][1]++,r<this.props.min)?(Rt().b[12][0]++,Rt().s[22]++,!1):(Rt().b[12][1]++,Rt().s[23]++,Rt().b[15][0]++,!isNaN(this.props.max)&&(Rt().b[15][1]++,r>this.props.max)?(Rt().b[14][0]++,Rt().s[24]++,!1):(Rt().b[14][1]++,Rt().s[25]++,!0)))}render(){var t,r;if(Rt().f[6]++,Rt().s[55]++,Rt().b[25][0]++,Object.prototype.hasOwnProperty.call(this.props,"min")&&(Rt().b[25][1]++,Object.prototype.hasOwnProperty.call(this.props,"max"))&&(Rt().b[25][2]++,this.props.min!==void 0)&&(Rt().b[25][3]++,this.props.max!==void 0)&&(Rt().b[25][4]++,this.props.allowRange)){Rt().b[24][0]++;const i=(Rt().s[56]++,this.state.editing?(Rt().b[26][0]++,this.state.dirtyValue):(Rt().b[26][1]++,this.state.value)),o=(Rt().s[57]++,this.props.default===void 0?(Rt().b[27][0]++,""):(Rt().b[27][1]++,this.props.default));let s;return Rt().s[58]++,this.state.editingRange?(Rt().b[28][0]++,Rt().s[59]++,s=this.state.value):(Rt().b[28][1]++,Rt().s[60]++,s=i),Rt().s[61]++,N.jsxs("div",{className:"maputnik-number-container",children:[N.jsx("input",{className:"maputnik-number-range",type:"range",max:this.props.max,min:this.props.min,step:"any",spellCheck:"false",value:i===void 0?(Rt().b[29][0]++,o):(Rt().b[29][1]++,i),onChange:this.onChangeRange,onKeyDown:()=>{Rt().f[7]++,Rt().s[62]++,this._keyboardEvent=!0},onPointerDown:()=>{Rt().f[8]++,Rt().s[63]++,this.setState({editing:!0,editingRange:!0})},onPointerUp:()=>{Rt().f[9]++,Rt().s[64]++,this.setState({editing:!1,editingRange:!1})},onBlur:()=>{Rt().f[10]++,Rt().s[65]++,this.setState({editing:!1,editingRange:!1,dirtyValue:this.state.value})},"data-wd-key":this.props["data-wd-key"]+"-range"},"range"),N.jsx("input",{type:"text",spellCheck:"false",className:"maputnik-number",placeholder:(t=this.props.default)==null?void 0:t.toString(),value:s===void 0?(Rt().b[30][0]++,""):(Rt().b[30][1]++,s),onFocus:a=>{Rt().f[11]++,Rt().s[66]++,this.setState({editing:!0})},onChange:a=>{Rt().f[12]++,Rt().s[67]++,this.changeValue(a.target.value)},onBlur:a=>{Rt().f[13]++,Rt().s[68]++,this.setState({editing:!1}),Rt().s[69]++,this.resetValue()},"data-wd-key":this.props["data-wd-key"]+"-text"},"text")]})}else{Rt().b[24][1]++;const i=(Rt().s[70]++,this.state.editing?(Rt().b[31][0]++,this.state.dirtyValue):(Rt().b[31][1]++,this.state.value));return Rt().s[71]++,N.jsx("input",{"aria-label":this.props["aria-label"],spellCheck:"false",className:"maputnik-number",placeholder:(r=this.props.default)==null?void 0:r.toString(),value:i===void 0?(Rt().b[32][0]++,""):(Rt().b[32][1]++,i),onChange:o=>(Rt().f[14]++,Rt().s[72]++,this.changeValue(o.target.value)),onFocus:()=>{Rt().f[15]++,Rt().s[73]++,this.setState({editing:!0})},onBlur:this.resetValue,required:this.props.required,"data-wd-key":this.props["data-wd-key"]})}}}nn(pf,"defaultProps",(Rt().s[0]++,{rangeStep:1}));function Gh(){var e="/home/runner/work/maputnik/maputnik/src/components/InputCheckbox.tsx",n="e85f7924976070cbab7795bce9cf0e191e4a6b5e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputCheckbox.tsx",statementMap:{0:{start:{line:4,column:24},end:{line:6,column:3}},1:{start:{line:7,column:13},end:{line:9,column:3}},2:{start:{line:8,column:4},end:{line:8,column:43}},3:{start:{line:11,column:4},end:{line:26,column:9}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:13},end:{line:7,column:14}},loc:{start:{line:7,column:19},end:{line:9,column:3}},line:7},1:{name:"(anonymous_1)",decl:{start:{line:10,column:2},end:{line:10,column:3}},loc:{start:{line:10,column:11},end:{line:27,column:3}},line:10}},branchMap:{0:{loc:{start:{line:24,column:17},end:{line:24,column:53}},type:"cond-expr",locations:[{start:{line:24,column:36},end:{line:24,column:44}},{start:{line:24,column:47},end:{line:24,column:53}}],line:24}},s:{0:0,1:0,2:0,3:0},f:{0:0,1:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputCheckbox.tsx"],names:[],mappings:"AAkBW,SACL,KADK;AAlBX,OAAO,WAAW;AAQlB,qBAAqB,sBAAsB,MAAM,UAA8B;AAAA,EAC7E,OAAO,eAAe;AAAA,IACpB,OAAO;AAAA,EACT;AAAA,EAEA,WAAW,MAAM;AACf,SAAK,MAAM,SAAS,CAAC,KAAK,MAAM,KAAK;AAAA,EACvC;AAAA,EAEA,SAAS;AACP,WAAO,qBAAC,SAAI,WAAU,6BACpB;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,MAAK;AAAA,UACL,OAAO,KAAK,MAAM;AAAA,UAClB,UAAU,KAAK;AAAA,UACf,SAAS,KAAK;AAAA,UACd,SAAS,KAAK,MAAM;AAAA;AAAA,MACtB;AAAA,MACA,oBAAC,SAAI,WAAU,yBACb,8BAAC,SAAI,OAAO;AAAA,QACV,SAAS,KAAK,MAAM,QAAQ,WAAW;AAAA,MACzC,GAAG,WAAU,0BAAyB,SAAQ,aAC5C,8BAAC,UAAK,GAAE,2CAA0C,GACpD,GACF;AAAA,OACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"e85f7924976070cbab7795bce9cf0e191e4a6b5e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Gh=function(){return s},s}Gh();class Q8 extends bn.Component{constructor(){super(...arguments);nn(this,"onChange",(Gh().s[1]++,()=>{Gh().f[0]++,Gh().s[2]++,this.props.onChange(!this.props.value)}))}render(){return Gh().f[1]++,Gh().s[3]++,N.jsxs("div",{className:"maputnik-checkbox-wrapper",children:[N.jsx("input",{className:"maputnik-checkbox",type:"checkbox",style:this.props.style,onChange:this.onChange,onClick:this.onChange,checked:this.props.value}),N.jsx("div",{className:"maputnik-checkbox-box",children:N.jsx("svg",{style:{display:this.props.value?(Gh().b[0][0]++,"inline"):(Gh().b[0][1]++,"none")},className:"maputnik-checkbox-icon",viewBox:"0 0 32 32",children:N.jsx("path",{d:"M1 14 L5 10 L13 18 L27 4 L31 8 L13 26 z"})})})]})}}nn(Q8,"defaultProps",(Gh().s[0]++,{value:!1}));function pr(){var e="/home/runner/work/maputnik/maputnik/src/components/InputArray.tsx",n="b22e3e5f460e97aba4bdc54843ce7e77423f5b07",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputArray.tsx",statementMap:{0:{start:{line:6,column:24},end:{line:9,column:3}},1:{start:{line:11,column:4},end:{line:11,column:17}},2:{start:{line:12,column:4},end:{line:16,column:6}},3:{start:{line:19,column:18},end:{line:19,column:20}},4:{start:{line:20,column:30},end:{line:20,column:62}},5:{start:{line:21,column:4},end:{line:28,column:7}},6:{start:{line:22,column:6},end:{line:27,column:7}},7:{start:{line:23,column:8},end:{line:23,column:34}},8:{start:{line:25,column:8},end:{line:25,column:34}},9:{start:{line:26,column:8},end:{line:26,column:46}},10:{start:{line:29,column:4},end:{line:32,column:6}},11:{start:{line:35,column:4},end:{line:38,column:7}},12:{start:{line:36,column:18},end:{line:36,column:26}},13:{start:{line:37,column:6},end:{line:37,column:45}},14:{start:{line:41,column:18},end:{line:41,column:43}},15:{start:{line:42,column:4},end:{line:42,column:26}},16:{start:{line:43,column:4},end:{line:51,column:7}},17:{start:{line:46,column:6},end:{line:50,column:7}},18:{start:{line:47,column:8},end:{line:47,column:35}},19:{start:{line:48,column:13},end:{line:50,column:7}},20:{start:{line:49,column:8},end:{line:49,column:36}},21:{start:{line:54,column:22},end:{line:54,column:32}},22:{start:{line:55,column:27},end:{line:57,column:6}},23:{start:{line:56,column:6},end:{line:56,column:42}},24:{start:{line:58,column:19},end:{line:84,column:6}},25:{start:{line:59,column:6},end:{line:83,column:7}},26:{start:{line:60,column:8},end:{line:70,column:10}},27:{start:{line:66,column:29},end:{line:66,column:51}},28:{start:{line:72,column:8},end:{line:82,column:10}},29:{start:{line:85,column:4},end:{line:85,column:89}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:10,column:2},end:{line:10,column:3}},loc:{start:{line:10,column:21},end:{line:17,column:3}},line:10},1:{name:"(anonymous_1)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:48},end:{line:33,column:3}},line:18},2:{name:"(anonymous_2)",decl:{start:{line:21,column:39},end:{line:21,column:40}},loc:{start:{line:21,column:49},end:{line:28,column:5}},line:21},3:{name:"(anonymous_3)",decl:{start:{line:34,column:2},end:{line:34,column:3}},loc:{start:{line:34,column:20},end:{line:39,column:3}},line:34},4:{name:"(anonymous_4)",decl:{start:{line:35,column:53},end:{line:35,column:54}},loc:{start:{line:35,column:63},end:{line:38,column:5}},line:35},5:{name:"(anonymous_5)",decl:{start:{line:40,column:2},end:{line:40,column:3}},loc:{start:{line:40,column:29},end:{line:52,column:3}},line:40},6:{name:"(anonymous_6)",decl:{start:{line:45,column:7},end:{line:45,column:8}},loc:{start:{line:45,column:13},end:{line:51,column:5}},line:45},7:{name:"(anonymous_7)",decl:{start:{line:53,column:2},end:{line:53,column:3}},loc:{start:{line:53,column:11},end:{line:86,column:3}},line:53},8:{name:"(anonymous_8)",decl:{start:{line:55,column:60},end:{line:55,column:61}},loc:{start:{line:55,column:69},end:{line:57,column:5}},line:55},9:{name:"(anonymous_9)",decl:{start:{line:58,column:59},end:{line:58,column:60}},loc:{start:{line:58,column:69},end:{line:84,column:5}},line:58},10:{name:"(anonymous_10)",decl:{start:{line:66,column:22},end:{line:66,column:23}},loc:{start:{line:66,column:29},end:{line:66,column:51}},line:66}},branchMap:{0:{loc:{start:{line:22,column:6},end:{line:27,column:7}},type:"if",locations:[{start:{line:22,column:6},end:{line:27,column:7}},{start:{line:24,column:13},end:{line:27,column:7}}],line:22},1:{loc:{start:{line:37,column:15},end:{line:37,column:43}},type:"binary-expr",locations:[{start:{line:37,column:15},end:{line:37,column:29}},{start:{line:37,column:33},end:{line:37,column:43}}],line:37},2:{loc:{start:{line:46,column:6},end:{line:50,column:7}},type:"if",locations:[{start:{line:46,column:6},end:{line:50,column:7}},{start:{line:48,column:13},end:{line:50,column:7}}],line:46},3:{loc:{start:{line:46,column:10},end:{line:46,column:55}},type:"binary-expr",locations:[{start:{line:46,column:10},end:{line:46,column:32}},{start:{line:46,column:36},end:{line:46,column:55}}],line:46},4:{loc:{start:{line:48,column:13},end:{line:50,column:7}},type:"if",locations:[{start:{line:48,column:13},end:{line:50,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:48},5:{loc:{start:{line:55,column:27},end:{line:57,column:6}},type:"binary-expr",locations:[{start:{line:55,column:27},end:{line:55,column:43}},{start:{line:55,column:47},end:{line:57,column:6}}],line:55},6:{loc:{start:{line:56,column:13},end:{line:56,column:41}},type:"binary-expr",locations:[{start:{line:56,column:13},end:{line:56,column:23}},{start:{line:56,column:27},end:{line:56,column:41}}],line:56},7:{loc:{start:{line:59,column:6},end:{line:83,column:7}},type:"if",locations:[{start:{line:59,column:6},end:{line:83,column:7}},{start:{line:71,column:13},end:{line:83,column:7}}],line:59},8:{loc:{start:{line:63,column:21},end:{line:63,column:91}},type:"cond-expr",locations:[{start:{line:63,column:61},end:{line:63,column:67}},{start:{line:63,column:70},end:{line:63,column:91}}],line:63},9:{loc:{start:{line:63,column:21},end:{line:63,column:58}},type:"binary-expr",locations:[{start:{line:63,column:21},end:{line:63,column:35}},{start:{line:63,column:39},end:{line:63,column:58}}],line:63},10:{loc:{start:{line:65,column:22},end:{line:65,column:51}},type:"cond-expr",locations:[{start:{line:65,column:39},end:{line:65,column:43}},{start:{line:65,column:46},end:{line:65,column:51}}],line:65},11:{loc:{start:{line:67,column:26},end:{line:67,column:70}},type:"binary-expr",locations:[{start:{line:67,column:26},end:{line:67,column:50}},{start:{line:67,column:54},end:{line:67,column:70}}],line:67},12:{loc:{start:{line:75,column:21},end:{line:75,column:91}},type:"cond-expr",locations:[{start:{line:75,column:61},end:{line:75,column:67}},{start:{line:75,column:70},end:{line:75,column:91}}],line:75},13:{loc:{start:{line:75,column:21},end:{line:75,column:58}},type:"binary-expr",locations:[{start:{line:75,column:21},end:{line:75,column:35}},{start:{line:75,column:39},end:{line:75,column:58}}],line:75},14:{loc:{start:{line:77,column:22},end:{line:77,column:51}},type:"cond-expr",locations:[{start:{line:77,column:39},end:{line:77,column:43}},{start:{line:77,column:46},end:{line:77,column:51}}],line:77},15:{loc:{start:{line:79,column:26},end:{line:79,column:70}},type:"binary-expr",locations:[{start:{line:79,column:26},end:{line:79,column:50}},{start:{line:79,column:54},end:{line:79,column:70}}],line:79}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputArray.tsx"],names:[],mappings:"AA0Fe;AA1Ff,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AAiBxB,qBAAqB,mBAAmB,MAAM,UAA4C;AAAA,EACxF,OAAO,eAAe;AAAA,IACpB,OAAO,CAAC;AAAA,IACR,SAAS,CAAC;AAAA,EACZ;AAAA,EAEA,YAAa,OAAwB;AACnC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,OAAO,KAAK,MAAM,MAAM,MAAM,CAAC;AAAA;AAAA,MAE/B,mBAAmB,KAAK,MAAM,MAAM,MAAM,CAAC;AAAA,IAC7C;AAAA,EACF;AAAA,EAEA,OAAO,yBAAyB,OAAwB,OAAwB;AAC9E,UAAM,QAAe,CAAC;AACtB,UAAM,oBAAoB,MAAM,kBAAkB,MAAM,CAAC;AAEzD,UAAM,MAAM,MAAM,EAAE,KAAK,IAAI,EAAE,IAAI,CAAC,GAAG,MAAM;AAC3C,UAAI,MAAM,MAAM,CAAC,MAAM,MAAM,kBAAkB,CAAC,GAAG;AACjD,cAAM,CAAC,IAAI,MAAM,MAAM,CAAC;AAAA,MAC1B,OACK;AACH,cAAM,CAAC,IAAI,MAAM,MAAM,CAAC;AACxB,0BAAkB,CAAC,IAAI,MAAM,MAAM,CAAC;AAAA,MACtC;AAAA,IACF,CAAC;AAED,WAAO;AAAA,MACL;AAAA,MACA;AAAA,IACF;AAAA,EACF;AAAA,EAEA,WAAW,OAAkB;AAC3B,WAAO,MAAM,KAAK,MAAM,MAAM,EAAE,KAAK,IAAI,EAAE,MAAM,CAAC,GAAG,MAAM;AACzD,YAAM,MAAM,MAAM,CAAC;AACnB,aAAO,EAAE,QAAQ,UAAa,QAAQ;AAAA,IACxC,CAAC;AAAA,EACH;AAAA,EAEA,YAAY,KAAa,UAAuC;AAC9D,UAAM,QAAQ,KAAK,MAAM,MAAM,MAAM,CAAC;AACtC,UAAM,GAAG,IAAI;AAEb,SAAK,SAAS;AAAA,MACZ;AAAA,IACF,GAAG,MAAM;AACP,UAAI,KAAK,WAAW,KAAK,KAAK,KAAK,MAAM,UAAU;AACjD,aAAK,MAAM,SAAS,KAAK;AAAA,MAC3B,WACS,KAAK,MAAM,UAAS;AAE3B,aAAK,MAAM,SAAS,MAAS;AAAA,MAC/B;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,MAAK,IAAI,KAAK;AAErB,UAAM,iBACJ,MAAM,SAAS,KACf,CAAC,MAAM,MAAM,SAAO;AAClB,aAAQ,QAAQ,MAAM,QAAQ;AAAA,IAChC,CAAC;AAGH,UAAM,SAAS,MAAM,KAAK,MAAM,MAAM,EAAE,KAAK,IAAI,EAAE,IAAI,CAAC,GAAG,MAAM;AAC/D,UAAG,KAAK,MAAM,SAAS,UAAU;AAC/B,eAAO;AAAA,UAAC;AAAA;AAAA,YAEN,SAAS,kBAAkB,CAAC,KAAK,MAAM,UAAU,SAAY,KAAK,MAAM,QAAQ,CAAC;AAAA,YACjF,OAAO,MAAM,CAAC;AAAA,YACd,UAAU,iBAAiB,OAAO;AAAA,YAClC,UAAU,CAAC,MAAM,KAAK,YAAY,GAAG,CAAC;AAAA,YACtC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA;AAAA,UAL9C;AAAA,QAMP;AAAA,MACF,OAAO;AACL,eAAO;AAAA,UAAC;AAAA;AAAA,YAEN,SAAS,kBAAkB,CAAC,KAAK,MAAM,UAAU,SAAY,KAAK,MAAM,QAAQ,CAAC;AAAA,YACjF,OAAO,MAAM,CAAC;AAAA,YACd,UAAU,iBAAiB,OAAO;AAAA,YAClC,UAAU,KAAK,YAAY,KAAK,MAAM,CAAC;AAAA,YACvC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA;AAAA,UAL9C;AAAA,QAMP;AAAA,MACF;AAAA,IACF,CAAC;AAED,WACE,oBAAC,SAAI,WAAU,kBACZ,kBACH;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"b22e3e5f460e97aba4bdc54843ce7e77423f5b07"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return pr=function(){return s},s}pr();var vS;let NN=(vS=class extends bn.Component{constructor(n){pr().f[0]++,pr().s[1]++,super(n),pr().s[2]++,this.state={value:this.props.value.slice(0),initialPropsValue:this.props.value.slice(0)}}static getDerivedStateFromProps(n,t){pr().f[1]++;const r=(pr().s[3]++,[]),i=(pr().s[4]++,t.initialPropsValue.slice(0));return pr().s[5]++,Array(n.length).fill(null).map((o,s)=>{pr().f[2]++,pr().s[6]++,n.value[s]===t.initialPropsValue[s]?(pr().b[0][0]++,pr().s[7]++,r[s]=t.value[s]):(pr().b[0][1]++,pr().s[8]++,r[s]=t.value[s],pr().s[9]++,i[s]=t.value[s])}),pr().s[10]++,{value:r,initialPropsValue:i}}isComplete(n){return pr().f[3]++,pr().s[11]++,Array(this.props.length).fill(null).every((t,r)=>{pr().f[4]++;const i=(pr().s[12]++,n[r]);return pr().s[13]++,pr().b[1][0]++,!(i===void 0||(pr().b[1][1]++,i===""))})}changeValue(n,t){pr().f[5]++;const r=(pr().s[14]++,this.state.value.slice(0));pr().s[15]++,r[n]=t,pr().s[16]++,this.setState({value:r},()=>{pr().f[6]++,pr().s[17]++,pr().b[3][0]++,this.isComplete(r)&&(pr().b[3][1]++,this.props.onChange)?(pr().b[2][0]++,pr().s[18]++,this.props.onChange(r)):(pr().b[2][1]++,pr().s[19]++,this.props.onChange?(pr().b[4][0]++,pr().s[20]++,this.props.onChange(void 0)):pr().b[4][1]++)})}render(){pr().f[7]++;const{value:n}=(pr().s[21]++,this.state),t=(pr().s[22]++,pr().b[5][0]++,n.length>0&&(pr().b[5][1]++,!n.every(i=>(pr().f[8]++,pr().s[23]++,pr().b[6][0]++,i===""||(pr().b[6][1]++,i===void 0))))),r=(pr().s[24]++,Array(this.props.length).fill(null).map((i,o)=>(pr().f[9]++,pr().s[25]++,this.props.type==="number"?(pr().b[7][0]++,pr().s[26]++,N.jsx(pf,{default:(pr().b[9][0]++,t||(pr().b[9][1]++,!this.props.default)?(pr().b[8][0]++,void 0):(pr().b[8][1]++,this.props.default[o])),value:n[o],required:t?(pr().b[10][0]++,!0):(pr().b[10][1]++,!1),onChange:s=>(pr().f[10]++,pr().s[27]++,this.changeValue(o,s)),"aria-label":(pr().b[11][0]++,this.props["aria-label"]||(pr().b[11][1]++,this.props.label))},o)):(pr().b[7][1]++,pr().s[28]++,N.jsx(Sd,{default:(pr().b[13][0]++,t||(pr().b[13][1]++,!this.props.default)?(pr().b[12][0]++,void 0):(pr().b[12][1]++,this.props.default[o])),value:n[o],required:t?(pr().b[14][0]++,!0):(pr().b[14][1]++,!1),onChange:this.changeValue.bind(this,o),"aria-label":(pr().b[15][0]++,this.props["aria-label"]||(pr().b[15][1]++,this.props.label))},o)))));return pr().s[29]++,N.jsx("div",{className:"maputnik-array",children:r})}},nn(vS,"defaultProps",(pr().s[0]++,{value:[],default:[]})),vS);function nl(){var e="/home/runner/work/maputnik/maputnik/src/components/InputMultiInput.tsx",n="c4660c9ecb80d9f1ce71e70441154e1e765b77ab",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputMultiInput.tsx",statementMap:{0:{start:{line:6,column:18},end:{line:6,column:36}},1:{start:{line:7,column:4},end:{line:9,column:5}},2:{start:{line:8,column:6},end:{line:8,column:43}},3:{start:{line:8,column:35},end:{line:8,column:41}},4:{start:{line:10,column:26},end:{line:10,column:59}},5:{start:{line:11,column:19},end:{line:32,column:6}},6:{start:{line:12,column:6},end:{line:31,column:8}},7:{start:{line:22,column:34},end:{line:22,column:58}},8:{start:{line:33,column:4},end:{line:33,column:140}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:34,column:3}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:8,column:28},end:{line:8,column:29}},loc:{start:{line:8,column:35},end:{line:8,column:41}},line:8},2:{name:"(anonymous_2)",decl:{start:{line:11,column:31},end:{line:11,column:32}},loc:{start:{line:11,column:49},end:{line:32,column:5}},line:11},3:{name:"(anonymous_3)",decl:{start:{line:22,column:26},end:{line:22,column:27}},loc:{start:{line:22,column:34},end:{line:22,column:58}},line:22}},branchMap:{0:{loc:{start:{line:7,column:4},end:{line:9,column:5}},type:"if",locations:[{start:{line:7,column:4},end:{line:9,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:7},1:{loc:{start:{line:7,column:8},end:{line:7,column:56}},type:"binary-expr",locations:[{start:{line:7,column:8},end:{line:7,column:26}},{start:{line:7,column:30},end:{line:7,column:56}}],line:7},2:{loc:{start:{line:10,column:26},end:{line:10,column:59}},type:"binary-expr",locations:[{start:{line:10,column:26},end:{line:10,column:42}},{start:{line:10,column:46},end:{line:10,column:59}}],line:10}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},f:{0:0,1:0,2:0,3:0},b:{0:[0,0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputMultiInput.tsx"],names:[],mappings:"AAoBa,SAIL,KAJK;AApBb,OAAO,WAAW;AAClB,OAAO,gBAAgB;AAUvB,qBAAqB,wBAAwB,MAAM,UAAgC;AAAA,EACjF,SAAS;AACP,QAAI,UAAU,KAAK,MAAM;AACzB,QAAG,QAAQ,SAAS,KAAK,CAAC,MAAM,QAAQ,QAAQ,CAAC,CAAC,GAAG;AACnD,gBAAU,QAAQ,IAAI,OAAK,CAAC,GAAG,CAAC,CAAC;AAAA,IACnC;AAEA,UAAM,gBAAgB,KAAK,MAAM,SAAS,QAAQ,CAAC,EAAE,CAAC;AACtD,UAAM,SAAS,QAAQ,IAAI,CAAC,CAAC,KAAK,KAAK,MAAK;AAC1C,aAAO;AAAA,QAAC;AAAA;AAAA,UAEN,WAAW,WAAW,4BAA4B,EAAC,4BAA4B,QAAQ,cAAa,CAAC;AAAA,UAErG;AAAA;AAAA,cAAC;AAAA;AAAA,gBAAM,MAAK;AAAA,gBACV,MAAM,KAAK,MAAM;AAAA,gBACjB,UAAU,QAAM,KAAK,MAAM,SAAS,GAAG;AAAA,gBACvC,OAAO;AAAA,gBACP,SAAS,QAAQ;AAAA;AAAA,YACnB;AAAA,YACC;AAAA;AAAA;AAAA,QATI;AAAA,MAUP;AAAA,IACF,CAAC;AAED,WAAO,oBAAC,cAAS,WAAU,wBAAuB,cAAY,KAAK,MAAM,YAAY,GAClF,kBACH;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c4660c9ecb80d9f1ce71e70441154e1e765b77ab"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return nl=function(){return s},s}nl();class o6e extends bn.Component{render(){nl().f[0]++;let n=(nl().s[0]++,this.props.options);nl().s[1]++,nl().b[1][0]++,n.length>0&&(nl().b[1][1]++,!Array.isArray(n[0]))?(nl().b[0][0]++,nl().s[2]++,n=n.map(i=>(nl().f[1]++,nl().s[3]++,[i,i]))):nl().b[0][1]++;const t=(nl().s[4]++,nl().b[2][0]++,this.props.value||(nl().b[2][1]++,n[0][0])),r=(nl().s[5]++,n.map(([i,o])=>(nl().f[2]++,nl().s[6]++,N.jsxs("label",{className:Af("maputnik-radio-as-button",{"maputnik-button-selected":i===t}),children:[N.jsx("input",{type:"radio",name:this.props.name,onChange:s=>(nl().f[3]++,nl().s[7]++,this.props.onChange(i)),value:i,checked:i===t}),o]},i))));return nl().s[8]++,N.jsx("fieldset",{className:"maputnik-multibutton","aria-label":this.props["aria-label"],children:r})}}function ns(){var e="/home/runner/work/maputnik/maputnik/src/components/InputEnum.tsx",n="d905b5da4422f2b84d44f87b04fda3de421542f5",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputEnum.tsx",statementMap:{0:{start:{line:6,column:12},end:{line:6,column:13}},1:{start:{line:7,column:2},end:{line:9,column:5}},2:{start:{line:8,column:4},end:{line:8,column:24}},3:{start:{line:10,column:2},end:{line:10,column:13}},4:{start:{line:14,column:54},end:{line:14,column:64}},5:{start:{line:15,column:4},end:{line:36,column:5}},6:{start:{line:16,column:6},end:{line:25,column:8}},7:{start:{line:27,column:6},end:{line:35,column:8}}},fnMap:{0:{name:"optionsLabelLength",decl:{start:{line:5,column:9},end:{line:5,column:27}},loc:{start:{line:5,column:37},end:{line:11,column:1}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:7,column:18},end:{line:7,column:19}},loc:{start:{line:7,column:34},end:{line:9,column:3}},line:7},2:{name:"(anonymous_2)",decl:{start:{line:13,column:2},end:{line:13,column:3}},loc:{start:{line:13,column:11},end:{line:37,column:3}},line:13}},branchMap:{0:{loc:{start:{line:15,column:4},end:{line:36,column:5}},type:"if",locations:[{start:{line:15,column:4},end:{line:36,column:5}},{start:{line:26,column:11},end:{line:36,column:5}}],line:15},1:{loc:{start:{line:15,column:8},end:{line:15,column:64}},type:"binary-expr",locations:[{start:{line:15,column:8},end:{line:15,column:27}},{start:{line:15,column:31},end:{line:15,column:64}}],line:15},2:{loc:{start:{line:21,column:17},end:{line:21,column:44}},type:"binary-expr",locations:[{start:{line:21,column:17},end:{line:21,column:22}},{start:{line:21,column:26},end:{line:21,column:44}}],line:21},3:{loc:{start:{line:23,column:24},end:{line:23,column:57}},type:"binary-expr",locations:[{start:{line:23,column:24},end:{line:23,column:48}},{start:{line:23,column:52},end:{line:23,column:57}}],line:23},4:{loc:{start:{line:31,column:17},end:{line:31,column:44}},type:"binary-expr",locations:[{start:{line:31,column:17},end:{line:31,column:22}},{start:{line:31,column:26},end:{line:31,column:44}}],line:31},5:{loc:{start:{line:33,column:24},end:{line:33,column:57}},type:"binary-expr",locations:[{start:{line:33,column:24},end:{line:33,column:48}},{start:{line:33,column:52},end:{line:33,column:57}}],line:33}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0},f:{0:0,1:0,2:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputEnum.tsx"],names:[],mappings:"AAgCa;AAhCb,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,qBAAqB;AAG5B,SAAS,mBAAmB,SAAgB;AAC1C,MAAI,MAAM;AACV,UAAQ,QAAQ,CAAC,CAAC,GAAG,KAAK,MAAM;AAC9B,WAAO,MAAM;AAAA,EACf,CAAC;AACD,SAAO;AACT;AAgBA,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,UAAM,EAAC,SAAS,OAAO,UAAU,MAAM,MAAK,IAAI,KAAK;AAErD,QAAG,QAAQ,UAAU,KAAK,mBAAmB,OAAO,KAAK,IAAI;AAC3D,aAAO;AAAA,QAAC;AAAA;AAAA,UACN;AAAA,UACA;AAAA,UACA,OAAQ,SAAS,KAAK,MAAM;AAAA,UAC5B;AAAA,UACA,cAAY,KAAK,MAAM,YAAY,KAAK;AAAA;AAAA,MAC1C;AAAA,IACF,OAAO;AACL,aAAO;AAAA,QAAC;AAAA;AAAA,UACN;AAAA,UACA,OAAQ,SAAS,KAAK,MAAM;AAAA,UAC5B;AAAA,UACA,cAAY,KAAK,MAAM,YAAY,KAAK;AAAA;AAAA,MAC1C;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"d905b5da4422f2b84d44f87b04fda3de421542f5"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ns=function(){return s},s}ns();function a6e(e){ns().f[0]++;let n=(ns().s[0]++,0);return ns().s[1]++,e.forEach(([t,r])=>{ns().f[1]++,ns().s[2]++,n+=r.length}),ns().s[3]++,n}class $8 extends bn.Component{render(){ns().f[2]++;const{options:n,value:t,onChange:r,name:i,label:o}=(ns().s[4]++,this.props);return ns().s[5]++,ns().b[1][0]++,n.length<=3&&(ns().b[1][1]++,a6e(n)<=20)?(ns().b[0][0]++,ns().s[6]++,N.jsx(o6e,{name:i,options:n,value:(ns().b[2][0]++,t||(ns().b[2][1]++,this.props.default)),onChange:r,"aria-label":(ns().b[3][0]++,this.props["aria-label"]||(ns().b[3][1]++,o))})):(ns().b[0][1]++,ns().s[7]++,N.jsx(w1,{options:n,value:(ns().b[4][0]++,t||(ns().b[4][1]++,this.props.default)),onChange:r,"aria-label":(ns().b[5][0]++,this.props["aria-label"]||(ns().b[5][1]++,o))}))}}function l4(){var e="/home/runner/work/maputnik/maputnik/src/components/SmallError.tsx",n="74f20da146753d9876d7a8eb2810e9f5402ba306",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/SmallError.tsx",statementMap:{0:{start:{line:6,column:4},end:{line:9,column:9}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:10,column:3}},line:5}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/SmallError.tsx"],names:[],mappings:"AAYM;AAZN,OAAO,WAAW;AAClB,OAAO;AAQP,qBAAqB,mBAAmB,MAAM,UAA2B;AAAA,EACvE,SAAU;AACR,WACE,qBAAC,SAAI,WAAU,cAAa;AAAA;AAAA,MAClB,KAAK,MAAM;AAAA,OACrB;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"74f20da146753d9876d7a8eb2810e9f5402ba306"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return l4=function(){return s},s}l4();class uP extends bn.Component{render(){return l4().f[0]++,l4().s[0]++,N.jsxs("div",{className:"SmallError",children:["Error: ",this.props.children]})}}function wi(){var e="/home/runner/work/maputnik/maputnik/src/components/InputUrl.tsx",n="a46ad84e5c054cc551de3c721f37ad4b7c2acd0b",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputUrl.tsx",statementMap:{0:{start:{line:6,column:2},end:{line:8,column:3}},1:{start:{line:7,column:4},end:{line:7,column:11}},2:{start:{line:10,column:22},end:{line:17,column:3}},3:{start:{line:11,column:4},end:{line:16,column:5}},4:{start:{line:12,column:21},end:{line:12,column:34}},5:{start:{line:13,column:6},end:{line:13,column:29}},6:{start:{line:15,column:6},end:{line:15,column:20}},7:{start:{line:18,column:19},end:{line:18,column:35}},8:{start:{line:19,column:16},end:{line:19,column:53}},9:{start:{line:20,column:2},end:{line:35,column:3}},10:{start:{line:21,column:4},end:{line:28,column:9}},11:{start:{line:29,column:9},end:{line:35,column:3}},12:{start:{line:30,column:4},end:{line:34,column:9}},13:{start:{line:36,column:2},end:{line:36,column:15}},14:{start:{line:39,column:24},end:{line:42,column:3}},15:{start:{line:44,column:4},end:{line:44,column:17}},16:{start:{line:45,column:4},end:{line:47,column:6}},17:{start:{line:49,column:12},end:{line:55,column:3}},18:{start:{line:50,column:4},end:{line:52,column:7}},19:{start:{line:53,column:4},end:{line:54,column:30}},20:{start:{line:54,column:6},end:{line:54,column:30}},21:{start:{line:56,column:13},end:{line:61,column:3}},22:{start:{line:57,column:4},end:{line:59,column:7}},23:{start:{line:60,column:4},end:{line:60,column:29}},24:{start:{line:63,column:4},end:{line:74,column:9}}},fnMap:{0:{name:"validate",decl:{start:{line:5,column:9},end:{line:5,column:17}},loc:{start:{line:5,column:23},end:{line:37,column:1}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:10,column:22},end:{line:10,column:23}},loc:{start:{line:10,column:32},end:{line:17,column:3}},line:10},2:{name:"(anonymous_2)",decl:{start:{line:40,column:13},end:{line:40,column:14}},loc:{start:{line:40,column:19},end:{line:41,column:5}},line:40},3:{name:"(anonymous_3)",decl:{start:{line:43,column:2},end:{line:43,column:3}},loc:{start:{line:43,column:21},end:{line:48,column:3}},line:43},4:{name:"(anonymous_4)",decl:{start:{line:49,column:12},end:{line:49,column:13}},loc:{start:{line:49,column:21},end:{line:55,column:3}},line:49},5:{name:"(anonymous_5)",decl:{start:{line:56,column:13},end:{line:56,column:14}},loc:{start:{line:56,column:22},end:{line:61,column:3}},line:56},6:{name:"(anonymous_6)",decl:{start:{line:62,column:2},end:{line:62,column:3}},loc:{start:{line:62,column:11},end:{line:75,column:3}},line:62}},branchMap:{0:{loc:{start:{line:6,column:2},end:{line:8,column:3}},type:"if",locations:[{start:{line:6,column:2},end:{line:8,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:6},1:{loc:{start:{line:20,column:2},end:{line:35,column:3}},type:"if",locations:[{start:{line:20,column:2},end:{line:35,column:3}},{start:{line:29,column:9},end:{line:35,column:3}}],line:20},2:{loc:{start:{line:23,column:6},end:{line:27,column:10}},type:"cond-expr",locations:[{start:{line:23,column:30},end:{line:23,column:67}},{start:{line:23,column:86},end:{line:27,column:10}}],line:23},3:{loc:{start:{line:29,column:9},end:{line:35,column:3}},type:"if",locations:[{start:{line:29,column:9},end:{line:35,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:29},4:{loc:{start:{line:29,column:13},end:{line:29,column:86}},type:"binary-expr",locations:[{start:{line:29,column:13},end:{line:29,column:21}},{start:{line:29,column:25},end:{line:29,column:45}},{start:{line:29,column:49},end:{line:29,column:86}}],line:29},5:{loc:{start:{line:53,column:4},end:{line:54,column:30}},type:"if",locations:[{start:{line:53,column:4},end:{line:54,column:30}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:53}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0,0],5:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputUrl.tsx"],names:["url"],mappings:"AA4Bc,SACA,UADA,KACA,YADA;AA5Bd,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,gBAAgB;AAGvB,SAAS,SAAS,KAAa;AAC7B,MAAI,QAAQ,IAAI;AACd;AAAA,EACF;AAEA,MAAI;AACJ,QAAM,cAAc,CAACA,SAAgB;AACnC,QAAI;AACF,YAAM,SAAS,IAAI,IAAIA,IAAG;AAC1B,aAAO,OAAO;AAAA,IAChB,SACO,KAAK;AACV,aAAO;AAAA,IACT;AAAA,EACF;AACA,QAAM,WAAW,YAAY,GAAG;AAChC,QAAM,QAAQ,OAAO,SAAS,aAAa;AAE3C,MAAI,CAAC,UAAU;AACb,YACE,qBAAC,cAAW;AAAA;AAAA,MAER,QACI,oBAAC,UAAK,sBAAQ,IACd,iCAAE;AAAA,4BAAC,UAAK,qBAAO;AAAA,QAAO;AAAA,QAAI,oBAAC,UAAK,sBAAQ;AAAA,SAAO;AAAA,OAEvD;AAAA,EAEJ,WAEE,YACA,aAAa,WACb,OAAO,SAAS,aAAa,UAC7B;AACA,YACE,qBAAC,cAAW;AAAA;AAAA,MACyE,oBAAC,UAAK,sBAAQ;AAAA,MAAO;AAAA,OAC1G;AAAA,EAEJ;AAEA,SAAO;AACT;AAoBA,qBAAqB,iBAAiB,MAAM,UAAwC;AAAA,EAClF,OAAO,eAAe;AAAA,IACpB,SAAS,MAAM;AAAA,IAAC;AAAA,EAClB;AAAA,EAEA,YAAa,OAAsB;AACjC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,OAAO,SAAS,MAAM,KAAK;AAAA,IAC7B;AAAA,EACF;AAAA,EAEA,UAAU,CAAC,QAAgB;AACzB,SAAK,SAAS;AAAA,MACZ,OAAO,SAAS,GAAG;AAAA,IACrB,CAAC;AACD,QAAI,KAAK,MAAM;AAAS,WAAK,MAAM,QAAQ,GAAG;AAAA,EAChD;AAAA,EAEA,WAAW,CAAC,QAAgB;AAC1B,SAAK,SAAS;AAAA,MACZ,OAAO,SAAS,GAAG;AAAA,IACrB,CAAC;AACD,SAAK,MAAM,SAAS,GAAG;AAAA,EACzB;AAAA,EAEA,SAAU;AACR,WACE,qBAAC,SACC;AAAA;AAAA,QAAC;AAAA;AAAA,UACE,GAAG,KAAK;AAAA,UACT,SAAS,KAAK;AAAA,UACd,UAAU,KAAK;AAAA,UACf,cAAY,KAAK,MAAM,YAAY;AAAA;AAAA,MACrC;AAAA,MACC,KAAK,MAAM;AAAA,OACd;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a46ad84e5c054cc551de3c721f37ad4b7c2acd0b"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return wi=function(){return s},s}wi();function iS(e){if(wi().f[0]++,wi().s[0]++,e===""){wi().b[0][0]++,wi().s[1]++;return}else wi().b[0][1]++;let n;wi().s[2]++;const t=o=>{wi().f[1]++,wi().s[3]++;try{const s=(wi().s[4]++,new URL(o));return wi().s[5]++,s.protocol}catch{wi().s[6]++;return}},r=(wi().s[7]++,t(e)),i=(wi().s[8]++,window.location.protocol==="https:");return wi().s[9]++,r?(wi().b[1][1]++,wi().s[11]++,wi().b[4][0]++,r&&(wi().b[4][1]++,r==="http:")&&(wi().b[4][2]++,window.location.protocol==="https:")?(wi().b[3][0]++,wi().s[12]++,n=N.jsxs(uP,{children:["CORS policy won't allow fetching resources served over http from https, use a ",N.jsx("code",{children:"https://"})," domain"]})):wi().b[3][1]++):(wi().b[1][0]++,wi().s[10]++,n=N.jsxs(uP,{children:["Must provide protocol ",i?(wi().b[2][0]++,N.jsx("code",{children:"https://"})):(wi().b[2][1]++,N.jsxs(N.Fragment,{children:[N.jsx("code",{children:"http://"})," or ",N.jsx("code",{children:"https://"})]}))]})),wi().s[13]++,n}var CS;let Y8=(CS=class extends bn.Component{constructor(t){wi().f[3]++,wi().s[15]++;super(t);nn(this,"onInput",(wi().s[17]++,t=>{wi().f[4]++,wi().s[18]++,this.setState({error:iS(t)}),wi().s[19]++,this.props.onInput?(wi().b[5][0]++,wi().s[20]++,this.props.onInput(t)):wi().b[5][1]++}));nn(this,"onChange",(wi().s[21]++,t=>{wi().f[5]++,wi().s[22]++,this.setState({error:iS(t)}),wi().s[23]++,this.props.onChange(t)}));wi().s[16]++,this.state={error:iS(t.value)}}render(){return wi().f[6]++,wi().s[24]++,N.jsxs("div",{children:[N.jsx(Sd,{...this.props,onInput:this.onInput,onChange:this.onChange,"aria-label":this.props["aria-label"]}),this.state.error]})}},nn(CS,"defaultProps",(wi().s[14]++,{onInput:()=>{wi().f[2]++}})),CS);function Ar(){var e="/home/runner/work/maputnik/maputnik/src/components/InputDynamicArray.tsx",n="a9b629853605b137778e6e7df9c6ca743543c2f4",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputDynamicArray.tsx",statementMap:{0:{start:{line:13,column:19},end:{line:13,column:39}},1:{start:{line:14,column:4},end:{line:14,column:27}},2:{start:{line:15,column:4},end:{line:16,column:34}},3:{start:{line:16,column:6},end:{line:16,column:34}},4:{start:{line:19,column:4},end:{line:19,column:56}},5:{start:{line:21,column:13},end:{line:36,column:3}},6:{start:{line:22,column:19},end:{line:22,column:39}},7:{start:{line:23,column:4},end:{line:33,column:5}},8:{start:{line:24,column:6},end:{line:24,column:21}},9:{start:{line:25,column:11},end:{line:33,column:5}},10:{start:{line:26,column:6},end:{line:26,column:22}},11:{start:{line:27,column:11},end:{line:33,column:5}},12:{start:{line:28,column:28},end:{line:28,column:38}},13:{start:{line:29,column:27},end:{line:29,column:59}},14:{start:{line:30,column:6},end:{line:30,column:32}},15:{start:{line:32,column:6},end:{line:32,column:22}},16:{start:{line:34,column:4},end:{line:35,column:34}},17:{start:{line:35,column:6},end:{line:35,column:34}},18:{start:{line:38,column:19},end:{line:38,column:39}},19:{start:{line:39,column:4},end:{line:39,column:31}},20:{start:{line:40,column:4},end:{line:41,column:63}},21:{start:{line:41,column:6},end:{line:41,column:63}},22:{start:{line:44,column:19},end:{line:98,column:6}},23:{start:{line:45,column:45},end:{line:45,column:117}},24:{start:{line:47,column:6},end:{line:85,column:7}},25:{start:{line:48,column:8},end:{line:55,column:10}},26:{start:{line:56,column:13},end:{line:85,column:7}},27:{start:{line:57,column:8},end:{line:64,column:10}},28:{start:{line:65,column:13},end:{line:85,column:7}},29:{start:{line:66,column:24},end:{line:66,column:99}},30:{start:{line:66,column:78},end:{line:66,column:98}},31:{start:{line:67,column:8},end:{line:75,column:10}},32:{start:{line:77,column:8},end:{line:84,column:10}},33:{start:{line:86,column:6},end:{line:97,column:8}},34:{start:{line:99,column:4},end:{line:109,column:9}},35:{start:{line:114,column:4},end:{line:127,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:12,column:2},end:{line:12,column:3}},loc:{start:{line:12,column:29},end:{line:17,column:3}},line:12},1:{name:"(anonymous_1)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:15},end:{line:20,column:3}},line:18},2:{name:"(anonymous_2)",decl:{start:{line:21,column:13},end:{line:21,column:14}},loc:{start:{line:21,column:19},end:{line:36,column:3}},line:21},3:{name:"(anonymous_3)",decl:{start:{line:37,column:2},end:{line:37,column:3}},loc:{start:{line:37,column:24},end:{line:42,column:3}},line:37},4:{name:"(anonymous_4)",decl:{start:{line:43,column:2},end:{line:43,column:3}},loc:{start:{line:43,column:11},end:{line:110,column:3}},line:43},5:{name:"(anonymous_5)",decl:{start:{line:44,column:35},end:{line:44,column:36}},loc:{start:{line:44,column:45},end:{line:98,column:5}},line:44},6:{name:"(anonymous_6)",decl:{start:{line:66,column:70},end:{line:66,column:71}},loc:{start:{line:66,column:78},end:{line:66,column:98}},line:66},7:{name:"(anonymous_7)",decl:{start:{line:113,column:2},end:{line:113,column:3}},loc:{start:{line:113,column:11},end:{line:128,column:3}},line:113}},branchMap:{0:{loc:{start:{line:15,column:4},end:{line:16,column:34}},type:"if",locations:[{start:{line:15,column:4},end:{line:16,column:34}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:15},1:{loc:{start:{line:19,column:11},end:{line:19,column:55}},type:"binary-expr",locations:[{start:{line:19,column:11},end:{line:19,column:27}},{start:{line:19,column:31},end:{line:19,column:49}},{start:{line:19,column:53},end:{line:19,column:55}}],line:19},2:{loc:{start:{line:23,column:4},end:{line:33,column:5}},type:"if",locations:[{start:{line:23,column:4},end:{line:33,column:5}},{start:{line:25,column:11},end:{line:33,column:5}}],line:23},3:{loc:{start:{line:25,column:11},end:{line:33,column:5}},type:"if",locations:[{start:{line:25,column:11},end:{line:33,column:5}},{start:{line:27,column:11},end:{line:33,column:5}}],line:25},4:{loc:{start:{line:27,column:11},end:{line:33,column:5}},type:"if",locations:[{start:{line:27,column:11},end:{line:33,column:5}},{start:{line:31,column:11},end:{line:33,column:5}}],line:27},5:{loc:{start:{line:34,column:4},end:{line:35,column:34}},type:"if",locations:[{start:{line:34,column:4},end:{line:35,column:34}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:34},6:{loc:{start:{line:40,column:4},end:{line:41,column:63}},type:"if",locations:[{start:{line:40,column:4},end:{line:41,column:63}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:40},7:{loc:{start:{line:41,column:26},end:{line:41,column:61}},type:"cond-expr",locations:[{start:{line:41,column:46},end:{line:41,column:52}},{start:{line:41,column:55},end:{line:41,column:61}}],line:41},8:{loc:{start:{line:47,column:6},end:{line:85,column:7}},type:"if",locations:[{start:{line:47,column:6},end:{line:85,column:7}},{start:{line:56,column:13},end:{line:85,column:7}}],line:47},9:{loc:{start:{line:53,column:26},end:{line:53,column:70}},type:"binary-expr",locations:[{start:{line:53,column:26},end:{line:53,column:50}},{start:{line:53,column:54},end:{line:53,column:70}}],line:53},10:{loc:{start:{line:56,column:13},end:{line:85,column:7}},type:"if",locations:[{start:{line:56,column:13},end:{line:85,column:7}},{start:{line:65,column:13},end:{line:85,column:7}}],line:56},11:{loc:{start:{line:62,column:26},end:{line:62,column:70}},type:"binary-expr",locations:[{start:{line:62,column:26},end:{line:62,column:50}},{start:{line:62,column:54},end:{line:62,column:70}}],line:62},12:{loc:{start:{line:65,column:13},end:{line:85,column:7}},type:"if",locations:[{start:{line:65,column:13},end:{line:85,column:7}},{start:{line:76,column:13},end:{line:85,column:7}}],line:65},13:{loc:{start:{line:73,column:26},end:{line:73,column:70}},type:"binary-expr",locations:[{start:{line:73,column:26},end:{line:73,column:50}},{start:{line:73,column:54},end:{line:73,column:70}}],line:73},14:{loc:{start:{line:82,column:26},end:{line:82,column:70}},type:"binary-expr",locations:[{start:{line:82,column:26},end:{line:82,column:50}},{start:{line:82,column:54},end:{line:82,column:70}}],line:82}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0},b:{0:[0,0],1:[0,0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputDynamicArray.tsx"],names:["v"],mappings:"AAiE4B,cAiCf,YAjCe;AAjE5B,OAAO,WAAW;AAClB,OAAO,gBAAgB;AACvB,SAAQ,gBAAe;AAEvB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,mBAAmB;AAC1B,OAAO,eAAe;AACtB,OAAO,cAAc;AAiBrB,qBAAqB,0BAA0B,MAAM,UAAkC;AAAA,EACrF,YAAY,KAAa,UAAuC;AAC9D,UAAM,SAAS,KAAK,OAAO,MAAM,CAAC;AAClC,WAAO,GAAG,IAAI;AACd,QAAI,KAAK,MAAM;AAAU,WAAK,MAAM,SAAS,MAAM;AAAA,EACrD;AAAA,EAEA,IAAI,SAAS;AACX,WAAO,KAAK,MAAM,SAAS,KAAK,MAAM,WAAW,CAAC;AAAA,EACpD;AAAA,EAEA,WAAW,MAAM;AACf,UAAM,SAAS,KAAK,OAAO,MAAM,CAAC;AAClC,QAAI,KAAK,MAAM,SAAS,UAAU;AAChC,aAAO,KAAK,CAAC;AAAA,IACf,WACS,KAAK,MAAM,SAAS,OAAO;AAClC,aAAO,KAAK,EAAE;AAAA,IAChB,WACS,KAAK,MAAM,SAAS,QAAQ;AACnC,YAAM,EAAC,UAAS,IAAI,KAAK;AACzB,YAAM,eAAe,OAAO,KAAK,UAAW,MAAM,EAAE,CAAC;AACrD,aAAO,KAAK,YAAY;AAAA,IAC1B,OAAO;AACL,aAAO,KAAK,EAAE;AAAA,IAChB;AAEA,QAAI,KAAK,MAAM;AAAU,WAAK,MAAM,SAAS,MAAM;AAAA,EACrD;AAAA,EAEA,YAAY,UAAkB;AAC5B,UAAM,SAAS,KAAK,OAAO,MAAM,CAAC;AAClC,WAAO,OAAO,UAAU,CAAC;AAEzB,QAAI,KAAK,MAAM;AAAU,WAAK,MAAM,SAAS,OAAO,SAAS,IAAI,SAAS,MAAS;AAAA,EACrF;AAAA,EAEA,SAAS;AACP,UAAM,SAAS,KAAK,OAAO,IAAI,CAAC,GAAG,MAAM;AACvC,YAAM,iBAAgB,oBAAC,0BAAuB,SAAS,KAAK,YAAY,KAAK,MAAM,CAAC,GAAG;AACvF,UAAI;AACJ,UAAG,KAAK,MAAM,SAAS,OAAO;AAC5B,gBAAQ;AAAA,UAAC;AAAA;AAAA,YACP,OAAO;AAAA,YACP,UAAU,KAAK,YAAY,KAAK,MAAM,CAAC;AAAA,YACvC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA;AAAA,QACrD;AAAA,MACF,WACS,KAAK,MAAM,SAAS,UAAU;AACrC,gBAAQ;AAAA,UAAC;AAAA;AAAA,YACP,OAAO;AAAA,YACP,UAAU,KAAK,YAAY,KAAK,MAAM,CAAC;AAAA,YACvC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA;AAAA,QACrD;AAAA,MACF,WACS,KAAK,MAAM,SAAS,QAAQ;AACnC,cAAM,UAAU,OAAO,KAAK,KAAK,MAAM,WAAW,MAAM,EAAE,IAAI,CAAAA,OAAK,CAACA,IAAG,WAAWA,EAAC,CAAC,CAAC;AACrF,gBAAQ;AAAA,UAAC;AAAA;AAAA,YACP;AAAA,YACA,OAAO;AAAA,YACP,UAAU,KAAK,YAAY,KAAK,MAAM,CAAC;AAAA,YACvC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA;AAAA,QACrD;AAAA,MACF,OACK;AACH,gBAAQ;AAAA,UAAC;AAAA;AAAA,YACP,OAAO;AAAA,YACP,UAAU,KAAK,YAAY,KAAK,MAAM,CAAC;AAAA,YACvC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA;AAAA,QACrD;AAAA,MACF;AAEA,aAAO;AAAA,QAAC;AAAA;AAAA,UACN,OAAO,KAAK,MAAM;AAAA,UAElB,WAAU;AAAA,UAEV;AAAA,gCAAC,SAAI,WAAU,+BACZ,0BACH;AAAA,YACA,oBAAC,SAAI,WAAU,gCACZ,iBACH;AAAA;AAAA;AAAA,QARK;AAAA,MASP;AAAA,IACF,CAAC;AAED,WACE,qBAAC,SAAI,WAAU,kBACZ;AAAA;AAAA,MACD;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,SAAS,KAAK;AAAA,UACf;AAAA;AAAA,MAED;AAAA,OACF;AAAA,EAEJ;AACF;AAMA,MAAM,+BAA+B,MAAM,UAAuC;AAAA,EAChF,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,SAAS,KAAK,MAAM;AAAA,QACpB,OAAM;AAAA,QAEN;AAAA,UAAC;AAAA;AAAA,YACC,OAAO,oBAAC,YAAS;AAAA;AAAA,QACnB;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a9b629853605b137778e6e7df9c6ca743543c2f4"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Ar=function(){return s},s}Ar();let GN=class extends bn.Component{constructor(){super(...arguments);nn(this,"addValue",(Ar().s[5]++,()=>{Ar().f[2]++;const t=(Ar().s[6]++,this.values.slice(0));if(Ar().s[7]++,this.props.type==="number")Ar().b[2][0]++,Ar().s[8]++,t.push(0);else if(Ar().b[2][1]++,Ar().s[9]++,this.props.type==="url")Ar().b[3][0]++,Ar().s[10]++,t.push("");else if(Ar().b[3][1]++,Ar().s[11]++,this.props.type==="enum"){Ar().b[4][0]++;const{fieldSpec:r}=(Ar().s[12]++,this.props),i=(Ar().s[13]++,Object.keys(r.values)[0]);Ar().s[14]++,t.push(i)}else Ar().b[4][1]++,Ar().s[15]++,t.push("");Ar().s[16]++,this.props.onChange?(Ar().b[5][0]++,Ar().s[17]++,this.props.onChange(t)):Ar().b[5][1]++}))}changeValue(t,r){Ar().f[0]++;const i=(Ar().s[0]++,this.values.slice(0));Ar().s[1]++,i[t]=r,Ar().s[2]++,this.props.onChange?(Ar().b[0][0]++,Ar().s[3]++,this.props.onChange(i)):Ar().b[0][1]++}get values(){return Ar().f[1]++,Ar().s[4]++,Ar().b[1][0]++,this.props.value||(Ar().b[1][1]++,this.props.default)||(Ar().b[1][2]++,[])}deleteValue(t){Ar().f[3]++;const r=(Ar().s[18]++,this.values.slice(0));Ar().s[19]++,r.splice(t,1),Ar().s[20]++,this.props.onChange?(Ar().b[6][0]++,Ar().s[21]++,this.props.onChange(r.length>0?(Ar().b[7][0]++,r):(Ar().b[7][1]++,void 0))):Ar().b[6][1]++}render(){Ar().f[4]++;const t=(Ar().s[22]++,this.values.map((r,i)=>{var a;Ar().f[5]++;const o=(Ar().s[23]++,N.jsx(s6e,{onClick:this.deleteValue.bind(this,i)}));let s;if(Ar().s[24]++,this.props.type==="url")Ar().b[8][0]++,Ar().s[25]++,s=N.jsx(Y8,{value:r,onChange:this.changeValue.bind(this,i),"aria-label":(Ar().b[9][0]++,this.props["aria-label"]||(Ar().b[9][1]++,this.props.label))});else if(Ar().b[8][1]++,Ar().s[26]++,this.props.type==="number")Ar().b[10][0]++,Ar().s[27]++,s=N.jsx(pf,{value:r,onChange:this.changeValue.bind(this,i),"aria-label":(Ar().b[11][0]++,this.props["aria-label"]||(Ar().b[11][1]++,this.props.label))});else if(Ar().b[10][1]++,Ar().s[28]++,this.props.type==="enum"){Ar().b[12][0]++;const f=(Ar().s[29]++,Object.keys((a=this.props.fieldSpec)==null?void 0:a.values).map(g=>(Ar().f[6]++,Ar().s[30]++,[g,p8(g)])));Ar().s[31]++,s=N.jsx($8,{options:f,value:r,onChange:this.changeValue.bind(this,i),"aria-label":(Ar().b[13][0]++,this.props["aria-label"]||(Ar().b[13][1]++,this.props.label))})}else Ar().b[12][1]++,Ar().s[32]++,s=N.jsx(Sd,{value:r,onChange:this.changeValue.bind(this,i),"aria-label":(Ar().b[14][0]++,this.props["aria-label"]||(Ar().b[14][1]++,this.props.label))});return Ar().s[33]++,N.jsxs("div",{style:this.props.style,className:"maputnik-array-block",children:[N.jsx("div",{className:"maputnik-array-block-action",children:o}),N.jsx("div",{className:"maputnik-array-block-content",children:s})]},i)}));return Ar().s[34]++,N.jsxs("div",{className:"maputnik-array",children:[t,N.jsx(Ka,{className:"maputnik-array-add-value",onClick:this.addValue,children:"Add value"})]})}};class s6e extends bn.Component{render(){return Ar().f[7]++,Ar().s[35]++,N.jsx(Ka,{className:"maputnik-delete-stop",onClick:this.props.onClick,title:"Remove array item",children:N.jsx(PB,{label:N.jsx(Ly,{})})})}}function ta(){var e="/home/runner/work/maputnik/maputnik/src/components/InputFont.tsx",n="cd16dc68fc42c219caf080518fd74984d4f8d81e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputFont.tsx",statementMap:{0:{start:{line:5,column:24},end:{line:7,column:3}},1:{start:{line:9,column:16},end:{line:9,column:60}},2:{start:{line:10,column:4},end:{line:14,column:5}},3:{start:{line:11,column:6},end:{line:11,column:28}},4:{start:{line:13,column:6},end:{line:13,column:17}},5:{start:{line:17,column:26},end:{line:17,column:46}},6:{start:{line:18,column:4},end:{line:18,column:34}},7:{start:{line:19,column:27},end:{line:19,column:92}},8:{start:{line:19,column:55},end:{line:19,column:67}},9:{start:{line:19,column:83},end:{line:19,column:91}},10:{start:{line:20,column:4},end:{line:20,column:40}},11:{start:{line:23,column:19},end:{line:39,column:6}},12:{start:{line:24,column:6},end:{line:38,column:8}},13:{start:{line:32,column:52},end:{line:32,column:58}},14:{start:{line:40,column:4},end:{line:40,column:87}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:8,column:2},end:{line:8,column:3}},loc:{start:{line:8,column:15},end:{line:15,column:3}},line:8},1:{name:"(anonymous_1)",decl:{start:{line:16,column:2},end:{line:16,column:3}},loc:{start:{line:16,column:28},end:{line:21,column:3}},line:16},2:{name:"(anonymous_2)",decl:{start:{line:19,column:48},end:{line:19,column:49}},loc:{start:{line:19,column:55},end:{line:19,column:67}},line:19},3:{name:"(anonymous_3)",decl:{start:{line:19,column:76},end:{line:19,column:77}},loc:{start:{line:19,column:83},end:{line:19,column:91}},line:19},4:{name:"(anonymous_4)",decl:{start:{line:22,column:2},end:{line:22,column:3}},loc:{start:{line:22,column:11},end:{line:41,column:3}},line:22},5:{name:"(anonymous_5)",decl:{start:{line:23,column:35},end:{line:23,column:36}},loc:{start:{line:23,column:49},end:{line:39,column:5}},line:23},6:{name:"(anonymous_6)",decl:{start:{line:32,column:45},end:{line:32,column:46}},loc:{start:{line:32,column:52},end:{line:32,column:58}},line:32}},branchMap:{0:{loc:{start:{line:9,column:16},end:{line:9,column:60}},type:"binary-expr",locations:[{start:{line:9,column:16},end:{line:9,column:32}},{start:{line:9,column:36},end:{line:9,column:54}},{start:{line:9,column:58},end:{line:9,column:60}}],line:9},1:{loc:{start:{line:10,column:4},end:{line:14,column:5}},type:"if",locations:[{start:{line:10,column:4},end:{line:14,column:5}},{start:{line:12,column:11},end:{line:14,column:5}}],line:10},2:{loc:{start:{line:30,column:28},end:{line:30,column:71}},type:"binary-expr",locations:[{start:{line:30,column:28},end:{line:30,column:52}},{start:{line:30,column:56},end:{line:30,column:71}}],line:30}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{0:[0,0,0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputFont.tsx"],names:[],mappings:"AA6CQ;AA7CR,OAAO,WAAW;AAClB,OAAO,uBAAuB;AAY9B,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,OAAO,eAAe;AAAA,IACpB,OAAO,CAAC;AAAA,EACV;AAAA,EAEA,IAAI,SAAS;AACX,UAAM,MAAM,KAAK,MAAM,SAAS,KAAK,MAAM,WAAW,CAAC;AAGvD,QAAI,IAAI,IAAI,SAAO,CAAC,MAAM,IAAG;AAC3B,aAAO,IAAI,OAAO,EAAE;AAAA,IACtB,OACK;AACH,aAAO;AAAA,IACT;AAAA,EACF;AAAA,EAEA,WAAW,KAAa,UAAkB;AACxC,UAAM,gBAAgB,KAAK,OAAO,MAAM,CAAC;AACzC,kBAAc,GAAG,IAAI;AACrB,UAAM,iBAAiB,cACpB,OAAO,OAAK,MAAM,MAAS,EAC3B,OAAO,OAAK,MAAM,EAAE;AAEvB,SAAK,MAAM,SAAS,cAAc;AAAA,EACpC;AAAA,EAEA,SAAS;AACP,UAAM,SAAS,KAAK,OAAO,IAAI,CAAC,OAAO,MAAM;AAC3C,aAAO;AAAA,QAAC;AAAA;AAAA,UAGN;AAAA,YAAC;AAAA;AAAA,cACC,cAAY,KAAK,MAAM,YAAY,KAAK,KAAK,MAAM;AAAA,cACnD;AAAA,cACA,SAAS,KAAK,MAAM,OAAO,IAAI,OAAK,CAAC,GAAG,CAAC,CAAC;AAAA,cAC1C,UAAU,KAAK,WAAW,KAAK,MAAM,CAAC;AAAA;AAAA,UACxC;AAAA;AAAA,QAPK;AAAA,MAQP;AAAA,IACF,CAAC;AAED,WACE,oBAAC,QAAG,WAAU,iBACX,kBACH;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"cd16dc68fc42c219caf080518fd74984d4f8d81e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ta=function(){return s},s}ta();class QN extends bn.Component{get values(){ta().f[0]++;const n=(ta().s[1]++,ta().b[0][0]++,this.props.value||(ta().b[0][1]++,this.props.default)||(ta().b[0][2]++,[]));return ta().s[2]++,n[n.length-1]!==""?(ta().b[1][0]++,ta().s[3]++,n.concat("")):(ta().b[1][1]++,ta().s[4]++,n)}changeFont(n,t){ta().f[1]++;const r=(ta().s[5]++,this.values.slice(0));ta().s[6]++,r[n]=t;const i=(ta().s[7]++,r.filter(o=>(ta().f[2]++,ta().s[8]++,o!==void 0)).filter(o=>(ta().f[3]++,ta().s[9]++,o!=="")));ta().s[10]++,this.props.onChange(i)}render(){ta().f[4]++;const n=(ta().s[11]++,this.values.map((t,r)=>{var i;return ta().f[5]++,ta().s[12]++,N.jsx("li",{children:N.jsx(Qy,{"aria-label":(ta().b[2][0]++,this.props["aria-label"]||(ta().b[2][1]++,this.props.name)),value:t,options:(i=this.props.fonts)==null?void 0:i.map(o=>(ta().f[6]++,ta().s[13]++,[o,o])),onChange:this.changeFont.bind(this,r)})},r)}));return ta().s[14]++,N.jsx("ul",{className:"maputnik-font",children:n})}}nn(QN,"defaultProps",(ta().s[0]++,{fonts:[]}));function gi(){var e="/home/runner/work/maputnik/maputnik/src/components/InputSpec.tsx",n="f1caee37f22e060a5d19e0dd557765702fdf5851",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/InputSpec.tsx",statementMap:{0:{start:{line:13,column:23},end:{line:13,column:117}},1:{start:{line:16,column:24},end:{line:27,column:5}},2:{start:{line:25,column:30},end:{line:25,column:81}},3:{start:{line:28,column:4},end:{line:114,column:5}},4:{start:{line:30,column:8},end:{line:37,column:10}},5:{start:{line:39,column:24},end:{line:39,column:101}},6:{start:{line:39,column:82},end:{line:39,column:100}},7:{start:{line:40,column:8},end:{line:46,column:10}},8:{start:{line:51,column:8},end:{line:67,column:9}},9:{start:{line:52,column:26},end:{line:52,column:59}},10:{start:{line:53,column:10},end:{line:59,column:12}},11:{start:{line:57,column:42},end:{line:57,column:48}},12:{start:{line:61,column:10},end:{line:66,column:12}},13:{start:{line:69,column:8},end:{line:74,column:10}},14:{start:{line:76,column:8},end:{line:81,column:10}},15:{start:{line:83,column:8},end:{line:111,column:9}},16:{start:{line:84,column:10},end:{line:90,column:12}},17:{start:{line:92,column:10},end:{line:110,column:11}},18:{start:{line:93,column:12},end:{line:100,column:14}},19:{start:{line:102,column:12},end:{line:109,column:14}},20:{start:{line:113,column:8},end:{line:113,column:20}},21:{start:{line:117,column:4},end:{line:117,column:124}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:15,column:2},end:{line:15,column:3}},loc:{start:{line:15,column:15},end:{line:115,column:3}},line:15},1:{name:"(anonymous_1)",decl:{start:{line:25,column:16},end:{line:25,column:17}},loc:{start:{line:25,column:30},end:{line:25,column:81}},line:25},2:{name:"(anonymous_2)",decl:{start:{line:39,column:75},end:{line:39,column:76}},loc:{start:{line:39,column:82},end:{line:39,column:100}},line:39},3:{name:"(anonymous_3)",decl:{start:{line:57,column:35},end:{line:57,column:36}},loc:{start:{line:57,column:42},end:{line:57,column:48}},line:57},4:{name:"(anonymous_4)",decl:{start:{line:116,column:2},end:{line:116,column:3}},loc:{start:{line:116,column:11},end:{line:118,column:3}},line:116}},branchMap:{0:{loc:{start:{line:28,column:4},end:{line:114,column:5}},type:"switch",locations:[{start:{line:29,column:6},end:{line:37,column:10}},{start:{line:38,column:6},end:{line:47,column:7}},{start:{line:48,column:6},end:{line:48,column:27}},{start:{line:49,column:6},end:{line:49,column:23}},{start:{line:50,column:6},end:{line:67,column:9}},{start:{line:68,column:6},end:{line:74,column:10}},{start:{line:75,column:6},end:{line:81,column:10}},{start:{line:82,column:6},end:{line:111,column:9}},{start:{line:112,column:6},end:{line:113,column:20}}],line:28},1:{loc:{start:{line:39,column:36},end:{line:39,column:69}},type:"binary-expr",locations:[{start:{line:39,column:36},end:{line:39,column:63}},{start:{line:39,column:67},end:{line:39,column:69}}],line:39},2:{loc:{start:{line:51,column:8},end:{line:67,column:9}},type:"if",locations:[{start:{line:51,column:8},end:{line:67,column:9}},{start:{line:60,column:15},end:{line:67,column:9}}],line:51},3:{loc:{start:{line:52,column:26},end:{line:52,column:59}},type:"binary-expr",locations:[{start:{line:52,column:26},end:{line:52,column:53}},{start:{line:52,column:57},end:{line:52,column:59}}],line:52},4:{loc:{start:{line:83,column:8},end:{line:111,column:9}},type:"if",locations:[{start:{line:83,column:8},end:{line:111,column:9}},{start:{line:91,column:15},end:{line:111,column:9}}],line:83},5:{loc:{start:{line:92,column:10},end:{line:110,column:11}},type:"if",locations:[{start:{line:92,column:10},end:{line:110,column:11}},{start:{line:101,column:17},end:{line:110,column:11}}],line:92}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0,0,0,0,0,0,0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/InputSpec.tsx"],names:[],mappings:"AAwDM;AAxDN,OAAO,WAA6B;AAEpC,OAAO,gBAAqC;AAC5C,OAAO,iBAAuC;AAC9C,OAAO,mBAA2C;AAClD,OAAO,iBAAuC;AAC9C,OAAO,gBAAqC;AAC5C,OAAO,uBAAmD;AAC1D,OAAO,eAAmC;AAC1C,OAAO,uBAAmD;AAC1D,OAAO,eAAmC;AAC1C,OAAO,gBAAgB;AAEvB,MAAM,iBAAiB,CAAC,sBAAsB,gBAAgB,gBAAgB,0BAA0B,YAAY;AA0BpH,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EAErE,aAAa;AACX,UAAM,cAAc;AAAA,MAClB,OAAO,KAAK,MAAM;AAAA,MAClB,WAAW,KAAK,MAAM;AAAA,MACtB,OAAO,KAAK,MAAM;AAAA,MAClB,QAAQ,KAAK,MAAM;AAAA,MACnB,OAAO,KAAK,MAAM;AAAA,MAClB,OAAO,KAAK,MAAM;AAAA,MAClB,SAAS,KAAK,MAAM,WAAW;AAAA,MAC/B,MAAM,KAAK,MAAM;AAAA,MACjB,UAAU,CAAC,aAAmE,KAAK,MAAM,SAAU,KAAK,MAAM,WAAW,QAAQ;AAAA,MACjI,cAAc,KAAK,MAAM,YAAY;AAAA,IACvC;AACA,YAAO,KAAK,MAAM,WAAW,MAAM;AAAA,MACnC,KAAK;AAAU,eACb;AAAA,UAAC;AAAA;AAAA,YACE,GAAG;AAAA,YACJ,KAAK,KAAK,MAAM,UAAU;AAAA,YAC1B,KAAK,KAAK,MAAM,UAAU;AAAA;AAAA,QAC5B;AAAA,MAEF,KAAK,QAAQ;AACX,cAAM,UAAU,OAAO,KAAK,KAAK,MAAM,UAAU,UAAU,CAAC,CAAC,EAAE,IAAI,OAAK,CAAC,GAAG,WAAW,CAAC,CAAC,CAAC;AAE1F,eAAO;AAAA,UAAC;AAAA;AAAA,YACL,GAAG;AAAA,YACJ;AAAA;AAAA,QACF;AAAA,MACF;AAAA,MACA,KAAK;AAAA,MACL,KAAK;AAAA,MACL,KAAK;AACH,YAAI,eAAe,QAAQ,KAAK,MAAM,SAAU,KAAK,GAAG;AACtD,gBAAM,UAAU,KAAK,MAAM,UAAU,UAAU,CAAC;AAChD,iBAAO;AAAA,YAAC;AAAA;AAAA,cACL,GAAG;AAAA,cACJ,SAAS,QAAQ,IAAI,OAAK,CAAC,GAAG,CAAC,CAAC;AAAA;AAAA,UAClC;AAAA,QACF,OAAO;AACL,iBAAO;AAAA,YAAC;AAAA;AAAA,cACL,GAAG;AAAA;AAAA,UACN;AAAA,QACF;AAAA,MACF,KAAK;AAAS,eACZ;AAAA,UAAC;AAAA;AAAA,YACE,GAAG;AAAA;AAAA,QACN;AAAA,MAEF,KAAK;AAAW,eACd;AAAA,UAAC;AAAA;AAAA,YACE,GAAG;AAAA;AAAA,QACN;AAAA,MAEF,KAAK;AACH,YAAG,KAAK,MAAM,cAAc,aAAa;AACvC,iBAAO;AAAA,YAAC;AAAA;AAAA,cACL,GAAG;AAAA,cACJ,OAAO,KAAK,MAAM,UAAU;AAAA;AAAA,UAC9B;AAAA,QACF,OAAO;AACL,cAAI,KAAK,MAAM,UAAU,QAAQ;AAC/B,mBAAO;AAAA,cAAC;AAAA;AAAA,gBACL,GAAG;AAAA,gBACJ,MAAM,KAAK,MAAM,UAAU;AAAA,gBAC3B,QAAQ,KAAK,MAAM,UAAU;AAAA;AAAA,YAC/B;AAAA,UACF,OAAO;AACL,mBAAO;AAAA,cAAC;AAAA;AAAA,gBACL,GAAG;AAAA,gBACJ,WAAW,KAAK,MAAM;AAAA,gBACtB,MAAM,KAAK,MAAM,UAAU;AAAA;AAAA,YAC7B;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAAS,eAAO;AAAA,IAChB;AAAA,EACF;AAAA,EAEA,SAAS;AACP,WACE,oBAAC,SAAI,eAAa,gBAAc,KAAK,MAAM,WACxC,eAAK,WAAW,GACnB;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"f1caee37f22e060a5d19e0dd557765702fdf5851"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return gi=function(){return s},s}gi();const l6e=(gi().s[0]++,["background-pattern","fill-pattern","line-pattern","fill-extrusion-pattern","icon-image"]);let dy=class extends bn.Component{childNodes(){var t,r;gi().f[0]++;const n=(gi().s[1]++,{error:this.props.error,fieldSpec:this.props.fieldSpec,label:this.props.label,action:this.props.action,style:this.props.style,value:this.props.value,default:(t=this.props.fieldSpec)==null?void 0:t.default,name:this.props.fieldName,onChange:i=>(gi().f[1]++,gi().s[2]++,this.props.onChange(this.props.fieldName,i)),"aria-label":this.props["aria-label"]});switch(gi().s[3]++,(r=this.props.fieldSpec)==null?void 0:r.type){case"number":return gi().b[0][0]++,gi().s[4]++,N.jsx(pf,{...n,min:this.props.fieldSpec.minimum,max:this.props.fieldSpec.maximum});case"enum":gi().b[0][1]++;{const i=(gi().s[5]++,Object.keys((gi().b[1][0]++,this.props.fieldSpec.values||(gi().b[1][1]++,[]))).map(o=>(gi().f[2]++,gi().s[6]++,[o,p8(o)])));return gi().s[7]++,N.jsx($8,{...n,options:i})}case"resolvedImage":gi().b[0][2]++;case"formatted":gi().b[0][3]++;case"string":if(gi().b[0][4]++,gi().s[8]++,l6e.indexOf(this.props.fieldName)>=0){gi().b[2][0]++;const i=(gi().s[9]++,gi().b[3][0]++,this.props.fieldSpec.values||(gi().b[3][1]++,[]));return gi().s[10]++,N.jsx(Qy,{...n,options:i.map(o=>(gi().f[3]++,gi().s[11]++,[o,o]))})}else return gi().b[2][1]++,gi().s[12]++,N.jsx(Sd,{...n});case"color":return gi().b[0][5]++,gi().s[13]++,N.jsx(WN,{...n});case"boolean":return gi().b[0][6]++,gi().s[14]++,N.jsx(Q8,{...n});case"array":return gi().b[0][7]++,gi().s[15]++,this.props.fieldName==="text-font"?(gi().b[4][0]++,gi().s[16]++,N.jsx(QN,{...n,fonts:this.props.fieldSpec.values})):(gi().b[4][1]++,gi().s[17]++,this.props.fieldSpec.length?(gi().b[5][0]++,gi().s[18]++,N.jsx(NN,{...n,type:this.props.fieldSpec.value,length:this.props.fieldSpec.length})):(gi().b[5][1]++,gi().s[19]++,N.jsx(GN,{...n,fieldSpec:this.props.fieldSpec,type:this.props.fieldSpec.value})));default:return gi().b[0][8]++,gi().s[20]++,null}}render(){return gi().f[4]++,gi().s[21]++,N.jsx("div",{"data-wd-key":"spec-field:"+this.props.fieldName,children:this.childNodes()})}};function Ll(){var e="/home/runner/work/maputnik/maputnik/src/components/Fieldset.tsx",n="c96d18417df19ff6c7361e6bbaa2c1e3e999a238",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/Fieldset.tsx",statementMap:{0:{start:{line:9,column:4},end:{line:9,column:17}},1:{start:{line:10,column:4},end:{line:10,column:56}},2:{start:{line:11,column:4},end:{line:13,column:6}},3:{start:{line:15,column:16},end:{line:19,column:3}},4:{start:{line:16,column:4},end:{line:18,column:7}},5:{start:{line:21,column:4},end:{line:41,column:9}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:8,column:2},end:{line:8,column:3}},loc:{start:{line:8,column:21},end:{line:14,column:3}},line:8},1:{name:"(anonymous_1)",decl:{start:{line:15,column:16},end:{line:15,column:17}},loc:{start:{line:15,column:25},end:{line:19,column:3}},line:15},2:{name:"(anonymous_2)",decl:{start:{line:20,column:2},end:{line:20,column:3}},loc:{start:{line:20,column:11},end:{line:42,column:3}},line:20}},branchMap:{0:{loc:{start:{line:22,column:6},end:{line:29,column:10}},type:"binary-expr",locations:[{start:{line:22,column:6},end:{line:22,column:26}},{start:{line:22,column:46},end:{line:29,column:10}}],line:22},1:{loc:{start:{line:30,column:6},end:{line:30,column:130}},type:"binary-expr",locations:[{start:{line:30,column:6},end:{line:30,column:27}},{start:{line:30,column:47},end:{line:30,column:130}}],line:30},2:{loc:{start:{line:33,column:6},end:{line:40,column:7}},type:"binary-expr",locations:[{start:{line:33,column:6},end:{line:33,column:26}},{start:{line:33,column:46},end:{line:40,column:7}}],line:33},3:{loc:{start:{line:37,column:28},end:{line:37,column:60}},type:"cond-expr",locations:[{start:{line:37,column:49},end:{line:37,column:51}},{start:{line:37,column:54},end:{line:37,column:60}}],line:37}},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0,2:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/Fieldset.tsx"],names:[],mappings:"AAiCW,SAGD,KAHC;AAjCX,OAAO,WAA6B;AACpC,OAAO,mBAAmB;AAC1B,OAAO,SAAS;AAChB,OAAO,sBAAsB;AAY7B,qBAAqB,iBAAiB,MAAM,UAAwC;AAAA,EAClF;AAAA,EAEA,YAAa,OAAsB;AACjC,UAAM,KAAK;AACX,SAAK,WAAW,iBAAiB,iBAAiB;AAClD,SAAK,QAAQ;AAAA,MACX,SAAS;AAAA,IACX;AAAA,EACF;AAAA,EAEA,cAAc,CAAC,QAAiB;AAC9B,SAAK,SAAS;AAAA,MACZ,SAAS;AAAA,IACX,CAAC;AAAA,EACH;AAAA,EAEA,SAAU;AACR,WAAO,qBAAC,SAAI,WAAU,wBAAuB,MAAK,SAAQ,mBAAiB,KAAK,UAC7E;AAAA,WAAK,MAAM,aACV,oBAAC,SAAI,WAAU,8BACb;AAAA,QAAC;AAAA;AAAA,UACC,OAAO,KAAK,MAAM;AAAA,UAClB,aAAa,KAAK;AAAA,UAClB,WAAW,KAAK,MAAM;AAAA;AAAA,MACxB,GACF;AAAA,MAED,CAAC,KAAK,MAAM,aACX,oBAAC,SAAI,WAAU,8BACZ,eAAK,MAAM,OACd;AAAA,MAEF,oBAAC,SAAI,WAAU,+BACZ,eAAK,MAAM,QACd;AAAA,MACA,oBAAC,SAAI,WAAU,gCACZ,eAAK,MAAM,UACd;AAAA,MACC,KAAK,MAAM,aACV;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,OAAO,EAAC,SAAS,KAAK,MAAM,UAAU,KAAK,OAAM;AAAA,UAEjD,8BAAC,OAAI,WAAW,KAAK,MAAM,WAAW;AAAA;AAAA,MACxC;AAAA,OAEJ;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c96d18417df19ff6c7361e6bbaa2c1e3e999a238"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Ll=function(){return s},s}Ll();class E_ extends bn.Component{constructor(t){Ll().f[0]++,Ll().s[0]++;super(t);nn(this,"_labelId");nn(this,"onToggleDoc",(Ll().s[3]++,t=>{Ll().f[1]++,Ll().s[4]++,this.setState({showDoc:t})}));Ll().s[1]++,this._labelId=Oy("fieldset_label_"),Ll().s[2]++,this.state={showDoc:!1}}render(){return Ll().f[2]++,Ll().s[5]++,N.jsxs("div",{className:"maputnik-input-block",role:"group","aria-labelledby":this._labelId,children:[(Ll().b[0][0]++,this.props.fieldSpec&&(Ll().b[0][1]++,N.jsx("div",{className:"maputnik-input-block-label",children:N.jsx(PB,{label:this.props.label,onToggleDoc:this.onToggleDoc,fieldSpec:this.props.fieldSpec})}))),(Ll().b[1][0]++,!this.props.fieldSpec&&(Ll().b[1][1]++,N.jsx("div",{className:"maputnik-input-block-label",children:this.props.label}))),N.jsx("div",{className:"maputnik-input-block-action",children:this.props.action}),N.jsx("div",{className:"maputnik-input-block-content",children:this.props.children}),(Ll().b[2][0]++,this.props.fieldSpec&&(Ll().b[2][1]++,N.jsx("div",{className:"maputnik-doc-inline",style:{display:this.state.showDoc?(Ll().b[3][0]++,""):(Ll().b[3][1]++,"none")},children:N.jsx(FB,{fieldSpec:this.props.fieldSpec})})))]})}}function Qo(){var e="/home/runner/work/maputnik/maputnik/src/components/SpecField.tsx",n="adadf49dc291f98804cd53f74e320ed51f276886",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/SpecField.tsx",statementMap:{0:{start:{line:6,column:16},end:{line:16,column:1}},1:{start:{line:7,column:15},end:{line:7,column:20}},2:{start:{line:8,column:27},end:{line:8,column:87}},3:{start:{line:9,column:17},end:{line:9,column:22}},4:{start:{line:10,column:15},end:{line:10,column:23}},5:{start:{line:11,column:23},end:{line:11,column:28}},6:{start:{line:12,column:16},end:{line:12,column:21}},7:{start:{line:13,column:16},end:{line:13,column:21}},8:{start:{line:14,column:19},end:{line:14,column:24}},9:{start:{line:15,column:17},end:{line:15,column:22}},10:{start:{line:19,column:22},end:{line:19,column:48}},11:{start:{line:20,column:24},end:{line:20,column:42}},12:{start:{line:22,column:4},end:{line:27,column:5}},13:{start:{line:23,column:6},end:{line:23,column:42}},14:{start:{line:25,column:6},end:{line:25,column:55}},15:{start:{line:26,column:6},end:{line:26,column:24}},16:{start:{line:28,column:4},end:{line:36,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:9},end:{line:7,column:10}},loc:{start:{line:7,column:15},end:{line:7,column:20}},line:7},1:{name:"(anonymous_1)",decl:{start:{line:8,column:8},end:{line:8,column:9}},loc:{start:{line:8,column:27},end:{line:8,column:87}},line:8},2:{name:"(anonymous_2)",decl:{start:{line:9,column:11},end:{line:9,column:12}},loc:{start:{line:9,column:17},end:{line:9,column:22}},line:9},3:{name:"(anonymous_3)",decl:{start:{line:10,column:9},end:{line:10,column:10}},loc:{start:{line:10,column:15},end:{line:10,column:23}},line:10},4:{name:"(anonymous_4)",decl:{start:{line:11,column:17},end:{line:11,column:18}},loc:{start:{line:11,column:23},end:{line:11,column:28}},line:11},5:{name:"(anonymous_5)",decl:{start:{line:12,column:10},end:{line:12,column:11}},loc:{start:{line:12,column:16},end:{line:12,column:21}},line:12},6:{name:"(anonymous_6)",decl:{start:{line:13,column:10},end:{line:13,column:11}},loc:{start:{line:13,column:16},end:{line:13,column:21}},line:13},7:{name:"(anonymous_7)",decl:{start:{line:14,column:13},end:{line:14,column:14}},loc:{start:{line:14,column:19},end:{line:14,column:24}},line:14},8:{name:"(anonymous_8)",decl:{start:{line:15,column:11},end:{line:15,column:12}},loc:{start:{line:15,column:17},end:{line:15,column:22}},line:15},9:{name:"(anonymous_9)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:11},end:{line:37,column:3}},line:18}},branchMap:{0:{loc:{start:{line:8,column:27},end:{line:8,column:87}},type:"cond-expr",locations:[{start:{line:8,column:71},end:{line:8,column:79}},{start:{line:8,column:82},end:{line:8,column:87}}],line:8},1:{loc:{start:{line:22,column:4},end:{line:27,column:5}},type:"if",locations:[{start:{line:22,column:4},end:{line:27,column:5}},{start:{line:24,column:11},end:{line:27,column:5}}],line:22}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/SpecField.tsx"],names:[],mappings:"AA0CM;AA1CN,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,eAA0D;AACjE,OAAO,cAAc;AAGrB,MAAM,UAAU;AAAA,EACd,OAAO,MAAM;AAAA,EACb,MAAM,CAAC,EAAC,UAAS,MAAY,OAAO,KAAK,UAAU,MAAM,EAAE,UAAU,IAAI,WAAW;AAAA,EACpF,SAAS,MAAM;AAAA,EACf,OAAO,MAAM;AAAA,EACb,eAAe,MAAM;AAAA,EACrB,QAAQ,MAAM;AAAA,EACd,QAAQ,MAAM;AAAA,EACd,WAAW,MAAM;AAAA,EACjB,SAAS,MAAM;AACjB;AAMA,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,UAAM,YAAY,KAAK,MAAM,WAAW;AAExC,UAAM,cAAc,QAAQ,SAAU;AAEtC,QAAI;AACJ,QAAI,aAAa;AACf,kBAAY,YAAY,KAAK,KAAK;AAAA,IACpC,OACK;AACH,cAAQ,KAAK,yBAAyB,SAAS;AAC/C,kBAAY;AAAA,IACd;AAEA,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,OAAO,KAAK,MAAM;AAAA,QAClB,QAAQ,KAAK,MAAM;AAAA,QACnB,WAAW,KAAK,MAAM;AAAA,QAEtB,8BAAC,aAAW,GAAG,KAAK,OAAO;AAAA;AAAA,IAC7B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"adadf49dc291f98804cd53f74e320ed51f276886"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Qo=function(){return s},s}Qo();const u6e=(Qo().s[0]++,{color:()=>(Qo().f[0]++,Qo().s[1]++,Uo),enum:({fieldSpec:e})=>(Qo().f[1]++,Qo().s[2]++,Object.keys(e.values).length<=3?(Qo().b[0][0]++,E_):(Qo().b[0][1]++,Uo)),boolean:()=>(Qo().f[2]++,Qo().s[3]++,Uo),array:()=>(Qo().f[3]++,Qo().s[4]++,E_),resolvedImage:()=>(Qo().f[4]++,Qo().s[5]++,Uo),number:()=>(Qo().f[5]++,Qo().s[6]++,Uo),string:()=>(Qo().f[6]++,Qo().s[7]++,Uo),formatted:()=>(Qo().f[7]++,Qo().s[8]++,Uo),padding:()=>(Qo().f[8]++,Qo().s[9]++,Uo)});class A6e extends bn.Component{render(){var i;Qo().f[9]++;const n=(Qo().s[10]++,(i=this.props.fieldSpec)==null?void 0:i.type),t=(Qo().s[11]++,u6e[n]);let r;return Qo().s[12]++,t?(Qo().b[1][0]++,Qo().s[13]++,r=t(this.props)):(Qo().b[1][1]++,Qo().s[14]++,console.warn("No such type for '%s'",n),Qo().s[15]++,r=Uo),Qo().s[16]++,N.jsx(r,{label:this.props.label,action:this.props.action,fieldSpec:this.props.fieldSpec,children:N.jsx(dy,{...this.props})})}}function zA(){var e="/home/runner/work/maputnik/maputnik/src/components/_FunctionButtons.tsx",n="fb167a16b2bc613f08e633cf4dc0232cee30b68f",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/_FunctionButtons.tsx",statementMap:{0:{start:{line:9,column:4},end:{line:46,column:5}},1:{start:{line:10,column:6},end:{line:18,column:8}},2:{start:{line:19,column:6},end:{line:27,column:8}},3:{start:{line:28,column:6},end:{line:38,column:7}},4:{start:{line:29,column:8},end:{line:37,column:10}},5:{start:{line:39,column:6},end:{line:43,column:11}},6:{start:{line:45,column:6},end:{line:45,column:77}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:2},end:{line:7,column:3}},loc:{start:{line:7,column:11},end:{line:47,column:3}},line:7}},branchMap:{0:{loc:{start:{line:9,column:4},end:{line:46,column:5}},type:"if",locations:[{start:{line:9,column:4},end:{line:46,column:5}},{start:{line:44,column:11},end:{line:46,column:5}}],line:9},1:{loc:{start:{line:28,column:6},end:{line:38,column:7}},type:"if",locations:[{start:{line:28,column:6},end:{line:38,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:28}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},f:{0:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/_FunctionButtons.tsx"],names:[],mappings:"AAyBY,cAsBC,YAtBD;AAzBZ,OAAO,WAAW;AAElB,OAAO,iBAAiB;AACxB,SAAQ,aAAa,qBAAoB;AACzC,SAAQ,0BAAyB;AASjC,qBAAqB,6BAA6B,MAAM,UAAqC;AAAA,EAC3F,SAAS;AACP,QAAI,qBAAqB,qBAAqB;AAE9C,QAAI,KAAK,MAAM,UAAU,WAAW,WAAW,SAAS,MAAM,GAAG;AAC/D,8BACE;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,SAAS,KAAK,MAAM;AAAA,UACpB,OAAM;AAAA,UAEN,8BAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,SAAQ,GAAG,SAAQ,aAC1E,8BAAC,UAAK,MAAK,gBAAe,GAAG,oBAAoB,GACnD;AAAA;AAAA,MACF;AAGF,4BAAsB;AAAA,QAAC;AAAA;AAAA,UACrB,WAAU;AAAA,UACV,SAAS,KAAK,MAAM;AAAA,UACpB,OAAM;AAAA,UAEN,8BAAC,eAAY;AAAA;AAAA,MACf;AAEA,UAAI,KAAK,MAAM,UAAU,eAAe,MAAM,eAAe;AAC3D,8BAAsB;AAAA,UAAC;AAAA;AAAA,YACrB,WAAU;AAAA,YACV,SAAS,KAAK,MAAM;AAAA,YACpB,OAAM;AAAA,YAEN,8BAAC,iBAAc;AAAA;AAAA,QACjB;AAAA,MACF;AACA,aAAO,qBAAC,SACL;AAAA;AAAA,QACA;AAAA,QACA;AAAA,SACH;AAAA,IACF,OACK;AACH,aAAO,oBAAC,SAAK,iCAAsB;AAAA,IACrC;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"fb167a16b2bc613f08e633cf4dc0232cee30b68f"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return zA=function(){return s},s}zA();class c6e extends bn.Component{render(){zA().f[0]++;let n,t,r;return zA().s[0]++,this.props.fieldSpec.expression.parameters.includes("zoom")?(zA().b[0][0]++,zA().s[1]++,r=N.jsx(Ka,{className:"maputnik-make-zoom-function",onClick:this.props.onExpressionClick,title:"Convert to expression",children:N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"middle"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:S_})})}),zA().s[2]++,n=N.jsx(Ka,{className:"maputnik-make-zoom-function",onClick:this.props.onZoomClick,title:"Convert property into a zoom function",children:N.jsx(_J,{})}),zA().s[3]++,this.props.fieldSpec["property-type"]==="data-driven"?(zA().b[1][0]++,zA().s[4]++,t=N.jsx(Ka,{className:"maputnik-make-data-function",onClick:this.props.onDataClick,title:"Convert property to data function",children:N.jsx(bJ,{})})):zA().b[1][1]++,zA().s[5]++,N.jsxs("div",{children:[r,t,n]})):(zA().b[0][1]++,zA().s[6]++,N.jsx("div",{children:r}))}}function Qh(){var e="/home/runner/work/maputnik/maputnik/src/components/_SpecProperty.tsx",n="60f6f0f35f3e44d7e7f08e2966cfff09ee69557d",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/_SpecProperty.tsx",statementMap:{0:{start:{line:7,column:24},end:{line:9,column:3}},1:{start:{line:11,column:45},end:{line:11,column:55}},2:{start:{line:12,column:40},end:{line:20,column:5}},3:{start:{line:21,column:18},end:{line:21,column:53}},4:{start:{line:22,column:4},end:{line:31,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:10,column:2},end:{line:10,column:3}},loc:{start:{line:10,column:11},end:{line:32,column:3}},line:10}},branchMap:{0:{loc:{start:{line:28,column:34},end:{line:28,column:60}},type:"binary-expr",locations:[{start:{line:28,column:34},end:{line:28,column:54}},{start:{line:28,column:58},end:{line:28,column:60}}],line:28}},s:{0:0,1:0,2:0,3:0,4:0},f:{0:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/_SpecProperty.tsx"],names:[],mappings:"AA4BwB;AA5BxB,OAAO,WAAW;AAElB,OAAO,eAAiC;AACxC,OAAO,qBAAqB;AAE5B,OAAO,wBAAwB;AAe/B,qBAAqB,qBAAqB,MAAM,UAA6B;AAAA,EAC3E,OAAO,eAAe;AAAA,IACpB,QAAQ,CAAC;AAAA,EACX;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,QAAQ,WAAW,UAAS,IAAI,KAAK;AAE5C,UAAM,cAAc;AAAA,MAAC;AAAA;AAAA,QACnB,WAAW,KAAK,MAAM;AAAA,QACtB,aAAa,KAAK,MAAM;AAAA,QACxB,aAAa,KAAK,MAAM;AAAA,QACxB,mBAAmB,KAAK,MAAM;AAAA;AAAA,IAChC;AAEA,UAAM,QAAQ,OAAQ,YAAU,MAAI,SAAgB;AAEpD,WAAO;AAAA,MAAC;AAAA;AAAA,QACL,GAAG,KAAK;AAAA,QACT;AAAA,QACA,WAAW,KAAK,MAAM;AAAA,QACtB,OAAO,mBAAmB,KAAK,MAAM,aAAa,EAAE;AAAA,QACpD,QAAQ;AAAA;AAAA,IACV;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"60f6f0f35f3e44d7e7f08e2966cfff09ee69557d"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Qh=function(){return s},s}Qh();class $N extends bn.Component{render(){Qh().f[0]++;const{errors:n,fieldName:t,fieldType:r}=(Qh().s[1]++,this.props),i=(Qh().s[2]++,N.jsx(c6e,{fieldSpec:this.props.fieldSpec,onZoomClick:this.props.onZoomClick,onDataClick:this.props.onDataClick,onExpressionClick:this.props.onExpressionClick})),o=(Qh().s[3]++,n[r+"."+t]);return Qh().s[4]++,N.jsx(A6e,{...this.props,error:o,fieldSpec:this.props.fieldSpec,label:D5((Qh().b[0][0]++,this.props.fieldName||(Qh().b[0][1]++,""))),action:i})}}nn($N,"defaultProps",(Qh().s[0]++,{errors:{}}));function jA(){var e="/home/runner/work/maputnik/maputnik/src/libs/sort-numerically.ts",n="e8906f642b33ab7d7a780fc0db870f7e4872d29c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/sort-numerically.ts",statementMap:{0:{start:{line:2,column:12},end:{line:2,column:17}},1:{start:{line:3,column:12},end:{line:3,column:17}},2:{start:{line:4,column:2},end:{line:10,column:3}},3:{start:{line:5,column:4},end:{line:5,column:14}},4:{start:{line:6,column:9},end:{line:10,column:3}},5:{start:{line:7,column:4},end:{line:7,column:13}},6:{start:{line:9,column:4},end:{line:9,column:13}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:1,column:15},end:{line:1,column:16}},loc:{start:{line:1,column:36},end:{line:11,column:1}},line:1}},branchMap:{0:{loc:{start:{line:4,column:2},end:{line:10,column:3}},type:"if",locations:[{start:{line:4,column:2},end:{line:10,column:3}},{start:{line:6,column:9},end:{line:10,column:3}}],line:4},1:{loc:{start:{line:6,column:9},end:{line:10,column:3}},type:"if",locations:[{start:{line:6,column:9},end:{line:10,column:3}},{start:{line:8,column:9},end:{line:10,column:3}}],line:6}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},f:{0:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/sort-numerically.ts"],names:[],mappings:"AAAA,wBAAwB,MAAuB,MAAsB;AACnE,QAAM,IAAI,CAAC;AACX,QAAM,IAAI,CAAC;AAEX,MAAG,IAAI,GAAG;AACR,WAAO;AAAA,EACT,WACQ,IAAI,GAAG;AACb,WAAO;AAAA,EACT,OACK;AACH,WAAO;AAAA,EACT;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"e8906f642b33ab7d7a780fc0db870f7e4872d29c"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return jA=function(){return s},s}jA();function YN(e,n){jA().f[0]++;const t=(jA().s[0]++,+e),r=(jA().s[1]++,+n);return jA().s[2]++,t<r?(jA().b[0][0]++,jA().s[3]++,-1):(jA().b[0][1]++,jA().s[4]++,t>r?(jA().b[1][0]++,jA().s[5]++,1):(jA().b[1][1]++,jA().s[6]++,0))}function ah(){var e="/home/runner/work/maputnik/maputnik/src/libs/spec-helper.ts",n="2f98128f0f990b67a049c58486c1fab4310fbcfa",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/spec-helper.ts",statementMap:{0:{start:{line:2,column:2},end:{line:4,column:3}},1:{start:{line:3,column:4},end:{line:3,column:24}},2:{start:{line:5,column:19},end:{line:11,column:3}},3:{start:{line:12,column:2},end:{line:12,column:35}}},fnMap:{0:{name:"findDefaultFromSpec",decl:{start:{line:1,column:16},end:{line:1,column:35}},loc:{start:{line:1,column:42},end:{line:13,column:1}},line:1}},branchMap:{0:{loc:{start:{line:2,column:2},end:{line:4,column:3}},type:"if",locations:[{start:{line:2,column:2},end:{line:4,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:2},1:{loc:{start:{line:12,column:9},end:{line:12,column:34}},type:"binary-expr",locations:[{start:{line:12,column:9},end:{line:12,column:28}},{start:{line:12,column:32},end:{line:12,column:34}}],line:12}},s:{0:0,1:0,2:0,3:0},f:{0:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/spec-helper.ts"],names:[],mappings:"AAGO,gBAAS,oBAAoB,MAAyE;AAC3G,MAAI,OAAO,UAAU,eAAe,KAAK,MAAM,SAAS,GAAG;AACzD,WAAO,KAAK;AAAA,EACd;AAEA,QAAM,WAAW;AAAA,IACf,SAAS;AAAA,IACT,UAAU;AAAA,IACV,WAAW;AAAA,IACX,UAAU;AAAA,IACV,SAAS,CAAC;AAAA,EACZ;AAEA,SAAO,SAAS,KAAK,IAAI,KAAK;AAChC;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"2f98128f0f990b67a049c58486c1fab4310fbcfa"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ah=function(){return s},s}ah();function fd(e){if(ah().f[0]++,ah().s[0]++,Object.prototype.hasOwnProperty.call(e,"default"))return ah().b[0][0]++,ah().s[1]++,e.default;ah().b[0][1]++;const n=(ah().s[2]++,{color:"#000000",string:"",boolean:!1,number:0,array:[]});return ah().s[3]++,ah().b[1][0]++,n[e.type]||(ah().b[1][1]++,"")}function u4(){var e="/home/runner/work/maputnik/maputnik/src/components/_DeleteStopButton.tsx",n="7dda8ab95b7fe1e03f2205def4590751728cfeac",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/_DeleteStopButton.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:15,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:16,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/_DeleteStopButton.tsx"],names:[],mappings:"AAkBM;AAlBN,OAAO,WAAW;AAElB,OAAO,iBAAiB;AACxB,SAAQ,gBAAe;AAQvB,qBAAqB,yBAAyB,MAAM,UAAiC;AAAA,EACnF,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,SAAS,KAAK,MAAM;AAAA,QACpB,OAAO;AAAA,QAEP,8BAAC,YAAS;AAAA;AAAA,IACZ;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"7dda8ab95b7fe1e03f2205def4590751728cfeac"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return u4=function(){return s},s}u4();class qN extends bn.Component{render(){return u4().f[0]++,u4().s[0]++,N.jsx(Ka,{className:"maputnik-delete-stop",onClick:this.props.onClick,title:"Remove zoom level from stop",children:N.jsx(Ly,{})})}}function zt(){var e="/home/runner/work/maputnik/maputnik/src/components/_DataProperty.tsx",n="232a59a4721428f6ea1780ae642f941986fcb93c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/_DataProperty.tsx",statementMap:{0:{start:{line:18,column:2},end:{line:27,column:3}},1:{start:{line:19,column:4},end:{line:26,column:7}},2:{start:{line:20,column:6},end:{line:25,column:7}},3:{start:{line:21,column:8},end:{line:23,column:9}},4:{start:{line:22,column:10},end:{line:22,column:33}},5:{start:{line:24,column:8},end:{line:24,column:39}},6:{start:{line:28,column:2},end:{line:28,column:17}},7:{start:{line:31,column:10},end:{line:33,column:3}},8:{start:{line:35,column:20},end:{line:35,column:55}},9:{start:{line:36,column:4},end:{line:40,column:5}},10:{start:{line:37,column:6},end:{line:39,column:9}},11:{start:{line:43,column:20},end:{line:43,column:45}},12:{start:{line:44,column:4},end:{line:48,column:5}},13:{start:{line:45,column:6},end:{line:47,column:8}},14:{start:{line:49,column:4},end:{line:49,column:16}},15:{start:{line:52,column:4},end:{line:54,column:5}},16:{start:{line:53,column:6},end:{line:53,column:27}},17:{start:{line:55,column:4},end:{line:57,column:5}},18:{start:{line:56,column:6},end:{line:56,column:24}},19:{start:{line:58,column:4},end:{line:58,column:25}},20:{start:{line:61,column:4},end:{line:65,column:5}},21:{start:{line:62,column:6},end:{line:62,column:83}},22:{start:{line:64,column:6},end:{line:64,column:53}},23:{start:{line:69,column:26},end:{line:74,column:70}},24:{start:{line:70,column:6},end:{line:73,column:8}},25:{start:{line:74,column:22},end:{line:74,column:69}},26:{start:{line:75,column:20},end:{line:75,column:22}},27:{start:{line:76,column:4},end:{line:78,column:7}},28:{start:{line:77,column:6},end:{line:77,column:30}},29:{start:{line:79,column:4},end:{line:81,column:7}},30:{start:{line:82,column:4},end:{line:82,column:50}},31:{start:{line:82,column:39},end:{line:82,column:48}},32:{start:{line:84,column:13},end:{line:104,column:3}},33:{start:{line:85,column:4},end:{line:102,column:5}},34:{start:{line:86,column:6},end:{line:89,column:8}},35:{start:{line:91,column:24},end:{line:91,column:61}},36:{start:{line:92,column:6},end:{line:101,column:8}},37:{start:{line:103,column:4},end:{line:103,column:42}},38:{start:{line:106,column:18},end:{line:106,column:56}},39:{start:{line:107,column:4},end:{line:113,column:6}},40:{start:{line:114,column:25},end:{line:114,column:53}},41:{start:{line:115,column:25},end:{line:118,column:5}},42:{start:{line:119,column:4},end:{line:119,column:54}},43:{start:{line:122,column:25},end:{line:125,column:5}},44:{start:{line:126,column:4},end:{line:128,column:5}},45:{start:{line:127,column:6},end:{line:127,column:34}},46:{start:{line:129,column:4},end:{line:129,column:60}},47:{start:{line:132,column:4},end:{line:139,column:5}},48:{start:{line:133,column:6},end:{line:133,column:42}},49:{start:{line:135,column:6},end:{line:138,column:9}},50:{start:{line:142,column:4},end:{line:146,column:5}},51:{start:{line:143,column:6},end:{line:143,column:43}},52:{start:{line:145,column:6},end:{line:145,column:40}},53:{start:{line:147,column:4},end:{line:147,column:58}},54:{start:{line:150,column:4},end:{line:152,column:5}},55:{start:{line:151,column:6},end:{line:151,column:78}},56:{start:{line:154,column:4},end:{line:202,column:5}},57:{start:{line:155,column:6},end:{line:201,column:9}},58:{start:{line:156,column:26},end:{line:156,column:77}},59:{start:{line:157,column:20},end:{line:157,column:40}},60:{start:{line:158,column:26},end:{line:158,column:79}},61:{start:{line:159,column:22},end:{line:159,column:29}},62:{start:{line:160,column:46},end:{line:160,column:122}},63:{start:{line:161,column:26},end:{line:166,column:9}},64:{start:{line:165,column:33},end:{line:165,column:97}},65:{start:{line:168,column:8},end:{line:172,column:9}},66:{start:{line:169,column:10},end:{line:169,column:73}},67:{start:{line:171,column:10},end:{line:171,column:73}},68:{start:{line:173,column:24},end:{line:173,column:28}},69:{start:{line:174,column:8},end:{line:185,column:9}},70:{start:{line:175,column:10},end:{line:184,column:15}},71:{start:{line:180,column:37},end:{line:180,column:101}},72:{start:{line:186,column:8},end:{line:200,column:18}},73:{start:{line:196,column:41},end:{line:196,column:110}},74:{start:{line:203,column:4},end:{line:303,column:12}},75:{start:{line:214,column:39},end:{line:214,column:67}},76:{start:{line:232,column:43},end:{line:232,column:68}},77:{start:{line:247,column:39},end:{line:247,column:83}},78:{start:{line:263,column:42},end:{line:263,column:85}}},fnMap:{0:{name:"setStopRefs",decl:{start:{line:16,column:9},end:{line:16,column:20}},loc:{start:{line:16,column:35},end:{line:29,column:1}},line:16},1:{name:"(anonymous_1)",decl:{start:{line:19,column:30},end:{line:19,column:31}},loc:{start:{line:19,column:45},end:{line:26,column:5}},line:19},2:{name:"(anonymous_2)",decl:{start:{line:34,column:2},end:{line:34,column:3}},loc:{start:{line:34,column:22},end:{line:41,column:3}},line:34},3:{name:"(anonymous_3)",decl:{start:{line:42,column:2},end:{line:42,column:3}},loc:{start:{line:42,column:48},end:{line:50,column:3}},line:42},4:{name:"(anonymous_4)",decl:{start:{line:51,column:2},end:{line:51,column:3}},loc:{start:{line:51,column:34},end:{line:59,column:3}},line:51},5:{name:"(anonymous_5)",decl:{start:{line:60,column:2},end:{line:60,column:3}},loc:{start:{line:60,column:34},end:{line:66,column:3}},line:60},6:{name:"(anonymous_6)",decl:{start:{line:68,column:2},end:{line:68,column:3}},loc:{start:{line:68,column:26},end:{line:83,column:3}},line:68},7:{name:"(anonymous_7)",decl:{start:{line:69,column:36},end:{line:69,column:37}},loc:{start:{line:69,column:51},end:{line:74,column:5}},line:69},8:{name:"(anonymous_8)",decl:{start:{line:74,column:12},end:{line:74,column:13}},loc:{start:{line:74,column:22},end:{line:74,column:69}},line:74},9:{name:"(anonymous_9)",decl:{start:{line:76,column:26},end:{line:76,column:27}},loc:{start:{line:76,column:41},end:{line:78,column:5}},line:76},10:{name:"(anonymous_10)",decl:{start:{line:82,column:29},end:{line:82,column:30}},loc:{start:{line:82,column:39},end:{line:82,column:48}},line:82},11:{name:"(anonymous_11)",decl:{start:{line:84,column:13},end:{line:84,column:14}},loc:{start:{line:84,column:35},end:{line:104,column:3}},line:84},12:{name:"(anonymous_12)",decl:{start:{line:105,column:2},end:{line:105,column:3}},loc:{start:{line:105,column:41},end:{line:120,column:3}},line:105},13:{name:"(anonymous_13)",decl:{start:{line:121,column:2},end:{line:121,column:3}},loc:{start:{line:121,column:23},end:{line:130,column:3}},line:121},14:{name:"(anonymous_14)",decl:{start:{line:131,column:2},end:{line:131,column:3}},loc:{start:{line:131,column:26},end:{line:140,column:3}},line:131},15:{name:"(anonymous_15)",decl:{start:{line:141,column:2},end:{line:141,column:3}},loc:{start:{line:141,column:40},end:{line:148,column:3}},line:141},16:{name:"(anonymous_16)",decl:{start:{line:149,column:2},end:{line:149,column:3}},loc:{start:{line:149,column:11},end:{line:304,column:3}},line:149},17:{name:"(anonymous_17)",decl:{start:{line:155,column:46},end:{line:155,column:47}},loc:{start:{line:155,column:61},end:{line:201,column:7}},line:155},18:{name:"(anonymous_18)",decl:{start:{line:165,column:20},end:{line:165,column:21}},loc:{start:{line:165,column:33},end:{line:165,column:97}},line:165},19:{name:"(anonymous_19)",decl:{start:{line:180,column:24},end:{line:180,column:25}},loc:{start:{line:180,column:37},end:{line:180,column:101}},line:180},20:{name:"(anonymous_20)",decl:{start:{line:196,column:24},end:{line:196,column:25}},loc:{start:{line:196,column:41},end:{line:196,column:110}},line:196},21:{name:"(anonymous_21)",decl:{start:{line:214,column:26},end:{line:214,column:27}},loc:{start:{line:214,column:39},end:{line:214,column:67}},line:214},22:{name:"(anonymous_22)",decl:{start:{line:232,column:26},end:{line:232,column:27}},loc:{start:{line:232,column:43},end:{line:232,column:68}},line:232},23:{name:"(anonymous_23)",decl:{start:{line:247,column:26},end:{line:247,column:27}},loc:{start:{line:247,column:39},end:{line:247,column:83}},line:247},24:{name:"(anonymous_24)",decl:{start:{line:263,column:26},end:{line:263,column:27}},loc:{start:{line:263,column:42},end:{line:263,column:85}},line:263}},branchMap:{0:{loc:{start:{line:18,column:2},end:{line:27,column:3}},type:"if",locations:[{start:{line:18,column:2},end:{line:27,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:18},1:{loc:{start:{line:18,column:6},end:{line:18,column:38}},type:"binary-expr",locations:[{start:{line:18,column:6},end:{line:18,column:17}},{start:{line:18,column:21},end:{line:18,column:38}}],line:18},2:{loc:{start:{line:20,column:6},end:{line:25,column:7}},type:"if",locations:[{start:{line:20,column:6},end:{line:25,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:20},3:{loc:{start:{line:21,column:8},end:{line:23,column:9}},type:"if",locations:[{start:{line:21,column:8},end:{line:23,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:21},4:{loc:{start:{line:36,column:4},end:{line:40,column:5}},type:"if",locations:[{start:{line:36,column:4},end:{line:40,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:36},5:{loc:{start:{line:44,column:4},end:{line:48,column:5}},type:"if",locations:[{start:{line:44,column:4},end:{line:48,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:44},6:{loc:{start:{line:52,column:4},end:{line:54,column:5}},type:"if",locations:[{start:{line:52,column:4},end:{line:54,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:52},7:{loc:{start:{line:55,column:4},end:{line:57,column:5}},type:"if",locations:[{start:{line:55,column:4},end:{line:57,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:55},8:{loc:{start:{line:61,column:4},end:{line:65,column:5}},type:"if",locations:[{start:{line:61,column:4},end:{line:65,column:5}},{start:{line:63,column:11},end:{line:65,column:5}}],line:61},9:{loc:{start:{line:85,column:4},end:{line:102,column:5}},type:"if",locations:[{start:{line:85,column:4},end:{line:102,column:5}},{start:{line:90,column:11},end:{line:102,column:5}}],line:85},10:{loc:{start:{line:91,column:24},end:{line:91,column:61}},type:"cond-expr",locations:[{start:{line:91,column:55},end:{line:91,column:57}},{start:{line:91,column:60},end:{line:91,column:61}}],line:91},11:{loc:{start:{line:106,column:18},end:{line:106,column:56}},type:"binary-expr",locations:[{start:{line:106,column:18},end:{line:106,column:50}},{start:{line:106,column:54},end:{line:106,column:56}}],line:106},12:{loc:{start:{line:110,column:14},end:{line:110,column:58}},type:"cond-expr",locations:[{start:{line:110,column:41},end:{line:110,column:42}},{start:{line:110,column:45},end:{line:110,column:58}}],line:110},13:{loc:{start:{line:126,column:4},end:{line:128,column:5}},type:"if",locations:[{start:{line:126,column:4},end:{line:128,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:126},14:{loc:{start:{line:132,column:4},end:{line:139,column:5}},type:"if",locations:[{start:{line:132,column:4},end:{line:139,column:5}},{start:{line:134,column:11},end:{line:139,column:5}}],line:132},15:{loc:{start:{line:132,column:8},end:{line:132,column:70}},type:"binary-expr",locations:[{start:{line:132,column:8},end:{line:132,column:33}},{start:{line:132,column:37},end:{line:132,column:70}}],line:132},16:{loc:{start:{line:142,column:4},end:{line:146,column:5}},type:"if",locations:[{start:{line:142,column:4},end:{line:146,column:5}},{start:{line:144,column:11},end:{line:146,column:5}}],line:142},17:{loc:{start:{line:150,column:4},end:{line:152,column:5}},type:"if",locations:[{start:{line:150,column:4},end:{line:152,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:150},18:{loc:{start:{line:154,column:4},end:{line:202,column:5}},type:"if",locations:[{start:{line:154,column:4},end:{line:202,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:154},19:{loc:{start:{line:156,column:26},end:{line:156,column:77}},type:"cond-expr",locations:[{start:{line:156,column:56},end:{line:156,column:68}},{start:{line:156,column:71},end:{line:156,column:77}}],line:156},20:{loc:{start:{line:158,column:26},end:{line:158,column:79}},type:"cond-expr",locations:[{start:{line:158,column:56},end:{line:158,column:69}},{start:{line:158,column:72},end:{line:158,column:79}}],line:158},21:{loc:{start:{line:168,column:8},end:{line:172,column:9}},type:"if",locations:[{start:{line:168,column:8},end:{line:172,column:9}},{start:{line:170,column:15},end:{line:172,column:9}}],line:168},22:{loc:{start:{line:174,column:8},end:{line:185,column:9}},type:"if",locations:[{start:{line:174,column:8},end:{line:185,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:174},23:{loc:{start:{line:222,column:8},end:{line:237,column:9}},type:"binary-expr",locations:[{start:{line:222,column:8},end:{line:222,column:45}},{start:{line:222,column:65},end:{line:237,column:9}}],line:222},24:{loc:{start:{line:253,column:8},end:{line:268,column:9}},type:"binary-expr",locations:[{start:{line:253,column:8},end:{line:253,column:18}},{start:{line:253,column:38},end:{line:268,column:9}}],line:253},25:{loc:{start:{line:269,column:8},end:{line:277,column:15}},type:"binary-expr",locations:[{start:{line:269,column:8},end:{line:269,column:18}},{start:{line:269,column:38},end:{line:277,column:15}}],line:269},26:{loc:{start:{line:279,column:10},end:{line:289,column:11}},type:"binary-expr",locations:[{start:{line:279,column:10},end:{line:279,column:20}},{start:{line:279,column:40},end:{line:289,column:11}}],line:279}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0,74:0,75:0,76:0,77:0,78:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0],17:[0,0],18:[0,0],19:[0,0],20:[0,0],21:[0,0],22:[0,0],23:[0,0],24:[0,0],25:[0,0],26:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/_DataProperty.tsx"],names:[],mappings:"AAkO8B,cA8Bf,YA9Be;AAlO9B,OAAO,WAAW;AAClB,SAAQ,oBAAoB,4BAA2B;AACvD,OAAO,YAAY;AAEnB,OAAO,iBAAiB;AACxB,OAAO,eAAe;AACtB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAClB,OAAO,YAAY;AACnB,OAAO,qBAAqB;AAC5B,SAAQ,2BAA0B;AAElC,OAAO,wBAAwB;AAC/B,OAAO,sBAAsB;AAI7B,SAAS,YAAY,OAA0B,OAA0B;AAEvE,MAAI;AAEJ,MAAG,MAAM,SAAS,MAAM,MAAM,OAAO;AACnC,UAAM,MAAM,MAAM,QAAQ,CAAC,MAAM,QAAQ;AACvC,UAAG,CAAC,OAAO,UAAU,eAAe,KAAK,MAAM,MAAM,GAAG,GAAG;AACzD,YAAG,CAAC,SAAS;AACX,oBAAU,EAAC,GAAG,MAAK;AAAA,QACrB;AACA,gBAAQ,GAAG,IAAI,OAAO,OAAO;AAAA,MAC/B;AAAA,IACF,CAAC;AAAA,EACH;AAEA,SAAO;AACT;AAgCA,qBAAqB,qBAAqB,MAAM,UAAgD;AAAA,EAC9F,QAAQ;AAAA,IACN,MAAM,CAAC;AAAA,EACT;AAAA,EAEA,oBAAoB;AAClB,UAAM,UAAU,YAAY,KAAK,OAAO,KAAK,KAAK;AAElD,QAAG,SAAS;AACV,WAAK,SAAS;AAAA,QACZ,MAAM;AAAA,MACR,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,OAAO,yBAAyB,OAA0B,OAA0B;AAClF,UAAM,UAAU,YAAY,OAAO,KAAK;AACxC,QAAG,SAAS;AACV,aAAO;AAAA,QACL,MAAM;AAAA,MACR;AAAA,IACF;AACA,WAAO;AAAA,EACT;AAAA,EAEA,qBAAqB,WAAgB;AACnC,QAAI,UAAU,WAAW,cAAc;AACrC,aAAO;AAAA,IACT;AACA,QAAI,UAAU,SAAS,UAAU;AAC/B,aAAO;AAAA,IACT;AACA,WAAO;AAAA,EACT;AAAA,EAEA,qBAAqB,WAAgB;AACnC,QAAI,UAAU,WAAW,cAAc;AACrC,aAAO,CAAC,eAAe,eAAe,YAAY,eAAe,UAAU;AAAA,IAC7E,OACK;AACH,aAAO,CAAC,eAAe,YAAY,UAAU;AAAA,IAC/C;AAAA,EACF;AAAA;AAAA,EAGA,iBAAiB,OAAe;AAC9B,UAAM,gBAAgB,MACnB,IAAI,CAAC,MAAM,QAAQ;AAClB,aAAO;AAAA,QACL,KAAK,KAAK,MAAM,KAAK,GAAG;AAAA,QACxB,MAAM;AAAA,MACR;AAAA,IACF,CAAC,EAEA,KAAK,CAAC,GAAG,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,IAAI,CAAC;AAGjE,UAAM,UAAU,CAAC;AACjB,kBACG,QAAQ,CAAC,MAAM,QAAO;AACrB,cAAQ,GAAG,IAAI,KAAK;AAAA,IACtB,CAAC;AAEH,SAAK,SAAS;AAAA,MACZ,MAAM;AAAA,IACR,CAAC;AAED,WAAO,cAAc,IAAI,CAAC,SAAS,KAAK,IAAI;AAAA,EAC9C;AAAA,EAEA,WAAW,CAAC,WAAmB,UAAe;AAC5C,QAAI,MAAM,SAAS,YAAY;AAC7B,cAAQ;AAAA,QACN,MAAM,MAAM;AAAA,QACZ,UAAU,MAAM;AAAA,MAClB;AAAA,IACF,OACK;AACH,YAAM,YAAY,MAAM,SAAS,gBAAgB,KAAK;AACtD,cAAQ;AAAA,QACN,UAAU;AAAA,QACV,MAAM,MAAM;AAAA;AAAA,QAEZ,OAAO;AAAA,UACL,CAAC,EAAC,MAAM,GAAG,OAAO,UAAS,GAAG,oBAAoB,KAAK,MAAM,SAAgB,CAAC;AAAA,UAC9E,CAAC,EAAC,MAAM,IAAI,OAAO,UAAS,GAAG,oBAAoB,KAAK,MAAM,SAAgB,CAAC;AAAA,QACjF;AAAA,QACA,GAAG;AAAA,MACL;AAAA,IACF;AACA,SAAK,MAAM,SAAU,WAAW,KAAK;AAAA,EACvC;AAAA,EAEA,WAAW,WAAmB,UAAuD,OAAe;AAClG,UAAM,QAAQ,KAAK,MAAM,OAAO,MAAM,MAAM,CAAC,KAAK,CAAC;AAEnD,UAAM,SAAS,IAAI;AAAA,MACjB;AAAA,QACE,OAAO,SAAS;AAAA,QAChB,MAAO,SAAS,SAAS,SAAa,IAAI,SAAS;AAAA,MACrD;AAAA,MACA;AAAA,IACF;AAEA,UAAM,eAAe,KAAK,iBAAiB,KAAK;AAEhD,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,OAAO;AAAA,IACT;AACA,SAAK,SAAS,KAAK,MAAM,WAAW,YAAY;AAAA,EAClD;AAAA,EAEA,WAAW,UAA8B;AACvC,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,MAAM;AAAA,IACR;AAEA,QAAI,aAAa,SAAS,QAAW;AACnC,aAAO,aAAa,MAAM;AAAA,IAC5B;AACA,SAAK,MAAM,SAAU,KAAK,MAAM,WAAW,YAAY;AAAA,EACzD;AAAA,EAEA,eAAe,SAAiB;AAC9B,QAAI,YAAY,iBAAiB,KAAK,MAAM,wBAAwB;AAClE,WAAK,MAAM,uBAAuB;AAAA,IACpC,OACK;AACH,WAAK,SAAS,KAAK,MAAM,WAAW;AAAA,QAClC,GAAG,KAAK,MAAM;AAAA,QACd,MAAM;AAAA,MACR,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,mBAAmB,UAAkC,SAAc;AACjE,QAAI,SAAS;AACX,WAAK,MAAM,MAAO,QAAQ,IAAI;AAAA,IAChC,OACK;AACH,aAAO,KAAK,MAAM,MAAO,QAAQ;AAAA,IACnC;AACA,SAAK,SAAS,KAAK,MAAM,WAAW,KAAK,MAAM,KAAK;AAAA,EACtD;AAAA,EAEA,SAAS;AACP,QAAI,OAAO,KAAK,MAAM,OAAO,SAAS,aAAa;AACjD,WAAK,MAAM,MAAO,OAAO,KAAK,qBAAqB,KAAK,MAAM,SAAS;AAAA,IACzE;AAEA,QAAI;AACJ,QAAI,KAAK,MAAM,OAAO,OAAO;AAC3B,mBAAa,KAAK,MAAM,MAAM,MAAM,IAAI,CAAC,MAAM,QAAQ;AACrD,cAAM,YAAY,OAAO,KAAK,CAAC,MAAM,WAAW,KAAK,CAAC,EAAE,OAAO;AAC/D,cAAM,MAAO,KAAK,MAAM,KAAK,GAAG;AAChC,cAAM,YAAY,OAAO,KAAK,CAAC,MAAM,WAAW,KAAK,CAAC,EAAE,QAAQ,KAAK,CAAC;AACtE,cAAM,QAAQ,KAAK,CAAC;AACpB,cAAM,gBAAgB,oBAAC,oBAAiB,SAAS,KAAK,MAAM,cAAc,KAAK,MAAM,GAAG,GAAG;AAE3F,cAAM,YAAY;AAAA,UAChB,cAAc;AAAA,UACd,OAAO;AAAA,UACP,OAAO;AAAA,UACP,UAAU,CAAC,YAAyC,KAAK,WAAW,KAAK,EAAE,MAAM,WAAW,OAAO,QAAkB,GAAG,KAAK;AAAA,QAC/H;AAEA,YAAI;AACJ,YAAG,KAAK,MAAM,OAAO,SAAS,eAAe;AAC3C,sBAAY,oBAAC,eAAa,GAAG,WAAW;AAAA,QAC1C,OACK;AACH,sBAAY,oBAAC,eAAa,GAAG,WAAW;AAAA,QAC1C;AAEA,YAAI,YAAY;AAChB,YAAG,cAAc,QAAW;AAC1B,sBAAY,oBAAC,SACX;AAAA,YAAC;AAAA;AAAA,cACC,cAAW;AAAA,cACX,OAAO;AAAA,cACP,UAAU,aAAW,KAAK,WAAW,KAAK,EAAC,MAAM,SAAS,OAAO,UAAS,GAAG,KAAK;AAAA,cAClF,KAAK;AAAA,cACL,KAAK;AAAA;AAAA,UACP,GACF;AAAA,QACF;AAEA,eAAO,qBAAC,QACN;AAAA,8BAAC,QACE,qBACH;AAAA,UACA,oBAAC,QACE,qBACH;AAAA,UACA,oBAAC,QACC;AAAA,YAAC;AAAA;AAAA,cACC,cAAW;AAAA,cACX,WAAW,KAAK,MAAM;AAAA,cACtB,WAAW,KAAK,MAAM;AAAA,cACtB;AAAA,cACA,UAAU,CAAC,GAAG,aAAa,KAAK,WAAW,KAAK,EAAC,MAAM,WAAW,OAAO,UAAS,GAAG,QAAkB;AAAA;AAAA,UACzG,GACF;AAAA,UACA,oBAAC,QACE,yBACH;AAAA,aAlBc,GAmBhB;AAAA,MACF,CAAC;AAAA,IACH;AAEA,WAAO,oBAAC,SAAI,WAAU,4BACpB,+BAAC,cAAS,WAAU,+BAClB;AAAA,0BAAC,YAAQ,6BAAmB,KAAK,MAAM,SAAS,GAAE;AAAA,MAClD,qBAAC,SAAI,WAAU,gCACb;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YAGP,8BAAC,SAAI,WAAU,qCACb;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO,KAAK,MAAM,MAAO;AAAA,gBACzB,UAAU,CAAC,YAAoB,KAAK,eAAe,OAAO;AAAA,gBAC1D,OAAO;AAAA,gBACP,SAAS,KAAK,qBAAqB,KAAK,MAAM,SAAS;AAAA;AAAA,YACzD,GACF;AAAA;AAAA,UATI;AAAA,QAUN;AAAA,QACC,KAAK,MAAM,OAAO,SAAS,cAC1B;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YAGP,8BAAC,SAAI,WAAU,qCACb;AAAA,cAAC;AAAA;AAAA,gBACC,WAAW;AAAA,gBACX,WAAW,OAAO,SAAS;AAAA,gBAC3B,OAAO,KAAK,MAAM,OAAO;AAAA,gBACzB,UAAU,CAAC,GAAG,aAAa,KAAK,WAAW,QAAkB;AAAA;AAAA,YAC/D,GACF;AAAA;AAAA,UATI;AAAA,QAUN;AAAA,QAEF;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YAGP,8BAAC,SAAI,WAAU,qCACb;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO,KAAK,MAAM,OAAO;AAAA,gBACzB,OAAO;AAAA,gBACP,UAAU,aAAW,KAAK,mBAAmB,YAAY,OAAO;AAAA;AAAA,YAClE,GACF;AAAA;AAAA,UARI;AAAA,QASN;AAAA,QACC,cACC;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YAGP;AAAA,cAAC;AAAA;AAAA,gBACC,WAAW,KAAK,MAAM;AAAA,gBACtB,WAAW,KAAK,MAAM;AAAA,gBACtB,OAAO,KAAK,MAAM,OAAO;AAAA,gBACzB,UAAU,CAAC,GAAG,YAAY,KAAK,mBAAmB,WAAW,OAAO;AAAA;AAAA,YACtE;AAAA;AAAA,UAPI;AAAA,QAQN;AAAA,QAED,cACC,oBAAC,SAAI,WAAU,0BACb,+BAAC,WAAM,WAAU,gCACf;AAAA,8BAAC,aAAQ,mBAAK;AAAA,UACd,oBAAC,WACC,+BAAC,QACC;AAAA,gCAAC,QAAG,kBAAI;AAAA,YACR,oBAAC,QAAG,yBAAW;AAAA,YACf,oBAAC,QAAG,SAAS,GAAG,0BAAY;AAAA,aAC9B,GACF;AAAA,UACA,oBAAC,WACE,sBACH;AAAA,WACF,GACF;AAAA,QAEF,qBAAC,SAAI,WAAU,oBACZ;AAAA,wBACC;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,SAAS,KAAK,MAAM,WAAW,KAAK,IAAI;AAAA,cAExC;AAAA,oCAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,cAAa,GAAG,SAAQ,aAC/E,8BAAC,UAAK,MAAK,gBAAe,GAAG,sBAAsB,GACrD;AAAA,gBAAM;AAAA;AAAA;AAAA,UACR;AAAA,UAEF;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,SAAS,KAAK,MAAM,mBAAmB,KAAK,IAAI;AAAA,cAEhD;AAAA,oCAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,cAAa,GAAG,SAAQ,aAC/E,8BAAC,UAAK,MAAK,gBAAe,GAAG,oBAAoB,GACnD;AAAA,gBAAM;AAAA;AAAA;AAAA,UACR;AAAA,WACF;AAAA,SACF;AAAA,OACF,GACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"232a59a4721428f6ea1780ae642f941986fcb93c"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return zt=function(){return s},s}zt();function AP(e,n){zt().f[0]++;let t;return zt().s[0]++,zt().b[1][0]++,e.value&&(zt().b[1][1]++,e.value.stops)?(zt().b[0][0]++,zt().s[1]++,e.value.stops.forEach((r,i)=>{zt().f[1]++,zt().s[2]++,Object.prototype.hasOwnProperty.call(n.refs,i)?zt().b[2][1]++:(zt().b[2][0]++,zt().s[3]++,t?zt().b[3][1]++:(zt().b[3][0]++,zt().s[4]++,t={...n}),zt().s[5]++,t[i]=Oy("stop-"))})):zt().b[0][1]++,zt().s[6]++,t}class d6e extends bn.Component{constructor(){super(...arguments);nn(this,"state",(zt().s[7]++,{refs:{}}));nn(this,"onChange",(zt().s[32]++,(t,r)=>{if(zt().f[11]++,zt().s[33]++,r.type==="identity")zt().b[9][0]++,zt().s[34]++,r={type:r.type,property:r.property};else{zt().b[9][1]++;const i=(zt().s[35]++,r.type==="categorical"?(zt().b[10][0]++,""):(zt().b[10][1]++,0));zt().s[36]++,r={property:"",type:r.type,stops:[[{zoom:6,value:i},fd(this.props.fieldSpec)],[{zoom:10,value:i},fd(this.props.fieldSpec)]],...r}}zt().s[37]++,this.props.onChange(t,r)}))}componentDidMount(){zt().f[2]++;const t=(zt().s[8]++,AP(this.props,this.state));zt().s[9]++,t?(zt().b[4][0]++,zt().s[10]++,this.setState({refs:t})):zt().b[4][1]++}static getDerivedStateFromProps(t,r){zt().f[3]++;const i=(zt().s[11]++,AP(t,r));return zt().s[12]++,i?(zt().b[5][0]++,zt().s[13]++,{refs:i}):(zt().b[5][1]++,zt().s[14]++,null)}getFieldFunctionType(t){return zt().f[4]++,zt().s[15]++,t.expression.interpolated?(zt().b[6][0]++,zt().s[16]++,"exponential"):(zt().b[6][1]++,zt().s[17]++,t.type==="number"?(zt().b[7][0]++,zt().s[18]++,"interval"):(zt().b[7][1]++,zt().s[19]++,"categorical"))}getDataFunctionTypes(t){return zt().f[5]++,zt().s[20]++,t.expression.interpolated?(zt().b[8][0]++,zt().s[21]++,["interpolate","categorical","interval","exponential","identity"]):(zt().b[8][1]++,zt().s[22]++,["categorical","interval","identity"])}orderStopsByZoom(t){zt().f[6]++;const r=(zt().s[23]++,t.map((o,s)=>(zt().f[7]++,zt().s[24]++,{ref:this.state.refs[s],data:o})).sort((o,s)=>(zt().f[8]++,zt().s[25]++,YN(o.data[0].zoom,s.data[0].zoom)))),i=(zt().s[26]++,{});return zt().s[27]++,r.forEach((o,s)=>{zt().f[9]++,zt().s[28]++,i[s]=o.ref}),zt().s[29]++,this.setState({refs:i}),zt().s[30]++,r.map(o=>(zt().f[10]++,zt().s[31]++,o.data))}changeStop(t,r,i){var f;zt().f[12]++;const o=(zt().s[38]++,zt().b[11][0]++,((f=this.props.value)==null?void 0:f.stops.slice(0))||(zt().b[11][1]++,[]));zt().s[39]++,o[t]=[{value:r.value,zoom:r.zoom===void 0?(zt().b[12][0]++,0):(zt().b[12][1]++,r.zoom)},i];const s=(zt().s[40]++,this.orderStopsByZoom(o)),a=(zt().s[41]++,{...this.props.value,stops:s});zt().s[42]++,this.onChange(this.props.fieldName,a)}changeBase(t){zt().f[13]++;const r=(zt().s[43]++,{...this.props.value,base:t});zt().s[44]++,r.base===void 0?(zt().b[13][0]++,zt().s[45]++,delete r.base):zt().b[13][1]++,zt().s[46]++,this.props.onChange(this.props.fieldName,r)}changeDataType(t){zt().f[14]++,zt().s[47]++,zt().b[15][0]++,t==="interpolate"&&(zt().b[15][1]++,this.props.onChangeToZoomFunction)?(zt().b[14][0]++,zt().s[48]++,this.props.onChangeToZoomFunction()):(zt().b[14][1]++,zt().s[49]++,this.onChange(this.props.fieldName,{...this.props.value,type:t}))}changeDataProperty(t,r){zt().f[15]++,zt().s[50]++,r?(zt().b[16][0]++,zt().s[51]++,this.props.value[t]=r):(zt().b[16][1]++,zt().s[52]++,delete this.props.value[t]),zt().s[53]++,this.onChange(this.props.fieldName,this.props.value)}render(){var r,i,o,s,a,f,g,x;zt().f[16]++,zt().s[54]++,typeof((r=this.props.value)==null?void 0:r.type)>"u"?(zt().b[17][0]++,zt().s[55]++,this.props.value.type=this.getFieldFunctionType(this.props.fieldSpec)):zt().b[17][1]++;let t;return zt().s[56]++,(i=this.props.value)!=null&&i.stops?(zt().b[18][0]++,zt().s[57]++,t=this.props.value.stops.map((k,B)=>{var ce,ae;zt().f[17]++;const P=(zt().s[58]++,typeof k[0]=="object"?(zt().b[19][0]++,k[0].zoom):(zt().b[19][1]++,void 0)),R=(zt().s[59]++,this.state.refs[B]),H=(zt().s[60]++,typeof k[0]=="object"?(zt().b[20][0]++,k[0].value):(zt().b[20][1]++,k[0])),W=(zt().s[61]++,k[1]),$=(zt().s[62]++,N.jsx(qN,{onClick:(ce=this.props.onDeleteStop)==null?void 0:ce.bind(this,B)})),q=(zt().s[63]++,{"aria-label":"Input value",label:"Data value",value:H,onChange:ue=>(zt().f[18]++,zt().s[64]++,this.changeStop(B,{zoom:P,value:ue},W))});let oe;zt().s[65]++,((ae=this.props.value)==null?void 0:ae.type)==="categorical"?(zt().b[21][0]++,zt().s[66]++,oe=N.jsx(Sd,{...q})):(zt().b[21][1]++,zt().s[67]++,oe=N.jsx(pf,{...q}));let ne=(zt().s[68]++,null);return zt().s[69]++,P!==void 0?(zt().b[22][0]++,zt().s[70]++,ne=N.jsx("div",{children:N.jsx(pf,{"aria-label":"Zoom",value:P,onChange:ue=>(zt().f[19]++,zt().s[71]++,this.changeStop(B,{zoom:ue,value:H},W)),min:0,max:22})})):zt().b[22][1]++,zt().s[72]++,N.jsxs("tr",{children:[N.jsx("td",{children:ne}),N.jsx("td",{children:oe}),N.jsx("td",{children:N.jsx(dy,{"aria-label":"Output value",fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:W,onChange:(ue,ye)=>(zt().f[20]++,zt().s[73]++,this.changeStop(B,{zoom:P,value:H},ye))})}),N.jsx("td",{children:$})]},R)})):zt().b[18][1]++,zt().s[74]++,N.jsx("div",{className:"maputnik-data-spec-block",children:N.jsxs("fieldset",{className:"maputnik-data-spec-property",children:[N.jsx("legend",{children:D5(this.props.fieldName)}),N.jsxs("div",{className:"maputnik-data-fieldset-inner",children:[N.jsx(Uo,{label:"Function",children:N.jsx("div",{className:"maputnik-data-spec-property-input",children:N.jsx(w1,{value:this.props.value.type,onChange:k=>(zt().f[21]++,zt().s[75]++,this.changeDataType(k)),title:"Select a type of data scale (default is 'categorical').",options:this.getDataFunctionTypes(this.props.fieldSpec)})})},"function"),(zt().b[23][0]++,((o=this.props.value)==null?void 0:o.type)!=="identity"&&(zt().b[23][1]++,N.jsx(Uo,{label:"Base",children:N.jsx("div",{className:"maputnik-data-spec-property-input",children:N.jsx(dy,{fieldName:"base",fieldSpec:Ji.function.base,value:(s=this.props.value)==null?void 0:s.base,onChange:(k,B)=>(zt().f[22]++,zt().s[76]++,this.changeBase(B))})})},"base"))),N.jsx(Uo,{label:"Property",children:N.jsx("div",{className:"maputnik-data-spec-property-input",children:N.jsx(Sd,{value:(a=this.props.value)==null?void 0:a.property,title:"Input a data property to base styles off of.",onChange:k=>(zt().f[23]++,zt().s[77]++,this.changeDataProperty("property",k))})})},"property"),(zt().b[24][0]++,t&&(zt().b[24][1]++,N.jsx(Uo,{label:"Default",children:N.jsx(dy,{fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:(f=this.props.value)==null?void 0:f.default,onChange:(k,B)=>(zt().f[24]++,zt().s[78]++,this.changeDataProperty("default",B))})},"default"))),(zt().b[25][0]++,t&&(zt().b[25][1]++,N.jsx("div",{className:"maputnik-function-stop",children:N.jsxs("table",{className:"maputnik-function-stop-table",children:[N.jsx("caption",{children:"Stops"}),N.jsx("thead",{children:N.jsxs("tr",{children:[N.jsx("th",{children:"Zoom"}),N.jsx("th",{children:"Input value"}),N.jsx("th",{rowSpan:2,children:"Output value"})]})}),N.jsx("tbody",{children:t})]})}))),N.jsxs("div",{className:"maputnik-toolbox",children:[(zt().b[26][0]++,t&&(zt().b[26][1]++,N.jsxs(Ka,{className:"maputnik-add-stop",onClick:(g=this.props.onAddStop)==null?void 0:g.bind(this),children:[N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:d8})})," Add stop"]}))),N.jsxs(Ka,{className:"maputnik-add-stop",onClick:(x=this.props.onExpressionClick)==null?void 0:x.bind(this),children:[N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:S_})})," Convert to expression"]})]})]})]})})}}function Un(){var e="/home/runner/work/maputnik/maputnik/src/components/_ZoomProperty.tsx",n="b293261b8db082101e4d8e26898ce3be8cd692d2",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/_ZoomProperty.tsx",statementMap:{0:{start:{line:15,column:16},end:{line:15,column:18}},1:{start:{line:16,column:2},end:{line:27,column:3}},2:{start:{line:17,column:4},end:{line:26,column:7}},3:{start:{line:18,column:6},end:{line:25,column:7}},4:{start:{line:19,column:8},end:{line:21,column:9}},5:{start:{line:20,column:10},end:{line:20,column:33}},6:{start:{line:22,column:8},end:{line:22,column:39}},7:{start:{line:24,column:8},end:{line:24,column:39}},8:{start:{line:28,column:2},end:{line:28,column:17}},9:{start:{line:31,column:24},end:{line:33,column:3}},10:{start:{line:34,column:10},end:{line:36,column:3}},11:{start:{line:38,column:20},end:{line:38,column:55}},12:{start:{line:39,column:4},end:{line:43,column:5}},13:{start:{line:40,column:6},end:{line:42,column:9}},14:{start:{line:46,column:20},end:{line:46,column:45}},15:{start:{line:47,column:4},end:{line:51,column:5}},16:{start:{line:48,column:6},end:{line:50,column:8}},17:{start:{line:52,column:4},end:{line:52,column:16}},18:{start:{line:56,column:26},end:{line:61,column:60}},19:{start:{line:57,column:6},end:{line:60,column:8}},20:{start:{line:61,column:22},end:{line:61,column:59}},21:{start:{line:62,column:20},end:{line:62,column:22}},22:{start:{line:63,column:4},end:{line:65,column:7}},23:{start:{line:64,column:6},end:{line:64,column:30}},24:{start:{line:66,column:4},end:{line:68,column:7}},25:{start:{line:69,column:4},end:{line:69,column:50}},26:{start:{line:69,column:39},end:{line:69,column:48}},27:{start:{line:72,column:18},end:{line:72,column:49}},28:{start:{line:73,column:4},end:{line:73,column:41}},29:{start:{line:74,column:25},end:{line:74,column:53}},30:{start:{line:75,column:25},end:{line:78,column:5}},31:{start:{line:79,column:4},end:{line:79,column:60}},32:{start:{line:82,column:25},end:{line:85,column:5}},33:{start:{line:86,column:4},end:{line:88,column:5}},34:{start:{line:87,column:6},end:{line:87,column:34}},35:{start:{line:89,column:4},end:{line:89,column:60}},36:{start:{line:91,column:19},end:{line:95,column:3}},37:{start:{line:92,column:4},end:{line:94,column:5}},38:{start:{line:93,column:6},end:{line:93,column:46}},39:{start:{line:97,column:23},end:{line:131,column:6}},40:{start:{line:98,column:24},end:{line:98,column:31}},41:{start:{line:99,column:18},end:{line:99,column:38}},42:{start:{line:100,column:20},end:{line:100,column:27}},43:{start:{line:101,column:44},end:{line:101,column:120}},44:{start:{line:102,column:6},end:{line:130,column:8}},45:{start:{line:111,column:43},end:{line:111,column:87}},46:{start:{line:123,column:43},end:{line:123,column:88}},47:{start:{line:132,column:4},end:{line:198,column:12}},48:{start:{line:143,column:39},end:{line:143,column:67}},49:{start:{line:160,column:43},end:{line:160,column:68}},50:{start:{line:201,column:4},end:{line:205,column:5}},51:{start:{line:202,column:6},end:{line:202,column:83}},52:{start:{line:204,column:6},end:{line:204,column:29}}},fnMap:{0:{name:"setStopRefs",decl:{start:{line:14,column:9},end:{line:14,column:20}},loc:{start:{line:14,column:35},end:{line:29,column:1}},line:14},1:{name:"(anonymous_1)",decl:{start:{line:17,column:30},end:{line:17,column:31}},loc:{start:{line:17,column:45},end:{line:26,column:5}},line:17},2:{name:"(anonymous_2)",decl:{start:{line:37,column:2},end:{line:37,column:3}},loc:{start:{line:37,column:22},end:{line:44,column:3}},line:37},3:{name:"(anonymous_3)",decl:{start:{line:45,column:2},end:{line:45,column:3}},loc:{start:{line:45,column:48},end:{line:53,column:3}},line:45},4:{name:"(anonymous_4)",decl:{start:{line:55,column:2},end:{line:55,column:3}},loc:{start:{line:55,column:26},end:{line:70,column:3}},line:55},5:{name:"(anonymous_5)",decl:{start:{line:56,column:36},end:{line:56,column:37}},loc:{start:{line:56,column:51},end:{line:61,column:5}},line:56},6:{name:"(anonymous_6)",decl:{start:{line:61,column:12},end:{line:61,column:13}},loc:{start:{line:61,column:22},end:{line:61,column:59}},line:61},7:{name:"(anonymous_7)",decl:{start:{line:63,column:26},end:{line:63,column:27}},loc:{start:{line:63,column:41},end:{line:65,column:5}},line:63},8:{name:"(anonymous_8)",decl:{start:{line:69,column:29},end:{line:69,column:30}},loc:{start:{line:69,column:39},end:{line:69,column:48}},line:69},9:{name:"(anonymous_9)",decl:{start:{line:71,column:2},end:{line:71,column:3}},loc:{start:{line:71,column:45},end:{line:80,column:3}},line:71},10:{name:"(anonymous_10)",decl:{start:{line:81,column:2},end:{line:81,column:3}},loc:{start:{line:81,column:23},end:{line:90,column:3}},line:81},11:{name:"(anonymous_11)",decl:{start:{line:91,column:19},end:{line:91,column:20}},loc:{start:{line:91,column:29},end:{line:95,column:3}},line:91},12:{name:"(anonymous_12)",decl:{start:{line:96,column:2},end:{line:96,column:3}},loc:{start:{line:96,column:11},end:{line:199,column:3}},line:96},13:{name:"(anonymous_13)",decl:{start:{line:97,column:51},end:{line:97,column:52}},loc:{start:{line:97,column:66},end:{line:131,column:5}},line:97},14:{name:"(anonymous_14)",decl:{start:{line:111,column:26},end:{line:111,column:27}},loc:{start:{line:111,column:43},end:{line:111,column:87}},line:111},15:{name:"(anonymous_15)",decl:{start:{line:123,column:26},end:{line:123,column:27}},loc:{start:{line:123,column:43},end:{line:123,column:88}},line:123},16:{name:"(anonymous_16)",decl:{start:{line:143,column:26},end:{line:143,column:27}},loc:{start:{line:143,column:39},end:{line:143,column:67}},line:143},17:{name:"(anonymous_17)",decl:{start:{line:160,column:26},end:{line:160,column:27}},loc:{start:{line:160,column:43},end:{line:160,column:68}},line:160},18:{name:"(anonymous_18)",decl:{start:{line:200,column:2},end:{line:200,column:3}},loc:{start:{line:200,column:34},end:{line:206,column:3}},line:200}},branchMap:{0:{loc:{start:{line:16,column:2},end:{line:27,column:3}},type:"if",locations:[{start:{line:16,column:2},end:{line:27,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:16},1:{loc:{start:{line:16,column:6},end:{line:16,column:38}},type:"binary-expr",locations:[{start:{line:16,column:6},end:{line:16,column:17}},{start:{line:16,column:21},end:{line:16,column:38}}],line:16},2:{loc:{start:{line:18,column:6},end:{line:25,column:7}},type:"if",locations:[{start:{line:18,column:6},end:{line:25,column:7}},{start:{line:23,column:13},end:{line:25,column:7}}],line:18},3:{loc:{start:{line:19,column:8},end:{line:21,column:9}},type:"if",locations:[{start:{line:19,column:8},end:{line:21,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:19},4:{loc:{start:{line:39,column:4},end:{line:43,column:5}},type:"if",locations:[{start:{line:39,column:4},end:{line:43,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:39},5:{loc:{start:{line:47,column:4},end:{line:51,column:5}},type:"if",locations:[{start:{line:47,column:4},end:{line:51,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:47},6:{loc:{start:{line:86,column:4},end:{line:88,column:5}},type:"if",locations:[{start:{line:86,column:4},end:{line:88,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:86},7:{loc:{start:{line:92,column:4},end:{line:94,column:5}},type:"if",locations:[{start:{line:92,column:4},end:{line:94,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:92},8:{loc:{start:{line:92,column:8},end:{line:92,column:67}},type:"binary-expr",locations:[{start:{line:92,column:8},end:{line:92,column:30}},{start:{line:92,column:34},end:{line:92,column:67}}],line:92},9:{loc:{start:{line:201,column:4},end:{line:205,column:5}},type:"if",locations:[{start:{line:201,column:4},end:{line:205,column:5}},{start:{line:203,column:11},end:{line:205,column:5}}],line:201}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/_ZoomProperty.tsx"],names:[],mappings:"AA8J2B,cACd,YADc;AA9J3B,OAAO,WAAW;AAClB,SAAQ,oBAAoB,4BAA2B;AACvD,OAAO,YAAY;AAEnB,OAAO,iBAAiB;AACxB,OAAO,eAAe;AACtB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAElB,OAAO,sBAAsB;AAC7B,OAAO,wBAAwB;AAE/B,OAAO,YAAY;AACnB,OAAO,qBAAqB;AAQ5B,SAAS,YAAY,OAA0B,OAA0B;AAEvE,MAAI,UAAmC,CAAC;AAExC,MAAG,MAAM,SAAU,MAAM,MAAwB,OAAO;AACtD,IAAC,MAAM,MAAwB,MAAM,QAAQ,CAAC,MAAM,QAAgB;AAClE,UAAG,OAAO,UAAU,eAAe,KAAK,CAAC,MAAM,MAAM,GAAG,GAAG;AACzD,YAAG,CAAC,SAAS;AACX,oBAAU,EAAC,GAAG,MAAK;AAAA,QACrB;AACA,gBAAQ,GAAG,IAAI,OAAO,OAAO;AAAA,MAC/B,OAAO;AACL,gBAAQ,GAAG,IAAI,MAAM,KAAK,GAAG;AAAA,MAC/B;AAAA,IACF,CAAC;AAAA,EACH;AACA,SAAO;AACT;AA4BA,qBAAqB,qBAAqB,MAAM,UAAgD;AAAA,EAC9F,OAAO,eAAe;AAAA,IACpB,QAAQ,CAAC;AAAA,EACX;AAAA,EAEA,QAAQ;AAAA,IACN,MAAM,CAAC;AAAA,EACT;AAAA,EAEA,oBAAoB;AAClB,UAAM,UAAU,YAAY,KAAK,OAAO,KAAK,KAAK;AAElD,QAAG,SAAS;AACV,WAAK,SAAS;AAAA,QACZ,MAAM;AAAA,MACR,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,OAAO,yBAAyB,OAA0B,OAA0B;AAClF,UAAM,UAAU,YAAY,OAAO,KAAK;AACxC,QAAG,SAAS;AACV,aAAO;AAAA,QACL,MAAM;AAAA,MACR;AAAA,IACF;AACA,WAAO;AAAA,EACT;AAAA;AAAA,EAGA,iBAAiB,OAA+B;AAC9C,UAAM,gBAAgB,MACnB,IAAI,CAAC,MAAM,QAAQ;AAClB,aAAO;AAAA,QACL,KAAK,KAAK,MAAM,KAAK,GAAG;AAAA,QACxB,MAAM;AAAA,MACR;AAAA,IACF,CAAC,EAEA,KAAK,CAAC,GAAG,MAAM,gBAAgB,EAAE,KAAK,CAAC,GAAI,EAAE,KAAK,CAAC,CAAE,CAAC;AAGzD,UAAM,UAAkC,CAAC;AACzC,kBACG,QAAQ,CAAC,MAAM,QAAO;AACrB,cAAQ,GAAG,IAAI,KAAK;AAAA,IACtB,CAAC;AAEH,SAAK,SAAS;AAAA,MACZ,MAAM;AAAA,IACR,CAAC;AAED,WAAO,cAAc,IAAI,CAAC,SAAS,KAAK,IAAI;AAAA,EAC9C;AAAA,EAEA,eAAe,WAAmB,UAA8B,OAAe;AAC7E,UAAM,QAAS,KAAK,MAAM,MAAwB,MAAM,MAAM,CAAC;AAC/D,UAAM,SAAS,IAAI,CAAC,UAAU,KAAK;AAEnC,UAAM,eAAe,KAAK,iBAAiB,KAAK;AAEhD,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,OAAO;AAAA,IACT;AACA,SAAK,MAAM,SAAU,KAAK,MAAM,WAAW,YAAY;AAAA,EACzD;AAAA,EAEA,WAAW,UAA8B;AACvC,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,MAAM;AAAA,IACR;AAEA,QAAI,aAAa,SAAS,QAAW;AACnC,aAAO,aAAa,MAAM;AAAA,IAC5B;AACA,SAAK,MAAM,SAAU,KAAK,MAAM,WAAW,YAAY;AAAA,EACzD;AAAA,EAEA,iBAAiB,CAAC,SAAiB;AACjC,QAAI,SAAS,iBAAiB,KAAK,MAAM,wBAAwB;AAC/D,WAAK,MAAM,uBAAuB,IAAI;AAAA,IACxC;AAAA,EACF;AAAA,EAEA,SAAS;AACP,UAAM,aAAa,KAAK,MAAM,OAAO,MAAM,IAAI,CAAC,MAAM,QAAQ;AAC5D,YAAM,YAAY,KAAK,CAAC;AACxB,YAAM,MAAO,KAAK,MAAM,KAAK,GAAG;AAChC,YAAM,QAAQ,KAAK,CAAC;AACpB,YAAM,gBAAe,oBAAC,oBAAiB,SAAS,KAAK,MAAM,cAAc,KAAK,MAAM,GAAG,GAAG;AAC1F,aAAO;AAAA,QAAC;AAAA;AAAA,UAGN;AAAA,gCAAC,QACC;AAAA,cAAC;AAAA;AAAA,gBACC,cAAW;AAAA,gBACX,OAAO;AAAA,gBACP,UAAU,iBAAe,KAAK,eAAe,KAAK,aAAa,KAAK;AAAA,gBACpE,KAAK;AAAA,gBACL,KAAK;AAAA;AAAA,YACP,GACF;AAAA,YACA,oBAAC,QACC;AAAA,cAAC;AAAA;AAAA,gBACC,cAAW;AAAA,gBACX,WAAW,KAAK,MAAM;AAAA,gBACtB,WAAW,KAAK,MAAM;AAAA,gBACtB;AAAA,gBACA,UAAU,CAAC,GAAG,aAAa,KAAK,eAAe,KAAK,WAAW,QAAkB;AAAA;AAAA,YACnF,GACF;AAAA,YACA,oBAAC,QACE,yBACH;AAAA;AAAA;AAAA,QAtBK;AAAA,MAuBP;AAAA,IACF,CAAC;AAGD,WAAO,oBAAC,SAAI,WAAU,4BACpB,+BAAC,cAAS,WAAU,+BAClB;AAAA,0BAAC,YAAQ,6BAAmB,KAAK,MAAM,SAAS,GAAE;AAAA,MAClD,qBAAC,SAAI,WAAU,gCACb;AAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YAEP,8BAAC,SAAI,WAAU,qCACb;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO;AAAA,gBACP,UAAU,CAAC,YAAoB,KAAK,eAAe,OAAO;AAAA,gBAC1D,OAAO;AAAA,gBACP,SAAS,KAAK,qBAAqB,KAAK,MAAM,SAAU;AAAA;AAAA,YAC1D,GACF;AAAA;AAAA,QACF;AAAA,QACA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YAEP,8BAAC,SAAI,WAAU,qCACb;AAAA,cAAC;AAAA;AAAA,gBACC,WAAW;AAAA,gBACX,WAAW,OAAO,SAAS;AAAA,gBAC3B,OAAO,KAAK,MAAM,OAAO;AAAA,gBACzB,UAAU,CAAC,GAAG,aAAa,KAAK,WAAW,QAA8B;AAAA;AAAA,YAC3E,GACF;AAAA;AAAA,QACF;AAAA,QACA,oBAAC,SAAI,WAAU,0BACb,+BAAC,WAAM,WAAU,mEACf;AAAA,8BAAC,aAAQ,mBAAK;AAAA,UACd,oBAAC,WACC,+BAAC,QACC;AAAA,gCAAC,QAAG,kBAAI;AAAA,YACR,oBAAC,QAAG,SAAS,GAAG,0BAAY;AAAA,aAC9B,GACF;AAAA,UACA,oBAAC,WACE,sBACH;AAAA,WACF,GACF;AAAA,QACA,qBAAC,SAAI,WAAU,oBACb;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,SAAS,KAAK,MAAM,WAAW,KAAK,IAAI;AAAA,cAExC;AAAA,oCAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,cAAa,GAAG,SAAQ,aAC/E,8BAAC,UAAK,MAAK,gBAAe,GAAG,sBAAsB,GACrD;AAAA,gBAAM;AAAA;AAAA;AAAA,UACR;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,SAAS,KAAK,MAAM,mBAAmB,KAAK,IAAI;AAAA,cAEhD;AAAA,oCAAC,SAAI,OAAO,EAAC,OAAM,QAAQ,QAAO,QAAQ,eAAe,cAAa,GAAG,SAAQ,aAC/E,8BAAC,UAAK,MAAK,gBAAe,GAAG,oBAAoB,GACnD;AAAA,gBAAM;AAAA;AAAA;AAAA,UACR;AAAA,WACF;AAAA,SACF;AAAA,OACF,GACF;AAAA,EACF;AAAA,EAEA,qBAAqB,WAGlB;AACD,QAAI,UAAU,eAAe,MAAM,eAAe;AAChD,aAAO,CAAC,eAAe,eAAe,YAAY,eAAe,UAAU;AAAA,IAC7E,OACK;AACH,aAAO,CAAC,aAAa;AAAA,IACvB;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"b293261b8db082101e4d8e26898ce3be8cd692d2"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Un=function(){return s},s}Un();function cP(e,n){Un().f[0]++;let t=(Un().s[0]++,{});return Un().s[1]++,Un().b[1][0]++,e.value&&(Un().b[1][1]++,e.value.stops)?(Un().b[0][0]++,Un().s[2]++,e.value.stops.forEach((r,i)=>{Un().f[1]++,Un().s[3]++,Object.prototype.hasOwnProperty.call(!n.refs,i)?(Un().b[2][0]++,Un().s[4]++,t?Un().b[3][1]++:(Un().b[3][0]++,Un().s[5]++,t={...n}),Un().s[6]++,t[i]=Oy("stop-")):(Un().b[2][1]++,Un().s[7]++,t[i]=n.refs[i])})):Un().b[0][1]++,Un().s[8]++,t}class VN extends bn.Component{constructor(){super(...arguments);nn(this,"state",(Un().s[10]++,{refs:{}}));nn(this,"changeDataType",(Un().s[36]++,t=>{Un().f[11]++,Un().s[37]++,Un().b[8][0]++,t!=="interpolate"&&(Un().b[8][1]++,this.props.onChangeToDataFunction)?(Un().b[7][0]++,Un().s[38]++,this.props.onChangeToDataFunction(t)):Un().b[7][1]++}))}componentDidMount(){Un().f[2]++;const t=(Un().s[11]++,cP(this.props,this.state));Un().s[12]++,t?(Un().b[4][0]++,Un().s[13]++,this.setState({refs:t})):Un().b[4][1]++}static getDerivedStateFromProps(t,r){Un().f[3]++;const i=(Un().s[14]++,cP(t,r));return Un().s[15]++,i?(Un().b[5][0]++,Un().s[16]++,{refs:i}):(Un().b[5][1]++,Un().s[17]++,null)}orderStopsByZoom(t){Un().f[4]++;const r=(Un().s[18]++,t.map((o,s)=>(Un().f[5]++,Un().s[19]++,{ref:this.state.refs[s],data:o})).sort((o,s)=>(Un().f[6]++,Un().s[20]++,YN(o.data[0],s.data[0])))),i=(Un().s[21]++,{});return Un().s[22]++,r.forEach((o,s)=>{Un().f[7]++,Un().s[23]++,i[s]=o.ref}),Un().s[24]++,this.setState({refs:i}),Un().s[25]++,r.map(o=>(Un().f[8]++,Un().s[26]++,o.data))}changeZoomStop(t,r,i){Un().f[9]++;const o=(Un().s[27]++,this.props.value.stops.slice(0));Un().s[28]++,o[t]=[r,i];const s=(Un().s[29]++,this.orderStopsByZoom(o)),a=(Un().s[30]++,{...this.props.value,stops:s});Un().s[31]++,this.props.onChange(this.props.fieldName,a)}changeBase(t){Un().f[10]++;const r=(Un().s[32]++,{...this.props.value,base:t});Un().s[33]++,r.base===void 0?(Un().b[6][0]++,Un().s[34]++,delete r.base):Un().b[6][1]++,Un().s[35]++,this.props.onChange(this.props.fieldName,r)}render(){var r,i,o,s;Un().f[12]++;const t=(Un().s[39]++,(r=this.props.value)==null?void 0:r.stops.map((a,f)=>{var P;Un().f[13]++;const g=(Un().s[40]++,a[0]),x=(Un().s[41]++,this.state.refs[f]),k=(Un().s[42]++,a[1]),B=(Un().s[43]++,N.jsx(qN,{onClick:(P=this.props.onDeleteStop)==null?void 0:P.bind(this,f)}));return Un().s[44]++,N.jsxs("tr",{children:[N.jsx("td",{children:N.jsx(pf,{"aria-label":"Zoom",value:g,onChange:R=>(Un().f[14]++,Un().s[45]++,this.changeZoomStop(f,R,k)),min:0,max:22})}),N.jsx("td",{children:N.jsx(dy,{"aria-label":"Output value",fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:k,onChange:(R,H)=>(Un().f[15]++,Un().s[46]++,this.changeZoomStop(f,g,H))})}),N.jsx("td",{children:B})]},x)}));return Un().s[47]++,N.jsx("div",{className:"maputnik-data-spec-block",children:N.jsxs("fieldset",{className:"maputnik-data-spec-property",children:[N.jsx("legend",{children:D5(this.props.fieldName)}),N.jsxs("div",{className:"maputnik-data-fieldset-inner",children:[N.jsx(Uo,{label:"Function",children:N.jsx("div",{className:"maputnik-data-spec-property-input",children:N.jsx(w1,{value:"interpolate",onChange:a=>(Un().f[16]++,Un().s[48]++,this.changeDataType(a)),title:"Select a type of data scale (default is 'categorical').",options:this.getDataFunctionTypes(this.props.fieldSpec)})})}),N.jsx(Uo,{label:"Base",children:N.jsx("div",{className:"maputnik-data-spec-property-input",children:N.jsx(dy,{fieldName:"base",fieldSpec:Ji.function.base,value:(i=this.props.value)==null?void 0:i.base,onChange:(a,f)=>(Un().f[17]++,Un().s[49]++,this.changeBase(f))})})}),N.jsx("div",{className:"maputnik-function-stop",children:N.jsxs("table",{className:"maputnik-function-stop-table maputnik-function-stop-table--zoom",children:[N.jsx("caption",{children:"Stops"}),N.jsx("thead",{children:N.jsxs("tr",{children:[N.jsx("th",{children:"Zoom"}),N.jsx("th",{rowSpan:2,children:"Output value"})]})}),N.jsx("tbody",{children:t})]})}),N.jsxs("div",{className:"maputnik-toolbox",children:[N.jsxs(Ka,{className:"maputnik-add-stop",onClick:(o=this.props.onAddStop)==null?void 0:o.bind(this),children:[N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:d8})})," Add stop"]}),N.jsxs(Ka,{className:"maputnik-add-stop",onClick:(s=this.props.onExpressionClick)==null?void 0:s.bind(this),children:[N.jsx("svg",{style:{width:"14px",height:"14px",verticalAlign:"text-bottom"},viewBox:"0 0 24 24",children:N.jsx("path",{fill:"currentColor",d:S_})})," Convert to expression"]})]})]})]})})}getDataFunctionTypes(t){return Un().f[18]++,Un().s[50]++,t["property-type"]==="data-driven"?(Un().b[9][0]++,Un().s[51]++,["interpolate","categorical","interval","exponential","identity"]):(Un().b[9][1]++,Un().s[52]++,["interpolate"])}}nn(VN,"defaultProps",(Un().s[9]++,{errors:{}}));function ut(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldFunction.tsx",n="435f90d980cace940b69ce8c0aa30d2fab175109",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldFunction.tsx",statementMap:{0:{start:{line:10,column:2},end:{line:10,column:78}},1:{start:{line:13,column:2},end:{line:13,column:74}},2:{start:{line:16,column:2},end:{line:18,column:5}},3:{start:{line:17,column:4},end:{line:17,column:52}},4:{start:{line:21,column:2},end:{line:21,column:123}},5:{start:{line:24,column:2},end:{line:26,column:5}},6:{start:{line:25,column:4},end:{line:25,column:83}},7:{start:{line:29,column:2},end:{line:29,column:64}},8:{start:{line:32,column:16},end:{line:32,column:47}},9:{start:{line:33,column:2},end:{line:33,column:38}},10:{start:{line:36,column:2},end:{line:38,column:3}},11:{start:{line:37,column:4},end:{line:37,column:37}},12:{start:{line:39,column:2},end:{line:39,column:15}},13:{start:{line:42,column:2},end:{line:54,column:3}},14:{start:{line:43,column:4},end:{line:43,column:19}},15:{start:{line:44,column:9},end:{line:54,column:3}},16:{start:{line:45,column:4},end:{line:45,column:19}},17:{start:{line:46,column:9},end:{line:54,column:3}},18:{start:{line:47,column:4},end:{line:47,column:19}},19:{start:{line:48,column:9},end:{line:54,column:3}},20:{start:{line:49,column:4},end:{line:49,column:27}},21:{start:{line:50,column:9},end:{line:54,column:3}},22:{start:{line:51,column:4},end:{line:51,column:27}},23:{start:{line:53,column:4},end:{line:53,column:24}},24:{start:{line:58,column:4},end:{line:58,column:17}},25:{start:{line:59,column:4},end:{line:62,column:6}},26:{start:{line:65,column:4},end:{line:72,column:5}},27:{start:{line:66,column:6},end:{line:66,column:16}},28:{start:{line:68,column:6},end:{line:71,column:8}},29:{start:{line:75,column:4},end:{line:77,column:5}},30:{start:{line:76,column:6},end:{line:76,column:27}},31:{start:{line:78,column:4},end:{line:80,column:5}},32:{start:{line:79,column:6},end:{line:79,column:24}},33:{start:{line:81,column:4},end:{line:81,column:25}},34:{start:{line:83,column:12},end:{line:99,column:3}},35:{start:{line:84,column:18},end:{line:84,column:49}},36:{start:{line:85,column:21},end:{line:85,column:44}},37:{start:{line:86,column:4},end:{line:93,column:5}},38:{start:{line:87,column:6},end:{line:90,column:9}},39:{start:{line:92,column:6},end:{line:92,column:49}},40:{start:{line:94,column:25},end:{line:97,column:5}},41:{start:{line:98,column:4},end:{line:98,column:60}},42:{start:{line:100,column:21},end:{line:106,column:3}},43:{start:{line:101,column:37},end:{line:101,column:47}},44:{start:{line:102,column:4},end:{line:102,column:54}},45:{start:{line:103,column:4},end:{line:105,column:7}},46:{start:{line:107,column:15},end:{line:118,column:3}},47:{start:{line:108,column:18},end:{line:108,column:49}},48:{start:{line:109,column:4},end:{line:109,column:29}},49:{start:{line:110,column:23},end:{line:113,column:5}},50:{start:{line:114,column:4},end:{line:116,column:5}},51:{start:{line:115,column:6},end:{line:115,column:33}},52:{start:{line:117,column:4},end:{line:117,column:60}},53:{start:{line:119,column:21},end:{line:148,column:3}},54:{start:{line:120,column:22},end:{line:120,column:32}},55:{start:{line:122,column:4},end:{line:146,column:5}},56:{start:{line:123,column:6},end:{line:138,column:7}},57:{start:{line:124,column:8},end:{line:129,column:10}},58:{start:{line:127,column:12},end:{line:127,column:88}},59:{start:{line:131,column:8},end:{line:137,column:10}},60:{start:{line:140,column:6},end:{line:145,column:8}},61:{start:{line:147,column:4},end:{line:147,column:56}},62:{start:{line:149,column:19},end:{line:165,column:3}},63:{start:{line:150,column:33},end:{line:150,column:43}},64:{start:{line:151,column:4},end:{line:164,column:5}},65:{start:{line:152,column:6},end:{line:155,column:9}},66:{start:{line:156,column:6},end:{line:158,column:9}},67:{start:{line:159,column:11},end:{line:164,column:5}},68:{start:{line:160,column:6},end:{line:160,column:47}},69:{start:{line:161,column:6},end:{line:163,column:9}},70:{start:{line:166,column:12},end:{line:169,column:3}},71:{start:{line:167,column:33},end:{line:167,column:43}},72:{start:{line:168,column:4},end:{line:168,column:140}},73:{start:{line:170,column:19},end:{line:181,column:3}},74:{start:{line:171,column:33},end:{line:171,column:43}},75:{start:{line:173,column:4},end:{line:179,column:5}},76:{start:{line:174,column:6},end:{line:174,column:67}},77:{start:{line:175,column:11},end:{line:179,column:5}},78:{start:{line:176,column:6},end:{line:176,column:43}},79:{start:{line:178,column:6},end:{line:178,column:70}},80:{start:{line:180,column:4},end:{line:180,column:58}},81:{start:{line:182,column:21},end:{line:220,column:3}},82:{start:{line:183,column:25},end:{line:183,column:72}},83:{start:{line:184,column:22},end:{line:184,column:61}},84:{start:{line:185,column:22},end:{line:185,column:32}},85:{start:{line:187,column:4},end:{line:218,column:5}},86:{start:{line:188,column:6},end:{line:207,column:7}},87:{start:{line:189,column:8},end:{line:196,column:10}},88:{start:{line:194,column:12},end:{line:194,column:111}},89:{start:{line:198,column:8},end:{line:206,column:10}},90:{start:{line:209,column:6},end:{line:217,column:8}},91:{start:{line:219,column:4},end:{line:219,column:56}},92:{start:{line:221,column:18},end:{line:223,column:3}},93:{start:{line:222,column:4},end:{line:222,column:39}},94:{start:{line:224,column:20},end:{line:226,column:3}},95:{start:{line:225,column:4},end:{line:225,column:40}},96:{start:{line:228,column:25},end:{line:228,column:35}},97:{start:{line:229,column:22},end:{line:229,column:132}},98:{start:{line:231,column:4},end:{line:295,column:5}},99:{start:{line:232,column:6},end:{line:247,column:8}},100:{start:{line:248,column:11},end:{line:295,column:5}},101:{start:{line:249,column:6},end:{line:263,column:8}},102:{start:{line:264,column:11},end:{line:295,column:5}},103:{start:{line:265,column:6},end:{line:279,column:8}},104:{start:{line:281,column:6},end:{line:294,column:8}},105:{start:{line:296,column:4},end:{line:296,column:148}}},fnMap:{0:{name:"isLiteralExpression",decl:{start:{line:9,column:9},end:{line:9,column:28}},loc:{start:{line:9,column:36},end:{line:11,column:1}},line:9},1:{name:"isGetExpression",decl:{start:{line:12,column:9},end:{line:12,column:24}},loc:{start:{line:12,column:32},end:{line:14,column:1}},line:12},2:{name:"isZoomField",decl:{start:{line:15,column:9},end:{line:15,column:20}},loc:{start:{line:15,column:28},end:{line:19,column:1}},line:15},3:{name:"(anonymous_3)",decl:{start:{line:16,column:168},end:{line:16,column:169}},loc:{start:{line:16,column:178},end:{line:18,column:3}},line:16},4:{name:"isIdentityProperty",decl:{start:{line:20,column:9},end:{line:20,column:27}},loc:{start:{line:20,column:35},end:{line:22,column:1}},line:20},5:{name:"isDataStopProperty",decl:{start:{line:23,column:9},end:{line:23,column:27}},loc:{start:{line:23,column:35},end:{line:27,column:1}},line:23},6:{name:"(anonymous_6)",decl:{start:{line:24,column:168},end:{line:24,column:169}},loc:{start:{line:24,column:178},end:{line:26,column:3}},line:24},7:{name:"isDataField",decl:{start:{line:28,column:9},end:{line:28,column:20}},loc:{start:{line:28,column:28},end:{line:30,column:1}},line:28},8:{name:"isPrimative",decl:{start:{line:31,column:9},end:{line:31,column:20}},loc:{start:{line:31,column:28},end:{line:34,column:1}},line:31},9:{name:"isArrayOfPrimatives",decl:{start:{line:35,column:9},end:{line:35,column:28}},loc:{start:{line:35,column:37},end:{line:40,column:1}},line:35},10:{name:"getDataType",decl:{start:{line:41,column:9},end:{line:41,column:20}},loc:{start:{line:41,column:44},end:{line:55,column:1}},line:41},11:{name:"(anonymous_11)",decl:{start:{line:57,column:2},end:{line:57,column:3}},loc:{start:{line:57,column:21},end:{line:63,column:3}},line:57},12:{name:"(anonymous_12)",decl:{start:{line:64,column:2},end:{line:64,column:3}},loc:{start:{line:64,column:48},end:{line:73,column:3}},line:64},13:{name:"(anonymous_13)",decl:{start:{line:74,column:2},end:{line:74,column:3}},loc:{start:{line:74,column:34},end:{line:82,column:3}},line:74},14:{name:"(anonymous_14)",decl:{start:{line:83,column:12},end:{line:83,column:13}},loc:{start:{line:83,column:18},end:{line:99,column:3}},line:83},15:{name:"(anonymous_15)",decl:{start:{line:100,column:21},end:{line:100,column:22}},loc:{start:{line:100,column:27},end:{line:106,column:3}},line:100},16:{name:"(anonymous_16)",decl:{start:{line:107,column:15},end:{line:107,column:16}},loc:{start:{line:107,column:28},end:{line:118,column:3}},line:107},17:{name:"(anonymous_17)",decl:{start:{line:119,column:21},end:{line:119,column:22}},loc:{start:{line:119,column:27},end:{line:148,column:3}},line:119},18:{name:"(anonymous_18)",decl:{start:{line:126,column:33},end:{line:126,column:34}},loc:{start:{line:126,column:43},end:{line:128,column:11}},line:126},19:{name:"(anonymous_19)",decl:{start:{line:149,column:19},end:{line:149,column:20}},loc:{start:{line:149,column:25},end:{line:165,column:3}},line:149},20:{name:"(anonymous_20)",decl:{start:{line:166,column:12},end:{line:166,column:13}},loc:{start:{line:166,column:18},end:{line:169,column:3}},line:166},21:{name:"(anonymous_21)",decl:{start:{line:170,column:19},end:{line:170,column:20}},loc:{start:{line:170,column:25},end:{line:181,column:3}},line:170},22:{name:"(anonymous_22)",decl:{start:{line:182,column:21},end:{line:182,column:22}},loc:{start:{line:182,column:27},end:{line:220,column:3}},line:182},23:{name:"(anonymous_23)",decl:{start:{line:193,column:33},end:{line:193,column:34}},loc:{start:{line:193,column:43},end:{line:195,column:11}},line:193},24:{name:"(anonymous_24)",decl:{start:{line:221,column:18},end:{line:221,column:19}},loc:{start:{line:221,column:24},end:{line:223,column:3}},line:221},25:{name:"(anonymous_25)",decl:{start:{line:224,column:20},end:{line:224,column:21}},loc:{start:{line:224,column:26},end:{line:226,column:3}},line:224},26:{name:"(anonymous_26)",decl:{start:{line:227,column:2},end:{line:227,column:3}},loc:{start:{line:227,column:11},end:{line:297,column:3}},line:227}},branchMap:{0:{loc:{start:{line:10,column:9},end:{line:10,column:77}},type:"binary-expr",locations:[{start:{line:10,column:9},end:{line:10,column:29}},{start:{line:10,column:33},end:{line:10,column:51}},{start:{line:10,column:55},end:{line:10,column:77}}],line:10},1:{loc:{start:{line:13,column:9},end:{line:13,column:73}},type:"binary-expr",locations:[{start:{line:13,column:9},end:{line:13,column:29}},{start:{line:13,column:33},end:{line:13,column:51}},{start:{line:13,column:55},end:{line:13,column:73}}],line:13},2:{loc:{start:{line:16,column:9},end:{line:18,column:4}},type:"binary-expr",locations:[{start:{line:16,column:9},end:{line:16,column:34}},{start:{line:16,column:38},end:{line:16,column:49}},{start:{line:16,column:53},end:{line:16,column:90}},{start:{line:16,column:94},end:{line:16,column:120}},{start:{line:16,column:124},end:{line:16,column:146}},{start:{line:16,column:150},end:{line:18,column:4}}],line:16},3:{loc:{start:{line:17,column:11},end:{line:17,column:51}},type:"binary-expr",locations:[{start:{line:17,column:11},end:{line:17,column:30}},{start:{line:17,column:34},end:{line:17,column:51}}],line:17},4:{loc:{start:{line:21,column:9},end:{line:21,column:122}},type:"binary-expr",locations:[{start:{line:21,column:9},end:{line:21,column:34}},{start:{line:21,column:38},end:{line:21,column:63}},{start:{line:21,column:67},end:{line:21,column:122}}],line:21},5:{loc:{start:{line:24,column:9},end:{line:26,column:4}},type:"binary-expr",locations:[{start:{line:24,column:9},end:{line:24,column:34}},{start:{line:24,column:38},end:{line:24,column:49}},{start:{line:24,column:53},end:{line:24,column:90}},{start:{line:24,column:94},end:{line:24,column:116}},{start:{line:24,column:120},end:{line:24,column:146}},{start:{line:24,column:150},end:{line:26,column:4}}],line:24},6:{loc:{start:{line:25,column:11},end:{line:25,column:82}},type:"binary-expr",locations:[{start:{line:25,column:11},end:{line:25,column:30}},{start:{line:25,column:34},end:{line:25,column:51}},{start:{line:25,column:55},end:{line:25,column:82}}],line:25},7:{loc:{start:{line:29,column:9},end:{line:29,column:63}},type:"binary-expr",locations:[{start:{line:29,column:9},end:{line:29,column:34}},{start:{line:29,column:38},end:{line:29,column:63}}],line:29},8:{loc:{start:{line:36,column:2},end:{line:38,column:3}},type:"if",locations:[{start:{line:36,column:2},end:{line:38,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:36},9:{loc:{start:{line:41,column:28},end:{line:41,column:42}},type:"default-arg",locations:[{start:{line:41,column:40},end:{line:41,column:42}}],line:41},10:{loc:{start:{line:42,column:2},end:{line:54,column:3}},type:"if",locations:[{start:{line:42,column:2},end:{line:54,column:3}},{start:{line:44,column:9},end:{line:54,column:3}}],line:42},11:{loc:{start:{line:44,column:9},end:{line:54,column:3}},type:"if",locations:[{start:{line:44,column:9},end:{line:54,column:3}},{start:{line:46,column:9},end:{line:54,column:3}}],line:44},12:{loc:{start:{line:46,column:9},end:{line:54,column:3}},type:"if",locations:[{start:{line:46,column:9},end:{line:54,column:3}},{start:{line:48,column:9},end:{line:54,column:3}}],line:46},13:{loc:{start:{line:46,column:13},end:{line:46,column:69}},type:"binary-expr",locations:[{start:{line:46,column:13},end:{line:46,column:39}},{start:{line:46,column:43},end:{line:46,column:69}}],line:46},14:{loc:{start:{line:48,column:9},end:{line:54,column:3}},type:"if",locations:[{start:{line:48,column:9},end:{line:54,column:3}},{start:{line:50,column:9},end:{line:54,column:3}}],line:48},15:{loc:{start:{line:50,column:9},end:{line:54,column:3}},type:"if",locations:[{start:{line:50,column:9},end:{line:54,column:3}},{start:{line:52,column:9},end:{line:54,column:3}}],line:50},16:{loc:{start:{line:65,column:4},end:{line:72,column:5}},type:"if",locations:[{start:{line:65,column:4},end:{line:72,column:5}},{start:{line:67,column:11},end:{line:72,column:5}}],line:65},17:{loc:{start:{line:75,column:4},end:{line:77,column:5}},type:"if",locations:[{start:{line:75,column:4},end:{line:77,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:75},18:{loc:{start:{line:78,column:4},end:{line:80,column:5}},type:"if",locations:[{start:{line:78,column:4},end:{line:80,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:78},19:{loc:{start:{line:86,column:4},end:{line:93,column:5}},type:"if",locations:[{start:{line:86,column:4},end:{line:93,column:5}},{start:{line:91,column:11},end:{line:93,column:5}}],line:86},20:{loc:{start:{line:114,column:4},end:{line:116,column:5}},type:"if",locations:[{start:{line:114,column:4},end:{line:116,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:114},21:{loc:{start:{line:122,column:4},end:{line:146,column:5}},type:"if",locations:[{start:{line:122,column:4},end:{line:146,column:5}},{start:{line:139,column:11},end:{line:146,column:5}}],line:122},22:{loc:{start:{line:123,column:6},end:{line:138,column:7}},type:"if",locations:[{start:{line:123,column:6},end:{line:138,column:7}},{start:{line:130,column:13},end:{line:138,column:7}}],line:123},23:{loc:{start:{line:127,column:34},end:{line:127,column:86}},type:"binary-expr",locations:[{start:{line:127,column:34},end:{line:127,column:41}},{start:{line:127,column:45},end:{line:127,column:86}}],line:127},24:{loc:{start:{line:142,column:14},end:{line:142,column:64}},type:"binary-expr",locations:[{start:{line:142,column:14},end:{line:142,column:19}},{start:{line:142,column:23},end:{line:142,column:64}}],line:142},25:{loc:{start:{line:143,column:15},end:{line:143,column:65}},type:"binary-expr",locations:[{start:{line:143,column:15},end:{line:143,column:20}},{start:{line:143,column:24},end:{line:143,column:65}}],line:143},26:{loc:{start:{line:151,column:4},end:{line:164,column:5}},type:"if",locations:[{start:{line:151,column:4},end:{line:164,column:5}},{start:{line:159,column:11},end:{line:164,column:5}}],line:151},27:{loc:{start:{line:159,column:11},end:{line:164,column:5}},type:"if",locations:[{start:{line:159,column:11},end:{line:164,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:159},28:{loc:{start:{line:168,column:11},end:{line:168,column:139}},type:"binary-expr",locations:[{start:{line:168,column:11},end:{line:168,column:33}},{start:{line:168,column:37},end:{line:168,column:63}},{start:{line:168,column:67},end:{line:168,column:85}},{start:{line:168,column:89},end:{line:168,column:109}},{start:{line:168,column:113},end:{line:168,column:139}}],line:168},29:{loc:{start:{line:173,column:4},end:{line:179,column:5}},type:"if",locations:[{start:{line:173,column:4},end:{line:179,column:5}},{start:{line:175,column:11},end:{line:179,column:5}}],line:173},30:{loc:{start:{line:173,column:8},end:{line:173,column:53}},type:"binary-expr",locations:[{start:{line:173,column:8},end:{line:173,column:33}},{start:{line:173,column:37},end:{line:173,column:53}}],line:173},31:{loc:{start:{line:175,column:11},end:{line:179,column:5}},type:"if",locations:[{start:{line:175,column:11},end:{line:179,column:5}},{start:{line:177,column:11},end:{line:179,column:5}}],line:175},32:{loc:{start:{line:178,column:31},end:{line:178,column:68}},type:"binary-expr",locations:[{start:{line:178,column:31},end:{line:178,column:36}},{start:{line:178,column:40},end:{line:178,column:68}}],line:178},33:{loc:{start:{line:184,column:22},end:{line:184,column:61}},type:"cond-expr",locations:[{start:{line:184,column:55},end:{line:184,column:57}},{start:{line:184,column:60},end:{line:184,column:61}}],line:184},34:{loc:{start:{line:187,column:4},end:{line:218,column:5}},type:"if",locations:[{start:{line:187,column:4},end:{line:218,column:5}},{start:{line:208,column:11},end:{line:218,column:5}}],line:187},35:{loc:{start:{line:188,column:6},end:{line:207,column:7}},type:"if",locations:[{start:{line:188,column:6},end:{line:207,column:7}},{start:{line:197,column:13},end:{line:207,column:7}}],line:188},36:{loc:{start:{line:194,column:57},end:{line:194,column:109}},type:"binary-expr",locations:[{start:{line:194,column:57},end:{line:194,column:64}},{start:{line:194,column:68},end:{line:194,column:109}}],line:194},37:{loc:{start:{line:214,column:42},end:{line:214,column:103}},type:"binary-expr",locations:[{start:{line:214,column:42},end:{line:214,column:58}},{start:{line:214,column:62},end:{line:214,column:103}}],line:214},38:{loc:{start:{line:215,column:43},end:{line:215,column:104}},type:"binary-expr",locations:[{start:{line:215,column:43},end:{line:215,column:59}},{start:{line:215,column:63},end:{line:215,column:104}}],line:215},39:{loc:{start:{line:229,column:22},end:{line:229,column:132}},type:"cond-expr",locations:[{start:{line:229,column:74},end:{line:229,column:101}},{start:{line:229,column:104},end:{line:229,column:132}}],line:229},40:{loc:{start:{line:231,column:4},end:{line:295,column:5}},type:"if",locations:[{start:{line:231,column:4},end:{line:295,column:5}},{start:{line:248,column:11},end:{line:295,column:5}}],line:231},41:{loc:{start:{line:248,column:11},end:{line:295,column:5}},type:"if",locations:[{start:{line:248,column:11},end:{line:295,column:5}},{start:{line:264,column:11},end:{line:295,column:5}}],line:248},42:{loc:{start:{line:264,column:11},end:{line:295,column:5}},type:"if",locations:[{start:{line:264,column:11},end:{line:295,column:5}},{start:{line:280,column:11},end:{line:295,column:5}}],line:264}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0,74:0,75:0,76:0,77:0,78:0,79:0,80:0,81:0,82:0,83:0,84:0,85:0,86:0,87:0,88:0,89:0,90:0,91:0,92:0,93:0,94:0,95:0,96:0,97:0,98:0,99:0,100:0,101:0,102:0,103:0,104:0,105:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0},b:{0:[0,0,0],1:[0,0,0],2:[0,0,0,0,0,0],3:[0,0],4:[0,0,0],5:[0,0,0,0,0,0],6:[0,0,0],7:[0,0],8:[0,0],9:[0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0],17:[0,0],18:[0,0],19:[0,0],20:[0,0],21:[0,0],22:[0,0],23:[0,0],24:[0,0],25:[0,0],26:[0,0],27:[0,0],28:[0,0,0,0,0],29:[0,0],30:[0,0],31:[0,0],32:[0,0],33:[0,0],34:[0,0],35:[0,0],36:[0,0],37:[0,0],38:[0,0],39:[0,0],40:[0,0],41:[0,0],42:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldFunction.tsx"],names:[],mappings:"AAkVQ;AAlVR,OAAO,WAAW;AAElB,OAAO,kBAAkB;AACzB,OAAO,kBAA4B;AACnC,OAAO,kBAAkB;AACzB,OAAO,wBAAwB;AAC/B,SAAQ,YAAY,qBAAoB;AACxC,SAAQ,2BAA0B;AAGlC,SAAS,oBAAoB,OAAY;AACvC,SAAQ,MAAM,QAAQ,KAAK,KAAK,MAAM,WAAW,KAAK,MAAM,CAAC,MAAM;AACrE;AAEA,SAAS,gBAAgB,OAAY;AACnC,SACE,MAAM,QAAQ,KAAK,KACnB,MAAM,WAAW,KACjB,MAAM,CAAC,MAAM;AAEjB;AAEA,SAAS,YAAY,OAAY;AAC/B,SACE,OAAO,UAAW,YAClB,MAAM,SACN,OAAO,MAAM,aAAc,eAC3B,MAAM,QAAQ,MAAM,KAAK,KACzB,MAAM,MAAM,SAAS,KACrB,MAAM,MAAM,MAAM,CAAC,SAAe;AAChC,WACE,MAAM,QAAQ,IAAI,KAClB,KAAK,WAAW;AAAA,EAEpB,CAAC;AAEL;AAEA,SAAS,mBAAmB,OAAY;AACtC,SACE,OAAO,UAAW,YAClB,MAAM,SAAS,cACf,OAAO,UAAU,eAAe,KAAK,OAAO,UAAU;AAE1D;AAEA,SAAS,mBAAmB,OAAY;AACtC,SACE,OAAO,UAAW,YAClB,MAAM,SACN,OAAO,MAAM,aAAc,eAC3B,MAAM,MAAM,SAAS,KACrB,MAAM,QAAQ,MAAM,KAAK,KACzB,MAAM,MAAM,MAAM,CAAC,SAAe;AAChC,WACE,MAAM,QAAQ,IAAI,KAClB,KAAK,WAAW,KAChB,OAAO,KAAK,CAAC,MAAO;AAAA,EAExB,CAAC;AAEL;AAEA,SAAS,YAAY,OAAY;AAC/B,SACE,mBAAmB,KAAK,KACxB,mBAAmB,KAAK;AAE5B;AAEA,SAAS,YAAY,OAAgD;AACnE,QAAM,QAAQ,CAAC,UAAU,WAAW,QAAQ;AAC5C,SAAO,MAAM,SAAS,OAAO,KAAM;AACrC;AAEA,SAAS,oBAAoB,QAAyD;AACpF,MAAI,MAAM,QAAQ,MAAM,GAAG;AACzB,WAAO,OAAO,MAAM,WAAW;AAAA,EACjC;AACA,SAAO;AACT;AAEA,SAAS,YAAY,OAAY,YAAU,CAAC,GAAU;AACpD,MAAI,UAAU,QAAW;AACvB,WAAO;AAAA,EACT,WACS,YAAY,KAAK,GAAG;AAC3B,WAAO;AAAA,EACT,WACS,UAAU,SAAS,WAAW,oBAAoB,KAAK,GAAG;AACjE,WAAO;AAAA,EACT,WACS,YAAY,KAAK,GAAG;AAC3B,WAAO;AAAA,EACT,WACS,YAAY,KAAK,GAAG;AAC3B,WAAO;AAAA,EACT,OACK;AACH,WAAO;AAAA,EACT;AACF;AAoBA,qBAAqB,sBAAsB,MAAM,UAAkD;AAAA,EACjG,YAAa,OAA2B;AACtC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,UAAU,YAAY,MAAM,OAAO,MAAM,SAAS;AAAA,MAClD,WAAW;AAAA,IACb;AAAA,EACF;AAAA,EAEA,OAAO,yBAAyB,OAA2B,OAA2B;AAEpF,QAAI,MAAM,WAAW;AACnB,aAAO,CAAC;AAAA,IACV,OACK;AACH,aAAO;AAAA,QACL,WAAW;AAAA,QACX,UAAU,YAAY,MAAM,OAAO,MAAM,SAAS;AAAA,MACpD;AAAA,IACF;AAAA,EACF;AAAA,EAEA,qBAAqB,WAAgB;AACnC,QAAI,UAAU,WAAW,cAAc;AACrC,aAAO;AAAA,IACT;AACA,QAAI,UAAU,SAAS,UAAU;AAC/B,aAAO;AAAA,IACT;AACA,WAAO;AAAA,EACT;AAAA,EAEA,UAAU,MAAM;AACd,UAAM,QAAQ,KAAK,MAAM,MAAM,MAAM,MAAM,CAAC;AAC5C,UAAM,WAAW,MAAM,MAAM,SAAS,CAAC;AACvC,QAAI,OAAO,SAAS,CAAC,MAAM,UAAU;AACnC,YAAM,KAAK;AAAA,QACT,EAAC,MAAM,SAAS,CAAC,EAAE,OAAO,GAAG,OAAO,SAAS,CAAC,EAAE,MAAK;AAAA,QACrD,SAAS,CAAC;AAAA,MACZ,CAAC;AAAA,IACH,OACK;AACH,YAAM,KAAK,CAAC,SAAS,CAAC,IAAI,GAAG,SAAS,CAAC,CAAC,CAAC;AAAA,IAC3C;AAEA,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd;AAAA,IACF;AAEA,SAAK,MAAM,SAAS,KAAK,MAAM,WAAW,YAAY;AAAA,EACxD;AAAA,EAEA,mBAAmB,MAAM;AACvB,UAAM,EAAC,WAAW,UAAS,IAAI,KAAK;AACpC,SAAK,MAAM,SAAS,WAAW,UAAU,OAAO;AAChD,SAAK,SAAS;AAAA,MACZ,UAAU;AAAA,IACZ,CAAC;AAAA,EACH;AAAA,EAEA,aAAa,CAAC,YAAoB;AAChC,UAAM,QAAQ,KAAK,MAAM,MAAM,MAAM,MAAM,CAAC;AAC5C,UAAM,OAAO,SAAS,CAAC;AAEvB,QAAI,eAAe;AAAA,MACjB,GAAG,KAAK,MAAM;AAAA,MACd;AAAA,IACF;AAEA,QAAG,MAAM,WAAW,GAAG;AACrB,qBAAe,MAAM,CAAC,EAAE,CAAC;AAAA,IAC3B;AAEA,SAAK,MAAM,SAAS,KAAK,MAAM,WAAW,YAAY;AAAA,EACxD;AAAA,EAEA,mBAAmB,MAAM;AACvB,UAAM,EAAC,MAAK,IAAI,KAAK;AAErB,QAAI;AACJ,QAAI,OAAO,UAAW,UAAU;AAC9B,UAAI,MAAM,OAAO;AACf,mBAAW;AAAA,UACT,MAAM,MAAM;AAAA,UACZ,OAAO,MAAM,MAAM,IAAI,CAAC,SAAe;AACrC,mBAAO,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,CAAC,KAAK,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,UAC5E,CAAC;AAAA,QACH;AAAA,MACF,OACK;AACH,mBAAW;AAAA,UACT,MAAM,MAAM;AAAA,UACZ,OAAO;AAAA,YACL,CAAC,GAAG,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,YAC7C,CAAC,IAAI,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,UAChD;AAAA,QACF;AAAA,MACF;AAAA,IACF,OACK;AACH,iBAAW;AAAA,QACT,OAAO;AAAA,UACL,CAAC,GAAG,SAAS,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,UACtD,CAAC,IAAI,SAAS,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,QACzD;AAAA,MACF;AAAA,IACF;AAEA,SAAK,MAAM,SAAS,KAAK,MAAM,WAAW,QAAQ;AAAA,EACpD;AAAA,EAEA,iBAAiB,MAAM;AACrB,UAAM,EAAC,OAAO,UAAS,IAAI,KAAK;AAEhC,QAAI,gBAAgB,KAAK,GAAG;AAC1B,WAAK,MAAM,SAAS,WAAW;AAAA,QAC7B,QAAQ;AAAA,QACR,YAAY,MAAM,CAAC;AAAA,MACrB,CAAC;AACD,WAAK,SAAS;AAAA,QACZ,UAAU;AAAA,MACZ,CAAC;AAAA,IACH,WACS,oBAAoB,KAAK,GAAG;AACnC,WAAK,MAAM,SAAS,WAAW,MAAM,CAAC,CAAC;AACvC,WAAK,SAAS;AAAA,QACZ,UAAU;AAAA,MACZ,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,UAAU,MAAM;AACd,UAAM,EAAC,OAAO,UAAS,IAAI,KAAK;AAChC,WACE,gBAAgB,KAAK,KACrB,oBAAoB,KAAK,KACzB,YAAY,KAAK,KAChB,MAAM,QAAQ,KAAK,KAAK,UAAU,SAAS;AAAA,EAEhD;AAAA,EAEA,iBAAiB,MAAM;AACrB,UAAM,EAAC,OAAO,UAAS,IAAI,KAAK;AAChC,QAAI;AAEJ,QAAI,OAAO,UAAW,YAAY,WAAW,OAAO;AAClD,mBAAa,cAAc,gBAAgB,OAAO,SAAS;AAAA,IAC7D,WACS,mBAAmB,KAAK,GAAG;AAClC,mBAAa,CAAC,OAAO,MAAM,QAAQ;AAAA,IACrC,OACK;AACH,mBAAa,CAAC,WAAW,SAAS,KAAK,MAAM,UAAU,OAAO;AAAA,IAChE;AACA,SAAK,MAAM,SAAS,KAAK,MAAM,WAAW,UAAU;AAAA,EACtD;AAAA,EAEA,mBAAmB,MAAM;AACvB,UAAM,eAAe,KAAK,qBAAqB,KAAK,MAAM,SAAS;AACnE,UAAM,YAAY,iBAAiB,gBAAgB,KAAK;AACxD,UAAM,EAAC,MAAK,IAAI,KAAK;AACrB,QAAI;AAEJ,QAAI,OAAO,UAAW,UAAU;AAC9B,UAAI,MAAM,OAAO;AACf,mBAAW;AAAA,UACT,UAAU;AAAA,UACV,MAAM;AAAA,UACN,MAAM,MAAM;AAAA,UACZ,OAAO,MAAM,MAAM,IAAI,CAAC,SAAe;AACrC,mBAAO,CAAC,EAAC,MAAM,KAAK,CAAC,GAAG,OAAO,UAAS,GAAG,KAAK,CAAC,KAAK,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,UACjG,CAAC;AAAA,QACH;AAAA,MACF,OACK;AACH,mBAAW;AAAA,UACT,UAAU;AAAA,UACV,MAAM;AAAA,UACN,MAAM,MAAM;AAAA,UACZ,OAAO;AAAA,YACL,CAAC,EAAC,MAAM,GAAG,OAAO,UAAS,GAAG,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,YACvE,CAAC,EAAC,MAAM,IAAI,OAAO,UAAS,GAAG,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,UAC1E;AAAA,QACF;AAAA,MACF;AAAA,IACF,OACK;AACH,iBAAW;AAAA,QACT,UAAU;AAAA,QACV,MAAM;AAAA,QACN,MAAM,MAAM;AAAA,QACZ,OAAO;AAAA,UACL,CAAC,EAAC,MAAM,GAAG,OAAO,UAAS,GAAG,KAAK,MAAM,SAAS,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,UAC3F,CAAC,EAAC,MAAM,IAAI,OAAO,UAAS,GAAG,KAAK,MAAM,SAAS,oBAAoB,KAAK,MAAM,SAAS,CAAC;AAAA,QAC9F;AAAA,MACF;AAAA,IACF;AAEA,SAAK,MAAM,SAAS,KAAK,MAAM,WAAW,QAAQ;AAAA,EACpD;AAAA,EAEA,gBAAgB,MAAM;AACpB,SAAK,SAAS,EAAC,WAAW,KAAI,CAAC;AAAA,EACjC;AAAA,EAEA,kBAAkB,MAAM;AACtB,SAAK,SAAS,EAAC,WAAW,MAAK,CAAC;AAAA,EAClC;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,SAAQ,IAAI,KAAK;AACxB,UAAM,YAAY,KAAK,MAAM,UAAU,YAAY,KAAK,MAAM,QAAQ,8BAA8B;AACpG,QAAI;AAEJ,QAAI,aAAa,cAAc;AAC7B,kBACE;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ,KAAK,MAAM;AAAA,UACnB,UAAU,KAAK,MAAM,SAAS,KAAK,MAAM,KAAK,MAAM,SAAS;AAAA,UAC7D,SAAS,KAAK;AAAA,UACd,QAAQ,KAAK;AAAA,UACb,UAAU,KAAK;AAAA,UACf,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,OAAO,KAAK,MAAM;AAAA,UAClB,SAAS,KAAK;AAAA,UACd,QAAQ,KAAK;AAAA;AAAA,MACf;AAAA,IAEJ,WACS,aAAa,iBAAiB;AACrC,kBACE;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ,KAAK,MAAM;AAAA,UACnB,UAAU,KAAK,MAAM,SAAS,KAAK,IAAI;AAAA,UACvC,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,OAAO,KAAK,MAAM;AAAA,UAClB,cAAc,KAAK;AAAA,UACnB,WAAW,KAAK;AAAA,UAChB,wBAAwB,KAAK;AAAA,UAC7B,mBAAmB,KAAK;AAAA;AAAA,MAC1B;AAAA,IAEJ,WACS,aAAa,iBAAiB;AAErC,kBACE;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ,KAAK,MAAM;AAAA,UACnB,UAAU,KAAK,MAAM,SAAS,KAAK,IAAI;AAAA,UACvC,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,OAAO,KAAK,MAAM;AAAA,UAClB,cAAc,KAAK;AAAA,UACnB,WAAW,KAAK;AAAA,UAChB,wBAAwB,KAAK;AAAA,UAC7B,mBAAmB,KAAK;AAAA;AAAA,MAC1B;AAAA,IAEJ,OACK;AACH,kBACE;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ,KAAK,MAAM;AAAA,UACnB,UAAU,KAAK,MAAM,SAAS,KAAK,IAAI;AAAA,UACvC,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,WAAW,KAAK,MAAM;AAAA,UACtB,OAAO,KAAK,MAAM;AAAA,UAClB,aAAa,KAAK;AAAA,UAClB,aAAa,KAAK;AAAA,UAClB,mBAAmB,KAAK;AAAA;AAAA,MAC1B;AAAA,IAEJ;AACA,WAAO,oBAAC,SAAI,WAAW,WAAW,eAAa,0BAAwB,KAAK,MAAM,WAC/E,qBACH;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"435f90d980cace940b69ce8c0aa30d2fab175109"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ut=function(){return s},s}ut();function dP(e){return ut().f[0]++,ut().s[0]++,ut().b[0][0]++,Array.isArray(e)&&(ut().b[0][1]++,e.length===2)&&(ut().b[0][2]++,e[0]==="literal")}function hP(e){return ut().f[1]++,ut().s[1]++,ut().b[1][0]++,Array.isArray(e)&&(ut().b[1][1]++,e.length===2)&&(ut().b[1][2]++,e[0]==="get")}function h6e(e){return ut().f[2]++,ut().s[2]++,ut().b[2][0]++,typeof e=="object"&&(ut().b[2][1]++,e.stops)&&(ut().b[2][2]++,typeof e.property>"u")&&(ut().b[2][3]++,Array.isArray(e.stops))&&(ut().b[2][4]++,e.stops.length>1)&&(ut().b[2][5]++,e.stops.every(n=>(ut().f[3]++,ut().s[3]++,ut().b[3][0]++,Array.isArray(n)&&(ut().b[3][1]++,n.length===2))))}function HN(e){return ut().f[4]++,ut().s[4]++,ut().b[4][0]++,typeof e=="object"&&(ut().b[4][1]++,e.type==="identity")&&(ut().b[4][2]++,Object.prototype.hasOwnProperty.call(e,"property"))}function f6e(e){return ut().f[5]++,ut().s[5]++,ut().b[5][0]++,typeof e=="object"&&(ut().b[5][1]++,e.stops)&&(ut().b[5][2]++,typeof e.property<"u")&&(ut().b[5][3]++,e.stops.length>1)&&(ut().b[5][4]++,Array.isArray(e.stops))&&(ut().b[5][5]++,e.stops.every(n=>(ut().f[6]++,ut().s[6]++,ut().b[6][0]++,Array.isArray(n)&&(ut().b[6][1]++,n.length===2)&&(ut().b[6][2]++,typeof n[0]=="object"))))}function p6e(e){return ut().f[7]++,ut().s[7]++,ut().b[7][0]++,HN(e)||(ut().b[7][1]++,f6e(e))}function q8(e){ut().f[8]++;const n=(ut().s[8]++,["string","boolean","number"]);return ut().s[9]++,n.includes(typeof e)}function m6e(e){return ut().f[9]++,ut().s[10]++,Array.isArray(e)?(ut().b[8][0]++,ut().s[11]++,e.every(q8)):(ut().b[8][1]++,ut().s[12]++,!1)}function fP(e,n=(ut().b[9][0]++,{})){return ut().f[10]++,ut().s[13]++,e===void 0?(ut().b[10][0]++,ut().s[14]++,"value"):(ut().b[10][1]++,ut().s[15]++,q8(e)?(ut().b[11][0]++,ut().s[16]++,"value"):(ut().b[11][1]++,ut().s[17]++,ut().b[13][0]++,n.type==="array"&&(ut().b[13][1]++,m6e(e))?(ut().b[12][0]++,ut().s[18]++,"value"):(ut().b[12][1]++,ut().s[19]++,h6e(e)?(ut().b[14][0]++,ut().s[20]++,"zoom_function"):(ut().b[14][1]++,ut().s[21]++,p6e(e)?(ut().b[15][0]++,ut().s[22]++,"data_function"):(ut().b[15][1]++,ut().s[23]++,"expression")))))}class g6e extends bn.Component{constructor(t){ut().f[11]++,ut().s[24]++;super(t);nn(this,"addStop",(ut().s[34]++,()=>{ut().f[14]++;const t=(ut().s[35]++,this.props.value.stops.slice(0)),r=(ut().s[36]++,t[t.length-1]);ut().s[37]++,typeof r[0]=="object"?(ut().b[19][0]++,ut().s[38]++,t.push([{zoom:r[0].zoom+1,value:r[0].value},r[1]])):(ut().b[19][1]++,ut().s[39]++,t.push([r[0]+1,r[1]]));const i=(ut().s[40]++,{...this.props.value,stops:t});ut().s[41]++,this.props.onChange(this.props.fieldName,i)}));nn(this,"deleteExpression",(ut().s[42]++,()=>{ut().f[15]++;const{fieldSpec:t,fieldName:r}=(ut().s[43]++,this.props);ut().s[44]++,this.props.onChange(r,t.default),ut().s[45]++,this.setState({dataType:"value"})}));nn(this,"deleteStop",(ut().s[46]++,t=>{ut().f[16]++;const r=(ut().s[47]++,this.props.value.stops.slice(0));ut().s[48]++,r.splice(t,1);let i=(ut().s[49]++,{...this.props.value,stops:r});ut().s[50]++,r.length===1?(ut().b[20][0]++,ut().s[51]++,i=r[0][1]):ut().b[20][1]++,ut().s[52]++,this.props.onChange(this.props.fieldName,i)}));nn(this,"makeZoomFunction",(ut().s[53]++,()=>{ut().f[17]++;const{value:t}=(ut().s[54]++,this.props);let r;ut().s[55]++,typeof t=="object"?(ut().b[21][0]++,ut().s[56]++,t.stops?(ut().b[22][0]++,ut().s[57]++,r={base:t.base,stops:t.stops.map(i=>(ut().f[18]++,ut().s[58]++,[i[0].zoom,(ut().b[23][0]++,i[1]||(ut().b[23][1]++,fd(this.props.fieldSpec)))]))}):(ut().b[22][1]++,ut().s[59]++,r={base:t.base,stops:[[6,fd(this.props.fieldSpec)],[10,fd(this.props.fieldSpec)]]})):(ut().b[21][1]++,ut().s[60]++,r={stops:[[6,(ut().b[24][0]++,t||(ut().b[24][1]++,fd(this.props.fieldSpec)))],[10,(ut().b[25][0]++,t||(ut().b[25][1]++,fd(this.props.fieldSpec)))]]}),ut().s[61]++,this.props.onChange(this.props.fieldName,r)}));nn(this,"undoExpression",(ut().s[62]++,()=>{ut().f[19]++;const{value:t,fieldName:r}=(ut().s[63]++,this.props);ut().s[64]++,hP(t)?(ut().b[26][0]++,ut().s[65]++,this.props.onChange(r,{type:"identity",property:t[1]}),ut().s[66]++,this.setState({dataType:"value"})):(ut().b[26][1]++,ut().s[67]++,dP(t)?(ut().b[27][0]++,ut().s[68]++,this.props.onChange(r,t[1]),ut().s[69]++,this.setState({dataType:"value"})):ut().b[27][1]++)}));nn(this,"canUndo",(ut().s[70]++,()=>{ut().f[20]++;const{value:t,fieldSpec:r}=(ut().s[71]++,this.props);return ut().s[72]++,ut().b[28][0]++,hP(t)||(ut().b[28][1]++,dP(t))||(ut().b[28][2]++,q8(t))||(ut().b[28][3]++,Array.isArray(t)&&(ut().b[28][4]++,r.type==="array"))}));nn(this,"makeExpression",(ut().s[73]++,()=>{ut().f[21]++;const{value:t,fieldSpec:r}=(ut().s[74]++,this.props);let i;ut().s[75]++,ut().b[30][0]++,typeof t=="object"&&(ut().b[30][1]++,"stops"in t)?(ut().b[29][0]++,ut().s[76]++,i=BX.convertFunction(t,r)):(ut().b[29][1]++,ut().s[77]++,HN(t)?(ut().b[31][0]++,ut().s[78]++,i=["get",t.property]):(ut().b[31][1]++,ut().s[79]++,i=["literal",(ut().b[32][0]++,t||(ut().b[32][1]++,this.props.fieldSpec.default))])),ut().s[80]++,this.props.onChange(this.props.fieldName,i)}));nn(this,"makeDataFunction",(ut().s[81]++,()=>{ut().f[22]++;const t=(ut().s[82]++,this.getFieldFunctionType(this.props.fieldSpec)),r=(ut().s[83]++,t==="categorical"?(ut().b[33][0]++,""):(ut().b[33][1]++,0)),{value:i}=(ut().s[84]++,this.props);let o;ut().s[85]++,typeof i=="object"?(ut().b[34][0]++,ut().s[86]++,i.stops?(ut().b[35][0]++,ut().s[87]++,o={property:"",type:t,base:i.base,stops:i.stops.map(s=>(ut().f[23]++,ut().s[88]++,[{zoom:s[0],value:r},(ut().b[36][0]++,s[1]||(ut().b[36][1]++,fd(this.props.fieldSpec)))]))}):(ut().b[35][1]++,ut().s[89]++,o={property:"",type:t,base:i.base,stops:[[{zoom:6,value:r},fd(this.props.fieldSpec)],[{zoom:10,value:r},fd(this.props.fieldSpec)]]})):(ut().b[34][1]++,ut().s[90]++,o={property:"",type:t,base:i.base,stops:[[{zoom:6,value:r},(ut().b[37][0]++,this.props.value||(ut().b[37][1]++,fd(this.props.fieldSpec)))],[{zoom:10,value:r},(ut().b[38][0]++,this.props.value||(ut().b[38][1]++,fd(this.props.fieldSpec)))]]}),ut().s[91]++,this.props.onChange(this.props.fieldName,o)}));nn(this,"onMarkEditing",(ut().s[92]++,()=>{ut().f[24]++,ut().s[93]++,this.setState({isEditing:!0})}));nn(this,"onUnmarkEditing",(ut().s[94]++,()=>{ut().f[25]++,ut().s[95]++,this.setState({isEditing:!1})}));ut().s[25]++,this.state={dataType:fP(t.value,t.fieldSpec),isEditing:!1}}static getDerivedStateFromProps(t,r){return ut().f[12]++,ut().s[26]++,r.isEditing?(ut().b[16][0]++,ut().s[27]++,{}):(ut().b[16][1]++,ut().s[28]++,{isEditing:!1,dataType:fP(t.value,t.fieldSpec)})}getFieldFunctionType(t){return ut().f[13]++,ut().s[29]++,t.expression.interpolated?(ut().b[17][0]++,ut().s[30]++,"exponential"):(ut().b[17][1]++,ut().s[31]++,t.type==="number"?(ut().b[18][0]++,ut().s[32]++,"interval"):(ut().b[18][1]++,ut().s[33]++,"categorical"))}render(){ut().f[26]++;const{dataType:t}=(ut().s[96]++,this.state),r=(ut().s[97]++,this.props.fieldSpec.default===this.props.value?(ut().b[39][0]++,"maputnik-default-property"):(ut().b[39][1]++,"maputnik-modified-property"));let i;return ut().s[98]++,t==="expression"?(ut().b[40][0]++,ut().s[99]++,i=N.jsx(m8,{errors:this.props.errors,onChange:this.props.onChange.bind(this,this.props.fieldName),canUndo:this.canUndo,onUndo:this.undoExpression,onDelete:this.deleteExpression,fieldType:this.props.fieldType,fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:this.props.value,onFocus:this.onMarkEditing,onBlur:this.onUnmarkEditing})):(ut().b[40][1]++,ut().s[100]++,t==="zoom_function"?(ut().b[41][0]++,ut().s[101]++,i=N.jsx(VN,{errors:this.props.errors,onChange:this.props.onChange.bind(this),fieldType:this.props.fieldType,fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:this.props.value,onDeleteStop:this.deleteStop,onAddStop:this.addStop,onChangeToDataFunction:this.makeDataFunction,onExpressionClick:this.makeExpression})):(ut().b[41][1]++,ut().s[102]++,t==="data_function"?(ut().b[42][0]++,ut().s[103]++,i=N.jsx(d6e,{errors:this.props.errors,onChange:this.props.onChange.bind(this),fieldType:this.props.fieldType,fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:this.props.value,onDeleteStop:this.deleteStop,onAddStop:this.addStop,onChangeToZoomFunction:this.makeZoomFunction,onExpressionClick:this.makeExpression})):(ut().b[42][1]++,ut().s[104]++,i=N.jsx($N,{errors:this.props.errors,onChange:this.props.onChange.bind(this),fieldType:this.props.fieldType,fieldName:this.props.fieldName,fieldSpec:this.props.fieldSpec,value:this.props.value,onZoomClick:this.makeZoomFunction,onDataClick:this.makeDataFunction,onExpressionClick:this.makeExpression})))),ut().s[105]++,N.jsx("div",{className:r,"data-wd-key":"spec-field-container:"+this.props.fieldName,children:i})}}function yi(){var e="/home/runner/work/maputnik/maputnik/src/components/PropertyGroup.tsx",n="411d3be261f729b266d6cb26884b34616b925c83",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/PropertyGroup.tsx",statementMap:{0:{start:{line:4,column:23},end:{line:4,column:117}},1:{start:{line:6,column:20},end:{line:6,column:60}},2:{start:{line:7,column:16},end:{line:7,column:49}},3:{start:{line:8,column:20},end:{line:8,column:36}},4:{start:{line:9,column:2},end:{line:14,column:3}},5:{start:{line:10,column:4},end:{line:13,column:6}},6:{start:{line:15,column:2},end:{line:20,column:3}},7:{start:{line:16,column:4},end:{line:19,column:6}},8:{start:{line:21,column:2},end:{line:21,column:19}},9:{start:{line:24,column:16},end:{line:24,column:48}},10:{start:{line:25,column:2},end:{line:29,column:3}},11:{start:{line:26,column:4},end:{line:26,column:19}},12:{start:{line:28,column:4},end:{line:28,column:20}},13:{start:{line:32,column:21},end:{line:35,column:3}},14:{start:{line:33,column:18},end:{line:33,column:80}},15:{start:{line:34,column:4},end:{line:34,column:51}},16:{start:{line:37,column:23},end:{line:37,column:33}},17:{start:{line:38,column:19},end:{line:56,column:6}},18:{start:{line:39,column:24},end:{line:39,column:87}},19:{start:{line:40,column:20},end:{line:40,column:48}},20:{start:{line:41,column:21},end:{line:41,column:50}},21:{start:{line:42,column:25},end:{line:42,column:82}},22:{start:{line:43,column:24},end:{line:43,column:63}},23:{start:{line:44,column:6},end:{line:55,column:8}},24:{start:{line:57,column:4},end:{line:57,column:98}}},fnMap:{0:{name:"getFieldSpec",decl:{start:{line:5,column:9},end:{line:5,column:21}},loc:{start:{line:5,column:50},end:{line:22,column:1}},line:5},1:{name:"getGroupName",decl:{start:{line:23,column:9},end:{line:23,column:21}},loc:{start:{line:23,column:50},end:{line:30,column:1}},line:23},2:{name:"(anonymous_2)",decl:{start:{line:32,column:21},end:{line:32,column:22}},loc:{start:{line:32,column:45},end:{line:35,column:3}},line:32},3:{name:"(anonymous_3)",decl:{start:{line:36,column:2},end:{line:36,column:3}},loc:{start:{line:36,column:11},end:{line:58,column:3}},line:36},4:{name:"(anonymous_4)",decl:{start:{line:38,column:46},end:{line:38,column:47}},loc:{start:{line:38,column:61},end:{line:56,column:5}},line:38}},branchMap:{0:{loc:{start:{line:9,column:2},end:{line:14,column:3}},type:"if",locations:[{start:{line:9,column:2},end:{line:14,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:9},1:{loc:{start:{line:15,column:2},end:{line:20,column:3}},type:"if",locations:[{start:{line:15,column:2},end:{line:20,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:15},2:{loc:{start:{line:24,column:16},end:{line:24,column:48}},type:"binary-expr",locations:[{start:{line:24,column:16},end:{line:24,column:42}},{start:{line:24,column:46},end:{line:24,column:48}}],line:24},3:{loc:{start:{line:25,column:2},end:{line:29,column:3}},type:"if",locations:[{start:{line:25,column:2},end:{line:29,column:3}},{start:{line:27,column:9},end:{line:29,column:3}}],line:25},4:{loc:{start:{line:40,column:20},end:{line:40,column:48}},type:"binary-expr",locations:[{start:{line:40,column:20},end:{line:40,column:42}},{start:{line:40,column:46},end:{line:40,column:48}}],line:40},5:{loc:{start:{line:41,column:21},end:{line:41,column:50}},type:"binary-expr",locations:[{start:{line:41,column:21},end:{line:41,column:44}},{start:{line:41,column:48},end:{line:41,column:50}}],line:41},6:{loc:{start:{line:42,column:25},end:{line:42,column:82}},type:"cond-expr",locations:[{start:{line:42,column:46},end:{line:42,column:62}},{start:{line:42,column:65},end:{line:42,column:82}}],line:42},7:{loc:{start:{line:43,column:24},end:{line:43,column:63}},type:"cond-expr",locations:[{start:{line:43,column:45},end:{line:43,column:52}},{start:{line:43,column:55},end:{line:43,column:63}}],line:43}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/PropertyGroup.tsx"],names:[],mappings:"AA+Da;AA/Db,OAAO,WAAW;AAElB,OAAO,mBAAmB;AAG1B,MAAM,iBAAiB,CAAC,sBAAsB,gBAAgB,gBAAgB,0BAA0B,YAAY;AAIpH,SAAS,aAAa,MAAW,WAAuC,WAAmB;AACzF,QAAM,YAAY,aAAa,MAAM,WAAW,SAAS;AACzD,QAAM,QAAQ,KAAK,YAAY,MAAM,SAAS;AAC9C,QAAM,YAAY,MAAM,SAAS;AACjC,MAAG,eAAe,QAAQ,SAAS,KAAK,GAAG;AACzC,WAAO;AAAA,MACL,GAAG;AAAA,MACH,QAAQ,KAAK,MAAM,OAAO;AAAA,IAC5B;AAAA,EACF;AACA,MAAG,cAAc,aAAa;AAC5B,WAAO;AAAA,MACL,GAAG;AAAA,MACH,QAAQ,KAAK,MAAM,OAAO;AAAA,IAC5B;AAAA,EACF;AACA,SAAO;AACT;AAEA,SAAS,aAAa,MAAW,WAAuC,WAAmB;AACzF,QAAM,QAAS,KAAK,WAAW,SAAS,KAAK,CAAC;AAC9C,MAAI,aAAa,OAAO;AACtB,WAAO;AAAA,EACT,OAAO;AACL,WAAO;AAAA,EACT;AACF;AAUA,qBAAqB,sBAAsB,MAAM,UAA8B;AAAA,EAC7E,mBAAmB,CAAC,UAAkB,aAAkB;AACtD,UAAM,QAAQ,aAAa,KAAK,MAAM,MAAM,KAAK,MAAM,MAAM,MAAM,QAAQ;AAC3E,SAAK,MAAM,SAAS,OAAO,UAAU,QAAQ;AAAA,EAC/C;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,OAAM,IAAI,KAAK;AACtB,UAAM,SAAS,KAAK,MAAM,YAAY,IAAI,eAAa;AACrD,YAAM,YAAY,aAAa,KAAK,MAAM,MAAM,KAAK,MAAM,MAAM,MAAM,SAAS;AAEhF,YAAM,QAAQ,KAAK,MAAM,MAAM,SAAS,CAAC;AACzC,YAAM,SAAS,KAAK,MAAM,MAAM,UAAU,CAAC;AAC3C,YAAM,aAAa,aAAa,QAC5B,MAAM,SAA+B,IACrC,OAAO,SAAgC;AAC3C,YAAM,YAAY,aAAa,QAAQ,UAAU;AAEjD,aAAO;AAAA,QAAC;AAAA;AAAA,UACN;AAAA,UACA,UAAU,KAAK;AAAA,UAEf;AAAA,UACA,OAAO;AAAA,UACP;AAAA,UACA;AAAA;AAAA,QAJK;AAAA,MAKP;AAAA,IACF,CAAC;AAED,WAAO,oBAAC,SAAI,WAAU,2BACnB,kBACH;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"411d3be261f729b266d6cb26884b34616b925c83"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return yi=function(){return s},s}yi();const y6e=(yi().s[0]++,["background-pattern","fill-pattern","line-pattern","fill-extrusion-pattern","icon-image"]);function v6e(e,n,t){yi().f[0]++;const r=(yi().s[1]++,ZN(e,n,t)),i=(yi().s[2]++,e[r+"_"+n]),o=(yi().s[3]++,i[t]);return yi().s[4]++,y6e.indexOf(t)>=0?(yi().b[0][0]++,yi().s[5]++,{...o,values:e.$root.sprite.values}):(yi().b[0][1]++,yi().s[6]++,t==="text-font"?(yi().b[1][0]++,yi().s[7]++,{...o,values:e.$root.glyphs.values}):(yi().b[1][1]++,yi().s[8]++,o))}function ZN(e,n,t){yi().f[1]++;const r=(yi().s[9]++,yi().b[2][0]++,e["paint_"+n]||(yi().b[2][1]++,{}));return yi().s[10]++,t in r?(yi().b[3][0]++,yi().s[11]++,"paint"):(yi().b[3][1]++,yi().s[12]++,"layout")}class C6e extends bn.Component{constructor(){super(...arguments);nn(this,"onPropertyChange",(yi().s[13]++,(t,r)=>{yi().f[2]++;const i=(yi().s[14]++,ZN(this.props.spec,this.props.layer.type,t));yi().s[15]++,this.props.onChange(i,t,r)}))}render(){yi().f[3]++;const{errors:t}=(yi().s[16]++,this.props),r=(yi().s[17]++,this.props.groupFields.map(i=>{yi().f[4]++;const o=(yi().s[18]++,v6e(this.props.spec,this.props.layer.type,i)),s=(yi().s[19]++,yi().b[4][0]++,this.props.layer.paint||(yi().b[4][1]++,{})),a=(yi().s[20]++,yi().b[5][0]++,this.props.layer.layout||(yi().b[5][1]++,{})),f=(yi().s[21]++,i in s?(yi().b[6][0]++,s[i]):(yi().b[6][1]++,a[i])),g=(yi().s[22]++,i in s?(yi().b[7][0]++,"paint"):(yi().b[7][1]++,"layout"));return yi().s[23]++,N.jsx(g6e,{errors:t,onChange:this.onPropertyChange,fieldName:i,value:f,fieldType:g,fieldSpec:o},i)}));return yi().s[24]++,N.jsx("div",{className:"maputnik-property-group",children:r})}}var _6e=function(e){var n={};function t(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=n,t.d=function(r,i,o){t.o(r,i)||Object.defineProperty(r,i,{enumerable:!0,get:o})},t.r=function(r){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(r,"__esModule",{value:!0})},t.t=function(r,i){if(1&i&&(r=t(r)),8&i||4&i&&typeof r=="object"&&r&&r.__esModule)return r;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:r}),2&i&&typeof r!="string")for(var s in r)t.d(o,s,(function(a){return r[a]}).bind(null,s));return o},t.n=function(r){var i=r&&r.__esModule?function(){return r.default}:function(){return r};return t.d(i,"a",i),i},t.o=function(r,i){return Object.prototype.hasOwnProperty.call(r,i)},t.p="",t(t.s=2)}([function(e,n){e.exports=ph},function(e,n){e.exports=kr},function(e,n,t){t.r(n);var r=t(1),i=t(0),o=function(){return(o=Object.assign||function(R){for(var H,W=1,$=arguments.length;W<$;W++)for(var q in H=arguments[W])Object.prototype.hasOwnProperty.call(H,q)&&(R[q]=H[q]);return R}).apply(this,arguments)},s=function(R,H){var W={};for(var $ in R)Object.prototype.hasOwnProperty.call(R,$)&&H.indexOf($)<0&&(W[$]=R[$]);if(R!=null&&typeof Object.getOwnPropertySymbols=="function"){var q=0;for($=Object.getOwnPropertySymbols(R);q<$.length;q++)H.indexOf($[q])<0&&Object.prototype.propertyIsEnumerable.call(R,$[q])&&(W[$[q]]=R[$[q]])}return W},a=0,f=r.forwardRef(function(R,H){var W=R.title,$=W===void 0?null:W,q=R.description,oe=q===void 0?null:q,ne=R.size,ce=ne===void 0?null:ne,ae=R.color,ue=ae===void 0?"currentColor":ae,ye=R.horizontal,Re=ye===void 0?null:ye,Ne=R.vertical,rt=Ne===void 0?null:Ne,ct=R.rotate,Fe=ct===void 0?null:ct,He=R.spin,Ce=He===void 0?null:He,jt=R.style,Ft=jt===void 0?{}:jt,Jt=R.children,Nt=s(R,["title","description","size","color","horizontal","vertical","rotate","spin","style","children"]);a++;var Ve,nt=Ce!==null&&Ce,Je=r.Children.map(Jt,function(kt){var Dt=kt;nt!==!0&&(nt=(Ce===null?Dt.props.spin:Ce)===!0);var Se=Dt.props.size;typeof ce=="number"&&typeof Dt.props.size=="number"&&(Se=Dt.props.size/ce);var de={size:Se,color:ue===null?Dt.props.color:ue,horizontal:Re===null?Dt.props.horizontal:Re,vertical:rt===null?Dt.props.vertical:rt,rotate:Fe===null?Dt.props.rotate:Fe,spin:Ce===null?Dt.props.spin:Ce,inStack:!0};return r.cloneElement(Dt,de)});ce!==null&&(Ft.width=typeof ce=="string"?ce:1.5*ce+"rem");var Vt,pt="stack_labelledby_"+a,dt="stack_describedby_"+a;if($)Ve=oe?pt+" "+dt:pt;else if(Vt="presentation",oe)throw new Error("title attribute required when description is set");return r.createElement("svg",o({ref:H,viewBox:"0 0 24 24",style:Ft,role:Vt,"aria-labelledby":Ve},Nt),$&&r.createElement("title",{id:pt},$),oe&&r.createElement("desc",{id:dt},oe),nt&&r.createElement("style",null,"@keyframes spin { from { transform: rotate(0deg) } to { transform: rotate(360deg) } }","@keyframes spin-inverse { from { transform: rotate(0deg) } to { transform: rotate(-360deg) } }"),Je)});f.displayName="Stack",f.propTypes={size:i.oneOfType([i.number,i.string]),color:i.string,horizontal:i.bool,vertical:i.bool,rotate:i.number,spin:i.oneOfType([i.bool,i.number]),children:i.oneOfType([i.arrayOf(i.node),i.node]).isRequired,className:i.string,style:i.object},f.defaultProps={size:null,color:null,horizontal:null,vertical:null,rotate:null,spin:null};var g=f;t.d(n,"Icon",function(){return P}),t.d(n,"Stack",function(){return g});var x=function(){return(x=Object.assign||function(R){for(var H,W=1,$=arguments.length;W<$;W++)for(var q in H=arguments[W])Object.prototype.hasOwnProperty.call(H,q)&&(R[q]=H[q]);return R}).apply(this,arguments)},k=function(R,H){var W={};for(var $ in R)Object.prototype.hasOwnProperty.call(R,$)&&H.indexOf($)<0&&(W[$]=R[$]);if(R!=null&&typeof Object.getOwnPropertySymbols=="function"){var q=0;for($=Object.getOwnPropertySymbols(R);q<$.length;q++)H.indexOf($[q])<0&&Object.prototype.propertyIsEnumerable.call(R,$[q])&&(W[$[q]]=R[$[q]])}return W},B=0,P=r.forwardRef(function(R,H){var W=R.path,$=R.id,q=$===void 0?++B:$,oe=R.title,ne=oe===void 0?null:oe,ce=R.description,ae=ce===void 0?null:ce,ue=R.size,ye=ue===void 0?null:ue,Re=R.color,Ne=Re===void 0?"currentColor":Re,rt=R.horizontal,ct=rt!==void 0&&rt,Fe=R.vertical,He=Fe!==void 0&&Fe,Ce=R.rotate,jt=Ce===void 0?0:Ce,Ft=R.spin,Jt=Ft!==void 0&&Ft,Nt=R.style,Ve=Nt===void 0?{}:Nt,nt=R.inStack,Je=nt!==void 0&&nt,Vt=k(R,["path","id","title","description","size","color","horizontal","vertical","rotate","spin","style","inStack"]),pt={},dt=[];ye!==null&&(Je?dt.push("scale("+ye+")"):(Ve.width=typeof ye=="string"?ye:1.5*ye+"rem",Ve.height=Ve.width)),ct&&dt.push("scaleX(-1)"),He&&dt.push("scaleY(-1)"),jt!==0&&dt.push("rotate("+jt+"deg)"),Ne!==null&&(pt.fill=Ne);var kt=r.createElement("path",x({d:W,style:pt},Je?Vt:{})),Dt=kt;dt.length>0&&(Ve.transform=dt.join(" "),Ve.transformOrigin="center",Je&&(Dt=r.createElement("g",{style:Ve},kt,r.createElement("rect",{width:"24",height:"24",fill:"transparent"}))));var Se,de=Dt,xe=Jt===!0||typeof Jt!="number"?2:Jt,Pe=!Je&&(ct||He);if(xe<0&&(Pe=!Pe),Jt&&(de=r.createElement("g",{style:{animation:"spin"+(Pe?"-inverse":"")+" linear "+Math.abs(xe)+"s infinite",transformOrigin:"center"}},Dt,!(ct||He||jt!==0)&&r.createElement("rect",{width:"24",height:"24",fill:"transparent"}))),Je)return de;var Ze,Xe="icon_labelledby_"+q,wt="icon_describedby_"+q;if(ne)Se=ae?Xe+" "+wt:Xe;else if(Ze="presentation",ae)throw new Error("title attribute required when description is set");return r.createElement("svg",x({ref:H,viewBox:"0 0 24 24",style:Ve,role:Ze,"aria-labelledby":Se},Vt),ne&&r.createElement("title",{id:Xe},ne),ae&&r.createElement("desc",{id:wt},ae),!Je&&Jt&&(Pe?r.createElement("style",null,"@keyframes spin-inverse { from { transform: rotate(0deg) } to { transform: rotate(-360deg) } }"):r.createElement("style",null,"@keyframes spin { from { transform: rotate(0deg) } to { transform: rotate(360deg) } }")),de)});P.displayName="Icon",P.propTypes={path:i.string.isRequired,size:i.oneOfType([i.number,i.string]),color:i.string,horizontal:i.bool,vertical:i.bool,rotate:i.number,spin:i.oneOfType([i.bool,i.number]),style:i.object,inStack:i.bool,className:i.string},P.defaultProps={size:null,color:"currentColor",horizontal:!1,vertical:!1,rotate:0,spin:!1},n.default=P}]);const pP=ga(_6e);function Ng(){var e="/home/runner/work/maputnik/maputnik/src/components/LayerEditorGroup.tsx",n="2f1dde9b3c8e927b8e8868bcb310eb3d6a65eb08",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/LayerEditorGroup.tsx",statementMap:{0:{start:{line:16,column:4},end:{line:45,column:9}},1:{start:{line:22,column:27},end:{line:22,column:74}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:15,column:2},end:{line:15,column:3}},loc:{start:{line:15,column:11},end:{line:46,column:3}},line:15},1:{name:"(anonymous_1)",decl:{start:{line:22,column:19},end:{line:22,column:20}},loc:{start:{line:22,column:27},end:{line:22,column:74}},line:22}},branchMap:{},s:{0:0,1:0},f:{0:0,1:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/LayerEditorGroup.tsx"],names:[],mappings:"AA+BQ,SACE,KADF;AA/BR,OAAO,WAAW;AAClB,OAAO,UAAU;AACjB;AAAA,EACE;AAAA,EACA;AAAA,OACK;AACP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAaP,qBAAqB,yBAAyB,MAAM,UAAiC;AAAA,EACnF,SAAS;AACP,WAAO,qBAAC,iBAAc,MAAM,KAAK,MAAM,IACrC;AAAA;AAAA,QAAC;AAAA;AAAA,UAAqB,WAAU;AAAA,UAC9B,eAAa,wBAAsB,KAAK,MAAM,aAAa;AAAA,UAC3D,SAAS,QAAM,KAAK,MAAM,eAAe,CAAC,KAAK,MAAM,QAAQ;AAAA,UAE7D,+BAAC,uBAAoB,WAAU,uCAC7B;AAAA,gCAAC,UAAK,OAAO,EAAC,UAAU,EAAC,GAAI,eAAK,MAAM,OAAM;AAAA,YAC9C;AAAA,cAAC;AAAA;AAAA,gBACC,MAAM;AAAA,gBACN,MAAM;AAAA,gBACN,WAAU;AAAA;AAAA,YACZ;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,MAAM;AAAA,gBACN,MAAM;AAAA,gBACN,WAAU;AAAA;AAAA,YACZ;AAAA,aACF;AAAA;AAAA,MACF;AAAA,MACA,oBAAC,sBACE,eAAK,MAAM,UACd;AAAA,OACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"2f1dde9b3c8e927b8e8868bcb310eb3d6a65eb08"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Ng=function(){return s},s}Ng();class b6e extends bn.Component{render(){return Ng().f[0]++,Ng().s[0]++,N.jsxs(gW,{uuid:this.props.id,children:[N.jsx(CW,{className:"maputnik-layer-editor-group","data-wd-key":"layer-editor-group:"+this.props["data-wd-key"],onClick:n=>(Ng().f[1]++,Ng().s[1]++,this.props.onActiveToggle(!this.props.isActive)),children:N.jsxs(Zfe,{className:"maputnik-layer-editor-group__button",children:[N.jsx("span",{style:{flexGrow:1},children:this.props.title}),N.jsx(pP,{path:lpe,size:1,className:"maputnik-layer-editor-group__button__icon maputnik-layer-editor-group__button__icon--up"}),N.jsx(pP,{path:spe,size:1,className:"maputnik-layer-editor-group__button__icon maputnik-layer-editor-group__button__icon--down"})]})}),N.jsx(epe,{children:this.props.children})]})}}function A4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldMinZoom.tsx",n="1854bc9345eba3b5ee508193a6378533df537e7e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldMinZoom.tsx",statementMap:{0:{start:{line:8,column:4},end:{line:28,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:2},end:{line:7,column:3}},loc:{start:{line:7,column:11},end:{line:29,column:3}},line:7}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldMinZoom.tsx"],names:[],mappings:"AAkBM;AAlBN,OAAO,WAAW;AAElB,OAAO,YAAY;AACnB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AAQxB,qBAAqB,qBAAqB,MAAM,UAA6B;AAAA,EAC3E,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QAAM,OAAO;AAAA,QAAY,WAAW,OAAO,MAAM;AAAA,QACvD,OAAO,KAAK,MAAM;AAAA,QAClB,eAAY;AAAA,QAEZ;AAAA,UAAC;AAAA;AAAA,YACC,YAAY;AAAA,YACZ,OAAO,KAAK,MAAM;AAAA,YAClB,UAAU,KAAK,MAAM;AAAA,YACrB,KAAK,OAAO,MAAM,QAAQ;AAAA,YAC1B,KAAK,OAAO,MAAM,QAAQ;AAAA,YAC1B,SAAS,OAAO,MAAM,QAAQ;AAAA,YAC9B,eAAY;AAAA;AAAA,QACd;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"1854bc9345eba3b5ee508193a6378533df537e7e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return A4=function(){return s},s}A4();class x6e extends bn.Component{render(){return A4().f[0]++,A4().s[0]++,N.jsx(Uo,{label:"Min Zoom",fieldSpec:Ji.layer.minzoom,error:this.props.error,"data-wd-key":"min-zoom",children:N.jsx(pf,{allowRange:!0,value:this.props.value,onChange:this.props.onChange,min:Ji.layer.minzoom.minimum,max:Ji.layer.minzoom.maximum,default:Ji.layer.minzoom.minimum,"data-wd-key":"min-zoom.input"})})}}function c4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldMaxZoom.tsx",n="8fe5d5ad6dca587b5c71f117ffe8eb6be8e87fd7",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldMaxZoom.tsx",statementMap:{0:{start:{line:8,column:4},end:{line:28,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:2},end:{line:7,column:3}},loc:{start:{line:7,column:11},end:{line:29,column:3}},line:7}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldMaxZoom.tsx"],names:[],mappings:"AAkBM;AAlBN,OAAO,WAAW;AAElB,OAAO,YAAY;AACnB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AAQxB,qBAAqB,qBAAqB,MAAM,UAA6B;AAAA,EAC3E,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QAAM,OAAO;AAAA,QAAY,WAAW,OAAO,MAAM;AAAA,QACvD,OAAO,KAAK,MAAM;AAAA,QAClB,eAAY;AAAA,QAEZ;AAAA,UAAC;AAAA;AAAA,YACC,YAAY;AAAA,YACZ,OAAO,KAAK,MAAM;AAAA,YAClB,UAAU,KAAK,MAAM;AAAA,YACrB,KAAK,OAAO,MAAM,QAAQ;AAAA,YAC1B,KAAK,OAAO,MAAM,QAAQ;AAAA,YAC1B,SAAS,OAAO,MAAM,QAAQ;AAAA,YAC9B,eAAY;AAAA;AAAA,QACd;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"8fe5d5ad6dca587b5c71f117ffe8eb6be8e87fd7"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return c4=function(){return s},s}c4();class w6e extends bn.Component{render(){return c4().f[0]++,c4().s[0]++,N.jsx(Uo,{label:"Max Zoom",fieldSpec:Ji.layer.maxzoom,error:this.props.error,"data-wd-key":"max-zoom",children:N.jsx(pf,{allowRange:!0,value:this.props.value,onChange:this.props.onChange,min:Ji.layer.maxzoom.minimum,max:Ji.layer.maxzoom.maximum,default:Ji.layer.maxzoom.maximum,"data-wd-key":"max-zoom.input"})})}}function LC(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldComment.tsx",n="78f2f7c5d70fb12fc1126c8cf454a217776b6a18",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldComment.tsx",statementMap:{0:{start:{line:7,column:22},end:{line:9,column:5}},1:{start:{line:10,column:4},end:{line:28,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:29,column:3}},line:6}},branchMap:{},s:{0:0,1:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldComment.tsx"],names:[],mappings:"AAuBM;AAvBN,OAAO,WAAW;AAElB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AAQxB,qBAAqB,qBAAqB,MAAM,UAA6B;AAAA,EAC3E,SAAS;AACP,UAAM,YAAY;AAAA,MAChB,KAAK;AAAA,IACP;AAEA,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,OAAO;AAAA,QACP;AAAA,QACA,eAAY;AAAA,QACZ,OAAO,KAAK,MAAM;AAAA,QAElB;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,OAAO,KAAK,MAAM;AAAA,YAClB,UAAU,KAAK,MAAM;AAAA,YACrB,SAAQ;AAAA,YACR,eAAY;AAAA;AAAA,QACd;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"78f2f7c5d70fb12fc1126c8cf454a217776b6a18"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return LC=function(){return s},s}LC();class M6e extends bn.Component{render(){LC().f[0]++;const n=(LC().s[0]++,{doc:"Comments for the current layer. This is non-standard and not in the spec."});return LC().s[1]++,N.jsx(Uo,{label:"Comments",fieldSpec:n,"data-wd-key":"layer-comment",error:this.props.error,children:N.jsx(Sd,{multi:!0,value:this.props.value,onChange:this.props.onChange,default:"Comment...","data-wd-key":"layer-comment.input"})})}}const S6e={groups:[{title:"Paint properties",type:"properties",fields:["line-opacity","line-color","line-width","line-offset","line-blur","line-dasharray","line-pattern","line-translate","line-translate-anchor","line-gap-width"]},{title:"Layout properties",type:"properties",fields:["line-cap","line-join","line-miter-limit","line-round-limit"]}]},E6e={groups:[{title:"Paint properties",type:"properties",fields:["background-color","background-pattern","background-opacity"]}]},O6e={groups:[{title:"Paint properties",type:"properties",fields:["fill-opacity","fill-color","fill-antialias","fill-outline-color","fill-pattern","fill-translate","fill-translate-anchor"]}]},B6e={groups:[{title:"Paint properties",type:"properties",fields:["circle-color","circle-opacity","circle-stroke-color","circle-stroke-opacity","circle-blur","circle-radius","circle-stroke-width","circle-pitch-scale","circle-translate","circle-translate-anchor","circle-pitch-alignment"]}]},k6e={groups:[{title:"General layout properties",type:"properties",fields:["symbol-placement","symbol-spacing","symbol-avoid-edges","symbol-z-order"]},{title:"Text layout properties",type:"properties",fields:["text-field","text-font","text-size","text-line-height","text-padding","text-allow-overlap","text-ignore-placement","text-pitch-alignment","text-rotation-alignment","text-max-width","text-letter-spacing","text-justify","text-anchor","text-max-angle","text-writing-mode","text-rotate","text-keep-upright","text-transform","text-offset","text-optional","text-variable-anchor","text-radial-offset"]},{title:"Icon layout properties",type:"properties",fields:["icon-image","icon-allow-overlap","icon-ignore-placement","icon-optional","icon-rotation-alignment","icon-size","icon-text-fit","icon-text-fit-padding","icon-rotate","icon-padding","icon-keep-upright","icon-offset","icon-anchor","icon-pitch-alignment"]},{title:"Text paint properties",type:"properties",fields:["text-color","text-opacity","text-halo-color","text-halo-width","text-halo-blur","text-translate","text-translate-anchor"]},{title:"Icon paint properties",type:"properties",fields:["icon-color","icon-opacity","icon-halo-color","icon-halo-width","icon-halo-blur","icon-translate","icon-translate-anchor"]}]},I6e={groups:[{title:"Paint properties",type:"properties",fields:["raster-opacity","raster-hue-rotate","raster-brightness-min","raster-brightness-max","raster-saturation","raster-contrast","raster-fade-duration","raster-resampling"]}]},T6e={groups:[{title:"Paint properties",type:"properties",fields:["hillshade-illumination-direction","hillshade-illumination-anchor","hillshade-exaggeration","hillshade-shadow-color","hillshade-highlight-color","hillshade-accent-color"]}]},K6e={groups:[{title:"Paint properties",type:"properties",fields:["heatmap-radius","heatmap-weight","heatmap-intensity","heatmap-opacity"]}]},P6e={groups:[]},oS={line:S6e,background:E6e,fill:O6e,"fill-extrusion":{groups:[{title:"Paint properties",type:"properties",fields:["fill-extrusion-opacity","fill-extrusion-color","fill-extrusion-translate","fill-extrusion-translate-anchor","fill-extrusion-pattern","fill-extrusion-height","fill-extrusion-base","fill-extrusion-vertical-gradient"]}]},circle:B6e,symbol:k6e,raster:I6e,hillshade:T6e,heatmap:K6e,invalid:P6e};function Gg(){var e="/home/runner/work/maputnik/maputnik/src/libs/format.ts",n="c45fbfac66e994b59070a295e5a7f219cd5d66ac",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/format.ts",statementMap:{0:{start:{line:2,column:2},end:{line:2,column:50}}},fnMap:{0:{name:"formatLayerId",decl:{start:{line:1,column:16},end:{line:1,column:29}},loc:{start:{line:1,column:34},end:{line:3,column:1}},line:1}},branchMap:{0:{loc:{start:{line:2,column:9},end:{line:2,column:49}},type:"cond-expr",locations:[{start:{line:2,column:21},end:{line:2,column:37}},{start:{line:2,column:40},end:{line:2,column:49}}],line:2}},s:{0:0},f:{0:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/format.ts"],names:[],mappings:"AAAO,gBAAS,cAAe,IAAwB;AACrD,SAAO,OAAO,KAAK,mBAAmB,IAAI,EAAE;AAC9C;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c45fbfac66e994b59070a295e5a7f219cd5d66ac"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Gg=function(){return s},s}Gg();function XN(e){return Gg().f[0]++,Gg().s[0]++,e===""?(Gg().b[0][0]++,"[empty_string]"):(Gg().b[0][1]++,`'${e}'`)}function ln(){var e="/home/runner/work/maputnik/maputnik/src/components/LayerEditor.tsx",n="13cf530347fd66324a92f0d1d210d94f3d2129c4",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/LayerEditor.tsx",statementMap:{0:{start:{line:22,column:2},end:{line:22,column:54}},1:{start:{line:25,column:21},end:{line:28,column:3}},2:{start:{line:29,column:22},end:{line:32,column:3}},3:{start:{line:33,column:22},end:{line:36,column:3}},4:{start:{line:37,column:2},end:{line:37,column:100}},5:{start:{line:40,column:24},end:{line:47,column:3}},6:{start:{line:48,column:29},end:{line:50,column:3}},7:{start:{line:52,column:4},end:{line:52,column:17}},8:{start:{line:53,column:25},end:{line:53,column:27}},9:{start:{line:54,column:4},end:{line:56,column:7}},10:{start:{line:55,column:6},end:{line:55,column:39}},11:{start:{line:57,column:4},end:{line:57,column:34}},12:{start:{line:60,column:29},end:{line:60,column:54}},13:{start:{line:61,column:4},end:{line:65,column:7}},14:{start:{line:62,column:6},end:{line:64,column:7}},15:{start:{line:63,column:8},end:{line:63,column:45}},16:{start:{line:66,column:4},end:{line:68,column:6}},17:{start:{line:71,column:4},end:{line:76,column:6}},18:{start:{line:79,column:4},end:{line:82,column:6}},19:{start:{line:85,column:32},end:{line:88,column:5}},20:{start:{line:89,column:4},end:{line:91,column:7}},21:{start:{line:94,column:18},end:{line:94,column:20}},22:{start:{line:95,column:4},end:{line:97,column:5}},23:{start:{line:96,column:6},end:{line:96,column:62}},24:{start:{line:98,column:35},end:{line:98,column:45}},25:{start:{line:99,column:22},end:{line:99,column:24}},26:{start:{line:100,column:4},end:{line:106,column:7}},27:{start:{line:101,column:6},end:{line:105,column:7}},28:{start:{line:102,column:8},end:{line:104,column:10}},29:{start:{line:108,column:18},end:{line:108,column:34}},30:{start:{line:109,column:4},end:{line:111,column:5}},31:{start:{line:110,column:6},end:{line:110,column:63}},32:{start:{line:112,column:4},end:{line:215,column:5}},33:{start:{line:114,column:8},end:{line:178,column:13}},34:{start:{line:121,column:35},end:{line:121,column:112}},35:{start:{line:130,column:37},end:{line:133,column:15}},36:{start:{line:142,column:31},end:{line:142,column:69}},37:{start:{line:151,column:31},end:{line:151,column:75}},38:{start:{line:159,column:31},end:{line:159,column:70}},39:{start:{line:167,column:31},end:{line:167,column:70}},40:{start:{line:175,column:31},end:{line:175,column:104}},41:{start:{line:180,column:8},end:{line:188,column:16}},42:{start:{line:186,column:29},end:{line:186,column:67}},43:{start:{line:190,column:8},end:{line:199,column:10}},44:{start:{line:201,column:8},end:{line:212,column:10}},45:{start:{line:206,column:14},end:{line:209,column:16}},46:{start:{line:214,column:8},end:{line:214,column:49}},47:{start:{line:218,column:4},end:{line:221,column:7}},48:{start:{line:224,column:21},end:{line:224,column:23}},49:{start:{line:225,column:22},end:{line:225,column:43}},50:{start:{line:226,column:19},end:{line:243,column:6}},51:{start:{line:227,column:6},end:{line:227,column:70}},52:{start:{line:229,column:22},end:{line:229,column:52}},53:{start:{line:230,column:6},end:{line:230,column:29}},54:{start:{line:231,column:6},end:{line:242,column:8}},55:{start:{line:244,column:20},end:{line:244,column:49}},56:{start:{line:245,column:18},end:{line:270,column:5}},57:{start:{line:248,column:23},end:{line:248,column:71}},58:{start:{line:252,column:23},end:{line:252,column:68}},59:{start:{line:256,column:23},end:{line:256,column:80}},60:{start:{line:262,column:23},end:{line:262,column:41}},61:{start:{line:268,column:23},end:{line:268,column:40}},62:{start:{line:272,column:6},end:{line:272,column:30}},63:{start:{line:273,column:6},end:{line:273,column:26}},64:{start:{line:275,column:4},end:{line:314,column:6}},65:{start:{line:296,column:33},end:{line:296,column:42}},66:{start:{line:297,column:20},end:{line:297,column:174}}},fnMap:{0:{name:"getLayoutForType",decl:{start:{line:21,column:9},end:{line:21,column:25}},loc:{start:{line:21,column:32},end:{line:23,column:1}},line:21},1:{name:"layoutGroups",decl:{start:{line:24,column:9},end:{line:24,column:21}},loc:{start:{line:24,column:33},end:{line:38,column:1}},line:24},2:{name:"(anonymous_2)",decl:{start:{line:41,column:20},end:{line:41,column:21}},loc:{start:{line:41,column:26},end:{line:42,column:5}},line:41},3:{name:"(anonymous_3)",decl:{start:{line:43,column:21},end:{line:43,column:22}},loc:{start:{line:43,column:27},end:{line:44,column:5}},line:43},4:{name:"(anonymous_4)",decl:{start:{line:45,column:22},end:{line:45,column:23}},loc:{start:{line:45,column:28},end:{line:46,column:5}},line:45},5:{name:"(anonymous_5)",decl:{start:{line:51,column:2},end:{line:51,column:3}},loc:{start:{line:51,column:21},end:{line:58,column:3}},line:51},6:{name:"(anonymous_6)",decl:{start:{line:54,column:48},end:{line:54,column:49}},loc:{start:{line:54,column:59},end:{line:56,column:5}},line:54},7:{name:"(anonymous_7)",decl:{start:{line:59,column:2},end:{line:59,column:3}},loc:{start:{line:59,column:48},end:{line:69,column:3}},line:59},8:{name:"(anonymous_8)",decl:{start:{line:61,column:54},end:{line:61,column:55}},loc:{start:{line:61,column:65},end:{line:65,column:5}},line:61},9:{name:"(anonymous_9)",decl:{start:{line:70,column:2},end:{line:70,column:3}},loc:{start:{line:70,column:20},end:{line:77,column:3}},line:70},10:{name:"(anonymous_10)",decl:{start:{line:78,column:2},end:{line:78,column:3}},loc:{start:{line:78,column:44},end:{line:83,column:3}},line:78},11:{name:"(anonymous_11)",decl:{start:{line:84,column:2},end:{line:84,column:3}},loc:{start:{line:84,column:36},end:{line:92,column:3}},line:84},12:{name:"(anonymous_12)",decl:{start:{line:93,column:2},end:{line:93,column:3}},loc:{start:{line:93,column:32},end:{line:216,column:3}},line:93},13:{name:"(anonymous_13)",decl:{start:{line:100,column:19},end:{line:100,column:20}},loc:{start:{line:100,column:30},end:{line:106,column:5}},line:100},14:{name:"(anonymous_14)",decl:{start:{line:121,column:24},end:{line:121,column:25}},loc:{start:{line:121,column:35},end:{line:121,column:112}},line:121},15:{name:"(anonymous_15)",decl:{start:{line:130,column:24},end:{line:130,column:25}},loc:{start:{line:130,column:37},end:{line:133,column:15}},line:130},16:{name:"(anonymous_16)",decl:{start:{line:142,column:24},end:{line:142,column:25}},loc:{start:{line:142,column:31},end:{line:142,column:69}},line:142},17:{name:"(anonymous_17)",decl:{start:{line:151,column:24},end:{line:151,column:25}},loc:{start:{line:151,column:31},end:{line:151,column:75}},line:151},18:{name:"(anonymous_18)",decl:{start:{line:159,column:24},end:{line:159,column:25}},loc:{start:{line:159,column:31},end:{line:159,column:70}},line:159},19:{name:"(anonymous_19)",decl:{start:{line:167,column:24},end:{line:167,column:25}},loc:{start:{line:167,column:31},end:{line:167,column:70}},line:167},20:{name:"(anonymous_20)",decl:{start:{line:175,column:24},end:{line:175,column:25}},loc:{start:{line:175,column:31},end:{line:175,column:104}},line:175},21:{name:"(anonymous_21)",decl:{start:{line:186,column:22},end:{line:186,column:23}},loc:{start:{line:186,column:29},end:{line:186,column:67}},line:186},22:{name:"(anonymous_22)",decl:{start:{line:205,column:22},end:{line:205,column:23}},loc:{start:{line:205,column:34},end:{line:210,column:13}},line:205},23:{name:"(anonymous_23)",decl:{start:{line:217,column:2},end:{line:217,column:3}},loc:{start:{line:217,column:20},end:{line:222,column:3}},line:217},24:{name:"(anonymous_24)",decl:{start:{line:223,column:2},end:{line:223,column:3}},loc:{start:{line:223,column:11},end:{line:315,column:3}},line:223},25:{name:"(anonymous_25)",decl:{start:{line:226,column:50},end:{line:226,column:51}},loc:{start:{line:226,column:61},end:{line:228,column:5}},line:226},26:{name:"(anonymous_26)",decl:{start:{line:228,column:11},end:{line:228,column:12}},loc:{start:{line:228,column:22},end:{line:243,column:5}},line:228},27:{name:"(anonymous_27)",decl:{start:{line:248,column:17},end:{line:248,column:18}},loc:{start:{line:248,column:23},end:{line:248,column:71}},line:248},28:{name:"(anonymous_28)",decl:{start:{line:252,column:17},end:{line:252,column:18}},loc:{start:{line:252,column:23},end:{line:252,column:68}},line:252},29:{name:"(anonymous_29)",decl:{start:{line:256,column:17},end:{line:256,column:18}},loc:{start:{line:256,column:23},end:{line:256,column:80}},line:256},30:{name:"(anonymous_30)",decl:{start:{line:262,column:17},end:{line:262,column:18}},loc:{start:{line:262,column:23},end:{line:262,column:41}},line:262},31:{name:"(anonymous_31)",decl:{start:{line:268,column:17},end:{line:268,column:18}},loc:{start:{line:268,column:23},end:{line:268,column:40}},line:268},32:{name:"handleSelection",decl:{start:{line:271,column:13},end:{line:271,column:28}},loc:{start:{line:271,column:40},end:{line:274,column:5}},line:271},33:{name:"(anonymous_33)",decl:{start:{line:295,column:147},end:{line:295,column:148}},loc:{start:{line:295,column:155},end:{line:298,column:19}},line:295}},branchMap:{0:{loc:{start:{line:22,column:9},end:{line:22,column:53}},type:"cond-expr",locations:[{start:{line:22,column:24},end:{line:22,column:36}},{start:{line:22,column:39},end:{line:22,column:53}}],line:22},1:{loc:{start:{line:62,column:6},end:{line:64,column:7}},type:"if",locations:[{start:{line:62,column:6},end:{line:64,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:62},2:{loc:{start:{line:95,column:4},end:{line:97,column:5}},type:"if",locations:[{start:{line:95,column:4},end:{line:97,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:95},3:{loc:{start:{line:101,column:6},end:{line:105,column:7}},type:"if",locations:[{start:{line:101,column:6},end:{line:105,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:101},4:{loc:{start:{line:101,column:10},end:{line:101,column:96}},type:"binary-expr",locations:[{start:{line:101,column:10},end:{line:101,column:22}},{start:{line:101,column:26},end:{line:101,column:55}},{start:{line:101,column:59},end:{line:101,column:96}}],line:101},5:{loc:{start:{line:109,column:4},end:{line:111,column:5}},type:"if",locations:[{start:{line:109,column:4},end:{line:111,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:109},6:{loc:{start:{line:112,column:4},end:{line:215,column:5}},type:"switch",locations:[{start:{line:113,column:6},end:{line:178,column:13}},{start:{line:179,column:6},end:{line:188,column:16}},{start:{line:189,column:6},end:{line:199,column:10}},{start:{line:200,column:6},end:{line:212,column:10}},{start:{line:213,column:6},end:{line:214,column:49}}],line:112},7:{loc:{start:{line:136,column:10},end:{line:144,column:11}},type:"binary-expr",locations:[{start:{line:136,column:10},end:{line:136,column:48}},{start:{line:136,column:68},end:{line:144,column:11}}],line:136},8:{loc:{start:{line:145,column:10},end:{line:153,column:11}},type:"binary-expr",locations:[{start:{line:145,column:10},end:{line:145,column:93}},{start:{line:145,column:113},end:{line:153,column:11}}],line:145},9:{loc:{start:{line:175,column:83},end:{line:175,column:103}},type:"cond-expr",locations:[{start:{line:175,column:93},end:{line:175,column:99}},{start:{line:175,column:102},end:{line:175,column:103}}],line:175},10:{loc:{start:{line:227,column:15},end:{line:227,column:68}},type:"binary-expr",locations:[{start:{line:227,column:15},end:{line:227,column:41}},{start:{line:227,column:45},end:{line:227,column:68}}],line:227},11:{loc:{start:{line:244,column:20},end:{line:244,column:49}},type:"binary-expr",locations:[{start:{line:244,column:20},end:{line:244,column:43}},{start:{line:244,column:47},end:{line:244,column:49}}],line:244},12:{loc:{start:{line:255,column:14},end:{line:255,column:61}},type:"cond-expr",locations:[{start:{line:255,column:46},end:{line:255,column:52}},{start:{line:255,column:55},end:{line:255,column:61}}],line:255}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0,0],5:[0,0],6:[0,0,0,0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/LayerEditor.tsx"],names:["layer","layout"],mappings:"AA6JyB,SA2EL,UA1Ed,KADmB;AA7JzB,OAAO,WAAuB;AAC9B,OAAO,eAAe;AACtB,SAAS,SAAS,QAAQ,MAAM,gBAAgB;AAChD,SAAQ,iBAAgB;AACxB,SAAQ,kBAAiB;AAGzB,OAAO,eAAe;AACtB,OAAO,kBAAkB;AACzB,OAAO,mBAAmB;AAC1B,OAAO,sBAAsB;AAC7B,OAAO,eAAe;AACtB,OAAO,aAAa;AACpB,OAAO,kBAAkB;AACzB,OAAO,kBAAkB;AACzB,OAAO,kBAAkB;AACzB,OAAO,iBAAiB;AACxB,OAAO,sBAAsB;AAC7B,SAAS,YAAY,sBAAsB;AAC3C,OAAO,YAAY;AACnB,SAAQ,qBAAoB;AAG5B,SAAS,iBAAiB,MAAkC;AAC1D,SAAO,OAAO,IAAI,IAAI,OAAO,IAAI,IAAI,OAAO;AAC9C;AAEA,SAAS,aAAa,WAA2F;AAC/G,QAAM,aAAa;AAAA,IACjB,OAAO;AAAA,IACP,MAAM;AAAA,EACR;AACA,QAAM,cAAc;AAAA,IAClB,OAAO;AAAA,IACP,MAAM;AAAA,EACR;AACA,QAAM,cAAc;AAAA,IAClB,OAAO;AAAA,IACP,MAAM;AAAA,EACR;AACA,SAAO,CAAC,YAAY,WAAW,EAC5B,OAAO,iBAAiB,SAAS,EAAE,MAAM,EACzC,OAAO,CAAC,WAAW,CAAC;AACzB;AAwBA,qBAAqB,oBAAoB,MAAM,UAA8C;AAAA,EAC3F,OAAO,eAAe;AAAA,IACpB,gBAAgB,MAAM;AAAA,IAAC;AAAA,IACvB,iBAAiB,MAAM;AAAA,IAAC;AAAA,IACxB,kBAAkB,MAAM;AAAA,IAAC;AAAA,EAC3B;AAAA,EAEA,OAAO,oBAAoB;AAAA,IACzB,eAAe,UAAU;AAAA,EAC3B;AAAA,EAEA,YAAY,OAAyB;AACnC,UAAM,KAAK;AAGX,UAAM,eAAyC,CAAC;AAChD,iBAAa,KAAK,MAAM,MAAM,IAAI,EAAE,QAAQ,WAAS;AACnD,mBAAa,MAAM,KAAK,IAAI;AAAA,IAC9B,CAAC;AAED,SAAK,QAAQ,EAAE,aAAa;AAAA,EAC9B;AAAA,EAEA,OAAO,yBAAyB,OAAyB,OAAyB;AAChF,UAAM,mBAAmB,EAAE,GAAG,MAAM,aAAa;AAEjD,qBAAiB,MAAM,MAAM,IAAI,EAAE,OAAO,QAAQ,WAAS;AACzD,UAAG,EAAE,MAAM,SAAS,mBAAmB;AACrC,yBAAiB,MAAM,KAAK,IAAI;AAAA,MAClC;AAAA,IACF,CAAC;AAED,WAAO;AAAA,MACL,cAAc;AAAA,IAChB;AAAA,EACF;AAAA,EAEA,kBAAmB;AACjB,WAAO;AAAA,MACL,eAAe;AAAA,QACb,MAAM;AAAA,QACN,OAAO;AAAA,MACT;AAAA,IACF;AAAA,EACF;AAAA,EAEA,eAAe,OAAwC,UAAkB,UAAe;AACtF,SAAK,MAAM;AAAA,MACT,KAAK,MAAM;AAAA,MACX,eAAe,KAAK,MAAM,OAAO,OAAO,UAAU,QAAQ;AAAA,IAC5D;AAAA,EACF;AAAA,EAEA,cAAc,YAAoB,QAAiB;AACjD,UAAM,sBAAsB;AAAA,MAC1B,GAAG,KAAK,MAAM;AAAA,MACd,CAAC,UAAU,GAAG;AAAA,IAChB;AACA,SAAK,SAAS;AAAA,MACZ,cAAc;AAAA,IAChB,CAAC;AAAA,EACH;AAAA,EAEA,gBAAgB,MAAc,QAAgC;AAC5D,QAAI,UAAU;AACd,QAAG,KAAK,MAAM,MAAM,UAAU;AAC5B,gBAAW,KAAK,MAAM,MAAM,SAAiB,kBAAkB;AAAA,IACjE;AACA,UAAM,EAAC,QAAQ,WAAU,IAAI,KAAK;AAElC,UAAM,YAAwE,CAAC;AAC/E,WAAQ,QAAQ,WAAS;AACvB,UACE,MAAM,UACN,MAAM,OAAO,SAAS,WACtB,MAAM,OAAO,KAAK,SAAS,YAC3B;AACA,kBAAU,MAAM,OAAO,KAAK,GAAG,IAAI;AAAA,UACjC,SAAS,MAAM,OAAO,KAAK;AAAA,QAC7B;AAAA,MACF;AAAA,IACF,CAAC;AAED,QAAI;AACJ,UAAM,QAAQ,KAAK,MAAM;AACzB,QAAG,OAAO,UAAU,eAAe,KAAK,KAAK,MAAM,SAAS,MAAM,MAAM,GAAG;AACzE,uBAAkB,KAAK,MAAM,QAAQ,MAAM,MAAM,EAAU;AAAA,IAC7D;AAEA,YAAO,MAAM;AAAA,MACb,KAAK;AAAS,eAAO,qBAAC,SACpB;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,KAAK,MAAM,MAAM;AAAA,cACxB,OAAM;AAAA,cACN,OAAO,UAAU;AAAA,cACjB,UAAU,WAAS,KAAK,MAAM,gBAAgB,KAAK,MAAM,YAAY,KAAK,MAAM,MAAM,IAAI,KAAK;AAAA;AAAA,UACjG;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,UAAU;AAAA,cACV,OAAO,UAAU;AAAA,cACjB,OAAO,KAAK,MAAM,MAAM;AAAA,cACxB,UAAU,aAAW,KAAK,MAAM;AAAA,gBAC9B,KAAK,MAAM;AAAA,gBACX,WAAW,KAAK,MAAM,OAAO,OAAO;AAAA,cACtC;AAAA;AAAA,UACF;AAAA,UACC,KAAK,MAAM,MAAM,SAAS,gBAAgB;AAAA,YAAC;AAAA;AAAA,cAC1C,OAAO,UAAU;AAAA,cACjB,WAAW,OAAO,KAAK,KAAK,MAAM,OAAQ;AAAA,cAC1C,OAAO,KAAK,MAAM,MAAM;AAAA,cACxB,UAAU,OAAK,KAAK,eAAe,MAAM,UAAU,CAAC;AAAA;AAAA,UACtD;AAAA,UAEC,CAAC,cAAc,UAAU,aAAa,SAAS,EAAE,QAAQ,KAAK,MAAM,MAAM,IAAI,IAAI,KACjF;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,UAAU,cAAc;AAAA,cAC/B;AAAA,cACA,OAAQ,KAAK,MAAM,MAAc,cAAc;AAAA,cAC/C,UAAU,OAAK,KAAK,eAAe,MAAM,gBAAgB,CAAC;AAAA;AAAA,UAC5D;AAAA,UAEF;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,UAAU;AAAA,cACjB,OAAO,KAAK,MAAM,MAAM;AAAA,cACxB,UAAU,OAAK,KAAK,eAAe,MAAM,WAAW,CAAC;AAAA;AAAA,UACvD;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,UAAU;AAAA,cACjB,OAAO,KAAK,MAAM,MAAM;AAAA,cACxB,UAAU,OAAK,KAAK,eAAe,MAAM,WAAW,CAAC;AAAA;AAAA,UACvD;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,UAAU;AAAA,cACjB,OAAO;AAAA,cACP,UAAU,OAAK,KAAK,eAAe,YAAY,oBAAoB,KAAK,KAAM,SAAY,CAAC;AAAA;AAAA,UAC7F;AAAA,WACF;AAAA,MACA,KAAK;AAAU,eAAO,oBAAC,SACrB,8BAAC,SAAI,WAAU,kCACb;AAAA,UAAC;AAAA;AAAA,YACC,QAAQ;AAAA,YACR,QAAS,KAAK,MAAM,MAAc;AAAA,YAClC,YAAY,KAAK,MAAM,aAAc,KAAK,MAAM,MAAc,cAAc,CAAC;AAAA,YAC7E,UAAU,OAAK,KAAK,eAAe,MAAM,UAAU,CAAC;AAAA;AAAA,QACtD,GACF,GACF;AAAA,MACA,KAAK;AACH,eAAO;AAAA,UAAC;AAAA;AAAA,YACN,QAAQ;AAAA,YACR,OAAO,KAAK,MAAM;AAAA,YAClB,aAAa;AAAA,YACb,MAAM,KAAK,MAAM;AAAA,YACjB,UAAU,KAAK,eAAe,KAAK,IAAI;AAAA;AAAA,QACzC;AAAA,MACF,KAAK;AACH,eAAO;AAAA,UAAC;AAAA;AAAA,YACN,OAAO,KAAK,MAAM;AAAA,YAClB,UAAU,CAACA,WAAU;AACnB,mBAAK,MAAM;AAAA,gBACT,KAAK,MAAM;AAAA,gBACXA;AAAA,cACF;AAAA,YACF;AAAA;AAAA,QACF;AAAA,MACF;AAAS,eAAO,gCAAE;AAAA,IAClB;AAAA,EACF;AAAA,EAEA,UAAU,QAAgB;AACxB,SAAK,MAAM,YAAY;AAAA,MACrB,UAAU,KAAK,MAAM;AAAA,MACrB,UAAU,KAAK,MAAM,aAAW;AAAA,IAClC,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,WAAqB,CAAC;AAC5B,UAAM,YAAY,KAAK,MAAM,MAAM;AACnC,UAAM,SAAS,aAAa,SAAS,EAAE,OAAO,WAAS;AACrD,aAAO,EAAE,cAAc,gBAAgB,MAAM,SAAS;AAAA,IACxD,CAAC,EAAE,IAAI,WAAS;AACd,YAAM,UAAU,MAAM,MAAM,QAAQ,MAAM,GAAG;AAC7C,eAAS,KAAK,OAAO;AACrB,aAAO;AAAA,QAAC;AAAA;AAAA,UACN,eAAa,MAAM;AAAA,UACnB,IAAI;AAAA,UAEJ,OAAO,MAAM;AAAA,UACb,UAAU,KAAK,MAAM,aAAa,MAAM,KAAK;AAAA,UAC7C,gBAAgB,KAAK,cAAc,KAAK,MAAM,MAAM,KAAK;AAAA,UAExD,eAAK,gBAAgB,MAAM,MAAM,MAAM,MAAM;AAAA;AAAA,QALzC,MAAM;AAAA,MAMb;AAAA,IACF,CAAC;AAED,UAAMC,UAAS,KAAK,MAAM,MAAM,UAAU,CAAC;AAE3C,UAAM,QAAkF;AAAA,MACtF,QAAQ;AAAA,QACN,MAAM;AAAA,QACN,SAAS,MAAM,KAAK,MAAM,eAAe,KAAK,MAAM,UAAU;AAAA,MAChE;AAAA,MACA,WAAW;AAAA,QACT,MAAM;AAAA,QACN,SAAS,MAAM,KAAK,MAAM,YAAY,KAAK,MAAM,UAAU;AAAA,MAC7D;AAAA,MACA,MAAM;AAAA,QACJ,MAAOA,QAAO,eAAe,SAAU,SAAS;AAAA,QAChD,SAAS,MAAM,KAAK,MAAM,wBAAwB,KAAK,MAAM,UAAU;AAAA,MACzE;AAAA,MACA,aAAa;AAAA,QACX,MAAM;AAAA;AAAA,QAEN,UAAU,KAAK,MAAM;AAAA,QACrB,SAAS,MAAM,KAAK,UAAU,EAAE;AAAA,MAClC;AAAA,MACA,eAAe;AAAA,QACb,MAAM;AAAA;AAAA,QAEN,UAAU,KAAK,MAAM;AAAA,QACrB,SAAS,MAAM,KAAK,UAAU,CAAE;AAAA,MAClC;AAAA,IACF;AAEA,aAAS,gBAAgB,IAAY,OAA6B;AAChE,YAAM,gBAAgB;AACtB,YAAM,EAAE,EAAE,QAAQ;AAAA,IACpB;AAEA,WAAO;AAAA,MAAC;AAAA;AAAA,QAAQ,WAAU;AAAA,QACxB,MAAK;AAAA,QACL,cAAW;AAAA,QAEX;AAAA,8BAAC,YACC,+BAAC,SAAI,WAAU,gBACb;AAAA,iCAAC,QAAG,WAAU,uBAAsB;AAAA;AAAA,cAC1B,cAAc,KAAK,MAAM,MAAM,EAAE;AAAA,eAC3C;AAAA,YACA,oBAAC,SAAI,WAAU,sBACb;AAAA,cAAC;AAAA;AAAA,gBACC,WAAU;AAAA,gBACV,aAAa;AAAA,gBACb,kBAAkB;AAAA,gBAElB;AAAA,sCAAC,UAAO,IAAG,4BAA2B,eAAY,4BAA2B,WAAU,qBAAoB,OAAM,iBAC/G,8BAAC,cAAW,WAAU,0BAAyB,GACjD;AAAA,kBACA,oBAAC,QACC,8BAAC,QAAG,WAAU,mBACX,iBAAO,KAAK,KAAK,EAAE,IAAI,CAAC,OAAO;AAC9B,0BAAM,OAAO,MAAM,EAAE;AACrB,2BAAO,oBAAC,QACN,8BAAC,YAAS,OAAO,IAAI,WAAU,yBAC5B,eAAK,MACR,KAHc,EAIhB;AAAA,kBACF,CAAC,GACH,GACF;AAAA;AAAA;AAAA,YACF,GACF;AAAA,aACF,GAEF;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,uBAAuB;AAAA,cACvB,mBAAmB;AAAA,cACnB,aAAa;AAAA,cAEZ;AAAA;AAAA,UACH;AAAA;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"13cf530347fd66324a92f0d1d210d94f3d2129c4"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ln=function(){return s},s}ln();function JN(e){return ln().f[0]++,ln().s[0]++,oS[e]?(ln().b[0][0]++,oS[e]):(ln().b[0][1]++,oS.invalid)}function mP(e){ln().f[1]++;const n=(ln().s[1]++,{title:"Layer",type:"layer"}),t=(ln().s[2]++,{title:"Filter",type:"filter"}),r=(ln().s[3]++,{title:"JSON Editor",type:"jsoneditor"});return ln().s[4]++,[n,t].concat(JN(e).groups).concat([r])}class tO extends bn.Component{constructor(n){ln().f[5]++,ln().s[7]++,super(n);const t=(ln().s[8]++,{});ln().s[9]++,mP(this.props.layer.type).forEach(r=>{ln().f[6]++,ln().s[10]++,t[r.title]=!0}),ln().s[11]++,this.state={editorGroups:t}}static getDerivedStateFromProps(n,t){ln().f[7]++;const r=(ln().s[12]++,{...t.editorGroups});return ln().s[13]++,JN(n.layer.type).groups.forEach(i=>{ln().f[8]++,ln().s[14]++,i.title in r?ln().b[1][1]++:(ln().b[1][0]++,ln().s[15]++,r[i.title]=!0)}),ln().s[16]++,{editorGroups:r}}getChildContext(){return ln().f[9]++,ln().s[17]++,{reactIconBase:{size:14,color:"#8e8e8e"}}}changeProperty(n,t,r){ln().f[10]++,ln().s[18]++,this.props.onLayerChanged(this.props.layerIndex,Khe(this.props.layer,n,t,r))}onGroupToggle(n,t){ln().f[11]++;const r=(ln().s[19]++,{...this.state.editorGroups,[n]:t});ln().s[20]++,this.setState({editorGroups:r})}renderGroupType(n,t){ln().f[12]++;let r=(ln().s[21]++,"");ln().s[22]++,this.props.layer.metadata?(ln().b[2][0]++,ln().s[23]++,r=this.props.layer.metadata["maputnik:comment"]):ln().b[2][1]++;const{errors:i,layerIndex:o}=(ln().s[24]++,this.props),s=(ln().s[25]++,{});ln().s[26]++,i.forEach(g=>{ln().f[13]++,ln().s[27]++,ln().b[4][0]++,g.parsed&&(ln().b[4][1]++,g.parsed.type==="layer")&&(ln().b[4][2]++,g.parsed.data.index==o)?(ln().b[3][0]++,ln().s[28]++,s[g.parsed.data.key]={message:g.parsed.data.message}):ln().b[3][1]++});let a;const f=(ln().s[29]++,this.props.layer);switch(ln().s[30]++,Object.prototype.hasOwnProperty.call(this.props.sources,f.source)?(ln().b[5][0]++,ln().s[31]++,a=this.props.sources[f.source].layers):ln().b[5][1]++,ln().s[32]++,n){case"layer":return ln().b[6][0]++,ln().s[33]++,N.jsxs("div",{children:[N.jsx(Jj,{value:this.props.layer.id,wdKey:"layer-editor.layer-id",error:s.id,onChange:g=>(ln().f[14]++,ln().s[34]++,this.props.onLayerIdChange(this.props.layerIndex,this.props.layer.id,g))}),N.jsx(e8,{disabled:!0,error:s.type,value:this.props.layer.type,onChange:g=>(ln().f[15]++,ln().s[35]++,this.props.onLayerChanged(this.props.layerIndex,The(this.props.layer,g)))}),(ln().b[7][0]++,this.props.layer.type!=="background"&&(ln().b[7][1]++,N.jsx(n8,{error:s.source,sourceIds:Object.keys(this.props.sources),value:this.props.layer.source,onChange:g=>(ln().f[16]++,ln().s[36]++,this.changeProperty(null,"source",g))}))),(ln().b[8][0]++,["background","raster","hillshade","heatmap"].indexOf(this.props.layer.type)<0&&(ln().b[8][1]++,N.jsx(r8,{error:s["source-layer"],sourceLayerIds:a,value:this.props.layer["source-layer"],onChange:g=>(ln().f[17]++,ln().s[37]++,this.changeProperty(null,"source-layer",g))}))),N.jsx(x6e,{error:s.minzoom,value:this.props.layer.minzoom,onChange:g=>(ln().f[18]++,ln().s[38]++,this.changeProperty(null,"minzoom",g))}),N.jsx(w6e,{error:s.maxzoom,value:this.props.layer.maxzoom,onChange:g=>(ln().f[19]++,ln().s[39]++,this.changeProperty(null,"maxzoom",g))}),N.jsx(M6e,{error:s.comment,value:r,onChange:g=>(ln().f[20]++,ln().s[40]++,this.changeProperty("metadata","maputnik:comment",g==""?(ln().b[9][0]++,void 0):(ln().b[9][1]++,g)))})]});case"filter":return ln().b[6][1]++,ln().s[41]++,N.jsx("div",{children:N.jsx("div",{className:"maputnik-filter-editor-wrapper",children:N.jsx(UW,{errors:s,filter:this.props.layer.filter,properties:this.props.vectorLayers[this.props.layer["source-layer"]],onChange:g=>(ln().f[21]++,ln().s[42]++,this.changeProperty(null,"filter",g))})})});case"properties":return ln().b[6][2]++,ln().s[43]++,N.jsx(C6e,{errors:s,layer:this.props.layer,groupFields:t,spec:this.props.spec,onChange:this.changeProperty.bind(this)});case"jsoneditor":return ln().b[6][3]++,ln().s[44]++,N.jsx(c8,{layer:this.props.layer,onChange:g=>{ln().f[22]++,ln().s[45]++,this.props.onLayerChanged(this.props.layerIndex,g)}});default:return ln().b[6][4]++,ln().s[46]++,N.jsx(N.Fragment,{})}}moveLayer(n){ln().f[23]++,ln().s[47]++,this.props.onMoveLayer({oldIndex:this.props.layerIndex,newIndex:this.props.layerIndex+n})}render(){ln().f[24]++;const n=(ln().s[48]++,[]),t=(ln().s[49]++,this.props.layer.type),r=(ln().s[50]++,mP(t).filter(a=>(ln().f[25]++,ln().s[51]++,ln().b[10][0]++,!(t==="background"&&(ln().b[10][1]++,a.type==="source")))).map(a=>{ln().f[26]++;const f=(ln().s[52]++,a.title.replace(/ /g,"_"));return ln().s[53]++,n.push(f),ln().s[54]++,N.jsx(b6e,{"data-wd-key":a.title,id:f,title:a.title,isActive:this.state.editorGroups[a.title],onActiveToggle:this.onGroupToggle.bind(this,a.title),children:this.renderGroupType(a.type,a.fields)},a.title)})),i=(ln().s[55]++,ln().b[11][0]++,this.props.layer.layout||(ln().b[11][1]++,{})),o=(ln().s[56]++,{delete:{text:"Delete",handler:()=>(ln().f[27]++,ln().s[57]++,this.props.onLayerDestroy(this.props.layerIndex))},duplicate:{text:"Duplicate",handler:()=>(ln().f[28]++,ln().s[58]++,this.props.onLayerCopy(this.props.layerIndex))},hide:{text:i.visibility==="none"?(ln().b[12][0]++,"Show"):(ln().b[12][1]++,"Hide"),handler:()=>(ln().f[29]++,ln().s[59]++,this.props.onLayerVisibilityToggle(this.props.layerIndex))},moveLayerUp:{text:"Move layer up",disabled:this.props.isFirstLayer,handler:()=>(ln().f[30]++,ln().s[60]++,this.moveLayer(-1))},moveLayerDown:{text:"Move layer down",disabled:this.props.isLastLayer,handler:()=>(ln().f[31]++,ln().s[61]++,this.moveLayer(1))}});function s(a,f){ln().f[32]++,ln().s[62]++,f.stopPropagation(),ln().s[63]++,o[a].handler()}return ln().s[64]++,N.jsxs("section",{className:"maputnik-layer-editor",role:"main","aria-label":"Layer editor",children:[N.jsx("header",{children:N.jsxs("div",{className:"layer-header",children:[N.jsxs("h2",{className:"layer-header__title",children:["Layer: ",XN(this.props.layer.id)]}),N.jsx("div",{className:"layer-header__info",children:N.jsxs(Gx.Wrapper,{className:"more-menu",onSelection:s,closeOnSelection:!1,children:[N.jsx(Gx.Button,{id:"skip-target-layer-editor","data-wd-key":"skip-target-layer-editor",className:"more-menu__button",title:"Layer options",children:N.jsx(OJ,{className:"more-menu__button__svg"})}),N.jsx(Gx.Menu,{children:N.jsx("ul",{className:"more-menu__menu",children:Object.keys(o).map(a=>{ln().f[33]++;const f=(ln().s[65]++,o[a]);return ln().s[66]++,N.jsx("li",{children:N.jsx(Gx.MenuItem,{value:a,className:"more-menu__menu__item",children:f.text})},a)})})})]})})]})}),N.jsx(zfe,{allowMultipleExpanded:!0,allowZeroExpanded:!0,preExpanded:n,children:r})]})}}nn(tO,"defaultProps",(ln().s[5]++,{onLayerChanged:()=>{ln().f[2]++},onLayerIdChange:()=>{ln().f[3]++},onLayerDestroyed:()=>{ln().f[4]++}})),nn(tO,"childContextTypes",(ln().s[6]++,{reactIconBase:Pr.object}));var gP=function(e,n,t){if(t||arguments.length===2)for(var r=0,i=n.length,o;r<i;r++)(o||!(r in n))&&(o||(o=Array.prototype.slice.call(n,0,r)),o[r]=n[r]);return e.concat(o||Array.prototype.slice.call(n))},F6e=function(){function e(n,t,r){this.name=n,this.version=t,this.os=r,this.type="browser"}return e}(),D6e=function(){function e(n){this.version=n,this.type="node",this.name="node",this.os=process.platform}return e}(),U6e=function(){function e(n,t,r,i){this.name=n,this.version=t,this.os=r,this.bot=i,this.type="bot-device"}return e}(),R6e=function(){function e(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null}return e}(),L6e=function(){function e(){this.type="react-native",this.name="react-native",this.version=null,this.os=null}return e}(),z6e=/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/,j6e=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,yP=3,W6e=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",z6e]],vP=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function N6e(e){return e?CP(e):typeof document>"u"&&typeof navigator<"u"&&navigator.product==="ReactNative"?new L6e:typeof navigator<"u"?CP(navigator.userAgent):$6e()}function G6e(e){return e!==""&&W6e.reduce(function(n,t){var r=t[0],i=t[1];if(n)return n;var o=i.exec(e);return!!o&&[r,o]},!1)}function CP(e){var n=G6e(e);if(!n)return null;var t=n[0],r=n[1];if(t==="searchbot")return new R6e;var i=r[1]&&r[1].split(".").join("_").split("_").slice(0,3);i?i.length<yP&&(i=gP(gP([],i,!0),Y6e(yP-i.length),!0)):i=[];var o=i.join("."),s=Q6e(e),a=j6e.exec(e);return a&&a[1]?new U6e(t,o,s,a[1]):new F6e(t,o,s)}function Q6e(e){for(var n=0,t=vP.length;n<t;n++){var r=vP[n],i=r[0],o=r[1],s=o.exec(e);if(s)return i}return null}function $6e(){var e=typeof process<"u"&&process.version;return e?new D6e(process.version.slice(1)):null}function Y6e(e){for(var n=[],t=0;t<e;t++)n.push("0");return n}const q6e="maputnik",V6e="2.0.0-pre.2",H6e="A MapLibre GL visual style editor",Z6e="module",X6e="''",J6e={start:"vite",build:"tsc && vite build --base=/maputnik/",lint:"eslint ./src ./cypress --ext ts,tsx,js,jsx --report-unused-disable-directives --max-warnings 0",test:"cypress run","cy:open":"cypress open","lint-css":'stylelint "src/styles/*.scss"'},eEe={type:"git",url:"https://github.com/maplibre/maputnik"},tEe="Lukas Martinelli",nEe="MIT",rEe="https://github.com/maplibre/maputnik#readme",iEe={"@mapbox/mapbox-gl-rtl-text":"^0.2.3","@maplibre/maplibre-gl-style-spec":"^20.1.0","@mdi/js":"^6.6.96","@mdi/react":"^1.5.0","@typescript-eslint/eslint-plugin":"^6.16.0","@typescript-eslint/parser":"^6.16.0","array-move":"^4.0.0",buffer:"^6.0.3",classnames:"^2.3.1",codemirror:"^5.65.2",color:"^4.2.3","detect-browser":"^5.3.0","file-saver":"^2.0.5","json-stringify-pretty-compact":"^3.0.0","json-to-ast":"^2.1.0",jsonlint:"github:josdejong/jsonlint#85a19d7",lodash:"^4.17.21","lodash.capitalize":"^4.2.1","lodash.clamp":"^4.0.3","lodash.clonedeep":"^4.5.0","lodash.get":"^4.4.2","lodash.isequal":"^4.5.0","lodash.throttle":"^4.1.1","mapbox-gl-inspect":"^1.3.1","maplibre-gl":"^4.0.0-pre.4","maputnik-design":"github:maputnik/design#172b06c",ol:"^6.14.1","ol-mapbox-style":"^7.1.1","prop-types":"^15.8.1",react:"^16.0.0","react-accessible-accordion":"^4.0.0","react-aria-menubutton":"^7.0.3","react-aria-modal":"^4.0.1","react-autobind":"^1.0.6","react-autocomplete":"^1.8.1","react-collapse":"^5.1.1","react-color":"^2.19.3","react-dom":"^16.0.0","react-file-reader-input":"^2.0.0","react-icon-base":"^2.1.2","react-icons":"^4.3.1","react-sortable-hoc":"^2.0.0","reconnecting-websocket":"^4.4.0",sass:"^1.50.0",slugify:"^1.6.5","string-hash":"^1.1.3",url:"^0.11.0"},oEe={esversion:6},aEe={extends:"stylelint-config-recommended-scss",rules:{"no-descending-specificity":null,"media-feature-name-no-unknown":[!0,{ignoreMediaFeatureNames:["prefers-reduced-motion"]}]}},sEe={"@cypress/code-coverage":"^3.12.15","@istanbuljs/nyc-config-typescript":"^1.0.2","@rollup/plugin-replace":"^5.0.5","@shellygo/cypress-test-utils":"^2.0.17","@types/codemirror":"^5.60.15","@types/color":"^3.0.6","@types/cors":"^2.8.17","@types/file-saver":"^2.0.7","@types/geojson":"^7946.0.13","@types/json-to-ast":"^2.1.4","@types/lodash.capitalize":"^4.2.9","@types/lodash.clamp":"^4.0.9","@types/lodash.clonedeep":"^4.5.9","@types/lodash.get":"^4.4.9","@types/lodash.isequal":"^4.5.8","@types/lodash.throttle":"^4.1.9","@types/react":"^16.14.52","@types/react-aria-menubutton":"^6.2.13","@types/react-aria-modal":"^4.0.9","@types/react-autocomplete":"^1.8.9","@types/react-collapse":"^5.0.4","@types/react-color":"^3.0.10","@types/react-dom":"^16.9.24","@types/react-file-reader-input":"^2.0.4","@types/react-icon-base":"^2.1.6","@types/string-hash":"^1.1.3","@types/uuid":"^9.0.7","@vitejs/plugin-react":"^4.2.0",cors:"^2.8.5",cypress:"^13.6.1",eslint:"^8.56.0","eslint-plugin-react":"^7.33.2","eslint-plugin-react-hooks":"^4.6.0","eslint-plugin-react-refresh":"^0.4.5",express:"^4.17.3",istanbul:"^0.4.5","istanbul-lib-coverage":"^3.2.0",mocha:"^9.2.2",postcss:"^8.4.12","react-hot-loader":"^4.13.0",stylelint:"^14.6.1","stylelint-config-recommended-scss":"^6.0.0","stylelint-scss":"^4.2.0",typescript:"^5.3.3",uuid:"^8.3.2",vite:"^5.0.12","vite-plugin-istanbul":"^5.0.0"},_P={name:q6e,version:V6e,description:H6e,type:Z6e,main:X6e,scripts:J6e,repository:eEe,author:tEe,license:nEe,homepage:rEe,dependencies:iEe,jshintConfig:oEe,stylelint:aEe,devDependencies:sEe},lEe="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='1200'%20height='1200'%20viewBox='0%200%20100%20100'%3e%3cg%20class='map'%20stroke='%23000'%3e%3cuse%20xlink:href='%23ref-1--map__main'%20fill='%234eba6f'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--map__line1'%20fill='none'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--map__line2'%20fill='none'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--map__line3'%20fill='none'%3e%3c/use%3e%3c/g%3e%3cg%20class='palette'%3e%3cuse%20xlink:href='%23ref-1--palette__main'%20fill='%23fff'%20stroke='%23000'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__inner'%20fill='none'%20stroke='%23000'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle5'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle4'%20fill='%234eba6f'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle3'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle2'%20fill='%234eba6f'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle1'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle0'%20fill='%234eba6f'%3e%3c/use%3e%3c/g%3e%3cg%20class='brush'%20stroke='%23000'%3e%3cuse%20xlink:href='%23ref-1--brush__bottom'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--brush__top'%20fill='%23fff'%3e%3c/use%3e%3c/g%3e%3cdefs%3e%3cpath%20id='ref-1--map__main'%20stroke-width='2.366'%20stroke-linejoin='round'%20d='M18.84%207.717l15.44%207.542%2015.75-7.762%2015.7%207.857L81.005%207.67%2096.31%2054.052%2073.598%2062.12%2050.93%2053.872l-25.1%208.066-22.668-8.066z'%3e%3c/path%3e%3cpath%20id='ref-1--map__line1'%20d='M65.556%2015.07l7.647%2046.838'%20stroke-width='1.104'%3e%3c/path%3e%3cpath%20id='ref-1--map__line2'%20d='M50.261%207.422l.717%2046.6'%20stroke-width='1.104'%3e%3c/path%3e%3cpath%20id='ref-1--map__line3'%20d='M34.011%2015.07l-8.603%2046.6'%20stroke-width='1.104'%3e%3c/path%3e%3cpath%20id='ref-1--palette__main'%20stroke-width='2.3'%20d='M47.352%2030.887c7.993.226%2016.934%209.725%2017.954%2015.25%201.02%205.527-.743%2011.125-4.298%2013.875-3.554%202.75-8.6%202.905-8.723%208.302-.097%204.237%208.457%208.5%208.088%2015.653-.406%207.857-15.508%2013.15-30.943%206.102-8.556-3.906-14.249-13.653-13.385-26.238C16.833%2052.334%2022.32%2043.658%2027.382%2039c5.977-5.503%2011.977-8.337%2019.97-8.112z'%3e%3c/path%3e%3ccircle%20id='ref-1--palette__inner'%20stroke-width='2.3'%20cx='41.873'%20cy='61.901'%20r='6.389'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle5'%20cy='44.56'%20cx='54.347'%20r='4.336'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle4'%20cx='40.443'%20cy='41.555'%20r='4.336'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle3'%20r='4.336'%20cy='51.102'%20cx='29.651'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle2'%20cx='25.293'%20cy='65.836'%20r='4.336'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle1'%20r='4.336'%20cy='79.326'%20cx='32.764'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle0'%20cx='46.669'%20cy='80.571'%20r='4.336'%3e%3c/circle%3e%3cpath%20id='ref-1--brush__bottom'%20d='M76.333%2089.333c-1.645-9.794-4.375-35.26-4.32-37.887.056-2.627%202.52-4.34%205.36-4.317%202.842.022%205.098%201.87%205.314%204.27.107%201.2-1.576%2028.06-2.318%2037.844-.332%204.374-3.31%204.413-4.036.09z'%20stroke-width='2.3'%20stroke-linejoin='round'%3e%3c/path%3e%3cpath%20id='ref-1--brush__top'%20stroke-linejoin='round'%20stroke-width='2.3'%20d='M77.184%2026.428s-5.621%207.02-5.621%2011.978c0%204.957%202.206%206.878%205.81%206.878%203.606%200%205.148-1.708%205.29-6.736.142-5.028-5.479-12.12-5.479-12.12z'%3e%3c/path%3e%3c/defs%3e%3c/svg%3e";function Ui(){var e="/home/runner/work/maputnik/maputnik/src/components/AppToolbar.tsx",n="0db82fbe81362fe89bc1026468f1e8ab5376993d",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/AppToolbar.tsx",statementMap:{0:{start:{line:8,column:16},end:{line:8,column:24}},1:{start:{line:9,column:41},end:{line:9,column:89}},2:{start:{line:12,column:4},end:{line:12,column:107}},3:{start:{line:17,column:4},end:{line:27,column:6}},4:{start:{line:32,column:4},end:{line:39,column:6}},5:{start:{line:44,column:4},end:{line:52,column:6}},6:{start:{line:56,column:10},end:{line:64,column:3}},7:{start:{line:66,column:4},end:{line:66,column:34}},8:{start:{line:68,column:11},end:{line:75,column:3}},9:{start:{line:69,column:4},end:{line:74,column:5}},10:{start:{line:70,column:6},end:{line:70,column:59}},11:{start:{line:72,column:17},end:{line:72,column:65}},12:{start:{line:73,column:6},end:{line:73,column:17}},13:{start:{line:77,column:18},end:{line:113,column:5}},14:{start:{line:114,column:24},end:{line:116,column:6}},15:{start:{line:115,column:6},end:{line:115,column:45}},16:{start:{line:117,column:4},end:{line:217,column:12}},17:{start:{line:128,column:33},end:{line:128,column:58}},18:{start:{line:137,column:33},end:{line:137,column:60}},19:{start:{line:146,column:33},end:{line:146,column:51}},20:{start:{line:198,column:33},end:{line:198,column:69}},21:{start:{line:201,column:38},end:{line:201,column:59}},22:{start:{line:202,column:20},end:{line:202,column:157}},23:{start:{line:204,column:112},end:{line:204,column:145}},24:{start:{line:205,column:20},end:{line:205,column:133}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:11,column:2},end:{line:11,column:3}},loc:{start:{line:11,column:11},end:{line:13,column:3}},line:11},1:{name:"(anonymous_1)",decl:{start:{line:16,column:2},end:{line:16,column:3}},loc:{start:{line:16,column:11},end:{line:28,column:3}},line:16},2:{name:"(anonymous_2)",decl:{start:{line:31,column:2},end:{line:31,column:3}},loc:{start:{line:31,column:11},end:{line:40,column:3}},line:31},3:{name:"(anonymous_3)",decl:{start:{line:43,column:2},end:{line:43,column:3}},loc:{start:{line:43,column:11},end:{line:53,column:3}},line:43},4:{name:"(anonymous_4)",decl:{start:{line:65,column:2},end:{line:65,column:3}},loc:{start:{line:65,column:23},end:{line:67,column:3}},line:65},5:{name:"(anonymous_5)",decl:{start:{line:68,column:11},end:{line:68,column:12}},loc:{start:{line:68,column:23},end:{line:75,column:3}},line:68},6:{name:"(anonymous_6)",decl:{start:{line:76,column:2},end:{line:76,column:3}},loc:{start:{line:76,column:11},end:{line:218,column:3}},line:76},7:{name:"(anonymous_7)",decl:{start:{line:114,column:35},end:{line:114,column:36}},loc:{start:{line:114,column:45},end:{line:116,column:5}},line:114},8:{name:"(anonymous_8)",decl:{start:{line:128,column:25},end:{line:128,column:26}},loc:{start:{line:128,column:33},end:{line:128,column:58}},line:128},9:{name:"(anonymous_9)",decl:{start:{line:137,column:25},end:{line:137,column:26}},loc:{start:{line:137,column:33},end:{line:137,column:60}},line:137},10:{name:"(anonymous_10)",decl:{start:{line:146,column:25},end:{line:146,column:26}},loc:{start:{line:146,column:33},end:{line:146,column:51}},line:146},11:{name:"(anonymous_11)",decl:{start:{line:198,column:26},end:{line:198,column:27}},loc:{start:{line:198,column:33},end:{line:198,column:69}},line:198},12:{name:"(anonymous_12)",decl:{start:{line:201,column:31},end:{line:201,column:32}},loc:{start:{line:201,column:38},end:{line:201,column:59}},line:201},13:{name:"(anonymous_13)",decl:{start:{line:201,column:65},end:{line:201,column:66}},loc:{start:{line:201,column:75},end:{line:203,column:19}},line:201},14:{name:"(anonymous_14)",decl:{start:{line:204,column:105},end:{line:204,column:106}},loc:{start:{line:204,column:112},end:{line:204,column:145}},line:204},15:{name:"(anonymous_15)",decl:{start:{line:204,column:151},end:{line:204,column:152}},loc:{start:{line:204,column:161},end:{line:206,column:19}},line:204}},branchMap:{0:{loc:{start:{line:69,column:4},end:{line:74,column:5}},type:"if",locations:[{start:{line:69,column:4},end:{line:74,column:5}},{start:{line:71,column:11},end:{line:74,column:5}}],line:69}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/AppToolbar.tsx"],names:[],mappings:"AAqBW,cAoLG,YApLH;AArBX,OAAO,WAAW;AAClB,OAAO,gBAAgB;AACvB,SAAQ,cAAa;AAErB,SAAQ,gBAAgB,iBAAiB,YAAY,UAAU,eAAe,oBAAmB;AACjG,OAAO,aAAa;AAEpB,OAAO,kBAAkB;AAGzB,MAAM,UAAU,OAAO;AACvB,MAAM,mCAAmC,CAAC,UAAU,SAAS,EAAE,QAAQ,QAAS,IAAI,IAAI;AAQxF,MAAM,iBAAiB,MAAM,UAAyB;AAAA,EACpD,SAAS;AACP,WAAO,oBAAC,UAAK,WAAU,sBAAsB,eAAK,MAAM,UAAS;AAAA,EACnE;AACF;AASA,MAAM,oBAAoB,MAAM,UAA4B;AAAA,EAC1D,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAW,WAAW,yBAAyB,KAAK,MAAM,SAAS;AAAA,QACnE,MAAM,KAAK,MAAM;AAAA,QACjB,KAAI;AAAA,QACJ,QAAO;AAAA,QACP,eAAY;AAAA,QAEX,eAAK,MAAM;AAAA;AAAA,IACd;AAAA,EACF;AACF;AAOA,MAAM,sBAAsB,MAAM,UAA8B;AAAA,EAC9D,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,eAAa,KAAK,MAAM;AAAA,QAEvB,eAAK,MAAM;AAAA;AAAA,IACd;AAAA,EACF;AACF;AAQA,MAAM,sBAAsB,MAAM,UAA8B;AAAA,EAC9D,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,WAAU;AAAA,QACV,eAAa,KAAK,MAAM;AAAA,QACxB,SAAS,KAAK,MAAM;AAAA,QAEnB,eAAK,MAAM;AAAA;AAAA,IACd;AAAA,EACF;AACF;AAmBA,qBAAqB,mBAAmB,MAAM,UAA2B;AAAA,EACvE,QAAQ;AAAA,IACN,QAAQ;AAAA,MACN,UAAU;AAAA,MACV,SAAS;AAAA,MACT,MAAM;AAAA,MACN,KAAK;AAAA,MACL,QAAQ;AAAA,IACV;AAAA,EACF;AAAA,EAEA,gBAAgB,KAAe;AAC7B,SAAK,MAAM,cAAc,GAAG;AAAA,EAC9B;AAAA,EAEA,SAAS,CAAC,WAAmB;AAC3B,QAAI,WAAW,OAAO;AACpB,MAAC,SAAS,cAAc,oBAAoB,EAAwB,MAAM;AAAA,IAC5E,OACK;AACH,YAAM,KAAK,SAAS,cAAc,kBAAgB,MAAM;AACxD,SAAG,MAAM;AAAA,IACX;AAAA,EACF;AAAA,EAEA,SAAS;AACP,UAAM,QAAQ;AAAA,MACZ;AAAA,QACE,IAAI;AAAA,QACJ,OAAO;AAAA,QACP,OAAO;AAAA,MACT;AAAA,MACA;AAAA,QACE,IAAI;AAAA,QACJ,OAAO;AAAA,QACP,OAAO;AAAA,QACP,UAAU,KAAK,MAAM,aAAa;AAAA,MACpC;AAAA,MACA;AAAA,QACE,IAAI;AAAA,QACJ,OAAO;AAAA,QACP,OAAO;AAAA,QACP,UAAU,CAAC;AAAA,MACb;AAAA,MACA;AAAA,QACE,IAAI;AAAA,QACJ,OAAO;AAAA,QACP,OAAO;AAAA,QACP,UAAU,CAAC;AAAA,MACb;AAAA,MACA;AAAA,QACE,IAAI;AAAA,QACJ,OAAO;AAAA,QACP,OAAO;AAAA,QACP,UAAU,CAAC;AAAA,MACb;AAAA,MACA;AAAA,QACE,IAAI;AAAA,QACJ,OAAO;AAAA,QACP,OAAO;AAAA,QACP,UAAU,CAAC;AAAA,MACb;AAAA,IACF;AAEA,UAAM,cAAc,MAAM,KAAK,CAAC,SAAS;AACvC,aAAO,KAAK,OAAO,KAAK,MAAM;AAAA,IAChC,CAAC;AAED,WAAO,oBAAC,SAAI,WAAU,oBACpB,+BAAC,SAAI,WAAU,2BACb;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UAGV;AAAA;AAAA,cAAC;AAAA;AAAA,gBACC,eAAY;AAAA,gBACZ,WAAU;AAAA,gBACV,SAAS,QAAM,KAAK,OAAO,YAAY;AAAA,gBACxC;AAAA;AAAA,YAED;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,eAAY;AAAA,gBACZ,WAAU;AAAA,gBACV,SAAS,QAAM,KAAK,OAAO,cAAc;AAAA,gBAC1C;AAAA;AAAA,YAED;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,eAAY;AAAA,gBACZ,WAAU;AAAA,gBACV,SAAS,QAAM,KAAK,OAAO,KAAK;AAAA,gBACjC;AAAA;AAAA,YAED;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,WAAU;AAAA,gBACV,QAAO;AAAA,gBACP,KAAI;AAAA,gBACJ,MAAK;AAAA,gBAEL;AAAA,sCAAC,SAAI,KAAK,cAAc,KAAI,sBAAqB;AAAA,kBACjD,qBAAC,QACC;AAAA,wCAAC,UAAK,WAAU,yBAAyB,kBAAQ,MAAK;AAAA,oBACtD,qBAAC,UAAK,WAAU,4BAA2B;AAAA;AAAA,sBAAE,QAAQ;AAAA,uBAAQ;AAAA,qBAC/D;AAAA;AAAA;AAAA,YACF;AAAA;AAAA;AAAA,MACF;AAAA,MACA,qBAAC,SAAI,WAAU,6BAA4B,MAAK,cAAa,cAAW,WACtE;AAAA,6BAAC,iBAAc,OAAM,YAAW,SAAS,KAAK,MAAM,cAAc,KAAK,MAAM,MAAM,GACjF;AAAA,8BAAC,mBAAgB;AAAA,UACjB,oBAAC,YAAS,kBAAI;AAAA,WAChB;AAAA,QACA,qBAAC,iBAAc,OAAM,cAAa,SAAS,KAAK,MAAM,cAAc,KAAK,MAAM,QAAQ,GACrF;AAAA,8BAAC,kBAAe;AAAA,UAChB,oBAAC,YAAS,oBAAM;AAAA,WAClB;AAAA,QACA,qBAAC,iBAAc,OAAM,eAAc,SAAS,KAAK,MAAM,cAAc,KAAK,MAAM,SAAS,GACvF;AAAA,8BAAC,YAAS;AAAA,UACV,oBAAC,YAAS,0BAAY;AAAA,WACxB;AAAA,QACA,qBAAC,iBAAc,OAAM,gBAAe,SAAS,KAAK,MAAM,cAAc,KAAK,MAAM,UAAU,GACzF;AAAA,8BAAC,cAAW;AAAA,UACZ,oBAAC,YAAS,4BAAc;AAAA,WAC1B;AAAA,QAEA,qBAAC,iBAAc,OAAM,eACnB;AAAA,8BAAC,gBAAa;AAAA,UACd,qBAAC,WAAM;AAAA;AAAA,YACL;AAAA,cAAC;AAAA;AAAA,gBACC,WAAU;AAAA,gBACV,eAAY;AAAA,gBACZ,UAAU,CAAC,MAAM,KAAK,gBAAgB,EAAE,OAAO,KAAiB;AAAA,gBAChE,OAAO,aAAa;AAAA,gBAEnB;AAAA,wBAAM,OAAO,OAAK,EAAE,UAAU,SAAS,EAAE,IAAI,CAAC,SAAS;AACtD,2BACE,oBAAC,YAAqB,OAAO,KAAK,IAAI,UAAU,KAAK,UAAU,eAAa,KAAK,IAC9E,eAAK,SADK,KAAK,EAElB;AAAA,kBAEJ,CAAC;AAAA,kBACD,oBAAC,cAAS,OAAM,uBACb,gBAAM,OAAO,OAAK,EAAE,UAAU,qBAAqB,EAAE,IAAI,CAAC,SAAS;AAClE,2BACE,oBAAC,YAAqB,OAAO,KAAK,IAAI,UAAU,KAAK,UAClD,eAAK,SADK,KAAK,EAElB;AAAA,kBAEJ,CAAC,GACH;AAAA;AAAA;AAAA,YACF;AAAA,aACF;AAAA,WACF;AAAA,QAEA,qBAAC,eAAY,MAAM,6CACjB;AAAA,8BAAC,iBAAc;AAAA,UACf,oBAAC,YAAS,kBAAI;AAAA,WAChB;AAAA,SACF;AAAA,OACF,GACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"0db82fbe81362fe89bc1026468f1e8ab5376993d"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Ui=function(){return s},s}Ui();const uEe=(Ui().s[0]++,N6e()),qx=(Ui().s[1]++,["chrome","firefox"].indexOf(uEe.name)>-1);class eC extends bn.Component{render(){return Ui().f[0]++,Ui().s[2]++,N.jsx("span",{className:"maputnik-icon-text",children:this.props.children})}}class AEe extends bn.Component{render(){return Ui().f[1]++,Ui().s[3]++,N.jsx("a",{className:Af("maputnik-toolbar-link",this.props.className),href:this.props.href,rel:"noopener noreferrer",target:"_blank","data-wd-key":"toolbar:link",children:this.props.children})}}class cEe extends bn.Component{render(){return Ui().f[2]++,Ui().s[4]++,N.jsx("div",{className:"maputnik-toolbar-select","data-wd-key":this.props.wdKey,children:this.props.children})}}class Vx extends bn.Component{render(){return Ui().f[3]++,Ui().s[5]++,N.jsx("button",{className:"maputnik-toolbar-action","data-wd-key":this.props.wdKey,onClick:this.props.onClick,children:this.props.children})}}class dEe extends bn.Component{constructor(){super(...arguments);nn(this,"state",(Ui().s[6]++,{isOpen:{settings:!1,sources:!1,open:!1,add:!1,export:!1}}));nn(this,"onSkip",(Ui().s[8]++,t=>{if(Ui().f[5]++,Ui().s[9]++,t==="map")Ui().b[0][0]++,Ui().s[10]++,document.querySelector(".maplibregl-canvas").focus();else{Ui().b[0][1]++;const r=(Ui().s[11]++,document.querySelector("#skip-target-"+t));Ui().s[12]++,r.focus()}}))}handleSelection(t){Ui().f[4]++,Ui().s[7]++,this.props.onSetMapState(t)}render(){Ui().f[6]++;const t=(Ui().s[13]++,[{id:"map",group:"general",title:"Map"},{id:"inspect",group:"general",title:"Inspect",disabled:this.props.renderer==="ol"},{id:"filter-deuteranopia",group:"color-accessibility",title:"Deuteranopia filter",disabled:!qx},{id:"filter-protanopia",group:"color-accessibility",title:"Protanopia filter",disabled:!qx},{id:"filter-tritanopia",group:"color-accessibility",title:"Tritanopia filter",disabled:!qx},{id:"filter-achromatopsia",group:"color-accessibility",title:"Achromatopsia filter",disabled:!qx}]),r=(Ui().s[14]++,t.find(i=>(Ui().f[7]++,Ui().s[15]++,i.id===this.props.mapState)));return Ui().s[16]++,N.jsx("nav",{className:"maputnik-toolbar",children:N.jsxs("div",{className:"maputnik-toolbar__inner",children:[N.jsxs("div",{className:"maputnik-toolbar-logo-container",children:[N.jsx("button",{"data-wd-key":"root:skip:layer-list",className:"maputnik-toolbar-skip",onClick:i=>(Ui().f[8]++,Ui().s[17]++,this.onSkip("layer-list")),children:"Layers list"}),N.jsx("button",{"data-wd-key":"root:skip:layer-editor",className:"maputnik-toolbar-skip",onClick:i=>(Ui().f[9]++,Ui().s[18]++,this.onSkip("layer-editor")),children:"Layer editor"}),N.jsx("button",{"data-wd-key":"root:skip:map-view",className:"maputnik-toolbar-skip",onClick:i=>(Ui().f[10]++,Ui().s[19]++,this.onSkip("map")),children:"Map view"}),N.jsxs("a",{className:"maputnik-toolbar-logo",target:"blank",rel:"noreferrer noopener",href:"https://github.com/maplibre/maputnik",children:[N.jsx("img",{src:lEe,alt:"Maputnik on GitHub"}),N.jsxs("h1",{children:[N.jsx("span",{className:"maputnik-toolbar-name",children:_P.name}),N.jsxs("span",{className:"maputnik-toolbar-version",children:["v",_P.version]})]})]})]}),N.jsxs("div",{className:"maputnik-toolbar__actions",role:"navigation","aria-label":"Toolbar",children:[N.jsxs(Vx,{wdKey:"nav:open",onClick:this.props.onToggleModal.bind(this,"open"),children:[N.jsx(pJ,{}),N.jsx(eC,{children:"Open"})]}),N.jsxs(Vx,{wdKey:"nav:export",onClick:this.props.onToggleModal.bind(this,"export"),children:[N.jsx(T6,{}),N.jsx(eC,{children:"Export"})]}),N.jsxs(Vx,{wdKey:"nav:sources",onClick:this.props.onToggleModal.bind(this,"sources"),children:[N.jsx(wJ,{}),N.jsx(eC,{children:"Data Sources"})]}),N.jsxs(Vx,{wdKey:"nav:settings",onClick:this.props.onToggleModal.bind(this,"settings"),children:[N.jsx(mJ,{}),N.jsx(eC,{children:"Style Settings"})]}),N.jsxs(cEe,{wdKey:"nav:inspect",children:[N.jsx(cJ,{}),N.jsxs("label",{children:["View",N.jsxs("select",{className:"maputnik-select","data-wd-key":"maputnik-select",onChange:i=>(Ui().f[11]++,Ui().s[20]++,this.handleSelection(i.target.value)),value:r==null?void 0:r.id,children:[t.filter(i=>(Ui().f[12]++,Ui().s[21]++,i.group==="general")).map(i=>(Ui().f[13]++,Ui().s[22]++,N.jsx("option",{value:i.id,disabled:i.disabled,"data-wd-key":i.id,children:i.title},i.id))),N.jsx("optgroup",{label:"Color accessibility",children:t.filter(i=>(Ui().f[14]++,Ui().s[23]++,i.group==="color-accessibility")).map(i=>(Ui().f[15]++,Ui().s[24]++,N.jsx("option",{value:i.id,disabled:i.disabled,children:i.title},i.id)))})]})]})]}),N.jsxs(AEe,{href:"https://github.com/maplibre/maputnik/wiki",children:[N.jsx(dJ,{}),N.jsx(eC,{children:"Help"})]})]})]})})}}function d4(){var e="/home/runner/work/maputnik/maputnik/src/components/ScrollContainer.tsx",n="d17a642b15310eb6111b086bd920c67ec86a8271",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ScrollContainer.tsx",statementMap:{0:{start:{line:5,column:4},end:{line:5,column:113}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:4,column:2},end:{line:4,column:3}},loc:{start:{line:4,column:11},end:{line:6,column:3}},line:4}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ScrollContainer.tsx"],names:[],mappings:"AAQW;AARX,OAAO,WAAW;AAMlB,qBAAqB,wBAAwB,MAAM,UAAgC;AAAA,EACjF,SAAS;AACP,WAAO,oBAAC,SAAI,WAAU,6BACnB,eAAK,MAAM,UACd;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"d17a642b15310eb6111b086bd920c67ec86a8271"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return d4=function(){return s},s}d4();class hEe extends bn.Component{render(){return d4().f[0]++,d4().s[0]++,N.jsx("div",{className:"maputnik-scroll-container",children:this.props.children})}}function sp(){var e="/home/runner/work/maputnik/maputnik/src/components/AppLayout.tsx",n="d25fdb432b603b186bd9e2fc84ff27ac61d9521e",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/AppLayout.tsx",statementMap:{0:{start:{line:6,column:29},end:{line:8,column:3}},1:{start:{line:10,column:4},end:{line:12,column:6}},2:{start:{line:15,column:4},end:{line:22,column:9}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:20},end:{line:13,column:3}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:11},end:{line:23,column:3}},line:14}},branchMap:{0:{loc:{start:{line:20,column:6},end:{line:20,column:123}},type:"binary-expr",locations:[{start:{line:20,column:6},end:{line:20,column:23}},{start:{line:20,column:43},end:{line:20,column:123}}],line:20}},s:{0:0,1:0,2:0},f:{0:0,1:0},b:{0:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/AppLayout.tsx"],names:[],mappings:"AAyBW,SAEL,KAFK;AAzBX,OAAO,WAAW;AAClB,OAAO,eAAe;AACtB,OAAO,qBAAqB;AAW5B,MAAM,kBAAkB,MAAM,UAA0B;AAAA,EACtD,OAAO,oBAAoB;AAAA,IACzB,eAAe,UAAU;AAAA,EAC3B;AAAA,EAEA,kBAAkB;AAChB,WAAO;AAAA,MACL,eAAe,EAAE,MAAM,GAAG;AAAA,IAC5B;AAAA,EACF;AAAA,EAEA,SAAS;AACP,WAAO,qBAAC,SAAI,WAAU,mBACnB;AAAA,WAAK,MAAM;AAAA,MACZ,oBAAC,SAAI,WAAU,wBACZ,eAAK,MAAM,WACd;AAAA,MACA,oBAAC,SAAI,WAAU,0BACb,8BAAC,mBACE,eAAK,MAAM,aACd,GACF;AAAA,MACC,KAAK,MAAM;AAAA,MACX,KAAK,MAAM,UAAU,oBAAC,SAAI,WAAU,0BAClC,eAAK,MAAM,QACd;AAAA,MAEC,KAAK,MAAM;AAAA,OACd;AAAA,EACF;AACF;AAEA,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"d25fdb432b603b186bd9e2fc84ff27ac61d9521e"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return sp=function(){return s},s}sp();class eG extends bn.Component{getChildContext(){return sp().f[0]++,sp().s[1]++,{reactIconBase:{size:14}}}render(){return sp().f[1]++,sp().s[2]++,N.jsxs("div",{className:"maputnik-layout",children:[this.props.toolbar,N.jsx("div",{className:"maputnik-layout-list",children:this.props.layerList}),N.jsx("div",{className:"maputnik-layout-drawer",children:N.jsx(hEe,{children:this.props.layerEditor})}),this.props.map,(sp().b[0][0]++,this.props.bottom&&(sp().b[0][1]++,N.jsx("div",{className:"maputnik-layout-bottom",children:this.props.bottom}))),this.props.modals]})}}nn(eG,"childContextTypes",(sp().s[0]++,{reactIconBase:Pr.object}));function za(){var e="/home/runner/work/maputnik/maputnik/src/components/AppMessagePanel.tsx",n="e5f88535075aece22d8ac3a6577a6cf140d2a75b",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/AppMessagePanel.tsx",statementMap:{0:{start:{line:5,column:24},end:{line:8,column:3}},1:{start:{line:10,column:35},end:{line:10,column:45}},2:{start:{line:11,column:19},end:{line:37,column:6}},3:{start:{line:13,column:6},end:{line:35,column:7}},4:{start:{line:14,column:27},end:{line:14,column:32}},5:{start:{line:15,column:24},end:{line:15,column:73}},6:{start:{line:16,column:8},end:{line:32,column:13}},7:{start:{line:27,column:31},end:{line:27,column:74}},8:{start:{line:34,column:8},end:{line:34,column:32}},9:{start:{line:36,column:6},end:{line:36,column:120}},10:{start:{line:38,column:18},end:{line:40,column:6}},11:{start:{line:39,column:6},end:{line:39,column:68}},12:{start:{line:41,column:4},end:{line:44,column:9}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:19},end:{line:6,column:20}},loc:{start:{line:6,column:25},end:{line:7,column:5}},line:6},1:{name:"(anonymous_1)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:11},end:{line:45,column:3}},line:9},2:{name:"(anonymous_2)",decl:{start:{line:11,column:42},end:{line:11,column:43}},loc:{start:{line:11,column:58},end:{line:37,column:5}},line:11},3:{name:"(anonymous_3)",decl:{start:{line:27,column:25},end:{line:27,column:26}},loc:{start:{line:27,column:31},end:{line:27,column:74}},line:27},4:{name:"(anonymous_4)",decl:{start:{line:38,column:40},end:{line:38,column:41}},loc:{start:{line:38,column:50},end:{line:40,column:5}},line:38}},branchMap:{0:{loc:{start:{line:13,column:6},end:{line:35,column:7}},type:"if",locations:[{start:{line:13,column:6},end:{line:35,column:7}},{start:{line:33,column:13},end:{line:35,column:7}}],line:13},1:{loc:{start:{line:13,column:10},end:{line:13,column:55}},type:"binary-expr",locations:[{start:{line:13,column:10},end:{line:13,column:22}},{start:{line:13,column:26},end:{line:13,column:55}}],line:13},2:{loc:{start:{line:21,column:10},end:{line:31,column:14}},type:"binary-expr",locations:[{start:{line:21,column:10},end:{line:21,column:50}},{start:{line:21,column:70},end:{line:31,column:14}}],line:21}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/AppMessagePanel.tsx"],names:[],mappings:"AA2BkB,SAEJ,UAFI,KAEJ,YAFI;AA3BlB,OAAO,WAAW;AAClB,SAAQ,qBAAoB;AAY5B,qBAAqB,wBAAwB,MAAM,UAAgC;AAAA,EACjF,OAAO,eAAe;AAAA,IACpB,eAAe,MAAM;AAAA,IAAC;AAAA,EACxB;AAAA,EAEA,SAAS;AACP,UAAM,EAAC,mBAAkB,IAAI,KAAK;AAClC,UAAM,SAAS,KAAK,MAAM,QAAQ,IAAI,CAAC,OAAY,QAAQ;AACzD,UAAI;AACJ,UAAI,MAAM,UAAU,MAAM,OAAO,SAAS,SAAS;AACjD,cAAM,EAAC,OAAM,IAAI;AACjB,cAAM,UAAU,KAAK,MAAM,UAAU,OAAO,OAAO,KAAK,KAAK,EAAE;AAC/D,kBACE,iCAAE;AAAA;AAAA,UACM,oBAAC,UAAM,wBAAc,OAAO,GAAE;AAAA,UAAO;AAAA,UAAG,OAAO,KAAK;AAAA,UACzD,uBAAuB,OAAO,KAAK,SAClC,iCAAE;AAAA;AAAA,YAEA;AAAA,cAAC;AAAA;AAAA,gBACC,WAAU;AAAA,gBACV,SAAS,MAAM,KAAK,MAAM,cAAe,OAAO,KAAK,KAAK;AAAA,gBAC3D;AAAA;AAAA,YAED;AAAA,aACF;AAAA,WAEJ;AAAA,MAEJ,OACK;AACH,kBAAU,MAAM;AAAA,MAClB;AACA,aAAO,oBAAC,OAAqB,WAAU,gCACpC,qBADY,WAAS,GAExB;AAAA,IACF,CAAC;AAED,UAAM,QAAQ,KAAK,MAAM,OAAO,IAAI,CAAC,GAAG,MAAM;AAC5C,aAAO,oBAAC,OAAmB,eAAZ,UAAQ,CAAM;AAAA,IAC/B,CAAC;AAED,WAAO,qBAAC,SAAI,WAAU,0BACnB;AAAA;AAAA,MACA;AAAA,OACH;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"e5f88535075aece22d8ac3a6577a6cf140d2a75b"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return za=function(){return s},s}za();class tG extends bn.Component{render(){var i,o;za().f[1]++;const{selectedLayerIndex:n}=(za().s[1]++,this.props),t=(za().s[2]++,(i=this.props.errors)==null?void 0:i.map((s,a)=>{var g;za().f[2]++;let f;if(za().s[3]++,za().b[1][0]++,s.parsed&&(za().b[1][1]++,s.parsed.type==="layer")){za().b[0][0]++;const{parsed:x}=(za().s[4]++,s),k=(za().s[5]++,(g=this.props.mapStyle)==null?void 0:g.layers[x.data.index].id);za().s[6]++,f=N.jsxs(N.Fragment,{children:["Layer ",N.jsx("span",{children:XN(k)}),": ",x.data.message,(za().b[2][0]++,n!==x.data.index&&(za().b[2][1]++,N.jsxs(N.Fragment,{children:[" — ",N.jsx("button",{className:"maputnik-message-panel__switch-button",onClick:()=>(za().f[3]++,za().s[7]++,this.props.onLayerSelect(x.data.index)),children:"switch to layer"})]})))]})}else za().b[0][1]++,za().s[8]++,f=s.message;return za().s[9]++,N.jsx("p",{className:"maputnik-message-panel-error",children:f},"error-"+a)})),r=(za().s[10]++,(o=this.props.infos)==null?void 0:o.map((s,a)=>(za().f[4]++,za().s[11]++,N.jsx("p",{children:s},"info-"+a))));return za().s[12]++,N.jsxs("div",{className:"maputnik-message-panel",children:[t,r]})}}nn(tG,"defaultProps",(za().s[0]++,{onLayerSelect:()=>{za().f[0]++}}));function h4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldArray.tsx",n="a416dfabb7eaa48bd0505cf98cb9c66326bca3ec",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldArray.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:165}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldArray.tsx"],names:[],mappings:"AAcM;AAdN,OAAO,WAAW;AAClB,OAAO,gBAAwD;AAC/D,OAAO,cAAc;AASrB,qBAAqB,mBAAmB,MAAM,UAA2B;AAAA,EACvE,SAAS;AACP,WAAO,oBAAC,YAAS,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WAC9D,8BAAC,cAAY,GAAG,KAAK,OAAO,GAC9B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a416dfabb7eaa48bd0505cf98cb9c66326bca3ec"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return h4=function(){return s},s}h4();class f4 extends bn.Component{render(){return h4().f[0]++,h4().s[0]++,N.jsx(E_,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx(NN,{...this.props})})}}function p4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldNumber.tsx",n="4931f85d3ebf1a60a85ac9883e78e028b7a388d8",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldNumber.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:163}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldNumber.tsx"],names:[],mappings:"AAgBM;AAhBN,OAAO,WAAW;AAClB,OAAO,iBAAqC;AAC5C,OAAO,WAAW;AAWlB,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,SAAS;AACP,WAAO,oBAAC,SAAM,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WAC3D,8BAAC,eAAa,GAAG,KAAK,OAAO,GAC/B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"4931f85d3ebf1a60a85ac9883e78e028b7a388d8"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return p4=function(){return s},s}p4();class lp extends bn.Component{render(){return p4().f[0]++,p4().s[0]++,N.jsx(Uo,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx(pf,{...this.props})})}}function m4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldUrl.tsx",n="a176a83ddcea7ca7f45b0bf957355a9e0c40a3af",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldUrl.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:160}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldUrl.tsx"],names:[],mappings:"AAiBQ;AAjBR,OAAO,WAAW;AAClB,OAAO,cAAgD;AACvD,OAAO,WAAW;AAWlB,qBAAqB,iBAAiB,MAAM,UAAyB;AAAA,EACnE,SAAU;AACR,WACE,oBAAC,SAAM,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WACpD,8BAAC,YAAU,GAAG,KAAK,OAAO,GAC5B;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a176a83ddcea7ca7f45b0bf957355a9e0c40a3af"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return m4=function(){return s},s}m4();class O_ extends bn.Component{render(){return m4().f[0]++,m4().s[0]++,N.jsx(Uo,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx(Y8,{...this.props})})}}function g4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldSelect.tsx",n="ed4136288b91381a6bd6755cdb2ea1dcf45e2f6b",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldSelect.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:163}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldSelect.tsx"],names:[],mappings:"AAgBM;AAhBN,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,iBAAqC;AAW5C,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,SAAS;AACP,WAAO,oBAAC,SAAM,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WAC3D,8BAAC,eAAa,GAAG,KAAK,OAAM,GAC9B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"ed4136288b91381a6bd6755cdb2ea1dcf45e2f6b"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return g4=function(){return s},s}g4();class V8 extends bn.Component{render(){return g4().f[0]++,g4().s[0]++,N.jsx(Uo,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx(w1,{...this.props})})}}function y4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldEnum.tsx",n="5745e67ee75c0f352c022256ef8bf31e8fa7367f",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldEnum.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:164}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldEnum.tsx"],names:[],mappings:"AAgBM;AAhBN,OAAO,WAAW;AAClB,OAAO,eAAiC;AACxC,OAAO,cAAc;AAWrB,qBAAqB,kBAAkB,MAAM,UAA0B;AAAA,EACrE,SAAS;AACP,WAAO,oBAAC,YAAS,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WAC9D,8BAAC,aAAW,GAAG,KAAK,OAAO,GAC7B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"5745e67ee75c0f352c022256ef8bf31e8fa7367f"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return y4=function(){return s},s}y4();class fEe extends bn.Component{render(){return y4().f[0]++,y4().s[0]++,N.jsx(E_,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx($8,{...this.props})})}}function v4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldColor.tsx",n="4d9e98bd5e7819496a7ef6b66981b81e318fe1bf",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldColor.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:162}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldColor.tsx"],names:[],mappings:"AAgBM;AAhBN,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,gBAAmC;AAW1C,qBAAqB,mBAAmB,MAAM,UAA2B;AAAA,EACvE,SAAS;AACP,WAAO,oBAAC,SAAM,OAAO,KAAK,MAAM,OAAO,WAAW,KAAK,MAAM,WAC3D,8BAAC,cAAY,GAAG,KAAK,OAAO,GAC9B;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"4d9e98bd5e7819496a7ef6b66981b81e318fe1bf"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return v4=function(){return s},s}v4();class pEe extends bn.Component{render(){return v4().f[0]++,v4().s[0]++,N.jsx(Uo,{label:this.props.label,fieldSpec:this.props.fieldSpec,children:N.jsx(WN,{...this.props})})}}function H8(){var e="/home/runner/work/maputnik/maputnik/src/libs/field-spec-additional.ts",n="97a1ce3b1515c5a2f7a23d6b76358b8fb48705ec",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/field-spec-additional.ts",statementMap:{0:{start:{line:1,column:13},end:{line:16,column:1}}},fnMap:{},branchMap:{},s:{0:0},f:{},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/field-spec-additional.ts"],names:[],mappings:"AAAA,MAAM,OAAO;AAAA,EACX,UAAU;AAAA,IACR,uBAAuB;AAAA,MACrB,OAAO;AAAA,MACP,KAAK;AAAA,IACP;AAAA,IACA,4BAA4B;AAAA,MAC1B,OAAO;AAAA,MACP,KAAK;AAAA,IACP;AAAA,IACA,gBAAgB;AAAA,MACd,OAAO;AAAA,MACP,KAAK;AAAA,IACP;AAAA,EACF;AACF;AAEA,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"97a1ce3b1515c5a2f7a23d6b76358b8fb48705ec"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return H8=function(){return s},s}H8();const Yh=(H8().s[0]++,{maputnik:{maptiler_access_token:{label:"MapTiler Access Token",doc:"Public access token for MapTiler Cloud."},thunderforest_access_token:{label:"Thunderforest Access Token",doc:"Public access token for Thunderforest services."},style_renderer:{label:"Style Renderer",doc:"Choose the default Maputnik renderer for this style."}}});function oi(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalSettings.tsx",n="b694e94f243a11fbdf621abee61c98955da7068f",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalSettings.tsx",statementMap:{0:{start:{line:15,column:23},end:{line:17,column:5}},1:{start:{line:18,column:4},end:{line:22,column:5}},2:{start:{line:19,column:6},end:{line:19,column:34}},3:{start:{line:21,column:6},end:{line:21,column:35}},4:{start:{line:23,column:4},end:{line:26,column:7}},5:{start:{line:29,column:18},end:{line:31,column:5}},6:{start:{line:32,column:4},end:{line:36,column:5}},7:{start:{line:33,column:6},end:{line:33,column:29}},8:{start:{line:35,column:6},end:{line:35,column:30}},9:{start:{line:37,column:4},end:{line:40,column:7}},10:{start:{line:43,column:20},end:{line:45,column:5}},11:{start:{line:46,column:4},end:{line:50,column:5}},12:{start:{line:47,column:6},end:{line:47,column:31}},13:{start:{line:49,column:6},end:{line:49,column:32}},14:{start:{line:51,column:4},end:{line:54,column:7}},15:{start:{line:57,column:25},end:{line:59,column:5}},16:{start:{line:60,column:4},end:{line:64,column:5}},17:{start:{line:61,column:6},end:{line:61,column:36}},18:{start:{line:63,column:6},end:{line:63,column:37}},19:{start:{line:65,column:4},end:{line:65,column:44}},20:{start:{line:68,column:21},end:{line:68,column:55}},21:{start:{line:69,column:51},end:{line:69,column:61}},22:{start:{line:70,column:18},end:{line:70,column:49}},23:{start:{line:71,column:23},end:{line:71,column:59}},24:{start:{line:72,column:20},end:{line:72,column:53}},25:{start:{line:73,column:4},end:{line:283,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:44},end:{line:27,column:3}},line:14},1:{name:"(anonymous_1)",decl:{start:{line:28,column:2},end:{line:28,column:3}},loc:{start:{line:28,column:39},end:{line:41,column:3}},line:28},2:{name:"(anonymous_2)",decl:{start:{line:42,column:2},end:{line:42,column:3}},loc:{start:{line:42,column:41},end:{line:55,column:3}},line:42},3:{name:"(anonymous_3)",decl:{start:{line:56,column:2},end:{line:56,column:3}},loc:{start:{line:56,column:39},end:{line:66,column:3}},line:56},4:{name:"(anonymous_4)",decl:{start:{line:67,column:2},end:{line:67,column:3}},loc:{start:{line:67,column:11},end:{line:284,column:3}},line:67}},branchMap:{0:{loc:{start:{line:18,column:4},end:{line:22,column:5}},type:"if",locations:[{start:{line:18,column:4},end:{line:22,column:5}},{start:{line:20,column:11},end:{line:22,column:5}}],line:18},1:{loc:{start:{line:32,column:4},end:{line:36,column:5}},type:"if",locations:[{start:{line:32,column:4},end:{line:36,column:5}},{start:{line:34,column:11},end:{line:36,column:5}}],line:32},2:{loc:{start:{line:46,column:4},end:{line:50,column:5}},type:"if",locations:[{start:{line:46,column:4},end:{line:50,column:5}},{start:{line:48,column:11},end:{line:50,column:5}}],line:46},3:{loc:{start:{line:60,column:4},end:{line:64,column:5}},type:"if",locations:[{start:{line:60,column:4},end:{line:64,column:5}},{start:{line:62,column:11},end:{line:64,column:5}}],line:60},4:{loc:{start:{line:68,column:21},end:{line:68,column:55}},type:"binary-expr",locations:[{start:{line:68,column:21},end:{line:68,column:49}},{start:{line:68,column:53},end:{line:68,column:55}}],line:68},5:{loc:{start:{line:70,column:18},end:{line:70,column:49}},type:"binary-expr",locations:[{start:{line:70,column:18},end:{line:70,column:43}},{start:{line:70,column:47},end:{line:70,column:49}}],line:70},6:{loc:{start:{line:71,column:23},end:{line:71,column:59}},type:"binary-expr",locations:[{start:{line:71,column:23},end:{line:71,column:53}},{start:{line:71,column:57},end:{line:71,column:59}}],line:71},7:{loc:{start:{line:72,column:20},end:{line:72,column:53}},type:"binary-expr",locations:[{start:{line:72,column:20},end:{line:72,column:47}},{start:{line:72,column:51},end:{line:72,column:53}}],line:72},8:{loc:{start:{line:148,column:21},end:{line:148,column:42}},type:"binary-expr",locations:[{start:{line:148,column:21},end:{line:148,column:36}},{start:{line:148,column:40},end:{line:148,column:42}}],line:148},9:{loc:{start:{line:277,column:21},end:{line:277,column:62}},type:"binary-expr",locations:[{start:{line:277,column:21},end:{line:277,column:50}},{start:{line:277,column:54},end:{line:277,column:62}}],line:277}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalSettings.tsx"],names:[],mappings:"AA6GM,SACE,KADF;AA7GN,OAAO,WAAW;AAClB,OAAO,YAAY;AAGnB,OAAO,gBAAgB;AACvB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,cAAc;AACrB,OAAO,iBAAiB;AACxB,OAAO,eAAe;AACtB,OAAO,gBAAgB;AACvB,OAAO,WAAW;AAClB,OAAO,yBAAyB;AAUhC,qBAAqB,sBAAsB,MAAM,UAA8B;AAAA,EAC7E,yBAAyB,UAAyC,OAA2B;AAC3F,UAAM,aAAa;AAAA,MACjB,GAAG,KAAK,MAAM,SAAS;AAAA,IACzB;AAEA,QAAI,UAAU,QAAW;AACvB,aAAO,WAAW,QAAQ;AAAA,IAC5B,OACK;AACH,iBAAW,QAAQ,IAAI;AAAA,IACzB;AAEA,SAAK,MAAM,eAAe;AAAA,MACxB,GAAG,KAAK,MAAM;AAAA,MACd;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,oBAAoB,UAAoC,OAAY;AAClE,UAAM,QAAQ;AAAA,MACZ,GAAG,KAAK,MAAM,SAAS;AAAA,IACzB;AAEA,QAAI,UAAU,QAAW;AACvB,aAAO,MAAM,QAAQ;AAAA,IACvB,OACK;AAEH,YAAM,QAAQ,IAAI;AAAA,IACpB;AAEA,SAAK,MAAM,eAAe;AAAA,MACxB,GAAG,KAAK,MAAM;AAAA,MACd;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,sBAAsB,UAAsC,OAAY;AACtE,UAAM,UAAU;AAAA,MACd,GAAG,KAAK,MAAM,SAAS;AAAA,IACzB;AAEA,QAAI,UAAU,QAAW;AACvB,aAAO,QAAQ,QAAQ;AAAA,IACzB,OACK;AAEH,cAAQ,QAAQ,IAAI;AAAA,IACtB;AAEA,SAAK,MAAM,eAAe;AAAA,MACxB,GAAG,KAAK,MAAM;AAAA,MACd;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,oBAAoB,UAA8C,OAAY;AAC5E,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,IAChB;AAEA,QAAI,UAAU,QAAW;AAEvB,aAAO,aAAa,QAAQ;AAAA,IAC9B,OACK;AAEH,mBAAa,QAAQ,IAAI;AAAA,IAC3B;AACA,SAAK,MAAM,eAAe,YAAY;AAAA,EACxC;AAAA,EAEA,SAAS;AACP,UAAM,WAAW,KAAK,MAAM,SAAS,YAAY,CAAC;AAClD,UAAM,EAAC,0BAA0B,SAAQ,IAAI,KAAK;AAElD,UAAM,QAAQ,KAAK,MAAM,SAAS,SAAS,CAAC;AAC5C,UAAM,aAAa,KAAK,MAAM,SAAS,cAAc,CAAC;AACtD,UAAM,UAAU,KAAK,MAAM,SAAS,WAAW,CAAC;AAEhD,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAO;AAAA,QAEP,+BAAC,SAAI,WAAU,kBACb;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,eAAY;AAAA,cACZ,OAAO,KAAK,MAAM,SAAS;AAAA,cAC3B,UAAU,KAAK,oBAAoB,KAAK,MAAM,MAAM;AAAA;AAAA,UACtD;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,EAAC,KAAK,8DAA6D;AAAA,cAC9E,eAAY;AAAA,cACZ,OAAQ,KAAK,MAAM,SAAiB;AAAA,cACpC,UAAU,KAAK,oBAAoB,KAAK,MAAM,OAAO;AAAA;AAAA,UACvD;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,WAAW,OAAO,MAAM;AAAA,cACxB,OAAM;AAAA,cACN,eAAY;AAAA,cACZ,OAAO,KAAK,MAAM,SAAS;AAAA,cAC3B,UAAU,KAAK,oBAAoB,KAAK,MAAM,QAAQ;AAAA;AAAA,UACxD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAM;AAAA,cACN,WAAW,OAAO,MAAM;AAAA,cACxB,eAAY;AAAA,cACZ,OAAO,KAAK,MAAM,SAAS;AAAA,cAC3B,UAAU,KAAK,oBAAoB,KAAK,MAAM,QAAQ;AAAA;AAAA,UACxD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,oBAAoB,SAAS,sBAAsB;AAAA,cAC1D,WAAW,oBAAoB,SAAS;AAAA,cACxC,eAAY;AAAA,cACZ,OAAO,SAAS,oCAAoC;AAAA,cACpD,UAAU,yBAAyB,KAAK,MAAM,oCAAoC;AAAA;AAAA,UACpF;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,oBAAoB,SAAS,2BAA2B;AAAA,cAC/D,WAAW,oBAAoB,SAAS;AAAA,cACxC,eAAY;AAAA,cACZ,OAAO,SAAS,qCAAqC;AAAA,cACrD,UAAU,yBAAyB,KAAK,MAAM,qCAAqC;AAAA;AAAA,UACrF;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,QAAQ;AAAA,cACR,MAAK;AAAA,cACL,OAAO,SAAS,UAAU,CAAC;AAAA,cAC3B,SAAS,CAAC,GAAG,CAAC;AAAA,cACd,UAAU,KAAK,oBAAoB,KAAK,MAAM,QAAQ;AAAA;AAAA,UACxD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,OAAO,SAAS;AAAA,cAChB,SAAS;AAAA,cACT,UAAU,KAAK,oBAAoB,KAAK,MAAM,MAAM;AAAA;AAAA,UACtD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,OAAO,SAAS;AAAA,cAChB,SAAS,OAAO,MAAM,QAAQ;AAAA,cAC9B,UAAU,KAAK,oBAAoB,KAAK,MAAM,SAAS;AAAA;AAAA,UACzD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,OAAO,SAAS;AAAA,cAChB,SAAS,OAAO,MAAM,MAAM;AAAA,cAC5B,UAAU,KAAK,oBAAoB,KAAK,MAAM,OAAO;AAAA;AAAA,UACvD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,MAAK;AAAA,cACL,OAAO,MAAM;AAAA,cACb,SAAS,OAAO,KAAK,OAAO,MAAM,OAAO,MAAM;AAAA,cAC/C,SAAS,OAAO,MAAM,OAAO;AAAA,cAC7B,UAAU,KAAK,oBAAoB,KAAK,MAAM,QAAQ;AAAA;AAAA,UACxD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,OAAO,MAAM;AAAA,cACb,SAAS,OAAO,MAAM,MAAM;AAAA,cAC5B,UAAU,KAAK,oBAAoB,KAAK,MAAM,OAAO;AAAA;AAAA,UACvD;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,OAAO,MAAM;AAAA,cACb,SAAS,OAAO,MAAM,UAAU;AAAA,cAChC,UAAU,KAAK,oBAAoB,KAAK,MAAM,WAAW;AAAA;AAAA,UAC3D;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,MAAM;AAAA,cACxB,MAAK;AAAA,cACL,QAAQ,OAAO,MAAM,SAAS;AAAA,cAC9B,OAAO,MAAM;AAAA,cACb,SAAS,OAAO,MAAM,SAAS;AAAA,cAC/B,UAAU,KAAK,oBAAoB,KAAK,MAAM,UAAU;AAAA;AAAA,UAC1D;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,QAAQ;AAAA,cAC1B,eAAY;AAAA,cACZ,OAAO,QAAQ;AAAA,cACf,UAAU,KAAK,sBAAsB,KAAK,MAAM,QAAQ;AAAA;AAAA,UAC1D;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,QAAQ;AAAA,cAC1B,OAAO,QAAQ;AAAA,cACf,SAAS,OAAO,QAAQ,aAAa;AAAA,cACrC,UAAU,KAAK,sBAAsB,KAAK,MAAM,cAAc;AAAA;AAAA,UAChE;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,WAAW;AAAA,cAC7B,OAAO,WAAW;AAAA,cAClB,SAAS,OAAO,WAAW,MAAM;AAAA,cACjC,UAAU,KAAK,yBAAyB,KAAK,MAAM,OAAO;AAAA;AAAA,UAC5D;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO;AAAA,cACP,WAAW,OAAO,WAAW;AAAA,cAC7B,OAAO,WAAW;AAAA,cAClB,SAAS,OAAO,WAAW,SAAS;AAAA,cACpC,UAAU,KAAK,yBAAyB,KAAK,MAAM,UAAU;AAAA;AAAA,UAC/D;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACC,OAAO,oBAAoB,SAAS,eAAe;AAAA,cACnD,WAAW,oBAAoB,SAAS;AAAA,cACxC,eAAY;AAAA,cACZ,SAAS;AAAA,gBACP,CAAC,UAAU,eAAe;AAAA,gBAC1B,CAAC,MAAM,4BAA4B;AAAA,cACrC;AAAA,cACA,OAAO,SAAS,mBAAmB,KAAK;AAAA,cACxC,UAAU,yBAAyB,KAAK,MAAM,mBAAmB;AAAA;AAAA,UACnE;AAAA,WACF;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"b694e94f243a11fbdf621abee61c98955da7068f"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return oi=function(){return s},s}oi();class mEe extends bn.Component{changeTransitionProperty(n,t){oi().f[0]++;const r=(oi().s[0]++,{...this.props.mapStyle.transition});oi().s[1]++,t===void 0?(oi().b[0][0]++,oi().s[2]++,delete r[n]):(oi().b[0][1]++,oi().s[3]++,r[n]=t),oi().s[4]++,this.props.onStyleChanged({...this.props.mapStyle,transition:r})}changeLightProperty(n,t){oi().f[1]++;const r=(oi().s[5]++,{...this.props.mapStyle.light});oi().s[6]++,t===void 0?(oi().b[1][0]++,oi().s[7]++,delete r[n]):(oi().b[1][1]++,oi().s[8]++,r[n]=t),oi().s[9]++,this.props.onStyleChanged({...this.props.mapStyle,light:r})}changeTerrainProperty(n,t){oi().f[2]++;const r=(oi().s[10]++,{...this.props.mapStyle.terrain});oi().s[11]++,t===void 0?(oi().b[2][0]++,oi().s[12]++,delete r[n]):(oi().b[2][1]++,oi().s[13]++,r[n]=t),oi().s[14]++,this.props.onStyleChanged({...this.props.mapStyle,terrain:r})}changeStyleProperty(n,t){oi().f[3]++;const r=(oi().s[15]++,{...this.props.mapStyle});oi().s[16]++,t===void 0?(oi().b[3][0]++,oi().s[17]++,delete r[n]):(oi().b[3][1]++,oi().s[18]++,r[n]=t),oi().s[19]++,this.props.onStyleChanged(r)}render(){oi().f[4]++;const n=(oi().s[20]++,oi().b[4][0]++,this.props.mapStyle.metadata||(oi().b[4][1]++,{})),{onChangeMetadataProperty:t,mapStyle:r}=(oi().s[21]++,this.props),i=(oi().s[22]++,oi().b[5][0]++,this.props.mapStyle.light||(oi().b[5][1]++,{})),o=(oi().s[23]++,oi().b[6][0]++,this.props.mapStyle.transition||(oi().b[6][1]++,{})),s=(oi().s[24]++,oi().b[7][0]++,this.props.mapStyle.terrain||(oi().b[7][1]++,{}));return oi().s[25]++,N.jsx(_f,{"data-wd-key":"modal:settings",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Style Settings",children:N.jsxs("div",{className:"modal:settings",children:[N.jsx(uh,{label:"Name",fieldSpec:Ji.$root.name,"data-wd-key":"modal:settings.name",value:this.props.mapStyle.name,onChange:this.changeStyleProperty.bind(this,"name")}),N.jsx(uh,{label:"Owner",fieldSpec:{doc:"Owner ID of the style. Used by Mapbox or future style APIs."},"data-wd-key":"modal:settings.owner",value:this.props.mapStyle.owner,onChange:this.changeStyleProperty.bind(this,"owner")}),N.jsx(O_,{fieldSpec:Ji.$root.sprite,label:"Sprite URL","data-wd-key":"modal:settings.sprite",value:this.props.mapStyle.sprite,onChange:this.changeStyleProperty.bind(this,"sprite")}),N.jsx(O_,{label:"Glyphs URL",fieldSpec:Ji.$root.glyphs,"data-wd-key":"modal:settings.glyphs",value:this.props.mapStyle.glyphs,onChange:this.changeStyleProperty.bind(this,"glyphs")}),N.jsx(uh,{label:Yh.maputnik.maptiler_access_token.label,fieldSpec:Yh.maputnik.maptiler_access_token,"data-wd-key":"modal:settings.maputnik:openmaptiles_access_token",value:n["maputnik:openmaptiles_access_token"],onChange:t.bind(this,"maputnik:openmaptiles_access_token")}),N.jsx(uh,{label:Yh.maputnik.thunderforest_access_token.label,fieldSpec:Yh.maputnik.thunderforest_access_token,"data-wd-key":"modal:settings.maputnik:thunderforest_access_token",value:n["maputnik:thunderforest_access_token"],onChange:t.bind(this,"maputnik:thunderforest_access_token")}),N.jsx(f4,{label:"Center",fieldSpec:Ji.$root.center,length:2,type:"number",value:(oi().b[8][0]++,r.center||(oi().b[8][1]++,[])),default:[0,0],onChange:this.changeStyleProperty.bind(this,"center")}),N.jsx(lp,{label:"Zoom",fieldSpec:Ji.$root.zoom,value:r.zoom,default:0,onChange:this.changeStyleProperty.bind(this,"zoom")}),N.jsx(lp,{label:"Bearing",fieldSpec:Ji.$root.bearing,value:r.bearing,default:Ji.$root.bearing.default,onChange:this.changeStyleProperty.bind(this,"bearing")}),N.jsx(lp,{label:"Pitch",fieldSpec:Ji.$root.pitch,value:r.pitch,default:Ji.$root.pitch.default,onChange:this.changeStyleProperty.bind(this,"pitch")}),N.jsx(fEe,{label:"Light anchor",fieldSpec:Ji.light.anchor,name:"light-anchor",value:i.anchor,options:Object.keys(Ji.light.anchor.values),default:Ji.light.anchor.default,onChange:this.changeLightProperty.bind(this,"anchor")}),N.jsx(pEe,{label:"Light color",fieldSpec:Ji.light.color,value:i.color,default:Ji.light.color.default,onChange:this.changeLightProperty.bind(this,"color")}),N.jsx(lp,{label:"Light intensity",fieldSpec:Ji.light.intensity,value:i.intensity,default:Ji.light.intensity.default,onChange:this.changeLightProperty.bind(this,"intensity")}),N.jsx(f4,{label:"Light position",fieldSpec:Ji.light.position,type:"number",length:Ji.light.position.length,value:i.position,default:Ji.light.position.default,onChange:this.changeLightProperty.bind(this,"position")}),N.jsx(uh,{label:"Terrain source",fieldSpec:Ji.terrain.source,"data-wd-key":"modal:settings.maputnik:terrain_source",value:s.source,onChange:this.changeTerrainProperty.bind(this,"source")}),N.jsx(lp,{label:"Terrain exaggeration",fieldSpec:Ji.terrain.exaggeration,value:s.exaggeration,default:Ji.terrain.exaggeration.default,onChange:this.changeTerrainProperty.bind(this,"exaggeration")}),N.jsx(lp,{label:"Transition delay",fieldSpec:Ji.transition.delay,value:o.delay,default:Ji.transition.delay.default,onChange:this.changeTransitionProperty.bind(this,"delay")}),N.jsx(lp,{label:"Transition duration",fieldSpec:Ji.transition.duration,value:o.duration,default:Ji.transition.duration.default,onChange:this.changeTransitionProperty.bind(this,"duration")}),N.jsx(V8,{label:Yh.maputnik.style_renderer.label,fieldSpec:Yh.maputnik.style_renderer,"data-wd-key":"modal:settings.maputnik:renderer",options:[["mlgljs","MapLibreGL JS"],["ol","Open Layers (experimental)"]],value:(oi().b[9][0]++,n["maputnik:renderer"]||(oi().b[9][1]++,"mlgljs")),onChange:t.bind(this,"maputnik:renderer")})]})})}}var nG={exports:{}};(function(e,n){(function(t,r,i){e.exports=i(),e.exports.default=i()})("slugify",mf,function(){var t=JSON.parse(`{"$":"dollar","%":"percent","&":"and","<":"less",">":"greater","|":"or","¢":"cent","£":"pound","¤":"currency","¥":"yen","©":"(c)","ª":"a","®":"(r)","º":"o","À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","Æ":"AE","Ç":"C","È":"E","É":"E","Ê":"E","Ë":"E","Ì":"I","Í":"I","Î":"I","Ï":"I","Ð":"D","Ñ":"N","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","Ù":"U","Ú":"U","Û":"U","Ü":"U","Ý":"Y","Þ":"TH","ß":"ss","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","æ":"ae","ç":"c","è":"e","é":"e","ê":"e","ë":"e","ì":"i","í":"i","î":"i","ï":"i","ð":"d","ñ":"n","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","ù":"u","ú":"u","û":"u","ü":"u","ý":"y","þ":"th","ÿ":"y","Ā":"A","ā":"a","Ă":"A","ă":"a","Ą":"A","ą":"a","Ć":"C","ć":"c","Č":"C","č":"c","Ď":"D","ď":"d","Đ":"DJ","đ":"dj","Ē":"E","ē":"e","Ė":"E","ė":"e","Ę":"e","ę":"e","Ě":"E","ě":"e","Ğ":"G","ğ":"g","Ģ":"G","ģ":"g","Ĩ":"I","ĩ":"i","Ī":"i","ī":"i","Į":"I","į":"i","İ":"I","ı":"i","Ķ":"k","ķ":"k","Ļ":"L","ļ":"l","Ľ":"L","ľ":"l","Ł":"L","ł":"l","Ń":"N","ń":"n","Ņ":"N","ņ":"n","Ň":"N","ň":"n","Ō":"O","ō":"o","Ő":"O","ő":"o","Œ":"OE","œ":"oe","Ŕ":"R","ŕ":"r","Ř":"R","ř":"r","Ś":"S","ś":"s","Ş":"S","ş":"s","Š":"S","š":"s","Ţ":"T","ţ":"t","Ť":"T","ť":"t","Ũ":"U","ũ":"u","Ū":"u","ū":"u","Ů":"U","ů":"u","Ű":"U","ű":"u","Ų":"U","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","ź":"z","Ż":"Z","ż":"z","Ž":"Z","ž":"z","Ə":"E","ƒ":"f","Ơ":"O","ơ":"o","Ư":"U","ư":"u","Lj":"LJ","lj":"lj","Nj":"NJ","nj":"nj","Ș":"S","ș":"s","Ț":"T","ț":"t","ə":"e","˚":"o","Ά":"A","Έ":"E","Ή":"H","Ί":"I","Ό":"O","Ύ":"Y","Ώ":"W","ΐ":"i","Α":"A","Β":"B","Γ":"G","Δ":"D","Ε":"E","Ζ":"Z","Η":"H","Θ":"8","Ι":"I","Κ":"K","Λ":"L","Μ":"M","Ν":"N","Ξ":"3","Ο":"O","Π":"P","Ρ":"R","Σ":"S","Τ":"T","Υ":"Y","Φ":"F","Χ":"X","Ψ":"PS","Ω":"W","Ϊ":"I","Ϋ":"Y","ά":"a","έ":"e","ή":"h","ί":"i","ΰ":"y","α":"a","β":"b","γ":"g","δ":"d","ε":"e","ζ":"z","η":"h","θ":"8","ι":"i","κ":"k","λ":"l","μ":"m","ν":"n","ξ":"3","ο":"o","π":"p","ρ":"r","ς":"s","σ":"s","τ":"t","υ":"y","φ":"f","χ":"x","ψ":"ps","ω":"w","ϊ":"i","ϋ":"y","ό":"o","ύ":"y","ώ":"w","Ё":"Yo","Ђ":"DJ","Є":"Ye","І":"I","Ї":"Yi","Ј":"J","Љ":"LJ","Њ":"NJ","Ћ":"C","Џ":"DZ","А":"A","Б":"B","В":"V","Г":"G","Д":"D","Е":"E","Ж":"Zh","З":"Z","И":"I","Й":"J","К":"K","Л":"L","М":"M","Н":"N","О":"O","П":"P","Р":"R","С":"S","Т":"T","У":"U","Ф":"F","Х":"H","Ц":"C","Ч":"Ch","Ш":"Sh","Щ":"Sh","Ъ":"U","Ы":"Y","Ь":"","Э":"E","Ю":"Yu","Я":"Ya","а":"a","б":"b","в":"v","г":"g","д":"d","е":"e","ж":"zh","з":"z","и":"i","й":"j","к":"k","л":"l","м":"m","н":"n","о":"o","п":"p","р":"r","с":"s","т":"t","у":"u","ф":"f","х":"h","ц":"c","ч":"ch","ш":"sh","щ":"sh","ъ":"u","ы":"y","ь":"","э":"e","ю":"yu","я":"ya","ё":"yo","ђ":"dj","є":"ye","і":"i","ї":"yi","ј":"j","љ":"lj","њ":"nj","ћ":"c","ѝ":"u","џ":"dz","Ґ":"G","ґ":"g","Ғ":"GH","ғ":"gh","Қ":"KH","қ":"kh","Ң":"NG","ң":"ng","Ү":"UE","ү":"ue","Ұ":"U","ұ":"u","Һ":"H","һ":"h","Ә":"AE","ә":"ae","Ө":"OE","ө":"oe","Ա":"A","Բ":"B","Գ":"G","Դ":"D","Ե":"E","Զ":"Z","Է":"E'","Ը":"Y'","Թ":"T'","Ժ":"JH","Ի":"I","Լ":"L","Խ":"X","Ծ":"C'","Կ":"K","Հ":"H","Ձ":"D'","Ղ":"GH","Ճ":"TW","Մ":"M","Յ":"Y","Ն":"N","Շ":"SH","Չ":"CH","Պ":"P","Ջ":"J","Ռ":"R'","Ս":"S","Վ":"V","Տ":"T","Ր":"R","Ց":"C","Փ":"P'","Ք":"Q'","Օ":"O''","Ֆ":"F","և":"EV","ء":"a","آ":"aa","أ":"a","ؤ":"u","إ":"i","ئ":"e","ا":"a","ب":"b","ة":"h","ت":"t","ث":"th","ج":"j","ح":"h","خ":"kh","د":"d","ذ":"th","ر":"r","ز":"z","س":"s","ش":"sh","ص":"s","ض":"dh","ط":"t","ظ":"z","ع":"a","غ":"gh","ف":"f","ق":"q","ك":"k","ل":"l","م":"m","ن":"n","ه":"h","و":"w","ى":"a","ي":"y","ً":"an","ٌ":"on","ٍ":"en","َ":"a","ُ":"u","ِ":"e","ْ":"","٠":"0","١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","پ":"p","چ":"ch","ژ":"zh","ک":"k","گ":"g","ی":"y","۰":"0","۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9","฿":"baht","ა":"a","ბ":"b","გ":"g","დ":"d","ე":"e","ვ":"v","ზ":"z","თ":"t","ი":"i","კ":"k","ლ":"l","მ":"m","ნ":"n","ო":"o","პ":"p","ჟ":"zh","რ":"r","ს":"s","ტ":"t","უ":"u","ფ":"f","ქ":"k","ღ":"gh","ყ":"q","შ":"sh","ჩ":"ch","ც":"ts","ძ":"dz","წ":"ts","ჭ":"ch","ხ":"kh","ჯ":"j","ჰ":"h","Ṣ":"S","ṣ":"s","Ẁ":"W","ẁ":"w","Ẃ":"W","ẃ":"w","Ẅ":"W","ẅ":"w","ẞ":"SS","Ạ":"A","ạ":"a","Ả":"A","ả":"a","Ấ":"A","ấ":"a","Ầ":"A","ầ":"a","Ẩ":"A","ẩ":"a","Ẫ":"A","ẫ":"a","Ậ":"A","ậ":"a","Ắ":"A","ắ":"a","Ằ":"A","ằ":"a","Ẳ":"A","ẳ":"a","Ẵ":"A","ẵ":"a","Ặ":"A","ặ":"a","Ẹ":"E","ẹ":"e","Ẻ":"E","ẻ":"e","Ẽ":"E","ẽ":"e","Ế":"E","ế":"e","Ề":"E","ề":"e","Ể":"E","ể":"e","Ễ":"E","ễ":"e","Ệ":"E","ệ":"e","Ỉ":"I","ỉ":"i","Ị":"I","ị":"i","Ọ":"O","ọ":"o","Ỏ":"O","ỏ":"o","Ố":"O","ố":"o","Ồ":"O","ồ":"o","Ổ":"O","ổ":"o","Ỗ":"O","ỗ":"o","Ộ":"O","ộ":"o","Ớ":"O","ớ":"o","Ờ":"O","ờ":"o","Ở":"O","ở":"o","Ỡ":"O","ỡ":"o","Ợ":"O","ợ":"o","Ụ":"U","ụ":"u","Ủ":"U","ủ":"u","Ứ":"U","ứ":"u","Ừ":"U","ừ":"u","Ử":"U","ử":"u","Ữ":"U","ữ":"u","Ự":"U","ự":"u","Ỳ":"Y","ỳ":"y","Ỵ":"Y","ỵ":"y","Ỷ":"Y","ỷ":"y","Ỹ":"Y","ỹ":"y","–":"-","‘":"'","’":"'","“":"\\"","”":"\\"","„":"\\"","†":"+","•":"*","…":"...","₠":"ecu","₢":"cruzeiro","₣":"french franc","₤":"lira","₥":"mill","₦":"naira","₧":"peseta","₨":"rupee","₩":"won","₪":"new shequel","₫":"dong","€":"euro","₭":"kip","₮":"tugrik","₯":"drachma","₰":"penny","₱":"peso","₲":"guarani","₳":"austral","₴":"hryvnia","₵":"cedi","₸":"kazakhstani tenge","₹":"indian rupee","₺":"turkish lira","₽":"russian ruble","₿":"bitcoin","℠":"sm","™":"tm","∂":"d","∆":"delta","∑":"sum","∞":"infinity","♥":"love","元":"yuan","円":"yen","﷼":"rial","ﻵ":"laa","ﻷ":"laa","ﻹ":"lai","ﻻ":"la"}`),r=JSON.parse('{"bg":{"Й":"Y","Ц":"Ts","Щ":"Sht","Ъ":"A","Ь":"Y","й":"y","ц":"ts","щ":"sht","ъ":"a","ь":"y"},"de":{"Ä":"AE","ä":"ae","Ö":"OE","ö":"oe","Ü":"UE","ü":"ue","ß":"ss","%":"prozent","&":"und","|":"oder","∑":"summe","∞":"unendlich","♥":"liebe"},"es":{"%":"por ciento","&":"y","<":"menor que",">":"mayor que","|":"o","¢":"centavos","£":"libras","¤":"moneda","₣":"francos","∑":"suma","∞":"infinito","♥":"amor"},"fr":{"%":"pourcent","&":"et","<":"plus petit",">":"plus grand","|":"ou","¢":"centime","£":"livre","¤":"devise","₣":"franc","∑":"somme","∞":"infini","♥":"amour"},"pt":{"%":"porcento","&":"e","<":"menor",">":"maior","|":"ou","¢":"centavo","∑":"soma","£":"libra","∞":"infinito","♥":"amor"},"uk":{"И":"Y","и":"y","Й":"Y","й":"y","Ц":"Ts","ц":"ts","Х":"Kh","х":"kh","Щ":"Shch","щ":"shch","Г":"H","г":"h"},"vi":{"Đ":"D","đ":"d"},"da":{"Ø":"OE","ø":"oe","Å":"AA","å":"aa","%":"procent","&":"og","|":"eller","$":"dollar","<":"mindre end",">":"større end"},"nb":{"&":"og","Å":"AA","Æ":"AE","Ø":"OE","å":"aa","æ":"ae","ø":"oe"},"it":{"&":"e"},"nl":{"&":"en"},"sv":{"&":"och","Å":"AA","Ä":"AE","Ö":"OE","å":"aa","ä":"ae","ö":"oe"}}');function i(o,s){if(typeof o!="string")throw new Error("slugify: string argument expected");s=typeof s=="string"?{replacement:s}:s||{};var a=r[s.locale]||{},f=s.replacement===void 0?"-":s.replacement,g=s.trim===void 0?!0:s.trim,x=o.normalize().split("").reduce(function(k,B){var P=a[B];return P===void 0&&(P=t[B]),P===void 0&&(P=B),P===f&&(P=" "),k+P.replace(s.remove||/[^\w\s$*_+~.()'"!\-:@]+/g,"")},"");return s.strict&&(x=x.replace(/[^A-Za-z0-9\s]/g,"")),g&&(x=x.trim()),x=x.replace(/\s+/g,f),s.lower&&(x=x.toLowerCase()),x}return i.extend=function(o){Object.assign(t,o)},i})})(nG);var gEe=nG.exports;const yEe=ga(gEe);var rG={exports:{}};(function(e,n){(function(t,r){r()})(mf,function(){function t(g,x){return typeof x>"u"?x={autoBom:!1}:typeof x!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),x={autoBom:!x}),x.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(g.type)?new Blob(["\uFEFF",g],{type:g.type}):g}function r(g,x,k){var B=new XMLHttpRequest;B.open("GET",g),B.responseType="blob",B.onload=function(){f(B.response,x,k)},B.onerror=function(){console.error("could not download file")},B.send()}function i(g){var x=new XMLHttpRequest;x.open("HEAD",g,!1);try{x.send()}catch{}return 200<=x.status&&299>=x.status}function o(g){try{g.dispatchEvent(new MouseEvent("click"))}catch{var x=document.createEvent("MouseEvents");x.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),g.dispatchEvent(x)}}var s=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof window=="object"&&window.global===window?window:void 0,a=s.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),f=s.saveAs||(typeof window!="object"||window!==s?function(){}:"download"in HTMLAnchorElement.prototype&&!a?function(g,x,k){var B=s.URL||s.webkitURL,P=document.createElement("a");x=x||g.name||"download",P.download=x,P.rel="noopener",typeof g=="string"?(P.href=g,P.origin===location.origin?o(P):i(P.href)?r(g,x,k):o(P,P.target="_blank")):(P.href=B.createObjectURL(g),setTimeout(function(){B.revokeObjectURL(P.href)},4e4),setTimeout(function(){o(P)},0))}:"msSaveOrOpenBlob"in navigator?function(g,x,k){if(x=x||g.name||"download",typeof g!="string")navigator.msSaveOrOpenBlob(t(g,k),x);else if(i(g))r(g,x,k);else{var B=document.createElement("a");B.href=g,B.target="_blank",setTimeout(function(){o(B)})}}:function(g,x,k,B){if(B=B||open("","_blank"),B&&(B.document.title=B.document.body.innerText="downloading..."),typeof g=="string")return r(g,x,k);var P=g.type==="application/octet-stream",R=/constructor/i.test(s.HTMLElement)||s.safari,H=/CriOS\/[\d]+/.test(navigator.userAgent);if((H||P&&R||a)&&typeof FileReader<"u"){var W=new FileReader;W.onloadend=function(){var oe=W.result;oe=H?oe:oe.replace(/^data:[^;]*;/,"data:attachment/file;"),B?B.location.href=oe:location=oe,B=null},W.readAsDataURL(g)}else{var $=s.URL||s.webkitURL,q=$.createObjectURL(g);B?B.location=q:location.href=q,B=null,setTimeout(function(){$.revokeObjectURL(q)},4e4)}});s.saveAs=f.saveAs=f,e.exports=f})})(rG);var bP=rG.exports;const vEe="4.0.0-pre.4",CEe="get_your_own_OpIi9ZULNHzrESv6T2vL",_Ee="b71f7f0ba4064f5eb9e903859a9cf5c6",iG={openmaptiles:CEe,thunderforest:_Ee};function Rn(){var e="/home/runner/work/maputnik/maputnik/src/libs/style.ts",n="90dcc82dd58ae44e1faf5283c5a3a70c09f07bf2",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/style.ts",statementMap:{0:{start:{line:3,column:19},end:{line:7,column:2}},1:{start:{line:9,column:2},end:{line:9,column:52}},2:{start:{line:12,column:2},end:{line:15,column:3}},3:{start:{line:13,column:4},end:{line:13,column:28}},4:{start:{line:14,column:4},end:{line:14,column:17}},5:{start:{line:16,column:2},end:{line:16,column:15}},6:{start:{line:19,column:24},end:{line:23,column:4}},7:{start:{line:20,column:25},end:{line:20,column:37}},8:{start:{line:21,column:4},end:{line:21,column:36}},9:{start:{line:22,column:4},end:{line:22,column:24}},10:{start:{line:24,column:2},end:{line:27,column:4}},11:{start:{line:30,column:2},end:{line:33,column:4}},12:{start:{line:36,column:2},end:{line:36,column:69}},13:{start:{line:39,column:2},end:{line:43,column:3}},14:{start:{line:39,column:15},end:{line:39,column:16}},15:{start:{line:40,column:4},end:{line:42,column:5}},16:{start:{line:41,column:6},end:{line:41,column:15}},17:{start:{line:44,column:2},end:{line:44,column:14}},18:{start:{line:47,column:2},end:{line:49,column:3}},19:{start:{line:48,column:4},end:{line:48,column:33}},20:{start:{line:50,column:19},end:{line:50,column:42}},21:{start:{line:51,column:20},end:{line:51,column:67}},22:{start:{line:52,column:2},end:{line:54,column:3}},23:{start:{line:53,column:4},end:{line:53,column:37}},24:{start:{line:55,column:2},end:{line:55,column:21}},25:{start:{line:58,column:17},end:{line:58,column:45}},26:{start:{line:59,column:2},end:{line:60,column:20}},27:{start:{line:60,column:4},end:{line:60,column:20}},28:{start:{line:61,column:2},end:{line:62,column:20}},29:{start:{line:62,column:4},end:{line:62,column:20}},30:{start:{line:63,column:22},end:{line:63,column:64}},31:{start:{line:64,column:2},end:{line:66,column:3}},32:{start:{line:65,column:4},end:{line:65,column:20}},33:{start:{line:67,column:25},end:{line:73,column:3}},34:{start:{line:74,column:23},end:{line:77,column:3}},35:{start:{line:78,column:2},end:{line:78,column:22}},36:{start:{line:81,column:21},end:{line:81,column:29}},37:{start:{line:82,column:2},end:{line:84,column:5}},38:{start:{line:83,column:4},end:{line:83,column:76}},39:{start:{line:85,column:2},end:{line:93,column:3}},40:{start:{line:86,column:27},end:{line:86,column:73}},41:{start:{line:87,column:4},end:{line:92,column:5}},42:{start:{line:88,column:6},end:{line:91,column:8}},43:{start:{line:94,column:2},end:{line:94,column:22}},44:{start:{line:97,column:26},end:{line:99,column:3}},45:{start:{line:100,column:2},end:{line:100,column:63}},46:{start:{line:101,column:2},end:{line:104,column:4}}},fnMap:{0:{name:"generateId",decl:{start:{line:8,column:9},end:{line:8,column:19}},loc:{start:{line:8,column:22},end:{line:10,column:1}},line:8},1:{name:"ensureHasId",decl:{start:{line:11,column:9},end:{line:11,column:20}},loc:{start:{line:11,column:28},end:{line:17,column:1}},line:11},2:{name:"ensureHasNoInteractive",decl:{start:{line:18,column:9},end:{line:18,column:31}},loc:{start:{line:18,column:39},end:{line:28,column:1}},line:18},3:{name:"(anonymous_3)",decl:{start:{line:19,column:41},end:{line:19,column:42}},loc:{start:{line:19,column:52},end:{line:23,column:3}},line:19},4:{name:"ensureHasNoRefs",decl:{start:{line:29,column:9},end:{line:29,column:24}},loc:{start:{line:29,column:32},end:{line:34,column:1}},line:29},5:{name:"ensureStyleValidity",decl:{start:{line:35,column:9},end:{line:35,column:28}},loc:{start:{line:35,column:36},end:{line:37,column:1}},line:35},6:{name:"indexOfLayer",decl:{start:{line:38,column:9},end:{line:38,column:21}},loc:{start:{line:38,column:39},end:{line:45,column:1}},line:38},7:{name:"getAccessToken",decl:{start:{line:46,column:9},end:{line:46,column:23}},loc:{start:{line:46,column:52},end:{line:56,column:1}},line:46},8:{name:"replaceSourceAccessToken",decl:{start:{line:57,column:9},end:{line:57,column:33}},loc:{start:{line:57,column:67},end:{line:79,column:1}},line:57},9:{name:"replaceAccessTokens",decl:{start:{line:80,column:9},end:{line:80,column:28}},loc:{start:{line:80,column:50},end:{line:95,column:1}},line:80},10:{name:"(anonymous_10)",decl:{start:{line:82,column:40},end:{line:82,column:41}},loc:{start:{line:82,column:56},end:{line:84,column:3}},line:82},11:{name:"stripAccessTokens",decl:{start:{line:96,column:9},end:{line:96,column:26}},loc:{start:{line:96,column:37},end:{line:105,column:1}},line:96}},branchMap:{0:{loc:{start:{line:12,column:2},end:{line:15,column:3}},type:"if",locations:[{start:{line:12,column:2},end:{line:15,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:12},1:{loc:{start:{line:12,column:6},end:{line:12,column:35}},type:"binary-expr",locations:[{start:{line:12,column:6},end:{line:12,column:22}},{start:{line:12,column:26},end:{line:12,column:35}}],line:12},2:{loc:{start:{line:40,column:4},end:{line:42,column:5}},type:"if",locations:[{start:{line:40,column:4},end:{line:42,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:40},3:{loc:{start:{line:47,column:2},end:{line:49,column:3}},type:"if",locations:[{start:{line:47,column:2},end:{line:49,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:47},4:{loc:{start:{line:47,column:6},end:{line:47,column:89}},type:"binary-expr",locations:[{start:{line:47,column:6},end:{line:47,column:46}},{start:{line:47,column:50},end:{line:47,column:89}}],line:47},5:{loc:{start:{line:50,column:19},end:{line:50,column:42}},type:"binary-expr",locations:[{start:{line:50,column:19},end:{line:50,column:36}},{start:{line:50,column:40},end:{line:50,column:42}}],line:50},6:{loc:{start:{line:52,column:2},end:{line:54,column:3}},type:"if",locations:[{start:{line:52,column:2},end:{line:54,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:52},7:{loc:{start:{line:52,column:6},end:{line:52,column:40}},type:"binary-expr",locations:[{start:{line:52,column:6},end:{line:52,column:24}},{start:{line:52,column:28},end:{line:52,column:40}}],line:52},8:{loc:{start:{line:57,column:56},end:{line:57,column:65}},type:"default-arg",locations:[{start:{line:57,column:63},end:{line:57,column:65}}],line:57},9:{loc:{start:{line:59,column:2},end:{line:60,column:20}},type:"if",locations:[{start:{line:59,column:2},end:{line:60,column:20}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:59},10:{loc:{start:{line:61,column:2},end:{line:62,column:20}},type:"if",locations:[{start:{line:61,column:2},end:{line:62,column:20}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:61},11:{loc:{start:{line:61,column:6},end:{line:61,column:39}},type:"binary-expr",locations:[{start:{line:61,column:6},end:{line:61,column:24}},{start:{line:61,column:28},end:{line:61,column:39}}],line:61},12:{loc:{start:{line:64,column:2},end:{line:66,column:3}},type:"if",locations:[{start:{line:64,column:2},end:{line:66,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:64},13:{loc:{start:{line:80,column:39},end:{line:80,column:48}},type:"default-arg",locations:[{start:{line:80,column:46},end:{line:80,column:48}}],line:80},14:{loc:{start:{line:85,column:2},end:{line:93,column:3}},type:"if",locations:[{start:{line:85,column:2},end:{line:93,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:85},15:{loc:{start:{line:85,column:6},end:{line:85,column:114}},type:"binary-expr",locations:[{start:{line:85,column:6},end:{line:85,column:21}},{start:{line:85,column:26},end:{line:85,column:69}},{start:{line:85,column:73},end:{line:85,column:113}}],line:85},16:{loc:{start:{line:87,column:4},end:{line:92,column:5}},type:"if",locations:[{start:{line:87,column:4},end:{line:92,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:87}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0],14:[0,0],15:[0,0,0],16:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/style.ts"],names:[],mappings:"AAAA,SAAQ,mBAAkB;AAE1B,OAAO,YAAY;AAGnB,MAAM,aAAa,oBAAoB;AAAA,EACrC,SAAS;AAAA,EACT,SAAS,CAAC;AAAA,EACV,QAAQ,CAAC;AACX,CAAC;AAED,SAAS,aAAa;AACpB,SAAO,KAAK,OAAO,EAAE,SAAS,EAAE,EAAE,UAAU,GAAG,CAAC;AAClD;AAEA,SAAS,YAAY,OAAkF;AACrG,MAAG,EAAE,QAAQ,UAAU,CAAC,MAAM,IAAI;AAChC,UAAM,KAAK,WAAW;AACtB,WAAO;AAAA,EACT;AACA,SAAO;AACT;AAEA,SAAS,uBAAuB,OAA0C;AACxE,QAAM,gBAAgB,MAAM,OAAO,IAAI,WAAS;AAC9C,UAAM,eAA2D,EAAE,GAAG,MAAM;AAC5E,WAAO,aAAa;AACpB,WAAO;AAAA,EACT,CAAC;AAED,SAAO;AAAA,IACL,GAAG;AAAA,IACH,QAAQ;AAAA,EACV;AACF;AAEA,SAAS,gBAAgB,OAA0C;AACjE,SAAO;AAAA,IACL,GAAG;AAAA,IACH,QAAQ,YAAY,MAAM,MAAM;AAAA,EAClC;AACF;AAEA,SAAS,oBAAoB,OAAgE;AAC3F,SAAO,uBAAuB,gBAAgB,YAAY,KAAK,CAAC,CAAC;AACnE;AAEA,SAAS,aAAa,QAA8B,SAAiB;AACnE,WAAS,IAAI,GAAG,IAAI,OAAO,QAAQ,KAAK;AACtC,QAAG,OAAO,CAAC,EAAE,OAAO,SAAS;AAC3B,aAAO;AAAA,IACT;AAAA,EACF;AACA,SAAO;AACT;AAEA,SAAS,eAAe,YAAoB,UAA8B,MAAiC;AACzG,MAAG,eAAe,6BAA6B,eAAe,0BAA0B;AACtF,iBAAa;AAAA,EACf;AAEA,QAAM,WAAW,SAAS,YAAY,CAAC;AACvC,MAAI,cAAc,SAAS,YAAY,UAAU,eAAe;AAEhE,MAAG,KAAK,iBAAiB,CAAC,aAAa;AACrC,kBAAc,OAAO,UAAiC;AAAA,EACxD;AAEA,SAAO;AACT;AAEA,SAAS,yBAAyB,UAA8B,YAAoB,OAAK,CAAC,GAAG;AAC3F,QAAM,SAAS,SAAS,QAAQ,UAAU;AAC1C,MAAG,CAAC;AAAQ,WAAO;AACnB,MAAG,EAAE,SAAS,WAAW,CAAC,OAAO;AAAK,WAAO;AAE7C,QAAM,cAAc,eAAe,YAAY,UAAU,IAAI;AAE7D,MAAG,CAAC,aAAa;AAEf,WAAO;AAAA,EACT;AAEA,QAAM,iBAAiB;AAAA,IACrB,GAAG,SAAS;AAAA,IACZ,CAAC,UAAU,GAAG;AAAA,MACZ,GAAG;AAAA,MACH,KAAK,OAAO,IAAI,QAAQ,SAAS,WAAW;AAAA,IAC9C;AAAA,EACF;AACA,QAAM,eAAe;AAAA,IACnB,GAAG;AAAA,IACH,SAAS;AAAA,EACX;AACA,SAAO;AACT;AAEA,SAAS,oBAAoB,UAA8B,OAAK,CAAC,GAAG;AAClE,MAAI,eAAe;AAEnB,SAAO,KAAK,SAAS,OAAO,EAAE,QAAQ,CAAC,eAAe;AACpD,mBAAe,yBAAyB,cAAc,YAAY,IAAI;AAAA,EACxE,CAAC;AAED,MAAI,SAAS,WAAW,SAAS,OAAO,MAAM,oBAAoB,KAAK,SAAS,OAAO,MAAM,iBAAiB,IAAI;AAChH,UAAM,iBAAiB,eAAe,gBAAgB,UAAU,IAAI;AACpE,QAAI,gBAAgB;AAClB,qBAAe;AAAA,QACb,GAAG;AAAA,QACH,QAAQ,SAAS,OAAO,QAAQ,SAAS,cAAc;AAAA,MACzD;AAAA,IACF;AAAA,EACF;AAEA,SAAO;AACT;AAEA,SAAS,kBAAkB,UAA8B;AACvD,QAAM,kBAAkB;AAAA,IACtB,GAAG,SAAS;AAAA,EACd;AACA,SAAO,gBAAgB,oCAAoC;AAC3D,SAAO;AAAA,IACL,GAAG;AAAA,IACH,UAAU;AAAA,EACZ;AACF;AAEA,eAAe;AAAA,EACb;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"90dcc82dd58ae44e1faf5283c5a3a70c09f07bf2"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Rn=function(){return s},s}Rn();const bEe=(Rn().s[0]++,aG({version:8,sources:{},layers:[]}));function oG(){return Rn().f[0]++,Rn().s[1]++,Math.random().toString(36).substring(2,9)}function xEe(e){return Rn().f[1]++,Rn().s[2]++,Rn().b[1][0]++,!("id"in e)||(Rn().b[1][1]++,!e.id)?(Rn().b[0][0]++,Rn().s[3]++,e.id=oG(),Rn().s[4]++,e):(Rn().b[0][1]++,Rn().s[5]++,e)}function wEe(e){Rn().f[2]++;const n=(Rn().s[6]++,e.layers.map(t=>{Rn().f[3]++;const r=(Rn().s[7]++,{...t});return Rn().s[8]++,delete r.interactive,Rn().s[9]++,r}));return Rn().s[10]++,{...e,layers:n}}function MEe(e){return Rn().f[4]++,Rn().s[11]++,{...e,layers:FH(e.layers)}}function aG(e){return Rn().f[5]++,Rn().s[12]++,wEe(MEe(xEe(e)))}function SEe(e,n){Rn().f[6]++,Rn().s[13]++;for(let t=(Rn().s[14]++,0);t<e.length;t++){if(Rn().s[15]++,e[t].id===n)return Rn().b[2][0]++,Rn().s[16]++,t;Rn().b[2][1]++}return Rn().s[17]++,null}function Z8(e,n,t){Rn().f[7]++,Rn().s[18]++,Rn().b[4][0]++,e==="thunderforest_transport"||(Rn().b[4][1]++,e==="thunderforest_outdoors")?(Rn().b[3][0]++,Rn().s[19]++,e="thunderforest"):Rn().b[3][1]++;const r=(Rn().s[20]++,Rn().b[5][0]++,n.metadata||(Rn().b[5][1]++,{}));let i=(Rn().s[21]++,r[`maputnik:${e}_access_token`]);return Rn().s[22]++,Rn().b[7][0]++,t.allowFallback&&(Rn().b[7][1]++,!i)?(Rn().b[6][0]++,Rn().s[23]++,i=iG[e]):Rn().b[6][1]++,Rn().s[24]++,i}function EEe(e,n,t=(Rn().b[8][0]++,{})){Rn().f[8]++;const r=(Rn().s[25]++,e.sources[n]);if(Rn().s[26]++,r)Rn().b[9][1]++;else return Rn().b[9][0]++,Rn().s[27]++,e;if(Rn().s[28]++,Rn().b[11][0]++,!("url"in r)||(Rn().b[11][1]++,!r.url))return Rn().b[10][0]++,Rn().s[29]++,e;Rn().b[10][1]++;const i=(Rn().s[30]++,Z8(n,e,t));if(Rn().s[31]++,i)Rn().b[12][1]++;else return Rn().b[12][0]++,Rn().s[32]++,e;const o=(Rn().s[33]++,{...e.sources,[n]:{...r,url:r.url.replace("{key}",i)}}),s=(Rn().s[34]++,{...e,sources:o});return Rn().s[35]++,s}function OEe(e,n=(Rn().b[13][0]++,{})){Rn().f[9]++;let t=(Rn().s[36]++,e);if(Rn().s[37]++,Object.keys(e.sources).forEach(r=>{Rn().f[10]++,Rn().s[38]++,t=EEe(t,r,n)}),Rn().s[39]++,Rn().b[15][0]++,e.glyphs&&(Rn().b[15][1]++,e.glyphs.match(/\.tilehosting\.com/)||(Rn().b[15][2]++,e.glyphs.match(/\.maptiler\.com/)))){Rn().b[14][0]++;const r=(Rn().s[40]++,Z8("openmaptiles",e,n));Rn().s[41]++,r?(Rn().b[16][0]++,Rn().s[42]++,t={...t,glyphs:e.glyphs.replace("{key}",r)}):Rn().b[16][1]++}else Rn().b[14][1]++;return Rn().s[43]++,t}function BEe(e){Rn().f[11]++;const n=(Rn().s[44]++,{...e.metadata});return Rn().s[45]++,delete n["maputnik:openmaptiles_access_token"],Rn().s[46]++,{...e,metadata:n}}const vu={ensureStyleValidity:aG,emptyStyle:bEe,indexOfLayer:SEe,generateId:oG,getAccessToken:Z8,replaceAccessTokens:OEe,stripAccessTokens:BEe};function Po(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalExport.tsx",n="5ede43596afbfd1204f65c6c1bd54e16d6b65a8a",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalExport.tsx",statementMap:{0:{start:{line:13,column:28},end:{line:13,column:35}},1:{start:{line:16,column:4},end:{line:20,column:6}},2:{start:{line:23,column:4},end:{line:31,column:5}},3:{start:{line:24,column:6},end:{line:28,column:9}},4:{start:{line:30,column:6},end:{line:30,column:36}},5:{start:{line:34,column:23},end:{line:34,column:44}},6:{start:{line:35,column:22},end:{line:35,column:55}},7:{start:{line:36,column:17},end:{line:60,column:1}},8:{start:{line:61,column:17},end:{line:61,column:70}},9:{start:{line:62,column:23},end:{line:62,column:40}},10:{start:{line:63,column:4},end:{line:63,column:39}},11:{start:{line:66,column:23},end:{line:66,column:44}},12:{start:{line:67,column:17},end:{line:67,column:83}},13:{start:{line:68,column:23},end:{line:68,column:40}},14:{start:{line:69,column:4},end:{line:69,column:39}},15:{start:{line:72,column:25},end:{line:78,column:5}},16:{start:{line:79,column:4},end:{line:79,column:44}},17:{start:{line:82,column:4},end:{line:137,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:15,column:2},end:{line:15,column:3}},loc:{start:{line:15,column:19},end:{line:21,column:3}},line:15},1:{name:"(anonymous_1)",decl:{start:{line:22,column:2},end:{line:22,column:3}},loc:{start:{line:22,column:15},end:{line:32,column:3}},line:22},2:{name:"(anonymous_2)",decl:{start:{line:33,column:2},end:{line:33,column:3}},loc:{start:{line:33,column:17},end:{line:64,column:3}},line:33},3:{name:"(anonymous_3)",decl:{start:{line:65,column:2},end:{line:65,column:3}},loc:{start:{line:65,column:18},end:{line:70,column:3}},line:65},4:{name:"(anonymous_4)",decl:{start:{line:71,column:2},end:{line:71,column:3}},loc:{start:{line:71,column:42},end:{line:80,column:3}},line:71},5:{name:"(anonymous_5)",decl:{start:{line:81,column:2},end:{line:81,column:3}},loc:{start:{line:81,column:11},end:{line:138,column:3}},line:81}},branchMap:{0:{loc:{start:{line:23,column:4},end:{line:31,column:5}},type:"if",locations:[{start:{line:23,column:4},end:{line:31,column:5}},{start:{line:29,column:11},end:{line:31,column:5}}],line:23},1:{loc:{start:{line:35,column:22},end:{line:35,column:55}},type:"binary-expr",locations:[{start:{line:35,column:22},end:{line:35,column:46}},{start:{line:35,column:50},end:{line:35,column:55}}],line:35},2:{loc:{start:{line:99,column:24},end:{line:99,column:58}},type:"binary-expr",locations:[{start:{line:99,column:24},end:{line:99,column:52}},{start:{line:99,column:56},end:{line:99,column:58}}],line:99},3:{loc:{start:{line:108,column:24},end:{line:108,column:58}},type:"binary-expr",locations:[{start:{line:108,column:24},end:{line:108,column:52}},{start:{line:108,column:56},end:{line:108,column:58}}],line:108}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0},f:{0:0,1:0,2:0,3:0,4:0,5:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalExport.tsx"],names:[],mappings:"AA+GQ,cAKA,YALA;AA/GR,OAAO,WAAW;AAClB,OAAO,aAAa;AACpB,SAAQ,cAAa;AACrB,SAAQ,eAAc;AACtB,SAAQ,cAAa;AAErB,SAAQ,sBAAqB;AAE7B,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,yBAAyB;AAGhC,MAAM,sBAAsB;AAW5B,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EAEzE,iBAAkB;AAChB,WAAO;AAAA,MACL,MAAM;AAAA,QACJ,MAAM,oBAAoB,KAAK,MAAM,QAAQ;AAAA,MAC/C;AAAA,IACF;AAAA,EACF;AAAA,EAEA,aAAc;AACZ,QAAG,KAAK,MAAM,SAAS,MAAM;AAC3B,aAAO,QAAQ,KAAK,MAAM,SAAS,MAAM;AAAA,QACvC,aAAa;AAAA,QACb,QAAQ;AAAA,QACR,OAAO;AAAA,MACT,CAAC;AAAA,IACH,OAAO;AACL,aAAO,KAAK,MAAM,SAAS;AAAA,IAC7B;AAAA,EACF;AAAA,EAEA,eAAe;AACb,UAAM,aAAa,KAAK,eAAe;AACvC,UAAM,YAAY,KAAK,MAAM,SAAS,QAAQ;AAC9C,UAAM,OAAO;AAAA;AAAA;AAAA;AAAA,WAIN,SAAS;AAAA;AAAA,+CAE2B,mBAAmB;AAAA,8CACpB,mBAAmB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAW/C,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQxB,UAAM,OAAO,IAAI,KAAK,CAAC,IAAI,GAAG,EAAC,MAAM,0BAAyB,CAAC;AAC/D,UAAM,aAAa,KAAK,WAAW;AACnC,WAAO,MAAM,aAAa,OAAO;AAAA,EACnC;AAAA,EAEA,gBAAgB;AACd,UAAM,aAAa,KAAK,eAAe;AACvC,UAAM,OAAO,IAAI,KAAK,CAAC,UAAU,GAAG,EAAC,MAAM,iCAAgC,CAAC;AAC5E,UAAM,aAAa,KAAK,WAAW;AACnC,WAAO,MAAM,aAAa,OAAO;AAAA,EACnC;AAAA,EAEA,uBAAuB,UAAkB,OAAY;AACnD,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,UAAU;AAAA,QACR,GAAG,KAAK,MAAM,SAAS;AAAA,QACvB,CAAC,QAAQ,GAAG;AAAA,MACd;AAAA,IACF;AACA,SAAK,MAAM,eAAe,YAAY;AAAA,EACxC;AAAA,EAGA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAO;AAAA,QACP,WAAU;AAAA,QAGV,+BAAC,aAAQ,WAAU,0BACjB;AAAA,8BAAC,QAAG,4BAAc;AAAA,UAClB,oBAAC,OAAE,qDAEH;AAAA,UAEA,qBAAC,SACC;AAAA;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO,oBAAoB,SAAS,sBAAsB;AAAA,gBAC1D,WAAW,oBAAoB,SAAS;AAAA,gBACxC,QAAQ,KAAK,MAAM,SAAS,YAAY,CAAC,GAAU,oCAAoC;AAAA,gBACvF,UAAU,KAAK,uBAAuB,KAAK,MAAM,oCAAoC;AAAA;AAAA,YACvF;AAAA,YACA;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO,oBAAoB,SAAS,2BAA2B;AAAA,gBAC/D,WAAW,oBAAoB,SAAS;AAAA,gBACxC,QAAQ,KAAK,MAAM,SAAS,YAAY,CAAC,GAAU,qCAAqC;AAAA,gBACxF,UAAU,KAAK,uBAAuB,KAAK,MAAM,qCAAqC;AAAA;AAAA,YACxF;AAAA,aACF;AAAA,UAEA,qBAAC,SAAI,WAAU,iCACb;AAAA;AAAA,cAAC;AAAA;AAAA,gBACC,SAAS,KAAK,cAAc,KAAK,IAAI;AAAA,gBAErC;AAAA,sCAAC,kBAAe;AAAA,kBAAE;AAAA;AAAA;AAAA,YAEpB;AAAA,YAEA;AAAA,cAAC;AAAA;AAAA,gBACC,SAAS,KAAK,aAAa,KAAK,IAAI;AAAA,gBAEpC;AAAA,sCAAC,kBAAe;AAAA,kBAAE;AAAA;AAAA;AAAA,YAEpB;AAAA,aACF;AAAA,WACF;AAAA;AAAA,IAEF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"5ede43596afbfd1204f65c6c1bd54e16d6b65a8a"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Po=function(){return s},s}Po();const xP=(Po().s[0]++,vEe);class kEe extends bn.Component{tokenizedStyle(){return Po().f[0]++,Po().s[1]++,zR(vu.stripAccessTokens(vu.replaceAccessTokens(this.props.mapStyle)))}exportName(){return Po().f[1]++,Po().s[2]++,this.props.mapStyle.name?(Po().b[0][0]++,Po().s[3]++,yEe(this.props.mapStyle.name,{replacement:"_",remove:/[*\-+~.()'"!:]/g,lower:!0})):(Po().b[0][1]++,Po().s[4]++,this.props.mapStyle.id)}downloadHtml(){Po().f[2]++;const n=(Po().s[5]++,this.tokenizedStyle()),t=(Po().s[6]++,Po().b[1][0]++,this.props.mapStyle.name||(Po().b[1][1]++,"Map")),r=(Po().s[7]++,`<!DOCTYPE html>
|
||
<html>
|
||
<head>
|
||
<meta charset="utf-8" />
|
||
<title>${t}</title>
|
||
<meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no" />
|
||
<script src="https://unpkg.com/maplibre-gl@${xP}/dist/maplibre-gl.js"><\/script>
|
||
<link href="https://unpkg.com/maplibre-gl@${xP}/dist/maplibre-gl.css" rel="stylesheet" />
|
||
<style>
|
||
body { margin: 0; padding: 0; }
|
||
#map { position: absolute; top: 0; bottom: 0; width: 100%; }
|
||
</style>
|
||
</head>
|
||
<body>
|
||
<div id="map"></div>
|
||
<script>
|
||
const map = new maplibregl.Map({
|
||
container: 'map',
|
||
style: ${n},
|
||
});
|
||
map.addControl(new maplibregl.NavigationControl());
|
||
<\/script>
|
||
</body>
|
||
</html>
|
||
`),i=(Po().s[8]++,new Blob([r],{type:"text/html;charset=utf-8"})),o=(Po().s[9]++,this.exportName());Po().s[10]++,bP.saveAs(i,o+".html")}downloadStyle(){Po().f[3]++;const n=(Po().s[11]++,this.tokenizedStyle()),t=(Po().s[12]++,new Blob([n],{type:"application/json;charset=utf-8"})),r=(Po().s[13]++,this.exportName());Po().s[14]++,bP.saveAs(t,r+".json")}changeMetadataProperty(n,t){Po().f[4]++;const r=(Po().s[15]++,{...this.props.mapStyle,metadata:{...this.props.mapStyle.metadata,[n]:t}});Po().s[16]++,this.props.onStyleChanged(r)}render(){return Po().f[5]++,Po().s[17]++,N.jsx(_f,{"data-wd-key":"modal:export",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Export Style",className:"maputnik-export-modal",children:N.jsxs("section",{className:"maputnik-modal-section",children:[N.jsx("h1",{children:"Download Style"}),N.jsx("p",{children:"Download a JSON style to your computer."}),N.jsxs("div",{children:[N.jsx(uh,{label:Yh.maputnik.maptiler_access_token.label,fieldSpec:Yh.maputnik.maptiler_access_token,value:(Po().b[2][0]++,this.props.mapStyle.metadata||(Po().b[2][1]++,{}))["maputnik:openmaptiles_access_token"],onChange:this.changeMetadataProperty.bind(this,"maputnik:openmaptiles_access_token")}),N.jsx(uh,{label:Yh.maputnik.thunderforest_access_token.label,fieldSpec:Yh.maputnik.thunderforest_access_token,value:(Po().b[3][0]++,this.props.mapStyle.metadata||(Po().b[3][1]++,{}))["maputnik:thunderforest_access_token"],onChange:this.changeMetadataProperty.bind(this,"maputnik:thunderforest_access_token")})]}),N.jsxs("div",{className:"maputnik-modal-export-buttons",children:[N.jsxs(Ka,{onClick:this.downloadStyle.bind(this),children:[N.jsx(T6,{}),"Download Style"]}),N.jsxs(Ka,{onClick:this.downloadHtml.bind(this),children:[N.jsx(T6,{}),"Download HTML"]})]})]})})}}function C4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldDynamicArray.tsx",n="950dd35e62562a3439b74678b95f406e749c6958",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldDynamicArray.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:139}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldDynamicArray.tsx"],names:[],mappings:"AAWM;AAXN,OAAO,WAAW;AAClB,OAAO,uBAA2E;AAClF,OAAO,cAAc;AAMrB,qBAAqB,0BAA0B,MAAM,UAAkC;AAAA,EACrF,SAAS;AACP,WAAO,oBAAC,YAAS,OAAO,KAAK,MAAM,OACjC,8BAAC,qBAAmB,GAAG,KAAK,OAAO,GACrC;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"950dd35e62562a3439b74678b95f406e749c6958"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return C4=function(){return s},s}C4();class sG extends bn.Component{render(){return C4().f[0]++,C4().s[0]++,N.jsx(E_,{label:this.props.label,children:N.jsx(GN,{...this.props})})}}function _4(){var e="/home/runner/work/maputnik/maputnik/src/components/FieldCheckbox.tsx",n="a27c35e986d22656fa80c276efb67df518853ac2",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/FieldCheckbox.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:132}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:11},end:{line:8,column:3}},line:6}},branchMap:{},s:{0:0},f:{0:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/FieldCheckbox.tsx"],names:[],mappings:"AAaM;AAbN,OAAO,WAAW;AAClB,OAAO,WAAW;AAClB,OAAO,mBAAyC;AAQhD,qBAAqB,sBAAsB,MAAM,UAA8B;AAAA,EAC7E,SAAS;AACP,WAAO,oBAAC,SAAM,OAAO,KAAK,MAAM,OAC9B,8BAAC,iBAAe,GAAG,KAAK,OAAO,GACjC;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"a27c35e986d22656fa80c276efb67df518853ac2"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return _4=function(){return s},s}_4();class IEe extends bn.Component{render(){return _4().f[0]++,_4().s[0]++,N.jsx(Uo,{label:this.props.label,children:N.jsx(Q8,{...this.props})})}}function Yn(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalSourcesTypeEditor.tsx",n="bd3e4d09ce7131c28fb23a5fc0245fe57c891028",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalSourcesTypeEditor.tsx",statementMap:{0:{start:{line:14,column:4},end:{line:28,column:9}},1:{start:{line:21,column:29},end:{line:24,column:12}},2:{start:{line:33,column:4},end:{line:36,column:7}},3:{start:{line:39,column:18},end:{line:39,column:47}},4:{start:{line:40,column:4},end:{line:49,column:6}},5:{start:{line:52,column:4},end:{line:79,column:9}},6:{start:{line:60,column:33},end:{line:63,column:12}},7:{start:{line:72,column:33},end:{line:75,column:12}},8:{start:{line:84,column:24},end:{line:91,column:5}},9:{start:{line:85,column:26},end:{line:85,column:64}},10:{start:{line:86,column:6},end:{line:86,column:29}},11:{start:{line:87,column:6},end:{line:90,column:9}},12:{start:{line:92,column:4},end:{line:119,column:9}},13:{start:{line:99,column:29},end:{line:102,column:12}},14:{start:{line:106,column:8},end:{line:117,column:10}},15:{start:{line:114,column:31},end:{line:114,column:52}},16:{start:{line:124,column:24},end:{line:131,column:5}},17:{start:{line:125,column:26},end:{line:125,column:64}},18:{start:{line:126,column:6},end:{line:126,column:29}},19:{start:{line:127,column:6},end:{line:130,column:9}},20:{start:{line:132,column:23},end:{line:137,column:5}},21:{start:{line:133,column:6},end:{line:136,column:9}},22:{start:{line:138,column:4},end:{line:164,column:9}},23:{start:{line:151,column:8},end:{line:162,column:10}},24:{start:{line:159,column:31},end:{line:159,column:52}},25:{start:{line:169,column:4},end:{line:180,column:6}},26:{start:{line:175,column:28},end:{line:178,column:10}},27:{start:{line:185,column:4},end:{line:217,column:9}},28:{start:{line:197,column:12},end:{line:200,column:15}},29:{start:{line:210,column:12},end:{line:213,column:15}},30:{start:{line:222,column:24},end:{line:225,column:5}},31:{start:{line:226,column:4},end:{line:261,column:5}},32:{start:{line:228,column:8},end:{line:228,column:79}},33:{start:{line:230,column:8},end:{line:230,column:85}},34:{start:{line:232,column:8},end:{line:232,column:77}},35:{start:{line:234,column:8},end:{line:234,column:76}},36:{start:{line:236,column:8},end:{line:236,column:77}},37:{start:{line:238,column:8},end:{line:238,column:76}},38:{start:{line:240,column:8},end:{line:240,column:77}},39:{start:{line:242,column:8},end:{line:254,column:13}},40:{start:{line:248,column:36},end:{line:251,column:14}},41:{start:{line:256,column:8},end:{line:256,column:74}},42:{start:{line:258,column:8},end:{line:258,column:74}},43:{start:{line:260,column:8},end:{line:260,column:20}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:13,column:2},end:{line:13,column:3}},loc:{start:{line:13,column:11},end:{line:29,column:3}},line:13},1:{name:"(anonymous_1)",decl:{start:{line:21,column:20},end:{line:21,column:21}},loc:{start:{line:21,column:29},end:{line:24,column:12}},line:21},2:{name:"(anonymous_2)",decl:{start:{line:32,column:2},end:{line:32,column:3}},loc:{start:{line:32,column:24},end:{line:37,column:3}},line:32},3:{name:"(anonymous_3)",decl:{start:{line:38,column:2},end:{line:38,column:3}},loc:{start:{line:38,column:19},end:{line:50,column:3}},line:38},4:{name:"(anonymous_4)",decl:{start:{line:51,column:2},end:{line:51,column:3}},loc:{start:{line:51,column:11},end:{line:80,column:3}},line:51},5:{name:"(anonymous_5)",decl:{start:{line:60,column:20},end:{line:60,column:21}},loc:{start:{line:60,column:33},end:{line:63,column:12}},line:60},6:{name:"(anonymous_6)",decl:{start:{line:72,column:20},end:{line:72,column:21}},loc:{start:{line:72,column:33},end:{line:75,column:12}},line:72},7:{name:"(anonymous_7)",decl:{start:{line:83,column:2},end:{line:83,column:3}},loc:{start:{line:83,column:11},end:{line:120,column:3}},line:83},8:{name:"(anonymous_8)",decl:{start:{line:84,column:24},end:{line:84,column:25}},loc:{start:{line:84,column:38},end:{line:91,column:5}},line:84},9:{name:"(anonymous_9)",decl:{start:{line:99,column:20},end:{line:99,column:21}},loc:{start:{line:99,column:29},end:{line:102,column:12}},line:99},10:{name:"(anonymous_10)",decl:{start:{line:105,column:67},end:{line:105,column:68}},loc:{start:{line:105,column:83},end:{line:118,column:7}},line:105},11:{name:"(anonymous_11)",decl:{start:{line:114,column:22},end:{line:114,column:23}},loc:{start:{line:114,column:31},end:{line:114,column:52}},line:114},12:{name:"(anonymous_12)",decl:{start:{line:123,column:2},end:{line:123,column:3}},loc:{start:{line:123,column:11},end:{line:165,column:3}},line:123},13:{name:"(anonymous_13)",decl:{start:{line:124,column:24},end:{line:124,column:25}},loc:{start:{line:124,column:38},end:{line:131,column:5}},line:124},14:{name:"(anonymous_14)",decl:{start:{line:132,column:23},end:{line:132,column:24}},loc:{start:{line:132,column:33},end:{line:137,column:5}},line:132},15:{name:"(anonymous_15)",decl:{start:{line:150,column:67},end:{line:150,column:68}},loc:{start:{line:150,column:83},end:{line:163,column:7}},line:150},16:{name:"(anonymous_16)",decl:{start:{line:159,column:22},end:{line:159,column:23}},loc:{start:{line:159,column:31},end:{line:159,column:52}},line:159},17:{name:"(anonymous_17)",decl:{start:{line:168,column:2},end:{line:168,column:3}},loc:{start:{line:168,column:11},end:{line:181,column:3}},line:168},18:{name:"(anonymous_18)",decl:{start:{line:175,column:18},end:{line:175,column:19}},loc:{start:{line:175,column:28},end:{line:178,column:10}},line:175},19:{name:"(anonymous_19)",decl:{start:{line:184,column:2},end:{line:184,column:3}},loc:{start:{line:184,column:11},end:{line:218,column:3}},line:184},20:{name:"(anonymous_20)",decl:{start:{line:196,column:20},end:{line:196,column:21}},loc:{start:{line:196,column:30},end:{line:201,column:11}},line:196},21:{name:"(anonymous_21)",decl:{start:{line:209,column:20},end:{line:209,column:21}},loc:{start:{line:209,column:33},end:{line:214,column:11}},line:209},22:{name:"(anonymous_22)",decl:{start:{line:221,column:2},end:{line:221,column:3}},loc:{start:{line:221,column:11},end:{line:262,column:3}},line:221},23:{name:"(anonymous_23)",decl:{start:{line:248,column:22},end:{line:248,column:23}},loc:{start:{line:248,column:36},end:{line:251,column:14}},line:248}},branchMap:{0:{loc:{start:{line:39,column:18},end:{line:39,column:47}},type:"binary-expr",locations:[{start:{line:39,column:18},end:{line:39,column:41}},{start:{line:39,column:45},end:{line:39,column:47}}],line:39},1:{loc:{start:{line:59,column:17},end:{line:59,column:47}},type:"binary-expr",locations:[{start:{line:59,column:17},end:{line:59,column:42}},{start:{line:59,column:46},end:{line:59,column:47}}],line:59},2:{loc:{start:{line:71,column:17},end:{line:71,column:48}},type:"binary-expr",locations:[{start:{line:71,column:17},end:{line:71,column:42}},{start:{line:71,column:46},end:{line:71,column:48}}],line:71},3:{loc:{start:{line:226,column:4},end:{line:261,column:5}},type:"switch",locations:[{start:{line:227,column:6},end:{line:228,column:79}},{start:{line:229,column:6},end:{line:230,column:85}},{start:{line:231,column:6},end:{line:232,column:77}},{start:{line:233,column:6},end:{line:234,column:76}},{start:{line:235,column:6},end:{line:236,column:77}},{start:{line:237,column:6},end:{line:238,column:76}},{start:{line:239,column:6},end:{line:240,column:77}},{start:{line:241,column:6},end:{line:254,column:13}},{start:{line:255,column:6},end:{line:256,column:74}},{start:{line:257,column:6},end:{line:258,column:74}},{start:{line:259,column:6},end:{line:260,column:20}}],line:226},4:{loc:{start:{line:252,column:19},end:{line:252,column:90}},type:"binary-expr",locations:[{start:{line:252,column:19},end:{line:252,column:45}},{start:{line:252,column:49},end:{line:252,column:90}}],line:252}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0,0,0,0,0,0,0,0,0,0],4:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalSourcesTypeEditor.tsx"],names:[],mappings:"AAwBW,SACL,KADK;AAxBX,OAAO,WAAW;AAClB,SAAQ,cAAa;AACrB,OAAO,WAAW;AAClB,OAAO,cAAc;AACrB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,uBAAuB;AAC9B,OAAO,gBAAgB;AACvB,OAAO,eAAe;AACtB,OAAO,mBAAmB;AAa1B,MAAM,6BAA6B,MAAM,UAAqC;AAAA,EAC5E,SAAS;AACP,WAAO,qBAAC,SACN;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW,OAAO,cAAc;AAAA,UAChC,OAAO,KAAK,MAAM,OAAO;AAAA,UACzB,UAAU,SAAO,KAAK,MAAM,SAAS;AAAA,YACnC,GAAG,KAAK,MAAM;AAAA,YACd;AAAA,UACF,CAAC;AAAA;AAAA,MACH;AAAA,MACC,KAAK,MAAM;AAAA,OACd;AAAA,EACF;AACF;AAYA,MAAM,4BAA4B,MAAM,UAAoC;AAAA,EAC1E,eAAe,OAAiB;AAC9B,SAAK,MAAM,SAAS;AAAA,MAClB,GAAG,KAAK,MAAM;AAAA,MACd;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,iBAAiB;AACf,UAAM,QAAQ,KAAK,MAAM,OAAO,SAAS,CAAC;AAC1C,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,OAAO;AAAA,QACP,WAAW,OAAO,cAAc;AAAA,QAChC,MAAK;AAAA,QACL,OAAO;AAAA,QACP,UAAU,KAAK,eAAe,KAAK,IAAI;AAAA;AAAA,IACzC;AAAA,EACF;AAAA,EAEA,SAAS;AACP,WAAO,qBAAC,SACL;AAAA,WAAK,eAAe;AAAA,MACrB;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW,OAAO,cAAc;AAAA,UAChC,OAAO,KAAK,MAAM,OAAO,WAAW;AAAA,UACpC,UAAU,aAAW,KAAK,MAAM,SAAS;AAAA,YACvC,GAAG,KAAK,MAAM;AAAA,YACd;AAAA,UACF,CAAC;AAAA;AAAA,MACH;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW,OAAO,cAAc;AAAA,UAChC,OAAO,KAAK,MAAM,OAAO,WAAW;AAAA,UACpC,UAAU,aAAW,KAAK,MAAM,SAAS;AAAA,YACvC,GAAG,KAAK,MAAM;AAAA,YACd;AAAA,UACF,CAAC;AAAA;AAAA,MACH;AAAA,MACC,KAAK,MAAM;AAAA,OACd;AAAA,EAEF;AACF;AAUA,MAAM,0BAA0B,MAAM,UAAkC;AAAA,EACtE,SAAS;AACP,UAAM,cAAc,CAAC,KAAa,QAA0B;AAC1D,YAAM,cAAc,KAAK,MAAM,OAAO,YAAY,MAAM,CAAC;AACzD,kBAAY,GAAG,IAAI;AAEnB,WAAK,MAAM,SAAS;AAAA,QAClB,GAAG,KAAK,MAAM;AAAA,QACd;AAAA,MACF,CAAC;AAAA,IACH;AAEA,WAAO,qBAAC,SACN;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW,OAAO,aAAa;AAAA,UAC/B,OAAO,KAAK,MAAM,OAAO;AAAA,UACzB,UAAU,SAAO,KAAK,MAAM,SAAS;AAAA,YACnC,GAAG,KAAK,MAAM;AAAA,YACd;AAAA,UACF,CAAC;AAAA;AAAA,MACH;AAAA,MACC,CAAC,YAAY,aAAa,gBAAgB,aAAa,EAAE,IAAI,CAAC,OAAO,QAAQ;AAC5E,eACE;AAAA,UAAC;AAAA;AAAA,YACC,OAAO,SAAS,KAAK;AAAA,YAErB,QAAQ;AAAA,YACR,MAAK;AAAA,YACL,OAAO,KAAK,MAAM,OAAO,YAAY,GAAG;AAAA,YACxC,SAAS,CAAC,GAAG,CAAC;AAAA,YACd,UAAU,CAAC,QAA0B,YAAY,KAAK,GAAG;AAAA;AAAA,UALpD;AAAA,QAMP;AAAA,MAEJ,CAAC;AAAA,OACH;AAAA,EACF;AACF;AAUA,MAAM,0BAA0B,MAAM,UAAkC;AAAA,EACtE,SAAS;AACP,UAAM,cAAc,CAAC,KAAa,QAA0B;AAC1D,YAAM,cAAc,KAAK,MAAM,OAAO,YAAY,MAAM,CAAC;AACzD,kBAAY,GAAG,IAAI;AAEnB,WAAK,MAAM,SAAS;AAAA,QAClB,GAAG,KAAK,MAAM;AAAA,QACd;AAAA,MACF,CAAC;AAAA,IACH;AAEA,UAAM,aAAa,CAAC,SAAmB;AACrC,WAAK,MAAM,SAAS;AAAA,QAClB,GAAG,KAAK,MAAM;AAAA,QACd;AAAA,MACF,CAAC;AAAA,IACH;AAEA,WAAO,qBAAC,SACN;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW,OAAO,aAAa;AAAA,UAC/B,MAAK;AAAA,UACL,OAAO,KAAK,MAAM,OAAO;AAAA,UACzB,SAAS,CAAC;AAAA,UACV,UAAU;AAAA;AAAA,MACZ;AAAA,MACC,CAAC,YAAY,aAAa,gBAAgB,aAAa,EAAE,IAAI,CAAC,OAAO,QAAQ;AAC5E,eACE;AAAA,UAAC;AAAA;AAAA,YACC,OAAO,SAAS,KAAK;AAAA,YAErB,QAAQ;AAAA,YACR,MAAK;AAAA,YACL,OAAO,KAAK,MAAM,OAAO,YAAY,GAAG;AAAA,YACxC,SAAS,CAAC,GAAG,CAAC;AAAA,YACd,UAAU,CAAC,QAA0B,YAAY,KAAK,GAAG;AAAA;AAAA,UALpD;AAAA,QAMP;AAAA,MAEJ,CAAC;AAAA,OACH;AAAA,EACF;AACF;AASA,MAAM,+BAA+B,MAAM,UAAuC;AAAA,EAChF,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,OAAO;AAAA,QACP,WAAW,OAAO,eAAe;AAAA,QACjC,OAAO,KAAK,MAAM,OAAO;AAAA,QACzB,UAAU,UAAQ,KAAK,MAAM,SAAS;AAAA,UACpC,GAAG,KAAK,MAAM;AAAA,UACd;AAAA,QACF,CAAC;AAAA;AAAA,IACH;AAAA,EACF;AACF;AAUA,MAAM,qCAAqC,MAAM,UAA6C;AAAA,EAC5F,SAAS;AACP,WAAO,qBAAC,SACN;AAAA,0BAAC,SAAM,OAAO,WAAW,WAAW,OAAO,eAAe,MACxD;AAAA,QAAC;AAAA;AAAA,UACC,OAAO,KAAK,MAAM,OAAO;AAAA,UACzB,WAAW;AAAA,UACX,MAAM;AAAA,YACJ,MAAM;AAAA,YACN,MAAM;AAAA,UACR;AAAA,UACA,MAAM;AAAA,UACN,UAAU,UAAQ;AAChB,iBAAK,MAAM,SAAS;AAAA,cAClB,GAAG,KAAK,MAAM;AAAA,cACd;AAAA,YACF,CAAC;AAAA,UACH;AAAA;AAAA,MACF,GACF;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,OAAO,KAAK,MAAM,OAAO;AAAA,UACzB,UAAU,aAAW;AACnB,iBAAK,MAAM,SAAS;AAAA,cAClB,GAAG,KAAK,MAAM;AAAA,cACd;AAAA,YACF,CAAC;AAAA,UACH;AAAA;AAAA,MACF;AAAA,OACF;AAAA,EACF;AACF;AAQA,qBAAqB,+BAA+B,MAAM,UAAuC;AAAA,EAC/F,SAAS;AACP,UAAM,cAAc;AAAA,MAClB,QAAQ,KAAK,MAAM;AAAA,MACnB,UAAU,KAAK,MAAM;AAAA,IACvB;AACA,YAAO,KAAK,MAAM,MAAM;AAAA,MACxB,KAAK;AAAe,eAAO,oBAAC,0BAAwB,GAAG,aAAa;AAAA,MACpE,KAAK;AAAgB,eAAO,oBAAC,gCAA8B,GAAG,aAAa;AAAA,MAC3E,KAAK;AAAmB,eAAO,oBAAC,wBAAsB,GAAG,aAAa;AAAA,MACtE,KAAK;AAAkB,eAAO,oBAAC,uBAAqB,GAAG,aAAa;AAAA,MACpE,KAAK;AAAmB,eAAO,oBAAC,wBAAsB,GAAG,aAAa;AAAA,MACtE,KAAK;AAAkB,eAAO,oBAAC,uBAAqB,GAAG,aAAa;AAAA,MACpE,KAAK;AAAuB,eAAO,oBAAC,wBAAsB,GAAG,aAAa;AAAA,MAC1E,KAAK;AAAsB,eAAO,oBAAC,uBAAqB,GAAG,aACzD;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,WAAW,OAAO,kBAAkB;AAAA,YACpC,SAAS,OAAO,KAAK,OAAO,kBAAkB,SAAS,MAAM;AAAA,YAC7D,UAAU,cAAY,KAAK,MAAM,SAAS;AAAA,cACxC,GAAG,KAAK,MAAM;AAAA,cACd;AAAA,YACF,CAAC;AAAA,YACD,OAAO,KAAK,MAAM,OAAO,YAAY,OAAO,kBAAkB,SAAS;AAAA;AAAA,QACzE,GACF;AAAA,MACA,KAAK;AAAS,eAAO,oBAAC,qBAAmB,GAAG,aAAa;AAAA,MACzD,KAAK;AAAS,eAAO,oBAAC,qBAAmB,GAAG,aAAa;AAAA,MACzD;AAAS,eAAO;AAAA,IAChB;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"bd3e4d09ce7131c28fb23a5fc0245fe57c891028"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Yn=function(){return s},s}Yn();class aS extends bn.Component{render(){return Yn().f[0]++,Yn().s[0]++,N.jsxs("div",{children:[N.jsx(O_,{label:"TileJSON URL",fieldSpec:ma.source_vector.url,value:this.props.source.url,onChange:n=>(Yn().f[1]++,Yn().s[1]++,this.props.onChange({...this.props.source,url:n}))}),this.props.children]})}}class sS extends bn.Component{changeTileUrls(n){Yn().f[2]++,Yn().s[2]++,this.props.onChange({...this.props.source,tiles:n})}renderTileUrls(){Yn().f[3]++;const n=(Yn().s[3]++,Yn().b[0][0]++,this.props.source.tiles||(Yn().b[0][1]++,[]));return Yn().s[4]++,N.jsx(sG,{label:"Tile URL",fieldSpec:ma.source_vector.tiles,type:"url",value:n,onChange:this.changeTileUrls.bind(this)})}render(){return Yn().f[4]++,Yn().s[5]++,N.jsxs("div",{children:[this.renderTileUrls(),N.jsx(lp,{label:"Min Zoom",fieldSpec:ma.source_vector.minzoom,value:(Yn().b[1][0]++,this.props.source.minzoom||(Yn().b[1][1]++,0)),onChange:n=>(Yn().f[5]++,Yn().s[6]++,this.props.onChange({...this.props.source,minzoom:n}))}),N.jsx(lp,{label:"Max Zoom",fieldSpec:ma.source_vector.maxzoom,value:(Yn().b[2][0]++,this.props.source.maxzoom||(Yn().b[2][1]++,22)),onChange:n=>(Yn().f[6]++,Yn().s[7]++,this.props.onChange({...this.props.source,maxzoom:n}))}),this.props.children]})}}class TEe extends bn.Component{render(){Yn().f[7]++,Yn().s[8]++;const n=(t,r)=>{Yn().f[8]++;const i=(Yn().s[9]++,this.props.source.coordinates.slice(0));Yn().s[10]++,i[t]=r,Yn().s[11]++,this.props.onChange({...this.props.source,coordinates:i})};return Yn().s[12]++,N.jsxs("div",{children:[N.jsx(O_,{label:"Image URL",fieldSpec:ma.source_image.url,value:this.props.source.url,onChange:t=>(Yn().f[9]++,Yn().s[13]++,this.props.onChange({...this.props.source,url:t}))}),["top left","top right","bottom right","bottom left"].map((t,r)=>(Yn().f[10]++,Yn().s[14]++,N.jsx(f4,{label:`Coord ${t}`,length:2,type:"number",value:this.props.source.coordinates[r],default:[0,0],onChange:i=>(Yn().f[11]++,Yn().s[15]++,n(r,i))},t)))]})}}class KEe extends bn.Component{render(){Yn().f[12]++,Yn().s[16]++;const n=(r,i)=>{Yn().f[13]++;const o=(Yn().s[17]++,this.props.source.coordinates.slice(0));Yn().s[18]++,o[r]=i,Yn().s[19]++,this.props.onChange({...this.props.source,coordinates:o})};Yn().s[20]++;const t=r=>{Yn().f[14]++,Yn().s[21]++,this.props.onChange({...this.props.source,urls:r})};return Yn().s[22]++,N.jsxs("div",{children:[N.jsx(sG,{label:"Video URL",fieldSpec:ma.source_video.urls,type:"string",value:this.props.source.urls,default:[],onChange:t}),["top left","top right","bottom right","bottom left"].map((r,i)=>(Yn().f[15]++,Yn().s[23]++,N.jsx(f4,{label:`Coord ${r}`,length:2,type:"number",value:this.props.source.coordinates[i],default:[0,0],onChange:o=>(Yn().f[16]++,Yn().s[24]++,n(i,o))},r)))]})}}class PEe extends bn.Component{render(){return Yn().f[17]++,Yn().s[25]++,N.jsx(O_,{label:"GeoJSON URL",fieldSpec:ma.source_geojson.data,value:this.props.source.data,onChange:n=>(Yn().f[18]++,Yn().s[26]++,this.props.onChange({...this.props.source,data:n}))})}}class FEe extends bn.Component{render(){return Yn().f[19]++,Yn().s[27]++,N.jsxs("div",{children:[N.jsx(Uo,{label:"GeoJSON",fieldSpec:ma.source_geojson.data,children:N.jsx(c8,{layer:this.props.source.data,maxHeight:200,mode:{name:"javascript",json:!0},lint:!0,onChange:n=>{Yn().f[20]++,Yn().s[28]++,this.props.onChange({...this.props.source,data:n})}})}),N.jsx(IEe,{label:"Cluster",value:this.props.source.cluster,onChange:n=>{Yn().f[21]++,Yn().s[29]++,this.props.onChange({...this.props.source,cluster:n})}})]})}}class lG extends bn.Component{render(){Yn().f[22]++;const n=(Yn().s[30]++,{source:this.props.source,onChange:this.props.onChange});switch(Yn().s[31]++,this.props.mode){case"geojson_url":return Yn().b[3][0]++,Yn().s[32]++,N.jsx(PEe,{...n});case"geojson_json":return Yn().b[3][1]++,Yn().s[33]++,N.jsx(FEe,{...n});case"tilejson_vector":return Yn().b[3][2]++,Yn().s[34]++,N.jsx(aS,{...n});case"tilexyz_vector":return Yn().b[3][3]++,Yn().s[35]++,N.jsx(sS,{...n});case"tilejson_raster":return Yn().b[3][4]++,Yn().s[36]++,N.jsx(aS,{...n});case"tilexyz_raster":return Yn().b[3][5]++,Yn().s[37]++,N.jsx(sS,{...n});case"tilejson_raster-dem":return Yn().b[3][6]++,Yn().s[38]++,N.jsx(aS,{...n});case"tilexyz_raster-dem":return Yn().b[3][7]++,Yn().s[39]++,N.jsx(sS,{...n,children:N.jsx(V8,{label:"Encoding",fieldSpec:ma.source_raster_dem.encoding,options:Object.keys(ma.source_raster_dem.encoding.values),onChange:t=>(Yn().f[23]++,Yn().s[40]++,this.props.onChange({...this.props.source,encoding:t})),value:(Yn().b[4][0]++,this.props.source.encoding||(Yn().b[4][1]++,ma.source_raster_dem.encoding.default))})});case"image":return Yn().b[3][8]++,Yn().s[41]++,N.jsx(TEe,{...n});case"video":return Yn().b[3][9]++,Yn().s[42]++,N.jsx(KEe,{...n});default:return Yn().b[3][10]++,Yn().s[43]++,null}}}function Ah(){var e="/home/runner/work/maputnik/maputnik/src/libs/source.ts",n="315b9927ffd3b5bf51669bb9e53779783a451930",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/source.ts",statementMap:{0:{start:{line:2,column:27},end:{line:2,column:50}},1:{start:{line:3,column:2},end:{line:3,column:36}},2:{start:{line:4,column:2},end:{line:7,column:4}},3:{start:{line:10,column:2},end:{line:10,column:50}},4:{start:{line:13,column:25},end:{line:16,column:3}},5:{start:{line:17,column:2},end:{line:20,column:4}}},fnMap:{0:{name:"deleteSource",decl:{start:{line:1,column:16},end:{line:1,column:28}},loc:{start:{line:1,column:49},end:{line:8,column:1}},line:1},1:{name:"addSource",decl:{start:{line:9,column:16},end:{line:9,column:25}},loc:{start:{line:9,column:54},end:{line:11,column:1}},line:9},2:{name:"changeSource",decl:{start:{line:12,column:16},end:{line:12,column:28}},loc:{start:{line:12,column:57},end:{line:21,column:1}},line:12}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0},f:{0:0,1:0,2:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/source.ts"],names:[],mappings:"AAEO,gBAAS,aAAa,UAA8B,UAAkB;AAC3E,QAAM,mBAAmB,EAAE,GAAG,SAAS,QAAO;AAC9C,SAAO,iBAAiB,QAAQ;AAChC,SAAO;AAAA,IACL,GAAG;AAAA,IACH,SAAS;AAAA,EACX;AACF;AAGO,gBAAS,UAAU,UAA8B,UAAkB,QAA6B;AACrG,SAAO,aAAa,UAAU,UAAU,MAAM;AAChD;AAEO,gBAAS,aAAa,UAA8B,UAAkB,QAA6B;AACxG,QAAM,iBAAiB;AAAA,IACrB,GAAG,SAAS;AAAA,IACZ,CAAC,QAAQ,GAAG;AAAA,EACd;AACA,SAAO;AAAA,IACL,GAAG;AAAA,IACH,SAAS;AAAA,EACX;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"315b9927ffd3b5bf51669bb9e53779783a451930"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Ah=function(){return s},s}Ah();function DEe(e,n){Ah().f[0]++;const t=(Ah().s[0]++,{...e.sources});return Ah().s[1]++,delete t[n],Ah().s[2]++,{...e,sources:t}}function wP(e,n,t){return Ah().f[1]++,Ah().s[3]++,uG(e,n,t)}function uG(e,n,t){Ah().f[2]++;const r=(Ah().s[4]++,{...e.sources,[n]:t});return Ah().s[5]++,{...e,sources:r}}const UEe={type:"vector",url:"https://api.maptiler.com/tiles/v3/tiles.json?key={key}",title:"OpenMapTiles v3"},REe={type:"vector",url:"https://tile.thunderforest.com/thunderforest.transport-v2.json?apikey={key}",title:"Thunderforest Transport v2"},LEe={type:"vector",url:"https://tile.thunderforest.com/thunderforest.outdoors-v2.json?apikey={key}",title:"Thunderforest Outdoors v2"},zEe={type:"vector",url:"https://s3-eu-west-1.amazonaws.com/tiles.os.uk/v2/data/vector/open-zoomstack/config.json",title:"OS Open Zoomstack v2"},MP={openmaptiles:UEe,thunderforest_transport:REe,thunderforest_outdoors:LEe,open_zoomstack:zEe};function Yt(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalSources.tsx",n="0cdb4eacb2560c191df467eefb0fb2a3bf6cb962",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalSources.tsx",statementMap:{0:{start:{line:15,column:4},end:{line:32,column:9}},1:{start:{line:19,column:23},end:{line:19,column:57}},2:{start:{line:36,column:2},end:{line:40,column:3}},3:{start:{line:37,column:4},end:{line:38,column:30}},4:{start:{line:38,column:6},end:{line:38,column:30}},5:{start:{line:39,column:4},end:{line:39,column:29}},6:{start:{line:41,column:2},end:{line:45,column:3}},7:{start:{line:42,column:4},end:{line:43,column:34}},8:{start:{line:43,column:6},end:{line:43,column:34}},9:{start:{line:44,column:4},end:{line:44,column:33}},10:{start:{line:46,column:2},end:{line:50,column:3}},11:{start:{line:47,column:4},end:{line:48,column:30}},12:{start:{line:48,column:6},end:{line:48,column:30}},13:{start:{line:49,column:4},end:{line:49,column:29}},14:{start:{line:51,column:2},end:{line:57,column:3}},15:{start:{line:52,column:4},end:{line:56,column:5}},16:{start:{line:53,column:6},end:{line:53,column:27}},17:{start:{line:55,column:6},end:{line:55,column:28}},18:{start:{line:58,column:2},end:{line:60,column:3}},19:{start:{line:59,column:4},end:{line:59,column:19}},20:{start:{line:61,column:2},end:{line:63,column:3}},21:{start:{line:62,column:4},end:{line:62,column:19}},22:{start:{line:64,column:2},end:{line:64,column:14}},23:{start:{line:68,column:4},end:{line:94,column:9}},24:{start:{line:80,column:27},end:{line:80,column:67}},25:{start:{line:99,column:4},end:{line:99,column:17}},26:{start:{line:100,column:4},end:{line:104,column:6}},27:{start:{line:107,column:19},end:{line:107,column:50}},28:{start:{line:108,column:25},end:{line:108,column:40}},29:{start:{line:109,column:4},end:{line:183,column:5}},30:{start:{line:111,column:8},end:{line:114,column:10}},31:{start:{line:116,column:8},end:{line:120,column:10}},32:{start:{line:122,column:8},end:{line:125,column:10}},33:{start:{line:127,column:8},end:{line:132,column:10}},34:{start:{line:134,column:8},end:{line:137,column:10}},35:{start:{line:139,column:8},end:{line:144,column:10}},36:{start:{line:146,column:8},end:{line:149,column:10}},37:{start:{line:151,column:8},end:{line:156,column:10}},38:{start:{line:158,column:8},end:{line:167,column:10}},39:{start:{line:169,column:8},end:{line:180,column:10}},40:{start:{line:182,column:8},end:{line:182,column:18}},41:{start:{line:185,column:10},end:{line:188,column:3}},42:{start:{line:186,column:33},end:{line:186,column:43}},43:{start:{line:187,column:4},end:{line:187,column:39}},44:{start:{line:189,column:19},end:{line:191,column:3}},45:{start:{line:190,column:4},end:{line:190,column:30}},46:{start:{line:193,column:32},end:{line:195,column:5}},47:{start:{line:196,column:4},end:{line:243,column:9}},48:{start:{line:203,column:27},end:{line:203,column:57}},49:{start:{line:223,column:30},end:{line:223,column:87}},50:{start:{line:248,column:27},end:{line:248,column:40}},51:{start:{line:249,column:4},end:{line:249,column:35}},52:{start:{line:250,column:4},end:{line:250,column:26}},53:{start:{line:253,column:21},end:{line:253,column:40}},54:{start:{line:254,column:26},end:{line:266,column:6}},55:{start:{line:255,column:21},end:{line:255,column:47}},56:{start:{line:256,column:6},end:{line:265,column:8}},57:{start:{line:261,column:29},end:{line:261,column:93}},58:{start:{line:262,column:26},end:{line:262,column:85}},59:{start:{line:267,column:27},end:{line:279,column:6}},60:{start:{line:267,column:75},end:{line:267,column:106}},61:{start:{line:268,column:21},end:{line:268,column:44}},62:{start:{line:269,column:6},end:{line:278,column:8}},63:{start:{line:275,column:26},end:{line:275,column:107}},64:{start:{line:280,column:4},end:{line:309,column:6}},65:{start:{line:303,column:45},end:{line:303,column:109}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:11},end:{line:33,column:3}},line:14},1:{name:"(anonymous_1)",decl:{start:{line:19,column:17},end:{line:19,column:18}},loc:{start:{line:19,column:23},end:{line:19,column:57}},line:19},2:{name:"editorMode",decl:{start:{line:35,column:9},end:{line:35,column:19}},loc:{start:{line:35,column:28},end:{line:65,column:1}},line:35},3:{name:"(anonymous_3)",decl:{start:{line:67,column:2},end:{line:67,column:3}},loc:{start:{line:67,column:11},end:{line:95,column:3}},line:67},4:{name:"(anonymous_4)",decl:{start:{line:80,column:21},end:{line:80,column:22}},loc:{start:{line:80,column:27},end:{line:80,column:67}},line:80},5:{name:"(anonymous_5)",decl:{start:{line:98,column:2},end:{line:98,column:3}},loc:{start:{line:98,column:21},end:{line:105,column:3}},line:98},6:{name:"(anonymous_6)",decl:{start:{line:106,column:2},end:{line:106,column:3}},loc:{start:{line:106,column:22},end:{line:184,column:3}},line:106},7:{name:"(anonymous_7)",decl:{start:{line:185,column:10},end:{line:185,column:11}},loc:{start:{line:185,column:16},end:{line:188,column:3}},line:185},8:{name:"(anonymous_8)",decl:{start:{line:189,column:19},end:{line:189,column:20}},loc:{start:{line:189,column:31},end:{line:191,column:3}},line:189},9:{name:"(anonymous_9)",decl:{start:{line:192,column:2},end:{line:192,column:3}},loc:{start:{line:192,column:11},end:{line:244,column:3}},line:192},10:{name:"(anonymous_10)",decl:{start:{line:203,column:20},end:{line:203,column:21}},loc:{start:{line:203,column:27},end:{line:203,column:57}},line:203},11:{name:"(anonymous_11)",decl:{start:{line:223,column:20},end:{line:223,column:21}},loc:{start:{line:223,column:30},end:{line:223,column:87}},line:223},12:{name:"(anonymous_12)",decl:{start:{line:247,column:2},end:{line:247,column:3}},loc:{start:{line:247,column:21},end:{line:251,column:3}},line:247},13:{name:"(anonymous_13)",decl:{start:{line:252,column:2},end:{line:252,column:3}},loc:{start:{line:252,column:11},end:{line:310,column:3}},line:252},14:{name:"(anonymous_14)",decl:{start:{line:254,column:60},end:{line:254,column:61}},loc:{start:{line:254,column:74},end:{line:266,column:5}},line:254},15:{name:"(anonymous_15)",decl:{start:{line:261,column:20},end:{line:261,column:21}},loc:{start:{line:261,column:29},end:{line:261,column:93}},line:261},16:{name:"(anonymous_16)",decl:{start:{line:262,column:20},end:{line:262,column:21}},loc:{start:{line:262,column:26},end:{line:262,column:85}},line:262},17:{name:"(anonymous_17)",decl:{start:{line:267,column:61},end:{line:267,column:62}},loc:{start:{line:267,column:75},end:{line:267,column:106}},line:267},18:{name:"(anonymous_18)",decl:{start:{line:267,column:112},end:{line:267,column:113}},loc:{start:{line:267,column:126},end:{line:279,column:5}},line:267},19:{name:"(anonymous_19)",decl:{start:{line:275,column:20},end:{line:275,column:21}},loc:{start:{line:275,column:26},end:{line:275,column:107}},line:275},20:{name:"(anonymous_20)",decl:{start:{line:303,column:23},end:{line:303,column:24}},loc:{start:{line:303,column:45},end:{line:303,column:109}},line:303}},branchMap:{0:{loc:{start:{line:36,column:2},end:{line:40,column:3}},type:"if",locations:[{start:{line:36,column:2},end:{line:40,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:36},1:{loc:{start:{line:37,column:4},end:{line:38,column:30}},type:"if",locations:[{start:{line:37,column:4},end:{line:38,column:30}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:37},2:{loc:{start:{line:41,column:2},end:{line:45,column:3}},type:"if",locations:[{start:{line:41,column:2},end:{line:45,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:41},3:{loc:{start:{line:42,column:4},end:{line:43,column:34}},type:"if",locations:[{start:{line:42,column:4},end:{line:43,column:34}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:42},4:{loc:{start:{line:46,column:2},end:{line:50,column:3}},type:"if",locations:[{start:{line:46,column:2},end:{line:50,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:46},5:{loc:{start:{line:47,column:4},end:{line:48,column:30}},type:"if",locations:[{start:{line:47,column:4},end:{line:48,column:30}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:47},6:{loc:{start:{line:51,column:2},end:{line:57,column:3}},type:"if",locations:[{start:{line:51,column:2},end:{line:57,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:51},7:{loc:{start:{line:52,column:4},end:{line:56,column:5}},type:"if",locations:[{start:{line:52,column:4},end:{line:56,column:5}},{start:{line:54,column:11},end:{line:56,column:5}}],line:52},8:{loc:{start:{line:58,column:2},end:{line:60,column:3}},type:"if",locations:[{start:{line:58,column:2},end:{line:60,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:58},9:{loc:{start:{line:61,column:2},end:{line:63,column:3}},type:"if",locations:[{start:{line:61,column:2},end:{line:63,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:61},10:{loc:{start:{line:107,column:19},end:{line:107,column:50}},type:"binary-expr",locations:[{start:{line:107,column:19},end:{line:107,column:44}},{start:{line:107,column:48},end:{line:107,column:50}}],line:107},11:{loc:{start:{line:107,column:20},end:{line:107,column:36}},type:"binary-expr",locations:[{start:{line:107,column:20},end:{line:107,column:30}},{start:{line:107,column:34},end:{line:107,column:36}}],line:107},12:{loc:{start:{line:109,column:4},end:{line:183,column:5}},type:"switch",locations:[{start:{line:110,column:6},end:{line:114,column:10}},{start:{line:115,column:6},end:{line:120,column:10}},{start:{line:121,column:6},end:{line:125,column:10}},{start:{line:126,column:6},end:{line:132,column:10}},{start:{line:133,column:6},end:{line:137,column:10}},{start:{line:138,column:6},end:{line:144,column:10}},{start:{line:145,column:6},end:{line:149,column:10}},{start:{line:150,column:6},end:{line:156,column:10}},{start:{line:157,column:6},end:{line:167,column:10}},{start:{line:168,column:6},end:{line:180,column:10}},{start:{line:181,column:6},end:{line:182,column:18}}],line:109},13:{loc:{start:{line:118,column:19},end:{line:118,column:42}},type:"binary-expr",locations:[{start:{line:118,column:19},end:{line:118,column:33}},{start:{line:118,column:37},end:{line:118,column:42}}],line:118},14:{loc:{start:{line:124,column:15},end:{line:124,column:72}},type:"binary-expr",locations:[{start:{line:124,column:15},end:{line:124,column:25}},{start:{line:124,column:29},end:{line:124,column:72}}],line:124},15:{loc:{start:{line:129,column:17},end:{line:129,column:80}},type:"binary-expr",locations:[{start:{line:129,column:17},end:{line:129,column:29}},{start:{line:129,column:33},end:{line:129,column:80}}],line:129},16:{loc:{start:{line:130,column:19},end:{line:130,column:38}},type:"binary-expr",locations:[{start:{line:130,column:19},end:{line:130,column:33}},{start:{line:130,column:37},end:{line:130,column:38}}],line:130},17:{loc:{start:{line:131,column:19},end:{line:131,column:39}},type:"binary-expr",locations:[{start:{line:131,column:19},end:{line:131,column:33}},{start:{line:131,column:37},end:{line:131,column:39}}],line:131},18:{loc:{start:{line:136,column:15},end:{line:136,column:72}},type:"binary-expr",locations:[{start:{line:136,column:15},end:{line:136,column:25}},{start:{line:136,column:29},end:{line:136,column:72}}],line:136},19:{loc:{start:{line:141,column:17},end:{line:141,column:80}},type:"binary-expr",locations:[{start:{line:141,column:17},end:{line:141,column:29}},{start:{line:141,column:33},end:{line:141,column:80}}],line:141},20:{loc:{start:{line:142,column:19},end:{line:142,column:38}},type:"binary-expr",locations:[{start:{line:142,column:19},end:{line:142,column:33}},{start:{line:142,column:37},end:{line:142,column:38}}],line:142},21:{loc:{start:{line:143,column:19},end:{line:143,column:39}},type:"binary-expr",locations:[{start:{line:143,column:19},end:{line:143,column:33}},{start:{line:143,column:37},end:{line:143,column:39}}],line:143},22:{loc:{start:{line:148,column:15},end:{line:148,column:72}},type:"binary-expr",locations:[{start:{line:148,column:15},end:{line:148,column:25}},{start:{line:148,column:29},end:{line:148,column:72}}],line:148},23:{loc:{start:{line:153,column:17},end:{line:153,column:80}},type:"binary-expr",locations:[{start:{line:153,column:17},end:{line:153,column:29}},{start:{line:153,column:33},end:{line:153,column:80}}],line:153},24:{loc:{start:{line:154,column:19},end:{line:154,column:38}},type:"binary-expr",locations:[{start:{line:154,column:19},end:{line:154,column:33}},{start:{line:154,column:37},end:{line:154,column:38}}],line:154},25:{loc:{start:{line:155,column:19},end:{line:155,column:39}},type:"binary-expr",locations:[{start:{line:155,column:19},end:{line:155,column:33}},{start:{line:155,column:37},end:{line:155,column:39}}],line:155}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0,0,0,0,0,0,0,0,0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0],17:[0,0],18:[0,0],19:[0,0],20:[0,0],21:[0,0],22:[0,0],23:[0,0],24:[0,0],25:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalSources.tsx"],names:[],mappings:"AA+BU,cACA,YADA;AA/BV,OAAO,WAAW;AAClB,SAAQ,oBAAoB,gBAAe;AAC3C,OAAO,YAAY;AAGnB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,iBAAiB;AACxB,OAAO,4BAA4C;AAEnD,OAAO,WAAW;AAClB,SAAS,cAAc,WAAW,oBAAoB;AACtD,OAAO,mBAAmB;AAU1B,MAAM,qBAAqB,MAAM,UAA6B;AAAA,EAC5D,SAAS;AACP,WAAO,oBAAC,SAAI,WAAU,0BACpB;AAAA,MAAC;AAAA;AAAA,QACC,WAAU;AAAA,QACV,SAAS,MAAM,KAAK,MAAM,SAAS,KAAK,MAAM,EAAE;AAAA,QAEhD;AAAA,+BAAC,SAAI,WAAU,+BACb;AAAA,gCAAC,OAAE,WAAU,+BAA+B,eAAK,MAAM,OAAM;AAAA,YAC7D,qBAAC,OAAE,WAAU,6BAA4B;AAAA;AAAA,cAAE,KAAK,MAAM;AAAA,eAAG;AAAA,aAC3D;AAAA,UACA,oBAAC,UAAK,WAAU,kBAAiB;AAAA,UACjC,oBAAC,sBAAmB;AAAA;AAAA;AAAA,IACtB,GACF;AAAA,EACF;AACF;AAEA,SAAS,WAAW,QAA6B;AAC/C,MAAG,OAAO,SAAS,UAAU;AAC3B,QAAG,OAAO;AAAO,aAAO;AACxB,WAAO;AAAA,EACT;AACA,MAAG,OAAO,SAAS,cAAc;AAC/B,QAAG,OAAO;AAAO,aAAO;AACxB,WAAO;AAAA,EACT;AACA,MAAG,OAAO,SAAS,UAAU;AAC3B,QAAG,OAAO;AAAO,aAAO;AACxB,WAAO;AAAA,EACT;AACA,MAAG,OAAO,SAAS,WAAW;AAC5B,QAAI,OAAO,OAAO,SAAU,UAAU;AACpC,aAAO;AAAA,IACT,OACK;AACH,aAAO;AAAA,IACT;AAAA,EACF;AACA,MAAG,OAAO,SAAS,SAAS;AAC1B,WAAO;AAAA,EACT;AACA,MAAG,OAAO,SAAS,SAAS;AAC1B,WAAO;AAAA,EACT;AACA,SAAO;AACT;AASA,MAAM,qCAAqC,MAAM,UAA6C;AAAA,EAC5F,SAAS;AACP,WAAO,qBAAC,SAAI,WAAU,sCACpB;AAAA,2BAAC,SAAI,WAAU,6CACb;AAAA,6BAAC,UAAK,WAAU,gDAA+C;AAAA;AAAA,UAAE,KAAK,MAAM;AAAA,WAAS;AAAA,QACrF,oBAAC,UAAK,WAAU,kBAAiB;AAAA,QACjC;AAAA,UAAC;AAAA;AAAA,YACC,cAAY,WAAW,KAAK,MAAM,QAAQ;AAAA,YAC1C,WAAU;AAAA,YACV,SAAS,MAAK,KAAK,MAAM,SAAS,KAAK,MAAM,QAAQ;AAAA,YACrD,OAAO,EAAC,iBAAiB,cAAa;AAAA,YAEtC,8BAAC,YAAS;AAAA;AAAA,QACZ;AAAA,SACF;AAAA,MACA,oBAAC,SAAI,WAAU,8CACb;AAAA,QAAC;AAAA;AAAA,UACC,UAAU,KAAK,MAAM;AAAA,UACrB,MAAM,WAAW,KAAK,MAAM,MAAM;AAAA,UAClC,QAAQ,KAAK,MAAM;AAAA;AAAA,MACrB,GACF;AAAA,OACF;AAAA,EACF;AACF;AAYA,MAAM,kBAAkB,MAAM,UAA0C;AAAA,EACtE,YAAY,OAAuB;AACjC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,MAAM;AAAA,MACN,UAAU,MAAM,WAAW;AAAA,MAC3B,QAAQ,KAAK,cAAc,iBAAiB;AAAA,IAC9C;AAAA,EACF;AAAA,EAEA,cAAc,MAAuC;AACnD,UAAM,UAAU,KAAK,SAAS,CAAC,GAAG,UAAU,CAAC;AAC7C,UAAM,EAAC,SAAQ,IAAI,OAAO;AAE1B,YAAO,MAAM;AAAA,MACb,KAAK;AAAe,eAAO;AAAA,UACzB,MAAM;AAAA,UACN,MAAM,GAAG,QAAQ;AAAA,QACnB;AAAA,MACA,KAAK;AAAgB,eAAO;AAAA,UAC1B,MAAM;AAAA,UACN,SAAU,OAAsC,WAAW;AAAA,UAC3D,MAAM;AAAA,QACR;AAAA,MACA,KAAK;AAAmB,eAAO;AAAA,UAC7B,MAAM;AAAA,UACN,KAAM,OAAqC,OAAO,GAAG,QAAQ;AAAA,QAC/D;AAAA,MACA,KAAK;AAAkB,eAAO;AAAA,UAC5B,MAAM;AAAA,UACN,OAAQ,OAAqC,SAAS,CAAC,GAAG,QAAQ,kCAAkC;AAAA,UACpG,SAAU,OAAqC,WAAW;AAAA,UAC1D,SAAU,OAAqC,WAAW;AAAA,QAC5D;AAAA,MACA,KAAK;AAAmB,eAAO;AAAA,UAC7B,MAAM;AAAA,UACN,KAAM,OAAqC,OAAO,GAAG,QAAQ;AAAA,QAC/D;AAAA,MACA,KAAK;AAAkB,eAAO;AAAA,UAC5B,MAAM;AAAA,UACN,OAAQ,OAAqC,SAAS,CAAC,GAAG,QAAQ,kCAAkC;AAAA,UACpG,SAAU,OAAqC,WAAW;AAAA,UAC1D,SAAU,OAAqC,WAAW;AAAA,QAC5D;AAAA,MACA,KAAK;AAAuB,eAAO;AAAA,UACjC,MAAM;AAAA,UACN,KAAM,OAAwC,OAAO,GAAG,QAAQ;AAAA,QAClE;AAAA,MACA,KAAK;AAAsB,eAAO;AAAA,UAChC,MAAM;AAAA,UACN,OAAQ,OAAwC,SAAS,CAAC,GAAG,QAAQ,kCAAkC;AAAA,UACvG,SAAU,OAAwC,WAAW;AAAA,UAC7D,SAAU,OAAwC,WAAW;AAAA,QAC/D;AAAA,MACA,KAAK;AAAS,eAAO;AAAA,UACnB,MAAM;AAAA,UACN,KAAK,GAAG,QAAQ;AAAA,UAChB,aAAa;AAAA,YACX,CAAC,GAAE,CAAC;AAAA,YACJ,CAAC,GAAE,CAAC;AAAA,YACJ,CAAC,GAAE,CAAC;AAAA,YACJ,CAAC,GAAE,CAAC;AAAA,UACN;AAAA,QACF;AAAA,MACA,KAAK;AAAS,eAAO;AAAA,UACnB,MAAM;AAAA,UACN,MAAM;AAAA,YACJ,GAAG,QAAQ;AAAA,UACb;AAAA,UACA,aAAa;AAAA,YACX,CAAC,GAAE,CAAC;AAAA,YACJ,CAAC,GAAE,CAAC;AAAA,YACJ,CAAC,GAAE,CAAC;AAAA,YACJ,CAAC,GAAE,CAAC;AAAA,UACN;AAAA,QACF;AAAA,MACA;AAAS,eAAO,CAAC;AAAA,IACjB;AAAA,EACF;AAAA,EAEA,QAAQ,MAAM;AACZ,UAAM,EAAC,QAAQ,SAAQ,IAAI,KAAK;AAChC,SAAK,MAAM,MAAM,UAAU,MAAM;AAAA,EACnC;AAAA,EAEA,iBAAiB,CAAC,WAAgC;AAChD,SAAK,SAAS,EAAC,OAAM,CAAC;AAAA,EACxB;AAAA,EAEA,SAAS;AAQP,UAAM,sBAAsB;AAAA,MAC1B,KAAK,OAAO,cAAc,KAAK;AAAA,IACjC;AAEA,WAAO,qBAAC,SAAI,WAAU,uBACpB;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW,EAAC,KAAK,yFAAwF;AAAA,UACzG,OAAO,KAAK,MAAM;AAAA,UAClB,UAAU,CAAC,MAAc,KAAK,SAAS,EAAE,UAAU,EAAC,CAAC;AAAA;AAAA,MACvD;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,UACP,WAAW;AAAA,UACX,SAAS;AAAA,YACP,CAAC,gBAAgB,gBAAgB;AAAA,YACjC,CAAC,eAAe,eAAe;AAAA,YAC/B,CAAC,mBAAmB,uBAAuB;AAAA,YAC3C,CAAC,kBAAkB,mBAAmB;AAAA,YACtC,CAAC,mBAAmB,uBAAuB;AAAA,YAC3C,CAAC,kBAAkB,kBAAkB;AAAA,YACrC,CAAC,uBAAuB,2BAA2B;AAAA,YACnD,CAAC,sBAAsB,uBAAuB;AAAA,YAC9C,CAAC,SAAS,OAAO;AAAA,YACjB,CAAC,SAAS,OAAO;AAAA,UACnB;AAAA,UACA,UAAU,UAAQ,KAAK,SAAS,EAAC,MAA0B,QAAQ,KAAK,cAAc,IAAkB,EAAC,CAAC;AAAA,UAC1G,OAAO,KAAK,MAAM;AAAA;AAAA,MACpB;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,UAAU,KAAK;AAAA,UACf,MAAM,KAAK,MAAM;AAAA,UACjB,QAAQ,KAAK,MAAM;AAAA;AAAA,MACrB;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,WAAU;AAAA,UACV,SAAS,KAAK;AAAA,UACf;AAAA;AAAA,MAED;AAAA,OACF;AAAA,EACF;AACF;AASA,qBAAqB,qBAAqB,MAAM,UAA6B;AAAA,EAC3E,WAAW,QAAqE;AAC9E,UAAM,iBAAiB,EAAC,GAAG,OAAM;AACjC,WAAO,eAAe,OAAO;AAC7B,WAAO;AAAA,EACT;AAAA,EAEA,SAAS;AACP,UAAM,WAAW,KAAK,MAAM;AAC5B,UAAM,gBAAgB,OAAO,KAAK,SAAS,OAAO,EAAE,IAAI,cAAY;AAClE,YAAM,SAAS,SAAS,QAAQ,QAAQ;AACxC,aAAO;AAAA,QAAC;AAAA;AAAA,UAEN;AAAA,UACA;AAAA,UACA,UAAU,CAAC,QAA6B,KAAK,MAAM,eAAe,aAAa,UAAU,UAAU,GAAG,CAAC;AAAA,UACvG,UAAU,MAAM,KAAK,MAAM,eAAe,aAAa,UAAU,QAAQ,CAAC;AAAA;AAAA,QAJrE;AAAA,MAKP;AAAA,IACF,CAAC;AAED,UAAM,iBAAiB,OAAO,KAAK,aAAa,EAAE,OAAO,CAAC,aAAqB,EAAE,YAAY,SAAS,QAAQ,EAAE,IAAI,CAAC,aAAqB;AACxI,YAAM,SAAS,cAAc,QAAsC;AACnE,aAAO;AAAA,QAAC;AAAA;AAAA,UAEN,IAAI;AAAA,UACJ,MAAM,OAAO;AAAA,UACb,OAAO,OAAO;AAAA,UACd,UAAU,MAAM,KAAK,MAAM,eAAe,UAAU,UAAU,UAAU,KAAK,WAAW,MAAM,CAAC,CAAC;AAAA;AAAA,QAJ3F;AAAA,MAKP;AAAA,IACF,CAAC;AAED,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAO;AAAA,QAEP;AAAA,+BAAC,aAAQ,WAAU,0BACjB;AAAA,gCAAC,QAAG,4BAAc;AAAA,YACjB;AAAA,aACH;AAAA,UAEA,qBAAC,aAAQ,WAAU,0BACjB;AAAA,gCAAC,QAAG,kCAAoB;AAAA,YACxB,oBAAC,OAAE,sEAEH;AAAA,YACA,oBAAC,SAAI,WAAU,2BAA0B,OAAO,EAAC,UAAU,IAAG,GAC3D,0BACH;AAAA,aACF;AAAA,UAEA,qBAAC,aAAQ,WAAU,0BACjB;AAAA,gCAAC,QAAG,4BAAc;AAAA,YAClB,oBAAC,OAAE,0GAA4F;AAAA,YAC/F;AAAA,cAAC;AAAA;AAAA,gBACC,OAAO,CAAC,UAAkB,WAAgC,KAAK,MAAM,eAAe,UAAU,UAAU,UAAU,MAAM,CAAC;AAAA;AAAA,YAC3H;AAAA,aACF;AAAA;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"0cdb4eacb2560c191df467eefb0fb2a3bf6cb962"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Yt=function(){return s},s}Yt();class jEe extends bn.Component{render(){return Yt().f[0]++,Yt().s[0]++,N.jsx("div",{className:"maputnik-public-source",children:N.jsxs(Ka,{className:"maputnik-public-source-select",onClick:()=>(Yt().f[1]++,Yt().s[1]++,this.props.onSelect(this.props.id)),children:[N.jsxs("div",{className:"maputnik-public-source-info",children:[N.jsx("p",{className:"maputnik-public-source-name",children:this.props.title}),N.jsxs("p",{className:"maputnik-public-source-id",children:["#",this.props.id]})]}),N.jsx("span",{className:"maputnik-space"}),N.jsx(qR,{})]})})}}function WEe(e){return Yt().f[2]++,Yt().s[2]++,e.type==="raster"?(Yt().b[0][0]++,Yt().s[3]++,e.tiles?(Yt().b[1][0]++,Yt().s[4]++,"tilexyz_raster"):(Yt().b[1][1]++,Yt().s[5]++,"tilejson_raster")):(Yt().b[0][1]++,Yt().s[6]++,e.type==="raster-dem"?(Yt().b[2][0]++,Yt().s[7]++,e.tiles?(Yt().b[3][0]++,Yt().s[8]++,"tilexyz_raster-dem"):(Yt().b[3][1]++,Yt().s[9]++,"tilejson_raster-dem")):(Yt().b[2][1]++,Yt().s[10]++,e.type==="vector"?(Yt().b[4][0]++,Yt().s[11]++,e.tiles?(Yt().b[5][0]++,Yt().s[12]++,"tilexyz_vector"):(Yt().b[5][1]++,Yt().s[13]++,"tilejson_vector")):(Yt().b[4][1]++,Yt().s[14]++,e.type==="geojson"?(Yt().b[6][0]++,Yt().s[15]++,typeof e.data=="string"?(Yt().b[7][0]++,Yt().s[16]++,"geojson_url"):(Yt().b[7][1]++,Yt().s[17]++,"geojson_json")):(Yt().b[6][1]++,Yt().s[18]++,e.type==="image"?(Yt().b[8][0]++,Yt().s[19]++,"image"):(Yt().b[8][1]++,Yt().s[20]++,e.type==="video"?(Yt().b[9][0]++,Yt().s[21]++,"video"):(Yt().b[9][1]++,Yt().s[22]++,null))))))}class NEe extends bn.Component{render(){return Yt().f[3]++,Yt().s[23]++,N.jsxs("div",{className:"maputnik-active-source-type-editor",children:[N.jsxs("div",{className:"maputnik-active-source-type-editor-header",children:[N.jsxs("span",{className:"maputnik-active-source-type-editor-header-id",children:["#",this.props.sourceId]}),N.jsx("span",{className:"maputnik-space"}),N.jsx(Ka,{"aria-label":`Remove '${this.props.sourceId}' source`,className:"maputnik-active-source-type-editor-header-delete",onClick:()=>(Yt().f[4]++,Yt().s[24]++,this.props.onDelete(this.props.sourceId)),style:{backgroundColor:"transparent"},children:N.jsx(Ly,{})})]}),N.jsx("div",{className:"maputnik-active-source-type-editor-content",children:N.jsx(lG,{onChange:this.props.onChange,mode:WEe(this.props.source),source:this.props.source})})]})}}class GEe extends bn.Component{constructor(t){Yt().f[5]++,Yt().s[25]++;super(t);nn(this,"onAdd",(Yt().s[41]++,()=>{Yt().f[7]++;const{source:t,sourceId:r}=(Yt().s[42]++,this.state);Yt().s[43]++,this.props.onAdd(r,t)}));nn(this,"onChangeSource",(Yt().s[44]++,t=>{Yt().f[8]++,Yt().s[45]++,this.setState({source:t})}));Yt().s[26]++,this.state={mode:"tilejson_vector",sourceId:vu.generateId(),source:this.defaultSource("tilejson_vector")}}defaultSource(t){Yt().f[6]++;const r=(Yt().s[27]++,Yt().b[10][0]++,(Yt().b[11][0]++,this.state||(Yt().b[11][1]++,{})).source||(Yt().b[10][1]++,{})),{protocol:i}=(Yt().s[28]++,window.location);switch(Yt().s[29]++,t){case"geojson_url":return Yt().b[12][0]++,Yt().s[30]++,{type:"geojson",data:`${i}//localhost:3000/geojson.json`};case"geojson_json":return Yt().b[12][1]++,Yt().s[31]++,{type:"geojson",cluster:(Yt().b[13][0]++,r.cluster||(Yt().b[13][1]++,!1)),data:""};case"tilejson_vector":return Yt().b[12][2]++,Yt().s[32]++,{type:"vector",url:(Yt().b[14][0]++,r.url||(Yt().b[14][1]++,`${i}//localhost:3000/tilejson.json`))};case"tilexyz_vector":return Yt().b[12][3]++,Yt().s[33]++,{type:"vector",tiles:(Yt().b[15][0]++,r.tiles||(Yt().b[15][1]++,[`${i}//localhost:3000/{x}/{y}/{z}.pbf`])),minzoom:(Yt().b[16][0]++,r.minzoom||(Yt().b[16][1]++,0)),maxzoom:(Yt().b[17][0]++,r.maxzoom||(Yt().b[17][1]++,14))};case"tilejson_raster":return Yt().b[12][4]++,Yt().s[34]++,{type:"raster",url:(Yt().b[18][0]++,r.url||(Yt().b[18][1]++,`${i}//localhost:3000/tilejson.json`))};case"tilexyz_raster":return Yt().b[12][5]++,Yt().s[35]++,{type:"raster",tiles:(Yt().b[19][0]++,r.tiles||(Yt().b[19][1]++,[`${i}//localhost:3000/{x}/{y}/{z}.pbf`])),minzoom:(Yt().b[20][0]++,r.minzoom||(Yt().b[20][1]++,0)),maxzoom:(Yt().b[21][0]++,r.maxzoom||(Yt().b[21][1]++,14))};case"tilejson_raster-dem":return Yt().b[12][6]++,Yt().s[36]++,{type:"raster-dem",url:(Yt().b[22][0]++,r.url||(Yt().b[22][1]++,`${i}//localhost:3000/tilejson.json`))};case"tilexyz_raster-dem":return Yt().b[12][7]++,Yt().s[37]++,{type:"raster-dem",tiles:(Yt().b[23][0]++,r.tiles||(Yt().b[23][1]++,[`${i}//localhost:3000/{x}/{y}/{z}.pbf`])),minzoom:(Yt().b[24][0]++,r.minzoom||(Yt().b[24][1]++,0)),maxzoom:(Yt().b[25][0]++,r.maxzoom||(Yt().b[25][1]++,14))};case"image":return Yt().b[12][8]++,Yt().s[38]++,{type:"image",url:`${i}//localhost:3000/image.png`,coordinates:[[0,0],[0,0],[0,0],[0,0]]};case"video":return Yt().b[12][9]++,Yt().s[39]++,{type:"video",urls:[`${i}//localhost:3000/movie.mp4`],coordinates:[[0,0],[0,0],[0,0],[0,0]]};default:return Yt().b[12][10]++,Yt().s[40]++,{}}}render(){Yt().f[9]++;const t=(Yt().s[46]++,{doc:Ji.source_vector.type.doc});return Yt().s[47]++,N.jsxs("div",{className:"maputnik-add-source",children:[N.jsx(uh,{label:"Source ID",fieldSpec:{doc:"Unique ID that identifies the source and is used in the layer to reference the source."},value:this.state.sourceId,onChange:r=>(Yt().f[10]++,Yt().s[48]++,this.setState({sourceId:r}))}),N.jsx(V8,{label:"Source Type",fieldSpec:t,options:[["geojson_json","GeoJSON (JSON)"],["geojson_url","GeoJSON (URL)"],["tilejson_vector","Vector (TileJSON URL)"],["tilexyz_vector","Vector (XYZ URLs)"],["tilejson_raster","Raster (TileJSON URL)"],["tilexyz_raster","Raster (XYZ URL)"],["tilejson_raster-dem","Raster DEM (TileJSON URL)"],["tilexyz_raster-dem","Raster DEM (XYZ URLs)"],["image","Image"],["video","Video"]],onChange:r=>(Yt().f[11]++,Yt().s[49]++,this.setState({mode:r,source:this.defaultSource(r)})),value:this.state.mode}),N.jsx(lG,{onChange:this.onChangeSource,mode:this.state.mode,source:this.state.source}),N.jsx(Ka,{className:"maputnik-add-source-button",onClick:this.onAdd,children:"Add Source"})]})}}class QEe extends bn.Component{stripTitle(n){Yt().f[12]++;const t=(Yt().s[50]++,{...n});return Yt().s[51]++,delete t.title,Yt().s[52]++,t}render(){Yt().f[13]++;const n=(Yt().s[53]++,this.props.mapStyle),t=(Yt().s[54]++,Object.keys(n.sources).map(i=>{Yt().f[14]++;const o=(Yt().s[55]++,n.sources[i]);return Yt().s[56]++,N.jsx(NEe,{sourceId:i,source:o,onChange:s=>(Yt().f[15]++,Yt().s[57]++,this.props.onStyleChanged(uG(n,i,s))),onDelete:()=>(Yt().f[16]++,Yt().s[58]++,this.props.onStyleChanged(DEe(n,i)))},i)})),r=(Yt().s[59]++,Object.keys(MP).filter(i=>(Yt().f[17]++,Yt().s[60]++,!(i in n.sources))).map(i=>{Yt().f[18]++;const o=(Yt().s[61]++,MP[i]);return Yt().s[62]++,N.jsx(jEe,{id:i,type:o.type,title:o.title,onSelect:()=>(Yt().f[19]++,Yt().s[63]++,this.props.onStyleChanged(wP(n,i,this.stripTitle(o))))},i)}));return Yt().s[64]++,N.jsxs(_f,{"data-wd-key":"modal:sources",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Sources",children:[N.jsxs("section",{className:"maputnik-modal-section",children:[N.jsx("h1",{children:"Active Sources"}),t]}),N.jsxs("section",{className:"maputnik-modal-section",children:[N.jsx("h1",{children:"Choose Public Source"}),N.jsx("p",{children:"Add one of the publicly available sources to your style."}),N.jsx("div",{className:"maputnik-public-sources",style:{maxWidth:500},children:r})]}),N.jsxs("section",{className:"maputnik-modal-section",children:[N.jsx("h1",{children:"Add New Source"}),N.jsx("p",{children:"Add a new source to your style. You can only choose the source type and id at creation time!"}),N.jsx(GEe,{onAdd:(i,o)=>(Yt().f[20]++,Yt().s[65]++,this.props.onStyleChanged(wP(n,i,o)))})]})]})}}var AG={};Object.defineProperty(AG,"__esModule",{value:!0});var $Ee=Object.assign||function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},YEe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},qEe=function(){function e(n,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}}return function(n,t,r){return t&&e(n.prototype,t),r&&e(n,r),n}}(),VEe=kr,lS=JEe(VEe),HEe=Rm,ZEe=XEe(HEe);function XEe(e){return e&&e.__esModule?e:{default:e}}function JEe(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t]);return n.default=e,n}function eOe(e,n){var t={};for(var r in e)n.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}function tOe(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function nOe(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function rOe(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var iOe=function(e){rOe(n,e);function n(t){tOe(this,n);var r=nOe(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,t));r.handleChange=function(o){var s=Array.prototype.slice.call(o.target.files),a=(r.props.as||"url").toLowerCase();Promise.all(s.map(function(f){return new Promise(function(g,x){var k=new FileReader;switch(k.onload=function(B){g([B,f])},a){case"binary":{k.readAsBinaryString(f);break}case"buffer":{k.readAsArrayBuffer(f);break}case"text":{k.readAsText(f);break}case"url":{k.readAsDataURL(f);break}}})})).then(function(f){r.props.onChange(o,f)})},r.triggerInput=function(){var o=ZEe.default.findDOMNode(r._reactFileReaderInput);o&&o.click()};var i=(typeof window>"u"?"undefined":YEe(window))==="object"?window:{};return(!i.File||!i.FileReader||!i.FileList||!i.Blob)&&console.warn("[react-file-reader-input] Some file APIs detected as not supported. File reader functionality may not fully work."),r}return qEe(n,[{key:"render",value:function(){var r=this,i=this.props;i.as;var o=i.children,s=i.style,a=eOe(i,["as","children","style"]),f=o?{position:"absolute",top:"-9999px"}:{};return lS.createElement("div",{className:"_react-file-reader-input",onClick:this.triggerInput,style:s},lS.createElement("input",$Ee({},a,{type:"file",ref:function(x){r._reactFileReaderInput=x},onChange:this.handleChange,onClick:function(){r._reactFileReaderInput.value=null},style:f})),o)}}]),n}(lS.Component),oOe=AG.default=iOe;function pd(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalLoading.tsx",n="c730187d836bc577ee534587d8c8df17ae09966b",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalLoading.tsx",statementMap:{0:{start:{line:7,column:4},end:{line:7,column:24}},1:{start:{line:10,column:4},end:{line:27,column:6}},2:{start:{line:18,column:26},end:{line:18,column:42}},3:{start:{line:21,column:28},end:{line:21,column:49}},4:{start:{line:24,column:137},end:{line:24,column:159}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:6,column:2},end:{line:6,column:3}},loc:{start:{line:6,column:21},end:{line:8,column:3}},line:6},1:{name:"(anonymous_1)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:11},end:{line:28,column:3}},line:9},2:{name:"(anonymous_2)",decl:{start:{line:18,column:19},end:{line:18,column:20}},loc:{start:{line:18,column:26},end:{line:18,column:42}},line:18},3:{name:"(anonymous_3)",decl:{start:{line:21,column:22},end:{line:21,column:23}},loc:{start:{line:21,column:28},end:{line:21,column:49}},line:21},4:{name:"(anonymous_4)",decl:{start:{line:24,column:130},end:{line:24,column:131}},loc:{start:{line:24,column:137},end:{line:24,column:159}},line:24}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0},f:{0:0,1:0,2:0,3:0,4:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalLoading.tsx"],names:[],mappings:"AAqBW,SAWL,KAXK;AArBX,OAAO,WAAW;AAElB,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAWlB,qBAAqB,qBAAqB,MAAM,UAA6B;AAAA,EAC3E,gBAAgB,GAAU;AAExB,MAAE,gBAAgB;AAAA,EACpB;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,oBAAoB;AAAA,QACpB,eAAe;AAAA;AAAA,UAEb,SAAS,CAAC,MAAa,cAAc,CAAC;AAAA,QACxC;AAAA,QACA,OAAO,KAAK,MAAM;AAAA,QAClB,cAAc,MAAM,KAAK,MAAM,SAAS;AAAA,QAExC;AAAA,8BAAC,OACE,eAAK,MAAM,SACd;AAAA,UACA,oBAAC,OAAE,WAAU,4BACX,8BAAC,eAAY,SAAS,CAAC,MAAM,KAAK,MAAM,SAAS,CAAC,GAAG,oBAErD,GACF;AAAA;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"c730187d836bc577ee534587d8c8df17ae09966b"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return pd=function(){return s},s}pd();class aOe extends bn.Component{underlayOnClick(n){pd().f[0]++,pd().s[0]++,n.stopPropagation()}render(){return pd().f[1]++,pd().s[1]++,N.jsxs(_f,{"data-wd-key":"modal:loading",isOpen:this.props.isOpen,underlayClickExits:!1,underlayProps:{onClick:n=>(pd().f[2]++,pd().s[2]++,underlayProps(n))},title:this.props.title,onOpenToggle:()=>(pd().f[3]++,pd().s[3]++,this.props.onCancel()),children:[N.jsx("p",{children:this.props.message}),N.jsx("p",{className:"maputnik-dialog__buttons",children:N.jsx(Ka,{onClick:n=>(pd().f[4]++,pd().s[4]++,this.props.onCancel(n)),children:"Cancel"})})]})}}const cG=[{id:"osm-liberty",title:"OSM Liberty",url:"https://maputnik.github.io/osm-liberty/style.json",thumbnail:"https://maputnik.github.io/thumbnails/osm-liberty.png"},{id:"maptiler-basic-gl-style",title:"Maptiler Basic",url:"https://cdn.jsdelivr.net/gh/openmaptiles/klokantech-basic-gl-style@v1.9/style.json",thumbnail:"https://maputnik.github.io/thumbnails/klokantech-basic.png"},{id:"dark-matter",title:"Dark Matter",url:"https://cdn.jsdelivr.net/gh/openmaptiles/dark-matter-gl-style@v1.8/style.json",thumbnail:"https://maputnik.github.io/thumbnails/dark-matter.png"},{id:"positron",title:"Positron",url:"https://cdn.jsdelivr.net/gh/openmaptiles/positron-gl-style@v1.8/style.json",thumbnail:"https://maputnik.github.io/thumbnails/positron.png"},{id:"osm-bright",title:"OSM Bright",url:"https://cdn.jsdelivr.net/gh/openmaptiles/osm-bright-gl-style@v1.9/style.json",thumbnail:"https://maputnik.github.io/thumbnails/osm-bright.png"},{id:"maptiler-toner-gl-style",title:"Toner",url:"https://cdn.jsdelivr.net/gh/openmaptiles/toner-gl-style@339e5b7/style.json",thumbnail:"https://maputnik.github.io/thumbnails/toner.png"},{id:"os-zoomstack-outdoor",title:"Zoomstack Outdoor",url:"https://s3-eu-west-1.amazonaws.com/tiles.os.uk/v2/styles/open-zoomstack-outdoor/style.json",thumbnail:"https://maputnik.github.io/thumbnails/os-zoomstack-outdoor.png"},{id:"os-zoomstack-road",title:"Zoomstack Road",url:"https://s3-eu-west-1.amazonaws.com/tiles.os.uk/v2/styles/open-zoomstack-road/style.json",thumbnail:"https://maputnik.github.io/thumbnails/os-zoomstack-road.png"},{id:"os-zoomstack-light",title:"Zoomstack Light",url:"https://s3-eu-west-1.amazonaws.com/tiles.os.uk/v2/styles/open-zoomstack-light/style.json",thumbnail:"https://maputnik.github.io/thumbnails/os-zoomstack-light.png"},{id:"os-zoomstack-night",title:"Zoomstack Night",url:"https://s3-eu-west-1.amazonaws.com/tiles.os.uk/v2/styles/open-zoomstack-night/style.json",thumbnail:"https://maputnik.github.io/thumbnails/os-zoomstack-night.png"},{id:"empty-style",title:"Empty Style",url:"https://cdn.jsdelivr.net/gh/maputnik/editor@9cf74ca405d2be0608b57db8109cf3a6af5b9f49/src/config/empty-style.json",thumbnail:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAECAQAAAAHDYbIAAAAEUlEQVR42mP8/58BDhiJ4wAA974H/U5Xe1oAAAAASUVORK5CYII="}];function $n(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalOpen.tsx",n="6f55b81c74a9657afee47a2c5820a136d93a0f65",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalOpen.tsx",statementMap:{0:{start:{line:14,column:4},end:{line:37,column:9}},1:{start:{line:19,column:23},end:{line:19,column:58}},2:{start:{line:42,column:4},end:{line:42,column:17}},3:{start:{line:43,column:4},end:{line:45,column:6}},4:{start:{line:48,column:4},end:{line:50,column:7}},5:{start:{line:53,column:4},end:{line:54,column:26}},6:{start:{line:54,column:6},end:{line:54,column:26}},7:{start:{line:55,column:4},end:{line:61,column:5}},8:{start:{line:56,column:6},end:{line:56,column:39}},9:{start:{line:57,column:6},end:{line:60,column:9}},10:{start:{line:63,column:18},end:{line:100,column:3}},11:{start:{line:64,column:4},end:{line:64,column:22}},12:{start:{line:65,column:19},end:{line:65,column:24}},13:{start:{line:66,column:4},end:{line:91,column:7}},14:{start:{line:70,column:6},end:{line:70,column:29}},15:{start:{line:72,column:6},end:{line:74,column:7}},16:{start:{line:73,column:8},end:{line:73,column:15}},17:{start:{line:75,column:6},end:{line:78,column:9}},18:{start:{line:79,column:23},end:{line:79,column:54}},19:{start:{line:80,column:6},end:{line:80,column:48}},20:{start:{line:81,column:6},end:{line:81,column:39}},21:{start:{line:82,column:6},end:{line:82,column:26}},22:{start:{line:84,column:6},end:{line:88,column:9}},23:{start:{line:89,column:6},end:{line:89,column:25}},24:{start:{line:90,column:6},end:{line:90,column:61}},25:{start:{line:92,column:4},end:{line:99,column:7}},26:{start:{line:95,column:10},end:{line:95,column:26}},27:{start:{line:101,column:16},end:{line:104,column:3}},28:{start:{line:102,column:4},end:{line:102,column:23}},29:{start:{line:103,column:4},end:{line:103,column:44}},30:{start:{line:105,column:13},end:{line:125,column:3}},31:{start:{line:106,column:21},end:{line:106,column:29}},32:{start:{line:107,column:19},end:{line:107,column:35}},33:{start:{line:108,column:4},end:{line:108,column:22}},34:{start:{line:109,column:4},end:{line:109,column:37}},35:{start:{line:110,column:4},end:{line:123,column:6}},36:{start:{line:112,column:6},end:{line:119,column:7}},37:{start:{line:113,column:8},end:{line:113,column:48}},38:{start:{line:115,column:8},end:{line:117,column:11}},39:{start:{line:118,column:8},end:{line:118,column:15}},40:{start:{line:120,column:6},end:{line:120,column:53}},41:{start:{line:121,column:6},end:{line:121,column:39}},42:{start:{line:122,column:6},end:{line:122,column:26}},43:{start:{line:124,column:4},end:{line:124,column:50}},44:{start:{line:124,column:28},end:{line:124,column:49}},45:{start:{line:127,column:4},end:{line:129,column:7}},46:{start:{line:130,column:4},end:{line:130,column:22}},47:{start:{line:131,column:4},end:{line:131,column:30}},48:{start:{line:133,column:16},end:{line:137,column:3}},49:{start:{line:134,column:4},end:{line:136,column:7}},50:{start:{line:139,column:25},end:{line:150,column:6}},51:{start:{line:140,column:6},end:{line:149,column:8}},52:{start:{line:152,column:4},end:{line:157,column:5}},53:{start:{line:153,column:6},end:{line:156,column:11}},54:{start:{line:155,column:61},end:{line:155,column:78}},55:{start:{line:158,column:4},end:{line:224,column:9}},56:{start:{line:164,column:30},end:{line:164,column:49}},57:{start:{line:220,column:27},end:{line:220,column:56}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:13,column:2},end:{line:13,column:3}},loc:{start:{line:13,column:11},end:{line:38,column:3}},line:13},1:{name:"(anonymous_1)",decl:{start:{line:19,column:17},end:{line:19,column:18}},loc:{start:{line:19,column:23},end:{line:19,column:58}},line:19},2:{name:"(anonymous_2)",decl:{start:{line:41,column:2},end:{line:41,column:3}},loc:{start:{line:41,column:21},end:{line:46,column:3}},line:41},3:{name:"(anonymous_3)",decl:{start:{line:47,column:2},end:{line:47,column:3}},loc:{start:{line:47,column:15},end:{line:51,column:3}},line:47},4:{name:"(anonymous_4)",decl:{start:{line:52,column:2},end:{line:52,column:3}},loc:{start:{line:52,column:27},end:{line:62,column:3}},line:52},5:{name:"(anonymous_5)",decl:{start:{line:63,column:18},end:{line:63,column:19}},loc:{start:{line:63,column:32},end:{line:100,column:3}},line:63},6:{name:"(anonymous_6)",decl:{start:{line:69,column:12},end:{line:69,column:13}},loc:{start:{line:69,column:31},end:{line:71,column:5}},line:69},7:{name:"(anonymous_7)",decl:{start:{line:71,column:12},end:{line:71,column:13}},loc:{start:{line:71,column:22},end:{line:83,column:5}},line:71},8:{name:"(anonymous_8)",decl:{start:{line:83,column:13},end:{line:83,column:14}},loc:{start:{line:83,column:22},end:{line:91,column:5}},line:83},9:{name:"(anonymous_9)",decl:{start:{line:94,column:15},end:{line:94,column:16}},loc:{start:{line:94,column:26},end:{line:96,column:9}},line:94},10:{name:"(anonymous_10)",decl:{start:{line:101,column:16},end:{line:101,column:17}},loc:{start:{line:101,column:23},end:{line:104,column:3}},line:101},11:{name:"(anonymous_11)",decl:{start:{line:105,column:13},end:{line:105,column:14}},loc:{start:{line:105,column:27},end:{line:125,column:3}},line:105},12:{name:"(anonymous_12)",decl:{start:{line:110,column:20},end:{line:110,column:21}},loc:{start:{line:110,column:27},end:{line:123,column:5}},line:110},13:{name:"(anonymous_13)",decl:{start:{line:124,column:21},end:{line:124,column:22}},loc:{start:{line:124,column:28},end:{line:124,column:49}},line:124},14:{name:"(anonymous_14)",decl:{start:{line:126,column:2},end:{line:126,column:3}},loc:{start:{line:126,column:17},end:{line:132,column:3}},line:126},15:{name:"(anonymous_15)",decl:{start:{line:133,column:16},end:{line:133,column:17}},loc:{start:{line:133,column:25},end:{line:137,column:3}},line:133},16:{name:"(anonymous_16)",decl:{start:{line:138,column:2},end:{line:138,column:3}},loc:{start:{line:138,column:11},end:{line:225,column:3}},line:138},17:{name:"(anonymous_17)",decl:{start:{line:139,column:42},end:{line:139,column:43}},loc:{start:{line:139,column:54},end:{line:150,column:5}},line:139},18:{name:"(anonymous_18)",decl:{start:{line:155,column:55},end:{line:155,column:56}},loc:{start:{line:155,column:61},end:{line:155,column:78}},line:155},19:{name:"(anonymous_19)",decl:{start:{line:164,column:24},end:{line:164,column:25}},loc:{start:{line:164,column:30},end:{line:164,column:49}},line:164},20:{name:"(anonymous_20)",decl:{start:{line:220,column:20},end:{line:220,column:21}},loc:{start:{line:220,column:27},end:{line:220,column:56}},line:220}},branchMap:{0:{loc:{start:{line:53,column:4},end:{line:54,column:26}},type:"if",locations:[{start:{line:53,column:4},end:{line:54,column:26}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:53},1:{loc:{start:{line:55,column:4},end:{line:61,column:5}},type:"if",locations:[{start:{line:55,column:4},end:{line:61,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:55},2:{loc:{start:{line:72,column:6},end:{line:74,column:7}},type:"if",locations:[{start:{line:72,column:6},end:{line:74,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:72},3:{loc:{start:{line:152,column:4},end:{line:157,column:5}},type:"if",locations:[{start:{line:152,column:4},end:{line:157,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:152}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalOpen.tsx"],names:["style"],mappings:"AA4BQ,SACE,KADF;AA5BR,OAAO,WAA0B;AACjC,SAAQ,oBAAmB;AAC3B,SAAQ,0BAAyB;AACjC,OAAO,qBAAiC;AAExC,OAAO,kBAAkB;AACzB,OAAO,WAAW;AAClB,OAAO,iBAAiB;AACxB,OAAO,cAAc;AAErB,OAAO,WAAW;AAClB,OAAO,kBAAkB;AASzB,MAAM,oBAAoB,MAAM,UAA4B;AAAA,EAC1D,SAAS;AACP,WAAO,oBAAC,SAAI,WAAU,yBACpB;AAAA,MAAC;AAAA;AAAA,QACC,WAAU;AAAA,QACV,cAAY,KAAK,MAAM;AAAA,QACvB,SAAS,MAAM,KAAK,MAAM,SAAS,KAAK,MAAM,GAAG;AAAA,QAEjD;AAAA,+BAAC,SAAI,WAAU,gCACb;AAAA,gCAAC,SAAK,eAAK,MAAM,OAAM;AAAA,YACvB,oBAAC,UAAK,WAAU,kBAAiB;AAAA,YACjC,oBAAC,sBAAmB;AAAA,aACtB;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,WAAU;AAAA,cACV,OAAO;AAAA,gBACL,iBAAiB,OAAO,KAAK,MAAM,YAAY;AAAA,cACjD;AAAA;AAAA,UACD;AAAA;AAAA;AAAA,IACH,GACF;AAAA,EACF;AACF;AAeA,qBAAqB,kBAAkB,MAAM,UAA0C;AAAA,EACrF,YAAY,OAAuB;AACjC,UAAM,KAAK;AACX,SAAK,QAAQ;AAAA,MACX,UAAU;AAAA,IACZ;AAAA,EACF;AAAA,EAEA,aAAa;AACX,SAAK,SAAS;AAAA,MACZ,OAAO;AAAA,IACT,CAAC;AAAA,EACH;AAAA,EAEA,sBAAsB,GAAU;AAE9B,QAAG;AAAG,QAAE,gBAAgB;AAExB,QAAG,KAAK,MAAM,eAAe;AAC3B,WAAK,MAAM,cAAc,MAAM;AAC/B,WAAK,SAAS;AAAA,QACZ,eAAe;AAAA,QACf,kBAAkB;AAAA,MACpB,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,gBAAgB,CAAC,aAAqB;AACpC,SAAK,WAAW;AAEhB,QAAI,WAAoB;AAExB,UAAM,UAAU;AAAA,MACd,MAAM;AAAA,MACN,aAAa;AAAA,IACf,CAAC,EACE,KAAK,SAAS,UAAU;AACvB,aAAO,SAAS,KAAK;AAAA,IACvB,CAAC,EACA,KAAK,CAAC,SAAS;AACd,UAAG,UAAU;AACX;AAAA,MACF;AAEA,WAAK,SAAS;AAAA,QACZ,eAAe;AAAA,QACf,kBAAkB;AAAA,MACpB,CAAC;AAED,YAAM,WAAW,MAAM,oBAAoB,IAAI;AAC/C,cAAQ,IAAI,iBAAiB,SAAS,EAAE;AACxC,WAAK,MAAM,YAAY,QAAQ;AAC/B,WAAK,aAAa;AAAA,IACpB,CAAC,EACA,MAAM,CAAC,QAAQ;AACd,WAAK,SAAS;AAAA,QACZ,OAAO,oBAAoB,QAAQ;AAAA,QACnC,eAAe;AAAA,QACf,kBAAkB;AAAA,MACpB,CAAC;AACD,cAAQ,MAAM,GAAG;AACjB,cAAQ,KAAK,gCAAgC,QAAQ;AAAA,IACvD,CAAC;AAEH,SAAK,SAAS;AAAA,MACZ,eAAe;AAAA,QACb,OAAO,WAAW;AAChB,qBAAW;AAAA,QACb;AAAA,MACF;AAAA,MACA,kBAAkB;AAAA,IACpB,CAAC;AAAA,EACH;AAAA,EAEA,cAAc,CAAC,MAAkC;AAC/C,MAAE,eAAe;AACjB,SAAK,cAAc,KAAK,MAAM,QAAQ;AAAA,EACxC;AAAA,EAEA,WAAW,CAAC,GAAQ,UAAoB;AACtC,UAAM,CAAC,EAAE,IAAI,IAAI,MAAM,CAAC;AACxB,UAAM,SAAS,IAAI,WAAW;AAE9B,SAAK,WAAW;AAEhB,WAAO,WAAW,MAAM,OAAO;AAC/B,WAAO,SAAS,OAAK;AACnB,UAAI;AACJ,UAAI;AACF,mBAAW,KAAK,MAAM,EAAE,QAAQ,MAAgB;AAAA,MAClD,SACM,KAAK;AACT,aAAK,SAAS;AAAA,UACZ,OAAQ,IAAc,SAAS;AAAA,QACjC,CAAC;AACD;AAAA,MACF;AACA,iBAAW,MAAM,oBAAoB,QAAQ;AAC7C,WAAK,MAAM,YAAY,QAAQ;AAC/B,WAAK,aAAa;AAAA,IACpB;AACA,WAAO,UAAU,OAAK,QAAQ,IAAI,EAAE,MAAM;AAAA,EAC5C;AAAA,EAEA,eAAe;AACb,SAAK,SAAS;AAAA,MACZ,UAAU;AAAA,IACZ,CAAC;AACD,SAAK,WAAW;AAChB,SAAK,MAAM,aAAa;AAAA,EAC1B;AAAA,EAEA,cAAc,CAAC,QAAgB;AAC7B,SAAK,SAAS;AAAA,MACZ,UAAU;AAAA,IACZ,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,eAAe,aAAa,IAAI,CAAAA,WAAS;AAC7C,aAAO;AAAA,QAAC;AAAA;AAAA,UAEN,KAAKA,OAAM;AAAA,UACX,OAAOA,OAAM;AAAA,UACb,cAAcA,OAAM;AAAA,UACpB,UAAU,KAAK;AAAA;AAAA,QAJVA,OAAM;AAAA,MAKb;AAAA,IACF,CAAC;AAED,QAAI;AACJ,QAAG,KAAK,MAAM,OAAO;AACnB,qBACE,qBAAC,SAAI,WAAU,wBACZ;AAAA,aAAK,MAAM;AAAA,QACZ,oBAAC,OAAE,MAAK,KAAI,SAAS,MAAM,KAAK,WAAW,GAAG,WAAU,8BAA6B,eAAC;AAAA,SACxF;AAAA,IAEJ;AAEA,WACE,qBAAC,SACC;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,eAAY;AAAA,UACZ,QAAQ,KAAK,MAAM;AAAA,UACnB,cAAc,MAAM,KAAK,aAAa;AAAA,UACtC,OAAO;AAAA,UAEN;AAAA;AAAA,YACD,qBAAC,aAAQ,WAAU,0BACjB;AAAA,kCAAC,QAAG,0BAAY;AAAA,cAChB,oBAAC,OAAE,qDAAuC;AAAA,cAC1C,oBAAC,mBAAgB,UAAU,KAAK,UAAU,UAAU,IAAI,cAAW,cACjE,+BAAC,eAAY,WAAU,0BAAyB;AAAA,oCAAC,gBAAa;AAAA,gBAAE;AAAA,iBAAO,GACzE;AAAA,eACF;AAAA,YAEA,oBAAC,aAAQ,WAAU,0BACjB,+BAAC,UAAK,UAAU,KAAK,aACnB;AAAA,kCAAC,QAAG,2BAAa;AAAA,cACjB,qBAAC,OAAE;AAAA;AAAA,gBAC4C,oBAAC,OAAE,MAAK,2BAA0B,QAAO,UAAS,KAAI,uBAAsB,0BAAY;AAAA,gBAAI;AAAA,iBAC3I;AAAA,cACA;AAAA,gBAAC;AAAA;AAAA,kBACC,cAAW;AAAA,kBACX,eAAY;AAAA,kBACZ,MAAK;AAAA,kBACL,WAAU;AAAA,kBACV,SAAQ;AAAA,kBACR,OAAO,KAAK,MAAM;AAAA,kBAClB,SAAS,KAAK;AAAA,kBACd,UAAU,KAAK;AAAA;AAAA,cACjB;AAAA,cACA,oBAAC,SACC;AAAA,gBAAC;AAAA;AAAA,kBACC,eAAY;AAAA,kBACZ,MAAK;AAAA,kBACL,WAAU;AAAA,kBACV,UAAU,KAAK,MAAM,SAAS,SAAS;AAAA,kBACxC;AAAA;AAAA,cAAa,GAChB;AAAA,eACF,GACF;AAAA,YAEA,qBAAC,aAAQ,WAAU,yDACjB;AAAA,kCAAC,QAAG,4BAAc;AAAA,cAClB,oBAAC,OAAE,sEAEH;AAAA,cACA,oBAAC,SAAI,WAAU,oCACZ,wBACH;AAAA,eACF;AAAA;AAAA;AAAA,MACF;AAAA,MAEA;AAAA,QAAC;AAAA;AAAA,UACC,QAAQ,CAAC,CAAC,KAAK,MAAM;AAAA,UACrB,OAAO;AAAA,UACP,UAAU,CAAC,MAAa,KAAK,sBAAsB,CAAC;AAAA,UACpD,SAAS,cAAY,KAAK,MAAM;AAAA;AAAA,MAClC;AAAA,OACF;AAAA,EAEJ;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"6f55b81c74a9657afee47a2c5820a136d93a0f65"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return $n=function(){return s},s}$n();class sOe extends bn.Component{render(){return $n().f[0]++,$n().s[0]++,N.jsx("div",{className:"maputnik-public-style",children:N.jsxs(Ka,{className:"maputnik-public-style-button","aria-label":this.props.title,onClick:()=>($n().f[1]++,$n().s[1]++,this.props.onSelect(this.props.url)),children:[N.jsxs("div",{className:"maputnik-public-style-header",children:[N.jsx("div",{children:this.props.title}),N.jsx("span",{className:"maputnik-space"}),N.jsx(qR,{})]}),N.jsx("div",{className:"maputnik-public-style-thumbnail",style:{backgroundImage:`url(${this.props.thumbnailUrl})`}})]})})}}class lOe extends bn.Component{constructor(t){$n().f[2]++,$n().s[2]++;super(t);nn(this,"onStyleSelect",($n().s[10]++,t=>{$n().f[5]++,$n().s[11]++,this.clearError();let r=($n().s[12]++,!1);$n().s[13]++,fetch(t,{mode:"cors",credentials:"same-origin"}).then(function(i){return $n().f[6]++,$n().s[14]++,i.json()}).then(i=>{if($n().f[7]++,$n().s[15]++,r){$n().b[2][0]++,$n().s[16]++;return}else $n().b[2][1]++;$n().s[17]++,this.setState({activeRequest:null,activeRequestUrl:null});const o=($n().s[18]++,vu.ensureStyleValidity(i));$n().s[19]++,console.log("Loaded style ",o.id),$n().s[20]++,this.props.onStyleOpen(o),$n().s[21]++,this.onOpenToggle()}).catch(i=>{$n().f[8]++,$n().s[22]++,this.setState({error:`Failed to load: '${t}'`,activeRequest:null,activeRequestUrl:null}),$n().s[23]++,console.error(i),$n().s[24]++,console.warn("Could not open the style URL",t)}),$n().s[25]++,this.setState({activeRequest:{abort:function(){$n().f[9]++,$n().s[26]++,r=!0}},activeRequestUrl:t})}));nn(this,"onSubmitUrl",($n().s[27]++,t=>{$n().f[10]++,$n().s[28]++,t.preventDefault(),$n().s[29]++,this.onStyleSelect(this.state.styleUrl)}));nn(this,"onUpload",($n().s[30]++,(t,r)=>{$n().f[11]++;const[,i]=($n().s[31]++,r[0]),o=($n().s[32]++,new FileReader);$n().s[33]++,this.clearError(),$n().s[34]++,o.readAsText(i,"UTF-8"),$n().s[35]++,o.onload=s=>{var f;$n().f[12]++;let a;$n().s[36]++;try{$n().s[37]++,a=JSON.parse((f=s.target)==null?void 0:f.result)}catch(g){$n().s[38]++,this.setState({error:g.toString()}),$n().s[39]++;return}$n().s[40]++,a=vu.ensureStyleValidity(a),$n().s[41]++,this.props.onStyleOpen(a),$n().s[42]++,this.onOpenToggle()},$n().s[43]++,o.onerror=s=>($n().f[13]++,$n().s[44]++,console.log(s.target))}));nn(this,"onChangeUrl",($n().s[48]++,t=>{$n().f[15]++,$n().s[49]++,this.setState({styleUrl:t})}));$n().s[3]++,this.state={styleUrl:""}}clearError(){$n().f[3]++,$n().s[4]++,this.setState({error:null})}onCancelActiveRequest(t){$n().f[4]++,$n().s[5]++,t?($n().b[0][0]++,$n().s[6]++,t.stopPropagation()):$n().b[0][1]++,$n().s[7]++,this.state.activeRequest?($n().b[1][0]++,$n().s[8]++,this.state.activeRequest.abort(),$n().s[9]++,this.setState({activeRequest:null,activeRequestUrl:null})):$n().b[1][1]++}onOpenToggle(){$n().f[14]++,$n().s[45]++,this.setState({styleUrl:""}),$n().s[46]++,this.clearError(),$n().s[47]++,this.props.onOpenToggle()}render(){$n().f[16]++;const t=($n().s[50]++,cG.map(i=>($n().f[17]++,$n().s[51]++,N.jsx(sOe,{url:i.url,title:i.title,thumbnailUrl:i.thumbnail,onSelect:this.onStyleSelect},i.id))));let r;return $n().s[52]++,this.state.error?($n().b[3][0]++,$n().s[53]++,r=N.jsxs("div",{className:"maputnik-modal-error",children:[this.state.error,N.jsx("a",{href:"#",onClick:()=>($n().f[18]++,$n().s[54]++,this.clearError()),className:"maputnik-modal-error-close",children:"×"})]})):$n().b[3][1]++,$n().s[55]++,N.jsxs("div",{children:[N.jsxs(_f,{"data-wd-key":"modal:open",isOpen:this.props.isOpen,onOpenToggle:()=>($n().f[19]++,$n().s[56]++,this.onOpenToggle()),title:"Open Style",children:[r,N.jsxs("section",{className:"maputnik-modal-section",children:[N.jsx("h1",{children:"Upload Style"}),N.jsx("p",{children:"Upload a JSON style from your computer."}),N.jsx(oOe,{onChange:this.onUpload,tabIndex:-1,"aria-label":"Style file",children:N.jsxs(Ka,{className:"maputnik-upload-button",children:[N.jsx(xJ,{})," Upload"]})})]}),N.jsx("section",{className:"maputnik-modal-section",children:N.jsxs("form",{onSubmit:this.onSubmitUrl,children:[N.jsx("h1",{children:"Load from URL"}),N.jsxs("p",{children:["Load from a URL. Note that the URL must have ",N.jsx("a",{href:"https://enable-cors.org",target:"_blank",rel:"noopener noreferrer",children:"CORS enabled"}),"."]}),N.jsx(Y8,{"aria-label":"Style URL","data-wd-key":"modal:open.url.input",type:"text",className:"maputnik-input",default:"Enter URL...",value:this.state.styleUrl,onInput:this.onChangeUrl,onChange:this.onChangeUrl}),N.jsx("div",{children:N.jsx(Ka,{"data-wd-key":"modal:open.url.button",type:"submit",className:"maputnik-big-button",disabled:this.state.styleUrl.length<1,children:"Load from URL"})})]})}),N.jsxs("section",{className:"maputnik-modal-section maputnik-modal-section--shrink",children:[N.jsx("h1",{children:"Gallery Styles"}),N.jsx("p",{children:"Open one of the publicly available styles to start from."}),N.jsx("div",{className:"maputnik-style-gallery-container",children:t})]})]}),N.jsx(aOe,{isOpen:!!this.state.activeRequest,title:"Loading style",onCancel:i=>($n().f[20]++,$n().s[57]++,this.onCancelActiveRequest(i)),message:"Loading: "+this.state.activeRequestUrl})]})}}function $h(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalShortcuts.tsx",n="5c6b0b4c3c3cced12e6393d9679f373c813a1e88",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalShortcuts.tsx",statementMap:{0:{start:{line:6,column:17},end:{line:39,column:5}},1:{start:{line:40,column:25},end:{line:113,column:5}},2:{start:{line:114,column:4},end:{line:143,column:6}},3:{start:{line:128,column:12},end:{line:131,column:22}},4:{start:{line:135,column:12},end:{line:139,column:22}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:144,column:3}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:127,column:57},end:{line:127,column:58}},loc:{start:{line:127,column:72},end:{line:132,column:11}},line:127},2:{name:"(anonymous_2)",decl:{start:{line:134,column:65},end:{line:134,column:66}},loc:{start:{line:134,column:80},end:{line:140,column:11}},line:134}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0},f:{0:0,1:0,2:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalShortcuts.tsx"],names:[],mappings:"AAea,SAwCA,UAxCA,KAwCA,YAxCA;AAfb,OAAO,WAAW;AAElB,OAAO,WAAW;AASlB,qBAAqB,uBAAuB,MAAM,UAA+B;AAAA,EAC/E,SAAS;AACP,UAAM,OAAO;AAAA,MACX;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,IACF;AAGA,UAAM,eAAe;AAAA,MACnB;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,iCAAE;AAAA,8BAAC,SAAI,mBAAK;AAAA,UAAM;AAAA,UAAG,oBAAC,SAAI,eAAC;AAAA,WAAM;AAAA,QACtC,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,eAAC;AAAA,QACX,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,iCAAE;AAAA,8BAAC,SAAI,mBAAK;AAAA,UAAM;AAAA,UAAG,oBAAC,SAAI,eAAC;AAAA,WAAM;AAAA,QACtC,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,gBAAE;AAAA,QACZ,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,kBAAI;AAAA,QACd,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,kBAAI;AAAA,QACd,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,oBAAC,SAAI,mBAAK;AAAA,QACf,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,iCAAE;AAAA,8BAAC,SAAI,mBAAK;AAAA,UAAM;AAAA,UAAG,oBAAC,SAAI,mBAAK;AAAA,WAAM;AAAA,QAC1C,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,iCAAE;AAAA,8BAAC,SAAI,mBAAK;AAAA,UAAM;AAAA,UAAG,oBAAC,SAAI,kBAAI;AAAA,WAAM;AAAA,QACzC,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,iCAAE;AAAA,8BAAC,SAAI,mBAAK;AAAA,UAAM;AAAA,UAAG,oBAAC,SAAI,gBAAE;AAAA,WAAM;AAAA,QACvC,MAAM;AAAA,MACR;AAAA,MACA;AAAA,QACE,KAAK,iCAAE;AAAA,8BAAC,SAAI,mBAAK;AAAA,UAAM;AAAA,UAAG,oBAAC,SAAI,kBAAI;AAAA,WAAM;AAAA,QACzC,MAAM;AAAA,MACR;AAAA,IACF;AAGA,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAO;AAAA,QAEP,+BAAC,aAAQ,WAAU,mDACjB;AAAA,+BAAC,OAAE;AAAA;AAAA,YACK,oBAAC,UAAK,iBAAG;AAAA,YAAO;AAAA,aACxB;AAAA,UACA,oBAAC,QACE,eAAK,IAAI,CAAC,MAAM,QAAQ;AACvB,mBAAO,qBAAC,SAAc,WAAU,sCAC9B;AAAA,kCAAC,QAAmB,eAAK,OAAhB,OAAK,GAAe;AAAA,cAC7B,oBAAC,QAAmB,eAAK,QAAhB,OAAK,GAAgB;AAAA,iBAFf,GAGjB;AAAA,UACF,CAAC,GACH;AAAA,UACA,oBAAC,OAAE,0EAA4D;AAAA,UAC/D,oBAAC,QACE,uBAAa,IAAI,CAAC,MAAM,QAAQ;AAC/B,mBAAO,qBAAC,QACN;AAAA,kCAAC,UAAM,eAAK,KAAI;AAAA,cAAO;AAAA,cAAE,KAAK;AAAA,iBADhB,GAEhB;AAAA,UACF,CAAC,GACH;AAAA,WACF;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"5c6b0b4c3c3cced12e6393d9679f373c813a1e88"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return $h=function(){return s},s}$h();class uOe extends bn.Component{render(){$h().f[0]++;const n=($h().s[0]++,[{key:N.jsx("kbd",{children:"?"}),text:"Shortcuts menu"},{key:N.jsx("kbd",{children:"o"}),text:"Open modal"},{key:N.jsx("kbd",{children:"e"}),text:"Export modal"},{key:N.jsx("kbd",{children:"d"}),text:"Data Sources modal"},{key:N.jsx("kbd",{children:"s"}),text:"Style Settings modal"},{key:N.jsx("kbd",{children:"i"}),text:"Toggle inspect"},{key:N.jsx("kbd",{children:"m"}),text:"Focus map"},{key:N.jsx("kbd",{children:"!"}),text:"Debug modal"}]),t=($h().s[1]++,[{key:N.jsx("kbd",{children:"+"}),text:"Increase the zoom level by 1."},{key:N.jsxs(N.Fragment,{children:[N.jsx("kbd",{children:"Shift"})," + ",N.jsx("kbd",{children:"+"})]}),text:"Increase the zoom level by 2."},{key:N.jsx("kbd",{children:"-"}),text:"Decrease the zoom level by 1."},{key:N.jsxs(N.Fragment,{children:[N.jsx("kbd",{children:"Shift"})," + ",N.jsx("kbd",{children:"-"})]}),text:"Decrease the zoom level by 2."},{key:N.jsx("kbd",{children:"Up"}),text:"Pan up by 100 pixels."},{key:N.jsx("kbd",{children:"Down"}),text:"Pan down by 100 pixels."},{key:N.jsx("kbd",{children:"Left"}),text:"Pan left by 100 pixels."},{key:N.jsx("kbd",{children:"Right"}),text:"Pan right by 100 pixels."},{key:N.jsxs(N.Fragment,{children:[N.jsx("kbd",{children:"Shift"})," + ",N.jsx("kbd",{children:"Right"})]}),text:"Increase the rotation by 15 degrees."},{key:N.jsxs(N.Fragment,{children:[N.jsx("kbd",{children:"Shift"})," + ",N.jsx("kbd",{children:"Left"})]}),text:"Decrease the rotation by 15 degrees."},{key:N.jsxs(N.Fragment,{children:[N.jsx("kbd",{children:"Shift"})," + ",N.jsx("kbd",{children:"Up"})]}),text:"Increase the pitch by 10 degrees."},{key:N.jsxs(N.Fragment,{children:[N.jsx("kbd",{children:"Shift"})," + ",N.jsx("kbd",{children:"Down"})]}),text:"Decrease the pitch by 10 degrees."}]);return $h().s[2]++,N.jsx(_f,{"data-wd-key":"modal:shortcuts",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Shortcuts",children:N.jsxs("section",{className:"maputnik-modal-section maputnik-modal-shortcuts",children:[N.jsxs("p",{children:["Press ",N.jsx("code",{children:"ESC"})," to lose focus of any active elements, then press one of:"]}),N.jsx("dl",{children:n.map((r,i)=>($h().f[1]++,$h().s[3]++,N.jsxs("div",{className:"maputnik-modal-shortcuts__shortcut",children:[N.jsx("dt",{children:r.key},"dt"+i),N.jsx("dd",{children:r.text},"dd"+i)]},i)))}),N.jsx("p",{children:"If the Map is in focused you can use the following shortcuts"}),N.jsx("ul",{children:t.map((r,i)=>($h().f[2]++,$h().s[4]++,N.jsxs("li",{children:[N.jsx("span",{children:r.key})," ",r.text]},i)))})]})})}}const AOe="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20width='1200'%20height='1200'%20viewBox='0%200%20100%20100'%3e%3cg%20class='map'%20stroke='%23000'%3e%3cuse%20xlink:href='%23ref-1--map__main'%20fill='%234eba6f'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--map__line1'%20fill='none'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--map__line2'%20fill='none'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--map__line3'%20fill='none'%3e%3c/use%3e%3c/g%3e%3cg%20class='palette'%3e%3cuse%20xlink:href='%23ref-1--palette__main'%20fill='%23fff'%20stroke='%23000'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__inner'%20fill='none'%20stroke='%23000'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle5'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle4'%20fill='%234eba6f'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle3'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle2'%20fill='%234eba6f'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle1'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--palette__circle0'%20fill='%234eba6f'%3e%3c/use%3e%3c/g%3e%3cg%20class='brush'%20stroke='%23000'%3e%3cuse%20xlink:href='%23ref-1--brush__bottom'%20fill='%23f7c44c'%3e%3c/use%3e%3cuse%20xlink:href='%23ref-1--brush__top'%20fill='%23fff'%3e%3c/use%3e%3c/g%3e%3cdefs%3e%3cpath%20id='ref-1--map__main'%20stroke-width='2.366'%20stroke-linejoin='round'%20d='M18.84%207.717l15.44%207.542%2015.75-7.762%2015.7%207.857L81.005%207.67%2096.31%2054.052%2073.598%2062.12%2050.93%2053.872l-25.1%208.066-22.668-8.066z'%3e%3c/path%3e%3cpath%20id='ref-1--map__line1'%20d='M65.556%2015.07l7.647%2046.838'%20stroke-width='1.104'%3e%3c/path%3e%3cpath%20id='ref-1--map__line2'%20d='M50.261%207.422l.717%2046.6'%20stroke-width='1.104'%3e%3c/path%3e%3cpath%20id='ref-1--map__line3'%20d='M34.011%2015.07l-8.603%2046.6'%20stroke-width='1.104'%3e%3c/path%3e%3cpath%20id='ref-1--palette__main'%20stroke-width='2.3'%20d='M47.352%2030.887c7.993.226%2016.934%209.725%2017.954%2015.25%201.02%205.527-.743%2011.125-4.298%2013.875-3.554%202.75-8.6%202.905-8.723%208.302-.097%204.237%208.457%208.5%208.088%2015.653-.406%207.857-15.508%2013.15-30.943%206.102-8.556-3.906-14.249-13.653-13.385-26.238C16.833%2052.334%2022.32%2043.658%2027.382%2039c5.977-5.503%2011.977-8.337%2019.97-8.112z'%3e%3c/path%3e%3ccircle%20id='ref-1--palette__inner'%20stroke-width='2.3'%20cx='41.873'%20cy='61.901'%20r='6.389'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle5'%20cy='44.56'%20cx='54.347'%20r='4.336'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle4'%20cx='40.443'%20cy='41.555'%20r='4.336'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle3'%20r='4.336'%20cy='51.102'%20cx='29.651'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle2'%20cx='25.293'%20cy='65.836'%20r='4.336'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle1'%20r='4.336'%20cy='79.326'%20cx='32.764'%3e%3c/circle%3e%3ccircle%20id='ref-1--palette__circle0'%20cx='46.669'%20cy='80.571'%20r='4.336'%3e%3c/circle%3e%3cpath%20id='ref-1--brush__bottom'%20d='M76.333%2089.333c-1.645-9.794-4.375-35.26-4.32-37.887.056-2.627%202.52-4.34%205.36-4.317%202.842.022%205.098%201.87%205.314%204.27.107%201.2-1.576%2028.06-2.318%2037.844-.332%204.374-3.31%204.413-4.036.09z'%20stroke-width='2.3'%20stroke-linejoin='round'%3e%3c/path%3e%3cpath%20id='ref-1--brush__top'%20stroke-linejoin='round'%20stroke-width='2.3'%20d='M77.184%2026.428s-5.621%207.02-5.621%2011.978c0%204.957%202.206%206.878%205.81%206.878%203.606%200%205.148-1.708%205.29-6.736.142-5.028-5.479-12.12-5.479-12.12z'%3e%3c/path%3e%3c/defs%3e%3c/svg%3e";function im(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalSurvey.tsx",n="61657e6b288c15c4507475083ae2151817c1dbb9",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalSurvey.tsx",statementMap:{0:{start:{line:7,column:12},end:{line:10,column:3}},1:{start:{line:8,column:4},end:{line:8,column:76}},2:{start:{line:9,column:4},end:{line:9,column:30}},3:{start:{line:12,column:4},end:{line:27,column:6}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:7,column:12},end:{line:7,column:13}},loc:{start:{line:7,column:18},end:{line:10,column:3}},line:7},1:{name:"(anonymous_1)",decl:{start:{line:11,column:2},end:{line:11,column:3}},loc:{start:{line:11,column:11},end:{line:28,column:3}},line:11}},branchMap:{},s:{0:0,1:0,2:0,3:0},f:{0:0,1:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalSurvey.tsx"],names:[],mappings:"AA2BM,SACE,KADF;AA3BN,OAAO,WAAW;AAElB,OAAO,iBAAiB;AACxB,OAAO,WAAW;AAGlB,OAAO,eAAe;AAOtB,qBAAqB,oBAAoB,MAAM,UAA4B;AAAA,EACzE,UAAU,MAAM;AACd,WAAO,KAAK,kDAAkD,QAAQ;AAEtE,SAAK,MAAM,aAAa;AAAA,EAC1B;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAM;AAAA,QAEN,+BAAC,SAAI,WAAU,yBACb;AAAA,8BAAC,SAAI,KAAK,WAAW,WAAU,+BAA8B;AAAA,UAC7D,oBAAC,QAAG,sDAAwC;AAAA,UAC5C,oBAAC,OAAE,WAAU,sCAAqC,uLAAyK;AAAA,UAC3N,oBAAC,eAAY,SAAS,KAAK,SAAS,WAAU,kEAAiE,sCAAwB;AAAA,UACvI,oBAAC,OAAE,WAAU,mCAAkC,mEAAqD;AAAA,WACtG;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"61657e6b288c15c4507475083ae2151817c1dbb9"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return im=function(){return s},s}im();class cOe extends bn.Component{constructor(){super(...arguments);nn(this,"onClick",(im().s[0]++,()=>{im().f[0]++,im().s[1]++,window.open("https://gregorywolanski.typeform.com/to/cPgaSY","_blank"),im().s[2]++,this.props.onOpenToggle()}))}render(){return im().f[1]++,im().s[3]++,N.jsx(_f,{"data-wd-key":"modal:survey",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Maputnik Survey",children:N.jsxs("div",{className:"maputnik-modal-survey",children:[N.jsx("img",{src:AOe,className:"maputnik-modal-survey__logo"}),N.jsx("h1",{children:"You + Maputnik = Maputnik better for you"}),N.jsx("p",{className:"maputnik-modal-survey__description",children:"We don’t track you, so we don’t know how you use Maputnik. Help us make Maputnik better for you by completing a 7–minute survey carried out by our contributing designer."}),N.jsx(Ka,{onClick:this.onClick,className:"maputnik-big-button maputnik-white-button maputnik-wide-button",children:"Take the Maputnik Survey"}),N.jsx("p",{className:"maputnik-modal-survey__footnote",children:"It takes 7 minutes, tops! Every question is optional."})]})})}}function yl(){var e="/home/runner/work/maputnik/maputnik/src/components/ModalDebug.tsx",n="3e2ef17c22ea77c711c82e681a7c05add06fcb64",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/ModalDebug.tsx",statementMap:{0:{start:{line:6,column:24},end:{line:6,column:34}},1:{start:{line:7,column:20},end:{line:7,column:48}},2:{start:{line:8,column:19},end:{line:8,column:49}},3:{start:{line:9,column:19},end:{line:9,column:49}},4:{start:{line:10,column:4},end:{line:52,column:6}},5:{start:{line:21,column:14},end:{line:25,column:27}},6:{start:{line:22,column:96},end:{line:22,column:153}},7:{start:{line:28,column:14},end:{line:32,column:27}},8:{start:{line:29,column:96},end:{line:29,column:153}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:5,column:2},end:{line:5,column:3}},loc:{start:{line:5,column:11},end:{line:53,column:3}},line:5},1:{name:"(anonymous_1)",decl:{start:{line:20,column:140},end:{line:20,column:141}},loc:{start:{line:20,column:156},end:{line:26,column:13}},line:20},2:{name:"(anonymous_2)",decl:{start:{line:22,column:89},end:{line:22,column:90}},loc:{start:{line:22,column:96},end:{line:22,column:153}},line:22},3:{name:"(anonymous_3)",decl:{start:{line:27,column:136},end:{line:27,column:137}},loc:{start:{line:27,column:152},end:{line:33,column:13}},line:27},4:{name:"(anonymous_4)",decl:{start:{line:29,column:89},end:{line:29,column:90}},loc:{start:{line:29,column:96},end:{line:29,column:153}},line:29}},branchMap:{0:{loc:{start:{line:20,column:12},end:{line:26,column:17}},type:"binary-expr",locations:[{start:{line:20,column:12},end:{line:20,column:44}},{start:{line:20,column:64},end:{line:26,column:17}}],line:20},1:{loc:{start:{line:27,column:12},end:{line:33,column:17}},type:"binary-expr",locations:[{start:{line:27,column:12},end:{line:27,column:40}},{start:{line:27,column:60},end:{line:33,column:17}}],line:27}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0},f:{0:0,1:0,2:0,3:0,4:0},b:{0:[0,0],1:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/ModalDebug.tsx"],names:[],mappings:"AAsCQ,cAKQ,YALR;AAtCR,OAAO,WAAW;AAElB,OAAO,WAAW;AAqBlB,qBAAqB,mBAAmB,MAAM,UAA2B;AAAA,EACvE,SAAS;AACP,UAAM,EAAC,QAAO,IAAI,KAAK;AAEvB,UAAM,UAAU,KAAK,MAAM,QAAQ,IAAI,IAAE;AACzC,UAAM,SAAS,CAAE,QAAQ,OAAO,IAAK,QAAQ,CAAC;AAC9C,UAAM,SAAS,CAAE,QAAQ,OAAO,IAAK,QAAQ,CAAC;AAE9C,WAAO;AAAA,MAAC;AAAA;AAAA,QACN,eAAY;AAAA,QACZ,QAAQ,KAAK,MAAM;AAAA,QACnB,cAAc,KAAK,MAAM;AAAA,QACzB,OAAO;AAAA,QAEP;AAAA,+BAAC,aAAQ,WAAU,mDACjB;AAAA,gCAAC,QAAG,qBAAO;AAAA,YACV,KAAK,MAAM,aAAa,YACvB,oBAAC,QACE,iBAAO,QAAQ,KAAK,MAAM,sBAAuB,EAAE,IAAI,CAAC,CAAC,KAAK,GAAG,MAAM;AACtE,qBAAO,oBAAC,QACN,+BAAC,WACC;AAAA,oCAAC,WAAM,MAAK,YAAW,SAAS,KAAK,UAAU,CAAC,MAAM,KAAK,MAAM,wBAAwB,KAAK,EAAE,OAAO,OAAO,GAAG;AAAA,gBAAE;AAAA,gBAAE;AAAA,iBACvH,KAHc,GAIhB;AAAA,YACF,CAAC,GACH;AAAA,YAED,KAAK,MAAM,aAAa,QACvB,oBAAC,QACE,iBAAO,QAAQ,KAAK,MAAM,sBAAuB,EAAE,IAAI,CAAC,CAAC,KAAK,GAAG,MAAM;AACtE,qBAAO,oBAAC,QACN,+BAAC,WACC;AAAA,oCAAC,WAAM,MAAK,YAAW,SAAS,KAAK,UAAU,CAAC,MAAM,KAAK,MAAM,wBAAwB,KAAK,EAAE,OAAO,OAAO,GAAG;AAAA,gBAAE;AAAA,gBAAE;AAAA,iBACvH,KAHc,GAIhB;AAAA,YACF,CAAC,GACH;AAAA,aAEJ;AAAA,UACA,qBAAC,aAAQ,WAAU,0BACjB;AAAA,gCAAC,QAAG,mBAAK;AAAA,YACT,qBAAC,OACC;AAAA;AAAA,gBAAC;AAAA;AAAA,kBACC,QAAO;AAAA,kBACP,KAAI;AAAA,kBACJ,MAAM,sCAAsC,OAAO,IAAI,MAAM,IAAI,MAAM;AAAA,kBACxE;AAAA;AAAA,cAED;AAAA,cAAI;AAAA,eACN;AAAA,aACF;AAAA;AAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"3e2ef17c22ea77c711c82e681a7c05add06fcb64"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return yl=function(){return s},s}yl();class dOe extends bn.Component{render(){yl().f[0]++;const{mapView:n}=(yl().s[0]++,this.props),t=(yl().s[1]++,Math.round(n.zoom)+1),r=(yl().s[2]++,+n.center.lng.toFixed(5)),i=(yl().s[3]++,+n.center.lat.toFixed(5));return yl().s[4]++,N.jsxs(_f,{"data-wd-key":"modal:debug",isOpen:this.props.isOpen,onOpenToggle:this.props.onOpenToggle,title:"Debug",children:[N.jsxs("section",{className:"maputnik-modal-section maputnik-modal-shortcuts",children:[N.jsx("h1",{children:"Options"}),(yl().b[0][0]++,this.props.renderer==="mlgljs"&&(yl().b[0][1]++,N.jsx("ul",{children:Object.entries(this.props.maplibreGlDebugOptions).map(([o,s])=>(yl().f[1]++,yl().s[5]++,N.jsx("li",{children:N.jsxs("label",{children:[N.jsx("input",{type:"checkbox",checked:s,onChange:a=>(yl().f[2]++,yl().s[6]++,this.props.onChangeMaplibreGlDebug(o,a.target.checked))})," ",o]})},o)))}))),(yl().b[1][0]++,this.props.renderer==="ol"&&(yl().b[1][1]++,N.jsx("ul",{children:Object.entries(this.props.openlayersDebugOptions).map(([o,s])=>(yl().f[3]++,yl().s[7]++,N.jsx("li",{children:N.jsxs("label",{children:[N.jsx("input",{type:"checkbox",checked:s,onChange:a=>(yl().f[4]++,yl().s[8]++,this.props.onChangeOpenlayersDebug(o,a.target.checked))})," ",o]})},o)))})))]}),N.jsxs("section",{className:"maputnik-modal-section",children:[N.jsx("h1",{children:"Links"}),N.jsxs("p",{children:[N.jsx("a",{target:"_blank",rel:"noopener noreferrer",href:`https://www.openstreetmap.org/#map=${t}/${i}/${r}`,children:"Open in OSM"})," — Opens the current view on openstreetmap.org"]})]})]})}}var g1={},b4={exports:{}};/*! https://mths.be/punycode v1.4.1 by @mathias */b4.exports;(function(e,n){(function(t){var r=n&&!n.nodeType&&n,i=e&&!e.nodeType&&e,o=typeof window=="object"&&window;(o.global===o||o.window===o||o.self===o)&&(t=o);var s,a=2147483647,f=36,g=1,x=26,k=38,B=700,P=72,R=128,H="-",W=/^xn--/,$=/[^\x20-\x7E]/,q=/[\x2E\u3002\uFF0E\uFF61]/g,oe={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},ne=f-g,ce=Math.floor,ae=String.fromCharCode,ue;function ye(Ve){throw new RangeError(oe[Ve])}function Re(Ve,nt){for(var Je=Ve.length,Vt=[];Je--;)Vt[Je]=nt(Ve[Je]);return Vt}function Ne(Ve,nt){var Je=Ve.split("@"),Vt="";Je.length>1&&(Vt=Je[0]+"@",Ve=Je[1]),Ve=Ve.replace(q,".");var pt=Ve.split("."),dt=Re(pt,nt).join(".");return Vt+dt}function rt(Ve){for(var nt=[],Je=0,Vt=Ve.length,pt,dt;Je<Vt;)pt=Ve.charCodeAt(Je++),pt>=55296&&pt<=56319&&Je<Vt?(dt=Ve.charCodeAt(Je++),(dt&64512)==56320?nt.push(((pt&1023)<<10)+(dt&1023)+65536):(nt.push(pt),Je--)):nt.push(pt);return nt}function ct(Ve){return Re(Ve,function(nt){var Je="";return nt>65535&&(nt-=65536,Je+=ae(nt>>>10&1023|55296),nt=56320|nt&1023),Je+=ae(nt),Je}).join("")}function Fe(Ve){return Ve-48<10?Ve-22:Ve-65<26?Ve-65:Ve-97<26?Ve-97:f}function He(Ve,nt){return Ve+22+75*(Ve<26)-((nt!=0)<<5)}function Ce(Ve,nt,Je){var Vt=0;for(Ve=Je?ce(Ve/B):Ve>>1,Ve+=ce(Ve/nt);Ve>ne*x>>1;Vt+=f)Ve=ce(Ve/ne);return ce(Vt+(ne+1)*Ve/(Ve+k))}function jt(Ve){var nt=[],Je=Ve.length,Vt,pt=0,dt=R,kt=P,Dt,Se,de,xe,Pe,Ze,Xe,wt,Kt;for(Dt=Ve.lastIndexOf(H),Dt<0&&(Dt=0),Se=0;Se<Dt;++Se)Ve.charCodeAt(Se)>=128&&ye("not-basic"),nt.push(Ve.charCodeAt(Se));for(de=Dt>0?Dt+1:0;de<Je;){for(xe=pt,Pe=1,Ze=f;de>=Je&&ye("invalid-input"),Xe=Fe(Ve.charCodeAt(de++)),(Xe>=f||Xe>ce((a-pt)/Pe))&&ye("overflow"),pt+=Xe*Pe,wt=Ze<=kt?g:Ze>=kt+x?x:Ze-kt,!(Xe<wt);Ze+=f)Kt=f-wt,Pe>ce(a/Kt)&&ye("overflow"),Pe*=Kt;Vt=nt.length+1,kt=Ce(pt-xe,Vt,xe==0),ce(pt/Vt)>a-dt&&ye("overflow"),dt+=ce(pt/Vt),pt%=Vt,nt.splice(pt++,0,dt)}return ct(nt)}function Ft(Ve){var nt,Je,Vt,pt,dt,kt,Dt,Se,de,xe,Pe,Ze=[],Xe,wt,Kt,Pt;for(Ve=rt(Ve),Xe=Ve.length,nt=R,Je=0,dt=P,kt=0;kt<Xe;++kt)Pe=Ve[kt],Pe<128&&Ze.push(ae(Pe));for(Vt=pt=Ze.length,pt&&Ze.push(H);Vt<Xe;){for(Dt=a,kt=0;kt<Xe;++kt)Pe=Ve[kt],Pe>=nt&&Pe<Dt&&(Dt=Pe);for(wt=Vt+1,Dt-nt>ce((a-Je)/wt)&&ye("overflow"),Je+=(Dt-nt)*wt,nt=Dt,kt=0;kt<Xe;++kt)if(Pe=Ve[kt],Pe<nt&&++Je>a&&ye("overflow"),Pe==nt){for(Se=Je,de=f;xe=de<=dt?g:de>=dt+x?x:de-dt,!(Se<xe);de+=f)Pt=Se-xe,Kt=f-xe,Ze.push(ae(He(xe+Pt%Kt,0))),Se=ce(Pt/Kt);Ze.push(ae(He(Se,0))),dt=Ce(Je,wt,Vt==pt),Je=0,++Vt}++Je,++nt}return Ze.join("")}function Jt(Ve){return Ne(Ve,function(nt){return W.test(nt)?jt(nt.slice(4).toLowerCase()):nt})}function Nt(Ve){return Ne(Ve,function(nt){return $.test(nt)?"xn--"+Ft(nt):nt})}if(s={version:"1.4.1",ucs2:{decode:rt,encode:ct},decode:jt,encode:Ft,toASCII:Nt,toUnicode:Jt},r&&i)if(e.exports==r)i.exports=s;else for(ue in s)s.hasOwnProperty(ue)&&(r[ue]=s[ue]);else t.punycode=s})(mf)})(b4,b4.exports);var hOe=b4.exports,fOe=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var n={},t=Symbol("test"),r=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(r)!=="[object Symbol]")return!1;var i=42;n[t]=i;for(t in n)return!1;if(typeof Object.keys=="function"&&Object.keys(n).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(n).length!==0)return!1;var o=Object.getOwnPropertySymbols(n);if(o.length!==1||o[0]!==t||!Object.prototype.propertyIsEnumerable.call(n,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var s=Object.getOwnPropertyDescriptor(n,t);if(s.value!==i||s.enumerable!==!0)return!1}return!0},SP=typeof Symbol<"u"&&Symbol,pOe=fOe,mOe=function(){return typeof SP!="function"||typeof Symbol!="function"||typeof SP("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:pOe()},EP={foo:{}},gOe=Object,yOe=function(){return{__proto__:EP}.foo===EP.foo&&!({__proto__:null}instanceof gOe)},vOe="Function.prototype.bind called on incompatible ",COe=Object.prototype.toString,_Oe=Math.max,bOe="[object Function]",OP=function(n,t){for(var r=[],i=0;i<n.length;i+=1)r[i]=n[i];for(var o=0;o<t.length;o+=1)r[o+n.length]=t[o];return r},xOe=function(n,t){for(var r=[],i=t||0,o=0;i<n.length;i+=1,o+=1)r[o]=n[i];return r},wOe=function(e,n){for(var t="",r=0;r<e.length;r+=1)t+=e[r],r+1<e.length&&(t+=n);return t},MOe=function(n){var t=this;if(typeof t!="function"||COe.apply(t)!==bOe)throw new TypeError(vOe+t);for(var r=xOe(arguments,1),i,o=function(){if(this instanceof i){var x=t.apply(this,OP(r,arguments));return Object(x)===x?x:this}return t.apply(n,OP(r,arguments))},s=_Oe(0,t.length-r.length),a=[],f=0;f<s;f++)a[f]="$"+f;if(i=Function("binder","return function ("+wOe(a,",")+"){ return binder.apply(this,arguments); }")(o),t.prototype){var g=function(){};g.prototype=t.prototype,i.prototype=new g,g.prototype=null}return i},SOe=MOe,X8=Function.prototype.bind||SOe,EOe=Function.prototype.call,OOe=Object.prototype.hasOwnProperty,BOe=X8,kOe=BOe.call(EOe,OOe),xo,By=SyntaxError,dG=Function,hy=TypeError,uS=function(e){try{return dG('"use strict"; return ('+e+").constructor;")()}catch{}},n1=Object.getOwnPropertyDescriptor;if(n1)try{n1({},"")}catch{n1=null}var AS=function(){throw new hy},IOe=n1?function(){try{return arguments.callee,AS}catch{try{return n1(arguments,"callee").get}catch{return AS}}}():AS,pg=mOe(),TOe=yOe(),ru=Object.getPrototypeOf||(TOe?function(e){return e.__proto__}:null),Eg={},KOe=typeof Uint8Array>"u"||!ru?xo:ru(Uint8Array),r1={"%AggregateError%":typeof AggregateError>"u"?xo:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?xo:ArrayBuffer,"%ArrayIteratorPrototype%":pg&&ru?ru([][Symbol.iterator]()):xo,"%AsyncFromSyncIteratorPrototype%":xo,"%AsyncFunction%":Eg,"%AsyncGenerator%":Eg,"%AsyncGeneratorFunction%":Eg,"%AsyncIteratorPrototype%":Eg,"%Atomics%":typeof Atomics>"u"?xo:Atomics,"%BigInt%":typeof BigInt>"u"?xo:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?xo:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?xo:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?xo:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?xo:Float32Array,"%Float64Array%":typeof Float64Array>"u"?xo:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?xo:FinalizationRegistry,"%Function%":dG,"%GeneratorFunction%":Eg,"%Int8Array%":typeof Int8Array>"u"?xo:Int8Array,"%Int16Array%":typeof Int16Array>"u"?xo:Int16Array,"%Int32Array%":typeof Int32Array>"u"?xo:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":pg&&ru?ru(ru([][Symbol.iterator]())):xo,"%JSON%":typeof JSON=="object"?JSON:xo,"%Map%":typeof Map>"u"?xo:Map,"%MapIteratorPrototype%":typeof Map>"u"||!pg||!ru?xo:ru(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?xo:Promise,"%Proxy%":typeof Proxy>"u"?xo:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?xo:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?xo:Set,"%SetIteratorPrototype%":typeof Set>"u"||!pg||!ru?xo:ru(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?xo:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":pg&&ru?ru(""[Symbol.iterator]()):xo,"%Symbol%":pg?Symbol:xo,"%SyntaxError%":By,"%ThrowTypeError%":IOe,"%TypedArray%":KOe,"%TypeError%":hy,"%Uint8Array%":typeof Uint8Array>"u"?xo:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?xo:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?xo:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?xo:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?xo:WeakMap,"%WeakRef%":typeof WeakRef>"u"?xo:WeakRef,"%WeakSet%":typeof WeakSet>"u"?xo:WeakSet};if(ru)try{null.error}catch(e){var POe=ru(ru(e));r1["%Error.prototype%"]=POe}var FOe=function e(n){var t;if(n==="%AsyncFunction%")t=uS("async function () {}");else if(n==="%GeneratorFunction%")t=uS("function* () {}");else if(n==="%AsyncGeneratorFunction%")t=uS("async function* () {}");else if(n==="%AsyncGenerator%"){var r=e("%AsyncGeneratorFunction%");r&&(t=r.prototype)}else if(n==="%AsyncIteratorPrototype%"){var i=e("%AsyncGenerator%");i&&ru&&(t=ru(i.prototype))}return r1[n]=t,t},BP={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},xb=X8,x4=kOe,DOe=xb.call(Function.call,Array.prototype.concat),UOe=xb.call(Function.apply,Array.prototype.splice),kP=xb.call(Function.call,String.prototype.replace),w4=xb.call(Function.call,String.prototype.slice),ROe=xb.call(Function.call,RegExp.prototype.exec),LOe=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,zOe=/\\(\\)?/g,jOe=function(n){var t=w4(n,0,1),r=w4(n,-1);if(t==="%"&&r!=="%")throw new By("invalid intrinsic syntax, expected closing `%`");if(r==="%"&&t!=="%")throw new By("invalid intrinsic syntax, expected opening `%`");var i=[];return kP(n,LOe,function(o,s,a,f){i[i.length]=a?kP(f,zOe,"$1"):s||o}),i},WOe=function(n,t){var r=n,i;if(x4(BP,r)&&(i=BP[r],r="%"+i[0]+"%"),x4(r1,r)){var o=r1[r];if(o===Eg&&(o=FOe(r)),typeof o>"u"&&!t)throw new hy("intrinsic "+n+" exists, but is not available. Please file an issue!");return{alias:i,name:r,value:o}}throw new By("intrinsic "+n+" does not exist!")},B1=function(n,t){if(typeof n!="string"||n.length===0)throw new hy("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof t!="boolean")throw new hy('"allowMissing" argument must be a boolean');if(ROe(/^%?[^%]*%?$/,n)===null)throw new By("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=jOe(n),i=r.length>0?r[0]:"",o=WOe("%"+i+"%",t),s=o.name,a=o.value,f=!1,g=o.alias;g&&(i=g[0],UOe(r,DOe([0,1],g)));for(var x=1,k=!0;x<r.length;x+=1){var B=r[x],P=w4(B,0,1),R=w4(B,-1);if((P==='"'||P==="'"||P==="`"||R==='"'||R==="'"||R==="`")&&P!==R)throw new By("property names with quotes must have matching quotes");if((B==="constructor"||!k)&&(f=!0),i+="."+B,s="%"+i+"%",x4(r1,s))a=r1[s];else if(a!=null){if(!(B in a)){if(!t)throw new hy("base intrinsic for "+n+" exists, but the property is not available.");return}if(n1&&x+1>=r.length){var H=n1(a,B);k=!!H,k&&"get"in H&&!("originalValue"in H.get)?a=H.get:a=a[B]}else k=x4(a,B),a=a[B];k&&!f&&(r1[s]=a)}}return a},hG={exports:{}},NOe=B1,nO=NOe("%Object.defineProperty%",!0),rO=function(){if(nO)try{return nO({},"a",{value:1}),!0}catch{return!1}return!1};rO.hasArrayLengthDefineBug=function(){if(!rO())return null;try{return nO([],"length",{value:1}).length!==1}catch{return!0}};var fG=rO,GOe=B1,S2=GOe("%Object.getOwnPropertyDescriptor%",!0);if(S2)try{S2([],"length")}catch{S2=null}var pG=S2,QOe=fG(),J8=B1,zC=QOe&&J8("%Object.defineProperty%",!0);if(zC)try{zC({},"a",{value:1})}catch{zC=!1}var $Oe=J8("%SyntaxError%"),mg=J8("%TypeError%"),IP=pG,YOe=function(n,t,r){if(!n||typeof n!="object"&&typeof n!="function")throw new mg("`obj` must be an object or a function`");if(typeof t!="string"&&typeof t!="symbol")throw new mg("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new mg("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new mg("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new mg("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new mg("`loose`, if provided, must be a boolean");var i=arguments.length>3?arguments[3]:null,o=arguments.length>4?arguments[4]:null,s=arguments.length>5?arguments[5]:null,a=arguments.length>6?arguments[6]:!1,f=!!IP&&IP(n,t);if(zC)zC(n,t,{configurable:s===null&&f?f.configurable:!s,enumerable:i===null&&f?f.enumerable:!i,value:r,writable:o===null&&f?f.writable:!o});else if(a||!i&&!o&&!s)n[t]=r;else throw new $Oe("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},mG=B1,TP=YOe,qOe=fG(),KP=pG,PP=mG("%TypeError%"),VOe=mG("%Math.floor%"),HOe=function(n,t){if(typeof n!="function")throw new PP("`fn` is not a function");if(typeof t!="number"||t<0||t>4294967295||VOe(t)!==t)throw new PP("`length` must be a positive 32-bit integer");var r=arguments.length>2&&!!arguments[2],i=!0,o=!0;if("length"in n&&KP){var s=KP(n,"length");s&&!s.configurable&&(i=!1),s&&!s.writable&&(o=!1)}return(i||o||!r)&&(qOe?TP(n,"length",t,!0,!0):TP(n,"length",t)),n};(function(e){var n=X8,t=B1,r=HOe,i=t("%TypeError%"),o=t("%Function.prototype.apply%"),s=t("%Function.prototype.call%"),a=t("%Reflect.apply%",!0)||n.call(s,o),f=t("%Object.defineProperty%",!0),g=t("%Math.max%");if(f)try{f({},"a",{value:1})}catch{f=null}e.exports=function(B){if(typeof B!="function")throw new i("a function is required");var P=a(n,s,arguments);return r(P,1+g(0,B.length-(arguments.length-1)),!0)};var x=function(){return a(n,o,arguments)};f?f(e.exports,"apply",{value:x}):e.exports.apply=x})(hG);var ZOe=hG.exports,gG=B1,yG=ZOe,XOe=yG(gG("String.prototype.indexOf")),JOe=function(n,t){var r=gG(n,!!t);return typeof r=="function"&&XOe(n,".prototype.")>-1?yG(r):r};const eBe={},tBe=Object.freeze(Object.defineProperty({__proto__:null,default:eBe},Symbol.toStringTag,{value:"Module"})),nBe=fO(tBe);var ek=typeof Map=="function"&&Map.prototype,cS=Object.getOwnPropertyDescriptor&&ek?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,M4=ek&&cS&&typeof cS.get=="function"?cS.get:null,FP=ek&&Map.prototype.forEach,tk=typeof Set=="function"&&Set.prototype,dS=Object.getOwnPropertyDescriptor&&tk?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,S4=tk&&dS&&typeof dS.get=="function"?dS.get:null,DP=tk&&Set.prototype.forEach,rBe=typeof WeakMap=="function"&&WeakMap.prototype,jC=rBe?WeakMap.prototype.has:null,iBe=typeof WeakSet=="function"&&WeakSet.prototype,WC=iBe?WeakSet.prototype.has:null,oBe=typeof WeakRef=="function"&&WeakRef.prototype,UP=oBe?WeakRef.prototype.deref:null,aBe=Boolean.prototype.valueOf,sBe=Object.prototype.toString,lBe=Function.prototype.toString,uBe=String.prototype.match,nk=String.prototype.slice,mm=String.prototype.replace,ABe=String.prototype.toUpperCase,RP=String.prototype.toLowerCase,vG=RegExp.prototype.test,LP=Array.prototype.concat,qh=Array.prototype.join,cBe=Array.prototype.slice,zP=Math.floor,iO=typeof BigInt=="function"?BigInt.prototype.valueOf:null,hS=Object.getOwnPropertySymbols,oO=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,ky=typeof Symbol=="function"&&typeof Symbol.iterator=="object",Vu=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===ky||!0)?Symbol.toStringTag:null,CG=Object.prototype.propertyIsEnumerable,jP=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function WP(e,n){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||vG.call(/e/,n))return n;var t=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var r=e<0?-zP(-e):zP(e);if(r!==e){var i=String(r),o=nk.call(n,i.length+1);return mm.call(i,t,"$&_")+"."+mm.call(mm.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return mm.call(n,t,"$&_")}var aO=nBe,NP=aO.custom,GP=bG(NP)?NP:null,dBe=function e(n,t,r,i){var o=t||{};if(om(o,"quoteStyle")&&o.quoteStyle!=="single"&&o.quoteStyle!=="double")throw new TypeError('option "quoteStyle" must be "single" or "double"');if(om(o,"maxStringLength")&&(typeof o.maxStringLength=="number"?o.maxStringLength<0&&o.maxStringLength!==1/0:o.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var s=om(o,"customInspect")?o.customInspect:!0;if(typeof s!="boolean"&&s!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(om(o,"indent")&&o.indent!==null&&o.indent!==" "&&!(parseInt(o.indent,10)===o.indent&&o.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(om(o,"numericSeparator")&&typeof o.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var a=o.numericSeparator;if(typeof n>"u")return"undefined";if(n===null)return"null";if(typeof n=="boolean")return n?"true":"false";if(typeof n=="string")return wG(n,o);if(typeof n=="number"){if(n===0)return 1/0/n>0?"0":"-0";var f=String(n);return a?WP(n,f):f}if(typeof n=="bigint"){var g=String(n)+"n";return a?WP(n,g):g}var x=typeof o.depth>"u"?5:o.depth;if(typeof r>"u"&&(r=0),r>=x&&x>0&&typeof n=="object")return sO(n)?"[Array]":"[Object]";var k=kBe(o,r);if(typeof i>"u")i=[];else if(xG(i,n)>=0)return"[Circular]";function B(Fe,He,Ce){if(He&&(i=cBe.call(i),i.push(He)),Ce){var jt={depth:o.depth};return om(o,"quoteStyle")&&(jt.quoteStyle=o.quoteStyle),e(Fe,jt,r+1,i)}return e(Fe,o,r+1,i)}if(typeof n=="function"&&!QP(n)){var P=_Be(n),R=Hx(n,B);return"[Function"+(P?": "+P:" (anonymous)")+"]"+(R.length>0?" { "+qh.call(R,", ")+" }":"")}if(bG(n)){var H=ky?mm.call(String(n),/^(Symbol\(.*\))_[^)]*$/,"$1"):oO.call(n);return typeof n=="object"&&!ky?tC(H):H}if(EBe(n)){for(var W="<"+RP.call(String(n.nodeName)),$=n.attributes||[],q=0;q<$.length;q++)W+=" "+$[q].name+"="+_G(hBe($[q].value),"double",o);return W+=">",n.childNodes&&n.childNodes.length&&(W+="..."),W+="</"+RP.call(String(n.nodeName))+">",W}if(sO(n)){if(n.length===0)return"[]";var oe=Hx(n,B);return k&&!BBe(oe)?"["+lO(oe,k)+"]":"[ "+qh.call(oe,", ")+" ]"}if(pBe(n)){var ne=Hx(n,B);return!("cause"in Error.prototype)&&"cause"in n&&!CG.call(n,"cause")?"{ ["+String(n)+"] "+qh.call(LP.call("[cause]: "+B(n.cause),ne),", ")+" }":ne.length===0?"["+String(n)+"]":"{ ["+String(n)+"] "+qh.call(ne,", ")+" }"}if(typeof n=="object"&&s){if(GP&&typeof n[GP]=="function"&&aO)return aO(n,{depth:x-r});if(s!=="symbol"&&typeof n.inspect=="function")return n.inspect()}if(bBe(n)){var ce=[];return FP&&FP.call(n,function(Fe,He){ce.push(B(He,n,!0)+" => "+B(Fe,n))}),$P("Map",M4.call(n),ce,k)}if(MBe(n)){var ae=[];return DP&&DP.call(n,function(Fe){ae.push(B(Fe,n))}),$P("Set",S4.call(n),ae,k)}if(xBe(n))return fS("WeakMap");if(SBe(n))return fS("WeakSet");if(wBe(n))return fS("WeakRef");if(gBe(n))return tC(B(Number(n)));if(vBe(n))return tC(B(iO.call(n)));if(yBe(n))return tC(aBe.call(n));if(mBe(n))return tC(B(String(n)));if(typeof window<"u"&&n===window)return"{ [object Window] }";if(n===window)return"{ [object globalThis] }";if(!fBe(n)&&!QP(n)){var ue=Hx(n,B),ye=jP?jP(n)===Object.prototype:n instanceof Object||n.constructor===Object,Re=n instanceof Object?"":"null prototype",Ne=!ye&&Vu&&Object(n)===n&&Vu in n?nk.call(zm(n),8,-1):Re?"Object":"",rt=ye||typeof n.constructor!="function"?"":n.constructor.name?n.constructor.name+" ":"",ct=rt+(Ne||Re?"["+qh.call(LP.call([],Ne||[],Re||[]),": ")+"] ":"");return ue.length===0?ct+"{}":k?ct+"{"+lO(ue,k)+"}":ct+"{ "+qh.call(ue,", ")+" }"}return String(n)};function _G(e,n,t){var r=(t.quoteStyle||n)==="double"?'"':"'";return r+e+r}function hBe(e){return mm.call(String(e),/"/g,""")}function sO(e){return zm(e)==="[object Array]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function fBe(e){return zm(e)==="[object Date]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function QP(e){return zm(e)==="[object RegExp]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function pBe(e){return zm(e)==="[object Error]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function mBe(e){return zm(e)==="[object String]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function gBe(e){return zm(e)==="[object Number]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function yBe(e){return zm(e)==="[object Boolean]"&&(!Vu||!(typeof e=="object"&&Vu in e))}function bG(e){if(ky)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!oO)return!1;try{return oO.call(e),!0}catch{}return!1}function vBe(e){if(!e||typeof e!="object"||!iO)return!1;try{return iO.call(e),!0}catch{}return!1}var CBe=Object.prototype.hasOwnProperty||function(e){return e in this};function om(e,n){return CBe.call(e,n)}function zm(e){return sBe.call(e)}function _Be(e){if(e.name)return e.name;var n=uBe.call(lBe.call(e),/^function\s*([\w$]+)/);return n?n[1]:null}function xG(e,n){if(e.indexOf)return e.indexOf(n);for(var t=0,r=e.length;t<r;t++)if(e[t]===n)return t;return-1}function bBe(e){if(!M4||!e||typeof e!="object")return!1;try{M4.call(e);try{S4.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}function xBe(e){if(!jC||!e||typeof e!="object")return!1;try{jC.call(e,jC);try{WC.call(e,WC)}catch{return!0}return e instanceof WeakMap}catch{}return!1}function wBe(e){if(!UP||!e||typeof e!="object")return!1;try{return UP.call(e),!0}catch{}return!1}function MBe(e){if(!S4||!e||typeof e!="object")return!1;try{S4.call(e);try{M4.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}function SBe(e){if(!WC||!e||typeof e!="object")return!1;try{WC.call(e,WC);try{jC.call(e,jC)}catch{return!0}return e instanceof WeakSet}catch{}return!1}function EBe(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function wG(e,n){if(e.length>n.maxStringLength){var t=e.length-n.maxStringLength,r="... "+t+" more character"+(t>1?"s":"");return wG(nk.call(e,0,n.maxStringLength),n)+r}var i=mm.call(mm.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,OBe);return _G(i,"single",n)}function OBe(e){var n=e.charCodeAt(0),t={8:"b",9:"t",10:"n",12:"f",13:"r"}[n];return t?"\\"+t:"\\x"+(n<16?"0":"")+ABe.call(n.toString(16))}function tC(e){return"Object("+e+")"}function fS(e){return e+" { ? }"}function $P(e,n,t,r){var i=r?lO(t,r):qh.call(t,", ");return e+" ("+n+") {"+i+"}"}function BBe(e){for(var n=0;n<e.length;n++)if(xG(e[n],`
|
||
`)>=0)return!1;return!0}function kBe(e,n){var t;if(e.indent===" ")t=" ";else if(typeof e.indent=="number"&&e.indent>0)t=qh.call(Array(e.indent+1)," ");else return null;return{base:t,prev:qh.call(Array(n+1),t)}}function lO(e,n){if(e.length===0)return"";var t=`
|
||
`+n.prev+n.base;return t+qh.call(e,","+t)+`
|
||
`+n.prev}function Hx(e,n){var t=sO(e),r=[];if(t){r.length=e.length;for(var i=0;i<e.length;i++)r[i]=om(e,i)?n(e[i],e):""}var o=typeof hS=="function"?hS(e):[],s;if(ky){s={};for(var a=0;a<o.length;a++)s["$"+o[a]]=o[a]}for(var f in e)om(e,f)&&(t&&String(Number(f))===f&&f<e.length||ky&&s["$"+f]instanceof Symbol||(vG.call(/[^\w$]/,f)?r.push(n(f,e)+": "+n(e[f],e)):r.push(f+": "+n(e[f],e))));if(typeof hS=="function")for(var g=0;g<o.length;g++)CG.call(e,o[g])&&r.push("["+n(o[g])+"]: "+n(e[o[g]],e));return r}var rk=B1,Jy=JOe,IBe=dBe,TBe=rk("%TypeError%"),Zx=rk("%WeakMap%",!0),Xx=rk("%Map%",!0),KBe=Jy("WeakMap.prototype.get",!0),PBe=Jy("WeakMap.prototype.set",!0),FBe=Jy("WeakMap.prototype.has",!0),DBe=Jy("Map.prototype.get",!0),UBe=Jy("Map.prototype.set",!0),RBe=Jy("Map.prototype.has",!0),ik=function(e,n){for(var t=e,r;(r=t.next)!==null;t=r)if(r.key===n)return t.next=r.next,r.next=e.next,e.next=r,r},LBe=function(e,n){var t=ik(e,n);return t&&t.value},zBe=function(e,n,t){var r=ik(e,n);r?r.value=t:e.next={key:n,next:e.next,value:t}},jBe=function(e,n){return!!ik(e,n)},WBe=function(){var n,t,r,i={assert:function(o){if(!i.has(o))throw new TBe("Side channel does not contain "+IBe(o))},get:function(o){if(Zx&&o&&(typeof o=="object"||typeof o=="function")){if(n)return KBe(n,o)}else if(Xx){if(t)return DBe(t,o)}else if(r)return LBe(r,o)},has:function(o){if(Zx&&o&&(typeof o=="object"||typeof o=="function")){if(n)return FBe(n,o)}else if(Xx){if(t)return RBe(t,o)}else if(r)return jBe(r,o);return!1},set:function(o,s){Zx&&o&&(typeof o=="object"||typeof o=="function")?(n||(n=new Zx),PBe(n,o,s)):Xx?(t||(t=new Xx),UBe(t,o,s)):(r||(r={key:{},next:null}),zBe(r,o,s))}};return i},NBe=String.prototype.replace,GBe=/%20/g,pS={RFC1738:"RFC1738",RFC3986:"RFC3986"},ok={default:pS.RFC3986,formatters:{RFC1738:function(e){return NBe.call(e,GBe,"+")},RFC3986:function(e){return String(e)}},RFC1738:pS.RFC1738,RFC3986:pS.RFC3986},QBe=ok,mS=Object.prototype.hasOwnProperty,F0=Array.isArray,Wh=function(){for(var e=[],n=0;n<256;++n)e.push("%"+((n<16?"0":"")+n.toString(16)).toUpperCase());return e}(),$Be=function(n){for(;n.length>1;){var t=n.pop(),r=t.obj[t.prop];if(F0(r)){for(var i=[],o=0;o<r.length;++o)typeof r[o]<"u"&&i.push(r[o]);t.obj[t.prop]=i}}},MG=function(n,t){for(var r=t&&t.plainObjects?Object.create(null):{},i=0;i<n.length;++i)typeof n[i]<"u"&&(r[i]=n[i]);return r},YBe=function e(n,t,r){if(!t)return n;if(typeof t!="object"){if(F0(n))n.push(t);else if(n&&typeof n=="object")(r&&(r.plainObjects||r.allowPrototypes)||!mS.call(Object.prototype,t))&&(n[t]=!0);else return[n,t];return n}if(!n||typeof n!="object")return[n].concat(t);var i=n;return F0(n)&&!F0(t)&&(i=MG(n,r)),F0(n)&&F0(t)?(t.forEach(function(o,s){if(mS.call(n,s)){var a=n[s];a&&typeof a=="object"&&o&&typeof o=="object"?n[s]=e(a,o,r):n.push(o)}else n[s]=o}),n):Object.keys(t).reduce(function(o,s){var a=t[s];return mS.call(o,s)?o[s]=e(o[s],a,r):o[s]=a,o},i)},qBe=function(n,t){return Object.keys(t).reduce(function(r,i){return r[i]=t[i],r},n)},VBe=function(e,n,t){var r=e.replace(/\+/g," ");if(t==="iso-8859-1")return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch{return r}},HBe=function(n,t,r,i,o){if(n.length===0)return n;var s=n;if(typeof n=="symbol"?s=Symbol.prototype.toString.call(n):typeof n!="string"&&(s=String(n)),r==="iso-8859-1")return escape(s).replace(/%u[0-9a-f]{4}/gi,function(x){return"%26%23"+parseInt(x.slice(2),16)+"%3B"});for(var a="",f=0;f<s.length;++f){var g=s.charCodeAt(f);if(g===45||g===46||g===95||g===126||g>=48&&g<=57||g>=65&&g<=90||g>=97&&g<=122||o===QBe.RFC1738&&(g===40||g===41)){a+=s.charAt(f);continue}if(g<128){a=a+Wh[g];continue}if(g<2048){a=a+(Wh[192|g>>6]+Wh[128|g&63]);continue}if(g<55296||g>=57344){a=a+(Wh[224|g>>12]+Wh[128|g>>6&63]+Wh[128|g&63]);continue}f+=1,g=65536+((g&1023)<<10|s.charCodeAt(f)&1023),a+=Wh[240|g>>18]+Wh[128|g>>12&63]+Wh[128|g>>6&63]+Wh[128|g&63]}return a},ZBe=function(n){for(var t=[{obj:{o:n},prop:"o"}],r=[],i=0;i<t.length;++i)for(var o=t[i],s=o.obj[o.prop],a=Object.keys(s),f=0;f<a.length;++f){var g=a[f],x=s[g];typeof x=="object"&&x!==null&&r.indexOf(x)===-1&&(t.push({obj:s,prop:g}),r.push(x))}return $Be(t),n},XBe=function(n){return Object.prototype.toString.call(n)==="[object RegExp]"},JBe=function(n){return!n||typeof n!="object"?!1:!!(n.constructor&&n.constructor.isBuffer&&n.constructor.isBuffer(n))},e7e=function(n,t){return[].concat(n,t)},t7e=function(n,t){if(F0(n)){for(var r=[],i=0;i<n.length;i+=1)r.push(t(n[i]));return r}return t(n)},SG={arrayToObject:MG,assign:qBe,combine:e7e,compact:ZBe,decode:VBe,encode:HBe,isBuffer:JBe,isRegExp:XBe,maybeMap:t7e,merge:YBe},EG=WBe,E2=SG,NC=ok,n7e=Object.prototype.hasOwnProperty,YP={brackets:function(n){return n+"[]"},comma:"comma",indices:function(n,t){return n+"["+t+"]"},repeat:function(n){return n}},dp=Array.isArray,r7e=Array.prototype.push,OG=function(e,n){r7e.apply(e,dp(n)?n:[n])},i7e=Date.prototype.toISOString,qP=NC.default,Qu={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:E2.encode,encodeValuesOnly:!1,format:qP,formatter:NC.formatters[qP],indices:!1,serializeDate:function(n){return i7e.call(n)},skipNulls:!1,strictNullHandling:!1},o7e=function(n){return typeof n=="string"||typeof n=="number"||typeof n=="boolean"||typeof n=="symbol"||typeof n=="bigint"},gS={},a7e=function e(n,t,r,i,o,s,a,f,g,x,k,B,P,R,H,W){for(var $=n,q=W,oe=0,ne=!1;(q=q.get(gS))!==void 0&&!ne;){var ce=q.get(n);if(oe+=1,typeof ce<"u"){if(ce===oe)throw new RangeError("Cyclic object value");ne=!0}typeof q.get(gS)>"u"&&(oe=0)}if(typeof f=="function"?$=f(t,$):$ instanceof Date?$=k($):r==="comma"&&dp($)&&($=E2.maybeMap($,function(jt){return jt instanceof Date?k(jt):jt})),$===null){if(o)return a&&!R?a(t,Qu.encoder,H,"key",B):t;$=""}if(o7e($)||E2.isBuffer($)){if(a){var ae=R?t:a(t,Qu.encoder,H,"key",B);return[P(ae)+"="+P(a($,Qu.encoder,H,"value",B))]}return[P(t)+"="+P(String($))]}var ue=[];if(typeof $>"u")return ue;var ye;if(r==="comma"&&dp($))R&&a&&($=E2.maybeMap($,a)),ye=[{value:$.length>0?$.join(",")||null:void 0}];else if(dp(f))ye=f;else{var Re=Object.keys($);ye=g?Re.sort(g):Re}for(var Ne=i&&dp($)&&$.length===1?t+"[]":t,rt=0;rt<ye.length;++rt){var ct=ye[rt],Fe=typeof ct=="object"&&typeof ct.value<"u"?ct.value:$[ct];if(!(s&&Fe===null)){var He=dp($)?typeof r=="function"?r(Ne,ct):Ne:Ne+(x?"."+ct:"["+ct+"]");W.set(n,oe);var Ce=EG();Ce.set(gS,W),OG(ue,e(Fe,He,r,i,o,s,r==="comma"&&R&&dp($)?null:a,f,g,x,k,B,P,R,H,Ce))}}return ue},s7e=function(n){if(!n)return Qu;if(n.encoder!==null&&typeof n.encoder<"u"&&typeof n.encoder!="function")throw new TypeError("Encoder has to be a function.");var t=n.charset||Qu.charset;if(typeof n.charset<"u"&&n.charset!=="utf-8"&&n.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=NC.default;if(typeof n.format<"u"){if(!n7e.call(NC.formatters,n.format))throw new TypeError("Unknown format option provided.");r=n.format}var i=NC.formatters[r],o=Qu.filter;return(typeof n.filter=="function"||dp(n.filter))&&(o=n.filter),{addQueryPrefix:typeof n.addQueryPrefix=="boolean"?n.addQueryPrefix:Qu.addQueryPrefix,allowDots:typeof n.allowDots>"u"?Qu.allowDots:!!n.allowDots,charset:t,charsetSentinel:typeof n.charsetSentinel=="boolean"?n.charsetSentinel:Qu.charsetSentinel,delimiter:typeof n.delimiter>"u"?Qu.delimiter:n.delimiter,encode:typeof n.encode=="boolean"?n.encode:Qu.encode,encoder:typeof n.encoder=="function"?n.encoder:Qu.encoder,encodeValuesOnly:typeof n.encodeValuesOnly=="boolean"?n.encodeValuesOnly:Qu.encodeValuesOnly,filter:o,format:r,formatter:i,serializeDate:typeof n.serializeDate=="function"?n.serializeDate:Qu.serializeDate,skipNulls:typeof n.skipNulls=="boolean"?n.skipNulls:Qu.skipNulls,sort:typeof n.sort=="function"?n.sort:null,strictNullHandling:typeof n.strictNullHandling=="boolean"?n.strictNullHandling:Qu.strictNullHandling}},l7e=function(e,n){var t=e,r=s7e(n),i,o;typeof r.filter=="function"?(o=r.filter,t=o("",t)):dp(r.filter)&&(o=r.filter,i=o);var s=[];if(typeof t!="object"||t===null)return"";var a;n&&n.arrayFormat in YP?a=n.arrayFormat:n&&"indices"in n?a=n.indices?"indices":"repeat":a="indices";var f=YP[a];if(n&&"commaRoundTrip"in n&&typeof n.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var g=f==="comma"&&n&&n.commaRoundTrip;i||(i=Object.keys(t)),r.sort&&i.sort(r.sort);for(var x=EG(),k=0;k<i.length;++k){var B=i[k];r.skipNulls&&t[B]===null||OG(s,a7e(t[B],B,f,g,r.strictNullHandling,r.skipNulls,r.encode?r.encoder:null,r.filter,r.sort,r.allowDots,r.serializeDate,r.format,r.formatter,r.encodeValuesOnly,r.charset,x))}var P=s.join(r.delimiter),R=r.addQueryPrefix===!0?"?":"";return r.charsetSentinel&&(r.charset==="iso-8859-1"?R+="utf8=%26%2310003%3B&":R+="utf8=%E2%9C%93&"),P.length>0?R+P:""},Iy=SG,uO=Object.prototype.hasOwnProperty,u7e=Array.isArray,nu={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:Iy.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},A7e=function(e){return e.replace(/&#(\d+);/g,function(n,t){return String.fromCharCode(parseInt(t,10))})},BG=function(e,n){return e&&typeof e=="string"&&n.comma&&e.indexOf(",")>-1?e.split(","):e},c7e="utf8=%26%2310003%3B",d7e="utf8=%E2%9C%93",h7e=function(n,t){var r={__proto__:null},i=t.ignoreQueryPrefix?n.replace(/^\?/,""):n,o=t.parameterLimit===1/0?void 0:t.parameterLimit,s=i.split(t.delimiter,o),a=-1,f,g=t.charset;if(t.charsetSentinel)for(f=0;f<s.length;++f)s[f].indexOf("utf8=")===0&&(s[f]===d7e?g="utf-8":s[f]===c7e&&(g="iso-8859-1"),a=f,f=s.length);for(f=0;f<s.length;++f)if(f!==a){var x=s[f],k=x.indexOf("]="),B=k===-1?x.indexOf("="):k+1,P,R;B===-1?(P=t.decoder(x,nu.decoder,g,"key"),R=t.strictNullHandling?null:""):(P=t.decoder(x.slice(0,B),nu.decoder,g,"key"),R=Iy.maybeMap(BG(x.slice(B+1),t),function(H){return t.decoder(H,nu.decoder,g,"value")})),R&&t.interpretNumericEntities&&g==="iso-8859-1"&&(R=A7e(R)),x.indexOf("[]=")>-1&&(R=u7e(R)?[R]:R),uO.call(r,P)?r[P]=Iy.combine(r[P],R):r[P]=R}return r},f7e=function(e,n,t,r){for(var i=r?n:BG(n,t),o=e.length-1;o>=0;--o){var s,a=e[o];if(a==="[]"&&t.parseArrays)s=[].concat(i);else{s=t.plainObjects?Object.create(null):{};var f=a.charAt(0)==="["&&a.charAt(a.length-1)==="]"?a.slice(1,-1):a,g=parseInt(f,10);!t.parseArrays&&f===""?s={0:i}:!isNaN(g)&&a!==f&&String(g)===f&&g>=0&&t.parseArrays&&g<=t.arrayLimit?(s=[],s[g]=i):f!=="__proto__"&&(s[f]=i)}i=s}return i},p7e=function(n,t,r,i){if(n){var o=r.allowDots?n.replace(/\.([^.[]+)/g,"[$1]"):n,s=/(\[[^[\]]*])/,a=/(\[[^[\]]*])/g,f=r.depth>0&&s.exec(o),g=f?o.slice(0,f.index):o,x=[];if(g){if(!r.plainObjects&&uO.call(Object.prototype,g)&&!r.allowPrototypes)return;x.push(g)}for(var k=0;r.depth>0&&(f=a.exec(o))!==null&&k<r.depth;){if(k+=1,!r.plainObjects&&uO.call(Object.prototype,f[1].slice(1,-1))&&!r.allowPrototypes)return;x.push(f[1])}return f&&x.push("["+o.slice(f.index)+"]"),f7e(x,t,r,i)}},m7e=function(n){if(!n)return nu;if(n.decoder!==null&&n.decoder!==void 0&&typeof n.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof n.charset<"u"&&n.charset!=="utf-8"&&n.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=typeof n.charset>"u"?nu.charset:n.charset;return{allowDots:typeof n.allowDots>"u"?nu.allowDots:!!n.allowDots,allowPrototypes:typeof n.allowPrototypes=="boolean"?n.allowPrototypes:nu.allowPrototypes,allowSparse:typeof n.allowSparse=="boolean"?n.allowSparse:nu.allowSparse,arrayLimit:typeof n.arrayLimit=="number"?n.arrayLimit:nu.arrayLimit,charset:t,charsetSentinel:typeof n.charsetSentinel=="boolean"?n.charsetSentinel:nu.charsetSentinel,comma:typeof n.comma=="boolean"?n.comma:nu.comma,decoder:typeof n.decoder=="function"?n.decoder:nu.decoder,delimiter:typeof n.delimiter=="string"||Iy.isRegExp(n.delimiter)?n.delimiter:nu.delimiter,depth:typeof n.depth=="number"||n.depth===!1?+n.depth:nu.depth,ignoreQueryPrefix:n.ignoreQueryPrefix===!0,interpretNumericEntities:typeof n.interpretNumericEntities=="boolean"?n.interpretNumericEntities:nu.interpretNumericEntities,parameterLimit:typeof n.parameterLimit=="number"?n.parameterLimit:nu.parameterLimit,parseArrays:n.parseArrays!==!1,plainObjects:typeof n.plainObjects=="boolean"?n.plainObjects:nu.plainObjects,strictNullHandling:typeof n.strictNullHandling=="boolean"?n.strictNullHandling:nu.strictNullHandling}},g7e=function(e,n){var t=m7e(n);if(e===""||e===null||typeof e>"u")return t.plainObjects?Object.create(null):{};for(var r=typeof e=="string"?h7e(e,t):e,i=t.plainObjects?Object.create(null):{},o=Object.keys(r),s=0;s<o.length;++s){var a=o[s],f=p7e(a,r[a],t,typeof e=="string");i=Iy.merge(i,f,t)}return t.allowSparse===!0?i:Iy.compact(i)},y7e=l7e,v7e=g7e,C7e=ok,_7e={formats:C7e,parse:v7e,stringify:y7e},b7e=hOe;function wd(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var x7e=/^([a-z0-9.+-]+:)/i,w7e=/:[0-9]*$/,M7e=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,S7e=["<",">",'"',"`"," ","\r",`
|
||
`," "],E7e=["{","}","|","\\","^","`"].concat(S7e),AO=["'"].concat(E7e),VP=["%","/","?",";","#"].concat(AO),HP=["/","?","#"],O7e=255,ZP=/^[+a-z0-9A-Z_-]{0,63}$/,B7e=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,k7e={javascript:!0,"javascript:":!0},cO={javascript:!0,"javascript:":!0},fy={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},dO=_7e;function wb(e,n,t){if(e&&typeof e=="object"&&e instanceof wd)return e;var r=new wd;return r.parse(e,n,t),r}wd.prototype.parse=function(e,n,t){if(typeof e!="string")throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var r=e.indexOf("?"),i=r!==-1&&r<e.indexOf("#")?"?":"#",o=e.split(i),s=/\\/g;o[0]=o[0].replace(s,"/"),e=o.join(i);var a=e;if(a=a.trim(),!t&&e.split("#").length===1){var f=M7e.exec(a);if(f)return this.path=a,this.href=a,this.pathname=f[1],f[2]?(this.search=f[2],n?this.query=dO.parse(this.search.substr(1)):this.query=this.search.substr(1)):n&&(this.search="",this.query={}),this}var g=x7e.exec(a);if(g){g=g[0];var x=g.toLowerCase();this.protocol=x,a=a.substr(g.length)}if(t||g||a.match(/^\/\/[^@/]+@[^@/]+/)){var k=a.substr(0,2)==="//";k&&!(g&&cO[g])&&(a=a.substr(2),this.slashes=!0)}if(!cO[g]&&(k||g&&!fy[g])){for(var B=-1,P=0;P<HP.length;P++){var R=a.indexOf(HP[P]);R!==-1&&(B===-1||R<B)&&(B=R)}var H,W;B===-1?W=a.lastIndexOf("@"):W=a.lastIndexOf("@",B),W!==-1&&(H=a.slice(0,W),a=a.slice(W+1),this.auth=decodeURIComponent(H)),B=-1;for(var P=0;P<VP.length;P++){var R=a.indexOf(VP[P]);R!==-1&&(B===-1||R<B)&&(B=R)}B===-1&&(B=a.length),this.host=a.slice(0,B),a=a.slice(B),this.parseHost(),this.hostname=this.hostname||"";var $=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!$)for(var q=this.hostname.split(/\./),P=0,oe=q.length;P<oe;P++){var ne=q[P];if(ne&&!ne.match(ZP)){for(var ce="",ae=0,ue=ne.length;ae<ue;ae++)ne.charCodeAt(ae)>127?ce+="x":ce+=ne[ae];if(!ce.match(ZP)){var ye=q.slice(0,P),Re=q.slice(P+1),Ne=ne.match(B7e);Ne&&(ye.push(Ne[1]),Re.unshift(Ne[2])),Re.length&&(a="/"+Re.join(".")+a),this.hostname=ye.join(".");break}}}this.hostname.length>O7e?this.hostname="":this.hostname=this.hostname.toLowerCase(),$||(this.hostname=b7e.toASCII(this.hostname));var rt=this.port?":"+this.port:"",ct=this.hostname||"";this.host=ct+rt,this.href+=this.host,$&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),a[0]!=="/"&&(a="/"+a))}if(!k7e[x])for(var P=0,oe=AO.length;P<oe;P++){var Fe=AO[P];if(a.indexOf(Fe)!==-1){var He=encodeURIComponent(Fe);He===Fe&&(He=escape(Fe)),a=a.split(Fe).join(He)}}var Ce=a.indexOf("#");Ce!==-1&&(this.hash=a.substr(Ce),a=a.slice(0,Ce));var jt=a.indexOf("?");if(jt!==-1?(this.search=a.substr(jt),this.query=a.substr(jt+1),n&&(this.query=dO.parse(this.query)),a=a.slice(0,jt)):n&&(this.search="",this.query={}),a&&(this.pathname=a),fy[x]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var rt=this.pathname||"",Ft=this.search||"";this.path=rt+Ft}return this.href=this.format(),this};function I7e(e){return typeof e=="string"&&(e=wb(e)),e instanceof wd?e.format():wd.prototype.format.call(e)}wd.prototype.format=function(){var e=this.auth||"";e&&(e=encodeURIComponent(e),e=e.replace(/%3A/i,":"),e+="@");var n=this.protocol||"",t=this.pathname||"",r=this.hash||"",i=!1,o="";this.host?i=e+this.host:this.hostname&&(i=e+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(i+=":"+this.port)),this.query&&typeof this.query=="object"&&Object.keys(this.query).length&&(o=dO.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var s=this.search||o&&"?"+o||"";return n&&n.substr(-1)!==":"&&(n+=":"),this.slashes||(!n||fy[n])&&i!==!1?(i="//"+(i||""),t&&t.charAt(0)!=="/"&&(t="/"+t)):i||(i=""),r&&r.charAt(0)!=="#"&&(r="#"+r),s&&s.charAt(0)!=="?"&&(s="?"+s),t=t.replace(/[?#]/g,function(a){return encodeURIComponent(a)}),s=s.replace("#","%23"),n+i+t+s+r};function T7e(e,n){return wb(e,!1,!0).resolve(n)}wd.prototype.resolve=function(e){return this.resolveObject(wb(e,!1,!0)).format()};function K7e(e,n){return e?wb(e,!1,!0).resolveObject(n):n}wd.prototype.resolveObject=function(e){if(typeof e=="string"){var n=new wd;n.parse(e,!1,!0),e=n}for(var t=new wd,r=Object.keys(this),i=0;i<r.length;i++){var o=r[i];t[o]=this[o]}if(t.hash=e.hash,e.href==="")return t.href=t.format(),t;if(e.slashes&&!e.protocol){for(var s=Object.keys(e),a=0;a<s.length;a++){var f=s[a];f!=="protocol"&&(t[f]=e[f])}return fy[t.protocol]&&t.hostname&&!t.pathname&&(t.pathname="/",t.path=t.pathname),t.href=t.format(),t}if(e.protocol&&e.protocol!==t.protocol){if(!fy[e.protocol]){for(var g=Object.keys(e),x=0;x<g.length;x++){var k=g[x];t[k]=e[k]}return t.href=t.format(),t}if(t.protocol=e.protocol,!e.host&&!cO[e.protocol]){for(var oe=(e.pathname||"").split("/");oe.length&&!(e.host=oe.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),oe[0]!==""&&oe.unshift(""),oe.length<2&&oe.unshift(""),t.pathname=oe.join("/")}else t.pathname=e.pathname;if(t.search=e.search,t.query=e.query,t.host=e.host||"",t.auth=e.auth,t.hostname=e.hostname||e.host,t.port=e.port,t.pathname||t.search){var B=t.pathname||"",P=t.search||"";t.path=B+P}return t.slashes=t.slashes||e.slashes,t.href=t.format(),t}var R=t.pathname&&t.pathname.charAt(0)==="/",H=e.host||e.pathname&&e.pathname.charAt(0)==="/",W=H||R||t.host&&e.pathname,$=W,q=t.pathname&&t.pathname.split("/")||[],oe=e.pathname&&e.pathname.split("/")||[],ne=t.protocol&&!fy[t.protocol];if(ne&&(t.hostname="",t.port=null,t.host&&(q[0]===""?q[0]=t.host:q.unshift(t.host)),t.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(oe[0]===""?oe[0]=e.host:oe.unshift(e.host)),e.host=null),W=W&&(oe[0]===""||q[0]==="")),H)t.host=e.host||e.host===""?e.host:t.host,t.hostname=e.hostname||e.hostname===""?e.hostname:t.hostname,t.search=e.search,t.query=e.query,q=oe;else if(oe.length)q||(q=[]),q.pop(),q=q.concat(oe),t.search=e.search,t.query=e.query;else if(e.search!=null){if(ne){t.host=q.shift(),t.hostname=t.host;var ce=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;ce&&(t.auth=ce.shift(),t.hostname=ce.shift(),t.host=t.hostname)}return t.search=e.search,t.query=e.query,(t.pathname!==null||t.search!==null)&&(t.path=(t.pathname?t.pathname:"")+(t.search?t.search:"")),t.href=t.format(),t}if(!q.length)return t.pathname=null,t.search?t.path="/"+t.search:t.path=null,t.href=t.format(),t;for(var ae=q.slice(-1)[0],ue=(t.host||e.host||q.length>1)&&(ae==="."||ae==="..")||ae==="",ye=0,Re=q.length;Re>=0;Re--)ae=q[Re],ae==="."?q.splice(Re,1):ae===".."?(q.splice(Re,1),ye++):ye&&(q.splice(Re,1),ye--);if(!W&&!$)for(;ye--;ye)q.unshift("..");W&&q[0]!==""&&(!q[0]||q[0].charAt(0)!=="/")&&q.unshift(""),ue&&q.join("/").substr(-1)!=="/"&&q.push("");var Ne=q[0]===""||q[0]&&q[0].charAt(0)==="/";if(ne){t.hostname=Ne?"":q.length?q.shift():"",t.host=t.hostname;var ce=t.host&&t.host.indexOf("@")>0?t.host.split("@"):!1;ce&&(t.auth=ce.shift(),t.hostname=ce.shift(),t.host=t.hostname)}return W=W||t.host&&q.length,W&&!Ne&&q.unshift(""),q.length>0?t.pathname=q.join("/"):(t.pathname=null,t.path=null),(t.pathname!==null||t.search!==null)&&(t.path=(t.pathname?t.pathname:"")+(t.search?t.search:"")),t.auth=e.auth||t.auth,t.slashes=t.slashes||e.slashes,t.href=t.format(),t};wd.prototype.parseHost=function(){var e=this.host,n=w7e.exec(e);n&&(n=n[0],n!==":"&&(this.port=n.substr(1)),e=e.substr(0,e.length-n.length)),e&&(this.hostname=e)};g1.parse=wb;g1.resolve=T7e;g1.resolveObject=K7e;g1.format=I7e;g1.Url=wd;function Fo(){var e="/home/runner/work/maputnik/maputnik/src/libs/metadata.ts",n="19e47c652b47a74a8fe842dad1f0616429ed3097",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/metadata.ts",statementMap:{0:{start:{line:3,column:2},end:{line:13,column:5}},1:{start:{line:7,column:4},end:{line:7,column:27}},2:{start:{line:9,column:4},end:{line:9,column:13}},3:{start:{line:11,column:4},end:{line:11,column:48}},4:{start:{line:12,column:4},end:{line:12,column:21}},5:{start:{line:16,column:2},end:{line:17,column:18}},6:{start:{line:17,column:4},end:{line:17,column:18}},7:{start:{line:18,column:17},end:{line:18,column:42}},8:{start:{line:19,column:23},end:{line:19,column:57}},9:{start:{line:20,column:2},end:{line:24,column:3}},10:{start:{line:21,column:4},end:{line:21,column:41}},11:{start:{line:23,column:4},end:{line:23,column:69}},12:{start:{line:25,column:14},end:{line:25,column:35}},13:{start:{line:26,column:2},end:{line:26,column:24}},14:{start:{line:29,column:2},end:{line:30,column:18}},15:{start:{line:30,column:4},end:{line:30,column:18}},16:{start:{line:31,column:14},end:{line:31,column:31}},17:{start:{line:32,column:2},end:{line:32,column:57}},18:{start:{line:32,column:32},end:{line:32,column:55}}},fnMap:{0:{name:"loadJSON",decl:{start:{line:2,column:9},end:{line:2,column:17}},loc:{start:{line:2,column:41},end:{line:14,column:1}},line:2},1:{name:"(anonymous_1)",decl:{start:{line:6,column:10},end:{line:6,column:11}},loc:{start:{line:6,column:29},end:{line:8,column:3}},line:6},2:{name:"(anonymous_2)",decl:{start:{line:8,column:10},end:{line:8,column:11}},loc:{start:{line:8,column:25},end:{line:10,column:3}},line:8},3:{name:"(anonymous_3)",decl:{start:{line:10,column:11},end:{line:10,column:12}},loc:{start:{line:10,column:22},end:{line:13,column:3}},line:10},4:{name:"downloadGlyphsMetadata",decl:{start:{line:15,column:16},end:{line:15,column:38}},loc:{start:{line:15,column:56},end:{line:27,column:1}},line:15},5:{name:"downloadSpriteMetadata",decl:{start:{line:28,column:16},end:{line:28,column:38}},loc:{start:{line:28,column:52},end:{line:33,column:1}},line:28},6:{name:"(anonymous_6)",decl:{start:{line:32,column:20},end:{line:32,column:21}},loc:{start:{line:32,column:32},end:{line:32,column:55}},line:32}},branchMap:{0:{loc:{start:{line:16,column:2},end:{line:17,column:18}},type:"if",locations:[{start:{line:16,column:2},end:{line:17,column:18}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:16},1:{loc:{start:{line:20,column:2},end:{line:24,column:3}},type:"if",locations:[{start:{line:20,column:2},end:{line:24,column:3}},{start:{line:22,column:9},end:{line:24,column:3}}],line:20},2:{loc:{start:{line:29,column:2},end:{line:30,column:18}},type:"if",locations:[{start:{line:29,column:2},end:{line:30,column:18}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:29}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},b:{0:[0,0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/metadata.ts"],names:[],mappings:"AAAA,OAAO,YAAY;AAEnB,SAAS,SAAS,KAAa,cAAmB,IAA8B;AAC9E,QAAM,KAAK;AAAA,IACT,MAAM;AAAA,IACN,aAAa;AAAA,EACf,CAAC,EACE,KAAK,SAAS,UAAU;AACvB,WAAO,SAAS,KAAK;AAAA,EACvB,CAAC,EACA,KAAK,SAAS,MAAM;AACnB,OAAG,IAAI;AAAA,EACT,CAAC,EACA,MAAM,WAAW;AAChB,YAAQ,KAAK,0BAA0B,GAAG;AAC1C,OAAG,YAAY;AAAA,EACjB,CAAC;AACL;AAEO,gBAAS,uBAAuB,aAAqB,IAA8B;AACxF,MAAG,CAAC;AAAa,WAAO,GAAG,CAAC,CAAC;AAI7B,QAAM,SAAS,OAAO,MAAM,WAAW;AACvC,QAAM,eAAe;AACrB,MAAG,OAAO,aAAa,cAAc;AACnC,WAAO,WAAW;AAAA,EACpB,OAAO;AACL,WAAO,WAAW,OAAO,SAAU,QAAQ,cAAc,OAAO;AAAA,EAClE;AACA,QAAM,MAAM,OAAO,OAAO,MAAM;AAEhC,WAAS,KAAK,CAAC,GAAG,EAAE;AACtB;AAEO,gBAAS,uBAAuB,SAAiB,IAA8B;AACpF,MAAG,CAAC;AAAS,WAAO,GAAG,CAAC,CAAC;AACzB,QAAM,MAAM,UAAU;AACtB,WAAS,KAAK,CAAC,GAAG,YAAU,GAAG,OAAO,KAAK,MAAM,CAAC,CAAC;AACrD;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"19e47c652b47a74a8fe842dad1f0616429ed3097"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Fo=function(){return s},s}Fo();function kG(e,n,t){Fo().f[0]++,Fo().s[0]++,fetch(e,{mode:"cors",credentials:"same-origin"}).then(function(r){return Fo().f[1]++,Fo().s[1]++,r.json()}).then(function(r){Fo().f[2]++,Fo().s[2]++,t(r)}).catch(function(){Fo().f[3]++,Fo().s[3]++,console.warn("Can not metadata for "+e),Fo().s[4]++,t(n)})}function P7e(e,n){if(Fo().f[4]++,Fo().s[5]++,e)Fo().b[0][1]++;else return Fo().b[0][0]++,Fo().s[6]++,n([]);const t=(Fo().s[7]++,g1.parse(e)),r=(Fo().s[8]++,"/%7Bfontstack%7D/%7Brange%7D.pbf");Fo().s[9]++,t.pathname===r?(Fo().b[1][0]++,Fo().s[10]++,t.pathname="/fontstacks.json"):(Fo().b[1][1]++,Fo().s[11]++,t.pathname=t.pathname.replace(r,".json"));const i=(Fo().s[12]++,g1.format(t));Fo().s[13]++,kG(i,[],n)}function F7e(e,n){if(Fo().f[5]++,Fo().s[14]++,e)Fo().b[2][1]++;else return Fo().b[2][0]++,Fo().s[15]++,n([]);const t=(Fo().s[16]++,e+".json");Fo().s[17]++,kG(t,{},r=>(Fo().f[6]++,Fo().s[18]++,n(Object.keys(r))))}function zl(){var e="/home/runner/work/maputnik/maputnik/src/libs/urlopen.ts",n="5d157b2ae65dbd5a5a7dfa0dbf76114e1399ceba",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/urlopen.ts",statementMap:{0:{start:{line:3,column:21},end:{line:3,column:50}},1:{start:{line:4,column:2},end:{line:4,column:46}},2:{start:{line:7,column:2},end:{line:7,column:41}},3:{start:{line:8,column:2},end:{line:18,column:5}},4:{start:{line:12,column:4},end:{line:12,column:27}},5:{start:{line:14,column:4},end:{line:14,column:40}},6:{start:{line:16,column:4},end:{line:16,column:60}},7:{start:{line:17,column:4},end:{line:17,column:25}},8:{start:{line:21,column:21},end:{line:21,column:50}},9:{start:{line:22,column:2},end:{line:22,column:42}},10:{start:{line:23,column:2},end:{line:23,column:73}}},fnMap:{0:{name:"initialStyleUrl",decl:{start:{line:2,column:16},end:{line:2,column:31}},loc:{start:{line:2,column:34},end:{line:5,column:1}},line:2},1:{name:"loadStyleUrl",decl:{start:{line:6,column:16},end:{line:6,column:28}},loc:{start:{line:6,column:43},end:{line:19,column:1}},line:6},2:{name:"(anonymous_2)",decl:{start:{line:11,column:10},end:{line:11,column:11}},loc:{start:{line:11,column:29},end:{line:13,column:3}},line:11},3:{name:"(anonymous_3)",decl:{start:{line:13,column:10},end:{line:13,column:11}},loc:{start:{line:13,column:25},end:{line:15,column:3}},line:13},4:{name:"(anonymous_4)",decl:{start:{line:15,column:11},end:{line:15,column:12}},loc:{start:{line:15,column:22},end:{line:18,column:3}},line:15},5:{name:"removeStyleQuerystring",decl:{start:{line:20,column:16},end:{line:20,column:38}},loc:{start:{line:20,column:41},end:{line:24,column:1}},line:20}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0},f:{0:0,1:0,2:0,3:0,4:0,5:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/urlopen.ts"],names:[],mappings:"AACA,OAAO,WAAW;AAEX,gBAAS,kBAAkB;AAChC,QAAM,aAAa,IAAI,IAAI,OAAO,SAAS,IAAI;AAC/C,SAAO,WAAW,aAAa,IAAI,OAAO;AAC5C;AAEO,gBAAS,aAAa,UAAkB,IAA8B;AAC3E,UAAQ,IAAI,iBAAiB,QAAQ;AACrC,QAAM,UAAU;AAAA,IACd,MAAM;AAAA,IACN,aAAa;AAAA,EACf,CAAC,EACE,KAAK,SAAS,UAAU;AACvB,WAAO,SAAS,KAAK;AAAA,EACvB,CAAC,EACA,KAAK,SAAS,MAAM;AACnB,OAAG,MAAM,oBAAoB,IAAI,CAAC;AAAA,EACpC,CAAC,EACA,MAAM,WAAW;AAChB,YAAQ,KAAK,iCAAiC,QAAQ;AACtD,OAAG,MAAM,UAAU;AAAA,EACrB,CAAC;AACL;AAEO,gBAAS,yBAAyB;AACvC,QAAM,aAAa,IAAI,IAAI,OAAO,SAAS,IAAI;AAC/C,aAAW,aAAa,OAAO,OAAO;AACtC,SAAO,QAAQ,aAAa,CAAC,GAAG,SAAS,OAAO,WAAW,SAAS,CAAC;AACvE;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"5d157b2ae65dbd5a5a7dfa0dbf76114e1399ceba"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return zl=function(){return s},s}zl();function D7e(){zl().f[0]++;const e=(zl().s[0]++,new URL(window.location.href));return zl().s[1]++,e.searchParams.get("style")}function IG(e,n){zl().f[1]++,zl().s[2]++,console.log("Loading style",e),zl().s[3]++,fetch(e,{mode:"cors",credentials:"same-origin"}).then(function(t){return zl().f[2]++,zl().s[4]++,t.json()}).then(function(t){zl().f[3]++,zl().s[5]++,n(vu.ensureStyleValidity(t))}).catch(function(){zl().f[4]++,zl().s[6]++,console.warn("Could not fetch default style",e),zl().s[7]++,n(vu.emptyStyle)})}function XP(){zl().f[5]++;const e=(zl().s[8]++,new URL(window.location.href));zl().s[9]++,e.searchParams.delete("style"),zl().s[10]++,window.history.replaceState({},document.title,e.toString())}function mA(){var e="/home/runner/work/maputnik/maputnik/src/libs/diffmessage.ts",n="f92fa2abb31199d99fd3ae02d967dc6702faf862",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/diffmessage.ts",statementMap:{0:{start:{line:3,column:18},end:{line:3,column:47}},1:{start:{line:4,column:2},end:{line:4,column:70}},2:{start:{line:4,column:30},end:{line:4,column:68}},3:{start:{line:7,column:2},end:{line:7,column:71}},4:{start:{line:7,column:58},end:{line:7,column:69}},5:{start:{line:10,column:2},end:{line:10,column:71}},6:{start:{line:10,column:58},end:{line:10,column:69}}},fnMap:{0:{name:"diffMessages",decl:{start:{line:2,column:9},end:{line:2,column:21}},loc:{start:{line:2,column:47},end:{line:5,column:1}},line:2},1:{name:"(anonymous_1)",decl:{start:{line:4,column:21},end:{line:4,column:22}},loc:{start:{line:4,column:30},end:{line:4,column:68}},line:4},2:{name:"undoMessages",decl:{start:{line:6,column:16},end:{line:6,column:28}},loc:{start:{line:6,column:54},end:{line:8,column:1}},line:6},3:{name:"(anonymous_3)",decl:{start:{line:7,column:51},end:{line:7,column:52}},loc:{start:{line:7,column:58},end:{line:7,column:69}},line:7},4:{name:"redoMessages",decl:{start:{line:9,column:16},end:{line:9,column:28}},loc:{start:{line:9,column:54},end:{line:11,column:1}},line:9},5:{name:"(anonymous_5)",decl:{start:{line:10,column:51},end:{line:10,column:52}},loc:{start:{line:10,column:58},end:{line:10,column:69}},line:10}},branchMap:{},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0},f:{0:0,1:0,2:0,3:0,4:0,5:0},b:{},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/diffmessage.ts"],names:[],mappings:"AAAA,SAAQ,YAAW;AAGnB,SAAS,aAAa,aAAiC,YAAgC;AACrF,QAAM,UAAU,KAAK,aAAa,UAAU;AAC5C,SAAO,QAAQ,IAAI,SAAO,IAAI,UAAU,MAAM,IAAI,KAAK,KAAK,GAAG,CAAC;AAClE;AAEO,gBAAS,aAAa,aAAiC,YAAgC;AAC5F,SAAO,aAAa,aAAa,UAAU,EAAE,IAAI,OAAK,UAAU,CAAC;AACnE;AACO,gBAAS,aAAa,aAAiC,YAAgC;AAC5F,SAAO,aAAa,aAAa,UAAU,EAAE,IAAI,OAAK,UAAU,CAAC;AACnE;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"f92fa2abb31199d99fd3ae02d967dc6702faf862"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return mA=function(){return s},s}mA();function TG(e,n){mA().f[0]++;const t=(mA().s[0]++,zH(e,n));return mA().s[1]++,t.map(r=>(mA().f[1]++,mA().s[2]++,r.command+" "+r.args.join(" ")))}function U7e(e,n){return mA().f[2]++,mA().s[3]++,TG(e,n).map(t=>(mA().f[3]++,mA().s[4]++,"Undo "+t))}function R7e(e,n){return mA().f[4]++,mA().s[5]++,TG(e,n).map(t=>(mA().f[5]++,mA().s[6]++,"Redo "+t))}function Fr(){var e="/home/runner/work/maputnik/maputnik/src/libs/stylestore.ts",n="dfd07f747cd43002e646758ee096fc67f1f8153d",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/stylestore.ts",statementMap:{0:{start:{line:4,column:22},end:{line:4,column:32}},1:{start:{line:5,column:20},end:{line:5,column:27}},2:{start:{line:6,column:20},end:{line:9,column:1}},3:{start:{line:10,column:24},end:{line:10,column:44}},4:{start:{line:12,column:2},end:{line:12,column:36}},5:{start:{line:15,column:17},end:{line:15,column:19}},6:{start:{line:16,column:2},end:{line:21,column:3}},7:{start:{line:16,column:15},end:{line:16,column:16}},8:{start:{line:17,column:16},end:{line:17,column:42}},9:{start:{line:18,column:4},end:{line:20,column:5}},10:{start:{line:19,column:6},end:{line:19,column:32}},11:{start:{line:22,column:2},end:{line:22,column:16}},12:{start:{line:25,column:16},end:{line:25,column:30}},13:{start:{line:26,column:2},end:{line:26,column:86}},14:{start:{line:29,column:2},end:{line:31,column:3}},15:{start:{line:30,column:4},end:{line:30,column:41}},16:{start:{line:32,column:16},end:{line:32,column:30}},17:{start:{line:33,column:18},end:{line:33,column:26}},18:{start:{line:34,column:2},end:{line:34,column:17}},19:{start:{line:37,column:2},end:{line:37,column:57}},20:{start:{line:47,column:4},end:{line:47,column:40}},21:{start:{line:50,column:4},end:{line:50,column:13}},22:{start:{line:54,column:4},end:{line:59,column:5}},23:{start:{line:54,column:17},end:{line:54,column:18}},24:{start:{line:55,column:18},end:{line:55,column:44}},25:{start:{line:56,column:6},end:{line:58,column:7}},26:{start:{line:57,column:8},end:{line:57,column:44}},27:{start:{line:63,column:4},end:{line:64,column:34}},28:{start:{line:64,column:6},end:{line:64,column:34}},29:{start:{line:65,column:20},end:{line:65,column:67}},30:{start:{line:66,column:22},end:{line:66,column:68}},31:{start:{line:67,column:4},end:{line:68,column:39}},32:{start:{line:68,column:6},end:{line:68,column:39}},33:{start:{line:69,column:4},end:{line:69,column:25}},34:{start:{line:73,column:4},end:{line:73,column:51}},35:{start:{line:74,column:16},end:{line:74,column:37}},36:{start:{line:75,column:4},end:{line:75,column:63}},37:{start:{line:76,column:4},end:{line:76,column:65}},38:{start:{line:77,column:4},end:{line:77,column:20}}},fnMap:{0:{name:"loadDefaultStyle",decl:{start:{line:11,column:16},end:{line:11,column:32}},loc:{start:{line:11,column:37},end:{line:13,column:1}},line:11},1:{name:"loadStoredStyles",decl:{start:{line:14,column:9},end:{line:14,column:25}},loc:{start:{line:14,column:28},end:{line:23,column:1}},line:14},2:{name:"isStyleKey",decl:{start:{line:24,column:9},end:{line:24,column:19}},loc:{start:{line:24,column:25},end:{line:27,column:1}},line:24},3:{name:"fromKey",decl:{start:{line:28,column:9},end:{line:28,column:16}},loc:{start:{line:28,column:22},end:{line:35,column:1}},line:28},4:{name:"styleKey",decl:{start:{line:36,column:9},end:{line:36,column:17}},loc:{start:{line:36,column:27},end:{line:38,column:1}},line:36},5:{name:"(anonymous_5)",decl:{start:{line:46,column:2},end:{line:46,column:3}},loc:{start:{line:46,column:16},end:{line:48,column:3}},line:46},6:{name:"(anonymous_6)",decl:{start:{line:49,column:2},end:{line:49,column:3}},loc:{start:{line:49,column:11},end:{line:51,column:3}},line:49},7:{name:"(anonymous_7)",decl:{start:{line:53,column:2},end:{line:53,column:3}},loc:{start:{line:53,column:10},end:{line:60,column:3}},line:53},8:{name:"(anonymous_8)",decl:{start:{line:62,column:2},end:{line:62,column:3}},loc:{start:{line:62,column:18},end:{line:70,column:3}},line:62},9:{name:"(anonymous_9)",decl:{start:{line:72,column:2},end:{line:72,column:3}},loc:{start:{line:72,column:17},end:{line:78,column:3}},line:72}},branchMap:{0:{loc:{start:{line:18,column:4},end:{line:20,column:5}},type:"if",locations:[{start:{line:18,column:4},end:{line:20,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:18},1:{loc:{start:{line:26,column:9},end:{line:26,column:85}},type:"binary-expr",locations:[{start:{line:26,column:9},end:{line:26,column:27}},{start:{line:26,column:31},end:{line:26,column:57}},{start:{line:26,column:61},end:{line:26,column:85}}],line:26},2:{loc:{start:{line:29,column:2},end:{line:31,column:3}},type:"if",locations:[{start:{line:29,column:2},end:{line:31,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:29},3:{loc:{start:{line:56,column:6},end:{line:58,column:7}},type:"if",locations:[{start:{line:56,column:6},end:{line:58,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:56},4:{loc:{start:{line:63,column:4},end:{line:64,column:34}},type:"if",locations:[{start:{line:63,column:4},end:{line:64,column:34}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:63},5:{loc:{start:{line:67,column:4},end:{line:68,column:39}},type:"if",locations:[{start:{line:67,column:4},end:{line:68,column:39}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:67}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0},b:{0:[0,0],1:[0,0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/stylestore.ts"],names:[],mappings:"AAAA,OAAO,WAAW;AAClB,SAAQ,oBAAmB;AAC3B,OAAO,mBAAmB;AAG1B,MAAM,gBAAgB;AACtB,MAAM,cAAc;AACpB,MAAM,cAAc;AAAA,EAClB,QAAQ,CAAC,eAAe,cAAc,EAAE,KAAK,GAAG;AAAA,EAChD,aAAa,CAAC,eAAe,cAAc,EAAE,KAAK,GAAG;AACvD;AAEA,MAAM,kBAAkB,cAAc,CAAC,EAAE;AAGlC,gBAAS,iBAAiB,IAA8B;AAC7D,eAAa,iBAAiB,EAAE;AAClC;AAGA,SAAS,mBAAmB;AAC1B,QAAM,SAAS,CAAC;AAChB,WAAS,IAAI,GAAG,IAAI,OAAO,aAAa,QAAQ,KAAK;AACnD,UAAM,MAAM,OAAO,aAAa,IAAI,CAAC;AACrC,QAAG,WAAW,GAAI,GAAG;AACnB,aAAO,KAAK,QAAQ,GAAI,CAAC;AAAA,IAC3B;AAAA,EACF;AACA,SAAO;AACT;AAEA,SAAS,WAAW,KAAa;AAC/B,QAAM,QAAQ,IAAI,MAAM,GAAG;AAC3B,SAAO,MAAM,WAAW,KAAK,MAAM,CAAC,MAAM,iBAAiB,MAAM,CAAC,MAAM;AAC1E;AAGA,SAAS,QAAQ,KAAa;AAC5B,MAAG,CAAC,WAAW,GAAG,GAAG;AACnB,UAAM;AAAA,EACR;AAEA,QAAM,QAAQ,IAAI,MAAM,GAAG;AAC3B,QAAM,UAAU,MAAM,CAAC;AACvB,SAAO;AACT;AAGA,SAAS,SAAS,SAAiB;AACjC,SAAO,CAAC,eAAe,aAAa,OAAO,EAAE,KAAK,GAAG;AACvD;AAGO,aAAM,WAAW;AAAA;AAAA;AAAA;AAAA,EAItB;AAAA;AAAA;AAAA,EAIA,cAAc;AACZ,SAAK,YAAY,iBAAiB;AAAA,EACpC;AAAA,EAEA,KAAK,IAA8B;AACjC,OAAG,IAAI;AAAA,EACT;AAAA;AAAA,EAGA,QAAQ;AACN,aAAS,IAAI,GAAG,IAAI,OAAO,aAAa,QAAQ,KAAK;AACnD,YAAM,MAAM,OAAO,aAAa,IAAI,CAAC;AACrC,UAAG,IAAI,WAAW,aAAa,GAAG;AAChC,eAAO,aAAa,WAAW,GAAG;AAAA,MACpC;AAAA,IACF;AAAA,EACF;AAAA;AAAA,EAGA,YAAY,IAA8B;AACxC,QAAG,KAAK,UAAU,WAAW;AAAG,aAAO,iBAAiB,EAAE;AAC1D,UAAM,UAAU,OAAO,aAAa,QAAQ,YAAY,MAAM;AAC9D,UAAM,YAAY,OAAO,aAAa,QAAQ,SAAS,OAAO,CAAC;AAE/D,QAAG;AAAW,aAAO,GAAG,KAAK,MAAM,SAAS,CAAC;AAC7C,qBAAiB,EAAE;AAAA,EACrB;AAAA;AAAA,EAGA,KAAK,UAA+C;AAClD,eAAW,MAAM,oBAAoB,QAAQ;AAC7C,UAAM,MAAM,SAAS,SAAS,EAAE;AAChC,WAAO,aAAa,QAAQ,KAAK,KAAK,UAAU,QAAQ,CAAC;AACzD,WAAO,aAAa,QAAQ,YAAY,QAAQ,SAAS,EAAE;AAC3D,WAAO;AAAA,EACT;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"dfd07f747cd43002e646758ee096fc67f1f8153d"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Fr=function(){return s},s}Fr();const B_=(Fr().s[0]++,"maputnik"),KG=(Fr().s[1]++,"style"),JP=(Fr().s[2]++,{latest:[B_,"latest_style"].join(":"),accessToken:[B_,"access_token"].join(":")}),L7e=(Fr().s[3]++,cG[0].url);function eF(e){Fr().f[0]++,Fr().s[4]++,IG(L7e,e)}function z7e(){Fr().f[1]++;const e=(Fr().s[5]++,[]);Fr().s[6]++;for(let n=(Fr().s[7]++,0);n<window.localStorage.length;n++){const t=(Fr().s[8]++,window.localStorage.key(n));Fr().s[9]++,PG(t)?(Fr().b[0][0]++,Fr().s[10]++,e.push(j7e(t))):Fr().b[0][1]++}return Fr().s[11]++,e}function PG(e){Fr().f[2]++;const n=(Fr().s[12]++,e.split(":"));return Fr().s[13]++,Fr().b[1][0]++,n.length===3&&(Fr().b[1][1]++,n[0]===B_)&&(Fr().b[1][2]++,n[1]===KG)}function j7e(e){if(Fr().f[3]++,Fr().s[14]++,PG(e))Fr().b[2][1]++;else throw Fr().b[2][0]++,Fr().s[15]++,"Key is not a valid style key";const n=(Fr().s[16]++,e.split(":")),t=(Fr().s[17]++,n[2]);return Fr().s[18]++,t}function tF(e){return Fr().f[4]++,Fr().s[19]++,[B_,KG,e].join(":")}class nF{constructor(){nn(this,"mapStyles");Fr().f[5]++,Fr().s[20]++,this.mapStyles=z7e()}init(n){Fr().f[6]++,Fr().s[21]++,n(null)}purge(){Fr().f[7]++,Fr().s[22]++;for(let n=(Fr().s[23]++,0);n<window.localStorage.length;n++){const t=(Fr().s[24]++,window.localStorage.key(n));Fr().s[25]++,t.startsWith(B_)?(Fr().b[3][0]++,Fr().s[26]++,window.localStorage.removeItem(t)):Fr().b[3][1]++}}latestStyle(n){if(Fr().f[8]++,Fr().s[27]++,this.mapStyles.length===0)return Fr().b[4][0]++,Fr().s[28]++,eF(n);Fr().b[4][1]++;const t=(Fr().s[29]++,window.localStorage.getItem(JP.latest)),r=(Fr().s[30]++,window.localStorage.getItem(tF(t)));if(Fr().s[31]++,r)return Fr().b[5][0]++,Fr().s[32]++,n(JSON.parse(r));Fr().b[5][1]++,Fr().s[33]++,eF(n)}save(n){Fr().f[9]++,Fr().s[34]++,n=vu.ensureStyleValidity(n);const t=(Fr().s[35]++,tF(n.id));return Fr().s[36]++,window.localStorage.setItem(t,JSON.stringify(n)),Fr().s[37]++,window.localStorage.setItem(JP.latest,n.id),Fr().s[38]++,n}}/*! *****************************************************************************
|
||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||
this file except in compliance with the License. You may obtain a copy of the
|
||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||
|
||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||
|
||
See the Apache Version 2.0 License for specific language governing permissions
|
||
and limitations under the License.
|
||
***************************************************************************** */var hO=function(e,n){return hO=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,r){t.__proto__=r}||function(t,r){for(var i in r)r.hasOwnProperty(i)&&(t[i]=r[i])},hO(e,n)};function FG(e,n){hO(e,n);function t(){this.constructor=e}e.prototype=n===null?Object.create(n):(t.prototype=n.prototype,new t)}function W7e(e){var n=typeof Symbol=="function"&&e[Symbol.iterator],t=0;return n?n.call(e):{next:function(){return e&&t>=e.length&&(e=void 0),{value:e&&e[t++],done:!e}}}}function N7e(e,n){var t=typeof Symbol=="function"&&e[Symbol.iterator];if(!t)return e;var r=t.call(e),i,o=[],s;try{for(;(n===void 0||n-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(a){s={error:a}}finally{try{i&&!i.done&&(t=r.return)&&t.call(r)}finally{if(s)throw s.error}}return o}function G7e(){for(var e=[],n=0;n<arguments.length;n++)e=e.concat(N7e(arguments[n]));return e}var DG=function(){function e(n,t){this.target=t,this.type=n}return e}(),Q7e=function(e){FG(n,e);function n(t,r){var i=e.call(this,"error",r)||this;return i.message=t.message,i.error=t,i}return n}(DG),$7e=function(e){FG(n,e);function n(t,r,i){t===void 0&&(t=1e3),r===void 0&&(r="");var o=e.call(this,"close",i)||this;return o.wasClean=!0,o.code=t,o.reason=r,o}return n}(DG);/*!
|
||
* Reconnecting WebSocket
|
||
* by Pedro Ladaria <pedro.ladaria@gmail.com>
|
||
* https://github.com/pladaria/reconnecting-websocket
|
||
* License MIT
|
||
*/var Y7e=function(){if(typeof WebSocket<"u")return WebSocket},q7e=function(e){return typeof e<"u"&&!!e&&e.CLOSING===2},w0={maxReconnectionDelay:1e4,minReconnectionDelay:1e3+Math.random()*4e3,minUptime:5e3,reconnectionDelayGrowFactor:1.3,connectionTimeout:4e3,maxRetries:1/0,maxEnqueuedMessages:1/0,startClosed:!1,debug:!1},V7e=function(){function e(n,t,r){var i=this;r===void 0&&(r={}),this._listeners={error:[],message:[],open:[],close:[]},this._retryCount=-1,this._shouldReconnect=!0,this._connectLock=!1,this._binaryType="blob",this._closeCalled=!1,this._messageQueue=[],this.onclose=null,this.onerror=null,this.onmessage=null,this.onopen=null,this._handleOpen=function(o){i._debug("open event");var s=i._options.minUptime,a=s===void 0?w0.minUptime:s;clearTimeout(i._connectTimeout),i._uptimeTimeout=setTimeout(function(){return i._acceptOpen()},a),i._ws.binaryType=i._binaryType,i._messageQueue.forEach(function(f){return i._ws.send(f)}),i._messageQueue=[],i.onopen&&i.onopen(o),i._listeners.open.forEach(function(f){return i._callEventListener(o,f)})},this._handleMessage=function(o){i._debug("message event"),i.onmessage&&i.onmessage(o),i._listeners.message.forEach(function(s){return i._callEventListener(o,s)})},this._handleError=function(o){i._debug("error event",o.message),i._disconnect(void 0,o.message==="TIMEOUT"?"timeout":void 0),i.onerror&&i.onerror(o),i._debug("exec error listeners"),i._listeners.error.forEach(function(s){return i._callEventListener(o,s)}),i._connect()},this._handleClose=function(o){i._debug("close event"),i._clearTimeouts(),i._shouldReconnect&&i._connect(),i.onclose&&i.onclose(o),i._listeners.close.forEach(function(s){return i._callEventListener(o,s)})},this._url=n,this._protocols=t,this._options=r,this._options.startClosed&&(this._shouldReconnect=!1),this._connect()}return Object.defineProperty(e,"CONNECTING",{get:function(){return 0},enumerable:!0,configurable:!0}),Object.defineProperty(e,"OPEN",{get:function(){return 1},enumerable:!0,configurable:!0}),Object.defineProperty(e,"CLOSING",{get:function(){return 2},enumerable:!0,configurable:!0}),Object.defineProperty(e,"CLOSED",{get:function(){return 3},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CONNECTING",{get:function(){return e.CONNECTING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"OPEN",{get:function(){return e.OPEN},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CLOSING",{get:function(){return e.CLOSING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"CLOSED",{get:function(){return e.CLOSED},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"binaryType",{get:function(){return this._ws?this._ws.binaryType:this._binaryType},set:function(n){this._binaryType=n,this._ws&&(this._ws.binaryType=n)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"retryCount",{get:function(){return Math.max(this._retryCount,0)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"bufferedAmount",{get:function(){var n=this._messageQueue.reduce(function(t,r){return typeof r=="string"?t+=r.length:r instanceof Blob?t+=r.size:t+=r.byteLength,t},0);return n+(this._ws?this._ws.bufferedAmount:0)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"extensions",{get:function(){return this._ws?this._ws.extensions:""},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"protocol",{get:function(){return this._ws?this._ws.protocol:""},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"readyState",{get:function(){return this._ws?this._ws.readyState:this._options.startClosed?e.CLOSED:e.CONNECTING},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._ws?this._ws.url:""},enumerable:!0,configurable:!0}),e.prototype.close=function(n,t){if(n===void 0&&(n=1e3),this._closeCalled=!0,this._shouldReconnect=!1,this._clearTimeouts(),!this._ws){this._debug("close enqueued: no ws instance");return}if(this._ws.readyState===this.CLOSED){this._debug("close: already closed");return}this._ws.close(n,t)},e.prototype.reconnect=function(n,t){this._shouldReconnect=!0,this._closeCalled=!1,this._retryCount=-1,!this._ws||this._ws.readyState===this.CLOSED?this._connect():(this._disconnect(n,t),this._connect())},e.prototype.send=function(n){if(this._ws&&this._ws.readyState===this.OPEN)this._debug("send",n),this._ws.send(n);else{var t=this._options.maxEnqueuedMessages,r=t===void 0?w0.maxEnqueuedMessages:t;this._messageQueue.length<r&&(this._debug("enqueue",n),this._messageQueue.push(n))}},e.prototype.addEventListener=function(n,t){this._listeners[n]&&this._listeners[n].push(t)},e.prototype.dispatchEvent=function(n){var t,r,i=this._listeners[n.type];if(i)try{for(var o=W7e(i),s=o.next();!s.done;s=o.next()){var a=s.value;this._callEventListener(n,a)}}catch(f){t={error:f}}finally{try{s&&!s.done&&(r=o.return)&&r.call(o)}finally{if(t)throw t.error}}return!0},e.prototype.removeEventListener=function(n,t){this._listeners[n]&&(this._listeners[n]=this._listeners[n].filter(function(r){return r!==t}))},e.prototype._debug=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];this._options.debug&&console.log.apply(console,G7e(["RWS>"],n))},e.prototype._getNextDelay=function(){var n=this._options,t=n.reconnectionDelayGrowFactor,r=t===void 0?w0.reconnectionDelayGrowFactor:t,i=n.minReconnectionDelay,o=i===void 0?w0.minReconnectionDelay:i,s=n.maxReconnectionDelay,a=s===void 0?w0.maxReconnectionDelay:s,f=0;return this._retryCount>0&&(f=o*Math.pow(r,this._retryCount-1),f>a&&(f=a)),this._debug("next delay",f),f},e.prototype._wait=function(){var n=this;return new Promise(function(t){setTimeout(t,n._getNextDelay())})},e.prototype._getNextUrl=function(n){if(typeof n=="string")return Promise.resolve(n);if(typeof n=="function"){var t=n();if(typeof t=="string")return Promise.resolve(t);if(t.then)return t}throw Error("Invalid URL")},e.prototype._connect=function(){var n=this;if(!(this._connectLock||!this._shouldReconnect)){this._connectLock=!0;var t=this._options,r=t.maxRetries,i=r===void 0?w0.maxRetries:r,o=t.connectionTimeout,s=o===void 0?w0.connectionTimeout:o,a=t.WebSocket,f=a===void 0?Y7e():a;if(this._retryCount>=i){this._debug("max retries reached",this._retryCount,">=",i);return}if(this._retryCount++,this._debug("connect",this._retryCount),this._removeListeners(),!q7e(f))throw Error("No valid WebSocket class provided");this._wait().then(function(){return n._getNextUrl(n._url)}).then(function(g){n._closeCalled||(n._debug("connect",{url:g,protocols:n._protocols}),n._ws=n._protocols?new f(g,n._protocols):new f(g),n._ws.binaryType=n._binaryType,n._connectLock=!1,n._addListeners(),n._connectTimeout=setTimeout(function(){return n._handleTimeout()},s))})}},e.prototype._handleTimeout=function(){this._debug("timeout event"),this._handleError(new Q7e(Error("TIMEOUT"),this))},e.prototype._disconnect=function(n,t){if(n===void 0&&(n=1e3),this._clearTimeouts(),!!this._ws){this._removeListeners();try{this._ws.close(n,t),this._handleClose(new $7e(n,t,this))}catch{}}},e.prototype._acceptOpen=function(){this._debug("accept open"),this._retryCount=0},e.prototype._callEventListener=function(n,t){"handleEvent"in t?t.handleEvent(n):t(n)},e.prototype._removeListeners=function(){this._ws&&(this._debug("removeListeners"),this._ws.removeEventListener("open",this._handleOpen),this._ws.removeEventListener("close",this._handleClose),this._ws.removeEventListener("message",this._handleMessage),this._ws.removeEventListener("error",this._handleError))},e.prototype._addListeners=function(){this._ws&&(this._debug("addListeners"),this._ws.addEventListener("open",this._handleOpen),this._ws.addEventListener("close",this._handleClose),this._ws.addEventListener("message",this._handleMessage),this._ws.addEventListener("error",this._handleError))},e.prototype._clearTimeouts=function(){clearTimeout(this._connectTimeout),clearTimeout(this._uptimeTimeout)},e}();function Rr(){var e="/home/runner/work/maputnik/maputnik/src/libs/apistore.ts",n="affc9a723ceb39c9f38866dab538bc0c9774f995",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/apistore.ts",statementMap:{0:{start:{line:7,column:18},end:{line:7,column:24}},1:{start:{line:10,column:4},end:{line:11,column:7}},2:{start:{line:12,column:17},end:{line:12,column:36}},3:{start:{line:13,column:17},end:{line:13,column:41}},4:{start:{line:14,column:4},end:{line:14,column:45}},5:{start:{line:15,column:4},end:{line:15,column:50}},6:{start:{line:16,column:4},end:{line:16,column:37}},7:{start:{line:19,column:4},end:{line:30,column:7}},8:{start:{line:22,column:6},end:{line:22,column:29}},9:{start:{line:24,column:23},end:{line:24,column:27}},10:{start:{line:25,column:6},end:{line:25,column:39}},11:{start:{line:26,column:6},end:{line:26,column:32}},12:{start:{line:27,column:6},end:{line:27,column:15}},13:{start:{line:29,column:6},end:{line:29,column:52}},14:{start:{line:33,column:23},end:{line:33,column:67}},15:{start:{line:34,column:4},end:{line:46,column:6}},16:{start:{line:35,column:6},end:{line:36,column:15}},17:{start:{line:36,column:8},end:{line:36,column:15}},18:{start:{line:37,column:6},end:{line:37,column:52}},19:{start:{line:38,column:24},end:{line:38,column:40}},20:{start:{line:39,column:6},end:{line:43,column:7}},21:{start:{line:40,column:8},end:{line:40,column:41}},22:{start:{line:42,column:8},end:{line:42,column:27}},23:{start:{line:44,column:27},end:{line:44,column:65}},24:{start:{line:45,column:6},end:{line:45,column:44}},25:{start:{line:49,column:4},end:{line:59,column:5}},26:{start:{line:50,column:6},end:{line:56,column:9}},27:{start:{line:53,column:8},end:{line:53,column:31}},28:{start:{line:55,column:8},end:{line:55,column:44}},29:{start:{line:58,column:6},end:{line:58,column:92}},30:{start:{line:63,column:22},end:{line:67,column:5}},31:{start:{line:68,column:15},end:{line:68,column:26}},32:{start:{line:69,column:4},end:{line:79,column:7}},33:{start:{line:77,column:6},end:{line:78,column:29}},34:{start:{line:78,column:8},end:{line:78,column:29}},35:{start:{line:80,column:4},end:{line:80,column:20}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:20},end:{line:17,column:3}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:10,column:58},end:{line:10,column:59}},loc:{start:{line:10,column:64},end:{line:11,column:5}},line:10},2:{name:"(anonymous_2)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:11},end:{line:31,column:3}},line:18},3:{name:"(anonymous_3)",decl:{start:{line:21,column:12},end:{line:21,column:13}},loc:{start:{line:21,column:26},end:{line:23,column:5}},line:21},4:{name:"(anonymous_4)",decl:{start:{line:23,column:12},end:{line:23,column:13}},loc:{start:{line:23,column:22},end:{line:28,column:5}},line:23},5:{name:"(anonymous_5)",decl:{start:{line:28,column:13},end:{line:28,column:14}},loc:{start:{line:28,column:19},end:{line:30,column:5}},line:28},6:{name:"(anonymous_6)",decl:{start:{line:32,column:2},end:{line:32,column:3}},loc:{start:{line:32,column:23},end:{line:47,column:3}},line:32},7:{name:"(anonymous_7)",decl:{start:{line:34,column:27},end:{line:34,column:28}},loc:{start:{line:34,column:34},end:{line:46,column:5}},line:34},8:{name:"(anonymous_8)",decl:{start:{line:48,column:2},end:{line:48,column:3}},loc:{start:{line:48,column:18},end:{line:60,column:3}},line:48},9:{name:"(anonymous_9)",decl:{start:{line:52,column:14},end:{line:52,column:15}},loc:{start:{line:52,column:33},end:{line:54,column:7}},line:52},10:{name:"(anonymous_10)",decl:{start:{line:54,column:14},end:{line:54,column:15}},loc:{start:{line:54,column:29},end:{line:56,column:7}},line:54},11:{name:"(anonymous_11)",decl:{start:{line:62,column:2},end:{line:62,column:3}},loc:{start:{line:62,column:17},end:{line:81,column:3}},line:62},12:{name:"(anonymous_12)",decl:{start:{line:76,column:13},end:{line:76,column:14}},loc:{start:{line:76,column:29},end:{line:79,column:5}},line:76}},branchMap:{0:{loc:{start:{line:10,column:30},end:{line:11,column:6}},type:"binary-expr",locations:[{start:{line:10,column:30},end:{line:10,column:53}},{start:{line:10,column:58},end:{line:11,column:5}}],line:10},1:{loc:{start:{line:12,column:17},end:{line:12,column:36}},type:"binary-expr",locations:[{start:{line:12,column:17},end:{line:12,column:26}},{start:{line:12,column:30},end:{line:12,column:36}}],line:12},2:{loc:{start:{line:13,column:17},end:{line:13,column:41}},type:"binary-expr",locations:[{start:{line:13,column:17},end:{line:13,column:26}},{start:{line:13,column:30},end:{line:13,column:41}}],line:13},3:{loc:{start:{line:35,column:6},end:{line:36,column:15}},type:"if",locations:[{start:{line:35,column:6},end:{line:36,column:15}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:35},4:{loc:{start:{line:49,column:4},end:{line:59,column:5}},type:"if",locations:[{start:{line:49,column:4},end:{line:59,column:5}},{start:{line:57,column:11},end:{line:59,column:5}}],line:49},5:{loc:{start:{line:77,column:6},end:{line:78,column:29}},type:"if",locations:[{start:{line:77,column:6},end:{line:78,column:29}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:77}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/apistore.ts"],names:[],mappings:"AAAA,OAAO,WAAW;AAClB,SAAQ,cAAa;AAErB,OAAO,2BAA2B;AAQ3B,aAAM,cAAc;AAAA,EAEzB;AAAA,EACA;AAAA,EACA,gBAAoC;AAAA,EACpC;AAAA,EAEA,YAAY,MAA4B;AACtC,SAAK,qBAAqB,KAAK,uBAAuB,MAAM;AAAA,IAAC;AAC7D,UAAM,OAAO,KAAK,QAAQ;AAC1B,UAAM,OAAO,KAAK,QAAQ;AAC1B,SAAK,WAAW,UAAU,IAAI,IAAI,IAAI;AACtC,SAAK,eAAe,QAAQ,IAAI,IAAI,IAAI;AACxC,SAAK,OAAO,KAAK,KAAK,KAAK,IAAI;AAAA,EACjC;AAAA,EAEA,KAAK,IAA8B;AACjC,UAAM,KAAK,WAAW,WAAW;AAAA,MAC/B,MAAM;AAAA,IACR,CAAC,EACE,KAAK,CAAC,aAAc;AACnB,aAAO,SAAS,KAAK;AAAA,IACvB,CAAC,EACA,KAAK,CAAC,SAAS;AACd,YAAM,WAAW;AACjB,WAAK,gBAAgB,SAAS,CAAC;AAC/B,WAAK,mBAAmB;AACxB,SAAG,IAAI;AAAA,IACT,CAAC,EACA,MAAM,MAAM;AACX,SAAG,IAAI,MAAM,8BAA8B,CAAC;AAAA,IAC9C,CAAC;AAAA,EACL;AAAA,EAEA,qBAAqB;AACnB,UAAM,aAAa,IAAI,sBAAsB,KAAK,YAAY;AAC9D,eAAW,YAAY,OAAK;AAC1B,UAAG,CAAC,EAAE;AAAM;AACZ,cAAQ,IAAI,gCAAgC;AAC5C,UAAI,cAAc,MAAM;AACxB,UAAI;AACF,sBAAc,KAAK,MAAM,EAAE,IAAI;AAAA,MACjC,SAAQ,KAAK;AACX,gBAAQ,MAAM,GAAG;AAAA,MACnB;AACA,YAAM,eAAe,MAAM,oBAAoB,WAAW;AAC1D,WAAK,mBAAmB,YAAY;AAAA,IACtC;AAAA,EACF;AAAA,EAEA,YAAY,IAA8B;AACxC,QAAG,KAAK,eAAe;AACrB,YAAM,KAAK,WAAW,aAAa,KAAK,eAAe;AAAA,QACrD,MAAM;AAAA,MACR,CAAC,EACE,KAAK,SAAS,UAAU;AACvB,eAAO,SAAS,KAAK;AAAA,MACvB,CAAC,EACA,KAAK,SAAS,MAAM;AACnB,WAAG,MAAM,oBAAoB,IAAI,CAAC;AAAA,MACpC,CAAC;AAAA,IACL,OAAO;AACL,YAAM,IAAI,MAAM,oEAAoE;AAAA,IACtF;AAAA,EACF;AAAA;AAAA,EAGA,KAAK,UAA+C;AAClD,UAAM,YAAY;AAAA,MAChB,MAAM;AAAA,QACJ,MAAM,oBAAoB,QAAQ;AAAA,MACpC;AAAA,IACF;AAEA,UAAM,KAAK,SAAS;AACpB,UAAM,KAAK,WAAW,aAAa,IAAI;AAAA,MACrC,QAAQ;AAAA,MACR,MAAM;AAAA,MACN,SAAS;AAAA,QACP,gBAAgB;AAAA,MAClB;AAAA,MACA,MAAM;AAAA,IACR,CAAC,EACE,MAAM,SAAS,OAAO;AACrB,UAAG;AAAO,gBAAQ,MAAM,KAAK;AAAA,IAC/B,CAAC;AACH,WAAO;AAAA,EACT;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"affc9a723ceb39c9f38866dab538bc0c9774f995"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return Rr=function(){return s},s}Rr();class H7e{constructor(n){nn(this,"localUrl");nn(this,"websocketUrl");nn(this,"latestStyleId",(Rr().s[0]++,void 0));nn(this,"onLocalStyleChange");Rr().f[0]++,Rr().s[1]++,this.onLocalStyleChange=(Rr().b[0][0]++,n.onLocalStyleChange||(Rr().b[0][1]++,()=>{Rr().f[1]++}));const t=(Rr().s[2]++,Rr().b[1][0]++,n.port||(Rr().b[1][1]++,"8000")),r=(Rr().s[3]++,Rr().b[2][0]++,n.host||(Rr().b[2][1]++,"localhost"));Rr().s[4]++,this.localUrl=`http://${r}:${t}`,Rr().s[5]++,this.websocketUrl=`ws://${r}:${t}/ws`,Rr().s[6]++,this.init=this.init.bind(this)}init(n){Rr().f[2]++,Rr().s[7]++,fetch(this.localUrl+"/styles",{mode:"cors"}).then(t=>(Rr().f[3]++,Rr().s[8]++,t.json())).then(t=>{Rr().f[4]++;const r=(Rr().s[9]++,t);Rr().s[10]++,this.latestStyleId=r[0],Rr().s[11]++,this.notifyLocalChanges(),Rr().s[12]++,n(null)}).catch(()=>{Rr().f[5]++,Rr().s[13]++,n(new Error("Can not connect to style API"))})}notifyLocalChanges(){Rr().f[6]++;const n=(Rr().s[14]++,new V7e(this.websocketUrl));Rr().s[15]++,n.onmessage=t=>{if(Rr().f[7]++,Rr().s[16]++,t.data)Rr().b[3][1]++;else{Rr().b[3][0]++,Rr().s[17]++;return}Rr().s[18]++,console.log("Received style update from API");let r=(Rr().s[19]++,vu.emptyStyle);Rr().s[20]++;try{Rr().s[21]++,r=JSON.parse(t.data)}catch(o){Rr().s[22]++,console.error(o)}const i=(Rr().s[23]++,vu.ensureStyleValidity(r));Rr().s[24]++,this.onLocalStyleChange(i)}}latestStyle(n){if(Rr().f[8]++,Rr().s[25]++,this.latestStyleId)Rr().b[4][0]++,Rr().s[26]++,fetch(this.localUrl+"/styles/"+this.latestStyleId,{mode:"cors"}).then(function(t){return Rr().f[9]++,Rr().s[27]++,t.json()}).then(function(t){Rr().f[10]++,Rr().s[28]++,n(vu.ensureStyleValidity(t))});else throw Rr().b[4][1]++,Rr().s[29]++,new Error("No latest style available. You need to init the api backend first.")}save(n){Rr().f[11]++;const t=(Rr().s[30]++,zR(vu.stripAccessTokens(vu.replaceAccessTokens(n)))),r=(Rr().s[31]++,n.id);return Rr().s[32]++,fetch(this.localUrl+"/styles/"+r,{method:"PUT",mode:"cors",headers:{"Content-Type":"application/json; charset=utf-8"},body:t}).catch(function(i){Rr().f[12]++,Rr().s[33]++,i?(Rr().b[5][0]++,Rr().s[34]++,console.error(i)):Rr().b[5][1]++}),Rr().s[35]++,n}}function ts(){var e="/home/runner/work/maputnik/maputnik/src/libs/revisions.ts",n="75aa64d8ac26c323427e8636e380dc661caefa68",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/revisions.ts",statementMap:{0:{start:{line:5,column:4},end:{line:5,column:38}},1:{start:{line:6,column:4},end:{line:6,column:50}},2:{start:{line:9,column:4},end:{line:9,column:53}},3:{start:{line:12,column:4},end:{line:12,column:43}},4:{start:{line:15,column:4},end:{line:15,column:34}},5:{start:{line:16,column:4},end:{line:16,column:22}},6:{start:{line:19,column:4},end:{line:21,column:5}},7:{start:{line:20,column:6},end:{line:20,column:24}},8:{start:{line:22,column:4},end:{line:22,column:24}},9:{start:{line:25,column:4},end:{line:27,column:5}},10:{start:{line:26,column:6},end:{line:26,column:24}},11:{start:{line:28,column:4},end:{line:28,column:24}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:4,column:2},end:{line:4,column:3}},loc:{start:{line:4,column:37},end:{line:7,column:3}},line:4},1:{name:"(anonymous_1)",decl:{start:{line:8,column:2},end:{line:8,column:3}},loc:{start:{line:8,column:15},end:{line:10,column:3}},line:8},2:{name:"(anonymous_2)",decl:{start:{line:11,column:2},end:{line:11,column:3}},loc:{start:{line:11,column:16},end:{line:13,column:3}},line:11},3:{name:"(anonymous_3)",decl:{start:{line:14,column:2},end:{line:14,column:3}},loc:{start:{line:14,column:24},end:{line:17,column:3}},line:14},4:{name:"(anonymous_4)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:9},end:{line:23,column:3}},line:18},5:{name:"(anonymous_5)",decl:{start:{line:24,column:2},end:{line:24,column:3}},loc:{start:{line:24,column:9},end:{line:29,column:3}},line:24}},branchMap:{0:{loc:{start:{line:4,column:14},end:{line:4,column:35}},type:"default-arg",locations:[{start:{line:4,column:33},end:{line:4,column:35}}],line:4},1:{loc:{start:{line:19,column:4},end:{line:21,column:5}},type:"if",locations:[{start:{line:19,column:4},end:{line:21,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:19},2:{loc:{start:{line:25,column:4},end:{line:27,column:5}},type:"if",locations:[{start:{line:25,column:4},end:{line:27,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:25}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0},f:{0:0,1:0,2:0,3:0,4:0,5:0},b:{0:[0],1:[0,0],2:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/revisions.ts"],names:[],mappings:"AAEO,aAAM,cAAc;AAAA,EACzB;AAAA,EACA;AAAA,EAGA,YAAY,mBAAiB,CAAC,GAAG;AAC/B,SAAK,YAAY;AACjB,SAAK,aAAa,iBAAiB,SAAS;AAAA,EAC9C;AAAA,EAEA,IAAI,SAAS;AACX,WAAO,KAAK,UAAU,KAAK,UAAU,SAAS,CAAC;AAAA,EACjD;AAAA,EAEA,IAAI,UAAU;AACZ,WAAO,KAAK,UAAU,KAAK,UAAU;AAAA,EACvC;AAAA,EAEA,YAAY,UAA6C;AAGvD,SAAK,UAAU,KAAK,QAAQ;AAC5B,SAAK;AAAA,EACP;AAAA,EAEA,OAAO;AACL,QAAG,KAAK,aAAa,GAAG;AACtB,WAAK;AAAA,IACP;AACA,WAAO,KAAK;AAAA,EACd;AAAA,EAEA,OAAO;AACL,QAAG,KAAK,aAAa,KAAK,UAAU,SAAS,GAAG;AAC9C,WAAK;AAAA,IACP;AACA,WAAO,KAAK;AAAA,EACd;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"75aa64d8ac26c323427e8636e380dc661caefa68"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ts=function(){return s},s}ts();class Z7e{constructor(n=(ts().b[0][0]++,[])){nn(this,"revisions");nn(this,"currentIdx");ts().f[0]++,ts().s[0]++,this.revisions=n,ts().s[1]++,this.currentIdx=n.length-1}get latest(){return ts().f[1]++,ts().s[2]++,this.revisions[this.revisions.length-1]}get current(){return ts().f[2]++,ts().s[3]++,this.revisions[this.currentIdx]}addRevision(n){ts().f[3]++,ts().s[4]++,this.revisions.push(n),ts().s[5]++,this.currentIdx++}undo(){return ts().f[4]++,ts().s[6]++,this.currentIdx>0?(ts().b[1][0]++,ts().s[7]++,this.currentIdx--):ts().b[1][1]++,ts().s[8]++,this.current}redo(){return ts().f[5]++,ts().s[9]++,this.currentIdx<this.revisions.length-1?(ts().b[2][0]++,ts().s[10]++,this.currentIdx++):ts().b[2][1]++,ts().s[11]++,this.current}}var UG="Expected a function",rF=NaN,X7e="[object Symbol]",J7e=/^\s+|\s+$/g,e8e=/^[-+]0x[0-9a-f]+$/i,t8e=/^0b[01]+$/i,n8e=/^0o[0-7]+$/i,r8e=parseInt,i8e=typeof window=="object"&&window&&window.Object===Object&&window,o8e=typeof self=="object"&&self&&self.Object===Object&&self,a8e=i8e||o8e||Function("return this")(),s8e=Object.prototype,l8e=s8e.toString,u8e=Math.max,A8e=Math.min,yS=function(){return a8e.Date.now()};function c8e(e,n,t){var r,i,o,s,a,f,g=0,x=!1,k=!1,B=!0;if(typeof e!="function")throw new TypeError(UG);n=iF(n)||0,E4(t)&&(x=!!t.leading,k="maxWait"in t,o=k?u8e(iF(t.maxWait)||0,n):o,B="trailing"in t?!!t.trailing:B);function P(ae){var ue=r,ye=i;return r=i=void 0,g=ae,s=e.apply(ye,ue),s}function R(ae){return g=ae,a=setTimeout($,n),x?P(ae):s}function H(ae){var ue=ae-f,ye=ae-g,Re=n-ue;return k?A8e(Re,o-ye):Re}function W(ae){var ue=ae-f,ye=ae-g;return f===void 0||ue>=n||ue<0||k&&ye>=o}function $(){var ae=yS();if(W(ae))return q(ae);a=setTimeout($,H(ae))}function q(ae){return a=void 0,B&&r?P(ae):(r=i=void 0,s)}function oe(){a!==void 0&&clearTimeout(a),g=0,r=f=i=a=void 0}function ne(){return a===void 0?s:q(yS())}function ce(){var ae=yS(),ue=W(ae);if(r=arguments,i=this,f=ae,ue){if(a===void 0)return R(f);if(k)return a=setTimeout($,n),P(f)}return a===void 0&&(a=setTimeout($,n)),s}return ce.cancel=oe,ce.flush=ne,ce}function d8e(e,n,t){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(UG);return E4(t)&&(r="leading"in t?!!t.leading:r,i="trailing"in t?!!t.trailing:i),c8e(e,n,{leading:r,maxWait:n,trailing:i})}function E4(e){var n=typeof e;return!!e&&(n=="object"||n=="function")}function h8e(e){return!!e&&typeof e=="object"}function f8e(e){return typeof e=="symbol"||h8e(e)&&l8e.call(e)==X7e}function iF(e){if(typeof e=="number")return e;if(f8e(e))return rF;if(E4(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=E4(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=e.replace(J7e,"");var t=t8e.test(e);return t||n8e.test(e)?r8e(e.slice(2),t?2:8):e8e.test(e)?rF:+e}var p8e=d8e;const m8e=ga(p8e);function ei(){var e="/home/runner/work/maputnik/maputnik/src/libs/layerwatcher.ts",n="77d2098743f5a64765174c6e14fc4dc25f900f6c",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/layerwatcher.ts",statementMap:{0:{start:{line:10,column:4},end:{line:11,column:7}},1:{start:{line:12,column:4},end:{line:13,column:7}},2:{start:{line:14,column:4},end:{line:14,column:23}},3:{start:{line:15,column:4},end:{line:15,column:28}},4:{start:{line:16,column:4},end:{line:16,column:90}},5:{start:{line:19,column:28},end:{line:19,column:48}},6:{start:{line:20,column:4},end:{line:22,column:7}},7:{start:{line:21,column:6},end:{line:21,column:88}},8:{start:{line:23,column:4},end:{line:25,column:5}},9:{start:{line:24,column:6},end:{line:24,column:42}},10:{start:{line:26,column:4},end:{line:26,column:48}},11:{start:{line:29,column:33},end:{line:29,column:58}},12:{start:{line:30,column:4},end:{line:43,column:7}},13:{start:{line:31,column:6},end:{line:42,column:9}},14:{start:{line:32,column:32},end:{line:32,column:71}},15:{start:{line:33,column:23},end:{line:33,column:53}},16:{start:{line:34,column:8},end:{line:40,column:11}},17:{start:{line:35,column:10},end:{line:39,column:13}},18:{start:{line:36,column:40},end:{line:36,column:75}},19:{start:{line:37,column:12},end:{line:37,column:71}},20:{start:{line:38,column:12},end:{line:38,column:64}},21:{start:{line:41,column:8},end:{line:41,column:60}},22:{start:{line:44,column:4},end:{line:46,column:5}},23:{start:{line:45,column:6},end:{line:45,column:52}},24:{start:{line:50,column:4},end:{line:50,column:25}},25:{start:{line:53,column:4},end:{line:53,column:30}}},fnMap:{0:{name:"(anonymous_0)",decl:{start:{line:9,column:2},end:{line:9,column:3}},loc:{start:{line:9,column:25},end:{line:17,column:3}},line:9},1:{name:"(anonymous_1)",decl:{start:{line:10,column:52},end:{line:10,column:53}},loc:{start:{line:10,column:58},end:{line:11,column:5}},line:10},2:{name:"(anonymous_2)",decl:{start:{line:12,column:62},end:{line:12,column:63}},loc:{start:{line:12,column:68},end:{line:13,column:5}},line:12},3:{name:"(anonymous_3)",decl:{start:{line:18,column:2},end:{line:18,column:3}},loc:{start:{line:18,column:18},end:{line:27,column:3}},line:18},4:{name:"(anonymous_4)",decl:{start:{line:20,column:48},end:{line:20,column:49}},loc:{start:{line:20,column:62},end:{line:22,column:5}},line:20},5:{name:"(anonymous_5)",decl:{start:{line:28,column:2},end:{line:28,column:3}},loc:{start:{line:28,column:32},end:{line:47,column:3}},line:28},6:{name:"(anonymous_6)",decl:{start:{line:30,column:39},end:{line:30,column:40}},loc:{start:{line:30,column:53},end:{line:43,column:5}},line:30},7:{name:"(anonymous_7)",decl:{start:{line:31,column:46},end:{line:31,column:47}},loc:{start:{line:31,column:65},end:{line:42,column:7}},line:31},8:{name:"(anonymous_8)",decl:{start:{line:34,column:58},end:{line:34,column:59}},loc:{start:{line:34,column:71},end:{line:40,column:9}},line:34},9:{name:"(anonymous_9)",decl:{start:{line:35,column:50},end:{line:35,column:51}},loc:{start:{line:35,column:68},end:{line:39,column:11}},line:35},10:{name:"(anonymous_10)",decl:{start:{line:49,column:2},end:{line:49,column:3}},loc:{start:{line:49,column:16},end:{line:51,column:3}},line:49},11:{name:"(anonymous_11)",decl:{start:{line:52,column:2},end:{line:52,column:3}},loc:{start:{line:52,column:21},end:{line:54,column:3}},line:52}},branchMap:{0:{loc:{start:{line:9,column:14},end:{line:9,column:23}},type:"default-arg",locations:[{start:{line:9,column:21},end:{line:9,column:23}}],line:9},1:{loc:{start:{line:10,column:27},end:{line:11,column:6}},type:"binary-expr",locations:[{start:{line:10,column:27},end:{line:10,column:47}},{start:{line:10,column:52},end:{line:11,column:5}}],line:10},2:{loc:{start:{line:12,column:32},end:{line:13,column:6}},type:"binary-expr",locations:[{start:{line:12,column:32},end:{line:12,column:57}},{start:{line:12,column:62},end:{line:13,column:5}}],line:12},3:{loc:{start:{line:23,column:4},end:{line:25,column:5}},type:"if",locations:[{start:{line:23,column:4},end:{line:25,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:23},4:{loc:{start:{line:31,column:7},end:{line:31,column:36}},type:"binary-expr",locations:[{start:{line:31,column:7},end:{line:31,column:30}},{start:{line:31,column:34},end:{line:31,column:36}}],line:31},5:{loc:{start:{line:32,column:32},end:{line:32,column:71}},type:"binary-expr",locations:[{start:{line:32,column:32},end:{line:32,column:65}},{start:{line:32,column:69},end:{line:32,column:71}}],line:32},6:{loc:{start:{line:36,column:40},end:{line:36,column:75}},type:"binary-expr",locations:[{start:{line:36,column:40},end:{line:36,column:69}},{start:{line:36,column:73},end:{line:36,column:75}}],line:36},7:{loc:{start:{line:44,column:4},end:{line:46,column:5}},type:"if",locations:[{start:{line:44,column:4},end:{line:46,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:44}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0},b:{0:[0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0],7:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/layerwatcher.ts"],names:[],mappings:"AAAA,OAAO,cAAc;AACrB,OAAO,aAAa;AAUpB,qBAAqB,aAAa;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAEA,YAAY,OAA4B,CAAC,GAAG;AAC1C,SAAK,kBAAkB,KAAK,oBAAoB,MAAM;AAAA,IAAC;AACvD,SAAK,uBAAuB,KAAK,yBAAyB,MAAM;AAAA,IAAC;AAEjE,SAAK,WAAW,CAAC;AACjB,SAAK,gBAAgB,CAAC;AAKtB,SAAK,oCAAoC,SAAS,KAAK,0BAA0B,GAAI;AAAA,EACvF;AAAA,EAEA,WAAW,KAAU;AACnB,UAAM,kBAAkB,EAAE,GAAG,KAAK,SAAS;AAE3C,WAAO,KAAK,IAAI,MAAM,YAAY,EAAE,QAAQ,cAAY;AAGtD,WAAK,SAAS,QAAQ,IAAI,IAAI,MAAM,aAAa,QAAQ,EAAE,QAAQ;AAAA,IACrE,CAAC;AAED,QAAG,CAAC,QAAQ,iBAAiB,KAAK,QAAQ,GAAG;AAC3C,WAAK,gBAAgB,KAAK,QAAQ;AAAA,IACpC;AAEA,SAAK,kCAAkC,GAAG;AAAA,EAC5C;AAAA,EAEA,yBAAyB,KAAU;AACjC,UAAM,uBAAuB,EAAE,GAAG,KAAK,cAAc;AAErD,WAAO,KAAK,KAAK,QAAQ,EAAE,QAAQ,cAAY;AAC7C,OAAC,KAAK,SAAS,QAAQ,KAAK,CAAC,GAAG,QAAQ,mBAAiB;AACvD,cAAM,kBAAkB,KAAK,cAAc,aAAa,KAAK,CAAC;AAC9D,cAAM,SAAS,EAAE,aAAa,cAAc;AAC5C,YAAI,oBAAoB,UAAU,MAAa,EAAE,QAAQ,aAAW;AAClE,iBAAO,KAAK,QAAQ,UAAU,EAAE,QAAQ,kBAAgB;AACtD,kBAAM,sBAAsB,gBAAgB,YAAY,KAAK,CAAC;AAC9D,gCAAoB,QAAQ,WAAW,YAAY,CAAC,IAAI,CAAC;AACzD,4BAAgB,YAAY,IAAI;AAAA,UAClC,CAAC;AAAA,QACH,CAAC;AAED,aAAK,cAAc,aAAa,IAAI;AAAA,MACtC,CAAC;AAAA,IACH,CAAC;AAED,QAAG,CAAC,QAAQ,sBAAsB,KAAK,aAAa,GAAG;AACrD,WAAK,qBAAqB,KAAK,aAAa;AAAA,IAC9C;AAAA,EAEF;AAAA;AAAA,EAGA,IAAI,UAAU;AACZ,WAAO,KAAK;AAAA,EACd;AAAA,EAEA,IAAI,eAAe;AACjB,WAAO,KAAK;AAAA,EACd;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"77d2098743f5a64765174c6e14fc4dc25f900f6c"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return ei=function(){return s},s}ei();class g8e{constructor(n=(ei().b[0][0]++,{})){nn(this,"onSourcesChange");nn(this,"onVectorLayersChange");nn(this,"throttledAnalyzeVectorLayerFields");nn(this,"_sources");nn(this,"_vectorLayers");ei().f[0]++,ei().s[0]++,this.onSourcesChange=(ei().b[1][0]++,n.onSourcesChange||(ei().b[1][1]++,()=>{ei().f[1]++})),ei().s[1]++,this.onVectorLayersChange=(ei().b[2][0]++,n.onVectorLayersChange||(ei().b[2][1]++,()=>{ei().f[2]++})),ei().s[2]++,this._sources={},ei().s[3]++,this._vectorLayers={},ei().s[4]++,this.throttledAnalyzeVectorLayerFields=m8e(this.analyzeVectorLayerFields,5e3)}analyzeMap(n){ei().f[3]++;const t=(ei().s[5]++,{...this._sources});ei().s[6]++,Object.keys(n.style.sourceCaches).forEach(r=>{ei().f[4]++,ei().s[7]++,this._sources[r]=n.style.sourceCaches[r]._source.vectorLayerIds}),ei().s[8]++,k6(t,this._sources)?ei().b[3][1]++:(ei().b[3][0]++,ei().s[9]++,this.onSourcesChange(this._sources)),ei().s[10]++,this.throttledAnalyzeVectorLayerFields(n)}analyzeVectorLayerFields(n){ei().f[5]++;const t=(ei().s[11]++,{...this._vectorLayers});ei().s[12]++,Object.keys(this._sources).forEach(r=>{ei().f[6]++,ei().s[13]++,(ei().b[4][0]++,this._sources[r]||(ei().b[4][1]++,[])).forEach(i=>{ei().f[7]++;const o=(ei().s[14]++,ei().b[5][0]++,this._vectorLayers[i]||(ei().b[5][1]++,{})),s=(ei().s[15]++,{sourceLayer:i});ei().s[16]++,n.querySourceFeatures(r,s).forEach(a=>{ei().f[8]++,ei().s[17]++,Object.keys(a.properties).forEach(f=>{ei().f[9]++;const g=(ei().s[18]++,ei().b[6][0]++,o[f]||(ei().b[6][1]++,{}));ei().s[19]++,g[a.properties[f]]={},ei().s[20]++,o[f]=g})}),ei().s[21]++,this._vectorLayers[i]=o})}),ei().s[22]++,k6(t,this._vectorLayers)?ei().b[7][1]++:(ei().b[7][0]++,ei().s[23]++,this.onVectorLayersChange(this._vectorLayers))}get sources(){return ei().f[10]++,ei().s[24]++,this._sources}get vectorLayers(){return ei().f[11]++,ei().s[25]++,this._vectorLayers}}function $o(){var e="/home/runner/work/maputnik/maputnik/src/libs/debug.ts",n="f3fc52390a8e0125df8ac2b3d3c29ba103bd1c39",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/libs/debug.ts",statementMap:{0:{start:{line:1,column:19},end:{line:1,column:21}},1:{start:{line:3,column:13},end:{line:3,column:55}},2:{start:{line:4,column:18},end:{line:4,column:33}},3:{start:{line:5,column:2},end:{line:9,column:3}},4:{start:{line:6,column:4},end:{line:6,column:42}},5:{start:{line:8,column:4},end:{line:8,column:17}},6:{start:{line:12,column:2},end:{line:12,column:91}},7:{start:{line:15,column:2},end:{line:17,column:3}},8:{start:{line:16,column:4},end:{line:16,column:19}},9:{start:{line:18,column:2},end:{line:18,column:54}},10:{start:{line:19,column:2},end:{line:19,column:37}},11:{start:{line:22,column:2},end:{line:24,column:3}},12:{start:{line:23,column:4},end:{line:23,column:19}},13:{start:{line:25,column:2},end:{line:27,column:3}},14:{start:{line:26,column:4},end:{line:26,column:38}},15:{start:{line:29,column:12},end:{line:33,column:1}},16:{start:{line:34,column:0},end:{line:34,column:19}}},fnMap:{0:{name:"enabled",decl:{start:{line:2,column:9},end:{line:2,column:16}},loc:{start:{line:2,column:19},end:{line:10,column:1}},line:2},1:{name:"genErr",decl:{start:{line:11,column:9},end:{line:11,column:15}},loc:{start:{line:11,column:18},end:{line:13,column:1}},line:11},2:{name:"set",decl:{start:{line:14,column:9},end:{line:14,column:12}},loc:{start:{line:14,column:36},end:{line:20,column:1}},line:14},3:{name:"get",decl:{start:{line:21,column:9},end:{line:21,column:12}},loc:{start:{line:21,column:29},end:{line:28,column:1}},line:21}},branchMap:{0:{loc:{start:{line:5,column:2},end:{line:9,column:3}},type:"if",locations:[{start:{line:5,column:2},end:{line:9,column:3}},{start:{line:7,column:9},end:{line:9,column:3}}],line:5},1:{loc:{start:{line:15,column:2},end:{line:17,column:3}},type:"if",locations:[{start:{line:15,column:2},end:{line:17,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:15},2:{loc:{start:{line:18,column:26},end:{line:18,column:53}},type:"binary-expr",locations:[{start:{line:18,column:26},end:{line:18,column:47}},{start:{line:18,column:51},end:{line:18,column:53}}],line:18},3:{loc:{start:{line:22,column:2},end:{line:24,column:3}},type:"if",locations:[{start:{line:22,column:2},end:{line:24,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:22},4:{loc:{start:{line:25,column:2},end:{line:27,column:3}},type:"if",locations:[{start:{line:25,column:2},end:{line:27,column:3}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:25}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0},f:{0:0,1:0,2:0,3:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/libs/debug.ts"],names:[],mappings:"AAMA,MAAM,aAAyB,CAAC;AAEhC,SAAS,UAAU;AACjB,QAAM,KAAK,IAAI,IAAI,OAAO,SAAS,IAAI,EAAE;AACzC,QAAM,UAAU,GAAG,IAAI,OAAO;AAC9B,MAAG,SAAS;AACV,WAAO,CAAC,CAAC,QAAQ,MAAM,aAAa;AAAA,EACtC,OACK;AACH,WAAO;AAAA,EACT;AACF;AAEA,SAAS,SAAS;AAChB,SAAO,IAAI,MAAM,sEAAsE;AACzF;AAEA,SAAS,IAAI,WAA6B,KAAa,OAAY;AACjE,MAAG,CAAC,QAAQ,GAAG;AACb,UAAM,OAAO;AAAA,EACf;AACA,aAAW,SAAS,IAAI,WAAW,SAAS,KAAK,CAAC;AAClD,aAAW,SAAS,EAAE,GAAG,IAAI;AAC/B;AAEA,SAAS,IAAI,WAA6B,KAAa;AACrD,MAAG,CAAC,QAAQ,GAAG;AACb,UAAM,OAAO;AAAA,EACf;AACA,MAAG,OAAO,UAAU,eAAe,KAAK,YAAY,SAAS,GAAG;AAC9D,WAAO,WAAW,SAAS,EAAE,GAAG;AAAA,EAClC;AACF;AAEA,MAAM,MAAM;AAAA,EACV;AAAA,EACA;AAAA,EACA;AACF;AAEC,OAAe,QAAQ;AACxB,eAAe;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"f3fc52390a8e0125df8ac2b3d3c29ba103bd1c39"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return $o=function(){return s},s}$o();const GC=($o().s[0]++,{});function ak(){$o().f[0]++;const e=($o().s[1]++,new URL(window.location.href).searchParams),n=($o().s[2]++,e.get("debug"));return $o().s[3]++,n?($o().b[0][0]++,$o().s[4]++,!!n.match(/^(|1|true)$/)):($o().b[0][1]++,$o().s[5]++,!1)}function RG(){return $o().f[1]++,$o().s[6]++,new Error("Debug not enabled, enable by appending '?debug' to your query string")}function y8e(e,n,t){if($o().f[2]++,$o().s[7]++,ak())$o().b[1][1]++;else throw $o().b[1][0]++,$o().s[8]++,RG();$o().s[9]++,GC[e]=($o().b[2][0]++,GC[e]||($o().b[2][1]++,{})),$o().s[10]++,GC[e][n]=t}function v8e(e,n){if($o().f[3]++,$o().s[11]++,ak())$o().b[3][1]++;else throw $o().b[3][0]++,$o().s[12]++,RG();if($o().s[13]++,Object.prototype.hasOwnProperty.call(GC,e))return $o().b[4][0]++,$o().s[14]++,GC[e][n];$o().b[4][1]++}const B0=($o().s[15]++,{enabled:ak,get:v8e,set:y8e});$o().s[16]++;window.debug=B0;function re(){var e="/home/runner/work/maputnik/maputnik/src/components/App.tsx",n="89c068ca942382ab4384d9496905567c46b1fd10",t=globalThis,r="__coverage__",i={path:"/home/runner/work/maputnik/maputnik/src/components/App.tsx",statementMap:{0:{start:{line:37,column:0},end:{line:37,column:30}},1:{start:{line:39,column:29},end:{line:39,column:60}},2:{start:{line:40,column:26},end:{line:40,column:54}},3:{start:{line:41,column:31},end:{line:41,column:64}},4:{start:{line:42,column:2},end:{line:54,column:3}},5:{start:{line:43,column:24},end:{line:43,column:95}},6:{start:{line:44,column:4},end:{line:46,column:5}},7:{start:{line:45,column:6},end:{line:45,column:47}},8:{start:{line:47,column:9},end:{line:54,column:3}},9:{start:{line:48,column:24},end:{line:48,column:96}},10:{start:{line:49,column:4},end:{line:51,column:5}},11:{start:{line:50,column:6},end:{line:50,column:47}},12:{start:{line:53,column:4},end:{line:53,column:15}},13:{start:{line:57,column:2},end:{line:66,column:4}},14:{start:{line:72,column:15},end:{line:72,column:19}},15:{start:{line:74,column:4},end:{line:74,column:17}},16:{start:{line:75,column:4},end:{line:75,column:19}},17:{start:{line:76,column:4},end:{line:76,column:45}},18:{start:{line:77,column:19},end:{line:77,column:75}},19:{start:{line:78,column:15},end:{line:78,column:38}},20:{start:{line:79,column:4},end:{line:81,column:5}},21:{start:{line:80,column:6},end:{line:80,column:34}},22:{start:{line:82,column:4},end:{line:86,column:7}},23:{start:{line:83,column:40},end:{line:83,column:86}},24:{start:{line:87,column:22},end:{line:138,column:5}},25:{start:{line:91,column:10},end:{line:91,column:40}},26:{start:{line:97,column:10},end:{line:97,column:35}},27:{start:{line:103,column:10},end:{line:103,column:37}},28:{start:{line:109,column:10},end:{line:109,column:38}},29:{start:{line:115,column:10},end:{line:115,column:39}},30:{start:{line:121,column:10},end:{line:123,column:12}},31:{start:{line:129,column:10},end:{line:129,column:63}},32:{start:{line:135,column:10},end:{line:135,column:36}},33:{start:{line:139,column:4},end:{line:152,column:7}},34:{start:{line:140,column:6},end:{line:151,column:7}},35:{start:{line:141,column:8},end:{line:141,column:24}},36:{start:{line:142,column:8},end:{line:142,column:30}},37:{start:{line:143,column:13},end:{line:151,column:7}},38:{start:{line:144,column:25},end:{line:146,column:10}},39:{start:{line:145,column:10},end:{line:145,column:41}},40:{start:{line:147,column:8},end:{line:150,column:9}},41:{start:{line:148,column:10},end:{line:148,column:44}},42:{start:{line:149,column:10},end:{line:149,column:29}},43:{start:{line:153,column:21},end:{line:153,column:38}},44:{start:{line:154,column:4},end:{line:173,column:5}},45:{start:{line:155,column:6},end:{line:155,column:41}},46:{start:{line:156,column:6},end:{line:156,column:74}},47:{start:{line:156,column:43},end:{line:156,column:72}},48:{start:{line:157,column:6},end:{line:157,column:31}},49:{start:{line:159,column:6},end:{line:161,column:7}},50:{start:{line:160,column:8},end:{line:160,column:33}},51:{start:{line:162,column:6},end:{line:172,column:9}},52:{start:{line:163,column:8},end:{line:166,column:9}},53:{start:{line:164,column:10},end:{line:164,column:74}},54:{start:{line:165,column:10},end:{line:165,column:45}},55:{start:{line:167,column:8},end:{line:167,column:104}},56:{start:{line:167,column:50},end:{line:167,column:102}},57:{start:{line:168,column:8},end:{line:171,column:9}},58:{start:{line:169,column:10},end:{line:169,column:63}},59:{start:{line:170,column:10},end:{line:170,column:69}},60:{start:{line:174,column:4},end:{line:177,column:5}},61:{start:{line:175,column:6},end:{line:175,column:65}},62:{start:{line:176,column:6},end:{line:176,column:59}},63:{start:{line:178,column:4},end:{line:212,column:6}},64:{start:{line:213,column:4},end:{line:215,column:7}},65:{start:{line:214,column:35},end:{line:214,column:69}},66:{start:{line:217,column:19},end:{line:235,column:3}},67:{start:{line:218,column:4},end:{line:234,column:5}},68:{start:{line:219,column:6},end:{line:225,column:7}},69:{start:{line:220,column:8},end:{line:220,column:27}},70:{start:{line:221,column:8},end:{line:221,column:22}},71:{start:{line:222,column:13},end:{line:225,column:7}},72:{start:{line:223,column:8},end:{line:223,column:27}},73:{start:{line:224,column:8},end:{line:224,column:22}},74:{start:{line:227,column:6},end:{line:233,column:7}},75:{start:{line:228,column:8},end:{line:228,column:27}},76:{start:{line:229,column:8},end:{line:229,column:22}},77:{start:{line:230,column:13},end:{line:233,column:7}},78:{start:{line:231,column:8},end:{line:231,column:27}},79:{start:{line:232,column:8},end:{line:232,column:22}},80:{start:{line:237,column:4},end:{line:237,column:60}},81:{start:{line:240,column:4},end:{line:240,column:63}},82:{start:{line:243,column:4},end:{line:243,column:40}},83:{start:{line:246,column:21},end:{line:246,column:55}},84:{start:{line:247,column:24},end:{line:247,column:93}},85:{start:{line:248,column:21},end:{line:248,column:110}},86:{start:{line:249,column:4},end:{line:251,column:7}},87:{start:{line:250,column:6},end:{line:250,column:80}},88:{start:{line:254,column:4},end:{line:256,column:7}},89:{start:{line:255,column:6},end:{line:255,column:80}},90:{start:{line:258,column:29},end:{line:272,column:3}},91:{start:{line:259,column:4},end:{line:263,column:5}},92:{start:{line:260,column:6},end:{line:262,column:9}},93:{start:{line:264,column:25},end:{line:270,column:5}},94:{start:{line:271,column:4},end:{line:271,column:38}},95:{start:{line:273,column:19},end:{line:385,column:3}},96:{start:{line:274,column:4},end:{line:279,column:6}},97:{start:{line:280,column:4},end:{line:282,column:5}},98:{start:{line:281,column:6},end:{line:281,column:44}},99:{start:{line:283,column:19},end:{line:283,column:51}},100:{start:{line:284,column:24},end:{line:284,column:26}},101:{start:{line:285,column:4},end:{line:296,column:5}},102:{start:{line:286,column:26},end:{line:286,column:42}},103:{start:{line:287,column:6},end:{line:295,column:9}},104:{start:{line:288,column:8},end:{line:293,column:9}},105:{start:{line:289,column:24},end:{line:291,column:11}},106:{start:{line:292,column:10},end:{line:292,column:34}},107:{start:{line:294,column:8},end:{line:294,column:40}},108:{start:{line:297,column:25},end:{line:348,column:6}},109:{start:{line:298,column:23},end:{line:298,column:109}},110:{start:{line:299,column:6},end:{line:312,column:7}},111:{start:{line:300,column:35},end:{line:300,column:43}},112:{start:{line:301,column:8},end:{line:311,column:10}},113:{start:{line:313,column:33},end:{line:313,column:100}},114:{start:{line:314,column:6},end:{line:327,column:7}},115:{start:{line:315,column:35},end:{line:315,column:53}},116:{start:{line:316,column:8},end:{line:326,column:10}},117:{start:{line:328,column:25},end:{line:328,column:88}},118:{start:{line:329,column:6},end:{line:347,column:7}},119:{start:{line:330,column:52},end:{line:330,column:62}},120:{start:{line:331,column:20},end:{line:331,column:78}},121:{start:{line:332,column:8},end:{line:342,column:10}},122:{start:{line:344,column:8},end:{line:346,column:10}},123:{start:{line:349,column:24},end:{line:349,column:30}},124:{start:{line:350,column:4},end:{line:364,column:5}},125:{start:{line:351,column:6},end:{line:351,column:42}},126:{start:{line:352,column:6},end:{line:363,column:9}},127:{start:{line:353,column:28},end:{line:353,column:33}},128:{start:{line:354,column:8},end:{line:362,column:9}},129:{start:{line:355,column:10},end:{line:361,column:11}},130:{start:{line:356,column:28},end:{line:356,column:49}},131:{start:{line:357,column:30},end:{line:357,column:69}},132:{start:{line:358,column:12},end:{line:358,column:44}},133:{start:{line:360,column:12},end:{line:360,column:30}},134:{start:{line:365,column:4},end:{line:367,column:5}},135:{start:{line:366,column:6},end:{line:366,column:40}},136:{start:{line:368,column:4},end:{line:370,column:5}},137:{start:{line:369,column:6},end:{line:369,column:40}},138:{start:{line:371,column:4},end:{line:373,column:5}},139:{start:{line:372,column:6},end:{line:372,column:47}},140:{start:{line:374,column:4},end:{line:376,column:5}},141:{start:{line:375,column:6},end:{line:375,column:31}},142:{start:{line:377,column:4},end:{line:384,column:7}},143:{start:{line:382,column:6},end:{line:382,column:26}},144:{start:{line:383,column:6},end:{line:383,column:27}},145:{start:{line:386,column:11},end:{line:393,column:3}},146:{start:{line:387,column:24},end:{line:387,column:49}},147:{start:{line:388,column:21},end:{line:388,column:67}},148:{start:{line:389,column:4},end:{line:389,column:61}},149:{start:{line:390,column:4},end:{line:392,column:7}},150:{start:{line:394,column:11},end:{line:401,column:3}},151:{start:{line:395,column:24},end:{line:395,column:49}},152:{start:{line:396,column:21},end:{line:396,column:67}},153:{start:{line:397,column:4},end:{line:397,column:61}},154:{start:{line:398,column:4},end:{line:400,column:7}},155:{start:{line:402,column:16},end:{line:417,column:3}},156:{start:{line:403,column:33},end:{line:403,column:37}},157:{start:{line:404,column:17},end:{line:404,column:43}},158:{start:{line:405,column:4},end:{line:405,column:53}},159:{start:{line:406,column:4},end:{line:406,column:53}},160:{start:{line:407,column:4},end:{line:408,column:13}},161:{start:{line:408,column:6},end:{line:408,column:13}},162:{start:{line:409,column:4},end:{line:413,column:5}},163:{start:{line:410,column:6},end:{line:412,column:9}},164:{start:{line:414,column:4},end:{line:414,column:29}},165:{start:{line:415,column:4},end:{line:415,column:49}},166:{start:{line:416,column:4},end:{line:416,column:32}},167:{start:{line:418,column:19},end:{line:424,column:3}},168:{start:{line:419,column:25},end:{line:422,column:5}},169:{start:{line:423,column:4},end:{line:423,column:38}},170:{start:{line:425,column:19},end:{line:430,column:3}},171:{start:{line:426,column:19},end:{line:426,column:45}},172:{start:{line:427,column:28},end:{line:427,column:43}},173:{start:{line:428,column:4},end:{line:428,column:37}},174:{start:{line:429,column:4},end:{line:429,column:41}},175:{start:{line:431,column:16},end:{line:438,column:3}},176:{start:{line:432,column:19},end:{line:432,column:45}},177:{start:{line:433,column:26},end:{line:433,column:41}},178:{start:{line:434,column:24},end:{line:434,column:55}},179:{start:{line:435,column:4},end:{line:435,column:46}},180:{start:{line:436,column:4},end:{line:436,column:48}},181:{start:{line:437,column:4},end:{line:437,column:39}},182:{start:{line:439,column:28},end:{line:448,column:3}},183:{start:{line:440,column:19},end:{line:440,column:45}},184:{start:{line:441,column:26},end:{line:441,column:41}},185:{start:{line:442,column:18},end:{line:442,column:45}},186:{start:{line:443,column:26},end:{line:443,column:70}},187:{start:{line:444,column:4},end:{line:444,column:88}},188:{start:{line:445,column:4},end:{line:445,column:33}},189:{start:{line:446,column:4},end:{line:446,column:33}},190:{start:{line:447,column:4},end:{line:447,column:39}},191:{start:{line:449,column:20},end:{line:456,column:3}},192:{start:{line:450,column:26},end:{line:450,column:61}},193:{start:{line:451,column:4},end:{line:454,column:6}},194:{start:{line:455,column:4},end:{line:455,column:39}},195:{start:{line:457,column:19},end:{line:461,column:3}},196:{start:{line:458,column:26},end:{line:458,column:61}},197:{start:{line:459,column:4},end:{line:459,column:33}},198:{start:{line:460,column:4},end:{line:460,column:39}},199:{start:{line:462,column:16},end:{line:466,column:3}},200:{start:{line:463,column:4},end:{line:465,column:27}},201:{start:{line:467,column:21},end:{line:481,column:3}},202:{start:{line:468,column:21},end:{line:468,column:44}},203:{start:{line:469,column:4},end:{line:480,column:5}},204:{start:{line:470,column:27},end:{line:476,column:7}},205:{start:{line:477,column:6},end:{line:477,column:26}},206:{start:{line:479,column:6},end:{line:479,column:22}},207:{start:{line:482,column:14},end:{line:485,column:3}},208:{start:{line:483,column:4},end:{line:483,column:47}},209:{start:{line:484,column:4},end:{line:484,column:34}},210:{start:{line:487,column:23},end:{line:487,column:25}},211:{start:{line:488,column:4},end:{line:522,column:5}},212:{start:{line:489,column:6},end:{line:521,column:7}},213:{start:{line:490,column:8},end:{line:493,column:10}},214:{start:{line:494,column:18},end:{line:494,column:25}},215:{start:{line:495,column:8},end:{line:499,column:9}},216:{start:{line:496,column:10},end:{line:496,column:62}},217:{start:{line:498,column:10},end:{line:498,column:63}},218:{start:{line:500,column:8},end:{line:518,column:11}},219:{start:{line:502,column:30},end:{line:502,column:45}},220:{start:{line:503,column:10},end:{line:505,column:11}},221:{start:{line:504,column:12},end:{line:504,column:19}},222:{start:{line:506,column:26},end:{line:508,column:12}},223:{start:{line:509,column:10},end:{line:511,column:11}},224:{start:{line:510,column:12},end:{line:510,column:47}},225:{start:{line:512,column:10},end:{line:512,column:51}},226:{start:{line:513,column:10},end:{line:515,column:13}},227:{start:{line:517,column:10},end:{line:517,column:72}},228:{start:{line:520,column:8},end:{line:520,column:86}},229:{start:{line:523,column:4},end:{line:528,column:5}},230:{start:{line:524,column:6},end:{line:524,column:39}},231:{start:{line:525,column:6},end:{line:527,column:9}},232:{start:{line:531,column:21},end:{line:531,column:55}},233:{start:{line:532,column:4},end:{line:532,column:53}},234:{start:{line:534,column:16},end:{line:538,column:3}},235:{start:{line:535,column:4},end:{line:537,column:7}},236:{start:{line:540,column:40},end:{line:540,column:50}},237:{start:{line:541,column:21},end:{line:552,column:5}},238:{start:{line:544,column:8},end:{line:546,column:11}},239:{start:{line:549,column:8},end:{line:549,column:44}},240:{start:{line:550,column:8},end:{line:550,column:28}},241:{start:{line:553,column:21},end:{line:553,column:40}},242:{start:{line:555,column:4},end:{line:577,column:5}},243:{start:{line:556,column:6},end:{line:564,column:8}},244:{start:{line:566,column:6},end:{line:576,column:8}},245:{start:{line:579,column:4},end:{line:581,column:5}},246:{start:{line:580,column:6},end:{line:580,column:63}},247:{start:{line:582,column:25},end:{line:582,column:27}},248:{start:{line:583,column:4},end:{line:585,column:5}},249:{start:{line:584,column:6},end:{line:584,column:52}},250:{start:{line:586,column:4},end:{line:586,column:160}},251:{start:{line:588,column:18},end:{line:606,column:3}},252:{start:{line:589,column:43},end:{line:589,column:53}},253:{start:{line:590,column:35},end:{line:590,column:45}},254:{start:{line:591,column:16},end:{line:591,column:38}},255:{start:{line:592,column:20},end:{line:592,column:50}},256:{start:{line:593,column:4},end:{line:593,column:70}},257:{start:{line:594,column:23},end:{line:594,column:122}},258:{start:{line:594,column:66},end:{line:594,column:91}},259:{start:{line:594,column:109},end:{line:594,column:121}},260:{start:{line:595,column:4},end:{line:599,column:5}},261:{start:{line:596,column:6},end:{line:596,column:58}},262:{start:{line:598,column:6},end:{line:598,column:39}},263:{start:{line:600,column:4},end:{line:604,column:5}},264:{start:{line:601,column:6},end:{line:601,column:38}},265:{start:{line:602,column:11},end:{line:604,column:5}},266:{start:{line:603,column:6},end:{line:603,column:46}},267:{start:{line:605,column:4},end:{line:605,column:71}},268:{start:{line:607,column:27},end:{line:652,column:3}},269:{start:{line:608,column:16},end:{line:608,column:38}},270:{start:{line:609,column:23},end:{line:609,column:52}},271:{start:{line:610,column:4},end:{line:622,column:5}},272:{start:{line:611,column:21},end:{line:611,column:42}},273:{start:{line:612,column:23},end:{line:612,column:25}},274:{start:{line:613,column:6},end:{line:615,column:9}},275:{start:{line:614,column:8},end:{line:614,column:35}},276:{start:{line:616,column:6},end:{line:621,column:9}},277:{start:{line:623,column:17},end:{line:623,column:45}},278:{start:{line:624,column:4},end:{line:626,column:5}},279:{start:{line:625,column:6},end:{line:625,column:29}},280:{start:{line:627,column:17},end:{line:627,column:46}},281:{start:{line:628,column:4},end:{line:651,column:5}},282:{start:{line:629,column:6},end:{line:650,column:7}},283:{start:{line:630,column:22},end:{line:630,column:37}},284:{start:{line:631,column:46},end:{line:634,column:9}},285:{start:{line:635,column:20},end:{line:635,column:24}},286:{start:{line:636,column:8},end:{line:641,column:9}},287:{start:{line:637,column:33},end:{line:637,column:63}},288:{start:{line:638,column:10},end:{line:640,column:11}},289:{start:{line:639,column:12},end:{line:639,column:26}},290:{start:{line:642,column:8},end:{line:647,column:9}},291:{start:{line:643,column:10},end:{line:646,column:13}},292:{start:{line:649,column:8},end:{line:649,column:26}},293:{start:{line:653,column:18},end:{line:658,column:3}},294:{start:{line:654,column:4},end:{line:657,column:27}},295:{start:{line:660,column:4},end:{line:662,column:5}},296:{start:{line:661,column:6},end:{line:661,column:41}},297:{start:{line:663,column:4},end:{line:668,column:27}},298:{start:{line:671,column:4},end:{line:671,column:60}},299:{start:{line:673,column:28},end:{line:680,column:3}},300:{start:{line:674,column:4},end:{line:679,column:7}},301:{start:{line:681,column:28},end:{line:688,column:3}},302:{start:{line:682,column:4},end:{line:687,column:7}},303:{start:{line:690,column:19},end:{line:690,column:51}},304:{start:{line:691,column:26},end:{line:691,column:92}},305:{start:{line:692,column:36},end:{line:705,column:5}},306:{start:{line:706,column:38},end:{line:720,column:5}},307:{start:{line:721,column:24},end:{line:740,column:14}},308:{start:{line:741,column:24},end:{line:751,column:14}},309:{start:{line:752,column:35},end:{line:817,column:8}},310:{start:{line:769,column:23},end:{line:769,column:43}},311:{start:{line:818,column:4},end:{line:828,column:6}}},fnMap:{0:{name:"setFetchAccessToken",decl:{start:{line:38,column:9},end:{line:38,column:28}},loc:{start:{line:38,column:44},end:{line:55,column:1}},line:38},1:{name:"updateRootSpec",decl:{start:{line:56,column:9},end:{line:56,column:23}},loc:{start:{line:56,column:52},end:{line:67,column:1}},line:56},2:{name:"(anonymous_2)",decl:{start:{line:73,column:2},end:{line:73,column:3}},loc:{start:{line:73,column:21},end:{line:216,column:3}},line:73},3:{name:"(anonymous_3)",decl:{start:{line:83,column:26},end:{line:83,column:27}},loc:{start:{line:83,column:40},end:{line:83,column:86}},line:83},4:{name:"(anonymous_4)",decl:{start:{line:90,column:17},end:{line:90,column:18}},loc:{start:{line:90,column:23},end:{line:92,column:9}},line:90},5:{name:"(anonymous_5)",decl:{start:{line:96,column:17},end:{line:96,column:18}},loc:{start:{line:96,column:23},end:{line:98,column:9}},line:96},6:{name:"(anonymous_6)",decl:{start:{line:102,column:17},end:{line:102,column:18}},loc:{start:{line:102,column:23},end:{line:104,column:9}},line:102},7:{name:"(anonymous_7)",decl:{start:{line:108,column:17},end:{line:108,column:18}},loc:{start:{line:108,column:23},end:{line:110,column:9}},line:108},8:{name:"(anonymous_8)",decl:{start:{line:114,column:17},end:{line:114,column:18}},loc:{start:{line:114,column:23},end:{line:116,column:9}},line:114},9:{name:"(anonymous_9)",decl:{start:{line:120,column:17},end:{line:120,column:18}},loc:{start:{line:120,column:23},end:{line:124,column:9}},line:120},10:{name:"(anonymous_10)",decl:{start:{line:128,column:17},end:{line:128,column:18}},loc:{start:{line:128,column:23},end:{line:130,column:9}},line:128},11:{name:"(anonymous_11)",decl:{start:{line:134,column:17},end:{line:134,column:18}},loc:{start:{line:134,column:23},end:{line:136,column:9}},line:134},12:{name:"(anonymous_12)",decl:{start:{line:139,column:44},end:{line:139,column:45}},loc:{start:{line:139,column:51},end:{line:152,column:5}},line:139},13:{name:"(anonymous_13)",decl:{start:{line:144,column:40},end:{line:144,column:41}},loc:{start:{line:144,column:55},end:{line:146,column:9}},line:144},14:{name:"(anonymous_14)",decl:{start:{line:156,column:29},end:{line:156,column:30}},loc:{start:{line:156,column:43},end:{line:156,column:72}},line:156},15:{name:"(anonymous_15)",decl:{start:{line:162,column:27},end:{line:162,column:28}},loc:{start:{line:162,column:36},end:{line:172,column:7}},line:162},16:{name:"(anonymous_16)",decl:{start:{line:167,column:36},end:{line:167,column:37}},loc:{start:{line:167,column:50},end:{line:167,column:102}},line:167},17:{name:"(anonymous_17)",decl:{start:{line:214,column:28},end:{line:214,column:29}},loc:{start:{line:214,column:35},end:{line:214,column:69}},line:214},18:{name:"(anonymous_18)",decl:{start:{line:217,column:19},end:{line:217,column:20}},loc:{start:{line:217,column:26},end:{line:235,column:3}},line:217},19:{name:"(anonymous_19)",decl:{start:{line:236,column:2},end:{line:236,column:3}},loc:{start:{line:236,column:22},end:{line:238,column:3}},line:236},20:{name:"(anonymous_20)",decl:{start:{line:239,column:2},end:{line:239,column:3}},loc:{start:{line:239,column:25},end:{line:241,column:3}},line:239},21:{name:"(anonymous_21)",decl:{start:{line:242,column:2},end:{line:242,column:3}},loc:{start:{line:242,column:27},end:{line:244,column:3}},line:242},22:{name:"(anonymous_22)",decl:{start:{line:245,column:2},end:{line:245,column:3}},loc:{start:{line:245,column:27},end:{line:252,column:3}},line:245},23:{name:"(anonymous_23)",decl:{start:{line:249,column:37},end:{line:249,column:38}},loc:{start:{line:249,column:48},end:{line:251,column:5}},line:249},24:{name:"(anonymous_24)",decl:{start:{line:253,column:2},end:{line:253,column:3}},loc:{start:{line:253,column:23},end:{line:257,column:3}},line:253},25:{name:"(anonymous_25)",decl:{start:{line:254,column:36},end:{line:254,column:37}},loc:{start:{line:254,column:47},end:{line:256,column:5}},line:254},26:{name:"(anonymous_26)",decl:{start:{line:258,column:29},end:{line:258,column:30}},loc:{start:{line:258,column:50},end:{line:272,column:3}},line:258},27:{name:"(anonymous_27)",decl:{start:{line:273,column:19},end:{line:273,column:20}},loc:{start:{line:273,column:44},end:{line:385,column:3}},line:273},28:{name:"(anonymous_28)",decl:{start:{line:287,column:30},end:{line:287,column:31}},loc:{start:{line:287,column:48},end:{line:295,column:7}},line:287},29:{name:"(anonymous_29)",decl:{start:{line:297,column:56},end:{line:297,column:57}},loc:{start:{line:297,column:67},end:{line:348,column:5}},line:297},30:{name:"(anonymous_30)",decl:{start:{line:352,column:21},end:{line:352,column:22}},loc:{start:{line:352,column:32},end:{line:363,column:7}},line:352},31:{name:"(anonymous_31)",decl:{start:{line:381,column:7},end:{line:381,column:8}},loc:{start:{line:381,column:13},end:{line:384,column:5}},line:381},32:{name:"(anonymous_32)",decl:{start:{line:386,column:11},end:{line:386,column:12}},loc:{start:{line:386,column:17},end:{line:393,column:3}},line:386},33:{name:"(anonymous_33)",decl:{start:{line:394,column:11},end:{line:394,column:12}},loc:{start:{line:394,column:17},end:{line:401,column:3}},line:394},34:{name:"(anonymous_34)",decl:{start:{line:402,column:16},end:{line:402,column:17}},loc:{start:{line:402,column:26},end:{line:417,column:3}},line:402},35:{name:"(anonymous_35)",decl:{start:{line:418,column:19},end:{line:418,column:20}},loc:{start:{line:418,column:38},end:{line:424,column:3}},line:418},36:{name:"(anonymous_36)",decl:{start:{line:425,column:19},end:{line:425,column:20}},loc:{start:{line:425,column:30},end:{line:430,column:3}},line:425},37:{name:"(anonymous_37)",decl:{start:{line:431,column:16},end:{line:431,column:17}},loc:{start:{line:431,column:27},end:{line:438,column:3}},line:431},38:{name:"(anonymous_38)",decl:{start:{line:439,column:28},end:{line:439,column:29}},loc:{start:{line:439,column:39},end:{line:448,column:3}},line:439},39:{name:"(anonymous_39)",decl:{start:{line:449,column:20},end:{line:449,column:21}},loc:{start:{line:449,column:46},end:{line:456,column:3}},line:449},40:{name:"(anonymous_40)",decl:{start:{line:457,column:19},end:{line:457,column:20}},loc:{start:{line:457,column:37},end:{line:461,column:3}},line:457},41:{name:"(anonymous_41)",decl:{start:{line:462,column:16},end:{line:462,column:17}},loc:{start:{line:462,column:30},end:{line:466,column:3}},line:462},42:{name:"(anonymous_42)",decl:{start:{line:467,column:21},end:{line:467,column:22}},loc:{start:{line:467,column:35},end:{line:481,column:3}},line:467},43:{name:"(anonymous_43)",decl:{start:{line:482,column:14},end:{line:482,column:15}},loc:{start:{line:482,column:28},end:{line:485,column:3}},line:482},44:{name:"(anonymous_44)",decl:{start:{line:486,column:2},end:{line:486,column:3}},loc:{start:{line:486,column:17},end:{line:529,column:3}},line:486},45:{name:"(anonymous_45)",decl:{start:{line:502,column:16},end:{line:502,column:17}},loc:{start:{line:502,column:30},end:{line:502,column:45}},line:502},46:{name:"(anonymous_46)",decl:{start:{line:502,column:52},end:{line:502,column:53}},loc:{start:{line:502,column:62},end:{line:516,column:9}},line:502},47:{name:"(anonymous_47)",decl:{start:{line:516,column:17},end:{line:516,column:18}},loc:{start:{line:516,column:26},end:{line:518,column:9}},line:516},48:{name:"(anonymous_48)",decl:{start:{line:530,column:2},end:{line:530,column:3}},loc:{start:{line:530,column:17},end:{line:533,column:3}},line:530},49:{name:"(anonymous_49)",decl:{start:{line:534,column:16},end:{line:534,column:17}},loc:{start:{line:534,column:29},end:{line:538,column:3}},line:534},50:{name:"(anonymous_50)",decl:{start:{line:539,column:2},end:{line:539,column:3}},loc:{start:{line:539,column:16},end:{line:587,column:3}},line:539},51:{name:"(anonymous_51)",decl:{start:{line:543,column:27},end:{line:543,column:28}},loc:{start:{line:543,column:42},end:{line:547,column:7}},line:543},52:{name:"(anonymous_52)",decl:{start:{line:548,column:20},end:{line:548,column:21}},loc:{start:{line:548,column:27},end:{line:551,column:7}},line:548},53:{name:"(anonymous_53)",decl:{start:{line:588,column:18},end:{line:588,column:19}},loc:{start:{line:588,column:24},end:{line:606,column:3}},line:588},54:{name:"(anonymous_54)",decl:{start:{line:594,column:50},end:{line:594,column:51}},loc:{start:{line:594,column:66},end:{line:594,column:91}},line:594},55:{name:"(anonymous_55)",decl:{start:{line:594,column:100},end:{line:594,column:101}},loc:{start:{line:594,column:109},end:{line:594,column:121}},line:594},56:{name:"(anonymous_56)",decl:{start:{line:607,column:27},end:{line:607,column:28}},loc:{start:{line:607,column:41},end:{line:652,column:3}},line:607},57:{name:"(anonymous_57)",decl:{start:{line:613,column:21},end:{line:613,column:22}},loc:{start:{line:613,column:36},end:{line:615,column:7}},line:613},58:{name:"(anonymous_58)",decl:{start:{line:653,column:18},end:{line:653,column:19}},loc:{start:{line:653,column:29},end:{line:658,column:3}},line:653},59:{name:"(anonymous_59)",decl:{start:{line:659,column:2},end:{line:659,column:3}},loc:{start:{line:659,column:29},end:{line:669,column:3}},line:659},60:{name:"(anonymous_60)",decl:{start:{line:670,column:2},end:{line:670,column:3}},loc:{start:{line:670,column:25},end:{line:672,column:3}},line:670},61:{name:"(anonymous_61)",decl:{start:{line:673,column:28},end:{line:673,column:29}},loc:{start:{line:673,column:44},end:{line:680,column:3}},line:673},62:{name:"(anonymous_62)",decl:{start:{line:681,column:28},end:{line:681,column:29}},loc:{start:{line:681,column:44},end:{line:688,column:3}},line:681},63:{name:"(anonymous_63)",decl:{start:{line:689,column:2},end:{line:689,column:3}},loc:{start:{line:689,column:11},end:{line:829,column:3}},line:689},64:{name:"(anonymous_64)",decl:{start:{line:769,column:15},end:{line:769,column:16}},loc:{start:{line:769,column:23},end:{line:769,column:43}},line:769}},branchMap:{0:{loc:{start:{line:42,column:2},end:{line:54,column:3}},type:"if",locations:[{start:{line:42,column:2},end:{line:54,column:3}},{start:{line:47,column:9},end:{line:54,column:3}}],line:42},1:{loc:{start:{line:42,column:6},end:{line:42,column:43}},type:"binary-expr",locations:[{start:{line:42,column:6},end:{line:42,column:24}},{start:{line:42,column:28},end:{line:42,column:43}}],line:42},2:{loc:{start:{line:44,column:4},end:{line:46,column:5}},type:"if",locations:[{start:{line:44,column:4},end:{line:46,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:44},3:{loc:{start:{line:47,column:9},end:{line:54,column:3}},type:"if",locations:[{start:{line:47,column:9},end:{line:54,column:3}},{start:{line:52,column:9},end:{line:54,column:3}}],line:47},4:{loc:{start:{line:49,column:4},end:{line:51,column:5}},type:"if",locations:[{start:{line:49,column:4},end:{line:51,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:49},5:{loc:{start:{line:79,column:4},end:{line:81,column:5}},type:"if",locations:[{start:{line:79,column:4},end:{line:81,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:79},6:{loc:{start:{line:79,column:8},end:{line:79,column:89}},type:"binary-expr",locations:[{start:{line:79,column:8},end:{line:79,column:20}},{start:{line:79,column:25},end:{line:79,column:54}},{start:{line:79,column:58},end:{line:79,column:88}}],line:79},7:{loc:{start:{line:122,column:12},end:{line:122,column:61}},type:"cond-expr",locations:[{start:{line:122,column:44},end:{line:122,column:53}},{start:{line:122,column:56},end:{line:122,column:61}}],line:122},8:{loc:{start:{line:140,column:6},end:{line:151,column:7}},type:"if",locations:[{start:{line:140,column:6},end:{line:151,column:7}},{start:{line:143,column:13},end:{line:151,column:7}}],line:140},9:{loc:{start:{line:143,column:13},end:{line:151,column:7}},type:"if",locations:[{start:{line:143,column:13},end:{line:151,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:143},10:{loc:{start:{line:143,column:17},end:{line:143,column:88}},type:"binary-expr",locations:[{start:{line:143,column:17},end:{line:143,column:44}},{start:{line:143,column:48},end:{line:143,column:88}}],line:143},11:{loc:{start:{line:147,column:8},end:{line:150,column:9}},type:"if",locations:[{start:{line:147,column:8},end:{line:150,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:147},12:{loc:{start:{line:154,column:4},end:{line:173,column:5}},type:"if",locations:[{start:{line:154,column:4},end:{line:173,column:5}},{start:{line:158,column:11},end:{line:173,column:5}}],line:154},13:{loc:{start:{line:154,column:8},end:{line:154,column:104}},type:"binary-expr",locations:[{start:{line:154,column:8},end:{line:154,column:16}},{start:{line:154,column:20},end:{line:154,column:104}}],line:154},14:{loc:{start:{line:159,column:6},end:{line:161,column:7}},type:"if",locations:[{start:{line:159,column:6},end:{line:161,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:159},15:{loc:{start:{line:163,column:8},end:{line:166,column:9}},type:"if",locations:[{start:{line:163,column:8},end:{line:166,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:163},16:{loc:{start:{line:168,column:8},end:{line:171,column:9}},type:"if",locations:[{start:{line:168,column:8},end:{line:171,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:168},17:{loc:{start:{line:174,column:4},end:{line:177,column:5}},type:"if",locations:[{start:{line:174,column:4},end:{line:177,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:174},18:{loc:{start:{line:218,column:4},end:{line:234,column:5}},type:"if",locations:[{start:{line:218,column:4},end:{line:234,column:5}},{start:{line:226,column:11},end:{line:234,column:5}}],line:218},19:{loc:{start:{line:219,column:6},end:{line:225,column:7}},type:"if",locations:[{start:{line:219,column:6},end:{line:225,column:7}},{start:{line:222,column:13},end:{line:225,column:7}}],line:219},20:{loc:{start:{line:219,column:10},end:{line:219,column:53}},type:"binary-expr",locations:[{start:{line:219,column:10},end:{line:219,column:19}},{start:{line:219,column:23},end:{line:219,column:33}},{start:{line:219,column:37},end:{line:219,column:53}}],line:219},21:{loc:{start:{line:222,column:13},end:{line:225,column:7}},type:"if",locations:[{start:{line:222,column:13},end:{line:225,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:222},22:{loc:{start:{line:222,column:17},end:{line:222,column:46}},type:"binary-expr",locations:[{start:{line:222,column:17},end:{line:222,column:26}},{start:{line:222,column:30},end:{line:222,column:46}}],line:222},23:{loc:{start:{line:227,column:6},end:{line:233,column:7}},type:"if",locations:[{start:{line:227,column:6},end:{line:233,column:7}},{start:{line:230,column:13},end:{line:233,column:7}}],line:227},24:{loc:{start:{line:227,column:10},end:{line:227,column:39}},type:"binary-expr",locations:[{start:{line:227,column:10},end:{line:227,column:19}},{start:{line:227,column:23},end:{line:227,column:39}}],line:227},25:{loc:{start:{line:230,column:13},end:{line:233,column:7}},type:"if",locations:[{start:{line:230,column:13},end:{line:233,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:230},26:{loc:{start:{line:230,column:17},end:{line:230,column:46}},type:"binary-expr",locations:[{start:{line:230,column:17},end:{line:230,column:26}},{start:{line:230,column:30},end:{line:230,column:46}}],line:230},27:{loc:{start:{line:246,column:21},end:{line:246,column:55}},type:"binary-expr",locations:[{start:{line:246,column:21},end:{line:246,column:49}},{start:{line:246,column:53},end:{line:246,column:55}}],line:246},28:{loc:{start:{line:247,column:24},end:{line:247,column:93}},type:"binary-expr",locations:[{start:{line:247,column:24},end:{line:247,column:70}},{start:{line:247,column:74},end:{line:247,column:93}}],line:247},29:{loc:{start:{line:248,column:21},end:{line:248,column:110}},type:"cond-expr",locations:[{start:{line:248,column:55},end:{line:248,column:96}},{start:{line:248,column:99},end:{line:248,column:110}}],line:248},30:{loc:{start:{line:259,column:4},end:{line:263,column:5}},type:"if",locations:[{start:{line:259,column:4},end:{line:263,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:259},31:{loc:{start:{line:259,column:8},end:{line:259,column:123}},type:"binary-expr",locations:[{start:{line:259,column:8},end:{line:259,column:40}},{start:{line:259,column:44},end:{line:259,column:123}}],line:259},32:{loc:{start:{line:273,column:30},end:{line:273,column:39}},type:"default-arg",locations:[{start:{line:273,column:37},end:{line:273,column:39}}],line:273},33:{loc:{start:{line:280,column:4},end:{line:282,column:5}},type:"if",locations:[{start:{line:280,column:4},end:{line:282,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:280},34:{loc:{start:{line:283,column:19},end:{line:283,column:51}},type:"binary-expr",locations:[{start:{line:283,column:19},end:{line:283,column:45}},{start:{line:283,column:49},end:{line:283,column:51}}],line:283},35:{loc:{start:{line:285,column:4},end:{line:296,column:5}},type:"if",locations:[{start:{line:285,column:4},end:{line:296,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:285},36:{loc:{start:{line:285,column:8},end:{line:285,column:35}},type:"binary-expr",locations:[{start:{line:285,column:8},end:{line:285,column:16}},{start:{line:285,column:20},end:{line:285,column:35}}],line:285},37:{loc:{start:{line:288,column:8},end:{line:293,column:9}},type:"if",locations:[{start:{line:288,column:8},end:{line:293,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:288},38:{loc:{start:{line:288,column:12},end:{line:288,column:56}},type:"binary-expr",locations:[{start:{line:288,column:12},end:{line:288,column:27}},{start:{line:288,column:31},end:{line:288,column:56}}],line:288},39:{loc:{start:{line:299,column:6},end:{line:312,column:7}},type:"if",locations:[{start:{line:299,column:6},end:{line:312,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:299},40:{loc:{start:{line:314,column:6},end:{line:327,column:7}},type:"if",locations:[{start:{line:314,column:6},end:{line:327,column:7}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:314},41:{loc:{start:{line:329,column:6},end:{line:347,column:7}},type:"if",locations:[{start:{line:329,column:6},end:{line:347,column:7}},{start:{line:343,column:13},end:{line:347,column:7}}],line:329},42:{loc:{start:{line:331,column:20},end:{line:331,column:78}},type:"cond-expr",locations:[{start:{line:331,column:40},end:{line:331,column:67}},{start:{line:331,column:70},end:{line:331,column:78}}],line:331},43:{loc:{start:{line:331,column:20},end:{line:331,column:37}},type:"binary-expr",locations:[{start:{line:331,column:20},end:{line:331,column:25}},{start:{line:331,column:29},end:{line:331,column:37}}],line:331},44:{loc:{start:{line:350,column:4},end:{line:364,column:5}},type:"if",locations:[{start:{line:350,column:4},end:{line:364,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:350},45:{loc:{start:{line:354,column:8},end:{line:362,column:9}},type:"if",locations:[{start:{line:354,column:8},end:{line:362,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:354},46:{loc:{start:{line:365,column:4},end:{line:367,column:5}},type:"if",locations:[{start:{line:365,column:4},end:{line:367,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:365},47:{loc:{start:{line:368,column:4},end:{line:370,column:5}},type:"if",locations:[{start:{line:368,column:4},end:{line:370,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:368},48:{loc:{start:{line:371,column:4},end:{line:373,column:5}},type:"if",locations:[{start:{line:371,column:4},end:{line:373,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:371},49:{loc:{start:{line:374,column:4},end:{line:376,column:5}},type:"if",locations:[{start:{line:374,column:4},end:{line:376,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:374},50:{loc:{start:{line:407,column:4},end:{line:408,column:13}},type:"if",locations:[{start:{line:407,column:4},end:{line:408,column:13}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:407},51:{loc:{start:{line:409,column:4},end:{line:413,column:5}},type:"if",locations:[{start:{line:409,column:4},end:{line:413,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:409},52:{loc:{start:{line:443,column:26},end:{line:443,column:70}},type:"cond-expr",locations:[{start:{line:443,column:46},end:{line:443,column:65}},{start:{line:443,column:68},end:{line:443,column:70}}],line:443},53:{loc:{start:{line:444,column:31},end:{line:444,column:87}},type:"cond-expr",locations:[{start:{line:444,column:69},end:{line:444,column:78}},{start:{line:444,column:81},end:{line:444,column:87}}],line:444},54:{loc:{start:{line:468,column:21},end:{line:468,column:44}},type:"binary-expr",locations:[{start:{line:468,column:21},end:{line:468,column:38}},{start:{line:468,column:42},end:{line:468,column:44}}],line:468},55:{loc:{start:{line:469,column:4},end:{line:480,column:5}},type:"if",locations:[{start:{line:469,column:4},end:{line:480,column:5}},{start:{line:478,column:11},end:{line:480,column:5}}],line:469},56:{loc:{start:{line:489,column:6},end:{line:521,column:7}},type:"if",locations:[{start:{line:489,column:6},end:{line:521,column:7}},{start:{line:519,column:13},end:{line:521,column:7}}],line:489},57:{loc:{start:{line:489,column:10},end:{line:489,column:149}},type:"binary-expr",locations:[{start:{line:489,column:10},end:{line:489,column:72}},{start:{line:489,column:76},end:{line:489,column:97}},{start:{line:489,column:101},end:{line:489,column:149}}],line:489},58:{loc:{start:{line:503,column:10},end:{line:505,column:11}},type:"if",locations:[{start:{line:503,column:10},end:{line:505,column:11}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:503},59:{loc:{start:{line:520,column:26},end:{line:520,column:85}},type:"binary-expr",locations:[{start:{line:520,column:26},end:{line:520,column:49}},{start:{line:520,column:53},end:{line:520,column:85}}],line:520},60:{loc:{start:{line:523,column:4},end:{line:528,column:5}},type:"if",locations:[{start:{line:523,column:4},end:{line:528,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:523},61:{loc:{start:{line:531,column:21},end:{line:531,column:55}},type:"binary-expr",locations:[{start:{line:531,column:21},end:{line:531,column:49}},{start:{line:531,column:53},end:{line:531,column:55}}],line:531},62:{loc:{start:{line:532,column:11},end:{line:532,column:52}},type:"binary-expr",locations:[{start:{line:532,column:11},end:{line:532,column:40}},{start:{line:532,column:44},end:{line:532,column:52}}],line:532},63:{loc:{start:{line:542,column:16},end:{line:542,column:41}},type:"binary-expr",locations:[{start:{line:542,column:16},end:{line:542,column:29}},{start:{line:542,column:33},end:{line:542,column:41}}],line:542},64:{loc:{start:{line:555,column:4},end:{line:577,column:5}},type:"if",locations:[{start:{line:555,column:4},end:{line:577,column:5}},{start:{line:565,column:11},end:{line:577,column:5}}],line:555},65:{loc:{start:{line:579,column:4},end:{line:581,column:5}},type:"if",locations:[{start:{line:579,column:4},end:{line:581,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:579},66:{loc:{start:{line:583,column:4},end:{line:585,column:5}},type:"if",locations:[{start:{line:583,column:4},end:{line:585,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:583},67:{loc:{start:{line:594,column:66},end:{line:594,column:91}},type:"cond-expr",locations:[{start:{line:594,column:81},end:{line:594,column:84}},{start:{line:594,column:87},end:{line:594,column:91}}],line:594},68:{loc:{start:{line:595,column:4},end:{line:599,column:5}},type:"if",locations:[{start:{line:595,column:4},end:{line:599,column:5}},{start:{line:597,column:11},end:{line:599,column:5}}],line:595},69:{loc:{start:{line:600,column:4},end:{line:604,column:5}},type:"if",locations:[{start:{line:600,column:4},end:{line:604,column:5}},{start:{line:602,column:11},end:{line:604,column:5}}],line:600},70:{loc:{start:{line:602,column:11},end:{line:604,column:5}},type:"if",locations:[{start:{line:602,column:11},end:{line:604,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:602},71:{loc:{start:{line:610,column:4},end:{line:622,column:5}},type:"if",locations:[{start:{line:610,column:4},end:{line:622,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:610},72:{loc:{start:{line:610,column:8},end:{line:610,column:39}},type:"binary-expr",locations:[{start:{line:610,column:8},end:{line:610,column:18}},{start:{line:610,column:22},end:{line:610,column:39}}],line:610},73:{loc:{start:{line:624,column:4},end:{line:626,column:5}},type:"if",locations:[{start:{line:624,column:4},end:{line:626,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:624},74:{loc:{start:{line:624,column:8},end:{line:624,column:27}},type:"binary-expr",locations:[{start:{line:624,column:8},end:{line:624,column:12}},{start:{line:624,column:16},end:{line:624,column:27}}],line:624},75:{loc:{start:{line:628,column:4},end:{line:651,column:5}},type:"if",locations:[{start:{line:628,column:4},end:{line:651,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:628},76:{loc:{start:{line:636,column:8},end:{line:641,column:9}},type:"if",locations:[{start:{line:636,column:8},end:{line:641,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:636},77:{loc:{start:{line:638,column:10},end:{line:640,column:11}},type:"if",locations:[{start:{line:638,column:10},end:{line:640,column:11}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:638},78:{loc:{start:{line:642,column:8},end:{line:647,column:9}},type:"if",locations:[{start:{line:642,column:8},end:{line:647,column:9}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:642},79:{loc:{start:{line:660,column:4},end:{line:662,column:5}},type:"if",locations:[{start:{line:660,column:4},end:{line:662,column:5}},{start:{line:void 0,column:void 0},end:{line:void 0,column:void 0}}],line:660},80:{loc:{start:{line:660,column:8},end:{line:660,column:49}},type:"binary-expr",locations:[{start:{line:660,column:8},end:{line:660,column:30}},{start:{line:660,column:34},end:{line:660,column:49}}],line:660},81:{loc:{start:{line:690,column:19},end:{line:690,column:51}},type:"binary-expr",locations:[{start:{line:690,column:19},end:{line:690,column:45}},{start:{line:690,column:49},end:{line:690,column:51}}],line:690},82:{loc:{start:{line:691,column:26},end:{line:691,column:92}},type:"cond-expr",locations:[{start:{line:691,column:46},end:{line:691,column:83}},{start:{line:691,column:86},end:{line:691,column:92}}],line:691},83:{loc:{start:{line:721,column:24},end:{line:740,column:14}},type:"cond-expr",locations:[{start:{line:721,column:56},end:{line:740,column:5}},{start:{line:740,column:8},end:{line:740,column:14}}],line:721},84:{loc:{start:{line:741,column:24},end:{line:751,column:14}},type:"cond-expr",locations:[{start:{line:741,column:97},end:{line:751,column:5}},{start:{line:751,column:8},end:{line:751,column:14}}],line:741}},s:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0,65:0,66:0,67:0,68:0,69:0,70:0,71:0,72:0,73:0,74:0,75:0,76:0,77:0,78:0,79:0,80:0,81:0,82:0,83:0,84:0,85:0,86:0,87:0,88:0,89:0,90:0,91:0,92:0,93:0,94:0,95:0,96:0,97:0,98:0,99:0,100:0,101:0,102:0,103:0,104:0,105:0,106:0,107:0,108:0,109:0,110:0,111:0,112:0,113:0,114:0,115:0,116:0,117:0,118:0,119:0,120:0,121:0,122:0,123:0,124:0,125:0,126:0,127:0,128:0,129:0,130:0,131:0,132:0,133:0,134:0,135:0,136:0,137:0,138:0,139:0,140:0,141:0,142:0,143:0,144:0,145:0,146:0,147:0,148:0,149:0,150:0,151:0,152:0,153:0,154:0,155:0,156:0,157:0,158:0,159:0,160:0,161:0,162:0,163:0,164:0,165:0,166:0,167:0,168:0,169:0,170:0,171:0,172:0,173:0,174:0,175:0,176:0,177:0,178:0,179:0,180:0,181:0,182:0,183:0,184:0,185:0,186:0,187:0,188:0,189:0,190:0,191:0,192:0,193:0,194:0,195:0,196:0,197:0,198:0,199:0,200:0,201:0,202:0,203:0,204:0,205:0,206:0,207:0,208:0,209:0,210:0,211:0,212:0,213:0,214:0,215:0,216:0,217:0,218:0,219:0,220:0,221:0,222:0,223:0,224:0,225:0,226:0,227:0,228:0,229:0,230:0,231:0,232:0,233:0,234:0,235:0,236:0,237:0,238:0,239:0,240:0,241:0,242:0,243:0,244:0,245:0,246:0,247:0,248:0,249:0,250:0,251:0,252:0,253:0,254:0,255:0,256:0,257:0,258:0,259:0,260:0,261:0,262:0,263:0,264:0,265:0,266:0,267:0,268:0,269:0,270:0,271:0,272:0,273:0,274:0,275:0,276:0,277:0,278:0,279:0,280:0,281:0,282:0,283:0,284:0,285:0,286:0,287:0,288:0,289:0,290:0,291:0,292:0,293:0,294:0,295:0,296:0,297:0,298:0,299:0,300:0,301:0,302:0,303:0,304:0,305:0,306:0,307:0,308:0,309:0,310:0,311:0},f:{0:0,1:0,2:0,3:0,4:0,5:0,6:0,7:0,8:0,9:0,10:0,11:0,12:0,13:0,14:0,15:0,16:0,17:0,18:0,19:0,20:0,21:0,22:0,23:0,24:0,25:0,26:0,27:0,28:0,29:0,30:0,31:0,32:0,33:0,34:0,35:0,36:0,37:0,38:0,39:0,40:0,41:0,42:0,43:0,44:0,45:0,46:0,47:0,48:0,49:0,50:0,51:0,52:0,53:0,54:0,55:0,56:0,57:0,58:0,59:0,60:0,61:0,62:0,63:0,64:0},b:{0:[0,0],1:[0,0],2:[0,0],3:[0,0],4:[0,0],5:[0,0],6:[0,0,0],7:[0,0],8:[0,0],9:[0,0],10:[0,0],11:[0,0],12:[0,0],13:[0,0],14:[0,0],15:[0,0],16:[0,0],17:[0,0],18:[0,0],19:[0,0],20:[0,0,0],21:[0,0],22:[0,0],23:[0,0],24:[0,0],25:[0,0],26:[0,0],27:[0,0],28:[0,0],29:[0,0],30:[0,0],31:[0,0],32:[0],33:[0,0],34:[0,0],35:[0,0],36:[0,0],37:[0,0],38:[0,0],39:[0,0],40:[0,0],41:[0,0],42:[0,0],43:[0,0],44:[0,0],45:[0,0],46:[0,0],47:[0,0],48:[0,0],49:[0,0],50:[0,0],51:[0,0],52:[0,0],53:[0,0],54:[0,0],55:[0,0],56:[0,0],57:[0,0,0],58:[0,0],59:[0,0],60:[0,0],61:[0,0],62:[0,0],63:[0,0],64:[0,0],65:[0,0],66:[0,0],67:[0,0],68:[0,0],69:[0,0],70:[0,0],71:[0,0],72:[0,0],73:[0,0],74:[0,0],75:[0,0],76:[0,0],77:[0,0],78:[0,0],79:[0,0],80:[0,0],81:[0,0],82:[0,0],83:[0,0],84:[0,0]},inputSourceMap:{version:3,file:null,sources:["/home/runner/work/maputnik/maputnik/src/components/App.tsx"],names:["shortcut","mapStyle"],mappings:"AAotBmB,SAAA,KAgNA,YAhNA;AAntBnB,OAAO,cAAc;AACrB,OAAO,WAAW;AAClB,OAAO,eAAe;AACtB,OAAO,WAAW;AAClB,OAAO,YAAY;AACnB,OAAO,SAAS;AAChB,SAAQ,aAAY;AACpB,SAAQ,wBAAuB;AAC/B,OAAO,UAAU;AAEjB,SAAQ,QAAQ,wBAAuB;AAEvC,OAAO,mBAAmB;AAC1B,OAAO,mBAAmB;AAC1B,OAAO,eAAe;AACtB,OAAO,iBAAiB;AACxB,OAAO,gBAA8B;AACrC,OAAO,eAAe;AACtB,OAAO,kBAAkB;AAEzB,OAAO,mBAAmB;AAC1B,OAAO,iBAAiB;AACxB,OAAO,kBAAkB;AACzB,OAAO,eAAe;AACtB,OAAO,oBAAoB;AAC3B,OAAO,iBAAiB;AACxB,OAAO,gBAAgB;AAEvB,SAAQ,wBAAwB,8BAA6B;AAC7D,OAAO,WAAW;AAClB,SAAS,iBAAiB,cAAc,8BAA8B;AACtE,SAAS,cAAc,oBAAoB;AAC3C,SAAS,kBAAkB;AAC3B,SAAS,qBAAqB;AAC9B,SAAS,qBAAqB;AAC9B,OAAO,kBAAkB;AACzB,OAAO,YAAY;AACnB,OAAO,aAAa;AACpB,OAAO,WAAW;AAKlB,OAAO,SAAS,OAAO;AAEvB,SAAS,oBAAoB,KAAa,UAA8B;AAChE,QAAA,qBAAqB,IAAI,MAAM,oBAAoB;AACnD,QAAA,kBAAkB,IAAI,MAAM,iBAAiB;AAC7C,QAAA,uBAAuB,IAAI,MAAM,sBAAsB;AAC7D,MAAI,sBAAsB,iBAAiB;AACnC,UAAA,cAAc,MAAM,eAAe,gBAAgB,UAAU,EAAC,eAAe,KAAI,CAAC;AACxF,QAAI,aAAa;AACR,aAAA,IAAI,QAAQ,SAAS,WAAW;AAAA,IACzC;AAAA,EACF,WACS,sBAAsB;AACvB,UAAA,cAAc,MAAM,eAAe,iBAAiB,UAAU,EAAC,eAAe,KAAI,CAAC;AACzF,QAAI,aAAa;AACR,aAAA,IAAI,QAAQ,SAAS,WAAW;AAAA,IACzC;AAAA,EACF,OACK;AACI,WAAA;AAAA,EACT;AACF;AAEA,SAAS,eAAe,MAAW,WAAmB,WAAgB;AAC7D,SAAA;AAAA,IACL,GAAG;AAAA,IACH,OAAO;AAAA,MACL,GAAG,KAAK;AAAA,MACR,CAAC,SAAS,GAAG;AAAA,QACX,GAAG,KAAK,MAAM,SAAS;AAAA,QACvB,QAAQ;AAAA,MACV;AAAA,IACF;AAAA,EACF;AACF;AAyDA,qBAAqB,YAAY,MAAM,UAAyB;AAAA,EAC9D;AAAA,EACA;AAAA,EACA;AAAA,EACA,aAAoC;AAAA,EAEpC,YAAY,OAAY;AACtB,UAAM,KAAK;AACX,aAAS,IAAI;AAER,SAAA,gBAAgB,IAAI,cAAc;AACjC,UAAA,SAAS,IAAI,gBAAgB,OAAO,SAAS,OAAO,UAAU,CAAC,CAAC;AAClE,QAAA,OAAO,OAAO,IAAI,WAAW;AAC7B,QAAA,QAAQ,SAAS,OAAO,SAAS,SAAS,QAAQ,OAAO,SAAS,SAAS,QAAQ;AACrF,aAAO,OAAO,SAAS;AAAA,IACzB;AACK,SAAA,aAAa,IAAI,cAAc;AAAA,MAClC,oBAAoB,cAAY,KAAK,eAAe,UAAU,EAAC,MAAM,MAAK,CAAC;AAAA,MAC3E;AAAA,MACA,MAAM,OAAO,IAAI,WAAW;AAAA,IAC9B,CAAC;AAGD,UAAM,YAAY;AAAA,MAChB;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACb,eAAK,YAAY,WAAW;AAAA,QAC9B;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACb,eAAK,YAAY,MAAM;AAAA,QACzB;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACb,eAAK,YAAY,QAAQ;AAAA,QAC3B;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACb,eAAK,YAAY,SAAS;AAAA,QAC5B;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACb,eAAK,YAAY,UAAU;AAAA,QAC7B;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACR,eAAA;AAAA,YACH,KAAK,MAAM,aAAa,QAAQ,YAAY;AAAA,UAC9C;AAAA,QACF;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACZ,mBAAS,cAAc,oBAAoB,EAAwB,MAAM;AAAA,QAC5E;AAAA,MACF;AAAA,MACA;AAAA,QACE,KAAK;AAAA,QACL,SAAS,MAAM;AACb,eAAK,YAAY,OAAO;AAAA,QAC1B;AAAA,MACF;AAAA,IACF;AAEA,aAAS,KAAK,iBAAiB,SAAS,CAAC,MAAM;AAC1C,UAAA,EAAE,QAAQ,UAAU;AACpB,UAAE,OAAuB,KAAK;AAC/B,iBAAS,KAAK,MAAM;AAAA,MACtB,WACQ,KAAK,MAAM,OAAO,aAAa,SAAS,kBAAkB,SAAS,MAAM;AAC/E,cAAM,WAAW,UAAU,KAAK,CAACA,cAAa;AACpCA,iBAAAA,UAAS,QAAQ,EAAE;AAAA,QAC7B,CAAC;AAED,YAAG,UAAU;AACN,eAAA,SAAS,aAAa,KAAK;AAChC,mBAAS,QAAQ;AAAA,QACnB;AAAA,MACF;AAAA,IACF,CAAC;AAED,UAAM,WAAW,gBAAgB;AACjC,QAAG,YAAY,OAAO,QAAQ,0BAA0B,WAAW,+BAA+B,GAAG;AAC9F,WAAA,aAAa,IAAI,WAAW;AACjC,mBAAa,UAAU,CAAA,aAAY,KAAK,eAAe,QAAQ,CAAC;AACzC,6BAAA;AAAA,IACzB,OAAO;AACL,UAAG,UAAU;AACY,+BAAA;AAAA,MACzB;AACK,WAAA,WAAW,KAAK,CAAO,QAAA;AAC1B,YAAG,KAAK;AACN,kBAAQ,IAAI,kDAAkD;AACzD,eAAA,aAAa,IAAI,WAAW;AAAA,QACnC;AACK,aAAA,WAAW,YAAY,CAAA,aAAY,KAAK,eAAe,UAAU,EAAC,aAAa,KAAI,CAAC,CAAC;AAEvF,YAAA,MAAM,QAAQ,GAAG;AAClB,gBAAM,IAAI,YAAY,cAAc,KAAK,UAAU;AACnD,gBAAM,IAAI,YAAY,iBAAiB,KAAK,aAAa;AAAA,QAC3D;AAAA,MACF,CAAC;AAAA,IACH;AAEG,QAAA,MAAM,QAAQ,GAAG;AAClB,YAAM,IAAI,YAAY,iBAAiB,KAAK,aAAa;AACzD,YAAM,IAAI,YAAY,cAAc,KAAK,UAAU;AAAA,IACrD;AAEA,SAAK,QAAQ;AAAA,MACX,QAAQ,CAAC;AAAA,MACT,OAAO,CAAC;AAAA,MACR,UAAU,MAAM;AAAA,MAChB,oBAAoB;AAAA,MACpB,SAAS,CAAC;AAAA,MACV,cAAc,CAAC;AAAA,MACf,UAAU;AAAA,MACV,MAAM;AAAA,MACN,SAAS;AAAA,QACP,MAAM;AAAA,QACN,QAAQ;AAAA,UACN,KAAK;AAAA,UACL,KAAK;AAAA,QACP;AAAA,MACF;AAAA,MACA,QAAQ;AAAA,QACN,UAAU;AAAA,QACV,SAAS;AAAA,QACT,MAAM;AAAA,QACN,WAAW;AAAA,QACX,QAAQ;AAAA;AAAA,QAER,QAAQ;AAAA,QACR,OAAO;AAAA,MACT;AAAA,MACA,wBAAwB;AAAA,QACtB,oBAAoB;AAAA,QACpB,oBAAoB;AAAA,QACpB,uBAAuB;AAAA,MACzB;AAAA,MACA,wBAAwB;AAAA,QACtB,cAAc;AAAA,MAChB;AAAA,IACF;AAEK,SAAA,eAAe,IAAI,aAAa;AAAA,MACnC,sBAAsB,CAAK,MAAA,KAAK,SAAS,EAAE,cAAc,EAAE,CAAC;AAAA,IAC9D,CAAC;AAAA,EACH;AAAA,EAEA,iBAAiB,CAAC,MAAqB;AACrC,QAAG,UAAU,SAAS,YAAY,EAAE,QAAQ,KAAK,KAAK,GAAG;AACvD,UAAG,EAAE,WAAW,EAAE,YAAY,EAAE,YAAY,IAAI;AAC9C,UAAE,eAAe;AACjB,aAAK,OAAO;AAAA,MACd,WACQ,EAAE,WAAW,EAAE,YAAY,IAAI;AACrC,UAAE,eAAe;AACjB,aAAK,OAAO;AAAA,MACd;AAAA,IACF,OACK;AACH,UAAG,EAAE,WAAW,EAAE,YAAY,IAAI;AAChC,UAAE,eAAe;AACjB,aAAK,OAAO;AAAA,MACd,WACQ,EAAE,WAAW,EAAE,YAAY,IAAI;AACrC,UAAE,eAAe;AACjB,aAAK,OAAO;AAAA,MACd;AAAA,IACF;AAAA,EACF;AAAA,EAEA,oBAAoB;AACX,WAAA,iBAAiB,WAAW,KAAK,cAAc;AAAA,EACxD;AAAA,EAEA,uBAAuB;AACd,WAAA,oBAAoB,WAAW,KAAK,cAAc;AAAA,EAC3D;AAAA,EAEA,UAAU,eAAkD;AACrD,SAAA,WAAW,KAAK,aAAa;AAAA,EACpC;AAAA,EAEA,YAAY,aAAqB;AAC/B,UAAM,WAAoC,KAAK,MAAM,SAAS,YAAY,CAAC;AAC3E,UAAM,cAAc,SAAS,oCAAoC,KAAK,OAAO;AAEvE,UAAA,WAAY,OAAO,gBAAgB,WAAW,YAAY,QAAQ,SAAS,WAAW,IAAG;AAC/F,2BAAuB,UAAU,CAAS,UAAA;AACnC,WAAA,SAAS,EAAE,MAAM,eAAe,KAAK,MAAM,MAAM,UAAU,KAAK,EAAC,CAAC;AAAA,IACzE,CAAC;AAAA,EACH;AAAA,EAEA,YAAY,SAAiB;AAC3B,2BAAuB,SAAS,CAAS,UAAA;AAClC,WAAA,SAAS,EAAE,MAAM,eAAe,KAAK,MAAM,MAAM,UAAU,KAAK,EAAC,CAAC;AAAA,IACzE,CAAC;AAAA,EACH;AAAA,EAEA,2BAA2B,CAAC,UAAkB,UAAe;AAE3D,QACE,aAAa,uBACb,UAAU,IAAI,KAAK,MAAM,UAAU,CAAC,YAAY,mBAAmB,GAAG,QAAQ,GAC9E;AACA,WAAK,SAAS;AAAA,QACZ,UAAU;AAAA,MACZ,CAAC;AAAA,IACH;AAEA,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,UAAU;AAAA,QACR,GAAI,KAAK,MAAM,SAAiB;AAAA,QAChC,CAAC,QAAQ,GAAG;AAAA,MACd;AAAA,IACF;AACA,SAAK,eAAe,YAAY;AAAA,EAClC;AAAA,EAEA,iBAAiB,CAAC,UAA6C,OAAyB,CAAC,MAAM;AACtF,WAAA;AAAA,MACL,MAAM;AAAA,MACN,aAAa;AAAA,MACb,aAAa;AAAA,MACb,GAAG;AAAA,IACL;AAEA,QAAI,KAAK,aAAa;AACpB,WAAK,uBAAuB,QAAQ;AAAA,IACtC;AAEA,UAAM,SAA4B,iBAAiB,QAAQ,KAAK,CAAC;AAIjE,UAAM,cAA2C,CAAC;AAC9C,QAAA,YAAY,SAAS,QAAQ;AACzB,YAAA,cAAc,IAAI,OAAO,IAAI;AACnC,eAAS,OAAO,QAAQ,CAAC,OAAO,UAAU;AACxC,YAAI,MAAM,OAAO,MAAM,YAAY,IAAI,MAAM,EAAE,GAAG;AAChD,gBAAM,QAAQ,IAAI;AAAA,YAChB,UAAU,KAAK;AAAA,UACjB;AACA,sBAAY,KAAK,KAAK;AAAA,QACxB;AACY,oBAAA,IAAI,MAAM,IAAI,IAAI;AAAA,MAChC,CAAC;AAAA,IACH;AAEA,UAAM,eAAe,YAAY,OAAO,MAAM,EAAE,IAAI,CAAS,UAAA;AAE3D,YAAM,WAAW,MAAM,QAAQ,MAAM,iEAAiE;AACtG,UAAI,UAAU;AACZ,cAAM,CAAC,EAAE,OAAO,OAAO,IAAI;AACpB,eAAA;AAAA,UACL,SAAS,MAAM;AAAA,UACf,QAAQ;AAAA,YACN,MAAM;AAAA,YACN,MAAM;AAAA,cACJ,OAAO,SAAS,OAAO,EAAE;AAAA,cACzB,KAAK;AAAA,cACL;AAAA,YACF;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAGA,YAAM,qBAAqB,MAAM,QAAQ,MAAM,8CAA8C;AAC7F,UAAI,oBAAoB;AACtB,cAAM,CAAC,EAAE,OAAO,OAAO,IAAI;AACpB,eAAA;AAAA,UACL,SAAS,MAAM;AAAA,UACf,QAAQ;AAAA,YACN,MAAM;AAAA,YACN,MAAM;AAAA,cACJ,OAAO,SAAS,OAAO,EAAE;AAAA,cACzB,KAAK;AAAA,cACL;AAAA,YACF;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAEA,YAAM,aAAa,MAAM,QAAQ,MAAM,0CAA0C;AACjF,UAAI,YAAY;AACd,cAAM,CAAC,EAAE,OAAO,OAAO,UAAU,OAAO,IAAI;AACtC,cAAA,MAAO,SAAS,WAAY,CAAC,OAAO,QAAQ,EAAE,KAAK,GAAG,IAAI;AACzD,eAAA;AAAA,UACL,SAAS,MAAM;AAAA,UACf,QAAQ;AAAA,YACN,MAAM;AAAA,YACN,MAAM;AAAA,cACJ,OAAO,SAAS,OAAO,EAAE;AAAA,cACzB;AAAA,cACA;AAAA,YACF;AAAA,UACF;AAAA,QACF;AAAA,MACF,OACK;AACI,eAAA;AAAA,UACL,SAAS,MAAM;AAAA,QACjB;AAAA,MACF;AAAA,IACF,CAAC;AAED,QAAI,gBAAgD;AAChD,QAAA,OAAO,SAAS,GAAG;AACrB,sBAAgB,UAAU,QAAQ;AAElC,aAAO,QAAQ,CAAS,UAAA;AAChB,cAAA,EAAC,QAAO,IAAI;AAClB,YAAI,SAAS;AACP,cAAA;AACF,kBAAM,UAAU,QAAQ,MAAM,GAAG,EAAE,CAAC;AAEpC,kBAAM,YAAY,QAAQ,MAAM,qBAAqB,EAAG,CAAC;AACzD,kBAAM,eAAe,SAAS;AAAA,UAChC,SACO,KAAK;AACV,oBAAQ,KAAK,GAAG;AAAA,UAClB;AAAA,QACF;AAAA,MACF,CAAC;AAAA,IACH;AAEA,QAAG,SAAS,WAAW,KAAK,MAAM,SAAS,QAAQ;AAC5C,WAAA,YAAY,SAAS,MAAgB;AAAA,IAC5C;AACA,QAAG,SAAS,WAAW,KAAK,MAAM,SAAS,QAAQ;AAC5C,WAAA,YAAY,SAAS,MAAgB;AAAA,IAC5C;AAEA,QAAI,KAAK,aAAa;AACf,WAAA,cAAc,YAAY,QAAQ;AAAA,IACzC;AACA,QAAI,KAAK,MAAM;AACb,WAAK,UAAU,QAA6C;AAAA,IAC9D;AAEA,SAAK,SAAS;AAAA,MACZ,UAAU;AAAA,MACV;AAAA,MACA,QAAQ;AAAA,IACV,GAAG,MAAM;AACP,WAAK,aAAa;AAClB,WAAK,cAAc;AAAA,IACrB,CAAC;AAAA,EAEH;AAAA,EAEA,SAAS,MAAM;AACP,UAAA,cAAc,KAAK,cAAc,KAAK;AAE5C,UAAM,WAAW,aAAa,KAAK,MAAM,UAAU,WAAW;AAC9D,SAAK,eAAe,aAAa,EAAC,aAAa,MAAK,CAAC;AACrD,SAAK,SAAS;AAAA,MACZ,OAAO;AAAA,IACT,CAAC;AAAA,EACH;AAAA,EAEA,SAAS,MAAM;AACP,UAAA,cAAc,KAAK,cAAc,KAAK;AAC5C,UAAM,WAAW,aAAa,KAAK,MAAM,UAAU,WAAW;AAC9D,SAAK,eAAe,aAAa,EAAC,aAAa,MAAK,CAAC;AACrD,SAAK,SAAS;AAAA,MACZ,OAAO;AAAA,IACT,CAAC;AAAA,EACH;AAAA,EAEA,cAAc,CAAC,SAAkB;AAC3B,QAAA,EAAE,UAAU,SAAS,IAAI;AACzB,QAAA,SAAS,KAAK,MAAM,SAAS;AACjC,eAAW,MAAM,UAAU,GAAG,OAAO,SAAO,CAAC;AAC7C,eAAW,MAAM,UAAU,GAAG,OAAO,SAAO,CAAC;AAC7C,QAAG,aAAa;AAAU;AAEtB,QAAA,aAAa,KAAK,MAAM,oBAAoB;AAC9C,WAAK,SAAS;AAAA,QACZ,oBAAoB;AAAA,MACtB,CAAC;AAAA,IACH;AAES,aAAA,OAAO,MAAM,CAAC;AACN,qBAAA,QAAQ,UAAU,QAAQ;AAC3C,SAAK,eAAe,MAAM;AAAA,EAC5B;AAAA,EAEA,iBAAiB,CAAC,kBAAwC;AACxD,UAAM,eAAe;AAAA,MACnB,GAAG,KAAK,MAAM;AAAA,MACd,QAAQ;AAAA,IACV;AACA,SAAK,eAAe,YAAY;AAAA,EAClC;AAAA,EAEA,iBAAiB,CAAC,UAAkB;AAC5B,UAAA,SAAS,KAAK,MAAM,SAAS;AAC7B,UAAA,kBAAkB,OAAO,MAAM,CAAC;AACtB,oBAAA,OAAO,OAAO,CAAC;AAC/B,SAAK,eAAe,eAAe;AAAA,EACrC;AAAA,EAEA,cAAc,CAAC,UAAkB;AACzB,UAAA,SAAS,KAAK,MAAM,SAAS;AAC7B,UAAA,gBAAgB,OAAO,MAAM,CAAC;AAEpC,UAAM,cAAc,UAAU,cAAc,KAAK,CAAC;AACtC,gBAAA,KAAK,YAAY,KAAK;AACpB,kBAAA,OAAO,OAAO,GAAG,WAAW;AAC1C,SAAK,eAAe,aAAa;AAAA,EACnC;AAAA,EAEA,0BAA0B,CAAC,UAAkB;AACrC,UAAA,SAAS,KAAK,MAAM,SAAS;AAC7B,UAAA,gBAAgB,OAAO,MAAM,CAAC;AAEpC,UAAM,QAAQ,EAAE,GAAG,cAAc,KAAK,EAAE;AAClC,UAAA,gBAAgB,YAAY,QAAQ,EAAC,GAAG,MAAM,OAAM,IAAI,CAAC;AAC/D,kBAAc,aAAa,cAAc,eAAe,SAAS,YAAY;AAE7E,UAAM,SAAS;AACf,kBAAc,KAAK,IAAI;AACvB,SAAK,eAAe,aAAa;AAAA,EACnC;AAAA,EAGA,kBAAkB,CAAC,OAAe,QAAgB,UAAkB;AAClE,UAAM,gBAAgB,KAAK,MAAM,SAAS,OAAO,MAAM,CAAC;AACxD,kBAAc,KAAK,IAAI;AAAA,MACrB,GAAG,cAAc,KAAK;AAAA,MACtB,IAAI;AAAA,IACN;AAEA,SAAK,eAAe,aAAa;AAAA,EACnC;AAAA,EAEA,iBAAiB,CAAC,OAAe,UAA8B;AAC7D,UAAM,gBAAgB,KAAK,MAAM,SAAS,OAAO,MAAM,CAAC;AACxD,kBAAc,KAAK,IAAI;AAEvB,SAAK,eAAe,aAAa;AAAA,EACnC;AAAA,EAEA,cAAc,CAAC,aAAuB;AACpC,SAAK,SAAS;AAAA,MACZ,UAAU;AAAA,IACZ,GAAG,KAAK,aAAa;AAAA,EACvB;AAAA,EAEA,mBAAmB,CAAC,aAAgD;AAC5D,UAAA,WAAoC,SAAS,YAAY,CAAC;AAC7D,QAAA,SAAS,mBAAmB,MAAM,QAAW;AAC9C,YAAM,eAAe;AAAA,QACnB,GAAG;AAAA,QACH,UAAU;AAAA,UACR,GAAG,SAAS;AAAA,UACZ,qBAAqB;AAAA,QACvB;AAAA,MACF;AACO,aAAA;AAAA,IACT,OAAO;AACE,aAAA;AAAA,IACT;AAAA,EACF;AAAA,EAEA,YAAY,CAAC,aAAgD;AAChD,eAAA,KAAK,iBAAiB,QAAQ;AACzC,SAAK,eAAe,QAAQ;AAAA,EAC9B;AAAA,EAEA,eAAe;AACb,UAAM,aAAmC,CAAC;AAEhC,eAAA,CAAC,KAAK,GAAG,KAAK,OAAO,QAAQ,KAAK,MAAM,SAAS,OAAO,GAAG;AACnE,UACE,CAAC,OAAO,UAAU,eAAe,KAAK,KAAK,MAAM,SAAS,GAAG,KAC7D,IAAI,SAAS,YACb,OAAO,UAAU,eAAe,KAAK,KAAK,KAAK,GAC/C;AACA,mBAAW,GAAG,IAAI;AAAA,UAChB,MAAM,IAAI;AAAA,UACV,QAAQ,CAAC;AAAA,QACX;AAEA,YAAI,MAAM,IAAI;AAEV,YAAA;AACF,gBAAM,oBAAoB,KAAM,KAAK,MAAM,QAAQ;AAAA,QACrD,SAAQ,KAAK;AACH,kBAAA,KAAK,mCAAmC,GAAG;AAAA,QACrD;AAEA,cAAM,KAAM;AAAA,UACV,MAAM;AAAA,QACR,CAAC,EACE,KAAK,CAAA,aAAY,SAAS,KAAK,CAAC,EAChC,KAAK,CAAQ,SAAA;AAEZ,cAAG,CAAC,OAAO,UAAU,eAAe,KAAK,MAAM,eAAe,GAAG;AAC/D;AAAA,UACF;AAGA,gBAAM,UAAU,OAAO,OAAO,CAAC,GAAG;AAAA,YAChC,CAAC,GAAG,GAAG,KAAK,MAAM,QAAQ,GAAG;AAAA,UAC/B,CAAC;AAES,qBAAA,SAAS,KAAK,eAAe;AACpC,oBAAQ,GAAG,EAAU,OAAO,KAAK,MAAM,EAAE;AAAA,UAC5C;AAEQ,kBAAA,MAAM,sBAAoB,GAAG;AACrC,eAAK,SAAS;AAAA,YACZ;AAAA,UACF,CAAC;AAAA,QACH,CAAC,EACA,MAAM,CAAO,QAAA;AACJ,kBAAA,MAAM,sCAAsC,KAAK,GAAG;AAAA,QAC9D,CAAC;AAAA,MACL,OACK;AACQ,mBAAA,GAAG,IAAI,KAAK,MAAM,QAAQ,GAAG,KAAK,KAAK,MAAM,SAAS,QAAQ,GAAG;AAAA,MAC9E;AAAA,IACF;AAEA,QAAG,CAAC,QAAQ,KAAK,MAAM,SAAS,UAAU,GAAG;AAC3C,cAAQ,MAAM,iBAAiB;AAC/B,WAAK,SAAS;AAAA,QACZ,SAAS;AAAA,MACX,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEA,eAAgB;AACd,UAAM,WAAmC,KAAK,MAAM,SAAS,YAAY,CAAC;AACnE,WAAA,SAAS,mBAAmB,KAAK;AAAA,EAC1C;AAAA,EAEA,cAAc,CAAC,YAMT;AACJ,SAAK,SAAS;AAAA,MACZ;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,cAAc;AACZ,UAAM,EAAC,UAAU,cAAa,IAAI,KAAK;AAEvC,UAAM,WAAW;AAAA,MACf,UAAW,iBAAiB;AAAA,MAC5B,qBAAqB,CAACC,cAAiC;AAC9C,eAAA,MAAM,oBAAoBA,WAAU;AAAA,UACzC,eAAe;AAAA,QACjB,CAAC;AAAA,MACH;AAAA,MACA,cAAc,CAAC,MAAkB;AAC1B,aAAA,aAAa,WAAW,EAAE,GAAG;AAClC,aAAK,aAAa;AAAA,MACpB;AAAA,IACF;AAEM,UAAA,WAAW,KAAK,aAAa;AAE/B,QAAA;AAGJ,QAAG,aAAa,MAAM;AACP,mBAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACX,GAAG;AAAA,UACJ,UAAU,KAAK;AAAA,UACf,cAAc,KAAK,MAAM,uBAAuB;AAAA,UAChD,eAAe,KAAK;AAAA,QAAA;AAAA,MACtB;AAAA,IACF,OAAO;AACQ,mBAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UAAe,GAAG;AAAA,UAC9B,UAAU,KAAK;AAAA,UACf,SAAS,KAAK,MAAM;AAAA,UACpB,oBAAoB,KAAK,MAAM,aAAa;AAAA,UAC5C,kBAAkB,KAAK,MAAM,SAAS,OAAO,KAAK,MAAM,kBAAkB;AAAA,UAC1E,eAAe,KAAK;AAAA,QAAA;AAAA,MAAe;AAAA,IACvC;AAEI,QAAA;AACJ,QAAG,KAAK,MAAM,SAAS,MAAM,UAAU,GAAG;AACxC,mBAAa,KAAK,MAAM,SAAS,QAAQ,YAAY,EAAE;AAAA,IACzD;AACA,UAAM,eAAkC,CAAC;AACzC,QAAI,YAAY;AACD,mBAAA,SAAS,SAAS,UAAU;AAAA,IAC3C;AAEO,WAAA,oBAAC,SAAI,OAAO,cAAc,WAAU,2BAA0B,eAAY,sBAC9E,UACH,WAAA,CAAA;AAAA,EACF;AAAA,EAEA,gBAAgB,MAAM;AACpB,UAAM,EAAC,UAAU,UAAU,OAAM,IAAI,KAAK;AACpC,UAAA,EAAC,mBAAkB,IAAI,KAAK;AAClC,UAAM,MAAM,IAAI,IAAI,SAAS,IAAI;AACjC,UAAM,UAAU,KAAK,KAAK,UAAU,QAAQ,CAAC;AAC7C,QAAI,aAAa,IAAI,SAAS,GAAG,OAAO,IAAI,kBAAkB,EAAE;AAEhE,UAAM,aAAa,OAAO,QAAQ,MAAM,EACrC,IAAI,CAAC,CAAC,KAAK,GAAG,MAAO,QAAQ,OAAO,MAAM,IAAK,EAC/C,OAAO,CAAA,QAAO,QAAQ,IAAI;AAEzB,QAAA,WAAW,SAAS,GAAG;AACzB,UAAI,aAAa,IAAI,SAAS,WAAW,KAAK,GAAG,CAAC;AAAA,IACpD,OACK;AACC,UAAA,aAAa,OAAO,OAAO;AAAA,IACjC;AAEA,QAAI,aAAa,OAAO;AAClB,UAAA,aAAa,OAAO,MAAM;AAAA,IAChC,WACS,aAAa,WAAW;AAC3B,UAAA,aAAa,IAAI,QAAQ,SAAS;AAAA,IACxC;AAEA,YAAQ,aAAa,EAAC,mBAAkB,GAAG,YAAY,IAAI,IAAI;AAAA,EACjE;AAAA,EAEA,yBAAyB,CAAC,aAAiC;AACzD,UAAM,MAAM,IAAI,IAAI,SAAS,IAAI;AACjC,UAAM,aAAa,IAAI,aAAa,IAAI,OAAO;AAC3C,QAAA,cAAc,eAAe,IAAI;AAC7B,YAAA,SAAS,WAAW,MAAM,GAAG;AACnC,YAAM,WAAqC,CAAC;AAC5C,aAAO,QAAQ,CAAa,cAAA;AAC1B,iBAAS,SAAS,IAAI;AAAA,MACxB,CAAC;AAED,WAAK,SAAS;AAAA,QACZ,QAAQ;AAAA,UACN,GAAG,KAAK,MAAM;AAAA,UACd,GAAG;AAAA,QACL;AAAA,MACF,CAAC;AAAA,IACH;AAEA,UAAM,OAAO,IAAI,aAAa,IAAI,MAAM;AACpC,QAAA,QAAQ,SAAS,IAAI;AACvB,WAAK,YAAY,IAAgB;AAAA,IACnC;AAEA,UAAM,OAAO,IAAI,aAAa,IAAI,OAAO;AACzC,QAAI,MAAM;AACJ,UAAA;AACI,cAAA,QAAQ,KAAK,MAAM,GAAG;AACtB,cAAA,CAAC,SAAS,kBAAkB,IAAI;AAAA,UACpC,MAAM,CAAC;AAAA,UACP,SAAS,MAAM,CAAC,GAAG,EAAE;AAAA,QACvB;AAEA,YAAI,QAAQ;AACZ,YAAI,YAAY,KAAK;AACnB,gBAAM,iBAAiB,KAAK,KAAK,UAAU,QAAQ,CAAC;AACpD,cAAI,mBAAmB,SAAS,SAAS,EAAE,GAAG;AACpC,oBAAA;AAAA,UACV;AAAA,QACF;AACA,YAAI,OAAO;AACT,eAAK,SAAS;AAAA,YACZ;AAAA,YACA,yBAAyB,SAAS,OAAO,kBAAkB,EAAE;AAAA,UAC/D,CAAC;AAAA,QACH;AAAA,MACF,SACO,KAAK;AACV,gBAAQ,KAAK,GAAG;AAAA,MAClB;AAAA,IACF;AAAA,EACF;AAAA,EAEA,gBAAgB,CAAC,UAAkB;AACjC,SAAK,SAAS;AAAA,MACZ,oBAAoB;AAAA,MACpB,yBAAyB,KAAK,MAAM,SAAS,OAAO,KAAK,EAAE;AAAA,IAC7D,GAAG,KAAK,aAAa;AAAA,EACvB;AAAA,EAEA,SAAS,WAAqC,OAAgB;AACzD,QAAA,cAAc,YAAY,UAAU,OAAO;AAC/B,mBAAA,QAAQ,UAAU,EAAE;AAAA,IACnC;AAEA,SAAK,SAAS;AAAA,MACZ,QAAQ;AAAA,QACN,GAAG,KAAK,MAAM;AAAA,QACd,CAAC,SAAS,GAAG;AAAA,MACf;AAAA,IACF,GAAG,KAAK,aAAa;AAAA,EACvB;AAAA,EAEA,YAAY,WAAqC;AAC/C,SAAK,SAAS,WAAW,CAAC,KAAK,MAAM,OAAO,SAAS,CAAC;AAAA,EACxD;AAAA,EAEA,0BAA0B,CAAC,KAA+C,UAAmB;AAC3F,SAAK,SAAS;AAAA,MACZ,wBAAwB;AAAA,QACtB,GAAG,KAAK,MAAM;AAAA,QACd,CAAC,GAAG,GAAG;AAAA,MACT;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,0BAA0B,CAAC,KAA+C,UAAe;AACvF,SAAK,SAAS;AAAA,MACZ,wBAAwB;AAAA,QACtB,GAAG,KAAK,MAAM;AAAA,QACd,CAAC,GAAG,GAAG;AAAA,MACT;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EAEA,SAAS;AACP,UAAM,SAAS,KAAK,MAAM,SAAS,UAAU,CAAC;AACxC,UAAA,gBAAgB,OAAO,SAAS,IAAI,OAAO,KAAK,MAAM,kBAAkB,IAAI;AAElF,UAAM,UAAU;AAAA,MAAC;AAAA,MAAA;AAAA,QACf,UAAU,KAAK,aAAa;AAAA,QAC5B,UAAU,KAAK,MAAM;AAAA,QACrB,UAAU,KAAK,MAAM;AAAA,QACrB,oBAAoB,KAAK,MAAM,aAAa;AAAA,QAC5C,SAAS,KAAK,MAAM;AAAA,QACpB,gBAAgB,KAAK;AAAA,QACrB,aAAa,KAAK;AAAA,QAClB,eAAe,KAAK;AAAA,QACpB,eAAe,KAAK,YAAY,KAAK,IAAI;AAAA,MAAA;AAAA,IAC3C;AAEA,UAAM,YAAY;AAAA,MAAC;AAAA,MAAA;AAAA,QACjB,aAAa,KAAK;AAAA,QAClB,gBAAgB,KAAK;AAAA,QACrB,aAAa,KAAK;AAAA,QAClB,yBAAyB,KAAK;AAAA,QAC9B,gBAAgB,KAAK;AAAA,QACrB,eAAe,KAAK;AAAA,QACpB,oBAAoB,KAAK,MAAM;AAAA,QAC/B;AAAA,QACA,SAAS,KAAK,MAAM;AAAA,QACpB,QAAQ,KAAK,MAAM;AAAA,MAAA;AAAA,IACrB;AAEA,UAAM,cAAc,gBAAgB;AAAA,MAAC;AAAA,MAAA;AAAA,QAEnC,OAAO;AAAA,QACP,YAAY,KAAK,MAAM;AAAA,QACvB,cAAc,KAAK,MAAM,qBAAqB;AAAA,QAC9C,aAAa,KAAK,MAAM,uBAAuB,KAAK,MAAM,SAAS,OAAO,SAAO;AAAA,QACjF,SAAS,KAAK,MAAM;AAAA,QACpB,cAAc,KAAK,MAAM;AAAA,QACzB,MAAM,KAAK,MAAM;AAAA,QACjB,aAAa,KAAK;AAAA,QAClB,gBAAgB,KAAK;AAAA,QACrB,gBAAgB,KAAK;AAAA,QACrB,aAAa,KAAK;AAAA,QAClB,yBAAyB,KAAK;AAAA,QAC9B,iBAAiB,KAAK;AAAA,QACtB,QAAQ,KAAK,MAAM;AAAA,MAAA;AAAA,MAdd,KAAK,MAAM;AAAA,IAelB,IAAK;AAEC,UAAA,cAAe,KAAK,MAAM,OAAO,SAAS,KAAK,MAAM,MAAM,SAAU,IAAI;AAAA,MAAC;AAAA,MAAA;AAAA,QAC9E,cAAc;AAAA,QACd,oBAAoB,KAAK,MAAM;AAAA,QAC/B,eAAe,KAAK;AAAA,QACpB,UAAU,KAAK,MAAM;AAAA,QACrB,QAAQ,KAAK,MAAM;AAAA,QACnB,OAAO,KAAK,MAAM;AAAA,MAAA;AAAA,IACpB,IAAK;AAGC,UAAA,8BAAU,OACd,EAAA,UAAA;AAAA,MAAA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,UAAU,KAAK,aAAa;AAAA,UAC5B,wBAAwB,KAAK,MAAM;AAAA,UACnC,wBAAwB,KAAK,MAAM;AAAA,UACnC,yBAAyB,KAAK;AAAA,UAC9B,yBAAyB,KAAK;AAAA,UAC9B,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,OAAO;AAAA,UACjD,SAAS,KAAK,MAAM;AAAA,QAAA;AAAA,MACtB;AAAA,MACA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,KAAK,CAAC,OAAO,KAAK,aAAa;AAAA,UAC/B,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,WAAW;AAAA,QAAA;AAAA,MACvD;AAAA,MACA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,UAAU,KAAK,MAAM;AAAA,UACrB,gBAAgB,KAAK;AAAA,UACrB,0BAA0B,KAAK;AAAA,UAC/B,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,UAAU;AAAA,QAAA;AAAA,MACtD;AAAA,MACA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,UAAU,KAAK,MAAM;AAAA,UACrB,gBAAgB,KAAK;AAAA,UACrB,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,QAAQ;AAAA,QAAA;AAAA,MACpD;AAAA,MACA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,aAAa,KAAK;AAAA,UAClB,cAAc,KAAK,YAAY,KAAK,MAAM,MAAM;AAAA,QAAA;AAAA,MAClD;AAAA,MACA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,UAAU,KAAK,MAAM;AAAA,UACrB,gBAAgB,KAAK;AAAA,UACrB,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,SAAS;AAAA,QAAA;AAAA,MACrD;AAAA,MACA;AAAA,QAAC;AAAA,QAAA;AAAA,UACC,QAAQ,KAAK,MAAM,OAAO;AAAA,UAC1B,cAAc,KAAK,YAAY,KAAK,MAAM,QAAQ;AAAA,QAAA;AAAA,MACpD;AAAA,IACF,EAAA,CAAA;AAEO,WAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACN;AAAA,QACA;AAAA,QACA;AAAA,QACA,KAAK,KAAK,YAAY;AAAA,QACtB,QAAQ;AAAA,QACR;AAAA,MAAA;AAAA,IACF;AAAA,EACF;AACF;"},_coverageSchema:"1a1c01bbd47fc00a2c39e90264f33305004495a9",hash:"89c068ca942382ab4384d9496905567c46b1fd10"},o=t[r]||(t[r]={});(!o[e]||o[e].hash!==n)&&(o[e]=i);var s=o[e];return re=function(){return s},s}re();re().s[0]++;window.Buffer=$q.Buffer;function C8e(e,n){re().f[0]++;const t=(re().s[1]++,e.match(/\.tilehosting\.com/)),r=(re().s[2]++,e.match(/\.maptiler\.com/)),i=(re().s[3]++,e.match(/\.thunderforest\.com/));if(re().s[4]++,re().b[1][0]++,t||(re().b[1][1]++,r)){re().b[0][0]++;const o=(re().s[5]++,vu.getAccessToken("openmaptiles",n,{allowFallback:!0}));if(re().s[6]++,o)return re().b[2][0]++,re().s[7]++,e.replace("{key}",o);re().b[2][1]++}else if(re().b[0][1]++,re().s[8]++,i){re().b[3][0]++;const o=(re().s[9]++,vu.getAccessToken("thunderforest",n,{allowFallback:!0}));if(re().s[10]++,o)return re().b[4][0]++,re().s[11]++,e.replace("{key}",o);re().b[4][1]++}else return re().b[3][1]++,re().s[12]++,e}function oF(e,n,t){return re().f[1]++,re().s[13]++,{...e,$root:{...e.$root,[n]:{...e.$root[n],values:t}}}}class _8e extends bn.Component{constructor(t){re().f[2]++,re().s[15]++;super(t);nn(this,"revisionStore");nn(this,"styleStore");nn(this,"layerWatcher");nn(this,"shortcutEl",(re().s[14]++,null));nn(this,"handleKeyPress",(re().s[66]++,t=>{re().f[18]++,re().s[67]++,navigator.platform.toUpperCase().indexOf("MAC")>=0?(re().b[18][0]++,re().s[68]++,re().b[20][0]++,t.metaKey&&(re().b[20][1]++,t.shiftKey)&&(re().b[20][2]++,t.keyCode===90)?(re().b[19][0]++,re().s[69]++,t.preventDefault(),re().s[70]++,this.onRedo()):(re().b[19][1]++,re().s[71]++,re().b[22][0]++,t.metaKey&&(re().b[22][1]++,t.keyCode===90)?(re().b[21][0]++,re().s[72]++,t.preventDefault(),re().s[73]++,this.onUndo()):re().b[21][1]++)):(re().b[18][1]++,re().s[74]++,re().b[24][0]++,t.ctrlKey&&(re().b[24][1]++,t.keyCode===90)?(re().b[23][0]++,re().s[75]++,t.preventDefault(),re().s[76]++,this.onUndo()):(re().b[23][1]++,re().s[77]++,re().b[26][0]++,t.ctrlKey&&(re().b[26][1]++,t.keyCode===89)?(re().b[25][0]++,re().s[78]++,t.preventDefault(),re().s[79]++,this.onRedo()):re().b[25][1]++))}));nn(this,"onChangeMetadataProperty",(re().s[90]++,(t,r)=>{re().f[26]++,re().s[91]++,re().b[31][0]++,t==="maputnik:renderer"&&(re().b[31][1]++,r!==GV(this.state.mapStyle,["metadata","maputnik:renderer"],"mlgljs"))?(re().b[30][0]++,re().s[92]++,this.setState({mapState:"map"})):re().b[30][1]++;const i=(re().s[93]++,{...this.state.mapStyle,metadata:{...this.state.mapStyle.metadata,[t]:r}});re().s[94]++,this.onStyleChanged(i)}));nn(this,"onStyleChanged",(re().s[95]++,(t,r=(re().b[32][0]++,{}))=>{re().f[27]++,re().s[96]++,r={save:!0,addRevision:!0,initialLoad:!1,...r},re().s[97]++,r.initialLoad?(re().b[33][0]++,re().s[98]++,this.getInitialStateFromUrl(t)):re().b[33][1]++;const i=(re().s[99]++,re().b[34][0]++,Bd(t)||(re().b[34][1]++,[])),o=(re().s[100]++,[]);if(re().s[101]++,re().b[36][0]++,t&&(re().b[36][1]++,t.layers)){re().b[35][0]++;const f=(re().s[102]++,new window.Map);re().s[103]++,t.layers.forEach((g,x)=>{if(re().f[28]++,re().s[104]++,re().b[38][0]++,g.id===""&&(re().b[38][1]++,f.has(g.id))){re().b[37][0]++;const k=(re().s[105]++,new Error(`layers[${x}]: duplicate layer id [empty_string], previously used`));re().s[106]++,o.push(k)}else re().b[37][1]++;re().s[107]++,f.set(g.id,!0)})}else re().b[35][1]++;const s=(re().s[108]++,o.concat(i).map(f=>{re().f[29]++;const g=(re().s[109]++,f.message.match(/layers\[(\d+)\]: (duplicate layer id "?(.*)"?, previously used)/));if(re().s[110]++,g){re().b[39][0]++;const[,B,P]=(re().s[111]++,g);return re().s[112]++,{message:f.message,parsed:{type:"layer",data:{index:parseInt(B,10),key:"id",message:P}}}}else re().b[39][1]++;const x=(re().s[113]++,f.message.match(/layers\[(\d+)\]: (source "(?:.*)" not found)/));if(re().s[114]++,x){re().b[40][0]++;const[,B,P]=(re().s[115]++,x);return re().s[116]++,{message:f.message,parsed:{type:"layer",data:{index:parseInt(B,10),key:"source",message:P}}}}else re().b[40][1]++;const k=(re().s[117]++,f.message.match(/layers\[(\d+)\]\.(?:(\S+)\.)?(\S+): (.*)/));if(re().s[118]++,k){re().b[41][0]++;const[,B,P,R,H]=(re().s[119]++,k),W=(re().s[120]++,re().b[43][0]++,P&&(re().b[43][1]++,R)?(re().b[42][0]++,[P,R].join(".")):(re().b[42][1]++,R));return re().s[121]++,{message:f.message,parsed:{type:"layer",data:{index:parseInt(B,10),key:W,message:H}}}}else return re().b[41][1]++,re().s[122]++,{message:f.message}}));let a=(re().s[123]++,void 0);re().s[124]++,i.length>0?(re().b[44][0]++,re().s[125]++,a=_I(t),re().s[126]++,i.forEach(f=>{re().f[30]++;const{message:g}=(re().s[127]++,f);if(re().s[128]++,g){re().b[45][0]++,re().s[129]++;try{const x=(re().s[130]++,g.split(":")[0]),k=(re().s[131]++,x.match(/^\S+?\[\d+\]\.[^[]+/)[0]);re().s[132]++,Q4.unset(a,k)}catch(x){re().s[133]++,console.warn(x)}}else re().b[45][1]++})):re().b[44][1]++,re().s[134]++,t.glyphs!==this.state.mapStyle.glyphs?(re().b[46][0]++,re().s[135]++,this.updateFonts(t.glyphs)):re().b[46][1]++,re().s[136]++,t.sprite!==this.state.mapStyle.sprite?(re().b[47][0]++,re().s[137]++,this.updateIcons(t.sprite)):re().b[47][1]++,re().s[138]++,r.addRevision?(re().b[48][0]++,re().s[139]++,this.revisionStore.addRevision(t)):re().b[48][1]++,re().s[140]++,r.save?(re().b[49][0]++,re().s[141]++,this.saveStyle(t)):re().b[49][1]++,re().s[142]++,this.setState({mapStyle:t,dirtyMapStyle:a,errors:s},()=>{re().f[31]++,re().s[143]++,this.fetchSources(),re().s[144]++,this.setStateInUrl()})}));nn(this,"onUndo",(re().s[145]++,()=>{re().f[32]++;const t=(re().s[146]++,this.revisionStore.undo()),r=(re().s[147]++,U7e(this.state.mapStyle,t));re().s[148]++,this.onStyleChanged(t,{addRevision:!1}),re().s[149]++,this.setState({infos:r})}));nn(this,"onRedo",(re().s[150]++,()=>{re().f[33]++;const t=(re().s[151]++,this.revisionStore.redo()),r=(re().s[152]++,R7e(this.state.mapStyle,t));re().s[153]++,this.onStyleChanged(t,{addRevision:!1}),re().s[154]++,this.setState({infos:r})}));nn(this,"onMoveLayer",(re().s[155]++,t=>{re().f[34]++;let{oldIndex:r,newIndex:i}=(re().s[156]++,t),o=(re().s[157]++,this.state.mapStyle.layers);if(re().s[158]++,r=wI(r,0,o.length-1),re().s[159]++,i=wI(i,0,o.length-1),re().s[160]++,r===i){re().b[50][0]++,re().s[161]++;return}else re().b[50][1]++;re().s[162]++,r===this.state.selectedLayerIndex?(re().b[51][0]++,re().s[163]++,this.setState({selectedLayerIndex:i})):re().b[51][1]++,re().s[164]++,o=o.slice(0),re().s[165]++,QV(o,r,i),re().s[166]++,this.onLayersChange(o)}));nn(this,"onLayersChange",(re().s[167]++,t=>{re().f[35]++;const r=(re().s[168]++,{...this.state.mapStyle,layers:t});re().s[169]++,this.onStyleChanged(r)}));nn(this,"onLayerDestroy",(re().s[170]++,t=>{re().f[36]++;const r=(re().s[171]++,this.state.mapStyle.layers),i=(re().s[172]++,r.slice(0));re().s[173]++,i.splice(t,1),re().s[174]++,this.onLayersChange(i)}));nn(this,"onLayerCopy",(re().s[175]++,t=>{re().f[37]++;const r=(re().s[176]++,this.state.mapStyle.layers),i=(re().s[177]++,r.slice(0)),o=(re().s[178]++,_I(i[t]));re().s[179]++,o.id=o.id+"-copy",re().s[180]++,i.splice(t,0,o),re().s[181]++,this.onLayersChange(i)}));nn(this,"onLayerVisibilityToggle",(re().s[182]++,t=>{re().f[38]++;const r=(re().s[183]++,this.state.mapStyle.layers),i=(re().s[184]++,r.slice(0)),o=(re().s[185]++,{...i[t]}),s=(re().s[186]++,"layout"in o?(re().b[52][0]++,{...o.layout}):(re().b[52][1]++,{}));re().s[187]++,s.visibility=s.visibility==="none"?(re().b[53][0]++,"visible"):(re().b[53][1]++,"none"),re().s[188]++,o.layout=s,re().s[189]++,i[t]=o,re().s[190]++,this.onLayersChange(i)}));nn(this,"onLayerIdChange",(re().s[191]++,(t,r,i)=>{re().f[39]++;const o=(re().s[192]++,this.state.mapStyle.layers.slice(0));re().s[193]++,o[t]={...o[t],id:i},re().s[194]++,this.onLayersChange(o)}));nn(this,"onLayerChanged",(re().s[195]++,(t,r)=>{re().f[40]++;const i=(re().s[196]++,this.state.mapStyle.layers.slice(0));re().s[197]++,i[t]=r,re().s[198]++,this.onLayersChange(i)}));nn(this,"setMapState",(re().s[199]++,t=>{re().f[41]++,re().s[200]++,this.setState({mapState:t},this.setStateInUrl)}));nn(this,"setDefaultValues",(re().s[201]++,t=>{re().f[42]++;const r=(re().s[202]++,re().b[54][0]++,t.metadata||(re().b[54][1]++,{}));if(re().s[203]++,r["maputnik:renderer"]===void 0){re().b[55][0]++;const i=(re().s[204]++,{...t,metadata:{...t.metadata,"maputnik:renderer":"mlgljs"}});return re().s[205]++,i}else return re().b[55][1]++,re().s[206]++,t}));nn(this,"openStyle",(re().s[207]++,t=>{re().f[43]++,re().s[208]++,t=this.setDefaultValues(t),re().s[209]++,this.onStyleChanged(t)}));nn(this,"onMapChange",(re().s[234]++,t=>{re().f[49]++,re().s[235]++,this.setState({mapView:t})}));nn(this,"setStateInUrl",(re().s[251]++,()=>{re().f[53]++;const{mapState:t,mapStyle:r,isOpen:i}=(re().s[252]++,this.state),{selectedLayerIndex:o}=(re().s[253]++,this.state),s=(re().s[254]++,new URL(location.href)),a=(re().s[255]++,BI(JSON.stringify(r)));re().s[256]++,s.searchParams.set("layer",`${a}~${o}`);const f=(re().s[257]++,Object.entries(i).map(([g,x])=>(re().f[54]++,re().s[258]++,x===!0?(re().b[67][0]++,g):(re().b[67][1]++,null))).filter(g=>(re().f[55]++,re().s[259]++,g!==null)));re().s[260]++,f.length>0?(re().b[68][0]++,re().s[261]++,s.searchParams.set("modal",f.join(","))):(re().b[68][1]++,re().s[262]++,s.searchParams.delete("modal")),re().s[263]++,t==="map"?(re().b[69][0]++,re().s[264]++,s.searchParams.delete("view")):(re().b[69][1]++,re().s[265]++,t==="inspect"?(re().b[70][0]++,re().s[266]++,s.searchParams.set("view","inspect")):re().b[70][1]++),re().s[267]++,history.replaceState({selectedLayerIndex:o},"Maputnik",s.href)}));nn(this,"getInitialStateFromUrl",(re().s[268]++,t=>{re().f[56]++;const r=(re().s[269]++,new URL(location.href)),i=(re().s[270]++,r.searchParams.get("modal"));if(re().s[271]++,re().b[72][0]++,i&&(re().b[72][1]++,i!=="")){re().b[71][0]++;const a=(re().s[272]++,i.split(",")),f=(re().s[273]++,{});re().s[274]++,a.forEach(g=>{re().f[57]++,re().s[275]++,f[g]=!0}),re().s[276]++,this.setState({isOpen:{...this.state.isOpen,...f}})}else re().b[71][1]++;const o=(re().s[277]++,r.searchParams.get("view"));re().s[278]++,re().b[74][0]++,o&&(re().b[74][1]++,o!=="")?(re().b[73][0]++,re().s[279]++,this.setMapState(o)):re().b[73][1]++;const s=(re().s[280]++,r.searchParams.get("layer"));if(re().s[281]++,s){re().b[75][0]++,re().s[282]++;try{const a=(re().s[283]++,s.split("~")),[f,g]=(re().s[284]++,[a[0],parseInt(a[1],10)]);let x=(re().s[285]++,!0);if(re().s[286]++,f!=="-"){re().b[76][0]++;const k=(re().s[287]++,BI(JSON.stringify(t)));re().s[288]++,k!==parseInt(f,10)?(re().b[77][0]++,re().s[289]++,x=!1):re().b[77][1]++}else re().b[76][1]++;re().s[290]++,x?(re().b[78][0]++,re().s[291]++,this.setState({selectedLayerIndex:g,selectedLayerOriginalId:t.layers[g].id})):re().b[78][1]++}catch(a){re().s[292]++,console.warn(a)}}else re().b[75][1]++}));nn(this,"onLayerSelect",(re().s[293]++,t=>{re().f[58]++,re().s[294]++,this.setState({selectedLayerIndex:t,selectedLayerOriginalId:this.state.mapStyle.layers[t].id},this.setStateInUrl)}));nn(this,"onChangeOpenlayersDebug",(re().s[299]++,(t,r)=>{re().f[61]++,re().s[300]++,this.setState({openlayersDebugOptions:{...this.state.openlayersDebugOptions,[t]:r}})}));nn(this,"onChangeMaplibreGlDebug",(re().s[301]++,(t,r)=>{re().f[62]++,re().s[302]++,this.setState({maplibreGlDebugOptions:{...this.state.maplibreGlDebugOptions,[t]:r}})}));re().s[16]++,xq(this),re().s[17]++,this.revisionStore=new Z7e;const r=(re().s[18]++,new URLSearchParams(window.location.search.substring(1)));let i=(re().s[19]++,r.get("localport"));re().s[20]++,re().b[6][0]++,i==null&&(re().b[6][1]++,window.location.port!=="80")&&(re().b[6][2]++,window.location.port!=="443")?(re().b[5][0]++,re().s[21]++,i=window.location.port):re().b[5][1]++,re().s[22]++,this.styleStore=new H7e({onLocalStyleChange:a=>(re().f[3]++,re().s[23]++,this.onStyleChanged(a,{save:!1})),port:i,host:r.get("localhost")});const o=(re().s[24]++,[{key:"?",handler:()=>{re().f[4]++,re().s[25]++,this.toggleModal("shortcuts")}},{key:"o",handler:()=>{re().f[5]++,re().s[26]++,this.toggleModal("open")}},{key:"e",handler:()=>{re().f[6]++,re().s[27]++,this.toggleModal("export")}},{key:"d",handler:()=>{re().f[7]++,re().s[28]++,this.toggleModal("sources")}},{key:"s",handler:()=>{re().f[8]++,re().s[29]++,this.toggleModal("settings")}},{key:"i",handler:()=>{re().f[9]++,re().s[30]++,this.setMapState(this.state.mapState==="map"?(re().b[7][0]++,"inspect"):(re().b[7][1]++,"map"))}},{key:"m",handler:()=>{re().f[10]++,re().s[31]++,document.querySelector(".maplibregl-canvas").focus()}},{key:"!",handler:()=>{re().f[11]++,re().s[32]++,this.toggleModal("debug")}}]);re().s[33]++,document.body.addEventListener("keyup",a=>{if(re().f[12]++,re().s[34]++,a.key==="Escape")re().b[8][0]++,re().s[35]++,a.target.blur(),re().s[36]++,document.body.focus();else if(re().b[8][1]++,re().s[37]++,re().b[10][0]++,this.state.isOpen.shortcuts||(re().b[10][1]++,document.activeElement===document.body)){re().b[9][0]++;const f=(re().s[38]++,o.find(g=>(re().f[13]++,re().s[39]++,g.key===a.key)));re().s[40]++,f?(re().b[11][0]++,re().s[41]++,this.setModal("shortcuts",!1),re().s[42]++,f.handler()):re().b[11][1]++}else re().b[9][1]++});const s=(re().s[43]++,D7e());re().s[44]++,re().b[13][0]++,s&&(re().b[13][1]++,window.confirm("Load style from URL: "+s+" and discard current changes?"))?(re().b[12][0]++,re().s[45]++,this.styleStore=new nF,re().s[46]++,IG(s,a=>(re().f[14]++,re().s[47]++,this.onStyleChanged(a))),re().s[48]++,XP()):(re().b[12][1]++,re().s[49]++,s?(re().b[14][0]++,re().s[50]++,XP()):re().b[14][1]++,re().s[51]++,this.styleStore.init(a=>{re().f[15]++,re().s[52]++,a?(re().b[15][0]++,re().s[53]++,console.log("Falling back to local storage for storing styles"),re().s[54]++,this.styleStore=new nF):re().b[15][1]++,re().s[55]++,this.styleStore.latestStyle(f=>(re().f[16]++,re().s[56]++,this.onStyleChanged(f,{initialLoad:!0}))),re().s[57]++,B0.enabled()?(re().b[16][0]++,re().s[58]++,B0.set("maputnik","styleStore",this.styleStore),re().s[59]++,B0.set("maputnik","revisionStore",this.revisionStore)):re().b[16][1]++})),re().s[60]++,B0.enabled()?(re().b[17][0]++,re().s[61]++,B0.set("maputnik","revisionStore",this.revisionStore),re().s[62]++,B0.set("maputnik","styleStore",this.styleStore)):re().b[17][1]++,re().s[63]++,this.state={errors:[],infos:[],mapStyle:vu.emptyStyle,selectedLayerIndex:0,sources:{},vectorLayers:{},mapState:"map",spec:ma,mapView:{zoom:0,center:{lng:0,lat:0}},isOpen:{settings:!1,sources:!1,open:!1,shortcuts:!1,export:!1,survey:!1,debug:!1},maplibreGlDebugOptions:{showTileBoundaries:!1,showCollisionBoxes:!1,showOverdrawInspector:!1},openlayersDebugOptions:{debugToolbox:!1}},re().s[64]++,this.layerWatcher=new g8e({onVectorLayersChange:a=>(re().f[17]++,re().s[65]++,this.setState({vectorLayers:a}))})}componentDidMount(){re().f[19]++,re().s[80]++,window.addEventListener("keydown",this.handleKeyPress)}componentWillUnmount(){re().f[20]++,re().s[81]++,window.removeEventListener("keydown",this.handleKeyPress)}saveStyle(t){re().f[21]++,re().s[82]++,this.styleStore.save(t)}updateFonts(t){re().f[22]++;const r=(re().s[83]++,re().b[27][0]++,this.state.mapStyle.metadata||(re().b[27][1]++,{})),i=(re().s[84]++,re().b[28][0]++,r["maputnik:openmaptiles_access_token"]||(re().b[28][1]++,iG.openmaptiles)),o=(re().s[85]++,typeof t=="string"?(re().b[29][0]++,t.replace("{key}",i)):(re().b[29][1]++,t));re().s[86]++,P7e(o,s=>{re().f[23]++,re().s[87]++,this.setState({spec:oF(this.state.spec,"glyphs",s)})})}updateIcons(t){re().f[24]++,re().s[88]++,F7e(t,r=>{re().f[25]++,re().s[89]++,this.setState({spec:oF(this.state.spec,"sprite",r)})})}fetchSources(){re().f[44]++;const t=(re().s[210]++,{});re().s[211]++;for(const[r,i]of Object.entries(this.state.mapStyle.sources))if(re().s[212]++,re().b[57][0]++,!Object.prototype.hasOwnProperty.call(this.state.sources,r)&&(re().b[57][1]++,i.type==="vector")&&(re().b[57][2]++,Object.prototype.hasOwnProperty.call(i,"url"))){re().b[56][0]++,re().s[213]++,t[r]={type:i.type,layers:[]};let o=(re().s[214]++,i.url);re().s[215]++;try{re().s[216]++,o=C8e(o,this.state.mapStyle)}catch(s){re().s[217]++,console.warn("Failed to setFetchAccessToken: ",s)}re().s[218]++,fetch(o,{mode:"cors"}).then(s=>(re().f[45]++,re().s[219]++,s.json())).then(s=>{if(re().f[46]++,re().s[220]++,Object.prototype.hasOwnProperty.call(s,"vector_layers"))re().b[58][1]++;else{re().b[58][0]++,re().s[221]++;return}const a=(re().s[222]++,Object.assign({},{[r]:this.state.sources[r]}));re().s[223]++;for(const f of s.vector_layers)re().s[224]++,a[r].layers.push(f.id);re().s[225]++,console.debug("Updating source: "+r),re().s[226]++,this.setState({sources:a})}).catch(s=>{re().f[47]++,re().s[227]++,console.error("Failed to process sources for '%s'",o,s)})}else re().b[56][1]++,re().s[228]++,t[r]=(re().b[59][0]++,this.state.sources[r]||(re().b[59][1]++,this.state.mapStyle.sources[r]));re().s[229]++,k6(this.state.sources,t)?re().b[60][1]++:(re().b[60][0]++,re().s[230]++,console.debug("Setting sources"),re().s[231]++,this.setState({sources:t}))}_getRenderer(){re().f[48]++;const t=(re().s[232]++,re().b[61][0]++,this.state.mapStyle.metadata||(re().b[61][1]++,{}));return re().s[233]++,re().b[62][0]++,t["maputnik:renderer"]||(re().b[62][1]++,"mlgljs")}mapRenderer(){re().f[50]++;const{mapStyle:t,dirtyMapStyle:r}=(re().s[236]++,this.state),i=(re().s[237]++,{mapStyle:(re().b[63][0]++,r||(re().b[63][1]++,t)),replaceAccessTokens:g=>(re().f[51]++,re().s[238]++,vu.replaceAccessTokens(g,{allowFallback:!0})),onDataChange:g=>{re().f[52]++,re().s[239]++,this.layerWatcher.analyzeMap(g.map),re().s[240]++,this.fetchSources()}}),o=(re().s[241]++,this._getRenderer());let s;re().s[242]++,o==="ol"?(re().b[64][0]++,re().s[243]++,s=N.jsx(Ij,{...i,onChange:this.onMapChange,debugToolbox:this.state.openlayersDebugOptions.debugToolbox,onLayerSelect:this.onLayerSelect})):(re().b[64][1]++,re().s[244]++,s=N.jsx(aL,{...i,onChange:this.onMapChange,options:this.state.maplibreGlDebugOptions,inspectModeEnabled:this.state.mapState==="inspect",highlightedLayer:this.state.mapStyle.layers[this.state.selectedLayerIndex],onLayerSelect:this.onLayerSelect}));let a;re().s[245]++,this.state.mapState.match(/^filter-/)?(re().b[65][0]++,re().s[246]++,a=this.state.mapState.replace(/^filter-/,"")):re().b[65][1]++;const f=(re().s[247]++,{});return re().s[248]++,a?(re().b[66][0]++,re().s[249]++,f.filter=`url('#${a}')`):re().b[66][1]++,re().s[250]++,N.jsx("div",{style:f,className:"maputnik-map__container","data-wd-key":"maplibre:container",children:s})}setModal(t,r){re().f[59]++,re().s[295]++,re().b[80][0]++,t==="survey"&&(re().b[80][1]++,r===!1)?(re().b[79][0]++,re().s[296]++,localStorage.setItem("survey","")):re().b[79][1]++,re().s[297]++,this.setState({isOpen:{...this.state.isOpen,[t]:r}},this.setStateInUrl)}toggleModal(t){re().f[60]++,re().s[298]++,this.setModal(t,!this.state.isOpen[t])}render(){re().f[63]++;const t=(re().s[303]++,re().b[81][0]++,this.state.mapStyle.layers||(re().b[81][1]++,[])),r=(re().s[304]++,t.length>0?(re().b[82][0]++,t[this.state.selectedLayerIndex]):(re().b[82][1]++,void 0)),i=(re().s[305]++,N.jsx(dEe,{renderer:this._getRenderer(),mapState:this.state.mapState,mapStyle:this.state.mapStyle,inspectModeEnabled:this.state.mapState==="inspect",sources:this.state.sources,onStyleChanged:this.onStyleChanged,onStyleOpen:this.onStyleChanged,onSetMapState:this.setMapState,onToggleModal:this.toggleModal.bind(this)})),o=(re().s[306]++,N.jsx(Dhe,{onMoveLayer:this.onMoveLayer,onLayerDestroy:this.onLayerDestroy,onLayerCopy:this.onLayerCopy,onLayerVisibilityToggle:this.onLayerVisibilityToggle,onLayersChange:this.onLayersChange,onLayerSelect:this.onLayerSelect,selectedLayerIndex:this.state.selectedLayerIndex,layers:t,sources:this.state.sources,errors:this.state.errors})),s=(re().s[307]++,r?(re().b[83][0]++,N.jsx(tO,{layer:r,layerIndex:this.state.selectedLayerIndex,isFirstLayer:this.state.selectedLayerIndex<1,isLastLayer:this.state.selectedLayerIndex===this.state.mapStyle.layers.length-1,sources:this.state.sources,vectorLayers:this.state.vectorLayers,spec:this.state.spec,onMoveLayer:this.onMoveLayer,onLayerChanged:this.onLayerChanged,onLayerDestroy:this.onLayerDestroy,onLayerCopy:this.onLayerCopy,onLayerVisibilityToggle:this.onLayerVisibilityToggle,onLayerIdChange:this.onLayerIdChange,errors:this.state.errors},this.state.selectedLayerOriginalId)):(re().b[83][1]++,void 0)),a=(re().s[308]++,this.state.errors.length+this.state.infos.length>0?(re().b[84][0]++,N.jsx(tG,{currentLayer:r,selectedLayerIndex:this.state.selectedLayerIndex,onLayerSelect:this.onLayerSelect,mapStyle:this.state.mapStyle,errors:this.state.errors,infos:this.state.infos})):(re().b[84][1]++,void 0)),f=(re().s[309]++,N.jsxs("div",{children:[N.jsx(dOe,{renderer:this._getRenderer(),maplibreGlDebugOptions:this.state.maplibreGlDebugOptions,openlayersDebugOptions:this.state.openlayersDebugOptions,onChangeMaplibreGlDebug:this.onChangeMaplibreGlDebug,onChangeOpenlayersDebug:this.onChangeOpenlayersDebug,isOpen:this.state.isOpen.debug,onOpenToggle:this.toggleModal.bind(this,"debug"),mapView:this.state.mapView}),N.jsx(uOe,{ref:g=>(re().f[64]++,re().s[310]++,this.shortcutEl=g),isOpen:this.state.isOpen.shortcuts,onOpenToggle:this.toggleModal.bind(this,"shortcuts")}),N.jsx(mEe,{mapStyle:this.state.mapStyle,onStyleChanged:this.onStyleChanged,onChangeMetadataProperty:this.onChangeMetadataProperty,isOpen:this.state.isOpen.settings,onOpenToggle:this.toggleModal.bind(this,"settings")}),N.jsx(kEe,{mapStyle:this.state.mapStyle,onStyleChanged:this.onStyleChanged,isOpen:this.state.isOpen.export,onOpenToggle:this.toggleModal.bind(this,"export")}),N.jsx(lOe,{isOpen:this.state.isOpen.open,onStyleOpen:this.openStyle,onOpenToggle:this.toggleModal.bind(this,"open")}),N.jsx(QEe,{mapStyle:this.state.mapStyle,onStyleChanged:this.onStyleChanged,isOpen:this.state.isOpen.sources,onOpenToggle:this.toggleModal.bind(this,"sources")}),N.jsx(cOe,{isOpen:this.state.isOpen.survey,onOpenToggle:this.toggleModal.bind(this,"survey")})]}));return re().s[311]++,N.jsx(eG,{toolbar:i,layerList:o,layerEditor:s,map:this.mapRenderer(),bottom:a,modals:f})}}_U.render(N.jsx(wS.Provider,{value:{className:"react-icons"},children:N.jsx(_8e,{})}),document.querySelector("#app"));document.querySelector(".loading").style.display="none";
|
||
//# sourceMappingURL=index-Z_ZPHxae.js.map
|